@codefast/ui 0.0.8 → 0.0.10
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/accordion.d.mts +8 -4
- package/dist/accordion.d.ts +8 -4
- package/dist/accordion.js +42 -32
- package/dist/accordion.js.map +1 -1
- package/dist/accordion.mjs +42 -32
- package/dist/accordion.mjs.map +1 -1
- package/dist/alert-dialog.d.mts +17 -8
- package/dist/alert-dialog.d.ts +17 -8
- package/dist/alert-dialog.js +47 -75
- package/dist/alert-dialog.js.map +1 -1
- package/dist/alert-dialog.mjs +47 -75
- package/dist/alert-dialog.mjs.map +1 -1
- package/dist/alert.d.mts +10 -5
- package/dist/alert.d.ts +10 -5
- package/dist/alert.js +5 -26
- package/dist/alert.js.map +1 -1
- package/dist/alert.mjs +5 -26
- package/dist/alert.mjs.map +1 -1
- package/dist/aspect-ratio.d.mts +2 -1
- package/dist/aspect-ratio.d.ts +2 -1
- package/dist/aspect-ratio.js.map +1 -1
- package/dist/aspect-ratio.mjs.map +1 -1
- package/dist/avatar.d.mts +7 -4
- package/dist/avatar.d.ts +7 -4
- package/dist/avatar.js +3 -16
- package/dist/avatar.js.map +1 -1
- package/dist/avatar.mjs +3 -16
- package/dist/avatar.mjs.map +1 -1
- package/dist/badge.d.mts +5 -2
- package/dist/badge.d.ts +5 -2
- package/dist/badge.js +1 -5
- package/dist/badge.js.map +1 -1
- package/dist/badge.mjs +1 -5
- package/dist/badge.mjs.map +1 -1
- package/dist/blockquote.d.mts +5 -4
- package/dist/blockquote.d.ts +5 -4
- package/dist/blockquote.js.map +1 -1
- package/dist/blockquote.mjs.map +1 -1
- package/dist/box.d.mts +1 -1
- package/dist/box.d.ts +1 -1
- package/dist/box.js +4 -6
- package/dist/box.js.map +1 -1
- package/dist/box.mjs +4 -6
- package/dist/box.mjs.map +1 -1
- package/dist/breadcrumb.d.mts +18 -11
- package/dist/breadcrumb.d.ts +18 -11
- package/dist/breadcrumb.js +12 -39
- package/dist/breadcrumb.js.map +1 -1
- package/dist/breadcrumb.mjs +12 -39
- package/dist/breadcrumb.mjs.map +1 -1
- package/dist/button.d.mts +4 -2
- package/dist/button.d.ts +4 -2
- package/dist/button.js +3 -2
- package/dist/button.mjs +2 -1
- package/dist/calendar.d.mts +3 -2
- package/dist/calendar.d.ts +3 -2
- package/dist/calendar.js +7 -19
- package/dist/calendar.js.map +1 -1
- package/dist/calendar.mjs +6 -18
- package/dist/calendar.mjs.map +1 -1
- package/dist/card.d.mts +13 -7
- package/dist/card.d.ts +13 -7
- package/dist/card.js +7 -44
- package/dist/card.js.map +1 -1
- package/dist/card.mjs +7 -44
- package/dist/card.mjs.map +1 -1
- package/dist/carousel.d.mts +13 -8
- package/dist/carousel.d.ts +13 -8
- package/dist/carousel.js +104 -104
- package/dist/carousel.js.map +1 -1
- package/dist/carousel.mjs +104 -104
- package/dist/carousel.mjs.map +1 -1
- package/dist/checkbox-cards.d.mts +15 -0
- package/dist/checkbox-cards.d.ts +15 -0
- package/dist/checkbox-cards.js +56 -0
- package/dist/checkbox-cards.js.map +1 -0
- package/dist/checkbox-cards.mjs +56 -0
- package/dist/checkbox-cards.mjs.map +1 -0
- package/dist/checkbox-group.d.mts +13 -0
- package/dist/checkbox-group.d.ts +13 -0
- package/dist/checkbox-group.js +44 -0
- package/dist/checkbox-group.js.map +1 -0
- package/dist/checkbox-group.mjs +44 -0
- package/dist/checkbox-group.mjs.map +1 -0
- package/dist/checkbox-group.primitive.d.mts +38 -0
- package/dist/checkbox-group.primitive.d.ts +38 -0
- package/dist/checkbox-group.primitive.js +19 -0
- package/dist/checkbox-group.primitive.js.map +1 -0
- package/dist/checkbox-group.primitive.mjs +19 -0
- package/dist/checkbox-group.primitive.mjs.map +1 -0
- package/dist/checkbox.d.mts +3 -2
- package/dist/checkbox.d.ts +3 -2
- package/dist/checkbox.js +5 -1
- package/dist/checkbox.js.map +1 -1
- package/dist/checkbox.mjs +5 -1
- package/dist/checkbox.mjs.map +1 -1
- package/dist/chunk-3ZZ3SRTJ.js +148 -0
- package/dist/chunk-3ZZ3SRTJ.js.map +1 -0
- package/dist/chunk-5UHPKXF4.mjs +60 -0
- package/dist/chunk-5UHPKXF4.mjs.map +1 -0
- package/dist/chunk-EWS3N4OZ.mjs +148 -0
- package/dist/chunk-EWS3N4OZ.mjs.map +1 -0
- package/dist/{chunk-PTD4AMHI.mjs → chunk-FGI3JA75.mjs} +1 -1
- package/dist/chunk-FGI3JA75.mjs.map +1 -0
- package/dist/{chunk-RTKEO347.js → chunk-IVYGBU4G.js} +1 -1
- package/dist/chunk-IVYGBU4G.js.map +1 -0
- package/dist/chunk-IXEJO7ZP.js +86 -0
- package/dist/chunk-IXEJO7ZP.js.map +1 -0
- package/dist/chunk-J6COVJTP.js +60 -0
- package/dist/chunk-J6COVJTP.js.map +1 -0
- package/dist/chunk-JULVZPCS.mjs +120 -0
- package/dist/chunk-JULVZPCS.mjs.map +1 -0
- package/dist/chunk-LNSEYAPJ.js +121 -0
- package/dist/chunk-LNSEYAPJ.js.map +1 -0
- package/dist/chunk-MOJNV3XZ.js +120 -0
- package/dist/chunk-MOJNV3XZ.js.map +1 -0
- package/dist/{chunk-U2WDUCW3.js → chunk-NEP3JDVQ.js} +31 -6
- package/dist/chunk-NEP3JDVQ.js.map +1 -0
- package/dist/chunk-OK63Q6EJ.mjs +121 -0
- package/dist/chunk-OK63Q6EJ.mjs.map +1 -0
- package/dist/{chunk-5GHZ6EXI.js → chunk-ORAVN37L.js} +6 -10
- package/dist/chunk-ORAVN37L.js.map +1 -0
- package/dist/{chunk-T52N6ZBP.mjs → chunk-XCBBSHAK.mjs} +6 -10
- package/dist/chunk-XCBBSHAK.mjs.map +1 -0
- package/dist/chunk-XCKLBP2V.mjs +86 -0
- package/dist/chunk-XCKLBP2V.mjs.map +1 -0
- package/dist/chunk-XHZUPL2U.mjs +81 -0
- package/dist/chunk-XHZUPL2U.mjs.map +1 -0
- package/dist/code.d.mts +5 -4
- package/dist/code.d.ts +5 -4
- package/dist/code.js.map +1 -1
- package/dist/code.mjs.map +1 -1
- package/dist/collapsible.d.mts +4 -1
- package/dist/collapsible.d.ts +4 -1
- package/dist/collapsible.js.map +1 -1
- package/dist/collapsible.mjs.map +1 -1
- package/dist/command.d.mts +24 -12
- package/dist/command.d.ts +24 -12
- package/dist/command.js +9 -40
- package/dist/command.js.map +1 -1
- package/dist/command.mjs +9 -40
- package/dist/command.mjs.map +1 -1
- package/dist/container.d.mts +5 -4
- package/dist/container.d.ts +5 -4
- package/dist/container.js.map +1 -1
- package/dist/container.mjs.map +1 -1
- package/dist/context-menu.d.mts +31 -16
- package/dist/context-menu.d.ts +31 -16
- package/dist/context-menu.js +108 -124
- package/dist/context-menu.js.map +1 -1
- package/dist/context-menu.mjs +109 -125
- package/dist/context-menu.mjs.map +1 -1
- package/dist/data-table.d.mts +10 -7
- package/dist/data-table.d.ts +10 -7
- package/dist/data-table.js +131 -149
- package/dist/data-table.js.map +1 -1
- package/dist/data-table.mjs +120 -138
- package/dist/data-table.mjs.map +1 -1
- package/dist/dialog.d.mts +14 -6
- package/dist/dialog.d.ts +14 -6
- package/dist/dialog.js +2 -2
- package/dist/dialog.mjs +1 -1
- package/dist/drawer.d.mts +12 -4
- package/dist/drawer.d.ts +12 -4
- package/dist/drawer.js +30 -63
- package/dist/drawer.js.map +1 -1
- package/dist/drawer.mjs +30 -63
- package/dist/drawer.mjs.map +1 -1
- package/dist/dropdown-menu.d.mts +29 -15
- package/dist/dropdown-menu.d.ts +29 -15
- package/dist/dropdown-menu.js +2 -2
- package/dist/dropdown-menu.mjs +1 -1
- package/dist/em.d.mts +5 -4
- package/dist/em.d.ts +5 -4
- package/dist/em.js.map +1 -1
- package/dist/em.mjs.map +1 -1
- package/dist/form.d.mts +14 -6
- package/dist/form.d.ts +14 -6
- package/dist/form.js +13 -40
- package/dist/form.js.map +1 -1
- package/dist/form.mjs +13 -40
- package/dist/form.mjs.map +1 -1
- package/dist/heading.d.mts +6 -5
- package/dist/heading.d.ts +6 -5
- package/dist/heading.js.map +1 -1
- package/dist/heading.mjs.map +1 -1
- package/dist/hover-card.d.mts +5 -2
- package/dist/hover-card.d.ts +5 -2
- package/dist/hover-card.js +15 -13
- package/dist/hover-card.js.map +1 -1
- package/dist/hover-card.mjs +15 -13
- package/dist/hover-card.mjs.map +1 -1
- package/dist/input-otp.d.mts +12 -32
- package/dist/input-otp.d.ts +12 -32
- package/dist/input-otp.js +16 -13
- package/dist/input-otp.js.map +1 -1
- package/dist/input-otp.mjs +15 -12
- package/dist/input-otp.mjs.map +1 -1
- package/dist/input.d.mts +6 -3
- package/dist/input.d.ts +6 -3
- package/dist/input.js +8 -10
- package/dist/input.js.map +1 -1
- package/dist/input.mjs +8 -10
- package/dist/input.mjs.map +1 -1
- package/dist/kbd.d.mts +5 -4
- package/dist/kbd.d.ts +5 -4
- package/dist/kbd.js.map +1 -1
- package/dist/kbd.mjs.map +1 -1
- package/dist/label.d.mts +3 -2
- package/dist/label.d.ts +3 -2
- package/dist/label.js +2 -2
- package/dist/label.mjs +1 -1
- package/dist/menubar.d.mts +32 -17
- package/dist/menubar.d.ts +32 -17
- package/dist/menubar.js +73 -93
- package/dist/menubar.js.map +1 -1
- package/dist/menubar.mjs +74 -94
- package/dist/menubar.mjs.map +1 -1
- package/dist/navigation-menu.d.mts +16 -8
- package/dist/navigation-menu.d.ts +16 -8
- package/dist/navigation-menu.js +89 -93
- package/dist/navigation-menu.js.map +1 -1
- package/dist/navigation-menu.mjs +89 -93
- package/dist/navigation-menu.mjs.map +1 -1
- package/dist/pagination.d.mts +13 -7
- package/dist/pagination.d.ts +13 -7
- package/dist/pagination.js +18 -55
- package/dist/pagination.js.map +1 -1
- package/dist/pagination.mjs +18 -55
- package/dist/pagination.mjs.map +1 -1
- package/dist/popover.d.mts +8 -3
- package/dist/popover.d.ts +8 -3
- package/dist/popover.js +16 -21
- package/dist/popover.js.map +1 -1
- package/dist/popover.mjs +16 -21
- package/dist/popover.mjs.map +1 -1
- package/dist/pre.d.mts +5 -4
- package/dist/pre.d.ts +5 -4
- package/dist/pre.js.map +1 -1
- package/dist/pre.mjs.map +1 -1
- package/dist/progress.d.mts +3 -2
- package/dist/progress.d.ts +3 -2
- package/dist/progress.js +2 -5
- package/dist/progress.js.map +1 -1
- package/dist/progress.mjs +2 -5
- package/dist/progress.mjs.map +1 -1
- package/dist/quote.d.mts +5 -4
- package/dist/quote.d.ts +5 -4
- package/dist/quote.js.map +1 -1
- package/dist/quote.mjs.map +1 -1
- package/dist/radio-cards.d.mts +9 -0
- package/dist/radio-cards.d.ts +9 -0
- package/dist/radio-cards.js +36 -0
- package/dist/radio-cards.js.map +1 -0
- package/dist/radio-cards.mjs +36 -0
- package/dist/radio-cards.mjs.map +1 -0
- package/dist/radio-group.d.mts +5 -3
- package/dist/radio-group.d.ts +5 -3
- package/dist/radio-group.js +3 -9
- package/dist/radio-group.js.map +1 -1
- package/dist/radio-group.mjs +3 -9
- package/dist/radio-group.mjs.map +1 -1
- package/dist/radio.d.mts +8 -0
- package/dist/radio.d.ts +8 -0
- package/dist/radio.js +35 -0
- package/dist/radio.js.map +1 -0
- package/dist/radio.mjs +35 -0
- package/dist/radio.mjs.map +1 -0
- package/dist/resizable.d.mts +6 -6
- package/dist/resizable.d.ts +6 -6
- package/dist/resizable.js +4 -6
- package/dist/resizable.js.map +1 -1
- package/dist/resizable.mjs +4 -6
- package/dist/resizable.mjs.map +1 -1
- package/dist/scroll-area.d.mts +5 -3
- package/dist/scroll-area.d.ts +5 -3
- package/dist/scroll-area.js +25 -31
- package/dist/scroll-area.js.map +1 -1
- package/dist/scroll-area.mjs +25 -31
- package/dist/scroll-area.mjs.map +1 -1
- package/dist/section.d.mts +5 -4
- package/dist/section.d.ts +5 -4
- package/dist/section.js.map +1 -1
- package/dist/section.mjs.map +1 -1
- package/dist/select.d.mts +18 -8
- package/dist/select.d.ts +18 -8
- package/dist/select.js +2 -2
- package/dist/select.mjs +1 -1
- package/dist/separator.d.mts +3 -2
- package/dist/separator.d.ts +3 -2
- package/dist/separator.js +1 -5
- package/dist/separator.js.map +1 -1
- package/dist/separator.mjs +1 -5
- package/dist/separator.mjs.map +1 -1
- package/dist/sheet.d.mts +20 -10
- package/dist/sheet.d.ts +20 -10
- package/dist/sheet.js +35 -76
- package/dist/sheet.js.map +1 -1
- package/dist/sheet.mjs +35 -76
- package/dist/sheet.mjs.map +1 -1
- package/dist/skeleton.d.mts +3 -2
- package/dist/skeleton.d.ts +3 -2
- package/dist/skeleton.js +2 -11
- package/dist/skeleton.js.map +1 -1
- package/dist/skeleton.mjs +2 -11
- package/dist/skeleton.mjs.map +1 -1
- package/dist/slider.d.mts +3 -2
- package/dist/slider.d.ts +3 -2
- package/dist/slider.js +10 -5
- package/dist/slider.js.map +1 -1
- package/dist/slider.mjs +10 -5
- package/dist/slider.mjs.map +1 -1
- package/dist/sonner.d.mts +1 -1
- package/dist/sonner.d.ts +1 -1
- package/dist/sonner.js +1 -6
- package/dist/sonner.js.map +1 -1
- package/dist/sonner.mjs +1 -6
- package/dist/sonner.mjs.map +1 -1
- package/dist/spinner.d.mts +8 -0
- package/dist/spinner.d.ts +8 -0
- package/dist/spinner.js +8 -0
- package/dist/spinner.js.map +1 -0
- package/dist/spinner.mjs +8 -0
- package/dist/spinner.mjs.map +1 -0
- package/dist/strong.d.mts +5 -4
- package/dist/strong.d.ts +5 -4
- package/dist/strong.js.map +1 -1
- package/dist/strong.mjs.map +1 -1
- package/dist/styles.css +1 -1
- package/dist/styles.css.map +1 -1
- package/dist/switch.d.mts +3 -2
- package/dist/switch.d.ts +3 -2
- package/dist/switch.js +2 -1
- package/dist/switch.js.map +1 -1
- package/dist/switch.mjs +2 -1
- package/dist/switch.mjs.map +1 -1
- package/dist/table.d.mts +17 -9
- package/dist/table.d.ts +17 -9
- package/dist/table.js +6 -47
- package/dist/table.js.map +1 -1
- package/dist/table.mjs +6 -47
- package/dist/table.mjs.map +1 -1
- package/dist/tabs.d.mts +8 -4
- package/dist/tabs.d.ts +8 -4
- package/dist/tabs.js +4 -2
- package/dist/tabs.js.map +1 -1
- package/dist/tabs.mjs +4 -2
- package/dist/tabs.mjs.map +1 -1
- package/dist/text.d.mts +1 -1
- package/dist/text.d.ts +1 -1
- package/dist/text.js +4 -6
- package/dist/text.js.map +1 -1
- package/dist/text.mjs +4 -6
- package/dist/text.mjs.map +1 -1
- package/dist/textarea.d.mts +3 -2
- package/dist/textarea.d.ts +3 -2
- package/dist/textarea.js +2 -1
- package/dist/textarea.js.map +1 -1
- package/dist/textarea.mjs +2 -1
- package/dist/textarea.mjs.map +1 -1
- package/dist/toggle-group.d.mts +5 -3
- package/dist/toggle-group.d.ts +5 -3
- package/dist/toggle-group.js +41 -34
- package/dist/toggle-group.js.map +1 -1
- package/dist/toggle-group.mjs +40 -33
- package/dist/toggle-group.mjs.map +1 -1
- package/dist/toggle.d.mts +3 -2
- package/dist/toggle.d.ts +3 -2
- package/dist/toggle.js +2 -2
- package/dist/toggle.mjs +1 -1
- package/dist/tooltip.d.mts +8 -3
- package/dist/tooltip.d.ts +8 -3
- package/dist/tooltip.js +15 -20
- package/dist/tooltip.js.map +1 -1
- package/dist/tooltip.mjs +15 -20
- package/dist/tooltip.mjs.map +1 -1
- package/package.json +40 -9
- package/src/accordion.tsx +63 -40
- package/src/alert-dialog.tsx +84 -84
- package/src/alert.tsx +25 -32
- package/src/aspect-ratio.tsx +3 -1
- package/src/avatar.tsx +19 -26
- package/src/badge.tsx +8 -9
- package/src/blockquote.tsx +9 -7
- package/src/box.tsx +8 -7
- package/src/breadcrumb.tsx +55 -54
- package/src/button.tsx +44 -15
- package/src/calendar.tsx +8 -23
- package/src/card.tsx +44 -53
- package/src/carousel.tsx +152 -134
- package/src/checkbox-cards.tsx +68 -0
- package/src/checkbox-group.primitive.tsx +199 -0
- package/src/checkbox-group.tsx +57 -0
- package/src/checkbox.tsx +11 -6
- package/src/code.tsx +9 -5
- package/src/collapsible.tsx +12 -1
- package/src/command.tsx +65 -65
- package/src/container.tsx +9 -7
- package/src/context-menu.tsx +184 -160
- package/src/data-table.tsx +43 -48
- package/src/dialog.tsx +68 -71
- package/src/drawer.tsx +59 -67
- package/src/dropdown-menu.tsx +164 -139
- package/src/em.tsx +9 -5
- package/src/form.tsx +61 -69
- package/src/heading.tsx +10 -8
- package/src/hover-card.tsx +30 -18
- package/src/input-otp.tsx +40 -26
- package/src/input.tsx +16 -15
- package/src/kbd.tsx +9 -5
- package/src/label.tsx +6 -5
- package/src/menubar.tsx +154 -139
- package/src/navigation-menu.tsx +118 -102
- package/src/pagination.tsx +39 -49
- package/src/popover.tsx +41 -27
- package/src/pre.tsx +9 -5
- package/src/progress.tsx +8 -10
- package/src/quote.tsx +9 -5
- package/src/radio-cards.tsx +50 -0
- package/src/radio-group.tsx +14 -17
- package/src/radio.tsx +44 -0
- package/src/resizable.tsx +7 -8
- package/src/scroll-area.tsx +33 -37
- package/src/section.tsx +9 -7
- package/src/select.tsx +116 -105
- package/src/separator.tsx +8 -14
- package/src/sheet.tsx +62 -70
- package/src/skeleton.tsx +5 -11
- package/src/slider.tsx +13 -10
- package/src/sonner.tsx +4 -8
- package/src/spinner.tsx +75 -0
- package/src/strong.tsx +9 -5
- package/src/switch.tsx +8 -6
- package/src/table.tsx +54 -64
- package/src/tabs.tsx +30 -15
- package/src/text.tsx +9 -9
- package/src/textarea.tsx +8 -6
- package/src/toggle-group.tsx +59 -48
- package/src/toggle.tsx +12 -13
- package/src/tooltip.tsx +33 -25
- package/dist/chunk-2D7SRYKN.js +0 -135
- package/dist/chunk-2D7SRYKN.js.map +0 -1
- package/dist/chunk-5GHZ6EXI.js.map +0 -1
- package/dist/chunk-EDVCMWDT.mjs +0 -158
- package/dist/chunk-EDVCMWDT.mjs.map +0 -1
- package/dist/chunk-EIHWTXQ4.mjs +0 -112
- package/dist/chunk-EIHWTXQ4.mjs.map +0 -1
- package/dist/chunk-ESWGFN3R.mjs +0 -135
- package/dist/chunk-ESWGFN3R.mjs.map +0 -1
- package/dist/chunk-KW5FJ62U.mjs +0 -56
- package/dist/chunk-KW5FJ62U.mjs.map +0 -1
- package/dist/chunk-LDYBRDAY.js +0 -112
- package/dist/chunk-LDYBRDAY.js.map +0 -1
- package/dist/chunk-OCLLX7EY.js +0 -158
- package/dist/chunk-OCLLX7EY.js.map +0 -1
- package/dist/chunk-PTD4AMHI.mjs.map +0 -1
- package/dist/chunk-RTKEO347.js.map +0 -1
- package/dist/chunk-T52N6ZBP.mjs.map +0 -1
- package/dist/chunk-U2WDUCW3.js.map +0 -1
package/dist/command.d.mts
CHANGED
|
@@ -1,13 +1,16 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { Command as Command$1 } from 'cmdk';
|
|
3
|
+
import { Dialog } from './dialog.mjs';
|
|
4
|
+
import '@radix-ui/react-dialog';
|
|
3
5
|
|
|
6
|
+
type CommandProps = React.ComponentPropsWithoutRef<typeof Command$1>;
|
|
4
7
|
declare const Command: React.ForwardRefExoticComponent<Omit<{
|
|
5
8
|
children?: React.ReactNode;
|
|
6
9
|
} & Pick<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
7
10
|
ref?: React.Ref<HTMLDivElement> | undefined;
|
|
8
11
|
} & {
|
|
9
12
|
asChild?: boolean | undefined;
|
|
10
|
-
}, "key" | keyof React.HTMLAttributes<HTMLDivElement
|
|
13
|
+
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
11
14
|
label?: string | undefined;
|
|
12
15
|
shouldFilter?: boolean | undefined;
|
|
13
16
|
filter?: ((value: string, search: string, keywords?: string[] | undefined) => number) | undefined;
|
|
@@ -18,72 +21,81 @@ declare const Command: React.ForwardRefExoticComponent<Omit<{
|
|
|
18
21
|
disablePointerSelection?: boolean | undefined;
|
|
19
22
|
vimBindings?: boolean | undefined;
|
|
20
23
|
} & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
21
|
-
|
|
24
|
+
type CommandDialogProps = React.ComponentProps<typeof Dialog>;
|
|
25
|
+
declare function CommandDialog({ children, ...props }: CommandDialogProps): React.JSX.Element;
|
|
26
|
+
type CommandInputProps = React.ComponentPropsWithoutRef<typeof Command$1.Input>;
|
|
22
27
|
declare const CommandInput: React.ForwardRefExoticComponent<Omit<Omit<Pick<Pick<React.DetailedHTMLProps<React.InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "key" | keyof React.InputHTMLAttributes<HTMLInputElement>> & {
|
|
23
28
|
ref?: React.Ref<HTMLInputElement> | undefined;
|
|
24
29
|
} & {
|
|
25
30
|
asChild?: boolean | undefined;
|
|
26
|
-
}, "key" | "asChild" | keyof React.InputHTMLAttributes<HTMLInputElement>>, "
|
|
31
|
+
}, "key" | "asChild" | keyof React.InputHTMLAttributes<HTMLInputElement>>, "type" | "value" | "onChange"> & {
|
|
27
32
|
value?: string | undefined;
|
|
28
33
|
onValueChange?: ((search: string) => void) | undefined;
|
|
29
34
|
} & React.RefAttributes<HTMLInputElement>, "ref"> & React.RefAttributes<HTMLInputElement>>;
|
|
35
|
+
type CommandListProps = React.ComponentPropsWithoutRef<typeof Command$1.List>;
|
|
30
36
|
declare const CommandList: React.ForwardRefExoticComponent<Omit<{
|
|
31
37
|
children?: React.ReactNode;
|
|
32
38
|
} & Pick<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
33
39
|
ref?: React.Ref<HTMLDivElement> | undefined;
|
|
34
40
|
} & {
|
|
35
41
|
asChild?: boolean | undefined;
|
|
36
|
-
}, "key" | keyof React.HTMLAttributes<HTMLDivElement
|
|
42
|
+
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
37
43
|
label?: string | undefined;
|
|
38
44
|
} & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
45
|
+
type CommandEmptyProps = React.ComponentPropsWithoutRef<typeof Command$1.Empty>;
|
|
39
46
|
declare const CommandEmpty: React.ForwardRefExoticComponent<Omit<{
|
|
40
47
|
children?: React.ReactNode;
|
|
41
48
|
} & Pick<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
42
49
|
ref?: React.Ref<HTMLDivElement> | undefined;
|
|
43
50
|
} & {
|
|
44
51
|
asChild?: boolean | undefined;
|
|
45
|
-
}, "key" | keyof React.HTMLAttributes<HTMLDivElement
|
|
52
|
+
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>> & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
53
|
+
type CommandGroupProps = React.ComponentPropsWithoutRef<typeof Command$1.Group>;
|
|
46
54
|
declare const CommandGroup: React.ForwardRefExoticComponent<Omit<{
|
|
47
55
|
children?: React.ReactNode;
|
|
48
56
|
} & Omit<Pick<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
49
57
|
ref?: React.Ref<HTMLDivElement> | undefined;
|
|
50
58
|
} & {
|
|
51
59
|
asChild?: boolean | undefined;
|
|
52
|
-
}, "key" | keyof React.HTMLAttributes<HTMLDivElement
|
|
60
|
+
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>>, "value" | "heading"> & {
|
|
53
61
|
heading?: React.ReactNode;
|
|
54
62
|
value?: string | undefined;
|
|
55
63
|
forceMount?: boolean | undefined;
|
|
56
64
|
} & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
65
|
+
type CommandSeparatorProps = React.ComponentPropsWithoutRef<typeof Command$1.Separator>;
|
|
57
66
|
declare const CommandSeparator: React.ForwardRefExoticComponent<Omit<Pick<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
58
67
|
ref?: React.Ref<HTMLDivElement> | undefined;
|
|
59
68
|
} & {
|
|
60
69
|
asChild?: boolean | undefined;
|
|
61
|
-
}, "key" | keyof React.HTMLAttributes<HTMLDivElement
|
|
70
|
+
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
62
71
|
alwaysRender?: boolean | undefined;
|
|
63
72
|
} & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
73
|
+
type CommandItemProps = React.ComponentPropsWithoutRef<typeof Command$1.Item>;
|
|
64
74
|
declare const CommandItem: React.ForwardRefExoticComponent<Omit<{
|
|
65
75
|
children?: React.ReactNode;
|
|
66
76
|
} & Omit<Pick<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
67
77
|
ref?: React.Ref<HTMLDivElement> | undefined;
|
|
68
78
|
} & {
|
|
69
79
|
asChild?: boolean | undefined;
|
|
70
|
-
}, "key" | keyof React.HTMLAttributes<HTMLDivElement
|
|
80
|
+
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>>, "disabled" | "value" | "onSelect"> & {
|
|
71
81
|
disabled?: boolean | undefined;
|
|
72
82
|
onSelect?: ((value: string) => void) | undefined;
|
|
73
83
|
value?: string | undefined;
|
|
74
84
|
keywords?: string[] | undefined;
|
|
75
85
|
forceMount?: boolean | undefined;
|
|
76
86
|
} & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
87
|
+
type CommandLoadingProps = React.ComponentPropsWithoutRef<typeof Command$1.Loading>;
|
|
77
88
|
declare const CommandLoading: React.ForwardRefExoticComponent<Omit<{
|
|
78
89
|
children?: React.ReactNode;
|
|
79
90
|
} & Pick<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
80
91
|
ref?: React.Ref<HTMLDivElement> | undefined;
|
|
81
92
|
} & {
|
|
82
93
|
asChild?: boolean | undefined;
|
|
83
|
-
}, "key" | keyof React.HTMLAttributes<HTMLDivElement
|
|
94
|
+
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
84
95
|
progress?: number | undefined;
|
|
85
96
|
label?: string | undefined;
|
|
86
97
|
} & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
87
|
-
|
|
98
|
+
type CommandShortcutProps = React.HTMLAttributes<HTMLSpanElement>;
|
|
99
|
+
declare function CommandShortcut({ className, ...props }: CommandShortcutProps): React.JSX.Element;
|
|
88
100
|
|
|
89
|
-
export { Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandLoading, CommandSeparator, CommandShortcut };
|
|
101
|
+
export { Command, CommandDialog, type CommandDialogProps, CommandEmpty, type CommandEmptyProps, CommandGroup, type CommandGroupProps, CommandInput, type CommandInputProps, CommandItem, type CommandItemProps, CommandList, type CommandListProps, CommandLoading, type CommandLoadingProps, type CommandProps, CommandSeparator, type CommandSeparatorProps, CommandShortcut, type CommandShortcutProps };
|
package/dist/command.d.ts
CHANGED
|
@@ -1,13 +1,16 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { Command as Command$1 } from 'cmdk';
|
|
3
|
+
import { Dialog } from './dialog.js';
|
|
4
|
+
import '@radix-ui/react-dialog';
|
|
3
5
|
|
|
6
|
+
type CommandProps = React.ComponentPropsWithoutRef<typeof Command$1>;
|
|
4
7
|
declare const Command: React.ForwardRefExoticComponent<Omit<{
|
|
5
8
|
children?: React.ReactNode;
|
|
6
9
|
} & Pick<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
7
10
|
ref?: React.Ref<HTMLDivElement> | undefined;
|
|
8
11
|
} & {
|
|
9
12
|
asChild?: boolean | undefined;
|
|
10
|
-
}, "key" | keyof React.HTMLAttributes<HTMLDivElement
|
|
13
|
+
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
11
14
|
label?: string | undefined;
|
|
12
15
|
shouldFilter?: boolean | undefined;
|
|
13
16
|
filter?: ((value: string, search: string, keywords?: string[] | undefined) => number) | undefined;
|
|
@@ -18,72 +21,81 @@ declare const Command: React.ForwardRefExoticComponent<Omit<{
|
|
|
18
21
|
disablePointerSelection?: boolean | undefined;
|
|
19
22
|
vimBindings?: boolean | undefined;
|
|
20
23
|
} & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
21
|
-
|
|
24
|
+
type CommandDialogProps = React.ComponentProps<typeof Dialog>;
|
|
25
|
+
declare function CommandDialog({ children, ...props }: CommandDialogProps): React.JSX.Element;
|
|
26
|
+
type CommandInputProps = React.ComponentPropsWithoutRef<typeof Command$1.Input>;
|
|
22
27
|
declare const CommandInput: React.ForwardRefExoticComponent<Omit<Omit<Pick<Pick<React.DetailedHTMLProps<React.InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "key" | keyof React.InputHTMLAttributes<HTMLInputElement>> & {
|
|
23
28
|
ref?: React.Ref<HTMLInputElement> | undefined;
|
|
24
29
|
} & {
|
|
25
30
|
asChild?: boolean | undefined;
|
|
26
|
-
}, "key" | "asChild" | keyof React.InputHTMLAttributes<HTMLInputElement>>, "
|
|
31
|
+
}, "key" | "asChild" | keyof React.InputHTMLAttributes<HTMLInputElement>>, "type" | "value" | "onChange"> & {
|
|
27
32
|
value?: string | undefined;
|
|
28
33
|
onValueChange?: ((search: string) => void) | undefined;
|
|
29
34
|
} & React.RefAttributes<HTMLInputElement>, "ref"> & React.RefAttributes<HTMLInputElement>>;
|
|
35
|
+
type CommandListProps = React.ComponentPropsWithoutRef<typeof Command$1.List>;
|
|
30
36
|
declare const CommandList: React.ForwardRefExoticComponent<Omit<{
|
|
31
37
|
children?: React.ReactNode;
|
|
32
38
|
} & Pick<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
33
39
|
ref?: React.Ref<HTMLDivElement> | undefined;
|
|
34
40
|
} & {
|
|
35
41
|
asChild?: boolean | undefined;
|
|
36
|
-
}, "key" | keyof React.HTMLAttributes<HTMLDivElement
|
|
42
|
+
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
37
43
|
label?: string | undefined;
|
|
38
44
|
} & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
45
|
+
type CommandEmptyProps = React.ComponentPropsWithoutRef<typeof Command$1.Empty>;
|
|
39
46
|
declare const CommandEmpty: React.ForwardRefExoticComponent<Omit<{
|
|
40
47
|
children?: React.ReactNode;
|
|
41
48
|
} & Pick<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
42
49
|
ref?: React.Ref<HTMLDivElement> | undefined;
|
|
43
50
|
} & {
|
|
44
51
|
asChild?: boolean | undefined;
|
|
45
|
-
}, "key" | keyof React.HTMLAttributes<HTMLDivElement
|
|
52
|
+
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>> & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
53
|
+
type CommandGroupProps = React.ComponentPropsWithoutRef<typeof Command$1.Group>;
|
|
46
54
|
declare const CommandGroup: React.ForwardRefExoticComponent<Omit<{
|
|
47
55
|
children?: React.ReactNode;
|
|
48
56
|
} & Omit<Pick<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
49
57
|
ref?: React.Ref<HTMLDivElement> | undefined;
|
|
50
58
|
} & {
|
|
51
59
|
asChild?: boolean | undefined;
|
|
52
|
-
}, "key" | keyof React.HTMLAttributes<HTMLDivElement
|
|
60
|
+
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>>, "value" | "heading"> & {
|
|
53
61
|
heading?: React.ReactNode;
|
|
54
62
|
value?: string | undefined;
|
|
55
63
|
forceMount?: boolean | undefined;
|
|
56
64
|
} & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
65
|
+
type CommandSeparatorProps = React.ComponentPropsWithoutRef<typeof Command$1.Separator>;
|
|
57
66
|
declare const CommandSeparator: React.ForwardRefExoticComponent<Omit<Pick<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
58
67
|
ref?: React.Ref<HTMLDivElement> | undefined;
|
|
59
68
|
} & {
|
|
60
69
|
asChild?: boolean | undefined;
|
|
61
|
-
}, "key" | keyof React.HTMLAttributes<HTMLDivElement
|
|
70
|
+
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
62
71
|
alwaysRender?: boolean | undefined;
|
|
63
72
|
} & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
73
|
+
type CommandItemProps = React.ComponentPropsWithoutRef<typeof Command$1.Item>;
|
|
64
74
|
declare const CommandItem: React.ForwardRefExoticComponent<Omit<{
|
|
65
75
|
children?: React.ReactNode;
|
|
66
76
|
} & Omit<Pick<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
67
77
|
ref?: React.Ref<HTMLDivElement> | undefined;
|
|
68
78
|
} & {
|
|
69
79
|
asChild?: boolean | undefined;
|
|
70
|
-
}, "key" | keyof React.HTMLAttributes<HTMLDivElement
|
|
80
|
+
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>>, "disabled" | "value" | "onSelect"> & {
|
|
71
81
|
disabled?: boolean | undefined;
|
|
72
82
|
onSelect?: ((value: string) => void) | undefined;
|
|
73
83
|
value?: string | undefined;
|
|
74
84
|
keywords?: string[] | undefined;
|
|
75
85
|
forceMount?: boolean | undefined;
|
|
76
86
|
} & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
87
|
+
type CommandLoadingProps = React.ComponentPropsWithoutRef<typeof Command$1.Loading>;
|
|
77
88
|
declare const CommandLoading: React.ForwardRefExoticComponent<Omit<{
|
|
78
89
|
children?: React.ReactNode;
|
|
79
90
|
} & Pick<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
80
91
|
ref?: React.Ref<HTMLDivElement> | undefined;
|
|
81
92
|
} & {
|
|
82
93
|
asChild?: boolean | undefined;
|
|
83
|
-
}, "key" | keyof React.HTMLAttributes<HTMLDivElement
|
|
94
|
+
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
84
95
|
progress?: number | undefined;
|
|
85
96
|
label?: string | undefined;
|
|
86
97
|
} & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
87
|
-
|
|
98
|
+
type CommandShortcutProps = React.HTMLAttributes<HTMLSpanElement>;
|
|
99
|
+
declare function CommandShortcut({ className, ...props }: CommandShortcutProps): React.JSX.Element;
|
|
88
100
|
|
|
89
|
-
export { Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandLoading, CommandSeparator, CommandShortcut };
|
|
101
|
+
export { Command, CommandDialog, type CommandDialogProps, CommandEmpty, type CommandEmptyProps, CommandGroup, type CommandGroupProps, CommandInput, type CommandInputProps, CommandItem, type CommandItemProps, CommandList, type CommandListProps, CommandLoading, type CommandLoadingProps, type CommandProps, CommandSeparator, type CommandSeparatorProps, CommandShortcut, type CommandShortcutProps };
|
package/dist/command.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
|
|
5
|
-
var
|
|
5
|
+
var _chunkIXEJO7ZPjs = require('./chunk-IXEJO7ZP.js');
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
var _chunkG3NP7M2Njs = require('./chunk-G3NP7M2N.js');
|
|
@@ -25,7 +25,7 @@ var Command = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */
|
|
|
25
25
|
));
|
|
26
26
|
Command.displayName = _cmdk.Command.displayName;
|
|
27
27
|
function CommandDialog({ children, ...props }) {
|
|
28
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
28
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkIXEJO7ZPjs.Dialog, { ...props, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkIXEJO7ZPjs.DialogContent, { className: "p-0", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Command, { className: "[&_[cmdk-group-heading]]:text-muted-foreground focus:outline-none [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-group]]:px-2 [&_[cmdk-input-wrapper]_svg]:size-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:size-5", children }) }) });
|
|
29
29
|
}
|
|
30
30
|
var CommandInput = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-2 border-b px-3", "cmdk-input-wrapper": "", children: [
|
|
31
31
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _reacticons.MagnifyingGlassIcon, { className: "size-4 shrink-0 opacity-50" }),
|
|
@@ -51,14 +51,7 @@ var CommandList = React.forwardRef(({ className, ...props }, ref) => /* @__PURE_
|
|
|
51
51
|
}
|
|
52
52
|
));
|
|
53
53
|
CommandList.displayName = _cmdk.Command.List.displayName;
|
|
54
|
-
var CommandEmpty = React.forwardRef((props, ref) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
55
|
-
_cmdk.Command.Empty,
|
|
56
|
-
{
|
|
57
|
-
ref,
|
|
58
|
-
className: "py-6 text-center text-sm",
|
|
59
|
-
...props
|
|
60
|
-
}
|
|
61
|
-
));
|
|
54
|
+
var CommandEmpty = React.forwardRef((props, ref) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _cmdk.Command.Empty, { ref, className: "py-6 text-center text-sm", ...props }));
|
|
62
55
|
CommandEmpty.displayName = _cmdk.Command.Empty.displayName;
|
|
63
56
|
var CommandGroup = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
64
57
|
_cmdk.Command.Group,
|
|
@@ -72,14 +65,9 @@ var CommandGroup = React.forwardRef(({ className, ...props }, ref) => /* @__PURE
|
|
|
72
65
|
}
|
|
73
66
|
));
|
|
74
67
|
CommandGroup.displayName = _cmdk.Command.Group.displayName;
|
|
75
|
-
var CommandSeparator = React.forwardRef(
|
|
76
|
-
_cmdk.Command.Separator,
|
|
77
|
-
|
|
78
|
-
ref,
|
|
79
|
-
className: _chunkG3NP7M2Njs.cn.call(void 0, "bg-border -mx-1 h-px", className),
|
|
80
|
-
...props
|
|
81
|
-
}
|
|
82
|
-
));
|
|
68
|
+
var CommandSeparator = React.forwardRef(
|
|
69
|
+
({ className, ...props }, ref) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _cmdk.Command.Separator, { ref, className: _chunkG3NP7M2Njs.cn.call(void 0, "bg-border -mx-1 h-px", className), ...props })
|
|
70
|
+
);
|
|
83
71
|
CommandSeparator.displayName = _cmdk.Command.Separator.displayName;
|
|
84
72
|
var CommandItem = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
85
73
|
_cmdk.Command.Item,
|
|
@@ -93,29 +81,10 @@ var CommandItem = React.forwardRef(({ className, ...props }, ref) => /* @__PURE_
|
|
|
93
81
|
}
|
|
94
82
|
));
|
|
95
83
|
CommandItem.displayName = _cmdk.Command.Item.displayName;
|
|
96
|
-
var CommandLoading = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
97
|
-
_cmdk.Command.Loading,
|
|
98
|
-
{
|
|
99
|
-
ref,
|
|
100
|
-
className: _chunkG3NP7M2Njs.cn.call(void 0, "flex justify-center p-2", className),
|
|
101
|
-
...props
|
|
102
|
-
}
|
|
103
|
-
));
|
|
84
|
+
var CommandLoading = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _cmdk.Command.Loading, { ref, className: _chunkG3NP7M2Njs.cn.call(void 0, "flex justify-center p-2", className), ...props }));
|
|
104
85
|
CommandLoading.displayName = _cmdk.Command.Loading.displayName;
|
|
105
|
-
function CommandShortcut({
|
|
106
|
-
className,
|
|
107
|
-
...props
|
|
108
|
-
}) {
|
|
109
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
110
|
-
"span",
|
|
111
|
-
{
|
|
112
|
-
className: _chunkG3NP7M2Njs.cn.call(void 0,
|
|
113
|
-
"text-muted-foreground ml-auto text-xs tracking-widest",
|
|
114
|
-
className
|
|
115
|
-
),
|
|
116
|
-
...props
|
|
117
|
-
}
|
|
118
|
-
);
|
|
86
|
+
function CommandShortcut({ className, ...props }) {
|
|
87
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: _chunkG3NP7M2Njs.cn.call(void 0, "text-muted-foreground ml-auto text-xs tracking-widest", className), ...props });
|
|
119
88
|
}
|
|
120
89
|
|
|
121
90
|
|
package/dist/command.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/command.tsx"],"names":[],"mappings":";;;;;;;;;;AAEA,YAAY,WAAW;AAEvB,SAAS,2BAA2B;AACpC,SAAS,WAAW,wBAAwB;AAY1C,cAmCA,YAnCA;AAJF,IAAM,UAAgB,iBAGpB,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAC1B;AAAA,EAAC;AAAA;AAAA,IACC;AAAA,IACA,WAAW;AAAA,MACT;AAAA,MACA;AAAA,IACF;AAAA,IACC,GAAG;AAAA;AACN,CACD;AACD,QAAQ,cAAc,iBAAiB;AAMvC,SAAS,cAAc,EAAE,UAAU,GAAG,MAAM,GAAmC;AAC7E,SACE,oBAAC,UAAQ,GAAG,OACV,8BAAC,iBAAc,WAAU,uBACvB,8BAAC,WAAQ,WAAU,4TAChB,UACH,GACF,GACF;AAEJ;AAMA,IAAM,eAAqB,iBAGzB,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAC1B,qBAAC,SAAI,WAAU,yCAAwC,sBAAmB,IACxE;AAAA,sBAAC,uBAAoB,WAAU,8BAA6B;AAAA,EAC5D;AAAA,IAAC,iBAAiB;AAAA,IAAjB;AAAA,MACC;AAAA,MACA,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA;AAAA,EACN;AAAA,GACF,CACD;AACD,aAAa,cAAc,iBAAiB,MAAM;AAMlD,IAAM,cAAoB,iBAGxB,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAC1B;AAAA,EAAC,iBAAiB;AAAA,EAAjB;AAAA,IACC;AAAA,IACA,WAAW,GAAG,mDAAmD,SAAS;AAAA,IACzE,GAAG;AAAA;AACN,CACD;AACD,YAAY,cAAc,iBAAiB,KAAK;AAMhD,IAAM,eAAqB,iBAGzB,CAAC,OAAO,QACR;AAAA,EAAC,iBAAiB;AAAA,EAAjB;AAAA,IACC;AAAA,IACA,WAAU;AAAA,IACT,GAAG;AAAA;AACN,CACD;AACD,aAAa,cAAc,iBAAiB,MAAM;AAMlD,IAAM,eAAqB,iBAGzB,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAC1B;AAAA,EAAC,iBAAiB;AAAA,EAAjB;AAAA,IACC;AAAA,IACA,WAAW;AAAA,MACT;AAAA,MACA;AAAA,IACF;AAAA,IACC,GAAG;AAAA;AACN,CACD;AACD,aAAa,cAAc,iBAAiB,MAAM;AAMlD,IAAM,mBAAyB,iBAG7B,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAC1B;AAAA,EAAC,iBAAiB;AAAA,EAAjB;AAAA,IACC;AAAA,IACA,WAAW,GAAG,wBAAwB,SAAS;AAAA,IAC9C,GAAG;AAAA;AACN,CACD;AACD,iBAAiB,cAAc,iBAAiB,UAAU;AAM1D,IAAM,cAAoB,iBAGxB,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAC1B;AAAA,EAAC,iBAAiB;AAAA,EAAjB;AAAA,IACC;AAAA,IACA,WAAW;AAAA,MACT;AAAA,MACA;AAAA,IACF;AAAA,IACC,GAAG;AAAA;AACN,CACD;AACD,YAAY,cAAc,iBAAiB,KAAK;AAMhD,IAAM,iBAAuB,iBAG3B,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAC1B;AAAA,EAAC,iBAAiB;AAAA,EAAjB;AAAA,IACC;AAAA,IACA,WAAW,GAAG,2BAA2B,SAAS;AAAA,IACjD,GAAG;AAAA;AACN,CACD;AACD,eAAe,cAAc,iBAAiB,QAAQ;AAMtD,SAAS,gBAAgB;AAAA,EACvB;AAAA,EACA,GAAG;AACL,GAA6D;AAC3D,SACE;AAAA,IAAC;AAAA;AAAA,MACC,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA;AAAA,EACN;AAEJ","sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport { type DialogProps } from \"@radix-ui/react-dialog\";\nimport { MagnifyingGlassIcon } from \"@radix-ui/react-icons\";\nimport { Command as CommandPrimitive } from \"cmdk\";\nimport { cn } from \"./utils\";\nimport { Dialog, DialogContent } from \"./dialog\";\n\n/* -----------------------------------------------------------------------------\n * Component: Command\n * -------------------------------------------------------------------------- */\n\nconst Command = React.forwardRef<\n React.ElementRef<typeof CommandPrimitive>,\n React.ComponentPropsWithoutRef<typeof CommandPrimitive>\n>(({ className, ...props }, ref) => (\n <CommandPrimitive\n ref={ref}\n className={cn(\n \"bg-popover text-popover-foreground flex h-full w-full flex-col overflow-hidden rounded-md\",\n className,\n )}\n {...props}\n />\n));\nCommand.displayName = CommandPrimitive.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandDialog\n * -------------------------------------------------------------------------- */\n\nfunction CommandDialog({ children, ...props }: DialogProps): React.JSX.Element {\n return (\n <Dialog {...props}>\n <DialogContent className=\"overflow-hidden p-0\">\n <Command className=\"[&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-group]]:px-2 [&_[cmdk-input-wrapper]_svg]:size-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:size-5\">\n {children}\n </Command>\n </DialogContent>\n </Dialog>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: CommandInput\n * -------------------------------------------------------------------------- */\n\nconst CommandInput = React.forwardRef<\n React.ElementRef<typeof CommandPrimitive.Input>,\n React.ComponentPropsWithoutRef<typeof CommandPrimitive.Input>\n>(({ className, ...props }, ref) => (\n <div className=\"flex items-center gap-2 border-b px-3\" cmdk-input-wrapper=\"\">\n <MagnifyingGlassIcon className=\"size-4 shrink-0 opacity-50\" />\n <CommandPrimitive.Input\n ref={ref}\n className={cn(\n \"placeholder:text-muted-foreground flex h-10 w-full rounded-md bg-transparent text-sm focus:outline-none disabled:cursor-not-allowed disabled:opacity-50\",\n className,\n )}\n {...props}\n />\n </div>\n));\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandList\n * -------------------------------------------------------------------------- */\n\nconst CommandList = React.forwardRef<\n React.ElementRef<typeof CommandPrimitive.List>,\n React.ComponentPropsWithoutRef<typeof CommandPrimitive.List>\n>(({ className, ...props }, ref) => (\n <CommandPrimitive.List\n ref={ref}\n className={cn(\"max-h-[300px] overflow-y-auto overflow-x-hidden\", className)}\n {...props}\n />\n));\nCommandList.displayName = CommandPrimitive.List.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandEmpty\n * -------------------------------------------------------------------------- */\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef<typeof CommandPrimitive.Empty>,\n React.ComponentPropsWithoutRef<typeof CommandPrimitive.Empty>\n>((props, ref) => (\n <CommandPrimitive.Empty\n ref={ref}\n className=\"py-6 text-center text-sm\"\n {...props}\n />\n));\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandGroup\n * -------------------------------------------------------------------------- */\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef<typeof CommandPrimitive.Group>,\n React.ComponentPropsWithoutRef<typeof CommandPrimitive.Group>\n>(({ className, ...props }, ref) => (\n <CommandPrimitive.Group\n ref={ref}\n className={cn(\n \"text-foreground [&_[cmdk-group-heading]]:text-muted-foreground overflow-hidden p-1 [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium\",\n className,\n )}\n {...props}\n />\n));\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandSeparator\n * -------------------------------------------------------------------------- */\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef<typeof CommandPrimitive.Separator>,\n React.ComponentPropsWithoutRef<typeof CommandPrimitive.Separator>\n>(({ className, ...props }, ref) => (\n <CommandPrimitive.Separator\n ref={ref}\n className={cn(\"bg-border -mx-1 h-px\", className)}\n {...props}\n />\n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandItem\n * -------------------------------------------------------------------------- */\n\nconst CommandItem = React.forwardRef<\n React.ElementRef<typeof CommandPrimitive.Item>,\n React.ComponentPropsWithoutRef<typeof CommandPrimitive.Item>\n>(({ className, ...props }, ref) => (\n <CommandPrimitive.Item\n ref={ref}\n className={cn(\n \"aria-selected:bg-accent aria-selected:text-accent-foreground relative flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm focus:outline-none aria-disabled:pointer-events-none aria-disabled:opacity-50\",\n className,\n )}\n {...props}\n />\n));\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandLoading\n * -------------------------------------------------------------------------- */\n\nconst CommandLoading = React.forwardRef<\n React.ElementRef<typeof CommandPrimitive.Loading>,\n React.ComponentPropsWithoutRef<typeof CommandPrimitive.Loading>\n>(({ className, ...props }, ref) => (\n <CommandPrimitive.Loading\n ref={ref}\n className={cn(\"flex justify-center p-2\", className)}\n {...props}\n />\n));\nCommandLoading.displayName = CommandPrimitive.Loading.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandShortcut\n * -------------------------------------------------------------------------- */\n\nfunction CommandShortcut({\n className,\n ...props\n}: React.HTMLAttributes<HTMLSpanElement>): React.JSX.Element {\n return (\n <span\n className={cn(\n \"text-muted-foreground ml-auto text-xs tracking-widest\",\n className,\n )}\n {...props}\n />\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandLoading,\n CommandShortcut,\n CommandSeparator,\n};\n"]}
|
|
1
|
+
{"version":3,"sources":["../src/command.tsx"],"names":[],"mappings":";;;;;;;;;;AAEA,YAAY,WAAW;AACvB,SAAS,2BAA2B;AACpC,SAAS,WAAW,wBAAwB;AAY1C,cAsCA,YAtCA;AADF,IAAM,UAAgB,iBAAyC,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACvF;AAAA,EAAC;AAAA;AAAA,IACC;AAAA,IACA,WAAW;AAAA,MACT;AAAA,MACA;AAAA,IACF;AAAA,IACC,GAAG;AAAA;AACN,CACD;AAED,QAAQ,cAAc,iBAAiB;AAQvC,SAAS,cAAc,EAAE,UAAU,GAAG,MAAM,GAA0C;AACpF,SACE,oBAAC,UAAQ,GAAG,OACV,8BAAC,iBAAc,WAAU,OACvB,8BAAC,WAAQ,WAAU,+UAChB,UACH,GACF,GACF;AAEJ;AASA,IAAM,eAAqB,iBAAmD,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACtG,qBAAC,SAAI,WAAU,yCAAwC,sBAAmB,IACxE;AAAA,sBAAC,uBAAoB,WAAU,8BAA6B;AAAA,EAC5D;AAAA,IAAC,iBAAiB;AAAA,IAAjB;AAAA,MACC;AAAA,MACA,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA;AAAA,EACN;AAAA,GACF,CACD;AAED,aAAa,cAAc,iBAAiB,MAAM;AASlD,IAAM,cAAoB,iBAAiD,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACnG;AAAA,EAAC,iBAAiB;AAAA,EAAjB;AAAA,IACC;AAAA,IACA,WAAW,GAAG,mDAAmD,SAAS;AAAA,IACzE,GAAG;AAAA;AACN,CACD;AAED,YAAY,cAAc,iBAAiB,KAAK;AAShD,IAAM,eAAqB,iBAAmD,CAAC,OAAO,QACpF,oBAAC,iBAAiB,OAAjB,EAAuB,KAAU,WAAU,4BAA4B,GAAG,OAAO,CACnF;AAED,aAAa,cAAc,iBAAiB,MAAM;AASlD,IAAM,eAAqB,iBAAmD,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACtG;AAAA,EAAC,iBAAiB;AAAA,EAAjB;AAAA,IACC;AAAA,IACA,WAAW;AAAA,MACT;AAAA,MACA;AAAA,IACF;AAAA,IACC,GAAG;AAAA;AACN,CACD;AAED,aAAa,cAAc,iBAAiB,MAAM;AASlD,IAAM,mBAAyB;AAAA,EAC7B,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB,oBAAC,iBAAiB,WAAjB,EAA2B,KAAU,WAAW,GAAG,wBAAwB,SAAS,GAAI,GAAG,OAAO;AAEvG;AAEA,iBAAiB,cAAc,iBAAiB,UAAU;AAS1D,IAAM,cAAoB,iBAAiD,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACnG;AAAA,EAAC,iBAAiB;AAAA,EAAjB;AAAA,IACC;AAAA,IACA,WAAW;AAAA,MACT;AAAA,MACA;AAAA,IACF;AAAA,IACC,GAAG;AAAA;AACN,CACD;AAED,YAAY,cAAc,iBAAiB,KAAK;AAShD,IAAM,iBAAuB,iBAAuD,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAC5G,oBAAC,iBAAiB,SAAjB,EAAyB,KAAU,WAAW,GAAG,2BAA2B,SAAS,GAAI,GAAG,OAAO,CACrG;AAED,eAAe,cAAc,iBAAiB,QAAQ;AAQtD,SAAS,gBAAgB,EAAE,WAAW,GAAG,MAAM,GAA4C;AACzF,SAAO,oBAAC,UAAK,WAAW,GAAG,yDAAyD,SAAS,GAAI,GAAG,OAAO;AAC7G","sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport { MagnifyingGlassIcon } from \"@radix-ui/react-icons\";\nimport { Command as CommandPrimitive } from \"cmdk\";\nimport { cn } from \"./utils\";\nimport { Dialog, DialogContent } from \"./dialog\";\n\n/* -----------------------------------------------------------------------------\n * Component: Command\n * -------------------------------------------------------------------------- */\n\ntype CommandElement = React.ElementRef<typeof CommandPrimitive>;\ntype CommandProps = React.ComponentPropsWithoutRef<typeof CommandPrimitive>;\n\nconst Command = React.forwardRef<CommandElement, CommandProps>(({ className, ...props }, ref) => (\n <CommandPrimitive\n ref={ref}\n className={cn(\n \"bg-popover text-popover-foreground flex h-full w-full flex-col overflow-hidden rounded-md\",\n className,\n )}\n {...props}\n />\n));\n\nCommand.displayName = CommandPrimitive.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandDialog\n * -------------------------------------------------------------------------- */\n\ntype CommandDialogProps = React.ComponentProps<typeof Dialog>;\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps): React.JSX.Element {\n return (\n <Dialog {...props}>\n <DialogContent className=\"p-0\">\n <Command className=\"[&_[cmdk-group-heading]]:text-muted-foreground focus:outline-none [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-group]]:px-2 [&_[cmdk-input-wrapper]_svg]:size-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:size-5\">\n {children}\n </Command>\n </DialogContent>\n </Dialog>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: CommandInput\n * -------------------------------------------------------------------------- */\n\ntype CommandInputElement = React.ElementRef<typeof CommandPrimitive.Input>;\ntype CommandInputProps = React.ComponentPropsWithoutRef<typeof CommandPrimitive.Input>;\n\nconst CommandInput = React.forwardRef<CommandInputElement, CommandInputProps>(({ className, ...props }, ref) => (\n <div className=\"flex items-center gap-2 border-b px-3\" cmdk-input-wrapper=\"\">\n <MagnifyingGlassIcon className=\"size-4 shrink-0 opacity-50\" />\n <CommandPrimitive.Input\n ref={ref}\n className={cn(\n \"placeholder:text-muted-foreground flex h-10 w-full rounded-md bg-transparent text-sm focus:outline-none disabled:cursor-not-allowed disabled:opacity-50\",\n className,\n )}\n {...props}\n />\n </div>\n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandList\n * -------------------------------------------------------------------------- */\n\ntype CommandListElement = React.ElementRef<typeof CommandPrimitive.List>;\ntype CommandListProps = React.ComponentPropsWithoutRef<typeof CommandPrimitive.List>;\n\nconst CommandList = React.forwardRef<CommandListElement, CommandListProps>(({ className, ...props }, ref) => (\n <CommandPrimitive.List\n ref={ref}\n className={cn(\"max-h-[300px] overflow-y-auto overflow-x-hidden\", className)}\n {...props}\n />\n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandEmpty\n * -------------------------------------------------------------------------- */\n\ntype CommandEmptyElement = React.ElementRef<typeof CommandPrimitive.Empty>;\ntype CommandEmptyProps = React.ComponentPropsWithoutRef<typeof CommandPrimitive.Empty>;\n\nconst CommandEmpty = React.forwardRef<CommandEmptyElement, CommandEmptyProps>((props, ref) => (\n <CommandPrimitive.Empty ref={ref} className=\"py-6 text-center text-sm\" {...props} />\n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandGroup\n * -------------------------------------------------------------------------- */\n\ntype CommandGroupElement = React.ElementRef<typeof CommandPrimitive.Group>;\ntype CommandGroupProps = React.ComponentPropsWithoutRef<typeof CommandPrimitive.Group>;\n\nconst CommandGroup = React.forwardRef<CommandGroupElement, CommandGroupProps>(({ className, ...props }, ref) => (\n <CommandPrimitive.Group\n ref={ref}\n className={cn(\n \"text-foreground [&_[cmdk-group-heading]]:text-muted-foreground overflow-hidden p-1 [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium\",\n className,\n )}\n {...props}\n />\n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandSeparator\n * -------------------------------------------------------------------------- */\n\ntype CommandSeparatorElement = React.ElementRef<typeof CommandPrimitive.Separator>;\ntype CommandSeparatorProps = React.ComponentPropsWithoutRef<typeof CommandPrimitive.Separator>;\n\nconst CommandSeparator = React.forwardRef<CommandSeparatorElement, CommandSeparatorProps>(\n ({ className, ...props }, ref) => (\n <CommandPrimitive.Separator ref={ref} className={cn(\"bg-border -mx-1 h-px\", className)} {...props} />\n ),\n);\n\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandItem\n * -------------------------------------------------------------------------- */\n\ntype CommandItemElement = React.ElementRef<typeof CommandPrimitive.Item>;\ntype CommandItemProps = React.ComponentPropsWithoutRef<typeof CommandPrimitive.Item>;\n\nconst CommandItem = React.forwardRef<CommandItemElement, CommandItemProps>(({ className, ...props }, ref) => (\n <CommandPrimitive.Item\n ref={ref}\n className={cn(\n \"aria-selected:bg-accent aria-selected:text-accent-foreground relative flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm focus:outline-none aria-disabled:pointer-events-none aria-disabled:opacity-50\",\n className,\n )}\n {...props}\n />\n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandLoading\n * -------------------------------------------------------------------------- */\n\ntype CommandLoadingElement = React.ElementRef<typeof CommandPrimitive.Loading>;\ntype CommandLoadingProps = React.ComponentPropsWithoutRef<typeof CommandPrimitive.Loading>;\n\nconst CommandLoading = React.forwardRef<CommandLoadingElement, CommandLoadingProps>(({ className, ...props }, ref) => (\n <CommandPrimitive.Loading ref={ref} className={cn(\"flex justify-center p-2\", className)} {...props} />\n));\n\nCommandLoading.displayName = CommandPrimitive.Loading.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandShortcut\n * -------------------------------------------------------------------------- */\n\ntype CommandShortcutProps = React.HTMLAttributes<HTMLSpanElement>;\n\nfunction CommandShortcut({ className, ...props }: CommandShortcutProps): React.JSX.Element {\n return <span className={cn(\"text-muted-foreground ml-auto text-xs tracking-widest\", className)} {...props} />;\n}\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandLoading,\n CommandShortcut,\n CommandSeparator,\n type CommandProps,\n type CommandDialogProps,\n type CommandInputProps,\n type CommandListProps,\n type CommandEmptyProps,\n type CommandGroupProps,\n type CommandItemProps,\n type CommandLoadingProps,\n type CommandShortcutProps,\n type CommandSeparatorProps,\n};\n"]}
|
package/dist/command.mjs
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import {
|
|
3
3
|
Dialog,
|
|
4
4
|
DialogContent
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-XCKLBP2V.mjs";
|
|
6
6
|
import {
|
|
7
7
|
cn
|
|
8
8
|
} from "./chunk-UG3URV2Z.mjs";
|
|
@@ -25,7 +25,7 @@ var Command = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */
|
|
|
25
25
|
));
|
|
26
26
|
Command.displayName = CommandPrimitive.displayName;
|
|
27
27
|
function CommandDialog({ children, ...props }) {
|
|
28
|
-
return /* @__PURE__ */ jsx(Dialog, { ...props, children: /* @__PURE__ */ jsx(DialogContent, { className: "
|
|
28
|
+
return /* @__PURE__ */ jsx(Dialog, { ...props, children: /* @__PURE__ */ jsx(DialogContent, { className: "p-0", children: /* @__PURE__ */ jsx(Command, { className: "[&_[cmdk-group-heading]]:text-muted-foreground focus:outline-none [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-group]]:px-2 [&_[cmdk-input-wrapper]_svg]:size-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:size-5", children }) }) });
|
|
29
29
|
}
|
|
30
30
|
var CommandInput = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2 border-b px-3", "cmdk-input-wrapper": "", children: [
|
|
31
31
|
/* @__PURE__ */ jsx(MagnifyingGlassIcon, { className: "size-4 shrink-0 opacity-50" }),
|
|
@@ -51,14 +51,7 @@ var CommandList = React.forwardRef(({ className, ...props }, ref) => /* @__PURE_
|
|
|
51
51
|
}
|
|
52
52
|
));
|
|
53
53
|
CommandList.displayName = CommandPrimitive.List.displayName;
|
|
54
|
-
var CommandEmpty = React.forwardRef((props, ref) => /* @__PURE__ */ jsx(
|
|
55
|
-
CommandPrimitive.Empty,
|
|
56
|
-
{
|
|
57
|
-
ref,
|
|
58
|
-
className: "py-6 text-center text-sm",
|
|
59
|
-
...props
|
|
60
|
-
}
|
|
61
|
-
));
|
|
54
|
+
var CommandEmpty = React.forwardRef((props, ref) => /* @__PURE__ */ jsx(CommandPrimitive.Empty, { ref, className: "py-6 text-center text-sm", ...props }));
|
|
62
55
|
CommandEmpty.displayName = CommandPrimitive.Empty.displayName;
|
|
63
56
|
var CommandGroup = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
64
57
|
CommandPrimitive.Group,
|
|
@@ -72,14 +65,9 @@ var CommandGroup = React.forwardRef(({ className, ...props }, ref) => /* @__PURE
|
|
|
72
65
|
}
|
|
73
66
|
));
|
|
74
67
|
CommandGroup.displayName = CommandPrimitive.Group.displayName;
|
|
75
|
-
var CommandSeparator = React.forwardRef(
|
|
76
|
-
CommandPrimitive.Separator,
|
|
77
|
-
|
|
78
|
-
ref,
|
|
79
|
-
className: cn("bg-border -mx-1 h-px", className),
|
|
80
|
-
...props
|
|
81
|
-
}
|
|
82
|
-
));
|
|
68
|
+
var CommandSeparator = React.forwardRef(
|
|
69
|
+
({ className, ...props }, ref) => /* @__PURE__ */ jsx(CommandPrimitive.Separator, { ref, className: cn("bg-border -mx-1 h-px", className), ...props })
|
|
70
|
+
);
|
|
83
71
|
CommandSeparator.displayName = CommandPrimitive.Separator.displayName;
|
|
84
72
|
var CommandItem = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
85
73
|
CommandPrimitive.Item,
|
|
@@ -93,29 +81,10 @@ var CommandItem = React.forwardRef(({ className, ...props }, ref) => /* @__PURE_
|
|
|
93
81
|
}
|
|
94
82
|
));
|
|
95
83
|
CommandItem.displayName = CommandPrimitive.Item.displayName;
|
|
96
|
-
var CommandLoading = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
97
|
-
CommandPrimitive.Loading,
|
|
98
|
-
{
|
|
99
|
-
ref,
|
|
100
|
-
className: cn("flex justify-center p-2", className),
|
|
101
|
-
...props
|
|
102
|
-
}
|
|
103
|
-
));
|
|
84
|
+
var CommandLoading = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(CommandPrimitive.Loading, { ref, className: cn("flex justify-center p-2", className), ...props }));
|
|
104
85
|
CommandLoading.displayName = CommandPrimitive.Loading.displayName;
|
|
105
|
-
function CommandShortcut({
|
|
106
|
-
className,
|
|
107
|
-
...props
|
|
108
|
-
}) {
|
|
109
|
-
return /* @__PURE__ */ jsx(
|
|
110
|
-
"span",
|
|
111
|
-
{
|
|
112
|
-
className: cn(
|
|
113
|
-
"text-muted-foreground ml-auto text-xs tracking-widest",
|
|
114
|
-
className
|
|
115
|
-
),
|
|
116
|
-
...props
|
|
117
|
-
}
|
|
118
|
-
);
|
|
86
|
+
function CommandShortcut({ className, ...props }) {
|
|
87
|
+
return /* @__PURE__ */ jsx("span", { className: cn("text-muted-foreground ml-auto text-xs tracking-widest", className), ...props });
|
|
119
88
|
}
|
|
120
89
|
export {
|
|
121
90
|
Command,
|
package/dist/command.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/command.tsx"],"sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport { type DialogProps } from \"@radix-ui/react-dialog\";\nimport { MagnifyingGlassIcon } from \"@radix-ui/react-icons\";\nimport { Command as CommandPrimitive } from \"cmdk\";\nimport { cn } from \"./utils\";\nimport { Dialog, DialogContent } from \"./dialog\";\n\n/* -----------------------------------------------------------------------------\n * Component: Command\n * -------------------------------------------------------------------------- */\n\nconst Command = React.forwardRef<\n React.ElementRef<typeof CommandPrimitive>,\n React.ComponentPropsWithoutRef<typeof CommandPrimitive>\n>(({ className, ...props }, ref) => (\n <CommandPrimitive\n ref={ref}\n className={cn(\n \"bg-popover text-popover-foreground flex h-full w-full flex-col overflow-hidden rounded-md\",\n className,\n )}\n {...props}\n />\n));\nCommand.displayName = CommandPrimitive.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandDialog\n * -------------------------------------------------------------------------- */\n\nfunction CommandDialog({ children, ...props }: DialogProps): React.JSX.Element {\n return (\n <Dialog {...props}>\n <DialogContent className=\"overflow-hidden p-0\">\n <Command className=\"[&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-group]]:px-2 [&_[cmdk-input-wrapper]_svg]:size-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:size-5\">\n {children}\n </Command>\n </DialogContent>\n </Dialog>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: CommandInput\n * -------------------------------------------------------------------------- */\n\nconst CommandInput = React.forwardRef<\n React.ElementRef<typeof CommandPrimitive.Input>,\n React.ComponentPropsWithoutRef<typeof CommandPrimitive.Input>\n>(({ className, ...props }, ref) => (\n <div className=\"flex items-center gap-2 border-b px-3\" cmdk-input-wrapper=\"\">\n <MagnifyingGlassIcon className=\"size-4 shrink-0 opacity-50\" />\n <CommandPrimitive.Input\n ref={ref}\n className={cn(\n \"placeholder:text-muted-foreground flex h-10 w-full rounded-md bg-transparent text-sm focus:outline-none disabled:cursor-not-allowed disabled:opacity-50\",\n className,\n )}\n {...props}\n />\n </div>\n));\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandList\n * -------------------------------------------------------------------------- */\n\nconst CommandList = React.forwardRef<\n React.ElementRef<typeof CommandPrimitive.List>,\n React.ComponentPropsWithoutRef<typeof CommandPrimitive.List>\n>(({ className, ...props }, ref) => (\n <CommandPrimitive.List\n ref={ref}\n className={cn(\"max-h-[300px] overflow-y-auto overflow-x-hidden\", className)}\n {...props}\n />\n));\nCommandList.displayName = CommandPrimitive.List.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandEmpty\n * -------------------------------------------------------------------------- */\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef<typeof CommandPrimitive.Empty>,\n React.ComponentPropsWithoutRef<typeof CommandPrimitive.Empty>\n>((props, ref) => (\n <CommandPrimitive.Empty\n ref={ref}\n className=\"py-6 text-center text-sm\"\n {...props}\n />\n));\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandGroup\n * -------------------------------------------------------------------------- */\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef<typeof CommandPrimitive.Group>,\n React.ComponentPropsWithoutRef<typeof CommandPrimitive.Group>\n>(({ className, ...props }, ref) => (\n <CommandPrimitive.Group\n ref={ref}\n className={cn(\n \"text-foreground [&_[cmdk-group-heading]]:text-muted-foreground overflow-hidden p-1 [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium\",\n className,\n )}\n {...props}\n />\n));\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandSeparator\n * -------------------------------------------------------------------------- */\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef<typeof CommandPrimitive.Separator>,\n React.ComponentPropsWithoutRef<typeof CommandPrimitive.Separator>\n>(({ className, ...props }, ref) => (\n <CommandPrimitive.Separator\n ref={ref}\n className={cn(\"bg-border -mx-1 h-px\", className)}\n {...props}\n />\n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandItem\n * -------------------------------------------------------------------------- */\n\nconst CommandItem = React.forwardRef<\n React.ElementRef<typeof CommandPrimitive.Item>,\n React.ComponentPropsWithoutRef<typeof CommandPrimitive.Item>\n>(({ className, ...props }, ref) => (\n <CommandPrimitive.Item\n ref={ref}\n className={cn(\n \"aria-selected:bg-accent aria-selected:text-accent-foreground relative flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm focus:outline-none aria-disabled:pointer-events-none aria-disabled:opacity-50\",\n className,\n )}\n {...props}\n />\n));\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandLoading\n * -------------------------------------------------------------------------- */\n\nconst CommandLoading = React.forwardRef<\n React.ElementRef<typeof CommandPrimitive.Loading>,\n React.ComponentPropsWithoutRef<typeof CommandPrimitive.Loading>\n>(({ className, ...props }, ref) => (\n <CommandPrimitive.Loading\n ref={ref}\n className={cn(\"flex justify-center p-2\", className)}\n {...props}\n />\n));\nCommandLoading.displayName = CommandPrimitive.Loading.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandShortcut\n * -------------------------------------------------------------------------- */\n\nfunction CommandShortcut({\n className,\n ...props\n}: React.HTMLAttributes<HTMLSpanElement>): React.JSX.Element {\n return (\n <span\n className={cn(\n \"text-muted-foreground ml-auto text-xs tracking-widest\",\n className,\n )}\n {...props}\n />\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandLoading,\n CommandShortcut,\n CommandSeparator,\n};\n"],"mappings":";;;;;;;;;;AAEA,YAAY,WAAW;AAEvB,SAAS,2BAA2B;AACpC,SAAS,WAAW,wBAAwB;AAY1C,cAmCA,YAnCA;AAJF,IAAM,UAAgB,iBAGpB,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAC1B;AAAA,EAAC;AAAA;AAAA,IACC;AAAA,IACA,WAAW;AAAA,MACT;AAAA,MACA;AAAA,IACF;AAAA,IACC,GAAG;AAAA;AACN,CACD;AACD,QAAQ,cAAc,iBAAiB;AAMvC,SAAS,cAAc,EAAE,UAAU,GAAG,MAAM,GAAmC;AAC7E,SACE,oBAAC,UAAQ,GAAG,OACV,8BAAC,iBAAc,WAAU,uBACvB,8BAAC,WAAQ,WAAU,4TAChB,UACH,GACF,GACF;AAEJ;AAMA,IAAM,eAAqB,iBAGzB,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAC1B,qBAAC,SAAI,WAAU,yCAAwC,sBAAmB,IACxE;AAAA,sBAAC,uBAAoB,WAAU,8BAA6B;AAAA,EAC5D;AAAA,IAAC,iBAAiB;AAAA,IAAjB;AAAA,MACC;AAAA,MACA,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA;AAAA,EACN;AAAA,GACF,CACD;AACD,aAAa,cAAc,iBAAiB,MAAM;AAMlD,IAAM,cAAoB,iBAGxB,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAC1B;AAAA,EAAC,iBAAiB;AAAA,EAAjB;AAAA,IACC;AAAA,IACA,WAAW,GAAG,mDAAmD,SAAS;AAAA,IACzE,GAAG;AAAA;AACN,CACD;AACD,YAAY,cAAc,iBAAiB,KAAK;AAMhD,IAAM,eAAqB,iBAGzB,CAAC,OAAO,QACR;AAAA,EAAC,iBAAiB;AAAA,EAAjB;AAAA,IACC;AAAA,IACA,WAAU;AAAA,IACT,GAAG;AAAA;AACN,CACD;AACD,aAAa,cAAc,iBAAiB,MAAM;AAMlD,IAAM,eAAqB,iBAGzB,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAC1B;AAAA,EAAC,iBAAiB;AAAA,EAAjB;AAAA,IACC;AAAA,IACA,WAAW;AAAA,MACT;AAAA,MACA;AAAA,IACF;AAAA,IACC,GAAG;AAAA;AACN,CACD;AACD,aAAa,cAAc,iBAAiB,MAAM;AAMlD,IAAM,mBAAyB,iBAG7B,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAC1B;AAAA,EAAC,iBAAiB;AAAA,EAAjB;AAAA,IACC;AAAA,IACA,WAAW,GAAG,wBAAwB,SAAS;AAAA,IAC9C,GAAG;AAAA;AACN,CACD;AACD,iBAAiB,cAAc,iBAAiB,UAAU;AAM1D,IAAM,cAAoB,iBAGxB,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAC1B;AAAA,EAAC,iBAAiB;AAAA,EAAjB;AAAA,IACC;AAAA,IACA,WAAW;AAAA,MACT;AAAA,MACA;AAAA,IACF;AAAA,IACC,GAAG;AAAA;AACN,CACD;AACD,YAAY,cAAc,iBAAiB,KAAK;AAMhD,IAAM,iBAAuB,iBAG3B,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAC1B;AAAA,EAAC,iBAAiB;AAAA,EAAjB;AAAA,IACC;AAAA,IACA,WAAW,GAAG,2BAA2B,SAAS;AAAA,IACjD,GAAG;AAAA;AACN,CACD;AACD,eAAe,cAAc,iBAAiB,QAAQ;AAMtD,SAAS,gBAAgB;AAAA,EACvB;AAAA,EACA,GAAG;AACL,GAA6D;AAC3D,SACE;AAAA,IAAC;AAAA;AAAA,MACC,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA;AAAA,EACN;AAEJ;","names":[]}
|
|
1
|
+
{"version":3,"sources":["../src/command.tsx"],"sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport { MagnifyingGlassIcon } from \"@radix-ui/react-icons\";\nimport { Command as CommandPrimitive } from \"cmdk\";\nimport { cn } from \"./utils\";\nimport { Dialog, DialogContent } from \"./dialog\";\n\n/* -----------------------------------------------------------------------------\n * Component: Command\n * -------------------------------------------------------------------------- */\n\ntype CommandElement = React.ElementRef<typeof CommandPrimitive>;\ntype CommandProps = React.ComponentPropsWithoutRef<typeof CommandPrimitive>;\n\nconst Command = React.forwardRef<CommandElement, CommandProps>(({ className, ...props }, ref) => (\n <CommandPrimitive\n ref={ref}\n className={cn(\n \"bg-popover text-popover-foreground flex h-full w-full flex-col overflow-hidden rounded-md\",\n className,\n )}\n {...props}\n />\n));\n\nCommand.displayName = CommandPrimitive.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandDialog\n * -------------------------------------------------------------------------- */\n\ntype CommandDialogProps = React.ComponentProps<typeof Dialog>;\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps): React.JSX.Element {\n return (\n <Dialog {...props}>\n <DialogContent className=\"p-0\">\n <Command className=\"[&_[cmdk-group-heading]]:text-muted-foreground focus:outline-none [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-group]]:px-2 [&_[cmdk-input-wrapper]_svg]:size-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:size-5\">\n {children}\n </Command>\n </DialogContent>\n </Dialog>\n );\n}\n\n/* -----------------------------------------------------------------------------\n * Component: CommandInput\n * -------------------------------------------------------------------------- */\n\ntype CommandInputElement = React.ElementRef<typeof CommandPrimitive.Input>;\ntype CommandInputProps = React.ComponentPropsWithoutRef<typeof CommandPrimitive.Input>;\n\nconst CommandInput = React.forwardRef<CommandInputElement, CommandInputProps>(({ className, ...props }, ref) => (\n <div className=\"flex items-center gap-2 border-b px-3\" cmdk-input-wrapper=\"\">\n <MagnifyingGlassIcon className=\"size-4 shrink-0 opacity-50\" />\n <CommandPrimitive.Input\n ref={ref}\n className={cn(\n \"placeholder:text-muted-foreground flex h-10 w-full rounded-md bg-transparent text-sm focus:outline-none disabled:cursor-not-allowed disabled:opacity-50\",\n className,\n )}\n {...props}\n />\n </div>\n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandList\n * -------------------------------------------------------------------------- */\n\ntype CommandListElement = React.ElementRef<typeof CommandPrimitive.List>;\ntype CommandListProps = React.ComponentPropsWithoutRef<typeof CommandPrimitive.List>;\n\nconst CommandList = React.forwardRef<CommandListElement, CommandListProps>(({ className, ...props }, ref) => (\n <CommandPrimitive.List\n ref={ref}\n className={cn(\"max-h-[300px] overflow-y-auto overflow-x-hidden\", className)}\n {...props}\n />\n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandEmpty\n * -------------------------------------------------------------------------- */\n\ntype CommandEmptyElement = React.ElementRef<typeof CommandPrimitive.Empty>;\ntype CommandEmptyProps = React.ComponentPropsWithoutRef<typeof CommandPrimitive.Empty>;\n\nconst CommandEmpty = React.forwardRef<CommandEmptyElement, CommandEmptyProps>((props, ref) => (\n <CommandPrimitive.Empty ref={ref} className=\"py-6 text-center text-sm\" {...props} />\n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandGroup\n * -------------------------------------------------------------------------- */\n\ntype CommandGroupElement = React.ElementRef<typeof CommandPrimitive.Group>;\ntype CommandGroupProps = React.ComponentPropsWithoutRef<typeof CommandPrimitive.Group>;\n\nconst CommandGroup = React.forwardRef<CommandGroupElement, CommandGroupProps>(({ className, ...props }, ref) => (\n <CommandPrimitive.Group\n ref={ref}\n className={cn(\n \"text-foreground [&_[cmdk-group-heading]]:text-muted-foreground overflow-hidden p-1 [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium\",\n className,\n )}\n {...props}\n />\n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandSeparator\n * -------------------------------------------------------------------------- */\n\ntype CommandSeparatorElement = React.ElementRef<typeof CommandPrimitive.Separator>;\ntype CommandSeparatorProps = React.ComponentPropsWithoutRef<typeof CommandPrimitive.Separator>;\n\nconst CommandSeparator = React.forwardRef<CommandSeparatorElement, CommandSeparatorProps>(\n ({ className, ...props }, ref) => (\n <CommandPrimitive.Separator ref={ref} className={cn(\"bg-border -mx-1 h-px\", className)} {...props} />\n ),\n);\n\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandItem\n * -------------------------------------------------------------------------- */\n\ntype CommandItemElement = React.ElementRef<typeof CommandPrimitive.Item>;\ntype CommandItemProps = React.ComponentPropsWithoutRef<typeof CommandPrimitive.Item>;\n\nconst CommandItem = React.forwardRef<CommandItemElement, CommandItemProps>(({ className, ...props }, ref) => (\n <CommandPrimitive.Item\n ref={ref}\n className={cn(\n \"aria-selected:bg-accent aria-selected:text-accent-foreground relative flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm focus:outline-none aria-disabled:pointer-events-none aria-disabled:opacity-50\",\n className,\n )}\n {...props}\n />\n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandLoading\n * -------------------------------------------------------------------------- */\n\ntype CommandLoadingElement = React.ElementRef<typeof CommandPrimitive.Loading>;\ntype CommandLoadingProps = React.ComponentPropsWithoutRef<typeof CommandPrimitive.Loading>;\n\nconst CommandLoading = React.forwardRef<CommandLoadingElement, CommandLoadingProps>(({ className, ...props }, ref) => (\n <CommandPrimitive.Loading ref={ref} className={cn(\"flex justify-center p-2\", className)} {...props} />\n));\n\nCommandLoading.displayName = CommandPrimitive.Loading.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: CommandShortcut\n * -------------------------------------------------------------------------- */\n\ntype CommandShortcutProps = React.HTMLAttributes<HTMLSpanElement>;\n\nfunction CommandShortcut({ className, ...props }: CommandShortcutProps): React.JSX.Element {\n return <span className={cn(\"text-muted-foreground ml-auto text-xs tracking-widest\", className)} {...props} />;\n}\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandLoading,\n CommandShortcut,\n CommandSeparator,\n type CommandProps,\n type CommandDialogProps,\n type CommandInputProps,\n type CommandListProps,\n type CommandEmptyProps,\n type CommandGroupProps,\n type CommandItemProps,\n type CommandLoadingProps,\n type CommandShortcutProps,\n type CommandSeparatorProps,\n};\n"],"mappings":";;;;;;;;;;AAEA,YAAY,WAAW;AACvB,SAAS,2BAA2B;AACpC,SAAS,WAAW,wBAAwB;AAY1C,cAsCA,YAtCA;AADF,IAAM,UAAgB,iBAAyC,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACvF;AAAA,EAAC;AAAA;AAAA,IACC;AAAA,IACA,WAAW;AAAA,MACT;AAAA,MACA;AAAA,IACF;AAAA,IACC,GAAG;AAAA;AACN,CACD;AAED,QAAQ,cAAc,iBAAiB;AAQvC,SAAS,cAAc,EAAE,UAAU,GAAG,MAAM,GAA0C;AACpF,SACE,oBAAC,UAAQ,GAAG,OACV,8BAAC,iBAAc,WAAU,OACvB,8BAAC,WAAQ,WAAU,+UAChB,UACH,GACF,GACF;AAEJ;AASA,IAAM,eAAqB,iBAAmD,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACtG,qBAAC,SAAI,WAAU,yCAAwC,sBAAmB,IACxE;AAAA,sBAAC,uBAAoB,WAAU,8BAA6B;AAAA,EAC5D;AAAA,IAAC,iBAAiB;AAAA,IAAjB;AAAA,MACC;AAAA,MACA,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA;AAAA,EACN;AAAA,GACF,CACD;AAED,aAAa,cAAc,iBAAiB,MAAM;AASlD,IAAM,cAAoB,iBAAiD,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACnG;AAAA,EAAC,iBAAiB;AAAA,EAAjB;AAAA,IACC;AAAA,IACA,WAAW,GAAG,mDAAmD,SAAS;AAAA,IACzE,GAAG;AAAA;AACN,CACD;AAED,YAAY,cAAc,iBAAiB,KAAK;AAShD,IAAM,eAAqB,iBAAmD,CAAC,OAAO,QACpF,oBAAC,iBAAiB,OAAjB,EAAuB,KAAU,WAAU,4BAA4B,GAAG,OAAO,CACnF;AAED,aAAa,cAAc,iBAAiB,MAAM;AASlD,IAAM,eAAqB,iBAAmD,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACtG;AAAA,EAAC,iBAAiB;AAAA,EAAjB;AAAA,IACC;AAAA,IACA,WAAW;AAAA,MACT;AAAA,MACA;AAAA,IACF;AAAA,IACC,GAAG;AAAA;AACN,CACD;AAED,aAAa,cAAc,iBAAiB,MAAM;AASlD,IAAM,mBAAyB;AAAA,EAC7B,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB,oBAAC,iBAAiB,WAAjB,EAA2B,KAAU,WAAW,GAAG,wBAAwB,SAAS,GAAI,GAAG,OAAO;AAEvG;AAEA,iBAAiB,cAAc,iBAAiB,UAAU;AAS1D,IAAM,cAAoB,iBAAiD,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACnG;AAAA,EAAC,iBAAiB;AAAA,EAAjB;AAAA,IACC;AAAA,IACA,WAAW;AAAA,MACT;AAAA,MACA;AAAA,IACF;AAAA,IACC,GAAG;AAAA;AACN,CACD;AAED,YAAY,cAAc,iBAAiB,KAAK;AAShD,IAAM,iBAAuB,iBAAuD,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAC5G,oBAAC,iBAAiB,SAAjB,EAAyB,KAAU,WAAW,GAAG,2BAA2B,SAAS,GAAI,GAAG,OAAO,CACrG;AAED,eAAe,cAAc,iBAAiB,QAAQ;AAQtD,SAAS,gBAAgB,EAAE,WAAW,GAAG,MAAM,GAA4C;AACzF,SAAO,oBAAC,UAAK,WAAW,GAAG,yDAAyD,SAAS,GAAI,GAAG,OAAO;AAC7G;","names":[]}
|
package/dist/container.d.mts
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
asChild?: boolean
|
|
5
|
-
}
|
|
3
|
+
interface ContainerProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
4
|
+
asChild?: boolean;
|
|
5
|
+
}
|
|
6
|
+
declare const Container: React.ForwardRefExoticComponent<ContainerProps & React.RefAttributes<HTMLDivElement>>;
|
|
6
7
|
|
|
7
|
-
export { Container };
|
|
8
|
+
export { Container, type ContainerProps };
|
package/dist/container.d.ts
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
asChild?: boolean
|
|
5
|
-
}
|
|
3
|
+
interface ContainerProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
4
|
+
asChild?: boolean;
|
|
5
|
+
}
|
|
6
|
+
declare const Container: React.ForwardRefExoticComponent<ContainerProps & React.RefAttributes<HTMLDivElement>>;
|
|
6
7
|
|
|
7
|
-
export { Container };
|
|
8
|
+
export { Container, type ContainerProps };
|
package/dist/container.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/container.tsx"],"names":[],"mappings":";;;;;AAAA,YAAY,WAAW;AACvB,SAAS,YAAY;
|
|
1
|
+
{"version":3,"sources":["../src/container.tsx"],"names":[],"mappings":";;;;;AAAA,YAAY,WAAW;AACvB,SAAS,YAAY;AAgBZ;AAHT,IAAM,YAAkB,iBAA6C,CAAC,EAAE,WAAW,SAAS,GAAG,MAAM,GAAG,QAAQ;AAC9G,QAAM,OAAO,UAAU,OAAO;AAE9B,SAAO,oBAAC,QAAK,KAAU,WAAW,GAAG,aAAa,SAAS,GAAI,GAAG,OAAO;AAC3E,CAAC;AAED,UAAU,cAAc","sourcesContent":["import * as React from \"react\";\nimport { Slot } from \"@radix-ui/react-slot\";\nimport { cn } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Component: Container\n * -------------------------------------------------------------------------- */\n\ntype ContainerElement = HTMLDivElement;\n\ninterface ContainerProps extends React.HTMLAttributes<HTMLDivElement> {\n asChild?: boolean;\n}\n\nconst Container = React.forwardRef<ContainerElement, ContainerProps>(({ className, asChild, ...props }, ref) => {\n const Comp = asChild ? Slot : \"div\";\n\n return <Comp ref={ref} className={cn(\"container\", className)} {...props} />;\n});\n\nContainer.displayName = \"Container\";\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Container, type ContainerProps };\n"]}
|
package/dist/container.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/container.tsx"],"sourcesContent":["import * as React from \"react\";\nimport { Slot } from \"@radix-ui/react-slot\";\nimport { cn } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Component: Container\n * -------------------------------------------------------------------------- */\n\
|
|
1
|
+
{"version":3,"sources":["../src/container.tsx"],"sourcesContent":["import * as React from \"react\";\nimport { Slot } from \"@radix-ui/react-slot\";\nimport { cn } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Component: Container\n * -------------------------------------------------------------------------- */\n\ntype ContainerElement = HTMLDivElement;\n\ninterface ContainerProps extends React.HTMLAttributes<HTMLDivElement> {\n asChild?: boolean;\n}\n\nconst Container = React.forwardRef<ContainerElement, ContainerProps>(({ className, asChild, ...props }, ref) => {\n const Comp = asChild ? Slot : \"div\";\n\n return <Comp ref={ref} className={cn(\"container\", className)} {...props} />;\n});\n\nContainer.displayName = \"Container\";\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Container, type ContainerProps };\n"],"mappings":";;;;;AAAA,YAAY,WAAW;AACvB,SAAS,YAAY;AAgBZ;AAHT,IAAM,YAAkB,iBAA6C,CAAC,EAAE,WAAW,SAAS,GAAG,MAAM,GAAG,QAAQ;AAC9G,QAAM,OAAO,UAAU,OAAO;AAE9B,SAAO,oBAAC,QAAK,KAAU,WAAW,GAAG,aAAa,SAAS,GAAI,GAAG,OAAO;AAC3E,CAAC;AAED,UAAU,cAAc;","names":[]}
|
package/dist/context-menu.d.mts
CHANGED
|
@@ -1,26 +1,41 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import * as ContextMenuPrimitive from '@radix-ui/react-context-menu';
|
|
3
3
|
|
|
4
|
+
type ContextMenuProps = React.ComponentProps<typeof ContextMenuPrimitive.Root>;
|
|
4
5
|
declare const ContextMenu: React.FC<ContextMenuPrimitive.ContextMenuProps>;
|
|
6
|
+
type ContextMenuTriggerProps = React.ComponentPropsWithoutRef<typeof ContextMenuPrimitive.Trigger>;
|
|
5
7
|
declare const ContextMenuTrigger: React.ForwardRefExoticComponent<ContextMenuPrimitive.ContextMenuTriggerProps & React.RefAttributes<HTMLSpanElement>>;
|
|
8
|
+
type ContextMenuGroupProps = React.ComponentPropsWithoutRef<typeof ContextMenuPrimitive.Group>;
|
|
6
9
|
declare const ContextMenuGroup: React.ForwardRefExoticComponent<ContextMenuPrimitive.ContextMenuGroupProps & React.RefAttributes<HTMLDivElement>>;
|
|
10
|
+
type ContextMenuSubProps = React.ComponentProps<typeof ContextMenuPrimitive.Sub>;
|
|
7
11
|
declare const ContextMenuSub: React.FC<ContextMenuPrimitive.ContextMenuSubProps>;
|
|
12
|
+
type ContextMenuRadioGroupProps = React.ComponentPropsWithoutRef<typeof ContextMenuPrimitive.RadioGroup>;
|
|
8
13
|
declare const ContextMenuRadioGroup: React.ForwardRefExoticComponent<ContextMenuPrimitive.ContextMenuRadioGroupProps & React.RefAttributes<HTMLDivElement>>;
|
|
9
|
-
|
|
10
|
-
inset?: boolean
|
|
11
|
-
}
|
|
12
|
-
declare const
|
|
13
|
-
|
|
14
|
-
declare const
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
declare const
|
|
23
|
-
|
|
14
|
+
interface ContextMenuSubTriggerProps extends React.ComponentPropsWithoutRef<typeof ContextMenuPrimitive.SubTrigger> {
|
|
15
|
+
inset?: boolean;
|
|
16
|
+
}
|
|
17
|
+
declare const ContextMenuSubTrigger: React.ForwardRefExoticComponent<ContextMenuSubTriggerProps & React.RefAttributes<HTMLDivElement>>;
|
|
18
|
+
type ContextMenuSubContentProps = React.ComponentPropsWithoutRef<typeof ContextMenuPrimitive.SubContent>;
|
|
19
|
+
declare const ContextMenuSubContent: React.ForwardRefExoticComponent<Omit<ContextMenuPrimitive.ContextMenuSubContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
20
|
+
type ContextMenuContentProps = React.ComponentPropsWithoutRef<typeof ContextMenuPrimitive.Content>;
|
|
21
|
+
declare const ContextMenuContent: React.ForwardRefExoticComponent<Omit<ContextMenuPrimitive.ContextMenuContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
22
|
+
interface ContextMenuItemProps extends React.ComponentPropsWithoutRef<typeof ContextMenuPrimitive.Item> {
|
|
23
|
+
inset?: boolean;
|
|
24
|
+
}
|
|
25
|
+
declare const ContextMenuItem: React.ForwardRefExoticComponent<ContextMenuItemProps & React.RefAttributes<HTMLDivElement>>;
|
|
26
|
+
type ContextMenuCheckboxItemProps = React.ComponentPropsWithoutRef<typeof ContextMenuPrimitive.CheckboxItem>;
|
|
27
|
+
declare const ContextMenuCheckboxItem: React.ForwardRefExoticComponent<Omit<ContextMenuPrimitive.ContextMenuCheckboxItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
28
|
+
type ContextMenuRadioItemProps = React.ComponentPropsWithoutRef<typeof ContextMenuPrimitive.RadioItem>;
|
|
29
|
+
declare const ContextMenuRadioItem: React.ForwardRefExoticComponent<Omit<ContextMenuPrimitive.ContextMenuRadioItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
30
|
+
interface ContextMenuLabelProps extends React.ComponentPropsWithoutRef<typeof ContextMenuPrimitive.Label> {
|
|
31
|
+
inset?: boolean;
|
|
32
|
+
}
|
|
33
|
+
declare const ContextMenuLabel: React.ForwardRefExoticComponent<ContextMenuLabelProps & React.RefAttributes<HTMLDivElement>>;
|
|
34
|
+
type ContextMenuSeparatorProps = React.ComponentPropsWithoutRef<typeof ContextMenuPrimitive.Separator>;
|
|
35
|
+
declare const ContextMenuSeparator: React.ForwardRefExoticComponent<Omit<ContextMenuPrimitive.ContextMenuSeparatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
36
|
+
type ContextMenuShortcutProps = React.HTMLAttributes<HTMLSpanElement>;
|
|
37
|
+
declare function ContextMenuShortcut({ className, ...props }: ContextMenuShortcutProps): React.JSX.Element;
|
|
38
|
+
type ContextMenuArrowProps = ContextMenuPrimitive.ContextMenuArrowProps;
|
|
24
39
|
declare const ContextMenuArrow: React.ForwardRefExoticComponent<ContextMenuPrimitive.ContextMenuArrowProps & React.RefAttributes<SVGSVGElement>>;
|
|
25
40
|
|
|
26
|
-
export { ContextMenu, ContextMenuArrow, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger };
|
|
41
|
+
export { ContextMenu, ContextMenuArrow, type ContextMenuArrowProps, ContextMenuCheckboxItem, type ContextMenuCheckboxItemProps, ContextMenuContent, type ContextMenuContentProps, ContextMenuGroup, type ContextMenuGroupProps, ContextMenuItem, type ContextMenuItemProps, ContextMenuLabel, type ContextMenuLabelProps, type ContextMenuProps, ContextMenuRadioGroup, type ContextMenuRadioGroupProps, ContextMenuRadioItem, type ContextMenuRadioItemProps, ContextMenuSeparator, type ContextMenuSeparatorProps, ContextMenuShortcut, type ContextMenuShortcutProps, ContextMenuSub, ContextMenuSubContent, type ContextMenuSubContentProps, type ContextMenuSubProps, ContextMenuSubTrigger, type ContextMenuSubTriggerProps, ContextMenuTrigger, type ContextMenuTriggerProps };
|