chore: stories

feat/type-attributes
Tomáš Mládek 2023-01-21 18:55:50 +01:00
parent 8528805ea7
commit d7920f6c15
3 changed files with 28 additions and 10 deletions

View File

@ -18,7 +18,6 @@ const meta: Meta<Gallery> = {
imageVerticalAddress, imageVerticalAddress,
videoAddress, videoAddress,
videoVerticalAddress, videoVerticalAddress,
], ],
}, },
decorators: [() => RouterDecorator], decorators: [() => RouterDecorator],
@ -27,14 +26,14 @@ const meta: Meta<Gallery> = {
export default meta; export default meta;
type Story = StoryObj<Gallery>; type Story = StoryObj<Gallery>;
export const Plain: Story = {
args: {
thumbnails: false,
},
};
export const Thumbnails: Story = { export const Thumbnails: Story = {
args: { args: {
thumbnails: true, thumbnails: true,
}, },
}; };
export const Plain: Story = {
args: {
thumbnails: false,
},
};

View File

@ -28,7 +28,7 @@ export default meta;
type Story = StoryObj<UpObject>; type Story = StoryObj<UpObject>;
// More on writing stories with args: https://storybook.js.org/docs/7.0/svelte/writing-stories/args // More on writing stories with args: https://storybook.js.org/docs/7.0/svelte/writing-stories/args
export const Plain: Story = {}; export const Default: Story = {};
export const WithLabels: Story = { export const WithLabels: Story = {
args: { args: {
@ -48,3 +48,10 @@ export const Banner: Story = {
banner: true, banner: true,
}, },
}; };
export const BannerWithLabels: Story = {
args: {
banner: true,
labels: ["Label 1", "Label B", "Label III"],
},
};

View File

@ -19,16 +19,28 @@ const meta: Meta<UpObjectCard> = {
type: "string", type: "string",
}, },
}, },
decorators: [() => RouterDecorator] decorators: [() => RouterDecorator],
}; };
export default meta; export default meta;
type Story = StoryObj<UpObjectCard>; type Story = StoryObj<UpObjectCard>;
export const Plain: Story = {}; export const Default: Story = {};
export const WithLabels: Story = { export const WithLabels: Story = {
args: { args: {
labels: ["Label 1", "Label B", "Label III"], labels: ["Label 1", "Label B", "Label III"],
}, },
}; };
export const WithoutThumbnail: Story = {
args: {
thumbnail: false,
},
};
export const Small: Story = {
args: {
banner: false,
},
};