Download wp-calypso/packages/components/src/select-dropdown/index.stories.jsx from Devendra174/react-code-dataset: direct link, hf CLI and curl.
- Browser
- Download file 774 Bytes
-
https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/wp-calypso/packages/components/src/select-dropdown/index.stories.jsx
- Command line
-
hf download hf://datasets/Devendra174/react-code-dataset/wp-calypso/packages/components/src/select-dropdown/index.stories.jsx
-
curl -L -o index.stories.jsx https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/wp-calypso/packages/components/src/select-dropdown/index.stories.jsx
774 Bytes
| import SelectDropdown from '.'; | |
| export default { component: SelectDropdown, title: 'Unaudited/SelectDropdown' }; | |
| const Template = ( args ) => { | |
| return <SelectDropdown { ...args } />; | |
| }; | |
| export const Default = Template.bind( {} ); | |
| Default.args = { | |
| ariaLabel: 'select-dropdown-aria-label', | |
| className: 'select-dropdown', | |
| compact: false, | |
| disabled: false, | |
| isLoading: false, | |
| // eslint-disable-next-line no-console | |
| onToggle: () => console.log( 'Toggled' ), | |
| onSelect: ( { label } ) => { | |
| // eslint-disable-next-line no-console | |
| console.log( `${ label } Dropdown item selected` ); | |
| }, | |
| initialSelected: 'pikachu', | |
| options: [ | |
| { value: 'pikachu', label: 'Pikachu' }, | |
| { value: 'charmander', label: 'Charmander' }, | |
| { value: 'bulbasaur', label: 'Bulbasaur' }, | |
| ], | |
| }; | |