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,20 @@
1
1
  import React from "react"
2
2
  import type { Meta, StoryObj } from "@storybook/react-vite"
3
3
 
4
+ import { FileTextIcon } from "src/ui/icons/file-text-icon"
5
+ import { NotepadIcon } from "src/ui/icons/notepad-icon"
6
+ import { NotesIcon } from "src/ui/icons/notes-icon"
7
+ import { PageTextIcon } from "src/ui/icons/page-text-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 { FileChartIcon } from "."
5
19
 
6
20
  const meta: Meta<typeof FileChartIcon> = {
@@ -18,914 +32,72 @@ const meta: Meta<typeof FileChartIcon> = {
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="bg-fm-surface-primary min-h-screen">
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-icon-info/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-icon-info/20 !mx-auto flex h-24 w-24 items-center justify-center rounded-2xl border bg-linear-to-br">
90
- <FileChartIcon className="text-fm-icon-info h-12 w-12" />
91
- </div>
92
- <h1 className="!text-fm-primary text-5xl font-bold">
93
- FileChartIcon
94
- </h1>
95
- <p className="text-fm-secondary! !mx-auto max-w-3xl text-xl leading-relaxed">
96
- A comprehensive file chart icon representing analytics,
97
- reports, and data visualization documents. Perfect for
98
- dashboard applications, analytics platforms, reporting
99
- systems, and document management interfaces. Features a
100
- clean document outline with integrated chart elements. Built
101
- with accessibility in mind using Radix UI's AccessibleIcon
102
- wrapper.
103
- </p>
104
-
105
- {/* Stats */}
106
- <div className="flex items-center justify-center gap-8 pt-8">
107
- <div className="text-center">
108
- <div className="text-fm-icon-info text-3xl font-bold">
109
- Analytics
110
- </div>
111
- <div className="text-fm-tertiary text-sm">
112
- Data visualization
113
- </div>
114
- </div>
115
- <div className="bg-fm-divider-primary h-8 w-px" />
116
- <div className="text-center">
117
- <div className="text-fm-icon-info text-3xl font-bold">
118
- Reports
119
- </div>
120
- <div className="text-fm-tertiary text-sm">
121
- Document representation
122
- </div>
123
- </div>
124
- <div className="bg-fm-divider-primary h-8 w-px" />
125
- <div className="text-center">
126
- <div className="text-fm-icon-positive text-3xl font-bold">
127
- Dashboard
128
- </div>
129
- <div className="text-fm-tertiary text-sm">
130
- Chart integration
131
- </div>
132
- </div>
133
- </div>
134
- </div>
135
- </div>
136
- </div>
137
-
138
- {/* Content */}
139
- <div className="!mx-auto max-w-7xl !space-y-16 px-6 py-12">
140
- {/* Quick Usage */}
141
- <div className="!space-y-8">
142
- <h2 className="text-fm-icon-active! text-center text-3xl font-bold">
143
- Quick Start
144
- </h2>
145
- <div className="grid grid-cols-1 gap-8 lg:grid-cols-2">
146
- <div className="!space-y-4">
147
- <h3 className="text-fm-icon-info! text-xl font-semibold">
148
- Basic Usage
149
- </h3>
150
- <div className="bg-fm-surface-secondary rounded-lg p-4">
151
- <pre className="text-fm-icon-positive! overflow-x-auto text-sm">
152
- {`import { FileChartIcon } from "@icons/file-chart-icon"
153
-
154
- function ReportsSection() {
35
+ <AuralIconDocsPage
36
+ accentToken="info"
37
+ features={[
38
+ {
39
+ title: "Analytics File",
40
+ description: "Chart / data report file",
41
+ },
42
+ { title: "Reports", description: "Performance data documents" },
43
+ { title: "Accessible", description: "ARIA-ready by default" },
44
+ ]}
45
+ quickStart={{
46
+ codeExample: `import { FileChartIcon } from "src/ui/icons/file-chart-icon"
47
+
48
+ function ReportItem() {
155
49
  return (
156
- <div className="flex items-center gap-3">
157
- <FileChartIcon className="h-6 w-6 text-blue-400 " />
158
- <div>
159
- <h3 className="font-semibold">Analytics Report</h3>
160
- <p className="text-sm text-gray-500">Q4 Performance Data</p>
161
- </div>
50
+ <div className="flex items-center gap-2">
51
+ <FileChartIcon className="h-5 w-5 text-fm-icon-active" />
52
+ <span>Analytics Report</span>
162
53
  </div>
163
54
  )
164
- }`}
165
- </pre>
166
- </div>
167
- </div>
168
-
169
- <div className="!space-y-4">
170
- <h3 className="text-fm-icon-info! text-xl font-semibold">
171
- Live Preview
172
- </h3>
173
- <div className="border-fm-divider-secondary bg-fm-surface-secondary flex h-32 items-center justify-center rounded-lg border">
174
- <div className="border-fm-icon-info/20 bg-fm-icon-info/10 flex items-start gap-3 rounded-lg border px-4 py-3">
175
- <FileChartIcon className="text-fm-icon-info h-6 w-6" />
176
- <div>
177
- <h3 className="text-fm-icon-active! font-semibold">
178
- Analytics Report
179
- </h3>
180
- <p className="text-fm-icon-info!/80 text-sm">
181
- Q4 Performance Data
182
- </p>
183
- </div>
184
- </div>
185
- </div>
186
- </div>
187
- </div>
188
- </div>
189
-
190
- {/* Props Documentation */}
191
- <div className="!space-y-8">
192
- <h2 className="text-fm-icon-active! text-center text-3xl font-bold">
193
- Props & Configuration
194
- </h2>
195
-
196
- <div className="border-fm-divider-secondary bg-fm-surface-secondary overflow-hidden rounded-lg border">
197
- <div className="bg-fm-surface-secondary p-4">
198
- <h3 className="text-fm-icon-active! text-xl font-semibold">
199
- Props
200
- </h3>
201
- </div>
202
- <table className="!my-0 w-full">
203
- <thead className="bg-fm-surface-secondary">
204
- <tr className="border-fm-divider-secondary border-b">
205
- <th className="text-fm-icon-active! px-6 py-4 text-left text-sm font-semibold">
206
- Prop
207
- </th>
208
- <th className="text-fm-icon-active! px-6 py-4 text-left text-sm font-semibold">
209
- Type
210
- </th>
211
- <th className="text-fm-icon-active! px-6 py-4 text-left text-sm font-semibold">
212
- Default
213
- </th>
214
- <th className="text-fm-icon-active! px-6 py-4 text-left text-sm font-semibold">
215
- Description
216
- </th>
217
- </tr>
218
- </thead>
219
- <tbody>
220
- {" "}
221
- <tr className="bg-fm-surface-secondary!">
222
- <td className="text-fm-icon-info! px-6 py-4 font-mono text-sm">
223
- withAccessibility
224
- </td>
225
- <td className="text-fm-secondary! px-6 py-4 text-sm">
226
- boolean
227
- </td>
228
- <td className="text-fm-placeholder! px-6 py-4 text-sm">
229
- true
230
- </td>
231
- <td className="text-fm-secondary! px-6 py-4 text-sm">
232
- Whether to wrap the icon with accessibility feature
233
- </td>
234
- </tr>
235
- <tr className="border-fm-divider-tertiary bg-fm-surface-secondary! border-b">
236
- <td className="text-fm-icon-info! px-6 py-4 font-mono text-sm">
237
- height
238
- </td>
239
- <td className="text-fm-secondary! px-6 py-4 text-sm">
240
- number | string
241
- </td>
242
- <td className="text-fm-placeholder! px-6 py-4 text-sm">
243
- 24
244
- </td>
245
- <td className="text-fm-secondary! px-6 py-4 text-sm">
246
- Height of the icon in pixels
247
- </td>
248
- </tr>
249
- <tr className="border-fm-divider-tertiary border-b">
250
- <td className="text-fm-icon-info! px-6 py-4 font-mono text-sm">
251
- stroke
252
- </td>
253
- <td className="text-fm-secondary! px-6 py-4 text-sm">
254
- string
255
- </td>
256
- <td className="text-fm-placeholder! px-6 py-4 text-sm">
257
- currentColor
258
- </td>
259
- <td className="text-fm-secondary! px-6 py-4 text-sm">
260
- Stroke color of the icon
261
- </td>
262
- </tr>
263
- <tr className="border-fm-divider-tertiary bg-fm-surface-secondary! border-b">
264
- <td className="text-fm-icon-info! px-6 py-4 font-mono text-sm">
265
- strokeWidth
266
- </td>
267
- <td className="text-fm-secondary! px-6 py-4 text-sm">
268
- string | number
269
- </td>
270
- <td className="text-fm-placeholder! px-6 py-4 text-sm">
271
- 1.5
272
- </td>
273
- <td className="text-fm-secondary! px-6 py-4 text-sm">
274
- Stroke width of the icon lines
275
- </td>
276
- </tr>
277
- <tr className="border-fm-divider-tertiary border-b">
278
- <td className="text-fm-icon-info! px-6 py-4 font-mono text-sm">
279
- className
280
- </td>
281
- <td className="text-fm-secondary! px-6 py-4 text-sm">
282
- string
283
- </td>
284
- <td className="text-fm-placeholder! px-6 py-4 text-sm">
285
- -
286
- </td>
287
- <td className="text-fm-secondary! px-6 py-4 text-sm">
288
- CSS classes for styling (use for overrides)
289
- </td>
290
- </tr>
291
- <tr className="bg-fm-surface-secondary!">
292
- <td className="text-fm-icon-info! px-6 py-4 font-mono text-sm">
293
- ...svgProps
294
- </td>
295
- <td className="text-fm-secondary! px-6 py-4 text-sm">
296
- SVGProps
297
- </td>
298
- <td className="text-fm-placeholder! px-6 py-4 text-sm">
299
- -
300
- </td>
301
- <td className="text-fm-secondary! px-6 py-4 text-sm">
302
- All standard SVG element props
303
- </td>
304
- </tr>
305
- </tbody>
306
- </table>
307
- </div>
308
- </div>
309
-
310
- {/* Size Variations */}
311
- <div className="!space-y-8">
312
- <h2 className="text-fm-icon-active! text-center text-3xl font-bold">
313
- Size Variations
314
- </h2>
315
- <div className="border-fm-divider-secondary bg-fm-surface-secondary rounded-lg border p-8">
316
- <div className="!space-y-6">
317
- <div className="grid grid-cols-1 gap-8 md:grid-cols-2">
318
- <div className="!space-y-4">
319
- <h3 className="text-fm-icon-info! text-lg font-semibold">
320
- Standard Sizes
321
- </h3>
322
- <div className="bg-fm-surface-secondary flex items-end gap-6 rounded-lg p-6">
323
- <div className="text-center">
324
- <FileChartIcon className="text-fm-icon-info !mx-auto mb-2 h-3 w-3" />
325
- <span className="text-fm-tertiary text-xs">
326
- 12px
327
- </span>
328
- </div>
329
- <div className="text-center">
330
- <FileChartIcon className="text-fm-icon-info !mx-auto mb-2 h-4 w-4" />
331
- <span className="text-fm-tertiary text-xs">
332
- 16px
333
- </span>
334
- </div>
335
- <div className="text-center">
336
- <FileChartIcon className="text-fm-icon-info !mx-auto mb-2 h-5 w-5" />
337
- <span className="text-fm-tertiary text-xs">
338
- 20px
339
- </span>
340
- </div>
341
- <div className="text-center">
342
- <FileChartIcon className="text-fm-icon-info !mx-auto mb-2 h-6 w-6" />
343
- <span className="text-fm-tertiary text-xs">
344
- 24px
345
- </span>
346
- </div>
347
- <div className="text-center">
348
- <FileChartIcon className="text-fm-icon-info !mx-auto mb-2 h-8 w-8" />
349
- <span className="text-fm-tertiary text-xs">
350
- 32px
351
- </span>
352
- </div>
353
- <div className="text-center">
354
- <FileChartIcon className="text-fm-icon-info !mx-auto mb-2 h-12 w-12" />
355
- <span className="text-fm-tertiary text-xs">
356
- 48px
357
- </span>
358
- </div>
359
- </div>
360
- </div>
361
-
362
- <div className="!space-y-4">
363
- <h3 className="text-fm-icon-info! text-lg font-semibold">
364
- Code Example
365
- </h3>
366
- <div className="bg-fm-surface-secondary rounded-lg p-4">
367
- <pre className="text-fm-icon-info! overflow-x-auto text-sm">
368
- {`// Small (16px)
369
- <FileChartIcon className="h-4 w-4 " />
370
-
371
- // Medium (24px)
372
- <FileChartIcon className="h-6 w-6 " />
373
-
374
- // Large (32px)
375
- <FileChartIcon className="h-8 w-8 " />
376
-
377
- // Custom size with stroke width
378
- <FileChartIcon
379
- width={40}
380
- height={40}
381
- strokeWidth={2}
382
- />`}
383
- </pre>
384
- </div>
385
- </div>
386
- </div>
387
- </div>
388
- </div>
389
- </div>
390
-
391
- {/* Color Variations */}
392
- <div className="!space-y-8">
393
- <h2 className="text-fm-icon-active! text-center text-3xl font-bold">
394
- Color Variations
395
- </h2>
396
- <div className="grid grid-cols-1 gap-8 lg:grid-cols-2">
397
- <div className="!space-y-4">
398
- <h3 className="text-fm-icon-info! text-lg font-semibold">
399
- Semantic Colors
400
- </h3>
401
- <div className="border-fm-divider-secondary bg-fm-surface-secondary !space-y-4 rounded-lg border p-6">
402
- <div className="flex items-center gap-4">
403
- <FileChartIcon className="text-fm-icon-info h-6 w-6" />
404
- <div>
405
- <div className="text-fm-icon-active text-sm font-medium">
406
- Analytics
407
- </div>
408
- <div className="text-fm-tertiary text-xs">
409
- text-fm-icon-info
410
- </div>
411
- </div>
412
- </div>
413
- <div className="flex items-center gap-4">
414
- <FileChartIcon className="text-fm-icon-positive h-6 w-6" />
415
- <div>
416
- <div className="text-fm-icon-active text-sm font-medium">
417
- Financial Reports
418
- </div>
419
- <div className="text-fm-tertiary text-xs">
420
- text-fm-icon-positive
421
- </div>
422
- </div>
423
- </div>
424
- <div className="flex items-center gap-4">
425
- <FileChartIcon className="text-fm-secondary-600 h-6 w-6" />
426
- <div>
427
- <div className="text-fm-icon-active text-sm font-medium">
428
- Marketing Data
429
- </div>
430
- <div className="text-fm-tertiary text-xs">
431
- text-fm-secondary-600
432
- </div>
433
- </div>
434
- </div>
435
- <div className="flex items-center gap-4">
436
- <FileChartIcon className="text-fm-icon-warning h-6 w-6" />
437
- <div>
438
- <div className="text-fm-icon-active text-sm font-medium">
439
- Sales Metrics
440
- </div>
441
- <div className="text-fm-tertiary text-xs">
442
- text-fm-icon-warning
443
- </div>
444
- </div>
445
- </div>
446
- </div>
447
- </div>
448
-
449
- <div className="!space-y-4">
450
- <h3 className="text-fm-icon-info! text-lg font-semibold">
451
- Custom Colors
452
- </h3>
453
- <div className="bg-fm-surface-secondary rounded-lg p-4">
454
- <pre className="text-fm-icon-positive! overflow-x-auto text-sm">
455
- {`// Using Tailwind classes with
456
- <FileChartIcon className="h-6 w-6 text-blue-400 " />
457
- <FileChartIcon className="h-6 w-6 text-green-500 " />
458
-
459
- // Using CSS custom properties
460
- <FileChartIcon
461
- className="h-6 w-6 "
462
- style={{ color: 'var(--color-analytics)' }}
463
- />
464
-
465
- // Direct stroke prop
466
- <FileChartIcon
467
- width={24}
468
- height={24}
469
- stroke="#3b82f6"
470
- strokeWidth={1.5}
471
- />`}
472
- </pre>
473
- </div>
474
- </div>
475
- </div>
476
- </div>
477
-
478
- {/* Usage Examples */}
479
- <div className="!space-y-8">
480
- <h2 className="text-fm-icon-active! text-center text-3xl font-bold">
481
- Usage Examples
482
- </h2>
483
-
484
- <div className="grid grid-cols-1 gap-8 lg:grid-cols-2">
485
- {/* Dashboard Card */}
486
- <div className="!space-y-4">
487
- <h3 className="text-fm-icon-info! text-lg font-semibold">
488
- Dashboard Card
489
- </h3>
490
- <div className="!space-y-4">
491
- <div className="border-fm-icon-info/20 bg-fm-icon-info/10 rounded-lg border p-6">
492
- <div className="flex items-start justify-between">
493
- <div className="flex items-start gap-4">
494
- <div className="bg-fm-icon-info/20 rounded-lg p-2">
495
- <FileChartIcon className="text-fm-icon-info h-6 w-6" />
496
- </div>
497
- <div>
498
- <h4 className="text-fm-icon-info! font-semibold">
499
- Monthly Analytics Report
500
- </h4>
501
- <p className="text-fm-icon-info!/80 text-sm">
502
- Comprehensive data analysis for November 2024
503
- </p>
504
- <div className="mt-3 flex items-center gap-4 text-sm">
505
- <span className="text-fm-icon-info">
506
- Format: PDF
507
- </span>
508
- <span className="text-fm-icon-info">
509
- Size: 2.4 MB
510
- </span>
511
- <span className="text-fm-icon-info">
512
- Pages: 24
513
- </span>
514
- </div>
515
- </div>
516
- </div>
517
- <button className="text-fm-icon-info hover:text-fm-icon-info">
518
- <span className="text-sm">Download</span>
519
- </button>
520
- </div>
521
- </div>
522
- <div className="bg-fm-surface-secondary rounded-lg p-4">
523
- <pre className="text-fm-icon-positive! overflow-x-auto text-sm">
524
- {`<div className="border border-blue-500/20 bg-blue-500/10 p-6 rounded-lg">
525
- <div className="flex items-start justify-between">
526
- <div className="flex items-start gap-4">
527
- <div className="bg-blue-500/20 p-2 rounded-lg">
528
- <FileChartIcon className="h-6 w-6 text-blue-400 " />
529
- </div>
530
- <div>
531
- <h4 className="font-semibold text-blue-200">Monthly Analytics Report</h4>
532
- <p className="text-sm text-blue-300/80">
533
- Comprehensive data analysis for November 2024
534
- </p>
535
- <div className="mt-3 flex items-center gap-4 text-sm">
536
- <span className="text-blue-300">Format: PDF</span>
537
- <span className="text-blue-300">Size: 2.4 MB</span>
538
- </div>
539
- </div>
540
- </div>
541
- </div>
542
- </div>`}
543
- </pre>
544
- </div>
545
- </div>
546
- </div>
547
-
548
- {/* File List */}
549
- <div className="!space-y-4">
550
- <h3 className="text-fm-icon-info! text-lg font-semibold">
551
- File List
552
- </h3>
553
- <div className="!space-y-4">
554
- <div className="!space-y-2">
555
- <div className="border-fm-divider-secondary bg-fm-surface-secondary flex items-center justify-between rounded-lg border p-3">
556
- <div className="flex items-center gap-3">
557
- <FileChartIcon className="text-fm-icon-info h-5 w-5" />
558
- <div>
559
- <div className="text-fm-icon-active text-sm font-medium">
560
- Q4_Sales_Report.xlsx
561
- </div>
562
- <div className="text-fm-tertiary text-xs">
563
- Modified 2 hours ago
564
- </div>
565
- </div>
566
- </div>
567
- <div className="text-fm-tertiary text-xs">1.2 MB</div>
568
- </div>
569
- <div className="border-fm-divider-secondary bg-fm-surface-secondary flex items-center justify-between rounded-lg border p-3">
570
- <div className="flex items-center gap-3">
571
- <FileChartIcon className="text-fm-icon-positive h-5 w-5" />
572
- <div>
573
- <div className="text-fm-icon-active text-sm font-medium">
574
- Financial_Dashboard.pdf
575
- </div>
576
- <div className="text-fm-tertiary text-xs">
577
- Modified yesterday
578
- </div>
579
- </div>
580
- </div>
581
- <div className="text-fm-tertiary text-xs">3.8 MB</div>
582
- </div>
583
- <div className="border-fm-divider-secondary bg-fm-surface-secondary flex items-center justify-between rounded-lg border p-3">
584
- <div className="flex items-center gap-3">
585
- <FileChartIcon className="text-fm-secondary-600 h-5 w-5" />
586
- <div>
587
- <div className="text-fm-icon-active text-sm font-medium">
588
- Marketing_Metrics.pptx
589
- </div>
590
- <div className="text-fm-tertiary text-xs">
591
- Modified 3 days ago
592
- </div>
593
- </div>
594
- </div>
595
- <div className="text-fm-tertiary text-xs">5.1 MB</div>
596
- </div>
597
- </div>
598
- <div className="bg-fm-surface-secondary rounded-lg p-4">
599
- <pre className="text-fm-icon-positive! overflow-x-auto text-sm">
600
- {`// File list item
601
- <div className="flex items-center justify-between p-3 border border-white/10 bg-white/5 rounded-lg">
602
- <div className="flex items-center gap-3">
603
- <FileChartIcon className="h-5 w-5 text-blue-400 " />
604
- <div>
605
- <div className="text-sm font-medium text-white">Q4_Sales_Report.xlsx</div>
606
- <div className="text-xs text-white/60">Modified 2 hours ago</div>
607
- </div>
608
- </div>
609
- <div className="text-xs text-white/60">1.2 MB</div>
610
- </div>`}
611
- </pre>
612
- </div>
613
- </div>
614
- </div>
615
-
616
- {/* Navigation Menu */}
617
- <div className="!space-y-4">
618
- <h3 className="text-fm-icon-info! text-lg font-semibold">
619
- Navigation Menu
620
- </h3>
621
- <div className="!space-y-4">
622
- <div className="border-fm-divider-secondary bg-fm-surface-secondary rounded-lg border p-4">
623
- <nav className="!space-y-1">
624
- <a
625
- href="#"
626
- className="bg-fm-icon-info/20 text-fm-icon-info flex items-center gap-3 rounded-lg px-3 py-2"
627
- >
628
- <FileChartIcon className="h-5 w-5" />
629
- <span className="font-medium">Reports</span>
630
- <span className="bg-fm-icon-info/30 ml-auto rounded px-2 py-1 text-xs">
631
- 24
632
- </span>
633
- </a>
634
- <a
635
- href="#"
636
- className="text-fm-secondary hover:bg-fm-surface-secondary hover:text-fm-icon-active flex items-center gap-3 rounded-lg px-3 py-2"
637
- >
638
- <FileChartIcon className="h-5 w-5" />
639
- <span>Analytics</span>
640
- </a>
641
- <a
642
- href="#"
643
- className="text-fm-secondary hover:bg-fm-surface-secondary hover:text-fm-icon-active flex items-center gap-3 rounded-lg px-3 py-2"
644
- >
645
- <FileChartIcon className="h-5 w-5" />
646
- <span>Dashboards</span>
647
- </a>
648
- </nav>
649
- </div>
650
- <div className="bg-fm-surface-secondary rounded-lg p-4">
651
- <pre className="text-fm-icon-positive! overflow-x-auto text-sm">
652
- {`// Active navigation item
653
- <a href="#" className="flex items-center gap-3 bg-blue-500/20 px-3 py-2 rounded-lg text-blue-200">
654
- <FileChartIcon className="h-5 w-5 " />
655
- <span className="font-medium">Reports</span>
656
- <span className="ml-auto bg-blue-500/30 px-2 py-1 rounded text-xs">24</span>
657
- </a>
658
-
659
- // Inactive navigation item
660
- <a href="#" className="flex items-center gap-3 px-3 py-2 rounded-lg text-white/70 hover:bg-white/5">
661
- <FileChartIcon className="h-5 w-5 " />
662
- <span>Analytics</span>
663
- </a>`}
664
- </pre>
665
- </div>
666
- </div>
667
- </div>
668
-
669
- {/* Upload Area */}
670
- <div className="!space-y-4">
671
- <h3 className="text-fm-icon-info! text-lg font-semibold">
672
- Upload Area
673
- </h3>
674
- <div className="!space-y-4">
675
- <div className="border-fm-icon-info/30 bg-fm-icon-info/5 rounded-lg border-2 border-dashed p-8 text-center">
676
- <div className="bg-fm-icon-info/20 !mx-auto mb-4 flex h-16 w-16 items-center justify-center rounded-full">
677
- <FileChartIcon className="text-fm-icon-info h-8 w-8" />
678
- </div>
679
- <h4 className="text-fm-icon-active! mb-2 font-semibold">
680
- Upload Analytics Files
681
- </h4>
682
- <p className="text-fm-secondary! mb-4 text-sm">
683
- Drag and drop your chart files here, or click to
684
- browse
685
- </p>
686
- <div className="text-fm-tertiary! text-xs">
687
- Supports: .xlsx, .pdf, .csv, .pptx (Max 10MB)
688
- </div>
689
- </div>
690
- <div className="bg-fm-surface-secondary rounded-lg p-4">
691
- <pre className="text-fm-icon-positive! overflow-x-auto text-sm">
692
- {`// Upload area
693
- <div className="border-2 border-dashed border-blue-500/30 bg-blue-500/5 p-8 rounded-lg text-center">
694
- <div className="mx-auto mb-4 flex h-16 w-16 items-center justify-center rounded-full bg-blue-500/20">
695
- <FileChartIcon className="h-8 w-8 text-blue-400 " />
696
- </div>
697
- <h4 className="mb-2 font-semibold text-white">Upload Analytics Files</h4>
698
- <p className="mb-4 text-sm text-white/70">
699
- Drag and drop your chart files here, or click to browse
700
- </p>
701
- <div className="text-xs text-white/60">
702
- Supports: .xlsx, .pdf, .csv, .pptx (Max 10MB)
703
- </div>
704
- </div>`}
705
- </pre>
706
- </div>
707
- </div>
708
- </div>
709
- </div>
55
+ }`,
56
+ livePreview: (
57
+ <div className="flex items-center gap-2">
58
+ <FileChartIcon className="text-fm-icon-active h-6 w-6" />
710
59
  </div>
711
-
712
- {/* Accessibility */}
713
- <div className="!space-y-8">
714
- <h2 className="text-fm-icon-active! text-center text-3xl font-bold">
715
- Accessibility Features
716
- </h2>
717
- <div className="grid grid-cols-1 gap-8 md:grid-cols-2">
718
- <div className="border-fm-divider-secondary bg-fm-surface-secondary !space-y-4 rounded-lg border p-6">
719
- <h3 className="text-fm-icon-positive! text-lg font-semibold">
720
- ✅ Built-in Features
721
- </h3>
722
- <ul className="text-fm-secondary! !space-y-2 text-sm">
723
- <li className="text-fm-secondary!">
724
- Uses Radix UI AccessibleIcon wrapper
725
- </li>
726
- <li className="text-fm-secondary!">
727
- Provides screen reader label "File Chart icon"
728
- </li>
729
- <li className="text-fm-secondary!">
730
- Supports keyboard navigation when interactive
731
- </li>
732
- <li className="text-fm-secondary!">
733
- Maintains proper color contrast ratios
734
- </li>
735
- <li className="text-fm-secondary!">
736
- Scales with user's font size preferences
737
- </li>
738
- </ul>
739
- </div>
740
-
741
- <div className="border-fm-divider-secondary bg-fm-surface-secondary !space-y-4 rounded-lg border p-6">
742
- <h3 className="text-fm-icon-info! text-lg font-semibold">
743
- 💡 Best Practices
744
- </h3>
745
- <ul className="text-fm-secondary !space-y-2 text-sm">
746
- <li className="text-fm-secondary!">
747
- Always pair with descriptive file names
748
- </li>
749
- <li className="text-fm-secondary!">
750
- Use consistent colors for different data types
751
- </li>
752
- <li className="text-fm-secondary!">
753
- Ensure sufficient color contrast for visibility
754
- </li>
755
- <li className="text-fm-secondary!">
756
- Provide alternative text for file formats
757
- </li>
758
- <li className="text-fm-secondary!">
759
- Consider providing data summaries for charts
760
- </li>
761
- </ul>
762
- </div>
763
- </div>
764
-
765
- <div className="border-fm-divider-secondary bg-fm-surface-secondary rounded-lg border p-6">
766
- <h3 className="text-fm-secondary-600! mb-4 text-lg font-semibold">
767
- Proper ARIA Implementation
768
- </h3>
769
- <div className="grid grid-cols-1 gap-6 lg:grid-cols-2">
770
- <div className="bg-fm-surface-secondary rounded-lg p-4">
771
- <pre className="text-fm-icon-info! overflow-x-auto text-sm">
772
- {`// File item with proper ARIA
773
- <div
774
- role="button"
775
- aria-label="Download Q4 Sales Report Excel file, 1.2 MB"
776
- className="flex items-center gap-3 p-3"
777
- >
778
- <FileChartIcon
779
- className="h-5 w-5 text-blue-400 "
780
- aria-hidden="true"
781
- />
782
- <div>
783
- <div className="font-medium">Q4_Sales_Report.xlsx</div>
784
- <div className="text-sm text-gray-500">1.2 MB</div>
785
- </div>
786
- </div>
787
-
788
- // Dashboard section with description
789
- <section
790
- aria-labelledby="reports-heading"
791
- className="space-y-4"
792
- >
793
- <h2 id="reports-heading" className="flex items-center gap-2">
794
- <FileChartIcon className="h-6 w-6 text-blue-400 " aria-hidden="true" />
795
- Analytics Reports
796
- </h2>
797
- {/* Report content */}
798
- </section>`}
799
- </pre>
800
- </div>
801
- <div className="!space-y-4">
802
- <p className="text-fm-secondary! text-sm">
803
- When using FileChartIcon in interactive contexts or as
804
- file representations, provide meaningful labels and
805
- descriptions that help users understand the file type,
806
- size, and purpose.
807
- </p>
808
- <div className="border-fm-icon-info/20 bg-fm-icon-info/10 rounded-lg border p-4">
809
- <div className="text-fm-icon-info flex items-center gap-2 text-sm">
810
- <FileChartIcon className="h-4 w-4" />
811
- <span>
812
- Screen readers need context about file types and
813
- data
814
- </span>
815
- </div>
816
- </div>
817
- </div>
818
- </div>
819
- </div>
820
- </div>
821
-
822
- {/* Related Icons */}
823
- <div className="!space-y-8">
824
- <h2 className="text-fm-icon-active! text-center text-3xl font-bold">
825
- Related Icons
826
- </h2>
827
- <div className="grid grid-cols-2 gap-6 md:grid-cols-4">
828
- <div className="border-fm-divider-secondary bg-fm-surface-secondary !space-y-3 rounded-lg border p-4 text-center">
829
- <div className="bg-fm-surface-tertiary/20 !mx-auto flex h-12 w-12 items-center justify-center rounded-lg">
830
- <span className="text-2xl">📄</span>
831
- </div>
832
- <div>
833
- <div className="text-fm-icon-active font-medium">
834
- FileIcon
835
- </div>
836
- <div className="text-fm-tertiary text-xs">
837
- Generic documents
838
- </div>
839
- </div>
840
- </div>
841
- <div className="border-fm-divider-secondary bg-fm-surface-secondary !space-y-3 rounded-lg border p-4 text-center">
842
- <div className="bg-fm-icon-positive/20 !mx-auto flex h-12 w-12 items-center justify-center rounded-lg">
843
- <span className="text-2xl">📊</span>
844
- </div>
845
- <div>
846
- <div className="text-fm-icon-active font-medium">
847
- ChartIcon
848
- </div>
849
- <div className="text-fm-tertiary text-xs">
850
- Data visualization
851
- </div>
852
- </div>
853
- </div>
854
- <div className="border-fm-divider-secondary bg-fm-surface-secondary !space-y-3 rounded-lg border p-4 text-center">
855
- <div className="bg-fm-secondary-500/20 !mx-auto flex h-12 w-12 items-center justify-center rounded-lg">
856
- <span className="text-2xl">📈</span>
857
- </div>
858
- <div>
859
- <div className="text-fm-icon-active font-medium">
860
- TrendIcon
861
- </div>
862
- <div className="text-fm-tertiary text-xs">
863
- Growth metrics
864
- </div>
865
- </div>
866
- </div>
867
- <div className="border-fm-divider-secondary bg-fm-surface-secondary !space-y-3 rounded-lg border p-4 text-center">
868
- <div className="bg-fm-icon-warning/20 !mx-auto flex h-12 w-12 items-center justify-center rounded-lg">
869
- <span className="text-2xl">📋</span>
870
- </div>
871
- <div>
872
- <div className="text-fm-icon-active font-medium">
873
- ReportIcon
874
- </div>
875
- <div className="text-fm-tertiary text-xs">
876
- Summary reports
877
- </div>
878
- </div>
879
- </div>
880
- </div>
881
- </div>
882
- </div>
883
-
884
- {/* Footer */}
885
- <div className="border-fm-divider-secondary bg-fm-surface-secondary border-t backdrop-blur-xl">
886
- <div className="!mx-auto max-w-7xl px-6 py-8">
887
- <div className="!space-y-4 text-center">
888
- <p className="text-fm-tertiary!">
889
- FileChartIcon is part of the Aural UI icon library, built
890
- with analytics and data visualization in mind.
891
- </p>
892
- <p className="text-fm-placeholder! text-sm">
893
- All icons use Radix UI's AccessibleIcon for screen reader
894
- compatibility and follow WCAG guidelines.
895
- </p>
896
- </div>
897
- </div>
898
- </div>
899
- </div>
900
- </>
60
+ ),
61
+ }}
62
+ relatedIcons={[
63
+ {
64
+ name: "FileTextIcon",
65
+ description: "Text document file icon",
66
+ icon: FileTextIcon,
67
+ accentToken: "info",
68
+ },
69
+ {
70
+ name: "NotepadIcon",
71
+ description: "Notepad document icon",
72
+ icon: NotepadIcon,
73
+ accentToken: "positive",
74
+ },
75
+ {
76
+ name: "NotesIcon",
77
+ description: "Notes / memo icon",
78
+ icon: NotesIcon,
79
+ accentToken: "warning",
80
+ },
81
+ {
82
+ name: "PageTextIcon",
83
+ description: "Page with text content",
84
+ icon: PageTextIcon,
85
+ accentToken: "negative",
86
+ },
87
+ ]}
88
+ />
901
89
  ),
902
90
  },
903
91
  },
904
92
  tags: ["autodocs"],
905
93
  argTypes: {
906
- width: {
907
- control: { type: "range", min: 8, max: 96, step: 2 },
908
- description: "Width of the icon in pixels",
94
+ className: {
95
+ control: "text",
96
+ description: "CSS classes including color token",
909
97
  },
910
98
  withAccessibility: {
911
99
  control: "boolean",
912
- description: "Whether to wrap the icon with accessibility features",
913
- },
914
- height: {
915
- control: { type: "range", min: 8, max: 96, step: 2 },
916
- description: "Height of the icon in pixels",
917
- },
918
- stroke: {
919
- control: "color",
920
- description: "Stroke color of the icon",
921
- },
922
- strokeWidth: {
923
- control: { type: "range", min: 0.5, max: 4, step: 0.5 },
924
- description: "Stroke width of the icon lines",
925
- },
926
- className: {
927
- control: "text",
928
- description: "CSS classes for styling (use for overrides)",
100
+ description: "Wrap with accessibility label",
929
101
  },
930
102
  },
931
103
  }
@@ -933,229 +105,89 @@ function ReportsSection() {
933
105
  export default meta
934
106
  type Story = StoryObj<typeof FileChartIcon>
935
107
 
936
- // Story parameters for consistent dark theme
937
- const storyParameters = {
938
- backgrounds: {
939
- default: "dark",
940
- values: [
941
- { name: "dark", value: "var(--color-fm-surface-primary)" },
942
- { name: "darker", value: "var(--color-fm-neutral-0)" },
943
- ],
944
- },
945
- }
946
-
947
108
  export const Default: Story = {
948
109
  args: {
949
- className: "h-6 w-6 text-fm-icon-info ",
110
+ className: "h-6 w-6 text-fm-icon-active",
950
111
  withAccessibility: true,
951
112
  },
952
- parameters: storyParameters,
953
113
  render: (args) => (
954
- <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>
955
115
  <FileChartIcon {...args} />
956
- </div>
116
+ </IconDefaultCanvas>
957
117
  ),
958
118
  }
959
119
 
960
120
  export const SizeVariations: Story = {
961
- parameters: {
962
- ...storyParameters,
963
- docs: {
964
- description: {
965
- story:
966
- "FileChartIcon in different sizes, from small UI elements to large displays.",
967
- },
968
- },
969
- },
970
- render: () => (
971
- <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">
972
- <div className="text-center">
973
- <FileChartIcon className="text-fm-icon-info !mx-auto mb-2 h-3 w-3" />
974
- <span className="text-fm-tertiary text-xs">12px</span>
975
- </div>
976
- <div className="text-center">
977
- <FileChartIcon className="text-fm-icon-info !mx-auto mb-2 h-4 w-4" />
978
- <span className="text-fm-tertiary text-xs">16px</span>
979
- </div>
980
- <div className="text-center">
981
- <FileChartIcon className="text-fm-icon-info !mx-auto mb-2 h-5 w-5" />
982
- <span className="text-fm-tertiary text-xs">20px</span>
983
- </div>
984
- <div className="text-center">
985
- <FileChartIcon className="text-fm-icon-info !mx-auto mb-2 h-6 w-6" />
986
- <span className="text-fm-tertiary text-xs">24px</span>
987
- </div>
988
- <div className="text-center">
989
- <FileChartIcon className="text-fm-icon-info !mx-auto mb-2 h-8 w-8" />
990
- <span className="text-fm-tertiary text-xs">32px</span>
991
- </div>
992
- <div className="text-center">
993
- <FileChartIcon className="text-fm-icon-info !mx-auto mb-2 h-12 w-12" />
994
- <span className="text-fm-tertiary text-xs">48px</span>
995
- </div>
996
- </div>
997
- ),
121
+ render: () => <IconSizeVariations icon={FileChartIcon} />,
998
122
  }
999
123
 
1000
124
  export const ColorVariations: Story = {
1001
- parameters: {
1002
- ...storyParameters,
1003
- docs: {
1004
- description: {
1005
- story:
1006
- "FileChartIcon in different semantic colors for various data types and contexts.",
1007
- },
1008
- },
1009
- },
1010
- render: () => (
1011
- <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">
1012
- <div className="text-center">
1013
- <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">
1014
- <FileChartIcon className="text-fm-icon-info h-8 w-8" />
1015
- </div>
1016
- <div className="text-fm-icon-active text-sm font-medium">Analytics</div>
1017
- <div className="text-fm-icon-info text-xs">text-fm-icon-info</div>
1018
- </div>
1019
- <div className="text-center">
1020
- <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">
1021
- <FileChartIcon className="text-fm-icon-positive h-8 w-8" />
1022
- </div>
1023
- <div className="text-fm-icon-active text-sm font-medium">Financial</div>
1024
- <div className="text-fm-icon-positive text-xs">
1025
- text-fm-icon-positive
1026
- </div>
1027
- </div>
1028
- <div className="text-center">
1029
- <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">
1030
- <FileChartIcon className="text-fm-secondary-600 h-8 w-8" />
1031
- </div>
1032
- <div className="text-fm-icon-active text-sm font-medium">Marketing</div>
1033
- <div className="text-fm-secondary-600 text-xs">
1034
- text-fm-secondary-600
1035
- </div>
1036
- </div>
1037
- <div className="text-center">
1038
- <div className="border-fm-icon-warning/30 bg-fm-icon-warning/20 !mx-auto mb-3 flex h-16 w-16 items-center justify-center rounded-lg border">
1039
- <FileChartIcon className="text-fm-icon-warning h-8 w-8" />
1040
- </div>
1041
- <div className="text-fm-icon-active text-sm font-medium">Sales</div>
1042
- <div className="text-fm-icon-warning text-xs">text-fm-icon-warning</div>
1043
- </div>
1044
- </div>
1045
- ),
125
+ render: () => <IconColorVariations icon={FileChartIcon} />,
1046
126
  }
1047
127
 
1048
128
  export const UsageExamples: Story = {
1049
- parameters: {
1050
- ...storyParameters,
1051
- docs: {
1052
- description: {
1053
- story:
1054
- "Real-world usage examples showing FileChartIcon in different analytics and reporting contexts.",
1055
- },
1056
- },
1057
- },
1058
129
  render: () => (
1059
- <div className="from-fm-surface-primary to-fm-surface-secondary min-h-dvh !space-y-8 rounded-lg bg-linear-to-br p-8">
1060
- {/* Dashboard Card */}
1061
- <div className="!space-y-2">
1062
- <h3 className="text-fm-icon-active text-sm font-medium">
1063
- Dashboard Card
1064
- </h3>
1065
- <div className="border-fm-icon-info/20 bg-fm-icon-info/10 rounded-lg border p-6">
1066
- <div className="flex items-start justify-between">
1067
- <div className="flex items-start gap-4">
1068
- <div className="bg-fm-icon-info/20 rounded-lg p-2">
1069
- <FileChartIcon className="text-fm-icon-info h-6 w-6" />
1070
- </div>
1071
- <div>
1072
- <h4 className="text-fm-icon-info font-semibold">
1073
- Monthly Analytics Report
1074
- </h4>
1075
- <p className="text-fm-icon-info/80 text-sm">
1076
- Comprehensive data analysis for November 2024
1077
- </p>
1078
- </div>
1079
- </div>
1080
- </div>
130
+ <IconUsageCanvas>
131
+ <IconUsageSection title="Reports List">
132
+ <div className="border-fm-divider-secondary bg-fm-surface-secondary w-full max-w-sm overflow-hidden rounded-xl border">
133
+ {[
134
+ "Monthly Listening Report",
135
+ "Engagement Analytics",
136
+ "Revenue Summary",
137
+ ].map((label) => (
138
+ <button
139
+ key={label}
140
+ className="border-fm-divider-secondary flex w-full items-center gap-3 border-b px-4 py-3 last:border-b-0"
141
+ >
142
+ <FileChartIcon className="text-fm-icon-active h-4 w-4" />
143
+ <span className="text-fm-primary font-fm-text text-sm">
144
+ {label}
145
+ </span>
146
+ </button>
147
+ ))}
1081
148
  </div>
1082
- </div>
1083
-
1084
- {/* File List */}
1085
- <div className="!space-y-2">
1086
- <h3 className="text-fm-icon-active text-sm font-medium">File List</h3>
1087
- <div className="!space-y-2">
1088
- <div className="border-fm-divider-secondary bg-fm-surface-secondary flex items-center justify-between rounded-lg border p-3">
1089
- <div className="flex items-center gap-3">
1090
- <FileChartIcon className="text-fm-icon-info h-5 w-5" />
1091
- <div>
1092
- <div className="text-fm-icon-active text-sm font-medium">
1093
- Q4_Sales_Report.xlsx
1094
- </div>
1095
- <div className="text-fm-tertiary text-xs">
1096
- Modified 2 hours ago
1097
- </div>
1098
- </div>
1099
- </div>
1100
- <div className="text-fm-tertiary text-xs">1.2 MB</div>
149
+ </IconUsageSection>
150
+
151
+ <IconUsageSection title="Dashboard Widget">
152
+ <div className="border-fm-divider-secondary bg-fm-surface-secondary w-full max-w-sm rounded-xl border p-4">
153
+ <div className="flex items-center gap-2">
154
+ <FileChartIcon className="text-fm-icon-active h-5 w-5" />
155
+ <span className="text-fm-primary font-fm-text text-sm font-medium">
156
+ Analytics
157
+ </span>
1101
158
  </div>
1102
- <div className="border-fm-divider-secondary bg-fm-surface-secondary flex items-center justify-between rounded-lg border p-3">
1103
- <div className="flex items-center gap-3">
1104
- <FileChartIcon className="text-fm-icon-positive h-5 w-5" />
1105
- <div>
1106
- <div className="text-fm-icon-active text-sm font-medium">
1107
- Financial_Dashboard.pdf
1108
- </div>
1109
- <div className="text-fm-tertiary text-xs">
1110
- Modified yesterday
1111
- </div>
1112
- </div>
1113
- </div>
1114
- <div className="text-fm-tertiary text-xs">3.8 MB</div>
159
+ <div className="text-fm-secondary font-fm-text mt-2 text-xs">
160
+ 3 reports available
1115
161
  </div>
1116
162
  </div>
1117
- </div>
1118
-
1119
- {/* Upload Area */}
1120
- <div className="!space-y-2">
1121
- <h3 className="text-fm-icon-active text-sm font-medium">Upload Area</h3>
1122
- <div className="border-fm-icon-info/30 bg-fm-icon-info/5 rounded-lg border-2 border-dashed p-8 text-center">
1123
- <div className="bg-fm-icon-info/20 !mx-auto mb-4 flex h-16 w-16 items-center justify-center rounded-full">
1124
- <FileChartIcon className="text-fm-icon-info h-8 w-8" />
1125
- </div>
1126
- <h4 className="text-fm-icon-active mb-2 font-semibold">
1127
- Upload Analytics Files
1128
- </h4>
1129
- <p className="text-fm-secondary text-sm">
1130
- Drag and drop your chart files here, or click to browse
1131
- </p>
163
+ </IconUsageSection>
164
+
165
+ <IconUsageSection title="Document Type Picker">
166
+ <div className="flex gap-3">
167
+ {[FileChartIcon, FileTextIcon, NotepadIcon].map((Icon, i) => (
168
+ <div
169
+ key={i}
170
+ className={`border-fm-divider-secondary flex h-12 w-12 items-center justify-center rounded-xl border ${i === 0 ? "bg-fm-surface-primary" : "bg-fm-surface-secondary"}`}
171
+ >
172
+ <Icon
173
+ className={`h-5 w-5 ${i === 0 ? "text-fm-icon-active" : "text-fm-icon-inactive"}`}
174
+ />
175
+ </div>
176
+ ))}
1132
177
  </div>
1133
- </div>
1134
- </div>
178
+ </IconUsageSection>
179
+ </IconUsageCanvas>
1135
180
  ),
1136
181
  }
1137
182
 
1138
183
  export const Playground: Story = {
1139
- parameters: {
1140
- ...storyParameters,
1141
- docs: {
1142
- description: {
1143
- story:
1144
- "Interactive playground to experiment with different FileChartIcon configurations.",
1145
- },
1146
- },
1147
- },
1148
184
  args: {
1149
- width: 32,
1150
- height: 32,
1151
- className: "text-fm-icon-info ",
1152
- strokeWidth: 1.5,
185
+ className: "h-8 w-8 text-fm-icon-active",
186
+ withAccessibility: true,
1153
187
  },
1154
188
  render: (args) => (
1155
- <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">
1156
- <div className="border-fm-divider-secondary bg-fm-surface-secondary rounded-lg border p-8">
1157
- <FileChartIcon {...args} />
1158
- </div>
1159
- </div>
189
+ <IconPlaygroundCanvas>
190
+ <FileChartIcon {...args} />
191
+ </IconPlaygroundCanvas>
1160
192
  ),
1161
193
  }