-
Notifications
You must be signed in to change notification settings - Fork 99
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test(Button): add 'render custom Icon size' test (#1455)
- Loading branch information
1 parent
b0b3ec8
commit f031d13
Showing
7 changed files
with
48 additions
and
6 deletions.
There are no files selected for viewing
Binary file added
BIN
+41 KB
...isual.test.tsx-snapshots/Button-render-custom-Icon-size-dark-chromium-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+24.5 KB
....visual.test.tsx-snapshots/Button-render-custom-Icon-size-dark-webkit-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+39.1 KB
...sual.test.tsx-snapshots/Button-render-custom-Icon-size-light-chromium-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+23.1 KB
...visual.test.tsx-snapshots/Button-render-custom-Icon-size-light-webkit-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
import React from 'react'; | ||
|
||
import {ChevronDown, Globe} from '@gravity-ui/icons'; | ||
import {composeStories} from '@storybook/react'; | ||
|
||
import {Button} from '..'; | ||
import {Showcase} from '../../../demo/Showcase'; | ||
import {Icon} from '../../Icon'; | ||
import * as DefaultButtonStories from '../__stories__/Button.stories'; | ||
|
||
export const ButtonStories = composeStories(DefaultButtonStories); | ||
|
||
export const CustomIconSizeButton = () => ( | ||
<Showcase> | ||
<Button size="xs"> | ||
<Icon size={16} data={Globe} /> | ||
Both bigger icons | ||
<Icon size={16} data={ChevronDown} /> | ||
</Button> | ||
<Button size="s"> | ||
<Icon size={20} data={Globe} /> | ||
Both bigger icons | ||
<Icon size={20} data={ChevronDown} /> | ||
</Button> | ||
<Button size="m"> | ||
<Icon size={20} data={Globe} /> | ||
Both bigger icons | ||
<Icon size={20} data={ChevronDown} /> | ||
</Button> | ||
<Button size="l"> | ||
<Icon size={20} data={Globe} /> | ||
Both bigger icons | ||
<Icon size={20} data={ChevronDown} /> | ||
</Button> | ||
<Button size="xl"> | ||
<Icon size={24} data={Globe} /> | ||
Both bigger icons | ||
<Icon size={24} data={ChevronDown} /> | ||
</Button> | ||
</Showcase> | ||
); |