Skip to content

fix: chromatic screenshots tests status #4481

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Feb 21, 2025
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 0 additions & 13 deletions packages/ui/src/components/va-date-picker/VaDatePicker.demo.vue
Original file line number Diff line number Diff line change
Expand Up @@ -16,18 +16,6 @@
<va-date-picker mode="multiple" v-model="dates" />
</VbCard>

<VbCard title="statefull">
<va-date-picker stateful />
</VbCard>

<VbCard title="readonly">
<va-date-picker readonly v-model:view="currentMonthDayView" />
</VbCard>

<VbCard title="without value">
<va-date-picker />
</VbCard>

<VbCard title="weekday names">
<va-date-picker v-model="value" :weekdayNames="['SUN', 'MON', 'TUE', 'WED', 'THU', 'FRI', 'SAT']" />
</VbCard>
Expand Down Expand Up @@ -188,7 +176,6 @@ export default {

dayView: { type: 'day', month: 6, year: 2020 } satisfies DatePickerViewProp,
monthView: { type: 'month' } satisfies DatePickerViewProp,
currentMonthDayView: { type: 'day', month: new Date().getMonth(), year: new Date().getFullYear() } satisfies DatePickerViewProp,
yearView: { type: 'year' } satisfies DatePickerViewProp,
}
},
Expand Down
19 changes: 19 additions & 0 deletions packages/ui/src/components/va-date-picker/VaDatePicker.stories.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,32 @@ export const Default: StoryFn = () => ({
template: '<VaDatePickerDemo />',
})

export const dynamicCurrentDate: StoryFn = () => ({
components: { VaDatePicker },
template: `
<VbDemo>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This component is not needed

<VbCard title="statefull">
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's split these into multiple stories.

<va-date-picker stateful />
</VbCard>
<VbCard title="readonly">
<va-date-picker readonly />
</VbCard>
<VbCard title="without value">
<va-date-picker />
</VbCard>
</VbDemo>
`,
})
dynamicCurrentDate.parameters = { chromatic: { disableSnapshot: true } }
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please comment why


export const firstWeekDay: StoryFn = () => ({
components: { VaDatePicker },
template: `
<VaDatePicker firstWeekday="sunday"/>
<VaDatePicker firstWeekday="monday"/>
`,
})
firstWeekDay.parameters = { chromatic: { disableSnapshot: true } }

export const Range = () => ({
components: { VaDatePicker },
Expand Down
Loading