@reni-corp/reni-2c-ui 0.3.291 → 0.4.1
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 +131 -0
- package/dist/__tests__/helpers/assert-contract.d.ts +9 -0
- package/dist/__tests__/helpers/assert-contract.d.ts.map +1 -0
- package/dist/__tests__/helpers/contract-helpers.d.ts +45 -0
- package/dist/__tests__/helpers/contract-helpers.d.ts.map +1 -0
- package/dist/__tests__/setup.d.ts +1 -0
- package/dist/__tests__/setup.d.ts.map +1 -0
- package/dist/components/elements/Alert.vue.d.ts +14 -36
- package/dist/components/elements/Alert.vue.d.ts.map +1 -1
- package/dist/components/elements/Button.vue.d.ts +13 -41
- package/dist/components/elements/Button.vue.d.ts.map +1 -1
- package/dist/components/elements/CheckBox.vue.d.ts +11 -60
- package/dist/components/elements/CheckBox.vue.d.ts.map +1 -1
- package/dist/components/elements/ComboBox.vue.d.ts +34 -116
- package/dist/components/elements/ComboBox.vue.d.ts.map +1 -1
- package/dist/components/elements/DescriptionList.vue.d.ts +12 -27
- package/dist/components/elements/DescriptionList.vue.d.ts.map +1 -1
- package/dist/components/elements/Divider.vue.d.ts +3 -27
- package/dist/components/elements/Divider.vue.d.ts.map +1 -1
- package/dist/components/elements/Html.vue.d.ts +2 -32
- package/dist/components/elements/Html.vue.d.ts.map +1 -1
- package/dist/components/elements/Icon.vue.d.ts +4 -28
- package/dist/components/elements/Icon.vue.d.ts.map +1 -1
- package/dist/components/elements/Image.vue.d.ts +19 -43
- package/dist/components/elements/Image.vue.d.ts.map +1 -1
- package/dist/components/elements/Label.vue.d.ts +13 -33
- package/dist/components/elements/Label.vue.d.ts.map +1 -1
- package/dist/components/elements/PasswordField.vue.d.ts +13 -151
- package/dist/components/elements/PasswordField.vue.d.ts.map +1 -1
- package/dist/components/elements/Progress.vue.d.ts +3 -31
- package/dist/components/elements/Progress.vue.d.ts.map +1 -1
- package/dist/components/elements/RadioButton.vue.d.ts +17 -28
- package/dist/components/elements/RadioButton.vue.d.ts.map +1 -1
- package/dist/components/elements/RadioButtonGroup.vue.d.ts +26 -75
- package/dist/components/elements/RadioButtonGroup.vue.d.ts.map +1 -1
- package/dist/components/elements/SelectBox.vue.d.ts +30 -121
- package/dist/components/elements/SelectBox.vue.d.ts.map +1 -1
- package/dist/components/elements/SkeletonLoader.vue.d.ts +2 -24
- package/dist/components/elements/SkeletonLoader.vue.d.ts.map +1 -1
- package/dist/components/elements/SpinButton.vue.d.ts +23 -52
- package/dist/components/elements/SpinButton.vue.d.ts.map +1 -1
- package/dist/components/elements/Spinner.vue.d.ts +3 -27
- package/dist/components/elements/Spinner.vue.d.ts.map +1 -1
- package/dist/components/elements/Text.vue.d.ts +12 -34
- package/dist/components/elements/Text.vue.d.ts.map +1 -1
- package/dist/components/elements/TextField.vue.d.ts +23 -146
- package/dist/components/elements/TextField.vue.d.ts.map +1 -1
- package/dist/components/elements/ToolChip.vue.d.ts +11 -33
- package/dist/components/elements/ToolChip.vue.d.ts.map +1 -1
- package/dist/components/features/AnnounceBar.vue.d.ts +11 -29
- package/dist/components/features/AnnounceBar.vue.d.ts.map +1 -1
- package/dist/components/features/AnnounceBarCollection.vue.d.ts +10 -34
- package/dist/components/features/AnnounceBarCollection.vue.d.ts.map +1 -1
- package/dist/components/features/Banner.vue.d.ts +22 -0
- package/dist/components/features/Banner.vue.d.ts.map +1 -0
- package/dist/components/features/BrandLogo.vue.d.ts +2 -24
- package/dist/components/features/BrandLogo.vue.d.ts.map +1 -1
- package/dist/components/features/CategoryBanner.vue.d.ts +3 -30
- package/dist/components/features/CategoryBanner.vue.d.ts.map +1 -1
- package/dist/components/features/FloatingBanner.vue.d.ts +3 -21
- package/dist/components/features/FloatingBanner.vue.d.ts.map +1 -1
- package/dist/components/features/Hero.vue.d.ts +32 -52
- package/dist/components/features/Hero.vue.d.ts.map +1 -1
- package/dist/components/features/ImageGrid.vue.d.ts +3 -30
- package/dist/components/features/ImageGrid.vue.d.ts.map +1 -1
- package/dist/components/features/LinkList.vue.d.ts +3 -28
- package/dist/components/features/LinkList.vue.d.ts.map +1 -1
- package/dist/components/features/Marquee.vue.d.ts +19 -49
- package/dist/components/features/Marquee.vue.d.ts.map +1 -1
- package/dist/components/features/MediaContent.vue.d.ts +14 -36
- package/dist/components/features/MediaContent.vue.d.ts.map +1 -1
- package/dist/components/features/ProductLabels.vue.d.ts +1 -19
- package/dist/components/features/ProductLabels.vue.d.ts.map +1 -1
- package/dist/components/features/ProductList.vue.d.ts +63 -88
- package/dist/components/features/ProductList.vue.d.ts.map +1 -1
- package/dist/components/features/ProductListItem.vue.d.ts +7 -35
- package/dist/components/features/ProductListItem.vue.d.ts.map +1 -1
- package/dist/components/features/ProductPurchase.vue.d.ts +12 -43
- package/dist/components/features/ProductPurchase.vue.d.ts.map +1 -1
- package/dist/components/features/Schedule.vue.d.ts +11 -29
- package/dist/components/features/Schedule.vue.d.ts.map +1 -1
- package/dist/components/features/ScheduleDateItem.vue.d.ts +2 -26
- package/dist/components/features/ScheduleDateItem.vue.d.ts.map +1 -1
- package/dist/components/features/ScheduleDelivery.vue.d.ts +10 -26
- package/dist/components/features/ScheduleDelivery.vue.d.ts.map +1 -1
- package/dist/components/features/ScheduleDeliveryItem.vue.d.ts +2 -24
- package/dist/components/features/ScheduleDeliveryItem.vue.d.ts.map +1 -1
- package/dist/components/features/SchedulePeriod.vue.d.ts +2 -26
- package/dist/components/features/SchedulePeriod.vue.d.ts.map +1 -1
- package/dist/components/features/SchedulePickup.vue.d.ts +10 -26
- package/dist/components/features/SchedulePickup.vue.d.ts.map +1 -1
- package/dist/components/features/SchedulePickupItem.vue.d.ts +2 -24
- package/dist/components/features/SchedulePickupItem.vue.d.ts.map +1 -1
- package/dist/components/features/Schedules.vue.d.ts +10 -22
- package/dist/components/features/Schedules.vue.d.ts.map +1 -1
- package/dist/components/features/SnsLink.vue.d.ts +3 -29
- package/dist/components/features/SnsLink.vue.d.ts.map +1 -1
- package/dist/components/foundation/AppBar.vue.d.ts +15 -40
- package/dist/components/foundation/AppBar.vue.d.ts.map +1 -1
- package/dist/components/foundation/AppBody.vue.d.ts +9 -4
- package/dist/components/foundation/AppBody.vue.d.ts.map +1 -1
- package/dist/components/foundation/AppFooter.vue.d.ts +13 -35
- package/dist/components/foundation/AppFooter.vue.d.ts.map +1 -1
- package/dist/components/foundation/AppFrame.vue.d.ts +10 -5
- package/dist/components/foundation/AppFrame.vue.d.ts.map +1 -1
- package/dist/components/interactive/Dialog.vue.d.ts +18 -40
- package/dist/components/interactive/Dialog.vue.d.ts.map +1 -1
- package/dist/components/interactive/Disclosure.vue.d.ts +22 -37
- package/dist/components/interactive/Disclosure.vue.d.ts.map +1 -1
- package/dist/components/interactive/DropDown.vue.d.ts +20 -34
- package/dist/components/interactive/DropDown.vue.d.ts.map +1 -1
- package/dist/components/interactive/Gallery.vue.d.ts +2 -34
- package/dist/components/interactive/Gallery.vue.d.ts.map +1 -1
- package/dist/components/interactive/Lightbox.vue.d.ts +32 -0
- package/dist/components/interactive/Lightbox.vue.d.ts.map +1 -0
- package/dist/components/interactive/Modal.vue.d.ts +15 -33
- package/dist/components/interactive/Modal.vue.d.ts.map +1 -1
- package/dist/components/interactive/Notification.vue.d.ts +5 -35
- package/dist/components/interactive/Notification.vue.d.ts.map +1 -1
- package/dist/components/interactive/Slider.vue.d.ts +32 -28
- package/dist/components/interactive/Slider.vue.d.ts.map +1 -1
- package/dist/components/interactive/Tab.vue.d.ts +17 -25
- package/dist/components/interactive/Tab.vue.d.ts.map +1 -1
- package/dist/components/interactive/TabGroup.vue.d.ts +25 -0
- package/dist/components/interactive/TabGroup.vue.d.ts.map +1 -0
- package/dist/components/interactive/TabPanel.vue.d.ts +9 -3
- package/dist/components/interactive/TabPanel.vue.d.ts.map +1 -1
- package/dist/components/interactive/TabPanels.vue.d.ts +27 -32
- package/dist/components/interactive/TabPanels.vue.d.ts.map +1 -1
- package/dist/components/interactive/Tabs.vue.d.ts +31 -31
- package/dist/components/interactive/Tabs.vue.d.ts.map +1 -1
- package/dist/components/layouts/Card.vue.d.ts +12 -30
- package/dist/components/layouts/Card.vue.d.ts.map +1 -1
- package/dist/components/layouts/Grid.vue.d.ts +11 -32
- package/dist/components/layouts/Grid.vue.d.ts.map +1 -1
- package/dist/components/layouts/List.vue.d.ts +28 -42
- package/dist/components/layouts/List.vue.d.ts.map +1 -1
- package/dist/components/layouts/Page.vue.d.ts +33 -62
- package/dist/components/layouts/Page.vue.d.ts.map +1 -1
- package/dist/components/layouts/Section.vue.d.ts +22 -41
- package/dist/components/layouts/Section.vue.d.ts.map +1 -1
- package/dist/components/layouts/Stack.vue.d.ts +12 -40
- package/dist/components/layouts/Stack.vue.d.ts.map +1 -1
- package/dist/components/navigation/BottomBar.vue.d.ts +10 -26
- package/dist/components/navigation/BottomBar.vue.d.ts.map +1 -1
- package/dist/components/navigation/Drawer.vue.d.ts +14 -32
- package/dist/components/navigation/Drawer.vue.d.ts.map +1 -1
- package/dist/components/renderless/DataProvider.vue.d.ts +19 -42
- package/dist/components/renderless/DataProvider.vue.d.ts.map +1 -1
- package/dist/components/renderless/Form.vue.d.ts +22 -43
- package/dist/components/renderless/Form.vue.d.ts.map +1 -1
- package/dist/components/renderless/OptionGroupSwitchController.vue.d.ts +20 -43
- package/dist/components/renderless/OptionGroupSwitchController.vue.d.ts.map +1 -1
- package/dist/composable/useAppNotifications.d.ts +0 -1
- package/dist/composable/useToolChip.d.ts +0 -1
- package/dist/composables.d.ts +0 -1
- package/dist/composables.es.js +5 -6
- package/dist/contexts/tabGroup.d.ts +17 -0
- package/dist/contexts/tabGroup.d.ts.map +1 -0
- package/dist/directives/auto-scale.d.ts +0 -1
- package/dist/directives/glitch.d.ts +0 -1
- package/dist/{index-a725a791.js → index-D7ldGb8i.js} +18 -30
- package/dist/index.d.ts +8 -11
- package/dist/index.d.ts.map +1 -1
- package/dist/index.es.js +6795 -6735
- package/dist/script.es.js +8571 -8506
- package/dist/script.umd.js +28 -28
- package/dist/style.css +1 -1
- package/dist/types.d.ts +0 -1
- package/dist/{composables-93778bb4.js → useAppDialogGuidance-Bs1h3YmP.js} +1060 -1044
- package/dist/utils.d.ts +46 -1
- package/dist/utils.d.ts.map +1 -1
- package/dist/validation.d.ts +0 -1
- package/dist/valueObjects/CurrencyValue.d.ts +0 -1
- package/dist/valueObjects/NumberValue.d.ts +0 -1
- package/dist/{valueObjects-e0ea7f1b.js → valueObjects-CvF0zaqR.js} +1 -1
- package/dist/valueObjects.es.js +1 -1
- package/package.json +29 -28
- package/src/stories/Alert.stories.ts +1 -1
- package/src/stories/AnnounceBar.stories.ts +1 -1
- package/src/stories/AnnounceBarCollection.stories.ts +135 -0
- package/src/stories/AppBar.stories.ts +6 -2
- package/src/stories/AppFooter.stories.ts +1 -1
- package/src/stories/AppFrame.stories.ts +1 -1
- package/src/stories/AppLayout.stories.ts +5 -16
- package/src/stories/Banner.stories.ts +235 -0
- package/src/stories/Button.stories.ts +1 -1
- package/src/stories/Card.stories.ts +1 -1
- package/src/stories/CheckBox.stories.ts +84 -22
- package/src/stories/ComboBox.stories.ts +62 -2
- package/src/stories/Dialog.stories.ts +1 -1
- package/src/stories/Disclosure.stories.ts +1 -1
- package/src/stories/Divider.stories.ts +1 -1
- package/src/stories/Drawer.stories.ts +1 -1
- package/src/stories/DropDown.stories.ts +1 -1
- package/src/stories/FloatingBanner.stories.ts +1 -1
- package/src/stories/Form.stories.ts +96 -1
- package/src/stories/Gallery.stories.ts +1 -1
- package/src/stories/Grid.stories.ts +1 -1
- package/src/stories/Hero.stories.ts +175 -26
- package/src/stories/Html.stories.ts +69 -1
- package/src/stories/Icon.stories.ts +1 -1
- package/src/stories/Image.stories.ts +1 -1
- package/src/stories/Label.stories.ts +97 -4
- package/src/stories/Lightbox.stories.ts +231 -0
- package/src/stories/List.stories.ts +62 -15
- package/src/stories/Modal.stories.ts +1 -1
- package/src/stories/Notification.stories.ts +1 -1
- package/src/stories/Page.stories.ts +36 -1
- package/src/stories/PasswordField.stories.ts +1 -1
- package/src/stories/ProductList.stories.ts +65 -3
- package/src/stories/ProductPurchase.stories.ts +2 -2
- package/src/stories/Progress.stories.ts +1 -1
- package/src/stories/Radio.stories.ts +130 -12
- package/src/stories/Section.stories.ts +29 -4
- package/src/stories/SelectBox.stories.ts +56 -1
- package/src/stories/SkeletonLoader.stories.ts +1 -1
- package/src/stories/Slider.stories.ts +365 -7
- package/src/stories/SnsLink.stories.ts +1 -1
- package/src/stories/SpinButton.stories.ts +1 -1
- package/src/stories/Spinner.stories.ts +1 -1
- package/src/stories/Stack.stories.ts +1 -1
- package/src/stories/Switch.stories.ts +1 -1
- package/src/stories/Tab.stories.ts +28 -11
- package/src/stories/TabGroup.stories.ts +290 -0
- package/src/stories/TabPanels.stories.ts +1 -1
- package/src/stories/Tabs.stories.ts +104 -3
- package/src/stories/Text.stories.ts +24 -1
- package/src/stories/TextArea.stories.ts +78 -1
- package/src/stories/TextField.stories.ts +75 -2
- package/src/stories/ToolChip.stories.ts +1 -1
- package/src/stories/compositions/EventPage.stories.ts +184 -0
- package/src/stories/compositions/FormPage.stories.ts +222 -0
- package/src/stories/compositions/TopPage.stories.ts +164 -0
- package/dist/components/features/CarouselBanner.vue.d.ts +0 -36
- package/dist/components/features/CarouselBanner.vue.d.ts.map +0 -1
- package/dist/components/features/VariationSelector.vue.d.ts +0 -39
- package/dist/components/features/VariationSelector.vue.d.ts.map +0 -1
- package/src/stories/Carousel.stories.ts +0 -62
- package/src/stories/CarouselBanner.stories.ts +0 -103
- package/src/stories/ProductLabels.stories.ts +0 -65
- package/src/stories/SoldStacker.stories.ts +0 -68
|
@@ -0,0 +1,231 @@
|
|
|
1
|
+
import { ref } from 'vue'
|
|
2
|
+
import type { Meta, StoryObj } from '@storybook/vue3-vite'
|
|
3
|
+
import Lightbox, {
|
|
4
|
+
type LightboxProps,
|
|
5
|
+
} from '@/components/interactive/Lightbox.vue'
|
|
6
|
+
import Button from '@/components/elements/Button.vue'
|
|
7
|
+
import FloatingBanner from '@/components/features/FloatingBanner.vue'
|
|
8
|
+
|
|
9
|
+
const meta: Meta<typeof Lightbox> = {
|
|
10
|
+
title: 'Interactive/Lightbox',
|
|
11
|
+
component: Lightbox,
|
|
12
|
+
tags: ['autodocs'],
|
|
13
|
+
parameters: {
|
|
14
|
+
docs: {
|
|
15
|
+
description: {
|
|
16
|
+
component:
|
|
17
|
+
'Lightboxコンポーネントです。画像やコンテンツをオーバーレイで拡大表示するためのコンポーネント。activator slotでトリガー要素を指定するか、v-model:visibleで外部から制御できます。',
|
|
18
|
+
},
|
|
19
|
+
},
|
|
20
|
+
},
|
|
21
|
+
argTypes: {
|
|
22
|
+
visible: {
|
|
23
|
+
control: 'boolean',
|
|
24
|
+
},
|
|
25
|
+
},
|
|
26
|
+
args: {
|
|
27
|
+
visible: false,
|
|
28
|
+
},
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
export default meta
|
|
32
|
+
type StoryArgs = LightboxProps
|
|
33
|
+
type Story = StoryObj<StoryArgs>
|
|
34
|
+
type OverridesStory = Omit<Story, 'argTypes'> & {
|
|
35
|
+
argTypes?: Record<string, any>
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export const 基本: OverridesStory = {
|
|
39
|
+
args: {},
|
|
40
|
+
argTypes: {},
|
|
41
|
+
parameters: {
|
|
42
|
+
docs: {
|
|
43
|
+
description: {
|
|
44
|
+
story: 'activator slotを使用した基本的な使い方。ボタンをクリックすると画像が表示されます。',
|
|
45
|
+
},
|
|
46
|
+
},
|
|
47
|
+
},
|
|
48
|
+
render: (args) => ({
|
|
49
|
+
components: { 'rn-lightbox': Lightbox, 'rn-button': Button },
|
|
50
|
+
setup() {
|
|
51
|
+
return { args }
|
|
52
|
+
},
|
|
53
|
+
template: /* html */ `
|
|
54
|
+
<div class='sb-canvas'>
|
|
55
|
+
<div style='height: 600px; padding: 20px;'>
|
|
56
|
+
<rn-lightbox>
|
|
57
|
+
<template #activator="{ open }">
|
|
58
|
+
<rn-button @click="open">画像を表示</rn-button>
|
|
59
|
+
</template>
|
|
60
|
+
<img
|
|
61
|
+
src="https://placehold.co/600x400/EEE/31343C?text=Sample+Image"
|
|
62
|
+
alt="サンプル画像"
|
|
63
|
+
style="width: 100%; display: block;"
|
|
64
|
+
/>
|
|
65
|
+
</rn-lightbox>
|
|
66
|
+
</div>
|
|
67
|
+
</div>
|
|
68
|
+
`,
|
|
69
|
+
}),
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
export const 縦長画像: OverridesStory = {
|
|
73
|
+
args: {},
|
|
74
|
+
argTypes: {},
|
|
75
|
+
parameters: {
|
|
76
|
+
docs: {
|
|
77
|
+
description: {
|
|
78
|
+
story: '縦に長い画像の場合、コンテンツ領域がスクロール可能になります。',
|
|
79
|
+
},
|
|
80
|
+
},
|
|
81
|
+
},
|
|
82
|
+
render: (args) => ({
|
|
83
|
+
components: { 'rn-lightbox': Lightbox, 'rn-button': Button },
|
|
84
|
+
setup() {
|
|
85
|
+
return { args }
|
|
86
|
+
},
|
|
87
|
+
template: /* html */ `
|
|
88
|
+
<div class='sb-canvas'>
|
|
89
|
+
<div style='height: 600px; padding: 20px;'>
|
|
90
|
+
<rn-lightbox>
|
|
91
|
+
<template #activator="{ open }">
|
|
92
|
+
<rn-button @click="open">サイズ表を見る</rn-button>
|
|
93
|
+
</template>
|
|
94
|
+
<img
|
|
95
|
+
src="https://placehold.co/600x3000/EEE/31343C?text=Size+Chart\\n(Tall+Image)"
|
|
96
|
+
alt="サイズ表"
|
|
97
|
+
style="width: 100%; display: block;"
|
|
98
|
+
/>
|
|
99
|
+
</rn-lightbox>
|
|
100
|
+
</div>
|
|
101
|
+
</div>
|
|
102
|
+
`,
|
|
103
|
+
}),
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
export const 外部制御: OverridesStory = {
|
|
107
|
+
args: {},
|
|
108
|
+
argTypes: {},
|
|
109
|
+
parameters: {
|
|
110
|
+
docs: {
|
|
111
|
+
description: {
|
|
112
|
+
story: 'v-model:visible を使用して外部から表示状態を制御する例。',
|
|
113
|
+
},
|
|
114
|
+
},
|
|
115
|
+
},
|
|
116
|
+
render: (args) => ({
|
|
117
|
+
components: { 'rn-lightbox': Lightbox, 'rn-button': Button },
|
|
118
|
+
setup() {
|
|
119
|
+
const visible = ref(false)
|
|
120
|
+
const handleVisible = () => {
|
|
121
|
+
visible.value = !visible.value
|
|
122
|
+
}
|
|
123
|
+
return { args, visible, handleVisible }
|
|
124
|
+
},
|
|
125
|
+
template: /* html */ `
|
|
126
|
+
<div class='sb-canvas'>
|
|
127
|
+
<div style='height: 600px; padding: 20px;'>
|
|
128
|
+
<rn-button @click="handleVisible">画像を表示(外部制御)</rn-button>
|
|
129
|
+
<rn-lightbox
|
|
130
|
+
:visible="visible"
|
|
131
|
+
@onChangeVisible="handleVisible"
|
|
132
|
+
>
|
|
133
|
+
<img
|
|
134
|
+
src="https://placehold.co/600x400/EEE/31343C?text=External+Control"
|
|
135
|
+
alt="外部制御サンプル"
|
|
136
|
+
style="width: 100%; display: block;"
|
|
137
|
+
/>
|
|
138
|
+
</rn-lightbox>
|
|
139
|
+
</div>
|
|
140
|
+
</div>
|
|
141
|
+
`,
|
|
142
|
+
}),
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
export const FloatingBannerとの組み合わせ: OverridesStory = {
|
|
146
|
+
args: {},
|
|
147
|
+
argTypes: {},
|
|
148
|
+
parameters: {
|
|
149
|
+
docs: {
|
|
150
|
+
description: {
|
|
151
|
+
story: 'FloatingBannerをactivatorとして使用し、クリックでLightboxを開く例。',
|
|
152
|
+
},
|
|
153
|
+
},
|
|
154
|
+
},
|
|
155
|
+
render: (args) => ({
|
|
156
|
+
components: {
|
|
157
|
+
'rn-lightbox': Lightbox,
|
|
158
|
+
'rn-floating-banner': FloatingBanner,
|
|
159
|
+
},
|
|
160
|
+
setup() {
|
|
161
|
+
return { args }
|
|
162
|
+
},
|
|
163
|
+
template: /* html */ `
|
|
164
|
+
<div class='sb-canvas'>
|
|
165
|
+
<div style='height: 600px; padding: 20px;'>
|
|
166
|
+
<p>画面下部のフローティングバナーをクリックすると、Lightboxが開きます。</p>
|
|
167
|
+
<rn-lightbox>
|
|
168
|
+
<template #activator="{ open }">
|
|
169
|
+
<rn-floating-banner
|
|
170
|
+
image-url="https://placehold.co/480x80/E8D5B7/31343C?text=Campaign+Banner"
|
|
171
|
+
@click="open"
|
|
172
|
+
/>
|
|
173
|
+
</template>
|
|
174
|
+
<img
|
|
175
|
+
src="https://placehold.co/600x800/E8D5B7/31343C?text=Campaign+Detail"
|
|
176
|
+
alt="キャンペーン詳細"
|
|
177
|
+
style="width: 100%; display: block;"
|
|
178
|
+
/>
|
|
179
|
+
</rn-lightbox>
|
|
180
|
+
</div>
|
|
181
|
+
</div>
|
|
182
|
+
`,
|
|
183
|
+
}),
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
export const カスタムコンテンツ: OverridesStory = {
|
|
187
|
+
args: {},
|
|
188
|
+
argTypes: {},
|
|
189
|
+
parameters: {
|
|
190
|
+
docs: {
|
|
191
|
+
description: {
|
|
192
|
+
story: '画像以外のHTMLコンテンツも表示できます。',
|
|
193
|
+
},
|
|
194
|
+
},
|
|
195
|
+
},
|
|
196
|
+
render: (args) => ({
|
|
197
|
+
components: { 'rn-lightbox': Lightbox, 'rn-button': Button },
|
|
198
|
+
setup() {
|
|
199
|
+
return { args }
|
|
200
|
+
},
|
|
201
|
+
template: /* html */ `
|
|
202
|
+
<div class='sb-canvas'>
|
|
203
|
+
<div style='height: 600px; padding: 20px;'>
|
|
204
|
+
<rn-lightbox>
|
|
205
|
+
<template #activator="{ open }">
|
|
206
|
+
<rn-button variant="text" @click="open">利用規約を確認</rn-button>
|
|
207
|
+
</template>
|
|
208
|
+
<div style="padding: 24px;">
|
|
209
|
+
<h3 style="margin: 0 0 16px; font-size: 18px; font-weight: bold;">利用規約</h3>
|
|
210
|
+
<p style="margin: 0 0 12px; font-size: 14px; line-height: 1.6;">
|
|
211
|
+
この利用規約(以下「本規約」)は、当サービスの利用条件を定めるものです。
|
|
212
|
+
ユーザーの皆様には、本規約に同意いただいた上で、当サービスをご利用いただきます。
|
|
213
|
+
</p>
|
|
214
|
+
<p style="margin: 0 0 12px; font-size: 14px; line-height: 1.6;">
|
|
215
|
+
第1条(適用)本規約は、ユーザーと当社との間の本サービスの利用に関わる一切の関係に適用されるものとします。
|
|
216
|
+
</p>
|
|
217
|
+
<p style="margin: 0 0 12px; font-size: 14px; line-height: 1.6;">
|
|
218
|
+
第2条(利用登録)登録希望者が当社の定める方法によって利用登録を申請し、
|
|
219
|
+
当社がこれを承認することによって、利用登録が完了するものとします。
|
|
220
|
+
</p>
|
|
221
|
+
<p style="margin: 0; font-size: 14px; line-height: 1.6;">
|
|
222
|
+
第3条(禁止事項)ユーザーは、本サービスの利用にあたり、以下の行為をしてはなりません。
|
|
223
|
+
法令または公序良俗に違反する行為、犯罪行為に関連する行為、その他当社が不適切と判断する行為。
|
|
224
|
+
</p>
|
|
225
|
+
</div>
|
|
226
|
+
</rn-lightbox>
|
|
227
|
+
</div>
|
|
228
|
+
</div>
|
|
229
|
+
`,
|
|
230
|
+
}),
|
|
231
|
+
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/vue3'
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/vue3-vite'
|
|
2
2
|
import List, { type ListProps } from '@/components/layouts/List.vue'
|
|
3
|
+
import Card from '@/components/layouts/Card.vue'
|
|
3
4
|
import { Size } from '@/types'
|
|
4
5
|
import { SizeOptions } from '@/constants'
|
|
5
6
|
import Text from '@/components/elements/Text.vue'
|
|
@@ -49,6 +50,12 @@ const meta: Meta<typeof List> = {
|
|
|
49
50
|
loading: {
|
|
50
51
|
control: 'boolean',
|
|
51
52
|
},
|
|
53
|
+
icon: {
|
|
54
|
+
control: 'text',
|
|
55
|
+
},
|
|
56
|
+
arrow: {
|
|
57
|
+
control: 'text',
|
|
58
|
+
},
|
|
52
59
|
},
|
|
53
60
|
args: {
|
|
54
61
|
items: [
|
|
@@ -73,6 +80,8 @@ const meta: Meta<typeof List> = {
|
|
|
73
80
|
},
|
|
74
81
|
emptyText: 'empty',
|
|
75
82
|
loading: false,
|
|
83
|
+
icon: 'icon',
|
|
84
|
+
arrow: 'withArrow',
|
|
76
85
|
},
|
|
77
86
|
}
|
|
78
87
|
export default meta
|
|
@@ -87,25 +96,63 @@ export const 基本: OverridesStory = {
|
|
|
87
96
|
args: {},
|
|
88
97
|
argTypes: {},
|
|
89
98
|
render: (args) => ({
|
|
90
|
-
components: { 'rn-list': List, 'rn-text': Text },
|
|
99
|
+
components: { 'rn-list': List, 'rn-text': Text, 'rn-card': Card },
|
|
100
|
+
setup() {
|
|
101
|
+
return { args }
|
|
102
|
+
},
|
|
103
|
+
template: /* html */ `
|
|
104
|
+
<div class='sb-canvas'>
|
|
105
|
+
<rn-card title="リスト" :elevation="false">
|
|
106
|
+
<rn-list v-bind="args">
|
|
107
|
+
<template #default="{ item }">
|
|
108
|
+
<rn-text>{{ item.name }}</rn-text>
|
|
109
|
+
</template>
|
|
110
|
+
</rn-list>
|
|
111
|
+
</rn-card>
|
|
112
|
+
</div>
|
|
113
|
+
`,
|
|
114
|
+
}),
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
export const アイコンと矢印: OverridesStory = {
|
|
118
|
+
args: {
|
|
119
|
+
items: [
|
|
120
|
+
{
|
|
121
|
+
name: 'マイページ',
|
|
122
|
+
icon: ['far', 'user'],
|
|
123
|
+
withArrow: true,
|
|
124
|
+
},
|
|
125
|
+
{
|
|
126
|
+
name: 'お気に入り',
|
|
127
|
+
icon: 'check',
|
|
128
|
+
withArrow: true,
|
|
129
|
+
},
|
|
130
|
+
{
|
|
131
|
+
name: '設定',
|
|
132
|
+
icon: ['far', 'pen-to-square'],
|
|
133
|
+
withArrow: true,
|
|
134
|
+
},
|
|
135
|
+
{
|
|
136
|
+
name: 'ショッピングカート',
|
|
137
|
+
icon: ['far', 'cart-shopping'],
|
|
138
|
+
withArrow: false,
|
|
139
|
+
},
|
|
140
|
+
],
|
|
141
|
+
withDivider: true,
|
|
142
|
+
icon: 'icon',
|
|
143
|
+
arrow: 'withArrow',
|
|
144
|
+
},
|
|
145
|
+
argTypes: {},
|
|
146
|
+
render: (args) => ({
|
|
147
|
+
components: { 'rn-list': List, 'rn-card': Card },
|
|
91
148
|
setup() {
|
|
92
149
|
return { args }
|
|
93
150
|
},
|
|
94
151
|
template: /* html */ `
|
|
95
152
|
<div class='sb-canvas'>
|
|
96
|
-
<rn-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
:dense=args.dense
|
|
100
|
-
:gap=args.gap
|
|
101
|
-
:contentInset=args.contentInset
|
|
102
|
-
:emptyText=args.emptyText
|
|
103
|
-
:loading=args.loading
|
|
104
|
-
>
|
|
105
|
-
<template #default="{ item }">
|
|
106
|
-
<rn-text>{{ item.name }}</rn-text>
|
|
107
|
-
</template>
|
|
108
|
-
</rn-list>
|
|
153
|
+
<rn-card title="アイコンと矢印" :elevation="false">
|
|
154
|
+
<rn-list v-bind="args" />
|
|
155
|
+
</rn-card>
|
|
109
156
|
</div>
|
|
110
157
|
`,
|
|
111
158
|
}),
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/vue3'
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/vue3-vite'
|
|
2
2
|
import Modal, { ModalProps } from '@/components/interactive/Modal.vue'
|
|
3
3
|
import Button from '@/components/elements/Button.vue'
|
|
4
4
|
import Icon from '@/components/elements/Icon.vue'
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/vue3'
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/vue3-vite'
|
|
2
2
|
import Page from '@/components/layouts/Page.vue'
|
|
3
3
|
import Card from '@/components/layouts/Card.vue'
|
|
4
4
|
import Stack from '@/components/layouts/Stack.vue'
|
|
@@ -15,6 +15,11 @@ const meta: Meta<typeof Page> = {
|
|
|
15
15
|
control: 'text',
|
|
16
16
|
description: 'ページタイトル',
|
|
17
17
|
},
|
|
18
|
+
titleFont: {
|
|
19
|
+
control: 'select',
|
|
20
|
+
options: ['default', 'key', 'mono'],
|
|
21
|
+
description: 'タイトルのフォントファミリー',
|
|
22
|
+
},
|
|
18
23
|
fluid: {
|
|
19
24
|
control: 'boolean',
|
|
20
25
|
description: '最大幅制限を無効にする',
|
|
@@ -47,6 +52,7 @@ const meta: Meta<typeof Page> = {
|
|
|
47
52
|
},
|
|
48
53
|
args: {
|
|
49
54
|
title: 'ページタイトル',
|
|
55
|
+
titleFont: 'default',
|
|
50
56
|
fluid: false,
|
|
51
57
|
pending: false,
|
|
52
58
|
withBack: false,
|
|
@@ -412,3 +418,32 @@ AppBodyのsafearea padding(PC: 40px / SP: 16px)をネガティブマージ
|
|
|
412
418
|
`,
|
|
413
419
|
}),
|
|
414
420
|
}
|
|
421
|
+
|
|
422
|
+
export const タイトルフォント選択: OverridesStory = {
|
|
423
|
+
args: {
|
|
424
|
+
title: 'ブランドフォントのページタイトル',
|
|
425
|
+
titleFont: 'key',
|
|
426
|
+
},
|
|
427
|
+
render: (args: StoryArgs) => ({
|
|
428
|
+
components: { 'rn-page': Page, 'rn-card': Card, 'rn-text': Text },
|
|
429
|
+
setup() {
|
|
430
|
+
return { args }
|
|
431
|
+
},
|
|
432
|
+
template: /* html */ `
|
|
433
|
+
<div class='sb-canvas' style="height: 600px;">
|
|
434
|
+
<rn-page
|
|
435
|
+
:title="args.title"
|
|
436
|
+
:title-font="args.titleFont"
|
|
437
|
+
>
|
|
438
|
+
<template #body>
|
|
439
|
+
<rn-card title="コンテンツ" elevation>
|
|
440
|
+
<rn-text>
|
|
441
|
+
ページタイトルにブランドフォント(key)を適用しています。
|
|
442
|
+
</rn-text>
|
|
443
|
+
</rn-card>
|
|
444
|
+
</template>
|
|
445
|
+
</rn-page>
|
|
446
|
+
</div>
|
|
447
|
+
`,
|
|
448
|
+
}),
|
|
449
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/vue3'
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/vue3-vite'
|
|
2
2
|
import ProductList, {
|
|
3
3
|
type ProductListProps,
|
|
4
4
|
} from '@/components/features/ProductList.vue'
|
|
@@ -28,6 +28,10 @@ const meta: Meta<typeof ProductList> = {
|
|
|
28
28
|
control: 'select',
|
|
29
29
|
options: ['default', 'boxed'],
|
|
30
30
|
},
|
|
31
|
+
variant: {
|
|
32
|
+
control: 'select',
|
|
33
|
+
options: ['flat', 'bordered', 'card'],
|
|
34
|
+
},
|
|
31
35
|
pcRows: { control: 'number' },
|
|
32
36
|
pcColumns: { control: 'number' },
|
|
33
37
|
spRows: { control: 'number' },
|
|
@@ -45,6 +49,7 @@ const meta: Meta<typeof ProductList> = {
|
|
|
45
49
|
paginationType: 'bullets',
|
|
46
50
|
theme: 'light',
|
|
47
51
|
itemType: 'default',
|
|
52
|
+
variant: 'flat',
|
|
48
53
|
pcRows: 2,
|
|
49
54
|
pcColumns: 4,
|
|
50
55
|
spRows: 2,
|
|
@@ -82,9 +87,11 @@ const generateMockProducts = (count: number) => {
|
|
|
82
87
|
'https://assets.official-goods-store.jp/label/KTK007.png',
|
|
83
88
|
]
|
|
84
89
|
} else if (i % 7 === 3) {
|
|
85
|
-
// Soldout
|
|
90
|
+
// Soldout画像ラベル(7個に1個)
|
|
86
91
|
soldoutUrl =
|
|
87
92
|
'https://official-goods-store.jp/yuuri/assets/img/yuuri/soldout.png'
|
|
93
|
+
} else if (i % 7 === 4) {
|
|
94
|
+
// Soldoutテキストラベル(soldout_url なし)
|
|
88
95
|
}
|
|
89
96
|
|
|
90
97
|
if (i % 7 === 1) {
|
|
@@ -116,6 +123,7 @@ const generateMockProducts = (count: number) => {
|
|
|
116
123
|
label_urls: labelUrls,
|
|
117
124
|
label_texts: labelTexts,
|
|
118
125
|
soldout_url: soldoutUrl,
|
|
126
|
+
is_soldout: i % 7 === 3 || i % 7 === 4, // soldout_url ありと なし の2パターン
|
|
119
127
|
is_forced_publish: i % 5 === 0, // 5個に1個は受付期間外
|
|
120
128
|
})
|
|
121
129
|
}
|
|
@@ -667,7 +675,7 @@ export const title2表示制御: Story = {
|
|
|
667
675
|
<span style="color: #666;">現在の設定: {{ showTitle2 ? '表示' : '非表示' }}</span>
|
|
668
676
|
</rn-stack>
|
|
669
677
|
|
|
670
|
-
<rn-product-list
|
|
678
|
+
<rn-product-list
|
|
671
679
|
:data="args.data"
|
|
672
680
|
:display-mode="args.displayMode"
|
|
673
681
|
:show-title2="showTitle2"
|
|
@@ -677,3 +685,57 @@ export const title2表示制御: Story = {
|
|
|
677
685
|
`,
|
|
678
686
|
}),
|
|
679
687
|
}
|
|
688
|
+
|
|
689
|
+
export const バリアント比較: Story = {
|
|
690
|
+
args: {
|
|
691
|
+
displayMode: 'list',
|
|
692
|
+
data: generateMockProducts(8),
|
|
693
|
+
},
|
|
694
|
+
render: (args: StoryArgs) => ({
|
|
695
|
+
components: {
|
|
696
|
+
'rn-product-list': ProductList,
|
|
697
|
+
'rn-stack': Stack,
|
|
698
|
+
},
|
|
699
|
+
setup() {
|
|
700
|
+
return { args }
|
|
701
|
+
},
|
|
702
|
+
template: `
|
|
703
|
+
<div class="sb-canvas" style="padding: 20px;">
|
|
704
|
+
<h2>アイテムバリアント比較</h2>
|
|
705
|
+
<p>各商品アイテム(ProductListItem)のスタイルバリアント3種類を比較できます</p>
|
|
706
|
+
|
|
707
|
+
<rn-stack direction="vertical" gap="xl" style="margin-top: 32px;">
|
|
708
|
+
<!-- Flat -->
|
|
709
|
+
<div>
|
|
710
|
+
<h3>Flat(デフォルト)</h3>
|
|
711
|
+
<p style="color: #666; margin: 8px 0;">背景・ボーダー・影・パディングなし</p>
|
|
712
|
+
<rn-product-list
|
|
713
|
+
v-bind="args"
|
|
714
|
+
variant="flat"
|
|
715
|
+
/>
|
|
716
|
+
</div>
|
|
717
|
+
|
|
718
|
+
<!-- Bordered -->
|
|
719
|
+
<div style="margin-top: 48px;">
|
|
720
|
+
<h3>Bordered</h3>
|
|
721
|
+
<p style="color: #666; margin: 8px 0;">ボーダー + パディング(角丸なし)</p>
|
|
722
|
+
<rn-product-list
|
|
723
|
+
v-bind="args"
|
|
724
|
+
variant="bordered"
|
|
725
|
+
/>
|
|
726
|
+
</div>
|
|
727
|
+
|
|
728
|
+
<!-- Card -->
|
|
729
|
+
<div style="margin-top: 48px;">
|
|
730
|
+
<h3>Card</h3>
|
|
731
|
+
<p style="color: #666; margin: 8px 0;">背景色 + 薄いボーダー + 影 + パディング + 角丸</p>
|
|
732
|
+
<rn-product-list
|
|
733
|
+
v-bind="args"
|
|
734
|
+
variant="card"
|
|
735
|
+
/>
|
|
736
|
+
</div>
|
|
737
|
+
</rn-stack>
|
|
738
|
+
</div>
|
|
739
|
+
`,
|
|
740
|
+
}),
|
|
741
|
+
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/vue3'
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/vue3-vite'
|
|
2
2
|
import ProductPurchase, {
|
|
3
3
|
type ProductPurchaseProps,
|
|
4
4
|
} from '@/components/features/ProductPurchase.vue'
|
|
5
|
-
import { action } from '
|
|
5
|
+
import { action } from 'storybook/actions'
|
|
6
6
|
import { ref } from 'vue'
|
|
7
7
|
|
|
8
8
|
const meta: Meta<typeof ProductPurchase> = {
|