From a01c17d97b295e6630655574229c04c32cb35168 Mon Sep 17 00:00:00 2001 From: CJ Cenizal Date: Sat, 18 Nov 2023 16:58:12 -0800 Subject: [PATCH] Add fullWidth prop to VuiTopicButton. --- src/lib/components/topicButton/TopicButton.tsx | 7 +++++-- src/lib/components/topicButton/_index.scss | 4 ++++ 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/src/lib/components/topicButton/TopicButton.tsx b/src/lib/components/topicButton/TopicButton.tsx index 8298fd6..00749e0 100644 --- a/src/lib/components/topicButton/TopicButton.tsx +++ b/src/lib/components/topicButton/TopicButton.tsx @@ -9,10 +9,13 @@ type Props = { href?: string; onClick?: () => void; title?: string; + fullWidth?: boolean; }; -export const VuiTopicButton = ({ children, className, href, onClick, title, ...rest }: Props) => { - const classes = classNames("vuiTopicButton", className); +export const VuiTopicButton = ({ children, className, href, onClick, title, fullWidth, ...rest }: Props) => { + const classes = classNames("vuiTopicButton", className, { + "vuiTopicButton--fullWidth": fullWidth + }); const content = ( <> {title && ( diff --git a/src/lib/components/topicButton/_index.scss b/src/lib/components/topicButton/_index.scss index 787c09a..5dc5034 100644 --- a/src/lib/components/topicButton/_index.scss +++ b/src/lib/components/topicButton/_index.scss @@ -14,3 +14,7 @@ z-index: 1; } } + +.vuiTopicButton--fullWidth { + width: 100%; +}