aural-ui 4.0.1 → 4.2.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 (175) hide show
  1. package/README.md +8 -1
  2. package/dist/components/aspect-ratio/AspectRatio.stories.tsx +290 -1228
  3. package/dist/components/avatar/Avatar.stories.tsx +219 -235
  4. package/dist/components/badge/Badge.stories.tsx +379 -116
  5. package/dist/components/banner/Banner.stories.tsx +445 -391
  6. package/dist/components/breadcrumb/Breadcrumb.stories.tsx +453 -199
  7. package/dist/components/button/Button.stories.tsx +585 -230
  8. package/dist/components/card/Card.stories.tsx +619 -301
  9. package/dist/components/char-count/CharCount.stories.tsx +350 -248
  10. package/dist/components/checkbox/Checkbox.stories.tsx +309 -167
  11. package/dist/components/chip/Chip.stories.tsx +362 -168
  12. package/dist/components/circular-loader/CircularLoader.stories.tsx +221 -636
  13. package/dist/components/clamp-lines/ClampLines.stories.tsx +246 -117
  14. package/dist/components/collapsible/Collapsible.stories.tsx +391 -252
  15. package/dist/components/command/Command.stories.tsx +530 -867
  16. package/dist/components/dialog/Dialog.stories.tsx +501 -950
  17. package/dist/components/divider/Divider.stories.tsx +264 -527
  18. package/dist/components/dot-loader/DotLoader.stories.tsx +256 -257
  19. package/dist/components/drawer/Drawer.stories.tsx +659 -1023
  20. package/dist/components/dropdown/Dropdown.stories.tsx +643 -1028
  21. package/dist/components/form/Form.stories.tsx +560 -274
  22. package/dist/components/helper-text/HelperText.stories.tsx +199 -200
  23. package/dist/components/hover-card/HoverCard.stories.tsx +318 -1254
  24. package/dist/components/icon-button/IconButton.stories.tsx +837 -194
  25. package/dist/components/if-else/if-else.stories.tsx +370 -83
  26. package/dist/components/input/Input.stories.tsx +436 -368
  27. package/dist/components/label/Label.stories.tsx +156 -154
  28. package/dist/components/list/List.stories.tsx +484 -835
  29. package/dist/components/marquee/Marquee.stories.tsx +356 -712
  30. package/dist/components/otp-inputs/OtpInputs.stories.tsx +352 -422
  31. package/dist/components/overlay/Overlay.stories.tsx +452 -824
  32. package/dist/components/pagination/Pagination.stories.tsx +721 -210
  33. package/dist/components/popover/Popover.stories.tsx +481 -896
  34. package/dist/components/radio/Radio.stories.tsx +432 -124
  35. package/dist/components/resizable/Resizable.stories.tsx +495 -799
  36. package/dist/components/scroll-area/ScrollArea.stories.tsx +383 -1059
  37. package/dist/components/search/Search.stories.tsx +312 -595
  38. package/dist/components/select/Select.stories.tsx +684 -789
  39. package/dist/components/sheet/Sheet.stories.tsx +671 -950
  40. package/dist/components/skelton/Skelton.stories.tsx +230 -764
  41. package/dist/components/slider/Slider.stories.tsx +383 -760
  42. package/dist/components/stepper/Stepper.stories.tsx +371 -514
  43. package/dist/components/switch/Switch.stories.tsx +461 -208
  44. package/dist/components/switch-case/SwitchCase.stories.tsx +367 -188
  45. package/dist/components/table/Table.stories.tsx +770 -916
  46. package/dist/components/tabs/Tabs.stories.tsx +458 -1455
  47. package/dist/components/tag/Tag.stories.tsx +714 -542
  48. package/dist/components/textarea/TextArea.stories.tsx +621 -562
  49. package/dist/components/thumbnail-tags/ThumbnailTags.stories.tsx +228 -154
  50. package/dist/components/toast/Toast.stories.tsx +452 -1339
  51. package/dist/components/toggle/Toggle.stories.tsx +488 -931
  52. package/dist/components/tooltip/Tooltip.stories.tsx +344 -1388
  53. package/dist/components/typography/Typography.stories.tsx +406 -89
  54. package/dist/hooks/use-change-state/UseChangeState.stories.tsx +309 -606
  55. package/dist/hooks/use-previous/UsePrevious.stories.tsx +367 -917
  56. package/dist/hooks/use-standalone-pagination/UseStandalonePagination.stories.tsx +639 -867
  57. package/dist/icons/Icons.stories.tsx +0 -12
  58. package/dist/icons/ai-avatar-icon/AiAvatarIcon.stories.tsx +223 -1060
  59. package/dist/icons/alert-icon/AlertIcon.stories.tsx +106 -968
  60. package/dist/icons/all-icons.tsx +37 -16
  61. package/dist/icons/angle-down-icon/AngleDownIcon.stories.tsx +137 -1010
  62. package/dist/icons/apple-logo-icon/AppleLogoIcon.stories.tsx +145 -935
  63. package/dist/icons/arrow-box-left-icon/ArrowBoxLeftIcon.stories.tsx +132 -1046
  64. package/dist/icons/arrow-corner-up-left-icon/ArrowCornerUpLeftIcon.stories.tsx +134 -986
  65. package/dist/icons/arrow-corner-up-right-icon/ArrowCornerUpRightIcon.stories.tsx +135 -1028
  66. package/dist/icons/arrow-left-icon/ArrowLeftIcon.stories.tsx +133 -971
  67. package/dist/icons/arrow-right-icon/ArrowRightIcon.stories.tsx +145 -1123
  68. package/dist/icons/arrow-right-up-icon/ArrowRightUpIcon.stories.tsx +143 -1252
  69. package/dist/icons/art-board-icon/ArtBoardIcon.stories.tsx +123 -632
  70. package/dist/icons/audio-bar-icon/AudioBarIcon.stories.tsx +141 -1223
  71. package/dist/icons/backward-ten-seconds-icon/BackwardTenSecondsIcon.stories.tsx +164 -1018
  72. package/dist/icons/bubble-check-icon/BubbleCheckIcon.stories.tsx +121 -1236
  73. package/dist/icons/bubble-crossed-icon/BubbleCrossedIcon.stories.tsx +121 -1213
  74. package/dist/icons/bubble-sparkle-icon/BubbleSparkleIcon.stories.tsx +116 -893
  75. package/dist/icons/camera-icon/CameraIcon.stories.tsx +109 -1254
  76. package/dist/icons/capital-a-letter-icon/CapitalALetterIcon.stories.tsx +114 -975
  77. package/dist/icons/chevron-double-left-icon/ChevronDoubleLeftIcon.stories.tsx +157 -994
  78. package/dist/icons/chevron-double-right-icon/ChevronDoubleRightIcon.stories.tsx +160 -992
  79. package/dist/icons/chevron-down-icon/ChevronDownIcon.stories.tsx +140 -970
  80. package/dist/icons/chevron-left-icon/ChevronLeftIcon.stories.tsx +126 -993
  81. package/dist/icons/chevron-right-icon/ChevronRightIcon.stories.tsx +144 -987
  82. package/dist/icons/chevron-up-icon/ChevronUpIcon.stories.tsx +141 -1007
  83. package/dist/icons/circle-tick-icon/CircleTickIcon.stories.tsx +147 -1187
  84. package/dist/icons/circular-play-icon/CircularPlayIcon.stories.tsx +110 -476
  85. package/dist/icons/coin-icon/CoinIcon.stories.tsx +120 -1364
  86. package/dist/icons/coin-toons-icon/CoinToonsIcon.stories.tsx +113 -1360
  87. package/dist/icons/column-wide-add-icon/ColumnWideAddIcon.stories.tsx +111 -942
  88. package/dist/icons/command-icon/CommandIcon.stories.tsx +124 -1087
  89. package/dist/icons/copy-icon/CopyIcon.stories.tsx +119 -996
  90. package/dist/icons/cross-circle-icon/CrossCircleIcon.stories.tsx +144 -1046
  91. package/dist/icons/cross-icon/CrossIcon.stories.tsx +136 -999
  92. package/dist/icons/download-icon/DownloadIcon.stories.tsx +123 -857
  93. package/dist/icons/edit-big-icon/EditBigIcon.stories.tsx +121 -1080
  94. package/dist/icons/email-icon/EmailIcon.stories.tsx +112 -979
  95. package/dist/icons/expand-icon/ExpandIcon.stories.tsx +109 -1146
  96. package/dist/icons/eye-close-icon/EyeCloseIcon.stories.tsx +141 -1068
  97. package/dist/icons/eye-open-icon/EyeOpenIcon.stories.tsx +140 -1081
  98. package/dist/icons/feature-shine-icon/FeatureShineIcon.stories.tsx +124 -1050
  99. package/dist/icons/file-chart-icon/FileChartIcon.stories.tsx +123 -1091
  100. package/dist/icons/file-text-icon/FileTextIcon.stories.tsx +122 -633
  101. package/dist/icons/filter-bar-row-icon/FilterBarRowIcon.stories.tsx +116 -1087
  102. package/dist/icons/forward-ten-seconds-icon/ForwardTenSecondsIcon.stories.tsx +166 -1020
  103. package/dist/icons/git-branch-icon/GitBranchIcon.stories.tsx +112 -1182
  104. package/dist/icons/git-fork-icon/GitForkIcon.stories.tsx +112 -1155
  105. package/dist/icons/globe-icon/GlobeIcon.stories.tsx +127 -325
  106. package/dist/icons/google-logo-icon/GoogleLogoIcon.stories.tsx +142 -985
  107. package/dist/icons/grip-vertical-icon/GripVerticalIcon.stories.tsx +116 -1217
  108. package/dist/icons/head-icon/HeadIcon.stories.tsx +108 -953
  109. package/dist/icons/heart-icon/HeartIcon.stories.tsx +117 -1060
  110. package/dist/icons/image-avatar-sparkle-icon/ImageAvatarSparkleIcon.stories.tsx +116 -716
  111. package/dist/icons/image-icon/ImageIcon.stories.tsx +102 -1164
  112. package/dist/icons/import-folder-icon/ImportFolderIcon.stories.tsx +108 -1233
  113. package/dist/icons/import-left-arrow-folder-icon/ImportLeftArrowFolderIcon.stories.tsx +133 -1289
  114. package/dist/icons/indian-flag-icon/IndianFlagIcon.stories.tsx +155 -1012
  115. package/dist/icons/instagram-icon/InstagramIcon.stories.tsx +158 -1438
  116. package/dist/icons/layout-column-icon/LayoutColumnIcon.stories.tsx +121 -1011
  117. package/dist/icons/layout-left-icon/LayoutLeftIcon.stories.tsx +116 -981
  118. package/dist/icons/layout-right-icon/LayoutRightIcon.stories.tsx +116 -979
  119. package/dist/icons/light-bulb-simple-icon/LightBulbSimpleIcon.stories.tsx +105 -1252
  120. package/dist/icons/linked-in-icon/LinkedInIcon.stories.tsx +151 -1554
  121. package/dist/icons/magic-book-icon/MagicBookIcon.stories.tsx +107 -1227
  122. package/dist/icons/magic-edit-icon/MagicEditIcon.stories.tsx +116 -707
  123. package/dist/icons/maintenance-icon/MaintenanceIcon.stories.tsx +119 -1226
  124. package/dist/icons/message-icon/MessageIcon.stories.tsx +111 -557
  125. package/dist/icons/minimize-icon/MinimizeIcon.stories.tsx +112 -1198
  126. package/dist/icons/moon-icon/MoonIcon.stories.tsx +117 -557
  127. package/dist/icons/move-horizontal-icon/MoveHorizontalIcon.stories.tsx +106 -1235
  128. package/dist/icons/move-vertical-icon/MoveVerticalIcon.stories.tsx +112 -1185
  129. package/dist/icons/musical-note-icon/MusicalNoteIcon.stories.tsx +116 -1012
  130. package/dist/icons/notepad-icon/NotepadIcon.stories.tsx +108 -1137
  131. package/dist/icons/notes-icon/NotesIcon.stories.tsx +116 -1138
  132. package/dist/icons/page-search-icon/PageSearchIcon.stories.tsx +106 -1146
  133. package/dist/icons/page-text-icon/PageTextIcon.stories.tsx +119 -719
  134. package/dist/icons/paint-roll-icon/PaintRollIcon.stories.tsx +110 -999
  135. package/dist/icons/paper-plane-icon/PaperPlaneIcon.stories.tsx +109 -912
  136. package/dist/icons/pause-icon/PauseIcon.stories.tsx +110 -1041
  137. package/dist/icons/pencil-icon/PencilIcon.stories.tsx +112 -1109
  138. package/dist/icons/phone-icon/PhoneIcon.stories.tsx +112 -1023
  139. package/dist/icons/plus-icon/PlusIcon.stories.tsx +103 -1132
  140. package/dist/icons/pocket-studio-icon/PocketStudioIcon.stories.tsx +104 -870
  141. package/dist/icons/scroll-down-icon/ScrollDownIcon.stories.tsx +99 -476
  142. package/dist/icons/search-icon/SearchIcon.stories.tsx +108 -1161
  143. package/dist/icons/setting-icon/SettingIcon.stories.tsx +104 -1009
  144. package/dist/icons/share-icon/ShareIcon.stories.tsx +117 -1064
  145. package/dist/icons/shield-icon/ShieldIcon.stories.tsx +114 -974
  146. package/dist/icons/site-logo-icon/SiteLogoIcon.stories.tsx +134 -1160
  147. package/dist/icons/skip-backward-icon/SkipBackwardIcon.stories.tsx +169 -1017
  148. package/dist/icons/skip-forward-icon/SkipForwardIcon.stories.tsx +161 -1016
  149. package/dist/icons/sparkles-soft-icon/SparklesSoftIcon.stories.tsx +102 -1001
  150. package/dist/icons/spinner-gradient-icon/SpinnerGradientIcon.stories.tsx +155 -593
  151. package/dist/icons/spinner-solid-icon/SpinnerSolidIcon.stories.tsx +155 -608
  152. package/dist/icons/spinner-solid-neutral-icon/SpinnerSolidINeutralcon.stories.tsx +142 -712
  153. package/dist/icons/star-icon/StarIcon.stories.tsx +120 -946
  154. package/dist/icons/store-coin-icon/StoreCoinIcon.stories.tsx +109 -1013
  155. package/dist/icons/suggestion-icon/SuggestionIcon.stories.tsx +113 -891
  156. package/dist/icons/sun-icon/SunIcon.stories.tsx +117 -864
  157. package/dist/icons/text-color-icon/TextColorIcon.stories.tsx +113 -989
  158. package/dist/icons/text-indicator-icon/TextIndicatorIcon.stories.tsx +120 -1027
  159. package/dist/icons/threads-icon/ThreadsIcon.stories.tsx +153 -1476
  160. package/dist/icons/tick-circle-icon/TickCircleIcon.stories.tsx +143 -1187
  161. package/dist/icons/tick-icon/TickIcon.stories.tsx +142 -1322
  162. package/dist/icons/trash-icon/TrashIcon.stories.tsx +105 -970
  163. package/dist/icons/twitter-x-icon/TwitterXIcon.stories.tsx +154 -1457
  164. package/dist/icons/upload-icon/UploadIcon.stories.tsx +112 -930
  165. package/dist/icons/vertical-menu-icon/VerticalMenuIcon.stories.tsx +115 -1019
  166. package/dist/icons/video-play-list-icon/VideoPlaylistIcon.stories.tsx +122 -1092
  167. package/dist/icons/voice-playing-icon/VoicePlayingIcon.stories.tsx +120 -1401
  168. package/dist/icons/volume-full-icon/VolumeFullIcon.stories.tsx +107 -1212
  169. package/dist/icons/volume-half-icon/VolumeHalfIcon.stories.tsx +109 -1122
  170. package/dist/icons/volume-off-icon/VolumeOffIcon.stories.tsx +112 -1124
  171. package/dist/icons/warning-icon/WarningIcon.stories.tsx +119 -1083
  172. package/dist/icons/youtube-icon/YoutubeIcon.stories.tsx +158 -983
  173. package/dist/index.cjs +90 -90
  174. package/dist/index.js +90 -90
  175. package/package.json +8 -3
@@ -1,6 +1,21 @@
1
1
  import React from "react"
2
2
  import type { Meta, StoryObj } from "@storybook/react-vite"
3
3
 
4
+ import { BackwardTenSecondsIcon } from "src/ui/icons/backward-ten-seconds-icon"
5
+ import { PauseIcon } from "src/ui/icons/pause-icon"
6
+ import { SkipBackwardIcon } from "src/ui/icons/skip-backward-icon"
7
+ import { SkipForwardIcon } from "src/ui/icons/skip-forward-icon"
8
+ import {
9
+ IconColorVariations,
10
+ IconDefaultCanvas,
11
+ IconDirectionalVariations,
12
+ IconPlaygroundCanvas,
13
+ IconSizeVariations,
14
+ IconUsageCanvas,
15
+ IconUsageSection,
16
+ } from "src/ui/story-spec/icons/icon-story-canvas"
17
+ import { AuralIconDocsPage } from "src/ui/story-spec/icons/icon-story-docs-page"
18
+
4
19
  import { ForwardTenSecondsIcon } from "."
5
20
 
6
21
  const meta: Meta<typeof ForwardTenSecondsIcon> = {
@@ -18,877 +33,71 @@ const meta: Meta<typeof ForwardTenSecondsIcon> = {
18
33
  },
19
34
  docs: {
20
35
  page: () => (
21
- <>
22
- {/* Override default docs styling */}
23
- <style>
24
- {`
25
- .sbdocs-wrapper {
26
- padding: 0 ;
27
- max-width: none ;
28
- background: transparent ;
29
- }
30
- .sbdocs-content {
31
- max-width: none ;
32
- padding: 0 ;
33
- margin: 0 ;
34
- background: transparent ;
35
- }
36
- .docs-story {
37
- background: transparent ;
38
- }
39
- .sbdocs {
40
- background: transparent ;
41
- }
42
- body {
43
- background: var(--color-fm-surface-primary) ;
44
- }
45
- #storybook-docs {
46
- background: var(--color-fm-surface-primary) ;
47
- }
48
- .sbdocs-preview {
49
- background: transparent ;
50
- border: none ;
51
- }
52
- .sbdocs-h1, .sbdocs-h2, .sbdocs-h3, .sbdocs-h4, .sbdocs-h5, .sbdocs-h6 {
53
- color: var(--color-fm-icon-active) ;
54
- }
55
- .sbdocs-p, .sbdocs-li {
56
- color: var(--color-fm-secondary) ;
57
- }
58
- .sbdocs-code {
59
- background: var(--color-fm-surface-secondary) ;
60
- color: var(--color-fm-secondary-500) ;
61
- border: 1px solid var(--color-fm-divider-secondary) ;
62
- }
63
- .sbdocs-pre {
64
- background: var(--color-fm-surface-secondary) ;
65
- border: 1px solid var(--color-fm-divider-secondary) ;
66
- }
67
- .sbdocs-table {
68
- background: var(--color-fm-surface-secondary) ;
69
- border: 1px solid var(--color-fm-divider-secondary) ;
70
- }
71
- .sbdocs-table th {
72
- background: var(--color-fm-surface-secondary) ;
73
- color: var(--color-fm-icon-active) ;
74
- border-bottom: 1px solid var(--color-fm-divider-secondary) ;
75
- }
76
- .sbdocs-table td {
77
- color: var(--color-fm-secondary) ;
78
- border-bottom: 1px solid var(--color-fm-divider-tertiary) ;
79
- }
80
- `}
81
- </style>
82
-
83
- <div className="from-fm-surface-primary via-fm-icon-positive/5 to-fm-surface-primary min-h-screen bg-linear-to-br">
84
- {/* Header */}
85
- <div className="border-fm-divider-secondary bg-fm-surface-secondary relative overflow-hidden border-b backdrop-blur-xl">
86
- <div className="from-fm-icon-positive/10 to-fm-icon-positive/10 absolute inset-0 bg-linear-to-r via-transparent" />
87
- <div className="relative !mx-auto max-w-7xl px-6 py-16">
88
- <div className="!space-y-6 text-center">
89
- <div className="border-fm-icon-positive/30 from-fm-icon-positive/20 to-fm-icon-positive/20 !mx-auto flex h-24 w-24 items-center justify-center rounded-2xl border bg-linear-to-br">
90
- <ForwardTenSecondsIcon className="text-fm-icon-positive h-12 w-12" />
91
- </div>
92
- <h1 className="text-fm-icon-active! text-5xl font-bold">
93
- ForwardTenSecondsIcon
94
- </h1>
95
- <p className="text-fm-secondary! !mx-auto max-w-3xl text-xl leading-relaxed">
96
- A media control icon for skipping forward 10 seconds in
97
- audio and video players. Features a circular arrow with "10"
98
- seconds indicator, perfect for podcast apps, video players,
99
- and music streaming interfaces.
100
- </p>
101
-
102
- {/* Stats */}
103
- <div className="flex items-center justify-center gap-8 pt-8">
104
- <div className="text-center">
105
- <div className="text-fm-icon-positive text-3xl font-bold">
106
- Media Control
107
- </div>
108
- <div className="text-fm-tertiary text-sm">
109
- 10-second skip forward
110
- </div>
111
- </div>
112
- <div className="bg-fm-divider-primary h-8 w-px" />
113
- <div className="text-center">
114
- <div className="text-fm-icon-positive text-3xl font-bold">
115
- Accessible
116
- </div>
117
- <div className="text-fm-tertiary text-sm">
118
- Screen reader friendly
119
- </div>
120
- </div>
121
- <div className="bg-fm-divider-primary h-8 w-px" />
122
- <div className="text-center">
123
- <div className="text-fm-icon-info text-3xl font-bold">
124
- Universal
125
- </div>
126
- <div className="text-fm-tertiary text-sm">
127
- Cross-platform standard
128
- </div>
129
- </div>
130
- </div>
131
- </div>
132
- </div>
133
- </div>
134
-
135
- {/* Content */}
136
- <div className="!mx-auto max-w-7xl !space-y-16 px-6 py-12">
137
- {/* Quick Usage */}
138
- <div className="!space-y-8">
139
- <h2 className="text-fm-icon-active! text-center text-3xl font-bold">
140
- Quick Start
141
- </h2>
142
- <div className="grid grid-cols-1 gap-8 lg:grid-cols-2">
143
- <div className="!space-y-4">
144
- <h3 className="text-fm-icon-positive! text-xl font-semibold">
145
- Basic Usage
146
- </h3>
147
- <div className="bg-fm-surface-secondary rounded-lg p-4">
148
- <pre className="text-fm-icon-positive! overflow-x-auto text-sm">
149
- {`import { ForwardTenSecondsIcon } from "@icons/forward-ten-seconds-icon"
150
-
151
- function MediaPlayer() {
36
+ <AuralIconDocsPage
37
+ accentToken="positive"
38
+ features={[
39
+ {
40
+ title: "Skip 10s",
41
+ description: "Standard media control",
42
+ },
43
+ { title: "currentColor", description: "Responds to text tokens" },
44
+ { title: "Accessible", description: "ARIA-ready by default" },
45
+ ]}
46
+ quickStart={{
47
+ codeExample: `import { ForwardTenSecondsIcon } from "src/ui/icons/forward-ten-seconds-icon"
48
+
49
+ function SkipButton() {
152
50
  return (
153
- <button
154
- onClick={skipForward}
155
- className="p-2 hover:bg-white/10 rounded-lg"
156
- >
157
- <ForwardTenSecondsIcon className="h-6 w-6 text-emerald-400" />
51
+ <button aria-label="Skip forward 10 seconds">
52
+ <ForwardTenSecondsIcon className="h-6 w-6 text-fm-icon-active" />
158
53
  </button>
159
54
  )
160
- }`}
161
- </pre>
162
- </div>
163
- </div>
164
-
165
- <div className="!space-y-4">
166
- <h3 className="text-fm-icon-positive! text-xl font-semibold">
167
- Live Preview
168
- </h3>
169
- <div className="border-fm-divider-secondary bg-fm-surface-secondary flex h-32 items-center justify-center rounded-lg border">
170
- <button className="border-fm-icon-positive/20 bg-fm-icon-positive/10 hover:bg-fm-icon-positive/20 rounded-lg border p-3 transition-colors">
171
- <ForwardTenSecondsIcon className="text-fm-icon-positive h-6 w-6" />
172
- </button>
173
- </div>
174
- </div>
175
- </div>
176
- </div>
177
-
178
- {/* Props Documentation */}
179
- <div className="!space-y-8">
180
- <h2 className="text-fm-icon-active! text-center text-3xl font-bold">
181
- Props & Configuration
182
- </h2>
183
-
184
- <div className="border-fm-divider-secondary bg-fm-surface-secondary overflow-hidden rounded-lg border">
185
- <div className="bg-fm-surface-secondary p-4">
186
- <h3 className="text-fm-icon-active! text-xl font-semibold">
187
- Props
188
- </h3>
189
- </div>
190
- <table className="!my-0 w-full">
191
- <thead className="bg-fm-surface-secondary">
192
- <tr className="border-fm-divider-secondary border-b">
193
- <th className="text-fm-icon-active! px-6 py-4 text-left text-sm font-semibold">
194
- Prop
195
- </th>
196
- <th className="text-fm-icon-active! px-6 py-4 text-left text-sm font-semibold">
197
- Type
198
- </th>
199
- <th className="text-fm-icon-active! px-6 py-4 text-left text-sm font-semibold">
200
- Default
201
- </th>
202
- <th className="text-fm-icon-active! px-6 py-4 text-left text-sm font-semibold">
203
- Description
204
- </th>
205
- </tr>
206
- </thead>
207
- <tbody>
208
- {" "}
209
- <tr className="bg-fm-surface-secondary!">
210
- <td className="text-fm-icon-info! px-6 py-4 font-mono text-sm">
211
- withAccessibility
212
- </td>
213
- <td className="text-fm-secondary! px-6 py-4 text-sm">
214
- boolean
215
- </td>
216
- <td className="text-fm-placeholder! px-6 py-4 text-sm">
217
- true
218
- </td>
219
- <td className="text-fm-secondary! px-6 py-4 text-sm">
220
- Whether to wrap the icon with accessibility feature
221
- </td>
222
- </tr>
223
- <tr className="border-fm-divider-tertiary bg-fm-surface-secondary! border-b">
224
- <td className="text-fm-icon-positive! px-6 py-4 font-mono text-sm">
225
- height
226
- </td>
227
- <td className="text-fm-secondary! px-6 py-4 text-sm">
228
- number | string
229
- </td>
230
- <td className="text-fm-placeholder! px-6 py-4 text-sm">
231
- 44
232
- </td>
233
- <td className="text-fm-secondary! px-6 py-4 text-sm">
234
- Height of the icon in pixels
235
- </td>
236
- </tr>
237
- <tr className="border-fm-divider-tertiary border-b">
238
- <td className="text-fm-icon-positive! px-6 py-4 font-mono text-sm">
239
- stroke
240
- </td>
241
- <td className="text-fm-secondary! px-6 py-4 text-sm">
242
- string
243
- </td>
244
- <td className="text-fm-placeholder! px-6 py-4 text-sm">
245
- currentColor
246
- </td>
247
- <td className="text-fm-secondary! px-6 py-4 text-sm">
248
- Stroke color of the icon
249
- </td>
250
- </tr>
251
- <tr className="border-fm-divider-tertiary bg-fm-surface-secondary! border-b">
252
- <td className="text-fm-icon-positive! px-6 py-4 font-mono text-sm">
253
- strokeWidth
254
- </td>
255
- <td className="text-fm-secondary! px-6 py-4 text-sm">
256
- string | number
257
- </td>
258
- <td className="text-fm-placeholder! px-6 py-4 text-sm">
259
- 1.5
260
- </td>
261
- <td className="text-fm-secondary! px-6 py-4 text-sm">
262
- Width of the stroke
263
- </td>
264
- </tr>
265
- <tr className="border-fm-divider-tertiary border-b">
266
- <td className="text-fm-icon-positive! px-6 py-4 font-mono text-sm">
267
- className
268
- </td>
269
- <td className="text-fm-secondary! px-6 py-4 text-sm">
270
- string
271
- </td>
272
- <td className="text-fm-placeholder! px-6 py-4 text-sm">
273
- -
274
- </td>
275
- <td className="text-fm-secondary! px-6 py-4 text-sm">
276
- CSS classes for styling (use for overrides)
277
- </td>
278
- </tr>
279
- <tr className="bg-fm-surface-secondary!">
280
- <td className="text-fm-icon-positive! px-6 py-4 font-mono text-sm">
281
- ...svgProps
282
- </td>
283
- <td className="text-fm-secondary! px-6 py-4 text-sm">
284
- SVGProps
285
- </td>
286
- <td className="text-fm-placeholder! px-6 py-4 text-sm">
287
- -
288
- </td>
289
- <td className="text-fm-secondary! px-6 py-4 text-sm">
290
- All standard SVG element props
291
- </td>
292
- </tr>
293
- </tbody>
294
- </table>
295
- </div>
296
- </div>
297
-
298
- {/* Size Variations */}
299
- <div className="!space-y-8">
300
- <h2 className="text-fm-icon-active! text-center text-3xl font-bold">
301
- Size Variations
302
- </h2>
303
- <div className="border-fm-divider-secondary bg-fm-surface-secondary rounded-lg border p-8">
304
- <div className="!space-y-6">
305
- <div className="grid grid-cols-1 gap-8 md:grid-cols-2">
306
- <div className="!space-y-4">
307
- <h3 className="text-fm-icon-positive! text-lg font-semibold">
308
- Standard Sizes
309
- </h3>
310
- <div className="bg-fm-surface-secondary flex items-end gap-6 rounded-lg p-6">
311
- <div className="text-center">
312
- <ForwardTenSecondsIcon className="text-fm-icon-positive !mx-auto mb-2 h-3 w-3" />
313
- <span className="text-fm-tertiary text-xs">
314
- 12px
315
- </span>
316
- </div>
317
- <div className="text-center">
318
- <ForwardTenSecondsIcon className="text-fm-icon-positive !mx-auto mb-2 h-4 w-4" />
319
- <span className="text-fm-tertiary text-xs">
320
- 16px
321
- </span>
322
- </div>
323
- <div className="text-center">
324
- <ForwardTenSecondsIcon className="text-fm-icon-positive !mx-auto mb-2 h-5 w-5" />
325
- <span className="text-fm-tertiary text-xs">
326
- 20px
327
- </span>
328
- </div>
329
- <div className="text-center">
330
- <ForwardTenSecondsIcon className="text-fm-icon-positive !mx-auto mb-2 h-6 w-6" />
331
- <span className="text-fm-tertiary text-xs">
332
- 24px
333
- </span>
334
- </div>
335
- <div className="text-center">
336
- <ForwardTenSecondsIcon className="text-fm-icon-positive !mx-auto mb-2 h-8 w-8" />
337
- <span className="text-fm-tertiary text-xs">
338
- 32px
339
- </span>
340
- </div>
341
- <div className="text-center">
342
- <ForwardTenSecondsIcon className="text-fm-icon-positive !mx-auto mb-2 h-12 w-12" />
343
- <span className="text-fm-tertiary text-xs">
344
- 48px
345
- </span>
346
- </div>
347
- </div>
348
- </div>
349
-
350
- <div className="!space-y-4">
351
- <h3 className="text-fm-icon-positive! text-lg font-semibold">
352
- Code Example
353
- </h3>
354
- <div className="bg-fm-surface-secondary rounded-lg p-4">
355
- <pre className="text-fm-icon-info! overflow-x-auto text-sm">
356
- {`// Small (16px)
357
- <ForwardTenSecondsIcon className="h-4 w-4" />
358
-
359
- // Medium (24px)
360
- <ForwardTenSecondsIcon className="h-6 w-6" />
361
-
362
- // Large (32px)
363
- <ForwardTenSecondsIcon className="h-8 w-8" />
364
-
365
- // Custom size
366
- <ForwardTenSecondsIcon width={40} height={40} />`}
367
- </pre>
368
- </div>
369
- </div>
370
- </div>
371
- </div>
372
- </div>
373
- </div>
374
-
375
- {/* Color Variations */}
376
- <div className="!space-y-8">
377
- <h2 className="text-fm-icon-active! text-center text-3xl font-bold">
378
- Color Variations
379
- </h2>
380
- <div className="grid grid-cols-1 gap-8 lg:grid-cols-2">
381
- <div className="!space-y-4">
382
- <h3 className="text-fm-icon-positive! text-lg font-semibold">
383
- Semantic Colors
384
- </h3>
385
- <div className="border-fm-divider-secondary bg-fm-surface-secondary !space-y-4 rounded-lg border p-6">
386
- <div className="flex items-center gap-4">
387
- <ForwardTenSecondsIcon className="text-fm-icon-positive h-6 w-6" />
388
- <div>
389
- <div className="text-fm-icon-active text-sm font-medium">
390
- Primary
391
- </div>
392
- <div className="text-fm-tertiary text-xs">
393
- text-fm-icon-positive
394
- </div>
395
- </div>
396
- </div>
397
- <div className="flex items-center gap-4">
398
- <ForwardTenSecondsIcon className="text-fm-icon-positive h-6 w-6" />
399
- <div>
400
- <div className="text-fm-icon-active text-sm font-medium">
401
- Secondary
402
- </div>
403
- <div className="text-fm-tertiary text-xs">
404
- text-fm-icon-positive
405
- </div>
406
- </div>
407
- </div>
408
- <div className="flex items-center gap-4">
409
- <ForwardTenSecondsIcon className="text-fm-icon-info h-6 w-6" />
410
- <div>
411
- <div className="text-fm-icon-active text-sm font-medium">
412
- Accent
413
- </div>
414
- <div className="text-fm-tertiary text-xs">
415
- text-fm-icon-info
416
- </div>
417
- </div>
418
- </div>
419
- <div className="flex items-center gap-4">
420
- <ForwardTenSecondsIcon className="text-fm-placeholder h-6 w-6" />
421
- <div>
422
- <div className="text-fm-icon-active text-sm font-medium">
423
- Disabled
424
- </div>
425
- <div className="text-fm-tertiary text-xs">
426
- text-fm-placeholder
427
- </div>
428
- </div>
429
- </div>
430
- </div>
431
- </div>
432
-
433
- <div className="!space-y-4">
434
- <h3 className="text-fm-icon-positive! text-lg font-semibold">
435
- Custom Colors
436
- </h3>
437
- <div className="bg-fm-surface-secondary rounded-lg p-4">
438
- <pre className="text-fm-icon-positive! overflow-x-auto text-sm">
439
- {`// Using Tailwind classes
440
- <ForwardTenSecondsIcon className="h-6 w-6 text-emerald-400" />
441
- <ForwardTenSecondsIcon className="h-6 w-6 text-green-500" />
442
-
443
- // Using CSS custom properties
444
- <ForwardTenSecondsIcon
445
- className="h-6 w-6"
446
- style={{ color: 'var(--color-primary)' }}
447
- />
448
-
449
- // Direct stroke prop
450
- <ForwardTenSecondsIcon
451
- width={24}
452
- height={24}
453
- stroke="#10b981"
454
- />`}
455
- </pre>
456
- </div>
457
- </div>
458
- </div>
459
- </div>
460
-
461
- {/* Usage Examples */}
462
- <div className="!space-y-8">
463
- <h2 className="text-fm-icon-active! text-center text-3xl font-bold">
464
- Usage Examples
465
- </h2>
466
-
467
- <div className="grid grid-cols-1 gap-8 lg:grid-cols-2">
468
- {/* Podcast Player */}
469
- <div className="!space-y-4">
470
- <h3 className="text-fm-icon-positive! text-lg font-semibold">
471
- Podcast Player
472
- </h3>
473
- <div className="!space-y-4">
474
- <div className="border-fm-divider-secondary bg-fm-surface-secondary rounded-lg border p-6">
475
- <div className="mb-4 flex items-center justify-between">
476
- <h3 className="text-fm-icon-active! text-lg font-semibold">
477
- Now Playing
478
- </h3>
479
- </div>
480
- <div className="mb-4 flex items-center justify-center gap-4">
481
- <button className="hover:bg-fm-surface-secondary rounded-lg p-2 transition-colors">
482
- <div className="border-fm-divider-contrast bg-fm-divider-primary h-6 w-6 rounded-full border" />
483
- </button>
484
- <button className="hover:bg-fm-surface-secondary rounded-lg p-3 transition-colors">
485
- <div className="border-fm-divider-contrast bg-fm-divider-primary h-8 w-8 rounded-full border-2" />
486
- </button>
487
- <button className="hover:bg-fm-surface-secondary rounded-lg p-2 transition-colors">
488
- <ForwardTenSecondsIcon className="text-fm-icon-positive h-6 w-6" />
489
- </button>
490
- </div>
491
- <p className="text-fm-secondary! text-sm">
492
- Skip forward 10 seconds to bypass ads or get past
493
- content
494
- </p>
495
- </div>
496
- <div className="bg-fm-surface-secondary rounded-lg p-4">
497
- <pre className="text-fm-icon-positive! overflow-x-auto text-sm">
498
- {`// Podcast control bar
499
- <div className="flex items-center justify-center gap-4">
500
- <button onClick={() => skipSeconds(-10)}>
501
- <BackwardTenSecondsIcon className="h-6 w-6" />
502
- </button>
503
- <button onClick={togglePlay}>
504
- <PlayIcon className="h-8 w-8" />
505
- </button>
506
- <button onClick={() => skipSeconds(10)}>
507
- <ForwardTenSecondsIcon className="h-6 w-6 text-emerald-400" />
508
- </button>
509
- </div>`}
510
- </pre>
511
- </div>
512
- </div>
513
- </div>
514
-
515
- {/* Video Player */}
516
- <div className="!space-y-4">
517
- <h3 className="text-fm-icon-positive! text-lg font-semibold">
518
- Video Player Controls
519
- </h3>
520
- <div className="!space-y-4">
521
- <div className="border-fm-divider-secondary bg-fm-surface-secondary rounded-lg border p-4">
522
- <div className="from-fm-icon-positive/20 to-fm-icon-positive/20 mb-4 h-32 rounded bg-linear-to-r" />
523
- <div className="flex items-center justify-between">
524
- <div className="flex items-center gap-2">
525
- <span className="text-fm-tertiary text-sm">
526
- 8:15 / 24:30
527
- </span>
528
- <button className="hover:bg-fm-surface-secondary rounded p-1.5">
529
- <ForwardTenSecondsIcon className="text-fm-icon-positive h-5 w-5" />
530
- </button>
531
- </div>
532
- <div className="flex items-center gap-2">
533
- <button className="hover:bg-fm-surface-secondary rounded p-1.5">
534
- <div className="border-fm-divider-contrast bg-fm-divider-primary h-5 w-5 rounded-full border" />
535
- </button>
536
- </div>
537
- </div>
538
- </div>
539
- <div className="bg-fm-surface-secondary rounded-lg p-4">
540
- <pre className="text-fm-icon-positive! overflow-x-auto text-sm">
541
- {`// Video player with fast forward
542
- <div className="video-controls">
543
- <div className="flex items-center gap-2">
544
- <span>{formatTime(currentTime)} / {formatTime(duration)}</span>
545
- <button
546
- onClick={fastForwardTenSeconds}
547
- aria-label="Fast forward 10 seconds"
548
- >
549
- <ForwardTenSecondsIcon className="h-5 w-5 text-emerald-400" />
550
- </button>
551
- </div>
552
- </div>`}
553
- </pre>
554
- </div>
555
- </div>
556
- </div>
557
-
558
- {/* Music Player */}
559
- <div className="!space-y-4">
560
- <h3 className="text-fm-icon-positive! text-lg font-semibold">
561
- Music Player Interface
562
- </h3>
563
- <div className="!space-y-4">
564
- <div className="border-fm-divider-secondary bg-fm-surface-secondary rounded-lg border p-4">
565
- <div className="mb-4 flex items-center gap-3">
566
- <div className="from-fm-icon-positive/20 to-fm-icon-positive/20 h-12 w-12 rounded-lg bg-linear-to-br" />
567
- <div>
568
- <div className="text-fm-icon-active! text-sm font-medium">
569
- Song Title
570
- </div>
571
- <div className="text-fm-tertiary! text-xs">
572
- Artist Name
573
- </div>
574
- </div>
575
- </div>
576
- <div className="flex items-center justify-center gap-6">
577
- <button className="hover:bg-fm-surface-secondary rounded-lg p-1.5">
578
- <div className="border-fm-divider-contrast bg-fm-divider-primary h-4 w-4 rounded-full border" />
579
- </button>
580
- <button className="hover:bg-fm-surface-secondary rounded-lg p-2">
581
- <div className="border-fm-divider-contrast bg-fm-divider-primary h-6 w-6 rounded-full border" />
582
- </button>
583
- <button className="hover:bg-fm-surface-secondary rounded-lg p-2">
584
- <div className="border-fm-divider-contrast bg-fm-divider-primary h-8 w-8 rounded-full border-2" />
585
- </button>
586
- <button className="hover:bg-fm-surface-secondary rounded-lg p-2">
587
- <div className="border-fm-divider-contrast bg-fm-divider-primary h-6 w-6 rounded-full border" />
588
- </button>
589
- <button className="hover:bg-fm-surface-secondary rounded-lg p-1.5">
590
- <ForwardTenSecondsIcon className="text-fm-icon-positive h-4 w-4" />
591
- </button>
592
- </div>
593
- </div>
594
- <div className="bg-fm-surface-secondary rounded-lg p-4">
595
- <pre className="text-fm-icon-positive! overflow-x-auto text-sm">
596
- {`// Music player with skip controls
597
- <div className="music-controls">
598
- <div className="flex items-center justify-center gap-6">
599
- <button onClick={skipBackward}>
600
- <BackwardTenSecondsIcon className="h-4 w-4" />
601
- </button>
602
- <button onClick={previousTrack}>
603
- <PreviousIcon className="h-6 w-6" />
604
- </button>
605
- <button onClick={togglePlay}>
606
- <PlayIcon className="h-8 w-8" />
607
- </button>
608
- <button onClick={nextTrack}>
609
- <NextIcon className="h-6 w-6" />
610
- </button>
611
- <button onClick={skipForward}>
612
- <ForwardTenSecondsIcon className="h-4 w-4 text-emerald-400" />
613
- </button>
614
- </div>
615
- </div>`}
616
- </pre>
617
- </div>
618
- </div>
619
- </div>
620
-
621
- {/* Educational Content */}
622
- <div className="!space-y-4">
623
- <h3 className="text-fm-icon-positive! text-lg font-semibold">
624
- Educational Video Player
625
- </h3>
626
- <div className="!space-y-4">
627
- <div className="border-fm-divider-secondary bg-fm-surface-secondary rounded-lg border p-4">
628
- <div className="mb-4">
629
- <div className="mb-2 flex items-center gap-2">
630
- <div className="bg-fm-icon-positive h-2 w-2 rounded-full" />
631
- <span className="text-fm-icon-active! text-sm font-medium">
632
- Lesson 3: Advanced Concepts
633
- </span>
634
- </div>
635
- <h4 className="text-fm-secondary! text-sm">
636
- Interactive Learning Module
637
- </h4>
638
- </div>
639
- <div className="flex items-center justify-between">
640
- <div className="flex items-center gap-2">
641
- <span className="text-fm-tertiary! text-xs">
642
- Skip to next section
643
- </span>
644
- <button className="hover:bg-fm-surface-secondary rounded p-1.5">
645
- <ForwardTenSecondsIcon className="text-fm-icon-positive h-5 w-5" />
646
- </button>
647
- </div>
648
- <button className="border-fm-icon-positive/30 bg-fm-icon-positive/10 text-fm-icon-positive rounded-lg border px-3 py-1 text-xs">
649
- Next Chapter
650
- </button>
651
- </div>
652
- </div>
653
- <div className="bg-fm-surface-secondary rounded-lg p-4">
654
- <pre className="text-fm-icon-positive! overflow-x-auto text-sm">
655
- {`// Educational content with skip ahead
656
- <div className="lesson-controls">
657
- <div className="flex items-center gap-2">
658
- <span>Skip to next section</span>
659
- <button
660
- onClick={skipToNextSection}
661
- aria-label="Skip forward 10 seconds to next section"
662
- >
663
- <ForwardTenSecondsIcon className="h-5 w-5 text-emerald-400" />
664
- </button>
665
- </div>
666
- <button onClick={nextChapter}>
667
- Next Chapter
668
- </button>
669
- </div>`}
670
- </pre>
671
- </div>
672
- </div>
673
- </div>
674
- </div>
675
- </div>
676
-
677
- {/* Accessibility */}
678
- <div className="!space-y-8">
679
- <h2 className="text-fm-icon-active! text-center text-3xl font-bold">
680
- Accessibility Features
681
- </h2>
682
- <div className="grid grid-cols-1 gap-8 md:grid-cols-2">
683
- <div className="border-fm-divider-secondary bg-fm-surface-secondary !space-y-4 rounded-lg border p-6">
684
- <h3 className="text-fm-icon-positive! text-lg font-semibold">
685
- ✅ Built-in Features
686
- </h3>
687
- <ul className="text-fm-secondary! !space-y-2 text-sm">
688
- <li className="text-fm-secondary!">
689
- Uses Radix UI AccessibleIcon wrapper
690
- </li>
691
- <li className="text-fm-secondary!">
692
- Provides screen reader label "Forward ten seconds icon"
693
- </li>
694
- <li className="text-fm-secondary!">
695
- Supports keyboard navigation when interactive
696
- </li>
697
- <li className="text-fm-secondary!">
698
- Maintains proper color contrast ratios
699
- </li>
700
- <li className="text-fm-secondary!">
701
- Scales with user's font size preferences
702
- </li>
703
- </ul>
704
- </div>
705
-
706
- <div className="border-fm-divider-secondary bg-fm-surface-secondary !space-y-4 rounded-lg border p-6">
707
- <h3 className="text-fm-icon-positive! text-lg font-semibold">
708
- 💡 Best Practices
709
- </h3>
710
- <ul className="text-fm-secondary !space-y-2 text-sm">
711
- <li className="text-fm-secondary!">
712
- Always provide descriptive aria-labels for buttons
713
- </li>
714
- <li className="text-fm-secondary!">
715
- Use consistent placement in media control groups
716
- </li>
717
- <li className="text-fm-secondary!">
718
- Ensure sufficient touch target size (44px minimum)
719
- </li>
720
- <li className="text-fm-secondary!">
721
- Provide visible focus states for keyboard users
722
- </li>
723
- <li className="text-fm-secondary!">
724
- Consider keyboard shortcuts (e.g., Right Arrow key)
725
- </li>
726
- </ul>
727
- </div>
728
- </div>
729
-
730
- <div className="border-fm-divider-secondary bg-fm-surface-secondary rounded-lg border p-6">
731
- <h3 className="text-fm-icon-positive! mb-4 text-lg font-semibold">
732
- Proper ARIA Implementation
733
- </h3>
734
- <div className="grid grid-cols-1 gap-6 lg:grid-cols-2">
735
- <div className="bg-fm-surface-secondary rounded-lg p-4">
736
- <pre className="text-fm-icon-info! overflow-x-auto text-sm">
737
- {`// Media control with proper ARIA
738
- <button
739
- aria-label="Fast forward 10 seconds"
740
- className="p-2 hover:bg-white/10 rounded-lg"
741
- onClick={fastForwardTenSeconds}
742
- >
743
- <ForwardTenSecondsIcon className="h-6 w-6 text-emerald-400" />
744
- </button>
745
-
746
- // Podcast player with context
747
- <button
748
- aria-label="Skip ahead 10 seconds in podcast"
749
- onClick={skipForward}
750
- >
751
- <ForwardTenSecondsIcon className="h-5 w-5" />
752
- </button>
753
-
754
- // Video player with state
755
- <button
756
- aria-label={\`Fast forward 10 seconds (current: \${formatTime(currentTime)})\`}
757
- disabled={currentTime > duration - 10}
758
- >
759
- <ForwardTenSecondsIcon className="h-5 w-5" />
760
- </button>`}
761
- </pre>
762
- </div>
763
- <div className="!space-y-4">
764
- <p className="text-fm-secondary! text-sm">
765
- When using ForwardTenSecondsIcon for interactive
766
- elements, always provide clear context about what action
767
- will be performed and the current playback state when
768
- relevant.
769
- </p>
770
- <div className="border-fm-icon-positive/20 bg-fm-icon-positive/10 rounded-lg border p-4">
771
- <div className="text-fm-icon-positive flex items-center gap-2 text-sm">
772
- <ForwardTenSecondsIcon className="h-4 w-4" />
773
- <span>
774
- Screen readers need specific context about the fast
775
- forward action
776
- </span>
777
- </div>
778
- </div>
779
- </div>
780
- </div>
781
- </div>
782
- </div>
783
-
784
- {/* Related Icons */}
785
- <div className="!space-y-8">
786
- <h2 className="text-fm-icon-active! text-center text-3xl font-bold">
787
- Related Icons
788
- </h2>
789
- <div className="grid grid-cols-2 gap-6 md:grid-cols-4">
790
- <div className="border-fm-divider-secondary bg-fm-surface-secondary !space-y-3 rounded-lg border p-4 text-center">
791
- <div className="bg-fm-icon-positive/20 !mx-auto flex h-12 w-12 items-center justify-center rounded-lg">
792
- <span className="text-fm-icon-active! !text-2xl">⏪</span>
793
- </div>
794
- <div>
795
- <div className="text-fm-icon-active font-medium">
796
- BackwardTenSecondsIcon
797
- </div>
798
- <div className="text-fm-tertiary text-xs">
799
- Skip backward 10s
800
- </div>
801
- </div>
802
- </div>
803
- <div className="border-fm-divider-secondary bg-fm-surface-secondary !space-y-3 rounded-lg border p-4 text-center">
804
- <div className="bg-fm-icon-positive/20 !mx-auto flex h-12 w-12 items-center justify-center rounded-lg">
805
- <span className="text-fm-icon-active! !text-2xl">⏸</span>
806
- </div>
807
- <div>
808
- <div className="text-fm-icon-active font-medium">
809
- PlayIcon
810
- </div>
811
- <div className="text-fm-tertiary text-xs">Play/pause</div>
812
- </div>
813
- </div>
814
- <div className="border-fm-divider-secondary bg-fm-surface-secondary !space-y-3 rounded-lg border p-4 text-center">
815
- <div className="bg-fm-icon-info/20 !mx-auto flex h-12 w-12 items-center justify-center rounded-lg">
816
- <span className="text-fm-icon-active! !text-2xl">⏩</span>
817
- </div>
818
- <div>
819
- <div className="text-fm-icon-active font-medium">
820
- FastForwardIcon
821
- </div>
822
- <div className="text-fm-tertiary text-xs">
823
- Fast forward
824
- </div>
825
- </div>
826
- </div>
827
- <div className="border-fm-divider-secondary bg-fm-surface-secondary !space-y-3 rounded-lg border p-4 text-center">
828
- <div className="bg-fm-icon-info/20 !mx-auto flex h-12 w-12 items-center justify-center rounded-lg">
829
- <span className="text-fm-icon-active! !text-2xl">⏭</span>
830
- </div>
831
- <div>
832
- <div className="text-fm-icon-active font-medium">
833
- NextIcon
834
- </div>
835
- <div className="text-fm-tertiary text-xs">Next track</div>
836
- </div>
837
- </div>
838
- </div>
839
- </div>
840
- </div>
841
-
842
- {/* Footer */}
843
- <div className="border-fm-divider-secondary bg-fm-surface-secondary border-t backdrop-blur-xl">
844
- <div className="!mx-auto max-w-7xl px-6 py-8">
845
- <div className="!space-y-4 text-center">
846
- <p className="text-fm-tertiary!">
847
- ForwardTenSecondsIcon is part of the Aural UI icon library,
848
- built with accessibility and media control best practices in
849
- mind.
850
- </p>
851
- <p className="text-fm-placeholder! text-sm">
852
- All icons use Radix UI's AccessibleIcon for screen reader
853
- compatibility and follow WCAG guidelines.
854
- </p>
855
- </div>
856
- </div>
857
- </div>
858
- </div>
859
- </>
55
+ }`,
56
+ livePreview: (
57
+ <button aria-label="Skip forward 10 seconds">
58
+ <ForwardTenSecondsIcon className="text-fm-icon-active h-6 w-6" />
59
+ </button>
60
+ ),
61
+ }}
62
+ relatedIcons={[
63
+ {
64
+ name: "BackwardTenSecondsIcon",
65
+ description: "Rewind 10s",
66
+ icon: BackwardTenSecondsIcon,
67
+ accentToken: "info",
68
+ },
69
+ {
70
+ name: "SkipForwardIcon",
71
+ description: "Skip to next",
72
+ icon: SkipForwardIcon,
73
+ accentToken: "positive",
74
+ },
75
+ {
76
+ name: "SkipBackwardIcon",
77
+ description: "Skip to previous",
78
+ icon: SkipBackwardIcon,
79
+ accentToken: "warning",
80
+ },
81
+ {
82
+ name: "PauseIcon",
83
+ description: "Pause playback",
84
+ icon: PauseIcon,
85
+ accentToken: "negative",
86
+ },
87
+ ]}
88
+ />
860
89
  ),
861
90
  },
862
91
  },
863
92
  tags: ["autodocs"],
864
93
  argTypes: {
865
- width: {
866
- control: { type: "range", min: 8, max: 96, step: 2 },
867
- description: "Width of the icon in pixels",
868
- },
869
- withAccessibility: {
870
- control: "boolean",
871
- description: "Whether to wrap the icon with accessibility features",
872
- },
873
- height: {
874
- control: { type: "range", min: 8, max: 96, step: 2 },
875
- description: "Height of the icon in pixels",
876
- },
877
- stroke: {
878
- control: "color",
879
- description: "Stroke color of the icon",
880
- },
881
- strokeWidth: {
882
- control: { type: "range", min: 0.5, max: 4, step: 0.5 },
883
- description: "Width of the stroke",
884
- },
885
94
  className: {
886
95
  control: "text",
887
- description: "CSS classes for styling (use for overrides)",
96
+ description: "CSS classes including size and color token",
888
97
  },
889
- onClick: {
890
- action: "clicked",
891
- description: "Click handler for interactive use",
98
+ withAccessibility: {
99
+ control: "boolean",
100
+ description: "Wrap with accessibility label",
892
101
  },
893
102
  },
894
103
  }
@@ -896,201 +105,138 @@ function MediaPlayer() {
896
105
  export default meta
897
106
  type Story = StoryObj<typeof ForwardTenSecondsIcon>
898
107
 
899
- // Story parameters for consistent dark theme
900
- const storyParameters = {
901
- backgrounds: {
902
- default: "dark",
903
- values: [
904
- { name: "dark", value: "var(--color-fm-surface-primary)" },
905
- { name: "darker", value: "var(--color-fm-neutral-0)" },
906
- ],
907
- },
908
- }
909
-
910
108
  export const Default: Story = {
911
109
  args: {
912
- className: "h-8 w-8 text-fm-icon-positive",
110
+ className: "h-6 w-6 text-fm-icon-active",
913
111
  withAccessibility: true,
914
112
  },
915
- parameters: storyParameters,
916
113
  render: (args) => (
917
- <div className="from-fm-surface-primary to-fm-surface-secondary flex h-32 min-h-dvh items-center justify-center rounded-lg bg-linear-to-br">
114
+ <IconDefaultCanvas>
918
115
  <ForwardTenSecondsIcon {...args} />
919
- </div>
116
+ </IconDefaultCanvas>
920
117
  ),
921
118
  }
922
119
 
923
120
  export const SizeVariations: Story = {
924
- parameters: {
925
- ...storyParameters,
926
- docs: {
927
- description: {
928
- story:
929
- "ForwardTenSecondsIcon in different sizes, from small UI elements to large displays.",
930
- },
931
- },
932
- },
933
- render: () => (
934
- <div className="from-fm-surface-primary to-fm-surface-secondary flex h-64 min-h-dvh items-center justify-center gap-8 rounded-lg bg-linear-to-br p-8">
935
- <div className="text-center">
936
- <ForwardTenSecondsIcon className="text-fm-icon-positive !mx-auto mb-2 h-3 w-3" />
937
- <span className="text-fm-tertiary text-xs">12px</span>
938
- </div>
939
- <div className="text-center">
940
- <ForwardTenSecondsIcon className="text-fm-icon-positive !mx-auto mb-2 h-4 w-4" />
941
- <span className="text-fm-tertiary text-xs">16px</span>
942
- </div>
943
- <div className="text-center">
944
- <ForwardTenSecondsIcon className="text-fm-icon-positive !mx-auto mb-2 h-5 w-5" />
945
- <span className="text-fm-tertiary text-xs">20px</span>
946
- </div>
947
- <div className="text-center">
948
- <ForwardTenSecondsIcon className="text-fm-icon-positive !mx-auto mb-2 h-6 w-6" />
949
- <span className="text-fm-tertiary text-xs">24px</span>
950
- </div>
951
- <div className="text-center">
952
- <ForwardTenSecondsIcon className="text-fm-icon-positive !mx-auto mb-2 h-8 w-8" />
953
- <span className="text-fm-tertiary text-xs">32px</span>
954
- </div>
955
- <div className="text-center">
956
- <ForwardTenSecondsIcon className="text-fm-icon-positive !mx-auto mb-2 h-12 w-12" />
957
- <span className="text-fm-tertiary text-xs">48px</span>
958
- </div>
959
- </div>
960
- ),
121
+ render: () => <IconSizeVariations icon={ForwardTenSecondsIcon} />,
961
122
  }
962
123
 
963
124
  export const ColorVariations: Story = {
964
- parameters: {
965
- ...storyParameters,
966
- docs: {
967
- description: {
968
- story:
969
- "ForwardTenSecondsIcon in different semantic colors for various use cases.",
970
- },
971
- },
972
- },
125
+ render: () => <IconColorVariations icon={ForwardTenSecondsIcon} />,
126
+ }
127
+
128
+ export const DirectionalVariations: Story = {
973
129
  render: () => (
974
- <div className="from-fm-surface-primary to-fm-surface-secondary grid min-h-dvh grid-cols-2 items-center justify-center gap-6 rounded-lg bg-linear-to-br p-8 md:grid-cols-4">
975
- <div className="text-center">
976
- <div className="border-fm-icon-positive/30 bg-fm-icon-positive/20 !mx-auto mb-3 flex h-16 w-16 items-center justify-center rounded-lg border">
977
- <ForwardTenSecondsIcon className="text-fm-icon-positive h-8 w-8" />
978
- </div>
979
- <div className="text-fm-icon-active text-sm font-medium">Primary</div>
980
- <div className="text-fm-icon-positive text-xs">
981
- text-fm-icon-positive
982
- </div>
983
- </div>
984
- <div className="text-center">
985
- <div className="border-fm-icon-positive/30 bg-fm-icon-positive/20 !mx-auto mb-3 flex h-16 w-16 items-center justify-center rounded-lg border">
986
- <ForwardTenSecondsIcon className="text-fm-icon-positive h-8 w-8" />
987
- </div>
988
- <div className="text-fm-icon-active text-sm font-medium">Secondary</div>
989
- <div className="text-fm-icon-positive text-xs">
990
- text-fm-icon-positive
991
- </div>
992
- </div>
993
- <div className="text-center">
994
- <div className="border-fm-icon-info/30 bg-fm-icon-info/20 !mx-auto mb-3 flex h-16 w-16 items-center justify-center rounded-lg border">
995
- <ForwardTenSecondsIcon className="text-fm-icon-info h-8 w-8" />
996
- </div>
997
- <div className="text-fm-icon-active text-sm font-medium">Accent</div>
998
- <div className="text-fm-icon-info text-xs">text-fm-icon-info</div>
999
- </div>
1000
- <div className="text-center">
1001
- <div className="border-fm-divider-secondary bg-fm-surface-secondary !mx-auto mb-3 flex h-16 w-16 items-center justify-center rounded-lg border">
1002
- <ForwardTenSecondsIcon className="text-fm-placeholder h-8 w-8" />
1003
- </div>
1004
- <div className="text-fm-icon-active text-sm font-medium">Disabled</div>
1005
- <div className="text-fm-placeholder text-xs">text-fm-placeholder</div>
1006
- </div>
1007
- </div>
130
+ <IconDirectionalVariations
131
+ icon={ForwardTenSecondsIcon}
132
+ directions={[
133
+ { label: "Forward", className: "h-8 w-8 text-fm-icon-active" },
134
+ {
135
+ label: "Backward",
136
+ className: "h-8 w-8 text-fm-icon-active rotate-180",
137
+ },
138
+ ]}
139
+ />
1008
140
  ),
1009
141
  }
1010
142
 
1011
143
  export const UsageExamples: Story = {
1012
- parameters: {
1013
- ...storyParameters,
1014
- docs: {
1015
- description: {
1016
- story:
1017
- "Real-world usage examples showing ForwardTenSecondsIcon in different media control contexts.",
1018
- },
1019
- },
1020
- },
1021
144
  render: () => (
1022
- <div className="from-fm-surface-primary to-fm-surface-secondary min-h-dvh !space-y-8 rounded-lg bg-linear-to-br p-8">
1023
- {/* Podcast Player */}
1024
- <div className="!space-y-2">
1025
- <h3 className="text-fm-icon-active text-sm font-medium">
1026
- Podcast Player
1027
- </h3>
1028
- <div className="border-fm-divider-secondary bg-fm-surface-secondary rounded-lg border p-6">
1029
- <div className="mb-4 flex items-center justify-between">
1030
- <h3 className="text-fm-icon-active text-lg font-semibold">
1031
- Now Playing
1032
- </h3>
1033
- </div>
145
+ <IconUsageCanvas>
146
+ <IconUsageSection title="Audio Player Controls">
147
+ <div className="border-fm-divider-secondary bg-fm-surface-secondary w-full max-w-sm rounded-xl border p-4">
1034
148
  <div className="flex items-center justify-center gap-4">
1035
- <button className="hover:bg-fm-surface-secondary rounded-lg p-2 transition-colors">
1036
- <div className="border-fm-divider-contrast bg-fm-divider-primary h-6 w-6 rounded-full border" />
149
+ <button
150
+ className="flex h-10 w-10 items-center justify-center"
151
+ aria-label="Skip backward"
152
+ >
153
+ <SkipBackwardIcon className="text-fm-icon-active h-5 w-5" />
154
+ </button>
155
+ <button
156
+ className="flex h-10 w-10 items-center justify-center"
157
+ aria-label="Rewind 10 seconds"
158
+ >
159
+ <BackwardTenSecondsIcon className="text-fm-icon-active h-6 w-6" />
160
+ </button>
161
+ <button
162
+ className="bg-fm-icon-active flex h-12 w-12 items-center justify-center rounded-full"
163
+ aria-label="Pause"
164
+ >
165
+ <PauseIcon className="text-fm-primary h-5 w-5" />
1037
166
  </button>
1038
- <button className="hover:bg-fm-surface-secondary rounded-lg p-3 transition-colors">
1039
- <div className="border-fm-divider-contrast bg-fm-divider-primary h-8 w-8 rounded-full border-2" />
167
+ <button
168
+ className="flex h-10 w-10 items-center justify-center"
169
+ aria-label="Forward 10 seconds"
170
+ >
171
+ <ForwardTenSecondsIcon className="text-fm-icon-active h-6 w-6" />
1040
172
  </button>
1041
- <button className="hover:bg-fm-surface-secondary rounded-lg p-2 transition-colors">
1042
- <ForwardTenSecondsIcon className="text-fm-icon-positive h-6 w-6" />
173
+ <button
174
+ className="flex h-10 w-10 items-center justify-center"
175
+ aria-label="Skip forward"
176
+ >
177
+ <SkipForwardIcon className="text-fm-icon-active h-5 w-5" />
1043
178
  </button>
1044
179
  </div>
1045
180
  </div>
1046
- </div>
181
+ </IconUsageSection>
1047
182
 
1048
- {/* Video Player */}
1049
- <div className="!space-y-2">
1050
- <h3 className="text-fm-icon-active text-sm font-medium">
1051
- Video Player Controls
1052
- </h3>
1053
- <div className="border-fm-divider-secondary bg-fm-surface-secondary rounded-lg border p-4">
1054
- <div className="from-fm-icon-positive/20 to-fm-icon-positive/20 mb-4 h-32 rounded bg-linear-to-r" />
183
+ <IconUsageSection title="Playback Speed Bar">
184
+ <div className="border-fm-divider-secondary bg-fm-surface-secondary w-full max-w-sm rounded-xl border p-4">
1055
185
  <div className="flex items-center justify-between">
1056
- <div className="flex items-center gap-2">
1057
- <span className="text-fm-tertiary text-sm">8:15 / 24:30</span>
1058
- <button className="hover:bg-fm-surface-secondary rounded p-1.5">
1059
- <ForwardTenSecondsIcon className="text-fm-icon-positive h-5 w-5" />
1060
- </button>
1061
- </div>
1062
- <div className="flex items-center gap-2">
1063
- <button className="hover:bg-fm-surface-secondary rounded p-1.5">
1064
- <div className="border-fm-divider-contrast bg-fm-divider-primary h-5 w-5 rounded-full border" />
1065
- </button>
1066
- </div>
186
+ <button aria-label="Rewind 10 seconds">
187
+ <BackwardTenSecondsIcon className="text-fm-icon-active h-5 w-5" />
188
+ </button>
189
+ <span className="text-fm-secondary font-fm-text text-sm">
190
+ 1.0x speed
191
+ </span>
192
+ <button aria-label="Skip forward 10 seconds">
193
+ <ForwardTenSecondsIcon className="text-fm-icon-active h-5 w-5" />
194
+ </button>
1067
195
  </div>
1068
196
  </div>
1069
- </div>
1070
- </div>
197
+ </IconUsageSection>
198
+
199
+ <IconUsageSection title="Lecture Player">
200
+ <div className="border-fm-divider-secondary bg-fm-surface-secondary w-full max-w-sm rounded-xl border p-4">
201
+ <div className="mb-3 flex items-center justify-between">
202
+ <span className="text-fm-primary font-fm-text text-sm font-medium">
203
+ Chapter 3
204
+ </span>
205
+ <span className="text-fm-secondary font-fm-text text-xs">
206
+ 08:45 / 24:00
207
+ </span>
208
+ </div>
209
+ <div className="bg-fm-divider-secondary mb-4 h-1 rounded-full">
210
+ <div className="bg-fm-icon-active h-full w-1/3 rounded-full" />
211
+ </div>
212
+ <div className="flex items-center justify-center gap-5">
213
+ <button aria-label="Rewind 10 seconds">
214
+ <BackwardTenSecondsIcon className="text-fm-icon-active h-6 w-6" />
215
+ </button>
216
+ <button
217
+ className="bg-fm-icon-active flex h-10 w-10 items-center justify-center rounded-full"
218
+ aria-label="Pause"
219
+ >
220
+ <PauseIcon className="text-fm-primary h-4 w-4" />
221
+ </button>
222
+ <button aria-label="Skip forward 10 seconds">
223
+ <ForwardTenSecondsIcon className="text-fm-icon-active h-6 w-6" />
224
+ </button>
225
+ </div>
226
+ </div>
227
+ </IconUsageSection>
228
+ </IconUsageCanvas>
1071
229
  ),
1072
230
  }
1073
231
 
1074
232
  export const Playground: Story = {
1075
- parameters: {
1076
- ...storyParameters,
1077
- docs: {
1078
- description: {
1079
- story:
1080
- "Interactive playground to experiment with different ForwardTenSecondsIcon configurations.",
1081
- },
1082
- },
1083
- },
1084
233
  args: {
1085
- width: 44,
1086
- height: 44,
1087
- className: "text-fm-icon-positive",
234
+ className: "h-8 w-8 text-fm-icon-active",
235
+ withAccessibility: true,
1088
236
  },
1089
237
  render: (args) => (
1090
- <div className="from-fm-surface-primary to-fm-surface-secondary flex h-64 min-h-dvh items-center justify-center rounded-lg bg-linear-to-br">
1091
- <div className="border-fm-divider-secondary bg-fm-surface-secondary rounded-lg border p-8">
1092
- <ForwardTenSecondsIcon {...args} />
1093
- </div>
1094
- </div>
238
+ <IconPlaygroundCanvas>
239
+ <ForwardTenSecondsIcon {...args} />
240
+ </IconPlaygroundCanvas>
1095
241
  ),
1096
242
  }