aural-ui 3.0.6 → 4.0.1
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.
- package/dist/components/aspect-ratio/AspectRatio.stories.tsx +271 -242
- package/dist/components/avatar/Avatar.stories.tsx +84 -70
- package/dist/components/button/Button.stories.tsx +7 -7
- package/dist/components/button/index.tsx +7 -7
- package/dist/components/card/Card.stories.tsx +3 -3
- package/dist/components/char-count/CharCount.stories.tsx +9 -9
- package/dist/components/circular-loader/CircularLoader.stories.tsx +109 -93
- package/dist/components/clamp-lines/ClampLines.stories.tsx +25 -0
- package/dist/components/clamp-lines/index.tsx +6 -1
- package/dist/components/collapsible/Collapsible.stories.tsx +1 -1
- package/dist/components/command/Command.stories.tsx +52 -38
- package/dist/components/dialog/Dialog.stories.tsx +89 -84
- package/dist/components/divider/Divider.stories.tsx +86 -60
- package/dist/components/dot-loader/DotLoader.stories.tsx +12 -12
- package/dist/components/drawer/Drawer.stories.tsx +74 -44
- package/dist/components/drawer/index.tsx +3 -3
- package/dist/components/dropdown/Dropdown.stories.tsx +42 -32
- package/dist/components/helper-text/HelperText.stories.tsx +2 -2
- package/dist/components/hover-card/HoverCard.stories.tsx +211 -178
- package/dist/components/input/Input.stories.tsx +2 -2
- package/dist/components/input/index.tsx +2 -0
- package/dist/components/label/Label.stories.tsx +10 -10
- package/dist/components/list/List.stories.tsx +58 -44
- package/dist/components/marquee/Marquee.stories.tsx +131 -113
- package/dist/components/otp-inputs/OtpInputs.stories.tsx +47 -35
- package/dist/components/overlay/Overlay.stories.tsx +98 -92
- package/dist/components/overlay/index.tsx +4 -4
- package/dist/components/popover/Popover.stories.tsx +132 -106
- package/dist/components/radio/Radio.stories.tsx +2 -2
- package/dist/components/resizable/Resizable.stories.tsx +186 -138
- package/dist/components/scroll-area/ScrollArea.stories.tsx +174 -120
- package/dist/components/search/Search.stories.tsx +81 -59
- package/dist/components/select/Select.stories.tsx +3 -1
- package/dist/components/sheet/Sheet.stories.tsx +68 -54
- package/dist/components/slider/Slider.stories.tsx +71 -47
- package/dist/components/stepper/Stepper.stories.tsx +16 -16
- package/dist/components/switch/Switch.stories.tsx +12 -12
- package/dist/components/table/Table.stories.tsx +8 -6
- package/dist/components/tabs/Tabs.stories.tsx +324 -268
- package/dist/components/textarea/TextArea.stories.tsx +1 -1
- package/dist/components/thumbnail-tags/ThumbnailTags.stories.tsx +16 -10
- package/dist/components/toast/Toast.stories.tsx +51 -45
- package/dist/components/toggle/Toggle.stories.tsx +111 -89
- package/dist/components/tooltip/Tooltip.stories.tsx +160 -144
- package/dist/icons/Icons.stories.tsx +2 -2
- package/dist/icons/ai-avatar-icon/AiAvatarIcon.stories.tsx +287 -237
- package/dist/icons/alert-icon/AlertIcon.stories.tsx +290 -248
- package/dist/icons/all-icons.tsx +97 -81
- package/dist/icons/angle-down-icon/AngleDownIcon.stories.tsx +312 -270
- package/dist/icons/apple-logo-icon/AppleLogoIcon.stories.tsx +294 -244
- package/dist/icons/arrow-box-left-icon/ArrowBoxLeftIcon.stories.tsx +309 -279
- package/dist/icons/arrow-corner-up-left-icon/ArrowCornerUpLeftIcon.stories.tsx +294 -258
- package/dist/icons/arrow-corner-up-right-icon/ArrowCornerUpRightIcon.stories.tsx +289 -255
- package/dist/icons/arrow-left-icon/ArrowLeftIcon.stories.tsx +288 -256
- package/dist/icons/arrow-right-icon/ArrowRightIcon.stories.tsx +322 -288
- package/dist/icons/arrow-right-up-icon/ArrowRightUpIcon.stories.tsx +340 -296
- package/dist/icons/art-board-icon/ArtBoardIcon.stories.tsx +197 -177
- package/dist/icons/audio-bar-icon/AudioBarIcon.stories.tsx +390 -328
- package/dist/icons/backward-ten-seconds-icon/BackwardTenSecondsIcon.stories.tsx +313 -277
- package/dist/icons/bubble-check-icon/BubbleCheckIcon.stories.tsx +367 -309
- package/dist/icons/bubble-crossed-icon/BubbleCrossedIcon.stories.tsx +356 -308
- package/dist/icons/bubble-sparkle-icon/BubbleSparkleIcon.stories.tsx +280 -234
- package/dist/icons/camera-icon/CameraIcon.stories.tsx +370 -326
- package/dist/icons/capital-a-letter-icon/CapitalALetterIcon.stories.tsx +300 -256
- package/dist/icons/chevron-double-left-icon/ChevronDoubleLeftIcon.stories.tsx +298 -262
- package/dist/icons/chevron-double-right-icon/ChevronDoubleRightIcon.stories.tsx +294 -260
- package/dist/icons/chevron-down-icon/ChevronDownIcon.stories.tsx +291 -259
- package/dist/icons/chevron-left-icon/ChevronLeftIcon.stories.tsx +286 -256
- package/dist/icons/chevron-right-icon/ChevronRightIcon.stories.tsx +282 -256
- package/dist/icons/chevron-up-icon/ChevronUpIcon.stories.tsx +292 -256
- package/dist/icons/circle-tick-icon/CircleTickIcon.stories.tsx +338 -290
- package/dist/icons/circular-play-icon/CircularPlayIcon.stories.tsx +167 -148
- package/dist/icons/coin-icon/CoinIcon.stories.tsx +342 -296
- package/dist/icons/coin-toons-icon/CoinToonsIcon.stories.tsx +342 -296
- package/dist/icons/column-wide-add-icon/ColumnWideAddIcon.stories.tsx +280 -238
- package/dist/icons/command-icon/CommandIcon.stories.tsx +328 -280
- package/dist/icons/copy-icon/CopyIcon.stories.tsx +294 -256
- package/dist/icons/cross-circle-icon/CrossCircleIcon.stories.tsx +285 -235
- package/dist/icons/cross-icon/CrossIcon.stories.tsx +308 -266
- package/dist/icons/download-icon/DownloadIcon.stories.tsx +271 -231
- package/dist/icons/edit-big-icon/EditBigIcon.stories.tsx +330 -278
- package/dist/icons/email-icon/EmailIcon.stories.tsx +303 -257
- package/dist/icons/expand-icon/ExpandIcon.stories.tsx +324 -286
- package/dist/icons/eye-close-icon/EyeCloseIcon.stories.tsx +317 -271
- package/dist/icons/eye-open-icon/EyeOpenIcon.stories.tsx +320 -272
- package/dist/icons/feature-shine-icon/FeatureShineIcon.stories.tsx +322 -280
- package/dist/icons/file-chart-icon/FileChartIcon.stories.tsx +315 -277
- package/dist/icons/file-text-icon/FileTextIcon.stories.tsx +199 -177
- package/dist/icons/filter-bar-row-icon/FilterBarRowIcon.stories.tsx +304 -264
- package/dist/icons/forward-ten-seconds-icon/ForwardTenSecondsIcon.stories.tsx +311 -277
- package/dist/icons/git-branch-icon/GitBranchIcon.stories.tsx +327 -287
- package/dist/icons/git-fork-icon/GitForkIcon.stories.tsx +314 -278
- package/dist/icons/globe-icon/GlobeIcon.stories.tsx +113 -98
- package/dist/icons/google-logo-icon/GoogleLogoIcon.stories.tsx +274 -226
- package/dist/icons/grip-vertical-icon/GripVerticalIcon.stories.tsx +349 -303
- package/dist/icons/head-icon/HeadIcon.stories.tsx +286 -246
- package/dist/icons/heart-icon/HeartIcon.stories.tsx +312 -268
- package/dist/icons/image-avatar-sparkle-icon/ImageAvatarSparkleIcon.stories.tsx +246 -210
- package/dist/icons/image-icon/ImageIcon.stories.tsx +330 -284
- package/dist/icons/import-folder-icon/ImportFolderIcon.stories.tsx +326 -282
- package/dist/icons/import-left-arrow-folder-icon/ImportLeftArrowFolderIcon.stories.tsx +330 -294
- package/dist/icons/indian-flag-icon/IndianFlagIcon.stories.tsx +288 -234
- package/dist/icons/instagram-icon/InstagramIcon.stories.tsx +386 -330
- package/dist/icons/layout-column-icon/LayoutColumnIcon.stories.tsx +305 -263
- package/dist/icons/layout-left-icon/LayoutLeftIcon.stories.tsx +295 -259
- package/dist/icons/layout-right-icon/LayoutRightIcon.stories.tsx +296 -256
- package/dist/icons/light-bulb-simple-icon/LightBulbSimpleIcon.stories.tsx +322 -282
- package/dist/icons/linked-in-icon/LinkedInIcon.stories.tsx +399 -359
- package/dist/icons/magic-book-icon/MagicBookIcon.stories.tsx +314 -272
- package/dist/icons/magic-edit-icon/MagicEditIcon.stories.tsx +238 -206
- package/dist/icons/maintenance-icon/MaintenanceIcon.stories.tsx +322 -276
- package/dist/icons/message-icon/MessageIcon.stories.tsx +192 -170
- package/dist/icons/minimize-icon/MinimizeIcon.stories.tsx +348 -304
- package/dist/icons/moon-icon/MoonIcon.stories.tsx +191 -167
- package/dist/icons/move-horizontal-icon/MoveHorizontalIcon.stories.tsx +380 -326
- package/dist/icons/move-vertical-icon/MoveVerticalIcon.stories.tsx +345 -291
- package/dist/icons/musical-note-icon/MusicalNoteIcon.stories.tsx +310 -266
- package/dist/icons/notepad-icon/NotepadIcon.stories.tsx +311 -271
- package/dist/icons/notes-icon/NotesIcon.stories.tsx +311 -271
- package/dist/icons/page-search-icon/PageSearchIcon.stories.tsx +309 -271
- package/dist/icons/page-text-icon/PageTextIcon.stories.tsx +248 -210
- package/dist/icons/paint-roll-icon/PaintRollIcon.stories.tsx +310 -262
- package/dist/icons/paper-plane-icon/PaperPlaneIcon.stories.tsx +274 -236
- package/dist/icons/pause-icon/PauseIcon.stories.tsx +324 -280
- package/dist/icons/pencil-icon/PencilIcon.stories.tsx +323 -281
- package/dist/icons/phone-icon/PhoneIcon.stories.tsx +288 -240
- package/dist/icons/plus-icon/PlusIcon.stories.tsx +315 -273
- package/dist/icons/pocket-studio-icon/PocketStudioIcon.stories.tsx +278 -234
- package/dist/icons/scroll-down-icon/ScrollDownIcon.stories.tsx +161 -151
- package/dist/icons/search-icon/SearchIcon.stories.tsx +324 -284
- package/dist/icons/setting-icon/SettingIcon.stories.tsx +306 -264
- package/dist/icons/share-icon/ShareIcon.stories.tsx +314 -272
- package/dist/icons/shield-icon/ShieldIcon.stories.tsx +281 -235
- package/dist/icons/site-logo-icon/SiteLogoIcon.stories.tsx +309 -250
- package/dist/icons/skip-backward-icon/SkipBackwardIcon.stories.tsx +317 -279
- package/dist/icons/skip-forward-icon/SkipForwardIcon.stories.tsx +315 -279
- package/dist/icons/sparkles-soft-icon/SparklesSoftIcon.stories.tsx +299 -253
- package/dist/icons/spinner-gradient-icon/SpinnerGradientIcon.stories.tsx +185 -169
- package/dist/icons/spinner-gradient-icon/index.tsx +6 -1
- package/dist/icons/spinner-solid-icon/SpinnerSolidIcon.stories.tsx +192 -168
- package/dist/icons/spinner-solid-icon/index.tsx +6 -1
- package/dist/icons/spinner-solid-neutral-icon/SpinnerSolidINeutralcon.stories.tsx +212 -178
- package/dist/icons/spinner-solid-neutral-icon/index.tsx +1 -1
- package/dist/icons/star-icon/StarIcon.stories.tsx +290 -244
- package/dist/icons/store-coin-icon/StoreCoinIcon.stories.tsx +286 -234
- package/dist/icons/suggestion-icon/SuggestionIcon.stories.tsx +272 -230
- package/dist/icons/sun-icon/SunIcon.stories.tsx +262 -226
- package/dist/icons/text-color-icon/TextColorIcon.stories.tsx +321 -279
- package/dist/icons/text-indicator-icon/TextIndicatorIcon.stories.tsx +332 -282
- package/dist/icons/threads-icon/ThreadsIcon.stories.tsx +394 -342
- package/dist/icons/tick-circle-icon/TickCircleIcon.stories.tsx +338 -290
- package/dist/icons/tick-icon/TickIcon.stories.tsx +364 -315
- package/dist/icons/trash-icon/TrashIcon.stories.tsx +293 -253
- package/dist/icons/twitter-x-icon/TwitterXIcon.stories.tsx +396 -338
- package/dist/icons/upload-icon/UploadIcon.stories.tsx +291 -247
- package/dist/icons/vertical-menu-icon/VerticalMenuIcon.stories.tsx +309 -271
- package/dist/icons/video-play-list-icon/VideoPlaylistIcon.stories.tsx +336 -290
- package/dist/icons/voice-playing-icon/VoicePlayingIcon.stories.tsx +382 -334
- package/dist/icons/volume-full-icon/VolumeFullIcon.stories.tsx +349 -305
- package/dist/icons/volume-half-icon/VolumeHalfIcon.stories.tsx +327 -295
- package/dist/icons/volume-off-icon/VolumeOffIcon.stories.tsx +336 -296
- package/dist/icons/warning-icon/WarningIcon.stories.tsx +314 -274
- package/dist/icons/youtube-icon/YoutubeIcon.stories.tsx +311 -261
- package/dist/index.cjs +84 -84
- package/dist/index.js +84 -84
- package/dist/styles/aural-all-theme.css +1222 -0
- package/dist/styles/{aural-theme.css → aural-dark-theme.css} +15 -3
- package/dist/styles/aural-light-theme.css +1047 -0
- package/package.json +1 -1
|
@@ -84,8 +84,10 @@ export const BasicVerticalScroll: Story = {
|
|
|
84
84
|
render: () => (
|
|
85
85
|
<div className="space-y-8">
|
|
86
86
|
<div className="text-center">
|
|
87
|
-
<h3 className="mb-2 font-medium
|
|
88
|
-
|
|
87
|
+
<h3 className="text-fm-primary mb-2 font-medium">
|
|
88
|
+
Basic Vertical Scroll
|
|
89
|
+
</h3>
|
|
90
|
+
<p className="text-fm-secondary text-sm">
|
|
89
91
|
Standard vertical scrolling with custom styled scrollbar
|
|
90
92
|
</p>
|
|
91
93
|
</div>
|
|
@@ -93,13 +95,15 @@ export const BasicVerticalScroll: Story = {
|
|
|
93
95
|
<div className="flex flex-wrap justify-center gap-8">
|
|
94
96
|
{/* Text Content */}
|
|
95
97
|
<div className="space-y-2">
|
|
96
|
-
<h4 className="text-sm font-medium
|
|
97
|
-
|
|
98
|
+
<h4 className="text-fm-secondary text-sm font-medium">
|
|
99
|
+
Text Content
|
|
100
|
+
</h4>
|
|
101
|
+
<ScrollArea className="border-fm-divider-secondary bg-fm-surface-secondary h-72 w-80 rounded-lg border">
|
|
98
102
|
<div className="p-4">
|
|
99
|
-
<h4 className="mb-4 text-sm leading-none font-medium
|
|
103
|
+
<h4 className="text-fm-primary mb-4 text-sm leading-none font-medium">
|
|
100
104
|
The Art of Web Development
|
|
101
105
|
</h4>
|
|
102
|
-
<div className="space-y-4 text-sm
|
|
106
|
+
<div className="text-fm-secondary space-y-4 text-sm">
|
|
103
107
|
<p>
|
|
104
108
|
Web development is an ever-evolving field that combines
|
|
105
109
|
creativity with technical expertise. Modern developers must
|
|
@@ -145,10 +149,12 @@ export const BasicVerticalScroll: Story = {
|
|
|
145
149
|
|
|
146
150
|
{/* List Content */}
|
|
147
151
|
<div className="space-y-2">
|
|
148
|
-
<h4 className="text-sm font-medium
|
|
149
|
-
|
|
152
|
+
<h4 className="text-fm-secondary text-sm font-medium">
|
|
153
|
+
List Content
|
|
154
|
+
</h4>
|
|
155
|
+
<ScrollArea className="border-fm-divider-secondary bg-fm-surface-secondary h-72 w-80 rounded-lg border">
|
|
150
156
|
<div className="p-4">
|
|
151
|
-
<h4 className="mb-4 text-sm leading-none font-medium
|
|
157
|
+
<h4 className="text-fm-primary mb-4 text-sm leading-none font-medium">
|
|
152
158
|
Popular Programming Languages
|
|
153
159
|
</h4>
|
|
154
160
|
<div className="space-y-2">
|
|
@@ -183,10 +189,12 @@ export const BasicVerticalScroll: Story = {
|
|
|
183
189
|
].map((lang, index) => (
|
|
184
190
|
<div
|
|
185
191
|
key={index}
|
|
186
|
-
className="rounded-lg border
|
|
192
|
+
className="border-fm-divider-secondary bg-fm-surface-secondary rounded-lg border p-3"
|
|
187
193
|
>
|
|
188
|
-
<div className="font-medium
|
|
189
|
-
|
|
194
|
+
<div className="text-fm-primary font-medium">
|
|
195
|
+
{lang.name}
|
|
196
|
+
</div>
|
|
197
|
+
<div className="text-fm-secondary text-xs">{lang.desc}</div>
|
|
190
198
|
</div>
|
|
191
199
|
))}
|
|
192
200
|
</div>
|
|
@@ -211,8 +219,8 @@ export const HorizontalScroll: Story = {
|
|
|
211
219
|
render: () => (
|
|
212
220
|
<div className="space-y-8">
|
|
213
221
|
<div className="text-center">
|
|
214
|
-
<h3 className="mb-2 font-medium
|
|
215
|
-
<p className="text-
|
|
222
|
+
<h3 className="text-fm-primary mb-2 font-medium">Horizontal Scroll</h3>
|
|
223
|
+
<p className="text-fm-secondary text-sm">
|
|
216
224
|
Horizontal scrolling with custom scrollbar orientation
|
|
217
225
|
</p>
|
|
218
226
|
</div>
|
|
@@ -220,8 +228,10 @@ export const HorizontalScroll: Story = {
|
|
|
220
228
|
<div className="space-y-6">
|
|
221
229
|
{/* Image Gallery */}
|
|
222
230
|
<div className="space-y-2">
|
|
223
|
-
<h4 className="text-sm font-medium
|
|
224
|
-
|
|
231
|
+
<h4 className="text-fm-secondary text-sm font-medium">
|
|
232
|
+
Image Gallery
|
|
233
|
+
</h4>
|
|
234
|
+
<ScrollArea className="border-fm-divider-secondary bg-fm-surface-secondary w-full max-w-4xl rounded-lg border whitespace-nowrap">
|
|
225
235
|
<div className="flex w-max gap-4 p-4">
|
|
226
236
|
{[
|
|
227
237
|
{
|
|
@@ -271,7 +281,7 @@ export const HorizontalScroll: Story = {
|
|
|
271
281
|
>
|
|
272
282
|
{item.name}
|
|
273
283
|
</div>
|
|
274
|
-
<p className="text-
|
|
284
|
+
<p className="text-fm-secondary text-center text-xs">
|
|
275
285
|
{item.name}
|
|
276
286
|
</p>
|
|
277
287
|
</div>
|
|
@@ -283,8 +293,10 @@ export const HorizontalScroll: Story = {
|
|
|
283
293
|
|
|
284
294
|
{/* Tag List */}
|
|
285
295
|
<div className="space-y-2">
|
|
286
|
-
<h4 className="text-sm font-medium
|
|
287
|
-
|
|
296
|
+
<h4 className="text-fm-secondary text-sm font-medium">
|
|
297
|
+
Technology Tags
|
|
298
|
+
</h4>
|
|
299
|
+
<ScrollArea className="border-fm-divider-secondary bg-fm-surface-secondary w-full max-w-2xl rounded-lg border whitespace-nowrap">
|
|
288
300
|
<div className="flex w-max gap-2 p-4">
|
|
289
301
|
{[
|
|
290
302
|
"React",
|
|
@@ -315,7 +327,7 @@ export const HorizontalScroll: Story = {
|
|
|
315
327
|
].map((tag, index) => (
|
|
316
328
|
<div
|
|
317
329
|
key={index}
|
|
318
|
-
className="flex-none rounded-full border
|
|
330
|
+
className="border-fm-divider-secondary bg-fm-surface-info-sec text-fm-info flex-none rounded-full border px-3 py-1 text-xs"
|
|
319
331
|
>
|
|
320
332
|
{tag}
|
|
321
333
|
</div>
|
|
@@ -327,10 +339,10 @@ export const HorizontalScroll: Story = {
|
|
|
327
339
|
|
|
328
340
|
{/* Timeline */}
|
|
329
341
|
<div className="space-y-2">
|
|
330
|
-
<h4 className="text-sm font-medium
|
|
342
|
+
<h4 className="text-fm-secondary text-sm font-medium">
|
|
331
343
|
Project Timeline
|
|
332
344
|
</h4>
|
|
333
|
-
<ScrollArea className="w-full max-w-3xl rounded-lg border
|
|
345
|
+
<ScrollArea className="border-fm-divider-secondary bg-fm-surface-secondary w-full max-w-3xl rounded-lg border whitespace-nowrap">
|
|
334
346
|
<div className="flex w-max gap-6 p-4">
|
|
335
347
|
{[
|
|
336
348
|
{ phase: "Planning", duration: "2 weeks", status: "completed" },
|
|
@@ -345,20 +357,22 @@ export const HorizontalScroll: Story = {
|
|
|
345
357
|
{ phase: "Launch", duration: "1 week", status: "pending" },
|
|
346
358
|
].map((item, index) => (
|
|
347
359
|
<div key={index} className="flex-none space-y-2">
|
|
348
|
-
<div className="w-32 rounded-lg border
|
|
360
|
+
<div className="border-fm-divider-secondary bg-fm-surface-secondary w-32 rounded-lg border p-3">
|
|
349
361
|
<div
|
|
350
362
|
className={`mb-2 h-2 w-2 rounded-full ${
|
|
351
363
|
item.status === "completed"
|
|
352
|
-
? "bg-
|
|
364
|
+
? "bg-fm-surface-positive"
|
|
353
365
|
: item.status === "in-progress"
|
|
354
|
-
? "bg-
|
|
355
|
-
: "bg-
|
|
366
|
+
? "bg-fm-surface-warning"
|
|
367
|
+
: "bg-fm-surface-tertiary"
|
|
356
368
|
}`}
|
|
357
369
|
></div>
|
|
358
|
-
<div className="text-sm font-medium
|
|
370
|
+
<div className="text-fm-primary text-sm font-medium">
|
|
359
371
|
{item.phase}
|
|
360
372
|
</div>
|
|
361
|
-
<div className="text-
|
|
373
|
+
<div className="text-fm-secondary text-xs">
|
|
374
|
+
{item.duration}
|
|
375
|
+
</div>
|
|
362
376
|
</div>
|
|
363
377
|
</div>
|
|
364
378
|
))}
|
|
@@ -384,8 +398,10 @@ export const BothDirectionsScroll: Story = {
|
|
|
384
398
|
render: () => (
|
|
385
399
|
<div className="space-y-8">
|
|
386
400
|
<div className="text-center">
|
|
387
|
-
<h3 className="mb-2 font-medium
|
|
388
|
-
|
|
401
|
+
<h3 className="text-fm-primary mb-2 font-medium">
|
|
402
|
+
Two-Dimensional Scroll
|
|
403
|
+
</h3>
|
|
404
|
+
<p className="text-fm-secondary text-sm">
|
|
389
405
|
Content that scrolls both horizontally and vertically
|
|
390
406
|
</p>
|
|
391
407
|
</div>
|
|
@@ -393,62 +409,71 @@ export const BothDirectionsScroll: Story = {
|
|
|
393
409
|
<div className="space-y-6">
|
|
394
410
|
{/* Data Table */}
|
|
395
411
|
<div className="space-y-2">
|
|
396
|
-
<h4 className="text-sm font-medium
|
|
397
|
-
<ScrollArea className="h-80 w-full max-w-4xl rounded-lg border
|
|
412
|
+
<h4 className="text-fm-secondary text-sm font-medium">Data Table</h4>
|
|
413
|
+
<ScrollArea className="border-fm-divider-secondary bg-fm-surface-secondary h-80 w-full max-w-4xl rounded-lg border">
|
|
398
414
|
<div className="w-[1200px] p-4">
|
|
399
415
|
<table className="w-full text-sm">
|
|
400
416
|
<thead>
|
|
401
|
-
<tr className="border-
|
|
402
|
-
<th className="p-2 text-left
|
|
403
|
-
<th className="p-2 text-left
|
|
404
|
-
<th className="p-2 text-left
|
|
405
|
-
<th className="p-2 text-left
|
|
406
|
-
<th className="p-2 text-left
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
<th className="p-2 text-left
|
|
410
|
-
<th className="p-2 text-left
|
|
417
|
+
<tr className="border-fm-divider-secondary border-b">
|
|
418
|
+
<th className="text-fm-primary p-2 text-left">ID</th>
|
|
419
|
+
<th className="text-fm-primary p-2 text-left">Name</th>
|
|
420
|
+
<th className="text-fm-primary p-2 text-left">Email</th>
|
|
421
|
+
<th className="text-fm-primary p-2 text-left">Role</th>
|
|
422
|
+
<th className="text-fm-primary p-2 text-left">
|
|
423
|
+
Department
|
|
424
|
+
</th>
|
|
425
|
+
<th className="text-fm-primary p-2 text-left">Location</th>
|
|
426
|
+
<th className="text-fm-primary p-2 text-left">
|
|
427
|
+
Start Date
|
|
428
|
+
</th>
|
|
429
|
+
<th className="text-fm-primary p-2 text-left">Salary</th>
|
|
430
|
+
<th className="text-fm-primary p-2 text-left">Status</th>
|
|
411
431
|
</tr>
|
|
412
432
|
</thead>
|
|
413
433
|
<tbody>
|
|
414
434
|
{Array.from({ length: 50 }, (_, i) => (
|
|
415
|
-
<tr
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
435
|
+
<tr
|
|
436
|
+
key={i}
|
|
437
|
+
className="border-fm-divider-secondary border-b"
|
|
438
|
+
>
|
|
439
|
+
<td className="text-fm-secondary p-2">{1000 + i}</td>
|
|
440
|
+
<td className="text-fm-secondary p-2">
|
|
441
|
+
Employee {i + 1}
|
|
442
|
+
</td>
|
|
443
|
+
<td className="text-fm-secondary p-2">
|
|
419
444
|
employee{i + 1}@company.com
|
|
420
445
|
</td>
|
|
421
|
-
<td className="p-2
|
|
446
|
+
<td className="text-fm-secondary p-2">
|
|
422
447
|
{["Developer", "Designer", "Manager", "Analyst"][i % 4]}
|
|
423
448
|
</td>
|
|
424
|
-
<td className="p-2
|
|
449
|
+
<td className="text-fm-secondary p-2">
|
|
425
450
|
{["Engineering", "Design", "Marketing", "Sales"][i % 4]}
|
|
426
451
|
</td>
|
|
427
|
-
<td className="p-2
|
|
452
|
+
<td className="text-fm-secondary p-2">
|
|
428
453
|
{
|
|
429
454
|
["San Francisco", "New York", "London", "Tokyo"][
|
|
430
455
|
i % 4
|
|
431
456
|
]
|
|
432
457
|
}
|
|
433
458
|
</td>
|
|
434
|
-
<td className="p-2
|
|
459
|
+
<td className="text-fm-secondary p-2">
|
|
435
460
|
{new Date(
|
|
436
461
|
2020 + (i % 4),
|
|
437
462
|
i % 12,
|
|
438
463
|
(i % 28) + 1
|
|
439
464
|
).toLocaleDateString()}
|
|
440
465
|
</td>
|
|
441
|
-
<td className="p-2
|
|
466
|
+
<td className="text-fm-secondary p-2">
|
|
442
467
|
${(50000 + i * 1000).toLocaleString()}
|
|
443
468
|
</td>
|
|
444
469
|
<td className="p-2">
|
|
445
470
|
<span
|
|
446
471
|
className={`rounded-full px-2 py-1 text-xs ${
|
|
447
472
|
i % 3 === 0
|
|
448
|
-
? "bg-
|
|
473
|
+
? "bg-fm-surface-positive-sec text-fm-positive"
|
|
449
474
|
: i % 3 === 1
|
|
450
|
-
? "bg-
|
|
451
|
-
: "bg-
|
|
475
|
+
? "bg-fm-surface-warning-sec text-fm-warning"
|
|
476
|
+
: "bg-fm-surface-secondary text-fm-icon-negative"
|
|
452
477
|
}`}
|
|
453
478
|
>
|
|
454
479
|
{i % 3 === 0
|
|
@@ -469,8 +494,10 @@ export const BothDirectionsScroll: Story = {
|
|
|
469
494
|
|
|
470
495
|
{/* Large Canvas */}
|
|
471
496
|
<div className="space-y-2">
|
|
472
|
-
<h4 className="text-sm font-medium
|
|
473
|
-
|
|
497
|
+
<h4 className="text-fm-secondary text-sm font-medium">
|
|
498
|
+
Design Canvas
|
|
499
|
+
</h4>
|
|
500
|
+
<ScrollArea className="border-fm-divider-secondary bg-fm-surface-secondary h-96 w-full max-w-2xl rounded-lg border">
|
|
474
501
|
<div className="h-[1200px] w-[1500px] bg-gradient-to-br from-blue-900/20 to-purple-900/20 p-4">
|
|
475
502
|
<div className="relative h-full w-full">
|
|
476
503
|
{/* Grid Pattern */}
|
|
@@ -486,19 +513,19 @@ export const BothDirectionsScroll: Story = {
|
|
|
486
513
|
/>
|
|
487
514
|
|
|
488
515
|
{/* Design Elements */}
|
|
489
|
-
<div className="absolute top-20 left-20 flex h-32 w-48 items-center justify-center rounded-lg border border-blue-400/50 bg-blue-500/30
|
|
516
|
+
<div className="text-fm-primary absolute top-20 left-20 flex h-32 w-48 items-center justify-center rounded-lg border border-blue-400/50 bg-blue-500/30">
|
|
490
517
|
Header Component
|
|
491
518
|
</div>
|
|
492
|
-
<div className="absolute top-60 left-20 flex h-40 w-64 items-center justify-center rounded-lg border border-green-400/50 bg-green-500/30
|
|
519
|
+
<div className="text-fm-primary absolute top-60 left-20 flex h-40 w-64 items-center justify-center rounded-lg border border-green-400/50 bg-green-500/30">
|
|
493
520
|
Navigation Menu
|
|
494
521
|
</div>
|
|
495
|
-
<div className="absolute top-20 left-80 flex h-96 w-80 items-center justify-center rounded-lg border border-purple-400/50 bg-purple-500/30
|
|
522
|
+
<div className="text-fm-primary absolute top-20 left-80 flex h-96 w-80 items-center justify-center rounded-lg border border-purple-400/50 bg-purple-500/30">
|
|
496
523
|
Main Content Area
|
|
497
524
|
</div>
|
|
498
|
-
<div className="absolute top-20 right-20 flex h-64 w-56 items-center justify-center rounded-lg border border-orange-400/50 bg-orange-500/30
|
|
525
|
+
<div className="text-fm-primary absolute top-20 right-20 flex h-64 w-56 items-center justify-center rounded-lg border border-orange-400/50 bg-orange-500/30">
|
|
499
526
|
Sidebar Widget
|
|
500
527
|
</div>
|
|
501
|
-
<div className="absolute bottom-20 left-20 flex h-24 w-[calc(100%-160px)] items-center justify-center rounded-lg border
|
|
528
|
+
<div className="border-fm-divider-secondary bg-fm-surface-secondary text-fm-primary absolute bottom-20 left-20 flex h-24 w-[calc(100%-160px)] items-center justify-center rounded-lg border">
|
|
502
529
|
Footer Component
|
|
503
530
|
</div>
|
|
504
531
|
</div>
|
|
@@ -524,8 +551,8 @@ export const DifferentSizes: Story = {
|
|
|
524
551
|
render: () => (
|
|
525
552
|
<div className="space-y-8">
|
|
526
553
|
<div className="text-center">
|
|
527
|
-
<h3 className="mb-2 font-medium
|
|
528
|
-
<p className="text-
|
|
554
|
+
<h3 className="text-fm-primary mb-2 font-medium">Different Sizes</h3>
|
|
555
|
+
<p className="text-fm-secondary text-sm">
|
|
529
556
|
ScrollArea components in various sizes and configurations
|
|
530
557
|
</p>
|
|
531
558
|
</div>
|
|
@@ -533,15 +560,17 @@ export const DifferentSizes: Story = {
|
|
|
533
560
|
<div className="grid grid-cols-1 gap-6 md:grid-cols-2 lg:grid-cols-3">
|
|
534
561
|
{/* Small */}
|
|
535
562
|
<div className="space-y-2">
|
|
536
|
-
<h4 className="text-sm font-medium
|
|
537
|
-
|
|
563
|
+
<h4 className="text-fm-secondary text-sm font-medium">
|
|
564
|
+
Small (h-40)
|
|
565
|
+
</h4>
|
|
566
|
+
<ScrollArea className="border-fm-divider-secondary bg-fm-surface-secondary h-40 w-full rounded-lg border">
|
|
538
567
|
<div className="p-3">
|
|
539
|
-
<h5 className="mb-2 text-sm font-medium
|
|
568
|
+
<h5 className="text-fm-primary mb-2 text-sm font-medium">
|
|
540
569
|
Quick Notes
|
|
541
570
|
</h5>
|
|
542
|
-
<div className="space-y-2 text-xs
|
|
571
|
+
<div className="text-fm-secondary space-y-2 text-xs">
|
|
543
572
|
{Array.from({ length: 15 }, (_, i) => (
|
|
544
|
-
<div key={i} className="
|
|
573
|
+
<div key={i} className="bg-fm-surface-secondary rounded p-2">
|
|
545
574
|
Note item {i + 1}: This is a quick note or reminder item.
|
|
546
575
|
</div>
|
|
547
576
|
))}
|
|
@@ -552,24 +581,32 @@ export const DifferentSizes: Story = {
|
|
|
552
581
|
|
|
553
582
|
{/* Medium */}
|
|
554
583
|
<div className="space-y-2">
|
|
555
|
-
<h4 className="text-sm font-medium
|
|
556
|
-
|
|
584
|
+
<h4 className="text-fm-secondary text-sm font-medium">
|
|
585
|
+
Medium (h-64)
|
|
586
|
+
</h4>
|
|
587
|
+
<ScrollArea className="border-fm-divider-secondary bg-fm-surface-secondary h-64 w-full rounded-lg border">
|
|
557
588
|
<div className="p-4">
|
|
558
|
-
<h5 className="mb-3 text-sm font-medium
|
|
589
|
+
<h5 className="text-fm-primary mb-3 text-sm font-medium">
|
|
590
|
+
Task List
|
|
591
|
+
</h5>
|
|
559
592
|
<div className="space-y-3">
|
|
560
593
|
{Array.from({ length: 12 }, (_, i) => (
|
|
561
594
|
<div
|
|
562
595
|
key={i}
|
|
563
|
-
className="flex items-center gap-3 rounded-lg
|
|
596
|
+
className="bg-fm-surface-secondary flex items-center gap-3 rounded-lg p-3"
|
|
564
597
|
>
|
|
565
598
|
<div
|
|
566
599
|
className={`h-3 w-3 rounded-full ${
|
|
567
|
-
i % 3 === 0
|
|
600
|
+
i % 3 === 0
|
|
601
|
+
? "bg-fm-surface-positive"
|
|
602
|
+
: "bg-fm-surface-tertiary"
|
|
568
603
|
}`}
|
|
569
604
|
></div>
|
|
570
605
|
<div>
|
|
571
|
-
<div className="text-
|
|
572
|
-
|
|
606
|
+
<div className="text-fm-primary text-sm">
|
|
607
|
+
Task {i + 1}
|
|
608
|
+
</div>
|
|
609
|
+
<div className="text-fm-secondary text-xs">
|
|
573
610
|
{i % 3 === 0 ? "Completed" : "Pending"}
|
|
574
611
|
</div>
|
|
575
612
|
</div>
|
|
@@ -582,23 +619,28 @@ export const DifferentSizes: Story = {
|
|
|
582
619
|
|
|
583
620
|
{/* Large */}
|
|
584
621
|
<div className="space-y-2">
|
|
585
|
-
<h4 className="text-sm font-medium
|
|
586
|
-
|
|
622
|
+
<h4 className="text-fm-secondary text-sm font-medium">
|
|
623
|
+
Large (h-96)
|
|
624
|
+
</h4>
|
|
625
|
+
<ScrollArea className="border-fm-divider-secondary bg-fm-surface-secondary h-96 w-full rounded-lg border">
|
|
587
626
|
<div className="p-4">
|
|
588
|
-
<h5 className="mb-4 text-sm font-medium
|
|
627
|
+
<h5 className="text-fm-primary mb-4 text-sm font-medium">
|
|
589
628
|
Activity Feed
|
|
590
629
|
</h5>
|
|
591
630
|
<div className="space-y-4">
|
|
592
631
|
{Array.from({ length: 20 }, (_, i) => (
|
|
593
|
-
<div
|
|
594
|
-
|
|
632
|
+
<div
|
|
633
|
+
key={i}
|
|
634
|
+
className="bg-fm-surface-secondary flex gap-3 rounded-lg p-3"
|
|
635
|
+
>
|
|
636
|
+
<div className="text-fm-primary flex h-8 w-8 items-center justify-center rounded-full bg-gradient-to-br from-blue-500 to-purple-600 text-xs font-medium">
|
|
595
637
|
{String.fromCharCode(65 + (i % 26))}
|
|
596
638
|
</div>
|
|
597
639
|
<div className="flex-1">
|
|
598
|
-
<div className="text-
|
|
640
|
+
<div className="text-fm-primary text-sm">
|
|
599
641
|
User {i + 1} performed an action
|
|
600
642
|
</div>
|
|
601
|
-
<div className="text-
|
|
643
|
+
<div className="text-fm-secondary text-xs">
|
|
602
644
|
{Math.floor(Math.random() * 60)} minutes ago
|
|
603
645
|
</div>
|
|
604
646
|
</div>
|
|
@@ -626,8 +668,10 @@ export const RealWorldExamples: Story = {
|
|
|
626
668
|
render: () => (
|
|
627
669
|
<div className="space-y-8">
|
|
628
670
|
<div className="text-center">
|
|
629
|
-
<h3 className="mb-2 font-medium
|
|
630
|
-
|
|
671
|
+
<h3 className="text-fm-primary mb-2 font-medium">
|
|
672
|
+
Real World Examples
|
|
673
|
+
</h3>
|
|
674
|
+
<p className="text-fm-secondary text-sm">
|
|
631
675
|
Common use cases for scrollable areas in applications
|
|
632
676
|
</p>
|
|
633
677
|
</div>
|
|
@@ -635,8 +679,10 @@ export const RealWorldExamples: Story = {
|
|
|
635
679
|
<div className="grid grid-cols-1 gap-6 lg:grid-cols-2">
|
|
636
680
|
{/* Chat Messages */}
|
|
637
681
|
<div className="space-y-2">
|
|
638
|
-
<h4 className="text-sm font-medium
|
|
639
|
-
|
|
682
|
+
<h4 className="text-fm-secondary text-sm font-medium">
|
|
683
|
+
Chat Messages
|
|
684
|
+
</h4>
|
|
685
|
+
<ScrollArea className="border-fm-divider-secondary bg-fm-surface-secondary h-80 w-full rounded-lg border">
|
|
640
686
|
<div className="space-y-4 p-4">
|
|
641
687
|
{[
|
|
642
688
|
{
|
|
@@ -724,19 +770,19 @@ export const RealWorldExamples: Story = {
|
|
|
724
770
|
<div
|
|
725
771
|
className={`max-w-xs rounded-lg p-3 ${
|
|
726
772
|
msg.self
|
|
727
|
-
? "bg-
|
|
728
|
-
: "bg-
|
|
773
|
+
? "bg-fm-surface-info text-fm-surface-primary"
|
|
774
|
+
: "bg-fm-surface-secondary text-fm-primary"
|
|
729
775
|
}`}
|
|
730
776
|
>
|
|
731
777
|
{!msg.self && (
|
|
732
|
-
<div className="mb-1 text-xs font-medium
|
|
778
|
+
<div className="text-fm-secondary mb-1 text-xs font-medium">
|
|
733
779
|
{msg.user}
|
|
734
780
|
</div>
|
|
735
781
|
)}
|
|
736
782
|
<div className="text-sm">{msg.message}</div>
|
|
737
783
|
<div
|
|
738
784
|
className={`mt-1 text-xs ${
|
|
739
|
-
msg.self ? "text-
|
|
785
|
+
msg.self ? "text-fm-info-sec" : "text-fm-secondary"
|
|
740
786
|
}`}
|
|
741
787
|
>
|
|
742
788
|
{msg.time}
|
|
@@ -750,8 +796,10 @@ export const RealWorldExamples: Story = {
|
|
|
750
796
|
|
|
751
797
|
{/* File Explorer */}
|
|
752
798
|
<div className="space-y-2">
|
|
753
|
-
<h4 className="text-sm font-medium
|
|
754
|
-
|
|
799
|
+
<h4 className="text-fm-secondary text-sm font-medium">
|
|
800
|
+
File Explorer
|
|
801
|
+
</h4>
|
|
802
|
+
<ScrollArea className="border-fm-divider-secondary bg-fm-surface-secondary h-80 w-full rounded-lg border">
|
|
755
803
|
<div className="text-fm-primary p-2">
|
|
756
804
|
{[
|
|
757
805
|
{
|
|
@@ -847,12 +895,12 @@ export const RealWorldExamples: Story = {
|
|
|
847
895
|
].map((item, i) => (
|
|
848
896
|
<div
|
|
849
897
|
key={i}
|
|
850
|
-
className="flex cursor-pointer items-center justify-between rounded p-2
|
|
898
|
+
className="hover:bg-fm-surface-secondary flex cursor-pointer items-center justify-between rounded p-2"
|
|
851
899
|
>
|
|
852
900
|
<div className="flex min-w-0 flex-1 items-center gap-2">
|
|
853
901
|
<span className="text-sm">{item.name}</span>
|
|
854
902
|
</div>
|
|
855
|
-
<div className="flex items-center gap-4 text-xs
|
|
903
|
+
<div className="text-fm-secondary flex items-center gap-4 text-xs">
|
|
856
904
|
<span className="w-12 text-right">{item.size}</span>
|
|
857
905
|
<span className="w-20 text-right">{item.modified}</span>
|
|
858
906
|
</div>
|
|
@@ -864,13 +912,13 @@ export const RealWorldExamples: Story = {
|
|
|
864
912
|
|
|
865
913
|
{/* Code Editor Sidebar */}
|
|
866
914
|
<div className="space-y-2">
|
|
867
|
-
<h4 className="text-sm font-medium
|
|
915
|
+
<h4 className="text-fm-secondary text-sm font-medium">
|
|
868
916
|
Code Editor Sidebar
|
|
869
917
|
</h4>
|
|
870
|
-
<ScrollArea className="h-80 w-full rounded-lg border
|
|
918
|
+
<ScrollArea className="border-fm-divider-secondary bg-fm-surface-secondary h-80 w-full rounded-lg border">
|
|
871
919
|
<div className="p-2">
|
|
872
920
|
<div className="space-y-1">
|
|
873
|
-
<div className="p-2 text-xs font-medium tracking-wide
|
|
921
|
+
<div className="text-fm-primary p-2 text-xs font-medium tracking-wide uppercase">
|
|
874
922
|
Explorer
|
|
875
923
|
</div>
|
|
876
924
|
{[
|
|
@@ -900,18 +948,18 @@ export const RealWorldExamples: Story = {
|
|
|
900
948
|
].map((item, i) => (
|
|
901
949
|
<div
|
|
902
950
|
key={i}
|
|
903
|
-
className="flex cursor-pointer items-center gap-1 rounded p-1 text-sm
|
|
951
|
+
className="hover:bg-fm-surface-secondary flex cursor-pointer items-center gap-1 rounded p-1 text-sm"
|
|
904
952
|
style={{ paddingLeft: `${8 + item.level * 16}px` }}
|
|
905
953
|
>
|
|
906
954
|
{item.type === "folder" && (
|
|
907
|
-
<span className="text-
|
|
955
|
+
<span className="text-fm-secondary">
|
|
908
956
|
{item.expanded ? "📂" : "📁"}
|
|
909
957
|
</span>
|
|
910
958
|
)}
|
|
911
959
|
{item.type === "file" && (
|
|
912
|
-
<span className="text-
|
|
960
|
+
<span className="text-fm-secondary">📄</span>
|
|
913
961
|
)}
|
|
914
|
-
<span className="text-
|
|
962
|
+
<span className="text-fm-primary">{item.name}</span>
|
|
915
963
|
</div>
|
|
916
964
|
))}
|
|
917
965
|
</div>
|
|
@@ -921,8 +969,10 @@ export const RealWorldExamples: Story = {
|
|
|
921
969
|
|
|
922
970
|
{/* Settings Panel */}
|
|
923
971
|
<div className="space-y-2">
|
|
924
|
-
<h4 className="text-sm font-medium
|
|
925
|
-
|
|
972
|
+
<h4 className="text-fm-secondary text-sm font-medium">
|
|
973
|
+
Settings Panel
|
|
974
|
+
</h4>
|
|
975
|
+
<ScrollArea className="border-fm-divider-secondary bg-fm-surface-secondary h-80 w-full rounded-lg border">
|
|
926
976
|
<div className="space-y-6 p-4">
|
|
927
977
|
{[
|
|
928
978
|
{
|
|
@@ -971,7 +1021,7 @@ export const RealWorldExamples: Story = {
|
|
|
971
1021
|
},
|
|
972
1022
|
].map((group, i) => (
|
|
973
1023
|
<div key={i}>
|
|
974
|
-
<h5 className="mb-3 text-sm font-medium
|
|
1024
|
+
<h5 className="text-fm-primary mb-3 text-sm font-medium">
|
|
975
1025
|
{group.section}
|
|
976
1026
|
</h5>
|
|
977
1027
|
<div className="space-y-3">
|
|
@@ -980,17 +1030,19 @@ export const RealWorldExamples: Story = {
|
|
|
980
1030
|
key={j}
|
|
981
1031
|
className="flex items-center justify-between"
|
|
982
1032
|
>
|
|
983
|
-
<span className="text-
|
|
1033
|
+
<span className="text-fm-secondary text-sm">
|
|
984
1034
|
{setting.label}
|
|
985
1035
|
</span>
|
|
986
1036
|
{setting.type === "toggle" ? (
|
|
987
1037
|
<div
|
|
988
1038
|
className={`h-5 w-10 rounded-full p-1 ${
|
|
989
|
-
setting.value
|
|
1039
|
+
setting.value
|
|
1040
|
+
? "bg-fm-surface-info"
|
|
1041
|
+
: "bg-fm-surface-tertiary"
|
|
990
1042
|
}`}
|
|
991
1043
|
>
|
|
992
1044
|
<div
|
|
993
|
-
className={`h-3 w-3 rounded-full
|
|
1045
|
+
className={`bg-fm-surface-primary h-3 w-3 rounded-full transition-transform ${
|
|
994
1046
|
setting.value
|
|
995
1047
|
? "translate-x-5"
|
|
996
1048
|
: "translate-x-0"
|
|
@@ -998,7 +1050,7 @@ export const RealWorldExamples: Story = {
|
|
|
998
1050
|
></div>
|
|
999
1051
|
</div>
|
|
1000
1052
|
) : (
|
|
1001
|
-
<span className="text-
|
|
1053
|
+
<span className="text-fm-secondary text-sm">
|
|
1002
1054
|
{setting.value}
|
|
1003
1055
|
</span>
|
|
1004
1056
|
)}
|
|
@@ -1028,19 +1080,21 @@ export const PerformanceExample: Story = {
|
|
|
1028
1080
|
render: () => (
|
|
1029
1081
|
<div className="space-y-8">
|
|
1030
1082
|
<div className="text-center">
|
|
1031
|
-
<h3 className="mb-2 font-medium
|
|
1032
|
-
|
|
1083
|
+
<h3 className="text-fm-primary mb-2 font-medium">
|
|
1084
|
+
Performance Example
|
|
1085
|
+
</h3>
|
|
1086
|
+
<p className="text-fm-secondary text-sm">
|
|
1033
1087
|
Large datasets handled efficiently with virtual scrolling simulation
|
|
1034
1088
|
</p>
|
|
1035
1089
|
</div>
|
|
1036
1090
|
|
|
1037
1091
|
<div className="space-y-4">
|
|
1038
1092
|
<div className="text-center">
|
|
1039
|
-
<div className="inline-block rounded-lg border
|
|
1040
|
-
<h4 className="mb-2 text-sm font-medium
|
|
1093
|
+
<div className="border-fm-divider-secondary bg-fm-surface-secondary inline-block rounded-lg border p-4">
|
|
1094
|
+
<h4 className="text-fm-primary mb-2 text-sm font-medium">
|
|
1041
1095
|
Large Dataset
|
|
1042
1096
|
</h4>
|
|
1043
|
-
<p className="text-xs leading-relaxed
|
|
1097
|
+
<p className="text-fm-secondary text-xs leading-relaxed">
|
|
1044
1098
|
This example shows 1000+ items in a scrollable area. The
|
|
1045
1099
|
ScrollArea component handles smooth scrolling even with large
|
|
1046
1100
|
amounts of content.
|
|
@@ -1048,20 +1102,20 @@ export const PerformanceExample: Story = {
|
|
|
1048
1102
|
</div>
|
|
1049
1103
|
</div>
|
|
1050
1104
|
|
|
1051
|
-
<ScrollArea className="mx-auto h-96 w-full max-w-2xl rounded-lg border
|
|
1105
|
+
<ScrollArea className="border-fm-divider-secondary bg-fm-surface-secondary mx-auto h-96 w-full max-w-2xl rounded-lg border">
|
|
1052
1106
|
<div className="p-4">
|
|
1053
|
-
<h4 className="mb-4 text-sm leading-none font-medium
|
|
1107
|
+
<h4 className="text-fm-primary mb-4 text-sm leading-none font-medium">
|
|
1054
1108
|
Large Item List (1000 items)
|
|
1055
1109
|
</h4>
|
|
1056
1110
|
<div className="space-y-1">
|
|
1057
1111
|
{Array.from({ length: 1000 }, (_, i) => (
|
|
1058
1112
|
<div
|
|
1059
1113
|
key={i}
|
|
1060
|
-
className="flex items-center justify-between rounded-lg
|
|
1114
|
+
className="bg-fm-surface-secondary hover:bg-fm-surface-tertiary flex items-center justify-between rounded-lg p-3 transition-colors"
|
|
1061
1115
|
>
|
|
1062
1116
|
<div className="flex items-center gap-3">
|
|
1063
1117
|
<div
|
|
1064
|
-
className={`flex h-8 w-8 items-center justify-center rounded-full text-xs font-medium
|
|
1118
|
+
className={`text-fm-primary flex h-8 w-8 items-center justify-center rounded-full text-xs font-medium ${
|
|
1065
1119
|
[
|
|
1066
1120
|
"bg-blue-500",
|
|
1067
1121
|
"bg-green-500",
|
|
@@ -1073,16 +1127,16 @@ export const PerformanceExample: Story = {
|
|
|
1073
1127
|
{i + 1}
|
|
1074
1128
|
</div>
|
|
1075
1129
|
<div>
|
|
1076
|
-
<div className="text-sm font-medium
|
|
1130
|
+
<div className="text-fm-primary text-sm font-medium">
|
|
1077
1131
|
Item {i + 1}
|
|
1078
1132
|
</div>
|
|
1079
|
-
<div className="text-
|
|
1133
|
+
<div className="text-fm-secondary text-xs">
|
|
1080
1134
|
Category:{" "}
|
|
1081
1135
|
{["Development", "Design", "Marketing", "Sales"][i % 4]}
|
|
1082
1136
|
</div>
|
|
1083
1137
|
</div>
|
|
1084
1138
|
</div>
|
|
1085
|
-
<div className="text-
|
|
1139
|
+
<div className="text-fm-secondary text-xs">
|
|
1086
1140
|
{new Date(Date.now() - i * 60000).toLocaleTimeString()}
|
|
1087
1141
|
</div>
|
|
1088
1142
|
</div>
|