mirror of
https://github.com/Kong/insomnia
synced 2024-11-08 14:49:53 +00:00
21 lines
527 B
JavaScript
21 lines
527 B
JavaScript
import * as React from 'react';
|
|
import MultiSwitch from './multi-switch';
|
|
|
|
export default { title: 'Navigation | Sliding Switch' };
|
|
|
|
export const _default = () => {
|
|
const [selectedValue, setSelectedValue] = React.useState('debug');
|
|
return (
|
|
<MultiSwitch
|
|
name="activity"
|
|
onChange={setSelectedValue}
|
|
choices={[
|
|
{ label: 'Design', value: 'design' },
|
|
{ label: 'Debug', value: 'debug' },
|
|
{ label: 'Test', value: 'test' },
|
|
]}
|
|
selectedValue={selectedValue}
|
|
/>
|
|
);
|
|
};
|