Open platform to collect and prioritize feedback
Vote button set to constant width
Matt Roberts06c303a18481
diff --git a/public/components/common/Button.tsx b/public/components/common/Button.tsxindex ca6623502..6d271849c 100644--- a/public/components/common/Button.tsx+++ b/public/components/common/Button.tsx@@ -12,9 +12,9 @@ interface ButtonProps {type?: "button" | "submit"variant?: "primary" | "danger" | "secondary" | "tertiary"size?: "small" | "default" | "large"+ style?: React.CSSPropertiesonClick?: (event: ButtonClickEvent) => Promise<any> | void}-export class ButtonClickEvent {private shouldEnable = truepublic preventEnable(): void {@@ -50,7 +50,7 @@ export const Button: React.FC<ButtonProps> = (props) => {if (props.href) {buttonContent = (- <a href={props.href} rel={props.rel} target={props.target} className={className}>+ <a href={props.href} rel={props.rel} target={props.target} className={className} style={props.style}>{props.children}</a>)@@ -76,13 +76,13 @@ export const Button: React.FC<ButtonProps> = (props) => {}buttonContent = (- <button type={props.type} className={className} onClick={onClick}>+ <button type={props.type} className={className} onClick={onClick} style={props.style}>{props.children}</button>)} else {buttonContent = (- <button type={props.type} className={className}>+ <button type={props.type} className={className} style={props.style}>{props.children}</button>)diff --git a/public/pages/ShowPost/components/VoteSection.tsx b/public/pages/ShowPost/components/VoteSection.tsxindex 5c8c15b01..dff750d5b 100644--- a/public/pages/ShowPost/components/VoteSection.tsx+++ b/public/pages/ShowPost/components/VoteSection.tsx@@ -53,8 +53,10 @@ export const VoteSection = (props: VoteSectionProps) => {<VStack spacing={4}><SignInModal isOpen={isSignInModalOpen} onClose={hideModal} /><div className="align-self-start">- <Button variant="primary" onClick={voteOrUndo} disabled={isDisabled}>- <Icon sprite={icon} /> <span>{buttonText}</span>+ <Button variant="primary" onClick={voteOrUndo} disabled={isDisabled} style={{ minWidth: "180px" }}>+ <HStack spacing={2} justify="center" className="w-full">+ <Icon sprite={icon} /> <span>{buttonText}</span>+ </HStack></Button></div><HStack>