aural-ui 3.0.7 → 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 (183) hide show
  1. package/dist/components/aspect-ratio/AspectRatio.stories.tsx +290 -1199
  2. package/dist/components/avatar/Avatar.stories.tsx +235 -237
  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/button/index.tsx +7 -7
  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 -620
  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 +533 -856
  16. package/dist/components/dialog/Dialog.stories.tsx +505 -949
  17. package/dist/components/divider/Divider.stories.tsx +265 -502
  18. package/dist/components/dot-loader/DotLoader.stories.tsx +256 -257
  19. package/dist/components/drawer/Drawer.stories.tsx +659 -993
  20. package/dist/components/drawer/index.tsx +3 -3
  21. package/dist/components/dropdown/Dropdown.stories.tsx +643 -1018
  22. package/dist/components/form/Form.stories.tsx +560 -274
  23. package/dist/components/helper-text/HelperText.stories.tsx +199 -200
  24. package/dist/components/hover-card/HoverCard.stories.tsx +318 -1221
  25. package/dist/components/icon-button/IconButton.stories.tsx +837 -194
  26. package/dist/components/if-else/if-else.stories.tsx +370 -83
  27. package/dist/components/input/Input.stories.tsx +436 -368
  28. package/dist/components/label/Label.stories.tsx +156 -154
  29. package/dist/components/list/List.stories.tsx +485 -822
  30. package/dist/components/marquee/Marquee.stories.tsx +356 -694
  31. package/dist/components/otp-inputs/OtpInputs.stories.tsx +352 -410
  32. package/dist/components/overlay/Overlay.stories.tsx +452 -818
  33. package/dist/components/overlay/index.tsx +4 -4
  34. package/dist/components/pagination/Pagination.stories.tsx +721 -210
  35. package/dist/components/popover/Popover.stories.tsx +484 -873
  36. package/dist/components/radio/Radio.stories.tsx +432 -124
  37. package/dist/components/resizable/Resizable.stories.tsx +496 -752
  38. package/dist/components/scroll-area/ScrollArea.stories.tsx +384 -1006
  39. package/dist/components/search/Search.stories.tsx +314 -575
  40. package/dist/components/select/Select.stories.tsx +684 -787
  41. package/dist/components/sheet/Sheet.stories.tsx +671 -936
  42. package/dist/components/skelton/Skelton.stories.tsx +230 -764
  43. package/dist/components/slider/Slider.stories.tsx +384 -737
  44. package/dist/components/stepper/Stepper.stories.tsx +371 -514
  45. package/dist/components/switch/Switch.stories.tsx +461 -208
  46. package/dist/components/switch-case/SwitchCase.stories.tsx +367 -188
  47. package/dist/components/table/Table.stories.tsx +770 -914
  48. package/dist/components/tabs/Tabs.stories.tsx +459 -1400
  49. package/dist/components/tag/Tag.stories.tsx +714 -542
  50. package/dist/components/textarea/TextArea.stories.tsx +621 -562
  51. package/dist/components/thumbnail-tags/ThumbnailTags.stories.tsx +228 -148
  52. package/dist/components/toast/Toast.stories.tsx +452 -1333
  53. package/dist/components/toggle/Toggle.stories.tsx +488 -909
  54. package/dist/components/tooltip/Tooltip.stories.tsx +344 -1372
  55. package/dist/components/typography/Typography.stories.tsx +406 -89
  56. package/dist/hooks/use-change-state/UseChangeState.stories.tsx +309 -606
  57. package/dist/hooks/use-previous/UsePrevious.stories.tsx +367 -917
  58. package/dist/hooks/use-standalone-pagination/UseStandalonePagination.stories.tsx +639 -867
  59. package/dist/icons/Icons.stories.tsx +0 -12
  60. package/dist/icons/ai-avatar-icon/AiAvatarIcon.stories.tsx +226 -1013
  61. package/dist/icons/alert-icon/AlertIcon.stories.tsx +109 -929
  62. package/dist/icons/all-icons.tsx +124 -87
  63. package/dist/icons/angle-down-icon/AngleDownIcon.stories.tsx +140 -971
  64. package/dist/icons/apple-logo-icon/AppleLogoIcon.stories.tsx +148 -888
  65. package/dist/icons/arrow-box-left-icon/ArrowBoxLeftIcon.stories.tsx +135 -1019
  66. package/dist/icons/arrow-corner-up-left-icon/ArrowCornerUpLeftIcon.stories.tsx +137 -953
  67. package/dist/icons/arrow-corner-up-right-icon/ArrowCornerUpRightIcon.stories.tsx +138 -997
  68. package/dist/icons/arrow-left-icon/ArrowLeftIcon.stories.tsx +136 -942
  69. package/dist/icons/arrow-right-icon/ArrowRightIcon.stories.tsx +148 -1092
  70. package/dist/icons/arrow-right-up-icon/ArrowRightUpIcon.stories.tsx +146 -1211
  71. package/dist/icons/art-board-icon/ArtBoardIcon.stories.tsx +126 -615
  72. package/dist/icons/audio-bar-icon/AudioBarIcon.stories.tsx +144 -1164
  73. package/dist/icons/backward-ten-seconds-icon/BackwardTenSecondsIcon.stories.tsx +167 -985
  74. package/dist/icons/bubble-check-icon/BubbleCheckIcon.stories.tsx +122 -1179
  75. package/dist/icons/bubble-crossed-icon/BubbleCrossedIcon.stories.tsx +124 -1168
  76. package/dist/icons/bubble-sparkle-icon/BubbleSparkleIcon.stories.tsx +119 -850
  77. package/dist/icons/camera-icon/CameraIcon.stories.tsx +112 -1213
  78. package/dist/icons/capital-a-letter-icon/CapitalALetterIcon.stories.tsx +117 -934
  79. package/dist/icons/chevron-double-left-icon/ChevronDoubleLeftIcon.stories.tsx +160 -961
  80. package/dist/icons/chevron-double-right-icon/ChevronDoubleRightIcon.stories.tsx +163 -961
  81. package/dist/icons/chevron-down-icon/ChevronDownIcon.stories.tsx +144 -942
  82. package/dist/icons/chevron-left-icon/ChevronLeftIcon.stories.tsx +129 -966
  83. package/dist/icons/chevron-right-icon/ChevronRightIcon.stories.tsx +147 -964
  84. package/dist/icons/chevron-up-icon/ChevronUpIcon.stories.tsx +145 -975
  85. package/dist/icons/circle-tick-icon/CircleTickIcon.stories.tsx +150 -1142
  86. package/dist/icons/circular-play-icon/CircularPlayIcon.stories.tsx +114 -461
  87. package/dist/icons/coin-icon/CoinIcon.stories.tsx +124 -1322
  88. package/dist/icons/coin-toons-icon/CoinToonsIcon.stories.tsx +117 -1318
  89. package/dist/icons/column-wide-add-icon/ColumnWideAddIcon.stories.tsx +114 -903
  90. package/dist/icons/command-icon/CommandIcon.stories.tsx +127 -1042
  91. package/dist/icons/copy-icon/CopyIcon.stories.tsx +123 -962
  92. package/dist/icons/cross-circle-icon/CrossCircleIcon.stories.tsx +147 -999
  93. package/dist/icons/cross-icon/CrossIcon.stories.tsx +139 -960
  94. package/dist/icons/download-icon/DownloadIcon.stories.tsx +126 -820
  95. package/dist/icons/edit-big-icon/EditBigIcon.stories.tsx +124 -1031
  96. package/dist/icons/email-icon/EmailIcon.stories.tsx +115 -936
  97. package/dist/icons/expand-icon/ExpandIcon.stories.tsx +112 -1111
  98. package/dist/icons/eye-close-icon/EyeCloseIcon.stories.tsx +144 -1025
  99. package/dist/icons/eye-open-icon/EyeOpenIcon.stories.tsx +143 -1036
  100. package/dist/icons/feature-shine-icon/FeatureShineIcon.stories.tsx +127 -1011
  101. package/dist/icons/file-chart-icon/FileChartIcon.stories.tsx +126 -1056
  102. package/dist/icons/file-text-icon/FileTextIcon.stories.tsx +125 -614
  103. package/dist/icons/filter-bar-row-icon/FilterBarRowIcon.stories.tsx +119 -1050
  104. package/dist/icons/forward-ten-seconds-icon/ForwardTenSecondsIcon.stories.tsx +169 -989
  105. package/dist/icons/git-branch-icon/GitBranchIcon.stories.tsx +115 -1145
  106. package/dist/icons/git-fork-icon/GitForkIcon.stories.tsx +115 -1122
  107. package/dist/icons/globe-icon/GlobeIcon.stories.tsx +130 -313
  108. package/dist/icons/google-logo-icon/GoogleLogoIcon.stories.tsx +145 -940
  109. package/dist/icons/grip-vertical-icon/GripVerticalIcon.stories.tsx +119 -1174
  110. package/dist/icons/head-icon/HeadIcon.stories.tsx +111 -916
  111. package/dist/icons/heart-icon/HeartIcon.stories.tsx +120 -1019
  112. package/dist/icons/image-avatar-sparkle-icon/ImageAvatarSparkleIcon.stories.tsx +119 -683
  113. package/dist/icons/image-icon/ImageIcon.stories.tsx +105 -1121
  114. package/dist/icons/import-folder-icon/ImportFolderIcon.stories.tsx +111 -1192
  115. package/dist/icons/import-left-arrow-folder-icon/ImportLeftArrowFolderIcon.stories.tsx +136 -1256
  116. package/dist/icons/indian-flag-icon/IndianFlagIcon.stories.tsx +159 -962
  117. package/dist/icons/instagram-icon/InstagramIcon.stories.tsx +161 -1385
  118. package/dist/icons/layout-column-icon/LayoutColumnIcon.stories.tsx +124 -972
  119. package/dist/icons/layout-left-icon/LayoutLeftIcon.stories.tsx +119 -948
  120. package/dist/icons/layout-right-icon/LayoutRightIcon.stories.tsx +119 -942
  121. package/dist/icons/light-bulb-simple-icon/LightBulbSimpleIcon.stories.tsx +108 -1215
  122. package/dist/icons/linked-in-icon/LinkedInIcon.stories.tsx +154 -1517
  123. package/dist/icons/magic-book-icon/MagicBookIcon.stories.tsx +110 -1188
  124. package/dist/icons/magic-edit-icon/MagicEditIcon.stories.tsx +119 -678
  125. package/dist/icons/maintenance-icon/MaintenanceIcon.stories.tsx +123 -1184
  126. package/dist/icons/message-icon/MessageIcon.stories.tsx +114 -538
  127. package/dist/icons/minimize-icon/MinimizeIcon.stories.tsx +116 -1158
  128. package/dist/icons/moon-icon/MoonIcon.stories.tsx +120 -536
  129. package/dist/icons/move-horizontal-icon/MoveHorizontalIcon.stories.tsx +109 -1184
  130. package/dist/icons/move-vertical-icon/MoveVerticalIcon.stories.tsx +115 -1134
  131. package/dist/icons/musical-note-icon/MusicalNoteIcon.stories.tsx +119 -971
  132. package/dist/icons/notepad-icon/NotepadIcon.stories.tsx +111 -1100
  133. package/dist/icons/notes-icon/NotesIcon.stories.tsx +119 -1101
  134. package/dist/icons/page-search-icon/PageSearchIcon.stories.tsx +109 -1111
  135. package/dist/icons/page-text-icon/PageTextIcon.stories.tsx +122 -684
  136. package/dist/icons/paint-roll-icon/PaintRollIcon.stories.tsx +113 -954
  137. package/dist/icons/paper-plane-icon/PaperPlaneIcon.stories.tsx +112 -877
  138. package/dist/icons/pause-icon/PauseIcon.stories.tsx +113 -1000
  139. package/dist/icons/pencil-icon/PencilIcon.stories.tsx +115 -1070
  140. package/dist/icons/phone-icon/PhoneIcon.stories.tsx +115 -978
  141. package/dist/icons/plus-icon/PlusIcon.stories.tsx +106 -1093
  142. package/dist/icons/pocket-studio-icon/PocketStudioIcon.stories.tsx +107 -829
  143. package/dist/icons/scroll-down-icon/ScrollDownIcon.stories.tsx +102 -469
  144. package/dist/icons/search-icon/SearchIcon.stories.tsx +111 -1124
  145. package/dist/icons/setting-icon/SettingIcon.stories.tsx +107 -970
  146. package/dist/icons/share-icon/ShareIcon.stories.tsx +120 -1025
  147. package/dist/icons/shield-icon/ShieldIcon.stories.tsx +117 -931
  148. package/dist/icons/site-logo-icon/SiteLogoIcon.stories.tsx +137 -1104
  149. package/dist/icons/skip-backward-icon/SkipBackwardIcon.stories.tsx +172 -982
  150. package/dist/icons/skip-forward-icon/SkipForwardIcon.stories.tsx +164 -983
  151. package/dist/icons/sparkles-soft-icon/SparklesSoftIcon.stories.tsx +105 -958
  152. package/dist/icons/spinner-gradient-icon/SpinnerGradientIcon.stories.tsx +158 -580
  153. package/dist/icons/spinner-gradient-icon/index.tsx +6 -1
  154. package/dist/icons/spinner-solid-icon/SpinnerSolidIcon.stories.tsx +158 -587
  155. package/dist/icons/spinner-solid-icon/index.tsx +6 -1
  156. package/dist/icons/spinner-solid-neutral-icon/SpinnerSolidINeutralcon.stories.tsx +146 -682
  157. package/dist/icons/spinner-solid-neutral-icon/index.tsx +1 -1
  158. package/dist/icons/star-icon/StarIcon.stories.tsx +124 -904
  159. package/dist/icons/store-coin-icon/StoreCoinIcon.stories.tsx +112 -964
  160. package/dist/icons/suggestion-icon/SuggestionIcon.stories.tsx +116 -852
  161. package/dist/icons/sun-icon/SunIcon.stories.tsx +120 -831
  162. package/dist/icons/text-color-icon/TextColorIcon.stories.tsx +116 -950
  163. package/dist/icons/text-indicator-icon/TextIndicatorIcon.stories.tsx +123 -980
  164. package/dist/icons/threads-icon/ThreadsIcon.stories.tsx +156 -1427
  165. package/dist/icons/tick-circle-icon/TickCircleIcon.stories.tsx +146 -1142
  166. package/dist/icons/tick-icon/TickIcon.stories.tsx +145 -1276
  167. package/dist/icons/trash-icon/TrashIcon.stories.tsx +108 -933
  168. package/dist/icons/twitter-x-icon/TwitterXIcon.stories.tsx +157 -1402
  169. package/dist/icons/upload-icon/UploadIcon.stories.tsx +115 -889
  170. package/dist/icons/vertical-menu-icon/VerticalMenuIcon.stories.tsx +118 -984
  171. package/dist/icons/video-play-list-icon/VideoPlaylistIcon.stories.tsx +125 -1049
  172. package/dist/icons/voice-playing-icon/VoicePlayingIcon.stories.tsx +123 -1356
  173. package/dist/icons/volume-full-icon/VolumeFullIcon.stories.tsx +110 -1171
  174. package/dist/icons/volume-half-icon/VolumeHalfIcon.stories.tsx +112 -1093
  175. package/dist/icons/volume-off-icon/VolumeOffIcon.stories.tsx +115 -1087
  176. package/dist/icons/warning-icon/WarningIcon.stories.tsx +122 -1046
  177. package/dist/icons/youtube-icon/YoutubeIcon.stories.tsx +161 -936
  178. package/dist/index.cjs +84 -84
  179. package/dist/index.js +84 -84
  180. package/dist/styles/aural-all-theme.css +1222 -0
  181. package/dist/styles/{aural-theme.css → aural-dark-theme.css} +15 -3
  182. package/dist/styles/aural-light-theme.css +1047 -0
  183. 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 { FeatureShineIcon } from "src/ui/icons/feature-shine-icon"
6
+ import { MagicEditIcon } from "src/ui/icons/magic-edit-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 { MagicBookIcon } from "."
5
19
 
6
20
  const meta: Meta<typeof MagicBookIcon> = {
@@ -11,959 +25,76 @@ const meta: Meta<typeof MagicBookIcon> = {
11
25
  backgrounds: {
12
26
  default: "dark",
13
27
  values: [
14
- { name: "dark", value: "#0a0a0a" },
15
- { name: "darker", value: "#000000" },
16
- { name: "light", value: "#ffffff" },
28
+ { name: "dark", value: "var(--color-fm-surface-primary)" },
29
+ { name: "darker", value: "var(--color-fm-neutral-0)" },
30
+ { name: "light", value: "var(--color-fm-neutral-1100)" },
17
31
  ],
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: #0a0a0a ;
44
- }
45
- #storybook-docs {
46
- background: #0a0a0a ;
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: white ;
54
- }
55
- .sbdocs-p, .sbdocs-li {
56
- color: rgba(255, 255, 255, 0.7) ;
57
- }
58
- .sbdocs-code {
59
- background: rgba(255, 255, 255, 0.1) ;
60
- color: rgba(168, 85, 247, 1) ;
61
- border: 1px solid rgba(255, 255, 255, 0.1) ;
62
- }
63
- .sbdocs-pre {
64
- background: rgba(0, 0, 0, 0.4) ;
65
- border: 1px solid rgba(255, 255, 255, 0.1) ;
66
- }
67
- .sbdocs-table {
68
- background: rgba(255, 255, 255, 0.05) ;
69
- border: 1px solid rgba(255, 255, 255, 0.1) ;
70
- }
71
- .sbdocs-table th {
72
- background: rgba(255, 255, 255, 0.05) ;
73
- color: white ;
74
- border-bottom: 1px solid rgba(255, 255, 255, 0.1) ;
75
- }
76
- .sbdocs-table td {
77
- color: rgba(255, 255, 255, 0.7) ;
78
- border-bottom: 1px solid rgba(255, 255, 255, 0.05) ;
79
- }
80
- @keyframes sparkle {
81
- 0%, 100% { opacity: 1; transform: scale(1); }
82
- 50% { opacity: 0.7; transform: scale(1.1); }
83
- }
84
- .animate-sparkle {
85
- animation: sparkle 2s ease-in-out infinite;
86
- }
87
- @keyframes float {
88
- 0%, 100% { transform: translateY(0px); }
89
- 50% { transform: translateY(-5px); }
90
- }
91
- .animate-float {
92
- animation: float 3s ease-in-out infinite;
93
- }
94
- `}
95
- </style>
96
-
97
- <div className="min-h-screen bg-gradient-to-br from-gray-900 via-purple-900/20 to-gray-900">
98
- {/* Header */}
99
- <div className="relative overflow-hidden border-b border-white/10 bg-black/20 backdrop-blur-xl">
100
- <div className="absolute inset-0 bg-gradient-to-r from-purple-500/10 via-transparent to-indigo-500/10" />
101
- <div className="relative !mx-auto max-w-7xl px-6 py-16">
102
- <div className="!space-y-6 text-center">
103
- <div className="!mx-auto flex h-24 w-24 items-center justify-center rounded-2xl border border-purple-500/30 bg-gradient-to-br from-purple-500/20 to-indigo-500/20">
104
- <MagicBookIcon className="h-12 w-12 text-purple-400" />
105
- </div>
106
- <h1 className="!text-fm-primary text-5xl font-bold">
107
- MagicBookIcon
108
- </h1>
109
- <p className="!mx-auto max-w-3xl text-xl leading-relaxed !text-white/70">
110
- A magical book icon perfect for representing knowledge,
111
- learning, documentation, spells, and educational content.
112
- Features sparkling stars to convey magic and wonder. Built
113
- with accessibility in mind using Radix UI's AccessibleIcon
114
- wrapper.
115
- </p>
116
-
117
- {/* Stats */}
118
- <div className="flex items-center justify-center gap-8 pt-8">
119
- <div className="text-center">
120
- <div className="text-3xl font-bold text-purple-300">
121
- Knowledge
122
- </div>
123
- <div className="text-sm text-white/60">
124
- Learning & education
125
- </div>
126
- </div>
127
- <div className="h-8 w-px bg-white/20" />
128
- <div className="text-center">
129
- <div className="text-3xl font-bold text-indigo-300">
130
- Magic
131
- </div>
132
- <div className="text-sm text-white/60">
133
- Spells & enchantments
134
- </div>
135
- </div>
136
- <div className="h-8 w-px bg-white/20" />
137
- <div className="text-center">
138
- <div className="text-3xl font-bold text-violet-300">
139
- Wisdom
140
- </div>
141
- <div className="text-sm text-white/60">
142
- Documentation & guides
143
- </div>
144
- </div>
145
- </div>
146
- </div>
147
- </div>
148
- </div>
149
-
150
- {/* Content */}
151
- <div className="!mx-auto max-w-7xl !space-y-16 px-6 py-12">
152
- {/* Quick Usage */}
153
- <div className="!space-y-8">
154
- <h2 className="text-center text-3xl font-bold !text-white">
155
- Quick Start
156
- </h2>
157
- <div className="grid grid-cols-1 gap-8 lg:grid-cols-2">
158
- <div className="!space-y-4">
159
- <h3 className="text-xl font-semibold !text-purple-300">
160
- Basic Usage
161
- </h3>
162
- <div className="rounded-lg bg-black/40 p-4">
163
- <pre className="overflow-x-auto text-sm !text-green-300">
164
- {`import { MagicBookIcon } from "@icons/magic-book-icon"
165
-
166
- function FeatureCard() {
35
+ <AuralIconDocsPage
36
+ accentToken="positive"
37
+ features={[
38
+ { title: "AI Writing", description: "AI-assisted story creation" },
39
+ { title: "Magic Book", description: "Smart content generator" },
40
+ { title: "Accessible", description: "ARIA-ready by default" },
41
+ ]}
42
+ quickStart={{
43
+ codeExample: `import { MagicBookIcon } from "src/ui/icons/magic-book-icon"
44
+
45
+ function AIWriteButton() {
167
46
  return (
168
- <div className="flex items-center gap-3">
169
- <MagicBookIcon className="h-6 w-6 text-purple-400 " />
170
- <span>Learn Magic</span>
171
- </div>
172
- )
173
- }`}
174
- </pre>
175
- </div>
176
- </div>
177
-
178
- <div className="!space-y-4">
179
- <h3 className="text-xl font-semibold !text-purple-300">
180
- Live Preview
181
- </h3>
182
- <div className="flex h-32 items-center justify-center rounded-lg border border-white/10 bg-white/5">
183
- <div className="flex items-center gap-3 rounded-lg border border-purple-500/20 bg-purple-500/10 px-4 py-3">
184
- <MagicBookIcon className="h-6 w-6 text-purple-400" />
185
- <span className="text-white">Learn Magic</span>
186
- </div>
187
- </div>
188
- </div>
189
- </div>
190
- </div>
191
-
192
- {/* Props Documentation */}
193
- <div className="!space-y-8">
194
- <h2 className="text-center text-3xl font-bold !text-white">
195
- Props & Configuration
196
- </h2>
197
-
198
- <div className="overflow-hidden rounded-lg border border-white/10 bg-white/5">
199
- <div className="bg-white/5 p-4">
200
- <h3 className="text-xl font-semibold !text-white">Props</h3>
201
- </div>
202
- <table className="!my-0 w-full">
203
- <thead className="bg-white/5">
204
- <tr className="border-b border-white/10">
205
- <th className="px-6 py-4 text-left text-sm font-semibold !text-white">
206
- Prop
207
- </th>
208
- <th className="px-6 py-4 text-left text-sm font-semibold !text-white">
209
- Type
210
- </th>
211
- <th className="px-6 py-4 text-left text-sm font-semibold !text-white">
212
- Default
213
- </th>
214
- <th className="px-6 py-4 text-left text-sm font-semibold !text-white">
215
- Description
216
- </th>
217
- </tr>
218
- </thead>
219
- <tbody>
220
- {" "}
221
- <tr className="!bg-black/10">
222
- <td className="px-6 py-4 font-mono text-sm !text-blue-300">
223
- withAccessibility
224
- </td>
225
- <td className="px-6 py-4 text-sm !text-white/70">
226
- boolean
227
- </td>
228
- <td className="px-6 py-4 text-sm !text-white/50">
229
- true
230
- </td>
231
- <td className="px-6 py-4 text-sm !text-white/70">
232
- Whether to wrap the icon with accessibility feature
233
- </td>
234
- </tr>
235
- <tr className="border-b border-white/5 !bg-black/10">
236
- <td className="px-6 py-4 font-mono text-sm !text-purple-300">
237
- height
238
- </td>
239
- <td className="px-6 py-4 text-sm !text-white/70">
240
- number | string
241
- </td>
242
- <td className="px-6 py-4 text-sm !text-white/50">24</td>
243
- <td className="px-6 py-4 text-sm !text-white/70">
244
- Height of the icon in pixels
245
- </td>
246
- </tr>
247
- <tr className="border-b border-white/5">
248
- <td className="px-6 py-4 font-mono text-sm !text-purple-300">
249
- fill
250
- </td>
251
- <td className="px-6 py-4 text-sm !text-white/70">
252
- string
253
- </td>
254
- <td className="px-6 py-4 text-sm !text-white/50">
255
- currentColor
256
- </td>
257
- <td className="px-6 py-4 text-sm !text-white/70">
258
- Fill color of the icon
259
- </td>
260
- </tr>
261
- <tr className="border-b border-white/5 !bg-black/10">
262
- <td className="px-6 py-4 font-mono text-sm !text-purple-300">
263
- className
264
- </td>
265
- <td className="px-6 py-4 text-sm !text-white/70">
266
- string
267
- </td>
268
- <td className="px-6 py-4 text-sm !text-white/50">-</td>
269
- <td className="px-6 py-4 text-sm !text-white/70">
270
- CSS classes for styling (use for overrides)
271
- </td>
272
- </tr>
273
- <tr className="!bg-black/10">
274
- <td className="px-6 py-4 font-mono text-sm !text-purple-300">
275
- ...svgProps
276
- </td>
277
- <td className="px-6 py-4 text-sm !text-white/70">
278
- SVGProps
279
- </td>
280
- <td className="px-6 py-4 text-sm !text-white/50">-</td>
281
- <td className="px-6 py-4 text-sm !text-white/70">
282
- All standard SVG element props
283
- </td>
284
- </tr>
285
- </tbody>
286
- </table>
287
- </div>
288
- </div>
289
-
290
- {/* Size Variations */}
291
- <div className="!space-y-8">
292
- <h2 className="text-center text-3xl font-bold !text-white">
293
- Size Variations
294
- </h2>
295
- <div className="rounded-lg border border-white/10 bg-white/5 p-8">
296
- <div className="!space-y-6">
297
- <div className="grid grid-cols-1 gap-8 md:grid-cols-2">
298
- <div className="!space-y-4">
299
- <h3 className="text-lg font-semibold !text-purple-300">
300
- Standard Sizes
301
- </h3>
302
- <div className="flex items-end gap-6 rounded-lg bg-black/20 p-6">
303
- <div className="text-center">
304
- <MagicBookIcon className="!mx-auto mb-2 h-3 w-3 text-purple-400" />
305
- <span className="text-xs text-white/60">12px</span>
306
- </div>
307
- <div className="text-center">
308
- <MagicBookIcon className="!mx-auto mb-2 h-4 w-4 text-purple-400" />
309
- <span className="text-xs text-white/60">16px</span>
310
- </div>
311
- <div className="text-center">
312
- <MagicBookIcon className="!mx-auto mb-2 h-5 w-5 text-purple-400" />
313
- <span className="text-xs text-white/60">20px</span>
314
- </div>
315
- <div className="text-center">
316
- <MagicBookIcon className="!mx-auto mb-2 h-6 w-6 text-purple-400" />
317
- <span className="text-xs text-white/60">24px</span>
318
- </div>
319
- <div className="text-center">
320
- <MagicBookIcon className="!mx-auto mb-2 h-8 w-8 text-purple-400" />
321
- <span className="text-xs text-white/60">32px</span>
322
- </div>
323
- <div className="text-center">
324
- <MagicBookIcon className="!mx-auto mb-2 h-12 w-12 text-purple-400" />
325
- <span className="text-xs text-white/60">48px</span>
326
- </div>
327
- </div>
328
- </div>
329
-
330
- <div className="!space-y-4">
331
- <h3 className="text-lg font-semibold !text-purple-300">
332
- Code Example
333
- </h3>
334
- <div className="rounded-lg bg-black/40 p-4">
335
- <pre className="overflow-x-auto text-sm !text-cyan-300">
336
- {`// Small (16px)
337
- <MagicBookIcon className="h-4 w-4 " />
338
-
339
- // Medium (24px)
340
- <MagicBookIcon className="h-6 w-6 " />
341
-
342
- // Large (32px)
343
- <MagicBookIcon className="h-8 w-8 " />
344
-
345
- // Custom size for learning sections
346
- <MagicBookIcon
347
- width={40}
348
- height={40}
349
- className="text-purple-400 "
350
- />`}
351
- </pre>
352
- </div>
353
- </div>
354
- </div>
355
- </div>
356
- </div>
357
- </div>
358
-
359
- {/* Color Variations */}
360
- <div className="!space-y-8">
361
- <h2 className="text-center text-3xl font-bold !text-white">
362
- Color Variations
363
- </h2>
364
- <div className="grid grid-cols-1 gap-8 lg:grid-cols-2">
365
- <div className="!space-y-4">
366
- <h3 className="text-lg font-semibold !text-purple-300">
367
- Semantic Colors
368
- </h3>
369
- <div className="!space-y-4 rounded-lg border border-white/10 bg-white/5 p-6">
370
- <div className="flex items-center gap-4">
371
- <MagicBookIcon className="h-6 w-6 text-purple-400" />
372
- <div>
373
- <div className="text-sm font-medium text-white">
374
- Magic & Spells
375
- </div>
376
- <div className="text-xs text-white/60">
377
- text-purple-400
378
- </div>
379
- </div>
380
- </div>
381
- <div className="flex items-center gap-4">
382
- <MagicBookIcon className="h-6 w-6 text-indigo-400" />
383
- <div>
384
- <div className="text-sm font-medium text-white">
385
- Knowledge & Learning
386
- </div>
387
- <div className="text-xs text-white/60">
388
- text-indigo-400
389
- </div>
390
- </div>
391
- </div>
392
- <div className="flex items-center gap-4">
393
- <MagicBookIcon className="h-6 w-6 text-violet-400" />
394
- <div>
395
- <div className="text-sm font-medium text-white">
396
- Wisdom & Guides
397
- </div>
398
- <div className="text-xs text-white/60">
399
- text-violet-400
400
- </div>
401
- </div>
402
- </div>
403
- <div className="flex items-center gap-4">
404
- <MagicBookIcon className="h-6 w-6 text-blue-400" />
405
- <div>
406
- <div className="text-sm font-medium text-white">
407
- Documentation
408
- </div>
409
- <div className="text-xs text-white/60">
410
- text-blue-400
411
- </div>
412
- </div>
413
- </div>
414
- </div>
415
- </div>
416
-
417
- <div className="!space-y-4">
418
- <h3 className="text-lg font-semibold !text-purple-300">
419
- Custom Colors
420
- </h3>
421
- <div className="rounded-lg bg-black/40 p-4">
422
- <pre className="overflow-x-auto text-sm !text-green-300">
423
- {`// Using Tailwind classes with
424
- <MagicBookIcon className="h-6 w-6 text-purple-400 " />
425
- <MagicBookIcon className="h-6 w-6 text-indigo-500 " />
426
-
427
- // Using CSS custom properties
428
- <MagicBookIcon
429
- className="h-6 w-6 "
430
- style={{ color: 'var(--color-magic)' }}
431
- />
432
-
433
- // Direct fill prop
434
- <MagicBookIcon
435
- width={24}
436
- height={24}
437
- fill="#a855f7"
438
- />`}
439
- </pre>
440
- </div>
441
- </div>
442
- </div>
443
- </div>
444
-
445
- {/* Usage Examples */}
446
- <div className="!space-y-8">
447
- <h2 className="text-center text-3xl font-bold !text-white">
448
- Usage Examples
449
- </h2>
450
-
451
- <div className="grid grid-cols-1 gap-8 lg:grid-cols-2">
452
- {/* Learning Card */}
453
- <div className="!space-y-4">
454
- <h3 className="text-lg font-semibold !text-purple-300">
455
- Learning Card
456
- </h3>
457
- <div className="!space-y-4">
458
- <div className="rounded-lg border border-white/10 bg-white/5 p-6">
459
- <div className="flex items-start gap-4">
460
- <div className="flex h-12 w-12 items-center justify-center rounded-lg border border-purple-500/30 bg-purple-500/20">
461
- <MagicBookIcon className="h-6 w-6 text-purple-400" />
462
- </div>
463
- <div className="flex-1">
464
- <h4 className="mb-2 text-lg font-semibold !text-white">
465
- Magical Arts Guide
466
- </h4>
467
- <p className="text-sm !text-white/70">
468
- Comprehensive guide to enchantments, spells, and
469
- mystical knowledge for aspiring wizards.
470
- </p>
471
- </div>
472
- </div>
473
- </div>
474
- <div className="rounded-lg bg-black/40 p-4">
475
- <pre className="overflow-x-auto text-sm !text-green-300">
476
- {`<div className="border border-white/10 bg-white/5 p-6 rounded-lg">
477
- <div className="flex items-start gap-4">
478
- <div className="flex h-12 w-12 items-center justify-center rounded-lg border border-purple-500/30 bg-purple-500/20">
479
- <MagicBookIcon className="h-6 w-6 text-purple-400 " />
480
- </div>
481
- <div className="flex-1">
482
- <h4 className="mb-2 text-lg font-semibold text-white">Magical Arts Guide</h4>
483
- <p className="text-sm text-white/70">
484
- Comprehensive guide to enchantments, spells, and mystical knowledge.
485
- </p>
486
- </div>
487
- </div>
488
- </div>`}
489
- </pre>
490
- </div>
491
- </div>
492
- </div>
493
-
494
- {/* Course Sections */}
495
- <div className="!space-y-4">
496
- <h3 className="text-lg font-semibold !text-purple-300">
497
- Course Sections
498
- </h3>
499
- <div className="!space-y-4">
500
- <div className="!space-y-3">
501
- {[
502
- {
503
- text: "Introduction to Spellcasting",
504
- level: "Beginner",
505
- color: "purple",
506
- },
507
- {
508
- text: "Advanced Potion Making",
509
- level: "Advanced",
510
- color: "indigo",
511
- },
512
- {
513
- text: "Mystical Creature Studies",
514
- level: "Expert",
515
- color: "violet",
516
- },
517
- ].map((course, index) => (
518
- <div
519
- key={index}
520
- className="flex items-center gap-3 rounded-lg border border-white/10 bg-white/5 p-3"
521
- >
522
- <MagicBookIcon
523
- className={`h-4 w-4 ${
524
- course.color === "purple"
525
- ? "text-purple-400"
526
- : course.color === "indigo"
527
- ? "text-indigo-400"
528
- : "text-violet-400"
529
- }`}
530
- />
531
- <div className="flex-1">
532
- <span className="text-sm text-white">
533
- {course.text}
534
- </span>
535
- </div>
536
- <div
537
- className={`rounded px-2 py-1 text-xs ${
538
- course.level === "Beginner"
539
- ? "bg-green-500/20 text-green-300"
540
- : course.level === "Advanced"
541
- ? "bg-yellow-500/20 text-yellow-300"
542
- : "bg-red-500/20 text-red-300"
543
- }`}
544
- >
545
- {course.level}
546
- </div>
547
- </div>
548
- ))}
549
- </div>
550
- <div className="rounded-lg bg-black/40 p-4">
551
- <pre className="overflow-x-auto text-sm !text-green-300">
552
- {`// Course item
553
- <div className="flex items-center gap-3 border border-white/10 bg-white/5 p-3 rounded-lg">
554
- <MagicBookIcon className="h-4 w-4 text-purple-400 " />
555
- <div className="flex-1">
556
- <span className="text-sm text-white">Introduction to Spellcasting</span>
557
- </div>
558
- <div className="text-xs px-2 py-1 rounded bg-green-500/20 text-green-300">
559
- Beginner
560
- </div>
561
- </div>`}
562
- </pre>
563
- </div>
564
- </div>
565
- </div>
566
-
567
- {/* Documentation Section */}
568
- <div className="!space-y-4">
569
- <h3 className="text-lg font-semibold !text-purple-300">
570
- Documentation Section
571
- </h3>
572
- <div className="!space-y-4">
573
- <div className="relative overflow-hidden rounded-lg border border-purple-500/20 bg-gradient-to-br from-purple-500/10 to-indigo-500/10 p-8 text-center">
574
- <div className="absolute inset-0 bg-gradient-to-r from-transparent via-purple-500/5 to-transparent" />
575
- <div className="relative">
576
- <MagicBookIcon className="!mx-auto mb-4 h-16 w-16 text-purple-400" />
577
- <h2 className="mb-4 text-3xl font-bold !text-white">
578
- Magical Knowledge Base
579
- </h2>
580
- <p className="mb-6 text-lg !text-white/70">
581
- Discover ancient spells, enchantments, and mystical
582
- wisdom
583
- </p>
584
- <button className="rounded-lg bg-purple-500/20 px-6 py-3 text-purple-200 transition-colors hover:bg-purple-500/30">
585
- Explore Spells
586
- </button>
587
- </div>
588
- </div>
589
- <div className="rounded-lg bg-black/40 p-4">
590
- <pre className="overflow-x-auto text-sm !text-green-300">
591
- {`// Documentation hero section
592
- <div className="relative overflow-hidden rounded-lg border border-purple-500/20 bg-gradient-to-br from-purple-500/10 to-indigo-500/10 p-8 text-center">
593
- <div className="relative">
594
- <MagicBookIcon className="mx-auto mb-4 h-16 w-16 text-purple-400 " />
595
- <h2 className="mb-4 text-3xl font-bold text-white">Magical Knowledge Base</h2>
596
- <p className="mb-6 text-lg text-white/70">
597
- Discover ancient spells, enchantments, and mystical wisdom
598
- </p>
599
- <button className="rounded-lg bg-purple-500/20 px-6 py-3 text-purple-200 hover:bg-purple-500/30">
600
- Explore Spells
47
+ <button className="flex items-center gap-2">
48
+ <MagicBookIcon className="h-5 w-5 text-fm-icon-positive" />
49
+ <span>AI Write</span>
601
50
  </button>
602
- </div>
603
- </div>`}
604
- </pre>
605
- </div>
606
- </div>
607
- </div>
608
-
609
- {/* Library Navigation */}
610
- <div className="!space-y-4">
611
- <h3 className="text-lg font-semibold !text-purple-300">
612
- Library Navigation
613
- </h3>
614
- <div className="!space-y-4">
615
- <div className="max-w-xs rounded-lg border border-white/10 bg-white/5 p-3">
616
- {[
617
- { name: "Home", icon: "🏠", active: false },
618
- {
619
- name: "Spellbooks",
620
- icon: "MagicBookIcon",
621
- active: true,
622
- },
623
- { name: "Potions", icon: "🧪", active: false },
624
- { name: "Artifacts", icon: "💎", active: false },
625
- ].map((item, index) => (
626
- <div
627
- key={index}
628
- className={`flex cursor-pointer items-center gap-3 rounded p-2 transition-colors ${
629
- item.active
630
- ? "bg-purple-500/20 text-purple-200"
631
- : "text-white/70 hover:bg-white/10"
632
- }`}
633
- >
634
- {item.icon === "MagicBookIcon" ? (
635
- <MagicBookIcon
636
- className={`h-4 w-4 ${
637
- item.active
638
- ? "text-purple-400"
639
- : "text-white/50"
640
- }`}
641
- />
642
- ) : (
643
- <span className="text-sm">{item.icon}</span>
644
- )}
645
- <span className="flex-1 text-sm">{item.name}</span>
646
- {item.active && (
647
- <div className="h-2 w-2 rounded-full bg-purple-400"></div>
648
- )}
649
- </div>
650
- ))}
651
- </div>
652
- <div className="rounded-lg bg-black/40 p-4">
653
- <pre className="overflow-x-auto text-sm !text-green-300">
654
- {`// Navigation item
655
- <div className="flex items-center gap-3 p-2 rounded bg-purple-500/20 text-purple-200 cursor-pointer">
656
- <MagicBookIcon className="h-4 w-4 text-purple-400 " />
657
- <span className="flex-1 text-sm">Spellbooks</span>
658
- <div className="h-2 w-2 rounded-full bg-purple-400"></div>
659
- </div>`}
660
- </pre>
661
- </div>
662
- </div>
663
- </div>
664
- </div>
665
- </div>
666
-
667
- {/* Interactive States */}
668
- <div className="!space-y-8">
669
- <h2 className="text-center text-3xl font-bold !text-white">
670
- Interactive States & Animations
671
- </h2>
672
- <div className="grid grid-cols-1 gap-8 lg:grid-cols-2">
673
- <div className="!space-y-4">
674
- <h3 className="text-lg font-semibold !text-purple-300">
675
- Hover & Animation Effects
676
- </h3>
677
- <div className="!space-y-4 rounded-lg border border-white/10 bg-white/5 p-6">
678
- <div className="flex items-center gap-4">
679
- <MagicBookIcon className="h-6 w-6 text-white/60 transition-colors hover:text-purple-400" />
680
- <div>
681
- <div className="text-sm font-medium text-white">
682
- Color Change
683
- </div>
684
- <div className="text-xs text-white/60">
685
- hover:text-purple-400
686
- </div>
687
- </div>
688
- </div>
689
- <div className="flex items-center gap-4">
690
- <MagicBookIcon className="h-6 w-6 text-white transition-transform hover:scale-110" />
691
- <div>
692
- <div className="text-sm font-medium text-white">
693
- Scale Effect
694
- </div>
695
- <div className="text-xs text-white/60">
696
- hover:scale-110
697
- </div>
698
- </div>
699
- </div>
700
- <div className="flex items-center gap-4">
701
- <MagicBookIcon className="animate-sparkle h-6 w-6 text-purple-400" />
702
- <div>
703
- <div className="text-sm font-medium text-white">
704
- Magical Sparkle
705
- </div>
706
- <div className="text-xs text-white/60">
707
- animate-sparkle
708
- </div>
709
- </div>
710
- </div>
711
- <div className="flex items-center gap-4">
712
- <MagicBookIcon className="animate-float h-6 w-6 text-purple-400" />
713
- <div>
714
- <div className="text-sm font-medium text-white">
715
- Floating Magic
716
- </div>
717
- <div className="text-xs text-white/60">
718
- animate-float
719
- </div>
720
- </div>
721
- </div>
722
- </div>
723
- </div>
724
-
725
- <div className="!space-y-4">
726
- <h3 className="text-lg font-semibold !text-purple-300">
727
- Animation Examples
728
- </h3>
729
- <div className="rounded-lg bg-black/40 p-4">
730
- <pre className="overflow-x-auto text-sm !text-cyan-300">
731
- {`// Hover effects
732
- <MagicBookIcon className="h-6 w-6 text-white/60 hover:text-purple-400 transition-colors " />
733
-
734
- // Scale on hover
735
- <MagicBookIcon className="h-6 w-6 text-white hover:scale-110 transition-transform " />
736
-
737
- // Sparkle animation
738
- <MagicBookIcon className="h-6 w-6 text-purple-400 animate-sparkle " />
739
-
740
- // Floating effect for magical sections
741
- <MagicBookIcon className="h-6 w-6 text-purple-400 animate-float " />
742
-
743
- // Custom sparkle animation
744
- @keyframes sparkle {
745
- 0%, 100% { opacity: 1; transform: scale(1); }
746
- 50% { opacity: 0.7; transform: scale(1.1); }
747
- }
748
-
749
- .animate-sparkle {
750
- animation: sparkle 2s ease-in-out infinite;
751
- }`}
752
- </pre>
753
- </div>
754
- </div>
755
- </div>
756
- </div>
757
-
758
- {/* Accessibility */}
759
- <div className="!space-y-8">
760
- <h2 className="text-center text-3xl font-bold !text-white">
761
- Accessibility Features
762
- </h2>
763
- <div className="grid grid-cols-1 gap-8 md:grid-cols-2">
764
- <div className="!space-y-4 rounded-lg border border-white/10 bg-white/5 p-6">
765
- <h3 className="text-lg font-semibold !text-green-300">
766
- ✅ Built-in Features
767
- </h3>
768
- <ul className="!space-y-2 text-sm !text-white/70">
769
- <li className="!text-white/70">
770
- Uses Radix UI AccessibleIcon wrapper
771
- </li>
772
- <li className="!text-white/70">
773
- Provides screen reader label "Magic book icon"
774
- </li>
775
- <li className="!text-white/70">
776
- Supports keyboard navigation when interactive
777
- </li>
778
- <li className="!text-white/70">
779
- Maintains proper color contrast ratios
780
- </li>
781
- <li className="!text-white/70">
782
- Scales with user's font size preferences
783
- </li>
784
- </ul>
785
- </div>
786
-
787
- <div className="!space-y-4 rounded-lg border border-white/10 bg-white/5 p-6">
788
- <h3 className="text-lg font-semibold !text-purple-300">
789
- 💡 Best Practices
790
- </h3>
791
- <ul className="!space-y-2 text-sm text-white/70">
792
- <li className="!text-white/70">
793
- Always pair with descriptive context
794
- </li>
795
- <li className="!text-white/70">
796
- Use consistent colors for learning themes
797
- </li>
798
- <li className="!text-white/70">
799
- Consider motion sensitivity for sparkle animations
800
- </li>
801
- <li className="!text-white/70">
802
- Add focus states for interactive elements
803
- </li>
804
- <li className="!text-white/70">
805
- Provide alternative text for complex contexts
806
- </li>
807
- </ul>
808
- </div>
809
- </div>
810
-
811
- <div className="rounded-lg border border-white/10 bg-white/5 p-6">
812
- <h3 className="mb-4 text-lg font-semibold !text-purple-300">
813
- Learning & Knowledge Accessibility
814
- </h3>
815
- <div className="grid grid-cols-1 gap-6 lg:grid-cols-2">
816
- <div className="rounded-lg bg-black/40 p-4">
817
- <pre className="overflow-x-auto text-sm !text-cyan-300">
818
- {`// Learning button with proper ARIA
819
- <button
820
- aria-label="Access magical knowledge base and spellbook library"
821
- className="flex items-center gap-2 p-3 rounded-lg focus:ring-2 focus:ring-purple-500"
822
- onClick={handleLearnClick}
823
- >
824
- <MagicBookIcon className="h-5 w-5 text-purple-400 " />
825
- <span>Learn Magic</span>
826
- </button>
827
-
828
- // Course card with semantic structure
829
- <div
830
- role="article"
831
- aria-labelledby="course-title"
832
- className="border border-white/10 bg-white/5 p-6 rounded-lg"
833
- >
834
- <div className="flex items-start gap-4">
835
- <div className="flex h-12 w-12 items-center justify-center rounded-lg bg-purple-500/20" aria-hidden="true">
836
- <MagicBookIcon className="h-6 w-6 text-purple-400 " />
837
- </div>
838
- <div>
839
- <h4 id="course-title" className="text-lg font-semibold text-white">
840
- Magical Arts Guide
841
- </h4>
842
- <p className="text-sm text-white/70">
843
- Comprehensive guide to enchantments and mystical knowledge.
844
- </p>
845
- </div>
846
- </div>
847
- </div>`}
848
- </pre>
849
- </div>
850
- <div className="!space-y-4">
851
- <p className="text-sm !text-white/70">
852
- When using MagicBookIcon for learning and knowledge
853
- features, provide clear context about what educational
854
- content or magical knowledge users can access.
855
- </p>
856
- <div className="rounded-lg border border-purple-500/20 bg-purple-500/10 p-4">
857
- <div className="flex items-center gap-2 text-sm text-purple-200">
858
- <MagicBookIcon className="h-4 w-4" />
859
- <span>
860
- Screen readers understand this represents learning
861
- content
862
- </span>
863
- </div>
864
- </div>
865
- </div>
866
- </div>
867
- </div>
868
- </div>
869
-
870
- {/* Related Icons */}
871
- <div className="!space-y-8">
872
- <h2 className="text-center text-3xl font-bold !text-white">
873
- Related Icons
874
- </h2>
875
- <div className="grid grid-cols-2 gap-6 md:grid-cols-4">
876
- <div className="!space-y-3 rounded-lg border border-white/10 bg-white/5 p-4 text-center">
877
- <div className="!mx-auto flex h-12 w-12 items-center justify-center rounded-lg bg-blue-500/20">
878
- <span className="text-2xl">📚</span>
879
- </div>
880
- <div>
881
- <div className="font-medium text-white">LibraryIcon</div>
882
- <div className="text-xs text-white/60">
883
- Books & knowledge
884
- </div>
885
- </div>
886
- </div>
887
- <div className="!space-y-3 rounded-lg border border-white/10 bg-white/5 p-4 text-center">
888
- <div className="!mx-auto flex h-12 w-12 items-center justify-center rounded-lg bg-purple-500/20">
889
- <span className="text-2xl">🎓</span>
890
- </div>
891
- <div>
892
- <div className="font-medium text-white">
893
- EducationIcon
894
- </div>
895
- <div className="text-xs text-white/60">
896
- Learning & degrees
897
- </div>
898
- </div>
899
- </div>
900
- <div className="!space-y-3 rounded-lg border border-white/10 bg-white/5 p-4 text-center">
901
- <div className="!mx-auto flex h-12 w-12 items-center justify-center rounded-lg bg-indigo-500/20">
902
- <span className="text-2xl">🪄</span>
903
- </div>
904
- <div>
905
- <div className="font-medium text-white">WandIcon</div>
906
- <div className="text-xs text-white/60">
907
- Magic & spells
908
- </div>
909
- </div>
910
- </div>
911
- <div className="!space-y-3 rounded-lg border border-white/10 bg-white/5 p-4 text-center">
912
- <div className="!mx-auto flex h-12 w-12 items-center justify-center rounded-lg bg-violet-500/20">
913
- <span className="text-2xl">📖</span>
914
- </div>
915
- <div>
916
- <div className="font-medium text-white">DocumentIcon</div>
917
- <div className="text-xs text-white/60">Documentation</div>
918
- </div>
919
- </div>
920
- </div>
921
- </div>
922
- </div>
923
-
924
- {/* Footer */}
925
- <div className="border-t border-white/10 bg-black/20 backdrop-blur-xl">
926
- <div className="!mx-auto max-w-7xl px-6 py-8">
927
- <div className="!space-y-4 text-center">
928
- <p className="!text-white/60">
929
- MagicBookIcon is part of the Aural UI icon library, built
930
- for representing magical knowledge, learning, and
931
- educational content.
932
- </p>
933
- <p className="text-sm !text-white/40">
934
- All icons use Radix UI's AccessibleIcon for screen reader
935
- compatibility and follow WCAG guidelines for learning
936
- applications.
937
- </p>
938
- </div>
939
- </div>
940
- </div>
941
- </div>
942
- </>
51
+ )
52
+ }`,
53
+ livePreview: (
54
+ <button className="flex items-center gap-2">
55
+ <MagicBookIcon className="text-fm-icon-positive h-6 w-6" />
56
+ </button>
57
+ ),
58
+ }}
59
+ relatedIcons={[
60
+ {
61
+ name: "MagicEditIcon",
62
+ description: "AI-enhanced edit icon",
63
+ icon: MagicEditIcon,
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: "FeatureShineIcon",
80
+ description: "Feature highlight / shine icon",
81
+ icon: FeatureShineIcon,
82
+ accentToken: "negative",
83
+ },
84
+ ]}
85
+ />
943
86
  ),
944
87
  },
945
88
  },
946
89
  tags: ["autodocs"],
947
90
  argTypes: {
948
- width: {
949
- control: { type: "range", min: 8, max: 96, step: 2 },
950
- description: "Width of the icon in pixels",
91
+ className: {
92
+ control: "text",
93
+ description: "CSS classes including color token",
951
94
  },
952
95
  withAccessibility: {
953
96
  control: "boolean",
954
- description: "Whether to wrap the icon with accessibility features",
955
- },
956
- height: {
957
- control: { type: "range", min: 8, max: 96, step: 2 },
958
- description: "Height of the icon in pixels",
959
- },
960
- fill: {
961
- control: "color",
962
- description: "Fill color of the icon",
963
- },
964
- className: {
965
- control: "text",
966
- description: "CSS classes for styling (use for overrides)",
97
+ description: "Wrap with accessibility label",
967
98
  },
968
99
  },
969
100
  }
@@ -971,283 +102,74 @@ function FeatureCard() {
971
102
  export default meta
972
103
  type Story = StoryObj<typeof MagicBookIcon>
973
104
 
974
- // Story parameters for consistent dark theme
975
- const storyParameters = {
976
- backgrounds: {
977
- default: "dark",
978
- values: [
979
- { name: "dark", value: "#0a0a0a" },
980
- { name: "darker", value: "#000000" },
981
- ],
982
- },
983
- }
984
-
985
105
  export const Default: Story = {
986
106
  args: {
987
- className: "h-6 w-6 text-purple-400 ",
107
+ className: "h-6 w-6 text-fm-icon-positive",
988
108
  withAccessibility: true,
989
109
  },
990
- parameters: storyParameters,
991
110
  render: (args) => (
992
- <div className="flex h-32 min-h-dvh items-center justify-center rounded-lg bg-gradient-to-br from-gray-900 to-gray-800">
111
+ <IconDefaultCanvas>
993
112
  <MagicBookIcon {...args} />
994
- </div>
113
+ </IconDefaultCanvas>
995
114
  ),
996
115
  }
997
116
 
998
117
  export const SizeVariations: Story = {
999
- parameters: {
1000
- ...storyParameters,
1001
- docs: {
1002
- description: {
1003
- story:
1004
- "MagicBookIcon in different sizes, from small UI elements to large learning displays.",
1005
- },
1006
- },
1007
- },
1008
- render: () => (
1009
- <div className="flex h-64 min-h-dvh items-center justify-center gap-8 rounded-lg bg-gradient-to-br from-gray-900 to-gray-800 p-8">
1010
- <div className="text-center">
1011
- <MagicBookIcon className="!mx-auto mb-2 h-3 w-3 text-purple-400" />
1012
- <span className="text-xs text-white/60">12px</span>
1013
- </div>
1014
- <div className="text-center">
1015
- <MagicBookIcon className="!mx-auto mb-2 h-4 w-4 text-purple-400" />
1016
- <span className="text-xs text-white/60">16px</span>
1017
- </div>
1018
- <div className="text-center">
1019
- <MagicBookIcon className="!mx-auto mb-2 h-5 w-5 text-purple-400" />
1020
- <span className="text-xs text-white/60">20px</span>
1021
- </div>
1022
- <div className="text-center">
1023
- <MagicBookIcon className="!mx-auto mb-2 h-6 w-6 text-purple-400" />
1024
- <span className="text-xs text-white/60">24px</span>
1025
- </div>
1026
- <div className="text-center">
1027
- <MagicBookIcon className="!mx-auto mb-2 h-8 w-8 text-purple-400" />
1028
- <span className="text-xs text-white/60">32px</span>
1029
- </div>
1030
- <div className="text-center">
1031
- <MagicBookIcon className="!mx-auto mb-2 h-12 w-12 text-purple-400" />
1032
- <span className="text-xs text-white/60">48px</span>
1033
- </div>
1034
- </div>
1035
- ),
118
+ render: () => <IconSizeVariations icon={MagicBookIcon} />,
1036
119
  }
1037
120
 
1038
121
  export const ColorVariations: Story = {
1039
- parameters: {
1040
- ...storyParameters,
1041
- docs: {
1042
- description: {
1043
- story:
1044
- "MagicBookIcon in different colors for various magical and learning contexts.",
1045
- },
1046
- },
1047
- },
1048
- render: () => (
1049
- <div className="grid min-h-dvh grid-cols-2 items-center justify-center gap-6 rounded-lg bg-gradient-to-br from-gray-900 to-gray-800 p-8 md:grid-cols-4">
1050
- <div className="text-center">
1051
- <div className="!mx-auto mb-3 flex h-16 w-16 items-center justify-center rounded-lg border border-purple-500/30 bg-purple-500/20">
1052
- <MagicBookIcon className="h-8 w-8 text-purple-400" />
1053
- </div>
1054
- <div className="text-sm font-medium text-white">Magic & Spells</div>
1055
- <div className="text-xs text-purple-400">text-purple-400</div>
1056
- </div>
1057
- <div className="text-center">
1058
- <div className="!mx-auto mb-3 flex h-16 w-16 items-center justify-center rounded-lg border border-indigo-500/30 bg-indigo-500/20">
1059
- <MagicBookIcon className="h-8 w-8 text-indigo-400" />
1060
- </div>
1061
- <div className="text-sm font-medium text-white">Knowledge</div>
1062
- <div className="text-xs text-indigo-400">text-indigo-400</div>
1063
- </div>
1064
- <div className="text-center">
1065
- <div className="!mx-auto mb-3 flex h-16 w-16 items-center justify-center rounded-lg border border-violet-500/30 bg-violet-500/20">
1066
- <MagicBookIcon className="h-8 w-8 text-violet-400" />
1067
- </div>
1068
- <div className="text-sm font-medium text-white">Wisdom</div>
1069
- <div className="text-xs text-violet-400">text-violet-400</div>
1070
- </div>
1071
- <div className="text-center">
1072
- <div className="!mx-auto mb-3 flex h-16 w-16 items-center justify-center rounded-lg border border-blue-500/30 bg-blue-500/20">
1073
- <MagicBookIcon className="h-8 w-8 text-blue-400" />
1074
- </div>
1075
- <div className="text-sm font-medium text-white">Documentation</div>
1076
- <div className="text-xs text-blue-400">text-blue-400</div>
1077
- </div>
1078
- </div>
1079
- ),
122
+ render: () => <IconColorVariations icon={MagicBookIcon} />,
1080
123
  }
1081
124
 
1082
125
  export const UsageExamples: Story = {
1083
- parameters: {
1084
- ...storyParameters,
1085
- docs: {
1086
- description: {
1087
- story:
1088
- "Real-world usage examples showing MagicBookIcon in different magical and learning contexts.",
1089
- },
1090
- },
1091
- },
1092
126
  render: () => (
1093
- <div className="min-h-dvh !space-y-8 rounded-lg bg-gradient-to-br from-gray-900 to-gray-800 p-8">
1094
- {/* Learning Card */}
1095
- <div className="!space-y-2">
1096
- <h3 className="text-sm font-medium text-white">Learning Card</h3>
1097
- <div className="rounded-lg border border-white/10 bg-white/5 p-6">
1098
- <div className="flex items-start gap-4">
1099
- <div className="flex h-12 w-12 items-center justify-center rounded-lg border border-purple-500/30 bg-purple-500/20">
1100
- <MagicBookIcon className="h-6 w-6 text-purple-400" />
1101
- </div>
1102
- <div className="flex-1">
1103
- <h4 className="mb-2 text-lg font-semibold !text-white">
1104
- Magical Arts Guide
1105
- </h4>
1106
- <p className="text-sm !text-white/70">
1107
- Comprehensive guide to enchantments, spells, and mystical
1108
- knowledge.
1109
- </p>
1110
- </div>
127
+ <IconUsageCanvas>
128
+ <IconUsageSection title="AI Write 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
+ <MagicBookIcon className="text-fm-icon-positive h-4 w-4" />
131
+ <span className="text-fm-primary font-fm-text text-sm">AI Write</span>
132
+ </button>
133
+ </IconUsageSection>
134
+
135
+ <IconUsageSection title="AI Feature Card">
136
+ <div className="border-fm-divider-secondary bg-fm-surface-secondary w-full max-w-sm rounded-xl border p-4">
137
+ <div className="mb-2 flex items-center gap-2">
138
+ <MagicBookIcon className="text-fm-icon-positive h-5 w-5" />
139
+ <span className="text-fm-primary font-fm-text text-sm font-medium">
140
+ AI Story Generator
141
+ </span>
1111
142
  </div>
143
+ <p className="text-fm-secondary font-fm-text text-xs">
144
+ Create compelling episodes with AI-assisted writing.
145
+ </p>
1112
146
  </div>
1113
- </div>
1114
-
1115
- {/* Course Sections */}
1116
- <div className="!space-y-2">
1117
- <h3 className="text-sm font-medium text-white">Course Sections</h3>
1118
- <div className="!space-y-3">
1119
- {[
1120
- {
1121
- text: "Introduction to Spellcasting",
1122
- level: "Beginner",
1123
- color: "purple",
1124
- },
1125
- {
1126
- text: "Advanced Potion Making",
1127
- level: "Advanced",
1128
- color: "indigo",
1129
- },
1130
- {
1131
- text: "Mystical Creature Studies",
1132
- level: "Expert",
1133
- color: "violet",
1134
- },
1135
- ].map((course, index) => (
1136
- <div
1137
- key={index}
1138
- className="flex items-center gap-3 rounded-lg border border-white/10 bg-white/5 p-3"
147
+ </IconUsageSection>
148
+
149
+ <IconUsageSection title="AI Tools Toolbar">
150
+ <div className="border-fm-divider-secondary bg-fm-surface-secondary flex items-center gap-2 rounded-xl border px-3 py-2">
151
+ {[MagicBookIcon, MagicEditIcon, BubbleSparkleIcon].map((Icon, i) => (
152
+ <button
153
+ key={i}
154
+ className="flex h-8 w-8 items-center justify-center rounded-lg"
1139
155
  >
1140
- <MagicBookIcon
1141
- className={`h-4 w-4 ${
1142
- course.color === "purple"
1143
- ? "text-purple-400"
1144
- : course.color === "indigo"
1145
- ? "text-indigo-400"
1146
- : "text-violet-400"
1147
- }`}
1148
- />
1149
- <div className="flex-1">
1150
- <span className="text-sm text-white">{course.text}</span>
1151
- </div>
1152
- <div
1153
- className={`rounded px-2 py-1 text-xs ${
1154
- course.level === "Beginner"
1155
- ? "bg-green-500/20 text-green-300"
1156
- : course.level === "Advanced"
1157
- ? "bg-yellow-500/20 text-yellow-300"
1158
- : "bg-red-500/20 text-red-300"
1159
- }`}
1160
- >
1161
- {course.level}
1162
- </div>
1163
- </div>
1164
- ))}
1165
- </div>
1166
- </div>
1167
-
1168
- {/* Documentation Hero */}
1169
- <div className="!space-y-2">
1170
- <h3 className="text-sm font-medium text-white">
1171
- Documentation Section
1172
- </h3>
1173
- <div className="relative overflow-hidden rounded-lg border border-purple-500/20 bg-gradient-to-br from-purple-500/10 to-indigo-500/10 p-8 text-center">
1174
- <div className="relative">
1175
- <MagicBookIcon className="!mx-auto mb-4 h-16 w-16 text-purple-400" />
1176
- <h2 className="mb-4 text-3xl font-bold !text-white">
1177
- Magical Knowledge Base
1178
- </h2>
1179
- <p className="mb-6 text-lg !text-white/70">
1180
- Discover ancient spells, enchantments, and mystical wisdom
1181
- </p>
1182
- <button className="rounded-lg bg-purple-500/20 px-6 py-3 text-purple-200 transition-colors hover:bg-purple-500/30">
1183
- Explore Spells
156
+ <Icon className="text-fm-icon-positive h-4 w-4" />
1184
157
  </button>
1185
- </div>
1186
- </div>
1187
- </div>
1188
- </div>
1189
- ),
1190
- }
1191
-
1192
- export const InteractiveStates: Story = {
1193
- parameters: {
1194
- ...storyParameters,
1195
- docs: {
1196
- description: {
1197
- story:
1198
- "Interactive states showing hover effects, animations, and magical visual effects for the magic book icon.",
1199
- },
1200
- },
1201
- },
1202
- render: () => (
1203
- <div className="min-h-dvh !space-y-8 rounded-lg bg-gradient-to-br from-gray-900 to-gray-800 p-8">
1204
- <div className="!space-y-4">
1205
- <h3 className="text-sm font-medium text-white/70">
1206
- Hover & Animation Effects
1207
- </h3>
1208
- <div className="flex gap-8">
1209
- <div className="flex flex-col items-center gap-2">
1210
- <MagicBookIcon className="h-8 w-8 text-white/60 transition-colors hover:text-purple-400" />
1211
- <span className="text-xs text-white/60">Color Change</span>
1212
- </div>
1213
- <div className="flex flex-col items-center gap-2">
1214
- <MagicBookIcon className="h-8 w-8 text-white transition-transform hover:scale-110" />
1215
- <span className="text-xs text-white/60">Scale Up</span>
1216
- </div>
1217
- <div className="flex flex-col items-center gap-2">
1218
- <MagicBookIcon className="animate-sparkle h-8 w-8 text-purple-400" />
1219
- <span className="text-xs text-white/60">Sparkle</span>
1220
- </div>
1221
- <div className="flex flex-col items-center gap-2">
1222
- <MagicBookIcon className="animate-float h-8 w-8 text-purple-400" />
1223
- <span className="text-xs text-white/60">Float</span>
1224
- </div>
158
+ ))}
1225
159
  </div>
1226
- </div>
1227
- </div>
160
+ </IconUsageSection>
161
+ </IconUsageCanvas>
1228
162
  ),
1229
163
  }
1230
164
 
1231
165
  export const Playground: Story = {
1232
- parameters: {
1233
- ...storyParameters,
1234
- docs: {
1235
- description: {
1236
- story:
1237
- "Interactive playground to experiment with different MagicBookIcon configurations.",
1238
- },
1239
- },
1240
- },
1241
166
  args: {
1242
- width: 32,
1243
- height: 32,
1244
- className: "text-purple-400 ",
167
+ className: "h-8 w-8 text-fm-icon-positive",
168
+ withAccessibility: true,
1245
169
  },
1246
170
  render: (args) => (
1247
- <div className="flex h-64 min-h-dvh items-center justify-center rounded-lg bg-gradient-to-br from-gray-900 to-gray-800">
1248
- <div className="rounded-lg border border-white/10 bg-white/5 p-8">
1249
- <MagicBookIcon {...args} />
1250
- </div>
1251
- </div>
171
+ <IconPlaygroundCanvas>
172
+ <MagicBookIcon {...args} />
173
+ </IconPlaygroundCanvas>
1252
174
  ),
1253
175
  }