Skip to content

Commit

Permalink
docs: add datepicker component story (#156)
Browse files Browse the repository at this point in the history
* docs: datepicker component document (#118)

* fix(docs): remove reactivity in datepicker (#118)
  • Loading branch information
beambeambeam authored Nov 6, 2024
1 parent da671a5 commit b248616
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions src/components/DatePicker/DatePicker.story.svelte
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<script lang="ts">
import type { Hst } from '@histoire/plugin-svelte';
import DatePicker from './DatePicker.svelte';
export let Hst: Hst;
let selectedDate = new Date();
const handleSelectDate = (date: Date) => {
selectedDate = date;
};
</script>

<Hst.Story title="DatePicker" layout={{ type: 'single' }}>
<DatePicker {selectedDate} {handleSelectDate} />
</Hst.Story>

0 comments on commit b248616

Please sign in to comment.