pxd 0.0.55 → 0.0.61
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +18 -4
- package/dist/components/_internal/fragment-container.vue +3 -2
- package/dist/components/active-graph/index.d.vue.ts +2 -3
- package/dist/components/active-graph/index.vue +23 -16
- package/dist/components/active-graph/types.d.ts +4 -3
- package/dist/components/avatar/index.vue +19 -10
- package/dist/components/avatar/types.d.ts +0 -12
- package/dist/components/avatar-group/index.d.vue.ts +2 -2
- package/dist/components/avatar-group/index.vue +4 -3
- package/dist/components/avatar-group/types.d.ts +11 -0
- package/dist/components/badge/index.d.vue.ts +1 -1
- package/dist/components/badge/index.vue +47 -3
- package/dist/components/badge/types.d.ts +24 -1
- package/dist/components/book/index.vue +3 -2
- package/dist/components/browser/index.vue +6 -2
- package/dist/components/button/index.d.vue.ts +1 -1
- package/dist/components/button/index.vue +60 -12
- package/dist/components/carousel/index.d.vue.ts +24 -2
- package/dist/components/carousel/index.vue +341 -28
- package/dist/components/carousel/types.d.ts +2 -2
- package/dist/components/carousel-item/index.d.vue.ts +13 -0
- package/dist/components/carousel-item/index.vue +49 -0
- package/dist/components/checkbox/index.d.vue.ts +1 -5
- package/dist/components/checkbox/index.vue +66 -31
- package/dist/components/checkbox/types.d.ts +2 -14
- package/dist/components/checkbox-group/index.d.vue.ts +2 -7
- package/dist/components/checkbox-group/index.vue +11 -29
- package/dist/components/checkbox-group/types.d.ts +12 -0
- package/dist/components/chip/index.d.vue.ts +1 -1
- package/dist/components/chip/index.vue +31 -2
- package/dist/components/choicebox/index.d.vue.ts +11 -5
- package/dist/components/choicebox/index.vue +36 -54
- package/dist/components/choicebox/types.d.ts +11 -18
- package/dist/components/choicebox-item/index.d.vue.ts +16 -0
- package/dist/components/choicebox-item/index.vue +67 -0
- package/dist/components/choicebox-item/types.d.ts +12 -0
- package/dist/components/collapse/index.d.vue.ts +5 -4
- package/dist/components/collapse/index.vue +47 -30
- package/dist/components/collapse/types.d.ts +2 -5
- package/dist/components/collapse-group/index.d.vue.ts +2 -4
- package/dist/components/collapse-group/index.vue +8 -20
- package/dist/components/collapse-group/types.d.ts +6 -0
- package/dist/components/command-menu/index.vue +6 -7
- package/dist/components/command-menu/types.d.ts +0 -5
- package/dist/components/command-menu-group/index.d.vue.ts +1 -1
- package/dist/components/command-menu-group/index.vue +3 -2
- package/dist/components/command-menu-group/types.d.ts +5 -0
- package/dist/components/config-provider/index.d.vue.ts +3 -3
- package/dist/components/config-provider/index.vue +6 -4
- package/dist/components/countdown/index.vue +3 -2
- package/dist/components/countdown/types.d.ts +2 -2
- package/dist/components/dash-line/index.vue +3 -1
- package/dist/components/description/index.d.vue.ts +1 -1
- package/dist/components/description/index.vue +8 -7
- package/dist/components/description/types.d.ts +1 -1
- package/dist/components/drawer/index.d.vue.ts +3 -2
- package/dist/components/drawer/index.vue +20 -15
- package/dist/components/drawer/types.d.ts +3 -3
- package/dist/components/ellipsis-text/index.d.vue.ts +14 -0
- package/dist/components/ellipsis-text/index.vue +242 -0
- package/dist/components/ellipsis-text/types.d.ts +14 -0
- package/dist/components/empty-state/index.vue +6 -2
- package/dist/components/error/index.d.vue.ts +1 -3
- package/dist/components/error/index.vue +21 -6
- package/dist/components/error/types.d.ts +7 -1
- package/dist/components/fader/index.vue +30 -11
- package/dist/components/fader/types.d.ts +2 -2
- package/dist/components/gauge/index.vue +7 -2
- package/dist/components/grid/index.vue +9 -4
- package/dist/components/grid/types.d.ts +0 -5
- package/dist/components/grid-item/index.d.vue.ts +1 -1
- package/dist/components/grid-item/index.vue +16 -8
- package/dist/components/grid-item/types.d.ts +6 -0
- package/dist/components/hold-button/index.d.vue.ts +2 -2
- package/dist/components/hold-button/index.vue +1 -1
- package/dist/components/index.d.ts +7 -3
- package/dist/components/index.js +7 -3
- package/dist/components/input/index.d.vue.ts +8 -8
- package/dist/components/input/index.vue +54 -21
- package/dist/components/input/types.d.ts +7 -10
- package/dist/components/intersection-observer/index.d.vue.ts +0 -1
- package/dist/components/intersection-observer/index.vue +12 -3
- package/dist/components/kbd/index.vue +1 -1
- package/dist/components/link-button/index.d.vue.ts +1 -1
- package/dist/components/link-button/index.vue +4 -6
- package/dist/components/link-button/types.d.ts +1 -1
- package/dist/components/list/index.d.vue.ts +8 -5
- package/dist/components/list/index.vue +50 -54
- package/dist/components/list/types.d.ts +3 -20
- package/dist/components/list-item/index.d.vue.ts +3 -2
- package/dist/components/list-item/index.vue +44 -18
- package/dist/components/list-item/types.d.ts +15 -0
- package/dist/components/loading-bar/index.vue +33 -2
- package/dist/components/loading-bar/types.d.ts +1 -1
- package/dist/components/loading-dots/index.vue +3 -2
- package/dist/components/menu/index.d.vue.ts +5 -2
- package/dist/components/menu/index.vue +4 -1
- package/dist/components/menu/types.d.ts +5 -0
- package/dist/components/message/index.d.vue.ts +11 -8
- package/dist/components/message/index.vue +4 -12
- package/dist/components/message/types.d.ts +1 -12
- package/dist/components/message-item/index.d.vue.ts +1 -3
- package/dist/components/message-item/index.vue +13 -7
- package/dist/components/message-item/types.d.ts +11 -0
- package/dist/components/modal/index.d.vue.ts +3 -2
- package/dist/components/modal/index.vue +17 -13
- package/dist/components/modal/types.d.ts +3 -3
- package/dist/components/noise-background/index.vue +4 -3
- package/dist/components/note/index.d.vue.ts +1 -2
- package/dist/components/note/index.vue +81 -29
- package/dist/components/note/types.d.ts +10 -2
- package/dist/components/number-input/index.d.vue.ts +5 -4
- package/dist/components/number-input/index.vue +36 -6
- package/dist/components/number-input/types.d.ts +2 -0
- package/dist/components/overlay/index.vue +1 -1
- package/dist/components/overlay/types.d.ts +1 -1
- package/dist/components/pagination/index.vue +5 -3
- package/dist/components/pin-input/index.d.vue.ts +6 -1
- package/dist/components/pin-input/index.vue +60 -23
- package/dist/components/pin-input/types.d.ts +0 -4
- package/dist/components/placeholder/index.vue +14 -11
- package/dist/components/popover/index.vue +116 -78
- package/dist/components/popover/types.d.ts +1 -0
- package/dist/components/progress/index.d.vue.ts +1 -1
- package/dist/components/progress/index.vue +15 -2
- package/dist/components/project-banner/index.d.vue.ts +18 -0
- package/dist/components/project-banner/index.vue +59 -0
- package/dist/components/project-banner/types.d.ts +8 -0
- package/dist/components/radio/index.vue +62 -20
- package/dist/components/radio/types.d.ts +1 -14
- package/dist/components/radio-group/index.d.vue.ts +2 -4
- package/dist/components/radio-group/index.vue +11 -16
- package/dist/components/radio-group/types.d.ts +12 -0
- package/dist/components/resizable/types.d.ts +5 -10
- package/dist/components/resizable-handle/index.vue +1 -1
- package/dist/components/resizable-panel/index.d.vue.ts +1 -1
- package/dist/components/resizable-panel/index.vue +7 -2
- package/dist/components/resizable-panel/types.d.ts +4 -0
- package/dist/components/scrollable/index.d.vue.ts +29 -0
- package/dist/components/scrollable/index.vue +98 -83
- package/dist/components/scrollable/types.d.ts +19 -6
- package/dist/components/skeleton/index.vue +24 -1
- package/dist/components/slider/index.d.vue.ts +6 -6
- package/dist/components/slider/index.vue +86 -44
- package/dist/components/slider/types.d.ts +1 -1
- package/dist/components/snippet/index.vue +28 -2
- package/dist/components/spinner/index.vue +4 -2
- package/dist/components/stack/index.d.vue.ts +2 -2
- package/dist/components/stack/index.vue +35 -3
- package/dist/components/stack/types.d.ts +1 -1
- package/dist/components/status-dot/index.vue +5 -1
- package/dist/components/switch/index.d.vue.ts +10 -1
- package/dist/components/switch/index.vue +35 -44
- package/dist/components/switch/types.d.ts +4 -12
- package/dist/components/switch-item/index.d.vue.ts +14 -0
- package/dist/components/switch-item/index.vue +79 -0
- package/dist/components/switch-item/types.d.ts +9 -0
- package/dist/components/teleport/index.d.vue.ts +1 -1
- package/dist/components/teleport/index.vue +1 -1
- package/dist/components/teleport/types.d.ts +1 -1
- package/dist/components/text/index.d.vue.ts +1 -2
- package/dist/components/text/index.vue +36 -22
- package/dist/components/text/types.d.ts +1 -1
- package/dist/components/textarea/index.d.vue.ts +4 -4
- package/dist/components/textarea/index.vue +33 -4
- package/dist/components/textarea/types.d.ts +0 -1
- package/dist/components/time-picker/index.d.vue.ts +1 -2
- package/dist/components/time-picker/index.vue +43 -9
- package/dist/components/time-picker/types.d.ts +1 -2
- package/dist/components/toggle/index.vue +11 -10
- package/dist/components/toggle-button/index.d.vue.ts +22 -0
- package/dist/components/toggle-button/index.vue +110 -0
- package/dist/components/toggle-button/types.d.ts +16 -0
- package/dist/components/{choicebox-group → toggle-button-group}/index.d.vue.ts +5 -5
- package/dist/components/toggle-button-group/index.vue +68 -0
- package/dist/components/toggle-button-group/types.d.ts +22 -0
- package/dist/components/tooltip/index.d.vue.ts +2 -0
- package/dist/components/tooltip/index.vue +9 -3
- package/dist/components/tooltip/types.d.ts +3 -2
- package/dist/components/virtual-list/index.d.vue.ts +25 -4
- package/dist/components/virtual-list/index.vue +66 -10
- package/dist/components/virtual-list/types.d.ts +9 -4
- package/dist/composables/index.d.ts +2 -2
- package/dist/composables/index.js +2 -2
- package/dist/composables/use-browser-observer.d.ts +5 -5
- package/dist/composables/use-browser-observer.js +23 -20
- package/dist/composables/use-copy-click.js +4 -0
- package/dist/composables/use-countdown.d.ts +2 -2
- package/dist/composables/use-delay-destroy.d.ts +1 -1
- package/dist/composables/use-focus-trap.d.ts +7 -3
- package/dist/composables/use-focus-trap.js +19 -7
- package/dist/composables/use-forward-ref-expose.d.ts +2 -0
- package/dist/composables/use-forward-ref-expose.js +41 -0
- package/dist/composables/use-message.d.ts +4 -7
- package/dist/composables/use-model-value.d.ts +9 -8
- package/dist/composables/use-popover-responsive.d.ts +2 -2
- package/dist/composables/use-popover-responsive.js +3 -3
- package/dist/composables/use-repeat-action.d.ts +1 -1
- package/dist/composables/use-repeat-action.js +2 -2
- package/dist/composables/use-virtual-list.d.ts +21 -12
- package/dist/composables/use-virtual-list.js +90 -158
- package/dist/composables/use-window-size.d.ts +4 -0
- package/dist/composables/use-window-size.js +27 -0
- package/dist/contexts/avatar.d.ts +5 -2
- package/dist/contexts/carousel.d.ts +4 -4
- package/dist/contexts/carousel.js +1 -1
- package/dist/contexts/checkbox.d.ts +7 -2
- package/dist/contexts/choicebox.d.ts +8 -4
- package/dist/contexts/choicebox.js +1 -4
- package/dist/contexts/collapse.d.ts +5 -6
- package/dist/contexts/collapse.js +1 -1
- package/dist/contexts/config-provider.d.ts +5 -0
- package/dist/{composables/use-config-provider-context.js → contexts/config-provider.js} +8 -5
- package/dist/contexts/list.d.ts +1 -1
- package/dist/contexts/radio.d.ts +8 -2
- package/dist/contexts/resizable.d.ts +1 -1
- package/dist/contexts/switch.d.ts +8 -4
- package/dist/contexts/switch.js +1 -2
- package/dist/contexts/toggle-button.d.ts +7 -0
- package/dist/contexts/toggle-button.js +2 -0
- package/dist/styles/source.css +14 -2
- package/dist/styles/styles.css +2 -2
- package/dist/styles/tw.css +14 -2
- package/dist/types/shared/props.d.ts +1 -3
- package/dist/types/shared/utils.d.ts +0 -3
- package/dist/utils/context.d.ts +1 -0
- package/dist/utils/get.d.ts +1 -0
- package/dist/utils/get.js +14 -0
- package/dist/utils/ref.d.ts +1 -1
- package/dist/utils/responsive.js +2 -1
- package/dist/utils/throttle.js +9 -7
- package/dist/utils/uid.d.ts +1 -1
- package/dist/utils/uid.js +2 -2
- package/package.json +23 -21
- package/volar.d.ts +7 -3
- package/dist/components/badge/cn.d.ts +0 -90
- package/dist/components/badge/cn.js +0 -44
- package/dist/components/button/cn.d.ts +0 -121
- package/dist/components/button/cn.js +0 -55
- package/dist/components/carousel-group/index.d.vue.ts +0 -35
- package/dist/components/carousel-group/index.vue +0 -368
- package/dist/components/checkbox/cn.d.ts +0 -67
- package/dist/components/checkbox/cn.js +0 -31
- package/dist/components/chip/cn.d.ts +0 -49
- package/dist/components/chip/cn.js +0 -26
- package/dist/components/choicebox-group/index.vue +0 -65
- package/dist/components/error/cn.d.ts +0 -22
- package/dist/components/error/cn.js +0 -15
- package/dist/components/input/cn.d.ts +0 -73
- package/dist/components/input/cn.js +0 -36
- package/dist/components/list-item/cn.d.ts +0 -22
- package/dist/components/list-item/cn.js +0 -15
- package/dist/components/loading-bar/cn.d.ts +0 -70
- package/dist/components/loading-bar/cn.js +0 -32
- package/dist/components/note/cn.d.ts +0 -121
- package/dist/components/note/cn.js +0 -66
- package/dist/components/pin-input/cn.d.ts +0 -46
- package/dist/components/pin-input/cn.js +0 -25
- package/dist/components/progress/cn.d.ts +0 -19
- package/dist/components/progress/cn.js +0 -14
- package/dist/components/radio/cn.d.ts +0 -46
- package/dist/components/radio/cn.js +0 -42
- package/dist/components/skeleton/cn.d.ts +0 -43
- package/dist/components/skeleton/cn.js +0 -24
- package/dist/components/snippet/cn.d.ts +0 -52
- package/dist/components/snippet/cn.js +0 -27
- package/dist/components/stack/cn.d.ts +0 -70
- package/dist/components/stack/cn.js +0 -33
- package/dist/components/switch/cn.d.ts +0 -16
- package/dist/components/switch/cn.js +0 -13
- package/dist/components/switch-group/index.d.vue.ts +0 -23
- package/dist/components/switch-group/index.vue +0 -54
- package/dist/components/text/cn.d.ts +0 -67
- package/dist/components/text/cn.js +0 -34
- package/dist/components/textarea/cn.d.ts +0 -58
- package/dist/components/textarea/cn.js +0 -30
- package/dist/composables/use-config-provider-context.d.ts +0 -3
- package/dist/composables/use-unique-id-context.d.ts +0 -2
- package/dist/composables/use-unique-id-context.js +0 -11
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { tv } from "tailwind-variants";
|
|
2
|
-
export const skeletonVariant = tv({
|
|
3
|
-
base: "pxd-skeleton relative block shrink-0 overflow-hidden",
|
|
4
|
-
variants: {
|
|
5
|
-
loading: {
|
|
6
|
-
true: "loading invisible",
|
|
7
|
-
false: ""
|
|
8
|
-
},
|
|
9
|
-
shape: {
|
|
10
|
-
default: "rounded-md",
|
|
11
|
-
square: "rounded-none",
|
|
12
|
-
rounded: "rounded-full"
|
|
13
|
-
},
|
|
14
|
-
animated: {
|
|
15
|
-
true: "animated after:default-animation-timing-function!",
|
|
16
|
-
false: ""
|
|
17
|
-
}
|
|
18
|
-
},
|
|
19
|
-
defaultVariants: {
|
|
20
|
-
loading: true,
|
|
21
|
-
shape: "default",
|
|
22
|
-
animated: true
|
|
23
|
-
}
|
|
24
|
-
});
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
export declare const snippetVariant: import("tailwind-variants").TVReturnType<{
|
|
2
|
-
size: {
|
|
3
|
-
sm: string;
|
|
4
|
-
md: string;
|
|
5
|
-
lg: string;
|
|
6
|
-
};
|
|
7
|
-
variant: {
|
|
8
|
-
default: string;
|
|
9
|
-
primary: string;
|
|
10
|
-
success: string;
|
|
11
|
-
error: string;
|
|
12
|
-
warning: string;
|
|
13
|
-
};
|
|
14
|
-
prompt: {
|
|
15
|
-
true: string;
|
|
16
|
-
false: string;
|
|
17
|
-
};
|
|
18
|
-
}, undefined, "pxd-snippet pr-12 relative flex items-center rounded-lg border motion-safe:transition-all", {
|
|
19
|
-
size: {
|
|
20
|
-
sm: string;
|
|
21
|
-
md: string;
|
|
22
|
-
lg: string;
|
|
23
|
-
};
|
|
24
|
-
variant: {
|
|
25
|
-
default: string;
|
|
26
|
-
primary: string;
|
|
27
|
-
success: string;
|
|
28
|
-
error: string;
|
|
29
|
-
warning: string;
|
|
30
|
-
};
|
|
31
|
-
prompt: {
|
|
32
|
-
true: string;
|
|
33
|
-
false: string;
|
|
34
|
-
};
|
|
35
|
-
}, undefined, import("tailwind-variants").TVReturnType<{
|
|
36
|
-
size: {
|
|
37
|
-
sm: string;
|
|
38
|
-
md: string;
|
|
39
|
-
lg: string;
|
|
40
|
-
};
|
|
41
|
-
variant: {
|
|
42
|
-
default: string;
|
|
43
|
-
primary: string;
|
|
44
|
-
success: string;
|
|
45
|
-
error: string;
|
|
46
|
-
warning: string;
|
|
47
|
-
};
|
|
48
|
-
prompt: {
|
|
49
|
-
true: string;
|
|
50
|
-
false: string;
|
|
51
|
-
};
|
|
52
|
-
}, undefined, "pxd-snippet pr-12 relative flex items-center rounded-lg border motion-safe:transition-all", unknown, unknown, undefined>>;
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import { tv } from "tailwind-variants";
|
|
2
|
-
export const snippetVariant = tv({
|
|
3
|
-
base: "pxd-snippet pr-12 relative flex items-center rounded-lg border motion-safe:transition-all",
|
|
4
|
-
variants: {
|
|
5
|
-
size: {
|
|
6
|
-
sm: "min-h-7.5 pl-3.5 pr-1.5 py-2 text-sm",
|
|
7
|
-
md: "min-h-9 pl-3.5 pr-2.5 py-2.5 text-sm",
|
|
8
|
-
lg: "min-h-10 pl-3.5 pr-3.5 py-3 text-base"
|
|
9
|
-
},
|
|
10
|
-
variant: {
|
|
11
|
-
default: "border-gray-alpha-300 bg-background-100",
|
|
12
|
-
primary: "border-gray-alpha-300 bg-primary text-gray-100",
|
|
13
|
-
success: "border-gray-alpha-300 bg-blue-200 text-blue-900",
|
|
14
|
-
error: "border-gray-alpha-300 bg-red-200 text-red-900",
|
|
15
|
-
warning: "border-gray-alpha-300 bg-amber-200 text-amber-900"
|
|
16
|
-
},
|
|
17
|
-
prompt: {
|
|
18
|
-
true: "pxd-snippet--prompt",
|
|
19
|
-
false: ""
|
|
20
|
-
}
|
|
21
|
-
},
|
|
22
|
-
defaultVariants: {
|
|
23
|
-
size: "md",
|
|
24
|
-
variant: "default",
|
|
25
|
-
prompt: false
|
|
26
|
-
}
|
|
27
|
-
});
|
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
export declare const stackVariant: import("tailwind-variants").TVReturnType<{
|
|
2
|
-
wrap: {
|
|
3
|
-
true: string;
|
|
4
|
-
false: string;
|
|
5
|
-
};
|
|
6
|
-
align: {
|
|
7
|
-
start: string;
|
|
8
|
-
end: string;
|
|
9
|
-
center: string;
|
|
10
|
-
between: string;
|
|
11
|
-
around: string;
|
|
12
|
-
evenly: string;
|
|
13
|
-
stretch: string;
|
|
14
|
-
};
|
|
15
|
-
justify: {
|
|
16
|
-
start: string;
|
|
17
|
-
end: string;
|
|
18
|
-
center: string;
|
|
19
|
-
between: string;
|
|
20
|
-
around: string;
|
|
21
|
-
evenly: string;
|
|
22
|
-
stretch: string;
|
|
23
|
-
};
|
|
24
|
-
}, undefined, "pxd-stack flex max-w-full gap-(--xs) [--xs:1rem]", {
|
|
25
|
-
wrap: {
|
|
26
|
-
true: string;
|
|
27
|
-
false: string;
|
|
28
|
-
};
|
|
29
|
-
align: {
|
|
30
|
-
start: string;
|
|
31
|
-
end: string;
|
|
32
|
-
center: string;
|
|
33
|
-
between: string;
|
|
34
|
-
around: string;
|
|
35
|
-
evenly: string;
|
|
36
|
-
stretch: string;
|
|
37
|
-
};
|
|
38
|
-
justify: {
|
|
39
|
-
start: string;
|
|
40
|
-
end: string;
|
|
41
|
-
center: string;
|
|
42
|
-
between: string;
|
|
43
|
-
around: string;
|
|
44
|
-
evenly: string;
|
|
45
|
-
stretch: string;
|
|
46
|
-
};
|
|
47
|
-
}, undefined, import("tailwind-variants").TVReturnType<{
|
|
48
|
-
wrap: {
|
|
49
|
-
true: string;
|
|
50
|
-
false: string;
|
|
51
|
-
};
|
|
52
|
-
align: {
|
|
53
|
-
start: string;
|
|
54
|
-
end: string;
|
|
55
|
-
center: string;
|
|
56
|
-
between: string;
|
|
57
|
-
around: string;
|
|
58
|
-
evenly: string;
|
|
59
|
-
stretch: string;
|
|
60
|
-
};
|
|
61
|
-
justify: {
|
|
62
|
-
start: string;
|
|
63
|
-
end: string;
|
|
64
|
-
center: string;
|
|
65
|
-
between: string;
|
|
66
|
-
around: string;
|
|
67
|
-
evenly: string;
|
|
68
|
-
stretch: string;
|
|
69
|
-
};
|
|
70
|
-
}, undefined, "pxd-stack flex max-w-full gap-(--xs) [--xs:1rem]", unknown, unknown, undefined>>;
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import { tv } from "tailwind-variants";
|
|
2
|
-
export const stackVariant = tv({
|
|
3
|
-
base: "pxd-stack flex max-w-full gap-(--xs) [--xs:1rem]",
|
|
4
|
-
variants: {
|
|
5
|
-
wrap: {
|
|
6
|
-
true: "flex-wrap",
|
|
7
|
-
false: ""
|
|
8
|
-
},
|
|
9
|
-
align: {
|
|
10
|
-
start: "items-start",
|
|
11
|
-
end: "items-end",
|
|
12
|
-
center: "items-center",
|
|
13
|
-
between: "items-between",
|
|
14
|
-
around: "items-around",
|
|
15
|
-
evenly: "items-evenly",
|
|
16
|
-
stretch: "items-stretch"
|
|
17
|
-
},
|
|
18
|
-
justify: {
|
|
19
|
-
start: "flex-start",
|
|
20
|
-
end: "flex-end",
|
|
21
|
-
center: "justify-center",
|
|
22
|
-
between: "justify-between",
|
|
23
|
-
around: "justify-around",
|
|
24
|
-
evenly: "justify-evenly",
|
|
25
|
-
stretch: "justify-stretch"
|
|
26
|
-
}
|
|
27
|
-
},
|
|
28
|
-
defaultVariants: {
|
|
29
|
-
wrap: true,
|
|
30
|
-
align: "start",
|
|
31
|
-
justify: "start"
|
|
32
|
-
}
|
|
33
|
-
});
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
export declare const switchVariant: import("tailwind-variants").TVReturnType<{
|
|
2
|
-
disabled: {
|
|
3
|
-
true: string;
|
|
4
|
-
false: string;
|
|
5
|
-
};
|
|
6
|
-
}, undefined, "pxd-switch--label px-3 text-sm font-medium flex size-full items-center justify-center truncate rounded-sm text-foreground-secondary peer-focus-ring select-none peer-checked:bg-gray-100 peer-disabled:cursor-not-allowed peer-disabled:text-gray-800 empty:hidden motion-safe:transition-all", {
|
|
7
|
-
disabled: {
|
|
8
|
-
true: string;
|
|
9
|
-
false: string;
|
|
10
|
-
};
|
|
11
|
-
}, undefined, import("tailwind-variants").TVReturnType<{
|
|
12
|
-
disabled: {
|
|
13
|
-
true: string;
|
|
14
|
-
false: string;
|
|
15
|
-
};
|
|
16
|
-
}, undefined, "pxd-switch--label px-3 text-sm font-medium flex size-full items-center justify-center truncate rounded-sm text-foreground-secondary peer-focus-ring select-none peer-checked:bg-gray-100 peer-disabled:cursor-not-allowed peer-disabled:text-gray-800 empty:hidden motion-safe:transition-all", unknown, unknown, undefined>>;
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { tv } from "tailwind-variants";
|
|
2
|
-
export const switchVariant = tv({
|
|
3
|
-
base: "pxd-switch--label px-3 text-sm font-medium flex size-full items-center justify-center truncate rounded-sm text-foreground-secondary peer-focus-ring select-none peer-checked:bg-gray-100 peer-disabled:cursor-not-allowed peer-disabled:text-gray-800 empty:hidden motion-safe:transition-all",
|
|
4
|
-
variants: {
|
|
5
|
-
disabled: {
|
|
6
|
-
true: "",
|
|
7
|
-
false: "peer-checked:text-foreground"
|
|
8
|
-
}
|
|
9
|
-
},
|
|
10
|
-
defaultVariants: {
|
|
11
|
-
disabled: false
|
|
12
|
-
}
|
|
13
|
-
});
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import type { SwitchGroupProps } from '../switch/types';
|
|
2
|
-
declare var __VLS_1: {};
|
|
3
|
-
type __VLS_Slots = {} & {
|
|
4
|
-
default?: (props: typeof __VLS_1) => any;
|
|
5
|
-
};
|
|
6
|
-
declare const __VLS_base: import("vue").DefineComponent<SwitchGroupProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
7
|
-
change: (args_0: NonNullable<string | number | undefined>) => any;
|
|
8
|
-
"update:modelValue": (args_0: NonNullable<string | number | undefined>) => any;
|
|
9
|
-
}, string, import("vue").PublicProps, Readonly<SwitchGroupProps> & Readonly<{
|
|
10
|
-
onChange?: ((args_0: NonNullable<string | number | undefined>) => any) | undefined;
|
|
11
|
-
"onUpdate:modelValue"?: ((args_0: NonNullable<string | number | undefined>) => any) | undefined;
|
|
12
|
-
}>, {
|
|
13
|
-
options: import("../../types/shared").ComponentOption[];
|
|
14
|
-
modelValue: string | number;
|
|
15
|
-
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
16
|
-
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
17
|
-
declare const _default: typeof __VLS_export;
|
|
18
|
-
export default _default;
|
|
19
|
-
type __VLS_WithSlots<T, S> = T & {
|
|
20
|
-
new (): {
|
|
21
|
-
$slots: S;
|
|
22
|
-
};
|
|
23
|
-
};
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
<script setup>
|
|
2
|
-
import { computed } from "vue";
|
|
3
|
-
import { useConfigProvider } from "../../composables/use-config-provider-context";
|
|
4
|
-
import { useModelValue } from "../../composables/use-model-value";
|
|
5
|
-
import { provideUniqueId } from "../../composables/use-unique-id-context";
|
|
6
|
-
import { provideSwitchGroupContext, provideSwitchGroupModelValue } from "../../contexts/switch";
|
|
7
|
-
import { getFallbackValue } from "../../utils/get";
|
|
8
|
-
import PSwitch from "../switch/index.vue";
|
|
9
|
-
defineOptions({
|
|
10
|
-
name: "PSwitchGroup",
|
|
11
|
-
model: {
|
|
12
|
-
prop: "modelValue",
|
|
13
|
-
event: "update:modelValue"
|
|
14
|
-
}
|
|
15
|
-
});
|
|
16
|
-
const props = defineProps({
|
|
17
|
-
disabled: { type: Boolean, required: false },
|
|
18
|
-
required: { type: Boolean, required: false },
|
|
19
|
-
fullWidth: { type: Boolean, required: false },
|
|
20
|
-
size: { type: String, required: false },
|
|
21
|
-
options: { type: Array, required: false, default: () => [] },
|
|
22
|
-
modelValue: { type: [String, Number], required: false, default: "" }
|
|
23
|
-
});
|
|
24
|
-
const emits = defineEmits(["change", "update:modelValue"]);
|
|
25
|
-
const SIZES = {
|
|
26
|
-
sm: "h-7.5",
|
|
27
|
-
md: "h-9",
|
|
28
|
-
lg: "h-10"
|
|
29
|
-
};
|
|
30
|
-
const configProvider = useConfigProvider();
|
|
31
|
-
const modelValue = useModelValue(props, emits);
|
|
32
|
-
const computedSize = computed(() => getFallbackValue(props.size, SIZES, configProvider.size));
|
|
33
|
-
provideUniqueId("SwitchGroupName");
|
|
34
|
-
provideSwitchGroupContext(props);
|
|
35
|
-
provideSwitchGroupModelValue(modelValue);
|
|
36
|
-
</script>
|
|
37
|
-
|
|
38
|
-
<template>
|
|
39
|
-
<div
|
|
40
|
-
class="pxd-switch-group p-1 flex touch-manipulation rounded-md border"
|
|
41
|
-
:class="[fullWidth ? 'w-full' : 'w-max', computedSize]"
|
|
42
|
-
>
|
|
43
|
-
<slot>
|
|
44
|
-
<PSwitch
|
|
45
|
-
v-for="option in options"
|
|
46
|
-
:key="option.value"
|
|
47
|
-
v-model="modelValue"
|
|
48
|
-
:label="option.label"
|
|
49
|
-
:value="option.value"
|
|
50
|
-
:disabled="option.disabled"
|
|
51
|
-
/>
|
|
52
|
-
</slot>
|
|
53
|
-
</div>
|
|
54
|
-
</template>
|
|
@@ -1,67 +0,0 @@
|
|
|
1
|
-
export declare const textVariant: import("tailwind-variants").TVReturnType<{
|
|
2
|
-
align: {
|
|
3
|
-
left: string;
|
|
4
|
-
center: string;
|
|
5
|
-
right: string;
|
|
6
|
-
};
|
|
7
|
-
monospace: {
|
|
8
|
-
true: string;
|
|
9
|
-
false: string;
|
|
10
|
-
};
|
|
11
|
-
secondary: {
|
|
12
|
-
true: string;
|
|
13
|
-
false: string;
|
|
14
|
-
};
|
|
15
|
-
truncate: {
|
|
16
|
-
true: string;
|
|
17
|
-
false: string;
|
|
18
|
-
};
|
|
19
|
-
lineClamp: {
|
|
20
|
-
true: string;
|
|
21
|
-
false: string;
|
|
22
|
-
};
|
|
23
|
-
}, undefined, "pxd-text m-0", {
|
|
24
|
-
align: {
|
|
25
|
-
left: string;
|
|
26
|
-
center: string;
|
|
27
|
-
right: string;
|
|
28
|
-
};
|
|
29
|
-
monospace: {
|
|
30
|
-
true: string;
|
|
31
|
-
false: string;
|
|
32
|
-
};
|
|
33
|
-
secondary: {
|
|
34
|
-
true: string;
|
|
35
|
-
false: string;
|
|
36
|
-
};
|
|
37
|
-
truncate: {
|
|
38
|
-
true: string;
|
|
39
|
-
false: string;
|
|
40
|
-
};
|
|
41
|
-
lineClamp: {
|
|
42
|
-
true: string;
|
|
43
|
-
false: string;
|
|
44
|
-
};
|
|
45
|
-
}, undefined, import("tailwind-variants").TVReturnType<{
|
|
46
|
-
align: {
|
|
47
|
-
left: string;
|
|
48
|
-
center: string;
|
|
49
|
-
right: string;
|
|
50
|
-
};
|
|
51
|
-
monospace: {
|
|
52
|
-
true: string;
|
|
53
|
-
false: string;
|
|
54
|
-
};
|
|
55
|
-
secondary: {
|
|
56
|
-
true: string;
|
|
57
|
-
false: string;
|
|
58
|
-
};
|
|
59
|
-
truncate: {
|
|
60
|
-
true: string;
|
|
61
|
-
false: string;
|
|
62
|
-
};
|
|
63
|
-
lineClamp: {
|
|
64
|
-
true: string;
|
|
65
|
-
false: string;
|
|
66
|
-
};
|
|
67
|
-
}, undefined, "pxd-text m-0", unknown, unknown, undefined>>;
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
import { tv } from "tailwind-variants";
|
|
2
|
-
export const textVariant = tv({
|
|
3
|
-
base: "pxd-text m-0",
|
|
4
|
-
variants: {
|
|
5
|
-
align: {
|
|
6
|
-
left: "text-left",
|
|
7
|
-
center: "text-center",
|
|
8
|
-
right: "text-right"
|
|
9
|
-
},
|
|
10
|
-
monospace: {
|
|
11
|
-
true: "font-mono",
|
|
12
|
-
false: ""
|
|
13
|
-
},
|
|
14
|
-
secondary: {
|
|
15
|
-
true: "text-foreground-secondary",
|
|
16
|
-
false: ""
|
|
17
|
-
},
|
|
18
|
-
truncate: {
|
|
19
|
-
true: "truncate",
|
|
20
|
-
false: ""
|
|
21
|
-
},
|
|
22
|
-
lineClamp: {
|
|
23
|
-
true: "line-clamp",
|
|
24
|
-
false: ""
|
|
25
|
-
}
|
|
26
|
-
},
|
|
27
|
-
defaultVariants: {
|
|
28
|
-
align: "left",
|
|
29
|
-
monospace: false,
|
|
30
|
-
secondary: false,
|
|
31
|
-
truncate: false,
|
|
32
|
-
lineClamp: false
|
|
33
|
-
}
|
|
34
|
-
});
|
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
export declare const textareaVariant: import("tailwind-variants").TVReturnType<{
|
|
2
|
-
size: {
|
|
3
|
-
xs: string;
|
|
4
|
-
sm: string;
|
|
5
|
-
md: string;
|
|
6
|
-
lg: string;
|
|
7
|
-
};
|
|
8
|
-
disabled: {
|
|
9
|
-
true: string;
|
|
10
|
-
false: string;
|
|
11
|
-
};
|
|
12
|
-
readonly: {
|
|
13
|
-
true: string;
|
|
14
|
-
false: string;
|
|
15
|
-
};
|
|
16
|
-
error: {
|
|
17
|
-
true: string;
|
|
18
|
-
false: string;
|
|
19
|
-
};
|
|
20
|
-
}, undefined, "", {
|
|
21
|
-
size: {
|
|
22
|
-
xs: string;
|
|
23
|
-
sm: string;
|
|
24
|
-
md: string;
|
|
25
|
-
lg: string;
|
|
26
|
-
};
|
|
27
|
-
disabled: {
|
|
28
|
-
true: string;
|
|
29
|
-
false: string;
|
|
30
|
-
};
|
|
31
|
-
readonly: {
|
|
32
|
-
true: string;
|
|
33
|
-
false: string;
|
|
34
|
-
};
|
|
35
|
-
error: {
|
|
36
|
-
true: string;
|
|
37
|
-
false: string;
|
|
38
|
-
};
|
|
39
|
-
}, undefined, import("tailwind-variants").TVReturnType<{
|
|
40
|
-
size: {
|
|
41
|
-
xs: string;
|
|
42
|
-
sm: string;
|
|
43
|
-
md: string;
|
|
44
|
-
lg: string;
|
|
45
|
-
};
|
|
46
|
-
disabled: {
|
|
47
|
-
true: string;
|
|
48
|
-
false: string;
|
|
49
|
-
};
|
|
50
|
-
readonly: {
|
|
51
|
-
true: string;
|
|
52
|
-
false: string;
|
|
53
|
-
};
|
|
54
|
-
error: {
|
|
55
|
-
true: string;
|
|
56
|
-
false: string;
|
|
57
|
-
};
|
|
58
|
-
}, undefined, "", unknown, unknown, undefined>>;
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import { tv } from "tailwind-variants";
|
|
2
|
-
export const textareaVariant = tv({
|
|
3
|
-
base: "",
|
|
4
|
-
variants: {
|
|
5
|
-
size: {
|
|
6
|
-
xs: "text-xs",
|
|
7
|
-
sm: "text-sm",
|
|
8
|
-
md: "text-sm",
|
|
9
|
-
lg: "text-base"
|
|
10
|
-
},
|
|
11
|
-
disabled: {
|
|
12
|
-
true: "is-disabled",
|
|
13
|
-
false: ""
|
|
14
|
-
},
|
|
15
|
-
readonly: {
|
|
16
|
-
true: "is-readonly",
|
|
17
|
-
false: ""
|
|
18
|
-
},
|
|
19
|
-
error: {
|
|
20
|
-
true: "is-error",
|
|
21
|
-
false: ""
|
|
22
|
-
}
|
|
23
|
-
},
|
|
24
|
-
defaultVariants: {
|
|
25
|
-
size: "md",
|
|
26
|
-
disabled: false,
|
|
27
|
-
readonly: false,
|
|
28
|
-
error: false
|
|
29
|
-
}
|
|
30
|
-
});
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
import type { ConfigProviderProps } from '../components/config-provider/types';
|
|
2
|
-
export declare const injectionKey = "ConfigProvider";
|
|
3
|
-
export declare const provideConfigProvider: (contextValue: Required<ConfigProviderProps>) => Required<ConfigProviderProps>, useConfigProvider: ((fallback?: Required<ConfigProviderProps> | undefined) => Required<ConfigProviderProps>) & ((fallback: null) => Required<ConfigProviderProps> | null);
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { inject, provide } from "vue";
|
|
2
|
-
import { getUniqueId } from "../utils/uid.js";
|
|
3
|
-
export function provideUniqueId(injectionKey = "uniqueId") {
|
|
4
|
-
const uniqueId = getUniqueId();
|
|
5
|
-
provide(injectionKey, uniqueId);
|
|
6
|
-
return uniqueId;
|
|
7
|
-
}
|
|
8
|
-
export function useUniqueId(injectionKey = "uniqueId") {
|
|
9
|
-
const injectedValue = inject(injectionKey, getUniqueId());
|
|
10
|
-
return injectedValue;
|
|
11
|
-
}
|