Skip to content

Commit 2fc77cf

Browse files
Merge pull request #27 from jeffreylauwers/fix/dateinputgroup-react-source
fix(storybook): DateInputGroup React tab toont correcte code i.p.v. <q />
2 parents 0a6baee + 8789e07 commit 2fc77cf

1 file changed

Lines changed: 16 additions & 1 deletion

File tree

packages/storybook/src/DateInputGroup.stories.tsx

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,22 @@ function InvalidStory(args: React.ComponentProps<typeof DateInputGroup>) {
9595
// DEFAULT
9696
// =============================================================================
9797

98-
export const Default: Story = { render: (args) => <DefaultStory {...args} /> };
98+
export const Default: Story = {
99+
parameters: {
100+
docs: {
101+
source: {
102+
code: `const [value, setValue] = useState<DateInputGroupValue>({
103+
day: '',
104+
month: '',
105+
year: '',
106+
});
107+
108+
<DateInputGroup id="datum" value={value} onChange={setValue} />`,
109+
},
110+
},
111+
},
112+
render: (args) => <DefaultStory {...args} />,
113+
};
99114

100115
// =============================================================================
101116
// VARIANTEN

0 commit comments

Comments
 (0)