@beydesign/storybook 0.0.1 → 0.0.2
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 +60 -40
- package/dist/App.js +161 -5
- package/dist/assets/animations/loading-animation.json +1 -0
- package/dist/index.d.ts +12 -2
- package/dist/index.js +12 -4
- package/dist/stories/Agent/AgentCard.d.ts +3 -0
- package/dist/stories/Agent/AgentCard.js +102 -0
- package/dist/stories/Agent/AgentCard.stories.d.ts +13 -0
- package/dist/stories/Agent/AgentCard.stories.js +303 -0
- package/dist/stories/Agent/AgentCardSkeleton.d.ts +2 -0
- package/dist/stories/Agent/AgentCardSkeleton.js +6 -0
- package/dist/stories/Agent/AgentCardSkeleton.stories.d.ts +13 -0
- package/dist/stories/Agent/AgentCardSkeleton.stories.js +101 -0
- package/dist/stories/Agent/CreateNewCard.d.ts +7 -0
- package/dist/stories/Agent/CreateNewCard.js +25 -0
- package/dist/stories/Agent/CreateNewCard.stories.d.ts +7 -0
- package/dist/stories/Agent/CreateNewCard.stories.js +23 -0
- package/dist/stories/Agent/index.d.ts +4 -0
- package/dist/stories/Agent/index.js +4 -0
- package/dist/stories/Agent/types.d.ts +96 -0
- package/dist/stories/Agent/types.js +7 -0
- package/dist/stories/Buttons/MainButton.d.ts +3 -0
- package/dist/stories/Buttons/MainButton.js +302 -0
- package/dist/stories/Buttons/MainButton.stories.d.ts +28 -0
- package/dist/stories/Buttons/MainButton.stories.js +299 -0
- package/dist/stories/Buttons/ToggleButtonGroup.d.ts +3 -0
- package/dist/stories/Buttons/ToggleButtonGroup.js +34 -0
- package/dist/stories/Buttons/ToggleButtonGroup.stories.d.ts +9 -0
- package/dist/stories/Buttons/ToggleButtonGroup.stories.js +78 -0
- package/dist/stories/Buttons/index.d.ts +3 -0
- package/dist/stories/Buttons/index.js +3 -0
- package/dist/stories/{types/button.d.ts → Buttons/types.d.ts} +37 -14
- package/dist/stories/{types/button.js → Buttons/types.js} +12 -2
- package/dist/stories/Credits/CreditsCard.d.ts +3 -0
- package/dist/stories/Credits/CreditsCard.js +53 -0
- package/dist/stories/Credits/CreditsCard.stories.d.ts +7 -0
- package/dist/stories/Credits/CreditsCard.stories.js +34 -0
- package/dist/stories/Credits/CreditsCardSkeleton.d.ts +3 -0
- package/dist/stories/Credits/CreditsCardSkeleton.js +30 -0
- package/dist/stories/Credits/CreditsCardSkeleton.stories.d.ts +7 -0
- package/dist/stories/Credits/CreditsCardSkeleton.stories.js +40 -0
- package/dist/stories/Credits/index.d.ts +3 -0
- package/dist/stories/Credits/index.js +3 -0
- package/dist/stories/Credits/types.d.ts +57 -0
- package/dist/stories/Credits/types.js +11 -0
- package/dist/stories/EntityCard/EntityCard.d.ts +3 -0
- package/dist/stories/EntityCard/EntityCard.js +22 -0
- package/dist/stories/EntityCard/EntityCard.stories.d.ts +10 -0
- package/dist/stories/EntityCard/EntityCard.stories.js +187 -0
- package/dist/stories/EntityCard/EntityCardSkeleton.d.ts +3 -0
- package/dist/stories/EntityCard/EntityCardSkeleton.js +9 -0
- package/dist/stories/EntityCard/EntityCardSkeleton.stories.d.ts +10 -0
- package/dist/stories/EntityCard/EntityCardSkeleton.stories.js +73 -0
- package/dist/stories/EntityCard/index.d.ts +3 -0
- package/dist/stories/EntityCard/index.js +3 -0
- package/dist/stories/EntityCard/types.d.ts +54 -0
- package/dist/stories/EntityCard/types.js +1 -0
- package/dist/stories/Form/AutoComplete.d.ts +3 -0
- package/dist/stories/Form/AutoComplete.js +163 -0
- package/dist/stories/Form/AutoComplete.stories.d.ts +6 -0
- package/dist/stories/Form/AutoComplete.stories.js +88 -0
- package/dist/stories/Form/Checkbox.d.ts +3 -0
- package/dist/stories/Form/Checkbox.js +65 -0
- package/dist/stories/Form/Checkbox.stories.d.ts +13 -0
- package/dist/stories/Form/Checkbox.stories.js +121 -0
- package/dist/stories/Form/Dropdown.d.ts +3 -0
- package/dist/stories/Form/Dropdown.js +183 -0
- package/dist/stories/Form/Dropdown.stories.d.ts +6 -0
- package/dist/stories/Form/Dropdown.stories.js +122 -0
- package/dist/stories/Form/FileUpload/FileUpload.d.ts +3 -0
- package/dist/stories/Form/FileUpload/FileUpload.js +128 -0
- package/dist/stories/Form/FileUpload/FileUpload.stories.d.ts +7 -0
- package/dist/stories/Form/FileUpload/FileUpload.stories.js +51 -0
- package/dist/stories/Form/FileUpload/FileUploading.d.ts +3 -0
- package/dist/stories/Form/FileUpload/FileUploading.js +49 -0
- package/dist/stories/Form/FileUpload/FileUploading.stories.d.ts +10 -0
- package/dist/stories/Form/FileUpload/FileUploading.stories.js +108 -0
- package/dist/stories/Form/FileUpload/UploadedFile.d.ts +3 -0
- package/dist/stories/Form/FileUpload/UploadedFile.js +12 -0
- package/dist/stories/Form/FileUpload/UploadedFile.stories.d.ts +7 -0
- package/dist/stories/Form/FileUpload/UploadedFile.stories.js +73 -0
- package/dist/stories/Form/FileUpload/index.d.ts +3 -0
- package/dist/stories/Form/FileUpload/index.js +3 -0
- package/dist/stories/Form/TextArea.d.ts +3 -0
- package/dist/stories/Form/TextArea.js +23 -0
- package/dist/stories/Form/TextArea.stories.d.ts +161 -0
- package/dist/stories/Form/TextArea.stories.js +142 -0
- package/dist/stories/Form/TextInput.d.ts +3 -0
- package/dist/stories/Form/TextInput.js +57 -0
- package/dist/stories/Form/TextInput.stories.d.ts +155 -0
- package/dist/stories/Form/TextInput.stories.js +155 -0
- package/dist/stories/Form/Toggle.d.ts +3 -0
- package/dist/stories/Form/Toggle.js +57 -0
- package/dist/stories/Form/Toggle.stories.d.ts +6 -0
- package/dist/stories/Form/Toggle.stories.js +79 -0
- package/dist/stories/Form/index.d.ts +8 -0
- package/dist/stories/Form/index.js +8 -0
- package/dist/stories/Form/types.d.ts +274 -0
- package/dist/stories/Form/types.js +46 -0
- package/dist/stories/Foundations/Colors.d.ts +2 -0
- package/dist/stories/Foundations/Colors.js +266 -0
- package/dist/stories/Foundations/Colors.stories.d.ts +6 -0
- package/dist/stories/Foundations/Colors.stories.js +15 -0
- package/dist/stories/Foundations/index.d.ts +1 -0
- package/dist/stories/Foundations/index.js +1 -0
- package/dist/stories/Navigation/ComplexHeader.d.ts +3 -0
- package/dist/stories/Navigation/ComplexHeader.js +21 -0
- package/dist/stories/Navigation/ComplexHeader.stories.d.ts +6 -0
- package/dist/stories/Navigation/ComplexHeader.stories.js +82 -0
- package/dist/stories/Navigation/Header.d.ts +3 -0
- package/dist/stories/Navigation/Header.js +9 -0
- package/dist/stories/Navigation/Header.stories.d.ts +7 -0
- package/dist/stories/Navigation/Header.stories.js +87 -0
- package/dist/stories/Navigation/NavItem.d.ts +3 -0
- package/dist/stories/Navigation/NavItem.js +66 -0
- package/dist/stories/Navigation/NavItem.stories.d.ts +14 -0
- package/dist/stories/Navigation/NavItem.stories.js +100 -0
- package/dist/stories/Navigation/ProcessHeader.d.ts +3 -0
- package/dist/stories/Navigation/ProcessHeader.js +11 -0
- package/dist/stories/Navigation/ProcessHeader.stories.d.ts +6 -0
- package/dist/stories/Navigation/ProcessHeader.stories.js +76 -0
- package/dist/stories/Navigation/Sidebar.d.ts +3 -0
- package/dist/stories/Navigation/Sidebar.js +115 -0
- package/dist/stories/Navigation/Sidebar.stories.d.ts +11 -0
- package/dist/stories/Navigation/Sidebar.stories.js +174 -0
- package/dist/stories/Navigation/index.d.ts +6 -0
- package/dist/stories/Navigation/index.js +6 -0
- package/dist/stories/Navigation/types.d.ts +186 -0
- package/dist/stories/Navigation/types.js +21 -0
- package/dist/stories/PlanCard/PlanCard.d.ts +3 -0
- package/dist/stories/PlanCard/PlanCard.js +13 -0
- package/dist/stories/PlanCard/PlanCard.stories.d.ts +9 -0
- package/dist/stories/PlanCard/PlanCard.stories.js +125 -0
- package/dist/stories/PlanCard/PlanCardSkeleton.d.ts +3 -0
- package/dist/stories/PlanCard/PlanCardSkeleton.js +6 -0
- package/dist/stories/PlanCard/PlanCardSkeleton.stories.d.ts +7 -0
- package/dist/stories/PlanCard/PlanCardSkeleton.stories.js +40 -0
- package/dist/stories/PlanCard/index.d.ts +3 -0
- package/dist/stories/PlanCard/index.js +3 -0
- package/dist/stories/PlanCard/types.d.ts +61 -0
- package/dist/stories/PlanCard/types.js +1 -0
- package/dist/stories/StripeProduct/StripeProduct.d.ts +3 -0
- package/dist/stories/StripeProduct/StripeProduct.js +24 -0
- package/dist/stories/StripeProduct/StripeProduct.stories.d.ts +10 -0
- package/dist/stories/StripeProduct/StripeProduct.stories.js +110 -0
- package/dist/stories/StripeProduct/StripeProductCardSkeleton.d.ts +3 -0
- package/dist/stories/StripeProduct/StripeProductCardSkeleton.js +6 -0
- package/dist/stories/StripeProduct/StripeProductCardSkeleton.stories.d.ts +16 -0
- package/dist/stories/StripeProduct/StripeProductCardSkeleton.stories.js +137 -0
- package/dist/stories/StripeProduct/index.d.ts +3 -0
- package/dist/stories/StripeProduct/index.js +3 -0
- package/dist/stories/StripeProduct/types.d.ts +56 -0
- package/dist/stories/StripeProduct/types.js +1 -0
- package/dist/stories/Typography/Typography.d.ts +3 -0
- package/dist/stories/Typography/Typography.js +22 -0
- package/dist/stories/Typography/Typography.stories.d.ts +25 -0
- package/dist/stories/Typography/Typography.stories.js +225 -0
- package/dist/stories/Typography/index.d.ts +2 -0
- package/dist/stories/Typography/index.js +2 -0
- package/dist/stories/Typography/types.d.ts +46 -0
- package/dist/stories/Typography/types.js +27 -0
- package/dist/stories/UI/Avatar.d.ts +3 -0
- package/dist/stories/UI/Avatar.js +76 -0
- package/dist/stories/UI/Avatar.stories.d.ts +8 -0
- package/dist/stories/UI/Avatar.stories.js +76 -0
- package/dist/stories/UI/Badge.d.ts +3 -0
- package/dist/stories/UI/Badge.js +118 -0
- package/dist/stories/UI/Badge.stories.d.ts +11 -0
- package/dist/stories/UI/Badge.stories.js +107 -0
- package/dist/stories/UI/CheckIcon.d.ts +3 -0
- package/dist/stories/UI/CheckIcon.js +36 -0
- package/dist/stories/UI/CheckIcon.stories.d.ts +7 -0
- package/dist/stories/UI/CheckIcon.stories.js +48 -0
- package/dist/stories/UI/FeatureBanner.d.ts +3 -0
- package/dist/stories/UI/FeatureBanner.js +34 -0
- package/dist/stories/UI/FeatureBanner.stories.d.ts +9 -0
- package/dist/stories/UI/FeatureBanner.stories.js +131 -0
- package/dist/stories/UI/HintBubble.d.ts +3 -0
- package/dist/stories/UI/HintBubble.js +28 -0
- package/dist/stories/UI/HintBubble.stories.d.ts +9 -0
- package/dist/stories/UI/HintBubble.stories.js +68 -0
- package/dist/stories/UI/Logo.d.ts +3 -0
- package/dist/stories/UI/Logo.js +60 -0
- package/dist/stories/UI/Logo.stories.d.ts +11 -0
- package/dist/stories/UI/Logo.stories.js +65 -0
- package/dist/stories/UI/Menu.d.ts +3 -0
- package/dist/stories/UI/Menu.js +56 -0
- package/dist/stories/UI/Menu.stories.d.ts +7 -0
- package/dist/stories/UI/Menu.stories.js +80 -0
- package/dist/stories/UI/ProgressIndicator.d.ts +3 -0
- package/dist/stories/UI/ProgressIndicator.js +35 -0
- package/dist/stories/UI/ProgressIndicator.stories.d.ts +10 -0
- package/dist/stories/UI/ProgressIndicator.stories.js +98 -0
- package/dist/stories/UI/PromoBanner.d.ts +3 -0
- package/dist/stories/UI/PromoBanner.js +34 -0
- package/dist/stories/UI/PromoBanner.stories.d.ts +9 -0
- package/dist/stories/UI/PromoBanner.stories.js +159 -0
- package/dist/stories/UI/SkeletonLoader.d.ts +3 -0
- package/dist/stories/UI/SkeletonLoader.js +19 -0
- package/dist/stories/UI/SkeletonLoader.stories.d.ts +8 -0
- package/dist/stories/UI/SkeletonLoader.stories.js +74 -0
- package/dist/stories/UI/Stepper.d.ts +3 -0
- package/dist/stories/UI/Stepper.js +67 -0
- package/dist/stories/UI/Stepper.stories.d.ts +6 -0
- package/dist/stories/UI/Stepper.stories.js +65 -0
- package/dist/stories/UI/Topbar.d.ts +3 -0
- package/dist/stories/UI/Topbar.js +9 -0
- package/dist/stories/UI/Topbar.stories.d.ts +6 -0
- package/dist/stories/UI/Topbar.stories.js +71 -0
- package/dist/stories/UI/index.d.ts +13 -0
- package/dist/stories/UI/index.js +13 -0
- package/dist/stories/UI/types.d.ts +398 -0
- package/dist/stories/UI/types.js +110 -0
- package/dist/utils/common.d.ts +2 -0
- package/dist/utils/common.js +20 -0
- package/dist/utils/icon.d.ts +6 -0
- package/dist/utils/icon.js +6 -0
- package/dist/utils/index.d.ts +3 -0
- package/dist/utils/index.js +3 -0
- package/dist/utils/typography.d.ts +14 -0
- package/dist/utils/typography.js +46 -0
- package/package.json +48 -42
- package/dist/stories/Button.d.ts +0 -4
- package/dist/stories/Button.js +0 -258
- package/dist/stories/Colors.d.ts +0 -5
- package/dist/stories/Colors.js +0 -9
- package/dist/stories/Header.d.ts +0 -12
- package/dist/stories/Header.js +0 -4
- package/dist/stories/Header.stories.d.ts +0 -18
- package/dist/stories/Header.stories.js +0 -26
- package/dist/stories/Page.d.ts +0 -3
- package/dist/stories/Page.js +0 -8
- package/dist/stories/Page.stories.d.ts +0 -12
- package/dist/stories/Page.stories.js +0 -24
|
@@ -0,0 +1,174 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { Sidebar } from './Sidebar';
|
|
3
|
+
import { SidebarSize, NavItemState } from './types';
|
|
4
|
+
import { Box, Stack, Typography } from '@mui/material';
|
|
5
|
+
const meta = {
|
|
6
|
+
title: 'Design System/Components/Navigation/Sidebar',
|
|
7
|
+
component: Sidebar,
|
|
8
|
+
parameters: {
|
|
9
|
+
layout: 'fullscreen',
|
|
10
|
+
},
|
|
11
|
+
tags: ['autodocs'],
|
|
12
|
+
argTypes: {
|
|
13
|
+
size: {
|
|
14
|
+
control: 'select',
|
|
15
|
+
options: Object.values(SidebarSize),
|
|
16
|
+
},
|
|
17
|
+
logoProps: {
|
|
18
|
+
control: 'object',
|
|
19
|
+
},
|
|
20
|
+
},
|
|
21
|
+
};
|
|
22
|
+
export default meta;
|
|
23
|
+
const defaultNavSections = [
|
|
24
|
+
{
|
|
25
|
+
title: '',
|
|
26
|
+
items: [
|
|
27
|
+
{
|
|
28
|
+
text: 'Home',
|
|
29
|
+
icon: 'House',
|
|
30
|
+
state: NavItemState.Default,
|
|
31
|
+
link: '#/home',
|
|
32
|
+
},
|
|
33
|
+
],
|
|
34
|
+
showSeparator: true,
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
title: '',
|
|
38
|
+
items: [
|
|
39
|
+
{
|
|
40
|
+
text: 'Avatars',
|
|
41
|
+
icon: 'UserFocus',
|
|
42
|
+
state: NavItemState.Default,
|
|
43
|
+
link: '#/avatars',
|
|
44
|
+
},
|
|
45
|
+
],
|
|
46
|
+
showSeparator: true,
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
title: 'Videos',
|
|
50
|
+
items: [
|
|
51
|
+
{
|
|
52
|
+
text: 'Text-to-Video',
|
|
53
|
+
icon: 'VideoCamera',
|
|
54
|
+
state: NavItemState.Active,
|
|
55
|
+
link: '#/text-to-video',
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
text: 'Outreach Campaigns',
|
|
59
|
+
icon: 'UsersFour',
|
|
60
|
+
state: NavItemState.Default,
|
|
61
|
+
link: '#/outreach-campaigns',
|
|
62
|
+
},
|
|
63
|
+
],
|
|
64
|
+
showSeparator: true,
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
title: 'Conversational Agents',
|
|
68
|
+
items: [
|
|
69
|
+
{
|
|
70
|
+
text: 'My Agents',
|
|
71
|
+
icon: 'Headset',
|
|
72
|
+
state: NavItemState.Default,
|
|
73
|
+
link: '#/my-agents',
|
|
74
|
+
},
|
|
75
|
+
{
|
|
76
|
+
text: 'Knowledge Base',
|
|
77
|
+
icon: 'Book',
|
|
78
|
+
state: NavItemState.Default,
|
|
79
|
+
link: '#/knowledge-base',
|
|
80
|
+
},
|
|
81
|
+
{
|
|
82
|
+
text: 'Conversations',
|
|
83
|
+
icon: 'ChatCircle',
|
|
84
|
+
state: NavItemState.Default,
|
|
85
|
+
link: '#/conversations',
|
|
86
|
+
},
|
|
87
|
+
],
|
|
88
|
+
showSeparator: true,
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
title: 'Analytics',
|
|
92
|
+
items: [
|
|
93
|
+
{
|
|
94
|
+
text: 'Analytics',
|
|
95
|
+
icon: 'ChartLine',
|
|
96
|
+
state: NavItemState.Default,
|
|
97
|
+
showBadge: true,
|
|
98
|
+
link: '#/analytics',
|
|
99
|
+
},
|
|
100
|
+
],
|
|
101
|
+
},
|
|
102
|
+
];
|
|
103
|
+
const defaultBottomNavItems = [
|
|
104
|
+
{
|
|
105
|
+
text: 'My account',
|
|
106
|
+
icon: 'Gear',
|
|
107
|
+
link: '#/account',
|
|
108
|
+
},
|
|
109
|
+
{
|
|
110
|
+
text: 'Feedback',
|
|
111
|
+
icon: 'ChatCircle',
|
|
112
|
+
link: '#/feedback',
|
|
113
|
+
},
|
|
114
|
+
];
|
|
115
|
+
export const InBoxContainer = {
|
|
116
|
+
render: (args) => (_jsxs(Stack, { direction: 'row', height: '100%', width: '100%', children: [_jsx(Box, { height: '100%', display: 'flex', flexDirection: 'column', justifyContent: 'space-between', sx: {
|
|
117
|
+
border: '1px solid var(--color-border-border-component)',
|
|
118
|
+
borderRadius: '8px',
|
|
119
|
+
boxShadow: '0 4px 12px rgba(0, 0, 0, 0.1)',
|
|
120
|
+
maxWidth: '280px',
|
|
121
|
+
}, children: _jsx(Sidebar, { ...args, size: SidebarSize.Expanded, navSections: defaultNavSections.slice(0, 3), bottomNavItems: defaultBottomNavItems, credits: {
|
|
122
|
+
maxCredits: 50,
|
|
123
|
+
usedCredits: 130,
|
|
124
|
+
overUsageEnabled: true,
|
|
125
|
+
overUsedCredits: 20,
|
|
126
|
+
} }) }), _jsx(Box, { sx: { height: '100dvh', width: 'calc(100dvw)', overflow: 'hidden' }, children: _jsx(Typography, { children: "Lorem ipsum dolor sit amet consectetur adipisicing elit. Quisquam, quos." }) })] })),
|
|
127
|
+
};
|
|
128
|
+
export const Expanded = {
|
|
129
|
+
args: {
|
|
130
|
+
size: SidebarSize.Expanded,
|
|
131
|
+
navSections: defaultNavSections,
|
|
132
|
+
bottomNavItems: defaultBottomNavItems,
|
|
133
|
+
credits: {
|
|
134
|
+
maxCredits: 50,
|
|
135
|
+
usedCredits: 10,
|
|
136
|
+
},
|
|
137
|
+
},
|
|
138
|
+
};
|
|
139
|
+
export const Collapsed = {
|
|
140
|
+
args: {
|
|
141
|
+
size: SidebarSize.Collapsed,
|
|
142
|
+
navSections: defaultNavSections,
|
|
143
|
+
bottomNavItems: defaultBottomNavItems,
|
|
144
|
+
credits: {
|
|
145
|
+
maxCredits: 50,
|
|
146
|
+
usedCredits: 102,
|
|
147
|
+
overUsageEnabled: true,
|
|
148
|
+
overUsedCredits: 20,
|
|
149
|
+
},
|
|
150
|
+
},
|
|
151
|
+
};
|
|
152
|
+
export const LoadingCredits = {
|
|
153
|
+
args: {
|
|
154
|
+
size: SidebarSize.Expanded,
|
|
155
|
+
navSections: defaultNavSections,
|
|
156
|
+
bottomNavItems: defaultBottomNavItems,
|
|
157
|
+
loadingCredits: true,
|
|
158
|
+
},
|
|
159
|
+
};
|
|
160
|
+
export const LoadingCreditsCollapsed = {
|
|
161
|
+
args: {
|
|
162
|
+
size: SidebarSize.Collapsed,
|
|
163
|
+
navSections: defaultNavSections,
|
|
164
|
+
bottomNavItems: defaultBottomNavItems,
|
|
165
|
+
loadingCredits: true,
|
|
166
|
+
},
|
|
167
|
+
};
|
|
168
|
+
export const WithoutCredits = {
|
|
169
|
+
args: {
|
|
170
|
+
size: SidebarSize.Expanded,
|
|
171
|
+
navSections: defaultNavSections,
|
|
172
|
+
bottomNavItems: defaultBottomNavItems,
|
|
173
|
+
},
|
|
174
|
+
};
|
|
@@ -0,0 +1,186 @@
|
|
|
1
|
+
import { SxProps, Theme } from '@mui/material';
|
|
2
|
+
import { IconName } from '../../utils';
|
|
3
|
+
import { AvatarProps } from '../UI';
|
|
4
|
+
import { CreditsCardProps } from '../Credits';
|
|
5
|
+
/**
|
|
6
|
+
* Header component props
|
|
7
|
+
*/
|
|
8
|
+
export type HeaderProps = {
|
|
9
|
+
/** Title of the header */
|
|
10
|
+
title: string;
|
|
11
|
+
/** Email of the logged in user */
|
|
12
|
+
email: string;
|
|
13
|
+
/** Avatar props */
|
|
14
|
+
avatarProps: AvatarProps;
|
|
15
|
+
/** Text of the back button */
|
|
16
|
+
backButtonText?: string;
|
|
17
|
+
/** CSS class name for additional styling */
|
|
18
|
+
className?: string;
|
|
19
|
+
/** Callback function to handle back button click */
|
|
20
|
+
onBackClick?: () => void;
|
|
21
|
+
/** Callback function to handle logout button click */
|
|
22
|
+
onLogoutClick?: () => void;
|
|
23
|
+
};
|
|
24
|
+
export declare enum LayoutType {
|
|
25
|
+
List = "list",
|
|
26
|
+
Grid = "grid"
|
|
27
|
+
}
|
|
28
|
+
export type ComplexHeaderProps = {
|
|
29
|
+
/** Title of the header */
|
|
30
|
+
title: string;
|
|
31
|
+
/** Text of the badge */
|
|
32
|
+
badgeText?: string;
|
|
33
|
+
/** Text of the new button */
|
|
34
|
+
newButtonText?: string;
|
|
35
|
+
/** Callback function to handle new button click */
|
|
36
|
+
onNewClick?: () => void;
|
|
37
|
+
/** Callback function to handle output file button click */
|
|
38
|
+
onOutputFileClick?: () => void;
|
|
39
|
+
/** Callback function to handle download all button click */
|
|
40
|
+
onDownloadAllClick?: () => void;
|
|
41
|
+
/** CSS class name for additional styling */
|
|
42
|
+
className?: string;
|
|
43
|
+
/** Callback function to handle layout change */
|
|
44
|
+
onLayoutChange?: (layoutType: LayoutType) => void;
|
|
45
|
+
/** Style object to apply to the component */
|
|
46
|
+
sx?: SxProps<Theme>;
|
|
47
|
+
};
|
|
48
|
+
export declare enum NavItemState {
|
|
49
|
+
Default = "default",
|
|
50
|
+
Active = "active",
|
|
51
|
+
Disabled = "disabled"
|
|
52
|
+
}
|
|
53
|
+
export declare enum NavItemSize {
|
|
54
|
+
Expanded = "expanded",
|
|
55
|
+
Collapsed = "collapsed"
|
|
56
|
+
}
|
|
57
|
+
export interface NavItemProps {
|
|
58
|
+
/**
|
|
59
|
+
* The text to display in the navigation item
|
|
60
|
+
*/
|
|
61
|
+
text: string;
|
|
62
|
+
/**
|
|
63
|
+
* The icon to display before the text
|
|
64
|
+
* Uses Phosphor Icons
|
|
65
|
+
*/
|
|
66
|
+
icon: IconName;
|
|
67
|
+
/**
|
|
68
|
+
* The current state of the navigation item
|
|
69
|
+
*/
|
|
70
|
+
state?: NavItemState;
|
|
71
|
+
/**
|
|
72
|
+
* The size of the navigation item
|
|
73
|
+
*/
|
|
74
|
+
size?: NavItemSize;
|
|
75
|
+
/**
|
|
76
|
+
* Whether to show a "Coming Soon" badge
|
|
77
|
+
*/
|
|
78
|
+
showBadge?: boolean;
|
|
79
|
+
/**
|
|
80
|
+
* Optional click handler
|
|
81
|
+
*/
|
|
82
|
+
onClick?: () => void;
|
|
83
|
+
/**
|
|
84
|
+
* Optional className for additional styling
|
|
85
|
+
*/
|
|
86
|
+
className?: string;
|
|
87
|
+
}
|
|
88
|
+
export declare enum SidebarSize {
|
|
89
|
+
Expanded = "expanded",
|
|
90
|
+
Collapsed = "collapsed"
|
|
91
|
+
}
|
|
92
|
+
export interface NavItemConfig {
|
|
93
|
+
/**
|
|
94
|
+
* The text to display in the navigation item
|
|
95
|
+
*/
|
|
96
|
+
text: string;
|
|
97
|
+
/**
|
|
98
|
+
* The icon to display before the text (Phosphor icon name)
|
|
99
|
+
*/
|
|
100
|
+
icon: IconName;
|
|
101
|
+
/**
|
|
102
|
+
* The current state of the navigation item
|
|
103
|
+
*/
|
|
104
|
+
state?: 'default' | 'active' | 'disabled';
|
|
105
|
+
/**
|
|
106
|
+
* Whether to show a badge (e.g., "Coming Soon")
|
|
107
|
+
*/
|
|
108
|
+
showBadge?: boolean;
|
|
109
|
+
/**
|
|
110
|
+
* Optional click handler
|
|
111
|
+
*/
|
|
112
|
+
onClick?: () => void;
|
|
113
|
+
/**
|
|
114
|
+
* Optional link URL for the navigation item
|
|
115
|
+
*/
|
|
116
|
+
link?: string;
|
|
117
|
+
}
|
|
118
|
+
export interface NavSection {
|
|
119
|
+
/**
|
|
120
|
+
* The title of the section
|
|
121
|
+
*/
|
|
122
|
+
title: string;
|
|
123
|
+
/**
|
|
124
|
+
* The navigation items in this section
|
|
125
|
+
*/
|
|
126
|
+
items: NavItemConfig[];
|
|
127
|
+
/**
|
|
128
|
+
* Whether to show a separator after this section
|
|
129
|
+
*/
|
|
130
|
+
showSeparator?: boolean;
|
|
131
|
+
}
|
|
132
|
+
export interface SidebarProps {
|
|
133
|
+
/**
|
|
134
|
+
* The size of the sidebar
|
|
135
|
+
*/
|
|
136
|
+
size?: SidebarSize;
|
|
137
|
+
/**
|
|
138
|
+
* Optional className for additional styling
|
|
139
|
+
*/
|
|
140
|
+
className?: string;
|
|
141
|
+
/**
|
|
142
|
+
* Navigation sections to display in the sidebar
|
|
143
|
+
*/
|
|
144
|
+
navSections: NavSection[];
|
|
145
|
+
/**
|
|
146
|
+
* Bottom navigation items (e.g., account, feedback)
|
|
147
|
+
*/
|
|
148
|
+
bottomNavItems?: NavItemConfig[];
|
|
149
|
+
/**
|
|
150
|
+
* Credits information
|
|
151
|
+
*/
|
|
152
|
+
credits?: Omit<CreditsCardProps, 'size' | 'className'>;
|
|
153
|
+
/**
|
|
154
|
+
* Whether the credits are loading
|
|
155
|
+
*/
|
|
156
|
+
loadingCredits?: boolean;
|
|
157
|
+
/**
|
|
158
|
+
* Optional callback when sidebar is toggled
|
|
159
|
+
*/
|
|
160
|
+
onToggle?: (size: SidebarSize) => void;
|
|
161
|
+
/**
|
|
162
|
+
* Optional logo props
|
|
163
|
+
*/
|
|
164
|
+
logoProps?: {
|
|
165
|
+
gradient?: string;
|
|
166
|
+
color?: string;
|
|
167
|
+
};
|
|
168
|
+
}
|
|
169
|
+
export interface ProcessHeaderProps {
|
|
170
|
+
/** The title of the process */
|
|
171
|
+
title: string;
|
|
172
|
+
/** The subtitle of the process */
|
|
173
|
+
subtitle: string;
|
|
174
|
+
/** The current step of the process */
|
|
175
|
+
currentStep: number;
|
|
176
|
+
/** The total steps of the process */
|
|
177
|
+
totalSteps: number;
|
|
178
|
+
/** The text to display in the header right */
|
|
179
|
+
headerRightText?: string;
|
|
180
|
+
/** The callback to handle the cancel button click */
|
|
181
|
+
onCancelClick?: () => void;
|
|
182
|
+
/** The style object to apply to the component */
|
|
183
|
+
sx?: SxProps<Theme>;
|
|
184
|
+
/** The class name to apply to the component */
|
|
185
|
+
className?: string;
|
|
186
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
export var LayoutType;
|
|
2
|
+
(function (LayoutType) {
|
|
3
|
+
LayoutType["List"] = "list";
|
|
4
|
+
LayoutType["Grid"] = "grid";
|
|
5
|
+
})(LayoutType || (LayoutType = {}));
|
|
6
|
+
export var NavItemState;
|
|
7
|
+
(function (NavItemState) {
|
|
8
|
+
NavItemState["Default"] = "default";
|
|
9
|
+
NavItemState["Active"] = "active";
|
|
10
|
+
NavItemState["Disabled"] = "disabled";
|
|
11
|
+
})(NavItemState || (NavItemState = {}));
|
|
12
|
+
export var NavItemSize;
|
|
13
|
+
(function (NavItemSize) {
|
|
14
|
+
NavItemSize["Expanded"] = "expanded";
|
|
15
|
+
NavItemSize["Collapsed"] = "collapsed";
|
|
16
|
+
})(NavItemSize || (NavItemSize = {}));
|
|
17
|
+
export var SidebarSize;
|
|
18
|
+
(function (SidebarSize) {
|
|
19
|
+
SidebarSize["Expanded"] = "expanded";
|
|
20
|
+
SidebarSize["Collapsed"] = "collapsed";
|
|
21
|
+
})(SidebarSize || (SidebarSize = {}));
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { Box } from '@mui/material';
|
|
3
|
+
import { Typography, TypographySize, TypographyWeight } from '../Typography';
|
|
4
|
+
import { MainButton, ButtonHierarchy, ButtonSize } from '../Buttons';
|
|
5
|
+
import { Badge, BadgeColor, BadgeSize, CheckIcon, CheckIconColor, CheckIconSize, CheckIconType, } from '../UI';
|
|
6
|
+
export const PlanCard = ({ title, description, price, priceSuffix = '/month', badgeText, badgeColor = BadgeColor.Lemon, highlighted = false, featuresTitle = 'This includes:', features = [], buttonText = 'Upgrade', onButtonClick, buttonDisabled = false, buttonHierarchy = ButtonHierarchy.Primary, buttonLoading = false, width = '286px', style, testId, }) => {
|
|
7
|
+
const planKey = title?.toLowerCase()?.replace(/\s+/g, '-');
|
|
8
|
+
return (_jsxs(Box, { width: width, display: 'flex', flexDirection: 'column', gap: 'var(--spacing-tokens-size-in-px-spacing-spacing-xl)', paddingX: 'var(--spacing-tokens-size-in-px-spacing-spacing-xl)', paddingY: 'var(--spacing-tokens-size-in-px-spacing-spacing-2xl)', borderRadius: 'var(--spacing-tokens-size-in-px-spacing-spacing-lg)', bgcolor: highlighted
|
|
9
|
+
? 'var(--color-background-bg-card-highlight)'
|
|
10
|
+
: 'var(--color-background-bg-component)', border: `1px solid ${highlighted
|
|
11
|
+
? 'var(--color-border-border-brand)'
|
|
12
|
+
: 'var(--color-border-border-subtle)'}`, boxSizing: 'border-box', style: style, "data-testid": testId ?? `${planKey}-plan-card`, children: [_jsxs(Box, { display: 'flex', flexDirection: 'column', gap: 'var(--spacing-tokens-size-in-px-spacing-spacing-md)', children: [_jsxs(Box, { display: 'flex', flexDirection: 'row', justifyContent: 'space-between', alignItems: 'center', minHeight: '24px', gap: 'var(--spacing-tokens-size-in-px-spacing-spacing-md)', children: [_jsx(Typography, { size: TypographySize.HeadingM, weight: TypographyWeight.Bold, color: 'var(--color-text-text-title)', children: title }), badgeText && (_jsx(Badge, { text: badgeText, color: badgeColor, size: BadgeSize.xs, fill: true }))] }), description && (_jsx(Typography, { size: TypographySize.TextS, weight: TypographyWeight.Regular, color: 'var(--color-text-text-paragraph)', textStyle: { textAlign: 'left' }, children: description })), price && (_jsxs(Box, { display: 'flex', flexDirection: 'row', alignItems: 'baseline', gap: '2px', children: [_jsx(Typography, { size: TypographySize.HeadingL, weight: TypographyWeight.Bold, color: 'var(--color-text-text-title)', children: price }), priceSuffix && (_jsx(Typography, { size: TypographySize.TextXS, weight: TypographyWeight.Regular, color: 'var(--color-text-text-paragraph)', children: priceSuffix }))] }))] }), buttonText && (_jsx(MainButton, { text: buttonText, hierarchy: buttonHierarchy, size: ButtonSize.md, disabled: buttonDisabled, loading: buttonLoading, onClick: onButtonClick, style: { width: '100%' }, testId: `${planKey}-plan-button` })), features.length > 0 && (_jsxs(Box, { display: 'flex', flexDirection: 'column', gap: 'var(--spacing-tokens-size-in-px-spacing-spacing-md)', alignItems: 'flex-start', children: [_jsx(Typography, { size: TypographySize.TextS, weight: TypographyWeight.Medium, color: 'var(--color-text-text-paragraph)', children: featuresTitle }), features.map((feature, index) => (_jsxs(Box, { display: 'flex', flexDirection: 'row', alignItems: 'flex-start', gap: 'var(--spacing-tokens-size-in-px-spacing-spacing-md)', width: '100%', children: [_jsx(CheckIcon, { color: CheckIconColor.Violet, size: CheckIconSize.xs, type: CheckIconType.Duotone }), _jsx(Typography, { size: TypographySize.TextM, weight: TypographyWeight.Regular, color: 'var(--color-text-text-title)', textStyle: { textAlign: 'left' }, children: feature })] }, `${index}-${feature}`)))] }))] }));
|
|
13
|
+
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
+
import { PlanCard } from './PlanCard';
|
|
3
|
+
declare const meta: Meta<typeof PlanCard>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof PlanCard>;
|
|
6
|
+
export declare const Pro: Story;
|
|
7
|
+
export declare const Free: Story;
|
|
8
|
+
export declare const Personal: Story;
|
|
9
|
+
export declare const Custom: Story;
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
import { PlanCard } from './PlanCard';
|
|
2
|
+
import { BadgeColor } from '../UI';
|
|
3
|
+
import { ButtonHierarchy } from '../Buttons';
|
|
4
|
+
const meta = {
|
|
5
|
+
title: 'Design System/Components/PlanCard/PlanCard',
|
|
6
|
+
component: PlanCard,
|
|
7
|
+
parameters: {
|
|
8
|
+
layout: 'centered',
|
|
9
|
+
design: {
|
|
10
|
+
type: 'figspec',
|
|
11
|
+
url: 'https://www.figma.com/design/mIhjz2yJjcpLlIqw6oUivt/Beyond-Presence?node-id=7002-19848',
|
|
12
|
+
},
|
|
13
|
+
},
|
|
14
|
+
tags: ['autodocs'],
|
|
15
|
+
argTypes: {
|
|
16
|
+
title: { control: 'text', description: 'Plan name' },
|
|
17
|
+
description: { control: 'text', description: 'Short plan description' },
|
|
18
|
+
price: {
|
|
19
|
+
control: 'text',
|
|
20
|
+
description: 'Price text (e.g. "€210" or "Custom")',
|
|
21
|
+
},
|
|
22
|
+
priceSuffix: {
|
|
23
|
+
control: 'text',
|
|
24
|
+
description: 'Price suffix',
|
|
25
|
+
table: { defaultValue: { summary: '/month' } },
|
|
26
|
+
},
|
|
27
|
+
badgeText: { control: 'text', description: 'Badge text' },
|
|
28
|
+
badgeColor: {
|
|
29
|
+
control: 'select',
|
|
30
|
+
options: Object.values(BadgeColor),
|
|
31
|
+
description: 'Badge color',
|
|
32
|
+
table: { defaultValue: { summary: BadgeColor.Lemon } },
|
|
33
|
+
},
|
|
34
|
+
highlighted: {
|
|
35
|
+
control: 'boolean',
|
|
36
|
+
description: 'Brand background + border highlight',
|
|
37
|
+
},
|
|
38
|
+
featuresTitle: {
|
|
39
|
+
control: 'text',
|
|
40
|
+
table: { defaultValue: { summary: 'This includes:' } },
|
|
41
|
+
},
|
|
42
|
+
features: { control: 'object', description: 'Feature list' },
|
|
43
|
+
buttonText: {
|
|
44
|
+
control: 'text',
|
|
45
|
+
table: { defaultValue: { summary: 'Upgrade' } },
|
|
46
|
+
},
|
|
47
|
+
buttonDisabled: { control: 'boolean' },
|
|
48
|
+
buttonHierarchy: {
|
|
49
|
+
control: 'select',
|
|
50
|
+
options: Object.values(ButtonHierarchy),
|
|
51
|
+
table: { defaultValue: { summary: ButtonHierarchy.Primary } },
|
|
52
|
+
},
|
|
53
|
+
buttonLoading: { control: 'boolean' },
|
|
54
|
+
width: {
|
|
55
|
+
control: 'text',
|
|
56
|
+
table: { defaultValue: { summary: '286px' } },
|
|
57
|
+
},
|
|
58
|
+
},
|
|
59
|
+
};
|
|
60
|
+
export default meta;
|
|
61
|
+
export const Pro = {
|
|
62
|
+
args: {
|
|
63
|
+
title: 'Pro',
|
|
64
|
+
description: 'Designed for professionals looking to expand their reach.',
|
|
65
|
+
price: '€210',
|
|
66
|
+
priceSuffix: '/month',
|
|
67
|
+
badgeText: 'Most Popular',
|
|
68
|
+
badgeColor: BadgeColor.Lemon,
|
|
69
|
+
highlighted: true,
|
|
70
|
+
buttonText: 'Upgrade',
|
|
71
|
+
features: [
|
|
72
|
+
'300 credits (300 min of Conversational Agent video)',
|
|
73
|
+
'5 stock Digital Twins',
|
|
74
|
+
'3 active Conversational Agents',
|
|
75
|
+
'Priority support',
|
|
76
|
+
],
|
|
77
|
+
},
|
|
78
|
+
};
|
|
79
|
+
export const Free = {
|
|
80
|
+
args: {
|
|
81
|
+
title: 'Free',
|
|
82
|
+
description: 'Discover what Beyond Presence has to offer.',
|
|
83
|
+
price: '€0',
|
|
84
|
+
priceSuffix: '/month',
|
|
85
|
+
badgeText: 'Current Plan',
|
|
86
|
+
badgeColor: BadgeColor.Green,
|
|
87
|
+
buttonText: 'Current plan',
|
|
88
|
+
buttonDisabled: true,
|
|
89
|
+
features: [
|
|
90
|
+
'1 credit (1 min of Conversational Agent video)',
|
|
91
|
+
'5 stock Digital Twins',
|
|
92
|
+
],
|
|
93
|
+
},
|
|
94
|
+
};
|
|
95
|
+
export const Personal = {
|
|
96
|
+
args: {
|
|
97
|
+
title: 'Personal',
|
|
98
|
+
description: 'Tailored for personal projects and independent creators.',
|
|
99
|
+
price: '€50',
|
|
100
|
+
priceSuffix: '/month',
|
|
101
|
+
buttonText: 'Upgrade',
|
|
102
|
+
features: [
|
|
103
|
+
'50 credits (50 min of Conversational Agent video)',
|
|
104
|
+
'5 stock Digital Twins',
|
|
105
|
+
'1 active Conversational Agent',
|
|
106
|
+
],
|
|
107
|
+
},
|
|
108
|
+
};
|
|
109
|
+
export const Custom = {
|
|
110
|
+
args: {
|
|
111
|
+
title: 'Professional',
|
|
112
|
+
description: 'For businesses with high volume and custom needs.',
|
|
113
|
+
price: 'Custom',
|
|
114
|
+
priceSuffix: '',
|
|
115
|
+
buttonText: 'Upgrade',
|
|
116
|
+
features: ['5000+ credits (5000+ min of Conversational Agent video)'],
|
|
117
|
+
},
|
|
118
|
+
parameters: {
|
|
119
|
+
docs: {
|
|
120
|
+
description: {
|
|
121
|
+
story: 'A custom-priced plan — the price suffix is omitted.',
|
|
122
|
+
},
|
|
123
|
+
},
|
|
124
|
+
},
|
|
125
|
+
};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { Box } from '@mui/material';
|
|
3
|
+
import { SkeletonLoader } from '../UI';
|
|
4
|
+
export const PlanCardSkeleton = ({ showBadge = true, showButton = true, showFeatures = true, featuresCount = 4, width = '286px', style, testId, }) => {
|
|
5
|
+
return (_jsxs(Box, { width: width, display: 'flex', flexDirection: 'column', gap: 'var(--spacing-tokens-size-in-px-spacing-spacing-xl)', paddingX: 'var(--spacing-tokens-size-in-px-spacing-spacing-xl)', paddingY: 'var(--spacing-tokens-size-in-px-spacing-spacing-2xl)', borderRadius: 'var(--spacing-tokens-size-in-px-spacing-spacing-lg)', bgcolor: 'var(--color-background-bg-component)', border: '1px solid var(--color-border-border-subtle)', boxSizing: 'border-box', style: style, "data-testid": testId, children: [_jsxs(Box, { display: 'flex', flexDirection: 'column', gap: 'var(--spacing-tokens-size-in-px-spacing-spacing-md)', children: [_jsxs(Box, { display: 'flex', flexDirection: 'row', justifyContent: 'space-between', alignItems: 'center', gap: 'var(--spacing-tokens-size-in-px-spacing-spacing-md)', children: [_jsx(SkeletonLoader, { width: '40%', height: '24px', borderRadius: 'var(--spacing-tokens-size-in-px-spacing-spacing-xs)' }), showBadge && (_jsx(SkeletonLoader, { width: '88px', height: '24px', borderRadius: 'var(--spacing-tokens-size-in-px-radius-radius-full)' }))] }), _jsx(SkeletonLoader, { width: '100%', height: '20px', borderRadius: 'var(--spacing-tokens-size-in-px-spacing-spacing-xs)' }), _jsx(SkeletonLoader, { width: '50%', height: '32px', borderRadius: 'var(--spacing-tokens-size-in-px-spacing-spacing-xs)' })] }), showButton && (_jsx(SkeletonLoader, { width: '100%', height: '36px', borderRadius: 'var(--spacing-tokens-size-in-px-radius-radius-xs)' })), showFeatures && (_jsxs(Box, { display: 'flex', flexDirection: 'column', gap: 'var(--spacing-tokens-size-in-px-spacing-spacing-md)', alignItems: 'flex-start', children: [_jsx(SkeletonLoader, { width: '96px', height: '20px', borderRadius: 'var(--spacing-tokens-size-in-px-spacing-spacing-xs)' }), Array.from({ length: featuresCount }).map((_, index) => (_jsxs(Box, { display: 'flex', flexDirection: 'row', alignItems: 'center', gap: 'var(--spacing-tokens-size-in-px-spacing-spacing-md)', width: '100%', children: [_jsx(SkeletonLoader, { width: '20px', height: '20px', borderRadius: 'var(--spacing-tokens-size-in-px-radius-radius-full)' }), _jsx(SkeletonLoader, { width: index % 2 === 0 ? '80%' : '60%', height: '18px', borderRadius: 'var(--spacing-tokens-size-in-px-spacing-spacing-xs)' })] }, index)))] }))] }));
|
|
6
|
+
};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
+
import { PlanCardSkeleton } from './PlanCardSkeleton';
|
|
3
|
+
declare const meta: Meta<typeof PlanCardSkeleton>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof PlanCardSkeleton>;
|
|
6
|
+
export declare const Default: Story;
|
|
7
|
+
export declare const Grid: Story;
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { Box } from '@mui/material';
|
|
3
|
+
import { PlanCardSkeleton } from './PlanCardSkeleton';
|
|
4
|
+
const meta = {
|
|
5
|
+
title: 'Design System/Components/PlanCard/PlanCardSkeleton',
|
|
6
|
+
component: PlanCardSkeleton,
|
|
7
|
+
parameters: {
|
|
8
|
+
layout: 'centered',
|
|
9
|
+
},
|
|
10
|
+
tags: ['autodocs'],
|
|
11
|
+
argTypes: {
|
|
12
|
+
showBadge: {
|
|
13
|
+
control: 'boolean',
|
|
14
|
+
table: { defaultValue: { summary: 'true' } },
|
|
15
|
+
},
|
|
16
|
+
showButton: {
|
|
17
|
+
control: 'boolean',
|
|
18
|
+
table: { defaultValue: { summary: 'true' } },
|
|
19
|
+
},
|
|
20
|
+
showFeatures: {
|
|
21
|
+
control: 'boolean',
|
|
22
|
+
table: { defaultValue: { summary: 'true' } },
|
|
23
|
+
},
|
|
24
|
+
featuresCount: {
|
|
25
|
+
control: 'number',
|
|
26
|
+
table: { defaultValue: { summary: '4' } },
|
|
27
|
+
},
|
|
28
|
+
width: {
|
|
29
|
+
control: 'text',
|
|
30
|
+
table: { defaultValue: { summary: '286px' } },
|
|
31
|
+
},
|
|
32
|
+
},
|
|
33
|
+
};
|
|
34
|
+
export default meta;
|
|
35
|
+
export const Default = {
|
|
36
|
+
args: {},
|
|
37
|
+
};
|
|
38
|
+
export const Grid = {
|
|
39
|
+
render: () => (_jsxs(Box, { display: "flex", flexWrap: "wrap", gap: 2, children: [_jsx(PlanCardSkeleton, {}), _jsx(PlanCardSkeleton, { featuresCount: 3 }), _jsx(PlanCardSkeleton, { featuresCount: 5 })] })),
|
|
40
|
+
};
|