@una-ui/nuxt-edge 0.61.0-29182246.bc2c328 → 1.0.0-alpha.0-29173950.b6a8c03

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.
Files changed (49) hide show
  1. package/dist/module.json +1 -1
  2. package/dist/module.mjs +2 -2
  3. package/dist/runtime/components/alert-dialog/AlertDialogCancel.vue +1 -1
  4. package/dist/runtime/components/combobox/Combobox.vue +2 -1
  5. package/dist/runtime/components/combobox/ComboboxTrigger.vue +1 -1
  6. package/dist/runtime/components/data/table/Table.vue +0 -1
  7. package/dist/runtime/components/elements/Skeleton.vue +1 -1
  8. package/dist/runtime/components/elements/Skeleton.vue.d.ts +3 -1
  9. package/dist/runtime/components/elements/tabs/TabsTrigger.vue +1 -1
  10. package/dist/runtime/components/forms/Checkbox.vue +2 -2
  11. package/dist/runtime/components/forms/Checkbox.vue.d.ts +2 -0
  12. package/dist/runtime/components/forms/FormGroup.vue +1 -1
  13. package/dist/runtime/components/forms/Slider.vue +13 -11
  14. package/dist/runtime/components/forms/Slider.vue.d.ts +1 -0
  15. package/dist/runtime/components/forms/form/FormField.vue +1 -1
  16. package/dist/runtime/components/forms/select/SelectTrigger.vue +1 -1
  17. package/dist/runtime/components/misc/ThemeSwitcher.vue +75 -17
  18. package/dist/runtime/components/navigation/breadcrumb/BreadcrumbPage.vue +1 -1
  19. package/dist/runtime/components/sidebar/SidebarMenuSubButton.vue +2 -1
  20. package/dist/runtime/composables/useUnaSettings.js +11 -7
  21. package/dist/runtime/composables/useUnaThemes.d.ts +77 -5
  22. package/dist/runtime/composables/useUnaThemes.js +414 -98
  23. package/dist/runtime/plugins/theme.client.js +12 -0
  24. package/dist/runtime/plugins/theme.server.js +9 -0
  25. package/dist/runtime/types/index.d.ts +7 -2
  26. package/dist/runtime/types/index.js +0 -2
  27. package/package.json +10 -10
  28. package/dist/runtime/components/number-field/NumberField.vue +0 -73
  29. package/dist/runtime/components/number-field/NumberField.vue.d.ts +0 -28
  30. package/dist/runtime/components/number-field/NumberFieldContent.vue +0 -20
  31. package/dist/runtime/components/number-field/NumberFieldContent.vue.d.ts +0 -13
  32. package/dist/runtime/components/number-field/NumberFieldDecrement.vue +0 -33
  33. package/dist/runtime/components/number-field/NumberFieldDecrement.vue.d.ts +0 -16
  34. package/dist/runtime/components/number-field/NumberFieldIncrement.vue +0 -33
  35. package/dist/runtime/components/number-field/NumberFieldIncrement.vue.d.ts +0 -16
  36. package/dist/runtime/components/number-field/NumberFieldInput.vue +0 -24
  37. package/dist/runtime/components/number-field/NumberFieldInput.vue.d.ts +0 -5
  38. package/dist/runtime/components/pin-input/PinInput.vue +0 -139
  39. package/dist/runtime/components/pin-input/PinInput.vue.d.ts +0 -33
  40. package/dist/runtime/components/pin-input/PinInputGroup.vue +0 -28
  41. package/dist/runtime/components/pin-input/PinInputGroup.vue.d.ts +0 -13
  42. package/dist/runtime/components/pin-input/PinInputSeparator.vue +0 -30
  43. package/dist/runtime/components/pin-input/PinInputSeparator.vue.d.ts +0 -15
  44. package/dist/runtime/components/pin-input/PinInputSlot.vue +0 -46
  45. package/dist/runtime/components/pin-input/PinInputSlot.vue.d.ts +0 -5
  46. package/dist/runtime/types/number-field.d.ts +0 -48
  47. package/dist/runtime/types/number-field.js +0 -0
  48. package/dist/runtime/types/pin-input.d.ts +0 -88
  49. package/dist/runtime/types/pin-input.js +0 -0
@@ -1,73 +0,0 @@
1
- <script setup>
2
- import { reactiveOmit } from "@vueuse/core";
3
- import { NumberFieldRoot, useForwardPropsEmits } from "reka-ui";
4
- import { cn } from "../../utils";
5
- import NumberFieldContent from "./NumberFieldContent.vue";
6
- const props = defineProps({
7
- numberField: { type: null, required: false, default: "outline-primary" },
8
- _numberFieldContent: { type: Object, required: false },
9
- _numberFieldDecrement: { type: Object, required: false },
10
- _numberFieldIncrement: { type: Object, required: false },
11
- _numberFieldInput: { type: Object, required: false },
12
- una: { type: Object, required: false },
13
- defaultValue: { type: Number, required: false },
14
- modelValue: { type: [Number, null], required: false },
15
- min: { type: Number, required: false },
16
- max: { type: Number, required: false },
17
- step: { type: Number, required: false },
18
- stepSnapping: { type: Boolean, required: false },
19
- formatOptions: { type: null, required: false },
20
- locale: { type: String, required: false },
21
- disabled: { type: Boolean, required: false },
22
- disableWheelChange: { type: Boolean, required: false },
23
- invertWheelChange: { type: Boolean, required: false },
24
- id: { type: String, required: false },
25
- asChild: { type: Boolean, required: false },
26
- as: { type: [String, Object, Function], required: false },
27
- name: { type: String, required: false },
28
- required: { type: Boolean, required: false },
29
- leading: { type: String, required: false, default: "i-lucide-minus" },
30
- trailing: { type: String, required: false, default: "i-lucide-plus" },
31
- class: { type: null, required: false },
32
- size: { type: null, required: false, default: "md" }
33
- });
34
- const emits = defineEmits(["update:modelValue"]);
35
- const delegatedProps = reactiveOmit(props, "class", "numberField");
36
- const forwarded = useForwardPropsEmits(delegatedProps, emits);
37
- </script>
38
-
39
- <template>
40
- <NumberFieldRoot
41
- v-bind="forwarded"
42
- :class="cn('number-field', props.class)"
43
- >
44
- <slot>
45
- <NumberFieldContent :size>
46
- <slot name="content">
47
- <NNumberFieldDecrement
48
- v-bind="forwarded._numberFieldDecrement"
49
- :icon="props.leading"
50
- :size
51
- :una
52
- >
53
- <slot name="decrement" />
54
- </NNumberFieldDecrement>
55
- <NNumberFieldInput
56
- v-bind="forwarded._numberFieldInput"
57
- :size
58
- :number-field
59
- :una
60
- />
61
- <NNumberFieldIncrement
62
- v-bind="forwarded._numberFieldIncrement"
63
- :icon="props.trailing"
64
- :size
65
- :una
66
- >
67
- <slot name="increment" />
68
- </NNumberFieldIncrement>
69
- </slot>
70
- </NumberFieldContent>
71
- </slot>
72
- </NumberFieldRoot>
73
- </template>
@@ -1,28 +0,0 @@
1
- import type { NNumberFieldProps } from '../../types/index.js';
2
- declare var __VLS_6: {}, __VLS_11: {}, __VLS_17: {}, __VLS_27: {};
3
- type __VLS_Slots = {} & {
4
- default?: (props: typeof __VLS_6) => any;
5
- } & {
6
- content?: (props: typeof __VLS_11) => any;
7
- } & {
8
- decrement?: (props: typeof __VLS_17) => any;
9
- } & {
10
- increment?: (props: typeof __VLS_27) => any;
11
- };
12
- declare const __VLS_component: import("vue").DefineComponent<NNumberFieldProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
13
- "update:modelValue": (val: number) => any;
14
- }, string, import("vue").PublicProps, Readonly<NNumberFieldProps> & Readonly<{
15
- "onUpdate:modelValue"?: ((val: number) => any) | undefined;
16
- }>, {
17
- leading: string;
18
- trailing: string;
19
- size: import("vue").HTMLAttributes["class"];
20
- numberField: import("vue").HTMLAttributes["class"];
21
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
22
- declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
23
- export default _default;
24
- type __VLS_WithSlots<T, S> = T & {
25
- new (): {
26
- $slots: S;
27
- };
28
- };
@@ -1,20 +0,0 @@
1
- <script setup>
2
- import { cn } from "../../utils";
3
- const props = defineProps({
4
- una: { type: Object, required: false },
5
- class: { type: null, required: false },
6
- size: { type: null, required: false }
7
- });
8
- </script>
9
-
10
- <template>
11
- <div
12
- :class="cn(
13
- 'number-field-content',
14
- props.una?.numberFieldContent,
15
- props.class
16
- )"
17
- >
18
- <slot />
19
- </div>
20
- </template>
@@ -1,13 +0,0 @@
1
- import type { NNumberFieldContentProps } from '../../types/index.js';
2
- declare var __VLS_1: {};
3
- type __VLS_Slots = {} & {
4
- default?: (props: typeof __VLS_1) => any;
5
- };
6
- declare const __VLS_component: import("vue").DefineComponent<NNumberFieldContentProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<NNumberFieldContentProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
7
- declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
8
- export default _default;
9
- type __VLS_WithSlots<T, S> = T & {
10
- new (): {
11
- $slots: S;
12
- };
13
- };
@@ -1,33 +0,0 @@
1
- <script setup>
2
- import { reactiveOmit } from "@vueuse/core";
3
- import { NumberFieldDecrement, useForwardProps } from "reka-ui";
4
- import { cn } from "../../utils";
5
- import Icon from "../elements/Icon.vue";
6
- const props = defineProps({
7
- icon: { type: String, required: false, default: "i-lucide-minus" },
8
- una: { type: Object, required: false },
9
- disabled: { type: Boolean, required: false },
10
- asChild: { type: Boolean, required: false },
11
- as: { type: [String, Object, Function], required: false },
12
- class: { type: null, required: false },
13
- size: { type: null, required: false, default: "md" }
14
- });
15
- const delegatedProps = reactiveOmit(props, "class");
16
- const forwarded = useForwardProps(delegatedProps);
17
- </script>
18
-
19
- <template>
20
- <NumberFieldDecrement
21
- data-slot="decrement"
22
- v-bind="forwarded"
23
- :class="cn(
24
- 'number-field-decrement',
25
- props.una?.numberFieldDecrement,
26
- props.class
27
- )"
28
- >
29
- <slot>
30
- <Icon :name="icon" />
31
- </slot>
32
- </NumberFieldDecrement>
33
- </template>
@@ -1,16 +0,0 @@
1
- import type { NNumberFieldDecrementProps } from '../../types/index.js';
2
- declare var __VLS_6: {};
3
- type __VLS_Slots = {} & {
4
- default?: (props: typeof __VLS_6) => any;
5
- };
6
- declare const __VLS_component: import("vue").DefineComponent<NNumberFieldDecrementProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<NNumberFieldDecrementProps> & Readonly<{}>, {
7
- icon: string;
8
- size: import("vue").HTMLAttributes["class"];
9
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
10
- declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
11
- export default _default;
12
- type __VLS_WithSlots<T, S> = T & {
13
- new (): {
14
- $slots: S;
15
- };
16
- };
@@ -1,33 +0,0 @@
1
- <script setup>
2
- import { reactiveOmit } from "@vueuse/core";
3
- import { NumberFieldIncrement, useForwardProps } from "reka-ui";
4
- import { cn } from "../../utils";
5
- import Icon from "../elements/Icon.vue";
6
- const props = defineProps({
7
- icon: { type: String, required: false, default: "i-lucide-plus" },
8
- una: { type: Object, required: false },
9
- disabled: { type: Boolean, required: false },
10
- asChild: { type: Boolean, required: false },
11
- as: { type: [String, Object, Function], required: false },
12
- class: { type: null, required: false },
13
- size: { type: null, required: false, default: "md" }
14
- });
15
- const delegatedProps = reactiveOmit(props, "class");
16
- const forwarded = useForwardProps(delegatedProps);
17
- </script>
18
-
19
- <template>
20
- <NumberFieldIncrement
21
- data-slot="increment"
22
- v-bind="forwarded"
23
- :class="cn(
24
- 'number-field-increment',
25
- props.una?.numberFieldIncrement,
26
- props.class
27
- )"
28
- >
29
- <slot>
30
- <Icon :name="icon" />
31
- </slot>
32
- </NumberFieldIncrement>
33
- </template>
@@ -1,16 +0,0 @@
1
- import type { NNumberFieldIncrementProps } from '../../types/index.js';
2
- declare var __VLS_6: {};
3
- type __VLS_Slots = {} & {
4
- default?: (props: typeof __VLS_6) => any;
5
- };
6
- declare const __VLS_component: import("vue").DefineComponent<NNumberFieldIncrementProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<NNumberFieldIncrementProps> & Readonly<{}>, {
7
- icon: string;
8
- size: import("vue").HTMLAttributes["class"];
9
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
10
- declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
11
- export default _default;
12
- type __VLS_WithSlots<T, S> = T & {
13
- new (): {
14
- $slots: S;
15
- };
16
- };
@@ -1,24 +0,0 @@
1
- <script setup>
2
- import { NumberFieldInput } from "reka-ui";
3
- import { cn } from "../../utils";
4
- const props = defineProps({
5
- una: { type: Object, required: false },
6
- asChild: { type: Boolean, required: false },
7
- as: { type: [String, Object, Function], required: false },
8
- class: { type: null, required: false },
9
- size: { type: null, required: false },
10
- numberField: { type: null, required: false, default: "outline-primary" }
11
- });
12
- </script>
13
-
14
- <template>
15
- <NumberFieldInput
16
- data-slot="input"
17
- :class="cn(
18
- 'number-field-input',
19
- props.una?.numberFieldInput,
20
- props.class
21
- )"
22
- :number-field
23
- />
24
- </template>
@@ -1,5 +0,0 @@
1
- import type { NNumberFieldInputProps } from '../../types/index.js';
2
- declare const _default: import("vue").DefineComponent<NNumberFieldInputProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<NNumberFieldInputProps> & Readonly<{}>, {
3
- numberField: import("vue").HTMLAttributes["class"];
4
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
5
- export default _default;
@@ -1,139 +0,0 @@
1
- <script>
2
-
3
- </script>
4
-
5
- <script setup>
6
- import { reactivePick } from "@vueuse/core";
7
- import { PinInputRoot, useForwardPropsEmits } from "reka-ui";
8
- import { computed } from "vue";
9
- import { cn, randomId } from "../../utils";
10
- import PinInputGroup from "./PinInputGroup.vue";
11
- import PinInputSeparator from "./PinInputSeparator.vue";
12
- import PinInputSlot from "./PinInputSlot.vue";
13
- const props = defineProps({
14
- defaultValue: { type: Array, required: false },
15
- maxLength: { type: Number, required: false },
16
- separator: { type: [Boolean, String], required: false, default: false },
17
- groupBy: { type: Number, required: false, default: 0 },
18
- _pinInputGroup: { type: Object, required: false },
19
- _pinInputSeparator: { type: Object, required: false },
20
- _pinInputSlot: { type: Object, required: false },
21
- una: { type: Object, required: false },
22
- modelValue: { type: null, required: false },
23
- placeholder: { type: String, required: false },
24
- mask: { type: Boolean, required: false },
25
- otp: { type: Boolean, required: false },
26
- type: { type: null, required: false, default: "text" },
27
- dir: { type: String, required: false },
28
- disabled: { type: Boolean, required: false },
29
- id: { type: String, required: false },
30
- asChild: { type: Boolean, required: false },
31
- as: { type: [String, Object, Function], required: false },
32
- name: { type: String, required: false },
33
- required: { type: Boolean, required: false },
34
- pinInput: { type: null, required: false, default: "outline-primary" },
35
- status: { type: String, required: false },
36
- class: { type: null, required: false },
37
- size: { type: null, required: false, default: "md" }
38
- });
39
- const emits = defineEmits(["update:modelValue", "complete"]);
40
- const rootProps = reactivePick(props, [
41
- "as",
42
- "asChild",
43
- "dir",
44
- "defaultValue",
45
- "disabled",
46
- "id",
47
- "mask",
48
- "modelValue",
49
- "name",
50
- "otp",
51
- "placeholder",
52
- "type",
53
- "required"
54
- ]);
55
- const forwarded = useForwardPropsEmits(rootProps, emits);
56
- const id = computed(() => props.id ?? randomId("pin-input"));
57
- const separator = computed(() => {
58
- if (props.separator === true) {
59
- return "pin-input-separator-icon";
60
- }
61
- return props.separator;
62
- });
63
- const maxLength = computed(() => {
64
- if (typeof props.maxLength !== "number") {
65
- return props.modelValue?.length ?? 0;
66
- }
67
- return props.maxLength;
68
- });
69
- </script>
70
-
71
- <template>
72
- <PinInputRoot
73
- v-bind="forwarded"
74
- :id
75
- data-slot="pin-input"
76
- :class="cn(
77
- 'pin-input',
78
- props.una?.pinInput,
79
- props.class
80
- )"
81
- :size
82
- >
83
- <slot>
84
- <template v-if="groupBy === 0">
85
- <PinInputGroup
86
- v-bind="_pinInputGroup"
87
- :una
88
- >
89
- <slot name="group">
90
- <template v-for="index in maxLength" :key="index">
91
- <slot name="slot" :index="index - 1">
92
- <PinInputSlot
93
- :index="index - 1"
94
- :una
95
- :status
96
- :pin-input
97
- v-bind="_pinInputSlot"
98
- />
99
- </slot>
100
- </template>
101
- </slot>
102
- </PinInputGroup>
103
- </template>
104
-
105
- <template v-else>
106
- <template v-for="(groupIndex) in Math.ceil(maxLength / groupBy)" :key="groupIndex">
107
- <PinInputGroup
108
- v-bind="_pinInputGroup"
109
- :una
110
- >
111
- <slot name="group">
112
- <template v-for="slotInGroup in Math.min(groupBy, maxLength - (groupIndex - 1) * groupBy)" :key="slotInGroup">
113
- <slot name="slot" :index="(groupIndex - 1) * groupBy + slotInGroup - 1">
114
- <PinInputSlot
115
- :index="(groupIndex - 1) * groupBy + slotInGroup - 1"
116
- :una
117
- :pin-input
118
- :status
119
- v-bind="_pinInputSlot"
120
- />
121
- </slot>
122
- </template>
123
- </slot>
124
- </PinInputGroup>
125
-
126
- <template v-if="separator !== false && (separator || $slots.separator) && groupIndex < Math.ceil(maxLength / groupBy)">
127
- <PinInputSeparator
128
- :icon="separator"
129
- :una
130
- v-bind="_pinInputSeparator"
131
- >
132
- <slot name="separator" />
133
- </PinInputSeparator>
134
- </template>
135
- </template>
136
- </template>
137
- </slot>
138
- </PinInputRoot>
139
- </template>
@@ -1,33 +0,0 @@
1
- import type { NPinInputProps, PinInputType } from '../../types/index.js';
2
- declare const _default: <T extends PinInputType = "text">(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
3
- props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{
4
- readonly "onUpdate:modelValue"?: ((value: string[]) => any) | undefined;
5
- readonly onComplete?: ((value: string[]) => any) | undefined;
6
- } & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, never>, "onUpdate:modelValue" | "onComplete"> & NPinInputProps<T> & Partial<{}>> & import("vue").PublicProps;
7
- expose(exposed: import("vue").ShallowUnwrapRef<{}>): void;
8
- attrs: any;
9
- slots: {
10
- default?: (props: {}) => any;
11
- } & {
12
- group?: (props: {}) => any;
13
- } & {
14
- slot?: (props: {
15
- index: number;
16
- }) => any;
17
- } & {
18
- group?: (props: {}) => any;
19
- } & {
20
- slot?: (props: {
21
- index: number;
22
- }) => any;
23
- } & {
24
- separator?: (props: {}) => any;
25
- };
26
- emit: ((evt: "update:modelValue", value: string[]) => void) & ((evt: "complete", value: string[]) => void);
27
- }>) => import("vue").VNode & {
28
- __ctx?: Awaited<typeof __VLS_setup>;
29
- };
30
- export default _default;
31
- type __VLS_PrettifyLocal<T> = {
32
- [K in keyof T]: T[K];
33
- } & {};
@@ -1,28 +0,0 @@
1
- <script setup>
2
- import { reactiveOmit } from "@vueuse/core";
3
- import { Primitive, useForwardProps } from "reka-ui";
4
- import { cn } from "../../utils";
5
- const props = defineProps({
6
- una: { type: Object, required: false },
7
- asChild: { type: Boolean, required: false },
8
- as: { type: [String, Object, Function], required: false },
9
- class: { type: null, required: false },
10
- size: { type: null, required: false }
11
- });
12
- const delegatedProps = reactiveOmit(props, "class");
13
- const forwardedProps = useForwardProps(delegatedProps);
14
- </script>
15
-
16
- <template>
17
- <Primitive
18
- data-slot="pin-input-group"
19
- v-bind="forwardedProps"
20
- :class="cn(
21
- 'pin-input-group',
22
- props.una?.pinInputGroup,
23
- props.class
24
- )"
25
- >
26
- <slot />
27
- </Primitive>
28
- </template>
@@ -1,13 +0,0 @@
1
- import type { NPinInputGroupProps } from '../../types/index.js';
2
- declare var __VLS_6: {};
3
- type __VLS_Slots = {} & {
4
- default?: (props: typeof __VLS_6) => any;
5
- };
6
- declare const __VLS_component: import("vue").DefineComponent<NPinInputGroupProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<NPinInputGroupProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
7
- declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
8
- export default _default;
9
- type __VLS_WithSlots<T, S> = T & {
10
- new (): {
11
- $slots: S;
12
- };
13
- };
@@ -1,30 +0,0 @@
1
- <script setup>
2
- import { Primitive, useForwardProps } from "reka-ui";
3
- import { cn } from "../../utils";
4
- import Icon from "../elements/Icon.vue";
5
- const props = defineProps({
6
- icon: { type: String, required: false, default: "i-lucide-minus" },
7
- una: { type: Object, required: false },
8
- asChild: { type: Boolean, required: false },
9
- as: { type: [String, Object, Function], required: false },
10
- class: { type: null, required: false },
11
- size: { type: null, required: false }
12
- });
13
- const forwardedProps = useForwardProps(props);
14
- </script>
15
-
16
- <template>
17
- <Primitive
18
- data-slot="pin-input-separator"
19
- v-bind="forwardedProps"
20
- :class="cn(
21
- 'pin-input-separator',
22
- props.una?.pinInputSeparator,
23
- props.class
24
- )"
25
- >
26
- <slot>
27
- <Icon :name="icon" />
28
- </slot>
29
- </Primitive>
30
- </template>
@@ -1,15 +0,0 @@
1
- import type { NPinInputSeparatorProps } from '../../types/index.js';
2
- declare var __VLS_6: {};
3
- type __VLS_Slots = {} & {
4
- default?: (props: typeof __VLS_6) => any;
5
- };
6
- declare const __VLS_component: import("vue").DefineComponent<NPinInputSeparatorProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<NPinInputSeparatorProps> & Readonly<{}>, {
7
- icon: string;
8
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
9
- declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
10
- export default _default;
11
- type __VLS_WithSlots<T, S> = T & {
12
- new (): {
13
- $slots: S;
14
- };
15
- };
@@ -1,46 +0,0 @@
1
- <script setup>
2
- import { reactiveOmit } from "@vueuse/core";
3
- import { PinInputInput, useForwardProps } from "reka-ui";
4
- import { computed } from "vue";
5
- import { cn } from "../../utils";
6
- const props = defineProps({
7
- pinInput: { type: null, required: false, default: "outline-primary" },
8
- status: { type: String, required: false },
9
- una: { type: Object, required: false },
10
- index: { type: Number, required: true },
11
- disabled: { type: Boolean, required: false },
12
- asChild: { type: Boolean, required: false },
13
- as: { type: [String, Object, Function], required: false },
14
- icon: { type: String, required: false },
15
- class: { type: null, required: false },
16
- size: { type: null, required: false }
17
- });
18
- const delegatedProps = reactiveOmit(props, "class");
19
- const forwardedProps = useForwardProps(delegatedProps);
20
- const statusClassVariants = computed(() => {
21
- const input = {
22
- info: "input-status-info pin-input-solid-info input-status-ring",
23
- success: "input-status-success pin-input-solid-success input-status-ring",
24
- warning: "input-status-warning pin-input-solid-warning input-status-ring",
25
- error: "input-status-error pin-input-solid-error input-status-ring",
26
- default: void 0
27
- };
28
- return {
29
- input: input[props.status ?? "default"]
30
- };
31
- });
32
- </script>
33
-
34
- <template>
35
- <PinInputInput
36
- data-slot="pin-input-slot"
37
- v-bind="forwardedProps"
38
- :class="cn(
39
- 'pin-input-slot',
40
- props.una?.pinInputSlot,
41
- props.class,
42
- statusClassVariants.input
43
- )"
44
- :pin-input="statusClassVariants.input === void 0 && props.pinInput"
45
- />
46
- </template>
@@ -1,5 +0,0 @@
1
- import type { NPinInputSlotProps } from '../../types/index.js';
2
- declare const _default: import("vue").DefineComponent<NPinInputSlotProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<NPinInputSlotProps> & Readonly<{}>, {
3
- pinInput: import("vue").HTMLAttributes["class"];
4
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
5
- export default _default;
@@ -1,48 +0,0 @@
1
- import type { NumberFieldDecrementProps, NumberFieldIncrementProps, NumberFieldInputProps, NumberFieldRootProps } from 'reka-ui';
2
- import type { HTMLAttributes } from 'vue';
3
- import type { NInputProps } from './input.js';
4
- export interface NNumberFieldProps extends NumberFieldRootProps, Pick<NInputProps, 'leading' | 'trailing'>, BaseExtensions {
5
- /**
6
- * Allows you to add `UnaUI` input preset properties,
7
- * Think of it as a shortcut for adding options or variants to the preset if available.
8
- *
9
- * @see https://github.com/una-ui/una-ui/blob/main/packages/preset/src/_shortcuts/number-field.ts
10
- * @example
11
- * numberField="solid-green"
12
- */
13
- numberField?: HTMLAttributes['class'];
14
- _numberFieldContent?: NNumberFieldContentProps;
15
- _numberFieldDecrement?: NNumberFieldDecrementProps;
16
- _numberFieldIncrement?: NNumberFieldIncrementProps;
17
- _numberFieldInput?: NNumberFieldInputProps;
18
- /**
19
- * `UnaUI` preset configuration
20
- * @see https://github.com/una-ui/una-ui/blob/main/packages/preset/src/_shortcuts/number-field.ts
21
- */
22
- una?: NNumberFieldUnaProps;
23
- }
24
- export interface NNumberFieldContentProps extends BaseExtensions {
25
- una?: Pick<NNumberFieldUnaProps, 'numberFieldContent'>;
26
- }
27
- export interface NNumberFieldDecrementProps extends NumberFieldDecrementProps, BaseExtensions {
28
- icon?: string;
29
- una?: Pick<NNumberFieldUnaProps, 'numberFieldDecrement'>;
30
- }
31
- export interface NNumberFieldIncrementProps extends NumberFieldIncrementProps, BaseExtensions {
32
- icon?: string;
33
- una?: Pick<NNumberFieldUnaProps, 'numberFieldIncrement'>;
34
- }
35
- export interface NNumberFieldInputProps extends NumberFieldInputProps, BaseExtensions, Pick<NNumberFieldProps, 'numberField'> {
36
- una?: Pick<NNumberFieldUnaProps, 'numberFieldInput'>;
37
- }
38
- export interface NNumberFieldUnaProps {
39
- numberFieldContent?: HTMLAttributes['class'];
40
- numberFieldIncrement?: HTMLAttributes['class'];
41
- numberFieldDecrement?: HTMLAttributes['class'];
42
- numberFieldInput?: HTMLAttributes['class'];
43
- }
44
- interface BaseExtensions {
45
- class?: HTMLAttributes['class'];
46
- size?: HTMLAttributes['class'];
47
- }
48
- export {};
File without changes