@vuer-ai/vuer-uikit 0.0.37 → 0.0.38
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/{chunk-DRL527OZ.js → chunk-4LJVGD5N.js} +1 -1
- package/dist/{chunk-SFFLVUWV.js → chunk-72PCXNEI.js} +3 -3
- package/dist/{chunk-A3EJLDGW.js → chunk-DCURVZQ2.js} +4 -17
- package/dist/{chunk-IODCQKTM.mjs → chunk-KQ6LMA4V.mjs} +3 -16
- package/dist/{chunk-DXZEM4KQ.mjs → chunk-MS5G6UZ4.mjs} +3 -3
- package/dist/{chunk-6MEYAIYL.mjs → chunk-ZEK2T25J.mjs} +1 -1
- package/dist/index.js +7 -7
- package/dist/index.mjs +3 -3
- package/dist/ui/index.js +7 -7
- package/dist/ui/index.mjs +3 -3
- package/dist/ui/theme/ThemeProvider.js +4 -4
- package/dist/ui/theme/ThemeProvider.mjs +2 -2
- package/dist/ui/theme/index.js +5 -5
- package/dist/ui/theme/index.mjs +2 -2
- package/dist/ui/theme/themeScript.js +2 -2
- package/dist/ui/theme/themeScript.mjs +1 -1
- package/dist/ui/version-badge.js +2 -2
- package/dist/ui/version-badge.mjs +1 -1
- package/package.json +1 -1
- package/src/ui/theme/ThemeProvider.tsx +3 -15
- package/src/ui/theme/themeScript.tsx +5 -3
|
@@ -6,7 +6,6 @@ var jsxRuntime = require('react/jsx-runtime');
|
|
|
6
6
|
// src/ui/theme/themeScript.tsx
|
|
7
7
|
var themeScript = (defaultTheme, storageKey, attribute, themes, value, forcedTheme, enableSystem, enableColorScheme) => {
|
|
8
8
|
const el = document.documentElement;
|
|
9
|
-
const systemThemes = ["light", "dark"];
|
|
10
9
|
function updateDOM(theme) {
|
|
11
10
|
const attributes = Array.isArray(attribute) ? attribute : [attribute];
|
|
12
11
|
attributes.forEach((attr) => {
|
|
@@ -22,8 +21,9 @@ var themeScript = (defaultTheme, storageKey, attribute, themes, value, forcedThe
|
|
|
22
21
|
setColorScheme(theme);
|
|
23
22
|
}
|
|
24
23
|
function setColorScheme(theme) {
|
|
25
|
-
if (enableColorScheme
|
|
26
|
-
|
|
24
|
+
if (enableColorScheme) {
|
|
25
|
+
const isDark = theme.includes("dark");
|
|
26
|
+
el.style.colorScheme = isDark ? "dark" : "light";
|
|
27
27
|
}
|
|
28
28
|
}
|
|
29
29
|
function getSystemTheme() {
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunk72PCXNEI_js = require('./chunk-72PCXNEI.js');
|
|
4
4
|
var react = require('react');
|
|
5
5
|
var jsxRuntime = require('react/jsx-runtime');
|
|
6
6
|
|
|
7
|
-
var colorSchemes = ["light", "dark"];
|
|
8
7
|
var MEDIA = "(prefers-color-scheme: dark)";
|
|
9
8
|
var isServer = typeof window === "undefined";
|
|
10
9
|
var ThemeContext = react.createContext(void 0);
|
|
@@ -69,20 +68,8 @@ var Theme = ({
|
|
|
69
68
|
if (Array.isArray(attribute)) attribute.forEach(handleAttribute);
|
|
70
69
|
else handleAttribute(attribute);
|
|
71
70
|
if (enableColorScheme) {
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
(schema, currentValue) => {
|
|
75
|
-
if (defaultTheme.includes(currentValue)) {
|
|
76
|
-
fallback = currentValue;
|
|
77
|
-
}
|
|
78
|
-
if (resolved.includes(currentValue)) {
|
|
79
|
-
return currentValue;
|
|
80
|
-
}
|
|
81
|
-
return schema;
|
|
82
|
-
},
|
|
83
|
-
void 0
|
|
84
|
-
);
|
|
85
|
-
d.style.colorScheme = c ?? fallback;
|
|
71
|
+
const isDark = resolved.includes("dark");
|
|
72
|
+
d.style.colorScheme = isDark ? "dark" : "light";
|
|
86
73
|
}
|
|
87
74
|
enable == null ? void 0 : enable();
|
|
88
75
|
},
|
|
@@ -161,7 +148,7 @@ var Theme = ({
|
|
|
161
148
|
),
|
|
162
149
|
children: [
|
|
163
150
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
164
|
-
|
|
151
|
+
chunk72PCXNEI_js.ThemeScript,
|
|
165
152
|
{
|
|
166
153
|
...{
|
|
167
154
|
forcedTheme,
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
import { ThemeScript } from './chunk-
|
|
1
|
+
import { ThemeScript } from './chunk-MS5G6UZ4.mjs';
|
|
2
2
|
import { createContext, useContext, useState, useCallback, useEffect, useMemo } from 'react';
|
|
3
3
|
import { jsx, Fragment, jsxs } from 'react/jsx-runtime';
|
|
4
4
|
|
|
5
|
-
var colorSchemes = ["light", "dark"];
|
|
6
5
|
var MEDIA = "(prefers-color-scheme: dark)";
|
|
7
6
|
var isServer = typeof window === "undefined";
|
|
8
7
|
var ThemeContext = createContext(void 0);
|
|
@@ -67,20 +66,8 @@ var Theme = ({
|
|
|
67
66
|
if (Array.isArray(attribute)) attribute.forEach(handleAttribute);
|
|
68
67
|
else handleAttribute(attribute);
|
|
69
68
|
if (enableColorScheme) {
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
(schema, currentValue) => {
|
|
73
|
-
if (defaultTheme.includes(currentValue)) {
|
|
74
|
-
fallback = currentValue;
|
|
75
|
-
}
|
|
76
|
-
if (resolved.includes(currentValue)) {
|
|
77
|
-
return currentValue;
|
|
78
|
-
}
|
|
79
|
-
return schema;
|
|
80
|
-
},
|
|
81
|
-
void 0
|
|
82
|
-
);
|
|
83
|
-
d.style.colorScheme = c ?? fallback;
|
|
69
|
+
const isDark = resolved.includes("dark");
|
|
70
|
+
d.style.colorScheme = isDark ? "dark" : "light";
|
|
84
71
|
}
|
|
85
72
|
enable == null ? void 0 : enable();
|
|
86
73
|
},
|
|
@@ -4,7 +4,6 @@ import { jsx } from 'react/jsx-runtime';
|
|
|
4
4
|
// src/ui/theme/themeScript.tsx
|
|
5
5
|
var themeScript = (defaultTheme, storageKey, attribute, themes, value, forcedTheme, enableSystem, enableColorScheme) => {
|
|
6
6
|
const el = document.documentElement;
|
|
7
|
-
const systemThemes = ["light", "dark"];
|
|
8
7
|
function updateDOM(theme) {
|
|
9
8
|
const attributes = Array.isArray(attribute) ? attribute : [attribute];
|
|
10
9
|
attributes.forEach((attr) => {
|
|
@@ -20,8 +19,9 @@ var themeScript = (defaultTheme, storageKey, attribute, themes, value, forcedThe
|
|
|
20
19
|
setColorScheme(theme);
|
|
21
20
|
}
|
|
22
21
|
function setColorScheme(theme) {
|
|
23
|
-
if (enableColorScheme
|
|
24
|
-
|
|
22
|
+
if (enableColorScheme) {
|
|
23
|
+
const isDark = theme.includes("dark");
|
|
24
|
+
el.style.colorScheme = isDark ? "dark" : "light";
|
|
25
25
|
}
|
|
26
26
|
}
|
|
27
27
|
function getSystemTheme() {
|
package/dist/index.js
CHANGED
|
@@ -6,9 +6,9 @@ var chunkQJR6MCTR_js = require('./chunk-QJR6MCTR.js');
|
|
|
6
6
|
var chunkFSFUZ7Y6_js = require('./chunk-FSFUZ7Y6.js');
|
|
7
7
|
var chunkEAN5SZYQ_js = require('./chunk-EAN5SZYQ.js');
|
|
8
8
|
var chunkR3SHGA4V_js = require('./chunk-R3SHGA4V.js');
|
|
9
|
-
var
|
|
10
|
-
var
|
|
11
|
-
var
|
|
9
|
+
var chunk4LJVGD5N_js = require('./chunk-4LJVGD5N.js');
|
|
10
|
+
var chunkDCURVZQ2_js = require('./chunk-DCURVZQ2.js');
|
|
11
|
+
var chunk72PCXNEI_js = require('./chunk-72PCXNEI.js');
|
|
12
12
|
var chunkBXYVNNXU_js = require('./chunk-BXYVNNXU.js');
|
|
13
13
|
var chunkGFPXAGJY_js = require('./chunk-GFPXAGJY.js');
|
|
14
14
|
var chunkJ2ZRCEKZ_js = require('./chunk-J2ZRCEKZ.js');
|
|
@@ -77,19 +77,19 @@ Object.defineProperty(exports, "TreeView", {
|
|
|
77
77
|
});
|
|
78
78
|
Object.defineProperty(exports, "VersionBadge", {
|
|
79
79
|
enumerable: true,
|
|
80
|
-
get: function () { return
|
|
80
|
+
get: function () { return chunk4LJVGD5N_js.VersionBadge; }
|
|
81
81
|
});
|
|
82
82
|
Object.defineProperty(exports, "ThemeProvider", {
|
|
83
83
|
enumerable: true,
|
|
84
|
-
get: function () { return
|
|
84
|
+
get: function () { return chunkDCURVZQ2_js.ThemeProvider; }
|
|
85
85
|
});
|
|
86
86
|
Object.defineProperty(exports, "useTheme", {
|
|
87
87
|
enumerable: true,
|
|
88
|
-
get: function () { return
|
|
88
|
+
get: function () { return chunkDCURVZQ2_js.useTheme; }
|
|
89
89
|
});
|
|
90
90
|
Object.defineProperty(exports, "ThemeScript", {
|
|
91
91
|
enumerable: true,
|
|
92
|
-
get: function () { return
|
|
92
|
+
get: function () { return chunk72PCXNEI_js.ThemeScript; }
|
|
93
93
|
});
|
|
94
94
|
Object.defineProperty(exports, "RadioGroup", {
|
|
95
95
|
enumerable: true,
|
package/dist/index.mjs
CHANGED
|
@@ -4,9 +4,9 @@ export { Toaster, toast } from './chunk-EAZQH4IX.mjs';
|
|
|
4
4
|
export { ToggleGroup, ToggleGroupItem } from './chunk-G6CSH3FC.mjs';
|
|
5
5
|
export { Toggle, toggleVariants } from './chunk-K6R7H7R2.mjs';
|
|
6
6
|
export { TreeView } from './chunk-NKNUMZJL.mjs';
|
|
7
|
-
export { VersionBadge } from './chunk-
|
|
8
|
-
export { ThemeProvider, useTheme } from './chunk-
|
|
9
|
-
export { ThemeScript } from './chunk-
|
|
7
|
+
export { VersionBadge } from './chunk-ZEK2T25J.mjs';
|
|
8
|
+
export { ThemeProvider, useTheme } from './chunk-KQ6LMA4V.mjs';
|
|
9
|
+
export { ThemeScript } from './chunk-MS5G6UZ4.mjs';
|
|
10
10
|
export { RadioGroup, RadioGroupItem } from './chunk-EL4FTB5J.mjs';
|
|
11
11
|
export { Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger } from './chunk-KAUA4ODT.mjs';
|
|
12
12
|
export { Slider } from './chunk-47WYS4WO.mjs';
|
package/dist/ui/index.js
CHANGED
|
@@ -6,9 +6,9 @@ var chunkQJR6MCTR_js = require('../chunk-QJR6MCTR.js');
|
|
|
6
6
|
var chunkFSFUZ7Y6_js = require('../chunk-FSFUZ7Y6.js');
|
|
7
7
|
var chunkEAN5SZYQ_js = require('../chunk-EAN5SZYQ.js');
|
|
8
8
|
var chunkR3SHGA4V_js = require('../chunk-R3SHGA4V.js');
|
|
9
|
-
var
|
|
10
|
-
var
|
|
11
|
-
var
|
|
9
|
+
var chunk4LJVGD5N_js = require('../chunk-4LJVGD5N.js');
|
|
10
|
+
var chunkDCURVZQ2_js = require('../chunk-DCURVZQ2.js');
|
|
11
|
+
var chunk72PCXNEI_js = require('../chunk-72PCXNEI.js');
|
|
12
12
|
var chunkBXYVNNXU_js = require('../chunk-BXYVNNXU.js');
|
|
13
13
|
var chunkGFPXAGJY_js = require('../chunk-GFPXAGJY.js');
|
|
14
14
|
var chunkJ2ZRCEKZ_js = require('../chunk-J2ZRCEKZ.js');
|
|
@@ -72,19 +72,19 @@ Object.defineProperty(exports, "TreeView", {
|
|
|
72
72
|
});
|
|
73
73
|
Object.defineProperty(exports, "VersionBadge", {
|
|
74
74
|
enumerable: true,
|
|
75
|
-
get: function () { return
|
|
75
|
+
get: function () { return chunk4LJVGD5N_js.VersionBadge; }
|
|
76
76
|
});
|
|
77
77
|
Object.defineProperty(exports, "ThemeProvider", {
|
|
78
78
|
enumerable: true,
|
|
79
|
-
get: function () { return
|
|
79
|
+
get: function () { return chunkDCURVZQ2_js.ThemeProvider; }
|
|
80
80
|
});
|
|
81
81
|
Object.defineProperty(exports, "useTheme", {
|
|
82
82
|
enumerable: true,
|
|
83
|
-
get: function () { return
|
|
83
|
+
get: function () { return chunkDCURVZQ2_js.useTheme; }
|
|
84
84
|
});
|
|
85
85
|
Object.defineProperty(exports, "ThemeScript", {
|
|
86
86
|
enumerable: true,
|
|
87
|
-
get: function () { return
|
|
87
|
+
get: function () { return chunk72PCXNEI_js.ThemeScript; }
|
|
88
88
|
});
|
|
89
89
|
Object.defineProperty(exports, "RadioGroup", {
|
|
90
90
|
enumerable: true,
|
package/dist/ui/index.mjs
CHANGED
|
@@ -4,9 +4,9 @@ export { Toaster, toast } from '../chunk-EAZQH4IX.mjs';
|
|
|
4
4
|
export { ToggleGroup, ToggleGroupItem } from '../chunk-G6CSH3FC.mjs';
|
|
5
5
|
export { Toggle, toggleVariants } from '../chunk-K6R7H7R2.mjs';
|
|
6
6
|
export { TreeView } from '../chunk-NKNUMZJL.mjs';
|
|
7
|
-
export { VersionBadge } from '../chunk-
|
|
8
|
-
export { ThemeProvider, useTheme } from '../chunk-
|
|
9
|
-
export { ThemeScript } from '../chunk-
|
|
7
|
+
export { VersionBadge } from '../chunk-ZEK2T25J.mjs';
|
|
8
|
+
export { ThemeProvider, useTheme } from '../chunk-KQ6LMA4V.mjs';
|
|
9
|
+
export { ThemeScript } from '../chunk-MS5G6UZ4.mjs';
|
|
10
10
|
export { RadioGroup, RadioGroupItem } from '../chunk-EL4FTB5J.mjs';
|
|
11
11
|
export { Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger } from '../chunk-KAUA4ODT.mjs';
|
|
12
12
|
export { Slider } from '../chunk-47WYS4WO.mjs';
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
require('../../chunk-
|
|
3
|
+
var chunkDCURVZQ2_js = require('../../chunk-DCURVZQ2.js');
|
|
4
|
+
require('../../chunk-72PCXNEI.js');
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
Object.defineProperty(exports, "ThemeProvider", {
|
|
9
9
|
enumerable: true,
|
|
10
|
-
get: function () { return
|
|
10
|
+
get: function () { return chunkDCURVZQ2_js.ThemeProvider; }
|
|
11
11
|
});
|
|
12
12
|
Object.defineProperty(exports, "useTheme", {
|
|
13
13
|
enumerable: true,
|
|
14
|
-
get: function () { return
|
|
14
|
+
get: function () { return chunkDCURVZQ2_js.useTheme; }
|
|
15
15
|
});
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { ThemeProvider, useTheme } from '../../chunk-
|
|
2
|
-
import '../../chunk-
|
|
1
|
+
export { ThemeProvider, useTheme } from '../../chunk-KQ6LMA4V.mjs';
|
|
2
|
+
import '../../chunk-MS5G6UZ4.mjs';
|
package/dist/ui/theme/index.js
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
require('../../chunk-Y2QBWXB4.js');
|
|
4
|
-
var
|
|
5
|
-
var
|
|
4
|
+
var chunkDCURVZQ2_js = require('../../chunk-DCURVZQ2.js');
|
|
5
|
+
var chunk72PCXNEI_js = require('../../chunk-72PCXNEI.js');
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
Object.defineProperty(exports, "ThemeProvider", {
|
|
10
10
|
enumerable: true,
|
|
11
|
-
get: function () { return
|
|
11
|
+
get: function () { return chunkDCURVZQ2_js.ThemeProvider; }
|
|
12
12
|
});
|
|
13
13
|
Object.defineProperty(exports, "useTheme", {
|
|
14
14
|
enumerable: true,
|
|
15
|
-
get: function () { return
|
|
15
|
+
get: function () { return chunkDCURVZQ2_js.useTheme; }
|
|
16
16
|
});
|
|
17
17
|
Object.defineProperty(exports, "ThemeScript", {
|
|
18
18
|
enumerable: true,
|
|
19
|
-
get: function () { return
|
|
19
|
+
get: function () { return chunk72PCXNEI_js.ThemeScript; }
|
|
20
20
|
});
|
package/dist/ui/theme/index.mjs
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import '../../chunk-AMB2H6WS.mjs';
|
|
2
|
-
export { ThemeProvider, useTheme } from '../../chunk-
|
|
3
|
-
export { ThemeScript } from '../../chunk-
|
|
2
|
+
export { ThemeProvider, useTheme } from '../../chunk-KQ6LMA4V.mjs';
|
|
3
|
+
export { ThemeScript } from '../../chunk-MS5G6UZ4.mjs';
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunk72PCXNEI_js = require('../../chunk-72PCXNEI.js');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
Object.defineProperty(exports, "ThemeScript", {
|
|
8
8
|
enumerable: true,
|
|
9
|
-
get: function () { return
|
|
9
|
+
get: function () { return chunk72PCXNEI_js.ThemeScript; }
|
|
10
10
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { ThemeScript } from '../../chunk-
|
|
1
|
+
export { ThemeScript } from '../../chunk-MS5G6UZ4.mjs';
|
package/dist/ui/version-badge.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunk4LJVGD5N_js = require('../chunk-4LJVGD5N.js');
|
|
4
4
|
require('../chunk-ILJK43VJ.js');
|
|
5
5
|
require('../chunk-T4N7UHZ7.js');
|
|
6
6
|
require('../chunk-QG7ZF6TO.js');
|
|
@@ -13,5 +13,5 @@ require('../chunk-7KYAICHB.js');
|
|
|
13
13
|
|
|
14
14
|
Object.defineProperty(exports, "VersionBadge", {
|
|
15
15
|
enumerable: true,
|
|
16
|
-
get: function () { return
|
|
16
|
+
get: function () { return chunk4LJVGD5N_js.VersionBadge; }
|
|
17
17
|
});
|
package/package.json
CHANGED
|
@@ -106,21 +106,9 @@ const Theme = ({
|
|
|
106
106
|
else handleAttribute(attribute);
|
|
107
107
|
|
|
108
108
|
if (enableColorScheme) {
|
|
109
|
-
|
|
110
|
-
const
|
|
111
|
-
|
|
112
|
-
if (defaultTheme.includes(currentValue)) {
|
|
113
|
-
fallback = currentValue;
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
if (resolved.includes(currentValue)) {
|
|
117
|
-
return currentValue;
|
|
118
|
-
}
|
|
119
|
-
return schema;
|
|
120
|
-
},
|
|
121
|
-
undefined,
|
|
122
|
-
);
|
|
123
|
-
d.style.colorScheme = c ?? fallback;
|
|
109
|
+
// Extract base color scheme from theme name
|
|
110
|
+
const isDark = resolved.includes("dark");
|
|
111
|
+
d.style.colorScheme = isDark ? "dark" : "light";
|
|
124
112
|
}
|
|
125
113
|
|
|
126
114
|
enable?.();
|
|
@@ -13,7 +13,7 @@ const themeScript = (
|
|
|
13
13
|
enableColorScheme?: boolean | undefined,
|
|
14
14
|
) => {
|
|
15
15
|
const el = document.documentElement;
|
|
16
|
-
const systemThemes = ["light", "dark"];
|
|
16
|
+
const systemThemes = ["light", "dark", "liquid-light", "liquid-dark"];
|
|
17
17
|
|
|
18
18
|
function updateDOM(theme: string) {
|
|
19
19
|
const attributes = Array.isArray(attribute) ? attribute : [attribute];
|
|
@@ -33,8 +33,10 @@ const themeScript = (
|
|
|
33
33
|
}
|
|
34
34
|
|
|
35
35
|
function setColorScheme(theme: string) {
|
|
36
|
-
if (enableColorScheme
|
|
37
|
-
|
|
36
|
+
if (enableColorScheme) {
|
|
37
|
+
// Extract base color scheme from theme name
|
|
38
|
+
const isDark = theme.includes("dark");
|
|
39
|
+
el.style.colorScheme = isDark ? "dark" : "light";
|
|
38
40
|
}
|
|
39
41
|
}
|
|
40
42
|
|