Skip to content

Commit

Permalink
button width and modal header font fix (#32)
Browse files Browse the repository at this point in the history
  • Loading branch information
Vadim73i authored Aug 1, 2024
1 parent d7cfa7e commit ae76350
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 4 deletions.
1 change: 1 addition & 0 deletions src/components/button/button.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
justify-content: center;
align-items: center;
height: 36px;
min-width: 120px;
padding: 7px 16px;
margin: 0;
outline: none;
Expand Down
11 changes: 7 additions & 4 deletions src/components/modal/modal.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ export const WithSteps: Story = {
render: (args) => {
// eslint-disable-next-line react-hooks/rules-of-hooks
const [step, setStep] = useState<number>(1);
const buttonStyle = { minWidth: 'fit-content' };

const CustomFooter: FC<{ closeHandler: () => void }> = ({ closeHandler }) => {
return (
Expand All @@ -55,14 +56,16 @@ export const WithSteps: Story = {
gap: 18,
}}
>
<Button variant={'ghost'} onClick={() => setStep(1)}>
<Button style={buttonStyle} variant={'ghost'} onClick={() => setStep(1)}>
Go to 1 step
</Button>
<Button variant={'ghost'} onClick={() => setStep(2)}>
<Button style={buttonStyle} variant={'ghost'} onClick={() => setStep(2)}>
Go to 2 step
</Button>
<Button onClick={() => console.log('done')}>OK</Button>
<Button variant={'danger'} onClick={() => closeHandler()}>
<Button style={buttonStyle} onClick={() => console.log('done')}>
OK
</Button>
<Button style={buttonStyle} variant={'danger'} onClick={() => closeHandler()}>
Cancel
</Button>
</div>
Expand Down
1 change: 1 addition & 0 deletions src/components/modal/modalHeader/modalHeader.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
}

.modal-title {
font-family: var(--rp-ui-base-font-family-heading);
flex-grow: 1;
vertical-align: middle;
text-overflow: ellipsis;
Expand Down

0 comments on commit ae76350

Please sign in to comment.