@theoremjs/studio 0.0.0-stage → 0.3.2
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/LICENSE +21 -0
- package/README.md +295 -2
- package/agreement.d.ts +14 -0
- package/agreement.js +80 -0
- package/asks.d.ts +47 -0
- package/asks.js +54 -0
- package/browser-connection.d.ts +49 -0
- package/browser-connection.js +215 -0
- package/browser-engine.d.ts +11 -0
- package/browser-engine.js +11 -0
- package/browser-execution.d.ts +6 -0
- package/browser-execution.js +18 -0
- package/browser-live.d.ts +4 -0
- package/browser-live.js +132 -0
- package/browser-transport.d.ts +33 -0
- package/browser-transport.js +229 -0
- package/browser.d.ts +4 -0
- package/browser.js +4 -0
- package/canonical.d.ts +10 -0
- package/canonical.js +25 -0
- package/compile-workspace.d.ts +28 -0
- package/compile-workspace.js +295 -0
- package/compile.d.ts +65 -0
- package/compile.js +1605 -0
- package/concierge-demo.d.ts +17 -0
- package/concierge-demo.js +1230 -0
- package/conversation-key.d.ts +5 -0
- package/conversation-key.js +10 -0
- package/decision-example-images.d.ts +30 -0
- package/decision-example-images.js +30 -0
- package/deno.json +3 -0
- package/draft.d.ts +407 -0
- package/draft.js +505 -0
- package/editors.d.ts +29 -0
- package/editors.js +51 -0
- package/example-embedding-files.d.ts +11 -0
- package/example-embedding-files.js +20 -0
- package/example.d.ts +36 -0
- package/example.js +357 -0
- package/guardrail-probe.d.ts +100 -0
- package/guardrail-probe.js +722 -0
- package/held-credentials.d.ts +28 -0
- package/held-credentials.js +87 -0
- package/installed.mjs +40 -0
- package/lent-keys.d.ts +122 -0
- package/lent-keys.js +47 -0
- package/line-diff.d.ts +15 -0
- package/line-diff.js +41 -0
- package/live-connection.d.ts +22 -0
- package/live-connection.js +27 -0
- package/live-session-bridge.d.ts +15 -0
- package/live-session-bridge.js +202 -0
- package/map-line.d.ts +19 -0
- package/map-line.js +42 -0
- package/map.d.ts +154 -0
- package/map.js +525 -0
- package/media-accept.d.ts +19 -0
- package/media-accept.js +65 -0
- package/mod.d.ts +39 -0
- package/mod.js +33 -0
- package/origins.d.ts +52 -0
- package/origins.js +165 -0
- package/package.json +85 -4
- package/page/assets/Banner-BISz3nXA.js +2 -0
- package/page/assets/BottomSheet-BwfBDtje.js +1 -0
- package/page/assets/Card-Lp-0P5eL.js +1 -0
- package/page/assets/CardWall-CBRLdDZW.js +1 -0
- package/page/assets/Center-nHS1JSux.js +1 -0
- package/page/assets/CheckboxInput-Cj5pk-KI.js +2 -0
- package/page/assets/CodeBlock-C7XJ4ioE.js +51 -0
- package/page/assets/CollapsibleGroup-N7_SOjbm.js +2 -0
- package/page/assets/ContextMenu-CBu9H-9H.js +2 -0
- package/page/assets/DateInput-BGrQ5tPC.js +1 -0
- package/page/assets/Dialog-DELWQo-v.js +1 -0
- package/page/assets/EmptyState-C8W4JKBZ.js +1 -0
- package/page/assets/HoverCard-D1Y1ltWQ.js +1 -0
- package/page/assets/Icon-JrysT8aU.js +3 -0
- package/page/assets/IconAlertTriangle-BqAEqqdU.js +1 -0
- package/page/assets/IconButton-DlOGzJIX.js +1 -0
- package/page/assets/IconEye-BB5aY-wQ.js +1 -0
- package/page/assets/IconFileText-6zOFKKrF.js +1 -0
- package/page/assets/IconSearch-BTx66a40.js +1 -0
- package/page/assets/IconShield-DDOh7Gr5.js +1 -0
- package/page/assets/ItemSwipeLayer-Ckn4X6h9.js +1 -0
- package/page/assets/PaneState-BvA2tLQg.js +1 -0
- package/page/assets/PaneState-eUzUkNE8.css +1 -0
- package/page/assets/ScrollableArea-Ckugdj1N.js +1 -0
- package/page/assets/Section-DJ97F7QE.js +1 -0
- package/page/assets/SegmentedControlItem-h-aaXzyS.js +1 -0
- package/page/assets/SidePanel-BL32abk8.js +1 -0
- package/page/assets/StackItem-CQviqAfM.js +1 -0
- package/page/assets/Text-bum6zWWx.js +2 -0
- package/page/assets/TimestampHoverCard-DQIG0RZF.js +1 -0
- package/page/assets/ToolResultCharts-CgshSv9Q.js +1 -0
- package/page/assets/Tooltip-BH9xiRMl.js +1 -0
- package/page/assets/TraceInspector-_yZiz05W.js +1 -0
- package/page/assets/TraceOverview-BPO-HIYK.js +57 -0
- package/page/assets/VStack-CkVMcNiK.js +1 -0
- package/page/assets/_virtual_studio-type-sources-ByxqQaOG.js +12936 -0
- package/page/assets/arrive-DvbqpeRS.js +1 -0
- package/page/assets/browser-engine-CYq9DQAM.js +9 -0
- package/page/assets/browser-transport-D-2jDYe7.js +47 -0
- package/page/assets/codicon-DF1abBS2.ttf +0 -0
- package/page/assets/compile-egress-BSxOdX4K.js +23 -0
- package/page/assets/container.stylex-BmOi-8DQ.js +1 -0
- package/page/assets/createReactComponent-CZwsv6DD.js +1 -0
- package/page/assets/decision-example-images-CZGr7YIT.js +1 -0
- package/page/assets/devWarning-DxuplmRl.js +1 -0
- package/page/assets/editor-DjpsE8to.css +1 -0
- package/page/assets/editor.api-Cd3ViPQa.js +908 -0
- package/page/assets/editor.worker-6GY8RhDc.js +1 -0
- package/page/assets/editor.worker-BmdWdrHZ.js +33 -0
- package/page/assets/editors-BJX_S59A.js +1 -0
- package/page/assets/egress-automata-B5ZGE1mT.js +1 -0
- package/page/assets/embedding-space-view-CfQBPDxD.js +140 -0
- package/page/assets/encode-files-Bc3HJyAh.js +1 -0
- package/page/assets/export-agent-C3yyzXH8.js +43 -0
- package/page/assets/figtree-latin-400-normal-BD4aNku5.woff +0 -0
- package/page/assets/figtree-latin-400-normal-g7Dtegnw.woff2 +0 -0
- package/page/assets/figtree-latin-500-normal-BWnGEVsr.woff2 +0 -0
- package/page/assets/figtree-latin-500-normal-B_yy1phn.woff +0 -0
- package/page/assets/figtree-latin-600-normal-BM_oTo4n.woff +0 -0
- package/page/assets/figtree-latin-600-normal-Cv_xCTDl.woff2 +0 -0
- package/page/assets/figtree-latin-700-normal-BCCt2T1q.woff +0 -0
- package/page/assets/figtree-latin-700-normal-th6qEP7c.woff2 +0 -0
- package/page/assets/focusOutline.stylex-BT0kfa4t.js +1 -0
- package/page/assets/focusableSelector-DXZeMU85.js +1 -0
- package/page/assets/groupStyles-C7Ter7zC.js +1 -0
- package/page/assets/guardrail-tester-Gut5xK4a.js +9 -0
- package/page/assets/host-patterns-C9RMP16Q.js +1 -0
- package/page/assets/index-CvvmFKgS.js +105 -0
- package/page/assets/index-DOaHlqBo.css +1 -0
- package/page/assets/isRtlElement-BG33-k_H.js +1 -0
- package/page/assets/labels-provider-4TIWDvsE.js +3 -0
- package/page/assets/lent-keys-C32ems-I.js +1 -0
- package/page/assets/live-ingress-lDUGPwth.js +1 -0
- package/page/assets/live-messages-CnkL4GWi.js +1 -0
- package/page/assets/mergeProps-ptS-gIMz.js +1 -0
- package/page/assets/padding.stylex-B76907Zf.js +1 -0
- package/page/assets/preload-helper-DpV6A1kQ.js +1 -0
- package/page/assets/reader-BOCCYaRp.js +7 -0
- package/page/assets/register-CDgivxvX.js +2 -0
- package/page/assets/rolldown-runtime-hePW80VL.js +1 -0
- package/page/assets/schemas-BQ9Jydzb.js +56 -0
- package/page/assets/shaped-data-BcarWqd5.js +16 -0
- package/page/assets/sharedResizeObserver-4U9Xq5Oq.js +1 -0
- package/page/assets/stub-DhdcU_Ew.js +471 -0
- package/page/assets/studio-code-pane-C_SAbcOa.js +8 -0
- package/page/assets/studio-console-DZwlEsvr.js +3 -0
- package/page/assets/studio-decision-B0FnCAXA.js +1 -0
- package/page/assets/studio-embedding-CmA51HVo.js +2 -0
- package/page/assets/studio-host-console-By7hqu2l.js +2 -0
- package/page/assets/studio-live-BrcVQcyV.js +1 -0
- package/page/assets/studio-map-B_xSia-z.js +1 -0
- package/page/assets/studio-map-Bb06Tw1F.css +1 -0
- package/page/assets/studio-monaco-CbKf90i6.css +1 -0
- package/page/assets/studio-monaco-xfyfezQS.js +34 -0
- package/page/assets/studio-ts.worker-B-EXG4Sv.js +67741 -0
- package/page/assets/studio-ts.worker-BXtW3z-O.js +1 -0
- package/page/assets/studio-type-checker-BOvxudki.js +23 -0
- package/page/assets/themeProps-3IqahpCr.js +1 -0
- package/page/assets/tokens.stylex-DkHf0P9C.js +1 -0
- package/page/assets/tool-schema-idaOe2nI.js +18 -0
- package/page/assets/trace-patterns-DnYJa0nI.js +1 -0
- package/page/assets/trace-record-C3zNksA_.js +1 -0
- package/page/assets/trace-schema-9CdEyG6Q.js +1 -0
- package/page/assets/tree-DqyAMsbI.js +3 -0
- package/page/assets/turn-client-Du3Um3Mg.js +2 -0
- package/page/assets/types-BhfXQCLx.js +1 -0
- package/page/assets/typescript-20GgZ8PJ.js +1 -0
- package/page/assets/use-one-call-Hcs8YBp1.js +1 -0
- package/page/assets/useAdaptivePresentation-BzmPCddb.js +1 -0
- package/page/assets/useClipboard-BgGRxRMJ.js +1 -0
- package/page/assets/useContainerReveal-BFy8N_QU.js +1 -0
- package/page/assets/useDevWarning-Z9SoixOP.js +1 -0
- package/page/assets/useLayerDismissal-B_G7IWpC.js +1 -0
- package/page/assets/useMediaQuery-BCT0NUeZ.js +1 -0
- package/page/assets/useScrollLock-Dyf6PHJt.js +1 -0
- package/page/assets/useScrollableArea-0NzdiBCq.js +1 -0
- package/page/assets/useTooltip-CJM_xhLB.js +1 -0
- package/page/assets/workspace-DZALqEDX.js +1 -0
- package/page/assets/zip-DTcEfps6.js +1 -0
- package/page/index.html +90 -0
- package/page.mjs +49 -0
- package/people.d.ts +87 -0
- package/people.js +110 -0
- package/policy.d.ts +43 -0
- package/policy.js +102 -0
- package/ports.d.mts +32 -0
- package/ports.mjs +85 -0
- package/probe-battery.d.ts +13 -0
- package/probe-battery.js +404 -0
- package/providers.d.ts +149 -0
- package/providers.js +306 -0
- package/read-source.d.ts +48 -0
- package/read-source.js +1301 -0
- package/read-steps.d.ts +23 -0
- package/read-steps.js +2 -0
- package/reader.d.ts +11 -0
- package/reader.js +11 -0
- package/registrations.d.ts +83 -0
- package/registrations.js +1 -0
- package/requirements.d.ts +22 -0
- package/requirements.js +38 -0
- package/run-payload-core.d.ts +28 -0
- package/run-payload-core.js +123 -0
- package/run-payload.d.ts +32 -0
- package/run-payload.js +26 -0
- package/runtime-scope.d.ts +84 -0
- package/runtime-scope.js +308 -0
- package/runtime.d.ts +84 -0
- package/runtime.js +387 -0
- package/section-notes.d.ts +33 -0
- package/section-notes.js +38 -0
- package/serve-page.mjs +96 -0
- package/server/draft-decide.d.ts +72 -0
- package/server/draft-decide.js +111 -0
- package/server/draft-embedding.d.ts +3 -0
- package/server/draft-embedding.js +35 -0
- package/server/draft-handler.d.ts +82 -0
- package/server/draft-handler.js +213 -0
- package/server/draft-probe.d.ts +14 -0
- package/server/draft-probe.js +61 -0
- package/server/draft-replies.d.ts +22 -0
- package/server/draft-replies.js +46 -0
- package/server/edited-session.d.ts +28 -0
- package/server/edited-session.js +83 -0
- package/server/edits.d.ts +38 -0
- package/server/edits.js +195 -0
- package/server/handler.d.ts +133 -0
- package/server/handler.js +598 -0
- package/server/lent-draft.d.ts +19 -0
- package/server/lent-draft.js +23 -0
- package/server/live.d.ts +15 -0
- package/server/live.js +96 -0
- package/server/open-editor.d.ts +63 -0
- package/server/open-editor.js +115 -0
- package/server/origins.d.ts +18 -0
- package/server/origins.js +330 -0
- package/server/project-source.d.ts +208 -0
- package/server/project-source.js +1042 -0
- package/server/project.d.ts +22 -0
- package/server/project.js +56 -0
- package/server/run-traces.d.ts +20 -0
- package/server/run-traces.js +96 -0
- package/server/save-new.d.ts +29 -0
- package/server/save-new.js +514 -0
- package/server/save-plan.d.ts +46 -0
- package/server/save-plan.js +1134 -0
- package/server/save-remove.d.ts +21 -0
- package/server/save-remove.js +528 -0
- package/server/save-session.d.ts +96 -0
- package/server/save-session.js +418 -0
- package/server/save-wire.d.ts +235 -0
- package/server/save-wire.js +8 -0
- package/server/save.d.ts +52 -0
- package/server/save.js +209 -0
- package/server/serve.d.ts +23 -0
- package/server/serve.js +413 -0
- package/server/test-connection.d.ts +17 -0
- package/server/test-connection.js +362 -0
- package/server/test-key.d.ts +2 -0
- package/server/test-key.js +83 -0
- package/server/watch.d.ts +28 -0
- package/server/watch.js +93 -0
- package/server/zod-edit.d.ts +74 -0
- package/server/zod-edit.js +558 -0
- package/server.d.ts +8 -0
- package/server.js +8 -0
- package/setups.mjs +170 -0
- package/shared-carry.d.ts +114 -0
- package/shared-carry.js +523 -0
- package/shared-settings.d.ts +34 -0
- package/shared-settings.js +70 -0
- package/source.d.ts +75 -0
- package/source.js +414 -0
- package/start.mjs +169 -0
- package/stream-lines.d.ts +9 -0
- package/stream-lines.js +27 -0
- package/stub.d.ts +6 -0
- package/stub.js +33 -0
- package/surface.d.ts +53 -0
- package/surface.js +631 -0
- package/system-markup.d.ts +20 -0
- package/system-markup.js +51 -0
- package/tool-schema.d.ts +23 -0
- package/tool-schema.js +69 -0
- package/tools.d.ts +16 -0
- package/tools.js +91 -0
- package/traces.d.ts +24 -0
- package/traces.js +29 -0
- package/transport.d.ts +57 -0
- package/transport.js +187 -0
- package/tree.d.ts +32 -0
- package/tree.js +83 -0
- package/types.d.ts +62 -0
- package/types.js +6 -0
- package/ui/acting-as-button.d.ts +2 -0
- package/ui/acting-as-button.js +16 -0
- package/ui/add-provider.d.ts +13 -0
- package/ui/add-provider.js +20 -0
- package/ui/boot-mark.css +53 -0
- package/ui/boot-mark.d.ts +19 -0
- package/ui/boot-mark.js +128 -0
- package/ui/boot-paint.d.ts +8 -0
- package/ui/boot-paint.js +8 -0
- package/ui/brand-icons.d.ts +57 -0
- package/ui/brand-icons.js +148 -0
- package/ui/built/theme.css +830 -0
- package/ui/built/theme.css.d.ts +9 -0
- package/ui/built/theorem-studio.d.ts +13 -0
- package/ui/built/theorem-studio.js +705 -0
- package/ui/built/theorem-studio.variants.d.ts +28 -0
- package/ui/code/monaco-contributions.d.ts +45 -0
- package/ui/code/studio-code.d.ts +7 -0
- package/ui/code/studio-code.js +253 -0
- package/ui/code/studio-monaco.d.ts +44 -0
- package/ui/code/studio-monaco.js +48 -0
- package/ui/code/studio-ts.worker.d.ts +1 -0
- package/ui/code/studio-ts.worker.js +16 -0
- package/ui/code/studio-type-checker.d.ts +12 -0
- package/ui/code/studio-type-checker.js +308 -0
- package/ui/code/studio-type-sources.d.ts +26 -0
- package/ui/confirm-write.d.ts +12 -0
- package/ui/confirm-write.js +45 -0
- package/ui/diff-block.d.ts +21 -0
- package/ui/diff-block.js +17 -0
- package/ui/figtree.css +59 -0
- package/ui/file-place.d.ts +4 -0
- package/ui/file-place.js +26 -0
- package/ui/guardrail-tester.d.ts +18 -0
- package/ui/guardrail-tester.js +248 -0
- package/ui/inspector-context.d.ts +119 -0
- package/ui/inspector-context.js +84 -0
- package/ui/inspector.d.ts +247 -0
- package/ui/inspector.js +284 -0
- package/ui/lib/acting-as.d.ts +25 -0
- package/ui/lib/acting-as.js +90 -0
- package/ui/lib/boot-sequence.d.ts +32 -0
- package/ui/lib/boot-sequence.js +57 -0
- package/ui/lib/export-agent.d.ts +11 -0
- package/ui/lib/export-agent.js +335 -0
- package/ui/lib/facet-icons.d.ts +20 -0
- package/ui/lib/facet-icons.js +21 -0
- package/ui/lib/panel-motion.d.ts +8 -0
- package/ui/lib/panel-motion.js +74 -0
- package/ui/lib/project-address.d.ts +14 -0
- package/ui/lib/project-address.js +24 -0
- package/ui/lib/project-starting.d.ts +13 -0
- package/ui/lib/project-starting.js +30 -0
- package/ui/lib/project-traces.d.ts +17 -0
- package/ui/lib/project-traces.js +54 -0
- package/ui/lib/read-map.d.ts +30 -0
- package/ui/lib/read-map.js +173 -0
- package/ui/lib/read-progress.d.ts +14 -0
- package/ui/lib/read-progress.js +12 -0
- package/ui/lib/refusal-lines.d.ts +3 -0
- package/ui/lib/refusal-lines.js +8 -0
- package/ui/lib/studio-activity.d.ts +5 -0
- package/ui/lib/studio-activity.js +17 -0
- package/ui/lib/studio-console.d.ts +27 -0
- package/ui/lib/studio-console.js +9 -0
- package/ui/lib/studio-conversation.d.ts +20 -0
- package/ui/lib/studio-conversation.js +130 -0
- package/ui/lib/studio-examples.d.ts +31 -0
- package/ui/lib/studio-examples.js +25 -0
- package/ui/lib/studio-labels.d.ts +6 -0
- package/ui/lib/studio-labels.js +13 -0
- package/ui/lib/studio-map-kept.d.ts +17 -0
- package/ui/lib/studio-map-kept.js +48 -0
- package/ui/lib/studio-open.d.ts +22 -0
- package/ui/lib/studio-open.js +54 -0
- package/ui/lib/studio-page.d.ts +33 -0
- package/ui/lib/studio-page.js +121 -0
- package/ui/lib/studio-prefs.d.ts +26 -0
- package/ui/lib/studio-prefs.js +87 -0
- package/ui/lib/studio-project.d.ts +106 -0
- package/ui/lib/studio-project.js +177 -0
- package/ui/lib/studio-restore.d.ts +49 -0
- package/ui/lib/studio-restore.js +251 -0
- package/ui/lib/studio-run-open.d.ts +15 -0
- package/ui/lib/studio-run-open.js +16 -0
- package/ui/lib/studio-session.d.ts +34 -0
- package/ui/lib/studio-session.js +17 -0
- package/ui/lib/studio-settings.d.ts +15 -0
- package/ui/lib/studio-settings.js +48 -0
- package/ui/lib/studio-store.d.ts +64 -0
- package/ui/lib/studio-store.js +391 -0
- package/ui/lib/studio-watch.d.ts +12 -0
- package/ui/lib/studio-watch.js +27 -0
- package/ui/lib/tab-fills.d.ts +6 -0
- package/ui/lib/tab-fills.js +14 -0
- package/ui/lib/tool-credentials.d.ts +3 -0
- package/ui/lib/tool-credentials.js +23 -0
- package/ui/lib/tool-probe.d.ts +19 -0
- package/ui/lib/tool-probe.js +104 -0
- package/ui/lib/type-icons.d.ts +35 -0
- package/ui/lib/type-icons.js +38 -0
- package/ui/lib/when-idle.d.ts +5 -0
- package/ui/lib/when-idle.js +14 -0
- package/ui/lib/zip.d.ts +5 -0
- package/ui/lib/zip.js +8 -0
- package/ui/map-token.css +11 -0
- package/ui/map-token.d.ts +17 -0
- package/ui/map-token.js +29 -0
- package/ui/mcp-icon.d.ts +6 -0
- package/ui/mcp-icon.js +8 -0
- package/ui/motion.css +113 -0
- package/ui/pan.d.ts +32 -0
- package/ui/pan.js +90 -0
- package/ui/profile-editor.d.ts +33 -0
- package/ui/profile-editor.js +2638 -0
- package/ui/provider-editor.d.ts +15 -0
- package/ui/provider-editor.js +92 -0
- package/ui/read-map.css +48 -0
- package/ui/read-map.d.ts +7 -0
- package/ui/read-map.js +163 -0
- package/ui/refusal-detail.d.ts +4 -0
- package/ui/refusal-detail.js +21 -0
- package/ui/shared-change.d.ts +9 -0
- package/ui/shared-change.js +28 -0
- package/ui/shell-motion.css +121 -0
- package/ui/shell-motion.d.ts +73 -0
- package/ui/shell-motion.js +194 -0
- package/ui/studio-code-pane.d.ts +19 -0
- package/ui/studio-code-pane.js +44 -0
- package/ui/studio-compare.d.ts +80 -0
- package/ui/studio-compare.js +326 -0
- package/ui/studio-conflicts.d.ts +17 -0
- package/ui/studio-conflicts.js +87 -0
- package/ui/studio-connection.d.ts +64 -0
- package/ui/studio-connection.js +286 -0
- package/ui/studio-decision.d.ts +6 -0
- package/ui/studio-decision.js +49 -0
- package/ui/studio-embedding.d.ts +6 -0
- package/ui/studio-embedding.js +30 -0
- package/ui/studio-host-console.d.ts +6 -0
- package/ui/studio-host-console.js +17 -0
- package/ui/studio-host.d.ts +73 -0
- package/ui/studio-host.js +12 -0
- package/ui/studio-live.d.ts +17 -0
- package/ui/studio-live.js +26 -0
- package/ui/studio-map.css +273 -0
- package/ui/studio-map.d.ts +17 -0
- package/ui/studio-map.js +397 -0
- package/ui/studio-nav.d.ts +24 -0
- package/ui/studio-nav.js +17 -0
- package/ui/studio-no-project.d.ts +5 -0
- package/ui/studio-no-project.js +9 -0
- package/ui/studio-run.css +76 -0
- package/ui/studio-run.d.ts +14 -0
- package/ui/studio-run.js +119 -0
- package/ui/studio-runner.d.ts +45 -0
- package/ui/studio-runner.js +187 -0
- package/ui/studio-save.d.ts +49 -0
- package/ui/studio-save.js +307 -0
- package/ui/studio-screen.d.ts +61 -0
- package/ui/studio-screen.js +2078 -0
- package/ui/studio-settings.d.ts +31 -0
- package/ui/studio-settings.js +288 -0
- package/ui/studio-shell.css +27 -0
- package/ui/studio-shell.d.ts +43 -0
- package/ui/studio-shell.js +87 -0
- package/ui/studio-theme.d.ts +7 -0
- package/ui/studio-theme.js +94 -0
- package/ui/studio.css +427 -0
- package/ui/theorem-mark.css +84 -0
- package/ui/theorem-mark.d.ts +22 -0
- package/ui/theorem-mark.js +21 -0
- package/vite.d.mts +30 -0
- package/vite.mjs +277 -0
- package/workspace.d.ts +230 -0
- package/workspace.js +1054 -0
package/mod.js
ADDED
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
export { writeAsk, writeAskLine } from "./asks.js";
|
|
2
|
+
export { KNOWN_GEMINI_EMBEDDING_MODELS, KNOWN_OPENROUTER_EMBEDDING_MODELS, } from "./browser-connection.js";
|
|
3
|
+
export { compileStudio, credentialHeaderProblem, credentialUrlProblem, } from "./compile.js";
|
|
4
|
+
export { compileWorkspace, workspaceRunAgent, } from "./compile-workspace.js";
|
|
5
|
+
export { DEMO_ALLOWED_HOSTS, DEMO_CONCIERGE_SYSTEM, DEMO_HTTP_SAMPLE_INPUT, demoHttpSampleInput, demoInputsSpec, demoToolSpecs, } from "./concierge-demo.js";
|
|
6
|
+
export { agentToolTarget, COMPACTION_DRAFT_DEFAULTS, createBlankDraft, defaultModelBinding, defaultToolSpec, draftAllows, draftFacets, draftKey, EXAMPLE_DECISION_STATE, EXAMPLE_EMBEDDING_QUERY, EXAMPLE_EMBEDDING_TEXT, EXAMPLE_SPAN_DECISION_STATE, exampleDecisionDraft, excludeFacet, INLINE_LABELS, includableFacets, includeFacet, newCriteria, newDecisionImage, newDecisionQuestion, newModelBinding, newOwnDetector, newPattern, newToolSpec, plantsCanary, removeModelBinding, STUDIO_PROFILE_TYPES, setProfileType, takesContinueInstruction, updateModelBinding, } from "./draft.js";
|
|
7
|
+
export { addArchitectExample, createArchitectWorkspace, createConsoleExampleDraft, createDecisionExampleDraft, createExampleDraft, createGeminiEmbeddingExampleDraft, createLiveExampleDraft, createNarratorExampleDraft, createSpanExampleDraft, DECISION_EXAMPLE_AGENT_ID, DECISION_EXAMPLE_STATE, decisionExampleAssets, } from "./example.js";
|
|
8
|
+
export { EXAMPLE_EMBEDDING_FILES } from "./example-embedding-files.js";
|
|
9
|
+
export { PROBE_BOUNDARIES, PROBE_BOUNDARY_NOTES, PROBE_STATUSES, PROBE_TEXT_LIMIT, probeDraft, probeRefusal, runGuardrailProbe, runGuardrailProbes, } from "./guardrail-probe.js";
|
|
10
|
+
export { unheldProblem } from "./held-credentials.js";
|
|
11
|
+
export { lentCompression, ON_OWN_KEYS, studioNetworkNote, studioTaintNote, } from "./lent-keys.js";
|
|
12
|
+
export { lineDiff } from "./line-diff.js";
|
|
13
|
+
export { studioLiveConnection, studioPageTools } from "./live-connection.js";
|
|
14
|
+
export { mapFamily, mapFound, mapLayout, mapLinkEnds, mapLinkWords, mapNeighbours, mapNoteLines, workspaceMap, } from "./map.js";
|
|
15
|
+
export { acceptSections, expandAccept, nextAccept } from "./media-accept.js";
|
|
16
|
+
export { nodeOrigins, openOutcome, originLabel, originPlace, originShortLabel, originWay, rowOrigin, } from "./origins.js";
|
|
17
|
+
export { firstServed, isGoogleRoute, isOpenRouterRoute, isProviderBuiltinId, modelBindingViolation, STUDIO_TRACE_DESTINATION, startingBinding, studioRunsProvider, } from "./policy.js";
|
|
18
|
+
export { PROBE_BATTERY } from "./probe-battery.js";
|
|
19
|
+
export { connectionFields, definitionFactory, definitionOf, definitionOfFactory, kernelDefinition, kernelDefinitions, LOCAL_PROVIDER_ID, localProviderAddress, modelRoute, modelSlots, onStudioLocal, optionAt, protocolOptionFields, providerProblems, registerStudioProvider, STUDIO_PROVIDERS, servedProtocols, servesProfileType, takesKey, withOption, } from "./providers.js";
|
|
20
|
+
export { readProviderSource, readStudioSource, } from "./read-source.js";
|
|
21
|
+
export { bindingSlots, defaultEffortRequired, defaultModelRequired, inputLimitsRequired, keySlotUnset, } from "./requirements.js";
|
|
22
|
+
export { clearStudioRunPayload, createStudioRunId, keptStudioRunIds, loadStudioRunPayload, readStudioRunIdFromUrl, STUDIO_RUN_INDEX_KEY, STUDIO_RUN_PAYLOAD_CAP, STUDIO_RUN_PAYLOAD_KEY, STUDIO_RUN_PAYLOAD_KEY_PREFIX, saveStudioRunPayload, studioRunPayloadKey, upsertStudioRunIndex, } from "./run-payload.js";
|
|
23
|
+
export { sectionNote } from "./section-notes.js";
|
|
24
|
+
export { askParts, reachesOthers, sharedAsk, sharedSnapshot, shortPlace, toolReach, toolSnapshot, withSharedCarry, withToolCarry, } from "./shared-carry.js";
|
|
25
|
+
export { sharedAt, sharedEntries, sharedNodeId, sharedOpens, } from "./shared-settings.js";
|
|
26
|
+
export { agentModulePath, importSpecifier, providerSource, studioSource, workspaceSource, } from "./source.js";
|
|
27
|
+
export { sampleToolInput, stubOutputFromSchema } from "./stub.js";
|
|
28
|
+
export { DEFAULT_TOOL_INPUT_SCHEMA, DEFAULT_TOOL_OUTPUT_SCHEMA, parseJsonSchema, sampleFromJsonSchema, zodFromJsonSchema, } from "./tool-schema.js";
|
|
29
|
+
export { registerStudioTools } from "./tools.js";
|
|
30
|
+
export { createStudioTraceRouter, STUDIO_RUN_METADATA_KEY, } from "./traces.js";
|
|
31
|
+
export { clearStaleStudioRuns, createStudioDecisionTransport, createStudioEmbeddingTransport, createStudioHostTransport, createStudioTransport, studioInterface, studioRunDefines, } from "./transport.js";
|
|
32
|
+
export { modelBindingNodeId, providerIdOf, providerNodeId, studioNodeRef, studioTree, toolSpecKeyOf, toolSpecNodeId, } from "./tree.js";
|
|
33
|
+
export { addAgent, addProvider, agentDraft, agentNodeId, atStart, createBlankWorkspace, duplicateAgent, editedSince, filesPrint, libraryDraft, mergedWithFiles, modelSharers, newProvider, providersAtStart, providerUse, rebased, removeAgent, removeLibraryTool, removeProvider, renameProvider, reopened, resetAgent, resetAll, resetLibraryTool, resetProvider, STUDIO_WORKSPACE_VERSION, scopedNodeId, setToolAllowed, startedHere, withAgentDraft, withFilesChosen, withLibraryDraft, withProvider, workspaceFromDraft, workspaceNodeRef, workspaceTree, } from "./workspace.js";
|
package/origins.d.ts
ADDED
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The settings a project's files set in code, as the studio's editor reads
|
|
3
|
+
* them: which rows of the open node show a value the studio does not change,
|
|
4
|
+
* and where the file sets it.
|
|
5
|
+
*
|
|
6
|
+
* @module
|
|
7
|
+
*/
|
|
8
|
+
import type { OpenAnswer, ProjectOrigins, SettingOrigin } from './server/save-wire.ts';
|
|
9
|
+
import { type StudioWorkspace } from './workspace.ts';
|
|
10
|
+
/** The open node's settings that are set in code. */
|
|
11
|
+
export interface NodeOrigins {
|
|
12
|
+
/** Those of the profile or tool the node belongs to. */
|
|
13
|
+
origins: readonly SettingOrigin[];
|
|
14
|
+
/** What a `*` in a row's path stands for here, by the path up to it: `models.*` is the open model's id. */
|
|
15
|
+
stars: Record<string, string>;
|
|
16
|
+
/** The node edits a tool: its rows name the tool's own settings. */
|
|
17
|
+
tool: boolean;
|
|
18
|
+
/** Set when one place in the files sets the whole node, so the editor says it once, over the rows. */
|
|
19
|
+
section?: SettingOrigin;
|
|
20
|
+
/**
|
|
21
|
+
* Set when the files spread other code into the node's own settings: the rows the files do not
|
|
22
|
+
* write after it are the spread's, so the editor says it once, over the rows.
|
|
23
|
+
*/
|
|
24
|
+
partly?: SettingOrigin;
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* A row's catalog path as the keys the files hold: each `*` the node names is filled in, and the
|
|
28
|
+
* path stops before one it does not. Undefined for a row no file sets.
|
|
29
|
+
*/
|
|
30
|
+
export declare function settingPath(scope: Pick<NodeOrigins, 'stars' | 'tool'>, catalogPath: string): string[] | undefined;
|
|
31
|
+
/**
|
|
32
|
+
* The origin that sets the value at `path`: the nearest one at or above it, or one that sets an
|
|
33
|
+
* entry of the list at `path`, since a row edits its list as a whole.
|
|
34
|
+
*/
|
|
35
|
+
export declare function originAt(origins: readonly SettingOrigin[], path: readonly string[]): SettingOrigin | undefined;
|
|
36
|
+
/** The origin of the row at a catalog path, when the files set it in code. */
|
|
37
|
+
export declare function rowOrigin(scope: NodeOrigins | undefined, catalogPath: string): SettingOrigin | undefined;
|
|
38
|
+
/**
|
|
39
|
+
* The settings set in code for the node `nodeId` opens. Undefined when the project's files do not
|
|
40
|
+
* hold the node's profile, tool or provider: one added in the studio.
|
|
41
|
+
*/
|
|
42
|
+
export declare function nodeOrigins(workspace: StudioWorkspace, project: ProjectOrigins, nodeId: string): NodeOrigins | undefined;
|
|
43
|
+
/** Where an origin is, as `file:line`. */
|
|
44
|
+
export declare function originPlace(origin: SettingOrigin): string | undefined;
|
|
45
|
+
/** The whole of what sets a value: what a hover and a banner say. */
|
|
46
|
+
export declare function originLabel(origin: SettingOrigin): string;
|
|
47
|
+
/** What a row says of its origin, at a glance: `Set by bonsaiGoogle`, `Set in code · bonsaiInputs()`. */
|
|
48
|
+
export declare function originShortLabel(origin: SettingOrigin): string;
|
|
49
|
+
/** What the builder does about an origin with no place to open. */
|
|
50
|
+
export declare function originWay(origin: SettingOrigin): string;
|
|
51
|
+
/** What the page says once it asked for a place in the builder's editor. */
|
|
52
|
+
export declare function openOutcome(answer: OpenAnswer, place: string): string;
|
package/origins.js
ADDED
|
@@ -0,0 +1,165 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The settings a project's files set in code, as the studio's editor reads
|
|
3
|
+
* them: which rows of the open node show a value the studio does not change,
|
|
4
|
+
* and where the file sets it.
|
|
5
|
+
*
|
|
6
|
+
* @module
|
|
7
|
+
*/
|
|
8
|
+
import { PROFILE_GRAPH } from '@theoremjs/agents/schema';
|
|
9
|
+
import { editorLabel } from "./editors.js";
|
|
10
|
+
import { workspaceNodeRef } from "./workspace.js";
|
|
11
|
+
/** Rows under these are the studio's own, and no file sets them. */
|
|
12
|
+
const STUDIO_ONLY = new Set(['studio', 'local']);
|
|
13
|
+
const isIndex = (key) => key !== undefined && /^\d+$/.test(key);
|
|
14
|
+
const startsWith = (path, prefix) => prefix.length <= path.length && prefix.every((key, index) => path[index] === key);
|
|
15
|
+
/**
|
|
16
|
+
* A row's catalog path as the keys the files hold: each `*` the node names is filled in, and the
|
|
17
|
+
* path stops before one it does not. Undefined for a row no file sets.
|
|
18
|
+
*/
|
|
19
|
+
export function settingPath(scope, catalogPath) {
|
|
20
|
+
const keys = catalogPath.replace(scope.tool ? /^registerTool\./ : /^profile\./, '').split('.');
|
|
21
|
+
if (STUDIO_ONLY.has(keys[0] ?? ''))
|
|
22
|
+
return undefined;
|
|
23
|
+
const path = [];
|
|
24
|
+
for (const [index, key] of keys.entries()) {
|
|
25
|
+
if (key !== '*') {
|
|
26
|
+
path.push(key);
|
|
27
|
+
continue;
|
|
28
|
+
}
|
|
29
|
+
const named = scope.stars[keys.slice(0, index + 1).join('.')];
|
|
30
|
+
if (named === undefined)
|
|
31
|
+
break;
|
|
32
|
+
path.push(named);
|
|
33
|
+
}
|
|
34
|
+
return path;
|
|
35
|
+
}
|
|
36
|
+
/** Whether an origin at or above `path` keeps the studio from writing it. */
|
|
37
|
+
function holds(origin, path) {
|
|
38
|
+
if (!startsWith(path, origin.path))
|
|
39
|
+
return false;
|
|
40
|
+
if (origin.kind !== 'spread')
|
|
41
|
+
return true;
|
|
42
|
+
// Past a spread, the studio writes the keys the file writes after it.
|
|
43
|
+
const key = path[origin.path.length];
|
|
44
|
+
return key === undefined || !origin.written?.includes(key);
|
|
45
|
+
}
|
|
46
|
+
/**
|
|
47
|
+
* The origin that sets the value at `path`: the nearest one at or above it, or one that sets an
|
|
48
|
+
* entry of the list at `path`, since a row edits its list as a whole.
|
|
49
|
+
*/
|
|
50
|
+
export function originAt(origins, path) {
|
|
51
|
+
const above = origins
|
|
52
|
+
.filter((origin) => holds(origin, path))
|
|
53
|
+
.sort((a, b) => b.path.length - a.path.length)[0];
|
|
54
|
+
if (above)
|
|
55
|
+
return above;
|
|
56
|
+
return origins.find((origin) => startsWith(origin.path, path) && isIndex(origin.path[path.length]));
|
|
57
|
+
}
|
|
58
|
+
/** The origin of the row at a catalog path, when the files set it in code. */
|
|
59
|
+
export function rowOrigin(scope, catalogPath) {
|
|
60
|
+
const path = scope && settingPath(scope, catalogPath);
|
|
61
|
+
return path && scope ? originAt(scope.origins, path) : undefined;
|
|
62
|
+
}
|
|
63
|
+
/** The id or name the project's files know a started agent, model, or tool by. */
|
|
64
|
+
function started(workspace, agentKey) {
|
|
65
|
+
const agent = workspace.starts.agents[agentKey];
|
|
66
|
+
return {
|
|
67
|
+
id: agent?.identity.agentId.trim(),
|
|
68
|
+
model: (key) => agent?.modelBindings.find((binding) => binding.key === key)?.modelId.trim(),
|
|
69
|
+
};
|
|
70
|
+
}
|
|
71
|
+
/**
|
|
72
|
+
* The settings set in code for the node `nodeId` opens. Undefined when the project's files do not
|
|
73
|
+
* hold the node's profile, tool or provider: one added in the studio.
|
|
74
|
+
*/
|
|
75
|
+
export function nodeOrigins(workspace, project, nodeId) {
|
|
76
|
+
const node = workspaceNodeRef(workspace, nodeId);
|
|
77
|
+
if (!node)
|
|
78
|
+
return undefined;
|
|
79
|
+
if ('tool' in node) {
|
|
80
|
+
const name = workspace.starts.tools[node.tool]?.toolName;
|
|
81
|
+
const origins = name === undefined ? undefined : project.tools[name];
|
|
82
|
+
return origins && withSection({ origins, stars: {}, tool: true }, []);
|
|
83
|
+
}
|
|
84
|
+
if ('provider' in node) {
|
|
85
|
+
const origins = project.providers[node.provider];
|
|
86
|
+
return origins && withSection({ origins, stars: {}, tool: false }, []);
|
|
87
|
+
}
|
|
88
|
+
const start = started(workspace, node.agent);
|
|
89
|
+
const origins = start.id === undefined ? undefined : project.profiles[start.id];
|
|
90
|
+
if (!origins)
|
|
91
|
+
return undefined;
|
|
92
|
+
const stars = {};
|
|
93
|
+
if (node.ref.facet === 'modelBinding') {
|
|
94
|
+
const model = start.model(node.ref.key);
|
|
95
|
+
if (model)
|
|
96
|
+
stars['models.*'] = model;
|
|
97
|
+
}
|
|
98
|
+
const scope = { origins, stars, tool: false };
|
|
99
|
+
const facet = PROFILE_GRAPH.find((each) => each.id === node.ref.facet);
|
|
100
|
+
// A section whose `*` names nothing in the files (a model added in the studio) is read at the key above it.
|
|
101
|
+
return withSection(scope, (facet && settingPath(scope, facet.profilePath)) ?? []);
|
|
102
|
+
}
|
|
103
|
+
/**
|
|
104
|
+
* `scope` with the one origin that sets the whole section at `path`: at or above the section's own
|
|
105
|
+
* key. A spread in the section itself is not one, since the rows it leaves written stay open.
|
|
106
|
+
*/
|
|
107
|
+
function withSection(scope, path) {
|
|
108
|
+
const own = (origin) => origin.kind === 'spread' && origin.path.length === path.length;
|
|
109
|
+
const above = scope.origins.filter((origin) => holds(origin, path));
|
|
110
|
+
const section = above
|
|
111
|
+
.filter((origin) => !own(origin))
|
|
112
|
+
.sort((a, b) => b.path.length - a.path.length)[0];
|
|
113
|
+
if (section)
|
|
114
|
+
return { ...scope, section };
|
|
115
|
+
const partly = above.find(own);
|
|
116
|
+
return partly ? { ...scope, partly } : scope;
|
|
117
|
+
}
|
|
118
|
+
/** Where an origin is, as `file:line`. */
|
|
119
|
+
export function originPlace(origin) {
|
|
120
|
+
if (!origin.file)
|
|
121
|
+
return undefined;
|
|
122
|
+
return origin.line ? `${origin.file}:${String(origin.line)}` : origin.file;
|
|
123
|
+
}
|
|
124
|
+
/** The whole of what sets a value: what a hover and a banner say. */
|
|
125
|
+
export function originLabel(origin) {
|
|
126
|
+
const short = originShortLabel(origin);
|
|
127
|
+
return origin.kind === 'constant' ? `${short}, which other code reads` : short;
|
|
128
|
+
}
|
|
129
|
+
/** What a row says of its origin, at a glance: `Set by bonsaiGoogle`, `Set in code · bonsaiInputs()`. */
|
|
130
|
+
export function originShortLabel(origin) {
|
|
131
|
+
switch (origin.kind) {
|
|
132
|
+
case 'constant':
|
|
133
|
+
return `Set by ${origin.text ?? 'a constant'}`;
|
|
134
|
+
case 'twice':
|
|
135
|
+
return 'Defined more than once in your files';
|
|
136
|
+
case 'unfound':
|
|
137
|
+
return 'Not defined where the studio reads';
|
|
138
|
+
default:
|
|
139
|
+
return origin.text ? `Set in code · ${origin.text}` : 'Set in code';
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
/** What the builder does about an origin with no place to open. */
|
|
143
|
+
export function originWay(origin) {
|
|
144
|
+
if (origin.kind === 'unfound') {
|
|
145
|
+
return 'Define it with defineProfile or registerTool, in a file your setup imports by a relative path.';
|
|
146
|
+
}
|
|
147
|
+
return 'Edit it in your files.';
|
|
148
|
+
}
|
|
149
|
+
/** What the page says once it asked for a place in the builder's editor. */
|
|
150
|
+
export function openOutcome(answer, place) {
|
|
151
|
+
if (answer.ok && answer.byDefault) {
|
|
152
|
+
return `Opened in your default editor: ${place}. To open on the line, choose your editor in Settings.`;
|
|
153
|
+
}
|
|
154
|
+
if (answer.ok)
|
|
155
|
+
return `Opened ${place} in ${editorLabel(answer.editor)}.`;
|
|
156
|
+
const how = 'Choose the editor you use in Settings, under Files.';
|
|
157
|
+
switch (answer.reason) {
|
|
158
|
+
case 'file':
|
|
159
|
+
return `${place} is not a file your setup reads now. Reload the studio.`;
|
|
160
|
+
case 'editor':
|
|
161
|
+
return `The studio cannot start ${answer.editor || 'that editor'} on a line. ${how}`;
|
|
162
|
+
default:
|
|
163
|
+
return `${answer.editor ? editorLabel(answer.editor) : 'Your editor'} did not start. ${how}`;
|
|
164
|
+
}
|
|
165
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,87 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@theoremjs/studio",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"
|
|
5
|
-
"
|
|
6
|
-
|
|
3
|
+
"version": "0.3.2",
|
|
4
|
+
"description": "Theorem Studio: open a project's agents in a local studio on Deno, edit and run them, and save back to its files; or show the studio screen in a Vite app.",
|
|
5
|
+
"license": "MIT",
|
|
6
|
+
"type": "module",
|
|
7
|
+
"engines": {
|
|
8
|
+
"node": ">=20"
|
|
9
|
+
},
|
|
10
|
+
"repository": {
|
|
11
|
+
"type": "git",
|
|
12
|
+
"url": "git+https://github.com/masudl-hub/theoremai.git",
|
|
13
|
+
"directory": "studio"
|
|
14
|
+
},
|
|
15
|
+
"bin": {
|
|
16
|
+
"theorem-studio": "start.mjs"
|
|
17
|
+
},
|
|
18
|
+
"sideEffects": [
|
|
19
|
+
"**/*.css",
|
|
20
|
+
"./ui/boot-mark.js",
|
|
21
|
+
"./ui/code/studio-monaco.js",
|
|
22
|
+
"./ui/map-token.js",
|
|
23
|
+
"./ui/read-map.js",
|
|
24
|
+
"./ui/studio-map.js",
|
|
25
|
+
"./ui/studio-run.js",
|
|
26
|
+
"./ui/studio-screen.js",
|
|
27
|
+
"./ui/studio-shell.js",
|
|
28
|
+
"./ui/theorem-mark.js"
|
|
29
|
+
],
|
|
30
|
+
"exports": {
|
|
31
|
+
".": {
|
|
32
|
+
"types": "./mod.d.ts",
|
|
33
|
+
"default": "./mod.js"
|
|
34
|
+
},
|
|
35
|
+
"./runtime": {
|
|
36
|
+
"types": "./runtime.d.ts",
|
|
37
|
+
"default": "./runtime.js"
|
|
38
|
+
},
|
|
39
|
+
"./browser": {
|
|
40
|
+
"types": "./browser.d.ts",
|
|
41
|
+
"default": "./browser.js"
|
|
42
|
+
},
|
|
43
|
+
"./people": {
|
|
44
|
+
"types": "./people.d.ts",
|
|
45
|
+
"default": "./people.js"
|
|
46
|
+
},
|
|
47
|
+
"./surface": {
|
|
48
|
+
"types": "./surface.d.ts",
|
|
49
|
+
"default": "./surface.js"
|
|
50
|
+
},
|
|
51
|
+
"./server": {
|
|
52
|
+
"types": "./server.d.ts",
|
|
53
|
+
"default": "./server.js"
|
|
54
|
+
},
|
|
55
|
+
"./ui/*.tsx": {
|
|
56
|
+
"types": "./ui/*.d.ts",
|
|
57
|
+
"default": "./ui/*.js"
|
|
58
|
+
},
|
|
59
|
+
"./ui/*.ts": {
|
|
60
|
+
"types": "./ui/*.d.ts",
|
|
61
|
+
"default": "./ui/*.js"
|
|
62
|
+
},
|
|
63
|
+
"./ui/*.css": "./ui/*.css",
|
|
64
|
+
"./vite": {
|
|
65
|
+
"types": "./vite.d.mts",
|
|
66
|
+
"default": "./vite.mjs"
|
|
67
|
+
}
|
|
68
|
+
},
|
|
69
|
+
"dependencies": {
|
|
70
|
+
"@fontsource/figtree": "^5.3.0",
|
|
71
|
+
"@tabler/icons-react": "^3.46.0",
|
|
72
|
+
"@types/node": "^20.19.43",
|
|
73
|
+
"fflate": "^0.8.2",
|
|
74
|
+
"monaco-editor": "^0.57.0",
|
|
75
|
+
"typescript": "^6.0.3"
|
|
76
|
+
},
|
|
77
|
+
"peerDependencies": {
|
|
78
|
+
"@astryxdesign/core": "0.7.0",
|
|
79
|
+
"@astryxdesign/theme-neutral": "0.7.0",
|
|
80
|
+
"@stylexjs/stylex": "0.19.0",
|
|
81
|
+
"react": "^19.0.0",
|
|
82
|
+
"react-dom": "^19.0.0",
|
|
83
|
+
"zod": "^4.6.5",
|
|
84
|
+
"@theoremjs/agents": "0.3.2",
|
|
85
|
+
"@theoremjs/react": "0.3.2"
|
|
86
|
+
}
|
|
87
|
+
}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/TraceInspector-_yZiz05W.js","assets/rolldown-runtime-hePW80VL.js","assets/themeProps-3IqahpCr.js","assets/tokens.stylex-DkHf0P9C.js","assets/SegmentedControlItem-h-aaXzyS.js","assets/padding.stylex-B76907Zf.js","assets/VStack-CkVMcNiK.js","assets/mergeProps-ptS-gIMz.js","assets/StackItem-CQviqAfM.js","assets/groupStyles-C7Ter7zC.js","assets/Icon-JrysT8aU.js","assets/devWarning-DxuplmRl.js","assets/Text-bum6zWWx.js","assets/sharedResizeObserver-4U9Xq5Oq.js","assets/preload-helper-DpV6A1kQ.js","assets/useMediaQuery-BCT0NUeZ.js","assets/focusOutline.stylex-BT0kfa4t.js","assets/useLayerDismissal-B_G7IWpC.js","assets/IconButton-DlOGzJIX.js","assets/useTooltip-CJM_xhLB.js","assets/useDevWarning-Z9SoixOP.js","assets/Tooltip-BH9xiRMl.js","assets/createReactComponent-CZwsv6DD.js","assets/isRtlElement-BG33-k_H.js","assets/focusableSelector-DXZeMU85.js","assets/CodeBlock-C7XJ4ioE.js","assets/useClipboard-BgGRxRMJ.js","assets/DateInput-BGrQ5tPC.js","assets/Card-Lp-0P5eL.js","assets/container.stylex-BmOi-8DQ.js","assets/ScrollableArea-Ckugdj1N.js","assets/useScrollableArea-0NzdiBCq.js","assets/BottomSheet-BwfBDtje.js","assets/useScrollLock-Dyf6PHJt.js","assets/SidePanel-BL32abk8.js","assets/CheckboxInput-Cj5pk-KI.js","assets/IconAlertTriangle-BqAEqqdU.js","assets/arrive-DvbqpeRS.js","assets/IconShield-DDOh7Gr5.js","assets/shaped-data-BcarWqd5.js","assets/host-patterns-C9RMP16Q.js","assets/trace-record-C3zNksA_.js","assets/TraceOverview-BPO-HIYK.js","assets/labels-provider-4TIWDvsE.js","assets/index-CvvmFKgS.js","assets/browser-transport-D-2jDYe7.js","assets/Center-nHS1JSux.js","assets/IconSearch-BTx66a40.js","assets/schemas-BQ9Jydzb.js","assets/tool-schema-idaOe2nI.js","assets/reader-BOCCYaRp.js","assets/live-ingress-lDUGPwth.js","assets/trace-schema-9CdEyG6Q.js","assets/stub-DhdcU_Ew.js","assets/tree-DqyAMsbI.js","assets/types-BhfXQCLx.js","assets/useContainerReveal-BFy8N_QU.js","assets/Dialog-DELWQo-v.js","assets/HoverCard-D1Y1ltWQ.js","assets/IconEye-BB5aY-wQ.js","assets/turn-client-Du3Um3Mg.js","assets/encode-files-Bc3HJyAh.js","assets/workspace-DZALqEDX.js","assets/lent-keys-C32ems-I.js","assets/editors-BJX_S59A.js","assets/EmptyState-C8W4JKBZ.js","assets/PaneState-BvA2tLQg.js","assets/PaneState-eUzUkNE8.css","assets/CollapsibleGroup-N7_SOjbm.js","assets/useAdaptivePresentation-BzmPCddb.js","assets/Section-DJ97F7QE.js","assets/ContextMenu-CBu9H-9H.js","assets/index-DOaHlqBo.css","assets/trace-patterns-DnYJa0nI.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{r as e}from"./rolldown-runtime-hePW80VL.js";import{c as t,l as n,n as r,u as i}from"./themeProps-3IqahpCr.js";import{h as a}from"./tokens.stylex-DkHf0P9C.js";import{t as o}from"./mergeProps-ptS-gIMz.js";import{D as s,O as c}from"./groupStyles-C7Ter7zC.js";import{b as l,t as u}from"./Icon-JrysT8aU.js";import{d,r as f}from"./IconButton-DlOGzJIX.js";import{_ as p,c as m,d as h,f as g,l as _,m as v,p as y,t as b,u as x}from"./SidePanel-BL32abk8.js";import{t as S}from"./preload-helper-DpV6A1kQ.js";import{n as C,t as w}from"./labels-provider-4TIWDvsE.js";import{t as T}from"./createReactComponent-CZwsv6DD.js";import{a as E}from"./ScrollableArea-Ckugdj1N.js";var D=T(`outline`,`check`,`Check`,[[`path`,{d:`M5 12l5 5l10 -10`,key:`svg-0`}]]),O=T(`outline`,`copy`,`Copy`,[[`path`,{d:`M7 9.667a2.667 2.667 0 0 1 2.667 -2.667h8.666a2.667 2.667 0 0 1 2.667 2.667v8.666a2.667 2.667 0 0 1 -2.667 2.667h-8.666a2.667 2.667 0 0 1 -2.667 -2.667l0 -8.666`,key:`svg-0`}],[`path`,{d:`M4.012 16.737a2.005 2.005 0 0 1 -1.012 -1.737v-10c0 -1.1 .9 -2 2 -2h10c.75 0 1.158 .385 1.5 1`,key:`svg-1`}]]),k=e(i(),1),A=t(),j=(0,k.lazy)(()=>S(()=>import(`./TraceInspector-_yZiz05W.js`).then(e=>({default:e.TraceGuardrailsBody})),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73]))),M=(0,k.lazy)(()=>S(()=>import(`./TraceInspector-_yZiz05W.js`).then(e=>({default:e.TraceFeedBody})),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73]))),N=(0,k.createContext)(`replace`);function P({value:e,children:t}){return(0,A.jsx)(N,{value:e,children:t})}function F({id:e,header:t,traces:n}){return(0,A.jsx)(m,{id:e,header:t,children:e=>(0,A.jsx)(k.Suspense,{fallback:null,children:(0,A.jsx)(M,{traces:n,isWide:e})})})}function I(e,t,n){let r=C(),i=(0,k.useId)(),[a,o]=(0,k.useState)(!1),s=(0,k.use)(N),c={name:r(`@theorem.panel.trace.name`),show:r(`@theorem.panel.trace.show`),hide:r(`@theorem.panel.trace.hide`),resize:r(`@theorem.panel.trace.resize`)};if(e.observability?.record!==!0)return{toggle:null,view:null,labels:c,offered:!1};let l=n??a,d=n===void 0?(0,A.jsx)(h,{labels:c,icon:(0,A.jsx)(u,{icon:E}),panelId:i,open:l,onToggle:()=>o(e=>!e)}):null;return{toggle:d,view:l?L(s===`panel`,i,t,d):null,labels:c,offered:!0}}function L(e,t,n,r){return e?(0,A.jsx)(R,{id:t,traces:n}):(0,A.jsx)(F,{id:t,header:r?(0,A.jsx)(x,{floating:!0,children:r}):void 0,traces:n})}function R({id:e,traces:t}){let{ref:n,width:r}=v();return(0,A.jsx)(`div`,{id:e,ref:n,style:{height:`100%`},children:(0,A.jsx)(k.Suspense,{fallback:null,children:(0,A.jsx)(M,{traces:t,isWide:g(r)})})})}function z({inspector:e,children:t}){let n=(0,k.useRef)(null),r=y(n,!1),i=(0,k.useRef)(void 0),a=(0,k.useCallback)(e=>{n.current=e;let t=i.current;typeof t==`function`?t(e):t!=null&&(t.current=e)},[]);if(!(0,k.isValidElement)(t))return(0,A.jsx)(b,{view:e.view,children:t});i.current=t.props.ref;let o=e.view!=null;return(0,k.cloneElement)(t,{ref:a,end:(0,A.jsx)(_,{labels:e.labels,resizable:r.resizable,open:o,children:e.view})})}function B({inspector:e,children:t}){return(0,k.use)(N)===`panel`&&e.offered?(0,A.jsx)(z,{inspector:e,children:t}):(0,A.jsx)(b,{view:e.view,children:t})}function V({records:e,head:t}){return(0,A.jsx)(w,{children:(0,A.jsx)(k.Suspense,{fallback:null,children:(0,A.jsx)(j,{records:e,head:t})})})}var H={info:`info`,warning:`warning`,error:`error`,success:`success`},U={info:`accent`,warning:`warning`,error:`error`,success:`success`},W={root:{k1xSpc:`x78zum5`,kXwgrk:`xdt5ytf`,kMv6JI:`xjb2p0i`,$$css:!0},rootElevatedCard:{kaIpWk:`x1vf2byn`,$$css:!0},header:{k1xSpc:`x78zum5`,kGNEyG:`x1cy8zhl`,kwnvtZ:`x1a02dak`,k1C7PZ:`xak3so`,khm7nJ:`x4olc9o`,k8WAf4:`x8o8v82`,kg3NbH:`x1pzlopt`,$$css:!0},headerCardStandalone:{kaIpWk:`x1vf2byn`,$$css:!0},headerCardWithContent:{krdFHd:`xwxb7qi`,kfmiAY:`x13nour3`,kVL7Gh:`xbiv7yw`,kT0f0o:`x16uus16`,$$css:!0},headerCentered:{kGNEyG:`x6s0dn4`,$$css:!0},endArea:{k1xSpc:`x78zum5`,kGNEyG:`x6s0dn4`,kwnvtZ:`x1a02dak`,kjj79g:`x13a6bvl`,kOIVth:`x1txdalj`,kmuXW:`x2lah0s`,ks0D6T:`x193iq5w`,keTefX:`xvc5jky`,kqGvvJ:`x81ka23`,$$css:!0},chevron:{k1ekBW:`x11xpdln`,kIyJzY:`xuedmi6 x12w9bfk`,kAMwcw:`xlr8y92`,$$css:!0},chevronExpanded:{k3aq6I:`x19jd1h0`,$$css:!0}},G={info:{kWkggS:`xgcxg3y`,$$css:!0},warning:{kWkggS:`x24i8r5`,$$css:!0},error:{kWkggS:`x1pritpl`,$$css:!0},success:{kWkggS:`xu13z74`,$$css:!0}};function K(e){return Object.prototype.hasOwnProperty.call(G,e)}var ee={none:{kGVxlE:`x1gnnqk1`,$$css:!0},low:{kGVxlE:`x1i5ehqx`,$$css:!0},med:{kGVxlE:`x14hfi27`,$$css:!0},high:{kGVxlE:`x1kcpxr7`,$$css:!0}};function q({status:e,title:t,description:i,icon:m,isDismissable:h=!1,onDismiss:g,dismissLabel:_,endContent:v,container:y=`card`,elevation:b=`none`,collapsible:x=!0,children:S,xstyle:C,className:w,style:T,ref:E,onFocusCapture:D,onPointerDownCapture:O,...j}){let M=l(),[N,P]=(0,k.useState)(!1),F=typeof x==`object`&&x?x:{},{isEnabled:I,isOpen:L,toggle:R}=p({isCollapsible:x!==!1&&{...F,defaultIsOpen:F.defaultIsOpen??!1}}),z=(0,k.useRef)(null),B=(0,k.useId)(),V=H[e],q=U[e],J=s(S),Y=M(`@astryx.banner.dismiss`),te=_??Y,ne=_??(typeof t==`string`?M(`@astryx.banner.dismissTitled`,{dismiss:Y,title:t}):Y);if(N)return null;let X=(e,t)=>{e instanceof HTMLElement&&e!==document.body&&!t.contains(e)&&(z.current=e)},re=e=>{X(e.relatedTarget,e.currentTarget)},ie=e=>{X(document.activeElement,e.currentTarget)},ae=()=>{let e=z.current;P(!0),g?.(),e?.isConnected&&e.focus()},Z=I&&J,oe=s(v)||h||Z,se=s(v)||h,ce=!s(i)&&se,Q=J&&(!I||L),$=y===`card`;return(0,A.jsxs)(`div`,{ref:E,onFocusCapture:c(D,re),onPointerDownCapture:c(O,ie),...o(r(`banner-frame`,{container:y,elevation:b}),n(W.root,ee[b],$&&b!==`none`&&W.rootElevatedCard,C),w,T),...j,children:[(0,A.jsxs)(`div`,{...o(r(`banner`,{container:y,status:e}),n(W.header,ce&&W.headerCentered,K(e)&&G[e],$&&(Q?W.headerCardWithContent:W.headerCardStandalone))),children:[(0,A.jsx)(`div`,{...s(m)?o(r(`banner-icon`,{status:e}),{className:`x78zum5 x6s0dn4 x2lah0s`}):{className:`x78zum5 x6s0dn4 x2lah0s`},"aria-hidden":`true`,children:s(m)?m:V==null?null:(0,A.jsx)(u,{icon:V,size:`md`,color:q,...r(`banner-icon`,{status:e})})}),(0,A.jsxs)(`div`,{...{0:{className:`x78zum5 xdt5ytf xxhr3t x98rzlu xeuugli`},1:{className:`x78zum5 xdt5ytf xxhr3t x98rzlu xeuugli xgualba`}}[!!s(v)|0],children:[(0,A.jsx)(`div`,{className:`x1ghz6dp xjb2p0i xcr08ib x2mo6ok x1kq96og x1tgivj0 xj0a0fe`,children:t}),s(i)&&(0,A.jsx)(`div`,{...o(r(`banner-description`),{className:`x1ghz6dp xjb2p0i x141an7d x1sodnla x1ltkj2j xv1l7n4 xj0a0fe`}),children:i})]}),oe&&(0,A.jsxs)(`div`,{...n(W.endArea,d.inset(a[`--spacing-2`])),children:[v,Z&&(0,A.jsx)(f,{variant:`ghost`,size:`sm`,label:M(L?`@astryx.banner.collapse`:`@astryx.banner.expand`),tooltip:M(L?`@astryx.banner.collapse`:`@astryx.banner.expand`),icon:(0,A.jsx)(u,{icon:`chevronDown`,size:`sm`,color:`inherit`,xstyle:[W.chevron,L&&W.chevronExpanded]}),onClick:R,"aria-expanded":L,"aria-controls":Q?B:void 0,isIconOnly:!0}),h&&(0,A.jsx)(f,{variant:`ghost`,size:`sm`,label:ne,tooltip:te,icon:(0,A.jsx)(u,{icon:`close`,size:`sm`,color:`inherit`}),onClick:ae,isIconOnly:!0})]})]}),Q&&(0,A.jsx)(`div`,{id:Z?B:void 0,...o(r(`banner-content`,{container:y,status:e}),{0:{className:`x1de1mus x8o8v82 x1pzlopt xgbv0en xw8tdv1 x92x3c3 x1t7ytsu x18b5jzi x1q0q8m5 x1j92z86 x1gejf6u xw8gpjh`},1:{className:`x1de1mus x8o8v82 x1pzlopt xgbv0en xw8tdv1 x92x3c3 x1t7ytsu x18b5jzi x1q0q8m5 x1j92z86 x1gejf6u xw8gpjh x1k5g1gk x1eprgri`}}[!!$|0]),children:S})]})}q.displayName=`Banner`;export{I as a,B as i,V as n,O as o,P as r,D as s,q as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{n as e,r as t}from"./rolldown-runtime-hePW80VL.js";import{c as n,l as r,n as i,u as a}from"./themeProps-3IqahpCr.js";import{h as o}from"./tokens.stylex-DkHf0P9C.js";import{_ as s,a as c,c as l,h as u,n as d,t as f,v as p}from"./padding.stylex-B76907Zf.js";import{t as m}from"./mergeProps-ptS-gIMz.js";import{i as h}from"./focusOutline.stylex-BT0kfa4t.js";import{a as g,i as _,n as v,t as y}from"./useLayerDismissal-B_G7IWpC.js";import{t as ee}from"./useMediaQuery-BCT0NUeZ.js";import{t as b}from"./useDevWarning-Z9SoixOP.js";import{t as x}from"./useScrollableArea-0NzdiBCq.js";import{t as S}from"./useScrollLock-Dyf6PHJt.js";import{t as C}from"./container.stylex-BmOi-8DQ.js";var w=t(a(),1),T=/^(\d+(?:\.\d+)?|\.\d+)(px|%)$/i;function E(e,t){if(typeof e==`number`)return Number.isFinite(e)&&e>0&&e<=1?e*t:null;let n=T.exec(e.trim());if(n===null)return null;let r=Number.parseFloat(n[1]);return r>0?n[2].toLowerCase()===`%`?r/100*t:r:null}function D(e){return E(e,1)!==null}function O(e,t){let n=[];for(let r of e){let e=E(r,t);e!==null&&n.push(e)}return n}function k(e,t,n=48){let r=[0,...t.filter(t=>t>0&&t<e).map(t=>e-t)].sort((e,t)=>e-t),i=[];for(let e of r){let t=i[i.length-1];(t===void 0||e-t>=n)&&i.push(e)}return i}function A(e,t){return t.reduce((t,n)=>Math.abs(n-e)<Math.abs(t-e)?n:t,t[0])}var j=.3;function te(e,t){if(e.length<2||t<=0)return null;let n=e[e.length-1];return t-n<=.25*t?n:null}function ne(e,t,n,r){let i=r!==null,a=i?t[t.length-2]:t[t.length-1],o=i?r:n,s=i?j:0;return e<=a?1:e>=o?s:1-(1-s)*((e-a)/(o-a))}function re(e,t,n,r){let i=t;if(n>0){let e=t.filter(e=>e>=r);e.length>0&&(i=e)}else if(n<0){let e=t.filter(e=>e<=r);e.length>0&&(i=e)}return A(e,i)}var M=`--_sheet-keyboard-inset`,N=new Set([`button`,`checkbox`,`color`,`file`,`hidden`,`image`,`radio`,`range`,`reset`,`submit`]);function P(){return window.visualViewport?.height??window.innerHeight}function ie(){return P()>=window.innerHeight-.5}function F(){let e=window.navigator.userAgent;return/iPad|iPhone|iPod/.test(e)||e.includes(`Macintosh`)&&window.navigator.maxTouchPoints>1}function I(e){return e instanceof HTMLTextAreaElement?!e.disabled&&!e.readOnly:e instanceof HTMLInputElement?!e.disabled&&!e.readOnly&&!N.has((e.getAttribute(`type`)??`text`).toLowerCase()):e instanceof HTMLElement&&e.matches(`[contenteditable]:not([contenteditable="false"])`)}function L(e,t){if(!(e instanceof Element))return null;let n=e.closest(`input, textarea, [contenteditable]:not([contenteditable="false"])`);if(t.contains(n)&&I(n))return n;let r=e.closest(`label`),i=r instanceof HTMLLabelElement?r.control:null;return t.contains(i)&&I(i)?i:null}function ae({bodyRef:e,bottomClearance:t,isEnabled:n,isFullyExpanded:r,isPageScrollLocked:i,isSheetTraveling:a,isOpen:o,isPresented:s,sheetRef:c}){let l=(0,w.useRef)(!1),u=(0,w.useRef)(!1),d=(0,w.useRef)(r),f=(0,w.useRef)(o);d.current=r,f.current=o,(0,w.useEffect)(()=>{if(!n||!a)return;let e=c.current,t=document.activeElement;e&&t instanceof HTMLElement&&t!==e&&e.contains(t)&&(u.current=l.current,e.focus({preventScroll:!0}))},[n,a,c]),(0,w.useEffect)(()=>{if(!n||!s||o)return;let e=c.current,t=document.activeElement;e&&t instanceof HTMLElement&&t!==e&&e.contains(t)&&(u.current=l.current,t.blur())},[n,o,s,c]),(0,w.useEffect)(()=>{let r=e.current,a=c.current;if(!n||!s||!r)return;let o=null,p=null,m=F(),h=()=>{r.style.setProperty(M,`0px`),o=null,p=null,l.current=!1,u.current=!1},g=(e,t)=>{if(typeof r.scrollBy!=`function`){r.scrollTop+=e;return}let n=typeof window.matchMedia==`function`&&window.matchMedia(`(prefers-reduced-motion: reduce)`).matches;r.scrollBy({top:e,behavior:t&&!n?`smooth`:`instant`})},_=(e,n)=>{let i=r.getBoundingClientRect(),a=e.getBoundingClientRect(),o=P(),s=Math.max(0,i.bottom-o)>0?t:0,c=i.top,l=Math.min(i.bottom,o-s);l<=c||(a.bottom>l?g(a.bottom-l,n):a.top<c&&g(a.top-c,n))},v=e=>{let n=P();if(ie()||Math.max(0,e.bodyBottom-n)===0){h();return}let i=Math.max(0,e.bodyBottom-(n-t));r.style.setProperty(M,`${i}px`)},y=e=>{if(!d.current)return;let t=L(e.relatedTarget,r);if(t){t!==document.activeElement&&t.focus({preventScroll:!0});return}let n=L(e.target,r);f.current&&n&&!e.relatedTarget&&a?.focus({preventScroll:!0})},ee=()=>{let e=document.activeElement;if(!d.current||!(e instanceof HTMLElement)||!r.contains(e)||!I(e)){if(u.current&&o){v(o);return}h();return}u.current=!1;let n=r.getBoundingClientRect(),a=P(),s=Math.max(0,n.bottom-a),c=s>0?t:0;o=s>0?{bodyBottom:n.bottom}:null,i&&s>0&&!l.current&&(p={x:window.scrollX,y:window.scrollY}),l.current=s>0;let f=s>0?Math.max(0,n.bottom-(a-c)):0;r.style.setProperty(M,`${f}px`),_(e,s>0)},b=0,x=()=>{cancelAnimationFrame(b),b=requestAnimationFrame(ee)},S=()=>{let e=p;if(e==null||window.scrollX===e.x&&window.scrollY===e.y)return;window.scrollTo(e.x,e.y);let t=document.activeElement;t instanceof HTMLElement&&r.contains(t)&&I(t)&&_(t,!1)},C=typeof ResizeObserver>`u`?null:new ResizeObserver(x),w=()=>{if(!C)return;C.disconnect();let e=new Set([r]);a&&e.add(a);for(let t of r.children)e.add(t);let t=document.activeElement;if(t instanceof HTMLElement&&r.contains(t))for(let n=t;n&&n!==r;n=n.parentElement)e.add(n);for(let t of e)C.observe(t)},T=typeof MutationObserver>`u`?null:new MutationObserver(e=>{e.every(e=>e.type===`attributes`&&e.target===r)||(w(),x())}),E=()=>{w(),x()},D=()=>{u.current=l.current,x()},O=e=>{e.target===a&&e.propertyName===`transform`&&x()},k=window.visualViewport;return m&&document.addEventListener(`blur`,y,!0),r.addEventListener(`focusin`,E),r.addEventListener(`focusout`,D),a?.addEventListener(`transitionend`,O),k?.addEventListener(`resize`,x),k?.addEventListener(`scroll`,x),window.addEventListener(`scroll`,S),window.addEventListener(`resize`,x),T?.observe(r,{attributes:!0,characterData:!0,childList:!0,subtree:!0}),w(),x(),()=>{cancelAnimationFrame(b),m&&document.removeEventListener(`blur`,y,!0),r.removeEventListener(`focusin`,E),r.removeEventListener(`focusout`,D),a?.removeEventListener(`transitionend`,O),k?.removeEventListener(`resize`,x),k?.removeEventListener(`scroll`,x),window.removeEventListener(`scroll`,S),window.removeEventListener(`resize`,x),C?.disconnect(),T?.disconnect(),r.style.removeProperty(M),l.current=!1,u.current=!1}},[e,t,n,i,s,c])}var oe=.998/.0020000000000000018,R=48,se=100,ce=.4,le=40;function ue(e){return e.syntheticTouch===!0}var de=.35,fe=4,pe=8;function me(){typeof navigator<`u`&&typeof navigator.vibrate==`function`&&(we()||navigator.vibrate(8))}function he(e,t){let n=t[0],r=Math.abs(e-n);for(let i of t){let t=Math.abs(e-i);t<r&&(r=t,n=i)}if(r>=le)return e;let i=r/le,a=1-i*i;return e+(n-e)*a}function ge(e,t,n){return Math.max(0,e-t-n)}function _e(e){let t=Number.parseFloat(getComputedStyle(e).paddingBlockEnd);return Number.isFinite(t)?t:0}function ve(e){if(!e)return 0;let t=_e(e);return Math.max(0,e.scrollHeight-e.clientHeight-t)-e.scrollTop}function ye(e){if(e.scrollHeight-e.clientHeight<=1)return!1;let{overflowY:t}=getComputedStyle(e);return t===`auto`||t===`scroll`}function be(e,t){let n=[];for(let r=e instanceof Element?e:null;r!=null&&r!==t;r=r.parentElement)r instanceof HTMLElement&&ye(r)&&n.push(r);return n.push(t),n}function z(e){return e.scrollTop<=0}function xe(e){return e.scrollTop+e.clientHeight>=e.scrollHeight-1}function Se(e){return e.every(z)}function Ce(e){return e.every(xe)}function B(e,t,n){return Math.max(0,e-n-t)}function we(){return typeof window>`u`||!window.matchMedia?!1:window.matchMedia(`(prefers-reduced-motion: reduce)`).matches}function V({isOpen:e,canDismiss:t=!0,offscreenBlockEndInset:n=0,onDismiss:r,snapHeights:i,onSnap:a,onScrimOpacity:o}){let[s,c]=(0,w.useState)(0),[l,u]=(0,w.useState)(0),[d,f]=(0,w.useState)(!1),[p,m]=(0,w.useState)(!1),[h,g]=(0,w.useState)(0),[_,v]=(0,w.useState)(0),[y,b]=(0,w.useState)(0),x=(0,w.useRef)(0),S=(0,w.useRef)(0),[C,T]=(0,w.useState)(null),[E,D]=(0,w.useState)(!1),O=(0,w.useRef)(0),A=(0,w.useRef)(null),j=(0,w.useRef)(null),M=(0,w.useRef)(n);M.current=Math.max(0,n);let N=(0,w.useCallback)(e=>{let t=Math.max(0,e);x.current=t,b(t)},[]),P=(0,w.useCallback)(e=>{let t=Math.max(0,e);Math.abs(t-O.current)>.5&&(O.current=t,v(t))},[]),ie=(0,w.useCallback)(()=>{D(!0),A.current=null,T(null);let e=j.current;j.current=null,e!=null&&P(e)},[P]),F=(0,w.useCallback)((e,t,n,r,i,a,o)=>{let s=ge(e,n,a);o&&Math.abs(r-t)>.5&&!we()?(j.current=s,A.current=i,T(i)):(j.current=null,A.current=null,T(null),D(Math.abs(i-n)>.5),P(s))},[P]),I=(0,w.useRef)(0);d||(I.current=l);let L=(0,w.useRef)(e);L.current=e;let ae=(0,w.useRef)(i);ae.current=i;let le=(0,w.useRef)(r),ye=(0,w.useRef)(t),z=(0,w.useRef)(a),xe=(0,w.useRef)(o);(0,w.useEffect)(()=>{le.current=r,ye.current=t,z.current=a,xe.current=o});let V=(0,w.useRef)(null),H=(0,w.useRef)(0),Te=(0,w.useRef)(null),Ee=(0,w.useRef)(null),De=(0,w.useRef)(null);(0,w.useLayoutEffect)(()=>{if(!E)return;Te.current?.offsetHeight;let e=requestAnimationFrame(()=>{D(!1)});return()=>cancelAnimationFrame(e)},[E]);let Oe=(0,w.useCallback)(e=>{e<=0||!L.current||I.current>0||(H.current=e,g(t=>t===e?t:e))},[]),ke=(0,w.useCallback)(e=>{if(De.current?.disconnect(),De.current=null,Te.current=e,!e||typeof ResizeObserver>`u`){e&&Oe(e.getBoundingClientRect().height);return}Oe(e.getBoundingClientRect().height);let t=new ResizeObserver(e=>{let t=e[0];if(t){let e=t.borderBoxSize?.[0]?.blockSize;Oe(e??t.target.getBoundingClientRect().height)}});t.observe(e),De.current=t},[Oe]);(0,w.useEffect)(()=>()=>De.current?.disconnect(),[]),(0,w.useEffect)(()=>{e&&(c(0),u(0),f(!1),m(!1),D(!1),N(0),S.current=0,O.current=0,A.current=null,j.current=null,v(0),T(null))},[e,N]);let Ae=(0,w.useCallback)(()=>H.current>0?H.current:Te.current?.getBoundingClientRect().height??0,[]),U=(0,w.useCallback)(e=>{let t=B(e,0,M.current),n=k(t,ae.current?.()??[]);return{offsets:n,peekOffset:te(n,t)}},[]),je=(0,w.useCallback)(()=>{let e=Te.current;if(!e)return H.current;let t=e.style.height;if(t===``)return e.getBoundingClientRect().height;e.style.height=``;let n=e.getBoundingClientRect().height;return e.style.height=t,n},[]),W=(0,w.useCallback)(()=>{if(!L.current||V.current!=null||A.current!=null)return;let e=je();if(e<=0)return;let{offsets:t,peekOffset:n}=U(e),r=Math.min(S.current,t.length-1),i=t[r],a=i===n?0:i,o=x.current;if(e===H.current&&Math.abs(i-I.current)<=.5&&Math.abs(a-o)<=.5)return;H.current=e,g(e),S.current=r,F(o,i,a,i,o,ve(Ee.current),!1),N(a),u(i),z.current?.(B(e,i,M.current));let s=t[t.length-1],c=B(e,s,M.current);xe.current?.(ne(i,t,s+c*ce,n))},[je,F,N,U]);(0,w.useEffect)(()=>{if(e&&typeof window<`u`)return window.addEventListener(`resize`,W),window.addEventListener(`orientationchange`,W),()=>{window.removeEventListener(`resize`,W),window.removeEventListener(`orientationchange`,W)}},[e,W]);let G=(0,w.useRef)(!1);(0,w.useLayoutEffect)(()=>{G.current?W():G.current=!0},[W,i]);let Me=(0,w.useCallback)((e,t)=>{let n=Te.current;if(n==null)return;let r=e-t;n.style.transform=r===0?``:`translateY(${r}px)`},[]),K=(0,w.useCallback)(e=>{let t=V.current;if(t==null)return;V.current=null,e?.hasPointerCapture?.(t.pointerId)&&e.releasePointerCapture(t.pointerId),c(t.baseOffset),f(!1),m(!1),F(t.baseLayoutOffset,t.baseOffset,t.baseLayoutOffset,t.renderedOffset,t.layoutOffset,t.naturalEndGap,!0);let{offsets:n,peekOffset:r}=U(t.height),i=n[n.length-1],a=i+B(t.height,i,M.current)*ce;xe.current?.(ne(t.baseOffset,n,a,r))},[F,U]);(0,w.useEffect)(()=>{let e=()=>K(),t=()=>{document.visibilityState===`hidden`&&K()};return window.addEventListener(`blur`,e),document.addEventListener(`visibilitychange`,t),()=>{window.removeEventListener(`blur`,e),document.removeEventListener(`visibilitychange`,t)}},[K]);let Ne=(0,w.useCallback)((e,t,n,r,i,a,o,s,c,l)=>{let{offsets:d,peekOffset:f}=U(n),p=d[d.length-1],m=p+B(n,p,M.current)*ce,h=i>R?e+t*oe:e,g=e=>{let t=e===f?0:e;F(o,e,t,s,c,l,!0),N(t),S.current=Math.max(0,d.indexOf(e)),u(e),z.current?.(B(n,e,M.current)),xe.current?.(ne(e,d,m,f)),e!==a&&me()};r>0&&h>m?ye.current?(F(o,a,o,o,o,l,!1),le.current()):g(p):g(re(Math.min(Math.max(h,0),p),d,r,a))},[F,N,U]),q=(0,w.useCallback)((e,t,n)=>{let r=e.currentTarget,i=ue(e);i||r.setPointerCapture?.(e.pointerId);let a=n??e.clientY,o=ve(Ee.current),s=x.current;V.current={syntheticTouch:i,pointerId:e.pointerId,startCoord:a,lastCoord:e.clientY,lastTime:e.timeStamp,samples:[{t:e.timeStamp,y:e.clientY}],velocity:0,height:t,baseOffset:l,baseLayoutOffset:s,renderedOffset:l,layoutOffset:s,naturalEndGap:o,hasTraveled:!1},P(ge(s,s,o)),c(l),f(!0)},[l,P]),Pe=(0,w.useCallback)(e=>{e.button===0&&e.isPrimary&&(e.preventDefault(),q(e,Ae()))},[q,Ae]),J=(0,w.useCallback)(e=>{V.current!=null&&(e.preventDefault(),K(e.currentTarget))},[K]),Fe=(0,w.useCallback)(e=>{V.current?.syntheticTouch||V.current?.pointerId===e.pointerId&&K()},[K]),Y=(0,w.useCallback)(e=>{let t=V.current;if(!t||t.pointerId!==e.pointerId||t.syntheticTouch&&!ue(e))return;let n=e.clientY-t.startCoord;if(e.timeStamp-t.lastTime>0){for(t.lastCoord=e.clientY,t.lastTime=e.timeStamp,t.samples.push({t:e.timeStamp,y:e.clientY});t.samples.length>2&&e.timeStamp-t.samples[0].t>se;)t.samples.shift();let n=t.samples[0],r=Math.min(e.timeStamp-n.t,se);t.velocity=r>0?(e.clientY-n.y)/r:0}let{offsets:r,peekOffset:i}=U(t.height),a=t.baseOffset+n,o=r[r.length-1],s;s=a<0?Math.max(-48,a*de):a>o?a:he(a,r);let l=s<t.baseOffset?0:t.baseLayoutOffset,u=l!==t.layoutOffset;t.renderedOffset=s,t.layoutOffset=l,I.current=s,Me(s,l),u&&c(s),!t.hasTraveled&&s!==t.baseOffset&&(t.hasTraveled=!0,m(!0)),P(ge(t.baseLayoutOffset,l,t.naturalEndGap));let d=r[r.length-1],f=d+B(t.height,d,M.current)*ce;xe.current?.(ne(s,r,f,i))},[U,P,Me]),X=(0,w.useCallback)(e=>{let t=V.current;if(!t||t.pointerId!==e.pointerId||t.syntheticTouch&&!ue(e))return;let n=e.currentTarget,r=e.clientY-t.startCoord,i=Math.max(0,t.baseOffset+r),a=r===0?0:r>0?1:-1,o=e.timeStamp-t.lastTime<se?t.velocity:0;V.current=null,t.syntheticTouch||n.releasePointerCapture?.(e.pointerId),f(!1),m(!1),Ne(i,o,t.height||1,a,Math.abs(r),t.baseOffset,t.baseLayoutOffset,t.renderedOffset,t.layoutOffset,t.naturalEndGap)},[Ne]),Z=(0,w.useRef)(null),Ie=(0,w.useCallback)(e=>{if(e.button!==0||!e.isPrimary)return;let t=be(e.target,e.currentTarget);Se(t)?Z.current={pointerId:e.pointerId,startCoord:e.clientY,scrollers:t}:Z.current=null},[]),Q=(0,w.useCallback)(e=>{if(V.current){Y(e);return}let t=Z.current;if(!t||t.pointerId!==e.pointerId)return;let n=e.clientY-t.startCoord;n>pe&&Se(t.scrollers)?(Z.current=null,q(e,Ae(),t.startCoord),Y(e)):n<0&&(Z.current=null)},[q,Y,Ae]),Le=(0,w.useCallback)(e=>{Z.current=null,!V.current?.syntheticTouch&&V.current&&X(e)},[X]),Re=(0,w.useRef)(null),ze=(0,w.useRef)(null),$=(0,w.useCallback)(e=>{Re.current=null,Z.current=null,K(e)},[K]),Be=(0,w.useRef)(q),Ve=(0,w.useRef)(K),He=(0,w.useRef)($),Ue=(0,w.useRef)(Y),We=(0,w.useRef)(X),Ge=(0,w.useRef)(Ae);(0,w.useEffect)(()=>{Be.current=q,Ve.current=K,He.current=$,Ue.current=Y,We.current=X,Ge.current=Ae});let Ke=(0,w.useCallback)(e=>{let t=(e,t)=>({syntheticTouch:!0,pointerId:e.identifier,clientY:e.clientY,timeStamp:Date.now(),currentTarget:t,setPointerCapture:()=>{},releasePointerCapture:()=>{}}),n=e=>{let t=e.currentTarget;if(e.touches.length>1){He.current(t);return}let n=e.changedTouches[0];if(!n){Re.current=null;return}let r=be(e.target,t),i=Se(r),a=Ce(r)&&I.current>0;Re.current={id:n.identifier,startY:n.clientY,scrollers:r,top:i,bottom:a,contentEndY:null,promotedAtContentEnd:!1}},r=e=>{let n=e.currentTarget;if(e.touches.length>1){He.current(n);return}let r=Re.current;if(V.current){let i=[...e.changedTouches].find(e=>e.identifier===V.current?.pointerId);if(!i)return;if(r?.promotedAtContentEnd&&r.contentEndY!=null){if(i.clientY>=r.contentEndY){r.contentEndY=null,r.promotedAtContentEnd=!1,Ve.current(n);return}Ue.current(t(i,n));return}e.preventDefault(),Ue.current(t(i,n));return}if(!r)return;let i=[...e.changedTouches].find(e=>e.identifier===r.id);if(!i)return;let a=i.clientY-r.startY,o=r.top&&a>pe&&Se(r.scrollers),s=r.bottom&&a<-8&&Ce(r.scrollers);o||s?(e.preventDefault(),Re.current=null,Be.current(t(i,n),Ge.current(),r.startY),Ue.current(t(i,n))):((r.top&&a<0||r.bottom&&a>0)&&(r.top=!1,r.bottom=!1),I.current>0&&Ce(r.scrollers)?r.contentEndY==null?r.contentEndY=i.clientY:r.contentEndY-i.clientY>=fe&&(r.promotedAtContentEnd=!0,Be.current(t(i,n),Ge.current(),r.contentEndY),Ue.current(t(i,n))):r.contentEndY=null)},i=e=>{Re.current=null;let n=V.current?.pointerId;if(n==null)return;let r=[...e.changedTouches].find(e=>e.identifier===n),i=e.currentTarget;r?We.current(t(r,i)):e.touches.length===0&&Ve.current(i)},a=Ee.current;if(a&&ze.current){let e=ze.current;a.removeEventListener(`touchstart`,e.start),a.removeEventListener(`touchmove`,e.move),a.removeEventListener(`touchend`,e.end),a.removeEventListener(`touchcancel`,e.end)}Ee.current=e,e?(e.addEventListener(`touchstart`,n,{passive:!0}),e.addEventListener(`touchmove`,r,{passive:!1}),e.addEventListener(`touchend`,i,{passive:!0}),e.addEventListener(`touchcancel`,i,{passive:!0}),ze.current={start:n,move:r,end:i}):ze.current=null},[]),qe=ee(`(prefers-reduced-motion: reduce)`),Je=(0,w.useCallback)(e=>{if(O.current<=0)return;let t=_e(e),n=Math.max(0,e.scrollHeight-e.clientHeight-t),r=Math.max(0,e.scrollTop-n);r<O.current-.5&&P(r)},[P]),Ye=(0,w.useCallback)(e=>{V.current==null&&A.current==null&&Je(e.currentTarget)},[Je]),Xe=(0,w.useCallback)(e=>{e.isPrimary?Pe(e):$(e.currentTarget)},[Pe,$]),Ze=(0,w.useCallback)(e=>{e.isPrimary?Ie(e):$(e.currentTarget)},[Ie,$]),Qe=(0,w.useCallback)(e=>{e.touches.length>1&&$(e.currentTarget)},[$]),$e=(0,w.useCallback)(e=>{let t=V.current;t?.pointerId!==e.pointerId||t.syntheticTouch||K(e.currentTarget)},[K]),et=d?s:l;return{sheetRef:ke,contentProps:(0,w.useMemo)(()=>({style:{transform:et===0?void 0:`translateY(${et}px)`,transition:e&&(d||E||qe)?`none`:void 0,touchAction:`pinch-zoom`,overscrollBehavior:`contain`}}),[et,d,e,E,qe]),handleProps:(0,w.useMemo)(()=>({style:{touchAction:`pinch-zoom`,cursor:`grab`},onContextMenu:J,onLostPointerCapture:Fe,onPointerDown:Xe,onPointerMove:Y,onPointerUp:X,onPointerCancel:$e,onTouchStart:Qe,onTouchMove:Qe}),[X,J,$e,Xe,Qe,Fe,Y]),bodyProps:(0,w.useMemo)(()=>({ref:Ke,onContextMenu:J,onLostPointerCapture:Fe,onPointerDown:Ze,onPointerMove:Q,onPointerUp:Le,onPointerCancel:Le,onScroll:Ye}),[Ke,Le,Ze,Q,Ye,J,Fe]),bodyElementRef:Ee,dragOffset:s,settledOffset:l,isDragging:d,isTraveling:p,activeOffsetRef:I,sheetHeight:h,scrollPreservationInset:_,settlingLayoutOffset:C,settledLayoutOffset:y,completeScrollAreaSettle:ie}}var H=n(),Te={hug:`92dvh`,capped:`62dvh`,tall:`92dvh`},Ee=48,De=48,Oe=50;o[`--spacing-6`];function ke(){return typeof window>`u`?0:window.innerHeight}function Ae(e){let t=``;for(let n of e??[])t+=`${typeof n}:${n}|`;return t}var U={sheet:{kfzvcC:`x67bb7w`,kB7OPa:`x9f619`,kVAEAm:`x1n2onr6`,k1xSpc:`x78zum5`,kXwgrk:`xdt5ytf`,kAzted:`x2lwn1j`,kzqmXN:`xh8yej3`,ks0D6T:`x11gisft`,kWkggS:`x10xzikg`,kEafiO:`x11xkdxz`,kPef9Z:`x13fuv20`,kLZC3w:`x1pc3f07`,k2ei4v:`xgbv0en`,kVhnKS:`x1t7ytsu`,kGJrpR:`x1j92z86`,ke9TFa:`xw8tdv1`,k8ry5P:`x18b5jzi`,kBCPoo:`x1gejf6u`,krdFHd:`x81l70g`,kfmiAY:`x7hs6f1`,kGVxlE:`x1kcpxr7`,kI3sdo:`x1a2a7pz`,kVQacm:`xb3r6kr`,kGO01o:`x1wkw6tp`,k1K539:`x1if0o47`,k3aq6I:`xnn1q72 xhbqy3z`,kSiTet:`x1hc1fzr`,k1ekBW:`xwcsmn1`,kIyJzY:`x80gvsz`,kAMwcw:`xlr8y92`,k6sLGO:`x1q1rmc8`,k6CgDc:`xzg1mie`,$$css:!0},sheetClosing:{k3aq6I:`x1weeur4`,kAMwcw:`xv2sgk5`,$$css:!0},sheetFading:{kSiTet:`xg01cxk`,$$css:!0},sheetInactive:{kfzvcC:`x47corl`,$$css:!0},body:{kzQI83:`x1iyjqo2`,kAzted:`x2lwn1j`,kB7OPa:`x9f619`,kFalU9:`xge0x1e`,kInvED:`x1wfwxd8 x1nw7mhf`,kWkggS:`x10xzikg`,kGO01o:`x18d9i69`,$$css:!0},content:{k1xSpc:`xufnvkl`,kB7OPa:`x9f619`,kZKoxP:`x5yr21d`,kAzted:`x121v3j4`,$$css:!0},tallKeyboardBody:{kFlMNQ:`xrw9175`,k5JduY:`x1s928wv`,kc3QkE:`xhkezso`,k4zj60:`xu6fald`,kloYau:`x2q1x1w`,$$css:!0},budget:{kZKoxP:`x1tpcejd`,$$css:!0},hugHeight:{kZKoxP:`xg7h5cd`,kskxy:`x14bu9tk`,$$css:!0}};function je(e){return e.kind===`open`?e.entering?`entering`:null:e.kind===`retained`?e.motion===`covered`?null:e.motion:e.kind===`exiting`?`exiting`:null}function W(e,t,n){if(e==null)return n(),()=>{};let r=!1,i=null,a=()=>{r||(r=!0,i!=null&&clearTimeout(i),e.removeEventListener(`transitionend`,o),e.removeEventListener(`transitioncancel`,o),n())},o=n=>{n.target===e&&n.propertyName===t&&a()};e.addEventListener(`transitionend`,o),e.addEventListener(`transitioncancel`,o);let s=getComputedStyle(e);if(e.style.transition.trim()===`none`||s.transition.trim()===`none`)return a(),()=>{};let c=s.transitionProperty.split(`,`).map(e=>e.trim()),l=s.transitionDuration.split(`,`).map(G),u=s.transitionDelay.split(`,`).map(G),d=!1,f=c.reduce((e,n,r)=>{if(n!==t&&n!==`all`)return e;let i=l[r%l.length],a=u[r%u.length];return i==null||a==null?(d=!0,e):Math.max(e,i+a)},0);return d?()=>{e.removeEventListener(`transitionend`,o),e.removeEventListener(`transitioncancel`,o)}:f<=0?(a(),()=>{}):(i=setTimeout(a,f+Oe),()=>{i!=null&&clearTimeout(i),e.removeEventListener(`transitionend`,o),e.removeEventListener(`transitioncancel`,o)})}function G(e){let t=e.trim();if(!/^-?(?:\d+|\d*\.\d+)(?:ms|s)$/.test(t))return null;let n=Number.parseFloat(e);return t.endsWith(`ms`)?n:n*1e3}function Me({ref:e,state:t,height:n,label:a,children:o,padding:v,snapPoints:y,className:ee,style:S,tabIndex:T,xstyle:E,isSwipeDismissAllowed:k=!0,isPageScrollLocked:A=!1,onDismiss:j,onScrimOpacity:te,onElementChange:ne,onMotionStart:re,onMotionComplete:M,...N}){let P=(0,w.useRef)(null),ie=(0,w.useRef)(t),F=(0,w.useRef)(!1),I=(0,w.useRef)(re),L=(0,w.useRef)(M),oe=(0,w.useRef)(null),R=(0,w.useRef)(null),se=t.kind===`open`&&t.entering,ce=ie.current,le=ce.kind===`open`&&ce.entering;se&&!le?F.current=ce.kind===`retained`:se||(F.current=!1),(0,w.useLayoutEffect)(()=>{ie.current=t,I.current=re,L.current=M},[M,re,t]);let ue=t.kind===`open`,de=t.kind!==`hidden`,fe=t.kind===`retained`,pe=fe||t.kind===`exiting`,me=t.kind===`exiting`,he=fe&&t.motion===`fading`,ge=fe?t.alignmentOffset:0,_e=Ae(y),ve=(0,w.useRef)(y);ve.current=y;let{snapHeights:ye,ignoredSnapPointsMessage:be}=(0,w.useMemo)(()=>{if(_e===``)return{snapHeights:void 0,ignoredSnapPointsMessage:``};let e=(ve.current??[]).filter(e=>!D(e));return{snapHeights:()=>O(ve.current??[],ke()),ignoredSnapPointsMessage:e.length===0?``:`snapPoints ignored ${JSON.stringify(e)}. A snap point is a viewport fraction above 0 and up to 1 (0.5 is half the screen), a px length ('320px'), or a percentage ('50%').`}},[_e]);b(`BottomSheet`,be,be!==``);let{contentProps:z,handleProps:xe,bodyProps:Se,bodyElementRef:Ce,sheetRef:B,dragOffset:we,settledOffset:Oe,isDragging:G,isTraveling:Me,sheetHeight:K,scrollPreservationInset:Ne,settlingLayoutOffset:q,settledLayoutOffset:Pe,completeScrollAreaSettle:J}=V({isOpen:ue,canDismiss:k,offscreenBlockEndInset:Ee,onDismiss:j,snapHeights:ye,onScrimOpacity:te}),{getViewportProps:Fe,getContentProps:Y}=x({axis:`both`,keyboardAccess:{owner:`contentOrViewport`,label:a},overscroll:`contain`,stickyContainment:`always`}),X=(0,w.useCallback)(e=>{B(e),P.current=e,ne?.(e)},[ne,B]);ae({bodyRef:Ce,bottomClearance:De,isEnabled:n===`tall`,isFullyExpanded:Oe===0,isPageScrollLocked:A,isSheetTraveling:Me,isOpen:ue,isPresented:de,sheetRef:P}),(0,w.useImperativeHandle)(e,()=>P.current,[]);let Z=je(t);(0,w.useLayoutEffect)(()=>{if(Z!=null){if(oe.current=null,R.current=null,Z===`entering`&&F.current)R.current=Z;else return W(P.current,Z===`fading`?`opacity`:`transform`,()=>{oe.current===Z?L.current?.(Z):R.current=Z})}},[Z]),(0,w.useLayoutEffect)(()=>{if(q!=null)return W(P.current,`transform`,J)},[J,q]),(0,w.useEffect)(()=>{if(Z!=null)return I.current?.(Z),oe.current=Z,R.current===Z&&(R.current=null,L.current?.(Z)),()=>{oe.current===Z&&(oe.current=null),R.current===Z&&(R.current=null)}},[Z]);let Ie=v==null,Q=v??4,Le=s[Q],Re=typeof n==`string`&&n in Te?Te[n]:typeof n==`number`?`${n}px`:n,ze=K>0,$=z.style.transform,Be;if(ze){let e=G?we<Oe?0:Pe:q??Pe,t=(G?we:Oe)-e;Be=e>0||G||q!=null?`${Math.max(0,K-Math.max(0,e))}px`:void 0,$=t===0?void 0:`translateY(${t}px)`}let Ve=ge>0?[$,`translateY(${ge}px)`].filter(Boolean).join(` `):$,He=ue?$:fe?Ve:void 0,Ue=S?.transform;(0,w.useLayoutEffect)(()=>{if(G||Ue!=null)return;let e=P.current;e!=null&&(e.style.transform=He??``)});let We={transition:z.style.transition,touchAction:z.style.touchAction,overscrollBehavior:z.style.overscrollBehavior,height:Be};return(0,H.jsxs)(`div`,{...N,ref:X,tabIndex:T??-1,...m(i(`bottom-sheet`),r(g.reset,_.reset,U.sheet,l.reset,n===`hug`?U.hugHeight:U.budget,me&&U.sheetClosing,he&&U.sheetFading,pe&&U.sheetInactive,E),ee,{"--_sheet-budget":Re,...ue?We:fe||me?{height:Be}:{},...S}),children:[(0,H.jsx)(`div`,{className:`x10l6tqk x13vifvy x1o0tod xtijo5x x1vjfegm x78zum5 x6s0dn4 xl56j7k xvpftlf xafqdz2 x1j4r261 x1jm3nie x16khyan`,...xe,"aria-hidden":`true`,children:(0,H.jsx)(`div`,{className:`x1m747yf x11c6zpc xjspbzw x1m4xfpy`})}),(0,H.jsx)(`div`,{...Fe({...Se,...m(r(h.focusVisible,U.body,n===`tall`&&U.tallKeyboardBody),Ne>0?{style:{paddingBlockEnd:`${Ne}px`}}:{})}),children:(0,H.jsx)(`div`,{...Y(r(U.content,...C(Ie?{useThemeDefault:`bottom-sheet`}:{paddingInnerX:Le,paddingInnerY:Le,paddingOuterX:Le,paddingOuterY:Le}),!Ie&&Q!==4&&u[Q],!Ie&&Q!==4&&c[Q],!Ie&&Q!==4&&d[Q],!Ie&&Q!==4&&f[Q])),children:(0,H.jsx)(p,{children:o})})})]})}Me.displayName=`BottomSheetPanel`;function K(){return(0,H.jsx)(`div`,{className:`xixxii4 x17y0mx6 x1ey2m1c x1kpxq89 x10xzikg xhtitgo x47corl x1cb67k9 xt2iwb0`,"data-sheet-edge-tint":``,"aria-hidden":`true`})}var Ne=(0,w.createContext)(null);Ne.displayName=`BottomSheetSwitcherContext`;var q=e({BottomSheet:()=>X});function Pe(e,t){switch(e){case`active`:return{kind:`open`,entering:!1};case`entering`:return{kind:`open`,entering:!0};case`covered`:case`aligning`:case`fading`:return{kind:`retained`,motion:e,alignmentOffset:t};case`exiting`:return{kind:`exiting`};case`hidden`:return{kind:`hidden`}}}function J(e,t){let n=document.activeElement;if(n!=null&&e?.contains(n))return;let r=e?.querySelector(`[data-autofocus]`);r==null?t&&e?.focus({preventScroll:!0}):r.focus({preventScroll:!0})}function Fe({ref:e,isOpen:t,onOpenChange:n,label:r,children:i,height:a=`capped`,snapPoints:o,hasScrim:s=!0,finalFocusRef:c,purpose:l=`info`,xstyle:u,...d}){let f=(0,w.useRef)(null),p=(0,w.useRef)(null),m=(0,w.useRef)(null),[h,g]=(0,w.useState)(t),_=t||h,ee=t?{kind:`open`,entering:!1}:h?{kind:`exiting`}:{kind:`hidden`},x=(0,w.useCallback)(()=>{t&&l!==`required`&&n(!1)},[t,n,l]),C=(0,w.useCallback)(()=>{l===`info`&&n(!1)},[n,l]),T=(0,w.useCallback)(e=>{p.current=e},[]),E=(0,w.useCallback)(e=>{f.current?.style.setProperty(`--_sheet-scrim-opacity`,String(e))},[]);(0,w.useEffect)(()=>{let e=f.current;e!=null&&t&&(g(!0),e.style.setProperty(`--_sheet-scrim-opacity`,`1`),e.open||(s?(m.current=document.activeElement,e.showModal()):e.show(),J(p.current,s)))},[s,t]),(0,w.useEffect)(()=>{!t&&h&&s&&E(0)},[E,s,t,h]);let D=(0,w.useCallback)(e=>{if(e!==`exiting`||t)return;let n=f.current;n?.open&&n.close(),g(!1),(c?.current??m.current)?.focus(),m.current=null},[c,t]);S(_&&s),b(`BottomSheet`,"requires a non-empty `label` for an accessible name; the open sheet has no built-in heading to derive one from.",t&&!r);let{shouldDismissOnCloseRequest:O}=y({isActive:_,escapeBehavior:t&&l!==`required`?`close`:`block`,onDismiss:x,getContainer:()=>f.current,isPresent:()=>f.current?.open??!1}),k=(0,w.useCallback)(e=>{e.preventDefault(),O()&&x()},[x,O]),A=(0,w.useCallback)(e=>{s&&e.target===e.currentTarget&&C()},[C,s]);return(0,H.jsxs)(`dialog`,{...{0:{className:`xixxii4 x10a8y8t x1o6l61p xtdtrs8 x1x1rfll x7ab17h x1ghz6dp x1717udv xc342km xng3xce xjbqb8w x1rea2x4 x1s85apg x1a2a7pz`},8:{className:`xixxii4 x10a8y8t x1o6l61p xtdtrs8 x1x1rfll x7ab17h x1ghz6dp x1717udv xc342km xng3xce xjbqb8w x1rea2x4 x1a2a7pz x1lliihq`},4:{className:`xixxii4 x10a8y8t x1o6l61p xtdtrs8 x1x1rfll x7ab17h x1ghz6dp x1717udv xc342km xng3xce xjbqb8w x1rea2x4 x1s85apg x1a2a7pz xnixb3f xni466t xxiuuzi xc0dz0a xft5bk6 x15h3t91 x142juwg x1viac0w`},12:{className:`xixxii4 x10a8y8t x1o6l61p xtdtrs8 x1x1rfll x7ab17h x1ghz6dp x1717udv xc342km xng3xce xjbqb8w x1rea2x4 x1a2a7pz x1lliihq xnixb3f xni466t xxiuuzi xc0dz0a xft5bk6 x15h3t91 x142juwg x1viac0w`},2:{className:`xixxii4 x10a8y8t x1o6l61p xtdtrs8 x1x1rfll x7ab17h x1ghz6dp x1717udv xc342km xng3xce xjbqb8w x1rea2x4 x1s85apg x1a2a7pz x1cz9k3x`},10:{className:`xixxii4 x10a8y8t x1o6l61p xtdtrs8 x1x1rfll x7ab17h x1ghz6dp x1717udv xc342km xng3xce xjbqb8w x1rea2x4 x1a2a7pz x1lliihq x1cz9k3x`},6:{className:`xixxii4 x10a8y8t x1o6l61p xtdtrs8 x1x1rfll x7ab17h x1ghz6dp x1717udv xc342km xng3xce xjbqb8w x1rea2x4 x1s85apg x1a2a7pz xnixb3f xni466t xxiuuzi xc0dz0a xft5bk6 x142juwg x1viac0w x1cz9k3x`},14:{className:`xixxii4 x10a8y8t x1o6l61p xtdtrs8 x1x1rfll x7ab17h x1ghz6dp x1717udv xc342km xng3xce xjbqb8w x1rea2x4 x1a2a7pz x1lliihq xnixb3f xni466t xxiuuzi xc0dz0a xft5bk6 x142juwg x1viac0w x1cz9k3x`},1:{className:`xixxii4 x10a8y8t x1x1rfll x7ab17h x1ghz6dp x1717udv xc342km xng3xce xjbqb8w x1rea2x4 x1s85apg x1a2a7pz x47corl xfo81ep xh8yej3 x5yr21d`},9:{className:`xixxii4 x10a8y8t x1x1rfll x7ab17h x1ghz6dp x1717udv xc342km xng3xce xjbqb8w x1rea2x4 x1a2a7pz x1lliihq x47corl xfo81ep xh8yej3 x5yr21d`},5:{className:`xixxii4 x10a8y8t x1x1rfll x7ab17h x1ghz6dp x1717udv xc342km xng3xce xjbqb8w x1rea2x4 x1s85apg x1a2a7pz xnixb3f xni466t xxiuuzi xc0dz0a xft5bk6 x15h3t91 x142juwg x1viac0w x47corl xfo81ep xh8yej3 x5yr21d`},13:{className:`xixxii4 x10a8y8t x1x1rfll x7ab17h x1ghz6dp x1717udv xc342km xng3xce xjbqb8w x1rea2x4 x1a2a7pz x1lliihq xnixb3f xni466t xxiuuzi xc0dz0a xft5bk6 x15h3t91 x142juwg x1viac0w x47corl xfo81ep xh8yej3 x5yr21d`},3:{className:`xixxii4 x10a8y8t x1x1rfll x7ab17h x1ghz6dp x1717udv xc342km xng3xce xjbqb8w x1rea2x4 x1s85apg x1a2a7pz x1cz9k3x x47corl xfo81ep xh8yej3 x5yr21d`},11:{className:`xixxii4 x10a8y8t x1x1rfll x7ab17h x1ghz6dp x1717udv xc342km xng3xce xjbqb8w x1rea2x4 x1a2a7pz x1lliihq x1cz9k3x x47corl xfo81ep xh8yej3 x5yr21d`},7:{className:`xixxii4 x10a8y8t x1x1rfll x7ab17h x1ghz6dp x1717udv xc342km xng3xce xjbqb8w x1rea2x4 x1s85apg x1a2a7pz xnixb3f xni466t xxiuuzi xc0dz0a xft5bk6 x142juwg x1viac0w x1cz9k3x x47corl xfo81ep xh8yej3 x5yr21d`},15:{className:`xixxii4 x10a8y8t x1x1rfll x7ab17h x1ghz6dp x1717udv xc342km xng3xce xjbqb8w x1rea2x4 x1a2a7pz x1lliihq xnixb3f xni466t xxiuuzi xc0dz0a xft5bk6 x142juwg x1viac0w x1cz9k3x x47corl xfo81ep xh8yej3 x5yr21d`}}[!!_<<3|!!s<<2|!!(s&&!t&&h)<<1|!s],ref:f,"aria-label":r,"aria-hidden":!t&&h?`true`:void 0,"aria-modal":s&&t?`true`:void 0,role:l===`required`?`alertdialog`:void 0,inert:!t&&h?!0:void 0,onCancel:k,onClick:A,children:[(0,H.jsx)(`div`,{className:`x10l6tqk x17y0mx6 x1ey2m1c x78zum5 xl56j7k x47corl`,children:(0,H.jsx)(Me,{...d,ref:e,state:ee,height:a,label:r,snapPoints:o,isSwipeDismissAllowed:l===`info`,isPageScrollLocked:_&&s,xstyle:u,onDismiss:C,onScrimOpacity:E,onElementChange:T,onMotionComplete:D,children:(0,H.jsx)(v,{children:i})})}),(0,H.jsx)(K,{})]})}function Y({switcher:e,ref:t,sheetId:n,label:r,children:i,height:a=`capped`,snapPoints:o,purpose:s=`info`,xstyle:c,...l}){let{activeSheet:u,hasScrim:d,onActiveSheetChange:f,getSheetPhase:p,getSheetAlignmentOffset:m,registerSheetElement:h,registerSheetLabel:g,registerSheetPurpose:_,onSheetEnterStart:v,onSheetTransitionComplete:y,onSheetScrimOpacityChange:ee}=e,x=typeof n==`string`&&n.length>0,S=x?p(n):`hidden`,C=Pe(S,x?m(n):0),T=S===`active`||S===`entering`,E=S===`covered`||S===`aligning`||S===`fading`||S===`exiting`,D=S!==`hidden`,O=S===`active`||S===`entering`,k=(0,w.useRef)(null),A=(0,w.useRef)(S),j=A.current,te=(0,w.useRef)(!1);(0,w.useLayoutEffect)(()=>{A.current=S},[S]);let ne=(0,w.useCallback)(()=>{s===`info`&&x&&u===n&&f(null)},[u,x,f,s,n]),re=(0,w.useCallback)(e=>{k.current=e,x&&h(n,e)},[x,h,n]),M=(0,w.useCallback)(e=>{e===`entering`&&x&&v(n)},[x,v,n]),N=(0,w.useCallback)(e=>{x&&y({sheetId:n,phase:e})},[x,y,n]),P=(0,w.useCallback)(e=>{x&&ee(n,e)},[x,ee,n]);return(0,w.useLayoutEffect)(()=>{if(x)return g(n,r),()=>g(n,null)},[x,r,g,n]),(0,w.useLayoutEffect)(()=>{if(x)return _(n,s),()=>_(n,null)},[x,s,_,n]),(0,w.useEffect)(()=>{if(T){let e=j===`active`||j===`entering`;(!te.current||!e)&&J(k.current,d),te.current=!0}else S===`hidden`&&(te.current=!1)},[d,T,S,j]),b(`BottomSheet`,"requires a non-empty `label` for an accessible name; the open sheet has no built-in heading to derive one from.",T&&!r),(0,H.jsx)(`div`,{...{0:{className:`x10l6tqk x17y0mx6 x1ey2m1c x78zum5 xl56j7k x47corl`},2:{className:`x10l6tqk x17y0mx6 x1ey2m1c xl56j7k x47corl x1s85apg`},1:{className:`x10l6tqk x17y0mx6 x1ey2m1c x78zum5 xl56j7k x47corl x1vjfegm`},3:{className:`x10l6tqk x17y0mx6 x1ey2m1c xl56j7k x47corl x1s85apg x1vjfegm`}}[!D<<1|!!O],hidden:!D,"aria-hidden":E?`true`:void 0,inert:E?!0:void 0,children:(0,H.jsx)(Me,{...l,ref:t,state:C,height:a,label:r,snapPoints:o,isSwipeDismissAllowed:s===`info`,isPageScrollLocked:d,xstyle:c,onDismiss:ne,onScrimOpacity:P,onElementChange:re,onMotionStart:M,onMotionComplete:N,children:(0,H.jsx)(Ne,{value:null,children:i})})})}function X(e){let t=(0,w.use)(Ne),n=e.sheetId,r=typeof n==`string`&&n.length>0;return b(`BottomSheet`,"requires a non-empty `sheetId` when nested in BottomSheetSwitcher; standalone `isOpen` / `onOpenChange` props are ignored there.",t!=null&&!r),b(`BottomSheet`,"`sheetId` only works inside BottomSheetSwitcher. Use `isOpen` and `onOpenChange` for a standalone sheet.",t==null&&n!=null),t==null?(0,H.jsx)(Fe,{...e}):(0,H.jsx)(Y,{...e,switcher:t})}X.displayName=`BottomSheet`;export{q as n,X as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e}from"./rolldown-runtime-hePW80VL.js";import{c as t,l as n,n as r,u as i}from"./themeProps-3IqahpCr.js";import{_ as a}from"./padding.stylex-B76907Zf.js";import{t as o}from"./mergeProps-ptS-gIMz.js";import{x as s}from"./Icon-JrysT8aU.js";import{t as c}from"./container.stylex-BmOi-8DQ.js";var l=e(i(),1);function u(){return(0,l.use)(s).locale}var d=t(),f={card:{"--_card-radius":`x2kkz0m`,kaIpWk:`x153u1i6`,k7Eaqz:`xeuugli`,kVQacm:`x7giv3`,kGVxlE:`x1p8z4y0`,$$css:!0},withBorder:{kMzoRj:`x1litavf`,ksu8eU:`x1y0btm7`,kVAM5u:`x14i3s5s`,kZCmMZ:`xs19ii7`,kwRFfy:`x12frdag`,kLKAdn:`x1nex4ik`,kGO01o:`xbv1mwh`,$$css:!0},scrollable:{kVQacm:`xysyzu8`,$$css:!0}},p={default:{kWkggS:`x1de1mus`,$$css:!0},transparent:{kWkggS:`xjbqb8w`,$$css:!0},muted:{kWkggS:`xwmxj5m`,$$css:!0},blue:{kWkggS:`x1o0wnni`,$$css:!0},cyan:{kWkggS:`x1rgj867`,$$css:!0},gray:{kWkggS:`xspzpui`,$$css:!0},green:{kWkggS:`x1sqjeoo`,$$css:!0},orange:{kWkggS:`x1e9xt6e`,$$css:!0},pink:{kWkggS:`xnpoty2`,$$css:!0},purple:{kWkggS:`x16i6n6f`,$$css:!0},red:{kWkggS:`x1cibrc5`,$$css:!0},teal:{kWkggS:`x1jtji5o`,$$css:!0},yellow:{kWkggS:`x1bo7t0x`,$$css:!0}},m={none:{"--_card-elevation":`xw28qpl`,$$css:!0},low:{"--_card-elevation":`x1nn8khe`,$$css:!0},med:{"--_card-elevation":`x1ovzxg0`,$$css:!0},high:{"--_card-elevation":`xnpe7fx`,$$css:!0}},h={sizing:(e,t,n,r)=>[{kzqmXN:e==null?e:`x5lhr3w`,kZKoxP:t==null?t:`x16ye13r`,ks0D6T:n==null?n:`xf68679`,kAzted:r==null?r:`x82snj4`,$$css:!0},{"--x-width":(e=>typeof e==`number`?e+`px`:e??void 0)(e),"--x-height":(e=>typeof e==`number`?e+`px`:e??void 0)(t),"--x-maxWidth":(e=>typeof e==`number`?e+`px`:e??void 0)(n),"--x-minHeight":(e=>typeof e==`number`?e+`px`:e??void 0)(r)}]};function g({width:e,height:t,maxWidth:i,minHeight:s,children:l,padding:u,variant:g=`default`,elevation:_=`none`,xstyle:v,className:y,style:b,ref:x,...S}){let C=t!=null&&t!==`auto`,w=u==null?void 0:a[u];return(0,d.jsx)(`div`,{ref:x,...o(r(`card`,{variant:g,elevation:_}),n(f.card,p[g],m[_],C&&f.scrollable,h.sizing(e??null,t??null,i??null,s??null),...c(w==null?{useThemeDefault:`card`}:{paddingInnerX:w,paddingInnerY:w,paddingOuterX:w,paddingOuterY:w}),g==="default"&&f.withBorder,v),y,b),...S,children:l})}g.displayName=`Card`;export{u as n,g as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e}from"./rolldown-runtime-hePW80VL.js";import{c as t,u as n}from"./themeProps-3IqahpCr.js";import{t as r}from"./VStack-CkVMcNiK.js";import{n as i,t as a}from"./StackItem-CQviqAfM.js";var o=e(n(),1);function s(e,t,n){return Math.max(1,Math.floor((e+n)/(t+n)))}function c(e,t,n){let r=Array.from({length:t},()=>[]),i=Array.from({length:t},()=>0);return e.forEach((e,t)=>{let a=i.indexOf(Math.min(...i));r[a]?.push(t),i[a]=(i[a]??0)+(e??0)+n}),r}var l=t();function u(e,t,n,r){let i=Array.from({length:r});n.forEach((e,n)=>{let r=t[n]?.children;e.forEach((e,t)=>{let n=r?.[t];n instanceof HTMLElement&&(i[e]=n.offsetHeight)})});let a=Number.parseFloat(getComputedStyle(e).columnGap)||0;return{width:e.clientWidth,gap:a,heights:i}}function d(e,t){return e.width===t.width&&e.gap===t.gap&&e.heights.length===t.heights.length&&e.heights.every((e,n)=>e===t.heights[n])}function f({minWidth:e,children:t}){let n=o.Children.toArray(t),f=(0,o.useRef)(null),p=(0,o.useRef)([]),[m,h]=(0,o.useState)({width:0,gap:0,heights:[]}),g=c(n.map((e,t)=>m.heights[t]),s(m.width,e,m.gap),m.gap),_=(0,o.useRef)(g);_.current=g;let v=g.map(e=>e.join(` `)).join(`|`);return(0,o.useLayoutEffect)(()=>{let e=f.current;if(!e||!v)return;let t=()=>{let t=u(e,p.current,_.current,n.length);h(e=>d(e,t)?e:t)};t();let r=new ResizeObserver(t);r.observe(e);for(let e of p.current)for(let t of e?.children??[])r.observe(t);return()=>r.disconnect()},[v,n.length]),(0,l.jsx)(i,{ref:f,gap:3,vAlign:`start`,children:g.map((e,t)=>(0,l.jsx)(a,{size:`fill`,children:(0,l.jsx)(r,{ref:e=>{p.current[t]=e},gap:3,children:e.map(e=>n[e])})},String(t)))})}export{f as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{c as e,l as t,n}from"./themeProps-3IqahpCr.js";import{f as r,l as i,p as a,u as o}from"./padding.stylex-B76907Zf.js";import{t as s}from"./mergeProps-ptS-gIMz.js";import{t as c}from"./createReactComponent-CZwsv6DD.js";var l=c(`outline`,`external-link`,`ExternalLink`,[[`path`,{d:`M12 6h-6a2 2 0 0 0 -2 2v10a2 2 0 0 0 2 2h10a2 2 0 0 0 2 -2v-6`,key:`svg-0`}],[`path`,{d:`M11 13l9 -9`,key:`svg-1`}],[`path`,{d:`M15 4h5v5`,key:`svg-2`}]]),u=e(),d={base:{k1xSpc:`x78zum5`,$$css:!0},inline:{k1xSpc:`x3nfvp2`,$$css:!0},alignItemsCenter:{kGNEyG:`x6s0dn4`,$$css:!0},justifyContentCenter:{kjj79g:`xl56j7k`,$$css:!0}},f={sizing:(e,t,n,r)=>[{kzqmXN:e==null?e:`x5lhr3w`,kZKoxP:t==null?t:`x16ye13r`,ks0D6T:n==null?n:`xf68679`,kAzted:r==null?r:`x82snj4`,$$css:!0},{"--x-width":(e=>typeof e==`number`?e+`px`:e??void 0)(e),"--x-height":(e=>typeof e==`number`?e+`px`:e??void 0)(t),"--x-maxWidth":(e=>typeof e==`number`?e+`px`:e??void 0)(n),"--x-minHeight":(e=>typeof e==`number`?e+`px`:e??void 0)(r)}]};function p({axis:e=`both`,width:c,height:l,maxWidth:p,minHeight:m,padding:h,paddingInline:g,paddingInlineStart:_,paddingInlineEnd:v,paddingBlock:y,paddingBlockStart:b,paddingBlockEnd:x,isInline:S=!1,children:C,xstyle:w,className:T,style:E,ref:D,...O}){let k=_??g??h,A=v??g??h,j=b??y??h,M=x??y??h,N=s(n(`center`,{axis:e}),t(S?d.inline:d.base,(e===`both`||e===`vertical`)&&d.alignItemsCenter,(e===`both`||e===`horizontal`)&&d.justifyContentCenter,f.sizing(c??null,l??null,p??null,m??null),k!=null&&a[k],A!=null&&r[A],j!=null&&o[j],M!=null&&i[M],w),T,E);return(0,u.jsx)(`div`,{ref:D,...O,...N,children:C})}p.displayName=`Center`;export{l as n,p as t};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/Tooltip-BH9xiRMl.js","assets/rolldown-runtime-hePW80VL.js","assets/themeProps-3IqahpCr.js","assets/useLayerDismissal-B_G7IWpC.js","assets/useTooltip-CJM_xhLB.js","assets/tokens.stylex-DkHf0P9C.js","assets/padding.stylex-B76907Zf.js","assets/ItemSwipeLayer-Ckn4X6h9.js","assets/mergeProps-ptS-gIMz.js","assets/focusOutline.stylex-BT0kfa4t.js","assets/useMediaQuery-BCT0NUeZ.js","assets/isRtlElement-BG33-k_H.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{r as e}from"./rolldown-runtime-hePW80VL.js";import{c as t,l as n,n as r,u as i}from"./themeProps-3IqahpCr.js";import{y as a}from"./padding.stylex-B76907Zf.js";import{t as o}from"./mergeProps-ptS-gIMz.js";import{C as s,D as c,d as l,f as u,p as d,w as f}from"./groupStyles-C7Ter7zC.js";import{l as p,s as m,t as h,y as g}from"./Icon-JrysT8aU.js";import{n as _,r as v,t as y}from"./focusOutline.stylex-BT0kfa4t.js";import{a as b,i as ee,p as te}from"./IconButton-DlOGzJIX.js";import{t as ne}from"./useTooltip-CJM_xhLB.js";import{_ as x,a as re,c as S,d as C,f as w,g as T,h as ie,i as ae,l as oe,m as E,n as D,o as O,p as se,r as k,s as A,u as j}from"./Text-bum6zWWx.js";import{t as M}from"./preload-helper-DpV6A1kQ.js";import{t as N}from"./useDevWarning-Z9SoixOP.js";var P=e(i(),1),F=t(),ce=(0,P.lazy)(async()=>M(()=>import(`./Tooltip-BH9xiRMl.js`).then(e=>e.n).then(e=>({default:e.Tooltip})),__vite__mapDeps([0,1,2,3,4,5,6])));function I(e){return e===`display-1`||e===`display-2`||e===`display-3`}var L={1:`h1`,2:`h2`,3:`h3`,4:`h4`,5:`h5`,6:`h6`};function R({level:e,type:t,weight:i,accessibilityLevel:a,color:s=`primary`,display:c=`block`,maxLines:l=0,hasTruncateTooltip:u=!0,wordBreak:d,textWrap:f,justify:p=`start`,hasCapsize:m=!1,hasStrikethrough:h=!1,xstyle:g,className:_,style:v,children:y,ref:b,...ee}){let te=L[e],ne=a&&a!==e?{"aria-level":a}:{},M=d??(l===1?`break-all`:`break-word`),N=l>0||m?`block`:c,R=t&&I(t)?t:void 0,z=ae({maxLines:l}),B=typeof u==`string`?u:`above`,V=l>0&&u!==!1&&z.isTruncated,H=(0,P.useRef)(null),U=k(b,z.ref,H),W=l>1?{WebkitLineClamp:l}:void 0;return(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)(te,{ref:U,...o(r(`heading`,{level:e,color:s,type:t,weight:i}),n(O[D(s)],R?w[R]:C[e],R&&S[R],i&&T[i],l===1?E.singleLine:l>1?E.multiLine:oe[N],l>0&&x[M],f&&se[f],p!==`start`&&j[p],m&&re.enabled,h&&A.strikethrough,g),_,{...v,...W}),...ne,...ee,children:y}),V&&(0,F.jsx)(P.Suspense,{fallback:null,children:(0,F.jsx)(ce,{anchorRef:H,content:(0,F.jsx)(`span`,{...n(ie.content),children:z.fullText}),placement:B})})]})}R.displayName=`Heading`;var z={horizontal:{k1xSpc:`x78zum5`,kGNEyG:`x6s0dn4`,kzqmXN:`xh8yej3`,$$css:!0},vertical:{k1xSpc:`x3nfvp2`,kXwgrk:`xdt5ytf`,kGNEyG:`x6s0dn4`,kZKoxP:`x5yr21d`,$$css:!0}},B={horizontalLine:{kZKoxP:`xsyqizj`,kzQI83:`x1iyjqo2`,kmuXW:`xs83m0k`,$$css:!0},verticalLine:{kzqmXN:`xjk4fl7`,kzQI83:`x1iyjqo2`,kmuXW:`xs83m0k`,$$css:!0},subtle:{kWkggS:`x1m4xfpy`,$$css:!0},strong:{kWkggS:`x7njt3n`,$$css:!0}},V={horizontal:{keTefX:`xojxgvx`,k71WvV:`x1fcf3bl`,kzqmXN:`xx6qvi6`,$$css:!0},vertical:{keoZOQ:`x1sa9bsh`,k1K539:`x6h7pi7`,kZKoxP:`x12qplqi`,$$css:!0}};function H({orientation:e=`horizontal`,label:t,variant:i=`subtle`,isFullBleed:a=!1,xstyle:s,className:c,style:l,ref:u,"aria-label":d,"aria-labelledby":f,...p}){let m=e===`horizontal`,h=(0,P.useId)(),g=f??(t&&d==null?h:void 0);return(0,F.jsxs)(`div`,{ref:u,...p,role:`separator`,"aria-orientation":e,"aria-label":d,"aria-labelledby":g,...o(r(`divider`,{variant:i,orientation:e}),n(m?z.horizontal:z.vertical,a&&(m?V.horizontal:V.vertical),s),c,l),children:[(0,F.jsx)(`div`,{...n(m?B.horizontalLine:B.verticalLine,B[i])}),t&&(0,F.jsx)(`div`,{id:h,...{0:{className:`x2lah0s xrrkdod x141an7d x1ltkj2j xv1l7n4`},1:{className:`x2lah0s x141an7d x1ltkj2j xv1l7n4 xnjsko4 x8o8v82`}}[!m|0],children:t}),t&&(0,F.jsx)(`div`,{...n(m?B.horizontalLine:B.verticalLine,B[i])})]})}H.displayName=`Divider`;var U=(0,P.createContext)(null);U.displayName=`ItemDescriptionContext`;var W=[`noopener`,`noreferrer`];function le(e,t){if(e!==`_blank`)return{target:e,rel:t};let n=t?.split(/\s+/).filter(Boolean)??[];for(let e of W)n.includes(e)||n.push(e);return{target:e,rel:n.join(` `)}}var G=(0,P.lazy)(async()=>M(()=>import(`./ItemSwipeLayer-Ckn4X6h9.js`),__vite__mapDeps([7,1,2,8,9,5,10,11]))),ue=new Set([`option`,`tab`,`row`,`gridcell`,`columnheader`,`rowheader`,`treeitem`]),de=new Set([`listitem`]),K={root:{k1xSpc:`x78zum5`,kGNEyG:`x6s0dn4`,kOIVth:`x1txdalj`,"--_item-inset-inline":`xw1s368`,kg3NbH:`xaip428`,kVAEAm:`x1n2onr6`,kB7OPa:`x9f619`,k9WMMc:`x1yc453h`,kaIpWk:`xh6dtrn`,$$css:!0},alignStart:{kGNEyG:`x1cy8zhl`,$$css:!0},interactive:{kkrTdU:`x1ypdohk x16khyan`,k1ekBW:`x15406qy`,kIyJzY:`xkvfbh3`,kAMwcw:`xlr8y92`,$$css:!0},highlighted:{kWkggS:`x1lmrjuc`,$$css:!0},selected:{kWkggS:`xgcxg3y`,$$css:!0},disabled:{kkrTdU:`xt0e3qv`,kfzvcC:`x47corl`,$$css:!0},linkRoot:{kMwMTN:`x1heor9g`,kybGjl:`x1hl2dhg`,$$css:!0},inlineLabel:{kmuXW:`x2lah0s`,$$css:!0},inlineDescription:{kmuXW:`xs83m0k`,k7Eaqz:`xeuugli`,$$css:!0},label:{kMwMTN:`x5tbw38`,kGuDYH:`xjm74w1`,kLWn49:`xw6l6zx`,$$css:!0},labelSingleTruncate:{kVQacm:`xb3r6kr`,kg5iWk:`xlyipyv`,khDVqt:`xuxw1ft`,$$css:!0},labelMultiTruncate:{kVQacm:`xb3r6kr`,k1xSpc:`x104kibb`,kgKLqz:`x1ua5tub`,$$css:!0},description:{kMwMTN:`x1gb3s7i`,kGuDYH:`x141an7d`,kLWn49:`x1ltkj2j`,$$css:!0},descriptionSingleTruncate:{kVQacm:`xb3r6kr`,kg5iWk:`xlyipyv`,khDVqt:`xuxw1ft`,$$css:!0},descriptionMultiTruncate:{kVQacm:`xb3r6kr`,k1xSpc:`x104kibb`,kgKLqz:`x1ua5tub`,$$css:!0},swipeRoot:{kHBbk8:`xc8icb0`,kFalU9:`xx69xxh`,k3aq6I:`x1kncwj0`,k1ekBW:`xuo13n2`,kIyJzY:`x15p14ac`,kAMwcw:`x158wxwp`,$$css:!0}},fe={lineClamp:e=>[{kJFfOR:e==null?e:`x1yhjpo9`,$$css:!0},{"--x-WebkitLineClamp":e??void 0}]},pe={compact:{k8WAf4:`xu0wf1k`,$$css:!0},balanced:{k8WAf4:`xce4md1`,$$css:!0},spacious:{k8WAf4:`x8o8v82`,"--_item-inset-inline":`x1ytau7y`,$$css:!0}};function q({as:e=`div`,marker:t,startContent:i,label:a,description:l,endContent:u,align:d=`center`,density:f=`balanced`,labelLines:p,descriptionLines:m,layout:h=`stacked`,onClick:g,interactiveRef:_,href:y,target:ne,rel:x,isHighlighted:re=!1,isSelected:S=!1,isDisabled:C=!1,swipeActions:w,swipeBehavior:T=`reveal`,xstyle:ie,className:ae,style:oe,ref:E,role:D,...O}){let se=ee(),A=b(),j=_!=null,M=(0,P.useRef)(null),{onClick:ce}=s({containerRef:M,interactiveRef:_??void 0,disabled:C});N(`Item`,"`interactiveRef` is mutually exclusive with `onClick`/`href`. In delegation mode the row only forwards clicks to the referenced control, so `onClick`/`href` are ignored. Drop one of them.",j&&(g!=null||y!=null));let I=g!=null||y!=null||j,{target:L,rel:R}=le(ne,x),z=D!=null,B=typeof e!=`string`&&y!=null,V=w?.leading??[],H=w?.trailing??[],W=w!=null&&(V.length>0||H.length>0)&&!C&&!j&&!B&&(D==null||de.has(D));N(`Item`,'`swipeBehavior="commit"` fires only the outermost entry of a side; the other entries have no touch path. Give a committing side one entry, or use `swipeBehavior="reveal"`.',W&&T===`commit`&&(V.length>1||H.length>1));let q=(0,P.useRef)(null),J=(0,P.useRef)(null),me=(0,P.useCallback)(e=>{J.current=e},[]),Y=B?{href:C?void 0:y,target:C?void 0:L,rel:C?void 0:R}:null,he=D!=null&&ue.has(D),ge=(0,P.useId)(),_e=c(l),ve=typeof a==`string`,ye=typeof l==`string`,be=p==null?ve?K.labelSingleTruncate:null:p===1?K.labelSingleTruncate:K.labelMultiTruncate,X=h===`inline`&&l!=null,Z=m==null?ye||X?K.descriptionSingleTruncate:null:m===1?K.descriptionSingleTruncate:K.descriptionMultiTruncate,Q=(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)(`span`,{...n(K.label,X&&K.inlineLabel,be,p!=null&&p>1&&fe.lineClamp(p)),children:a}),l!=null&&(0,F.jsx)(`span`,{id:_e?ge:void 0,...n(K.description,X&&K.inlineDescription,Z,m!=null&&m>1&&fe.lineClamp(m)),children:l})]}),xe=e=>{C||e.target.closest(`button, a, input, select, textarea`)||g?.(e)},Se=(0,F.jsxs)(F.Fragment,{children:[t,i!=null&&(0,F.jsx)(`span`,{className:`x3psx0u x78zum5`,children:i}),z||j?(0,F.jsx)(`span`,{...{0:{className:`x78zum5 xdt5ytf x98rzlu xeuugli x1yc453h`},2:{className:`x78zum5 x98rzlu xeuugli x1yc453h x1q0g3np x6s0dn4 x1lfs0n9`},1:{className:`x78zum5 xdt5ytf x98rzlu xeuugli x1yc453h xbyyjgo`},3:{className:`x78zum5 x98rzlu xeuugli x1yc453h x1q0g3np x6s0dn4 x1lfs0n9 xbyyjgo`}}[!!X<<1|!!C],children:Q}):y!=null&&!B?(0,F.jsx)(A,{href:y,target:L,rel:R,"aria-disabled":C||void 0,tabIndex:C?-1:void 0,...{0:{className:`xmper1u x16khyan x1heor9g x78zum5 xdt5ytf x98rzlu xeuugli x1yc453h x1hl2dhg x1a2a7pz`},2:{className:`xmper1u x16khyan x1heor9g x78zum5 x98rzlu xeuugli x1yc453h x1hl2dhg x1a2a7pz x1q0g3np x6s0dn4 x1lfs0n9`},1:{className:`xmper1u x16khyan x1heor9g x78zum5 xdt5ytf x98rzlu xeuugli x1yc453h x1hl2dhg x1a2a7pz xbyyjgo`},3:{className:`xmper1u x16khyan x1heor9g x78zum5 x98rzlu xeuugli x1yc453h x1hl2dhg x1a2a7pz x1q0g3np x6s0dn4 x1lfs0n9 xbyyjgo`}}[!!X<<1|!!C],children:Q}):g==null?(0,F.jsx)(`span`,{...{0:{className:`x78zum5 xdt5ytf x98rzlu xeuugli x1yc453h`},2:{className:`x78zum5 x98rzlu xeuugli x1yc453h x1q0g3np x6s0dn4 x1lfs0n9`},1:{className:`x78zum5 xdt5ytf x98rzlu xeuugli x1yc453h xbyyjgo`},3:{className:`x78zum5 x98rzlu xeuugli x1yc453h x1q0g3np x6s0dn4 x1lfs0n9 xbyyjgo`}}[!!X<<1|!!C],children:Q}):(0,F.jsx)(`button`,{type:`button`,onClick:g,disabled:C,...{0:{className:`xmper1u x16khyan x1heor9g x78zum5 xdt5ytf x98rzlu xeuugli x1yc453h x1a2a7pz`},2:{className:`xmper1u x16khyan x1heor9g x78zum5 x98rzlu xeuugli x1yc453h x1a2a7pz x1q0g3np x6s0dn4 x1lfs0n9`},1:{className:`xmper1u x16khyan x1heor9g x78zum5 xdt5ytf x98rzlu xeuugli x1yc453h x1a2a7pz xbyyjgo`},3:{className:`xmper1u x16khyan x1heor9g x78zum5 x98rzlu xeuugli x1yc453h x1a2a7pz x1q0g3np x6s0dn4 x1lfs0n9 xbyyjgo`}}[!!X<<1|!!C],children:Q}),u!=null&&(0,F.jsx)(`span`,{...{0:{className:`x3psx0u x78zum5 xvc5jky`},1:{className:`x3psx0u x78zum5 xvc5jky xbyyjgo`}}[!!C|0],children:u})]}),Ce=k(E,M),we=k(j?Ce:E,W?q:void 0),Te=j?ce:z?g:I?xe:void 0,Ee=W&&Te!=null?e=>{J.current?.shouldSuppressClick()!==!0&&Te(e)}:Te,De=W?{onPointerDown:e=>J.current?.handlers.onPointerDown(e),onPointerMove:e=>J.current?.handlers.onPointerMove(e),onPointerUp:e=>J.current?.handlers.onPointerUp(e),onPointerCancel:e=>J.current?.handlers.onPointerCancel(e),onClickCapture:e=>J.current?.handlers.onClickCapture(e),onKeyDown:e=>J.current?.handlers.onKeyDown(e)}:void 0;return(0,F.jsxs)(e,{ref:we,...O,...De,...Y,"aria-selected":he&&S||void 0,"aria-current":O[`aria-current`]??(S&&!he?!0:void 0),"aria-disabled":C||void 0,...I?se:void 0,...o(r(`item`,{density:f,align:d}),v.focusWithin(K.root,pe[f],d===`start`&&K.alignStart,I&&K.interactive,I&&te.backgroundColor,B&&K.linkRoot,re&&K.highlighted,S&&K.selected,C&&!z&&K.disabled,W&&K.swipeRoot,ie),ae,oe),role:D,onClick:Ee,children:[(0,F.jsx)(U,{value:_e?ge:null,children:Se}),W&&(0,F.jsx)(P.Suspense,{fallback:null,children:(0,F.jsx)(G,{rootRef:q,onBridge:me,leading:V,trailing:H,behavior:T})})]})}q.displayName=`Item`;function J(e,t=!1){let n=(0,P.useCallback)(t=>{let n=e.current?.firstElementChild;n instanceof HTMLElement&&Object.assign(n.style,t?y:_)},[e]),r=(0,P.useCallback)(e=>{if(t)return;let r=e.target;r instanceof HTMLElement&&!r.matches(`:focus-visible`)||n(!0)},[t,n]),i=(0,P.useCallback)(()=>n(!1),[n]);return(0,P.useMemo)(()=>({focusProps:{onFocus:r,onBlur:i}}),[r,i])}var me={x1odsvnm:`x1odsvnm`,$$css:!0},Y={box:{kB7OPa:`x9f619`,k1xSpc:`x78zum5`,kGNEyG:`x6s0dn4`,kjj79g:`xl56j7k`,kmuXW:`x2lah0s`,kMzoRj:`x1litavf`,ksu8eU:`x1y0btm7`,kaIpWk:`xx3sua9`,k1ekBW:`xts7igz`,kIyJzY:`xuedmi6 x12w9bfk`,kAMwcw:`xlr8y92`,$$css:!0},unchecked:{kMwMTN:`xqwr325`,kVAM5u:`xvy26l8 xilc7fp`,kWkggS:`x10xzikg xeultfy`,$$css:!0},checked:{kMwMTN:`x17wrial`,kVAM5u:`xad5do x1ozl1p1`,kWkggS:`x1ewilqj x17srpfb`,$$css:!0},disabled:{kSiTet:`xbyyjgo`,kVAM5u:`x14i3s5s x61roa7`,$$css:!0},disabledUnchecked:{kWkggS:`xwmxj5m xqxnq6d`,$$css:!0},checkmark:{k1xSpc:`x1s85apg`,kMwMTN:`x17wrial xs5hli`,$$css:!0},checkmarkVisible:{k1xSpc:`x1lliihq`,$$css:!0},indeterminateMark:{k1xSpc:`x1s85apg`,kWkggS:`x1azo05 xwvh9j7`,kaIpWk:`xjspbzw`,$$css:!0},indeterminateMarkVisible:{k1xSpc:`x1lliihq`,$$css:!0}},he={sm:{kzqmXN:`xw4jnvo`,kZKoxP:`x1qx5ct2`,$$css:!0},md:{kzqmXN:`xvy4d1p`,kZKoxP:`xxk0z11`,$$css:!0}},ge={sm:{kzqmXN:`xsmyaan`,kZKoxP:`x1kpxq89`,$$css:!0},md:{kzqmXN:`x6jxa94`,kZKoxP:`x1v9usgg`,$$css:!0}},_e={sm:{kzqmXN:`x1fsd2vl`,kZKoxP:`x36qwtl`,$$css:!0},md:{kzqmXN:`xsmyaan`,kZKoxP:`x36qwtl`,$$css:!0}};function ve({state:e,size:t=`md`,isDisabled:i=!1,children:a,ref:s,className:l,style:u,xstyle:d,...f}){let p=e===`checked`,m=e===`indeterminate`,h=p||m;return(0,F.jsx)(`span`,{...f,ref:s,"aria-hidden":`true`,...o(r(`checkbox-indicator`,{size:t,checked:p?`checked`:m?`indeterminate`:null,disabled:i?`disabled`:null}),n(Y.box,he[t],h?Y.checked:Y.unchecked,i&&Y.disabled,i&&!h&&Y.disabledUnchecked,d),l,u),children:c(a)?a:(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)(`svg`,{viewBox:`0 0 10 10`,...o(r(`checkbox-indicator-check`,{size:t}),n(Y.checkmark,ge[t],p&&Y.checkmarkVisible)),children:(0,F.jsx)(`path`,{d:`M8.5 2.5L4 7.5L1.5 5`,stroke:`currentColor`,strokeWidth:`1.5`,fill:`none`,strokeLinecap:`round`,strokeLinejoin:`round`})}),(0,F.jsx)(`span`,{...o(r(`checkbox-indicator-dash`,{size:t}),n(Y.indeterminateMark,_e[t],m&&Y.indeterminateMarkVisible))})]})})}ve.displayName=`CheckboxIndicator`;var ye={sm:`sm`,md:`sm`},be={slot:{k1xSpc:`x3nfvp2`,kGNEyG:`x6s0dn4`,kjj79g:`xl56j7k`,kmuXW:`x2lah0s`,kzqmXN:`xcdlrvm`,kZKoxP:`x1l36t39`,$$css:!0},enabled:{kMwMTN:`xqwr325`,$$css:!0},disabled:{kMwMTN:`xqa6c3m`,$$css:!0}};function X({state:e,size:t=`md`,isDisabled:r=!1,children:i,ref:a,className:s,style:l,xstyle:u,...d}){let f=e===`checked`;return c(i)?(0,F.jsx)(`span`,{...d,ref:a,"aria-hidden":`true`,...o(n(be.slot,r?be.disabled:be.enabled,u),s,l),children:i}):f?(0,F.jsx)(h,{...d,"aria-hidden":`true`,icon:`check`,size:ye[t],color:r?`disabled`:`accent`,xstyle:u,className:s,style:l}):null}X.displayName=`CheckIndicator`;var Z={circle:{kB7OPa:`x9f619`,k1xSpc:`x78zum5`,kGNEyG:`x6s0dn4`,kjj79g:`xl56j7k`,kmuXW:`x2lah0s`,kMzoRj:`x1litavf`,ksu8eU:`x1y0btm7`,kaIpWk:`xjspbzw`,k1ekBW:`xts7igz`,kIyJzY:`xuedmi6 x12w9bfk`,kAMwcw:`xlr8y92`,$$css:!0},unchecked:{kVAM5u:`xvy26l8 xilc7fp`,kWkggS:`x10xzikg xeultfy`,$$css:!0},checked:{kVAM5u:`xad5do x1ozl1p1`,kWkggS:`x1ewilqj x17srpfb`,$$css:!0},disabled:{kSiTet:`xbyyjgo`,kVAM5u:`x14i3s5s x61roa7`,$$css:!0},disabledUnchecked:{kWkggS:`xwmxj5m xqxnq6d`,$$css:!0},dot:{kaIpWk:`xjspbzw`,kWkggS:`x1azo05 xwvh9j7`,$$css:!0}},Q={sm:{kzqmXN:`xw4jnvo`,kZKoxP:`x1qx5ct2`,$$css:!0},md:{kzqmXN:`xvy4d1p`,kZKoxP:`xxk0z11`,$$css:!0}},xe={sm:{kzqmXN:`x1xc55vz`,kZKoxP:`xdk7pt`,$$css:!0},md:{kzqmXN:`x1fsd2vl`,kZKoxP:`x170jfvy`,$$css:!0}};function Se({state:e,size:t=`md`,isDisabled:i=!1,children:a,ref:s,className:l,style:u,xstyle:d,...f}){let p=e!==`unchecked`;return(0,F.jsx)(`span`,{...f,ref:s,"aria-hidden":`true`,...o(r(`radio-indicator`,{size:t,checked:p?`checked`:null,disabled:i?`disabled`:null}),n(Z.circle,Q[t],p?Z.checked:Z.unchecked,i&&Z.disabled,i&&!p&&Z.disabledUnchecked,d),l,u),children:c(a)?a:p&&(0,F.jsx)(`span`,{...o(r(`radio-indicator-dot`,{size:t}),n(Z.dot,xe[t]))})})}Se.displayName=`RadioIndicator`;var Ce={check:X,checkbox:ve,radio:Se};function we(e){return e==null?null:typeof e==`string`?p(e):e}function Te(e){return we(e)?.indicators??null}function Ee(e,t){return Te(t)?.[e]??Ce[e]}function De(e){return Ee(e,m())}var Oe=a(null);Oe.displayName=`CheckboxListContext`;var $={container:{k1xSpc:`x78zum5`,kGNEyG:`x6s0dn4`,kOIVth:`x1txdalj`,$$css:!0},containerLabelHidden:{kOIVth:`xxhr3t`,$$css:!0},checkboxWrapper:{kVAEAm:`x1n2onr6`,k1xSpc:`x78zum5`,kGNEyG:`x6s0dn4`,kjj79g:`xl56j7k`,kmuXW:`x2lah0s`,kHBbk8:`xc8icb0`,$$css:!0},indicatorPressOverlay:{k5JduY:`x1s928wv`,kwXMNM:`x1j6awrg`,kv0HGH:`xarstr8`,kUfP38:`xtb6wbx`,kloYau:`x2q1x1w`,ks3ayO:`xyhc2n1 xzywxsk x1gybruy`,kNctxI:`x1ikgzpo xsozn46`,$$css:!0},input:{kVAEAm:`x10l6tqk`,k87sOh:`xwa60dl`,kogj98:`x1ghz6dp`,kmVPX3:`x1717udv`,kSiTet:`xg01cxk`,kkrTdU:`x1ypdohk x16khyan`,kY2c9j:`x1vjfegm`,$$css:!0},inputCoarse:{kjFi6P:`xkagaj0`,kHzOjL:`x80b3aj`,$$css:!0},inputDisabled:{kkrTdU:`xt0e3qv`,$$css:!0}},ke={sm:{kzqmXN:`xw4jnvo`,kZKoxP:`x1qx5ct2`,$$css:!0},md:{kzqmXN:`xvy4d1p`,kZKoxP:`xxk0z11`,$$css:!0}},Ae={width:e=>[{kzqmXN:e==null?e:`x5lhr3w`,$$css:!0},{"--x-width":(e=>typeof e==`number`?e+`px`:e??void 0)(e)}]};function je({label:e,isLabelHidden:t=!1,description:i,onChange:a,changeAction:s,isLoading:c=!1,value:p,isDisabled:m=!1,htmlName:h,disabledMessage:_,isReadOnly:v=!1,isOptional:y=!1,isRequired:b=!1,size:x=`md`,onFocus:re,onBlur:S,labelIcon:C,status:w,width:T,xstyle:ie,className:ae,style:oe,ref:E,"aria-describedby":D,...O}){let se=ee(),A=(0,P.useId)(),j=(0,P.useId)(),M=(0,P.useId)(),N=l({isRequired:b,isOptional:y}),[,ce]=(0,P.useTransition)(),[I,L]=(0,P.useOptimistic)(p),R=c||I!==p,z=m&&!!_,B=(0,P.use)(Oe),V=m&&(z||(B?.hasDisabledMessage??!1)),H=ne({placement:`above`,focusTrigger:`always`,isEnabled:z}),U=De(`checkbox`),W=(0,P.useRef)(null),{focusProps:le}=J(W,m),G=I===`indeterminate`,ue=I===!0,de=(0,P.useCallback)(e=>{e&&(e.indeterminate=G)},[G]),K=[];D&&K.push(D),i&&K.push(j),w?.message&&K.push(M),z&&K.push(H.describedBy);let fe=K.length>0?K.join(` `):void 0;return(0,F.jsxs)(`div`,{...o(r(`checkbox-input`,{size:x}),n(T!=null&&Ae.width(T),ie),ae,oe),children:[(0,F.jsxs)(`div`,{ref:e=>{H.interactionRef(e)},...m?void 0:se,...n($.container,t&&$.containerLabelHidden,!m&&me,!m&&te.pressedAlpha),children:[(0,F.jsxs)(`div`,{...n($.checkboxWrapper,ke[x],!m&&$.indicatorPressOverlay),...le,children:[(0,F.jsx)(`input`,{...O,ref:k(E,de,H.positionRef),id:A,type:`checkbox`,name:m?void 0:h,checked:ue,disabled:m&&!V,"aria-disabled":V?`true`:void 0,form:V?``:void 0,readOnly:v,required:b,"aria-required":N?`true`:void 0,onChange:e=>{if(m||R||v)return;let t=e.target.checked;a?.(t,e),s&&!e.defaultPrevented&&ce(async()=>{L(t),await s(t,e)})},onFocus:re,onBlur:S,"aria-readonly":v||void 0,"aria-describedby":fe,"aria-invalid":w?.type===`error`||void 0,"aria-busy":R||void 0,...n($.input,f.centerInline(`-50%`),$.inputCoarse,ke[x],m&&$.inputDisabled)}),(0,F.jsx)(`span`,{ref:W,className:`xjp7ctv`,children:(0,F.jsx)(U,{state:G?`indeterminate`:ue?`checked`:`unchecked`,size:x,isDisabled:m,children:R?(0,F.jsx)(g,{size:`sm`,shade:`inherit`}):null})})]}),(0,F.jsx)(`div`,{className:`x78zum5 xdt5ytf`,children:(0,F.jsx)(d,{...r(`checkbox-label`),label:e,inputID:A,isLabelHidden:t,isDisabled:m,isOptional:y,isRequired:b,labelIcon:C,description:i,descriptionID:j})})]}),w?.message&&(0,F.jsx)(u,{type:w.type,message:w.message,id:M,variant:`detached`}),z&&H.renderTooltip(_)]})}je.displayName=`CheckboxInput`;export{J as a,U as c,me as i,H as l,Oe as n,q as o,De as r,le as s,je as t,R as u};
|