x-prop-tree 0.3.4 → 0.3.7
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.
|
@@ -10,6 +10,7 @@ declare const _default: import("vue").DefineComponent<__VLS_TypePropsToOption<Pr
|
|
|
10
10
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
11
11
|
}, {}, {}>;
|
|
12
12
|
export default _default;
|
|
13
|
+
|
|
13
14
|
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
14
15
|
type __VLS_TypePropsToOption<T> = {
|
|
15
16
|
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
@@ -1,50 +1,29 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
readonly: {
|
|
20
|
-
type: import("vue").PropType<boolean>;
|
|
21
|
-
default: boolean;
|
|
22
|
-
};
|
|
23
|
-
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
1
|
+
interface Props {
|
|
2
|
+
min?: number;
|
|
3
|
+
max?: number;
|
|
4
|
+
precision?: number;
|
|
5
|
+
step?: number;
|
|
6
|
+
readonly?: boolean;
|
|
7
|
+
}
|
|
8
|
+
declare let __VLS_typeProps: Props;
|
|
9
|
+
type __VLS_PublicProps = {
|
|
10
|
+
modelValue?: number;
|
|
11
|
+
} & typeof __VLS_typeProps;
|
|
12
|
+
declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToOption<__VLS_PublicProps>, {
|
|
13
|
+
min: number;
|
|
14
|
+
max: number;
|
|
15
|
+
precision: number;
|
|
16
|
+
step: number;
|
|
17
|
+
readonly: boolean;
|
|
18
|
+
}>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
24
19
|
"update:modelValue": (modelValue: number) => void;
|
|
25
|
-
}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
type: import("vue").PropType<number>;
|
|
33
|
-
default: number;
|
|
34
|
-
};
|
|
35
|
-
precision: {
|
|
36
|
-
type: import("vue").PropType<number>;
|
|
37
|
-
default: number;
|
|
38
|
-
};
|
|
39
|
-
step: {
|
|
40
|
-
type: import("vue").PropType<number>;
|
|
41
|
-
default: number;
|
|
42
|
-
};
|
|
43
|
-
readonly: {
|
|
44
|
-
type: import("vue").PropType<boolean>;
|
|
45
|
-
default: boolean;
|
|
46
|
-
};
|
|
47
|
-
}>> & {
|
|
20
|
+
}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToOption<__VLS_PublicProps>, {
|
|
21
|
+
min: number;
|
|
22
|
+
max: number;
|
|
23
|
+
precision: number;
|
|
24
|
+
step: number;
|
|
25
|
+
readonly: boolean;
|
|
26
|
+
}>>> & {
|
|
48
27
|
"onUpdate:modelValue"?: ((modelValue: number) => any) | undefined;
|
|
49
28
|
}, {
|
|
50
29
|
min: number;
|
|
@@ -54,3 +33,20 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
54
33
|
readonly: boolean;
|
|
55
34
|
}, {}>;
|
|
56
35
|
export default _default;
|
|
36
|
+
type __VLS_WithDefaults<P, D> = {
|
|
37
|
+
[K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
|
|
38
|
+
default: D[K];
|
|
39
|
+
}> : P[K];
|
|
40
|
+
};
|
|
41
|
+
type __VLS_Prettify<T> = {
|
|
42
|
+
[K in keyof T]: T[K];
|
|
43
|
+
} & {};
|
|
44
|
+
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
45
|
+
type __VLS_TypePropsToOption<T> = {
|
|
46
|
+
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
47
|
+
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
48
|
+
} : {
|
|
49
|
+
type: import('vue').PropType<T[K]>;
|
|
50
|
+
required: true;
|
|
51
|
+
};
|
|
52
|
+
};
|
|
@@ -1,27 +1,21 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
1
|
+
interface Props {
|
|
2
|
+
readonly?: boolean;
|
|
3
|
+
hasDelete?: boolean;
|
|
4
|
+
}
|
|
5
|
+
declare let __VLS_typeProps: Props;
|
|
6
|
+
type __VLS_PublicProps = {
|
|
7
|
+
modelValue?: string;
|
|
8
|
+
} & typeof __VLS_typeProps;
|
|
9
|
+
declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToOption<__VLS_PublicProps>, {
|
|
10
|
+
readonly: boolean;
|
|
11
|
+
hasDelete: boolean;
|
|
12
|
+
}>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
12
13
|
"update:modelValue": (modelValue: string) => void;
|
|
13
14
|
delete: (...args: any[]) => void;
|
|
14
|
-
}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
default: boolean;
|
|
19
|
-
};
|
|
20
|
-
hasDelete: {
|
|
21
|
-
type: import("vue").PropType<boolean>;
|
|
22
|
-
default: boolean;
|
|
23
|
-
};
|
|
24
|
-
}>> & {
|
|
15
|
+
}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToOption<__VLS_PublicProps>, {
|
|
16
|
+
readonly: boolean;
|
|
17
|
+
hasDelete: boolean;
|
|
18
|
+
}>>> & {
|
|
25
19
|
"onUpdate:modelValue"?: ((modelValue: string) => any) | undefined;
|
|
26
20
|
onDelete?: ((...args: any[]) => any) | undefined;
|
|
27
21
|
}, {
|
|
@@ -29,3 +23,20 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
29
23
|
hasDelete: boolean;
|
|
30
24
|
}, {}>;
|
|
31
25
|
export default _default;
|
|
26
|
+
type __VLS_WithDefaults<P, D> = {
|
|
27
|
+
[K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
|
|
28
|
+
default: D[K];
|
|
29
|
+
}> : P[K];
|
|
30
|
+
};
|
|
31
|
+
type __VLS_Prettify<T> = {
|
|
32
|
+
[K in keyof T]: T[K];
|
|
33
|
+
} & {};
|
|
34
|
+
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
35
|
+
type __VLS_TypePropsToOption<T> = {
|
|
36
|
+
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
37
|
+
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
38
|
+
} : {
|
|
39
|
+
type: import('vue').PropType<T[K]>;
|
|
40
|
+
required: true;
|
|
41
|
+
};
|
|
42
|
+
};
|
package/dist/index.js
CHANGED
|
@@ -75,8 +75,7 @@ function we(e) {
|
|
|
75
75
|
}
|
|
76
76
|
function F() {
|
|
77
77
|
let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : "";
|
|
78
|
-
if (F.cache.has(e))
|
|
79
|
-
return F.cache.get(e);
|
|
78
|
+
if (F.cache.has(e)) return F.cache.get(e);
|
|
80
79
|
const t = e.replace(/[^a-z]/gi, "-").replace(/\B([A-Z])/g, "-$1").toLowerCase();
|
|
81
80
|
return F.cache.set(e, t), t;
|
|
82
81
|
}
|
|
@@ -97,8 +96,7 @@ const _ = 2.4, se = 0.2126729, ae = 0.7151522, le = 0.072175, et = 0.55, tt = 0.
|
|
|
97
96
|
function ce(e, t) {
|
|
98
97
|
const n = (e.r / 255) ** _, s = (e.g / 255) ** _, a = (e.b / 255) ** _, r = (t.r / 255) ** _, u = (t.g / 255) ** _, m = (t.b / 255) ** _;
|
|
99
98
|
let o = n * se + s * ae + a * le, f = r * se + u * ae + m * le;
|
|
100
|
-
if (o <= O && (o += (O - o) ** re), f <= O && (f += (O - f) ** re), Math.abs(f - o) < at)
|
|
101
|
-
return 0;
|
|
99
|
+
if (o <= O && (o += (O - o) ** re), f <= O && (f += (O - f) ** re), Math.abs(f - o) < at) return 0;
|
|
102
100
|
let h;
|
|
103
101
|
if (f > o) {
|
|
104
102
|
const g = (f ** et - o ** tt) * lt;
|
|
@@ -260,8 +258,7 @@ function mt(e) {
|
|
|
260
258
|
const J = Symbol.for("vuetify:defaults");
|
|
261
259
|
function Fe() {
|
|
262
260
|
const e = Q(J);
|
|
263
|
-
if (!e)
|
|
264
|
-
throw new Error("[Vuetify] Could not find defaults instance");
|
|
261
|
+
if (!e) throw new Error("[Vuetify] Could not find defaults instance");
|
|
265
262
|
return e;
|
|
266
263
|
}
|
|
267
264
|
function gt(e, t) {
|
|
@@ -312,8 +309,7 @@ function q(e) {
|
|
|
312
309
|
return Je(s, t);
|
|
313
310
|
}, e.props._as = String, e.setup = function(s, a) {
|
|
314
311
|
const r = Fe();
|
|
315
|
-
if (!r.value)
|
|
316
|
-
return e._setup(s, a);
|
|
312
|
+
if (!r.value) return e._setup(s, a);
|
|
317
313
|
const {
|
|
318
314
|
props: u,
|
|
319
315
|
provideSubDefaults: m
|
|
@@ -337,8 +333,7 @@ const me = Symbol.for("vuetify:theme"), vt = w({
|
|
|
337
333
|
function Ct(e) {
|
|
338
334
|
T("provideTheme");
|
|
339
335
|
const t = Q(me, null);
|
|
340
|
-
if (!t)
|
|
341
|
-
throw new Error("Could not find Vuetify theme injection");
|
|
336
|
+
if (!t) throw new Error("Could not find Vuetify theme injection");
|
|
342
337
|
const n = k(() => e.theme ?? t.name.value), s = k(() => t.themes.value[n.value]), a = k(() => t.isDisabled ? void 0 : `v-theme--${n.value}`), r = {
|
|
343
338
|
...t,
|
|
344
339
|
name: n,
|
|
@@ -459,16 +454,14 @@ q({
|
|
|
459
454
|
});
|
|
460
455
|
const wt = (e) => {
|
|
461
456
|
const t = Q(Vt);
|
|
462
|
-
if (!t)
|
|
463
|
-
throw new Error("Missing Vuetify Icons provide!");
|
|
457
|
+
if (!t) throw new Error("Missing Vuetify Icons provide!");
|
|
464
458
|
return {
|
|
465
459
|
iconData: k(() => {
|
|
466
460
|
var o;
|
|
467
461
|
const s = W(e);
|
|
468
|
-
if (!s)
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
};
|
|
462
|
+
if (!s) return {
|
|
463
|
+
component: ge
|
|
464
|
+
};
|
|
472
465
|
let a = s;
|
|
473
466
|
if (typeof a == "string" && (a = a.trim(), a.startsWith("$") && (a = (o = t.aliases) == null ? void 0 : o[a.slice(1)])), a || D(`Could not find aliased icon "${s}"`), Array.isArray(a))
|
|
474
467
|
return {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "x-prop-tree",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "0.3.
|
|
4
|
+
"version": "0.3.7",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"module": "dist/index.js",
|
|
7
7
|
"types": "dist/index.d.ts",
|
|
@@ -22,30 +22,31 @@
|
|
|
22
22
|
"*": "prettier --write ."
|
|
23
23
|
},
|
|
24
24
|
"peerDependencies": {
|
|
25
|
-
"
|
|
25
|
+
"axios": "^1.7.2",
|
|
26
|
+
"vue": "^3.4.31",
|
|
26
27
|
"vue-i18n": "^9.13.1",
|
|
27
|
-
"vuetify": "^3.6.
|
|
28
|
-
"x-essential-lib": "^0.
|
|
29
|
-
"x-runtime-lib": "^0.3.
|
|
28
|
+
"vuetify": "^3.6.12",
|
|
29
|
+
"x-essential-lib": "^0.6.1",
|
|
30
|
+
"x-runtime-lib": "^0.3.8"
|
|
30
31
|
},
|
|
31
32
|
"devDependencies": {
|
|
32
33
|
"@mdi/js": "^7.4.47",
|
|
33
|
-
"@rushstack/eslint-patch": "^1.
|
|
34
|
-
"@types/node": "^20.
|
|
35
|
-
"@vitejs/plugin-vue": "^5.0.
|
|
34
|
+
"@rushstack/eslint-patch": "^1.10.3",
|
|
35
|
+
"@types/node": "^20.14.10",
|
|
36
|
+
"@vitejs/plugin-vue": "^5.0.5",
|
|
36
37
|
"@vue/eslint-config-prettier": "^9.0.0",
|
|
37
38
|
"@vue/eslint-config-typescript": "^13.0.0",
|
|
38
39
|
"eslint": "^8.57.0",
|
|
39
|
-
"eslint-plugin-vue": "^9.
|
|
40
|
+
"eslint-plugin-vue": "^9.27.0",
|
|
40
41
|
"husky": "^9.0.11",
|
|
41
|
-
"lint-staged": "^15.2.
|
|
42
|
-
"prettier": "3.2
|
|
43
|
-
"sass": "^1.
|
|
44
|
-
"typescript": "^5.
|
|
45
|
-
"vite": "^5.
|
|
46
|
-
"vite-plugin-css-injected-by-js": "^3.5.
|
|
42
|
+
"lint-staged": "^15.2.7",
|
|
43
|
+
"prettier": "3.3.2",
|
|
44
|
+
"sass": "^1.77.7",
|
|
45
|
+
"typescript": "^5.5.3",
|
|
46
|
+
"vite": "^5.3.3",
|
|
47
|
+
"vite-plugin-css-injected-by-js": "^3.5.1",
|
|
47
48
|
"vite-plugin-vuetify": "^2.0.3",
|
|
48
49
|
"vue-router": "^4.4.0",
|
|
49
|
-
"vue-tsc": "^2.0.
|
|
50
|
+
"vue-tsc": "^2.0.26"
|
|
50
51
|
}
|
|
51
52
|
}
|