@wallarm-org/claude-design 0.0.0-stage → 4.9.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.
- package/README.md +114 -2
- package/bin/claude-design.js +347 -0
- package/dist/SETUP.md +130 -0
- package/dist/UPDATE.md +84 -0
- package/dist/assets/Icons/activity.svg +1 -0
- package/dist/assets/Icons/alt.svg +1 -0
- package/dist/assets/Icons/android-neutral.svg +1 -0
- package/dist/assets/Icons/android.svg +1 -0
- package/dist/assets/Icons/api.svg +1 -0
- package/dist/assets/Icons/apple-music-neutral.svg +1 -0
- package/dist/assets/Icons/apple-music.svg +1 -0
- package/dist/assets/Icons/apple-neutral.svg +1 -0
- package/dist/assets/Icons/apple-podcasts-neutral.svg +1 -0
- package/dist/assets/Icons/apple-podcasts.svg +1 -0
- package/dist/assets/Icons/apple.svg +1 -0
- package/dist/assets/Icons/archive.svg +1 -0
- package/dist/assets/Icons/arrow-big-up-dash.svg +1 -0
- package/dist/assets/Icons/arrow-big-up.svg +1 -0
- package/dist/assets/Icons/arrow-down-left.svg +1 -0
- package/dist/assets/Icons/arrow-down-right.svg +1 -0
- package/dist/assets/Icons/arrow-down.svg +1 -0
- package/dist/assets/Icons/arrow-left.svg +1 -0
- package/dist/assets/Icons/arrow-right-alt.svg +1 -0
- package/dist/assets/Icons/arrow-right.svg +1 -0
- package/dist/assets/Icons/arrow-up-down.svg +1 -0
- package/dist/assets/Icons/arrow-up-left.svg +1 -0
- package/dist/assets/Icons/arrow-up-right.svg +1 -0
- package/dist/assets/Icons/arrow-up.svg +1 -0
- package/dist/assets/Icons/artstation-neutral.svg +1 -0
- package/dist/assets/Icons/artstation.svg +1 -0
- package/dist/assets/Icons/asterisk.svg +1 -0
- package/dist/assets/Icons/audio-waveform.svg +1 -0
- package/dist/assets/Icons/aws-neutral.svg +1 -0
- package/dist/assets/Icons/aws.svg +1 -0
- package/dist/assets/Icons/badge-check.svg +1 -0
- package/dist/assets/Icons/baidu-neutral.svg +1 -0
- package/dist/assets/Icons/baidu.svg +1 -0
- package/dist/assets/Icons/bandage.svg +1 -0
- package/dist/assets/Icons/behance-neutral.svg +1 -0
- package/dist/assets/Icons/behance.svg +1 -0
- package/dist/assets/Icons/bell-cog.svg +1 -0
- package/dist/assets/Icons/bell.svg +1 -0
- package/dist/assets/Icons/binary.svg +1 -0
- package/dist/assets/Icons/book-open.svg +1 -0
- package/dist/assets/Icons/book.svg +1 -0
- package/dist/assets/Icons/boosty-neutral.svg +1 -0
- package/dist/assets/Icons/boosty.svg +1 -0
- package/dist/assets/Icons/bot.svg +1 -0
- package/dist/assets/Icons/brain.svg +1 -0
- package/dist/assets/Icons/braze-neutral.svg +1 -0
- package/dist/assets/Icons/braze.svg +1 -0
- package/dist/assets/Icons/brevo-neutral.svg +1 -0
- package/dist/assets/Icons/brevo.svg +1 -0
- package/dist/assets/Icons/bug-off.svg +1 -0
- package/dist/assets/Icons/bug-play.svg +1 -0
- package/dist/assets/Icons/bug.svg +1 -0
- package/dist/assets/Icons/building.svg +1 -0
- package/dist/assets/Icons/building2.svg +1 -0
- package/dist/assets/Icons/calendar-check.svg +1 -0
- package/dist/assets/Icons/calendar-check2.svg +1 -0
- package/dist/assets/Icons/calendar-clock.svg +1 -0
- package/dist/assets/Icons/calendar-cog.svg +1 -0
- package/dist/assets/Icons/calendar-days.svg +1 -0
- package/dist/assets/Icons/calendar-fold.svg +1 -0
- package/dist/assets/Icons/calendar-heart.svg +1 -0
- package/dist/assets/Icons/calendar-minus.svg +1 -0
- package/dist/assets/Icons/calendar-minus2.svg +1 -0
- package/dist/assets/Icons/calendar-off.svg +1 -0
- package/dist/assets/Icons/calendar-plus.svg +1 -0
- package/dist/assets/Icons/calendar-plus2.svg +1 -0
- package/dist/assets/Icons/calendar-range.svg +1 -0
- package/dist/assets/Icons/calendar-search.svg +1 -0
- package/dist/assets/Icons/calendar-x.svg +1 -0
- package/dist/assets/Icons/calendar-x2.svg +1 -0
- package/dist/assets/Icons/calendar.svg +1 -0
- package/dist/assets/Icons/chart-area.svg +1 -0
- package/dist/assets/Icons/chart-bar.svg +1 -0
- package/dist/assets/Icons/chart-column.svg +1 -0
- package/dist/assets/Icons/chart-no-axes-column.svg +1 -0
- package/dist/assets/Icons/check-check.svg +1 -0
- package/dist/assets/Icons/check.svg +1 -0
- package/dist/assets/Icons/checkbox-indeterminate.svg +1 -0
- package/dist/assets/Icons/chevron-down.svg +1 -0
- package/dist/assets/Icons/chevron-first.svg +1 -0
- package/dist/assets/Icons/chevron-last.svg +1 -0
- package/dist/assets/Icons/chevron-left.svg +1 -0
- package/dist/assets/Icons/chevron-right.svg +1 -0
- package/dist/assets/Icons/chevron-up-down.svg +1 -0
- package/dist/assets/Icons/chevron-up.svg +1 -0
- package/dist/assets/Icons/chevrons-down-up.svg +1 -0
- package/dist/assets/Icons/chevrons-down.svg +1 -0
- package/dist/assets/Icons/chevrons-left-right.svg +1 -0
- package/dist/assets/Icons/chevrons-left.svg +1 -0
- package/dist/assets/Icons/chevrons-right-left.svg +1 -0
- package/dist/assets/Icons/chevrons-right.svg +1 -0
- package/dist/assets/Icons/chevrons-up-down.svg +1 -0
- package/dist/assets/Icons/chevrons-up.svg +1 -0
- package/dist/assets/Icons/circle-arrow-down.svg +1 -0
- package/dist/assets/Icons/circle-arrow-left.svg +1 -0
- package/dist/assets/Icons/circle-arrow-out-down-left.svg +1 -0
- package/dist/assets/Icons/circle-arrow-out-down-right.svg +1 -0
- package/dist/assets/Icons/circle-arrow-out-up-left.svg +1 -0
- package/dist/assets/Icons/circle-arrow-out-up-right.svg +1 -0
- package/dist/assets/Icons/circle-arrow-right.svg +1 -0
- package/dist/assets/Icons/circle-arrow-up.svg +1 -0
- package/dist/assets/Icons/circle-check-big.svg +1 -0
- package/dist/assets/Icons/circle-check.svg +1 -0
- package/dist/assets/Icons/circle-chevron-down.svg +1 -0
- package/dist/assets/Icons/circle-chevron-left.svg +1 -0
- package/dist/assets/Icons/circle-chevron-right.svg +1 -0
- package/dist/assets/Icons/circle-chevron-up.svg +1 -0
- package/dist/assets/Icons/circle-dashed.svg +1 -0
- package/dist/assets/Icons/circle-dot-dashed.svg +1 -0
- package/dist/assets/Icons/circle-ellipsis.svg +1 -0
- package/dist/assets/Icons/circle-gauge.svg +1 -0
- package/dist/assets/Icons/circle-help.svg +1 -0
- package/dist/assets/Icons/circle-minus.svg +1 -0
- package/dist/assets/Icons/circle-plus.svg +1 -0
- package/dist/assets/Icons/circle-slash.svg +1 -0
- package/dist/assets/Icons/circle-slash2.svg +1 -0
- package/dist/assets/Icons/circle-stop.svg +1 -0
- package/dist/assets/Icons/circle.svg +1 -0
- package/dist/assets/Icons/clipboard-check.svg +1 -0
- package/dist/assets/Icons/clipboard-x.svg +1 -0
- package/dist/assets/Icons/clipboard.svg +1 -0
- package/dist/assets/Icons/clock-fading.svg +1 -0
- package/dist/assets/Icons/clock.svg +1 -0
- package/dist/assets/Icons/cloud-off.svg +1 -0
- package/dist/assets/Icons/cloud-sync.svg +1 -0
- package/dist/assets/Icons/cloud.svg +1 -0
- package/dist/assets/Icons/code.svg +1 -0
- package/dist/assets/Icons/collapse.svg +1 -0
- package/dist/assets/Icons/columns3-cog.svg +1 -0
- package/dist/assets/Icons/command.svg +1 -0
- package/dist/assets/Icons/compass.svg +1 -0
- package/dist/assets/Icons/copy-slash.svg +1 -0
- package/dist/assets/Icons/copy.svg +1 -0
- package/dist/assets/Icons/corner-down-left.svg +1 -0
- package/dist/assets/Icons/corner-down-right.svg +1 -0
- package/dist/assets/Icons/corner-left-down.svg +1 -0
- package/dist/assets/Icons/corner-left-up.svg +1 -0
- package/dist/assets/Icons/corner-right-down.svg +1 -0
- package/dist/assets/Icons/corner-right-up.svg +1 -0
- package/dist/assets/Icons/corner-up-left.svg +1 -0
- package/dist/assets/Icons/corner-up-right.svg +1 -0
- package/dist/assets/Icons/cpu.svg +1 -0
- package/dist/assets/Icons/credit-card.svg +1 -0
- package/dist/assets/Icons/crosshair.svg +1 -0
- package/dist/assets/Icons/ctrl.svg +1 -0
- package/dist/assets/Icons/database.svg +1 -0
- package/dist/assets/Icons/devianart-neutral.svg +1 -0
- package/dist/assets/Icons/devianart.svg +1 -0
- package/dist/assets/Icons/discord-neutral.svg +1 -0
- package/dist/assets/Icons/discord.svg +1 -0
- package/dist/assets/Icons/dollar-sign.svg +1 -0
- package/dist/assets/Icons/dot.svg +1 -0
- package/dist/assets/Icons/download.svg +1 -0
- package/dist/assets/Icons/dprofile-neutral.svg +1 -0
- package/dist/assets/Icons/dprofile.svg +1 -0
- package/dist/assets/Icons/dribbble-neutral.svg +1 -0
- package/dist/assets/Icons/dribbble.svg +1 -0
- package/dist/assets/Icons/droplet.svg +1 -0
- package/dist/assets/Icons/duplicate.svg +1 -0
- package/dist/assets/Icons/dzen-neutral.svg +1 -0
- package/dist/assets/Icons/dzen.svg +1 -0
- package/dist/assets/Icons/earth-lock.svg +1 -0
- package/dist/assets/Icons/earth.svg +1 -0
- package/dist/assets/Icons/ellipsis.svg +1 -0
- package/dist/assets/Icons/expand.svg +1 -0
- package/dist/assets/Icons/external-link.svg +1 -0
- package/dist/assets/Icons/eye-off.svg +1 -0
- package/dist/assets/Icons/eye.svg +1 -0
- package/dist/assets/Icons/facebook-neutral.svg +1 -0
- package/dist/assets/Icons/facebook.svg +1 -0
- package/dist/assets/Icons/fast-forward.svg +1 -0
- package/dist/assets/Icons/figma-neutral.svg +1 -0
- package/dist/assets/Icons/figma.svg +1 -0
- package/dist/assets/Icons/file-down.svg +1 -0
- package/dist/assets/Icons/file-plus.svg +1 -0
- package/dist/assets/Icons/file-text.svg +1 -0
- package/dist/assets/Icons/file.svg +1 -0
- package/dist/assets/Icons/film.svg +1 -0
- package/dist/assets/Icons/filter-x.svg +1 -0
- package/dist/assets/Icons/filter.svg +1 -0
- package/dist/assets/Icons/fingerprint-pattern.svg +1 -0
- package/dist/assets/Icons/flag.svg +1 -0
- package/dist/assets/Icons/flask-conical.svg +1 -0
- package/dist/assets/Icons/folder.svg +1 -0
- package/dist/assets/Icons/funnel-plus.svg +1 -0
- package/dist/assets/Icons/ghost.svg +1 -0
- package/dist/assets/Icons/git-branch.svg +1 -0
- package/dist/assets/Icons/git-commit-horizontal.svg +1 -0
- package/dist/assets/Icons/git-commit-vertical.svg +1 -0
- package/dist/assets/Icons/git-compare-arrows-alt.svg +1 -0
- package/dist/assets/Icons/git-compare-arrows.svg +1 -0
- package/dist/assets/Icons/git-compare.svg +1 -0
- package/dist/assets/Icons/git-fork.svg +1 -0
- package/dist/assets/Icons/git-graph.svg +1 -0
- package/dist/assets/Icons/git-merge.svg +1 -0
- package/dist/assets/Icons/git-pull-request-arrow.svg +1 -0
- package/dist/assets/Icons/git-pull-request-closed.svg +1 -0
- package/dist/assets/Icons/git-pull-request-create-arrow.svg +1 -0
- package/dist/assets/Icons/git-pull-request-create.svg +1 -0
- package/dist/assets/Icons/git-pull-request-draft.svg +1 -0
- package/dist/assets/Icons/git-pull-request.svg +1 -0
- package/dist/assets/Icons/github-neutral.svg +1 -0
- package/dist/assets/Icons/github.svg +1 -0
- package/dist/assets/Icons/globe-lock.svg +1 -0
- package/dist/assets/Icons/globe.svg +1 -0
- package/dist/assets/Icons/gmail-neutral.svg +1 -0
- package/dist/assets/Icons/gmail.svg +1 -0
- package/dist/assets/Icons/google-meet-neutral.svg +1 -0
- package/dist/assets/Icons/google-meet.svg +1 -0
- package/dist/assets/Icons/google-neutral.svg +1 -0
- package/dist/assets/Icons/google-play-neutral.svg +1 -0
- package/dist/assets/Icons/google-play.svg +1 -0
- package/dist/assets/Icons/google-podcast-neutral.svg +1 -0
- package/dist/assets/Icons/google-podcast.svg +1 -0
- package/dist/assets/Icons/google.svg +1 -0
- package/dist/assets/Icons/grip-horizontal.svg +1 -0
- package/dist/assets/Icons/grip-vertical.svg +1 -0
- package/dist/assets/Icons/hammer.svg +1 -0
- package/dist/assets/Icons/heart-pulse.svg +1 -0
- package/dist/assets/Icons/history.svg +1 -0
- package/dist/assets/Icons/home.svg +1 -0
- package/dist/assets/Icons/imo-neutral.svg +1 -0
- package/dist/assets/Icons/imo.svg +1 -0
- package/dist/assets/Icons/infinity.svg +1 -0
- package/dist/assets/Icons/info.svg +1 -0
- package/dist/assets/Icons/infobip-neutral.svg +1 -0
- package/dist/assets/Icons/infobip.svg +1 -0
- package/dist/assets/Icons/instagram-neutral.svg +1 -0
- package/dist/assets/Icons/instagram.svg +1 -0
- package/dist/assets/Icons/key-round.svg +1 -0
- package/dist/assets/Icons/key-square.svg +1 -0
- package/dist/assets/Icons/keyboard.svg +1 -0
- package/dist/assets/Icons/kickstarter-neutral.svg +1 -0
- package/dist/assets/Icons/kickstarter.svg +1 -0
- package/dist/assets/Icons/laptop.svg +1 -0
- package/dist/assets/Icons/layers.svg +1 -0
- package/dist/assets/Icons/layers2.svg +1 -0
- package/dist/assets/Icons/layers3.svg +1 -0
- package/dist/assets/Icons/layout-dashboard.svg +1 -0
- package/dist/assets/Icons/layout-grid.svg +1 -0
- package/dist/assets/Icons/layout-list.svg +1 -0
- package/dist/assets/Icons/layout-panel-left.svg +1 -0
- package/dist/assets/Icons/layout-panel-top.svg +1 -0
- package/dist/assets/Icons/layout-template.svg +1 -0
- package/dist/assets/Icons/library-big.svg +1 -0
- package/dist/assets/Icons/life-buoy.svg +1 -0
- package/dist/assets/Icons/lightbulb-off.svg +1 -0
- package/dist/assets/Icons/lightbulb.svg +1 -0
- package/dist/assets/Icons/line-neutral.svg +1 -0
- package/dist/assets/Icons/line.svg +1 -0
- package/dist/assets/Icons/link.svg +1 -0
- package/dist/assets/Icons/link2-off.svg +1 -0
- package/dist/assets/Icons/link2.svg +1 -0
- package/dist/assets/Icons/linkedin-neutral.svg +1 -0
- package/dist/assets/Icons/linkedin.svg +1 -0
- package/dist/assets/Icons/list-checks.svg +1 -0
- package/dist/assets/Icons/list-collapse.svg +1 -0
- package/dist/assets/Icons/list-filter.svg +1 -0
- package/dist/assets/Icons/list-minus.svg +1 -0
- package/dist/assets/Icons/list-ordered.svg +1 -0
- package/dist/assets/Icons/list-plus.svg +1 -0
- package/dist/assets/Icons/list-restart.svg +1 -0
- package/dist/assets/Icons/list-start.svg +1 -0
- package/dist/assets/Icons/list-todo.svg +1 -0
- package/dist/assets/Icons/list-tree.svg +1 -0
- package/dist/assets/Icons/list-video.svg +1 -0
- package/dist/assets/Icons/list-x.svg +1 -0
- package/dist/assets/Icons/list.svg +1 -0
- package/dist/assets/Icons/loader-circle.svg +1 -0
- package/dist/assets/Icons/loader.svg +1 -0
- package/dist/assets/Icons/lock-open.svg +1 -0
- package/dist/assets/Icons/lock.svg +1 -0
- package/dist/assets/Icons/log-in.svg +1 -0
- package/dist/assets/Icons/log-out.svg +1 -0
- package/dist/assets/Icons/mail-check.svg +1 -0
- package/dist/assets/Icons/mail-minus.svg +1 -0
- package/dist/assets/Icons/mail-open.svg +1 -0
- package/dist/assets/Icons/mail-plus.svg +1 -0
- package/dist/assets/Icons/mail-question.svg +1 -0
- package/dist/assets/Icons/mail-search.svg +1 -0
- package/dist/assets/Icons/mail-warning.svg +1 -0
- package/dist/assets/Icons/mail-x.svg +1 -0
- package/dist/assets/Icons/mail.svg +1 -0
- package/dist/assets/Icons/mailbox.svg +1 -0
- package/dist/assets/Icons/mailersend-neutral.svg +1 -0
- package/dist/assets/Icons/mailersend.svg +1 -0
- package/dist/assets/Icons/mailgun-neutral.svg +1 -0
- package/dist/assets/Icons/mailgun.svg +1 -0
- package/dist/assets/Icons/mailjet-neutral.svg +1 -0
- package/dist/assets/Icons/mailjet.svg +1 -0
- package/dist/assets/Icons/mails.svg +1 -0
- package/dist/assets/Icons/mailtrap-neutral.svg +1 -0
- package/dist/assets/Icons/mailtrap.svg +1 -0
- package/dist/assets/Icons/mandrill-neutral.svg +1 -0
- package/dist/assets/Icons/mandrill.svg +1 -0
- package/dist/assets/Icons/map-pin.svg +1 -0
- package/dist/assets/Icons/maqsam-neutral.svg +1 -0
- package/dist/assets/Icons/maqsam.svg +1 -0
- package/dist/assets/Icons/mattermost-neutral.svg +1 -0
- package/dist/assets/Icons/mattermost.svg +1 -0
- package/dist/assets/Icons/maximize.svg +1 -0
- package/dist/assets/Icons/maximize2.svg +1 -0
- package/dist/assets/Icons/medium-neutral.svg +1 -0
- package/dist/assets/Icons/medium.svg +1 -0
- package/dist/assets/Icons/megaphone-off.svg +1 -0
- package/dist/assets/Icons/megaphone.svg +1 -0
- package/dist/assets/Icons/menu.svg +1 -0
- package/dist/assets/Icons/merge.svg +1 -0
- package/dist/assets/Icons/message-square-code.svg +1 -0
- package/dist/assets/Icons/message-square-dashed.svg +1 -0
- package/dist/assets/Icons/message-square-diff.svg +1 -0
- package/dist/assets/Icons/message-square-dot.svg +1 -0
- package/dist/assets/Icons/message-square-heart.svg +1 -0
- package/dist/assets/Icons/message-square-off.svg +1 -0
- package/dist/assets/Icons/message-square-plus.svg +1 -0
- package/dist/assets/Icons/message-square-quote.svg +1 -0
- package/dist/assets/Icons/message-square-reply.svg +1 -0
- package/dist/assets/Icons/message-square-share.svg +1 -0
- package/dist/assets/Icons/message-square-text.svg +1 -0
- package/dist/assets/Icons/message-square-warning.svg +1 -0
- package/dist/assets/Icons/message-square-x.svg +1 -0
- package/dist/assets/Icons/message-square.svg +1 -0
- package/dist/assets/Icons/messages-square.svg +1 -0
- package/dist/assets/Icons/messenger-neutral.svg +1 -0
- package/dist/assets/Icons/messenger.svg +1 -0
- package/dist/assets/Icons/microsoft-neutral.svg +1 -0
- package/dist/assets/Icons/microsoft-teams-neutral.svg +1 -0
- package/dist/assets/Icons/microsoft-teams.svg +1 -0
- package/dist/assets/Icons/microsoft.svg +1 -0
- package/dist/assets/Icons/minimize.svg +1 -0
- package/dist/assets/Icons/minimize2.svg +1 -0
- package/dist/assets/Icons/minus.svg +1 -0
- package/dist/assets/Icons/moon.svg +1 -0
- package/dist/assets/Icons/mouse-pointer-ban.svg +1 -0
- package/dist/assets/Icons/mouse-pointer-click.svg +1 -0
- package/dist/assets/Icons/mouse-pointer.svg +1 -0
- package/dist/assets/Icons/mouse-pointer2.svg +1 -0
- package/dist/assets/Icons/mouse.svg +1 -0
- package/dist/assets/Icons/move-diagonal.svg +1 -0
- package/dist/assets/Icons/move-diagonal2.svg +1 -0
- package/dist/assets/Icons/move-down-left.svg +1 -0
- package/dist/assets/Icons/move-down-right.svg +1 -0
- package/dist/assets/Icons/move-down.svg +1 -0
- package/dist/assets/Icons/move-horizontal.svg +1 -0
- package/dist/assets/Icons/move-left.svg +1 -0
- package/dist/assets/Icons/move-right.svg +1 -0
- package/dist/assets/Icons/move-up-left.svg +1 -0
- package/dist/assets/Icons/move-up-right.svg +1 -0
- package/dist/assets/Icons/move-up.svg +1 -0
- package/dist/assets/Icons/move-vertical.svg +1 -0
- package/dist/assets/Icons/move3-d.svg +1 -0
- package/dist/assets/Icons/netcore-neutral.svg +1 -0
- package/dist/assets/Icons/netcore.svg +1 -0
- package/dist/assets/Icons/notebook-pen.svg +1 -0
- package/dist/assets/Icons/notebook-tabs.svg +1 -0
- package/dist/assets/Icons/notebook-text.svg +1 -0
- package/dist/assets/Icons/notebook.svg +1 -0
- package/dist/assets/Icons/notepad-text-dashed.svg +1 -0
- package/dist/assets/Icons/notepad-text.svg +1 -0
- package/dist/assets/Icons/notion-neutral.svg +1 -0
- package/dist/assets/Icons/notion.svg +1 -0
- package/dist/assets/Icons/octagon-alert.svg +1 -0
- package/dist/assets/Icons/octagon-pause.svg +1 -0
- package/dist/assets/Icons/octagon-x.svg +1 -0
- package/dist/assets/Icons/octagon.svg +1 -0
- package/dist/assets/Icons/ok-neutral.svg +1 -0
- package/dist/assets/Icons/ok-only-sign-neutral.svg +1 -0
- package/dist/assets/Icons/ok-only-sign.svg +1 -0
- package/dist/assets/Icons/ok.svg +1 -0
- package/dist/assets/Icons/onlyfans-neutral.svg +1 -0
- package/dist/assets/Icons/onlyfans.svg +1 -0
- package/dist/assets/Icons/option.svg +1 -0
- package/dist/assets/Icons/outlook365-neutral.svg +1 -0
- package/dist/assets/Icons/outlook365.svg +1 -0
- package/dist/assets/Icons/paintbrush.svg +1 -0
- package/dist/assets/Icons/panel-bottom-open.svg +1 -0
- package/dist/assets/Icons/panel-bottom.svg +1 -0
- package/dist/assets/Icons/panel-left-close.svg +1 -0
- package/dist/assets/Icons/panel-left-dashed.svg +1 -0
- package/dist/assets/Icons/panel-left-open.svg +1 -0
- package/dist/assets/Icons/panel-left.svg +1 -0
- package/dist/assets/Icons/panel-right-animated.svg +1 -0
- package/dist/assets/Icons/panel-right-close.svg +1 -0
- package/dist/assets/Icons/panel-right-dashed.svg +1 -0
- package/dist/assets/Icons/panel-right-open.svg +1 -0
- package/dist/assets/Icons/panel-right.svg +1 -0
- package/dist/assets/Icons/panel-top-bottom-dashed.svg +1 -0
- package/dist/assets/Icons/panel-top-close.svg +1 -0
- package/dist/assets/Icons/panel-top-open.svg +1 -0
- package/dist/assets/Icons/panel-top.svg +1 -0
- package/dist/assets/Icons/panels-left-bottom.svg +1 -0
- package/dist/assets/Icons/panels-right-bottom.svg +1 -0
- package/dist/assets/Icons/panels-top-left.svg +1 -0
- package/dist/assets/Icons/paperclip.svg +1 -0
- package/dist/assets/Icons/patreon-neutral.svg +1 -0
- package/dist/assets/Icons/patreon.svg +1 -0
- package/dist/assets/Icons/paypal-neutral.svg +1 -0
- package/dist/assets/Icons/paypal.svg +1 -0
- package/dist/assets/Icons/pen-line.svg +1 -0
- package/dist/assets/Icons/pen-off.svg +1 -0
- package/dist/assets/Icons/pen-tool.svg +1 -0
- package/dist/assets/Icons/pen.svg +1 -0
- package/dist/assets/Icons/pencil-line.svg +1 -0
- package/dist/assets/Icons/pencil-off.svg +1 -0
- package/dist/assets/Icons/pencil-ruler.svg +1 -0
- package/dist/assets/Icons/pencil.svg +1 -0
- package/dist/assets/Icons/pentagon.svg +1 -0
- package/dist/assets/Icons/percentage.svg +1 -0
- package/dist/assets/Icons/phone.svg +1 -0
- package/dist/assets/Icons/pin-off.svg +1 -0
- package/dist/assets/Icons/pin.svg +1 -0
- package/dist/assets/Icons/pinterest-neutral.svg +1 -0
- package/dist/assets/Icons/pinterest.svg +1 -0
- package/dist/assets/Icons/play.svg +1 -0
- package/dist/assets/Icons/plug.svg +1 -0
- package/dist/assets/Icons/plunk-neutral.svg +1 -0
- package/dist/assets/Icons/plunk.svg +1 -0
- package/dist/assets/Icons/plus.svg +1 -0
- package/dist/assets/Icons/postmark-neutral.svg +1 -0
- package/dist/assets/Icons/postmark.svg +1 -0
- package/dist/assets/Icons/product-hunt-neutral.svg +1 -0
- package/dist/assets/Icons/product-hunt.svg +1 -0
- package/dist/assets/Icons/quora-neutral.svg +1 -0
- package/dist/assets/Icons/quora.svg +1 -0
- package/dist/assets/Icons/quote.svg +1 -0
- package/dist/assets/Icons/radar.svg +1 -0
- package/dist/assets/Icons/reddit-neutral.svg +1 -0
- package/dist/assets/Icons/reddit.svg +1 -0
- package/dist/assets/Icons/redo-dot.svg +1 -0
- package/dist/assets/Icons/redo.svg +1 -0
- package/dist/assets/Icons/redo2.svg +1 -0
- package/dist/assets/Icons/refresh-ccw.svg +1 -0
- package/dist/assets/Icons/refresh-cw-off.svg +1 -0
- package/dist/assets/Icons/resend-neutral.svg +1 -0
- package/dist/assets/Icons/resend.svg +1 -0
- package/dist/assets/Icons/rss.svg +1 -0
- package/dist/assets/Icons/rules.svg +1 -0
- package/dist/assets/Icons/scan-line.svg +1 -0
- package/dist/assets/Icons/scroll-text.svg +1 -0
- package/dist/assets/Icons/search-hint.svg +1 -0
- package/dist/assets/Icons/search-x.svg +1 -0
- package/dist/assets/Icons/search.svg +1 -0
- package/dist/assets/Icons/sendgrid-neutral.svg +1 -0
- package/dist/assets/Icons/sendgrid.svg +1 -0
- package/dist/assets/Icons/server.svg +1 -0
- package/dist/assets/Icons/ses-neutral.svg +1 -0
- package/dist/assets/Icons/ses.svg +1 -0
- package/dist/assets/Icons/settings.svg +1 -0
- package/dist/assets/Icons/settings2.svg +1 -0
- package/dist/assets/Icons/shapes.svg +1 -0
- package/dist/assets/Icons/share.svg +1 -0
- package/dist/assets/Icons/sheet.svg +1 -0
- package/dist/assets/Icons/shield-alert.svg +1 -0
- package/dist/assets/Icons/shield-ban.svg +1 -0
- package/dist/assets/Icons/shield-check.svg +1 -0
- package/dist/assets/Icons/shield-ellipsis.svg +1 -0
- package/dist/assets/Icons/shield-half.svg +1 -0
- package/dist/assets/Icons/shield-minus.svg +1 -0
- package/dist/assets/Icons/shield-off.svg +1 -0
- package/dist/assets/Icons/shield-plus.svg +1 -0
- package/dist/assets/Icons/shield-question.svg +1 -0
- package/dist/assets/Icons/shield-user.svg +1 -0
- package/dist/assets/Icons/shield-x.svg +1 -0
- package/dist/assets/Icons/shield.svg +1 -0
- package/dist/assets/Icons/shift.svg +1 -0
- package/dist/assets/Icons/signal-neutral.svg +1 -0
- package/dist/assets/Icons/signal.svg +1 -0
- package/dist/assets/Icons/signpost.svg +1 -0
- package/dist/assets/Icons/sina-weibo-neutral.svg +1 -0
- package/dist/assets/Icons/sina-weibo.svg +1 -0
- package/dist/assets/Icons/skull.svg +1 -0
- package/dist/assets/Icons/skype-neutral.svg +1 -0
- package/dist/assets/Icons/skype.svg +1 -0
- package/dist/assets/Icons/slack-neutral.svg +1 -0
- package/dist/assets/Icons/slack.svg +1 -0
- package/dist/assets/Icons/sliders-horizontal.svg +1 -0
- package/dist/assets/Icons/sliders-vertical.svg +1 -0
- package/dist/assets/Icons/smtp-neutral.svg +1 -0
- package/dist/assets/Icons/smtp.svg +1 -0
- package/dist/assets/Icons/snapchat-neutral.svg +1 -0
- package/dist/assets/Icons/snapchat.svg +1 -0
- package/dist/assets/Icons/soundcloud-neutral.svg +1 -0
- package/dist/assets/Icons/soundcloud.svg +1 -0
- package/dist/assets/Icons/space.svg +1 -0
- package/dist/assets/Icons/sparkpost-neutral.svg +1 -0
- package/dist/assets/Icons/sparkpost.svg +1 -0
- package/dist/assets/Icons/speed.svg +1 -0
- package/dist/assets/Icons/split.svg +1 -0
- package/dist/assets/Icons/spotify-neutral.svg +1 -0
- package/dist/assets/Icons/spotify.svg +1 -0
- package/dist/assets/Icons/square-arrow-out-up-right.svg +1 -0
- package/dist/assets/Icons/square-minus.svg +1 -0
- package/dist/assets/Icons/square-pen.svg +1 -0
- package/dist/assets/Icons/square-plus.svg +1 -0
- package/dist/assets/Icons/square-user-round.svg +1 -0
- package/dist/assets/Icons/stack-overflow-neutral.svg +1 -0
- package/dist/assets/Icons/stack-overflow.svg +1 -0
- package/dist/assets/Icons/star.svg +1 -0
- package/dist/assets/Icons/sun.svg +1 -0
- package/dist/assets/Icons/syringe.svg +1 -0
- package/dist/assets/Icons/tag.svg +1 -0
- package/dist/assets/Icons/target.svg +1 -0
- package/dist/assets/Icons/teams-neutral.svg +1 -0
- package/dist/assets/Icons/teams.svg +1 -0
- package/dist/assets/Icons/telegram-neutral.svg +1 -0
- package/dist/assets/Icons/telegram-only-sign-neutral.svg +1 -0
- package/dist/assets/Icons/telegram-only-sign.svg +1 -0
- package/dist/assets/Icons/telegram.svg +1 -0
- package/dist/assets/Icons/terminal.svg +1 -0
- package/dist/assets/Icons/test-policies.svg +1 -0
- package/dist/assets/Icons/threads-neutral.svg +1 -0
- package/dist/assets/Icons/threads.svg +1 -0
- package/dist/assets/Icons/thumbs-down.svg +1 -0
- package/dist/assets/Icons/thumbs-up.svg +1 -0
- package/dist/assets/Icons/tiktok-neutral.svg +1 -0
- package/dist/assets/Icons/tiktok.svg +1 -0
- package/dist/assets/Icons/tinder-neutral.svg +1 -0
- package/dist/assets/Icons/tinder.svg +1 -0
- package/dist/assets/Icons/trash.svg +1 -0
- package/dist/assets/Icons/trash2.svg +1 -0
- package/dist/assets/Icons/triangle-alert.svg +1 -0
- package/dist/assets/Icons/tumblr-neutral.svg +1 -0
- package/dist/assets/Icons/tumblr.svg +1 -0
- package/dist/assets/Icons/twitch-neutral.svg +1 -0
- package/dist/assets/Icons/twitch.svg +1 -0
- package/dist/assets/Icons/undo-dot.svg +1 -0
- package/dist/assets/Icons/undo.svg +1 -0
- package/dist/assets/Icons/undo2.svg +1 -0
- package/dist/assets/Icons/unplug.svg +1 -0
- package/dist/assets/Icons/user-check.svg +1 -0
- package/dist/assets/Icons/user-minus.svg +1 -0
- package/dist/assets/Icons/user-plus.svg +1 -0
- package/dist/assets/Icons/user-round-x.svg +1 -0
- package/dist/assets/Icons/user-round.svg +1 -0
- package/dist/assets/Icons/user.svg +1 -0
- package/dist/assets/Icons/username.svg +1 -0
- package/dist/assets/Icons/users-round.svg +1 -0
- package/dist/assets/Icons/users.svg +1 -0
- package/dist/assets/Icons/viber-neutral.svg +1 -0
- package/dist/assets/Icons/viber.svg +1 -0
- package/dist/assets/Icons/video.svg +1 -0
- package/dist/assets/Icons/vimeo-neutral.svg +1 -0
- package/dist/assets/Icons/vimeo.svg +1 -0
- package/dist/assets/Icons/vk-music-neutral.svg +1 -0
- package/dist/assets/Icons/vk-music.svg +1 -0
- package/dist/assets/Icons/vk-neutral.svg +1 -0
- package/dist/assets/Icons/vk-only-sign-neutral.svg +1 -0
- package/dist/assets/Icons/vk-only-sign.svg +1 -0
- package/dist/assets/Icons/vk.svg +1 -0
- package/dist/assets/Icons/webhook-neutral.svg +1 -0
- package/dist/assets/Icons/webhook.svg +1 -0
- package/dist/assets/Icons/wechat-neutral.svg +1 -0
- package/dist/assets/Icons/wechat.svg +1 -0
- package/dist/assets/Icons/whatsapp-badge-neutral.svg +1 -0
- package/dist/assets/Icons/whatsapp-badge.svg +1 -0
- package/dist/assets/Icons/whatsapp-neutral.svg +1 -0
- package/dist/assets/Icons/whatsapp.svg +1 -0
- package/dist/assets/Icons/workflow.svg +1 -0
- package/dist/assets/Icons/wrap-text.svg +1 -0
- package/dist/assets/Icons/wrench.svg +1 -0
- package/dist/assets/Icons/x-ex-twitter-neutral.svg +1 -0
- package/dist/assets/Icons/x-ex-twitter.svg +1 -0
- package/dist/assets/Icons/x.svg +1 -0
- package/dist/assets/Icons/xing-neutral.svg +1 -0
- package/dist/assets/Icons/xing.svg +1 -0
- package/dist/assets/Icons/yandex-music-neutral.svg +1 -0
- package/dist/assets/Icons/yandex-music.svg +1 -0
- package/dist/assets/Icons/yelp-neutral.svg +1 -0
- package/dist/assets/Icons/yelp.svg +1 -0
- package/dist/assets/Icons/youtube-music-neutral.svg +1 -0
- package/dist/assets/Icons/youtube-music.svg +1 -0
- package/dist/assets/Icons/youtube-neutral.svg +1 -0
- package/dist/assets/Icons/youtube-shorts-neutral.svg +1 -0
- package/dist/assets/Icons/youtube-shorts.svg +1 -0
- package/dist/assets/Icons/youtube.svg +1 -0
- package/dist/assets/Icons/zap.svg +1 -0
- package/dist/assets/Icons/zoom-in.svg +1 -0
- package/dist/assets/Icons/zoom-neutral.svg +1 -0
- package/dist/assets/Icons/zoom-out.svg +1 -0
- package/dist/assets/Icons/zoom.svg +1 -0
- package/dist/assets/Icons/zulip-neutral.svg +1 -0
- package/dist/assets/Icons/zulip.svg +1 -0
- package/dist/assets/Logos/wallarm.svg +1 -0
- package/dist/assets.json +4666 -0
- package/dist/project/README.md +265 -0
- package/dist/project/components/Accordion/README.md +354 -0
- package/dist/project/components/Accordion/preview.html +2 -0
- package/dist/project/components/Accordion/stories.js +12 -0
- package/dist/project/components/AgentAvatar/README.md +127 -0
- package/dist/project/components/AgentAvatar/preview.html +2 -0
- package/dist/project/components/AgentAvatar/stories.js +12 -0
- package/dist/project/components/AgentAvatar/stories.md +1805 -0
- package/dist/project/components/AgentGlyph/README.md +1182 -0
- package/dist/project/components/AgentGlyph/preview.html +2 -0
- package/dist/project/components/AgentGlyph/stories.js +12 -0
- package/dist/project/components/AgentLookBuilder/README.md +269 -0
- package/dist/project/components/AgentLookBuilder/preview.html +2 -0
- package/dist/project/components/AgentLookBuilder/stories.js +12 -0
- package/dist/project/components/Alert/README.md +492 -0
- package/dist/project/components/Alert/preview.html +2 -0
- package/dist/project/components/Alert/stories.js +12 -0
- package/dist/project/components/AnimatedBackground/README.md +124 -0
- package/dist/project/components/AnimatedBackground/preview.html +2 -0
- package/dist/project/components/AnimatedBackground/stories.js +12 -0
- package/dist/project/components/AppShell/README.md +75 -0
- package/dist/project/components/AppShell/preview.html +2 -0
- package/dist/project/components/AppShell/stories.js +28 -0
- package/dist/project/components/AppShell/stories.md +2878 -0
- package/dist/project/components/ApprovalCard/README.md +353 -0
- package/dist/project/components/ApprovalCard/preview.html +2 -0
- package/dist/project/components/ApprovalCard/stories.js +12 -0
- package/dist/project/components/AreaChart/README.md +673 -0
- package/dist/project/components/AreaChart/preview.html +2 -0
- package/dist/project/components/AreaChart/stories.js +12 -0
- package/dist/project/components/AssistantMessage/README.md +724 -0
- package/dist/project/components/AssistantMessage/preview.html +2 -0
- package/dist/project/components/AssistantMessage/stories.js +55 -0
- package/dist/project/components/Attribute/README.md +1174 -0
- package/dist/project/components/Attribute/preview.html +2 -0
- package/dist/project/components/Attribute/stories.js +12 -0
- package/dist/project/components/Avatar/README.md +416 -0
- package/dist/project/components/Avatar/preview.html +2 -0
- package/dist/project/components/Avatar/stories.js +12 -0
- package/dist/project/components/Badge/README.md +853 -0
- package/dist/project/components/Badge/preview.html +2 -0
- package/dist/project/components/Badge/stories.js +12 -0
- package/dist/project/components/Banner/README.md +341 -0
- package/dist/project/components/Banner/preview.html +2 -0
- package/dist/project/components/Banner/stories.js +12 -0
- package/dist/project/components/BarList/README.md +757 -0
- package/dist/project/components/BarList/preview.html +2 -0
- package/dist/project/components/BarList/stories.js +12 -0
- package/dist/project/components/Breadcrumbs/README.md +274 -0
- package/dist/project/components/Breadcrumbs/preview.html +2 -0
- package/dist/project/components/Breadcrumbs/stories.js +12 -0
- package/dist/project/components/BulkBar/README.md +19 -0
- package/dist/project/components/Button/README.md +467 -0
- package/dist/project/components/Button/preview.html +2 -0
- package/dist/project/components/Button/stories.js +12 -0
- package/dist/project/components/Calendar/README.md +654 -0
- package/dist/project/components/Calendar/preview.html +2 -0
- package/dist/project/components/Calendar/stories.js +12 -0
- package/dist/project/components/Card/README.md +367 -0
- package/dist/project/components/Card/preview.html +2 -0
- package/dist/project/components/Card/stories.js +12 -0
- package/dist/project/components/ChainOfThought/README.md +412 -0
- package/dist/project/components/ChainOfThought/preview.html +2 -0
- package/dist/project/components/ChainOfThought/stories.js +12 -0
- package/dist/project/components/Chart/README.md +224 -0
- package/dist/project/components/Chart/preview.html +2 -0
- package/dist/project/components/Chart/stories.js +12 -0
- package/dist/project/components/Chat/README.md +1244 -0
- package/dist/project/components/Chat/preview.html +2 -0
- package/dist/project/components/Chat/stories.js +12 -0
- package/dist/project/components/ChatInput/README.md +378 -0
- package/dist/project/components/ChatInput/preview.html +2 -0
- package/dist/project/components/ChatInput/stories.js +12 -0
- package/dist/project/components/ChatPermissions/README.md +218 -0
- package/dist/project/components/ChatPermissions/preview.html +2 -0
- package/dist/project/components/ChatPermissions/stories.js +12 -0
- package/dist/project/components/Checkbox/README.md +367 -0
- package/dist/project/components/Checkbox/preview.html +2 -0
- package/dist/project/components/Checkbox/stories.js +12 -0
- package/dist/project/components/Code/README.md +243 -0
- package/dist/project/components/Code/preview.html +2 -0
- package/dist/project/components/Code/stories.js +12 -0
- package/dist/project/components/CodeEditor/README.md +280 -0
- package/dist/project/components/CodeEditor/preview.html +2 -0
- package/dist/project/components/CodeEditor/stories.js +162 -0
- package/dist/project/components/CodeEditor/stories.md +1533 -0
- package/dist/project/components/CodeSnippet/README.md +1352 -0
- package/dist/project/components/CodeSnippet/preview.html +2 -0
- package/dist/project/components/CodeSnippet/stories.js +156 -0
- package/dist/project/components/ColumnChart/README.md +521 -0
- package/dist/project/components/ColumnChart/preview.html +2 -0
- package/dist/project/components/ColumnChart/stories.js +12 -0
- package/dist/project/components/Conversation/README.md +314 -0
- package/dist/project/components/Conversation/preview.html +2 -0
- package/dist/project/components/Conversation/stories.js +12 -0
- package/dist/project/components/Copyable/README.md +406 -0
- package/dist/project/components/Copyable/preview.html +2 -0
- package/dist/project/components/Copyable/stories.js +12 -0
- package/dist/project/components/Country/README.md +226 -0
- package/dist/project/components/Country/preview.html +2 -0
- package/dist/project/components/Country/stories.js +12 -0
- package/dist/project/components/Cover/preview.html +43 -0
- package/dist/project/components/DateInput/README.md +458 -0
- package/dist/project/components/DateInput/preview.html +2 -0
- package/dist/project/components/DateInput/stories.js +12 -0
- package/dist/project/components/DateRangeInput/README.md +412 -0
- package/dist/project/components/DateRangeInput/preview.html +2 -0
- package/dist/project/components/DateRangeInput/stories.js +12 -0
- package/dist/project/components/Dialog/README.md +1140 -0
- package/dist/project/components/Dialog/preview.html +2 -0
- package/dist/project/components/Dialog/stories.js +12 -0
- package/dist/project/components/Drawer/README.md +1163 -0
- package/dist/project/components/Drawer/preview.html +2 -0
- package/dist/project/components/Drawer/stories.js +12 -0
- package/dist/project/components/DropdownMenu/README.md +678 -0
- package/dist/project/components/DropdownMenu/preview.html +2 -0
- package/dist/project/components/DropdownMenu/stories.js +12 -0
- package/dist/project/components/EmptyState/README.md +276 -0
- package/dist/project/components/EmptyState/preview.html +2 -0
- package/dist/project/components/EmptyState/stories.js +12 -0
- package/dist/project/components/FeedbackPulse/README.md +125 -0
- package/dist/project/components/FeedbackPulse/preview.html +2 -0
- package/dist/project/components/FeedbackPulse/stories.js +12 -0
- package/dist/project/components/Field/README.md +676 -0
- package/dist/project/components/Field/preview.html +2 -0
- package/dist/project/components/Field/stories.js +12 -0
- package/dist/project/components/FileUpload/README.md +544 -0
- package/dist/project/components/FileUpload/preview.html +2 -0
- package/dist/project/components/FileUpload/stories.js +12 -0
- package/dist/project/components/FilterCascade/README.md +348 -0
- package/dist/project/components/FilterCascade/preview.html +2 -0
- package/dist/project/components/FilterCascade/stories.js +12 -0
- package/dist/project/components/FilterDropdown/README.md +542 -0
- package/dist/project/components/FilterDropdown/preview.html +2 -0
- package/dist/project/components/FilterDropdown/stories.js +12 -0
- package/dist/project/components/FilterInput/README.md +416 -0
- package/dist/project/components/FilterInput/preview.html +2 -0
- package/dist/project/components/FilterInput/stories.js +12 -0
- package/dist/project/components/FilterInput/stories.md +6682 -0
- package/dist/project/components/Flex/README.md +225 -0
- package/dist/project/components/Flex/preview.html +2 -0
- package/dist/project/components/Flex/stories.js +12 -0
- package/dist/project/components/FormatDateTime/README.md +315 -0
- package/dist/project/components/FormatDateTime/preview.html +2 -0
- package/dist/project/components/FormatDateTime/stories.js +12 -0
- package/dist/project/components/FormatNumber/README.md +317 -0
- package/dist/project/components/FormatNumber/preview.html +2 -0
- package/dist/project/components/FormatNumber/stories.js +12 -0
- package/dist/project/components/Heading/README.md +240 -0
- package/dist/project/components/Heading/preview.html +2 -0
- package/dist/project/components/Heading/stories.js +12 -0
- package/dist/project/components/HorizontalBarStack/README.md +281 -0
- package/dist/project/components/HorizontalBarStack/preview.html +2 -0
- package/dist/project/components/HorizontalBarStack/stories.js +12 -0
- package/dist/project/components/HttpMethod/README.md +137 -0
- package/dist/project/components/HttpMethod/preview.html +2 -0
- package/dist/project/components/HttpMethod/stories.js +12 -0
- package/dist/project/components/ImageCropper/README.md +332 -0
- package/dist/project/components/ImageCropper/preview.html +2 -0
- package/dist/project/components/ImageCropper/stories.js +33 -0
- package/dist/project/components/Indicator/README.md +110 -0
- package/dist/project/components/Indicator/preview.html +2 -0
- package/dist/project/components/Indicator/stories.js +12 -0
- package/dist/project/components/InlineEdit/README.md +977 -0
- package/dist/project/components/InlineEdit/preview.html +2 -0
- package/dist/project/components/InlineEdit/stories.js +12 -0
- package/dist/project/components/Input/README.md +187 -0
- package/dist/project/components/Input/preview.html +2 -0
- package/dist/project/components/Input/stories.js +12 -0
- package/dist/project/components/InputGroup/README.md +423 -0
- package/dist/project/components/InputGroup/preview.html +2 -0
- package/dist/project/components/InputGroup/stories.js +12 -0
- package/dist/project/components/InputOTP/README.md +201 -0
- package/dist/project/components/InputOTP/preview.html +2 -0
- package/dist/project/components/InputOTP/stories.js +12 -0
- package/dist/project/components/Ip/README.md +226 -0
- package/dist/project/components/Ip/preview.html +2 -0
- package/dist/project/components/Ip/stories.js +12 -0
- package/dist/project/components/Kbd/README.md +126 -0
- package/dist/project/components/Kbd/preview.html +2 -0
- package/dist/project/components/Kbd/stories.js +12 -0
- package/dist/project/components/LineChart/README.md +1479 -0
- package/dist/project/components/LineChart/preview.html +2 -0
- package/dist/project/components/LineChart/stories.js +12 -0
- package/dist/project/components/Link/README.md +160 -0
- package/dist/project/components/Link/preview.html +2 -0
- package/dist/project/components/Link/stories.js +12 -0
- package/dist/project/components/List/README.md +181 -0
- package/dist/project/components/List/preview.html +2 -0
- package/dist/project/components/List/stories.js +12 -0
- package/dist/project/components/Loader/README.md +145 -0
- package/dist/project/components/Loader/preview.html +2 -0
- package/dist/project/components/Loader/stories.js +12 -0
- package/dist/project/components/Logo/README.md +183 -0
- package/dist/project/components/Logo/preview.html +2 -0
- package/dist/project/components/Logo/stories.js +12 -0
- package/dist/project/components/MessageActions/README.md +255 -0
- package/dist/project/components/MessageActions/preview.html +2 -0
- package/dist/project/components/MessageActions/stories.js +12 -0
- package/dist/project/components/Metric/README.md +324 -0
- package/dist/project/components/Metric/preview.html +2 -0
- package/dist/project/components/Metric/stories.js +12 -0
- package/dist/project/components/NavRail/README.md +25 -0
- package/dist/project/components/NotificationCenter/README.md +91 -0
- package/dist/project/components/NotificationCenter/preview.html +2 -0
- package/dist/project/components/NotificationCenter/stories.js +12 -0
- package/dist/project/components/NotificationCenter/stories.md +2170 -0
- package/dist/project/components/NumberInput/README.md +177 -0
- package/dist/project/components/NumberInput/preview.html +2 -0
- package/dist/project/components/NumberInput/stories.js +12 -0
- package/dist/project/components/NumericBadge/README.md +252 -0
- package/dist/project/components/NumericBadge/preview.html +2 -0
- package/dist/project/components/NumericBadge/stories.js +12 -0
- package/dist/project/components/OverflowList/README.md +324 -0
- package/dist/project/components/OverflowList/preview.html +2 -0
- package/dist/project/components/OverflowList/stories.js +12 -0
- package/dist/project/components/OverflowTooltip/README.md +421 -0
- package/dist/project/components/OverflowTooltip/preview.html +2 -0
- package/dist/project/components/OverflowTooltip/stories.js +12 -0
- package/dist/project/components/Overlay/README.md +95 -0
- package/dist/project/components/Overlay/preview.html +2 -0
- package/dist/project/components/Overlay/stories.js +12 -0
- package/dist/project/components/Overview/README.md +445 -0
- package/dist/project/components/Overview/preview.html +2 -0
- package/dist/project/components/Overview/stories.js +12 -0
- package/dist/project/components/Page/README.md +215 -0
- package/dist/project/components/Page/preview.html +2 -0
- package/dist/project/components/Page/stories.js +12 -0
- package/dist/project/components/Pagination/README.md +302 -0
- package/dist/project/components/Pagination/preview.html +2 -0
- package/dist/project/components/Pagination/stories.js +12 -0
- package/dist/project/components/ParameterPath/README.md +284 -0
- package/dist/project/components/ParameterPath/preview.html +2 -0
- package/dist/project/components/ParameterPath/stories.js +12 -0
- package/dist/project/components/PasswordComplexity/README.md +171 -0
- package/dist/project/components/PasswordComplexity/preview.html +2 -0
- package/dist/project/components/PasswordComplexity/stories.js +12 -0
- package/dist/project/components/PasswordInput/README.md +254 -0
- package/dist/project/components/PasswordInput/preview.html +2 -0
- package/dist/project/components/PasswordInput/stories.js +12 -0
- package/dist/project/components/PieChart/README.md +895 -0
- package/dist/project/components/PieChart/preview.html +2 -0
- package/dist/project/components/PieChart/stories.js +12 -0
- package/dist/project/components/Popover/README.md +282 -0
- package/dist/project/components/Popover/preview.html +2 -0
- package/dist/project/components/Popover/stories.js +12 -0
- package/dist/project/components/Progress/README.md +174 -0
- package/dist/project/components/Progress/preview.html +2 -0
- package/dist/project/components/Progress/stories.js +12 -0
- package/dist/project/components/Radio/README.md +264 -0
- package/dist/project/components/Radio/preview.html +2 -0
- package/dist/project/components/Radio/stories.js +12 -0
- package/dist/project/components/RemoteShell/README.md +1758 -0
- package/dist/project/components/RemoteShell/preview.html +2 -0
- package/dist/project/components/RemoteShell/stories.js +28 -0
- package/dist/project/components/Resizable/README.md +290 -0
- package/dist/project/components/Resizable/preview.html +2 -0
- package/dist/project/components/Resizable/stories.js +12 -0
- package/dist/project/components/ResponseCode/README.md +205 -0
- package/dist/project/components/ResponseCode/preview.html +2 -0
- package/dist/project/components/ResponseCode/stories.js +12 -0
- package/dist/project/components/ScrollArea/README.md +234 -0
- package/dist/project/components/ScrollArea/preview.html +2 -0
- package/dist/project/components/ScrollArea/stories.js +12 -0
- package/dist/project/components/SearchInput/README.md +158 -0
- package/dist/project/components/SearchInput/preview.html +2 -0
- package/dist/project/components/SearchInput/stories.js +12 -0
- package/dist/project/components/SearchModal/README.md +836 -0
- package/dist/project/components/SearchModal/preview.html +2 -0
- package/dist/project/components/SearchModal/stories.js +12 -0
- package/dist/project/components/SegmentedControl/README.md +382 -0
- package/dist/project/components/SegmentedControl/preview.html +2 -0
- package/dist/project/components/SegmentedControl/stories.js +12 -0
- package/dist/project/components/SegmentedTabs/README.md +390 -0
- package/dist/project/components/SegmentedTabs/preview.html +2 -0
- package/dist/project/components/SegmentedTabs/stories.js +12 -0
- package/dist/project/components/Select/README.md +1311 -0
- package/dist/project/components/Select/preview.html +2 -0
- package/dist/project/components/Select/stories.js +12 -0
- package/dist/project/components/Selection/README.md +648 -0
- package/dist/project/components/Selection/preview.html +2 -0
- package/dist/project/components/Selection/stories.js +12 -0
- package/dist/project/components/Separator/README.md +77 -0
- package/dist/project/components/Separator/preview.html +2 -0
- package/dist/project/components/Separator/stories.js +12 -0
- package/dist/project/components/Skeleton/README.md +358 -0
- package/dist/project/components/Skeleton/preview.html +2 -0
- package/dist/project/components/Skeleton/stories.js +12 -0
- package/dist/project/components/Slider/README.md +433 -0
- package/dist/project/components/Slider/preview.html +2 -0
- package/dist/project/components/Slider/stories.js +12 -0
- package/dist/project/components/SplashScreen/README.md +192 -0
- package/dist/project/components/SplashScreen/preview.html +2 -0
- package/dist/project/components/SplashScreen/stories.js +12 -0
- package/dist/project/components/SplitButton/README.md +402 -0
- package/dist/project/components/SplitButton/preview.html +2 -0
- package/dist/project/components/SplitButton/stories.js +12 -0
- package/dist/project/components/Stack/README.md +269 -0
- package/dist/project/components/Stack/preview.html +2 -0
- package/dist/project/components/Stack/stories.js +12 -0
- package/dist/project/components/Stepper/README.md +682 -0
- package/dist/project/components/Stepper/preview.html +2 -0
- package/dist/project/components/Stepper/stories.js +12 -0
- package/dist/project/components/Switch/README.md +236 -0
- package/dist/project/components/Switch/preview.html +2 -0
- package/dist/project/components/Switch/stories.js +12 -0
- package/dist/project/components/Table/README.md +471 -0
- package/dist/project/components/Table/preview.html +2 -0
- package/dist/project/components/Table/stories.js +12 -0
- package/dist/project/components/Table/stories.md +3697 -0
- package/dist/project/components/Tabs/README.md +443 -0
- package/dist/project/components/Tabs/preview.html +2 -0
- package/dist/project/components/Tabs/stories.js +12 -0
- package/dist/project/components/Tag/README.md +324 -0
- package/dist/project/components/Tag/preview.html +2 -0
- package/dist/project/components/Tag/stories.js +12 -0
- package/dist/project/components/Text/README.md +200 -0
- package/dist/project/components/Text/preview.html +2 -0
- package/dist/project/components/Text/stories.js +12 -0
- package/dist/project/components/Textarea/README.md +273 -0
- package/dist/project/components/Textarea/preview.html +2 -0
- package/dist/project/components/Textarea/stories.js +12 -0
- package/dist/project/components/TimeInput/README.md +359 -0
- package/dist/project/components/TimeInput/preview.html +2 -0
- package/dist/project/components/TimeInput/stories.js +12 -0
- package/dist/project/components/Timeline/README.md +204 -0
- package/dist/project/components/Timeline/preview.html +2 -0
- package/dist/project/components/Timeline/stories.js +12 -0
- package/dist/project/components/Toast/README.md +718 -0
- package/dist/project/components/Toast/preview.html +2 -0
- package/dist/project/components/Toast/stories.js +12 -0
- package/dist/project/components/ToggleButton/README.md +292 -0
- package/dist/project/components/ToggleButton/preview.html +2 -0
- package/dist/project/components/ToggleButton/stories.js +12 -0
- package/dist/project/components/Tooltip/README.md +199 -0
- package/dist/project/components/Tooltip/preview.html +2 -0
- package/dist/project/components/Tooltip/stories.js +12 -0
- package/dist/project/components/TopHeader/README.md +21 -0
- package/dist/project/components/Tour/README.md +532 -0
- package/dist/project/components/Tour/preview.html +2 -0
- package/dist/project/components/Tour/stories.js +12 -0
- package/dist/project/components/Tree/README.md +450 -0
- package/dist/project/components/Tree/preview.html +2 -0
- package/dist/project/components/Tree/stories.js +12 -0
- package/dist/project/components/TreeView/README.md +531 -0
- package/dist/project/components/TreeView/preview.html +2 -0
- package/dist/project/components/TreeView/stories.js +12 -0
- package/dist/project/components/UTILITIES.md +647 -0
- package/dist/project/components/UserMessage/README.md +166 -0
- package/dist/project/components/UserMessage/preview.html +2 -0
- package/dist/project/components/UserMessage/stories.js +12 -0
- package/dist/project/components/UtilityPage/README.md +147 -0
- package/dist/project/components/UtilityPage/preview.html +2 -0
- package/dist/project/components/UtilityPage/stories.js +12 -0
- package/dist/project/components/WallyAssistant/README.md +1380 -0
- package/dist/project/components/WallyAssistant/preview.html +2 -0
- package/dist/project/components/WallyAssistant/stories.js +12 -0
- package/dist/project/components/WallyIcon/README.md +130 -0
- package/dist/project/components/WallyIcon/preview.html +2 -0
- package/dist/project/components/WallyIcon/stories.js +12 -0
- package/dist/project/components/WallySkeleton/README.md +96 -0
- package/dist/project/components/WallySkeleton/preview.html +2 -0
- package/dist/project/components/WallySkeleton/stories.js +12 -0
- package/dist/project/components/bundle.css +18734 -0
- package/dist/project/components/bundle.js +167 -0
- package/dist/project/components/index.d.ts +27226 -0
- package/dist/project/design-system.json +35 -0
- package/dist/project/fonts/Geist-Variable.woff2 +0 -0
- package/dist/project/fonts/GeistMono-Variable.woff2 +0 -0
- package/dist/project/fonts/GeistPixel-Square.woff2 +0 -0
- package/dist/project/sampler.dc.html +238 -0
- package/dist/project/tokens.css +1395 -0
- package/dist/project/tokens.json +5235 -0
- package/dist/wallarm-sampler.dc.html +239 -0
- package/package.json +67 -3
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
var e={vD(e,t,r){let i,n;/**
|
|
2
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*
|
|
7
|
+
* @lightSyntaxTransform
|
|
8
|
+
* @noflow
|
|
9
|
+
* @nolint
|
|
10
|
+
* @preventMunge
|
|
11
|
+
* @preserve-invariant-messages
|
|
12
|
+
*/var l,a,o=Object.create,s=Object.defineProperty,c=Object.getOwnPropertyDescriptor,h=Object.getOwnPropertyNames,u=Object.getPrototypeOf,d=Object.prototype.hasOwnProperty,m=(e,t,r,i)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let n of h(t))d.call(e,n)||n===r||s(e,n,{get:()=>t[n],enumerable:!(i=c(t,n))||i.enumerable});return e},f={},p={$dispatcherGuard:()=>R,$makeReadOnly:()=>N,$reset:()=>O,$structuralCheck:()=>V,c:()=>C,clearRenderCounterRegistry:()=>M,renderCounterRegistry:()=>$,useRenderCounter:()=>T};for(var y in p)s(f,y,{get:p[y],enumerable:!0});e.exports=m(s({},"__esModule",{value:!0}),f);var g=(n=null!=(i=r("C"))?o(u(i)):{},m(i&&i.__esModule?n:s(n,"default",{value:i,enumerable:!0}),i)),{useRef:b,useEffect:S,isValidElement:w}=g,_=null!=(l=g.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE)?l:g.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,v=Symbol.for("react.memo_cache_sentinel"),C="function"==typeof(null==(a=g.__COMPILER_RUNTIME)?void 0:a.c)?g.__COMPILER_RUNTIME.c:function(e){return g.useMemo(()=>{let t=Array(e);for(let r=0;r<e;r++)t[r]=v;return t[v]=!0,t},[])},I={};["readContext","useCallback","useContext","useEffect","useImperativeHandle","useInsertionEffect","useLayoutEffect","useMemo","useReducer","useRef","useState","useDebugValue","useDeferredValue","useTransition","useMutableSource","useSyncExternalStore","useId","unstable_isNewReconciler","getCacheSignal","getCacheForType","useCacheRefresh"].forEach(e=>{I[e]=()=>{throw Error(`[React] Unexpected React hook call (${e}) from a React compiled function. Check that all hooks are called directly and named according to convention ('use[A-Z]') `)}});var D=null;function E(e){return _.ReactCurrentDispatcher.current=e,_.ReactCurrentDispatcher.current}I.useMemoCache=e=>{if(null!=D)return D.useMemoCache(e);throw Error("React Compiler internal invariant violation: unexpected null dispatcher")};var x=[];function R(e){let t=_.ReactCurrentDispatcher.current;if(0===e){if(x.push(t),1===x.length&&(D=t),t===I)throw Error("[React] Unexpected call to custom hook or component from a React compiled function. Check that (1) all hooks are called directly and named according to convention ('use[A-Z]') and (2) components are returned as JSX instead of being directly invoked.");E(I)}else if(1===e){let e=x.pop();if(null==e)throw Error("React Compiler internal error: unexpected null in guard stack");0===x.length&&(D=null),E(e)}else if(2===e)x.push(t),E(D);else if(3===e){let e=x.pop();if(null==e)throw Error("React Compiler internal error: unexpected null in guard stack");E(e)}else throw Error("React Compiler internal error: unreachable block"+e)}function O(e){for(let t=0;t<e.length;t++)e[t]=v}function N(){throw Error("TODO: implement $makeReadOnly in react-compiler-runtime")}var $=new Map;function M(){for(let e of $.values())e.forEach(e=>{e.count=0})}function T(e){let t=b(null);null!=t.current&&(t.current.count+=1),S(()=>{if(null==t.current){let r,i={count:0};null==(r=$.get(e))&&(r=new Set,$.set(e,r)),r.add(i),t.current=i}return()=>{var r;let i;null!==t.current&&(r=t.current,null!=(i=$.get(e))&&i.delete(r))}})}var k=new Set;function V(e,t,r,i,n,l){function a(e,t,a,o){let s=`${i}:${l} [${n}] ${r}${a} changed from ${e} to ${t} at depth ${o}`;k.has(s)||(k.add(s),console.error(s))}!function e(t,r,i,n){if(!(n>2)){if(t!==r)if(typeof t!=typeof r)a(`type ${typeof t}`,`type ${typeof r}`,i,n);else if("object"==typeof t){let l=Array.isArray(t),o=Array.isArray(r);if(null===t&&null!==r)a("null",`type ${typeof r}`,i,n);else if(null===r)a(`type ${typeof t}`,"null",i,n);else if(t instanceof Map)if(r instanceof Map)if(t.size!==r.size)a(`Map instance with size ${t.size}`,`Map instance with size ${r.size}`,i,n);else for(let[l,o]of t)r.has(l)?e(o,r.get(l),`${i}.get(${l})`,n+1):a(`Map instance with key ${l}`,`Map instance without key ${l}`,i,n);else a("Map instance","other value",i,n);else if(r instanceof Map)a("other value","Map instance",i,n);else if(t instanceof Set)if(r instanceof Set)if(t.size!==r.size)a(`Set instance with size ${t.size}`,`Set instance with size ${r.size}`,i,n);else for(let e of r)t.has(e)||a(`Set instance without element ${e}`,`Set instance with element ${e}`,i,n);else a("Set instance","other value",i,n);else if(r instanceof Set)a("other value","Set instance",i,n);else if(l||o)if(l!==o)a(`type ${l?"array":"object"}`,`type ${o?"array":"object"}`,i,n);else if(t.length!==r.length)a(`array with length ${t.length}`,`array with length ${r.length}`,i,n);else for(let l=0;l<t.length;l++)e(t[l],r[l],`${i}[${l}]`,n+1);else if(w(t)||w(r))w(t)!==w(r)?a(`type ${w(t)?"React element":"object"}`,`type ${w(r)?"React element":"object"}`,i,n):t.type!==r.type?a(`React element of type ${t.type}`,`React element of type ${r.type}`,i,n):e(t.props,r.props,`[props of ${i}]`,n+1);else{for(let e in r)e in t||a(`object without key ${e}`,`object with key ${e}`,i,n);for(let l in t)l in r?e(t[l],r[l],`${i}.${l}`,n+1):a(`object with key ${l}`,`object without key ${l}`,i,n)}}else{if("function"==typeof t)return;isNaN(t)||isNaN(r)?isNaN(t)!==isNaN(r)&&a(`${isNaN(t)?"NaN":"non-NaN value"}`,`${isNaN(r)?"NaN":"non-NaN value"}`,i,n):t!==r&&a(t,r,i,n)}}}(e,t,"",0)}},p(e,t,r){let i=new WeakMap,n=new WeakMap;function l(e,t,r){let l=t,a=r;if("object"==typeof l&&null!==l&&"$$typeof"in l&&l.$$typeof===Symbol.for("react.context")&&"Provider"in l&&(l=l.Provider),"function"==typeof l&&null!=a.ref&&!l.prototype?.isReactComponent){let t=l,r=i.get(e);r||(r=new WeakMap,i.set(e,r));let n=r.get(t);n||((n=e.forwardRef((e,r)=>t({...e,ref:r}))).displayName=t.displayName??t.name,r.set(t,n)),l=n}if("string"==typeof l&&"boolean"==typeof a.inert&&((a={...a}).inert?a.inert="":delete a.inert),"string"==typeof l)for(let[e,t]of[["fill-rule","fillRule"],["clip-rule","clipRule"]])e in a&&(a={...a,[t]:a[e]},delete a[e]);return"string"==typeof l&&null!=a.ref&&(l=function(e,t){let r=n.get(e);r||(r=new Map,n.set(e,r));let i=r.get(t);if(i)return i;let l=e.forwardRef((r,i)=>{let n=e.useRef(null);if(!n.current||n.current.original!==i){let e;n.current={original:i,callback:t=>{if(null==t&&e){let t=e;e=void 0,t();return}if("function"==typeof i){let r=i(t);e="function"==typeof r?r:void 0}else i&&(i.current=t)}}}return e.createElement(t,{...r,ref:n.current.callback})});return l.displayName=`CanvasHost(${t})`,r.set(t,l),l}(e,l)),{type:l,props:a}}function a(e){let t=(t,r,i)=>{let n=l(e,t,r??{});return e.createElement(n.type,void 0===i?n.props:{...n.props,key:i})};return{jsx:t,jsxs:(t,r,i)=>{let n=l(e,t,r??{}),{children:a,...o}=n.props;return e.createElement(n.type,void 0===i?o:{...o,key:i},...Array.isArray(a)?a:[a])},jsxDEV:t,Fragment:e.Fragment}}function o(e){return{...e,createElement:(t,r,...i)=>{let n=l(e,t,r??{});return e.createElement(n.type,n.props,...i)},cloneElement:(t,r,...i)=>{let n=e.cloneElement(t,r??void 0,...i),a=n.ref,o=l(e,n.type,{...n.props,ref:a});return o.type===n.type&&"string"!=typeof n.type?n:e.createElement(o.type,{...o.props,key:n.key})}}}r.d(t,{MA:()=>a,YJ:()=>o})},C(e,t,r){r.r(t);let i=(0,r("p").YJ)(window.React),{Children:n,Component:l,Fragment:a,Profiler:o,PureComponent:s,StrictMode:c,Suspense:h,__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:u,act:d,cloneElement:m,createContext:f,createElement:p,createFactory:y,createRef:g,forwardRef:b,isValidElement:S,lazy:w,memo:_,startTransition:v,unstable_act:C,useCallback:I,useContext:D,useDebugValue:E,useDeferredValue:x,useEffect:R,useId:O,useImperativeHandle:N,useInsertionEffect:$,useLayoutEffect:M,useMemo:T,useReducer:k,useRef:V,useState:W,useSyncExternalStore:j,useTransition:A,version:z,use:P}=i;r.d(t,{},{Children:n,Component:l,Fragment:a,Profiler:o,PureComponent:s,StrictMode:c,Suspense:h,__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:u,act:d,cloneElement:m,createContext:f,createElement:p,createFactory:y,createRef:g,default:i,forwardRef:b,isValidElement:S,lazy:w,memo:_,startTransition:v,unstable_act:C,use:P,useCallback:I,useContext:D,useDebugValue:E,useDeferredValue:x,useEffect:R,useId:O,useImperativeHandle:N,useInsertionEffect:$,useLayoutEffect:M,useMemo:T,useReducer:k,useRef:V,useState:W,useSyncExternalStore:j,useTransition:A,version:z})}},t={};function r(i){var n=t[i];if(void 0!==n)return n.exports;var l=t[i]={exports:{}};return e[i](l,l.exports,r),l.exports}r.d=(e,t,i)=>{var n=(t,i)=>{for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,[i]:t[n]})};n(t,"get"),n(i,"value")},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.r=e=>{"u">typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{let{jsx:e,jsxs:t,jsxDEV:i,Fragment:n}=(0,r("p").MA)(window.React);var l=r("vD"),a=Object.defineProperty,o=(e,t,r)=>{let i;return(i="symbol"!=typeof t?t+"":t)in e?a(e,i,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[i]=r},s=e=>null!=e&&"object"==typeof e&&!Array.isArray(e),c=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);Function.prototype.toString.call(Object);var h=e=>e?.constructor.name==="Array",u=(e,t)=>{if(Object.is(e,t))return!0;if(null==e&&null!=t||null!=e&&null==t)return!1;if("function"==typeof e?.isEqual&&"function"==typeof t?.isEqual)return e.isEqual(t);if("function"==typeof e&&"function"==typeof t)return e.toString()===t.toString();if(h(e)&&h(t))return((e,t)=>{if(e.length!==t.length)return!1;for(let r=0;r<e.length;r++)if(!u(e[r],t[r]))return!1;return!0})(Array.from(e),Array.from(t));if("object"!=typeof e||"object"!=typeof t)return!1;let r=Object.keys(t??Object.create(null)),i=r.length;for(let t=0;t<i;t++)if(!Reflect.has(e,r[t]))return!1;for(let n=0;n<i;n++){let i=r[n];if(!u(e[i],t[i]))return!1}return!0},d={itemToValue:e=>"string"==typeof e?e:s(e)&&c(e,"value")?e.value:"",itemToString:e=>"string"==typeof e?e:s(e)&&c(e,"label")?e.label:d.itemToValue(e),isItemDisabled:e=>!!(s(e)&&c(e,"disabled"))&&!!e.disabled},m=class e{constructor(t){o(this,"options",t),o(this,"items"),o(this,"indexMap",null),o(this,"copy",t=>new e({...this.options,items:t??[...this.items]})),o(this,"isEqual",e=>u(this.items,e.items)),o(this,"setItems",e=>this.copy(e)),o(this,"getValues",(e=this.items)=>{let t=[];for(let r of e){let e=this.getItemValue(r);null!=e&&t.push(e)}return t}),o(this,"find",e=>{if(null==e)return null;let t=this.indexOf(e);return -1!==t?this.at(t):null}),o(this,"findMany",e=>{let t=[];for(let r of e){let e=this.find(r);null!=e&&t.push(e)}return t}),o(this,"at",e=>{if(!this.options.groupBy&&!this.options.groupSort)return this.items[e]??null;let t=0;for(let[,r]of this.group())for(let i of r){if(t===e)return i;t++}return null}),o(this,"sortFn",(e,t)=>(this.indexOf(e)??0)-(this.indexOf(t)??0)),o(this,"sort",e=>[...e].sort(this.sortFn.bind(this))),o(this,"getItemValue",e=>null==e?null:this.options.itemToValue?.(e)??d.itemToValue(e)),o(this,"getItemDisabled",e=>null!=e&&(this.options.isItemDisabled?.(e)??d.isItemDisabled(e))),o(this,"stringifyItem",e=>null==e?null:this.options.itemToString?.(e)??d.itemToString(e)),o(this,"stringify",e=>null==e?null:this.stringifyItem(this.find(e))),o(this,"stringifyItems",(e,t=", ")=>{let r=[];for(let t of e){let e=this.stringifyItem(t);null!=e&&r.push(e)}return r.join(t)}),o(this,"stringifyMany",(e,t)=>this.stringifyItems(this.findMany(e),t)),o(this,"has",e=>-1!==this.indexOf(e)),o(this,"hasItem",e=>null!=e&&this.has(this.getItemValue(e))),o(this,"group",()=>{let{groupBy:e,groupSort:t}=this.options;if(!e)return[["",[...this.items]]];let r=new Map;this.items.forEach((t,i)=>{let n=e(t,i);r.has(n)||r.set(n,[]),r.get(n).push(t)});let i=Array.from(r.entries());return t&&i.sort(([e],[r])=>{if("function"==typeof t)return t(e,r);if(Array.isArray(t)){let i=t.indexOf(e),n=t.indexOf(r);return -1===i?1:-1===n?-1:i-n}return"asc"===t?e.localeCompare(r):"desc"===t?r.localeCompare(e):0}),i}),o(this,"getNextValue",(e,t=1,r=!1)=>{let i=this.indexOf(e);if(-1===i)return null;for(i=r?Math.min(i+t,this.size-1):i+t;i<=this.size&&this.getItemDisabled(this.at(i));)i++;return this.getItemValue(this.at(i))}),o(this,"getPreviousValue",(e,t=1,r=!1)=>{let i=this.indexOf(e);if(-1===i)return null;for(i=r?Math.max(i-t,0):i-t;i>=0&&this.getItemDisabled(this.at(i));)i--;return this.getItemValue(this.at(i))}),o(this,"indexOf",e=>{if(null==e)return -1;if(!this.options.groupBy&&!this.options.groupSort)return this.items.findIndex(t=>this.getItemValue(t)===e);if(!this.indexMap){this.indexMap=new Map;let e=0;for(let[,t]of this.group())for(let r of t){let t=this.getItemValue(r);null!=t&&this.indexMap.set(t,e),e++}}return this.indexMap.get(e)??-1}),o(this,"getByText",(e,t)=>{let r=null!=t?this.indexOf(t):-1,i=1===e.length;for(let n=0;n<this.items.length;n++){let l=this.items[(r+n+1)%this.items.length];if((!i||this.getItemValue(l)!==t)&&!this.getItemDisabled(l)&&f(this.stringifyItem(l),e))return l}}),o(this,"search",(e,t)=>{let{state:r,currentValue:i,timeout:n=350}=t,l=r.keysSoFar+e,a=l.length>1&&Array.from(l).every(e=>e===l[0])?l[0]:l,o=this.getByText(a,i),s=this.getItemValue(o);function c(){clearTimeout(r.timer),r.timer=-1}return!function e(t){r.keysSoFar=t,c(),""!==t&&(r.timer=+setTimeout(()=>{e(""),c()},n))}(l),s}),o(this,"update",(e,t)=>{let r=this.indexOf(e);return -1===r?this:this.copy([...this.items.slice(0,r),t,...this.items.slice(r+1)])}),o(this,"upsert",(e,t,r="append")=>{let i=this.indexOf(e);return -1===i?("append"===r?this.append:this.prepend)(t):this.copy([...this.items.slice(0,i),t,...this.items.slice(i+1)])}),o(this,"insert",(e,...t)=>this.copy(p(this.items,e,...t))),o(this,"insertBefore",(e,...t)=>{let r=this.indexOf(e);if(-1===r)if(0!==this.items.length)return this;else r=0;return this.copy(p(this.items,r,...t))}),o(this,"insertAfter",(e,...t)=>{let r=this.indexOf(e);if(-1===r)if(0!==this.items.length)return this;else r=0;return this.copy(p(this.items,r+1,...t))}),o(this,"prepend",(...e)=>this.copy(p(this.items,0,...e))),o(this,"append",(...e)=>this.copy(p(this.items,this.items.length,...e))),o(this,"filter",e=>{let t=this.items.filter((t,r)=>e(this.stringifyItem(t),r,t));return this.copy(t)}),o(this,"remove",(...e)=>{let t=e.map(e=>"string"==typeof e?e:this.getItemValue(e));return this.copy(this.items.filter(e=>{let r=this.getItemValue(e);return null!=r&&!t.includes(r)}))}),o(this,"move",(e,t)=>{let r=this.indexOf(e);return -1===r?this:this.copy(y(this.items,[r],t))}),o(this,"moveBefore",(e,...t)=>{let r=this.items.findIndex(t=>this.getItemValue(t)===e);if(-1===r)return this;let i=t.map(e=>this.items.findIndex(t=>this.getItemValue(t)===e)).sort((e,t)=>e-t);return this.copy(y(this.items,i,r))}),o(this,"moveAfter",(e,...t)=>{let r=this.items.findIndex(t=>this.getItemValue(t)===e);if(-1===r)return this;let i=t.map(e=>this.items.findIndex(t=>this.getItemValue(t)===e)).sort((e,t)=>e-t);return this.copy(y(this.items,i,r+1))}),o(this,"reorder",(e,t)=>this.copy(y(this.items,[e],t))),o(this,"compareValue",(e,t)=>{let r=this.indexOf(e),i=this.indexOf(t);return r<i?-1:+(r>i)}),o(this,"range",(e,t)=>{let r=[],i=e;for(;null!=i;){if(this.find(i)&&r.push(i),i===t)return r;i=this.getNextValue(i)}return[]}),o(this,"getValueRange",(e,t)=>e&&t?0>=this.compareValue(e,t)?this.range(e,t):this.range(t,e):[]),o(this,"toString",()=>{let e="";for(let t of this.items)e+=[this.getItemValue(t),this.stringifyItem(t),this.getItemDisabled(t)].filter(Boolean).join(":")+",";return e}),o(this,"toJSON",()=>({size:this.size,first:this.firstValue,last:this.lastValue})),this.items=[...t.items]}get size(){return this.items.length}get firstValue(){let e=0;for(;this.getItemDisabled(this.at(e));)e++;return this.getItemValue(this.at(e))}get lastValue(){let e=this.size-1;for(;this.getItemDisabled(this.at(e));)e--;return this.getItemValue(this.at(e))}*[Symbol.iterator](){yield*this.items}},f=(e,t)=>!!e?.toLowerCase().startsWith(t.toLowerCase());function p(e,t,...r){return[...e.slice(0,t),...r,...e.slice(t)]}function y(e,t,r){let i=(t=[...t].sort((e,t)=>e-t)).map(t=>e[t]);for(let r=t.length-1;r>=0;r--)e=[...e.slice(0,t[r]),...e.slice(t[r]+1)];return r=Math.max(0,r-t.filter(e=>e<r).length),[...e.slice(0,r),...i,...e.slice(r)]}var g=e=>new m(e);let b=window.WallarmDS.Icons.Info,S=window.WallarmDS.Button,w=window.WallarmDS.Checkbox,_=window.WallarmDS.CheckboxDescription,v=window.WallarmDS.CheckboxIndicator,C=window.WallarmDS.CheckboxLabel,I=window.WallarmDS.Input,D=window.WallarmDS.NumberInput,E=window.WallarmDS.Radio,x=window.WallarmDS.RadioGroup,R=window.WallarmDS.RadioIndicator,O=window.WallarmDS.RadioLabel,N=window.WallarmDS.Select,$=window.WallarmDS.SelectButton,M=window.WallarmDS.SelectContent,T=window.WallarmDS.SelectOption,k=window.WallarmDS.SelectOptionText,V=window.WallarmDS.SelectPositioner,W=window.WallarmDS.HStack,j=window.WallarmDS.Switch,A=window.WallarmDS.SwitchControl,z=window.WallarmDS.SwitchDescription,P=window.WallarmDS.SwitchLabel,F=window.WallarmDS.Textarea,L=window.WallarmDS.Tooltip,U=window.WallarmDS.TooltipContent,B=window.WallarmDS.TooltipTrigger,Y=window.WallarmDS.Field,q=window.WallarmDS.FieldAction,G=window.WallarmDS.FieldDescription,J=window.WallarmDS.FieldError,H=window.WallarmDS.FieldGroup,Z=window.WallarmDS.FieldIndicator,K=window.WallarmDS.FieldLabel,Q=window.WallarmDS.FieldLegend,X=window.WallarmDS.FieldSeparator,ee=window.WallarmDS.FieldSet,et={title:"Inputs/Field",component:Y,subcomponents:{FieldAction:q,FieldDescription:G,FieldError:J,FieldGroup:H,FieldIndicator:Z,FieldLabel:K,FieldLegend:Q,FieldSeparator:X,FieldSet:ee},parameters:{layout:"centered",docs:{description:{component:"The scaffolding around a control — label, description, error and the required marker — so the control itself only has to be the control. Only `Input`, `Textarea` and `Slider` read this context automatically; wrap anything else and you get the layout, but the labelling still has to be wired by hand."}}}};function er(t){return e(T,{item:t,children:e(k,{children:t})},t)}function ei(t){return e(T,{item:t,children:e(k,{children:t})},t)}function en(t){return e(T,{item:t,children:e(k,{children:t.label})},t.value)}function el(t){return e(T,{item:t,children:e(k,{children:t.label})},t.value)}function ea(t){return e(T,{item:t,children:e(k,{children:t.label})},t.value)}var eo=r("C");let es=[{name:"Basic",story:()=>{let r,i,n,a,o,s,c,h,u,d,m,f,p,y,b,_,T,k,z,L,U,B,q,J,Z,et,en,el=(0,l.c)(27);if(el[0]===Symbol.for("react.memo_cache_sentinel")){let l=g({items:["01","02","03","04","05","06","07","08","09","10","11","12"]}),f=g({items:["2025","2026","2027","2028","2029"]});d="min-w-320",a=H,n=ee,h=e(Q,{children:"Payment Method"}),u=e(G,{children:"All transactions are secure and encrypted"}),i=H,s=t(Y,{children:[e(K,{children:"Name on Card"}),e(I,{placeholder:"Evil Rabbit"})]}),c=t(Y,{children:[e(K,{htmlFor:"checkout-7j9-card-number-uw1",children:"Card Number"}),e(I,{id:"checkout-7j9-card-number-uw1",placeholder:"1234 5678 9012 3456",required:!0}),e(G,{children:"Enter your 16-digit card number"})]}),r=W,o=t(Y,{children:[e(K,{children:"Month"}),t(N,{collection:l,children:[e($,{placeholder:"Month"}),e(V,{children:e(M,{children:l.items.map(er)})})]})]}),m=t(Y,{children:[e(K,{children:"Year"}),t(N,{collection:f,children:[e($,{placeholder:"Year"}),e(V,{children:e(M,{children:f.items.map(ei)})})]})]}),el[0]=r,el[1]=i,el[2]=n,el[3]=a,el[4]=o,el[5]=s,el[6]=c,el[7]=h,el[8]=u,el[9]=d,el[10]=m}else r=el[0],i=el[1],n=el[2],a=el[3],o=el[4],s=el[5],c=el[6],h=el[7],u=el[8],d=el[9],m=el[10];return el[11]===Symbol.for("react.memo_cache_sentinel")?(f=t(r,{children:[o,m,t(Y,{children:[e(K,{children:"CVV"}),e(I,{placeholder:"123",required:!0})]})]}),el[11]=f):f=el[11],el[12]===Symbol.for("react.memo_cache_sentinel")?(p=t(n,{children:[h,u,t(i,{children:[s,c,f,t(Y,{children:[e(K,{children:"Amount"}),e(D,{defaultValue:"1000"})]})]})]}),y=e(X,{}),el[12]=p,el[13]=y):(p=el[12],y=el[13]),el[14]===Symbol.for("react.memo_cache_sentinel")?(b=e(Q,{children:"Billing Address"}),_=e(G,{children:"The billing address associated with your payment method"}),el[14]=b,el[15]=_):(b=el[14],_=el[15]),el[16]===Symbol.for("react.memo_cache_sentinel")?(T=t(ee,{children:[b,_,e(H,{children:e(Y,{orientation:"horizontal",children:t(w,{defaultChecked:!0,children:[e(v,{}),e(C,{children:"Same as shipping address"})]})})})]}),k=e(X,{}),el[16]=T,el[17]=k):(T=el[16],k=el[17]),el[18]===Symbol.for("react.memo_cache_sentinel")?(z=e(Q,{children:"Subscription Plan"}),L=e(G,{children:"Yearly and lifetime plans offer significant savings."}),el[18]=z,el[19]=L):(z=el[18],L=el[19]),el[20]===Symbol.for("react.memo_cache_sentinel")?(U=t(E,{value:"monthly",children:[e(R,{}),e(O,{children:"Monthly ($9.99/month)"})]}),el[20]=U):U=el[20],el[21]===Symbol.for("react.memo_cache_sentinel")?(B=t(E,{value:"yearly",children:[e(R,{}),e(O,{children:"Yearly ($99.99/year)"})]}),el[21]=B):B=el[21],el[22]===Symbol.for("react.memo_cache_sentinel")?(q=t(ee,{children:[z,L,e(Y,{children:t(x,{defaultValue:"monthly",children:[U,B,t(E,{value:"lifetime",children:[e(R,{}),e(O,{children:"Lifetime ($299.99)"})]})]})})]}),J=e(X,{}),el[22]=q,el[23]=J):(q=el[22],J=el[23]),el[24]===Symbol.for("react.memo_cache_sentinel")?(Z=e(ee,{children:e(H,{children:e(Y,{orientation:"horizontal",children:t(j,{children:[e(A,{}),e(P,{children:"Notice when delivered"})]})})})}),el[24]=Z):Z=el[24],el[25]===Symbol.for("react.memo_cache_sentinel")?(et=e(ee,{children:e(H,{children:t(Y,{children:[e(K,{children:"Comments"}),e(F,{placeholder:"Add any additional comments"})]})})}),el[25]=et):et=el[25],el[26]===Symbol.for("react.memo_cache_sentinel")?(en=e("div",{className:d,children:e("form",{children:t(a,{children:[p,y,T,k,q,J,Z,et,t(Y,{orientation:"horizontal",children:[e(S,{type:"submit",children:"Submit"}),e(S,{variant:"outline",color:"neutral",type:"button",children:"Cancel"})]})]})})}),el[26]=en):en=el[26],en},meta:et},{name:"Inputs",story:()=>{let r,i,n=(0,l.c)(2);return n[0]===Symbol.for("react.memo_cache_sentinel")?(r=t(Y,{children:[e(K,{children:"Username"}),e(I,{type:"text",placeholder:"Max Leiter"}),e(G,{children:"Choose a unique username for your account."})]}),n[0]=r):r=n[0],n[1]===Symbol.for("react.memo_cache_sentinel")?(i=e("div",{className:"min-w-320",children:e(ee,{children:t(H,{children:[r,t(Y,{children:[e(K,{children:"Password"}),e(G,{children:"Must be at least 8 characters long."}),e(I,{type:"password",placeholder:"********"})]})]})})}),n[1]=i):i=n[1],i},meta:et},{name:"Textareas",story:()=>{let r,i=(0,l.c)(1);return i[0]===Symbol.for("react.memo_cache_sentinel")?(r=e("div",{className:"min-w-320",children:e(ee,{children:e(H,{children:t(Y,{children:[e(K,{children:"Feedback"}),e(F,{placeholder:"Your feedback helps us improve...",rows:4}),e(G,{children:"Share your thoughts about our service."})]})})})}),i[0]=r):r=i[0],r},meta:et},{name:"Fieldset",story:()=>{let r,i,n,a,o,s=(0,l.c)(5);return s[0]===Symbol.for("react.memo_cache_sentinel")?(r=e(Q,{children:"Profile"}),i=e(G,{children:"This appears on invoices and emails."}),s[0]=r,s[1]=i):(r=s[0],i=s[1]),s[2]===Symbol.for("react.memo_cache_sentinel")?(n=t(Y,{children:[t(K,{children:["Full name",e(q,{children:"Generate new"})]}),e(I,{autoComplete:"off",placeholder:"Evil Rabbit"}),e(G,{children:"This appears on invoices and emails."})]}),s[2]=n):n=s[2],s[3]===Symbol.for("react.memo_cache_sentinel")?(a=t(Y,{required:!0,children:[t(K,{children:["Username",e(Z,{})]}),e(I,{placeholder:"@paveldurov",autoComplete:"off",error:!0}),e(J,{children:"Choose another username."})]}),s[3]=a):a=s[3],s[4]===Symbol.for("react.memo_cache_sentinel")?(o=e("div",{className:"min-w-320",children:t(ee,{children:[r,i,t(H,{children:[n,a,t(Y,{children:[t(K,{children:["Message",t(L,{children:[e(B,{children:e(b,{})}),e(U,{children:"Additional information"})]})]}),e(F,{placeholder:"Your message..."}),e(G,{children:"Enter your message."})]})]})]})}),s[4]=o):o=s[4],o},meta:et},{name:"Switches",story:()=>{let r,i,n,a,o,s=(0,l.c)(5);return s[0]===Symbol.for("react.memo_cache_sentinel")?(r=e(Q,{children:"Notification Settings"}),i=e(G,{children:"Manage your notification preferences."}),s[0]=r,s[1]=i):(r=s[0],i=s[1]),s[2]===Symbol.for("react.memo_cache_sentinel")?(n=e(Y,{orientation:"horizontal",children:t(j,{defaultChecked:!0,children:[e(A,{}),e(P,{children:"Email notifications"}),e(z,{children:"Receive email alerts for important updates."})]})}),s[2]=n):n=s[2],s[3]===Symbol.for("react.memo_cache_sentinel")?(a=e(Y,{orientation:"horizontal",children:t(j,{children:[e(A,{}),e(P,{children:"Push notifications"}),e(z,{children:"Get push notifications on your device."})]})}),s[3]=a):a=s[3],s[4]===Symbol.for("react.memo_cache_sentinel")?(o=e("div",{className:"min-w-320",children:t(ee,{children:[r,i,t(H,{children:[n,a,e(Y,{orientation:"horizontal",children:t(j,{defaultChecked:!0,children:[e(A,{}),e(P,{children:"SMS notifications"}),e(z,{children:"Receive text messages for critical alerts."})]})})]})]})}),s[4]=o):o=s[4],o},meta:et},{name:"Radios",story:()=>{let r,i,n,a,o,s,c=(0,l.c)(6);return c[0]===Symbol.for("react.memo_cache_sentinel")?(r=e(Q,{children:"Delivery Method"}),i=e(G,{children:"Choose how you want to receive your order."}),c[0]=r,c[1]=i):(r=c[0],i=c[1]),c[2]===Symbol.for("react.memo_cache_sentinel")?(n=t(E,{value:"standard",children:[e(R,{}),e(O,{children:"Standard Shipping (5-7 days)"})]}),c[2]=n):n=c[2],c[3]===Symbol.for("react.memo_cache_sentinel")?(a=t(E,{value:"express",children:[e(R,{}),e(O,{children:"Express Shipping (2-3 days)"})]}),c[3]=a):a=c[3],c[4]===Symbol.for("react.memo_cache_sentinel")?(o=t(E,{value:"overnight",children:[e(R,{}),e(O,{children:"Overnight Shipping (1 day)"})]}),c[4]=o):o=c[4],c[5]===Symbol.for("react.memo_cache_sentinel")?(s=e("div",{className:"min-w-320",children:t(ee,{children:[r,i,t(Y,{children:[t(x,{defaultValue:"standard",children:[n,a,o,t(E,{value:"pickup",children:[e(R,{}),e(O,{children:"In-store Pickup"})]})]}),e(G,{children:"Shipping costs will be calculated at checkout."})]})]})}),c[5]=s):s=c[5],s},meta:et},{name:"Checkboxes",story:()=>{let r,i,n,a,o,s=(0,l.c)(5);return s[0]===Symbol.for("react.memo_cache_sentinel")?(r=e(Q,{children:"Terms and Preferences"}),i=e(G,{children:"Select which terms you agree to."}),s[0]=r,s[1]=i):(r=s[0],i=s[1]),s[2]===Symbol.for("react.memo_cache_sentinel")?(n=e(Y,{orientation:"horizontal",children:t(w,{defaultChecked:!0,children:[e(v,{}),e(C,{children:"I accept the terms and conditions"}),e(_,{children:"You must agree to our terms to continue."})]})}),s[2]=n):n=s[2],s[3]===Symbol.for("react.memo_cache_sentinel")?(a=e(Y,{orientation:"horizontal",children:t(w,{children:[e(v,{}),e(C,{children:"Subscribe to newsletter"}),e(_,{children:"Get weekly updates and exclusive offers."})]})}),s[3]=a):a=s[3],s[4]===Symbol.for("react.memo_cache_sentinel")?(o=e("div",{className:"min-w-320",children:t(ee,{children:[r,i,t(H,{children:[n,a,e(Y,{orientation:"horizontal",children:t(w,{defaultChecked:!0,children:[e(v,{}),e(C,{children:"Share usage data"}),e(_,{children:"Help us improve our services."})]})})]})]})}),s[4]=o):o=s[4],o},meta:et},{name:"NumberInputs",story:()=>{let r,i,n,a,o,s,c,h=(0,l.c)(7);return h[0]===Symbol.for("react.memo_cache_sentinel")?(r=e(Q,{children:"Product Details"}),i=e(G,{children:"Configure your product quantity and pricing."}),h[0]=r,h[1]=i):(r=h[0],i=h[1]),h[2]===Symbol.for("react.memo_cache_sentinel")?(n=t(Y,{children:[e(K,{children:"Quantity"}),e(D,{defaultValue:"1",min:1,max:100}),e(G,{children:"Choose between 1 and 100 items."})]}),h[2]=n):n=h[2],h[3]===Symbol.for("react.memo_cache_sentinel")?(a=e(K,{children:"Price per unit"}),h[3]=a):a=h[3],h[4]===Symbol.for("react.memo_cache_sentinel")?(o=t(Y,{children:[a,e(D,{defaultValue:"99.99",step:.01,formatOptions:{style:"currency",currency:"USD"}}),e(G,{children:"Set the price for each unit."})]}),h[4]=o):o=h[4],h[5]===Symbol.for("react.memo_cache_sentinel")?(s=e(K,{children:"Discount percentage"}),h[5]=s):s=h[5],h[6]===Symbol.for("react.memo_cache_sentinel")?(c=e("div",{className:"min-w-320",children:t(ee,{children:[r,i,t(H,{children:[n,o,t(Y,{children:[s,e(D,{defaultValue:"10",min:0,max:100,formatOptions:{style:"percent"}}),e(G,{children:"Apply a discount from 0% to 100%."})]})]})]})}),h[6]=c):c=h[6],c},meta:et},{name:"Selects",story:()=>{let r,i=(0,l.c)(1);if(i[0]===Symbol.for("react.memo_cache_sentinel")){let n=g({items:[{value:"us",label:"United States"},{value:"uk",label:"United Kingdom"},{value:"ca",label:"Canada"},{value:"au",label:"Australia"},{value:"fr",label:"France"},{value:"de",label:"Germany"},{value:"jp",label:"Japan"}]}),l=g({items:[{value:"en",label:"English"},{value:"es",label:"Spanish"},{value:"fr",label:"French"},{value:"de",label:"German"},{value:"it",label:"Italian"},{value:"pt",label:"Portuguese"},{value:"ru",label:"Russian"},{value:"zh",label:"Chinese"},{value:"ja",label:"Japanese"}]}),a=g({items:[{value:"utc-8",label:"Pacific Time (UTC-8)"},{value:"utc-5",label:"Eastern Time (UTC-5)"},{value:"utc",label:"UTC"},{value:"utc+1",label:"Central European Time (UTC+1)"},{value:"utc+8",label:"China Standard Time (UTC+8)"},{value:"utc+9",label:"Japan Standard Time (UTC+9)"}]});r=e("div",{className:"min-w-320",children:t(ee,{children:[e(Q,{children:"Regional Settings"}),e(G,{children:"Configure your location and language preferences."}),t(H,{children:[t(Y,{children:[e(K,{children:"Country"}),t(N,{collection:n,children:[e($,{placeholder:"Select a country"}),e(V,{children:e(M,{children:n.items.map(en)})})]}),e(G,{children:"Your country determines available features."})]}),t(Y,{children:[e(K,{children:"Language"}),t(N,{collection:l,children:[e($,{placeholder:"Select a language"}),e(V,{children:e(M,{children:l.items.map(el)})})]}),e(G,{children:"Choose your preferred language."})]}),t(Y,{children:[e(K,{children:"Timezone"}),t(N,{collection:a,children:[e($,{placeholder:"Select a timezone"}),e(V,{children:e(M,{children:a.items.map(ea)})})]}),e(G,{children:"All times will be displayed in this timezone."})]})]})]})}),i[0]=r}else r=i[0];return r},meta:et}];function ec({entry:e}){let{story:t,meta:r}=e,i={...r.args,...t.args},n="function"==typeof t||t.$$typeof?t:t.render||r.render||r.component,l=()=>eo.default.createElement(n,i),a={args:i,globals:{theme:"light"},parameters:{...r.parameters,...t.parameters},viewMode:"story"};for(let e of[...r.decorators||[],...t.decorators||[]].reverse()){let t=l;l=()=>e(t,a)}return eo.default.createElement("section",{"data-preview-story":e.name,className:"p-16"},eo.default.createElement("h2",{className:"text-sm mb-12"},e.name),eo.default.createElement(l))}window.WallarmPreview={mount(e){let t=window.ReactDOM.createRoot(e);return t.render(eo.default.createElement(window.WallarmDS.Root,null,es.map((e,t)=>eo.default.createElement(ec,{key:t,entry:e})))),t}}})();
|
|
@@ -0,0 +1,544 @@
|
|
|
1
|
+
Attaches files to a form and checks their type, size and count before accepting them — the drop Area when attaching is the main task on the screen, the "Select file" button when space is tight. Picking never uploads: files travel with the form when it is saved, and the product marks a row `loading` while it sends one. To pick a photo by clicking an avatar, see Data Display/Avatar → Click To Upload.
|
|
2
|
+
|
|
3
|
+
## Props as canvas attributes
|
|
4
|
+
|
|
5
|
+
Use kebab-case attribute names. Pass non-string values through renderVals holes, including booleans. The full emitted API is in `components/index.d.ts`.
|
|
6
|
+
|
|
7
|
+
| Attribute | Type | Required | Default | Description |
|
|
8
|
+
| --- | --- | --- | --- | --- |
|
|
9
|
+
| `value` | `File[] \| undefined` | no | — | Controlled accepted files. |
|
|
10
|
+
| `default-value` | `File[] \| undefined` | no | — | Uncontrolled initial files. |
|
|
11
|
+
| `on-value-change` | `((files: File[]) => void) \| undefined` | no | — | Every change to the accepted list — pick, drop, replace, delete (then `[]`). |
|
|
12
|
+
| `on-file-reject` | `((rejections: FileUploadRejection[]) => void) \| undefined` | no | — | Files that failed validation (for consumers that also want a toast). |
|
|
13
|
+
| `accept` | `string \| string[] \| undefined` | no | — | Extensions and/or MIME types: `'.so,.dylib'`, `'image/png'`, `['.lua']`. |
|
|
14
|
+
| `max-files` | `number \| undefined` | no | `1` | Default `1`: a new pick replaces the file, and the picker stays visible, with the chosen file shown below it. |
|
|
15
|
+
| `max-file-size` | `number \| undefined` | no | — | Bytes. Checked on pick, drop and replace. |
|
|
16
|
+
| `min-file-size` | `number \| undefined` | no | — | Bytes. |
|
|
17
|
+
| `validate` | `((file: File) => string[] \| null) \| undefined` | no | — | Custom rules; returned strings are shown verbatim as rejection messages. |
|
|
18
|
+
| `name` | `string \| undefined` | no | — | Hidden input name — the files submit with a native form under it. |
|
|
19
|
+
| `required` | `boolean \| undefined` | no | — | |
|
|
20
|
+
| `disabled` | `boolean \| undefined` | no | — | |
|
|
21
|
+
| `read-only` | `boolean \| undefined` | no | — | Hides the picker, Delete and Replace; `FileUploadItemAction` (e.g. Download) stays. |
|
|
22
|
+
| `error` | `boolean \| undefined` | no | `false` | Error state (maps to Ark `invalid`); also read from a wrapping `Field`. |
|
|
23
|
+
| `allow-drop` | `boolean \| undefined` | no | `true` | Default `true`. |
|
|
24
|
+
| `title` | `string \| undefined` | no | — | |
|
|
25
|
+
| `default-checked` | `boolean \| undefined` | no | — | |
|
|
26
|
+
| `auto-focus` | `boolean \| undefined` | no | — | |
|
|
27
|
+
| `id` | `string \| undefined` | no | — | |
|
|
28
|
+
| `tab-index` | `number \| undefined` | no | — | |
|
|
29
|
+
| `rel` | `string \| undefined` | no | — | |
|
|
30
|
+
| `on-change` | `ChangeEventHandler<T, Element> \| undefined` | no | — | |
|
|
31
|
+
| `data-testid` | `string \| undefined` | no | — | |
|
|
32
|
+
|
|
33
|
+
## Sub-components
|
|
34
|
+
|
|
35
|
+
- `WallarmDS.FileUploadDropzone` — `FileUploadDropzoneProps` in the declaration bundle.
|
|
36
|
+
- `WallarmDS.FileUploadError` — `FileUploadErrorProps` in the declaration bundle.
|
|
37
|
+
- `WallarmDS.FileUploadItem` — `FileUploadItemProps` in the declaration bundle.
|
|
38
|
+
- `WallarmDS.FileUploadItemAction` — `FileUploadItemActionProps` in the declaration bundle.
|
|
39
|
+
- `WallarmDS.FileUploadItemDeleteTrigger` — `FileUploadItemDeleteTriggerProps` in the declaration bundle.
|
|
40
|
+
- `WallarmDS.FileUploadItemGroup` — `FileUploadItemGroupProps` in the declaration bundle.
|
|
41
|
+
- `WallarmDS.FileUploadItemReplaceTrigger` — `FileUploadItemReplaceTriggerProps` in the declaration bundle.
|
|
42
|
+
- `WallarmDS.FileUploadTrigger` — `FileUploadTriggerProps` in the declaration bundle.
|
|
43
|
+
|
|
44
|
+
## Stories
|
|
45
|
+
|
|
46
|
+
### Basic
|
|
47
|
+
|
|
48
|
+
The drop Area: click anywhere on it or drop files onto it, and from the keyboard Tab reaches it and Enter opens the file dialog.
|
|
49
|
+
|
|
50
|
+
Source: FileUpload/FileUpload.stories.tsx#Basic
|
|
51
|
+
|
|
52
|
+
### ButtonTrigger
|
|
53
|
+
|
|
54
|
+
The same picking and checks behind a "Select file" button that hugs its label, for when a 96px Area would crowd the form.
|
|
55
|
+
|
|
56
|
+
Source: FileUpload/FileUpload.stories.tsx#ButtonTrigger
|
|
57
|
+
|
|
58
|
+
### InField
|
|
59
|
+
|
|
60
|
+
Inside `Field`: the label names the Area, and the description carries the format and the limit.
|
|
61
|
+
|
|
62
|
+
Source: FileUpload/FileUpload.stories.tsx#InField
|
|
63
|
+
|
|
64
|
+
### Multiple
|
|
65
|
+
|
|
66
|
+
With `maxFiles` above one the picker stays and disables once the limit is reached, while each file stacks below it as its own row.
|
|
67
|
+
|
|
68
|
+
Source: FileUpload/FileUpload.stories.tsx#Multiple
|
|
69
|
+
|
|
70
|
+
### SingleFileChosen
|
|
71
|
+
|
|
72
|
+
One file allowed and chosen: the file shows below the picker, and a new pick, or Replace in the row, swaps it.
|
|
73
|
+
|
|
74
|
+
Source: FileUpload/FileUpload.stories.tsx#SingleFileChosen
|
|
75
|
+
|
|
76
|
+
### WithDescription
|
|
77
|
+
|
|
78
|
+
`description` adds a second line to the row for size or status — here, that the file goes with the form.
|
|
79
|
+
|
|
80
|
+
Source: FileUpload/FileUpload.stories.tsx#WithDescription
|
|
81
|
+
|
|
82
|
+
### Uploading
|
|
83
|
+
|
|
84
|
+
A row marked `loading` dims and shows a spinner, and the picker locks until no row is loading; its X becomes "Cancel upload", and stopping the request is up to the product.
|
|
85
|
+
|
|
86
|
+
Source: FileUpload/FileUpload.stories.tsx#Uploading
|
|
87
|
+
|
|
88
|
+
### Validation
|
|
89
|
+
|
|
90
|
+
Only `.so` / `.dylib` up to 32 KB: anything else is refused inline, naming the file and the rule.
|
|
91
|
+
|
|
92
|
+
Source: FileUpload/FileUpload.stories.tsx#Validation
|
|
93
|
+
|
|
94
|
+
### Disabled
|
|
95
|
+
|
|
96
|
+
Disabled: nothing responds, and the Area and the row actions dim.
|
|
97
|
+
|
|
98
|
+
Source: FileUpload/FileUpload.stories.tsx#Disabled
|
|
99
|
+
|
|
100
|
+
### ReadOnly
|
|
101
|
+
|
|
102
|
+
Read-only removes the picker, Replace and Delete, while a custom `FileUploadItemAction` such as Download stays.
|
|
103
|
+
|
|
104
|
+
Source: FileUpload/FileUpload.stories.tsx#ReadOnly
|
|
105
|
+
|
|
106
|
+
### StoredFile
|
|
107
|
+
|
|
108
|
+
A file already on the server is a row too: `FileUploadItem` works outside `FileUpload` from a name and size, and its actions only run your `onClick`.
|
|
109
|
+
|
|
110
|
+
Source: FileUpload/FileUpload.stories.tsx#StoredFile
|
|
111
|
+
|
|
112
|
+
### LongFileName
|
|
113
|
+
|
|
114
|
+
Long names truncate; hover shows the full name.
|
|
115
|
+
|
|
116
|
+
Source: FileUpload/FileUpload.stories.tsx#LongFileName
|
|
117
|
+
|
|
118
|
+
### FormSubmission
|
|
119
|
+
|
|
120
|
+
Nothing uploads on pick: the file travels in the form's `FormData` under `name`, and an empty submit of a required Field shows its error.
|
|
121
|
+
|
|
122
|
+
Source: FileUpload/FileUpload.stories.tsx#FormSubmission
|
|
123
|
+
|
|
124
|
+
## Story sources
|
|
125
|
+
|
|
126
|
+
### FileUpload/FileUpload.stories.tsx
|
|
127
|
+
|
|
128
|
+
```tsx
|
|
129
|
+
import { type FormEvent, useState } from 'react';
|
|
130
|
+
import type { Meta, StoryFn } from 'storybook-react-rsbuild';
|
|
131
|
+
import { Download } from '../../icons';
|
|
132
|
+
import { Button } from '../Button';
|
|
133
|
+
import { Field, FieldDescription, FieldError, FieldIndicator, FieldLabel } from '../Field';
|
|
134
|
+
import { FileUpload, type FileUploadProps } from './FileUpload';
|
|
135
|
+
import { FileUploadDropzone } from './FileUploadDropzone';
|
|
136
|
+
import { FileUploadError } from './FileUploadError';
|
|
137
|
+
import { FileUploadItem } from './FileUploadItem';
|
|
138
|
+
import { FileUploadItemAction } from './FileUploadItemAction';
|
|
139
|
+
import { FileUploadItemDeleteTrigger } from './FileUploadItemDeleteTrigger';
|
|
140
|
+
import { FileUploadItemGroup } from './FileUploadItemGroup';
|
|
141
|
+
import { FileUploadItemReplaceTrigger } from './FileUploadItemReplaceTrigger';
|
|
142
|
+
import { FileUploadTrigger } from './FileUploadTrigger';
|
|
143
|
+
import { formatFileSize } from './lib';
|
|
144
|
+
|
|
145
|
+
const DESCRIPTION = [
|
|
146
|
+
'Attaches files to a form and checks their type, size and count before accepting them — the drop Area when attaching is the main task on the screen, the "Select file" button when space is tight.',
|
|
147
|
+
'Picking never uploads: files travel with the form when it is saved, and the product marks a row `loading` while it sends one. To pick a photo by clicking an avatar, see Data Display/Avatar → Click To Upload.',
|
|
148
|
+
].join(' ');
|
|
149
|
+
|
|
150
|
+
const MB = 1024 ** 2;
|
|
151
|
+
const sample = (name: string, size = 48 * 1024) => new File([new Uint8Array(size)], name);
|
|
152
|
+
|
|
153
|
+
const Rows = () => (
|
|
154
|
+
<FileUploadItemGroup>
|
|
155
|
+
{file => (
|
|
156
|
+
<FileUploadItem file={file}>
|
|
157
|
+
<FileUploadItemReplaceTrigger />
|
|
158
|
+
<FileUploadItemDeleteTrigger />
|
|
159
|
+
</FileUploadItem>
|
|
160
|
+
)}
|
|
161
|
+
</FileUploadItemGroup>
|
|
162
|
+
);
|
|
163
|
+
|
|
164
|
+
const meta = {
|
|
165
|
+
title: 'Inputs/FileUpload',
|
|
166
|
+
component: FileUpload,
|
|
167
|
+
parameters: {
|
|
168
|
+
layout: 'centered',
|
|
169
|
+
docs: { description: { component: DESCRIPTION } },
|
|
170
|
+
},
|
|
171
|
+
args: { maxFiles: 1, disabled: false, readOnly: false, error: false },
|
|
172
|
+
argTypes: {
|
|
173
|
+
value: { control: false },
|
|
174
|
+
defaultValue: { control: false },
|
|
175
|
+
onValueChange: { control: false },
|
|
176
|
+
onFileReject: { control: false },
|
|
177
|
+
validate: { control: false },
|
|
178
|
+
ref: { control: false },
|
|
179
|
+
maxFiles: { control: 'number' },
|
|
180
|
+
maxFileSize: { control: 'number' },
|
|
181
|
+
accept: { control: 'text' },
|
|
182
|
+
},
|
|
183
|
+
decorators: [
|
|
184
|
+
Story => (
|
|
185
|
+
<div style={{ width: 360 }}>
|
|
186
|
+
<Story />
|
|
187
|
+
</div>
|
|
188
|
+
),
|
|
189
|
+
],
|
|
190
|
+
} satisfies Meta<typeof FileUpload>;
|
|
191
|
+
|
|
192
|
+
export default meta;
|
|
193
|
+
|
|
194
|
+
/** The drop Area: click anywhere on it or drop files onto it, and from the keyboard Tab reaches it and Enter opens the file dialog. */
|
|
195
|
+
export const Basic: StoryFn<FileUploadProps> = args => (
|
|
196
|
+
<FileUpload data-testid='file-upload' {...args}>
|
|
197
|
+
<FileUploadDropzone data-analytics-id='FILE_UPLOAD_DROPZONE' />
|
|
198
|
+
<FileUploadError />
|
|
199
|
+
<Rows />
|
|
200
|
+
</FileUpload>
|
|
201
|
+
);
|
|
202
|
+
|
|
203
|
+
/** The same picking and checks behind a "Select file" button that hugs its label, for when a 96px Area would crowd the form. */
|
|
204
|
+
export const ButtonTrigger: StoryFn<FileUploadProps> = args => (
|
|
205
|
+
<FileUpload data-testid='file-upload' {...args}>
|
|
206
|
+
<FileUploadTrigger />
|
|
207
|
+
<FileUploadError />
|
|
208
|
+
<Rows />
|
|
209
|
+
</FileUpload>
|
|
210
|
+
);
|
|
211
|
+
|
|
212
|
+
/** Inside `Field`: the label names the Area, and the description carries the format and the limit. */
|
|
213
|
+
export const InField: StoryFn<FileUploadProps> = args => (
|
|
214
|
+
<Field required data-testid='field'>
|
|
215
|
+
<FieldLabel>
|
|
216
|
+
WASM module
|
|
217
|
+
<FieldIndicator />
|
|
218
|
+
</FieldLabel>
|
|
219
|
+
<FieldDescription>
|
|
220
|
+
Exports memory, spe_alloc, spe_free, spe_init, spe_on_phase · up to 32 MB
|
|
221
|
+
</FieldDescription>
|
|
222
|
+
<FileUpload data-testid='file-upload' accept='.wasm' maxFileSize={32 * MB} {...args}>
|
|
223
|
+
<FileUploadDropzone>Choose a .wasm module or drop it here</FileUploadDropzone>
|
|
224
|
+
<FileUploadError />
|
|
225
|
+
<Rows />
|
|
226
|
+
</FileUpload>
|
|
227
|
+
</Field>
|
|
228
|
+
);
|
|
229
|
+
|
|
230
|
+
/** With `maxFiles` above one the picker stays and disables once the limit is reached, while each file stacks below it as its own row. */
|
|
231
|
+
export const Multiple: StoryFn<FileUploadProps> = args => (
|
|
232
|
+
<FileUpload
|
|
233
|
+
data-testid='file-upload'
|
|
234
|
+
{...args}
|
|
235
|
+
maxFiles={5}
|
|
236
|
+
defaultValue={[sample('rules.lua'), sample('headers.lua')]}
|
|
237
|
+
>
|
|
238
|
+
<FileUploadDropzone />
|
|
239
|
+
<FileUploadError />
|
|
240
|
+
<Rows />
|
|
241
|
+
</FileUpload>
|
|
242
|
+
);
|
|
243
|
+
|
|
244
|
+
/** One file allowed and chosen: the file shows below the picker, and a new pick, or Replace in the row, swaps it. */
|
|
245
|
+
export const SingleFileChosen: StoryFn<FileUploadProps> = args => (
|
|
246
|
+
<FileUpload data-testid='file-upload' {...args} defaultValue={[sample('policy.wasm')]}>
|
|
247
|
+
<FileUploadDropzone />
|
|
248
|
+
<FileUploadError />
|
|
249
|
+
<Rows />
|
|
250
|
+
</FileUpload>
|
|
251
|
+
);
|
|
252
|
+
|
|
253
|
+
/** `description` adds a second line to the row for size or status — here, that the file goes with the form. */
|
|
254
|
+
export const WithDescription: StoryFn<FileUploadProps> = args => (
|
|
255
|
+
<FileUpload data-testid='file-upload' {...args} defaultValue={[sample('policy.wasm')]}>
|
|
256
|
+
<FileUploadDropzone />
|
|
257
|
+
<FileUploadItemGroup>
|
|
258
|
+
{file => (
|
|
259
|
+
<FileUploadItem
|
|
260
|
+
file={file}
|
|
261
|
+
description={`${formatFileSize(file.size)} · uploads when you save`}
|
|
262
|
+
>
|
|
263
|
+
<FileUploadItemReplaceTrigger />
|
|
264
|
+
<FileUploadItemDeleteTrigger />
|
|
265
|
+
</FileUploadItem>
|
|
266
|
+
)}
|
|
267
|
+
</FileUploadItemGroup>
|
|
268
|
+
</FileUpload>
|
|
269
|
+
);
|
|
270
|
+
|
|
271
|
+
/** A row marked `loading` dims and shows a spinner, and the picker locks until no row is loading; its X becomes "Cancel upload", and stopping the request is up to the product. */
|
|
272
|
+
export const Uploading: StoryFn<FileUploadProps> = args => (
|
|
273
|
+
<FileUpload data-testid='file-upload' {...args} maxFiles={5} defaultValue={[sample('rules.lua')]}>
|
|
274
|
+
<FileUploadDropzone />
|
|
275
|
+
<FileUploadItemGroup>
|
|
276
|
+
{file => (
|
|
277
|
+
<FileUploadItem file={file}>
|
|
278
|
+
<FileUploadItemReplaceTrigger />
|
|
279
|
+
<FileUploadItemDeleteTrigger />
|
|
280
|
+
</FileUploadItem>
|
|
281
|
+
)}
|
|
282
|
+
</FileUploadItemGroup>
|
|
283
|
+
<FileUploadItemGroup>
|
|
284
|
+
<FileUploadItem file={{ name: 'headers.lua' }} loading>
|
|
285
|
+
<FileUploadItemDeleteTrigger />
|
|
286
|
+
</FileUploadItem>
|
|
287
|
+
</FileUploadItemGroup>
|
|
288
|
+
</FileUpload>
|
|
289
|
+
);
|
|
290
|
+
|
|
291
|
+
/** Only `.so` / `.dylib` up to 32 KB: anything else is refused inline, naming the file and the rule. */
|
|
292
|
+
export const Validation: StoryFn<FileUploadProps> = args => (
|
|
293
|
+
<FileUpload data-testid='file-upload' {...args} accept='.so,.dylib' maxFileSize={32 * 1024}>
|
|
294
|
+
<FileUploadDropzone />
|
|
295
|
+
<FileUploadError />
|
|
296
|
+
<Rows />
|
|
297
|
+
</FileUpload>
|
|
298
|
+
);
|
|
299
|
+
|
|
300
|
+
/** Disabled: nothing responds, and the Area and the row actions dim. */
|
|
301
|
+
export const Disabled: StoryFn<FileUploadProps> = args => (
|
|
302
|
+
<div className='flex flex-col gap-16'>
|
|
303
|
+
<FileUpload data-testid='file-upload' {...args} disabled>
|
|
304
|
+
<FileUploadDropzone />
|
|
305
|
+
</FileUpload>
|
|
306
|
+
<FileUpload {...args} disabled defaultValue={[sample('policy.wasm')]}>
|
|
307
|
+
<Rows />
|
|
308
|
+
</FileUpload>
|
|
309
|
+
</div>
|
|
310
|
+
);
|
|
311
|
+
|
|
312
|
+
/** Read-only removes the picker, Replace and Delete, while a custom `FileUploadItemAction` such as Download stays. */
|
|
313
|
+
export const ReadOnly: StoryFn<FileUploadProps> = args => (
|
|
314
|
+
<FileUpload data-testid='file-upload' {...args} readOnly defaultValue={[sample('policy.wasm')]}>
|
|
315
|
+
<FileUploadDropzone />
|
|
316
|
+
<FileUploadItemGroup>
|
|
317
|
+
{file => (
|
|
318
|
+
<FileUploadItem file={file}>
|
|
319
|
+
<FileUploadItemReplaceTrigger />
|
|
320
|
+
<FileUploadItemAction aria-label={`Download ${file.name}`}>
|
|
321
|
+
<Download />
|
|
322
|
+
</FileUploadItemAction>
|
|
323
|
+
<FileUploadItemDeleteTrigger />
|
|
324
|
+
</FileUploadItem>
|
|
325
|
+
)}
|
|
326
|
+
</FileUploadItemGroup>
|
|
327
|
+
</FileUpload>
|
|
328
|
+
);
|
|
329
|
+
|
|
330
|
+
/** A file already on the server is a row too: `FileUploadItem` works outside `FileUpload` from a name and size, and its actions only run your `onClick`. */
|
|
331
|
+
export const StoredFile: StoryFn<FileUploadProps> = () => (
|
|
332
|
+
<FileUploadItemGroup data-testid='stored'>
|
|
333
|
+
<FileUploadItem file={{ name: 'policy.wasm', size: 48 * 1024 }} description='48 KB · attached'>
|
|
334
|
+
<FileUploadItemAction aria-label='Download policy.wasm'>
|
|
335
|
+
<Download />
|
|
336
|
+
</FileUploadItemAction>
|
|
337
|
+
<FileUploadItemDeleteTrigger aria-label='Detach artifact' />
|
|
338
|
+
</FileUploadItem>
|
|
339
|
+
</FileUploadItemGroup>
|
|
340
|
+
);
|
|
341
|
+
|
|
342
|
+
/** Long names truncate; hover shows the full name. */
|
|
343
|
+
export const LongFileName: StoryFn<FileUploadProps> = args => (
|
|
344
|
+
<FileUpload
|
|
345
|
+
data-testid='file-upload'
|
|
346
|
+
{...args}
|
|
347
|
+
defaultValue={[
|
|
348
|
+
sample('flow-policy-artifact-for-the-production-edge-cluster-eu-central-1.wasm'),
|
|
349
|
+
]}
|
|
350
|
+
>
|
|
351
|
+
<Rows />
|
|
352
|
+
</FileUpload>
|
|
353
|
+
);
|
|
354
|
+
|
|
355
|
+
/** Nothing uploads on pick: the file travels in the form's `FormData` under `name`, and an empty submit of a required Field shows its error. */
|
|
356
|
+
export const FormSubmission: StoryFn<FileUploadProps> = args => {
|
|
357
|
+
const [submitted, setSubmitted] = useState<string>('');
|
|
358
|
+
const onSubmit = (event: FormEvent<HTMLFormElement>) => {
|
|
359
|
+
event.preventDefault();
|
|
360
|
+
const file = new FormData(event.currentTarget).get('artifact');
|
|
361
|
+
setSubmitted(
|
|
362
|
+
file instanceof File && file.name ? `${file.name} (${formatFileSize(file.size)})` : 'nothing',
|
|
363
|
+
);
|
|
364
|
+
};
|
|
365
|
+
return (
|
|
366
|
+
<form onSubmit={onSubmit} noValidate className='flex flex-col gap-12'>
|
|
367
|
+
<Field required invalid={submitted === 'nothing'}>
|
|
368
|
+
<FieldLabel>
|
|
369
|
+
Artifact
|
|
370
|
+
<FieldIndicator />
|
|
371
|
+
</FieldLabel>
|
|
372
|
+
<FileUpload
|
|
373
|
+
data-testid='file-upload'
|
|
374
|
+
name='artifact'
|
|
375
|
+
{...args}
|
|
376
|
+
onValueChange={() => setSubmitted('')}
|
|
377
|
+
>
|
|
378
|
+
<FileUploadTrigger />
|
|
379
|
+
<Rows />
|
|
380
|
+
</FileUpload>
|
|
381
|
+
{submitted === 'nothing' ? <FieldError>Attach a file</FieldError> : null}
|
|
382
|
+
</Field>
|
|
383
|
+
<Button type='submit' variant='outline' color='neutral' data-testid='submit'>
|
|
384
|
+
Save
|
|
385
|
+
</Button>
|
|
386
|
+
{submitted && submitted !== 'nothing' ? (
|
|
387
|
+
<p className='sb-annotation' data-testid='submitted'>
|
|
388
|
+
Submitted: {submitted}
|
|
389
|
+
</p>
|
|
390
|
+
) : null}
|
|
391
|
+
</form>
|
|
392
|
+
);
|
|
393
|
+
};
|
|
394
|
+
```
|
|
395
|
+
|
|
396
|
+
### FileUpload/lib/index.ts
|
|
397
|
+
|
|
398
|
+
```tsx
|
|
399
|
+
export { toAcceptList, toAcceptString } from './accept';
|
|
400
|
+
export { checkFile, type FileCheckRules } from './checkFile';
|
|
401
|
+
export { formatFileSize } from './formatFileSize';
|
|
402
|
+
export { formatRejection } from './formatRejection';
|
|
403
|
+
export { isSameFile, setInputFiles } from './setInputFiles';
|
|
404
|
+
```
|
|
405
|
+
|
|
406
|
+
### FileUpload/lib/accept.ts
|
|
407
|
+
|
|
408
|
+
```tsx
|
|
409
|
+
/** `'.so, .dylib'` / `['.lua', 'image/png,image/jpeg']` → `['.so', '.dylib']` / `['.lua', 'image/png', 'image/jpeg']`. */
|
|
410
|
+
export const toAcceptList = (accept?: string | string[]): string[] => {
|
|
411
|
+
if (accept === undefined) return [];
|
|
412
|
+
const parts = Array.isArray(accept) ? accept : [accept];
|
|
413
|
+
return parts
|
|
414
|
+
.flatMap(part => part.split(','))
|
|
415
|
+
.map(part => part.trim())
|
|
416
|
+
.filter(Boolean);
|
|
417
|
+
};
|
|
418
|
+
|
|
419
|
+
/** The native / Ark `accept` string, or `undefined` when nothing is restricted. */
|
|
420
|
+
export const toAcceptString = (accept?: string | string[]): string | undefined => {
|
|
421
|
+
const list = toAcceptList(accept);
|
|
422
|
+
return list.length ? list.join(',') : undefined;
|
|
423
|
+
};
|
|
424
|
+
```
|
|
425
|
+
|
|
426
|
+
### FileUpload/lib/checkFile.ts
|
|
427
|
+
|
|
428
|
+
```tsx
|
|
429
|
+
import { isValidFileType } from '@zag-js/file-utils';
|
|
430
|
+
import type { FileUploadErrorCode } from '../types';
|
|
431
|
+
|
|
432
|
+
export interface FileCheckRules {
|
|
433
|
+
acceptList: string[];
|
|
434
|
+
maxFileSize?: number;
|
|
435
|
+
minFileSize?: number;
|
|
436
|
+
validate?: (file: File) => string[] | null;
|
|
437
|
+
}
|
|
438
|
+
|
|
439
|
+
/**
|
|
440
|
+
* The same rules Ark applies on pick/drop (type → size → custom), for the one path Ark
|
|
441
|
+
* cannot validate without side effects: replacing a single file in multiple-file mode
|
|
442
|
+
* (`api.setFiles` re-validates the whole list and would drop the original on failure).
|
|
443
|
+
*/
|
|
444
|
+
export const checkFile = (file: File, rules: FileCheckRules): FileUploadErrorCode[] => {
|
|
445
|
+
const errors: FileUploadErrorCode[] = [];
|
|
446
|
+
// zag's own type check: an empty `file.type` falls back to the MIME type guessed from the
|
|
447
|
+
// extension, and `application/x-moz-file` passes — so Replace agrees with pick and drop.
|
|
448
|
+
const [typeOk] = isValidFileType(
|
|
449
|
+
file,
|
|
450
|
+
rules.acceptList.length ? rules.acceptList.join(',') : undefined,
|
|
451
|
+
);
|
|
452
|
+
if (!typeOk) errors.push('FILE_INVALID_TYPE');
|
|
453
|
+
if (rules.maxFileSize !== undefined && file.size > rules.maxFileSize)
|
|
454
|
+
errors.push('FILE_TOO_LARGE');
|
|
455
|
+
if (rules.minFileSize !== undefined && file.size < rules.minFileSize)
|
|
456
|
+
errors.push('FILE_TOO_SMALL');
|
|
457
|
+
const custom = rules.validate?.(file);
|
|
458
|
+
if (custom) errors.push(...custom);
|
|
459
|
+
return errors;
|
|
460
|
+
};
|
|
461
|
+
```
|
|
462
|
+
|
|
463
|
+
### FileUpload/lib/formatFileSize.ts
|
|
464
|
+
|
|
465
|
+
```tsx
|
|
466
|
+
const UNITS = ['B', 'KB', 'MB', 'GB', 'TB'] as const;
|
|
467
|
+
|
|
468
|
+
/** Binary units, at most one decimal, trailing `.0` dropped: `32 MB`, `40.5 MB`, `512 B`. */
|
|
469
|
+
export const formatFileSize = (bytes: number): string => {
|
|
470
|
+
let value = bytes;
|
|
471
|
+
let unit = 0;
|
|
472
|
+
while (value >= 1024 && unit < UNITS.length - 1) {
|
|
473
|
+
value /= 1024;
|
|
474
|
+
unit += 1;
|
|
475
|
+
}
|
|
476
|
+
let rounded = unit === 0 ? value : Math.round(value * 10) / 10;
|
|
477
|
+
// 1023.96 KB rounds to 1024 KB — promote to the next unit instead.
|
|
478
|
+
if (rounded >= 1024 && unit < UNITS.length - 1) {
|
|
479
|
+
rounded = Math.round((rounded / 1024) * 10) / 10;
|
|
480
|
+
unit += 1;
|
|
481
|
+
}
|
|
482
|
+
return `${rounded} ${UNITS[unit]}`;
|
|
483
|
+
};
|
|
484
|
+
```
|
|
485
|
+
|
|
486
|
+
### FileUpload/lib/formatRejection.ts
|
|
487
|
+
|
|
488
|
+
```tsx
|
|
489
|
+
import type { FileUploadErrorCode, FileUploadLimits } from '../types';
|
|
490
|
+
import { formatFileSize } from './formatFileSize';
|
|
491
|
+
|
|
492
|
+
const describe = (
|
|
493
|
+
code: FileUploadErrorCode,
|
|
494
|
+
limits: FileUploadLimits,
|
|
495
|
+
fileSize?: number,
|
|
496
|
+
): string => {
|
|
497
|
+
switch (code) {
|
|
498
|
+
case 'FILE_INVALID_TYPE':
|
|
499
|
+
return `Not a ${limits.acceptList.join(' / ')} file`;
|
|
500
|
+
case 'FILE_TOO_LARGE':
|
|
501
|
+
return `Too large: ${formatFileSize(fileSize ?? 0)}; the limit is ${formatFileSize(limits.maxFileSize ?? 0)}`;
|
|
502
|
+
case 'FILE_TOO_SMALL':
|
|
503
|
+
return `Too small: ${formatFileSize(fileSize ?? 0)}; the minimum is ${formatFileSize(limits.minFileSize ?? 0)}`;
|
|
504
|
+
case 'TOO_MANY_FILES':
|
|
505
|
+
return `Too many files; the limit is ${limits.maxFiles}`;
|
|
506
|
+
case 'FILE_EXISTS':
|
|
507
|
+
return 'Already added';
|
|
508
|
+
default:
|
|
509
|
+
return code;
|
|
510
|
+
}
|
|
511
|
+
};
|
|
512
|
+
|
|
513
|
+
/** Default message for one (file, error) pair: `{name} — {message}`. */
|
|
514
|
+
export const formatRejection = (
|
|
515
|
+
fileName: string,
|
|
516
|
+
code: FileUploadErrorCode,
|
|
517
|
+
limits: FileUploadLimits,
|
|
518
|
+
fileSize?: number,
|
|
519
|
+
): string => `${fileName} — ${describe(code, limits, fileSize)}`;
|
|
520
|
+
```
|
|
521
|
+
|
|
522
|
+
### FileUpload/lib/setInputFiles.ts
|
|
523
|
+
|
|
524
|
+
```tsx
|
|
525
|
+
/**
|
|
526
|
+
* Writes `files` into a file input the way zag does (`DataTransfer` → `input.files`), so the
|
|
527
|
+
* files go with native form submission. A no-op where `DataTransfer` is missing.
|
|
528
|
+
*/
|
|
529
|
+
export const setInputFiles = (input: HTMLInputElement, files: File[]): void => {
|
|
530
|
+
const win = input.ownerDocument.defaultView;
|
|
531
|
+
if (!win || !('DataTransfer' in win)) return;
|
|
532
|
+
try {
|
|
533
|
+
const transfer = new win.DataTransfer();
|
|
534
|
+
for (const file of files) transfer.items.add(file);
|
|
535
|
+
input.files = transfer.files;
|
|
536
|
+
} catch {
|
|
537
|
+
// Old browsers refuse to construct DataTransfer; the input just keeps what it had.
|
|
538
|
+
}
|
|
539
|
+
};
|
|
540
|
+
|
|
541
|
+
/** zag's `isFileEqual`: name, size and type — not `lastModified` or content. */
|
|
542
|
+
export const isSameFile = (a: File, b: File): boolean =>
|
|
543
|
+
a.name === b.name && a.size === b.size && a.type === b.type;
|
|
544
|
+
```
|