@kumix/ui 0.4.4 → 0.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +18 -12
- package/dist/{account-avatar--0_0u0WW.js → account-avatar-BHh_21aQ.js} +1 -1
- package/dist/account-avatar-BHh_21aQ.js.map +1 -0
- package/dist/{cascader-types-Bh_kJ3Qw.d.ts → cascader-types-D2DFznHz.d.ts} +5 -5
- package/dist/cascader-types-D2DFznHz.d.ts.map +1 -0
- package/dist/components/agents/agent-activity/activity-row.d.ts +3 -2
- package/dist/components/agents/agent-activity/activity-row.d.ts.map +1 -1
- package/dist/components/agents/agent-activity/activity-row.js +24 -15
- package/dist/components/agents/agent-activity/activity-row.js.map +1 -1
- package/dist/components/agents/agent-activity/index.d.ts +3 -3
- package/dist/components/agents/agent-activity/index.d.ts.map +1 -1
- package/dist/components/agents/agent-activity/index.js +74 -28
- package/dist/components/agents/agent-activity/index.js.map +1 -1
- package/dist/components/agents/agent-code.js +1 -1
- package/dist/components/agents/agent-disclosure.js +2 -2
- package/dist/components/agents/ai-sidebar.d.ts +23 -1
- package/dist/components/agents/ai-sidebar.d.ts.map +1 -1
- package/dist/components/agents/ai-sidebar.js +53 -21
- package/dist/components/agents/ai-sidebar.js.map +1 -1
- package/dist/components/agents/approval-card/index.d.ts +24 -2
- package/dist/components/agents/approval-card/index.d.ts.map +1 -1
- package/dist/components/agents/approval-card/index.js +64 -43
- package/dist/components/agents/approval-card/index.js.map +1 -1
- package/dist/components/agents/chat-app.js +1 -1
- package/dist/components/agents/citations.d.ts +8 -1
- package/dist/components/agents/citations.d.ts.map +1 -1
- package/dist/components/agents/citations.js +15 -8
- package/dist/components/agents/citations.js.map +1 -1
- package/dist/components/agents/code-block.d.ts +11 -2
- package/dist/components/agents/code-block.d.ts.map +1 -1
- package/dist/components/agents/code-block.js +19 -9
- package/dist/components/agents/code-block.js.map +1 -1
- package/dist/components/agents/file-diff.d.ts +13 -2
- package/dist/components/agents/file-diff.d.ts.map +1 -1
- package/dist/components/agents/file-diff.js +23 -12
- package/dist/components/agents/file-diff.js.map +1 -1
- package/dist/components/agents/image-generation.d.ts +15 -1
- package/dist/components/agents/image-generation.d.ts.map +1 -1
- package/dist/components/agents/image-generation.js +23 -17
- package/dist/components/agents/image-generation.js.map +1 -1
- package/dist/components/agents/loading-states/agent-progress.d.ts +4 -1
- package/dist/components/agents/loading-states/agent-progress.d.ts.map +1 -1
- package/dist/components/agents/loading-states/agent-progress.js +30 -9
- package/dist/components/agents/loading-states/agent-progress.js.map +1 -1
- package/dist/components/agents/loading-states/reasoning-text.d.ts +4 -1
- package/dist/components/agents/loading-states/reasoning-text.d.ts.map +1 -1
- package/dist/components/agents/loading-states/reasoning-text.js +14 -12
- package/dist/components/agents/loading-states/reasoning-text.js.map +1 -1
- package/dist/components/agents/loading-states/thinking-shimmer.d.ts +4 -1
- package/dist/components/agents/loading-states/thinking-shimmer.d.ts.map +1 -1
- package/dist/components/agents/loading-states/thinking-shimmer.js +6 -3
- package/dist/components/agents/loading-states/thinking-shimmer.js.map +1 -1
- package/dist/components/agents/message-bubble.d.ts +9 -1
- package/dist/components/agents/message-bubble.d.ts.map +1 -1
- package/dist/components/agents/message-bubble.js +18 -10
- package/dist/components/agents/message-bubble.js.map +1 -1
- package/dist/components/agents/message-scroller.d.ts +12 -1
- package/dist/components/agents/message-scroller.d.ts.map +1 -1
- package/dist/components/agents/message-scroller.js +29 -10
- package/dist/components/agents/message-scroller.js.map +1 -1
- package/dist/components/agents/message.d.ts +11 -3
- package/dist/components/agents/message.d.ts.map +1 -1
- package/dist/components/agents/message.js +17 -9
- package/dist/components/agents/message.js.map +1 -1
- package/dist/components/agents/prompt-input.d.ts +13 -1
- package/dist/components/agents/prompt-input.d.ts.map +1 -1
- package/dist/components/agents/prompt-input.js +22 -12
- package/dist/components/agents/prompt-input.js.map +1 -1
- package/dist/components/agents/streaming-response.d.ts +15 -2
- package/dist/components/agents/streaming-response.d.ts.map +1 -1
- package/dist/components/agents/streaming-response.js +26 -18
- package/dist/components/agents/streaming-response.js.map +1 -1
- package/dist/components/agents/todo-list.d.ts +15 -1
- package/dist/components/agents/todo-list.d.ts.map +1 -1
- package/dist/components/agents/todo-list.js +39 -27
- package/dist/components/agents/todo-list.js.map +1 -1
- package/dist/components/agents/tool-approval.d.ts +20 -2
- package/dist/components/agents/tool-approval.d.ts.map +1 -1
- package/dist/components/agents/tool-approval.js +29 -21
- package/dist/components/agents/tool-approval.js.map +1 -1
- package/dist/components/agents/tool-result.d.ts +15 -2
- package/dist/components/agents/tool-result.d.ts.map +1 -1
- package/dist/components/agents/tool-result.js +21 -15
- package/dist/components/agents/tool-result.js.map +1 -1
- package/dist/components/agents/voice-orb.d.ts +7 -1
- package/dist/components/agents/voice-orb.d.ts.map +1 -1
- package/dist/components/agents/voice-orb.js +8 -5
- package/dist/components/agents/voice-orb.js.map +1 -1
- package/dist/components/charts/bar-chart/context.d.ts +24 -9
- package/dist/components/charts/bar-chart/context.d.ts.map +1 -1
- package/dist/components/charts/bar-chart/context.js +16 -5
- package/dist/components/charts/bar-chart/context.js.map +1 -1
- package/dist/components/charts/bar-chart/legend.js +2 -2
- package/dist/components/charts/bar-chart/legend.js.map +1 -1
- package/dist/components/charts/bar-chart/plot.js +23 -13
- package/dist/components/charts/bar-chart/plot.js.map +1 -1
- package/dist/components/charts/bar-chart/tooltip.d.ts +1 -1
- package/dist/components/charts/bar-chart/tooltip.js +5 -4
- package/dist/components/charts/bar-chart/tooltip.js.map +1 -1
- package/dist/components/charts/bar-chart.d.ts +5 -4
- package/dist/components/charts/bar-chart.d.ts.map +1 -1
- package/dist/components/charts/bar-chart.js +9 -6
- package/dist/components/charts/bar-chart.js.map +1 -1
- package/dist/components/charts/bump-chart/context.d.ts +1 -1
- package/dist/components/charts/bump-chart/context.js +1 -1
- package/dist/components/charts/bump-chart/legend.js +4 -4
- package/dist/components/charts/bump-chart/legend.js.map +1 -1
- package/dist/components/charts/bump-chart/plot.js +1 -1
- package/dist/components/charts/bump-chart/point.d.ts +1 -1
- package/dist/components/charts/bump-chart/point.js +15 -13
- package/dist/components/charts/bump-chart/point.js.map +1 -1
- package/dist/components/charts/bump-chart/series.d.ts +2 -2
- package/dist/components/charts/bump-chart/series.js +3 -3
- package/dist/components/charts/bump-chart.d.ts +2 -2
- package/dist/components/charts/bump-chart.d.ts.map +1 -1
- package/dist/components/charts/bump-chart.js +4 -4
- package/dist/components/charts/bump-chart.js.map +1 -1
- package/dist/components/charts/candlestick-chart/context.d.ts +18 -1
- package/dist/components/charts/candlestick-chart/context.d.ts.map +1 -1
- package/dist/components/charts/candlestick-chart/context.js +17 -3
- package/dist/components/charts/candlestick-chart/context.js.map +1 -1
- package/dist/components/charts/candlestick-chart/legend.d.ts +1 -1
- package/dist/components/charts/candlestick-chart/legend.js +10 -10
- package/dist/components/charts/candlestick-chart/legend.js.map +1 -1
- package/dist/components/charts/candlestick-chart/plot.d.ts.map +1 -1
- package/dist/components/charts/candlestick-chart/plot.js +16 -17
- package/dist/components/charts/candlestick-chart/plot.js.map +1 -1
- package/dist/components/charts/candlestick-chart.d.ts +2 -2
- package/dist/components/charts/candlestick-chart.js +3 -3
- package/dist/components/charts/candlestick-chart.js.map +1 -1
- package/dist/components/charts/composition-chart/context.d.ts +1 -1
- package/dist/components/charts/composition-chart/context.js +1 -1
- package/dist/components/charts/composition-chart/legend.js +4 -4
- package/dist/components/charts/composition-chart/legend.js.map +1 -1
- package/dist/components/charts/composition-chart/plot.js +9 -9
- package/dist/components/charts/composition-chart/plot.js.map +1 -1
- package/dist/components/charts/composition-chart/tooltip-content.js +4 -4
- package/dist/components/charts/composition-chart/tooltip-content.js.map +1 -1
- package/dist/components/charts/composition-chart.d.ts +2 -2
- package/dist/components/charts/composition-chart.js +3 -3
- package/dist/components/charts/composition-chart.js.map +1 -1
- package/dist/components/charts/donut-chart/center.d.ts +1 -1
- package/dist/components/charts/donut-chart/center.d.ts.map +1 -1
- package/dist/components/charts/donut-chart/center.js +7 -7
- package/dist/components/charts/donut-chart/center.js.map +1 -1
- package/dist/components/charts/donut-chart/context.d.ts +13 -2
- package/dist/components/charts/donut-chart/context.d.ts.map +1 -1
- package/dist/components/charts/donut-chart/context.js +1 -1
- package/dist/components/charts/donut-chart/legend.d.ts +1 -1
- package/dist/components/charts/donut-chart/legend.js +3 -3
- package/dist/components/charts/donut-chart/plot.js +3 -3
- package/dist/components/charts/donut-chart.d.ts +3 -3
- package/dist/components/charts/donut-chart.js +3 -3
- package/dist/components/charts/donut-chart.js.map +1 -1
- package/dist/components/charts/funnel-chart.d.ts +19 -1
- package/dist/components/charts/funnel-chart.d.ts.map +1 -1
- package/dist/components/charts/funnel-chart.js +45 -30
- package/dist/components/charts/funnel-chart.js.map +1 -1
- package/dist/components/charts/heat-calendar/grid.js +12 -5
- package/dist/components/charts/heat-calendar/grid.js.map +1 -1
- package/dist/components/charts/heat-calendar/legend.js +9 -6
- package/dist/components/charts/heat-calendar/legend.js.map +1 -1
- package/dist/components/charts/heat-calendar/tooltip.d.ts +1 -1
- package/dist/components/charts/heat-calendar/tooltip.js +10 -7
- package/dist/components/charts/heat-calendar/tooltip.js.map +1 -1
- package/dist/components/charts/heat-calendar.d.ts +2 -2
- package/dist/components/charts/heat-calendar.js +3 -3
- package/dist/components/charts/heat-calendar.js.map +1 -1
- package/dist/components/charts/line-chart/context.d.ts +21 -4
- package/dist/components/charts/line-chart/context.d.ts.map +1 -1
- package/dist/components/charts/line-chart/context.js +19 -6
- package/dist/components/charts/line-chart/context.js.map +1 -1
- package/dist/components/charts/line-chart/legend.js +2 -2
- package/dist/components/charts/line-chart/legend.js.map +1 -1
- package/dist/components/charts/line-chart/plot.js +26 -16
- package/dist/components/charts/line-chart/plot.js.map +1 -1
- package/dist/components/charts/line-chart/tooltip.d.ts +1 -1
- package/dist/components/charts/line-chart/tooltip.js +7 -6
- package/dist/components/charts/line-chart/tooltip.js.map +1 -1
- package/dist/components/charts/line-chart.d.ts +6 -5
- package/dist/components/charts/line-chart.d.ts.map +1 -1
- package/dist/components/charts/line-chart.js +9 -6
- package/dist/components/charts/line-chart.js.map +1 -1
- package/dist/components/charts/liquidity-heatmap.d.ts +17 -1
- package/dist/components/charts/liquidity-heatmap.d.ts.map +1 -1
- package/dist/components/charts/liquidity-heatmap.js +52 -27
- package/dist/components/charts/liquidity-heatmap.js.map +1 -1
- package/dist/components/charts/order-book/depth-row.d.ts +1 -1
- package/dist/components/charts/order-book/depth-row.js +2 -2
- package/dist/components/charts/order-book.d.ts +26 -1
- package/dist/components/charts/order-book.d.ts.map +1 -1
- package/dist/components/charts/order-book.js +84 -33
- package/dist/components/charts/order-book.js.map +1 -1
- package/dist/components/charts/price-target-fan/header.js +5 -5
- package/dist/components/charts/price-target-fan/header.js.map +1 -1
- package/dist/components/charts/price-target-fan/plot.d.ts.map +1 -1
- package/dist/components/charts/price-target-fan/plot.js +21 -11
- package/dist/components/charts/price-target-fan/plot.js.map +1 -1
- package/dist/components/charts/price-target-fan/series.d.ts.map +1 -1
- package/dist/components/charts/price-target-fan/series.js +11 -7
- package/dist/components/charts/price-target-fan/series.js.map +1 -1
- package/dist/components/charts/price-target-fan/tooltip.d.ts +1 -1
- package/dist/components/charts/price-target-fan/tooltip.js +2 -2
- package/dist/components/charts/price-target-fan.d.ts +2 -2
- package/dist/components/charts/price-target-fan.js +4 -4
- package/dist/components/charts/price-target-fan.js.map +1 -1
- package/dist/components/charts/returns-calendar/grid.js +16 -9
- package/dist/components/charts/returns-calendar/grid.js.map +1 -1
- package/dist/components/charts/returns-calendar/tooltip.d.ts +1 -1
- package/dist/components/charts/returns-calendar/tooltip.js +3 -3
- package/dist/components/charts/returns-calendar.d.ts +9 -2
- package/dist/components/charts/returns-calendar.d.ts.map +1 -1
- package/dist/components/charts/returns-calendar.js +3 -3
- package/dist/components/charts/returns-calendar.js.map +1 -1
- package/dist/components/charts/sankey-chart/context.d.ts +1 -1
- package/dist/components/charts/sankey-chart/context.js +1 -1
- package/dist/components/charts/sankey-chart/plot.js +9 -6
- package/dist/components/charts/sankey-chart/plot.js.map +1 -1
- package/dist/components/charts/sankey-chart/tooltip.d.ts +1 -1
- package/dist/components/charts/sankey-chart/tooltip.js +16 -19
- package/dist/components/charts/sankey-chart/tooltip.js.map +1 -1
- package/dist/components/charts/sankey-chart.d.ts +3 -3
- package/dist/components/charts/sankey-chart.d.ts.map +1 -1
- package/dist/components/charts/sankey-chart.js +16 -15
- package/dist/components/charts/sankey-chart.js.map +1 -1
- package/dist/components/charts/sparkline.d.ts +19 -2
- package/dist/components/charts/sparkline.d.ts.map +1 -1
- package/dist/components/charts/sparkline.js +34 -14
- package/dist/components/charts/sparkline.js.map +1 -1
- package/dist/components/charts/status-bar/legend.js +3 -3
- package/dist/components/charts/status-bar/legend.js.map +1 -1
- package/dist/components/charts/status-bar/plot.js +6 -6
- package/dist/components/charts/status-bar/plot.js.map +1 -1
- package/dist/components/charts/status-bar/tooltip.d.ts +1 -1
- package/dist/components/charts/status-bar/tooltip.js +2 -2
- package/dist/components/charts/status-bar.d.ts +3 -3
- package/dist/components/charts/status-bar.d.ts.map +1 -1
- package/dist/components/charts/status-bar.js +11 -9
- package/dist/components/charts/status-bar.js.map +1 -1
- package/dist/components/charts/treemap/legend.js +3 -3
- package/dist/components/charts/treemap/legend.js.map +1 -1
- package/dist/components/charts/treemap/plot.d.ts +1 -1
- package/dist/components/charts/treemap/plot.js +6 -6
- package/dist/components/charts/treemap/plot.js.map +1 -1
- package/dist/components/charts/treemap/tile.d.ts +1 -1
- package/dist/components/charts/treemap/tile.js +5 -5
- package/dist/components/charts/treemap/tile.js.map +1 -1
- package/dist/components/charts/treemap/tooltip.d.ts +1 -1
- package/dist/components/charts/treemap/tooltip.js +4 -4
- package/dist/components/charts/treemap.d.ts +21 -4
- package/dist/components/charts/treemap.d.ts.map +1 -1
- package/dist/components/charts/treemap.js +12 -10
- package/dist/components/charts/treemap.js.map +1 -1
- package/dist/components/charts/volume-profile/plot.js +7 -7
- package/dist/components/charts/volume-profile/plot.js.map +1 -1
- package/dist/components/charts/volume-profile/summary.js +15 -21
- package/dist/components/charts/volume-profile/summary.js.map +1 -1
- package/dist/components/charts/volume-profile/tooltip.d.ts +1 -1
- package/dist/components/charts/volume-profile/tooltip.js +6 -6
- package/dist/components/charts/volume-profile/tooltip.js.map +1 -1
- package/dist/components/charts/volume-profile.d.ts +29 -4
- package/dist/components/charts/volume-profile.d.ts.map +1 -1
- package/dist/components/charts/volume-profile.js +18 -22
- package/dist/components/charts/volume-profile.js.map +1 -1
- package/dist/components/charts/xy/axis.js +1 -1
- package/dist/components/charts/xy/data-table.d.ts +4 -2
- package/dist/components/charts/xy/data-table.d.ts.map +1 -1
- package/dist/components/charts/xy/data-table.js +4 -4
- package/dist/components/charts/xy/data-table.js.map +1 -1
- package/dist/components/charts/xy/legend.d.ts +1 -1
- package/dist/components/charts/xy/tooltip-content.d.ts +1 -1
- package/dist/components/charts/xy/tooltip-content.js +5 -5
- package/dist/components/charts/xy/tooltip-content.js.map +1 -1
- package/dist/components/custom/confirm-dialog.js +1 -1
- package/dist/components/custom/toast.js +1 -1
- package/dist/components/motion/action-swap.js +2 -2
- package/dist/components/motion/adaptive-stepper.d.ts +11 -1
- package/dist/components/motion/adaptive-stepper.d.ts.map +1 -1
- package/dist/components/motion/adaptive-stepper.js +26 -16
- package/dist/components/motion/adaptive-stepper.js.map +1 -1
- package/dist/components/motion/alert.d.ts +8 -1
- package/dist/components/motion/alert.d.ts.map +1 -1
- package/dist/components/motion/alert.js +16 -10
- package/dist/components/motion/alert.js.map +1 -1
- package/dist/components/motion/animated-badge.js +5 -5
- package/dist/components/motion/animated-number.js +2 -2
- package/dist/components/motion/animated-sidebar.d.ts +12 -1
- package/dist/components/motion/animated-sidebar.d.ts.map +1 -1
- package/dist/components/motion/animated-sidebar.js +24 -14
- package/dist/components/motion/animated-sidebar.js.map +1 -1
- package/dist/components/motion/animated-toast-stack.d.ts +8 -1
- package/dist/components/motion/animated-toast-stack.d.ts.map +1 -1
- package/dist/components/motion/animated-toast-stack.js +14 -9
- package/dist/components/motion/animated-toast-stack.js.map +1 -1
- package/dist/components/motion/arc-picker.d.ts +11 -1
- package/dist/components/motion/arc-picker.d.ts.map +1 -1
- package/dist/components/motion/arc-picker.js +20 -13
- package/dist/components/motion/arc-picker.js.map +1 -1
- package/dist/components/motion/aspect-ratio.js +2 -2
- package/dist/components/motion/attachment-upload.d.ts +32 -1
- package/dist/components/motion/attachment-upload.d.ts.map +1 -1
- package/dist/components/motion/attachment-upload.js +106 -52
- package/dist/components/motion/attachment-upload.js.map +1 -1
- package/dist/components/motion/availability-scheduler/copy-menu.d.ts +5 -2
- package/dist/components/motion/availability-scheduler/copy-menu.d.ts.map +1 -1
- package/dist/components/motion/availability-scheduler/copy-menu.js +1 -1
- package/dist/components/motion/availability-scheduler/day-row.d.ts +4 -2
- package/dist/components/motion/availability-scheduler/day-row.d.ts.map +1 -1
- package/dist/components/motion/availability-scheduler/day-row.js +23 -15
- package/dist/components/motion/availability-scheduler/day-row.js.map +1 -1
- package/dist/components/motion/availability-scheduler/icon-button.js +2 -2
- package/dist/components/motion/availability-scheduler/index.d.ts +6 -3
- package/dist/components/motion/availability-scheduler/index.d.ts.map +1 -1
- package/dist/components/motion/availability-scheduler/index.js +30 -8
- package/dist/components/motion/availability-scheduler/index.js.map +1 -1
- package/dist/components/motion/availability-scheduler/time-select.d.ts +1 -1
- package/dist/components/motion/avatar-group.d.ts +10 -1
- package/dist/components/motion/avatar-group.d.ts.map +1 -1
- package/dist/components/motion/avatar-group.js +18 -9
- package/dist/components/motion/avatar-group.js.map +1 -1
- package/dist/components/motion/before-after-slider.d.ts +35 -0
- package/dist/components/motion/before-after-slider.d.ts.map +1 -0
- package/dist/components/motion/before-after-slider.js +352 -0
- package/dist/components/motion/before-after-slider.js.map +1 -0
- package/dist/components/motion/bloom-menu.d.ts +15 -1
- package/dist/components/motion/bloom-menu.d.ts.map +1 -1
- package/dist/components/motion/bloom-menu.js +32 -11
- package/dist/components/motion/bloom-menu.js.map +1 -1
- package/dist/components/motion/bookshelf.d.ts +46 -0
- package/dist/components/motion/bookshelf.d.ts.map +1 -0
- package/dist/components/motion/bookshelf.js +518 -0
- package/dist/components/motion/bookshelf.js.map +1 -0
- package/dist/components/motion/bottom-sheet.d.ts +9 -1
- package/dist/components/motion/bottom-sheet.d.ts.map +1 -1
- package/dist/components/motion/bottom-sheet.js +16 -13
- package/dist/components/motion/bottom-sheet.js.map +1 -1
- package/dist/components/motion/bounce-sidebar.d.ts +8 -1
- package/dist/components/motion/bounce-sidebar.d.ts.map +1 -1
- package/dist/components/motion/bounce-sidebar.js +8 -4
- package/dist/components/motion/bounce-sidebar.js.map +1 -1
- package/dist/components/motion/bouncy-accordion.d.ts.map +1 -1
- package/dist/components/motion/bouncy-accordion.js +45 -36
- package/dist/components/motion/bouncy-accordion.js.map +1 -1
- package/dist/components/motion/breadcrumb.d.ts +11 -2
- package/dist/components/motion/breadcrumb.d.ts.map +1 -1
- package/dist/components/motion/breadcrumb.js +29 -14
- package/dist/components/motion/breadcrumb.js.map +1 -1
- package/dist/components/motion/button/base.js +3 -3
- package/dist/components/motion/button/index.d.ts +2 -2
- package/dist/components/motion/button/index.js +2 -2
- package/dist/components/motion/button/magnetic.js +1 -1
- package/dist/components/motion/button/metallic.js +7 -7
- package/dist/components/motion/button/metallic.js.map +1 -1
- package/dist/components/motion/button/stateful.d.ts +10 -1
- package/dist/components/motion/button/stateful.d.ts.map +1 -1
- package/dist/components/motion/button/stateful.js +14 -6
- package/dist/components/motion/button/stateful.js.map +1 -1
- package/dist/components/motion/card-dealer.d.ts +8 -1
- package/dist/components/motion/card-dealer.d.ts.map +1 -1
- package/dist/components/motion/card-dealer.js +13 -9
- package/dist/components/motion/card-dealer.js.map +1 -1
- package/dist/components/motion/card-folder.d.ts +14 -1
- package/dist/components/motion/card-folder.d.ts.map +1 -1
- package/dist/components/motion/card-folder.js +27 -11
- package/dist/components/motion/card-folder.js.map +1 -1
- package/dist/components/motion/card.js +2 -2
- package/dist/components/motion/casino/game-parts.d.ts +2 -0
- package/dist/components/motion/casino/game-parts.js +207 -0
- package/dist/components/motion/casino/game-parts.js.map +1 -0
- package/dist/components/motion/center-morph-modal.d.ts +9 -1
- package/dist/components/motion/center-morph-modal.d.ts.map +1 -1
- package/dist/components/motion/center-morph-modal.js +22 -11
- package/dist/components/motion/center-morph-modal.js.map +1 -1
- package/dist/components/motion/checkbox.d.ts +9 -1
- package/dist/components/motion/checkbox.d.ts.map +1 -1
- package/dist/components/motion/checkbox.js +12 -5
- package/dist/components/motion/checkbox.js.map +1 -1
- package/dist/components/motion/chromatic-text-reveal.js +2 -2
- package/dist/components/motion/collapsible.js +3 -3
- package/dist/components/motion/color-picker.d.ts +23 -1
- package/dist/components/motion/color-picker.d.ts.map +1 -1
- package/dist/components/motion/color-picker.js +72 -37
- package/dist/components/motion/color-picker.js.map +1 -1
- package/dist/components/motion/color-selector.js +2 -2
- package/dist/components/motion/combobox/content.js +4 -4
- package/dist/components/motion/combobox/context.d.ts +2 -66
- package/dist/components/motion/combobox/context.js +1 -216
- package/dist/components/motion/combobox/list.d.ts.map +1 -1
- package/dist/components/motion/combobox/list.js +10 -9
- package/dist/components/motion/combobox/list.js.map +1 -1
- package/dist/components/motion/combobox/trigger.d.ts.map +1 -1
- package/dist/components/motion/combobox/trigger.js +8 -7
- package/dist/components/motion/combobox/trigger.js.map +1 -1
- package/dist/components/motion/combobox.d.ts +2 -2
- package/dist/components/motion/combobox.js +2 -2
- package/dist/components/motion/command-palette.d.ts +13 -1
- package/dist/components/motion/command-palette.d.ts.map +1 -1
- package/dist/components/motion/command-palette.js +28 -13
- package/dist/components/motion/command-palette.js.map +1 -1
- package/dist/components/motion/context-menu.d.ts +8 -1
- package/dist/components/motion/context-menu.d.ts.map +1 -1
- package/dist/components/motion/context-menu.js +17 -11
- package/dist/components/motion/context-menu.js.map +1 -1
- package/dist/components/motion/crash/crash-balloon.d.ts +10 -0
- package/dist/components/motion/crash/crash-balloon.d.ts.map +1 -0
- package/dist/components/motion/crash/crash-balloon.js +831 -0
- package/dist/components/motion/crash/crash-balloon.js.map +1 -0
- package/dist/components/motion/crash/crash-parts.d.ts +55 -0
- package/dist/components/motion/crash/crash-parts.d.ts.map +1 -0
- package/dist/components/motion/crash/crash-parts.js +4 -0
- package/dist/components/motion/crash/crash-tower.d.ts +10 -0
- package/dist/components/motion/crash/crash-tower.d.ts.map +1 -0
- package/dist/components/motion/crash/crash-tower.js +371 -0
- package/dist/components/motion/crash/crash-tower.js.map +1 -0
- package/dist/components/motion/crash.d.ts +10 -0
- package/dist/components/motion/crash.d.ts.map +1 -0
- package/dist/components/motion/crash.js +592 -0
- package/dist/components/motion/crash.js.map +1 -0
- package/dist/components/motion/cylinder-carousel.d.ts +8 -1
- package/dist/components/motion/cylinder-carousel.d.ts.map +1 -1
- package/dist/components/motion/cylinder-carousel.js +13 -7
- package/dist/components/motion/cylinder-carousel.js.map +1 -1
- package/dist/components/motion/date-range-picker.d.ts +37 -3
- package/dist/components/motion/date-range-picker.d.ts.map +1 -1
- package/dist/components/motion/date-range-picker.js +80 -32
- package/dist/components/motion/date-range-picker.js.map +1 -1
- package/dist/components/motion/digit-swap.js +2 -2
- package/dist/components/motion/dock.js +2 -2
- package/dist/components/motion/drawer.d.ts +8 -1
- package/dist/components/motion/drawer.d.ts.map +1 -1
- package/dist/components/motion/drawer.js +11 -7
- package/dist/components/motion/drawer.js.map +1 -1
- package/dist/components/motion/dropdown-menu.d.ts +99 -0
- package/dist/components/motion/dropdown-menu.d.ts.map +1 -0
- package/dist/components/motion/dropdown-menu.js +708 -0
- package/dist/components/motion/dropdown-menu.js.map +1 -0
- package/dist/components/motion/dynamic-island.js +2 -2
- package/dist/components/motion/expandable-action-bar.js +3 -3
- package/dist/components/motion/expandable-control.js +5 -2
- package/dist/components/motion/expandable-control.js.map +1 -1
- package/dist/components/motion/expandable-tabs.d.ts +8 -1
- package/dist/components/motion/expandable-tabs.d.ts.map +1 -1
- package/dist/components/motion/expandable-tabs.js +9 -5
- package/dist/components/motion/expandable-tabs.js.map +1 -1
- package/dist/components/motion/expanding-arrow-button.js +3 -3
- package/dist/components/motion/feedback-widget.d.ts +18 -1
- package/dist/components/motion/feedback-widget.d.ts.map +1 -1
- package/dist/components/motion/feedback-widget.js +33 -16
- package/dist/components/motion/feedback-widget.js.map +1 -1
- package/dist/components/motion/file-tree.d.ts +8 -1
- package/dist/components/motion/file-tree.d.ts.map +1 -1
- package/dist/components/motion/file-tree.js +11 -11
- package/dist/components/motion/file-tree.js.map +1 -1
- package/dist/components/motion/file-upload.d.ts +20 -1
- package/dist/components/motion/file-upload.d.ts.map +1 -1
- package/dist/components/motion/file-upload.js +63 -31
- package/dist/components/motion/file-upload.js.map +1 -1
- package/dist/components/motion/hold-action-button.d.ts +8 -0
- package/dist/components/motion/hold-action-button.d.ts.map +1 -1
- package/dist/components/motion/hold-action-button.js +20 -8
- package/dist/components/motion/hold-action-button.js.map +1 -1
- package/dist/components/motion/infinite-masonry.d.ts +13 -1
- package/dist/components/motion/infinite-masonry.d.ts.map +1 -1
- package/dist/components/motion/infinite-masonry.js +30 -15
- package/dist/components/motion/infinite-masonry.js.map +1 -1
- package/dist/components/motion/input.js +1 -1
- package/dist/components/motion/knockout-bracket.d.ts +21 -2
- package/dist/components/motion/knockout-bracket.d.ts.map +1 -1
- package/dist/components/motion/knockout-bracket.js +78 -33
- package/dist/components/motion/knockout-bracket.js.map +1 -1
- package/dist/components/motion/knockout-wheel.d.ts +14 -1
- package/dist/components/motion/knockout-wheel.d.ts.map +1 -1
- package/dist/components/motion/knockout-wheel.js +46 -20
- package/dist/components/motion/knockout-wheel.js.map +1 -1
- package/dist/components/motion/liquid.js +2 -2
- package/dist/components/motion/loader.d.ts +10 -1
- package/dist/components/motion/loader.d.ts.map +1 -1
- package/dist/components/motion/loader.js +49 -34
- package/dist/components/motion/loader.js.map +1 -1
- package/dist/components/motion/magnetic.js +3 -3
- package/dist/components/motion/mines.d.ts +80 -0
- package/dist/components/motion/mines.d.ts.map +1 -0
- package/dist/components/motion/mines.js +797 -0
- package/dist/components/motion/mines.js.map +1 -0
- package/dist/components/motion/morphing-lightbox.d.ts +17 -1
- package/dist/components/motion/morphing-lightbox.d.ts.map +1 -1
- package/dist/components/motion/morphing-lightbox.js +39 -22
- package/dist/components/motion/morphing-lightbox.js.map +1 -1
- package/dist/components/motion/morphing-modal.d.ts +8 -1
- package/dist/components/motion/morphing-modal.d.ts.map +1 -1
- package/dist/components/motion/morphing-modal.js +12 -8
- package/dist/components/motion/morphing-modal.js.map +1 -1
- package/dist/components/motion/morphing-search-chips.d.ts +22 -1
- package/dist/components/motion/morphing-search-chips.d.ts.map +1 -1
- package/dist/components/motion/morphing-search-chips.js +41 -19
- package/dist/components/motion/morphing-search-chips.js.map +1 -1
- package/dist/components/motion/morphing-search.d.ts +12 -1
- package/dist/components/motion/morphing-search.d.ts.map +1 -1
- package/dist/components/motion/morphing-search.js +27 -13
- package/dist/components/motion/morphing-search.js.map +1 -1
- package/dist/components/motion/morphing-tabs.d.ts +9 -1
- package/dist/components/motion/morphing-tabs.d.ts.map +1 -1
- package/dist/components/motion/morphing-tabs.js +40 -16
- package/dist/components/motion/morphing-tabs.js.map +1 -1
- package/dist/components/motion/multi-select/content.js +4 -4
- package/dist/components/motion/multi-select/context.d.ts +2 -61
- package/dist/components/motion/multi-select/context.js +1 -226
- package/dist/components/motion/multi-select/index.d.ts +2 -2
- package/dist/components/motion/multi-select/index.js +2 -2
- package/dist/components/motion/multi-select/list.d.ts.map +1 -1
- package/dist/components/motion/multi-select/list.js +10 -9
- package/dist/components/motion/multi-select/list.js.map +1 -1
- package/dist/components/motion/multi-select/trigger.js +11 -10
- package/dist/components/motion/multi-select/trigger.js.map +1 -1
- package/dist/components/motion/not-found/glitch.d.ts +1 -1
- package/dist/components/motion/not-found/glitch.d.ts.map +1 -1
- package/dist/components/motion/not-found/glitch.js +8 -6
- package/dist/components/motion/not-found/glitch.js.map +1 -1
- package/dist/components/motion/not-found/magnetic.d.ts +1 -1
- package/dist/components/motion/not-found/magnetic.d.ts.map +1 -1
- package/dist/components/motion/not-found/magnetic.js +8 -6
- package/dist/components/motion/not-found/magnetic.js.map +1 -1
- package/dist/components/motion/not-found/shared.d.ts +16 -6
- package/dist/components/motion/not-found/shared.d.ts.map +1 -1
- package/dist/components/motion/not-found/shared.js +20 -9
- package/dist/components/motion/not-found/shared.js.map +1 -1
- package/dist/components/motion/not-found/spotlight.d.ts +1 -1
- package/dist/components/motion/not-found/spotlight.d.ts.map +1 -1
- package/dist/components/motion/not-found/spotlight.js +9 -7
- package/dist/components/motion/not-found/spotlight.js.map +1 -1
- package/dist/components/motion/not-found/stacked.d.ts +1 -1
- package/dist/components/motion/not-found/stacked.d.ts.map +1 -1
- package/dist/components/motion/not-found/stacked.js +9 -7
- package/dist/components/motion/not-found/stacked.js.map +1 -1
- package/dist/components/motion/not-found/terminal.d.ts +1 -1
- package/dist/components/motion/not-found/terminal.d.ts.map +1 -1
- package/dist/components/motion/not-found/terminal.js +8 -6
- package/dist/components/motion/not-found/terminal.js.map +1 -1
- package/dist/components/motion/notification-stack.d.ts +12 -1
- package/dist/components/motion/notification-stack.d.ts.map +1 -1
- package/dist/components/motion/notification-stack.js +23 -7
- package/dist/components/motion/notification-stack.js.map +1 -1
- package/dist/components/motion/number-ticker.d.ts +5 -2
- package/dist/components/motion/number-ticker.d.ts.map +1 -1
- package/dist/components/motion/number-ticker.js +7 -4
- package/dist/components/motion/number-ticker.js.map +1 -1
- package/dist/components/motion/otp-input.d.ts +16 -1
- package/dist/components/motion/otp-input.d.ts.map +1 -1
- package/dist/components/motion/otp-input.js +34 -9
- package/dist/components/motion/otp-input.js.map +1 -1
- package/dist/components/motion/overflow-actions.d.ts +9 -1
- package/dist/components/motion/overflow-actions.d.ts.map +1 -1
- package/dist/components/motion/overflow-actions.js +16 -8
- package/dist/components/motion/overflow-actions.js.map +1 -1
- package/dist/components/motion/pagination.d.ts +13 -1
- package/dist/components/motion/pagination.d.ts.map +1 -1
- package/dist/components/motion/pagination.js +22 -11
- package/dist/components/motion/pagination.js.map +1 -1
- package/dist/components/motion/parallax.js +1 -1
- package/dist/components/motion/plinko.d.ts +70 -0
- package/dist/components/motion/plinko.d.ts.map +1 -0
- package/dist/components/motion/plinko.js +399 -0
- package/dist/components/motion/plinko.js.map +1 -0
- package/dist/components/motion/popover-morph.js +6 -6
- package/dist/components/motion/popover-morph.js.map +1 -1
- package/dist/components/motion/popover.js +5 -5
- package/dist/components/motion/popover.js.map +1 -1
- package/dist/components/motion/prediction-market-card.d.ts +15 -1
- package/dist/components/motion/prediction-market-card.d.ts.map +1 -1
- package/dist/components/motion/prediction-market-card.js +32 -15
- package/dist/components/motion/prediction-market-card.js.map +1 -1
- package/dist/components/motion/prediction-market.d.ts +24 -1
- package/dist/components/motion/prediction-market.d.ts.map +1 -1
- package/dist/components/motion/prediction-market.js +56 -37
- package/dist/components/motion/prediction-market.js.map +1 -1
- package/dist/components/motion/preview-rail.d.ts +8 -1
- package/dist/components/motion/preview-rail.d.ts.map +1 -1
- package/dist/components/motion/preview-rail.js +10 -5
- package/dist/components/motion/preview-rail.js.map +1 -1
- package/dist/components/motion/project-folder.d.ts +17 -1
- package/dist/components/motion/project-folder.d.ts.map +1 -1
- package/dist/components/motion/project-folder.js +21 -10
- package/dist/components/motion/project-folder.js.map +1 -1
- package/dist/components/motion/pull-to-refresh.d.ts +11 -1
- package/dist/components/motion/pull-to-refresh.d.ts.map +1 -1
- package/dist/components/motion/pull-to-refresh.js +21 -10
- package/dist/components/motion/pull-to-refresh.js.map +1 -1
- package/dist/components/motion/radio.js +2 -2
- package/dist/components/motion/range-slider-bubble.js +3 -3
- package/dist/components/motion/range-slider-fluid.js +3 -3
- package/dist/components/motion/range-slider-inline.js +3 -3
- package/dist/components/motion/range-slider-ruler.js +3 -3
- package/dist/components/motion/range-slider-ruler.js.map +1 -1
- package/dist/components/motion/range-slider-wave.js +3 -3
- package/dist/components/motion/range-slider.js +3 -3
- package/dist/components/motion/scroll-progress.js +2 -2
- package/dist/components/motion/scroll-reveal.js +2 -2
- package/dist/components/motion/scroll-to.d.ts +1 -1
- package/dist/components/motion/scroll-to.js +1 -1
- package/dist/components/motion/select-morph.d.ts +1 -1
- package/dist/components/motion/select-morph.js +4 -4
- package/dist/components/motion/select-morph.js.map +1 -1
- package/dist/components/motion/select.js +4 -4
- package/dist/components/motion/shader-background.js +2 -2
- package/dist/components/motion/shared-layout-bg.js +4 -4
- package/dist/components/motion/shared-layout-bg.js.map +1 -1
- package/dist/components/motion/signup-form.d.ts +38 -1
- package/dist/components/motion/signup-form.d.ts.map +1 -1
- package/dist/components/motion/signup-form.js +80 -38
- package/dist/components/motion/signup-form.js.map +1 -1
- package/dist/components/motion/slide-action-button.d.ts +9 -1
- package/dist/components/motion/slide-action-button.d.ts.map +1 -1
- package/dist/components/motion/slide-action-button.js +15 -9
- package/dist/components/motion/slide-action-button.js.map +1 -1
- package/dist/components/motion/slide-game.d.ts +91 -0
- package/dist/components/motion/slide-game.d.ts.map +1 -0
- package/dist/components/motion/slide-game.js +642 -0
- package/dist/components/motion/slide-game.js.map +1 -0
- package/dist/components/motion/smooth-scroll.d.ts +1 -1
- package/dist/components/motion/smooth-scroll.js +5 -4
- package/dist/components/motion/smooth-scroll.js.map +1 -1
- package/dist/components/motion/sortable-list.d.ts +13 -1
- package/dist/components/motion/sortable-list.d.ts.map +1 -1
- package/dist/components/motion/sortable-list.js +39 -14
- package/dist/components/motion/sortable-list.js.map +1 -1
- package/dist/components/motion/swap/controls.d.ts +8 -4
- package/dist/components/motion/swap/controls.d.ts.map +1 -1
- package/dist/components/motion/swap/controls.js +20 -12
- package/dist/components/motion/swap/controls.js.map +1 -1
- package/dist/components/motion/swap/field.d.ts +4 -2
- package/dist/components/motion/swap/field.d.ts.map +1 -1
- package/dist/components/motion/swap/field.js +9 -7
- package/dist/components/motion/swap/field.js.map +1 -1
- package/dist/components/motion/swap/quote-row.d.ts +4 -2
- package/dist/components/motion/swap/quote-row.d.ts.map +1 -1
- package/dist/components/motion/swap/quote-row.js +9 -7
- package/dist/components/motion/swap/quote-row.js.map +1 -1
- package/dist/components/motion/swap/token-badges.d.ts +1 -1
- package/dist/components/motion/swap/token-badges.js +1 -1
- package/dist/components/motion/swap/token-badges.js.map +1 -1
- package/dist/components/motion/swap/token-picker.d.ts +4 -2
- package/dist/components/motion/swap/token-picker.d.ts.map +1 -1
- package/dist/components/motion/swap/token-picker.js +39 -37
- package/dist/components/motion/swap/token-picker.js.map +1 -1
- package/dist/components/motion/swap.d.ts +7 -4
- package/dist/components/motion/swap.d.ts.map +1 -1
- package/dist/components/motion/swap.js +30 -18
- package/dist/components/motion/swap.js.map +1 -1
- package/dist/components/motion/swipeable-list.d.ts +9 -1
- package/dist/components/motion/swipeable-list.d.ts.map +1 -1
- package/dist/components/motion/swipeable-list.js +17 -9
- package/dist/components/motion/swipeable-list.js.map +1 -1
- package/dist/components/motion/switch.js +3 -7
- package/dist/components/motion/switch.js.map +1 -1
- package/dist/components/motion/table/editable-cell.d.ts +2 -1
- package/dist/components/motion/table/editable-cell.d.ts.map +1 -1
- package/dist/components/motion/table/editable-cell.js +2 -2
- package/dist/components/motion/table/editable-cell.js.map +1 -1
- package/dist/components/motion/table/index.d.ts +4 -3
- package/dist/components/motion/table/index.d.ts.map +1 -1
- package/dist/components/motion/table/index.js +44 -13
- package/dist/components/motion/table/index.js.map +1 -1
- package/dist/components/motion/table/row-handle.d.ts +3 -1
- package/dist/components/motion/table/row-handle.d.ts.map +1 -1
- package/dist/components/motion/table/row-handle.js +7 -7
- package/dist/components/motion/table/row-handle.js.map +1 -1
- package/dist/components/motion/table/skeleton-rows.d.ts +1 -1
- package/dist/components/motion/table/skeleton-rows.js +1 -1
- package/dist/components/motion/table/table-header.d.ts +4 -2
- package/dist/components/motion/table/table-header.d.ts.map +1 -1
- package/dist/components/motion/table/table-header.js +22 -19
- package/dist/components/motion/table/table-header.js.map +1 -1
- package/dist/components/motion/table/table-menu.js +3 -3
- package/dist/components/motion/tabs.d.ts +9 -1
- package/dist/components/motion/tabs.d.ts.map +1 -1
- package/dist/components/motion/tabs.js +19 -10
- package/dist/components/motion/tabs.js.map +1 -1
- package/dist/components/motion/text-reveal.js +2 -2
- package/dist/components/motion/text-scramble.js +1 -1
- package/dist/components/motion/text-shimmer.js +1 -1
- package/dist/components/motion/theme-toggle.d.ts +9 -1
- package/dist/components/motion/theme-toggle.d.ts.map +1 -1
- package/dist/components/motion/theme-toggle.js +15 -8
- package/dist/components/motion/theme-toggle.js.map +1 -1
- package/dist/components/motion/tilt-card.js +3 -3
- package/dist/components/motion/timeline.d.ts +9 -1
- package/dist/components/motion/timeline.d.ts.map +1 -1
- package/dist/components/motion/timeline.js +26 -7
- package/dist/components/motion/timeline.js.map +1 -1
- package/dist/components/motion/tooltip/positioner.d.ts +1 -1
- package/dist/components/motion/tooltip/positioner.js +1 -1
- package/dist/components/motion/tooltip-surface.d.ts +1 -2
- package/dist/components/motion/tooltip-surface.d.ts.map +1 -1
- package/dist/components/motion/tooltip-surface.js +3 -3
- package/dist/components/motion/tooltip-surface.js.map +1 -1
- package/dist/components/motion/tooltip.d.ts +1 -1
- package/dist/components/motion/tooltip.js +1 -1
- package/dist/components/motion/wallet-card/account-avatar.d.ts +1 -1
- package/dist/components/motion/wallet-card/account-avatar.js +1 -1
- package/dist/components/motion/wallet-card/account-switcher.d.ts +4 -2
- package/dist/components/motion/wallet-card/account-switcher.d.ts.map +1 -1
- package/dist/components/motion/wallet-card/account-switcher.js +17 -10
- package/dist/components/motion/wallet-card/account-switcher.js.map +1 -1
- package/dist/components/motion/wallet-card/actions.d.ts +3 -1
- package/dist/components/motion/wallet-card/actions.d.ts.map +1 -1
- package/dist/components/motion/wallet-card/actions.js +33 -29
- package/dist/components/motion/wallet-card/actions.js.map +1 -1
- package/dist/components/motion/wallet-card/balance-delta.d.ts +2 -1
- package/dist/components/motion/wallet-card/balance-delta.d.ts.map +1 -1
- package/dist/components/motion/wallet-card/balance-delta.js +5 -5
- package/dist/components/motion/wallet-card/balance-delta.js.map +1 -1
- package/dist/components/motion/wallet-card/copy-button.d.ts +3 -1
- package/dist/components/motion/wallet-card/copy-button.d.ts.map +1 -1
- package/dist/components/motion/wallet-card/copy-button.js +12 -6
- package/dist/components/motion/wallet-card/copy-button.js.map +1 -1
- package/dist/components/motion/wallet-card/index.d.ts +8 -3
- package/dist/components/motion/wallet-card/index.d.ts.map +1 -1
- package/dist/components/motion/wallet-card/index.js +19 -13
- package/dist/components/motion/wallet-card/index.js.map +1 -1
- package/dist/components/motion/wallet-card/search-bar.d.ts +3 -1
- package/dist/components/motion/wallet-card/search-bar.d.ts.map +1 -1
- package/dist/components/motion/wallet-card/search-bar.js +14 -11
- package/dist/components/motion/wallet-card/search-bar.js.map +1 -1
- package/dist/components/motion/wheel-picker.js +3 -3
- package/dist/components/reui/alert.d.ts +1 -1
- package/dist/components/reui/alert.js +1 -1
- package/dist/components/reui/autocomplete.d.ts +2 -2
- package/dist/components/reui/autocomplete.js +4 -4
- package/dist/components/reui/badge.d.ts +3 -3
- package/dist/components/reui/badge.js +2 -2
- package/dist/components/reui/cascader/cascader-async.d.ts +1 -1
- package/dist/components/reui/cascader/cascader-async.js +37 -37
- package/dist/components/reui/cascader/cascader-async.js.map +1 -1
- package/dist/components/reui/cascader/cascader-columns.d.ts +6 -6
- package/dist/components/reui/cascader/cascader-columns.d.ts.map +1 -1
- package/dist/components/reui/cascader/cascader-columns.js +6 -6
- package/dist/components/reui/cascader/cascader-columns.js.map +1 -1
- package/dist/components/reui/cascader/cascader-context.d.ts +8 -8
- package/dist/components/reui/cascader/cascader-context.d.ts.map +1 -1
- package/dist/components/reui/cascader/cascader-context.js +10 -10
- package/dist/components/reui/cascader/cascader-context.js.map +1 -1
- package/dist/components/reui/cascader/cascader-footer.d.ts +14 -14
- package/dist/components/reui/cascader/cascader-footer.d.ts.map +1 -1
- package/dist/components/reui/cascader/cascader-footer.js +32 -33
- package/dist/components/reui/cascader/cascader-footer.js.map +1 -1
- package/dist/components/reui/cascader/cascader-i18n.d.ts +1 -1
- package/dist/components/reui/cascader/cascader-item.d.ts +12 -12
- package/dist/components/reui/cascader/cascader-item.d.ts.map +1 -1
- package/dist/components/reui/cascader/cascader-item.js +27 -27
- package/dist/components/reui/cascader/cascader-item.js.map +1 -1
- package/dist/components/reui/cascader/cascader-lib.d.ts +1 -1
- package/dist/components/reui/cascader/cascader-nav.d.ts +12 -12
- package/dist/components/reui/cascader/cascader-nav.d.ts.map +1 -1
- package/dist/components/reui/cascader/cascader-nav.js +12 -12
- package/dist/components/reui/cascader/cascader-nav.js.map +1 -1
- package/dist/components/reui/cascader/cascader-types.d.ts +1 -1
- package/dist/components/reui/cascader/cascader-virtual.d.ts +4 -4
- package/dist/components/reui/cascader/cascader-virtual.d.ts.map +1 -1
- package/dist/components/reui/cascader/cascader-virtual.js +13 -13
- package/dist/components/reui/cascader/cascader-virtual.js.map +1 -1
- package/dist/components/reui/cascader/cascader.d.ts +24 -24
- package/dist/components/reui/cascader/cascader.d.ts.map +1 -1
- package/dist/components/reui/cascader/cascader.js +110 -110
- package/dist/components/reui/cascader/cascader.js.map +1 -1
- package/dist/components/reui/code-block/code-block.d.ts +2 -1
- package/dist/components/reui/code-block/code-block.d.ts.map +1 -1
- package/dist/components/reui/code-block/code-block.js +2 -2
- package/dist/components/reui/code-block/code-block.js.map +1 -1
- package/dist/components/reui/color-picker.d.ts +1 -1
- package/dist/components/reui/color-picker.js +6 -6
- package/dist/components/reui/data-grid/data-grid-cell-selection.d.ts +1 -1
- package/dist/components/reui/data-grid/data-grid-cell-selection.js +4 -4
- package/dist/components/reui/data-grid/data-grid-cell-selection.js.map +1 -1
- package/dist/components/reui/data-grid/data-grid-column-filter.d.ts +1 -1
- package/dist/components/reui/data-grid/data-grid-column-filter.js +3 -3
- package/dist/components/reui/data-grid/data-grid-column-header.d.ts +1 -1
- package/dist/components/reui/data-grid/data-grid-column-header.js +4 -4
- package/dist/components/reui/data-grid/data-grid-column-visibility.d.ts +1 -1
- package/dist/components/reui/data-grid/data-grid-i18n.d.ts +1 -1
- package/dist/components/reui/data-grid/data-grid-pagination.js +2 -2
- package/dist/components/reui/data-grid/data-grid-scroll-area.js +3 -3
- package/dist/components/reui/data-grid/data-grid-table-dnd-rows.d.ts +1 -1
- package/dist/components/reui/data-grid/data-grid-table-dnd-rows.js +8 -8
- package/dist/components/reui/data-grid/data-grid-table-dnd.js +6 -6
- package/dist/components/reui/data-grid/data-grid-table-virtual.d.ts +2 -2
- package/dist/components/reui/data-grid/data-grid-table-virtual.js +3 -3
- package/dist/components/reui/data-grid/data-grid-table.d.ts.map +1 -1
- package/dist/components/reui/data-grid/data-grid-table.js +4 -4
- package/dist/components/reui/data-grid/data-grid-table.js.map +1 -1
- package/dist/components/reui/data-grid/data-grid.d.ts +1 -1
- package/dist/components/reui/data-grid/data-grid.js +2 -2
- package/dist/components/reui/date-selector.js +4 -4
- package/dist/components/reui/emoji-picker.d.ts +1 -1
- package/dist/components/reui/emoji-picker.js +5 -5
- package/dist/components/reui/emoji-picker.js.map +1 -1
- package/dist/components/reui/event-calendar/event-calendar-agenda-view.js +6 -6
- package/dist/components/reui/event-calendar/event-calendar-content.d.ts +1 -1
- package/dist/components/reui/event-calendar/event-calendar-content.js +3 -3
- package/dist/components/reui/event-calendar/event-calendar-dnd.js +2 -2
- package/dist/components/reui/event-calendar/event-calendar-event.d.ts +1 -1
- package/dist/components/reui/event-calendar/event-calendar-event.js +6 -6
- package/dist/components/reui/event-calendar/event-calendar-i18n.d.ts +1 -1
- package/dist/components/reui/event-calendar/event-calendar-lib.d.ts +1 -1
- package/dist/components/reui/event-calendar/event-calendar-lib.js +4 -4
- package/dist/components/reui/event-calendar/event-calendar-month-view.d.ts +1 -1
- package/dist/components/reui/event-calendar/event-calendar-month-view.js +6 -6
- package/dist/components/reui/event-calendar/event-calendar-nav.js +6 -6
- package/dist/components/reui/event-calendar/event-calendar-recurrence.js +1 -1
- package/dist/components/reui/event-calendar/event-calendar-resource-view.js +5 -5
- package/dist/components/reui/event-calendar/event-calendar-time-grid.d.ts +1 -1
- package/dist/components/reui/event-calendar/event-calendar-time-grid.js +5 -5
- package/dist/components/reui/event-calendar/event-calendar.d.ts +3 -3
- package/dist/components/reui/event-calendar/event-calendar.js +4 -4
- package/dist/components/reui/event-calendar/event-calendar.js.map +1 -1
- package/dist/components/reui/file-type.d.ts +1 -1
- package/dist/components/reui/file-type.js +1 -1
- package/dist/components/reui/filters/filters-advanced.d.ts +6 -6
- package/dist/components/reui/filters/filters-advanced.d.ts.map +1 -1
- package/dist/components/reui/filters/filters-advanced.js +35 -35
- package/dist/components/reui/filters/filters-advanced.js.map +1 -1
- package/dist/components/reui/filters/filters-builder.d.ts +5 -5
- package/dist/components/reui/filters/filters-builder.d.ts.map +1 -1
- package/dist/components/reui/filters/filters-builder.js +6 -6
- package/dist/components/reui/filters/filters-builder.js.map +1 -1
- package/dist/components/reui/filters/filters-chip.d.ts +10 -10
- package/dist/components/reui/filters/filters-chip.d.ts.map +1 -1
- package/dist/components/reui/filters/filters-chip.js +20 -20
- package/dist/components/reui/filters/filters-chip.js.map +1 -1
- package/dist/components/reui/filters/filters-context.d.ts +11 -11
- package/dist/components/reui/filters/filters-context.d.ts.map +1 -1
- package/dist/components/reui/filters/filters-context.js +27 -27
- package/dist/components/reui/filters/filters-context.js.map +1 -1
- package/dist/components/reui/filters/filters-dnd.d.ts +2 -2
- package/dist/components/reui/filters/filters-dnd.d.ts.map +1 -1
- package/dist/components/reui/filters/filters-dnd.js +5 -5
- package/dist/components/reui/filters/filters-dnd.js.map +1 -1
- package/dist/components/reui/filters/filters-draft.d.ts +1 -1
- package/dist/components/reui/filters/filters-editors.d.ts +9 -9
- package/dist/components/reui/filters/filters-editors.d.ts.map +1 -1
- package/dist/components/reui/filters/filters-editors.js +41 -41
- package/dist/components/reui/filters/filters-editors.js.map +1 -1
- package/dist/components/reui/filters/filters-lib.d.ts +1 -1
- package/dist/components/reui/filters/filters-types.d.ts +7 -7
- package/dist/components/reui/filters/filters-types.d.ts.map +1 -1
- package/dist/components/reui/filters/filters.d.ts +9 -9
- package/dist/components/reui/filters/filters.d.ts.map +1 -1
- package/dist/components/reui/filters/filters.js +56 -56
- package/dist/components/reui/filters/filters.js.map +1 -1
- package/dist/components/reui/frame.d.ts +2 -2
- package/dist/components/reui/frame.js +1 -1
- package/dist/components/reui/gantt/gantt-bar.d.ts +1 -1
- package/dist/components/reui/gantt/gantt-bar.js +5 -5
- package/dist/components/reui/gantt/gantt-dnd.js +5 -5
- package/dist/components/reui/gantt/gantt-dnd.js.map +1 -1
- package/dist/components/reui/gantt/gantt-i18n.d.ts +1 -1
- package/dist/components/reui/gantt/gantt-lib.d.ts +1 -1
- package/dist/components/reui/gantt/gantt-lib.js +4 -4
- package/dist/components/reui/gantt/gantt-nav.d.ts +1 -1
- package/dist/components/reui/gantt/gantt-nav.js +6 -6
- package/dist/components/reui/gantt/gantt-recurrence.js +1 -1
- package/dist/components/reui/gantt/gantt-view.js +11 -11
- package/dist/components/reui/gantt/gantt-view.js.map +1 -1
- package/dist/components/reui/gantt/gantt.d.ts +3 -3
- package/dist/components/reui/gantt/gantt.js +4 -4
- package/dist/components/reui/gantt/gantt.js.map +1 -1
- package/dist/components/reui/icon-tile.d.ts +3 -3
- package/dist/components/reui/icon-tile.js +2 -2
- package/dist/components/reui/kanban.d.ts +11 -11
- package/dist/components/reui/kanban.d.ts.map +1 -1
- package/dist/components/reui/kanban.js +3 -3
- package/dist/components/reui/number-field.d.ts +4 -4
- package/dist/components/reui/number-field.js +4 -4
- package/dist/components/reui/phone-input.js +5 -5
- package/dist/components/reui/rating.d.ts +1 -1
- package/dist/components/reui/rating.js +2 -2
- package/dist/components/reui/scrollspy.js +1 -1
- package/dist/components/reui/signature-pad.d.ts +1 -1
- package/dist/components/reui/signature-pad.js +7 -7
- package/dist/components/reui/signature-pad.js.map +1 -1
- package/dist/components/reui/sortable.d.ts +7 -7
- package/dist/components/reui/sortable.d.ts.map +1 -1
- package/dist/components/reui/sortable.js +3 -3
- package/dist/components/reui/stepper.js +2 -2
- package/dist/components/reui/time-picker.d.ts +1 -1
- package/dist/components/reui/time-picker.js +4 -4
- package/dist/components/reui/timeline.js +2 -2
- package/dist/components/reui/tree.d.ts +1 -0
- package/dist/components/reui/tree.d.ts.map +1 -1
- package/dist/components/reui/tree.js +3 -3
- package/dist/components/ui/accordion.js +2 -2
- package/dist/components/ui/alert-dialog.d.ts +14 -14
- package/dist/components/ui/alert-dialog.d.ts.map +1 -1
- package/dist/components/ui/alert-dialog.js +2 -2
- package/dist/components/ui/alert.d.ts +5 -5
- package/dist/components/ui/alert.d.ts.map +1 -1
- package/dist/components/ui/alert.js +1 -1
- package/dist/components/ui/attachment.d.ts +15 -15
- package/dist/components/ui/attachment.d.ts.map +1 -1
- package/dist/components/ui/attachment.js +4 -4
- package/dist/components/ui/avatar.d.ts +7 -7
- package/dist/components/ui/avatar.d.ts.map +1 -1
- package/dist/components/ui/avatar.js +1 -1
- package/dist/components/ui/badge.d.ts +2 -2
- package/dist/components/ui/badge.js +2 -2
- package/dist/components/ui/breadcrumb.d.ts +8 -8
- package/dist/components/ui/breadcrumb.d.ts.map +1 -1
- package/dist/components/ui/breadcrumb.js +3 -3
- package/dist/components/ui/bubble.d.ts +9 -9
- package/dist/components/ui/bubble.d.ts.map +1 -1
- package/dist/components/ui/bubble.js +3 -3
- package/dist/components/ui/button-group.d.ts +3 -3
- package/dist/components/ui/button-group.js +4 -4
- package/dist/components/ui/button.d.ts +2 -2
- package/dist/components/ui/button.js +2 -2
- package/dist/components/ui/calendar.d.ts +7 -7
- package/dist/components/ui/calendar.d.ts.map +1 -1
- package/dist/components/ui/calendar.js +6 -6
- package/dist/components/ui/calendar.js.map +1 -1
- package/dist/components/ui/card.d.ts +9 -9
- package/dist/components/ui/card.d.ts.map +1 -1
- package/dist/components/ui/carousel.d.ts +7 -7
- package/dist/components/ui/carousel.d.ts.map +1 -1
- package/dist/components/ui/carousel.js +14 -14
- package/dist/components/ui/carousel.js.map +1 -1
- package/dist/components/ui/chart.d.ts +12 -12
- package/dist/components/ui/chart.d.ts.map +1 -1
- package/dist/components/ui/chart.js +6 -6
- package/dist/components/ui/chart.js.map +1 -1
- package/dist/components/ui/checkbox.js +2 -2
- package/dist/components/ui/code-block.d.ts +13 -13
- package/dist/components/ui/code-block.d.ts.map +1 -1
- package/dist/components/ui/code-block.js +6 -6
- package/dist/components/ui/code-block.js.map +1 -1
- package/dist/components/ui/collapsible.js +1 -1
- package/dist/components/ui/combobox.d.ts +16 -16
- package/dist/components/ui/combobox.d.ts.map +1 -1
- package/dist/components/ui/combobox.js +5 -5
- package/dist/components/ui/combobox.js.map +1 -1
- package/dist/components/ui/command.d.ts +13 -13
- package/dist/components/ui/command.d.ts.map +1 -1
- package/dist/components/ui/command.js +3 -3
- package/dist/components/ui/context-menu.d.ts +16 -16
- package/dist/components/ui/context-menu.d.ts.map +1 -1
- package/dist/components/ui/context-menu.js +2 -2
- package/dist/components/ui/dialog.d.ts +12 -12
- package/dist/components/ui/dialog.d.ts.map +1 -1
- package/dist/components/ui/dialog.js +3 -3
- package/dist/components/ui/drawer.d.ts +12 -12
- package/dist/components/ui/drawer.d.ts.map +1 -1
- package/dist/components/ui/drawer.js +5 -5
- package/dist/components/ui/drawer.js.map +1 -1
- package/dist/components/ui/dropdown-menu.d.ts +16 -16
- package/dist/components/ui/dropdown-menu.d.ts.map +1 -1
- package/dist/components/ui/dropdown-menu.js +2 -2
- package/dist/components/ui/empty.js +1 -1
- package/dist/components/ui/field.d.ts +2 -2
- package/dist/components/ui/field.js +3 -3
- package/dist/components/ui/hover-card.js +1 -1
- package/dist/components/ui/input-group.d.ts +11 -11
- package/dist/components/ui/input-group.d.ts.map +1 -1
- package/dist/components/ui/input-group.js +2 -2
- package/dist/components/ui/input-otp.d.ts +7 -7
- package/dist/components/ui/input-otp.d.ts.map +1 -1
- package/dist/components/ui/input-otp.js +4 -4
- package/dist/components/ui/input-otp.js.map +1 -1
- package/dist/components/ui/input.d.ts +2 -2
- package/dist/components/ui/input.d.ts.map +1 -1
- package/dist/components/ui/input.js +1 -1
- package/dist/components/ui/item.d.ts +14 -14
- package/dist/components/ui/item.d.ts.map +1 -1
- package/dist/components/ui/item.js +4 -4
- package/dist/components/ui/label.d.ts +2 -2
- package/dist/components/ui/label.d.ts.map +1 -1
- package/dist/components/ui/marker.d.ts +6 -6
- package/dist/components/ui/marker.d.ts.map +1 -1
- package/dist/components/ui/marker.js +3 -3
- package/dist/components/ui/menubar.d.ts +20 -20
- package/dist/components/ui/menubar.d.ts.map +1 -1
- package/dist/components/ui/menubar.js +4 -4
- package/dist/components/ui/message-scroller.d.ts +8 -8
- package/dist/components/ui/message-scroller.d.ts.map +1 -1
- package/dist/components/ui/message-scroller.js +3 -3
- package/dist/components/ui/message.d.ts +8 -8
- package/dist/components/ui/message.d.ts.map +1 -1
- package/dist/components/ui/native-select.d.ts +5 -5
- package/dist/components/ui/native-select.d.ts.map +1 -1
- package/dist/components/ui/native-select.js +1 -1
- package/dist/components/ui/navigation-menu.js +3 -3
- package/dist/components/ui/pagination.d.ts +11 -11
- package/dist/components/ui/pagination.d.ts.map +1 -1
- package/dist/components/ui/pagination.js +2 -2
- package/dist/components/ui/popover.d.ts +7 -7
- package/dist/components/ui/popover.d.ts.map +1 -1
- package/dist/components/ui/popover.js +1 -1
- package/dist/components/ui/progress.js +1 -1
- package/dist/components/ui/questionnaire.d.ts +17 -17
- package/dist/components/ui/questionnaire.d.ts.map +1 -1
- package/dist/components/ui/questionnaire.js +3 -3
- package/dist/components/ui/radio-group.js +2 -2
- package/dist/components/ui/resizable.js +1 -1
- package/dist/components/ui/scroll-area.js +1 -1
- package/dist/components/ui/select.d.ts +10 -10
- package/dist/components/ui/select.d.ts.map +1 -1
- package/dist/components/ui/select.js +2 -2
- package/dist/components/ui/separator.js +1 -1
- package/dist/components/ui/sheet.d.ts +9 -9
- package/dist/components/ui/sheet.d.ts.map +1 -1
- package/dist/components/ui/sheet.js +3 -3
- package/dist/components/ui/sidebar.d.ts +34 -34
- package/dist/components/ui/sidebar.d.ts.map +1 -1
- package/dist/components/ui/sidebar.js +15 -15
- package/dist/components/ui/sidebar.js.map +1 -1
- package/dist/components/ui/slider.js +1 -1
- package/dist/components/ui/spinner.js +1 -1
- package/dist/components/ui/switch.js +1 -1
- package/dist/components/ui/table.d.ts +9 -9
- package/dist/components/ui/table.d.ts.map +1 -1
- package/dist/components/ui/tabs.d.ts +1 -1
- package/dist/components/ui/tabs.js +2 -2
- package/dist/components/ui/textarea.d.ts +2 -2
- package/dist/components/ui/textarea.d.ts.map +1 -1
- package/dist/components/ui/toast.d.ts +11 -11
- package/dist/components/ui/toast.d.ts.map +1 -1
- package/dist/components/ui/toast.js +3 -3
- package/dist/components/ui/toggle-group.d.ts +5 -5
- package/dist/components/ui/toggle-group.d.ts.map +1 -1
- package/dist/components/ui/toggle-group.js +6 -6
- package/dist/components/ui/toggle-group.js.map +1 -1
- package/dist/components/ui/toggle.d.ts +2 -2
- package/dist/components/ui/toggle.js +2 -2
- package/dist/components/ui/tooltip.js +1 -1
- package/dist/components/ui/trace.d.ts +12 -12
- package/dist/components/ui/trace.d.ts.map +1 -1
- package/dist/components/ui/trace.js +2 -2
- package/dist/{constants-evLzfUhL.js → constants-CggcOqef.js} +1 -1
- package/dist/constants-CggcOqef.js.map +1 -0
- package/dist/context-B5NItr9C.d.ts +82 -0
- package/dist/context-B5NItr9C.d.ts.map +1 -0
- package/dist/context-BEYROlTB.d.ts +78 -0
- package/dist/context-BEYROlTB.d.ts.map +1 -0
- package/dist/context-BLjAwZ5V.js +243 -0
- package/dist/context-BLjAwZ5V.js.map +1 -0
- package/dist/{context-CXlD0FcC.js → context-BpHX6J1T.js} +28 -4
- package/dist/context-BpHX6J1T.js.map +1 -0
- package/dist/{context-tv-kneJV.d.ts → context-BrGWrRwa.d.ts} +26 -3
- package/dist/context-BrGWrRwa.d.ts.map +1 -0
- package/dist/{context-D-juVNr2.d.ts → context-C1Z_5vew.d.ts} +18 -3
- package/dist/context-C1Z_5vew.d.ts.map +1 -0
- package/dist/context-C5DO1oe1.js +232 -0
- package/dist/context-C5DO1oe1.js.map +1 -0
- package/dist/{context-Dk6C9IvC.js → context-C8M88I1F.js} +48 -8
- package/dist/context-C8M88I1F.js.map +1 -0
- package/dist/{context-3i2_6ly8.js → context-C92iQeLO.js} +13 -5
- package/dist/context-C92iQeLO.js.map +1 -0
- package/dist/{context-DdnKlMjE.js → context-CHXHCbuu.js} +18 -4
- package/dist/context-CHXHCbuu.js.map +1 -0
- package/dist/{context-mjP5wifG.d.ts → context-CgRa89Bq.d.ts} +29 -3
- package/dist/context-CgRa89Bq.d.ts.map +1 -0
- package/dist/{context-CQbvWVnM.js → context-CmexbpIK.js} +31 -9
- package/dist/context-CmexbpIK.js.map +1 -0
- package/dist/{context-i6Dwvi3T.js → context-Cr2SLhVi.js} +45 -21
- package/dist/context-Cr2SLhVi.js.map +1 -0
- package/dist/{context-DWXNECDe.js → context-CwSk1WZR.js} +23 -5
- package/dist/context-CwSk1WZR.js.map +1 -0
- package/dist/{context-C5TW-k6u.js → context-DWHy9EUW.js} +41 -8
- package/dist/context-DWHy9EUW.js.map +1 -0
- package/dist/{context-ChsuSih6.js → context-Dae38FV_.js} +33 -14
- package/dist/context-Dae38FV_.js.map +1 -0
- package/dist/{context-DUx44mGi.js → context-r3QNWoPh.js} +29 -5
- package/dist/context-r3QNWoPh.js.map +1 -0
- package/dist/{copy-menu-LU54Aruj.js → copy-menu-BizTEv8v.js} +42 -23
- package/dist/copy-menu-BizTEv8v.js.map +1 -0
- package/dist/crash-parts-Dg5WC8u4.js +926 -0
- package/dist/crash-parts-Dg5WC8u4.js.map +1 -0
- package/dist/{data-grid-i18n-BySPLTBy.d.ts → data-grid-i18n-BcJcbW5k.d.ts} +1 -1
- package/dist/{data-grid-i18n-BySPLTBy.d.ts.map → data-grid-i18n-BcJcbW5k.d.ts.map} +1 -1
- package/dist/{ease-CHhXKlG3.d.ts → ease-DnPhwGe6.d.ts} +4 -2
- package/dist/ease-DnPhwGe6.d.ts.map +1 -0
- package/dist/{filters-draft-COwwppZX.d.ts → filters-draft-b-BwSZb1.d.ts} +1 -1
- package/dist/{filters-draft-COwwppZX.d.ts.map → filters-draft-b-BwSZb1.d.ts.map} +1 -1
- package/dist/game-parts-hATtqY3s.d.ts +89 -0
- package/dist/game-parts-hATtqY3s.d.ts.map +1 -0
- package/dist/hooks/use-copy-to-clipboard.js +5 -5
- package/dist/hooks/use-copy-to-clipboard.js.map +1 -1
- package/dist/hooks/use-favicon.js +1 -1
- package/dist/hooks/use-highlighted-code.d.ts +2 -2
- package/dist/hooks/use-highlighted-code.d.ts.map +1 -1
- package/dist/hooks/use-highlighted-code.js +6 -76
- package/dist/hooks/use-highlighted-code.js.map +1 -1
- package/dist/hooks/use-hover-gesture.js +1 -1
- package/dist/hooks/use-intersection-observer.d.ts +2 -2
- package/dist/hooks/use-intersection-observer.d.ts.map +1 -1
- package/dist/hooks/use-intersection-observer.js +4 -4
- package/dist/hooks/use-intersection-observer.js.map +1 -1
- package/dist/hooks/use-listbox.js +1 -1
- package/dist/hooks/use-listbox.js.map +1 -1
- package/dist/hooks/use-meta-color.js +7 -7
- package/dist/hooks/use-meta-color.js.map +1 -1
- package/dist/hooks/use-mobile.js +3 -3
- package/dist/hooks/use-mobile.js.map +1 -1
- package/dist/hooks/use-modal-scope.js +1 -1
- package/dist/hooks/use-mutation-observer.d.ts +2 -2
- package/dist/hooks/use-mutation-observer.d.ts.map +1 -1
- package/dist/hooks/use-mutation-observer.js +2 -2
- package/dist/hooks/use-mutation-observer.js.map +1 -1
- package/dist/hooks/use-slider-input.d.ts +4 -4
- package/dist/hooks/use-slider-input.d.ts.map +1 -1
- package/dist/hooks/use-slider.js +1 -1
- package/dist/i18n-BRH0Y7Sm.d.ts +34 -0
- package/dist/i18n-BRH0Y7Sm.d.ts.map +1 -0
- package/dist/lib/audio-context.d.ts +11 -0
- package/dist/lib/audio-context.d.ts.map +1 -0
- package/dist/lib/audio-context.js +37 -0
- package/dist/lib/audio-context.js.map +1 -0
- package/dist/lib/book-sounds.d.ts +18 -0
- package/dist/lib/book-sounds.d.ts.map +1 -0
- package/dist/lib/book-sounds.js +202 -0
- package/dist/lib/book-sounds.js.map +1 -0
- package/dist/lib/ease.d.ts +2 -2
- package/dist/lib/ease.js +8 -1
- package/dist/lib/ease.js.map +1 -1
- package/dist/lib/game-sounds.d.ts +18 -0
- package/dist/lib/game-sounds.d.ts.map +1 -0
- package/dist/lib/game-sounds.js +142 -0
- package/dist/lib/game-sounds.js.map +1 -0
- package/dist/lib/highlighter.d.ts +10 -0
- package/dist/lib/highlighter.d.ts.map +1 -0
- package/dist/lib/highlighter.js +78 -0
- package/dist/lib/highlighter.js.map +1 -0
- package/dist/lib/i18n.d.ts +2 -0
- package/dist/lib/i18n.js +51 -0
- package/dist/lib/i18n.js.map +1 -0
- package/dist/lib/presence-gate.d.ts +39 -0
- package/dist/lib/presence-gate.d.ts.map +1 -0
- package/dist/{presence-gate-DC7yL1Ls.js → lib/presence-gate.js} +3 -2
- package/dist/lib/presence-gate.js.map +1 -0
- package/dist/lib/text-shimmer.js.map +1 -1
- package/dist/lib/tick-sound.d.ts +4 -3
- package/dist/lib/tick-sound.d.ts.map +1 -1
- package/dist/lib/tick-sound.js +30 -37
- package/dist/lib/tick-sound.js.map +1 -1
- package/dist/messages-BYMFNf5X.d.ts +13 -0
- package/dist/messages-BYMFNf5X.d.ts.map +1 -0
- package/dist/messages-CVaE8xc6.js +14 -0
- package/dist/messages-CVaE8xc6.js.map +1 -0
- package/dist/messages-CqyH8Hd7.js +21 -0
- package/dist/messages-CqyH8Hd7.js.map +1 -0
- package/dist/messages-CrtN5AXG.js +20 -0
- package/dist/messages-CrtN5AXG.js.map +1 -0
- package/dist/messages-D4axySpl.d.ts +21 -0
- package/dist/messages-D4axySpl.d.ts.map +1 -0
- package/dist/messages-Dyou6PVt.d.ts +23 -0
- package/dist/messages-Dyou6PVt.d.ts.map +1 -0
- package/dist/messages-azsh5xBO.d.ts +20 -0
- package/dist/messages-azsh5xBO.d.ts.map +1 -0
- package/dist/messages-ogb0tIIX.d.ts +23 -0
- package/dist/messages-ogb0tIIX.d.ts.map +1 -0
- package/dist/messages-tLRkxZwI.d.ts +33 -0
- package/dist/messages-tLRkxZwI.d.ts.map +1 -0
- package/dist/{model-mS4UXPwk.d.ts → model-B_LLKNOs.d.ts} +1 -1
- package/dist/model-B_LLKNOs.d.ts.map +1 -0
- package/dist/{model-CvWolJdo.d.ts → model-Cbzktxjx.d.ts} +1 -1
- package/dist/model-Cbzktxjx.d.ts.map +1 -0
- package/dist/{model-BFZGhrnQ.d.ts → model-Cqi9KKo1.d.ts} +1 -1
- package/dist/{model-BFZGhrnQ.d.ts.map → model-Cqi9KKo1.d.ts.map} +1 -1
- package/dist/{model-DuAc65oe.d.ts → model-DP6FsG__.d.ts} +1 -1
- package/dist/model-DP6FsG__.d.ts.map +1 -0
- package/dist/{path-VEfFUowr.d.ts → path-DMP3rnd1.d.ts} +1 -1
- package/dist/path-DMP3rnd1.d.ts.map +1 -0
- package/dist/{plot-CTQFrQKi.js → plot-B2aPWHib.js} +12 -12
- package/dist/plot-B2aPWHib.js.map +1 -0
- package/dist/{popover-position-BaDNBZ-D.js → popover-position-U1ZMRPsY.js} +1 -1
- package/dist/{popover-position-BaDNBZ-D.js.map → popover-position-U1ZMRPsY.js.map} +1 -1
- package/dist/{positioner-MidjIUUT.js → positioner-DY1vB4rF.js} +6 -6
- package/dist/positioner-DY1vB4rF.js.map +1 -0
- package/dist/{scale-DSsaupNc.d.ts → scale-BLDMdHAp.d.ts} +1 -1
- package/dist/scale-BLDMdHAp.d.ts.map +1 -0
- package/dist/{tooltip-CuHpilPN.js → tooltip-BUkacvMl.js} +6 -6
- package/dist/tooltip-BUkacvMl.js.map +1 -0
- package/dist/{tooltip-Cq46pSJ2.d.ts → tooltip-CJccRGy9.d.ts} +21 -2
- package/dist/tooltip-CJccRGy9.d.ts.map +1 -0
- package/dist/{tooltip-CNEYdIX3.d.ts → tooltip-CMtIWcUY.d.ts} +19 -2
- package/dist/tooltip-CMtIWcUY.d.ts.map +1 -0
- package/dist/{tooltip-BVRmgnbZ.d.ts → tooltip-DuPE_3Gi.d.ts} +21 -2
- package/dist/tooltip-DuPE_3Gi.d.ts.map +1 -0
- package/dist/{tooltip-w0KptZat.d.ts → tooltip-UI0lMGya.d.ts} +1 -1
- package/dist/tooltip-UI0lMGya.d.ts.map +1 -0
- package/dist/{tooltip-content-K0vPsEtI.d.ts → tooltip-content-Dr8bhW-q.d.ts} +4 -2
- package/dist/tooltip-content-Dr8bhW-q.d.ts.map +1 -0
- package/dist/{tooltip-CMVyNolz.d.ts → tooltip-jQICwV_k.d.ts} +13 -2
- package/dist/tooltip-jQICwV_k.d.ts.map +1 -0
- package/dist/{types-B0d0d7PF.d.ts → types-C1WFGMvf.d.ts} +1 -1
- package/dist/types-C1WFGMvf.d.ts.map +1 -0
- package/dist/{types-BB61jXS_.d.ts → types-C_v1N4fH.d.ts} +4 -1
- package/dist/types-C_v1N4fH.d.ts.map +1 -0
- package/dist/{types-D9hKqIzm.d.ts → types-DJ8z6gW8.d.ts} +32 -2
- package/dist/types-DJ8z6gW8.d.ts.map +1 -0
- package/dist/{types-qTGsGdN1.d.ts → types-DROZkngo.d.ts} +1 -1
- package/dist/types-DROZkngo.d.ts.map +1 -0
- package/dist/{types-BSMELKE5.d.ts → types-DlSHf6nJ.d.ts} +1 -1
- package/dist/types-DlSHf6nJ.d.ts.map +1 -0
- package/dist/{use-active-option-DerS-wGL.js → use-active-option-DbxnIM2n.js} +1 -1
- package/dist/{use-active-option-DerS-wGL.js.map → use-active-option-DbxnIM2n.js.map} +1 -1
- package/dist/use-crash-game-DiGujbfH.d.ts +160 -0
- package/dist/use-crash-game-DiGujbfH.d.ts.map +1 -0
- package/dist/{use-geometry-C84j2gUk.d.ts → use-geometry-BajLqxjC.d.ts} +1 -1
- package/dist/use-geometry-BajLqxjC.d.ts.map +1 -0
- package/dist/{use-inspection-CZhdpH8J.js → use-inspection-DWk6TdY9.js} +1 -1
- package/dist/use-inspection-DWk6TdY9.js.map +1 -0
- package/dist/{use-points-C2jpElHh.js → use-points-y0l-9pdN.js} +1 -1
- package/dist/use-points-y0l-9pdN.js.map +1 -0
- package/dist/{use-position-CWSE4wCz.d.ts → use-position-B1lYvN8D.d.ts} +1 -1
- package/dist/{use-position-CWSE4wCz.d.ts.map → use-position-B1lYvN8D.d.ts.map} +1 -1
- package/dist/{use-width-CkKCh1b3.js → use-width-Dmy1eT1-.js} +1 -1
- package/dist/{use-width-CkKCh1b3.js.map → use-width-Dmy1eT1-.js.map} +1 -1
- package/dist/utils-Dve5wIjB.js +56 -0
- package/dist/utils-Dve5wIjB.js.map +1 -0
- package/dist/{utils-ZRfJ78Df.js → utils-F-hKjEFd.js} +1 -1
- package/dist/utils-F-hKjEFd.js.map +1 -0
- package/package.json +9 -9
- package/dist/account-avatar--0_0u0WW.js.map +0 -1
- package/dist/cascader-types-Bh_kJ3Qw.d.ts.map +0 -1
- package/dist/components/motion/combobox/context.d.ts.map +0 -1
- package/dist/components/motion/combobox/context.js.map +0 -1
- package/dist/components/motion/multi-select/context.d.ts.map +0 -1
- package/dist/components/motion/multi-select/context.js.map +0 -1
- package/dist/constants-evLzfUhL.js.map +0 -1
- package/dist/context-3i2_6ly8.js.map +0 -1
- package/dist/context-C5TW-k6u.js.map +0 -1
- package/dist/context-CQbvWVnM.js.map +0 -1
- package/dist/context-CXlD0FcC.js.map +0 -1
- package/dist/context-ChsuSih6.js.map +0 -1
- package/dist/context-D-juVNr2.d.ts.map +0 -1
- package/dist/context-DUx44mGi.js.map +0 -1
- package/dist/context-DWXNECDe.js.map +0 -1
- package/dist/context-DdnKlMjE.js.map +0 -1
- package/dist/context-Dk6C9IvC.js.map +0 -1
- package/dist/context-i6Dwvi3T.js.map +0 -1
- package/dist/context-mjP5wifG.d.ts.map +0 -1
- package/dist/context-tv-kneJV.d.ts.map +0 -1
- package/dist/copy-menu-LU54Aruj.js.map +0 -1
- package/dist/ease-CHhXKlG3.d.ts.map +0 -1
- package/dist/model-CvWolJdo.d.ts.map +0 -1
- package/dist/model-DuAc65oe.d.ts.map +0 -1
- package/dist/model-mS4UXPwk.d.ts.map +0 -1
- package/dist/path-VEfFUowr.d.ts.map +0 -1
- package/dist/plot-CTQFrQKi.js.map +0 -1
- package/dist/positioner-MidjIUUT.js.map +0 -1
- package/dist/presence-gate-DC7yL1Ls.js.map +0 -1
- package/dist/scale-DSsaupNc.d.ts.map +0 -1
- package/dist/tooltip-BVRmgnbZ.d.ts.map +0 -1
- package/dist/tooltip-CMVyNolz.d.ts.map +0 -1
- package/dist/tooltip-CNEYdIX3.d.ts.map +0 -1
- package/dist/tooltip-Cq46pSJ2.d.ts.map +0 -1
- package/dist/tooltip-CuHpilPN.js.map +0 -1
- package/dist/tooltip-content-K0vPsEtI.d.ts.map +0 -1
- package/dist/tooltip-w0KptZat.d.ts.map +0 -1
- package/dist/types-B0d0d7PF.d.ts.map +0 -1
- package/dist/types-BB61jXS_.d.ts.map +0 -1
- package/dist/types-BSMELKE5.d.ts.map +0 -1
- package/dist/types-D9hKqIzm.d.ts.map +0 -1
- package/dist/types-qTGsGdN1.d.ts.map +0 -1
- package/dist/use-geometry-C84j2gUk.d.ts.map +0 -1
- package/dist/use-inspection-CZhdpH8J.js.map +0 -1
- package/dist/use-points-C2jpElHh.js.map +0 -1
- package/dist/utils-DMrlhG6M.js +0 -25
- package/dist/utils-DMrlhG6M.js.map +0 -1
- package/dist/utils-ZRfJ78Df.js.map +0 -1
|
@@ -0,0 +1,926 @@
|
|
|
1
|
+
import { memo, useEffect, useLayoutEffect, useMemo, useRef, useState } from "react";
|
|
2
|
+
import { Check, History } from "lucide-react";
|
|
3
|
+
import { AnimatePresence, motion, useReducedMotion } from "motion/react";
|
|
4
|
+
import { cn } from "@kumix/utils";
|
|
5
|
+
import { EASE_IN_OUT, EASE_OUT } from "./lib/ease.js";
|
|
6
|
+
import { PresenceGate } from "./lib/presence-gate.js";
|
|
7
|
+
import { Button } from "./components/motion/button/base.js";
|
|
8
|
+
import { EXIT, GameEyebrow, GameHistory, HEAT_TEXT, PRIMARY_TEXT, PULSE, SHAKE, SWAP, SoundToggle, floor2, formatMultiplier, formatShort, heat, useStable } from "./components/motion/casino/game-parts.js";
|
|
9
|
+
import { NumberTicker } from "./components/motion/number-ticker.js";
|
|
10
|
+
import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from "./components/motion/select.js";
|
|
11
|
+
import { createGameSounds } from "./lib/game-sounds.js";
|
|
12
|
+
import { useMessages } from "./lib/i18n.js";
|
|
13
|
+
import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
|
|
14
|
+
// src/components/motion/crash/messages.ts
|
|
15
|
+
const crashMessages = {
|
|
16
|
+
region: "Crash",
|
|
17
|
+
recentCrashes: "Recent crashes",
|
|
18
|
+
recentEmpty: "Recent rounds show here",
|
|
19
|
+
sound: "Sound",
|
|
20
|
+
auto: "Auto",
|
|
21
|
+
autoOff: "Off",
|
|
22
|
+
start: "Start",
|
|
23
|
+
starting: "Starting…",
|
|
24
|
+
cashOut: "Cash out {multiplier}",
|
|
25
|
+
crashing: "Crashing…",
|
|
26
|
+
skip: "Skip to crash",
|
|
27
|
+
waiting: "Waiting for crash",
|
|
28
|
+
playAgain: "Play again",
|
|
29
|
+
stateReady: "Ready",
|
|
30
|
+
stateStarting: "Starting",
|
|
31
|
+
stateFlying: "In flight",
|
|
32
|
+
stateCashedOut: "Cashed out",
|
|
33
|
+
stateCrashed: "Crashed",
|
|
34
|
+
statusIdle: "Start a round",
|
|
35
|
+
statusFlying: "Cash out before it crashes",
|
|
36
|
+
statusAuto: "Auto cash out at {multiplier}",
|
|
37
|
+
statusCloseCall: "Crashed at {multiplier}, a close call",
|
|
38
|
+
statusFlewOn: "It flew on to {multiplier}",
|
|
39
|
+
statusShort: "Short of your {target} target",
|
|
40
|
+
statusStillIn: "You were still in",
|
|
41
|
+
cashedBadge: "Cashed out {multiplier}",
|
|
42
|
+
announceStarting: "Starting round.",
|
|
43
|
+
announceStarted: "Round started.",
|
|
44
|
+
announceStartedAuto: "Round started. Auto cash out at {multiplier}.",
|
|
45
|
+
announceStartFailed: "The round couldn't start. Try again.",
|
|
46
|
+
announceCashedOut: "Cashed out at {multiplier}.",
|
|
47
|
+
announceCrashed: "Crashed at {multiplier}.",
|
|
48
|
+
announceLost: "Crashed at {multiplier}. The round is lost.",
|
|
49
|
+
result: "Round result",
|
|
50
|
+
hideResult: "Hide result and show the flight",
|
|
51
|
+
crashedAt: "Crashed at",
|
|
52
|
+
flight: "Flight",
|
|
53
|
+
seconds: "{seconds}s",
|
|
54
|
+
oddsBeaten: "Odds beaten",
|
|
55
|
+
odds: "1 in {odds}",
|
|
56
|
+
leftAt: "You left at",
|
|
57
|
+
autoTarget: "Auto target",
|
|
58
|
+
autoMark: "Auto {multiplier}",
|
|
59
|
+
targetMark: "target",
|
|
60
|
+
targetMarkValue: "target {multiplier}",
|
|
61
|
+
lastMark: "Last {multiplier}",
|
|
62
|
+
targetMarkTower: "Target {multiplier}"
|
|
63
|
+
};
|
|
64
|
+
// src/components/motion/crash/use-crash-game.ts
|
|
65
|
+
const GROWTH = .12;
|
|
66
|
+
const growth = (seconds) => Math.exp(GROWTH * seconds);
|
|
67
|
+
const timeAt = (multiplier) => Math.log(multiplier) / GROWTH;
|
|
68
|
+
const MAX_CRASH = 1e6;
|
|
69
|
+
const CEILING = 1e100;
|
|
70
|
+
/**
|
|
71
|
+
* A crash point from one uniform draw in [0, 1): the round reaches `m` with
|
|
72
|
+
* probability (1 − houseEdge) / m, floored to two decimals and capped at
|
|
73
|
+
* 1,000,000×. The default edge of 0 is a fair game. Pass your own `random`
|
|
74
|
+
* for a seeded or provably fair round, for example the first 52 bits of a
|
|
75
|
+
* round's HMAC-SHA256: `crashPoint(() => parseInt(hash.slice(0, 13), 16) / 2 ** 52, 0.01)`.
|
|
76
|
+
*/
|
|
77
|
+
function crashPoint(random = Math.random, houseEdge = 0) {
|
|
78
|
+
return Math.min(MAX_CRASH, Math.max(1, Math.floor(100 * (1 - Math.min(Math.max(houseEdge, 0), 1)) / (1 - random())) / 100));
|
|
79
|
+
}
|
|
80
|
+
/**
|
|
81
|
+
* A passed crash point as the game plays it: at least 1 and floored to two
|
|
82
|
+
* decimals, the way crash games display them. The round ends on exactly the
|
|
83
|
+
* caller's value up to the 1e100 ceiling; `crashPoint()` caps at 1,000,000.
|
|
84
|
+
* Anything not finite plays as 1.
|
|
85
|
+
*/
|
|
86
|
+
const settle = (point) => {
|
|
87
|
+
if (!Number.isFinite(point)) return 1;
|
|
88
|
+
return Math.max(1, floor2(Math.min(point, CEILING)));
|
|
89
|
+
};
|
|
90
|
+
/**
|
|
91
|
+
* Multipliers announced (and chimed) while the player is in: 2× to 5×, then
|
|
92
|
+
* 10×, 20×, 50×, 100× and on, so a long flight stays quiet enough to follow.
|
|
93
|
+
*/
|
|
94
|
+
function milestone(index) {
|
|
95
|
+
if (index < 4) return index + 2;
|
|
96
|
+
return [
|
|
97
|
+
10,
|
|
98
|
+
20,
|
|
99
|
+
50
|
|
100
|
+
][(index - 4) % 3] * 10 ** Math.floor((index - 4) / 3);
|
|
101
|
+
}
|
|
102
|
+
const AUTO_STEPS = [
|
|
103
|
+
1.5,
|
|
104
|
+
2,
|
|
105
|
+
3,
|
|
106
|
+
5,
|
|
107
|
+
10,
|
|
108
|
+
25,
|
|
109
|
+
100
|
|
110
|
+
];
|
|
111
|
+
const SKIP_TIME = .8;
|
|
112
|
+
let rounds = 0;
|
|
113
|
+
const HISTORY = 12;
|
|
114
|
+
const BURST = {
|
|
115
|
+
duration: .45,
|
|
116
|
+
ease: EASE_OUT
|
|
117
|
+
};
|
|
118
|
+
function useCrashGame({ autoCashOut: autoProp, defaultAutoCashOut = null, onAutoCashOutChange, getCrashPoint, crashAt, onStart, onCashOut, onCrash, sound, defaultSound = false, onSoundChange, labels }) {
|
|
119
|
+
const text = useMessages("crash", crashMessages, labels);
|
|
120
|
+
const live = crashAt !== void 0;
|
|
121
|
+
const reduce = useReducedMotion() ?? false;
|
|
122
|
+
const [internalAuto, setInternalAuto] = useState(defaultAutoCashOut);
|
|
123
|
+
const rawAuto = autoProp === void 0 ? internalAuto : autoProp;
|
|
124
|
+
const auto = rawAuto === null || !Number.isFinite(rawAuto) ? null : Math.max(1.01, floor2(rawAuto));
|
|
125
|
+
const [phase, setPhase] = useState("idle");
|
|
126
|
+
const [round, setRound] = useState(0);
|
|
127
|
+
const [elapsed, setElapsed] = useState(0);
|
|
128
|
+
const [cashed, setCashed] = useState(null);
|
|
129
|
+
const [cashedT, setCashedT] = useState(null);
|
|
130
|
+
const [crashedAt, setCrashedAt] = useState(null);
|
|
131
|
+
const [history, setHistory] = useState([]);
|
|
132
|
+
const [announcement, setAnnouncement] = useState("");
|
|
133
|
+
const [pulse, setPulse] = useState(0);
|
|
134
|
+
const [roundAuto, setRoundAuto] = useState(null);
|
|
135
|
+
const flight = useRef({
|
|
136
|
+
round: 0,
|
|
137
|
+
live: false,
|
|
138
|
+
t: 0,
|
|
139
|
+
rate: 1,
|
|
140
|
+
crash: 1,
|
|
141
|
+
auto: null,
|
|
142
|
+
milestone: 0,
|
|
143
|
+
pressTime: Number.NEGATIVE_INFINITY,
|
|
144
|
+
held: false
|
|
145
|
+
});
|
|
146
|
+
const cashedRef = useRef(null);
|
|
147
|
+
const busy = useRef(false);
|
|
148
|
+
const alive = useRef(true);
|
|
149
|
+
useEffect(() => {
|
|
150
|
+
alive.current = true;
|
|
151
|
+
return () => {
|
|
152
|
+
alive.current = false;
|
|
153
|
+
};
|
|
154
|
+
}, []);
|
|
155
|
+
const [internalSound, setInternalSound] = useState(defaultSound);
|
|
156
|
+
const soundOn = sound ?? internalSound;
|
|
157
|
+
const player = useRef(null);
|
|
158
|
+
const getPlayer = () => {
|
|
159
|
+
if (!player.current) player.current = createGameSounds();
|
|
160
|
+
return player.current;
|
|
161
|
+
};
|
|
162
|
+
useEffect(() => () => {
|
|
163
|
+
player.current?.dispose();
|
|
164
|
+
player.current = null;
|
|
165
|
+
}, []);
|
|
166
|
+
const running = phase === "running";
|
|
167
|
+
const starting = phase === "starting";
|
|
168
|
+
const crashed = phase === "crashed";
|
|
169
|
+
const roundLive = flight.current.live;
|
|
170
|
+
const crashKnown = !roundLive || crashAt?.round === round;
|
|
171
|
+
const overtaken = running && roundLive && crashKnown;
|
|
172
|
+
const t = crashed && crashedAt !== null ? timeAt(crashedAt) : elapsed;
|
|
173
|
+
const multiplier = crashed && crashedAt !== null ? crashedAt : floor2(growth(t));
|
|
174
|
+
const cashOut = (value, time) => {
|
|
175
|
+
if (!busy.current || cashedRef.current !== null) return;
|
|
176
|
+
cashedRef.current = value;
|
|
177
|
+
setCashed(value);
|
|
178
|
+
setCashedT(time);
|
|
179
|
+
setAnnouncement(text("announceCashedOut", { multiplier: formatMultiplier(value) }));
|
|
180
|
+
if (soundOn) getPlayer().cashOut();
|
|
181
|
+
if (Number.isFinite(flight.current.crash)) onCashOut?.(value);
|
|
182
|
+
else flight.current.held = true;
|
|
183
|
+
};
|
|
184
|
+
const fly = (id, crash) => {
|
|
185
|
+
flight.current = {
|
|
186
|
+
round: id,
|
|
187
|
+
live,
|
|
188
|
+
t: 0,
|
|
189
|
+
rate: 1,
|
|
190
|
+
crash,
|
|
191
|
+
auto,
|
|
192
|
+
milestone: 0,
|
|
193
|
+
pressTime: flight.current.pressTime,
|
|
194
|
+
held: false
|
|
195
|
+
};
|
|
196
|
+
setPhase("running");
|
|
197
|
+
setAnnouncement(auto === null ? text("announceStarted") : text("announceStartedAuto", { multiplier: formatMultiplier(auto) }));
|
|
198
|
+
};
|
|
199
|
+
const start = () => {
|
|
200
|
+
if (busy.current) return;
|
|
201
|
+
busy.current = true;
|
|
202
|
+
rounds += 1;
|
|
203
|
+
const id = rounds;
|
|
204
|
+
try {
|
|
205
|
+
onStart?.(id);
|
|
206
|
+
} catch (error) {
|
|
207
|
+
busy.current = false;
|
|
208
|
+
throw error;
|
|
209
|
+
}
|
|
210
|
+
flight.current.pressTime = performance.now();
|
|
211
|
+
cashedRef.current = null;
|
|
212
|
+
setCashed(null);
|
|
213
|
+
setCashedT(null);
|
|
214
|
+
setCrashedAt(null);
|
|
215
|
+
setElapsed(0);
|
|
216
|
+
setPulse(0);
|
|
217
|
+
setRoundAuto(auto);
|
|
218
|
+
setRound(id);
|
|
219
|
+
if (soundOn) getPlayer().prepare();
|
|
220
|
+
if (live) {
|
|
221
|
+
fly(id, Number.POSITIVE_INFINITY);
|
|
222
|
+
return;
|
|
223
|
+
}
|
|
224
|
+
let point;
|
|
225
|
+
try {
|
|
226
|
+
point = getCrashPoint ? getCrashPoint() : crashPoint();
|
|
227
|
+
} catch {
|
|
228
|
+
point = Promise.reject();
|
|
229
|
+
}
|
|
230
|
+
if (typeof point === "number") {
|
|
231
|
+
fly(id, settle(point));
|
|
232
|
+
return;
|
|
233
|
+
}
|
|
234
|
+
setPhase("starting");
|
|
235
|
+
setAnnouncement(text("announceStarting"));
|
|
236
|
+
Promise.resolve(point).then((value) => {
|
|
237
|
+
if (alive.current) fly(id, settle(value));
|
|
238
|
+
}, () => {
|
|
239
|
+
if (!alive.current) return;
|
|
240
|
+
busy.current = false;
|
|
241
|
+
setPhase("idle");
|
|
242
|
+
setAnnouncement(text("announceStartFailed"));
|
|
243
|
+
});
|
|
244
|
+
};
|
|
245
|
+
const skip = () => {
|
|
246
|
+
const f = flight.current;
|
|
247
|
+
if (!Number.isFinite(f.crash)) return;
|
|
248
|
+
f.rate = reduce ? 1e9 : Math.max(1, (timeAt(f.crash) - f.t) / SKIP_TIME);
|
|
249
|
+
};
|
|
250
|
+
const onFrame = useStable((dt) => {
|
|
251
|
+
if (!busy.current) return false;
|
|
252
|
+
const f = flight.current;
|
|
253
|
+
const wasIn = cashedRef.current === null;
|
|
254
|
+
if (f.live && !Number.isFinite(f.crash) && crashAt?.round === f.round) {
|
|
255
|
+
f.crash = settle(crashAt.value);
|
|
256
|
+
f.rate = reduce ? 1e9 : Math.max(1, (timeAt(f.crash) - f.t) / SKIP_TIME);
|
|
257
|
+
if (cashedRef.current !== null && cashedRef.current > f.crash) {
|
|
258
|
+
cashedRef.current = null;
|
|
259
|
+
setCashed(null);
|
|
260
|
+
setCashedT(null);
|
|
261
|
+
f.held = false;
|
|
262
|
+
}
|
|
263
|
+
}
|
|
264
|
+
if (f.live && !live && !Number.isFinite(f.crash)) {
|
|
265
|
+
f.crash = settle(growth(f.t));
|
|
266
|
+
if (f.held) {
|
|
267
|
+
f.held = false;
|
|
268
|
+
cashedRef.current = null;
|
|
269
|
+
setCashed(null);
|
|
270
|
+
setCashedT(null);
|
|
271
|
+
}
|
|
272
|
+
}
|
|
273
|
+
if (f.held && Number.isFinite(f.crash) && cashedRef.current !== null) {
|
|
274
|
+
f.held = false;
|
|
275
|
+
onCashOut?.(cashedRef.current);
|
|
276
|
+
}
|
|
277
|
+
const end = timeAt(f.crash);
|
|
278
|
+
f.t = Math.min(end, f.t + dt * f.rate, timeAt(CEILING));
|
|
279
|
+
const value = growth(f.t);
|
|
280
|
+
if (cashedRef.current === null) {
|
|
281
|
+
if (f.auto !== null && f.auto <= f.crash && (value >= f.auto || f.t >= end)) cashOut(f.auto, timeAt(f.auto));
|
|
282
|
+
else if (f.rate === 1 && f.t < end && Number.isFinite(value) && value >= milestone(f.milestone)) {
|
|
283
|
+
while (value >= milestone(f.milestone + 1)) f.milestone++;
|
|
284
|
+
setAnnouncement(formatShort(milestone(f.milestone)));
|
|
285
|
+
setPulse((count) => count + 1);
|
|
286
|
+
f.milestone++;
|
|
287
|
+
if (soundOn) getPlayer().gem(f.milestone);
|
|
288
|
+
}
|
|
289
|
+
}
|
|
290
|
+
if (f.t < end) {
|
|
291
|
+
setElapsed(f.t);
|
|
292
|
+
return true;
|
|
293
|
+
}
|
|
294
|
+
busy.current = false;
|
|
295
|
+
f.pressTime = performance.now();
|
|
296
|
+
setCrashedAt(f.crash);
|
|
297
|
+
setPhase("crashed");
|
|
298
|
+
setHistory((current) => [{
|
|
299
|
+
id: f.round,
|
|
300
|
+
value: f.crash
|
|
301
|
+
}, ...current].slice(0, HISTORY));
|
|
302
|
+
setAnnouncement(cashedRef.current === null ? text("announceLost", { multiplier: formatMultiplier(f.crash) }) : `${wasIn ? `${text("announceCashedOut", { multiplier: formatMultiplier(cashedRef.current) })} ` : ""}${text("announceCrashed", { multiplier: formatMultiplier(f.crash) })}`);
|
|
303
|
+
if (soundOn) getPlayer().mine();
|
|
304
|
+
onCrash?.(f.crash, cashedRef.current);
|
|
305
|
+
return false;
|
|
306
|
+
});
|
|
307
|
+
useEffect(() => {
|
|
308
|
+
if (phase !== "running") return;
|
|
309
|
+
let last = performance.now();
|
|
310
|
+
let id = requestAnimationFrame(function step() {
|
|
311
|
+
const now = performance.now();
|
|
312
|
+
const dt = Math.max(0, now - last) / 1e3;
|
|
313
|
+
last = now;
|
|
314
|
+
id = requestAnimationFrame(step);
|
|
315
|
+
if (!onFrame(dt)) cancelAnimationFrame(id);
|
|
316
|
+
});
|
|
317
|
+
return () => cancelAnimationFrame(id);
|
|
318
|
+
}, [phase, onFrame]);
|
|
319
|
+
const setAuto = useStable((value) => {
|
|
320
|
+
const next = value === "off" ? null : Number(value);
|
|
321
|
+
if (autoProp === void 0) setInternalAuto(next);
|
|
322
|
+
onAutoCashOutChange?.(next);
|
|
323
|
+
});
|
|
324
|
+
const autoOptions = useMemo(() => auto === null || AUTO_STEPS.includes(auto) ? AUTO_STEPS : [...AUTO_STEPS, auto].sort((a, b) => a - b), [auto]);
|
|
325
|
+
const toggleSound = useStable(() => {
|
|
326
|
+
const next = !soundOn;
|
|
327
|
+
if (next) getPlayer().prepare();
|
|
328
|
+
if (sound === void 0) setInternalSound(next);
|
|
329
|
+
onSoundChange?.(next);
|
|
330
|
+
});
|
|
331
|
+
/** Start, cash out or skip, whichever the round is ready for. */
|
|
332
|
+
const act = () => {
|
|
333
|
+
const now = performance.now();
|
|
334
|
+
if (starting || now - flight.current.pressTime < 400) return;
|
|
335
|
+
if (!running) start();
|
|
336
|
+
else if (cashedRef.current === null) {
|
|
337
|
+
if (overtaken || flight.current.live && Number.isFinite(flight.current.crash)) return;
|
|
338
|
+
flight.current.pressTime = now;
|
|
339
|
+
cashOut(floor2(growth(flight.current.t)), flight.current.t);
|
|
340
|
+
} else skip();
|
|
341
|
+
};
|
|
342
|
+
const actionLabel = starting ? text("starting") : running ? cashed === null ? overtaken ? text("crashing") : text("cashOut", { multiplier: formatMultiplier(multiplier) }) : crashKnown ? text("skip") : text("waiting") : crashed ? text("playAgain") : text("start");
|
|
343
|
+
/** The main action can't act right now: the crash point is still coming, or a live round is already over. */
|
|
344
|
+
const actionBusy = starting || running && cashed !== null && !crashKnown || overtaken && cashed === null;
|
|
345
|
+
const lost = crashed && cashed === null;
|
|
346
|
+
const eyebrow = text(lost ? "stateCrashed" : crashed ? "stateCashedOut" : running ? "stateFlying" : starting ? "stateStarting" : "stateReady");
|
|
347
|
+
const shownAuto = running ? roundAuto : auto;
|
|
348
|
+
const status = crashed ? cashed !== null ? multiplier / cashed < 1.1 ? text("statusCloseCall", { multiplier: formatMultiplier(multiplier) }) : text("statusFlewOn", { multiplier: formatMultiplier(multiplier) }) : roundAuto !== null ? text("statusShort", { target: formatShort(roundAuto) }) : text("statusStillIn") : shownAuto !== null ? text("statusAuto", { multiplier: formatMultiplier(shownAuto) }) : running ? text("statusFlying") : text("statusIdle");
|
|
349
|
+
const target = cashed !== null || crashed ? null : running ? roundAuto : auto;
|
|
350
|
+
const ghost = (crashed ? history[1] : history[0])?.value ?? null;
|
|
351
|
+
return {
|
|
352
|
+
reduce,
|
|
353
|
+
/** The built-in fair crash point decides the round, so "1 in m" odds hold. */
|
|
354
|
+
fair: !live && !getCrashPoint,
|
|
355
|
+
target,
|
|
356
|
+
ghost,
|
|
357
|
+
/** The auto target the current or last round played with. */
|
|
358
|
+
roundAuto,
|
|
359
|
+
phase,
|
|
360
|
+
running,
|
|
361
|
+
starting,
|
|
362
|
+
crashed,
|
|
363
|
+
lost,
|
|
364
|
+
/** A skip is running the rest of the flight out; scenery that streams with t would only flicker. */
|
|
365
|
+
skipping: running && flight.current.rate > 1,
|
|
366
|
+
/** Seconds into the flight, frozen at the crash. */
|
|
367
|
+
t,
|
|
368
|
+
multiplier,
|
|
369
|
+
cashed,
|
|
370
|
+
/** Seconds into the flight at the cash out, or null. */
|
|
371
|
+
cashedT,
|
|
372
|
+
round,
|
|
373
|
+
pulse,
|
|
374
|
+
history,
|
|
375
|
+
auto,
|
|
376
|
+
autoOptions,
|
|
377
|
+
setAuto,
|
|
378
|
+
soundOn,
|
|
379
|
+
toggleSound,
|
|
380
|
+
act,
|
|
381
|
+
actionLabel,
|
|
382
|
+
actionBusy,
|
|
383
|
+
eyebrow,
|
|
384
|
+
status,
|
|
385
|
+
announcement,
|
|
386
|
+
/** The game's built-in text, resolved for the current locale and `labels`. */
|
|
387
|
+
text
|
|
388
|
+
};
|
|
389
|
+
}
|
|
390
|
+
// src/components/motion/crash/crash-parts.tsx
|
|
391
|
+
/** The width of the viewBox an SVG stage draws in. */
|
|
392
|
+
const STAGE_W = 400;
|
|
393
|
+
/**
|
|
394
|
+
* SVG stage labels: 10px on screen however narrow the card. A viewBox scales
|
|
395
|
+
* its text with the stage, so the shell sets --crash-label in viewBox units.
|
|
396
|
+
* The server render has no width to go on and draws them at 10 units.
|
|
397
|
+
*/
|
|
398
|
+
const STAGE_LABEL = "text-[length:var(--crash-label,10px)]";
|
|
399
|
+
/**
|
|
400
|
+
* The frame every design sits in: one card holding the recent rounds and
|
|
401
|
+
* sound, the stage with the readout pinned top left, and the controls. Each
|
|
402
|
+
* design draws only its stage, which must keep the top-left corner clear.
|
|
403
|
+
*/
|
|
404
|
+
function CrashShell({ game, "aria-label": ariaLabel, className, children, miniature }) {
|
|
405
|
+
const mainRef = useRef(null);
|
|
406
|
+
const stageRef = useRef(null);
|
|
407
|
+
useLayoutEffect(() => {
|
|
408
|
+
const node = stageRef.current;
|
|
409
|
+
if (!node) return;
|
|
410
|
+
const measure = () => {
|
|
411
|
+
const width = node.clientWidth;
|
|
412
|
+
if (width > 0) node.style.setProperty("--crash-label", `${Math.max(10, 4e3 / width)}px`);
|
|
413
|
+
};
|
|
414
|
+
measure();
|
|
415
|
+
const observer = new ResizeObserver(measure);
|
|
416
|
+
observer.observe(node);
|
|
417
|
+
return () => observer.disconnect();
|
|
418
|
+
}, []);
|
|
419
|
+
const [openRound, setOpenRound] = useState(null);
|
|
420
|
+
const resultShown = game.crashed && openRound === game.round;
|
|
421
|
+
const { crashed, round } = game;
|
|
422
|
+
const ticketDelay = useStable(() => (game.reduce ? .15 : TICKET_DELAY) * 1e3);
|
|
423
|
+
useEffect(() => {
|
|
424
|
+
if (!crashed) return;
|
|
425
|
+
const id = setTimeout(() => setOpenRound(round), ticketDelay());
|
|
426
|
+
return () => clearTimeout(id);
|
|
427
|
+
}, [
|
|
428
|
+
crashed,
|
|
429
|
+
round,
|
|
430
|
+
ticketDelay
|
|
431
|
+
]);
|
|
432
|
+
const closeResult = () => {
|
|
433
|
+
setOpenRound(null);
|
|
434
|
+
mainRef.current?.focus();
|
|
435
|
+
};
|
|
436
|
+
return /* @__PURE__ */ jsxs("section", {
|
|
437
|
+
"aria-label": ariaLabel,
|
|
438
|
+
tabIndex: -1,
|
|
439
|
+
className: cn("w-full max-w-md outline-none", className),
|
|
440
|
+
onKeyDown: (event) => {
|
|
441
|
+
if (event.key !== "Escape" || !resultShown) return;
|
|
442
|
+
if (event.target instanceof Element && event.target.closest("[role=\"listbox\"],[aria-expanded=\"true\"]")) return;
|
|
443
|
+
event.stopPropagation();
|
|
444
|
+
closeResult();
|
|
445
|
+
},
|
|
446
|
+
children: [/* @__PURE__ */ jsxs("div", {
|
|
447
|
+
className: "border-border flex flex-col gap-3 rounded-3xl border p-3",
|
|
448
|
+
children: [
|
|
449
|
+
/* @__PURE__ */ jsxs("div", {
|
|
450
|
+
className: "flex h-8 items-center gap-2 pl-1",
|
|
451
|
+
children: [
|
|
452
|
+
/* @__PURE__ */ jsx(History, {
|
|
453
|
+
"aria-hidden": "true",
|
|
454
|
+
className: "text-muted-foreground size-3.5 shrink-0",
|
|
455
|
+
strokeWidth: 2
|
|
456
|
+
}),
|
|
457
|
+
/* @__PURE__ */ jsx(GameHistory, {
|
|
458
|
+
history: game.history,
|
|
459
|
+
reduce: game.reduce,
|
|
460
|
+
"aria-label": game.text("recentCrashes"),
|
|
461
|
+
emptyLabel: game.text("recentEmpty"),
|
|
462
|
+
className: "min-w-0 flex-1"
|
|
463
|
+
}),
|
|
464
|
+
/* @__PURE__ */ jsx(SoundToggle, {
|
|
465
|
+
on: game.soundOn,
|
|
466
|
+
onToggle: game.toggleSound,
|
|
467
|
+
label: game.text("sound")
|
|
468
|
+
})
|
|
469
|
+
]
|
|
470
|
+
}),
|
|
471
|
+
/* @__PURE__ */ jsxs("div", {
|
|
472
|
+
ref: stageRef,
|
|
473
|
+
className: "bg-muted/40 @container relative aspect-[10/7] overflow-hidden rounded-xl",
|
|
474
|
+
children: [
|
|
475
|
+
children,
|
|
476
|
+
/* @__PURE__ */ jsxs("div", {
|
|
477
|
+
className: "pointer-events-none absolute top-4 left-4",
|
|
478
|
+
children: [
|
|
479
|
+
/* @__PURE__ */ jsx(GameEyebrow, {
|
|
480
|
+
label: game.eyebrow,
|
|
481
|
+
state: game.crashed ? game.lost ? "lost" : "won" : game.running && game.cashed === null ? "live" : "idle",
|
|
482
|
+
reduce: game.reduce
|
|
483
|
+
}),
|
|
484
|
+
/* @__PURE__ */ jsx(CrashMultiplier, {
|
|
485
|
+
game,
|
|
486
|
+
className: "mt-1 text-3xl @min-[20rem]:text-4xl [&>span]:origin-left"
|
|
487
|
+
}),
|
|
488
|
+
/* @__PURE__ */ jsx(CrashStatus, {
|
|
489
|
+
game,
|
|
490
|
+
className: "mt-2"
|
|
491
|
+
})
|
|
492
|
+
]
|
|
493
|
+
}),
|
|
494
|
+
/* @__PURE__ */ jsx(AnimatePresence, { children: resultShown ? /* @__PURE__ */ jsx(PresenceGate, { children: ({ gate }) => /* @__PURE__ */ jsx(ResultTicket, {
|
|
495
|
+
game,
|
|
496
|
+
gate,
|
|
497
|
+
onClose: closeResult,
|
|
498
|
+
miniature
|
|
499
|
+
}) }, "result") : null })
|
|
500
|
+
]
|
|
501
|
+
}),
|
|
502
|
+
/* @__PURE__ */ jsx(CrashControls, {
|
|
503
|
+
game,
|
|
504
|
+
mainRef
|
|
505
|
+
})
|
|
506
|
+
]
|
|
507
|
+
}), /* @__PURE__ */ jsx(CrashAnnouncer, { game })]
|
|
508
|
+
});
|
|
509
|
+
}
|
|
510
|
+
const TICKET_DELAY = .7;
|
|
511
|
+
const CARD_IN = {
|
|
512
|
+
type: "spring",
|
|
513
|
+
duration: .4,
|
|
514
|
+
bounce: .15
|
|
515
|
+
};
|
|
516
|
+
const CARD_OUT = {
|
|
517
|
+
duration: .15,
|
|
518
|
+
ease: EASE_OUT
|
|
519
|
+
};
|
|
520
|
+
const CHUNK = {
|
|
521
|
+
duration: .25,
|
|
522
|
+
ease: EASE_OUT
|
|
523
|
+
};
|
|
524
|
+
const TEAR = 104;
|
|
525
|
+
const TICKET_SHADOW = "[filter:drop-shadow(0_1px_1px_rgb(0_0_0/0.12))_drop-shadow(0_12px_16px_rgb(0_0_0/0.3))]";
|
|
526
|
+
const NOTCH_MASK = `radial-gradient(circle 9px at 0 ${TEAR}px, transparent 98%, black), radial-gradient(circle 9px at 100% ${TEAR}px, transparent 98%, black)`;
|
|
527
|
+
/**
|
|
528
|
+
* The end-of-round receipt over a dimmed stage. It has no buttons: the main
|
|
529
|
+
* action already says Play again, and tapping the stage (or Escape) puts it
|
|
530
|
+
* away to look at the flight.
|
|
531
|
+
*/
|
|
532
|
+
function ResultTicket({ game, gate, onClose, miniature }) {
|
|
533
|
+
const { reduce } = game;
|
|
534
|
+
return /* @__PURE__ */ jsxs(Fragment$1, { children: [/* @__PURE__ */ jsx(motion.button, {
|
|
535
|
+
type: "button",
|
|
536
|
+
"aria-label": game.text("hideResult"),
|
|
537
|
+
onClick: onClose,
|
|
538
|
+
...gate,
|
|
539
|
+
className: "bg-background/55 focus-visible:ring-primary absolute inset-0 z-20 cursor-default backdrop-blur-[2px] outline-none focus-visible:ring-2 focus-visible:ring-inset",
|
|
540
|
+
initial: { opacity: 0 },
|
|
541
|
+
animate: { opacity: 1 },
|
|
542
|
+
exit: {
|
|
543
|
+
opacity: 0,
|
|
544
|
+
transition: CARD_OUT
|
|
545
|
+
},
|
|
546
|
+
transition: {
|
|
547
|
+
duration: .2,
|
|
548
|
+
ease: EASE_OUT
|
|
549
|
+
}
|
|
550
|
+
}), /* @__PURE__ */ jsx("div", {
|
|
551
|
+
inert: gate.inert,
|
|
552
|
+
className: "pointer-events-none absolute inset-0 z-20 grid place-items-center p-4",
|
|
553
|
+
children: /* @__PURE__ */ jsx(motion.div, {
|
|
554
|
+
role: "group",
|
|
555
|
+
"aria-label": game.text("result"),
|
|
556
|
+
className: cn("w-full max-w-[17rem]", TICKET_SHADOW),
|
|
557
|
+
initial: reduce ? { opacity: 0 } : {
|
|
558
|
+
opacity: 0,
|
|
559
|
+
y: 16,
|
|
560
|
+
scale: .96
|
|
561
|
+
},
|
|
562
|
+
animate: {
|
|
563
|
+
opacity: 1,
|
|
564
|
+
y: 0,
|
|
565
|
+
scale: 1
|
|
566
|
+
},
|
|
567
|
+
exit: reduce ? {
|
|
568
|
+
opacity: 0,
|
|
569
|
+
transition: CARD_OUT
|
|
570
|
+
} : {
|
|
571
|
+
opacity: 0,
|
|
572
|
+
y: 8,
|
|
573
|
+
scale: .98,
|
|
574
|
+
transition: CARD_OUT
|
|
575
|
+
},
|
|
576
|
+
transition: reduce ? { duration: .2 } : CARD_IN,
|
|
577
|
+
children: /* @__PURE__ */ jsx(Ticket, {
|
|
578
|
+
game,
|
|
579
|
+
miniature
|
|
580
|
+
})
|
|
581
|
+
})
|
|
582
|
+
})] });
|
|
583
|
+
}
|
|
584
|
+
function Chunk({ delay, reduce, className, children }) {
|
|
585
|
+
return /* @__PURE__ */ jsx(motion.div, {
|
|
586
|
+
className,
|
|
587
|
+
initial: reduce ? { opacity: 0 } : {
|
|
588
|
+
opacity: 0,
|
|
589
|
+
y: 6
|
|
590
|
+
},
|
|
591
|
+
animate: {
|
|
592
|
+
opacity: 1,
|
|
593
|
+
y: 0
|
|
594
|
+
},
|
|
595
|
+
transition: {
|
|
596
|
+
...CHUNK,
|
|
597
|
+
delay: reduce ? 0 : delay
|
|
598
|
+
},
|
|
599
|
+
children
|
|
600
|
+
});
|
|
601
|
+
}
|
|
602
|
+
function Ticket({ game, miniature }) {
|
|
603
|
+
const { cashed, multiplier: crash, roundAuto, reduce, t, text } = game;
|
|
604
|
+
const won = cashed !== null;
|
|
605
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
606
|
+
className: "bg-card text-foreground @container w-full rounded-2xl @max-[17rem]:scale-[0.72] @min-[17rem]:@max-[21rem]:scale-[0.85]",
|
|
607
|
+
style: {
|
|
608
|
+
WebkitMaskImage: NOTCH_MASK,
|
|
609
|
+
WebkitMaskComposite: "source-in",
|
|
610
|
+
maskImage: NOTCH_MASK,
|
|
611
|
+
maskComposite: "intersect"
|
|
612
|
+
},
|
|
613
|
+
children: [
|
|
614
|
+
/* @__PURE__ */ jsxs("div", {
|
|
615
|
+
className: cn("flex flex-col items-center justify-center gap-1 rounded-t-2xl px-5 text-center", won ? "bg-primary/10" : "bg-rose-500/10"),
|
|
616
|
+
style: { height: TEAR },
|
|
617
|
+
children: [/* @__PURE__ */ jsx(Chunk, {
|
|
618
|
+
delay: .05,
|
|
619
|
+
reduce,
|
|
620
|
+
children: /* @__PURE__ */ jsx("p", {
|
|
621
|
+
className: cn("text-xs font-medium tracking-wide uppercase", won ? PRIMARY_TEXT : "text-rose-700 dark:text-rose-400"),
|
|
622
|
+
children: text(won ? "stateCashedOut" : "stateCrashed")
|
|
623
|
+
})
|
|
624
|
+
}), /* @__PURE__ */ jsx(Chunk, {
|
|
625
|
+
delay: .1,
|
|
626
|
+
reduce,
|
|
627
|
+
children: /* @__PURE__ */ jsx("p", {
|
|
628
|
+
className: cn("text-3xl font-semibold", !won && "text-muted-foreground line-through decoration-2"),
|
|
629
|
+
children: won ? /* @__PURE__ */ jsx(NumberTicker, {
|
|
630
|
+
value: cashed,
|
|
631
|
+
decimals: 2,
|
|
632
|
+
format: (value) => formatMultiplier(value).slice(0, -1),
|
|
633
|
+
suffix: "×",
|
|
634
|
+
startOnView: false,
|
|
635
|
+
duration: .6,
|
|
636
|
+
stagger: .05
|
|
637
|
+
}) : /* @__PURE__ */ jsx("span", {
|
|
638
|
+
className: "tabular-nums",
|
|
639
|
+
children: formatMultiplier(crash)
|
|
640
|
+
})
|
|
641
|
+
})
|
|
642
|
+
})]
|
|
643
|
+
}),
|
|
644
|
+
/* @__PURE__ */ jsx("div", {
|
|
645
|
+
"aria-hidden": "true",
|
|
646
|
+
className: "border-border mx-4 border-t-2 border-dashed"
|
|
647
|
+
}),
|
|
648
|
+
/* @__PURE__ */ jsxs("div", {
|
|
649
|
+
className: "flex items-center gap-4 px-5 pt-4 pb-5",
|
|
650
|
+
children: [/* @__PURE__ */ jsx(Chunk, {
|
|
651
|
+
delay: .18,
|
|
652
|
+
reduce,
|
|
653
|
+
className: "flex-1",
|
|
654
|
+
children: /* @__PURE__ */ jsxs("dl", {
|
|
655
|
+
className: "grid gap-1.5 text-xs",
|
|
656
|
+
children: [
|
|
657
|
+
/* @__PURE__ */ jsx(Row, {
|
|
658
|
+
label: text("crashedAt"),
|
|
659
|
+
value: formatMultiplier(crash)
|
|
660
|
+
}),
|
|
661
|
+
/* @__PURE__ */ jsx(Row, {
|
|
662
|
+
label: text("flight"),
|
|
663
|
+
value: text("seconds", { seconds: t.toFixed(1) })
|
|
664
|
+
}),
|
|
665
|
+
won && game.fair ? /* @__PURE__ */ jsx(Row, {
|
|
666
|
+
label: text("oddsBeaten"),
|
|
667
|
+
value: text("odds", { odds: formatMultiplier(cashed).slice(0, -1) })
|
|
668
|
+
}) : won ? /* @__PURE__ */ jsx(Row, {
|
|
669
|
+
label: text("leftAt"),
|
|
670
|
+
value: formatMultiplier(cashed)
|
|
671
|
+
}) : /* @__PURE__ */ jsx(Row, {
|
|
672
|
+
label: text("autoTarget"),
|
|
673
|
+
value: roundAuto === null ? text("autoOff") : formatShort(roundAuto)
|
|
674
|
+
})
|
|
675
|
+
]
|
|
676
|
+
})
|
|
677
|
+
}), miniature ? /* @__PURE__ */ jsx(Chunk, {
|
|
678
|
+
delay: .24,
|
|
679
|
+
reduce,
|
|
680
|
+
className: "@max-[15rem]:hidden",
|
|
681
|
+
children: miniature({
|
|
682
|
+
crash,
|
|
683
|
+
cashed,
|
|
684
|
+
cashedT: game.cashedT,
|
|
685
|
+
target: won ? null : roundAuto,
|
|
686
|
+
reduce
|
|
687
|
+
})
|
|
688
|
+
}) : null]
|
|
689
|
+
})
|
|
690
|
+
]
|
|
691
|
+
});
|
|
692
|
+
}
|
|
693
|
+
function Row({ label, value }) {
|
|
694
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
695
|
+
className: "flex justify-between gap-2 whitespace-nowrap",
|
|
696
|
+
children: [/* @__PURE__ */ jsx("dt", {
|
|
697
|
+
className: "text-muted-foreground",
|
|
698
|
+
children: label
|
|
699
|
+
}), /* @__PURE__ */ jsx("dd", {
|
|
700
|
+
className: "font-medium tabular-nums",
|
|
701
|
+
children: value
|
|
702
|
+
})]
|
|
703
|
+
});
|
|
704
|
+
}
|
|
705
|
+
const CHUTE = {
|
|
706
|
+
y: {
|
|
707
|
+
duration: 2.2,
|
|
708
|
+
ease: EASE_OUT
|
|
709
|
+
},
|
|
710
|
+
rotate: {
|
|
711
|
+
duration: 2.2,
|
|
712
|
+
ease: EASE_IN_OUT
|
|
713
|
+
},
|
|
714
|
+
opacity: {
|
|
715
|
+
duration: 2.2,
|
|
716
|
+
times: [
|
|
717
|
+
0,
|
|
718
|
+
.08,
|
|
719
|
+
.7,
|
|
720
|
+
1
|
|
721
|
+
]
|
|
722
|
+
}
|
|
723
|
+
};
|
|
724
|
+
const clamp01 = (value) => Math.min(1, Math.max(0, value));
|
|
725
|
+
/** Wraps scenery that streams past into a loop `span` long. */
|
|
726
|
+
const wrap = (value, span) => (value % span + span) % span;
|
|
727
|
+
/** A tick step of 1, 2 or 5 times a power of ten, at least `min`. */
|
|
728
|
+
function niceAtLeast(min) {
|
|
729
|
+
const power = 10 ** Math.floor(Math.log10(min));
|
|
730
|
+
return Number((([
|
|
731
|
+
1,
|
|
732
|
+
2,
|
|
733
|
+
5,
|
|
734
|
+
10
|
|
735
|
+
].find((unit) => unit * power >= min) ?? 10) * power).toPrecision(12));
|
|
736
|
+
}
|
|
737
|
+
/** The parachute that opens at a cash out: a scalloped canopy, three lines and the player. */
|
|
738
|
+
function Parachute() {
|
|
739
|
+
return /* @__PURE__ */ jsxs("g", {
|
|
740
|
+
className: "text-primary",
|
|
741
|
+
children: [
|
|
742
|
+
/* @__PURE__ */ jsx("path", {
|
|
743
|
+
d: "M-9,0Q-9,-11 0,-11Q9,-11 9,0Q6,-3 3,0Q0,-3 -3,0Q-6,-3 -9,0Z",
|
|
744
|
+
fill: "currentColor"
|
|
745
|
+
}),
|
|
746
|
+
/* @__PURE__ */ jsx("path", {
|
|
747
|
+
d: "M-9,0L0,10M0,0L0,10M9,0L0,10",
|
|
748
|
+
stroke: "currentColor",
|
|
749
|
+
strokeWidth: .75,
|
|
750
|
+
opacity: .6,
|
|
751
|
+
fill: "none"
|
|
752
|
+
}),
|
|
753
|
+
/* @__PURE__ */ jsx("circle", {
|
|
754
|
+
cy: 11.5,
|
|
755
|
+
r: 2,
|
|
756
|
+
fill: "currentColor"
|
|
757
|
+
})
|
|
758
|
+
]
|
|
759
|
+
});
|
|
760
|
+
}
|
|
761
|
+
/** Every miniature is 88 × 48, like Mines' mini map. */
|
|
762
|
+
const MINI = {
|
|
763
|
+
width: 88,
|
|
764
|
+
height: 48
|
|
765
|
+
};
|
|
766
|
+
const MINI_REPLAY = {
|
|
767
|
+
delay: .3,
|
|
768
|
+
duration: .6,
|
|
769
|
+
ease: EASE_OUT
|
|
770
|
+
};
|
|
771
|
+
/** The Auto menu and the main action, in one 40px row with 12px corners. */
|
|
772
|
+
function CrashControls({ game, mainRef }) {
|
|
773
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
774
|
+
className: "flex items-center gap-2",
|
|
775
|
+
children: [/* @__PURE__ */ jsx(AutoMenu, {
|
|
776
|
+
auto: game.auto,
|
|
777
|
+
options: game.autoOptions,
|
|
778
|
+
onChange: game.setAuto,
|
|
779
|
+
disabled: game.running || game.starting,
|
|
780
|
+
label: game.text("auto"),
|
|
781
|
+
offLabel: game.text("autoOff")
|
|
782
|
+
}), /* @__PURE__ */ jsxs(Button, {
|
|
783
|
+
ref: mainRef,
|
|
784
|
+
className: "aria-disabled:hover:bg-primary relative h-10 flex-1 overflow-hidden rounded-xl tabular-nums aria-disabled:cursor-wait aria-disabled:opacity-60",
|
|
785
|
+
"aria-disabled": game.actionBusy || void 0,
|
|
786
|
+
"aria-busy": game.starting || void 0,
|
|
787
|
+
pressScale: game.actionBusy ? 1 : .96,
|
|
788
|
+
...game.actionBusy ? { whileHover: {} } : {},
|
|
789
|
+
onClick: game.act,
|
|
790
|
+
onKeyDown: (event) => {
|
|
791
|
+
if (event.repeat && event.key === "Enter") event.preventDefault();
|
|
792
|
+
},
|
|
793
|
+
children: [game.actionLabel, game.running && game.target !== null ? /* @__PURE__ */ jsx("span", {
|
|
794
|
+
"aria-hidden": "true",
|
|
795
|
+
className: "bg-primary-foreground/45 pointer-events-none absolute inset-x-0 bottom-0 h-[3px] origin-left",
|
|
796
|
+
style: { transform: `scaleX(${Math.min(1, Math.log(growth(game.t)) / Math.log(game.target)).toFixed(4)})` }
|
|
797
|
+
}) : null]
|
|
798
|
+
})]
|
|
799
|
+
});
|
|
800
|
+
}
|
|
801
|
+
/** The Auto cash-out menu. */
|
|
802
|
+
const AutoMenu = memo(function AutoMenu({ auto, options, onChange, disabled, label, offLabel }) {
|
|
803
|
+
return /* @__PURE__ */ jsxs(Select, {
|
|
804
|
+
value: auto === null ? "off" : String(auto),
|
|
805
|
+
onValueChange: onChange,
|
|
806
|
+
disabled,
|
|
807
|
+
className: "w-32 shrink-0",
|
|
808
|
+
children: [/* @__PURE__ */ jsx(SelectTrigger, {
|
|
809
|
+
className: "h-10 tabular-nums",
|
|
810
|
+
children: /* @__PURE__ */ jsxs("span", {
|
|
811
|
+
className: "flex items-baseline gap-1.5",
|
|
812
|
+
children: [/* @__PURE__ */ jsx("span", {
|
|
813
|
+
className: "text-muted-foreground text-xs",
|
|
814
|
+
children: label
|
|
815
|
+
}), /* @__PURE__ */ jsx(SelectValue, { placeholder: auto === null ? offLabel : formatShort(auto) })]
|
|
816
|
+
})
|
|
817
|
+
}), /* @__PURE__ */ jsxs(SelectContent, { children: [/* @__PURE__ */ jsx(SelectItem, {
|
|
818
|
+
value: "off",
|
|
819
|
+
children: offLabel
|
|
820
|
+
}), options.map((step) => /* @__PURE__ */ jsx(SelectItem, {
|
|
821
|
+
value: String(step),
|
|
822
|
+
children: formatShort(step)
|
|
823
|
+
}, step))] })]
|
|
824
|
+
});
|
|
825
|
+
});
|
|
826
|
+
/**
|
|
827
|
+
* The live multiplier, warming as it climbs, that becomes the result at the
|
|
828
|
+
* crash: red and shaking on a loss, your cash out in primary on a win.
|
|
829
|
+
*/
|
|
830
|
+
function CrashMultiplier({ game, className }) {
|
|
831
|
+
const { lost, crashed, cashed, reduce, pulse, round } = game;
|
|
832
|
+
const final = crashed && cashed !== null;
|
|
833
|
+
return /* @__PURE__ */ jsx(motion.p, {
|
|
834
|
+
className: cn("font-semibold tracking-tight tabular-nums transition-colors duration-150", className, lost ? "text-rose-600 dark:text-rose-400" : final ? "text-primary" : HEAT_TEXT[heat(game.multiplier)]),
|
|
835
|
+
animate: lost && !reduce ? { x: [
|
|
836
|
+
0,
|
|
837
|
+
-6,
|
|
838
|
+
6,
|
|
839
|
+
-3,
|
|
840
|
+
3,
|
|
841
|
+
0
|
|
842
|
+
] } : { x: 0 },
|
|
843
|
+
transition: SHAKE,
|
|
844
|
+
children: /* @__PURE__ */ jsx(motion.span, {
|
|
845
|
+
className: "inline-block",
|
|
846
|
+
initial: reduce ? final ? { opacity: 0 } : false : final ? {
|
|
847
|
+
opacity: 0,
|
|
848
|
+
scale: .96,
|
|
849
|
+
filter: "blur(4px)"
|
|
850
|
+
} : pulse > 0 ? { scale: 1.08 } : false,
|
|
851
|
+
animate: {
|
|
852
|
+
opacity: 1,
|
|
853
|
+
scale: 1,
|
|
854
|
+
filter: "blur(0px)"
|
|
855
|
+
},
|
|
856
|
+
transition: final ? SWAP : PULSE,
|
|
857
|
+
children: formatMultiplier(final ? cashed : game.multiplier)
|
|
858
|
+
}, final ? "final" : pulse)
|
|
859
|
+
}, round);
|
|
860
|
+
}
|
|
861
|
+
/**
|
|
862
|
+
* The line under the multiplier: a hint before and during the flight, a
|
|
863
|
+
* solid badge from the cash out until the crash, then the round's context.
|
|
864
|
+
*/
|
|
865
|
+
function CrashStatus({ game, className }) {
|
|
866
|
+
const { cashed, crashed, status, reduce } = game;
|
|
867
|
+
return /* @__PURE__ */ jsx("div", {
|
|
868
|
+
className: cn("flex h-6 items-center", className),
|
|
869
|
+
children: /* @__PURE__ */ jsx(AnimatePresence, {
|
|
870
|
+
initial: false,
|
|
871
|
+
mode: "popLayout",
|
|
872
|
+
children: cashed !== null && !crashed ? /* @__PURE__ */ jsxs(motion.p, {
|
|
873
|
+
className: "bg-primary text-primary-foreground inline-flex h-6 items-center gap-1 rounded-full pr-2.5 pl-2 text-xs font-medium tabular-nums",
|
|
874
|
+
initial: reduce ? { opacity: 0 } : {
|
|
875
|
+
opacity: 0,
|
|
876
|
+
scale: .96,
|
|
877
|
+
filter: "blur(4px)"
|
|
878
|
+
},
|
|
879
|
+
animate: {
|
|
880
|
+
opacity: 1,
|
|
881
|
+
scale: 1,
|
|
882
|
+
filter: "blur(0px)"
|
|
883
|
+
},
|
|
884
|
+
exit: {
|
|
885
|
+
opacity: 0,
|
|
886
|
+
transition: EXIT
|
|
887
|
+
},
|
|
888
|
+
transition: SWAP,
|
|
889
|
+
children: [/* @__PURE__ */ jsx(Check, {
|
|
890
|
+
"aria-hidden": "true",
|
|
891
|
+
className: "size-3.5",
|
|
892
|
+
strokeWidth: 2.5
|
|
893
|
+
}), game.text("cashedBadge", { multiplier: formatMultiplier(cashed) })]
|
|
894
|
+
}, "cashed") : /* @__PURE__ */ jsx(motion.p, {
|
|
895
|
+
className: "text-muted-foreground text-xs tabular-nums",
|
|
896
|
+
initial: reduce ? { opacity: 0 } : {
|
|
897
|
+
opacity: 0,
|
|
898
|
+
y: 4,
|
|
899
|
+
filter: "blur(4px)"
|
|
900
|
+
},
|
|
901
|
+
animate: {
|
|
902
|
+
opacity: 1,
|
|
903
|
+
y: 0,
|
|
904
|
+
filter: "blur(0px)"
|
|
905
|
+
},
|
|
906
|
+
exit: {
|
|
907
|
+
opacity: 0,
|
|
908
|
+
transition: EXIT
|
|
909
|
+
},
|
|
910
|
+
transition: SWAP,
|
|
911
|
+
children: status
|
|
912
|
+
}, status)
|
|
913
|
+
})
|
|
914
|
+
});
|
|
915
|
+
}
|
|
916
|
+
/** The polite live region for starts, milestones, cash outs and crashes. */
|
|
917
|
+
function CrashAnnouncer({ game }) {
|
|
918
|
+
return /* @__PURE__ */ jsx("p", {
|
|
919
|
+
"aria-live": "polite",
|
|
920
|
+
className: "sr-only",
|
|
921
|
+
children: game.announcement
|
|
922
|
+
});
|
|
923
|
+
}
|
|
924
|
+
export { Parachute as a, clamp01 as c, BURST as d, GROWTH as f, useCrashGame as g, timeAt as h, MINI_REPLAY as i, niceAtLeast as l, growth as m, CrashShell as n, STAGE_LABEL as o, crashPoint as p, MINI as r, STAGE_W as s, CHUTE as t, wrap as u };
|
|
925
|
+
|
|
926
|
+
//# sourceMappingURL=crash-parts-Dg5WC8u4.js.map
|