@una-ui/nuxt-edge 1.0.0-alpha.0-29174566.3206b75 → 1.0.0-alpha.0-29174700.640b0f9

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/module.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@una-ui/nuxt-edge",
3
3
  "configKey": "una",
4
- "version": "1.0.0-alpha.0-29174566.3206b75",
4
+ "version": "1.0.0-alpha.0-29174700.640b0f9",
5
5
  "compatibility": {
6
6
  "nuxt": ">=3.0.0"
7
7
  },
package/dist/module.mjs CHANGED
@@ -8,7 +8,7 @@ import 'unocss';
8
8
  import 'unocss-preset-animations';
9
9
 
10
10
  const name = "@una-ui/nuxt-edge";
11
- const version = "1.0.0-alpha.0-29174566.3206b75";
11
+ const version = "1.0.0-alpha.0-29174700.640b0f9";
12
12
 
13
13
  const module = defineNuxtModule({
14
14
  meta: {
@@ -104,7 +104,7 @@ function shuffleTheme() {
104
104
  >
105
105
  <Button
106
106
  v-if="theme"
107
- btn="solid-gray"
107
+ btn="outline-gray"
108
108
  size="xs"
109
109
  :title="capitalize(theme?.name)"
110
110
  class="justify-start gap-2 ring-primary"
@@ -188,7 +188,7 @@ function shuffleTheme() {
188
188
  <Button
189
189
  v-for="r in RADIUS"
190
190
  :key="r"
191
- btn="solid-gray"
191
+ btn="outline-gray"
192
192
  size="xs"
193
193
  :class="
194
194
  r === settings.radius ? 'ring-2 ring-primary' : ''
@@ -207,7 +207,7 @@ function shuffleTheme() {
207
207
 
208
208
  <div class="flex justify-around py-1.5 space-x-2">
209
209
  <Button
210
- btn="solid-gray"
210
+ btn="outline-gray"
211
211
  :class="{ 'ring-2 ring-primary': colorMode.preference === 'system' }"
212
212
  leading="i-radix-icons-desktop"
213
213
  class="px-3"
@@ -217,7 +217,7 @@ function shuffleTheme() {
217
217
  />
218
218
 
219
219
  <Button
220
- btn="solid-gray"
220
+ btn="outline-gray"
221
221
  :class="{ 'ring-2 ring-primary': colorMode.preference === 'light' }"
222
222
  leading="i-radix-icons-sun"
223
223
  class="px-3"
@@ -227,7 +227,7 @@ function shuffleTheme() {
227
227
  />
228
228
 
229
229
  <Button
230
- btn="solid-gray"
230
+ btn="outline-gray"
231
231
  :class="{ 'ring-2 ring-primary': colorMode.preference === 'dark' }"
232
232
  leading="i-radix-icons-moon"
233
233
  class="px-3"
@@ -243,7 +243,7 @@ function shuffleTheme() {
243
243
  <div class="grid grid-cols-2 gap-2">
244
244
  <Button
245
245
  size="xs"
246
- btn="solid-gray"
246
+ btn="outline-gray"
247
247
  label="Reset"
248
248
  leading="i-radix-icons-reload"
249
249
  @click="reset"
@@ -0,0 +1,73 @@
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: null, 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>
@@ -0,0 +1,28 @@
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
+ };
@@ -0,0 +1,20 @@
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>
@@ -0,0 +1,13 @@
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
+ };
@@ -0,0 +1,33 @@
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: null, 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>
@@ -0,0 +1,16 @@
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
+ };
@@ -0,0 +1,33 @@
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: null, 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>
@@ -0,0 +1,16 @@
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
+ };
@@ -0,0 +1,24 @@
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: null, 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>
@@ -0,0 +1,5 @@
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;
@@ -24,6 +24,7 @@ export * from './kbd.js';
24
24
  export * from './label.js';
25
25
  export * from './link.js';
26
26
  export * from './navigation-menu.js';
27
+ export * from './number-field.js';
27
28
  export * from './pagination.js';
28
29
  export * from './popover.js';
29
30
  export * from './progress.js';
@@ -24,6 +24,7 @@ export * from "./kbd.js";
24
24
  export * from "./label.js";
25
25
  export * from "./link.js";
26
26
  export * from "./navigation-menu.js";
27
+ export * from "./number-field.js";
27
28
  export * from "./pagination.js";
28
29
  export * from "./popover.js";
29
30
  export * from "./progress.js";
@@ -0,0 +1,48 @@
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
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@una-ui/nuxt-edge",
3
3
  "type": "module",
4
- "version": "1.0.0-alpha.0-29174566.3206b75",
4
+ "version": "1.0.0-alpha.0-29174700.640b0f9",
5
5
  "description": "Nuxt module for @una-ui",
6
6
  "author": "Phojie Rengel <phojrengel@gmail.com>",
7
7
  "license": "MIT",
@@ -41,8 +41,8 @@
41
41
  "@nuxt/kit": "^3.17.5",
42
42
  "@nuxtjs/color-mode": "^3.5.2",
43
43
  "@tanstack/vue-table": "^8.21.3",
44
- "@una-ui/extractor-vue-script": "npm:@una-ui/extractor-vue-script-edge@1.0.0-alpha.0-29174566.3206b75",
45
- "@una-ui/preset": "npm:@una-ui/preset-edge@1.0.0-alpha.0-29174566.3206b75",
44
+ "@una-ui/extractor-vue-script": "npm:@una-ui/extractor-vue-script-edge@1.0.0-alpha.0-29174700.640b0f9",
45
+ "@una-ui/preset": "npm:@una-ui/preset-edge@1.0.0-alpha.0-29174700.640b0f9",
46
46
  "@unocss/core": "^66.2.0",
47
47
  "@unocss/nuxt": "^66.2.0",
48
48
  "@unocss/preset-attributify": "^66.2.0",