Skip to content

Commit

Permalink
fix the story
Browse files Browse the repository at this point in the history
  • Loading branch information
sharlotta93 committed Jan 15, 2025
1 parent fb0f0aa commit 1d59176
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions src/stories/DateRangeSelect.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,17 @@ type Story = StoryObj<typeof DateRangeSelect>;
export const InitialDates = {
args: {
onSelect: (from: string, to: string) => console.log('Date range changed:', { from, to }),
defaultFromDate: addDays(new Date(), -7).toISOString(),
defaultToDate: new Date().toISOString()
defaultDateRange: {
from: addDays(new Date(), -7).toISOString(),
to: new Date().toISOString()
}
},
render: (args) => <DateRangeSelect {...args} />
} satisfies Story;

export const NoInitialDates = {
args: {
onSelect: (from: string, to: string) => console.log('Date range changed:', { from, to }),
withInitialDates: false
onSelect: (from: string, to: string) => console.log('Date range changed:', { from, to })
},
render: (args) => <DateRangeSelect {...args} />
} satisfies Story;

0 comments on commit 1d59176

Please sign in to comment.