@pixpilot/shadcn-ui 0.1.0 → 0.4.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/AbsoluteFill.cjs +24 -1
- package/dist/AbsoluteFill.d.ts +2 -2
- package/dist/AbsoluteFill.js +21 -1
- package/dist/Alert.cjs +81 -1
- package/dist/Alert.js +77 -1
- package/dist/Button.cjs +84 -1
- package/dist/Button.js +79 -1
- package/dist/CloseButtonAbsolute.cjs +20 -1
- package/dist/CloseButtonAbsolute.js +16 -1
- package/dist/CloseButtonRounded.cjs +22 -1
- package/dist/CloseButtonRounded.js +17 -1
- package/dist/Combobox.cjs +53 -1
- package/dist/Combobox.js +48 -1
- package/dist/CommandOptionList.cjs +29 -1
- package/dist/CommandOptionList.js +25 -1
- package/dist/ContentCard.cjs +27 -1
- package/dist/ContentCard.js +23 -1
- package/dist/DatePicker.cjs +38 -1
- package/dist/DatePicker.d.ts +2 -2
- package/dist/DatePicker.js +33 -1
- package/dist/LoadingOverlay.cjs +65 -1
- package/dist/LoadingOverlay.js +60 -1
- package/dist/Select.cjs +27 -1
- package/dist/Select.d.cts +2 -2
- package/dist/Select.d.ts +2 -2
- package/dist/Select.js +23 -1
- package/dist/Slider.cjs +19 -1
- package/dist/Slider.js +15 -1
- package/dist/ThemeToggle.cjs +98 -1
- package/dist/ThemeToggle.d.cts +2 -2
- package/dist/ThemeToggle.d.ts +2 -2
- package/dist/ThemeToggle.js +94 -1
- package/dist/_virtual/rolldown_runtime.cjs +44 -1
- package/dist/_virtual/rolldown_runtime.js +43 -0
- package/dist/confirmation-dialog/ConfirmationDialog.cjs +47 -1
- package/dist/confirmation-dialog/ConfirmationDialog.d.cts +1 -0
- package/dist/confirmation-dialog/ConfirmationDialog.js +43 -1
- package/dist/confirmation-dialog/DialogProvider.cjs +16 -1
- package/dist/confirmation-dialog/DialogProvider.js +12 -1
- package/dist/confirmation-dialog/confirmation-dialogs.cjs +14 -1
- package/dist/confirmation-dialog/confirmation-dialogs.js +12 -1
- package/dist/confirmation-dialog/index.cjs +7 -1
- package/dist/confirmation-dialog/index.js +6 -1
- package/dist/file-upload/FileUpload.cjs +68 -0
- package/dist/file-upload/FileUpload.d.cts +7 -0
- package/dist/file-upload/FileUpload.d.ts +7 -0
- package/dist/file-upload/FileUpload.js +63 -0
- package/dist/file-upload/FileUploadItems.cjs +36 -0
- package/dist/file-upload/FileUploadItems.js +32 -0
- package/dist/file-upload/FileUploadListItem.cjs +89 -0
- package/dist/file-upload/FileUploadListItem.js +83 -0
- package/dist/file-upload/hooks/index.cjs +4 -0
- package/dist/file-upload/hooks/index.d.cts +2 -0
- package/dist/file-upload/hooks/index.d.ts +2 -0
- package/dist/file-upload/hooks/index.js +3 -0
- package/dist/file-upload/hooks/use-file-error.cjs +15 -0
- package/dist/file-upload/hooks/use-file-error.js +14 -0
- package/dist/file-upload/hooks/use-file-upload-progress-callbacks.cjs +34 -0
- package/dist/file-upload/hooks/use-file-upload-progress-callbacks.d.cts +1 -0
- package/dist/file-upload/hooks/use-file-upload-progress-callbacks.d.ts +1 -0
- package/dist/file-upload/hooks/use-file-upload-progress-callbacks.js +32 -0
- package/dist/file-upload/hooks/use-file-upload-store.cjs +77 -0
- package/dist/file-upload/hooks/use-file-upload-store.d.cts +2 -0
- package/dist/file-upload/hooks/use-file-upload-store.d.ts +2 -0
- package/dist/file-upload/hooks/use-file-upload-store.js +75 -0
- package/dist/file-upload/index.cjs +6 -0
- package/dist/file-upload/index.d.cts +3 -0
- package/dist/file-upload/index.d.ts +3 -0
- package/dist/file-upload/index.js +5 -0
- package/dist/file-upload/types/index.d.cts +40 -0
- package/dist/file-upload/types/index.d.ts +40 -0
- package/dist/file-upload/utils/create-placeholder-file.cjs +12 -0
- package/dist/file-upload/utils/create-placeholder-file.js +10 -0
- package/dist/file-upload/utils/get-file-key.cjs +9 -0
- package/dist/file-upload/utils/get-file-key.d.cts +1 -0
- package/dist/file-upload/utils/get-file-key.d.ts +1 -0
- package/dist/file-upload/utils/get-file-key.js +7 -0
- package/dist/file-upload/utils/get-file-meta.cjs +24 -0
- package/dist/file-upload/utils/get-file-meta.d.cts +1 -0
- package/dist/file-upload/utils/get-file-meta.d.ts +1 -0
- package/dist/file-upload/utils/get-file-meta.js +21 -0
- package/dist/file-upload/utils/index.d.cts +4 -0
- package/dist/file-upload/utils/index.d.ts +4 -0
- package/dist/file-upload/utils/is-file-equal.cjs +10 -0
- package/dist/file-upload/utils/is-file-equal.d.cts +1 -0
- package/dist/file-upload/utils/is-file-equal.d.ts +1 -0
- package/dist/file-upload/utils/is-file-equal.js +8 -0
- package/dist/file-upload/utils/merge-file-metadata.cjs +27 -0
- package/dist/file-upload/utils/merge-file-metadata.d.cts +1 -0
- package/dist/file-upload/utils/merge-file-metadata.d.ts +1 -0
- package/dist/file-upload/utils/merge-file-metadata.js +26 -0
- package/dist/file-upload-inline/FileUploadInline.cjs +71 -0
- package/dist/file-upload-inline/FileUploadInline.d.cts +10 -0
- package/dist/file-upload-inline/FileUploadInline.d.ts +10 -0
- package/dist/file-upload-inline/FileUploadInline.js +66 -0
- package/dist/file-upload-inline/FileUploadInlineItem.cjs +96 -0
- package/dist/file-upload-inline/FileUploadInlineItem.js +90 -0
- package/dist/file-upload-inline/defaults.cjs +12 -0
- package/dist/file-upload-inline/defaults.js +10 -0
- package/dist/file-upload-inline/index.cjs +2 -0
- package/dist/file-upload-inline/index.d.cts +2 -0
- package/dist/file-upload-inline/index.d.ts +2 -0
- package/dist/file-upload-inline/index.js +1 -0
- package/dist/file-upload-inline/types.d.cts +16 -0
- package/dist/file-upload-inline/types.d.ts +16 -0
- package/dist/file-upload-inline/utils.cjs +37 -0
- package/dist/file-upload-inline/utils.js +34 -0
- package/dist/hooks/index.cjs +2 -1
- package/dist/hooks/index.js +1 -1
- package/dist/hooks/use-media-query.cjs +9 -1
- package/dist/hooks/use-media-query.js +7 -1
- package/dist/icon-selector/IconPicker.cjs +93 -1
- package/dist/icon-selector/IconPicker.d.cts +3 -2
- package/dist/icon-selector/IconPicker.d.ts +3 -2
- package/dist/icon-selector/IconPicker.js +88 -1
- package/dist/icon-selector/constants.cjs +7 -1
- package/dist/icon-selector/constants.js +5 -0
- package/dist/icon-selector/icon-picker-container.cjs +35 -1
- package/dist/icon-selector/icon-picker-container.js +32 -1
- package/dist/icon-selector/icon-picker-content.cjs +146 -1
- package/dist/icon-selector/icon-picker-content.js +141 -1
- package/dist/icon-selector/index.cjs +2 -1
- package/dist/icon-selector/index.d.cts +1 -2
- package/dist/icon-selector/index.d.ts +1 -2
- package/dist/icon-selector/index.js +1 -1
- package/dist/icon-selector/types.d.cts +4 -2
- package/dist/icon-selector/types.d.ts +4 -2
- package/dist/icon-selector/use-async-providers.cjs +69 -1
- package/dist/icon-selector/use-async-providers.js +67 -1
- package/dist/icon-selector/utils/is-valid-provider.cjs +12 -1
- package/dist/icon-selector/utils/is-valid-provider.js +10 -1
- package/dist/icon-selector/virtualized-icon-grid.cjs +137 -1
- package/dist/icon-selector/virtualized-icon-grid.js +132 -1
- package/dist/index.cjs +76 -1
- package/dist/index.d.cts +12 -7
- package/dist/index.d.ts +12 -7
- package/dist/index.js +37 -1
- package/dist/node_modules/.pnpm/@diceui_shared@0.12.0_@floating-ui_react@0.27.16_react-dom@19.2.0_react@19.2.0__react@1_2c51ffe880f01dd537d5b6a13313daf4/node_modules/@diceui/shared/dist/index.cjs +558 -0
- package/dist/node_modules/.pnpm/@diceui_shared@0.12.0_@floating-ui_react@0.27.16_react-dom@19.2.0_react@19.2.0__react@1_2c51ffe880f01dd537d5b6a13313daf4/node_modules/@diceui/shared/dist/index.js +555 -0
- package/dist/node_modules/.pnpm/@diceui_tags-input@0.7.2_@floating-ui_react@0.27.16_react-dom@19.2.0_react@19.2.0__reac_e193dc2ff0d426ed009417f8d89778fd/node_modules/@diceui/tags-input/dist/index.cjs +566 -0
- package/dist/node_modules/.pnpm/@diceui_tags-input@0.7.2_@floating-ui_react@0.27.16_react-dom@19.2.0_react@19.2.0__reac_e193dc2ff0d426ed009417f8d89778fd/node_modules/@diceui/tags-input/dist/index.js +565 -0
- package/dist/node_modules/.pnpm/@floating-ui_core@1.7.3/node_modules/@floating-ui/core/dist/floating-ui.core.cjs +695 -0
- package/dist/node_modules/.pnpm/@floating-ui_core@1.7.3/node_modules/@floating-ui/core/dist/floating-ui.core.js +679 -0
- package/dist/node_modules/.pnpm/@floating-ui_dom@1.7.4/node_modules/@floating-ui/dom/dist/floating-ui.dom.cjs +521 -0
- package/dist/node_modules/.pnpm/@floating-ui_dom@1.7.4/node_modules/@floating-ui/dom/dist/floating-ui.dom.js +503 -0
- package/dist/node_modules/.pnpm/@floating-ui_react-dom@2.1.6_react-dom@19.2.0_react@19.2.0__react@19.2.0/node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.cjs +282 -0
- package/dist/node_modules/.pnpm/@floating-ui_react-dom@2.1.6_react-dom@19.2.0_react@19.2.0__react@19.2.0/node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.js +266 -0
- package/dist/node_modules/.pnpm/@floating-ui_react@0.27.16_react-dom@19.2.0_react@19.2.0__react@19.2.0/node_modules/@floating-ui/react/dist/floating-ui.react.esm.cjs +3767 -0
- package/dist/node_modules/.pnpm/@floating-ui_react@0.27.16_react-dom@19.2.0_react@19.2.0__react@19.2.0/node_modules/@floating-ui/react/dist/floating-ui.react.esm.js +3747 -0
- package/dist/node_modules/.pnpm/@floating-ui_react@0.27.16_react-dom@19.2.0_react@19.2.0__react@19.2.0/node_modules/@floating-ui/react/dist/floating-ui.react.utils.cjs +426 -0
- package/dist/node_modules/.pnpm/@floating-ui_react@0.27.16_react-dom@19.2.0_react@19.2.0__react@19.2.0/node_modules/@floating-ui/react/dist/floating-ui.react.utils.js +379 -0
- package/dist/node_modules/.pnpm/@floating-ui_utils@0.2.10/node_modules/@floating-ui/utils/dist/floating-ui.utils.cjs +165 -0
- package/dist/node_modules/.pnpm/@floating-ui_utils@0.2.10/node_modules/@floating-ui/utils/dist/floating-ui.utils.dom.cjs +175 -0
- package/dist/node_modules/.pnpm/@floating-ui_utils@0.2.10/node_modules/@floating-ui/utils/dist/floating-ui.utils.dom.js +151 -0
- package/dist/node_modules/.pnpm/@floating-ui_utils@0.2.10/node_modules/@floating-ui/utils/dist/floating-ui.utils.js +138 -0
- package/dist/node_modules/.pnpm/@radix-ui_primitive@1.1.3/node_modules/@radix-ui/primitive/dist/index.cjs +13 -0
- package/dist/node_modules/.pnpm/@radix-ui_primitive@1.1.3/node_modules/@radix-ui/primitive/dist/index.js +11 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-compose-refs@1.1.2_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-compose-refs/dist/index.cjs +33 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-compose-refs@1.1.2_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-compose-refs/dist/index.js +30 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-context@1.1.2_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-context/dist/index.cjs +92 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-context@1.1.2_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-context/dist/index.js +88 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-dialog@1.1.15_@types_react-dom@19.2.3_@types_react@19.2.6__@types_react_4f1d9653b0e2175502748f45fd432185/node_modules/@radix-ui/react-dialog/dist/index.cjs +310 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-dialog@1.1.15_@types_react-dom@19.2.3_@types_react@19.2.6__@types_react_4f1d9653b0e2175502748f45fd432185/node_modules/@radix-ui/react-dialog/dist/index.js +299 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-dismissable-layer@1.1.11_@types_react-dom@19.2.3_@types_react@19.2.6__@_9ee1db7daf927866cf505b31d40047ad/node_modules/@radix-ui/react-dismissable-layer/dist/index.cjs +190 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-dismissable-layer@1.1.11_@types_react-dom@19.2.3_@types_react@19.2.6__@_9ee1db7daf927866cf505b31d40047ad/node_modules/@radix-ui/react-dismissable-layer/dist/index.js +187 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-focus-guards@1.1.3_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-focus-guards/dist/index.cjs +34 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-focus-guards@1.1.3_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-focus-guards/dist/index.js +32 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-focus-scope@1.1.7_@types_react-dom@19.2.3_@types_react@19.2.6__@types_r_0a31b7f987af9482d13505312e1a1be9/node_modules/@radix-ui/react-focus-scope/dist/index.cjs +203 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-focus-scope@1.1.7_@types_react-dom@19.2.3_@types_react@19.2.6__@types_r_0a31b7f987af9482d13505312e1a1be9/node_modules/@radix-ui/react-focus-scope/dist/index.js +200 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-id@1.1.1_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-id/dist/index.cjs +18 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-id@1.1.1_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-id/dist/index.js +16 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-portal@1.1.9_@types_react-dom@19.2.3_@types_react@19.2.6__@types_react@_1bb4e0f97f86496802d28a2e74e2a8b9/node_modules/@radix-ui/react-portal/dist/index.cjs +29 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-portal@1.1.9_@types_react-dom@19.2.3_@types_react@19.2.6__@types_react@_1bb4e0f97f86496802d28a2e74e2a8b9/node_modules/@radix-ui/react-portal/dist/index.js +25 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-presence@1.1.5_@types_react-dom@19.2.3_@types_react@19.2.6__@types_reac_90f8e5c12233caef3399d5fd66452a13/node_modules/@radix-ui/react-presence/dist/index.cjs +110 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-presence@1.1.5_@types_react-dom@19.2.3_@types_react@19.2.6__@types_reac_90f8e5c12233caef3399d5fd66452a13/node_modules/@radix-ui/react-presence/dist/index.js +108 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-primitive@2.1.3_@types_react-dom@19.2.3_@types_react@19.2.6__@types_rea_a92a69cb1cb39305138539e4fa72f596/node_modules/@radix-ui/react-primitive/dist/index.cjs +52 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-primitive@2.1.3_@types_react-dom@19.2.3_@types_react@19.2.6__@types_rea_a92a69cb1cb39305138539e4fa72f596/node_modules/@radix-ui/react-primitive/dist/index.js +47 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-slot@1.2.3_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-slot/dist/index.cjs +92 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-slot@1.2.3_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-slot/dist/index.js +89 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-slot@1.2.4_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-slot/dist/index.cjs +103 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-slot@1.2.4_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-slot/dist/index.js +100 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-use-callback-ref@1.1.1_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-use-callback-ref/dist/index.cjs +15 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-use-callback-ref@1.1.1_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-use-callback-ref/dist/index.js +13 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-use-controllable-state@1.2.2_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-use-controllable-state/dist/index.cjs +64 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-use-controllable-state@1.2.2_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-use-controllable-state/dist/index.js +62 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-use-escape-keydown@1.1.1_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-use-escape-keydown/dist/index.cjs +19 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-use-escape-keydown@1.1.1_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-use-escape-keydown/dist/index.js +17 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-use-layout-effect@1.1.1_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-use-layout-effect/dist/index.cjs +9 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-use-layout-effect@1.1.1_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-use-layout-effect/dist/index.js +7 -0
- package/dist/node_modules/.pnpm/aria-hidden@1.2.6/node_modules/aria-hidden/dist/es2015/index.js +108 -0
- package/dist/node_modules/.pnpm/aria-hidden@1.2.6/node_modules/aria-hidden/dist/es5/index.cjs +155 -0
- package/dist/node_modules/.pnpm/clsx@2.1.1/node_modules/clsx/dist/clsx.cjs +19 -0
- package/dist/node_modules/.pnpm/clsx@2.1.1/node_modules/clsx/dist/clsx.js +17 -0
- package/dist/node_modules/.pnpm/detect-node-es@1.1.0/node_modules/detect-node-es/es5/node.cjs +14 -0
- package/dist/node_modules/.pnpm/get-nonce@1.0.1/node_modules/get-nonce/dist/es2015/index.js +9 -0
- package/dist/node_modules/.pnpm/get-nonce@1.0.1/node_modules/get-nonce/dist/es5/index.cjs +22 -0
- package/dist/node_modules/.pnpm/react-remove-scroll-bar@2.3.8_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll-bar/dist/es2015/component.js +46 -0
- package/dist/node_modules/.pnpm/react-remove-scroll-bar@2.3.8_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll-bar/dist/es2015/constants.js +12 -0
- package/dist/node_modules/.pnpm/react-remove-scroll-bar@2.3.8_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll-bar/dist/es2015/index.js +3 -0
- package/dist/node_modules/.pnpm/react-remove-scroll-bar@2.3.8_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll-bar/dist/es2015/utils.js +37 -0
- package/dist/node_modules/.pnpm/react-remove-scroll-bar@2.3.8_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll-bar/dist/es5/component.cjs +61 -0
- package/dist/node_modules/.pnpm/react-remove-scroll-bar@2.3.8_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll-bar/dist/es5/constants.cjs +23 -0
- package/dist/node_modules/.pnpm/react-remove-scroll-bar@2.3.8_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll-bar/dist/es5/index.cjs +57 -0
- package/dist/node_modules/.pnpm/react-remove-scroll-bar@2.3.8_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll-bar/dist/es5/utils.cjs +49 -0
- package/dist/node_modules/.pnpm/react-remove-scroll@2.7.1_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll/dist/es2015/Combination.js +17 -0
- package/dist/node_modules/.pnpm/react-remove-scroll@2.7.1_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll/dist/es2015/SideEffect.js +163 -0
- package/dist/node_modules/.pnpm/react-remove-scroll@2.7.1_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll/dist/es2015/UI.js +64 -0
- package/dist/node_modules/.pnpm/react-remove-scroll@2.7.1_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll/dist/es2015/aggresiveCapture.js +16 -0
- package/dist/node_modules/.pnpm/react-remove-scroll@2.7.1_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll/dist/es2015/handleScroll.js +85 -0
- package/dist/node_modules/.pnpm/react-remove-scroll@2.7.1_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll/dist/es2015/medium.js +7 -0
- package/dist/node_modules/.pnpm/react-remove-scroll@2.7.1_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll/dist/es2015/sidecar.js +9 -0
- package/dist/node_modules/.pnpm/react-remove-scroll@2.7.1_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll/dist/es5/Combination.cjs +29 -0
- package/dist/node_modules/.pnpm/react-remove-scroll@2.7.1_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll/dist/es5/SideEffect.cjs +179 -0
- package/dist/node_modules/.pnpm/react-remove-scroll@2.7.1_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll/dist/es5/UI.cjs +79 -0
- package/dist/node_modules/.pnpm/react-remove-scroll@2.7.1_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll/dist/es5/aggresiveCapture.cjs +27 -0
- package/dist/node_modules/.pnpm/react-remove-scroll@2.7.1_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll/dist/es5/handleScroll.cjs +98 -0
- package/dist/node_modules/.pnpm/react-remove-scroll@2.7.1_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll/dist/es5/index.cjs +19 -0
- package/dist/node_modules/.pnpm/react-remove-scroll@2.7.1_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll/dist/es5/medium.cjs +18 -0
- package/dist/node_modules/.pnpm/react-remove-scroll@2.7.1_@types_react@19.2.6_react@19.2.0/node_modules/react-remove-scroll/dist/es5/sidecar.cjs +21 -0
- package/dist/node_modules/.pnpm/react-style-singleton@2.2.3_@types_react@19.2.6_react@19.2.0/node_modules/react-style-singleton/dist/es2015/component.js +21 -0
- package/dist/node_modules/.pnpm/react-style-singleton@2.2.3_@types_react@19.2.6_react@19.2.0/node_modules/react-style-singleton/dist/es2015/hook.js +27 -0
- package/dist/node_modules/.pnpm/react-style-singleton@2.2.3_@types_react@19.2.6_react@19.2.0/node_modules/react-style-singleton/dist/es2015/index.js +3 -0
- package/dist/node_modules/.pnpm/react-style-singleton@2.2.3_@types_react@19.2.6_react@19.2.0/node_modules/react-style-singleton/dist/es2015/singleton.js +43 -0
- package/dist/node_modules/.pnpm/react-style-singleton@2.2.3_@types_react@19.2.6_react@19.2.0/node_modules/react-style-singleton/dist/es5/component.cjs +33 -0
- package/dist/node_modules/.pnpm/react-style-singleton@2.2.3_@types_react@19.2.6_react@19.2.0/node_modules/react-style-singleton/dist/es5/hook.cjs +40 -0
- package/dist/node_modules/.pnpm/react-style-singleton@2.2.3_@types_react@19.2.6_react@19.2.0/node_modules/react-style-singleton/dist/es5/index.cjs +39 -0
- package/dist/node_modules/.pnpm/react-style-singleton@2.2.3_@types_react@19.2.6_react@19.2.0/node_modules/react-style-singleton/dist/es5/singleton.cjs +55 -0
- package/dist/node_modules/.pnpm/tabbable@6.3.0/node_modules/tabbable/dist/index.cjs +347 -0
- package/dist/node_modules/.pnpm/tabbable@6.3.0/node_modules/tabbable/dist/index.esm.js +268 -0
- package/dist/node_modules/.pnpm/tailwind-merge@3.4.0/node_modules/tailwind-merge/dist/bundle-mjs.cjs +1895 -0
- package/dist/node_modules/.pnpm/tailwind-merge@3.4.0/node_modules/tailwind-merge/dist/bundle-mjs.js +1893 -0
- package/dist/node_modules/.pnpm/tslib@2.8.1/node_modules/tslib/tslib.es6.cjs +557 -0
- package/dist/node_modules/.pnpm/tslib@2.8.1/node_modules/tslib/tslib.es6.js +31 -0
- package/dist/node_modules/.pnpm/use-callback-ref@1.3.3_@types_react@19.2.6_react@19.2.0/node_modules/use-callback-ref/dist/es2015/assignRef.js +22 -0
- package/dist/node_modules/.pnpm/use-callback-ref@1.3.3_@types_react@19.2.6_react@19.2.0/node_modules/use-callback-ref/dist/es2015/useMergeRef.js +47 -0
- package/dist/node_modules/.pnpm/use-callback-ref@1.3.3_@types_react@19.2.6_react@19.2.0/node_modules/use-callback-ref/dist/es2015/useRef.js +42 -0
- package/dist/node_modules/.pnpm/use-callback-ref@1.3.3_@types_react@19.2.6_react@19.2.0/node_modules/use-callback-ref/dist/es5/assignRef.cjs +34 -0
- package/dist/node_modules/.pnpm/use-callback-ref@1.3.3_@types_react@19.2.6_react@19.2.0/node_modules/use-callback-ref/dist/es5/createRef.cjs +39 -0
- package/dist/node_modules/.pnpm/use-callback-ref@1.3.3_@types_react@19.2.6_react@19.2.0/node_modules/use-callback-ref/dist/es5/index.cjs +85 -0
- package/dist/node_modules/.pnpm/use-callback-ref@1.3.3_@types_react@19.2.6_react@19.2.0/node_modules/use-callback-ref/dist/es5/mergeRef.cjs +40 -0
- package/dist/node_modules/.pnpm/use-callback-ref@1.3.3_@types_react@19.2.6_react@19.2.0/node_modules/use-callback-ref/dist/es5/refToCallback.cjs +59 -0
- package/dist/node_modules/.pnpm/use-callback-ref@1.3.3_@types_react@19.2.6_react@19.2.0/node_modules/use-callback-ref/dist/es5/transformRef.cjs +34 -0
- package/dist/node_modules/.pnpm/use-callback-ref@1.3.3_@types_react@19.2.6_react@19.2.0/node_modules/use-callback-ref/dist/es5/useMergeRef.cjs +61 -0
- package/dist/node_modules/.pnpm/use-callback-ref@1.3.3_@types_react@19.2.6_react@19.2.0/node_modules/use-callback-ref/dist/es5/useRef.cjs +53 -0
- package/dist/node_modules/.pnpm/use-callback-ref@1.3.3_@types_react@19.2.6_react@19.2.0/node_modules/use-callback-ref/dist/es5/useTransformRef.cjs +38 -0
- package/dist/node_modules/.pnpm/use-sidecar@1.1.3_@types_react@19.2.6_react@19.2.0/node_modules/use-sidecar/dist/es2015/exports.js +19 -0
- package/dist/node_modules/.pnpm/use-sidecar@1.1.3_@types_react@19.2.6_react@19.2.0/node_modules/use-sidecar/dist/es2015/medium.js +84 -0
- package/dist/node_modules/.pnpm/use-sidecar@1.1.3_@types_react@19.2.6_react@19.2.0/node_modules/use-sidecar/dist/es5/config.cjs +22 -0
- package/dist/node_modules/.pnpm/use-sidecar@1.1.3_@types_react@19.2.6_react@19.2.0/node_modules/use-sidecar/dist/es5/env.cjs +21 -0
- package/dist/node_modules/.pnpm/use-sidecar@1.1.3_@types_react@19.2.6_react@19.2.0/node_modules/use-sidecar/dist/es5/exports.cjs +31 -0
- package/dist/node_modules/.pnpm/use-sidecar@1.1.3_@types_react@19.2.6_react@19.2.0/node_modules/use-sidecar/dist/es5/hoc.cjs +31 -0
- package/dist/node_modules/.pnpm/use-sidecar@1.1.3_@types_react@19.2.6_react@19.2.0/node_modules/use-sidecar/dist/es5/hook.cjs +60 -0
- package/dist/node_modules/.pnpm/use-sidecar@1.1.3_@types_react@19.2.6_react@19.2.0/node_modules/use-sidecar/dist/es5/index.cjs +69 -0
- package/dist/node_modules/.pnpm/use-sidecar@1.1.3_@types_react@19.2.6_react@19.2.0/node_modules/use-sidecar/dist/es5/medium.cjs +101 -0
- package/dist/node_modules/.pnpm/use-sidecar@1.1.3_@types_react@19.2.6_react@19.2.0/node_modules/use-sidecar/dist/es5/renderProp.cjs +58 -0
- package/dist/packages/shadcn/src/components/index.cjs +6 -0
- package/dist/packages/shadcn/src/components/index.js +5 -0
- package/dist/packages/shadcn/src/components/ui/OrContinueWithSeparator.cjs +6 -0
- package/dist/packages/shadcn/src/components/ui/OrContinueWithSeparator.js +3 -0
- package/dist/packages/shadcn/src/components/ui/alert-dialog.cjs +10 -0
- package/dist/packages/shadcn/src/components/ui/alert-dialog.js +6 -0
- package/dist/packages/shadcn/src/components/ui/alert.cjs +44 -0
- package/dist/packages/shadcn/src/components/ui/alert.js +38 -0
- package/dist/packages/shadcn/src/components/ui/avatar.cjs +5 -0
- package/dist/packages/shadcn/src/components/ui/avatar.js +2 -0
- package/dist/packages/shadcn/src/components/ui/badge.cjs +20 -0
- package/dist/packages/shadcn/src/components/ui/badge.js +16 -0
- package/dist/packages/shadcn/src/components/ui/button.cjs +50 -0
- package/dist/packages/shadcn/src/components/ui/button.js +45 -0
- package/dist/packages/shadcn/src/components/ui/calendar.cjs +8 -0
- package/dist/packages/shadcn/src/components/ui/calendar.js +4 -0
- package/dist/packages/shadcn/src/components/ui/card.cjs +5 -0
- package/dist/packages/shadcn/src/components/ui/card.js +2 -0
- package/dist/packages/shadcn/src/components/ui/checkbox.cjs +10 -0
- package/dist/packages/shadcn/src/components/ui/checkbox.js +6 -0
- package/dist/packages/shadcn/src/components/ui/command.cjs +11 -0
- package/dist/packages/shadcn/src/components/ui/command.js +7 -0
- package/dist/packages/shadcn/src/components/ui/dialog.cjs +93 -0
- package/dist/packages/shadcn/src/components/ui/dialog.js +81 -0
- package/dist/packages/shadcn/src/components/ui/dropdown-menu.cjs +7 -0
- package/dist/packages/shadcn/src/components/ui/dropdown-menu.js +3 -0
- package/dist/packages/shadcn/src/components/ui/file-upload.cjs +49 -0
- package/dist/packages/shadcn/src/components/ui/file-upload.js +45 -0
- package/dist/packages/shadcn/src/components/ui/form.cjs +12 -0
- package/dist/packages/shadcn/src/components/ui/form.js +9 -0
- package/dist/packages/shadcn/src/components/ui/index.cjs +30 -0
- package/dist/packages/shadcn/src/components/ui/index.js +29 -0
- package/dist/packages/shadcn/src/components/ui/input.cjs +5 -0
- package/dist/packages/shadcn/src/components/ui/input.js +2 -0
- package/dist/packages/shadcn/src/components/ui/label.cjs +5 -0
- package/dist/packages/shadcn/src/components/ui/label.js +2 -0
- package/dist/packages/shadcn/src/components/ui/pagination.cjs +9 -0
- package/dist/packages/shadcn/src/components/ui/pagination.js +4 -0
- package/dist/packages/shadcn/src/components/ui/popover.cjs +5 -0
- package/dist/packages/shadcn/src/components/ui/popover.js +2 -0
- package/dist/packages/shadcn/src/components/ui/radio-group.cjs +7 -0
- package/dist/packages/shadcn/src/components/ui/radio-group.js +3 -0
- package/dist/packages/shadcn/src/components/ui/select.cjs +10 -0
- package/dist/packages/shadcn/src/components/ui/select.js +6 -0
- package/dist/packages/shadcn/src/components/ui/separator.cjs +5 -0
- package/dist/packages/shadcn/src/components/ui/separator.js +2 -0
- package/dist/packages/shadcn/src/components/ui/shadcn-io/tags/index.cjs +26 -0
- package/dist/packages/shadcn/src/components/ui/shadcn-io/tags/index.js +22 -0
- package/dist/packages/shadcn/src/components/ui/shadcn-io/tags-input-inline/index.cjs +6 -0
- package/dist/packages/shadcn/src/components/ui/shadcn-io/tags-input-inline/index.js +3 -0
- package/dist/packages/shadcn/src/components/ui/sheet.cjs +7 -0
- package/dist/packages/shadcn/src/components/ui/sheet.js +3 -0
- package/dist/packages/shadcn/src/components/ui/slider.cjs +5 -0
- package/dist/packages/shadcn/src/components/ui/slider.js +2 -0
- package/dist/packages/shadcn/src/components/ui/switch.cjs +8 -0
- package/dist/packages/shadcn/src/components/ui/switch.js +5 -0
- package/dist/packages/shadcn/src/components/ui/tabs.cjs +5 -0
- package/dist/packages/shadcn/src/components/ui/tabs.js +2 -0
- package/dist/packages/shadcn/src/components/ui/textarea.cjs +5 -0
- package/dist/packages/shadcn/src/components/ui/textarea.js +2 -0
- package/dist/packages/shadcn/src/components/ui/tooltip.cjs +5 -0
- package/dist/packages/shadcn/src/components/ui/tooltip.js +2 -0
- package/dist/packages/shadcn/src/lib/utils.cjs +11 -0
- package/dist/packages/shadcn/src/lib/utils.js +10 -0
- package/dist/pagination/Pagination.cjs +156 -0
- package/dist/{Pagination → pagination}/Pagination.d.cts +1 -1
- package/dist/{Pagination → pagination}/Pagination.d.ts +1 -1
- package/dist/pagination/Pagination.js +151 -0
- package/dist/pagination/index.cjs +2 -0
- package/dist/pagination/index.js +1 -0
- package/dist/rich-text-editor/RichTextEditor.cjs +132 -0
- package/dist/rich-text-editor/RichTextEditor.d.cts +55 -0
- package/dist/rich-text-editor/RichTextEditor.d.ts +55 -0
- package/dist/rich-text-editor/RichTextEditor.js +126 -0
- package/dist/rich-text-editor/index.cjs +2 -0
- package/dist/rich-text-editor/index.d.cts +1 -0
- package/dist/rich-text-editor/index.d.ts +1 -0
- package/dist/rich-text-editor/index.js +1 -0
- package/dist/rich-text-editor/predefined-toolbar-options.cjs +84 -0
- package/dist/rich-text-editor/predefined-toolbar-options.js +81 -0
- package/dist/spinner/index.cjs +2 -1
- package/dist/spinner/index.js +1 -1
- package/dist/spinner/spinner.cjs +73 -6
- package/dist/spinner/spinner.js +70 -6
- package/dist/spinner/styles.cjs +25 -12
- package/dist/spinner/styles.js +23 -12
- package/dist/tags-input.cjs +226 -1
- package/dist/tags-input.d.cts +2 -2
- package/dist/tags-input.d.ts +2 -2
- package/dist/tags-input.js +222 -1
- package/dist/theme-provider/ThemeProvider.cjs +27 -1
- package/dist/theme-provider/ThemeProvider.js +23 -1
- package/dist/theme-provider/index.cjs +4 -1
- package/dist/theme-provider/index.js +4 -1
- package/dist/toast/AlertToast.cjs +36 -1
- package/dist/toast/AlertToast.js +31 -1
- package/dist/toast/index.cjs +2 -1
- package/dist/toast/index.js +1 -1
- package/dist/toast/toast.cjs +75 -1
- package/dist/toast/toast.js +66 -1
- package/package.json +11 -4
- package/dist/FileUploadInline.cjs +0 -1
- package/dist/FileUploadInline.d.cts +0 -75
- package/dist/FileUploadInline.d.ts +0 -75
- package/dist/FileUploadInline.js +0 -1
- package/dist/Pagination/Pagination.cjs +0 -1
- package/dist/Pagination/Pagination.js +0 -1
- package/dist/Pagination/index.cjs +0 -1
- package/dist/Pagination/index.js +0 -1
- package/dist/PopoverContent.cjs +0 -1
- package/dist/PopoverContent.d.cts +0 -8
- package/dist/PopoverContent.d.ts +0 -8
- package/dist/PopoverContent.js +0 -1
- package/dist/icon-selector/use-async-providers.d.cts +0 -14
- package/dist/icon-selector/use-async-providers.d.ts +0 -14
- package/dist/shadcn/src/components/ui/alert.cjs +0 -1
- package/dist/shadcn/src/components/ui/alert.js +0 -1
- package/dist/shadcn/src/components/ui/dialog.cjs +0 -1
- package/dist/shadcn/src/components/ui/dialog.js +0 -1
- package/dist/shadcn/src/lib/index.cjs +0 -1
- package/dist/shadcn/src/lib/index.js +0 -1
- package/dist/shadcn/src/lib/utils.cjs +0 -1
- package/dist/shadcn/src/lib/utils.js +0 -1
- /package/dist/{Pagination → pagination}/index.d.cts +0 -0
- /package/dist/{Pagination → pagination}/index.d.ts +0 -0
|
@@ -1 +1,25 @@
|
|
|
1
|
-
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
import { CommandEmpty, CommandGroup, CommandItem, CommandList, cn } from "@pixpilot/shadcn";
|
|
5
|
+
import { Check } from "lucide-react";
|
|
6
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
7
|
+
|
|
8
|
+
//#region src/CommandOptionList.tsx
|
|
9
|
+
const CommandOptionList = (props) => {
|
|
10
|
+
const { options, value, onChange, emptyText = "No option found." } = props;
|
|
11
|
+
return /* @__PURE__ */ jsxs(CommandList, { children: [/* @__PURE__ */ jsx(CommandEmpty, { children: emptyText }), /* @__PURE__ */ jsx(CommandGroup, { children: options.map((option) => /* @__PURE__ */ jsx(CommandItem, {
|
|
12
|
+
value: option.value,
|
|
13
|
+
onSelect: (currentValue) => {
|
|
14
|
+
onChange?.(currentValue === value ? "" : currentValue);
|
|
15
|
+
},
|
|
16
|
+
children: /* @__PURE__ */ jsxs("div", {
|
|
17
|
+
className: "w-full flex items-center justify-between",
|
|
18
|
+
children: [option.label, /* @__PURE__ */ jsx(Check, { className: cn("mr-2 h-4 w-4", value === option.value ? "opacity-100" : "opacity-0") })]
|
|
19
|
+
})
|
|
20
|
+
}, option.value)) })] });
|
|
21
|
+
};
|
|
22
|
+
CommandOptionList.displayName = "CommandOptionList";
|
|
23
|
+
|
|
24
|
+
//#endregion
|
|
25
|
+
export { CommandOptionList };
|
package/dist/ContentCard.cjs
CHANGED
|
@@ -1 +1,27 @@
|
|
|
1
|
-
const
|
|
1
|
+
const require_rolldown_runtime = require('./_virtual/rolldown_runtime.cjs');
|
|
2
|
+
let __pixpilot_shadcn = require("@pixpilot/shadcn");
|
|
3
|
+
__pixpilot_shadcn = require_rolldown_runtime.__toESM(__pixpilot_shadcn);
|
|
4
|
+
let react = require("react");
|
|
5
|
+
react = require_rolldown_runtime.__toESM(react);
|
|
6
|
+
let react_jsx_runtime = require("react/jsx-runtime");
|
|
7
|
+
react_jsx_runtime = require_rolldown_runtime.__toESM(react_jsx_runtime);
|
|
8
|
+
|
|
9
|
+
//#region src/ContentCard.tsx
|
|
10
|
+
function ContentCard(props) {
|
|
11
|
+
const { title, children, className, marginBottom,...other } = props;
|
|
12
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(__pixpilot_shadcn.Card, {
|
|
13
|
+
className: (0, __pixpilot_shadcn.cn)("py-4 sm:py-5", { "mb-2 sm:mb-4": marginBottom }, className),
|
|
14
|
+
...other,
|
|
15
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(__pixpilot_shadcn.CardContent, {
|
|
16
|
+
className: (0, __pixpilot_shadcn.cn)("px-4 sm:px-6"),
|
|
17
|
+
children: [title != null && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("h2", {
|
|
18
|
+
className: (0, __pixpilot_shadcn.cn)("text-xl font-semibold", "mb-1 sm:mb-2"),
|
|
19
|
+
children: title
|
|
20
|
+
}), children]
|
|
21
|
+
})
|
|
22
|
+
});
|
|
23
|
+
}
|
|
24
|
+
ContentCard.displayName = "ContentBox";
|
|
25
|
+
|
|
26
|
+
//#endregion
|
|
27
|
+
exports.ContentCard = ContentCard;
|
package/dist/ContentCard.js
CHANGED
|
@@ -1 +1,23 @@
|
|
|
1
|
-
import{Card
|
|
1
|
+
import { Card, CardContent, cn } from "@pixpilot/shadcn";
|
|
2
|
+
import React from "react";
|
|
3
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
4
|
+
|
|
5
|
+
//#region src/ContentCard.tsx
|
|
6
|
+
function ContentCard(props) {
|
|
7
|
+
const { title, children, className, marginBottom,...other } = props;
|
|
8
|
+
return /* @__PURE__ */ jsx(Card, {
|
|
9
|
+
className: cn("py-4 sm:py-5", { "mb-2 sm:mb-4": marginBottom }, className),
|
|
10
|
+
...other,
|
|
11
|
+
children: /* @__PURE__ */ jsxs(CardContent, {
|
|
12
|
+
className: cn("px-4 sm:px-6"),
|
|
13
|
+
children: [title != null && /* @__PURE__ */ jsx("h2", {
|
|
14
|
+
className: cn("text-xl font-semibold", "mb-1 sm:mb-2"),
|
|
15
|
+
children: title
|
|
16
|
+
}), children]
|
|
17
|
+
})
|
|
18
|
+
});
|
|
19
|
+
}
|
|
20
|
+
ContentCard.displayName = "ContentBox";
|
|
21
|
+
|
|
22
|
+
//#endregion
|
|
23
|
+
export { ContentCard };
|
package/dist/DatePicker.cjs
CHANGED
|
@@ -1 +1,38 @@
|
|
|
1
|
-
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
const require_rolldown_runtime = require('./_virtual/rolldown_runtime.cjs');
|
|
5
|
+
let __pixpilot_shadcn = require("@pixpilot/shadcn");
|
|
6
|
+
__pixpilot_shadcn = require_rolldown_runtime.__toESM(__pixpilot_shadcn);
|
|
7
|
+
let lucide_react = require("lucide-react");
|
|
8
|
+
lucide_react = require_rolldown_runtime.__toESM(lucide_react);
|
|
9
|
+
let react = require("react");
|
|
10
|
+
react = require_rolldown_runtime.__toESM(react);
|
|
11
|
+
let react_jsx_runtime = require("react/jsx-runtime");
|
|
12
|
+
react_jsx_runtime = require_rolldown_runtime.__toESM(react_jsx_runtime);
|
|
13
|
+
|
|
14
|
+
//#region src/DatePicker.tsx
|
|
15
|
+
function DatePicker(props) {
|
|
16
|
+
const { value, onChange, placeholder = "Pick a date",...calendarProps } = props;
|
|
17
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(__pixpilot_shadcn.Popover, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(__pixpilot_shadcn.PopoverTrigger, {
|
|
18
|
+
asChild: true,
|
|
19
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(__pixpilot_shadcn.Button, {
|
|
20
|
+
variant: "outline",
|
|
21
|
+
className: (0, __pixpilot_shadcn.cn)("w-full justify-start text-left font-normal", !value && "text-muted-foreground"),
|
|
22
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.CalendarIcon, { className: "mr-2 h-4 w-4" }), value ? value.toLocaleDateString() : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { children: placeholder })]
|
|
23
|
+
})
|
|
24
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(__pixpilot_shadcn.PopoverContent, {
|
|
25
|
+
className: "w-auto p-0",
|
|
26
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(__pixpilot_shadcn.Calendar, {
|
|
27
|
+
mode: "single",
|
|
28
|
+
selected: value,
|
|
29
|
+
onSelect: onChange,
|
|
30
|
+
initialFocus: true,
|
|
31
|
+
...calendarProps
|
|
32
|
+
})
|
|
33
|
+
})] });
|
|
34
|
+
}
|
|
35
|
+
DatePicker.displayName = "DatePicker";
|
|
36
|
+
|
|
37
|
+
//#endregion
|
|
38
|
+
exports.DatePicker = DatePicker;
|
package/dist/DatePicker.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Calendar } from "@pixpilot/shadcn";
|
|
2
2
|
import { ComponentProps } from "react";
|
|
3
|
-
import * as
|
|
3
|
+
import * as react_jsx_runtime0 from "react/jsx-runtime";
|
|
4
4
|
|
|
5
5
|
//#region src/DatePicker.d.ts
|
|
6
6
|
type BaseDatePickerProps = {
|
|
@@ -8,7 +8,7 @@ type BaseDatePickerProps = {
|
|
|
8
8
|
onChange?: (date: Date | undefined) => void;
|
|
9
9
|
placeholder?: string;
|
|
10
10
|
} & Omit<ComponentProps<typeof Calendar>, 'selected' | 'onSelect' | 'mode'>;
|
|
11
|
-
declare function DatePicker(props: BaseDatePickerProps):
|
|
11
|
+
declare function DatePicker(props: BaseDatePickerProps): react_jsx_runtime0.JSX.Element;
|
|
12
12
|
declare namespace DatePicker {
|
|
13
13
|
var displayName: string;
|
|
14
14
|
}
|
package/dist/DatePicker.js
CHANGED
|
@@ -1 +1,33 @@
|
|
|
1
|
-
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
import { Button, Calendar, Popover, PopoverContent, PopoverTrigger, cn } from "@pixpilot/shadcn";
|
|
5
|
+
import { CalendarIcon } from "lucide-react";
|
|
6
|
+
import React from "react";
|
|
7
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
8
|
+
|
|
9
|
+
//#region src/DatePicker.tsx
|
|
10
|
+
function DatePicker(props) {
|
|
11
|
+
const { value, onChange, placeholder = "Pick a date",...calendarProps } = props;
|
|
12
|
+
return /* @__PURE__ */ jsxs(Popover, { children: [/* @__PURE__ */ jsx(PopoverTrigger, {
|
|
13
|
+
asChild: true,
|
|
14
|
+
children: /* @__PURE__ */ jsxs(Button, {
|
|
15
|
+
variant: "outline",
|
|
16
|
+
className: cn("w-full justify-start text-left font-normal", !value && "text-muted-foreground"),
|
|
17
|
+
children: [/* @__PURE__ */ jsx(CalendarIcon, { className: "mr-2 h-4 w-4" }), value ? value.toLocaleDateString() : /* @__PURE__ */ jsx("span", { children: placeholder })]
|
|
18
|
+
})
|
|
19
|
+
}), /* @__PURE__ */ jsx(PopoverContent, {
|
|
20
|
+
className: "w-auto p-0",
|
|
21
|
+
children: /* @__PURE__ */ jsx(Calendar, {
|
|
22
|
+
mode: "single",
|
|
23
|
+
selected: value,
|
|
24
|
+
onSelect: onChange,
|
|
25
|
+
initialFocus: true,
|
|
26
|
+
...calendarProps
|
|
27
|
+
})
|
|
28
|
+
})] });
|
|
29
|
+
}
|
|
30
|
+
DatePicker.displayName = "DatePicker";
|
|
31
|
+
|
|
32
|
+
//#endregion
|
|
33
|
+
export { DatePicker };
|
package/dist/LoadingOverlay.cjs
CHANGED
|
@@ -1 +1,65 @@
|
|
|
1
|
-
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
const require_rolldown_runtime = require('./_virtual/rolldown_runtime.cjs');
|
|
5
|
+
let __pixpilot_shadcn = require("@pixpilot/shadcn");
|
|
6
|
+
__pixpilot_shadcn = require_rolldown_runtime.__toESM(__pixpilot_shadcn);
|
|
7
|
+
let lucide_react = require("lucide-react");
|
|
8
|
+
lucide_react = require_rolldown_runtime.__toESM(lucide_react);
|
|
9
|
+
let react = require("react");
|
|
10
|
+
react = require_rolldown_runtime.__toESM(react);
|
|
11
|
+
let react_jsx_runtime = require("react/jsx-runtime");
|
|
12
|
+
react_jsx_runtime = require_rolldown_runtime.__toESM(react_jsx_runtime);
|
|
13
|
+
|
|
14
|
+
//#region src/LoadingOverlay.tsx
|
|
15
|
+
const DEFAULT_DELAY = 0;
|
|
16
|
+
const FADE_DURATION = 300;
|
|
17
|
+
const LoadingOverlay = (props) => {
|
|
18
|
+
const { backdrop = true, placement = "center", loading, delay = DEFAULT_DELAY, message } = props;
|
|
19
|
+
const [mounted, setMounted] = (0, react.useState)(false);
|
|
20
|
+
const [visible, setVisible] = (0, react.useState)(false);
|
|
21
|
+
(0, react.useEffect)(() => {
|
|
22
|
+
let timeoutId;
|
|
23
|
+
if (loading) timeoutId = setTimeout(() => {
|
|
24
|
+
setMounted(true);
|
|
25
|
+
requestAnimationFrame(() => {
|
|
26
|
+
requestAnimationFrame(() => {
|
|
27
|
+
setVisible(true);
|
|
28
|
+
});
|
|
29
|
+
});
|
|
30
|
+
}, delay);
|
|
31
|
+
else {
|
|
32
|
+
setVisible(false);
|
|
33
|
+
timeoutId = setTimeout(() => {
|
|
34
|
+
setMounted(false);
|
|
35
|
+
}, mounted ? FADE_DURATION : 0);
|
|
36
|
+
}
|
|
37
|
+
return () => {
|
|
38
|
+
clearTimeout(timeoutId);
|
|
39
|
+
};
|
|
40
|
+
}, [
|
|
41
|
+
loading,
|
|
42
|
+
delay,
|
|
43
|
+
mounted
|
|
44
|
+
]);
|
|
45
|
+
const positionClass = {
|
|
46
|
+
top: "items-start pt-[50px]",
|
|
47
|
+
center: "items-center",
|
|
48
|
+
bottom: "items-end pb-[50px]"
|
|
49
|
+
}[placement];
|
|
50
|
+
if (!mounted) return null;
|
|
51
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
52
|
+
className: (0, __pixpilot_shadcn.cn)("fixed inset-0 z-[9999] flex justify-center transition-opacity", positionClass, backdrop ? "bg-black/50" : "pointer-events-none", visible ? "opacity-100" : "opacity-0"),
|
|
53
|
+
style: { transitionDuration: `${FADE_DURATION}ms` },
|
|
54
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
55
|
+
className: "flex flex-col items-center",
|
|
56
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(lucide_react.Loader2, { className: "text-foreground h-10 w-10 animate-spin" }), message != null && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
57
|
+
className: "mt-2 text-foreground",
|
|
58
|
+
children: message
|
|
59
|
+
})]
|
|
60
|
+
})
|
|
61
|
+
});
|
|
62
|
+
};
|
|
63
|
+
|
|
64
|
+
//#endregion
|
|
65
|
+
exports.LoadingOverlay = LoadingOverlay;
|
package/dist/LoadingOverlay.js
CHANGED
|
@@ -1 +1,60 @@
|
|
|
1
|
-
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
import { cn } from "@pixpilot/shadcn";
|
|
5
|
+
import { Loader2 } from "lucide-react";
|
|
6
|
+
import React, { useEffect, useState } from "react";
|
|
7
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
8
|
+
|
|
9
|
+
//#region src/LoadingOverlay.tsx
|
|
10
|
+
const DEFAULT_DELAY = 0;
|
|
11
|
+
const FADE_DURATION = 300;
|
|
12
|
+
const LoadingOverlay = (props) => {
|
|
13
|
+
const { backdrop = true, placement = "center", loading, delay = DEFAULT_DELAY, message } = props;
|
|
14
|
+
const [mounted, setMounted] = useState(false);
|
|
15
|
+
const [visible, setVisible] = useState(false);
|
|
16
|
+
useEffect(() => {
|
|
17
|
+
let timeoutId;
|
|
18
|
+
if (loading) timeoutId = setTimeout(() => {
|
|
19
|
+
setMounted(true);
|
|
20
|
+
requestAnimationFrame(() => {
|
|
21
|
+
requestAnimationFrame(() => {
|
|
22
|
+
setVisible(true);
|
|
23
|
+
});
|
|
24
|
+
});
|
|
25
|
+
}, delay);
|
|
26
|
+
else {
|
|
27
|
+
setVisible(false);
|
|
28
|
+
timeoutId = setTimeout(() => {
|
|
29
|
+
setMounted(false);
|
|
30
|
+
}, mounted ? FADE_DURATION : 0);
|
|
31
|
+
}
|
|
32
|
+
return () => {
|
|
33
|
+
clearTimeout(timeoutId);
|
|
34
|
+
};
|
|
35
|
+
}, [
|
|
36
|
+
loading,
|
|
37
|
+
delay,
|
|
38
|
+
mounted
|
|
39
|
+
]);
|
|
40
|
+
const positionClass = {
|
|
41
|
+
top: "items-start pt-[50px]",
|
|
42
|
+
center: "items-center",
|
|
43
|
+
bottom: "items-end pb-[50px]"
|
|
44
|
+
}[placement];
|
|
45
|
+
if (!mounted) return null;
|
|
46
|
+
return /* @__PURE__ */ jsx("div", {
|
|
47
|
+
className: cn("fixed inset-0 z-[9999] flex justify-center transition-opacity", positionClass, backdrop ? "bg-black/50" : "pointer-events-none", visible ? "opacity-100" : "opacity-0"),
|
|
48
|
+
style: { transitionDuration: `${FADE_DURATION}ms` },
|
|
49
|
+
children: /* @__PURE__ */ jsxs("div", {
|
|
50
|
+
className: "flex flex-col items-center",
|
|
51
|
+
children: [/* @__PURE__ */ jsx(Loader2, { className: "text-foreground h-10 w-10 animate-spin" }), message != null && /* @__PURE__ */ jsx("div", {
|
|
52
|
+
className: "mt-2 text-foreground",
|
|
53
|
+
children: message
|
|
54
|
+
})]
|
|
55
|
+
})
|
|
56
|
+
});
|
|
57
|
+
};
|
|
58
|
+
|
|
59
|
+
//#endregion
|
|
60
|
+
export { LoadingOverlay };
|
package/dist/Select.cjs
CHANGED
|
@@ -1 +1,27 @@
|
|
|
1
|
-
const
|
|
1
|
+
const require_rolldown_runtime = require('./_virtual/rolldown_runtime.cjs');
|
|
2
|
+
let __pixpilot_shadcn = require("@pixpilot/shadcn");
|
|
3
|
+
__pixpilot_shadcn = require_rolldown_runtime.__toESM(__pixpilot_shadcn);
|
|
4
|
+
let react = require("react");
|
|
5
|
+
react = require_rolldown_runtime.__toESM(react);
|
|
6
|
+
let react_jsx_runtime = require("react/jsx-runtime");
|
|
7
|
+
react_jsx_runtime = require_rolldown_runtime.__toESM(react_jsx_runtime);
|
|
8
|
+
|
|
9
|
+
//#region src/Select.tsx
|
|
10
|
+
function Select(props) {
|
|
11
|
+
const { options, value = "", onChange, placeholder,...restProps } = props;
|
|
12
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(__pixpilot_shadcn.Select, {
|
|
13
|
+
value,
|
|
14
|
+
onValueChange: onChange,
|
|
15
|
+
...restProps,
|
|
16
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(__pixpilot_shadcn.SelectTrigger, {
|
|
17
|
+
className: "w-full",
|
|
18
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(__pixpilot_shadcn.SelectValue, { placeholder })
|
|
19
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(__pixpilot_shadcn.SelectContent, { children: options?.map((option) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(__pixpilot_shadcn.SelectItem, {
|
|
20
|
+
value: String(option.value),
|
|
21
|
+
children: option.label
|
|
22
|
+
}, option.value)) })]
|
|
23
|
+
});
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
//#endregion
|
|
27
|
+
exports.Select = Select;
|
package/dist/Select.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Select } from "@pixpilot/shadcn";
|
|
2
|
-
import * as
|
|
2
|
+
import * as react_jsx_runtime3 from "react/jsx-runtime";
|
|
3
3
|
import { ComponentProps } from "react";
|
|
4
4
|
|
|
5
5
|
//#region src/Select.d.ts
|
|
@@ -13,6 +13,6 @@ type BaseSelectProps = {
|
|
|
13
13
|
onChange?: (value: string) => void;
|
|
14
14
|
placeholder?: string;
|
|
15
15
|
} & Omit<ComponentProps<typeof Select>, 'value' | 'onValueChange' | 'children'>;
|
|
16
|
-
declare function Select$1(props: BaseSelectProps):
|
|
16
|
+
declare function Select$1(props: BaseSelectProps): react_jsx_runtime3.JSX.Element;
|
|
17
17
|
//#endregion
|
|
18
18
|
export { Select$1 as Select, SelectOption };
|
package/dist/Select.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Select } from "@pixpilot/shadcn";
|
|
2
2
|
import { ComponentProps } from "react";
|
|
3
|
-
import * as
|
|
3
|
+
import * as react_jsx_runtime3 from "react/jsx-runtime";
|
|
4
4
|
|
|
5
5
|
//#region src/Select.d.ts
|
|
6
6
|
interface SelectOption {
|
|
@@ -13,6 +13,6 @@ type BaseSelectProps = {
|
|
|
13
13
|
onChange?: (value: string) => void;
|
|
14
14
|
placeholder?: string;
|
|
15
15
|
} & Omit<ComponentProps<typeof Select>, 'value' | 'onValueChange' | 'children'>;
|
|
16
|
-
declare function Select$1(props: BaseSelectProps):
|
|
16
|
+
declare function Select$1(props: BaseSelectProps): react_jsx_runtime3.JSX.Element;
|
|
17
17
|
//#endregion
|
|
18
18
|
export { Select$1 as Select, SelectOption };
|
package/dist/Select.js
CHANGED
|
@@ -1 +1,23 @@
|
|
|
1
|
-
import{Select
|
|
1
|
+
import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from "@pixpilot/shadcn";
|
|
2
|
+
import React from "react";
|
|
3
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
4
|
+
|
|
5
|
+
//#region src/Select.tsx
|
|
6
|
+
function Select$1(props) {
|
|
7
|
+
const { options, value = "", onChange, placeholder,...restProps } = props;
|
|
8
|
+
return /* @__PURE__ */ jsxs(Select, {
|
|
9
|
+
value,
|
|
10
|
+
onValueChange: onChange,
|
|
11
|
+
...restProps,
|
|
12
|
+
children: [/* @__PURE__ */ jsx(SelectTrigger, {
|
|
13
|
+
className: "w-full",
|
|
14
|
+
children: /* @__PURE__ */ jsx(SelectValue, { placeholder })
|
|
15
|
+
}), /* @__PURE__ */ jsx(SelectContent, { children: options?.map((option) => /* @__PURE__ */ jsx(SelectItem, {
|
|
16
|
+
value: String(option.value),
|
|
17
|
+
children: option.label
|
|
18
|
+
}, option.value)) })]
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
//#endregion
|
|
23
|
+
export { Select$1 as Select };
|
package/dist/Slider.cjs
CHANGED
|
@@ -1 +1,19 @@
|
|
|
1
|
-
const
|
|
1
|
+
const require_rolldown_runtime = require('./_virtual/rolldown_runtime.cjs');
|
|
2
|
+
let __pixpilot_shadcn = require("@pixpilot/shadcn");
|
|
3
|
+
__pixpilot_shadcn = require_rolldown_runtime.__toESM(__pixpilot_shadcn);
|
|
4
|
+
let react = require("react");
|
|
5
|
+
react = require_rolldown_runtime.__toESM(react);
|
|
6
|
+
let react_jsx_runtime = require("react/jsx-runtime");
|
|
7
|
+
react_jsx_runtime = require_rolldown_runtime.__toESM(react_jsx_runtime);
|
|
8
|
+
|
|
9
|
+
//#region src/Slider.tsx
|
|
10
|
+
const Slider = (props) => {
|
|
11
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(__pixpilot_shadcn.Slider, {
|
|
12
|
+
...props,
|
|
13
|
+
className: (0, __pixpilot_shadcn.cn)("py-2", props.className)
|
|
14
|
+
});
|
|
15
|
+
};
|
|
16
|
+
Slider.displayName = "Slider";
|
|
17
|
+
|
|
18
|
+
//#endregion
|
|
19
|
+
exports.Slider = Slider;
|
package/dist/Slider.js
CHANGED
|
@@ -1 +1,15 @@
|
|
|
1
|
-
import{Slider
|
|
1
|
+
import { Slider, cn } from "@pixpilot/shadcn";
|
|
2
|
+
import React from "react";
|
|
3
|
+
import { jsx } from "react/jsx-runtime";
|
|
4
|
+
|
|
5
|
+
//#region src/Slider.tsx
|
|
6
|
+
const Slider$1 = (props) => {
|
|
7
|
+
return /* @__PURE__ */ jsx(Slider, {
|
|
8
|
+
...props,
|
|
9
|
+
className: cn("py-2", props.className)
|
|
10
|
+
});
|
|
11
|
+
};
|
|
12
|
+
Slider$1.displayName = "Slider";
|
|
13
|
+
|
|
14
|
+
//#endregion
|
|
15
|
+
export { Slider$1 as Slider };
|
package/dist/ThemeToggle.cjs
CHANGED
|
@@ -1 +1,98 @@
|
|
|
1
|
-
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
const require_rolldown_runtime = require('./_virtual/rolldown_runtime.cjs');
|
|
5
|
+
let react = require("react");
|
|
6
|
+
react = require_rolldown_runtime.__toESM(react);
|
|
7
|
+
let react_jsx_runtime = require("react/jsx-runtime");
|
|
8
|
+
react_jsx_runtime = require_rolldown_runtime.__toESM(react_jsx_runtime);
|
|
9
|
+
let next_themes = require("next-themes");
|
|
10
|
+
next_themes = require_rolldown_runtime.__toESM(next_themes);
|
|
11
|
+
|
|
12
|
+
//#region src/ThemeToggle.tsx
|
|
13
|
+
function SunIcon() {
|
|
14
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("svg", {
|
|
15
|
+
className: "h-5 w-5",
|
|
16
|
+
fill: "none",
|
|
17
|
+
stroke: "currentColor",
|
|
18
|
+
viewBox: "0 0 24 24",
|
|
19
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
20
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
|
|
21
|
+
strokeLinecap: "round",
|
|
22
|
+
strokeLinejoin: "round",
|
|
23
|
+
strokeWidth: 2,
|
|
24
|
+
d: "M12 3v1m0 16v1m9-9h-1M4 12H3m15.364 6.364l-.707-.707M6.343 6.343l-.707-.707m12.728 0l-.707.707M6.343 17.657l-.707.707M16 12a4 4 0 11-8 0 4 4 0 018 0z"
|
|
25
|
+
})
|
|
26
|
+
});
|
|
27
|
+
}
|
|
28
|
+
function MoonIcon() {
|
|
29
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("svg", {
|
|
30
|
+
className: "h-5 w-5",
|
|
31
|
+
fill: "none",
|
|
32
|
+
stroke: "currentColor",
|
|
33
|
+
viewBox: "0 0 24 24",
|
|
34
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
35
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
|
|
36
|
+
strokeLinecap: "round",
|
|
37
|
+
strokeLinejoin: "round",
|
|
38
|
+
strokeWidth: 2,
|
|
39
|
+
d: "M20.354 15.354A9 9 0 018.646 3.646 9.003 9.003 0 0012 21a9.003 9.003 0 008.354-5.646z"
|
|
40
|
+
})
|
|
41
|
+
});
|
|
42
|
+
}
|
|
43
|
+
function SystemIcon() {
|
|
44
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("svg", {
|
|
45
|
+
className: "h-5 w-5",
|
|
46
|
+
fill: "none",
|
|
47
|
+
stroke: "currentColor",
|
|
48
|
+
viewBox: "0 0 24 24",
|
|
49
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
50
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
|
|
51
|
+
strokeLinecap: "round",
|
|
52
|
+
strokeLinejoin: "round",
|
|
53
|
+
strokeWidth: 2,
|
|
54
|
+
d: "M9.75 17L9 20l-1 1h8l-1-1-.75-3M3 13h18M5 17h14a2 2 0 002-2V5a2 2 0 00-2-2H5a2 2 0 00-2 2v10a2 2 0 002 2z"
|
|
55
|
+
})
|
|
56
|
+
});
|
|
57
|
+
}
|
|
58
|
+
function ThemeToggle() {
|
|
59
|
+
const [mounted, setMounted] = (0, react.useState)(false);
|
|
60
|
+
const { theme, setTheme } = (0, next_themes.useTheme)();
|
|
61
|
+
(0, react.useEffect)(() => {
|
|
62
|
+
const timer = setTimeout(() => {
|
|
63
|
+
setMounted(true);
|
|
64
|
+
}, 0);
|
|
65
|
+
return () => {
|
|
66
|
+
clearTimeout(timer);
|
|
67
|
+
};
|
|
68
|
+
}, []);
|
|
69
|
+
if (!mounted) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
70
|
+
className: "flex h-9 w-9 items-center justify-center rounded-md border border-gray-200 dark:border-gray-700",
|
|
71
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", { className: "h-5 w-5 animate-pulse rounded bg-gray-300 dark:bg-gray-600" })
|
|
72
|
+
});
|
|
73
|
+
const toggleTheme = () => {
|
|
74
|
+
if (theme === "light") setTheme("dark");
|
|
75
|
+
else if (theme === "dark") setTheme("system");
|
|
76
|
+
else setTheme("light");
|
|
77
|
+
};
|
|
78
|
+
const getIcon = () => {
|
|
79
|
+
if (theme === "light") return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(MoonIcon, {});
|
|
80
|
+
if (theme === "dark") return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(SystemIcon, {});
|
|
81
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(SunIcon, {});
|
|
82
|
+
};
|
|
83
|
+
const getTitle = () => {
|
|
84
|
+
if (theme === "light") return "Switch to Dark mode";
|
|
85
|
+
if (theme === "dark") return "Switch to System mode";
|
|
86
|
+
return "Switch to Light mode";
|
|
87
|
+
};
|
|
88
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
|
|
89
|
+
onClick: toggleTheme,
|
|
90
|
+
className: "flex h-9 w-9 items-center justify-center rounded-md border border-gray-200 bg-white text-gray-900 transition-colors hover:bg-gray-50 dark:border-gray-700 dark:bg-gray-900 dark:text-gray-100 dark:hover:bg-gray-800",
|
|
91
|
+
title: getTitle(),
|
|
92
|
+
type: "button",
|
|
93
|
+
children: getIcon()
|
|
94
|
+
});
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
//#endregion
|
|
98
|
+
exports.ThemeToggle = ThemeToggle;
|
package/dist/ThemeToggle.d.cts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react_jsx_runtime5 from "react/jsx-runtime";
|
|
2
2
|
|
|
3
3
|
//#region src/ThemeToggle.d.ts
|
|
4
|
-
declare function ThemeToggle():
|
|
4
|
+
declare function ThemeToggle(): react_jsx_runtime5.JSX.Element;
|
|
5
5
|
//#endregion
|
|
6
6
|
export { ThemeToggle };
|
package/dist/ThemeToggle.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react_jsx_runtime5 from "react/jsx-runtime";
|
|
2
2
|
|
|
3
3
|
//#region src/ThemeToggle.d.ts
|
|
4
|
-
declare function ThemeToggle():
|
|
4
|
+
declare function ThemeToggle(): react_jsx_runtime5.JSX.Element;
|
|
5
5
|
//#endregion
|
|
6
6
|
export { ThemeToggle };
|