@quantinuum/quantinuum-ui 4.0.0 → 4.0.1-fix-update-radix.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_virtual/index.js +4 -0
- package/dist/_virtual/index.js.map +1 -0
- package/dist/_virtual/use-sync-external-store-shim.development.js +4 -0
- package/dist/_virtual/use-sync-external-store-shim.development.js.map +1 -0
- package/dist/_virtual/use-sync-external-store-shim.production.js +4 -0
- package/dist/_virtual/use-sync-external-store-shim.production.js.map +1 -0
- package/dist/node_modules/@radix-ui/number/dist/index.mjs.js +4 -3
- package/dist/node_modules/@radix-ui/number/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/primitive/dist/index.mjs.js +9 -6
- package/dist/node_modules/@radix-ui/primitive/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-accordion/dist/index.mjs.js +279 -267
- package/dist/node_modules/@radix-ui/react-accordion/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-arrow/dist/index.mjs.js +26 -0
- package/dist/node_modules/@radix-ui/react-arrow/dist/index.mjs.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-avatar/dist/index.mjs.js +114 -92
- package/dist/node_modules/@radix-ui/react-avatar/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-checkbox/dist/index.mjs.js +255 -138
- package/dist/node_modules/@radix-ui/react-checkbox/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-collapsible/dist/index.mjs.js +135 -130
- package/dist/node_modules/@radix-ui/react-collapsible/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-collection/dist/index.mjs.js +66 -88
- package/dist/node_modules/@radix-ui/react-collection/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-collection/node_modules/@radix-ui/react-slot/dist/index.mjs.js +81 -73
- package/dist/node_modules/@radix-ui/react-collection/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-compose-refs/dist/index.mjs.js +34 -21
- package/dist/node_modules/@radix-ui/react-compose-refs/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-context/dist/index.mjs.js +72 -93
- package/dist/node_modules/@radix-ui/react-context/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-dialog/dist/index.mjs.js +297 -254
- package/dist/node_modules/@radix-ui/react-dialog/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-slot/dist/index.mjs.js +81 -73
- package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-direction/dist/index.mjs.js +8 -6
- package/dist/node_modules/@radix-ui/react-direction/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-dismissable-layer/dist/index.mjs.js +190 -217
- package/dist/node_modules/@radix-ui/react-dismissable-layer/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-dropdown-menu/dist/index.mjs.js +243 -217
- package/dist/node_modules/@radix-ui/react-dropdown-menu/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-focus-guards/dist/index.mjs.js +26 -25
- package/dist/node_modules/@radix-ui/react-focus-guards/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-focus-scope/dist/index.mjs.js +191 -259
- package/dist/node_modules/@radix-ui/react-focus-scope/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-hover-card/dist/index.mjs.js +224 -205
- package/dist/node_modules/@radix-ui/react-hover-card/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-id/dist/index.mjs.js +11 -14
- package/dist/node_modules/@radix-ui/react-id/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-label/dist/index.mjs.js +22 -14
- package/dist/node_modules/@radix-ui/react-label/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-menu/dist/index.mjs.js +765 -820
- package/dist/node_modules/@radix-ui/react-menu/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-menu/node_modules/@radix-ui/react-slot/dist/index.mjs.js +81 -73
- package/dist/node_modules/@radix-ui/react-menu/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-navigation-menu/dist/index.mjs.js +717 -730
- package/dist/node_modules/@radix-ui/react-navigation-menu/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-popover/dist/index.mjs.js +268 -199
- package/dist/node_modules/@radix-ui/react-popover/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-slot/dist/index.mjs.js +81 -73
- package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-popper/dist/index.mjs.js +267 -223
- package/dist/node_modules/@radix-ui/react-popper/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-portal/dist/index.mjs.js +14 -10
- package/dist/node_modules/@radix-ui/react-portal/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-presence/dist/index.mjs.js +122 -121
- package/dist/node_modules/@radix-ui/react-presence/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-primitive/dist/index.mjs.js +39 -83
- package/dist/node_modules/@radix-ui/react-primitive/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-primitive/node_modules/@radix-ui/react-slot/dist/index.mjs.js +81 -73
- package/dist/node_modules/@radix-ui/react-primitive/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-progress/dist/index.mjs.js +77 -78
- package/dist/node_modules/@radix-ui/react-progress/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-radio-group/dist/index.mjs.js +264 -217
- package/dist/node_modules/@radix-ui/react-radio-group/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-roving-focus/dist/index.mjs.js +204 -216
- package/dist/node_modules/@radix-ui/react-roving-focus/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-scroll-area/dist/index.mjs.js +9 -9
- package/dist/node_modules/@radix-ui/react-select/dist/index.mjs.js +1080 -1079
- package/dist/node_modules/@radix-ui/react-select/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-select/node_modules/@radix-ui/react-slot/dist/index.mjs.js +81 -73
- package/dist/node_modules/@radix-ui/react-select/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-separator/dist/index.mjs.js +26 -43
- package/dist/node_modules/@radix-ui/react-separator/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-slot/dist/index.mjs.js +1 -1
- package/dist/node_modules/@radix-ui/react-switch/dist/index.mjs.js +140 -112
- package/dist/node_modules/@radix-ui/react-switch/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-tabs/dist/index.mjs.js +173 -141
- package/dist/node_modules/@radix-ui/react-tabs/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-toggle/dist/index.mjs.js +34 -25
- package/dist/node_modules/@radix-ui/react-toggle/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-toggle-group/dist/index.mjs.js +154 -145
- package/dist/node_modules/@radix-ui/react-toggle-group/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-tooltip/dist/index.mjs.js +462 -491
- package/dist/node_modules/@radix-ui/react-tooltip/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-slot/dist/index.mjs.js +13 -78
- package/dist/node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-use-callback-ref/dist/index.mjs.js +9 -15
- package/dist/node_modules/@radix-ui/react-use-callback-ref/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-use-controllable-state/dist/index.mjs.js +66 -43
- package/dist/node_modules/@radix-ui/react-use-controllable-state/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-use-escape-keydown/dist/index.mjs.js +15 -18
- package/dist/node_modules/@radix-ui/react-use-escape-keydown/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-use-is-hydrated/dist/index.mjs.js +18 -0
- package/dist/node_modules/@radix-ui/react-use-is-hydrated/dist/index.mjs.js.map +1 -0
- package/dist/node_modules/@radix-ui/react-use-layout-effect/dist/index.mjs.js +5 -9
- package/dist/node_modules/@radix-ui/react-use-layout-effect/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-use-previous/dist/index.mjs.js +12 -18
- package/dist/node_modules/@radix-ui/react-use-previous/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-use-size/dist/index.mjs.js +37 -48
- package/dist/node_modules/@radix-ui/react-use-size/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/@radix-ui/react-visually-hidden/dist/index.mjs.js +32 -23
- package/dist/node_modules/@radix-ui/react-visually-hidden/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/aria-hidden/dist/es2015/index.js +22 -16
- package/dist/node_modules/aria-hidden/dist/es2015/index.js.map +1 -1
- package/dist/node_modules/class-variance-authority/dist/index.mjs.js +7 -9
- package/dist/node_modules/class-variance-authority/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/cmdk/dist/chunk-NZJY6EH4.mjs.js +4 -0
- package/dist/node_modules/cmdk/dist/chunk-NZJY6EH4.mjs.js.map +1 -0
- package/dist/node_modules/cmdk/dist/index.mjs.js +8 -4
- package/dist/node_modules/cmdk/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/{@radix-ui/react-scroll-area → cmdk}/node_modules/@radix-ui/react-primitive/dist/index.mjs.js +1 -1
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-primitive/dist/index.mjs.js.map +1 -0
- package/dist/node_modules/input-otp/dist/index.mjs.js +1 -1
- package/dist/node_modules/input-otp/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/react-remove-scroll/dist/es2015/SideEffect.js +23 -5
- package/dist/node_modules/react-remove-scroll/dist/es2015/SideEffect.js.map +1 -1
- package/dist/node_modules/react-remove-scroll/dist/es2015/UI.js +2 -2
- package/dist/node_modules/react-remove-scroll/dist/es2015/UI.js.map +1 -1
- package/dist/node_modules/react-remove-scroll/dist/es2015/handleScroll.js +18 -6
- package/dist/node_modules/react-remove-scroll/dist/es2015/handleScroll.js.map +1 -1
- package/dist/node_modules/react-remove-scroll-bar/dist/es2015/component.js +25 -5
- package/dist/node_modules/react-remove-scroll-bar/dist/es2015/component.js.map +1 -1
- package/dist/node_modules/sonner/dist/index.mjs.js +46 -26
- package/dist/node_modules/sonner/dist/index.mjs.js.map +1 -1
- package/dist/node_modules/use-callback-ref/dist/es2015/useMergeRef.js +27 -1
- package/dist/node_modules/use-callback-ref/dist/es2015/useMergeRef.js.map +1 -1
- package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.js +107 -0
- package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.js.map +1 -0
- package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.js +78 -0
- package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.js.map +1 -0
- package/dist/node_modules/use-sync-external-store/shim/index.js +13 -0
- package/dist/node_modules/use-sync-external-store/shim/index.js.map +1 -0
- package/dist/src/index.js +1 -1
- package/dist/src/shadcn/ui/accordion.js +7 -7
- package/dist/src/shadcn/ui/avatar.js +7 -7
- package/dist/src/shadcn/ui/checkbox.js +3 -3
- package/dist/src/shadcn/ui/command.js +15 -15
- package/dist/src/shadcn/ui/dialog.js +14 -14
- package/dist/src/shadcn/ui/dropdown-menu.js +23 -23
- package/dist/src/shadcn/ui/hover-card.js +5 -5
- package/dist/src/shadcn/ui/label.js +3 -3
- package/dist/src/shadcn/ui/navigation-menu.js +15 -15
- package/dist/src/shadcn/ui/navigation-menu.js.map +1 -1
- package/dist/src/shadcn/ui/popover.js +32 -6
- package/dist/src/shadcn/ui/popover.js.map +1 -1
- package/dist/src/shadcn/ui/progress.js +3 -3
- package/dist/src/shadcn/ui/radio-group.js +5 -5
- package/dist/src/shadcn/ui/select.js +19 -19
- package/dist/src/shadcn/ui/separator.js +3 -3
- package/dist/src/shadcn/ui/sheet.js +14 -14
- package/dist/src/shadcn/ui/switch.js +3 -3
- package/dist/src/shadcn/ui/tabs.js +8 -8
- package/dist/src/shadcn/ui/toggle-group.js +5 -5
- package/dist/src/shadcn/ui/toggle.js +3 -3
- package/dist/src/shadcn/ui/tooltip.js +7 -7
- package/dist/tailwind-manifest.js +12595 -14091
- package/dist/types/src/shadcn/ui/command.d.ts +44 -8
- package/dist/types/src/shadcn/ui/popover.d.ts +8 -4
- package/dist/types/src/shadcn/ui/sheet.d.ts +1 -1
- package/package.json +10 -31
- package/dist/node_modules/@babel/runtime/helpers/esm/extends.js +0 -12
- package/dist/node_modules/@babel/runtime/helpers/esm/extends.js.map +0 -1
- package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/number/dist/index.mjs.js +0 -7
- package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/number/dist/index.mjs.js.map +0 -1
- package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/primitive/dist/index.mjs.js +0 -12
- package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/primitive/dist/index.mjs.js.map +0 -1
- package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-compose-refs/dist/index.mjs.js +0 -40
- package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-compose-refs/dist/index.mjs.js.map +0 -1
- package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-context/dist/index.mjs.js +0 -64
- package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-context/dist/index.mjs.js.map +0 -1
- package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-direction/dist/index.mjs.js +0 -12
- package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-direction/dist/index.mjs.js.map +0 -1
- package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-presence/dist/index.mjs.js +0 -132
- package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-presence/dist/index.mjs.js.map +0 -1
- package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-primitive/dist/index.mjs.js.map +0 -1
- package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-slot/dist/index.mjs.js +0 -90
- package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +0 -1
- package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-use-callback-ref/dist/index.mjs.js +0 -13
- package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-use-callback-ref/dist/index.mjs.js.map +0 -1
- package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-use-layout-effect/dist/index.mjs.js +0 -8
- package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-use-layout-effect/dist/index.mjs.js.map +0 -1
- package/dist/node_modules/@radix-ui/react-slot/node_modules/@radix-ui/react-compose-refs/dist/index.mjs.js +0 -37
- package/dist/node_modules/@radix-ui/react-slot/node_modules/@radix-ui/react-compose-refs/dist/index.mjs.js.map +0 -1
- package/dist/node_modules/class-variance-authority/node_modules/clsx/dist/clsx.mjs.js +0 -4
- package/dist/node_modules/class-variance-authority/node_modules/clsx/dist/clsx.mjs.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/@radix-ui/primitive/dist/index.module.js +0 -9
- package/dist/node_modules/cmdk/node_modules/@radix-ui/primitive/dist/index.module.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-compose-refs/dist/index.module.js +0 -27
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-compose-refs/dist/index.module.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-context/dist/index.module.js +0 -101
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-context/dist/index.module.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-dialog/dist/index.module.js +0 -214
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-dialog/dist/index.module.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-dismissable-layer/dist/index.module.js +0 -233
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-dismissable-layer/dist/index.module.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-focus-guards/dist/index.module.js +0 -30
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-focus-guards/dist/index.module.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-focus-scope/dist/index.module.js +0 -252
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-focus-scope/dist/index.module.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-id/dist/index.module.js +0 -19
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-id/dist/index.module.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-portal/dist/index.module.js +0 -15
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-portal/dist/index.module.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-presence/dist/index.module.js +0 -131
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-presence/dist/index.module.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-primitive/dist/index.module.js +0 -85
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-primitive/dist/index.module.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-slot/dist/index.module.js +0 -79
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-slot/dist/index.module.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-use-callback-ref/dist/index.module.js +0 -19
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-use-callback-ref/dist/index.module.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-use-controllable-state/dist/index.module.js +0 -48
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-use-controllable-state/dist/index.module.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-use-escape-keydown/dist/index.module.js +0 -21
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-use-escape-keydown/dist/index.module.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-use-layout-effect/dist/index.module.js +0 -12
- package/dist/node_modules/cmdk/node_modules/@radix-ui/react-use-layout-effect/dist/index.module.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/Combination.js +0 -10
- package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/Combination.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/SideEffect.js +0 -146
- package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/SideEffect.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/UI.js +0 -39
- package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/UI.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/aggresiveCapture.js +0 -22
- package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/aggresiveCapture.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/handleScroll.js +0 -97
- package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/handleScroll.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/medium.js +0 -9
- package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/medium.js.map +0 -1
- package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/sidecar.js +0 -10
- package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/sidecar.js.map +0 -1
- package/dist/node_modules/command-score/index.js +0 -138
- package/dist/node_modules/command-score/index.js.map +0 -1
|
@@ -1,161 +1,170 @@
|
|
|
1
|
-
|
|
1
|
+
'use client';
|
|
2
2
|
import React__default from 'react';
|
|
3
|
-
import { createContextScope
|
|
4
|
-
import { Primitive
|
|
5
|
-
import { createRovingFocusGroupScope
|
|
6
|
-
import { Toggle
|
|
7
|
-
import { useControllableState
|
|
8
|
-
import { useDirection
|
|
3
|
+
import { createContextScope } from '../../react-context/dist/index.mjs.js';
|
|
4
|
+
import { Primitive } from '../../react-primitive/dist/index.mjs.js';
|
|
5
|
+
import { createRovingFocusGroupScope, Root, Item } from '../../react-roving-focus/dist/index.mjs.js';
|
|
6
|
+
import { Toggle } from '../../react-toggle/dist/index.mjs.js';
|
|
7
|
+
import { useControllableState } from '../../react-use-controllable-state/dist/index.mjs.js';
|
|
8
|
+
import { useDirection } from '../../react-direction/dist/index.mjs.js';
|
|
9
|
+
import { jsx } from 'react/jsx-runtime';
|
|
9
10
|
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
const [$6c1fd9e6a8969628$var$createToggleGroupContext, $6c1fd9e6a8969628$export$d1c7c4bcd9f26dd4] = $c512c27ab02ef895$export$50c7b4e9d9f19c1($6c1fd9e6a8969628$var$TOGGLE_GROUP_NAME, [
|
|
14
|
-
$d7bdfb9eb0fdf311$export$c7109489551a4f4
|
|
11
|
+
var TOGGLE_GROUP_NAME = "ToggleGroup";
|
|
12
|
+
var [createToggleGroupContext, createToggleGroupScope] = createContextScope(TOGGLE_GROUP_NAME, [
|
|
13
|
+
createRovingFocusGroupScope
|
|
15
14
|
]);
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
ref: forwardedRef
|
|
29
|
-
}));
|
|
30
|
-
}
|
|
31
|
-
throw new Error(`Missing prop \`type\` expected on \`${$6c1fd9e6a8969628$var$TOGGLE_GROUP_NAME}\``);
|
|
15
|
+
var useRovingFocusGroupScope = createRovingFocusGroupScope();
|
|
16
|
+
var ToggleGroup = React__default.forwardRef((props, forwardedRef) => {
|
|
17
|
+
const { type, ...toggleGroupProps } = props;
|
|
18
|
+
if (type === "single") {
|
|
19
|
+
const singleProps = toggleGroupProps;
|
|
20
|
+
return /* @__PURE__ */ jsx(ToggleGroupImplSingle, { ...singleProps, ref: forwardedRef });
|
|
21
|
+
}
|
|
22
|
+
if (type === "multiple") {
|
|
23
|
+
const multipleProps = toggleGroupProps;
|
|
24
|
+
return /* @__PURE__ */ jsx(ToggleGroupImplMultiple, { ...multipleProps, ref: forwardedRef });
|
|
25
|
+
}
|
|
26
|
+
throw new Error(`Missing prop \`type\` expected on \`${TOGGLE_GROUP_NAME}\``);
|
|
32
27
|
});
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
28
|
+
ToggleGroup.displayName = TOGGLE_GROUP_NAME;
|
|
29
|
+
var [ToggleGroupValueProvider, useToggleGroupValueContext] = createToggleGroupContext(TOGGLE_GROUP_NAME);
|
|
30
|
+
var ToggleGroupImplSingle = React__default.forwardRef((props, forwardedRef) => {
|
|
31
|
+
const {
|
|
32
|
+
value: valueProp,
|
|
33
|
+
defaultValue,
|
|
34
|
+
onValueChange = () => {
|
|
35
|
+
},
|
|
36
|
+
...toggleGroupSingleProps
|
|
37
|
+
} = props;
|
|
38
|
+
const [value, setValue] = useControllableState({
|
|
39
|
+
prop: valueProp,
|
|
40
|
+
defaultProp: defaultValue ?? "",
|
|
41
|
+
onChange: onValueChange,
|
|
42
|
+
caller: TOGGLE_GROUP_NAME
|
|
43
|
+
});
|
|
44
|
+
return /* @__PURE__ */ jsx(
|
|
45
|
+
ToggleGroupValueProvider,
|
|
46
|
+
{
|
|
47
|
+
scope: props.__scopeToggleGroup,
|
|
48
|
+
type: "single",
|
|
49
|
+
value: React__default.useMemo(() => value ? [value] : [], [value]),
|
|
50
|
+
onItemActivate: setValue,
|
|
51
|
+
onItemDeactivate: React__default.useCallback(() => setValue(""), [setValue]),
|
|
52
|
+
children: /* @__PURE__ */ jsx(ToggleGroupImpl, { ...toggleGroupSingleProps, ref: forwardedRef })
|
|
53
|
+
}
|
|
54
|
+
);
|
|
55
55
|
});
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
]
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
56
|
+
var ToggleGroupImplMultiple = React__default.forwardRef((props, forwardedRef) => {
|
|
57
|
+
const {
|
|
58
|
+
value: valueProp,
|
|
59
|
+
defaultValue,
|
|
60
|
+
onValueChange = () => {
|
|
61
|
+
},
|
|
62
|
+
...toggleGroupMultipleProps
|
|
63
|
+
} = props;
|
|
64
|
+
const [value, setValue] = useControllableState({
|
|
65
|
+
prop: valueProp,
|
|
66
|
+
defaultProp: defaultValue ?? [],
|
|
67
|
+
onChange: onValueChange,
|
|
68
|
+
caller: TOGGLE_GROUP_NAME
|
|
69
|
+
});
|
|
70
|
+
const handleButtonActivate = React__default.useCallback(
|
|
71
|
+
(itemValue) => setValue((prevValue = []) => [...prevValue, itemValue]),
|
|
72
|
+
[setValue]
|
|
73
|
+
);
|
|
74
|
+
const handleButtonDeactivate = React__default.useCallback(
|
|
75
|
+
(itemValue) => setValue((prevValue = []) => prevValue.filter((value2) => value2 !== itemValue)),
|
|
76
|
+
[setValue]
|
|
77
|
+
);
|
|
78
|
+
return /* @__PURE__ */ jsx(
|
|
79
|
+
ToggleGroupValueProvider,
|
|
80
|
+
{
|
|
81
|
+
scope: props.__scopeToggleGroup,
|
|
82
|
+
type: "multiple",
|
|
83
|
+
value,
|
|
84
|
+
onItemActivate: handleButtonActivate,
|
|
85
|
+
onItemDeactivate: handleButtonDeactivate,
|
|
86
|
+
children: /* @__PURE__ */ jsx(ToggleGroupImpl, { ...toggleGroupMultipleProps, ref: forwardedRef })
|
|
87
|
+
}
|
|
88
|
+
);
|
|
86
89
|
});
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
const
|
|
92
|
-
|
|
93
|
-
|
|
90
|
+
ToggleGroup.displayName = TOGGLE_GROUP_NAME;
|
|
91
|
+
var [ToggleGroupContext, useToggleGroupContext] = createToggleGroupContext(TOGGLE_GROUP_NAME);
|
|
92
|
+
var ToggleGroupImpl = React__default.forwardRef(
|
|
93
|
+
(props, forwardedRef) => {
|
|
94
|
+
const {
|
|
95
|
+
__scopeToggleGroup,
|
|
96
|
+
disabled = false,
|
|
97
|
+
rovingFocus = true,
|
|
98
|
+
orientation,
|
|
99
|
+
dir,
|
|
100
|
+
loop = true,
|
|
101
|
+
...toggleGroupProps
|
|
102
|
+
} = props;
|
|
103
|
+
const rovingFocusGroupScope = useRovingFocusGroupScope(__scopeToggleGroup);
|
|
104
|
+
const direction = useDirection(dir);
|
|
105
|
+
const commonProps = { role: "group", dir: direction, ...toggleGroupProps };
|
|
106
|
+
return /* @__PURE__ */ jsx(ToggleGroupContext, { scope: __scopeToggleGroup, rovingFocus, disabled, children: rovingFocus ? /* @__PURE__ */ jsx(
|
|
107
|
+
Root,
|
|
108
|
+
{
|
|
109
|
+
asChild: true,
|
|
110
|
+
...rovingFocusGroupScope,
|
|
111
|
+
orientation,
|
|
94
112
|
dir: direction,
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
}), /*#__PURE__*/ React__default.createElement($8927f6f2acc4f386$export$250ffa63cdc0d034.div, _extends({}, commonProps, {
|
|
108
|
-
ref: forwardedRef
|
|
109
|
-
}))) : /*#__PURE__*/ React__default.createElement($8927f6f2acc4f386$export$250ffa63cdc0d034.div, _extends({}, commonProps, {
|
|
110
|
-
ref: forwardedRef
|
|
111
|
-
})));
|
|
112
|
-
});
|
|
113
|
-
/* -------------------------------------------------------------------------------------------------
|
|
114
|
-
* ToggleGroupItem
|
|
115
|
-
* -----------------------------------------------------------------------------------------------*/ const $6c1fd9e6a8969628$var$ITEM_NAME = 'ToggleGroupItem';
|
|
116
|
-
const $6c1fd9e6a8969628$export$b453109e13abe10b = /*#__PURE__*/ React__default.forwardRef((props, forwardedRef)=>{
|
|
117
|
-
const valueContext = $6c1fd9e6a8969628$var$useToggleGroupValueContext($6c1fd9e6a8969628$var$ITEM_NAME, props.__scopeToggleGroup);
|
|
118
|
-
const context = $6c1fd9e6a8969628$var$useToggleGroupContext($6c1fd9e6a8969628$var$ITEM_NAME, props.__scopeToggleGroup);
|
|
119
|
-
const rovingFocusGroupScope = $6c1fd9e6a8969628$var$useRovingFocusGroupScope(props.__scopeToggleGroup);
|
|
113
|
+
loop,
|
|
114
|
+
children: /* @__PURE__ */ jsx(Primitive.div, { ...commonProps, ref: forwardedRef })
|
|
115
|
+
}
|
|
116
|
+
) : /* @__PURE__ */ jsx(Primitive.div, { ...commonProps, ref: forwardedRef }) });
|
|
117
|
+
}
|
|
118
|
+
);
|
|
119
|
+
var ITEM_NAME = "ToggleGroupItem";
|
|
120
|
+
var ToggleGroupItem = React__default.forwardRef(
|
|
121
|
+
(props, forwardedRef) => {
|
|
122
|
+
const valueContext = useToggleGroupValueContext(ITEM_NAME, props.__scopeToggleGroup);
|
|
123
|
+
const context = useToggleGroupContext(ITEM_NAME, props.__scopeToggleGroup);
|
|
124
|
+
const rovingFocusGroupScope = useRovingFocusGroupScope(props.__scopeToggleGroup);
|
|
120
125
|
const pressed = valueContext.value.includes(props.value);
|
|
121
126
|
const disabled = context.disabled || props.disabled;
|
|
122
|
-
const commonProps = {
|
|
123
|
-
...props,
|
|
124
|
-
pressed: pressed,
|
|
125
|
-
disabled: disabled
|
|
126
|
-
};
|
|
127
|
+
const commonProps = { ...props, pressed, disabled };
|
|
127
128
|
const ref = React__default.useRef(null);
|
|
128
|
-
return context.rovingFocus ?
|
|
129
|
-
|
|
130
|
-
|
|
129
|
+
return context.rovingFocus ? /* @__PURE__ */ jsx(
|
|
130
|
+
Item,
|
|
131
|
+
{
|
|
132
|
+
asChild: true,
|
|
133
|
+
...rovingFocusGroupScope,
|
|
131
134
|
focusable: !disabled,
|
|
132
135
|
active: pressed,
|
|
133
|
-
ref
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
const
|
|
143
|
-
const
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
136
|
+
ref,
|
|
137
|
+
children: /* @__PURE__ */ jsx(ToggleGroupItemImpl, { ...commonProps, ref: forwardedRef })
|
|
138
|
+
}
|
|
139
|
+
) : /* @__PURE__ */ jsx(ToggleGroupItemImpl, { ...commonProps, ref: forwardedRef });
|
|
140
|
+
}
|
|
141
|
+
);
|
|
142
|
+
ToggleGroupItem.displayName = ITEM_NAME;
|
|
143
|
+
var ToggleGroupItemImpl = React__default.forwardRef(
|
|
144
|
+
(props, forwardedRef) => {
|
|
145
|
+
const { __scopeToggleGroup, value, ...itemProps } = props;
|
|
146
|
+
const valueContext = useToggleGroupValueContext(ITEM_NAME, __scopeToggleGroup);
|
|
147
|
+
const singleProps = { role: "radio", "aria-checked": props.pressed, "aria-pressed": void 0 };
|
|
148
|
+
const typeProps = valueContext.type === "single" ? singleProps : void 0;
|
|
149
|
+
return /* @__PURE__ */ jsx(
|
|
150
|
+
Toggle,
|
|
151
|
+
{
|
|
152
|
+
...typeProps,
|
|
153
|
+
...itemProps,
|
|
150
154
|
ref: forwardedRef,
|
|
151
|
-
onPressedChange: (pressed)=>{
|
|
152
|
-
|
|
153
|
-
|
|
155
|
+
onPressedChange: (pressed) => {
|
|
156
|
+
if (pressed) {
|
|
157
|
+
valueContext.onItemActivate(value);
|
|
158
|
+
} else {
|
|
159
|
+
valueContext.onItemDeactivate(value);
|
|
160
|
+
}
|
|
154
161
|
}
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
162
|
+
}
|
|
163
|
+
);
|
|
164
|
+
}
|
|
165
|
+
);
|
|
166
|
+
var Root2 = ToggleGroup;
|
|
167
|
+
var Item2 = ToggleGroupItem;
|
|
159
168
|
|
|
160
|
-
export {
|
|
169
|
+
export { Item2 as Item, Root2 as Root, ToggleGroup, ToggleGroupItem, createToggleGroupScope };
|
|
161
170
|
//# sourceMappingURL=index.mjs.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs.js","sources":["../../../../../node_modules/@radix-ui/react-toggle-group/dist/index.mjs"],"sourcesContent":["import $jFibJ$babelruntimehelpersesmextends from \"@babel/runtime/helpers/esm/extends\";\nimport $jFibJ$react from \"react\";\nimport {createContextScope as $jFibJ$createContextScope} from \"@radix-ui/react-context\";\nimport {Primitive as $jFibJ$Primitive} from \"@radix-ui/react-primitive\";\nimport {createRovingFocusGroupScope as $jFibJ$createRovingFocusGroupScope, Root as $jFibJ$Root, Item as $jFibJ$Item} from \"@radix-ui/react-roving-focus\";\nimport {Toggle as $jFibJ$Toggle} from \"@radix-ui/react-toggle\";\nimport {useControllableState as $jFibJ$useControllableState} from \"@radix-ui/react-use-controllable-state\";\nimport {useDirection as $jFibJ$useDirection} from \"@radix-ui/react-direction\";\n\n\n\n\n\n\n\n\n\n\n/* -------------------------------------------------------------------------------------------------\n * ToggleGroup\n * -----------------------------------------------------------------------------------------------*/ const $6c1fd9e6a8969628$var$TOGGLE_GROUP_NAME = 'ToggleGroup';\nconst [$6c1fd9e6a8969628$var$createToggleGroupContext, $6c1fd9e6a8969628$export$d1c7c4bcd9f26dd4] = $jFibJ$createContextScope($6c1fd9e6a8969628$var$TOGGLE_GROUP_NAME, [\n $jFibJ$createRovingFocusGroupScope\n]);\nconst $6c1fd9e6a8969628$var$useRovingFocusGroupScope = $jFibJ$createRovingFocusGroupScope();\nconst $6c1fd9e6a8969628$export$af3ec21f6cfb5e30 = /*#__PURE__*/ $jFibJ$react.forwardRef((props, forwardedRef)=>{\n const { type: type , ...toggleGroupProps } = props;\n if (type === 'single') {\n const singleProps = toggleGroupProps;\n return /*#__PURE__*/ $jFibJ$react.createElement($6c1fd9e6a8969628$var$ToggleGroupImplSingle, $jFibJ$babelruntimehelpersesmextends({}, singleProps, {\n ref: forwardedRef\n }));\n }\n if (type === 'multiple') {\n const multipleProps = toggleGroupProps;\n return /*#__PURE__*/ $jFibJ$react.createElement($6c1fd9e6a8969628$var$ToggleGroupImplMultiple, $jFibJ$babelruntimehelpersesmextends({}, multipleProps, {\n ref: forwardedRef\n }));\n }\n throw new Error(`Missing prop \\`type\\` expected on \\`${$6c1fd9e6a8969628$var$TOGGLE_GROUP_NAME}\\``);\n});\n/*#__PURE__*/ Object.assign($6c1fd9e6a8969628$export$af3ec21f6cfb5e30, {\n displayName: $6c1fd9e6a8969628$var$TOGGLE_GROUP_NAME\n});\n/* -----------------------------------------------------------------------------------------------*/ const [$6c1fd9e6a8969628$var$ToggleGroupValueProvider, $6c1fd9e6a8969628$var$useToggleGroupValueContext] = $6c1fd9e6a8969628$var$createToggleGroupContext($6c1fd9e6a8969628$var$TOGGLE_GROUP_NAME);\nconst $6c1fd9e6a8969628$var$ToggleGroupImplSingle = /*#__PURE__*/ $jFibJ$react.forwardRef((props, forwardedRef)=>{\n const { value: valueProp , defaultValue: defaultValue , onValueChange: onValueChange = ()=>{} , ...toggleGroupSingleProps } = props;\n const [value, setValue] = $jFibJ$useControllableState({\n prop: valueProp,\n defaultProp: defaultValue,\n onChange: onValueChange\n });\n return /*#__PURE__*/ $jFibJ$react.createElement($6c1fd9e6a8969628$var$ToggleGroupValueProvider, {\n scope: props.__scopeToggleGroup,\n type: \"single\",\n value: value ? [\n value\n ] : [],\n onItemActivate: setValue,\n onItemDeactivate: $jFibJ$react.useCallback(()=>setValue('')\n , [\n setValue\n ])\n }, /*#__PURE__*/ $jFibJ$react.createElement($6c1fd9e6a8969628$var$ToggleGroupImpl, $jFibJ$babelruntimehelpersesmextends({}, toggleGroupSingleProps, {\n ref: forwardedRef\n })));\n});\nconst $6c1fd9e6a8969628$var$ToggleGroupImplMultiple = /*#__PURE__*/ $jFibJ$react.forwardRef((props, forwardedRef)=>{\n const { value: valueProp , defaultValue: defaultValue , onValueChange: onValueChange = ()=>{} , ...toggleGroupMultipleProps } = props;\n const [value1 = [], setValue] = $jFibJ$useControllableState({\n prop: valueProp,\n defaultProp: defaultValue,\n onChange: onValueChange\n });\n const handleButtonActivate = $jFibJ$react.useCallback((itemValue)=>setValue((prevValue = [])=>[\n ...prevValue,\n itemValue\n ]\n )\n , [\n setValue\n ]);\n const handleButtonDeactivate = $jFibJ$react.useCallback((itemValue)=>setValue((prevValue = [])=>prevValue.filter((value)=>value !== itemValue\n )\n )\n , [\n setValue\n ]);\n return /*#__PURE__*/ $jFibJ$react.createElement($6c1fd9e6a8969628$var$ToggleGroupValueProvider, {\n scope: props.__scopeToggleGroup,\n type: \"multiple\",\n value: value1,\n onItemActivate: handleButtonActivate,\n onItemDeactivate: handleButtonDeactivate\n }, /*#__PURE__*/ $jFibJ$react.createElement($6c1fd9e6a8969628$var$ToggleGroupImpl, $jFibJ$babelruntimehelpersesmextends({}, toggleGroupMultipleProps, {\n ref: forwardedRef\n })));\n});\n/*#__PURE__*/ Object.assign($6c1fd9e6a8969628$export$af3ec21f6cfb5e30, {\n displayName: $6c1fd9e6a8969628$var$TOGGLE_GROUP_NAME\n});\n/* -----------------------------------------------------------------------------------------------*/ const [$6c1fd9e6a8969628$var$ToggleGroupContext, $6c1fd9e6a8969628$var$useToggleGroupContext] = $6c1fd9e6a8969628$var$createToggleGroupContext($6c1fd9e6a8969628$var$TOGGLE_GROUP_NAME);\nconst $6c1fd9e6a8969628$var$ToggleGroupImpl = /*#__PURE__*/ $jFibJ$react.forwardRef((props, forwardedRef)=>{\n const { __scopeToggleGroup: __scopeToggleGroup , disabled: disabled = false , rovingFocus: rovingFocus = true , orientation: orientation , dir: dir , loop: loop = true , ...toggleGroupProps } = props;\n const rovingFocusGroupScope = $6c1fd9e6a8969628$var$useRovingFocusGroupScope(__scopeToggleGroup);\n const direction = $jFibJ$useDirection(dir);\n const commonProps = {\n role: 'group',\n dir: direction,\n ...toggleGroupProps\n };\n return /*#__PURE__*/ $jFibJ$react.createElement($6c1fd9e6a8969628$var$ToggleGroupContext, {\n scope: __scopeToggleGroup,\n rovingFocus: rovingFocus,\n disabled: disabled\n }, rovingFocus ? /*#__PURE__*/ $jFibJ$react.createElement($jFibJ$Root, $jFibJ$babelruntimehelpersesmextends({\n asChild: true\n }, rovingFocusGroupScope, {\n orientation: orientation,\n dir: direction,\n loop: loop\n }), /*#__PURE__*/ $jFibJ$react.createElement($jFibJ$Primitive.div, $jFibJ$babelruntimehelpersesmextends({}, commonProps, {\n ref: forwardedRef\n }))) : /*#__PURE__*/ $jFibJ$react.createElement($jFibJ$Primitive.div, $jFibJ$babelruntimehelpersesmextends({}, commonProps, {\n ref: forwardedRef\n })));\n});\n/* -------------------------------------------------------------------------------------------------\n * ToggleGroupItem\n * -----------------------------------------------------------------------------------------------*/ const $6c1fd9e6a8969628$var$ITEM_NAME = 'ToggleGroupItem';\nconst $6c1fd9e6a8969628$export$b453109e13abe10b = /*#__PURE__*/ $jFibJ$react.forwardRef((props, forwardedRef)=>{\n const valueContext = $6c1fd9e6a8969628$var$useToggleGroupValueContext($6c1fd9e6a8969628$var$ITEM_NAME, props.__scopeToggleGroup);\n const context = $6c1fd9e6a8969628$var$useToggleGroupContext($6c1fd9e6a8969628$var$ITEM_NAME, props.__scopeToggleGroup);\n const rovingFocusGroupScope = $6c1fd9e6a8969628$var$useRovingFocusGroupScope(props.__scopeToggleGroup);\n const pressed = valueContext.value.includes(props.value);\n const disabled = context.disabled || props.disabled;\n const commonProps = {\n ...props,\n pressed: pressed,\n disabled: disabled\n };\n const ref = $jFibJ$react.useRef(null);\n return context.rovingFocus ? /*#__PURE__*/ $jFibJ$react.createElement($jFibJ$Item, $jFibJ$babelruntimehelpersesmextends({\n asChild: true\n }, rovingFocusGroupScope, {\n focusable: !disabled,\n active: pressed,\n ref: ref\n }), /*#__PURE__*/ $jFibJ$react.createElement($6c1fd9e6a8969628$var$ToggleGroupItemImpl, $jFibJ$babelruntimehelpersesmextends({}, commonProps, {\n ref: forwardedRef\n }))) : /*#__PURE__*/ $jFibJ$react.createElement($6c1fd9e6a8969628$var$ToggleGroupItemImpl, $jFibJ$babelruntimehelpersesmextends({}, commonProps, {\n ref: forwardedRef\n }));\n});\n/*#__PURE__*/ Object.assign($6c1fd9e6a8969628$export$b453109e13abe10b, {\n displayName: $6c1fd9e6a8969628$var$ITEM_NAME\n});\n/* -----------------------------------------------------------------------------------------------*/ const $6c1fd9e6a8969628$var$ToggleGroupItemImpl = /*#__PURE__*/ $jFibJ$react.forwardRef((props, forwardedRef)=>{\n const { __scopeToggleGroup: __scopeToggleGroup , value: value , ...itemProps } = props;\n const valueContext = $6c1fd9e6a8969628$var$useToggleGroupValueContext($6c1fd9e6a8969628$var$ITEM_NAME, __scopeToggleGroup);\n const singleProps = {\n role: 'radio',\n 'aria-checked': props.pressed,\n 'aria-pressed': undefined\n };\n const typeProps = valueContext.type === 'single' ? singleProps : undefined;\n return /*#__PURE__*/ $jFibJ$react.createElement($jFibJ$Toggle, $jFibJ$babelruntimehelpersesmextends({}, typeProps, itemProps, {\n ref: forwardedRef,\n onPressedChange: (pressed)=>{\n if (pressed) valueContext.onItemActivate(value);\n else valueContext.onItemDeactivate(value);\n }\n }));\n});\n/* -----------------------------------------------------------------------------------------------*/ const $6c1fd9e6a8969628$export$be92b6f5f03c0fe9 = $6c1fd9e6a8969628$export$af3ec21f6cfb5e30;\nconst $6c1fd9e6a8969628$export$6d08773d2e66f8f2 = $6c1fd9e6a8969628$export$b453109e13abe10b;\n\n\n\n\nexport {$6c1fd9e6a8969628$export$d1c7c4bcd9f26dd4 as createToggleGroupScope, $6c1fd9e6a8969628$export$af3ec21f6cfb5e30 as ToggleGroup, $6c1fd9e6a8969628$export$b453109e13abe10b as ToggleGroupItem, $6c1fd9e6a8969628$export$be92b6f5f03c0fe9 as Root, $6c1fd9e6a8969628$export$6d08773d2e66f8f2 as Item};\n//# sourceMappingURL=index.mjs.map\n"],"names":["$jFibJ$createContextScope","$jFibJ$createRovingFocusGroupScope","$jFibJ$react","$jFibJ$babelruntimehelpersesmextends","$jFibJ$useControllableState","$jFibJ$useDirection","$jFibJ$Root","$jFibJ$Primitive","$jFibJ$Item","$jFibJ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yC,GAAG;;;;"}
|
|
1
|
+
{"version":3,"file":"index.mjs.js","sources":["../../../../../node_modules/@radix-ui/react-toggle-group/dist/index.mjs"],"sourcesContent":["\"use client\";\n\n// src/toggle-group.tsx\nimport React from \"react\";\nimport { createContextScope } from \"@radix-ui/react-context\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport * as RovingFocusGroup from \"@radix-ui/react-roving-focus\";\nimport { createRovingFocusGroupScope } from \"@radix-ui/react-roving-focus\";\nimport { Toggle } from \"@radix-ui/react-toggle\";\nimport { useControllableState } from \"@radix-ui/react-use-controllable-state\";\nimport { useDirection } from \"@radix-ui/react-direction\";\nimport { jsx } from \"react/jsx-runtime\";\nvar TOGGLE_GROUP_NAME = \"ToggleGroup\";\nvar [createToggleGroupContext, createToggleGroupScope] = createContextScope(TOGGLE_GROUP_NAME, [\n createRovingFocusGroupScope\n]);\nvar useRovingFocusGroupScope = createRovingFocusGroupScope();\nvar ToggleGroup = React.forwardRef((props, forwardedRef) => {\n const { type, ...toggleGroupProps } = props;\n if (type === \"single\") {\n const singleProps = toggleGroupProps;\n return /* @__PURE__ */ jsx(ToggleGroupImplSingle, { ...singleProps, ref: forwardedRef });\n }\n if (type === \"multiple\") {\n const multipleProps = toggleGroupProps;\n return /* @__PURE__ */ jsx(ToggleGroupImplMultiple, { ...multipleProps, ref: forwardedRef });\n }\n throw new Error(`Missing prop \\`type\\` expected on \\`${TOGGLE_GROUP_NAME}\\``);\n});\nToggleGroup.displayName = TOGGLE_GROUP_NAME;\nvar [ToggleGroupValueProvider, useToggleGroupValueContext] = createToggleGroupContext(TOGGLE_GROUP_NAME);\nvar ToggleGroupImplSingle = React.forwardRef((props, forwardedRef) => {\n const {\n value: valueProp,\n defaultValue,\n onValueChange = () => {\n },\n ...toggleGroupSingleProps\n } = props;\n const [value, setValue] = useControllableState({\n prop: valueProp,\n defaultProp: defaultValue ?? \"\",\n onChange: onValueChange,\n caller: TOGGLE_GROUP_NAME\n });\n return /* @__PURE__ */ jsx(\n ToggleGroupValueProvider,\n {\n scope: props.__scopeToggleGroup,\n type: \"single\",\n value: React.useMemo(() => value ? [value] : [], [value]),\n onItemActivate: setValue,\n onItemDeactivate: React.useCallback(() => setValue(\"\"), [setValue]),\n children: /* @__PURE__ */ jsx(ToggleGroupImpl, { ...toggleGroupSingleProps, ref: forwardedRef })\n }\n );\n});\nvar ToggleGroupImplMultiple = React.forwardRef((props, forwardedRef) => {\n const {\n value: valueProp,\n defaultValue,\n onValueChange = () => {\n },\n ...toggleGroupMultipleProps\n } = props;\n const [value, setValue] = useControllableState({\n prop: valueProp,\n defaultProp: defaultValue ?? [],\n onChange: onValueChange,\n caller: TOGGLE_GROUP_NAME\n });\n const handleButtonActivate = React.useCallback(\n (itemValue) => setValue((prevValue = []) => [...prevValue, itemValue]),\n [setValue]\n );\n const handleButtonDeactivate = React.useCallback(\n (itemValue) => setValue((prevValue = []) => prevValue.filter((value2) => value2 !== itemValue)),\n [setValue]\n );\n return /* @__PURE__ */ jsx(\n ToggleGroupValueProvider,\n {\n scope: props.__scopeToggleGroup,\n type: \"multiple\",\n value,\n onItemActivate: handleButtonActivate,\n onItemDeactivate: handleButtonDeactivate,\n children: /* @__PURE__ */ jsx(ToggleGroupImpl, { ...toggleGroupMultipleProps, ref: forwardedRef })\n }\n );\n});\nToggleGroup.displayName = TOGGLE_GROUP_NAME;\nvar [ToggleGroupContext, useToggleGroupContext] = createToggleGroupContext(TOGGLE_GROUP_NAME);\nvar ToggleGroupImpl = React.forwardRef(\n (props, forwardedRef) => {\n const {\n __scopeToggleGroup,\n disabled = false,\n rovingFocus = true,\n orientation,\n dir,\n loop = true,\n ...toggleGroupProps\n } = props;\n const rovingFocusGroupScope = useRovingFocusGroupScope(__scopeToggleGroup);\n const direction = useDirection(dir);\n const commonProps = { role: \"group\", dir: direction, ...toggleGroupProps };\n return /* @__PURE__ */ jsx(ToggleGroupContext, { scope: __scopeToggleGroup, rovingFocus, disabled, children: rovingFocus ? /* @__PURE__ */ jsx(\n RovingFocusGroup.Root,\n {\n asChild: true,\n ...rovingFocusGroupScope,\n orientation,\n dir: direction,\n loop,\n children: /* @__PURE__ */ jsx(Primitive.div, { ...commonProps, ref: forwardedRef })\n }\n ) : /* @__PURE__ */ jsx(Primitive.div, { ...commonProps, ref: forwardedRef }) });\n }\n);\nvar ITEM_NAME = \"ToggleGroupItem\";\nvar ToggleGroupItem = React.forwardRef(\n (props, forwardedRef) => {\n const valueContext = useToggleGroupValueContext(ITEM_NAME, props.__scopeToggleGroup);\n const context = useToggleGroupContext(ITEM_NAME, props.__scopeToggleGroup);\n const rovingFocusGroupScope = useRovingFocusGroupScope(props.__scopeToggleGroup);\n const pressed = valueContext.value.includes(props.value);\n const disabled = context.disabled || props.disabled;\n const commonProps = { ...props, pressed, disabled };\n const ref = React.useRef(null);\n return context.rovingFocus ? /* @__PURE__ */ jsx(\n RovingFocusGroup.Item,\n {\n asChild: true,\n ...rovingFocusGroupScope,\n focusable: !disabled,\n active: pressed,\n ref,\n children: /* @__PURE__ */ jsx(ToggleGroupItemImpl, { ...commonProps, ref: forwardedRef })\n }\n ) : /* @__PURE__ */ jsx(ToggleGroupItemImpl, { ...commonProps, ref: forwardedRef });\n }\n);\nToggleGroupItem.displayName = ITEM_NAME;\nvar ToggleGroupItemImpl = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeToggleGroup, value, ...itemProps } = props;\n const valueContext = useToggleGroupValueContext(ITEM_NAME, __scopeToggleGroup);\n const singleProps = { role: \"radio\", \"aria-checked\": props.pressed, \"aria-pressed\": void 0 };\n const typeProps = valueContext.type === \"single\" ? singleProps : void 0;\n return /* @__PURE__ */ jsx(\n Toggle,\n {\n ...typeProps,\n ...itemProps,\n ref: forwardedRef,\n onPressedChange: (pressed) => {\n if (pressed) {\n valueContext.onItemActivate(value);\n } else {\n valueContext.onItemDeactivate(value);\n }\n }\n }\n );\n }\n);\nvar Root2 = ToggleGroup;\nvar Item2 = ToggleGroupItem;\nexport {\n Item2 as Item,\n Root2 as Root,\n ToggleGroup,\n ToggleGroupItem,\n createToggleGroupScope\n};\n//# sourceMappingURL=index.mjs.map\n"],"names":[],"mappings":";;;;;;;;;;AAYA;AACG;AACH;AACA;AACA;AACG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACG;AACA;;"}
|