aural-ui 4.0.1 → 4.1.0

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.
Files changed (174) hide show
  1. package/dist/components/aspect-ratio/AspectRatio.stories.tsx +290 -1228
  2. package/dist/components/avatar/Avatar.stories.tsx +219 -235
  3. package/dist/components/badge/Badge.stories.tsx +379 -116
  4. package/dist/components/banner/Banner.stories.tsx +445 -391
  5. package/dist/components/breadcrumb/Breadcrumb.stories.tsx +453 -199
  6. package/dist/components/button/Button.stories.tsx +585 -230
  7. package/dist/components/card/Card.stories.tsx +619 -301
  8. package/dist/components/char-count/CharCount.stories.tsx +350 -248
  9. package/dist/components/checkbox/Checkbox.stories.tsx +309 -167
  10. package/dist/components/chip/Chip.stories.tsx +362 -168
  11. package/dist/components/circular-loader/CircularLoader.stories.tsx +221 -636
  12. package/dist/components/clamp-lines/ClampLines.stories.tsx +246 -117
  13. package/dist/components/collapsible/Collapsible.stories.tsx +391 -252
  14. package/dist/components/command/Command.stories.tsx +530 -867
  15. package/dist/components/dialog/Dialog.stories.tsx +501 -950
  16. package/dist/components/divider/Divider.stories.tsx +264 -527
  17. package/dist/components/dot-loader/DotLoader.stories.tsx +256 -257
  18. package/dist/components/drawer/Drawer.stories.tsx +659 -1023
  19. package/dist/components/dropdown/Dropdown.stories.tsx +643 -1028
  20. package/dist/components/form/Form.stories.tsx +560 -274
  21. package/dist/components/helper-text/HelperText.stories.tsx +199 -200
  22. package/dist/components/hover-card/HoverCard.stories.tsx +318 -1254
  23. package/dist/components/icon-button/IconButton.stories.tsx +837 -194
  24. package/dist/components/if-else/if-else.stories.tsx +370 -83
  25. package/dist/components/input/Input.stories.tsx +436 -368
  26. package/dist/components/label/Label.stories.tsx +156 -154
  27. package/dist/components/list/List.stories.tsx +484 -835
  28. package/dist/components/marquee/Marquee.stories.tsx +356 -712
  29. package/dist/components/otp-inputs/OtpInputs.stories.tsx +352 -422
  30. package/dist/components/overlay/Overlay.stories.tsx +452 -824
  31. package/dist/components/pagination/Pagination.stories.tsx +721 -210
  32. package/dist/components/popover/Popover.stories.tsx +481 -896
  33. package/dist/components/radio/Radio.stories.tsx +432 -124
  34. package/dist/components/resizable/Resizable.stories.tsx +495 -799
  35. package/dist/components/scroll-area/ScrollArea.stories.tsx +383 -1059
  36. package/dist/components/search/Search.stories.tsx +312 -595
  37. package/dist/components/select/Select.stories.tsx +684 -789
  38. package/dist/components/sheet/Sheet.stories.tsx +671 -950
  39. package/dist/components/skelton/Skelton.stories.tsx +230 -764
  40. package/dist/components/slider/Slider.stories.tsx +383 -760
  41. package/dist/components/stepper/Stepper.stories.tsx +371 -514
  42. package/dist/components/switch/Switch.stories.tsx +461 -208
  43. package/dist/components/switch-case/SwitchCase.stories.tsx +367 -188
  44. package/dist/components/table/Table.stories.tsx +770 -916
  45. package/dist/components/tabs/Tabs.stories.tsx +458 -1455
  46. package/dist/components/tag/Tag.stories.tsx +714 -542
  47. package/dist/components/textarea/TextArea.stories.tsx +621 -562
  48. package/dist/components/thumbnail-tags/ThumbnailTags.stories.tsx +228 -154
  49. package/dist/components/toast/Toast.stories.tsx +452 -1339
  50. package/dist/components/toggle/Toggle.stories.tsx +488 -931
  51. package/dist/components/tooltip/Tooltip.stories.tsx +344 -1388
  52. package/dist/components/typography/Typography.stories.tsx +406 -89
  53. package/dist/hooks/use-change-state/UseChangeState.stories.tsx +309 -606
  54. package/dist/hooks/use-previous/UsePrevious.stories.tsx +367 -917
  55. package/dist/hooks/use-standalone-pagination/UseStandalonePagination.stories.tsx +639 -867
  56. package/dist/icons/Icons.stories.tsx +0 -12
  57. package/dist/icons/ai-avatar-icon/AiAvatarIcon.stories.tsx +223 -1060
  58. package/dist/icons/alert-icon/AlertIcon.stories.tsx +106 -968
  59. package/dist/icons/all-icons.tsx +37 -16
  60. package/dist/icons/angle-down-icon/AngleDownIcon.stories.tsx +137 -1010
  61. package/dist/icons/apple-logo-icon/AppleLogoIcon.stories.tsx +145 -935
  62. package/dist/icons/arrow-box-left-icon/ArrowBoxLeftIcon.stories.tsx +132 -1046
  63. package/dist/icons/arrow-corner-up-left-icon/ArrowCornerUpLeftIcon.stories.tsx +134 -986
  64. package/dist/icons/arrow-corner-up-right-icon/ArrowCornerUpRightIcon.stories.tsx +135 -1028
  65. package/dist/icons/arrow-left-icon/ArrowLeftIcon.stories.tsx +133 -971
  66. package/dist/icons/arrow-right-icon/ArrowRightIcon.stories.tsx +145 -1123
  67. package/dist/icons/arrow-right-up-icon/ArrowRightUpIcon.stories.tsx +143 -1252
  68. package/dist/icons/art-board-icon/ArtBoardIcon.stories.tsx +123 -632
  69. package/dist/icons/audio-bar-icon/AudioBarIcon.stories.tsx +141 -1223
  70. package/dist/icons/backward-ten-seconds-icon/BackwardTenSecondsIcon.stories.tsx +164 -1018
  71. package/dist/icons/bubble-check-icon/BubbleCheckIcon.stories.tsx +121 -1236
  72. package/dist/icons/bubble-crossed-icon/BubbleCrossedIcon.stories.tsx +121 -1213
  73. package/dist/icons/bubble-sparkle-icon/BubbleSparkleIcon.stories.tsx +116 -893
  74. package/dist/icons/camera-icon/CameraIcon.stories.tsx +109 -1254
  75. package/dist/icons/capital-a-letter-icon/CapitalALetterIcon.stories.tsx +114 -975
  76. package/dist/icons/chevron-double-left-icon/ChevronDoubleLeftIcon.stories.tsx +157 -994
  77. package/dist/icons/chevron-double-right-icon/ChevronDoubleRightIcon.stories.tsx +160 -992
  78. package/dist/icons/chevron-down-icon/ChevronDownIcon.stories.tsx +140 -970
  79. package/dist/icons/chevron-left-icon/ChevronLeftIcon.stories.tsx +126 -993
  80. package/dist/icons/chevron-right-icon/ChevronRightIcon.stories.tsx +144 -987
  81. package/dist/icons/chevron-up-icon/ChevronUpIcon.stories.tsx +141 -1007
  82. package/dist/icons/circle-tick-icon/CircleTickIcon.stories.tsx +147 -1187
  83. package/dist/icons/circular-play-icon/CircularPlayIcon.stories.tsx +110 -476
  84. package/dist/icons/coin-icon/CoinIcon.stories.tsx +120 -1364
  85. package/dist/icons/coin-toons-icon/CoinToonsIcon.stories.tsx +113 -1360
  86. package/dist/icons/column-wide-add-icon/ColumnWideAddIcon.stories.tsx +111 -942
  87. package/dist/icons/command-icon/CommandIcon.stories.tsx +124 -1087
  88. package/dist/icons/copy-icon/CopyIcon.stories.tsx +119 -996
  89. package/dist/icons/cross-circle-icon/CrossCircleIcon.stories.tsx +144 -1046
  90. package/dist/icons/cross-icon/CrossIcon.stories.tsx +136 -999
  91. package/dist/icons/download-icon/DownloadIcon.stories.tsx +123 -857
  92. package/dist/icons/edit-big-icon/EditBigIcon.stories.tsx +121 -1080
  93. package/dist/icons/email-icon/EmailIcon.stories.tsx +112 -979
  94. package/dist/icons/expand-icon/ExpandIcon.stories.tsx +109 -1146
  95. package/dist/icons/eye-close-icon/EyeCloseIcon.stories.tsx +141 -1068
  96. package/dist/icons/eye-open-icon/EyeOpenIcon.stories.tsx +140 -1081
  97. package/dist/icons/feature-shine-icon/FeatureShineIcon.stories.tsx +124 -1050
  98. package/dist/icons/file-chart-icon/FileChartIcon.stories.tsx +123 -1091
  99. package/dist/icons/file-text-icon/FileTextIcon.stories.tsx +122 -633
  100. package/dist/icons/filter-bar-row-icon/FilterBarRowIcon.stories.tsx +116 -1087
  101. package/dist/icons/forward-ten-seconds-icon/ForwardTenSecondsIcon.stories.tsx +166 -1020
  102. package/dist/icons/git-branch-icon/GitBranchIcon.stories.tsx +112 -1182
  103. package/dist/icons/git-fork-icon/GitForkIcon.stories.tsx +112 -1155
  104. package/dist/icons/globe-icon/GlobeIcon.stories.tsx +127 -325
  105. package/dist/icons/google-logo-icon/GoogleLogoIcon.stories.tsx +142 -985
  106. package/dist/icons/grip-vertical-icon/GripVerticalIcon.stories.tsx +116 -1217
  107. package/dist/icons/head-icon/HeadIcon.stories.tsx +108 -953
  108. package/dist/icons/heart-icon/HeartIcon.stories.tsx +117 -1060
  109. package/dist/icons/image-avatar-sparkle-icon/ImageAvatarSparkleIcon.stories.tsx +116 -716
  110. package/dist/icons/image-icon/ImageIcon.stories.tsx +102 -1164
  111. package/dist/icons/import-folder-icon/ImportFolderIcon.stories.tsx +108 -1233
  112. package/dist/icons/import-left-arrow-folder-icon/ImportLeftArrowFolderIcon.stories.tsx +133 -1289
  113. package/dist/icons/indian-flag-icon/IndianFlagIcon.stories.tsx +155 -1012
  114. package/dist/icons/instagram-icon/InstagramIcon.stories.tsx +158 -1438
  115. package/dist/icons/layout-column-icon/LayoutColumnIcon.stories.tsx +121 -1011
  116. package/dist/icons/layout-left-icon/LayoutLeftIcon.stories.tsx +116 -981
  117. package/dist/icons/layout-right-icon/LayoutRightIcon.stories.tsx +116 -979
  118. package/dist/icons/light-bulb-simple-icon/LightBulbSimpleIcon.stories.tsx +105 -1252
  119. package/dist/icons/linked-in-icon/LinkedInIcon.stories.tsx +151 -1554
  120. package/dist/icons/magic-book-icon/MagicBookIcon.stories.tsx +107 -1227
  121. package/dist/icons/magic-edit-icon/MagicEditIcon.stories.tsx +116 -707
  122. package/dist/icons/maintenance-icon/MaintenanceIcon.stories.tsx +119 -1226
  123. package/dist/icons/message-icon/MessageIcon.stories.tsx +111 -557
  124. package/dist/icons/minimize-icon/MinimizeIcon.stories.tsx +112 -1198
  125. package/dist/icons/moon-icon/MoonIcon.stories.tsx +117 -557
  126. package/dist/icons/move-horizontal-icon/MoveHorizontalIcon.stories.tsx +106 -1235
  127. package/dist/icons/move-vertical-icon/MoveVerticalIcon.stories.tsx +112 -1185
  128. package/dist/icons/musical-note-icon/MusicalNoteIcon.stories.tsx +116 -1012
  129. package/dist/icons/notepad-icon/NotepadIcon.stories.tsx +108 -1137
  130. package/dist/icons/notes-icon/NotesIcon.stories.tsx +116 -1138
  131. package/dist/icons/page-search-icon/PageSearchIcon.stories.tsx +106 -1146
  132. package/dist/icons/page-text-icon/PageTextIcon.stories.tsx +119 -719
  133. package/dist/icons/paint-roll-icon/PaintRollIcon.stories.tsx +110 -999
  134. package/dist/icons/paper-plane-icon/PaperPlaneIcon.stories.tsx +109 -912
  135. package/dist/icons/pause-icon/PauseIcon.stories.tsx +110 -1041
  136. package/dist/icons/pencil-icon/PencilIcon.stories.tsx +112 -1109
  137. package/dist/icons/phone-icon/PhoneIcon.stories.tsx +112 -1023
  138. package/dist/icons/plus-icon/PlusIcon.stories.tsx +103 -1132
  139. package/dist/icons/pocket-studio-icon/PocketStudioIcon.stories.tsx +104 -870
  140. package/dist/icons/scroll-down-icon/ScrollDownIcon.stories.tsx +99 -476
  141. package/dist/icons/search-icon/SearchIcon.stories.tsx +108 -1161
  142. package/dist/icons/setting-icon/SettingIcon.stories.tsx +104 -1009
  143. package/dist/icons/share-icon/ShareIcon.stories.tsx +117 -1064
  144. package/dist/icons/shield-icon/ShieldIcon.stories.tsx +114 -974
  145. package/dist/icons/site-logo-icon/SiteLogoIcon.stories.tsx +134 -1160
  146. package/dist/icons/skip-backward-icon/SkipBackwardIcon.stories.tsx +169 -1017
  147. package/dist/icons/skip-forward-icon/SkipForwardIcon.stories.tsx +161 -1016
  148. package/dist/icons/sparkles-soft-icon/SparklesSoftIcon.stories.tsx +102 -1001
  149. package/dist/icons/spinner-gradient-icon/SpinnerGradientIcon.stories.tsx +155 -593
  150. package/dist/icons/spinner-solid-icon/SpinnerSolidIcon.stories.tsx +155 -608
  151. package/dist/icons/spinner-solid-neutral-icon/SpinnerSolidINeutralcon.stories.tsx +142 -712
  152. package/dist/icons/star-icon/StarIcon.stories.tsx +120 -946
  153. package/dist/icons/store-coin-icon/StoreCoinIcon.stories.tsx +109 -1013
  154. package/dist/icons/suggestion-icon/SuggestionIcon.stories.tsx +113 -891
  155. package/dist/icons/sun-icon/SunIcon.stories.tsx +117 -864
  156. package/dist/icons/text-color-icon/TextColorIcon.stories.tsx +113 -989
  157. package/dist/icons/text-indicator-icon/TextIndicatorIcon.stories.tsx +120 -1027
  158. package/dist/icons/threads-icon/ThreadsIcon.stories.tsx +153 -1476
  159. package/dist/icons/tick-circle-icon/TickCircleIcon.stories.tsx +143 -1187
  160. package/dist/icons/tick-icon/TickIcon.stories.tsx +142 -1322
  161. package/dist/icons/trash-icon/TrashIcon.stories.tsx +105 -970
  162. package/dist/icons/twitter-x-icon/TwitterXIcon.stories.tsx +154 -1457
  163. package/dist/icons/upload-icon/UploadIcon.stories.tsx +112 -930
  164. package/dist/icons/vertical-menu-icon/VerticalMenuIcon.stories.tsx +115 -1019
  165. package/dist/icons/video-play-list-icon/VideoPlaylistIcon.stories.tsx +122 -1092
  166. package/dist/icons/voice-playing-icon/VoicePlayingIcon.stories.tsx +120 -1401
  167. package/dist/icons/volume-full-icon/VolumeFullIcon.stories.tsx +107 -1212
  168. package/dist/icons/volume-half-icon/VolumeHalfIcon.stories.tsx +109 -1122
  169. package/dist/icons/volume-off-icon/VolumeOffIcon.stories.tsx +112 -1124
  170. package/dist/icons/warning-icon/WarningIcon.stories.tsx +119 -1083
  171. package/dist/icons/youtube-icon/YoutubeIcon.stories.tsx +158 -983
  172. package/dist/index.cjs +1 -1
  173. package/dist/index.js +1 -1
  174. package/package.json +1 -1
@@ -1,6 +1,8 @@
1
1
  import React from "react"
2
2
  import type { Meta, StoryObj } from "@storybook/react-vite"
3
3
 
4
+ import { AuralComponentDocsPage } from "src/ui/story-spec/components/component-story-docs-page"
5
+
4
6
  import { Divider } from "."
5
7
 
6
8
  const meta: Meta<typeof Divider> = {
@@ -8,93 +10,29 @@ const meta: Meta<typeof Divider> = {
8
10
  component: Divider,
9
11
  parameters: {
10
12
  layout: "centered",
11
- backgrounds: {
12
- default: "dark",
13
- values: [
14
- { name: "dark", value: "#0a0a0a" },
15
- { name: "light", value: "#ffffff" },
16
- ],
17
- },
18
13
  docs: {
19
14
  description: {
20
- component: `
21
- A versatile divider component built on Radix UI Divider with dark theme optimization and multiple visual styles.
22
-
23
- ## Overview
24
-
25
- The Divider component provides clear visual separation between content sections, improving layout organization and readability. It supports multiple variants including solid, stylized, and dashed styles with flexible sizing and orientation options.
26
-
27
- ## Features
28
- - **Multiple Variants**: Primary, secondary, stylised, and dashed styles
29
- - **Flexible Sizing**: Four size options from thin to large
30
- - **Dual Orientation**: Horizontal and vertical layouts
31
- - **Dark Theme Optimized**: Designed for dark interfaces
32
- - **Accessibility Ready**: Built on Radix UI Divider primitive
33
- - **Stylised Option**: Includes decorative audio bar icon
34
- - **Dashed Style**: Perfect for subtle separations and grouped content
35
-
36
- ## Design Tokens
37
- - Uses \`--fm-divider-primary\`, \`--fm-divider-secondary\`, \`--fm-divider-tertiary\` color tokens
38
- - Responsive sizing with consistent visual hierarchy
39
- - Semantic color mapping for different use cases
40
-
41
- ## Usage
42
-
43
- ### Basic Divider
44
- \`\`\`tsx
45
- import { Divider } from '@/ui/components/divider'
46
-
47
- export default function Example() {
48
- return (
49
- <div className="space-y-4">
50
- <p>Content above</p>
51
- <Divider />
52
- <p>Content below</p>
53
- </div>
54
- )
55
- }
56
- \`\`\`
57
-
58
- ### Dashed Divider
59
- \`\`\`tsx
60
- export default function DashedExample() {
61
- return (
62
- <div className="space-y-4">
63
- <h3>Section Title</h3>
64
- <Divider variant="dashed" />
65
- <p>Section content with subtle separation</p>
66
- </div>
67
- )
68
- }
69
- \`\`\`
70
-
71
- ### Vertical Divider
72
- \`\`\`tsx
73
- export default function VerticalExample() {
74
- return (
75
- <div className="flex items-center gap-4">
76
- <span>Item 1</span>
77
- <Divider orientation="vertical" className="h-6" />
78
- <span>Item 2</span>
79
- </div>
80
- )
81
- }
82
- \`\`\`
83
-
84
- ### Stylised Divider
85
- \`\`\`tsx
86
- export default function StylisedExample() {
87
- return (
88
- <div className="space-y-6">
89
- <section>Main content section</section>
90
- <Divider variant="stylised" />
91
- <section>Next content section</section>
92
- </div>
93
- )
94
- }
95
- \`\`\`
96
- `,
15
+ component:
16
+ "A versatile divider built on Radix UI Separator with four visual variants (primary, secondary, stylised, dashed), four size steps, and horizontal/vertical orientation. The stylised variant renders a decorative audio-bar icon, making it ideal for section breaks in audio streaming interfaces.",
97
17
  },
18
+ page: () => (
19
+ <AuralComponentDocsPage
20
+ features={[
21
+ {
22
+ title: "4 Visual Variants",
23
+ description: "Primary to stylised",
24
+ },
25
+ {
26
+ title: "Orientations",
27
+ description: "Horizontal or vertical",
28
+ },
29
+ {
30
+ title: "Size Steps",
31
+ description: "Hairline to bold",
32
+ },
33
+ ]}
34
+ />
35
+ ),
98
36
  },
99
37
  },
100
38
  tags: ["autodocs"],
@@ -102,7 +40,7 @@ export default function StylisedExample() {
102
40
  variant: {
103
41
  control: "select",
104
42
  options: ["primary", "secondary", "stylised", "dashed"],
105
- description: "The visual style of the divider",
43
+ description: "Visual style of the divider.",
106
44
  table: {
107
45
  type: { summary: "string" },
108
46
  defaultValue: { summary: "primary" },
@@ -111,7 +49,7 @@ export default function StylisedExample() {
111
49
  size: {
112
50
  control: "select",
113
51
  options: ["half_default", "full_default", "full_medium", "full_large"],
114
- description: "The size/thickness of the divider",
52
+ description: "Thickness / extent of the divider line.",
115
53
  table: {
116
54
  type: { summary: "string" },
117
55
  defaultValue: { summary: "full_default" },
@@ -120,7 +58,7 @@ export default function StylisedExample() {
120
58
  orientation: {
121
59
  control: "select",
122
60
  options: ["horizontal", "vertical"],
123
- description: "The orientation of the divider",
61
+ description: "Direction of the divider.",
124
62
  table: {
125
63
  type: { summary: "string" },
126
64
  defaultValue: { summary: "horizontal" },
@@ -129,7 +67,7 @@ export default function StylisedExample() {
129
67
  decorative: {
130
68
  control: "boolean",
131
69
  description:
132
- "Whether the Divider is decorative (hidden from screen readers)",
70
+ "When true the element is hidden from the accessibility tree.",
133
71
  table: {
134
72
  type: { summary: "boolean" },
135
73
  defaultValue: { summary: "true" },
@@ -137,18 +75,12 @@ export default function StylisedExample() {
137
75
  },
138
76
  className: {
139
77
  control: "text",
140
- description: "Additional CSS classes for custom styling",
141
- table: {
142
- type: { summary: "string" },
143
- },
78
+ description: "Extra classes applied to the separator element.",
144
79
  },
145
80
  wrapperClassName: {
146
81
  control: "text",
147
82
  description:
148
- "CSS classes for the wrapper element (used with stylised variant)",
149
- table: {
150
- type: { summary: "string" },
151
- },
83
+ "Extra classes applied to the outer wrapper (used by the stylised variant to position the audio-bar icon).",
152
84
  },
153
85
  },
154
86
  }
@@ -156,477 +88,299 @@ export default function StylisedExample() {
156
88
  export default meta
157
89
  type Story = StoryObj<typeof Divider>
158
90
 
159
- export const Primary: Story = {
160
- args: {
161
- variant: "primary",
162
- size: "full_default",
163
- className: "my-4 min-w-96",
164
- },
165
- parameters: {
166
- docs: {
167
- description: {
168
- story:
169
- "The default primary divider with medium opacity, perfect for standard content separation.",
170
- },
171
- },
172
- },
173
- }
91
+ // ─── 1. AllVariants ──────────────────────────────────────────────────────────
174
92
 
175
- export const Secondary: Story = {
176
- args: {
177
- variant: "secondary",
178
- size: "full_default",
179
- className: "my-4 min-w-96",
180
- },
181
- parameters: {
182
- docs: {
183
- description: {
184
- story:
185
- "A lighter secondary divider for subtle separations within grouped content.",
93
+ export const AllVariants: Story = {
94
+ render: () => {
95
+ const variants = [
96
+ {
97
+ key: "primary",
98
+ label: "Primary",
99
+ desc: "Standard line for main content separation",
186
100
  },
187
- },
188
- },
189
- }
190
-
191
- export const Dashed: Story = {
192
- args: {
193
- variant: "dashed",
194
- size: "full_default",
195
- className: "my-4 min-w-96",
196
- },
197
- parameters: {
198
- docs: {
199
- description: {
200
- story:
201
- "A dashed divider style perfect for indicating temporary or conditional separations.",
101
+ {
102
+ key: "secondary",
103
+ label: "Secondary",
104
+ desc: "Subtler line for related-content groups",
202
105
  },
203
- },
204
- },
205
- }
206
-
207
- export const Stylised: Story = {
208
- args: {
209
- variant: "stylised",
210
- size: "full_default",
211
- className: "my-4 min-w-96",
212
- },
213
- parameters: {
214
- docs: {
215
- description: {
216
- story:
217
- "A decorative divider with an audio bar icon, ideal for section breaks in audio/media interfaces.",
218
- },
219
- },
220
- },
221
- }
222
-
223
- export const SizeVariations: Story = {
224
- render: () => (
225
- <div className="bg-fm-surface-primary w-full max-w-2xl space-y-8 rounded-lg p-6">
226
- <div className="text-center">
227
- <h3 className="text-fm-primary mb-2 text-lg font-medium">
228
- Size Variations
229
- </h3>
230
- <p className="text-fm-secondary text-sm">
231
- Different thickness options for various use cases
232
- </p>
233
- </div>
234
-
235
- <div className="space-y-6">
236
- {(
237
- [
238
- {
239
- size: "half_default",
240
- label: "Half Default",
241
- description: "50% width, minimal thickness",
242
- },
243
- {
244
- size: "full_default",
245
- label: "Full Default",
246
- description: "Standard thickness for most use cases",
247
- },
248
- {
249
- size: "full_medium",
250
- label: "Full Medium",
251
- description: "Medium thickness for emphasis",
252
- },
253
- {
254
- size: "full_large",
255
- label: "Full Large",
256
- description: "Bold thickness for strong separation",
257
- },
258
- ] as const
259
- ).map((item) => (
260
- <div key={item.size} className="space-y-3">
261
- <div className="flex items-center justify-between">
262
- <h4 className="text-fm-primary text-sm font-medium">
263
- {item.label}
264
- </h4>
265
- <span className="text-fm-tertiary text-xs">
266
- {item.description}
267
- </span>
268
- </div>
269
- <Divider variant="primary" size={item.size} />
270
- </div>
271
- ))}
272
- </div>
273
- </div>
274
- ),
275
- parameters: {
276
- docs: {
277
- description: {
278
- story:
279
- "Comparison of all available size options for dividers, from subtle to prominent separations.",
106
+ {
107
+ key: "stylised",
108
+ label: "Stylised",
109
+ desc: "Decorative audio-bar accent for section breaks",
280
110
  },
281
- },
282
- },
283
- }
284
-
285
- export const VariantComparison: Story = {
286
- render: () => (
287
- <div className="bg-fm-surface-primary w-full max-w-2xl space-y-8 rounded-lg p-6">
288
- <div className="text-center">
289
- <h3 className="text-fm-primary mb-2 text-lg font-medium">
290
- Variant Comparison
291
- </h3>
292
- <p className="text-fm-secondary text-sm">
293
- Different visual styles for various design needs
294
- </p>
295
- </div>
296
-
297
- <div className="space-y-8">
298
- {(
299
- [
300
- {
301
- variant: "primary",
302
- label: "Primary",
303
- description: "Standard divider for main content separation",
304
- useCase: "Main sections, page content",
305
- },
306
- {
307
- variant: "secondary",
308
- label: "Secondary",
309
- description: "Subtle divider for related content groups",
310
- useCase: "Subsections, related items",
311
- },
312
- {
313
- variant: "dashed",
314
- label: "Dashed",
315
- description:
316
- "Dotted line for temporary or conditional separations",
317
- useCase: "Grouped items, optional content",
318
- },
319
- {
320
- variant: "stylised",
321
- label: "Stylised",
322
- description: "Decorative divider with audio bar icon",
323
- useCase: "Section breaks, audio interfaces",
324
- },
325
- ] as const
326
- ).map((item) => (
327
- <div key={item.variant} className="space-y-3">
328
- <div className="space-y-1">
329
- <h4 className="text-fm-primary text-sm font-medium">
330
- {item.label}
331
- </h4>
332
- <p className="text-fm-secondary text-xs">{item.description}</p>
333
- <p className="text-fm-tertiary text-xs">
334
- Use case: {item.useCase}
335
- </p>
336
- </div>
337
- <Divider variant={item.variant} size="full_default" />
338
- </div>
339
- ))}
340
- </div>
341
- </div>
342
- ),
343
- parameters: {
344
- docs: {
345
- description: {
346
- story:
347
- "Side-by-side comparison of all divider variants with their recommended use cases.",
111
+ {
112
+ key: "dashed",
113
+ label: "Dashed",
114
+ desc: "Soft dashed line for optional or conditional breaks",
348
115
  },
349
- },
350
- },
351
- }
116
+ ] as const
352
117
 
353
- export const DashedVariations: Story = {
354
- render: () => (
355
- <div className="bg-fm-surface-primary w-full max-w-2xl space-y-8 rounded-lg p-6">
356
- <div className="text-center">
357
- <h3 className="text-fm-primary mb-2 text-lg font-medium">
358
- Dashed Divider Variations
359
- </h3>
360
- <p className="text-fm-secondary text-sm">
361
- Different sizes and orientations of dashed dividers
362
- </p>
363
- </div>
364
-
365
- <div className="space-y-6">
118
+ return (
119
+ <div className="space-y-8" style={{ width: 560 }}>
120
+ {/* Horizontal */}
366
121
  <div>
367
- <h4 className="text-fm-primary mb-4 text-sm font-medium">
368
- Horizontal Dashed
122
+ <h4 className="text-fm-secondary font-fm-text text-fm-md leading-fm-md mb-4 font-medium">
123
+ Horizontal
369
124
  </h4>
370
- <div className="space-y-4">
371
- {(
372
- [
373
- { size: "half_default", label: "Half Width" },
374
- { size: "full_default", label: "Full Width" },
375
- { size: "full_medium", label: "Medium Thickness" },
376
- { size: "full_large", label: "Large Thickness" },
377
- ] as const
378
- ).map((item) => (
379
- <div key={item.size} className="space-y-2">
380
- <span className="text-fm-secondary text-xs">{item.label}</span>
381
- <Divider variant="dashed" size={item.size} />
125
+ <div className="space-y-6">
126
+ {variants.map(({ key, label, desc }) => (
127
+ <div key={key} className="space-y-2 text-center">
128
+ <Divider
129
+ variant={key}
130
+ size="full_default"
131
+ orientation="horizontal"
132
+ />
133
+ <p className="text-fm-secondary font-fm-text text-fm-sm leading-fm-sm">
134
+ {label} {desc}
135
+ </p>
382
136
  </div>
383
137
  ))}
384
138
  </div>
385
139
  </div>
386
140
 
141
+ {/* Vertical */}
387
142
  <div>
388
- <h4 className="text-fm-primary mb-4 text-sm font-medium">
389
- Vertical Dashed
143
+ <h4 className="text-fm-secondary font-fm-text text-fm-md leading-fm-md mb-4 font-medium">
144
+ Vertical
390
145
  </h4>
391
- <div className="flex h-16 items-center gap-6">
392
- {(
393
- [
394
- { size: "half_default", label: "Half" },
395
- { size: "full_default", label: "Full" },
396
- { size: "full_medium", label: "Medium" },
397
- { size: "full_large", label: "Large" },
398
- ] as const
399
- ).map((item) => (
400
- <div key={item.size} className="flex flex-col items-center gap-2">
401
- <span className="text-fm-secondary text-xs">{item.label}</span>
402
- <Divider
403
- variant="dashed"
404
- size={item.size}
405
- orientation="vertical"
406
- className="h-12"
407
- />
146
+ <div className="flex flex-wrap items-center justify-center gap-10">
147
+ {variants.map(({ key, label }) => (
148
+ <div key={key} className="space-y-2 text-center">
149
+ <div className="flex h-16 items-center justify-center">
150
+ <Divider
151
+ variant={key}
152
+ size="full_default"
153
+ orientation="vertical"
154
+ className="h-12"
155
+ />
156
+ </div>
157
+ <p className="text-fm-secondary font-fm-text text-fm-sm leading-fm-sm">
158
+ {label}
159
+ </p>
408
160
  </div>
409
161
  ))}
410
162
  </div>
411
163
  </div>
412
164
  </div>
413
- </div>
414
- ),
165
+ )
166
+ },
415
167
  parameters: {
416
168
  docs: {
417
169
  description: {
418
170
  story:
419
- "Comprehensive showcase of dashed divider options in both horizontal and vertical orientations.",
171
+ "Full matrix of all four variants in both horizontal and vertical orientations, each with a short label describing its intended use.",
420
172
  },
421
173
  },
422
174
  },
423
175
  }
424
176
 
425
- export const OrientationExample: Story = {
426
- render: () => (
427
- <div className="bg-fm-surface-primary w-full max-w-2xl space-y-8 rounded-lg p-6">
428
- <div className="text-center">
429
- <h3 className="text-fm-primary mb-2 text-lg font-medium">
430
- Orientation Examples
431
- </h3>
432
- <p className="text-fm-secondary text-sm">
433
- Horizontal and vertical divider usage in layouts
434
- </p>
435
- </div>
177
+ // ─── 2. Sizes ────────────────────────────────────────────────────────────────
436
178
 
437
- <div className="space-y-8">
438
- {/* Horizontal Example */}
439
- <div className="space-y-4">
440
- <h4 className="text-fm-primary text-sm font-medium">
441
- Horizontal Dividers
179
+ export const Sizes: Story = {
180
+ render: () => {
181
+ const sizes = [
182
+ {
183
+ key: "half_default",
184
+ label: "Half Default",
185
+ sub: "50% width · hairline",
186
+ },
187
+ {
188
+ key: "full_default",
189
+ label: "Full Default",
190
+ sub: "100% width · hairline",
191
+ },
192
+ {
193
+ key: "full_medium",
194
+ label: "Full Medium",
195
+ sub: "100% width · 4 px",
196
+ },
197
+ {
198
+ key: "full_large",
199
+ label: "Full Large",
200
+ sub: "100% width · 8 px",
201
+ },
202
+ ] as const
203
+
204
+ return (
205
+ <div className="space-y-8" style={{ width: 520 }}>
206
+ {/* Horizontal sizes */}
207
+ <div>
208
+ <h4 className="text-fm-secondary font-fm-text text-fm-md leading-fm-md mb-4 font-medium">
209
+ Horizontal — primary variant
442
210
  </h4>
443
- <div className="bg-fm-surface-secondary space-y-4 rounded-lg p-4">
444
- <div className="text-fm-tertiary text-sm">
445
- Section A: User Profile
446
- </div>
447
- <Divider variant="primary" />
448
- <div className="text-fm-tertiary text-sm">
449
- Section B: Account Settings
450
- </div>
451
- <Divider variant="dashed" />
452
- <div className="text-fm-tertiary text-sm">
453
- Section C: Privacy Options
454
- </div>
211
+ <div className="space-y-6">
212
+ {sizes.map(({ key, label, sub }) => (
213
+ <div key={key} className="space-y-2 text-center">
214
+ <Divider
215
+ variant="primary"
216
+ size={key}
217
+ orientation="horizontal"
218
+ />
219
+ <p className="text-fm-secondary font-fm-text text-fm-sm leading-fm-sm">
220
+ {label}
221
+ <span className="text-fm-tertiary"> {sub}</span>
222
+ </p>
223
+ </div>
224
+ ))}
455
225
  </div>
456
226
  </div>
457
227
 
458
- {/* Vertical Example */}
459
- <div className="space-y-4">
460
- <h4 className="text-fm-primary text-sm font-medium">
461
- Vertical Dividers
228
+ {/* Vertical sizes */}
229
+ <div>
230
+ <h4 className="text-fm-secondary font-fm-text text-fm-md leading-fm-md mb-4 font-medium">
231
+ Vertical — primary variant
462
232
  </h4>
463
- <div className="bg-fm-surface-secondary flex items-center gap-6 rounded-lg p-4">
464
- <div className="text-fm-tertiary text-sm">Profile</div>
465
- <Divider variant="primary" orientation="vertical" className="h-8" />
466
- <div className="text-fm-tertiary text-sm">Settings</div>
467
- <Divider variant="dashed" orientation="vertical" className="h-8" />
468
- <div className="text-fm-tertiary text-sm">Help</div>
469
- <Divider
470
- variant="secondary"
471
- orientation="vertical"
472
- className="h-8"
473
- />
474
- <div className="text-fm-tertiary text-sm">Logout</div>
233
+ <div className="flex flex-wrap items-end justify-center gap-8">
234
+ {sizes.map(({ key, label }) => (
235
+ <div key={key} className="space-y-2 text-center">
236
+ <div className="flex h-20 items-center justify-center">
237
+ <Divider
238
+ variant="primary"
239
+ size={key}
240
+ orientation="vertical"
241
+ className="h-full"
242
+ />
243
+ </div>
244
+ <p className="text-fm-secondary font-fm-text text-fm-sm leading-fm-sm">
245
+ {label}
246
+ </p>
247
+ </div>
248
+ ))}
475
249
  </div>
476
250
  </div>
477
251
  </div>
478
- </div>
479
- ),
252
+ )
253
+ },
480
254
  parameters: {
481
255
  docs: {
482
256
  description: {
483
257
  story:
484
- "Real-world examples showing how to use dividers in both horizontal and vertical layouts.",
258
+ "Side-by-side size comparison for both orientations, from the hairline default to the bold large variant.",
485
259
  },
486
260
  },
487
261
  },
488
262
  }
489
263
 
490
- export const RealWorldUsage: Story = {
491
- render: () => (
492
- <div className="bg-fm-surface-primary w-full max-w-4xl space-y-8 rounded-lg p-6">
493
- <div className="text-center">
494
- <h3 className="text-fm-primary mb-2 text-lg font-medium">
495
- Real World Usage
496
- </h3>
497
- <p className="text-fm-secondary text-sm">
498
- Practical examples in common UI patterns
499
- </p>
500
- </div>
264
+ // ─── 3. UseCases ─────────────────────────────────────────────────────────────
501
265
 
502
- <div className="grid grid-cols-1 gap-8 md:grid-cols-2">
503
- {/* Card Layout */}
504
- <div className="space-y-4">
505
- <h4 className="text-fm-primary text-sm font-medium">Card Layout</h4>
506
- <div className="bg-fm-surface-secondary space-y-4 rounded-lg p-4">
507
- <div className="flex items-center gap-3">
508
- <div className="h-10 w-10 rounded-full bg-blue-600"></div>
509
- <div>
510
- <div className="text-fm-primary text-sm font-medium">
511
- John Doe
512
- </div>
513
- <div className="text-fm-secondary text-xs">
514
- Product Designer
515
- </div>
516
- </div>
517
- </div>
518
- <Divider variant="dashed" />
519
- <div className="text-fm-tertiary text-sm">
520
- Passionate about creating intuitive user experiences and
521
- innovative design solutions.
522
- </div>
523
- <Divider variant="secondary" />
524
- <div className="text-fm-secondary flex gap-4 text-xs">
525
- <span>Joined: Jan 2024</span>
526
- <span>Projects: 12</span>
266
+ export const UseCases: Story = {
267
+ render: () => (
268
+ <div className="mx-auto max-w-3xl space-y-8 p-8">
269
+ {/* Podcast episode card */}
270
+ <div>
271
+ <h4 className="text-fm-secondary font-fm-text text-fm-md leading-fm-md mb-4 font-medium">
272
+ Podcast episode card
273
+ </h4>
274
+ <div className="border-fm-divider-secondary bg-fm-surface-secondary mx-auto max-w-md space-y-4 rounded-xl border p-5">
275
+ <div className="flex items-center gap-3">
276
+ <div className="bg-fm-surface-tertiary h-12 w-12 shrink-0 rounded-lg" />
277
+ <div>
278
+ <p className="text-fm-primary font-fm-brand text-fm-md leading-fm-md font-semibold">
279
+ The Sound Lab · Ep. 42
280
+ </p>
281
+ <p className="text-fm-tertiary font-fm-text text-fm-sm leading-fm-sm">
282
+ 45 min · Anya Reeves
283
+ </p>
527
284
  </div>
528
285
  </div>
286
+ <Divider variant="secondary" size="full_default" />
287
+ <p className="text-fm-secondary font-fm-text text-fm-sm leading-fm-sm">
288
+ Mixing live orchestral recordings, spatial audio formats, and the
289
+ future of independent streaming.
290
+ </p>
291
+ <Divider variant="dashed" size="full_default" />
292
+ <div className="flex items-center justify-between">
293
+ <span className="text-fm-tertiary font-fm-text text-fm-sm leading-fm-sm">
294
+ 2.4k plays
295
+ </span>
296
+ <span className="text-fm-tertiary font-fm-text text-fm-sm leading-fm-sm">
297
+ ★ 4.9
298
+ </span>
299
+ </div>
529
300
  </div>
301
+ </div>
530
302
 
531
- {/* Navigation Layout */}
532
- <div className="space-y-4">
533
- <h4 className="text-fm-primary text-sm font-medium">
534
- Navigation Menu
535
- </h4>
536
- <div className="bg-fm-surface-secondary space-y-3 rounded-lg p-4">
537
- <div className="text-fm-primary cursor-pointer text-sm hover:text-blue-400">
538
- Dashboard
539
- </div>
540
- <Divider variant="secondary" />
541
- <div className="text-fm-primary cursor-pointer text-sm hover:text-blue-400">
542
- Projects
543
- </div>
544
- <Divider variant="secondary" />
545
- <div className="text-fm-primary cursor-pointer text-sm hover:text-blue-400">
546
- Team
547
- </div>
548
- <Divider variant="dashed" />
549
- <div className="text-fm-primary cursor-pointer text-sm hover:text-blue-400">
550
- Settings
551
- </div>
552
- <Divider variant="primary" />
553
- <div className="cursor-pointer text-sm text-red-400 hover:text-red-300">
554
- Logout
555
- </div>
303
+ {/* Section break with stylised divider */}
304
+ <div>
305
+ <h4 className="text-fm-secondary font-fm-text text-fm-md leading-fm-md mb-4 font-medium">
306
+ Section break — stylised
307
+ </h4>
308
+ <div className="mx-auto max-w-md space-y-4">
309
+ <div className="space-y-2">
310
+ <p className="text-fm-primary font-fm-brand text-fm-md leading-fm-md font-semibold">
311
+ Featured Releases
312
+ </p>
313
+ <p className="text-fm-secondary font-fm-text text-fm-sm leading-fm-sm">
314
+ New albums curated by Aural editors this week.
315
+ </p>
316
+ </div>
317
+ <Divider variant="stylised" size="full_default" />
318
+ <div className="space-y-2">
319
+ <p className="text-fm-primary font-fm-brand text-fm-md leading-fm-md font-semibold">
320
+ Trending Now
321
+ </p>
322
+ <p className="text-fm-secondary font-fm-text text-fm-sm leading-fm-sm">
323
+ Tracks climbing the charts across all genres.
324
+ </p>
556
325
  </div>
557
326
  </div>
327
+ </div>
558
328
 
559
- {/* Timeline Layout */}
560
- <div className="space-y-4">
561
- <h4 className="text-fm-primary text-sm font-medium">
562
- Content Timeline
563
- </h4>
564
- <div className="bg-fm-surface-secondary space-y-4 rounded-lg p-4">
565
- <div className="space-y-2">
566
- <div className="text-fm-primary text-sm font-medium">
567
- Project Started
568
- </div>
569
- <div className="text-fm-secondary text-xs">
570
- Initial setup and planning phase
571
- </div>
572
- </div>
573
- <Divider variant="stylised" />
574
- <div className="space-y-2">
575
- <div className="text-fm-primary text-sm font-medium">
576
- Development Phase
577
- </div>
578
- <div className="text-fm-secondary text-xs">
579
- Core features implementation
580
- </div>
581
- </div>
582
- <Divider variant="dashed" />
583
- <div className="space-y-2">
584
- <div className="text-fm-primary text-sm font-medium">
585
- Testing & QA
586
- </div>
587
- <div className="text-fm-secondary text-xs">
588
- Quality assurance and bug fixes
589
- </div>
590
- </div>
329
+ {/* Inline toolbar with vertical dividers */}
330
+ <div>
331
+ <h4 className="text-fm-secondary font-fm-text text-fm-md leading-fm-md mb-4 font-medium">
332
+ Player toolbar — vertical dividers
333
+ </h4>
334
+ <div className="border-fm-divider-secondary bg-fm-surface-secondary mx-auto max-w-md rounded-xl border px-5 py-3">
335
+ <div className="flex items-center gap-4">
336
+ <button className="text-fm-tertiary font-fm-text text-fm-sm leading-fm-sm hover:text-fm-primary cursor-pointer outline-none">
337
+ Queue
338
+ </button>
339
+ <Divider
340
+ variant="secondary"
341
+ orientation="vertical"
342
+ className="h-5"
343
+ />
344
+ <button className="text-fm-tertiary font-fm-text text-fm-sm leading-fm-sm hover:text-fm-primary cursor-pointer outline-none">
345
+ Lyrics
346
+ </button>
347
+ <Divider variant="dashed" orientation="vertical" className="h-5" />
348
+ <button className="text-fm-tertiary font-fm-text text-fm-sm leading-fm-sm hover:text-fm-primary cursor-pointer outline-none">
349
+ Related
350
+ </button>
351
+ <Divider variant="primary" orientation="vertical" className="h-5" />
352
+ <button className="text-fm-tertiary font-fm-text text-fm-sm leading-fm-sm hover:text-fm-primary cursor-pointer outline-none">
353
+ Share
354
+ </button>
591
355
  </div>
592
356
  </div>
357
+ </div>
593
358
 
594
- {/* Toolbar Layout */}
595
- <div className="space-y-4">
596
- <h4 className="text-fm-primary text-sm font-medium">
597
- Toolbar Actions
598
- </h4>
599
- <div className="bg-fm-surface-secondary rounded-lg p-4">
600
- <div className="flex items-center gap-4">
601
- <button className="text-fm-tertiary hover:text-fm-primary text-sm">
602
- Edit
603
- </button>
604
- <Divider
605
- variant="secondary"
606
- orientation="vertical"
607
- className="h-6"
608
- />
609
- <button className="text-fm-tertiary hover:text-fm-primary text-sm">
610
- Share
611
- </button>
612
- <Divider
613
- variant="dashed"
614
- orientation="vertical"
615
- className="h-6"
616
- />
617
- <button className="text-fm-tertiary hover:text-fm-primary text-sm">
618
- Export
619
- </button>
620
- <Divider
621
- variant="primary"
622
- orientation="vertical"
623
- className="h-6"
624
- />
625
- <button className="text-sm text-red-400 hover:text-red-300">
626
- Delete
627
- </button>
628
- </div>
629
- </div>
359
+ {/* Artist profile settings panel */}
360
+ <div>
361
+ <h4 className="text-fm-secondary font-fm-text text-fm-md leading-fm-md mb-4 font-medium">
362
+ Settings panel — grouped sections
363
+ </h4>
364
+ <div className="border-fm-divider-secondary bg-fm-surface-secondary mx-auto max-w-md space-y-3 rounded-xl border p-5">
365
+ <p className="text-fm-primary font-fm-brand text-fm-md leading-fm-md font-semibold">
366
+ Account
367
+ </p>
368
+ <Divider variant="primary" size="full_default" />
369
+ <p className="text-fm-secondary font-fm-text text-fm-sm leading-fm-sm">
370
+ Profile · Subscription · Billing
371
+ </p>
372
+ <Divider variant="secondary" size="full_default" />
373
+ <p className="text-fm-primary font-fm-brand text-fm-md leading-fm-md font-semibold">
374
+ Playback
375
+ </p>
376
+ <Divider variant="primary" size="full_default" />
377
+ <p className="text-fm-secondary font-fm-text text-fm-sm leading-fm-sm">
378
+ Audio quality · Downloads · Crossfade
379
+ </p>
380
+ <Divider variant="dashed" size="full_default" />
381
+ <p className="text-fm-tertiary font-fm-text text-fm-sm leading-fm-sm">
382
+ Advanced settings
383
+ </p>
630
384
  </div>
631
385
  </div>
632
386
  </div>
@@ -635,24 +389,7 @@ export const RealWorldUsage: Story = {
635
389
  docs: {
636
390
  description: {
637
391
  story:
638
- "Real-world UI patterns showing effective use of different divider variants in common interface layouts.",
639
- },
640
- },
641
- },
642
- }
643
-
644
- export const InteractivePlayground: Story = {
645
- args: {
646
- variant: "primary",
647
- size: "full_default",
648
- orientation: "horizontal",
649
- className: "my-4 min-w-96",
650
- },
651
- parameters: {
652
- docs: {
653
- description: {
654
- story:
655
- "Interactive playground to experiment with all divider properties and see live changes.",
392
+ "Real-world scenarios from an audio streaming context: episode cards, stylised section breaks, inline player toolbars with vertical dividers, and a settings panel with grouped sections.",
656
393
  },
657
394
  },
658
395
  },