test: add stories for MkChannelPreview

This commit is contained in:
Acid Chicken (硫酸鶏) 2023-05-29 05:14:33 +09:00
parent 01b7ce11ba
commit 48e2943502
No known key found for this signature in database
GPG key ID: 3E87B98A3F6BAB99
2 changed files with 34 additions and 0 deletions

View file

@ -0,0 +1,2 @@
import MkChannelList from './MkChannelList.vue';
void MkChannelList;

View file

@ -0,0 +1,32 @@
/* eslint-disable @typescript-eslint/explicit-function-return-type */
import { StoryObj } from '@storybook/vue3';
import { channel } from '../../.storybook/fakes';
import MkChannelPreview from './MkChannelPreview.vue';
export const Default = {
render(args) {
return {
components: {
MkChannelPreview,
},
setup() {
return {
args,
};
},
computed: {
props() {
return {
...this.args,
};
},
},
template: '<MkChannelPreview v-bind="props" / >',
};
},
args: {
channel: channel(),
},
parameters: {
layout: 'default',
},
} satisfies StoryObj<typeof MkChannelPreview>;