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,20 @@
1
1
  import React from "react"
2
2
  import type { Meta, StoryObj } from "@storybook/react-vite"
3
3
 
4
+ import { BubbleSparkleIcon } from "src/ui/icons/bubble-sparkle-icon"
5
+ import { LightBulbSimpleIcon } from "src/ui/icons/light-bulb-simple-icon"
6
+ import { MagicBookIcon } from "src/ui/icons/magic-book-icon"
7
+ import { SparklesSoftIcon } from "src/ui/icons/sparkles-soft-icon"
8
+ import {
9
+ IconColorVariations,
10
+ IconDefaultCanvas,
11
+ IconPlaygroundCanvas,
12
+ IconSizeVariations,
13
+ IconUsageCanvas,
14
+ IconUsageSection,
15
+ } from "src/ui/story-spec/icons/icon-story-canvas"
16
+ import { AuralIconDocsPage } from "src/ui/story-spec/icons/icon-story-docs-page"
17
+
4
18
  import { SuggestionIcon } from "."
5
19
 
6
20
  const meta: Meta<typeof SuggestionIcon> = {
@@ -18,727 +32,69 @@ const meta: Meta<typeof SuggestionIcon> = {
18
32
  },
19
33
  docs: {
20
34
  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-info/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-info/10 to-fm-secondary-500/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-info/30 from-fm-icon-info/20 to-fm-secondary-500/20 !mx-auto flex h-24 w-24 items-center justify-center rounded-2xl border bg-linear-to-br">
90
- <SuggestionIcon className="text-fm-icon-info h-12 w-12" />
91
- </div>
92
- <h1 className="!text-fm-primary text-5xl font-bold">
93
- SuggestionIcon
94
- </h1>
95
- <p className="text-fm-secondary! !mx-auto max-w-3xl text-xl leading-relaxed">
96
- A versatile suggestion icon for hints, recommendations, and
97
- guidance elements. Built with accessibility in mind using
98
- Radix UI's AccessibleIcon wrapper.
99
- </p>
100
-
101
- {/* Stats */}
102
- <div className="flex items-center justify-center gap-8 pt-8">
103
- <div className="text-center">
104
- <div className="text-fm-icon-info text-3xl font-bold">
105
- Accessible
106
- </div>
107
- <div className="text-fm-tertiary text-sm">
108
- Screen reader friendly
109
- </div>
110
- </div>
111
- <div className="bg-fm-divider-primary h-8 w-px" />
112
- <div className="text-center">
113
- <div className="text-fm-secondary-600 text-3xl font-bold">
114
- Scalable
115
- </div>
116
- <div className="text-fm-tertiary text-sm">
117
- Any size needed
118
- </div>
119
- </div>
120
- <div className="bg-fm-divider-primary h-8 w-px" />
121
- <div className="text-center">
122
- <div className="text-fm-icon-info text-3xl font-bold">
123
- Flexible
124
- </div>
125
- <div className="text-fm-tertiary text-sm">
126
- Customizable styling
127
- </div>
128
- </div>
129
- </div>
130
- </div>
131
- </div>
132
- </div>
133
-
134
- {/* Content */}
135
- <div className="!mx-auto max-w-7xl !space-y-16 px-6 py-12">
136
- {/* Quick Usage */}
137
- <div className="!space-y-8">
138
- <h2 className="text-fm-icon-active! text-center text-3xl font-bold">
139
- Quick Start
140
- </h2>
141
- <div className="grid grid-cols-1 gap-8 lg:grid-cols-2">
142
- <div className="!space-y-4">
143
- <h3 className="text-fm-icon-info! text-xl font-semibold">
144
- Basic Usage
145
- </h3>
146
- <div className="bg-fm-surface-secondary rounded-lg p-4">
147
- <pre className="text-fm-icon-positive! overflow-x-auto text-sm">
148
- {`import { SuggestionIcon } from "@icons/suggestion-icon"
149
-
150
- function MyComponent() {
35
+ <AuralIconDocsPage
36
+ accentToken="info"
37
+ features={[
38
+ { title: "Suggestion", description: "Content suggestions trigger" },
39
+ { title: "Idea", description: "Idea prompt for creators" },
40
+ { title: "Accessible", description: "ARIA-ready by default" },
41
+ ]}
42
+ quickStart={{
43
+ codeExample: `import { SuggestionIcon } from "src/ui/icons/suggestion-icon"
44
+
45
+ function SuggestButton() {
151
46
  return (
152
- <div className="flex items-center gap-2">
153
- <SuggestionIcon className="h-5 w-5 text-blue-500" />
154
- <span>Try this suggestion</span>
155
- </div>
47
+ <button className="flex items-center gap-2">
48
+ <SuggestionIcon className="h-5 w-5 text-fm-icon-active" />
49
+ <span>Get suggestions</span>
50
+ </button>
156
51
  )
157
- }`}
158
- </pre>
159
- </div>
160
- </div>
161
-
162
- <div className="!space-y-4">
163
- <h3 className="text-fm-icon-info! text-xl font-semibold">
164
- Live Preview
165
- </h3>
166
- <div className="border-fm-divider-secondary bg-fm-surface-secondary flex h-32 items-center justify-center rounded-lg border">
167
- <div className="border-fm-icon-info/20 bg-fm-icon-info/10 flex items-center gap-3 rounded-lg border px-4 py-2">
168
- <SuggestionIcon className="text-fm-icon-info h-5 w-5" />
169
- <span className="text-fm-icon-active">
170
- Try this suggestion
171
- </span>
172
- </div>
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-info! 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
- 24
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-info! px-6 py-4 font-mono text-sm">
239
- fill
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
- Fill 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-info! px-6 py-4 font-mono text-sm">
253
- className
254
- </td>
255
- <td className="text-fm-secondary! px-6 py-4 text-sm">
256
- string
257
- </td>
258
- <td className="text-fm-placeholder! px-6 py-4 text-sm">
259
- undefined
260
- </td>
261
- <td className="text-fm-secondary! px-6 py-4 text-sm">
262
- CSS classes for styling
263
- </td>
264
- </tr>
265
- <tr className="border-fm-divider-tertiary border-b">
266
- <td className="text-fm-icon-info! px-6 py-4 font-mono text-sm">
267
- stroke
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
- currentColor
274
- </td>
275
- <td className="text-fm-secondary! px-6 py-4 text-sm">
276
- Stroke color of the icon
277
- </td>
278
- </tr>
279
- <tr className="bg-fm-surface-secondary!">
280
- <td className="text-fm-icon-info! px-6 py-4 font-mono text-sm">
281
- strokeWidth
282
- </td>
283
- <td className="text-fm-secondary! px-6 py-4 text-sm">
284
- number | string
285
- </td>
286
- <td className="text-fm-placeholder! px-6 py-4 text-sm">
287
- 1
288
- </td>
289
- <td className="text-fm-secondary! px-6 py-4 text-sm">
290
- Width of the stroke
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-info! text-lg font-semibold">
308
- Common Sizes
309
- </h3>
310
- <div className="flex items-center gap-6">
311
- <div className="text-center">
312
- <SuggestionIcon className="text-fm-icon-info !mx-auto mb-2 h-4 w-4" />
313
- <span className="text-fm-tertiary text-xs">
314
- 16px
315
- </span>
316
- </div>
317
- <div className="text-center">
318
- <SuggestionIcon className="text-fm-icon-info !mx-auto mb-2 h-5 w-5" />
319
- <span className="text-fm-tertiary text-xs">
320
- 20px
321
- </span>
322
- </div>
323
- <div className="text-center">
324
- <SuggestionIcon className="text-fm-icon-info !mx-auto mb-2 h-6 w-6" />
325
- <span className="text-fm-tertiary text-xs">
326
- 24px
327
- </span>
328
- </div>
329
- <div className="text-center">
330
- <SuggestionIcon className="text-fm-icon-info !mx-auto mb-2 h-8 w-8" />
331
- <span className="text-fm-tertiary text-xs">
332
- 32px
333
- </span>
334
- </div>
335
- </div>
336
- </div>
337
-
338
- <div className="!space-y-4">
339
- <h3 className="text-fm-icon-info! text-lg font-semibold">
340
- Large Displays
341
- </h3>
342
- <div className="flex items-center gap-6">
343
- <div className="text-center">
344
- <SuggestionIcon className="text-fm-icon-info !mx-auto mb-2 h-12 w-12" />
345
- <span className="text-fm-tertiary text-xs">
346
- 48px
347
- </span>
348
- </div>
349
- <div className="text-center">
350
- <SuggestionIcon className="text-fm-icon-info !mx-auto mb-2 h-16 w-16" />
351
- <span className="text-fm-tertiary text-xs">
352
- 64px
353
- </span>
354
- </div>
355
- </div>
356
- </div>
357
- </div>
358
- </div>
359
- </div>
360
- </div>
361
-
362
- {/* Color Variations */}
363
- <div className="!space-y-8">
364
- <h2 className="text-fm-icon-active! text-center text-3xl font-bold">
365
- Color Variations
366
- </h2>
367
- <div className="grid grid-cols-1 gap-8 lg:grid-cols-2">
368
- <div className="!space-y-4">
369
- <h3 className="text-fm-icon-info! text-lg font-semibold">
370
- Semantic Colors
371
- </h3>
372
- <div className="border-fm-divider-secondary bg-fm-surface-secondary !space-y-4 rounded-lg border p-6">
373
- <div className="flex items-center gap-4">
374
- <SuggestionIcon className="text-fm-icon-info h-6 w-6" />
375
- <span className="text-fm-icon-info">
376
- Primary suggestion
377
- </span>
378
- </div>
379
- <div className="flex items-center gap-4">
380
- <SuggestionIcon className="text-fm-secondary-600 h-6 w-6" />
381
- <span className="text-fm-secondary-600">Hint</span>
382
- </div>
383
- <div className="flex items-center gap-4">
384
- <SuggestionIcon className="text-fm-icon-info h-6 w-6" />
385
- <span className="text-fm-icon-info">
386
- Recommendation
387
- </span>
388
- </div>
389
- <div className="flex items-center gap-4">
390
- <SuggestionIcon className="text-fm-icon-info h-6 w-6" />
391
- <span className="text-fm-icon-info">Tip</span>
392
- </div>
393
- </div>
394
- </div>
395
-
396
- <div className="!space-y-4">
397
- <h3 className="text-fm-icon-info! text-lg font-semibold">
398
- Custom Colors
399
- </h3>
400
- <div className="bg-fm-surface-secondary rounded-lg p-4">
401
- <pre className="text-fm-icon-positive! overflow-x-auto text-sm">
402
- {`// Using Tailwind classes
403
- <SuggestionIcon className="h-6 w-6 text-blue-500" />
404
- <SuggestionIcon className="h-6 w-6 text-purple-500" />
405
- <SuggestionIcon className="h-6 w-6 text-indigo-500" />
406
-
407
- // Using custom colors
408
- <SuggestionIcon
409
- className="h-6 w-6"
410
- style={{ color: '#3B82F6' }}
411
- />`}
412
- </pre>
413
- </div>
414
- </div>
415
- </div>
416
- </div>
417
-
418
- {/* Usage Examples */}
419
- <div className="!space-y-8">
420
- <h2 className="text-fm-icon-active! text-center text-3xl font-bold">
421
- Usage Examples
422
- </h2>
423
-
424
- <div className="grid grid-cols-1 gap-8 lg:grid-cols-2">
425
- {/* Suggestion Card */}
426
- <div className="!space-y-4">
427
- <h3 className="text-fm-icon-info! text-lg font-semibold">
428
- Suggestion Card
429
- </h3>
430
- <div className="!space-y-4">
431
- <div className="border-fm-icon-info/20 bg-fm-icon-info/10 rounded-lg border p-4">
432
- <div className="flex items-start gap-3">
433
- <SuggestionIcon className="text-fm-icon-info mt-0.5 h-5 w-5 flex-shrink-0" />
434
- <div>
435
- <h4 className="text-fm-icon-info! font-medium">
436
- Pro Tip
437
- </h4>
438
- <p className="text-fm-icon-info!/80 text-sm">
439
- Use keyboard shortcuts to speed up your workflow.
440
- </p>
441
- </div>
442
- </div>
443
- </div>
444
- <div className="bg-fm-surface-secondary rounded-lg p-4">
445
- <pre className="text-fm-icon-positive! overflow-x-auto text-sm">
446
- {`<div className="border border-blue-500/20 bg-blue-500/10 p-4">
447
- <div className="flex items-start gap-3">
448
- <SuggestionIcon className="h-5 w-5 text-blue-400" />
449
- <div>
450
- <h4>Pro Tip</h4>
451
- <p>Use keyboard shortcuts...</p>
452
- </div>
453
- </div>
454
- </div>`}
455
- </pre>
456
- </div>
457
- </div>
458
- </div>
459
-
460
- {/* Help Text */}
461
- <div className="!space-y-4">
462
- <h3 className="text-fm-icon-info! text-lg font-semibold">
463
- Help Text
464
- </h3>
465
- <div className="!space-y-4">
466
- <div className="!space-y-2">
467
- <label className="text-fm-icon-active block text-sm font-medium">
468
- Username
469
- </label>
470
- <input
471
- type="text"
472
- className="border-fm-divider-primary bg-fm-surface-secondary text-fm-icon-active w-full rounded-lg border px-3 py-2 placeholder-white/50"
473
- placeholder="Enter username"
474
- />
475
- <div className="text-fm-icon-info flex items-center gap-2 text-sm">
476
- <SuggestionIcon className="h-4 w-4" />
477
- <span>Use at least 3 characters</span>
478
- </div>
479
- </div>
480
- <div className="bg-fm-surface-secondary rounded-lg p-4">
481
- <pre className="text-fm-icon-positive! overflow-x-auto text-sm">
482
- {`<div className="flex items-center gap-2 text-blue-400">
483
- <SuggestionIcon className="h-4 w-4" />
484
- <span>Use at least 3 characters</span>
485
- </div>`}
486
- </pre>
487
- </div>
488
- </div>
489
- </div>
490
-
491
- {/* Button Integration */}
492
- <div className="!space-y-4">
493
- <h3 className="text-fm-icon-info! text-lg font-semibold">
494
- Button Integration
495
- </h3>
496
- <div className="!space-y-4">
497
- <div className="flex gap-4">
498
- <button className="border-fm-icon-info/30 bg-fm-icon-info/20 text-fm-icon-info hover:bg-fm-icon-info/30 flex items-center gap-2 rounded-lg border px-4 py-2 transition-colors">
499
- <SuggestionIcon className="h-4 w-4" />
500
- Show Hints
501
- </button>
502
- <button className="border-fm-secondary-500/30 bg-fm-secondary-500/20 text-fm-secondary-600 hover:bg-fm-secondary-500/30 flex items-center gap-2 rounded-lg border px-4 py-2 transition-colors">
503
- <SuggestionIcon className="h-4 w-4" />
504
- Get Suggestions
505
- </button>
506
- </div>
507
- <div className="bg-fm-surface-secondary rounded-lg p-4">
508
- <pre className="text-fm-icon-positive! overflow-x-auto text-sm">
509
- {`<button className="flex items-center gap-2">
510
- <SuggestionIcon className="h-4 w-4" />
511
- Show Hints
512
- </button>`}
513
- </pre>
514
- </div>
515
- </div>
516
- </div>
517
-
518
- {/* Tooltip */}
519
- <div className="!space-y-4">
520
- <h3 className="text-fm-icon-info! text-lg font-semibold">
521
- Interactive Tooltip
522
- </h3>
523
- <div className="!space-y-4">
524
- <div className="flex items-center gap-2">
525
- <span className="text-fm-icon-active">Need help?</span>
526
- <div className="group relative">
527
- <SuggestionIcon className="text-fm-icon-info h-4 w-4 cursor-help" />
528
- <div className="bg-fm-surface-primary text-fm-icon-active invisible absolute bottom-full left-1/2 mb-2 -translate-x-1/2 transform rounded px-2 py-1 text-xs opacity-0 transition-all group-hover:visible group-hover:opacity-100">
529
- Click for suggestions
530
- </div>
531
- </div>
532
- </div>
533
- <div className="bg-fm-surface-secondary rounded-lg p-4">
534
- <pre className="text-fm-icon-positive! overflow-x-auto text-sm">
535
- {`<div className="group relative">
536
- <SuggestionIcon className="h-4 w-4 cursor-help text-blue-400" />
537
- <div className="tooltip">Click for suggestions</div>
538
- </div>`}
539
- </pre>
540
- </div>
541
- </div>
542
- </div>
543
- </div>
544
- </div>
545
-
546
- {/* Accessibility */}
547
- <div className="!space-y-8">
548
- <h2 className="text-fm-icon-active! text-center text-3xl font-bold">
549
- Accessibility Features
550
- </h2>
551
- <div className="grid grid-cols-1 gap-8 md:grid-cols-2">
552
- <div className="border-fm-divider-secondary bg-fm-surface-secondary !space-y-4 rounded-lg border p-6">
553
- <h3 className="text-fm-icon-positive! text-lg font-semibold">
554
- ✅ Built-in Features
555
- </h3>
556
- <ul className="text-fm-secondary! !space-y-2 text-sm">
557
- <li className="text-fm-secondary!">
558
- Uses Radix UI AccessibleIcon wrapper
559
- </li>
560
- <li className="text-fm-secondary!">
561
- Provides screen reader label "Suggestion icon"
562
- </li>
563
- <li className="text-fm-secondary!">
564
- Supports keyboard navigation when interactive
565
- </li>
566
- <li className="text-fm-secondary!">
567
- Maintains proper color contrast ratios
568
- </li>
569
- <li className="text-fm-secondary!">
570
- Scales with user's font size preferences
571
- </li>
572
- </ul>
573
- </div>
574
-
575
- <div className="border-fm-divider-secondary bg-fm-surface-secondary !space-y-4 rounded-lg border p-6">
576
- <h3 className="text-fm-icon-info! text-lg font-semibold">
577
- 💡 Best Practices
578
- </h3>
579
- <ul className="text-fm-secondary !space-y-2 text-sm">
580
- <li className="text-fm-secondary!">
581
- Always pair with descriptive text
582
- </li>
583
- <li className="text-fm-secondary!">
584
- Use consistent colors for suggestion types
585
- </li>
586
- <li className="text-fm-secondary!">
587
- Ensure sufficient color contrast
588
- </li>
589
- <li className="text-fm-secondary!">
590
- Add focus states for interactive elements
591
- </li>
592
- <li className="text-fm-secondary!">
593
- Provide alternative text for screen readers
594
- </li>
595
- </ul>
596
- </div>
597
- </div>
598
-
599
- <div className="border-fm-divider-secondary bg-fm-surface-secondary rounded-lg border p-6">
600
- <h3 className="text-fm-secondary-600! mb-4 text-lg font-semibold">
601
- Custom Accessibility Label
602
- </h3>
603
- <div className="grid grid-cols-1 gap-6 lg:grid-cols-2">
604
- <div className="bg-fm-surface-secondary rounded-lg p-4">
605
- <pre className="text-fm-icon-info! overflow-x-auto text-sm">
606
- {`import { AccessibleIcon } from "@radix-ui/react-accessible-icon"
607
- import { SuggestionIcon } from "@icons/suggestion-icon"
608
-
609
- <AccessibleIcon label="Helpful tip available">
610
- <SuggestionIcon className="h-4 w-4 text-blue-500" />
611
- </AccessibleIcon>`}
612
- </pre>
613
- </div>
614
- <div className="!space-y-4">
615
- <p className="text-fm-secondary! text-sm">
616
- For specific contexts, you can wrap the SuggestionIcon
617
- with a custom AccessibleIcon component that provides
618
- more descriptive labels.
619
- </p>
620
- <div className="border-fm-icon-info/20 bg-fm-icon-info/10 rounded-lg border p-4">
621
- <div className="text-fm-icon-info flex items-center gap-2">
622
- <SuggestionIcon className="h-4 w-4" />
623
- <span>Helpful tip available</span>
624
- </div>
625
- </div>
626
- </div>
627
- </div>
628
- </div>
629
- </div>
630
-
631
- {/* Related Icons */}
632
- <div className="!space-y-8">
633
- <h2 className="text-fm-icon-active! text-center text-3xl font-bold">
634
- Related Icons
635
- </h2>
636
- <div className="grid grid-cols-2 gap-6 md:grid-cols-4">
637
- <div className="border-fm-divider-secondary bg-fm-surface-secondary !space-y-3 rounded-lg border p-4 text-center">
638
- <div className="bg-fm-icon-info/20 !mx-auto flex h-12 w-12 items-center justify-center rounded-lg">
639
- <span className="text-2xl">ℹ️</span>
640
- </div>
641
- <div>
642
- <div className="text-fm-icon-active font-medium">
643
- InfoIcon
644
- </div>
645
- <div className="text-fm-tertiary text-xs">
646
- Information states
647
- </div>
648
- </div>
649
- </div>
650
- <div className="border-fm-divider-secondary bg-fm-surface-secondary !space-y-3 rounded-lg border p-4 text-center">
651
- <div className="bg-fm-icon-warning/20 !mx-auto flex h-12 w-12 items-center justify-center rounded-lg">
652
- <span className="text-2xl">💡</span>
653
- </div>
654
- <div>
655
- <div className="text-fm-icon-active font-medium">
656
- LightbulbIcon
657
- </div>
658
- <div className="text-fm-tertiary text-xs">
659
- Ideas & tips
660
- </div>
661
- </div>
662
- </div>
663
- <div className="border-fm-divider-secondary bg-fm-surface-secondary !space-y-3 rounded-lg border p-4 text-center">
664
- <div className="bg-fm-secondary-500/20 !mx-auto flex h-12 w-12 items-center justify-center rounded-lg">
665
- <span className="text-2xl">❓</span>
666
- </div>
667
- <div>
668
- <div className="text-fm-icon-active font-medium">
669
- HelpIcon
670
- </div>
671
- <div className="text-fm-tertiary text-xs">
672
- Help & guidance
673
- </div>
674
- </div>
675
- </div>
676
- <div className="border-fm-divider-secondary bg-fm-surface-secondary !space-y-3 rounded-lg border p-4 text-center">
677
- <div className="bg-fm-icon-positive/20 !mx-auto flex h-12 w-12 items-center justify-center rounded-lg">
678
- <span className="text-2xl">✨</span>
679
- </div>
680
- <div>
681
- <div className="text-fm-icon-active font-medium">
682
- SparkleIcon
683
- </div>
684
- <div className="text-fm-tertiary text-xs">
685
- Enhancement
686
- </div>
687
- </div>
688
- </div>
689
- </div>
690
- </div>
691
- </div>
692
-
693
- {/* Footer */}
694
- <div className="border-fm-divider-secondary bg-fm-surface-secondary border-t backdrop-blur-xl">
695
- <div className="!mx-auto max-w-7xl px-6 py-8">
696
- <div className="!space-y-4 text-center">
697
- <p className="text-fm-tertiary!">
698
- SuggestionIcon is part of the Aural UI icon library, built
699
- with accessibility and consistency in mind.
700
- </p>
701
- <p className="text-fm-placeholder! text-sm">
702
- All icons use Radix UI's AccessibleIcon for screen reader
703
- compatibility and follow WCAG guidelines.
704
- </p>
705
- </div>
706
- </div>
707
- </div>
708
- </div>
709
- </>
52
+ }`,
53
+ livePreview: (
54
+ <button className="flex items-center gap-2">
55
+ <SuggestionIcon className="text-fm-icon-active h-6 w-6" />
56
+ </button>
57
+ ),
58
+ }}
59
+ relatedIcons={[
60
+ {
61
+ name: "LightBulbSimpleIcon",
62
+ description: "Insight / tip indicator icon",
63
+ icon: LightBulbSimpleIcon,
64
+ accentToken: "info",
65
+ },
66
+ {
67
+ name: "BubbleSparkleIcon",
68
+ description: "AI sparkle bubble icon",
69
+ icon: BubbleSparkleIcon,
70
+ accentToken: "positive",
71
+ },
72
+ {
73
+ name: "SparklesSoftIcon",
74
+ description: "Soft sparkle / AI glow icon",
75
+ icon: SparklesSoftIcon,
76
+ accentToken: "warning",
77
+ },
78
+ {
79
+ name: "MagicBookIcon",
80
+ description: "AI-assisted story creation",
81
+ icon: MagicBookIcon,
82
+ accentToken: "negative",
83
+ },
84
+ ]}
85
+ />
710
86
  ),
711
87
  },
712
88
  },
713
89
  tags: ["autodocs"],
714
90
  argTypes: {
715
- width: {
716
- control: { type: "range", min: 8, max: 96, step: 2 },
717
- description: "Width of the icon in pixels",
718
- },
719
- withAccessibility: {
720
- control: "boolean",
721
- description: "Whether to wrap the icon with accessibility features",
722
- },
723
- height: {
724
- control: { type: "range", min: 8, max: 96, step: 2 },
725
- description: "Height of the icon in pixels",
726
- },
727
- fill: {
728
- control: "color",
729
- description: "Fill color of the icon",
730
- },
731
91
  className: {
732
92
  control: "text",
733
- description: "CSS classes for styling",
93
+ description: "CSS classes including color token",
734
94
  },
735
- stroke: {
736
- control: "color",
737
- description: "Stroke color of the icon",
738
- },
739
- strokeWidth: {
740
- control: { type: "range", min: 0.5, max: 3, step: 0.1 },
741
- description: "Width of the stroke",
95
+ withAccessibility: {
96
+ control: "boolean",
97
+ description: "Wrap with accessibility label",
742
98
  },
743
99
  },
744
100
  }
@@ -746,212 +102,78 @@ import { SuggestionIcon } from "@icons/suggestion-icon"
746
102
  export default meta
747
103
  type Story = StoryObj<typeof SuggestionIcon>
748
104
 
749
- // Story parameters for consistent dark theme
750
- const storyParameters = {
751
- backgrounds: {
752
- default: "dark",
753
- values: [
754
- { name: "dark", value: "var(--color-fm-surface-primary)" },
755
- { name: "darker", value: "var(--color-fm-neutral-0)" },
756
- ],
757
- },
758
- }
759
-
760
105
  export const Default: Story = {
761
106
  args: {
762
- width: 24,
763
- height: 24,
764
- className: "text-fm-icon-info",
107
+ className: "h-6 w-6 text-fm-icon-active",
765
108
  withAccessibility: true,
766
109
  },
767
- parameters: storyParameters,
768
110
  render: (args) => (
769
- <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">
111
+ <IconDefaultCanvas>
770
112
  <SuggestionIcon {...args} />
771
- </div>
113
+ </IconDefaultCanvas>
772
114
  ),
773
115
  }
774
116
 
775
117
  export const SizeVariations: Story = {
776
- parameters: {
777
- ...storyParameters,
778
- docs: {
779
- description: {
780
- story:
781
- "SuggestionIcon in different sizes, from small UI elements to large displays.",
782
- },
783
- },
784
- },
785
- render: () => (
786
- <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">
787
- <div className="text-center">
788
- <SuggestionIcon className="text-fm-icon-info !mx-auto mb-2 h-3 w-3" />
789
- <span className="text-fm-tertiary text-xs">12px</span>
790
- </div>
791
- <div className="text-center">
792
- <SuggestionIcon className="text-fm-icon-info !mx-auto mb-2 h-4 w-4" />
793
- <span className="text-fm-tertiary text-xs">16px</span>
794
- </div>
795
- <div className="text-center">
796
- <SuggestionIcon className="text-fm-icon-info !mx-auto mb-2 h-5 w-5" />
797
- <span className="text-fm-tertiary text-xs">20px</span>
798
- </div>
799
- <div className="text-center">
800
- <SuggestionIcon className="text-fm-icon-info !mx-auto mb-2 h-6 w-6" />
801
- <span className="text-fm-tertiary text-xs">24px</span>
802
- </div>
803
- <div className="text-center">
804
- <SuggestionIcon className="text-fm-icon-info !mx-auto mb-2 h-8 w-8" />
805
- <span className="text-fm-tertiary text-xs">32px</span>
806
- </div>
807
- <div className="text-center">
808
- <SuggestionIcon className="text-fm-icon-info !mx-auto mb-2 h-12 w-12" />
809
- <span className="text-fm-tertiary text-xs">48px</span>
810
- </div>
811
- </div>
812
- ),
118
+ render: () => <IconSizeVariations icon={SuggestionIcon} />,
813
119
  }
814
120
 
815
121
  export const ColorVariations: Story = {
816
- parameters: {
817
- ...storyParameters,
818
- docs: {
819
- description: {
820
- story:
821
- "SuggestionIcon in different semantic colors for various suggestion types.",
822
- },
823
- },
824
- },
825
- render: () => (
826
- <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">
827
- <div className="text-center">
828
- <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">
829
- <SuggestionIcon className="text-fm-icon-info h-8 w-8" />
830
- </div>
831
- <div className="text-fm-icon-active text-sm font-medium">Primary</div>
832
- <div className="text-fm-icon-info text-xs">text-fm-icon-info</div>
833
- </div>
834
- <div className="text-center">
835
- <div className="border-fm-secondary-500/30 bg-fm-secondary-500/20 !mx-auto mb-3 flex h-16 w-16 items-center justify-center rounded-lg border">
836
- <SuggestionIcon className="text-fm-secondary-600 h-8 w-8" />
837
- </div>
838
- <div className="text-fm-icon-active text-sm font-medium">Hint</div>
839
- <div className="text-fm-secondary-600 text-xs">
840
- text-fm-secondary-600
841
- </div>
842
- </div>
843
- <div className="text-center">
844
- <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">
845
- <SuggestionIcon className="text-fm-icon-info h-8 w-8" />
846
- </div>
847
- <div className="text-fm-icon-active text-sm font-medium">
848
- Recommendation
849
- </div>
850
- <div className="text-fm-icon-info text-xs">text-fm-icon-info</div>
851
- </div>
852
- <div className="text-center">
853
- <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">
854
- <SuggestionIcon className="text-fm-icon-info h-8 w-8" />
855
- </div>
856
- <div className="text-fm-icon-active text-sm font-medium">Tip</div>
857
- <div className="text-fm-icon-info text-xs">text-fm-icon-info</div>
858
- </div>
859
- </div>
860
- ),
122
+ render: () => <IconColorVariations icon={SuggestionIcon} />,
861
123
  }
862
124
 
863
125
  export const UsageExamples: Story = {
864
- parameters: {
865
- ...storyParameters,
866
- docs: {
867
- description: {
868
- story:
869
- "Real-world usage examples showing SuggestionIcon in different UI contexts.",
870
- },
871
- },
872
- },
873
126
  render: () => (
874
- <div className="from-fm-surface-primary to-fm-surface-secondary min-h-dvh !space-y-8 rounded-lg bg-linear-to-br p-8">
875
- {/* Suggestion Card */}
876
- <div className="!space-y-2">
877
- <h3 className="text-fm-icon-active text-sm font-medium">
878
- Suggestion Card
879
- </h3>
880
- <div className="border-fm-icon-info/20 bg-fm-icon-info/10 rounded-lg border p-4">
881
- <div className="flex items-start gap-3">
882
- <SuggestionIcon className="text-fm-icon-info mt-0.5 h-5 w-5 flex-shrink-0" />
883
- <div>
884
- <h4 className="text-fm-icon-info font-medium">Pro Tip</h4>
885
- <p className="text-fm-icon-info/80 text-sm">
886
- Use keyboard shortcuts Cmd+K to open the command palette
887
- quickly.
888
- </p>
889
- </div>
127
+ <IconUsageCanvas>
128
+ <IconUsageSection title="Suggest Button">
129
+ <button className="border-fm-divider-secondary bg-fm-surface-secondary flex items-center gap-2 rounded-xl border px-4 py-2">
130
+ <SuggestionIcon className="text-fm-icon-active h-4 w-4" />
131
+ <span className="text-fm-primary font-fm-text text-sm">
132
+ Get suggestions
133
+ </span>
134
+ </button>
135
+ </IconUsageSection>
136
+
137
+ <IconUsageSection title="Suggestion Card">
138
+ <div className="border-fm-divider-secondary bg-fm-surface-secondary w-full max-w-sm rounded-xl border p-4">
139
+ <div className="mb-2 flex items-center gap-2">
140
+ <SuggestionIcon className="text-fm-icon-active h-5 w-5" />
141
+ <span className="text-fm-primary font-fm-text text-sm font-medium">
142
+ Writing Prompt
143
+ </span>
890
144
  </div>
145
+ <p className="text-fm-secondary font-fm-text text-xs">
146
+ What if the hero discovers a hidden power in the final act?
147
+ </p>
891
148
  </div>
892
- </div>
893
-
894
- {/* Help Text */}
895
- <div className="!space-y-2">
896
- <h3 className="text-fm-icon-active text-sm font-medium">
897
- Form Help Text
898
- </h3>
899
- <div className="!space-y-2">
900
- <div className="relative">
901
- <input
902
- type="text"
903
- className="border-fm-divider-primary bg-fm-surface-secondary text-fm-icon-active focus:border-fm-icon-info w-full rounded-lg border px-3 py-2 placeholder-white/50 focus:ring-2 focus:ring-blue-500/20"
904
- placeholder="Enter username"
905
- />
906
- </div>
907
- <div className="text-fm-icon-info flex items-center gap-2 text-sm">
908
- <SuggestionIcon className="h-4 w-4" />
909
- <span>Username should be at least 3 characters long</span>
910
- </div>
149
+ </IconUsageSection>
150
+
151
+ <IconUsageSection title="AI Toolbar">
152
+ <div className="border-fm-divider-secondary bg-fm-surface-secondary flex items-center gap-2 rounded-xl border px-3 py-2">
153
+ {[SuggestionIcon, BubbleSparkleIcon, LightBulbSimpleIcon].map(
154
+ (Icon, i) => (
155
+ <button
156
+ key={i}
157
+ className="flex h-8 w-8 items-center justify-center rounded-lg"
158
+ >
159
+ <Icon className="text-fm-icon-active h-4 w-4" />
160
+ </button>
161
+ )
162
+ )}
911
163
  </div>
912
- </div>
913
-
914
- {/* Button Integration */}
915
- <div className="!space-y-2">
916
- <h3 className="text-fm-icon-active text-sm font-medium">
917
- Button Integration
918
- </h3>
919
- <div className="flex gap-4">
920
- <button className="border-fm-icon-info/30 bg-fm-icon-info/20 text-fm-icon-info hover:bg-fm-icon-info/30 flex items-center gap-2 rounded-lg border px-4 py-2 transition-colors">
921
- <SuggestionIcon className="h-4 w-4" />
922
- Show Hints
923
- </button>
924
- <button className="border-fm-secondary-500/30 bg-fm-secondary-500/20 text-fm-secondary-600 hover:bg-fm-secondary-500/30 flex items-center gap-2 rounded-lg border px-4 py-2 transition-colors">
925
- <SuggestionIcon className="h-4 w-4" />
926
- Get Suggestions
927
- </button>
928
- </div>
929
- </div>
930
- </div>
164
+ </IconUsageSection>
165
+ </IconUsageCanvas>
931
166
  ),
932
167
  }
933
168
 
934
169
  export const Playground: Story = {
935
- parameters: {
936
- ...storyParameters,
937
- docs: {
938
- description: {
939
- story:
940
- "Interactive playground to experiment with different SuggestionIcon configurations.",
941
- },
942
- },
943
- },
944
170
  args: {
945
- width: 32,
946
- height: 32,
947
- className: "text-fm-icon-info",
948
- strokeWidth: 1,
171
+ className: "h-8 w-8 text-fm-icon-active",
172
+ withAccessibility: true,
949
173
  },
950
174
  render: (args) => (
951
- <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">
952
- <div className="border-fm-divider-secondary bg-fm-surface-secondary rounded-lg border p-8">
953
- <SuggestionIcon {...args} />
954
- </div>
955
- </div>
175
+ <IconPlaygroundCanvas>
176
+ <SuggestionIcon {...args} />
177
+ </IconPlaygroundCanvas>
956
178
  ),
957
179
  }