mirror of
https://github.com/Kong/insomnia
synced 2024-11-12 17:26:32 +00:00
24 lines
629 B
JavaScript
24 lines
629 B
JavaScript
// @flow
|
|
import * as React from 'react';
|
|
|
|
import RadioButtonGroup from './radio-button-group';
|
|
|
|
export default { title: 'Navigation | Radio Button Group' };
|
|
|
|
export const _default = () => {
|
|
const [selectedValue, setSelectedValue] = React.useState('scratch');
|
|
return (
|
|
<RadioButtonGroup
|
|
name="dummy"
|
|
onChange={setSelectedValue}
|
|
choices={[
|
|
{ label: 'From Scratch', value: 'scratch' },
|
|
{ label: 'From Repository', value: 'repo' },
|
|
{ label: 'From Clipboard', value: 'clip' },
|
|
{ label: 'From Spec', value: 'spec' },
|
|
]}
|
|
selectedValue={selectedValue}
|
|
/>
|
|
);
|
|
};
|