@reni-corp/reni-2c-ui 0.3.28 → 0.3.291
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +0 -196
- package/dist/components/elements/Alert.vue.d.ts +21 -3
- package/dist/components/elements/Alert.vue.d.ts.map +1 -1
- package/dist/components/elements/CheckBox.vue.d.ts +42 -2
- package/dist/components/elements/CheckBox.vue.d.ts.map +1 -1
- package/dist/components/elements/ComboBox.vue.d.ts +153 -0
- package/dist/components/elements/ComboBox.vue.d.ts.map +1 -0
- package/dist/components/elements/Icon.vue.d.ts.map +1 -1
- package/dist/components/elements/PasswordField.vue.d.ts +75 -25
- package/dist/components/elements/PasswordField.vue.d.ts.map +1 -1
- package/dist/components/elements/Progress.vue.d.ts +45 -0
- package/dist/components/elements/Progress.vue.d.ts.map +1 -0
- package/dist/components/elements/SelectBox.vue.d.ts +30 -10
- package/dist/components/elements/SelectBox.vue.d.ts.map +1 -1
- package/dist/components/elements/SkeletonLoader.vue.d.ts +30 -0
- package/dist/components/elements/SkeletonLoader.vue.d.ts.map +1 -0
- package/dist/components/elements/SpinButton.vue.d.ts +4 -2
- package/dist/components/elements/SpinButton.vue.d.ts.map +1 -1
- package/dist/components/elements/TextField.vue.d.ts +21 -6
- package/dist/components/elements/TextField.vue.d.ts.map +1 -1
- package/dist/components/features/ProductList.vue.d.ts +4 -0
- package/dist/components/features/ProductList.vue.d.ts.map +1 -1
- package/dist/components/features/ProductListItem.vue.d.ts +4 -0
- package/dist/components/features/ProductListItem.vue.d.ts.map +1 -1
- package/dist/components/features/ProductPurchase.vue.d.ts +0 -4
- package/dist/components/features/ProductPurchase.vue.d.ts.map +1 -1
- package/dist/components/foundation/AppBar.vue.d.ts +28 -3
- package/dist/components/foundation/AppBar.vue.d.ts.map +1 -1
- package/dist/components/foundation/AppFooter.vue.d.ts +51 -1
- package/dist/components/foundation/AppFooter.vue.d.ts.map +1 -1
- package/dist/components/interactive/Disclosure.vue.d.ts +54 -0
- package/dist/components/interactive/Disclosure.vue.d.ts.map +1 -0
- package/dist/components/layouts/Page.vue.d.ts +2 -0
- package/dist/components/layouts/Page.vue.d.ts.map +1 -1
- package/dist/components/renderless/Form.vue.d.ts +27 -1
- package/dist/components/renderless/Form.vue.d.ts.map +1 -1
- package/dist/index.d.ts +9 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.es.js +7161 -5941
- package/dist/script.es.js +8364 -7146
- package/dist/script.umd.js +26 -26
- package/dist/style.css +1 -1
- package/dist/types.d.ts +7 -0
- package/dist/types.d.ts.map +1 -1
- package/dist/utils.d.ts.map +1 -1
- package/package.json +18 -13
- package/src/stories/Alert.stories.ts +260 -0
- package/src/stories/AnnounceBar.stories.ts +138 -0
- package/src/stories/AppBar.stories.ts +277 -0
- package/src/stories/AppFooter.stories.ts +274 -0
- package/src/stories/AppFrame.stories.ts +46 -0
- package/src/stories/AppLayout.stories.ts +870 -0
- package/src/stories/Button.stories.ts +101 -0
- package/src/stories/Card.stories.ts +152 -0
- package/src/stories/Carousel.stories.ts +62 -0
- package/src/stories/CarouselBanner.stories.ts +103 -0
- package/src/stories/CheckBox.stories.ts +76 -0
- package/src/stories/ComboBox.stories.ts +524 -0
- package/src/stories/Dialog.stories.ts +174 -0
- package/src/stories/Disclosure.stories.ts +217 -0
- package/src/stories/Divider.stories.ts +68 -0
- package/src/stories/Drawer.stories.ts +135 -0
- package/src/stories/DropDown.stories.ts +195 -0
- package/src/stories/FloatingBanner.stories.ts +79 -0
- package/src/stories/Form.stories.ts +704 -0
- package/src/stories/Gallery.stories.ts +78 -0
- package/src/stories/Grid.stories.ts +357 -0
- package/src/stories/Hero.stories.ts +52 -0
- package/src/stories/Html.stories.ts +178 -0
- package/src/stories/Icon.stories.ts +176 -0
- package/src/stories/Image.stories.ts +613 -0
- package/src/stories/Label.stories.ts +54 -0
- package/src/stories/List.stories.ts +112 -0
- package/src/stories/Modal.stories.ts +123 -0
- package/src/stories/Notification.stories.ts +82 -0
- package/src/stories/Page.stories.ts +414 -0
- package/src/stories/PasswordField.stories.ts +304 -0
- package/src/stories/ProductLabels.stories.ts +65 -0
- package/src/stories/ProductList.stories.ts +679 -0
- package/src/stories/ProductPurchase.stories.ts +807 -0
- package/src/stories/Progress.stories.ts +192 -0
- package/src/stories/Radio.stories.ts +81 -0
- package/src/stories/Section.stories.ts +244 -0
- package/src/stories/SelectBox.stories.ts +377 -0
- package/src/stories/SkeletonLoader.stories.ts +170 -0
- package/src/stories/Slider.stories.ts +79 -0
- package/src/stories/SnsLink.stories.ts +259 -0
- package/src/stories/SoldStacker.stories.ts +68 -0
- package/src/stories/SpinButton.stories.ts +134 -0
- package/src/stories/Spinner.stories.ts +58 -0
- package/src/stories/Stack.stories.ts +104 -0
- package/src/stories/Switch.stories.ts +68 -0
- package/src/stories/Tab.stories.ts +52 -0
- package/src/stories/TabPanels.stories.ts +67 -0
- package/src/stories/Tabs.stories.ts +68 -0
- package/src/stories/Text.stories.ts +69 -0
- package/src/stories/TextArea.stories.ts +78 -0
- package/src/stories/TextField.stories.ts +97 -0
- package/src/stories/ToolChip.stories.ts +125 -0
- package/dist/components/elements/SkeltonLoader.vue.d.ts +0 -7
- package/dist/components/elements/SkeltonLoader.vue.d.ts.map +0 -1
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/vue3'
|
|
2
|
+
import Tab, { type TabProps } from '@/components/interactive/Tab.vue'
|
|
3
|
+
|
|
4
|
+
const meta: Meta<typeof Tab> = {
|
|
5
|
+
title: 'Interactive/Tab',
|
|
6
|
+
component: Tab,
|
|
7
|
+
tags: ['autodocs'],
|
|
8
|
+
parameters: {
|
|
9
|
+
docs: {
|
|
10
|
+
description: {
|
|
11
|
+
component: 'Tabコンポーネント',
|
|
12
|
+
},
|
|
13
|
+
},
|
|
14
|
+
},
|
|
15
|
+
argTypes: {
|
|
16
|
+
active: {
|
|
17
|
+
control: 'boolean',
|
|
18
|
+
},
|
|
19
|
+
},
|
|
20
|
+
args: {
|
|
21
|
+
active: false,
|
|
22
|
+
},
|
|
23
|
+
render: (args) => ({
|
|
24
|
+
components: { 'rn-tab': Tab },
|
|
25
|
+
setup() {
|
|
26
|
+
return { args }
|
|
27
|
+
},
|
|
28
|
+
template: /* html */ `
|
|
29
|
+
<div class='sb-canvas'>
|
|
30
|
+
<rn-tab
|
|
31
|
+
:active=args.active
|
|
32
|
+
>
|
|
33
|
+
{{ args.slotText }}
|
|
34
|
+
</rn-tab>
|
|
35
|
+
</div>
|
|
36
|
+
`,
|
|
37
|
+
}),
|
|
38
|
+
}
|
|
39
|
+
export default meta
|
|
40
|
+
|
|
41
|
+
type StoryArgs = TabProps & { slotText: string }
|
|
42
|
+
type Story = StoryObj<StoryArgs>
|
|
43
|
+
type OverridesStory = Omit<Story, 'argTypes'> & {
|
|
44
|
+
argTypes?: Record<string, TabProps>
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
export const 基本: OverridesStory = {
|
|
48
|
+
args: {
|
|
49
|
+
slotText: 'tabText',
|
|
50
|
+
},
|
|
51
|
+
argTypes: {},
|
|
52
|
+
}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import { ref } from 'vue'
|
|
2
|
+
import type { Meta, StoryObj } from '@storybook/vue3'
|
|
3
|
+
import TabPanels, {
|
|
4
|
+
type TabPanelsProps,
|
|
5
|
+
} from '@/components/interactive/TabPanels.vue'
|
|
6
|
+
|
|
7
|
+
const meta: Meta<typeof TabPanels> = {
|
|
8
|
+
title: 'Interactive/TabPanels',
|
|
9
|
+
component: TabPanels,
|
|
10
|
+
tags: ['autodocs'],
|
|
11
|
+
parameters: {
|
|
12
|
+
docs: {
|
|
13
|
+
description: {
|
|
14
|
+
component: 'TabPanelsコンポーネント',
|
|
15
|
+
},
|
|
16
|
+
},
|
|
17
|
+
},
|
|
18
|
+
argTypes: {
|
|
19
|
+
modelValue: {
|
|
20
|
+
control: 'number',
|
|
21
|
+
},
|
|
22
|
+
},
|
|
23
|
+
args: {
|
|
24
|
+
modelValue: 1,
|
|
25
|
+
},
|
|
26
|
+
}
|
|
27
|
+
export default meta
|
|
28
|
+
|
|
29
|
+
type StoryArgs = TabPanelsProps
|
|
30
|
+
type Story = StoryObj<StoryArgs>
|
|
31
|
+
type OverridesStory = Omit<Story, 'argTypes'> & {
|
|
32
|
+
argTypes?: Record<string, TabPanelsProps>
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
export const 基本: OverridesStory = {
|
|
36
|
+
argTypes: {},
|
|
37
|
+
args: {},
|
|
38
|
+
render: (args) => ({
|
|
39
|
+
components: {
|
|
40
|
+
'rn-tab-panels': TabPanels,
|
|
41
|
+
},
|
|
42
|
+
setup() {
|
|
43
|
+
const current = ref(0)
|
|
44
|
+
|
|
45
|
+
const updateTabIndex = (num: number) => {
|
|
46
|
+
current.value = num
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
return { args, current, updateTabIndex }
|
|
50
|
+
},
|
|
51
|
+
template: /* html */ `
|
|
52
|
+
<div class='sb-canvas'>
|
|
53
|
+
<rn-tab-panels
|
|
54
|
+
:modelValue=current
|
|
55
|
+
@on-change-index="updateTabIndex($event)"
|
|
56
|
+
>
|
|
57
|
+
<template v-for="(_value, index) in new Array(10)" :key="index">
|
|
58
|
+
<span style="min-width: 300px; height: 100px;">
|
|
59
|
+
{{ index }}
|
|
60
|
+
</span>
|
|
61
|
+
</template>
|
|
62
|
+
</rn-tab-panels>
|
|
63
|
+
表示中:{{ current }}番目のコンテンツ
|
|
64
|
+
</div>
|
|
65
|
+
`,
|
|
66
|
+
}),
|
|
67
|
+
}
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import { ref } from 'vue'
|
|
2
|
+
import type { Meta, StoryObj } from '@storybook/vue3'
|
|
3
|
+
import Tabs, { type TabsProps } from '@/components/interactive/Tabs.vue'
|
|
4
|
+
import Tab from '@/components/interactive/Tab.vue'
|
|
5
|
+
|
|
6
|
+
const meta: Meta<typeof Tabs> = {
|
|
7
|
+
title: 'Interactive/Tabs',
|
|
8
|
+
component: Tabs,
|
|
9
|
+
tags: ['autodocs'],
|
|
10
|
+
parameters: {
|
|
11
|
+
docs: {
|
|
12
|
+
description: {
|
|
13
|
+
component: 'Tabsコンポーネント',
|
|
14
|
+
},
|
|
15
|
+
},
|
|
16
|
+
},
|
|
17
|
+
argTypes: {
|
|
18
|
+
modelValue: {
|
|
19
|
+
control: 'number',
|
|
20
|
+
},
|
|
21
|
+
isScrollable: {
|
|
22
|
+
control: 'boolean',
|
|
23
|
+
},
|
|
24
|
+
},
|
|
25
|
+
args: {
|
|
26
|
+
modelValue: 1,
|
|
27
|
+
isScrollable: true,
|
|
28
|
+
},
|
|
29
|
+
render: (args) => ({
|
|
30
|
+
components: { 'rn-tabs': Tabs, 'rn-tab': Tab },
|
|
31
|
+
setup() {
|
|
32
|
+
const current = ref(0)
|
|
33
|
+
const handleVisible = (num: number) => {
|
|
34
|
+
current.value = num
|
|
35
|
+
}
|
|
36
|
+
return { args, handleVisible, current }
|
|
37
|
+
},
|
|
38
|
+
template: /* html */ `
|
|
39
|
+
<div class='sb-canvas'>
|
|
40
|
+
<rn-tabs
|
|
41
|
+
:modelValue=current
|
|
42
|
+
:isScrollable=args.isScrollable
|
|
43
|
+
v-slot=slotProps
|
|
44
|
+
>
|
|
45
|
+
<rn-tab
|
|
46
|
+
v-for="(_value, index) in new Array(10)"
|
|
47
|
+
:active="slotProps.currentIndex === index"
|
|
48
|
+
@click=handleVisible(index)
|
|
49
|
+
>
|
|
50
|
+
tab {{ index }}
|
|
51
|
+
</rn-tab>
|
|
52
|
+
</rn-tabs>
|
|
53
|
+
</div>
|
|
54
|
+
`,
|
|
55
|
+
}),
|
|
56
|
+
}
|
|
57
|
+
export default meta
|
|
58
|
+
|
|
59
|
+
type StoryArgs = TabsProps
|
|
60
|
+
type Story = StoryObj<StoryArgs>
|
|
61
|
+
type OverridesStory = Omit<Story, 'argTypes'> & {
|
|
62
|
+
argTypes?: Record<string, TabsProps>
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
export const 基本: OverridesStory = {
|
|
66
|
+
args: {},
|
|
67
|
+
argTypes: {},
|
|
68
|
+
}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/vue3'
|
|
2
|
+
import Text, { TextProps } from '@/components/elements/Text.vue'
|
|
3
|
+
|
|
4
|
+
const meta: Meta<typeof Text> = {
|
|
5
|
+
title: 'Elements/Text',
|
|
6
|
+
component: Text,
|
|
7
|
+
tags: ['autodocs'],
|
|
8
|
+
argTypes: {
|
|
9
|
+
size: {
|
|
10
|
+
control: 'select',
|
|
11
|
+
options: ['caption', 'body', 'subtitle', 'title', 'headline'],
|
|
12
|
+
},
|
|
13
|
+
color: {
|
|
14
|
+
control: 'select',
|
|
15
|
+
options: [
|
|
16
|
+
'primary',
|
|
17
|
+
'secondary',
|
|
18
|
+
'warning',
|
|
19
|
+
'danger',
|
|
20
|
+
'success',
|
|
21
|
+
'info',
|
|
22
|
+
'default',
|
|
23
|
+
'subtle',
|
|
24
|
+
'muted',
|
|
25
|
+
'light',
|
|
26
|
+
],
|
|
27
|
+
},
|
|
28
|
+
weight: {
|
|
29
|
+
control: 'select',
|
|
30
|
+
options: ['normal', 'bold'],
|
|
31
|
+
},
|
|
32
|
+
lineClamp: { control: 'number' },
|
|
33
|
+
},
|
|
34
|
+
args: {
|
|
35
|
+
size: 'body',
|
|
36
|
+
color: 'default',
|
|
37
|
+
weight: 'normal',
|
|
38
|
+
},
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
export default meta
|
|
42
|
+
type StoryArgs = TextProps & { slotText: string }
|
|
43
|
+
type Story = StoryObj<StoryArgs>
|
|
44
|
+
type OverridesStory = Omit<Story, 'argTypes'> & {
|
|
45
|
+
argTypes?: Record<string, any>
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
export const 基本: OverridesStory = {
|
|
49
|
+
args: {
|
|
50
|
+
slotText:
|
|
51
|
+
'気がさですのはよく今をよしますですん。ついに嘉納さんのお話時分それほど附与と出な貧民その周囲みんなか発展でってお戦争ですなたでて、こういうほかは私か人物風俗に聞こえるが、大森さんののを画の私がすでに実安心とさてあなた金力がお落第がすようについご相当がいんなから、けっしていくらでも徴をなるありからいけでのがなるないます',
|
|
52
|
+
},
|
|
53
|
+
argTypes: {
|
|
54
|
+
default: { table: { disable: true } },
|
|
55
|
+
},
|
|
56
|
+
render: (args: StoryArgs) => ({
|
|
57
|
+
components: { 'rn-text': Text },
|
|
58
|
+
setup() {
|
|
59
|
+
return { args }
|
|
60
|
+
},
|
|
61
|
+
template: /* html */ `
|
|
62
|
+
<div class='sb-canvas'>
|
|
63
|
+
<rn-text :size=args.size :color=args.color :weight=args.weight :lineClamp=args.lineClamp>
|
|
64
|
+
{{ args.slotText }}
|
|
65
|
+
</rn-text>
|
|
66
|
+
</div>
|
|
67
|
+
`,
|
|
68
|
+
}),
|
|
69
|
+
}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import { ref } from 'vue'
|
|
2
|
+
import type { Meta, StoryObj } from '@storybook/vue3'
|
|
3
|
+
import TextArea, {
|
|
4
|
+
type TextAreaProps,
|
|
5
|
+
} from '@/components/elements/TextArea.vue'
|
|
6
|
+
|
|
7
|
+
const meta: Meta<typeof TextArea> = {
|
|
8
|
+
title: 'Elements/TextArea',
|
|
9
|
+
component: TextArea,
|
|
10
|
+
tags: ['autodocs'],
|
|
11
|
+
argTypes: {
|
|
12
|
+
label: {
|
|
13
|
+
control: 'text',
|
|
14
|
+
},
|
|
15
|
+
placeholder: {
|
|
16
|
+
control: 'text',
|
|
17
|
+
},
|
|
18
|
+
rows: {
|
|
19
|
+
control: 'number',
|
|
20
|
+
},
|
|
21
|
+
dynamicRows: {
|
|
22
|
+
control: 'boolean',
|
|
23
|
+
},
|
|
24
|
+
disabled: {
|
|
25
|
+
control: 'boolean',
|
|
26
|
+
},
|
|
27
|
+
rules: {
|
|
28
|
+
control: 'text',
|
|
29
|
+
},
|
|
30
|
+
},
|
|
31
|
+
args: {
|
|
32
|
+
label: 'label',
|
|
33
|
+
placeholder: 'メールアドレスを入力してください',
|
|
34
|
+
rows: 4,
|
|
35
|
+
dynamicRows: true,
|
|
36
|
+
disabled: false,
|
|
37
|
+
rules: '',
|
|
38
|
+
},
|
|
39
|
+
render: (args) => ({
|
|
40
|
+
components: { 'rn-text-area': TextArea },
|
|
41
|
+
setup() {
|
|
42
|
+
const myRef = ref()
|
|
43
|
+
const handleUpload = () => {
|
|
44
|
+
console.log(myRef.value)
|
|
45
|
+
}
|
|
46
|
+
return { args, myRef, handleUpload }
|
|
47
|
+
},
|
|
48
|
+
template: /* html */ `
|
|
49
|
+
<div class='sb-canvas'>
|
|
50
|
+
<rn-text-area
|
|
51
|
+
v-model=myRef
|
|
52
|
+
:label=args.label
|
|
53
|
+
:rows=args.rows
|
|
54
|
+
:dynamicRows=args.dynamicRows
|
|
55
|
+
:disabled=args.disabled
|
|
56
|
+
:rules=args.rules
|
|
57
|
+
:placeholder=args.placeholder
|
|
58
|
+
@update:modelValue=handleUpload
|
|
59
|
+
>
|
|
60
|
+
</rn-text-area>
|
|
61
|
+
</div>
|
|
62
|
+
`,
|
|
63
|
+
}),
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
export default meta
|
|
67
|
+
type StoryArgs = TextAreaProps
|
|
68
|
+
type Story = StoryObj<StoryArgs>
|
|
69
|
+
type OverridesStory = Omit<Story, 'argTypes'> & {
|
|
70
|
+
argTypes?: Record<string, any>
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
export const 基本: OverridesStory = {
|
|
74
|
+
args: {},
|
|
75
|
+
argTypes: {
|
|
76
|
+
default: { table: { disable: true } },
|
|
77
|
+
},
|
|
78
|
+
}
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
import { ref } from 'vue'
|
|
2
|
+
import type { Meta, StoryObj } from '@storybook/vue3'
|
|
3
|
+
import TextField, {
|
|
4
|
+
type TextFieldProps,
|
|
5
|
+
} from '@/components/elements/TextField.vue'
|
|
6
|
+
|
|
7
|
+
const meta: Meta<typeof TextField> = {
|
|
8
|
+
title: 'Elements/TextField',
|
|
9
|
+
component: TextField,
|
|
10
|
+
tags: ['autodocs'],
|
|
11
|
+
argTypes: {
|
|
12
|
+
label: {
|
|
13
|
+
control: 'text',
|
|
14
|
+
},
|
|
15
|
+
modelValue: {
|
|
16
|
+
control: 'text',
|
|
17
|
+
},
|
|
18
|
+
disabled: {
|
|
19
|
+
control: 'boolean',
|
|
20
|
+
},
|
|
21
|
+
rules: {
|
|
22
|
+
control: 'text',
|
|
23
|
+
},
|
|
24
|
+
},
|
|
25
|
+
args: {
|
|
26
|
+
label: 'label',
|
|
27
|
+
modelValue: 'value',
|
|
28
|
+
disabled: false,
|
|
29
|
+
rules: '',
|
|
30
|
+
},
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
export default meta
|
|
34
|
+
type StoryArgs = TextFieldProps
|
|
35
|
+
type Story = StoryObj<StoryArgs>
|
|
36
|
+
type OverridesStory = Omit<Story, 'argTypes'> & {
|
|
37
|
+
argTypes?: Record<string, any>
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
export const 基本: OverridesStory = {
|
|
41
|
+
args: {},
|
|
42
|
+
argTypes: {
|
|
43
|
+
default: { table: { disable: true } },
|
|
44
|
+
},
|
|
45
|
+
render: (args: StoryArgs) => ({
|
|
46
|
+
components: { 'rn-text-field': TextField },
|
|
47
|
+
setup() {
|
|
48
|
+
const myRef = ref()
|
|
49
|
+
const handleUpload = () => {
|
|
50
|
+
console.log(myRef.value)
|
|
51
|
+
}
|
|
52
|
+
return { args, myRef, handleUpload }
|
|
53
|
+
},
|
|
54
|
+
template: /* html */ `
|
|
55
|
+
<div class='sb-canvas'>
|
|
56
|
+
<rn-text-field
|
|
57
|
+
v-model=myRef
|
|
58
|
+
:label=args.label
|
|
59
|
+
:disabled=args.disabled
|
|
60
|
+
:rules=args.rules
|
|
61
|
+
@update:modelValue=handleUpload
|
|
62
|
+
>
|
|
63
|
+
</rn-text-field>
|
|
64
|
+
</div>
|
|
65
|
+
`,
|
|
66
|
+
}),
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
export const 応用: OverridesStory = {
|
|
70
|
+
args: {},
|
|
71
|
+
argTypes: {
|
|
72
|
+
default: { table: { disable: true } },
|
|
73
|
+
},
|
|
74
|
+
render: (args: StoryArgs) => ({
|
|
75
|
+
components: { 'rn-text-field': TextField },
|
|
76
|
+
setup() {
|
|
77
|
+
return { args }
|
|
78
|
+
},
|
|
79
|
+
template: /* html */ `
|
|
80
|
+
<div class='sb-canvas'>
|
|
81
|
+
<rn-text-field
|
|
82
|
+
:label=args.label
|
|
83
|
+
:modelValue=args.modelValue
|
|
84
|
+
:disabled=args.disabled
|
|
85
|
+
:rules=args.rules
|
|
86
|
+
>
|
|
87
|
+
<template #prepend>
|
|
88
|
+
prepend
|
|
89
|
+
</template>
|
|
90
|
+
<template #append>
|
|
91
|
+
append
|
|
92
|
+
</template>
|
|
93
|
+
</rn-text-field>
|
|
94
|
+
</div>
|
|
95
|
+
`,
|
|
96
|
+
}),
|
|
97
|
+
}
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/vue3'
|
|
2
|
+
import ToolChip, {
|
|
3
|
+
type ToolChipProps,
|
|
4
|
+
} from '@/components/elements/ToolChip.vue'
|
|
5
|
+
import { StatusColorOptions } from '@/constants'
|
|
6
|
+
import { StatusColor } from '@/types'
|
|
7
|
+
|
|
8
|
+
const meta: Meta<typeof ToolChip> = {
|
|
9
|
+
title: 'Elements/ToolChip',
|
|
10
|
+
component: ToolChip,
|
|
11
|
+
tags: ['autodocs'],
|
|
12
|
+
argTypes: {
|
|
13
|
+
placement: {
|
|
14
|
+
control: 'select',
|
|
15
|
+
options: [
|
|
16
|
+
'auto',
|
|
17
|
+
'auto-start',
|
|
18
|
+
'auto-end',
|
|
19
|
+
'top',
|
|
20
|
+
'top-start',
|
|
21
|
+
'top-end',
|
|
22
|
+
'right',
|
|
23
|
+
'right-start',
|
|
24
|
+
'right-end',
|
|
25
|
+
'bottom',
|
|
26
|
+
'bottom-start',
|
|
27
|
+
'bottom-end',
|
|
28
|
+
'left',
|
|
29
|
+
'left-start',
|
|
30
|
+
'left-end',
|
|
31
|
+
],
|
|
32
|
+
},
|
|
33
|
+
autoShow: {
|
|
34
|
+
control: 'boolean',
|
|
35
|
+
},
|
|
36
|
+
color: {
|
|
37
|
+
control: 'select',
|
|
38
|
+
options: Object.keys(StatusColorOptions) as StatusColor[],
|
|
39
|
+
},
|
|
40
|
+
message: {
|
|
41
|
+
control: 'text',
|
|
42
|
+
},
|
|
43
|
+
hasDone: {
|
|
44
|
+
control: 'boolean',
|
|
45
|
+
},
|
|
46
|
+
displayOnceId: {
|
|
47
|
+
control: 'text',
|
|
48
|
+
},
|
|
49
|
+
},
|
|
50
|
+
args: {
|
|
51
|
+
placement: 'bottom',
|
|
52
|
+
autoShow: false,
|
|
53
|
+
color: 'default',
|
|
54
|
+
message: 'message',
|
|
55
|
+
hasDone: false,
|
|
56
|
+
},
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
export default meta
|
|
60
|
+
type StoryArgs = ToolChipProps & { slotText: string }
|
|
61
|
+
type Story = StoryObj<StoryArgs>
|
|
62
|
+
type OverridesStory = Omit<Story, 'argTypes'> & {
|
|
63
|
+
argTypes?: Record<string, any>
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
export const 基本: OverridesStory = {
|
|
67
|
+
args: {
|
|
68
|
+
slotText: 'ToolChip',
|
|
69
|
+
},
|
|
70
|
+
argTypes: {
|
|
71
|
+
default: { table: { disable: true } },
|
|
72
|
+
},
|
|
73
|
+
render: (args: StoryArgs) => ({
|
|
74
|
+
components: { 'rn-tool-chip': ToolChip },
|
|
75
|
+
setup() {
|
|
76
|
+
return { args }
|
|
77
|
+
},
|
|
78
|
+
template: /* html */ `
|
|
79
|
+
<div class='sb-canvas'>
|
|
80
|
+
<rn-tool-chip
|
|
81
|
+
:placement=args.placement
|
|
82
|
+
:autoShow=args.autoShow
|
|
83
|
+
:color=args.color
|
|
84
|
+
:message=args.message
|
|
85
|
+
:hasDone=args.hasDone
|
|
86
|
+
:displayOnceId=args.displayOnceId
|
|
87
|
+
>
|
|
88
|
+
{{ args.slotText }}
|
|
89
|
+
</rn-tool-chip>
|
|
90
|
+
</div>
|
|
91
|
+
`,
|
|
92
|
+
}),
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
export const 応用1: OverridesStory = {
|
|
96
|
+
args: {
|
|
97
|
+
slotText: 'ToolChip',
|
|
98
|
+
autoShow: true,
|
|
99
|
+
displayOnceId: '1',
|
|
100
|
+
hasDone: true,
|
|
101
|
+
},
|
|
102
|
+
argTypes: {
|
|
103
|
+
default: { table: { disable: true } },
|
|
104
|
+
},
|
|
105
|
+
render: (args: StoryArgs) => ({
|
|
106
|
+
components: { 'rn-tool-chip': ToolChip },
|
|
107
|
+
setup() {
|
|
108
|
+
return { args }
|
|
109
|
+
},
|
|
110
|
+
template: /* html */ `
|
|
111
|
+
<div class='sb-canvas'>
|
|
112
|
+
<rn-tool-chip
|
|
113
|
+
:placement=args.placement
|
|
114
|
+
:autoShow=args.autoShow
|
|
115
|
+
:color=args.color
|
|
116
|
+
:message=args.message
|
|
117
|
+
:hasDone=args.hasDone
|
|
118
|
+
:displayOnceId=args.displayOnceId
|
|
119
|
+
>
|
|
120
|
+
{{ args.slotText }}
|
|
121
|
+
</rn-tool-chip>
|
|
122
|
+
</div>
|
|
123
|
+
`,
|
|
124
|
+
}),
|
|
125
|
+
}
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
export type SkeltonLoaderProps = {
|
|
3
|
-
type: 'articleThumbnail';
|
|
4
|
-
};
|
|
5
|
-
declare const _default: import('vue').DefineComponent<{}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
6
|
-
export default _default;
|
|
7
|
-
//# sourceMappingURL=SkeltonLoader.vue.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"SkeltonLoader.vue.d.ts","sourceRoot":"","sources":["../../../src/components/elements/SkeltonLoader.vue"],"names":[],"mappings":"AAEA,OAAO,0BAA0B,CAAA;AAIjC,MAAM,MAAM,kBAAkB,GAAG;IAC/B,IAAI,EAAE,kBAAkB,CAAA;CACzB,CAAA;;AA4ID,wBAKG"}
|