@mekari/pixel3-utils 0.0.6 → 0.0.7-dev.1

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.
File without changes
@@ -0,0 +1,86 @@
1
+ import {
2
+ canUseDOM
3
+ } from "./chunk-OVY52ELY.mjs";
4
+ import {
5
+ __name
6
+ } from "./chunk-QZ7VFGWC.mjs";
7
+
8
+ // src/composables/usePixelTheme.ts
9
+ import { watch } from "vue";
10
+ import { useStorage } from "@vueuse/core";
11
+ var isDark = useStorage("pixel-dark-mode", false);
12
+ var isNextTheme = useStorage("pixel-next-theme", false);
13
+ function usePixelTheme() {
14
+ function setDarkMode(value) {
15
+ isDark.value = value;
16
+ }
17
+ __name(setDarkMode, "setDarkMode");
18
+ function setNextTheme(value) {
19
+ isNextTheme.value = value;
20
+ }
21
+ __name(setNextTheme, "setNextTheme");
22
+ function showLightMode() {
23
+ if (!canUseDOM)
24
+ return;
25
+ document.documentElement.classList.add("light");
26
+ document.documentElement.classList.remove("dark");
27
+ }
28
+ __name(showLightMode, "showLightMode");
29
+ function showDarkMode() {
30
+ if (!canUseDOM)
31
+ return;
32
+ document.documentElement.classList.add("dark");
33
+ document.documentElement.classList.remove("light");
34
+ }
35
+ __name(showDarkMode, "showDarkMode");
36
+ function applyNextTheme() {
37
+ if (!canUseDOM)
38
+ return;
39
+ document.documentElement.setAttribute("data-panda-theme", "next");
40
+ }
41
+ __name(applyNextTheme, "applyNextTheme");
42
+ function removeNextTheme() {
43
+ if (!canUseDOM)
44
+ return;
45
+ document.documentElement.removeAttribute("data-panda-theme");
46
+ }
47
+ __name(removeNextTheme, "removeNextTheme");
48
+ function getComputedCSSVariableValue(variable) {
49
+ if (!canUseDOM)
50
+ return;
51
+ return getComputedStyle(document.documentElement).getPropertyValue(variable.slice(4, variable.length - 1)).trim();
52
+ }
53
+ __name(getComputedCSSVariableValue, "getComputedCSSVariableValue");
54
+ watch(() => isDark.value, (value) => {
55
+ if (value) {
56
+ showDarkMode();
57
+ } else {
58
+ showLightMode();
59
+ }
60
+ }, {
61
+ immediate: true
62
+ });
63
+ watch(() => isNextTheme.value, (value) => {
64
+ if (!canUseDOM)
65
+ return;
66
+ if (value) {
67
+ applyNextTheme();
68
+ } else {
69
+ removeNextTheme();
70
+ }
71
+ }, {
72
+ immediate: true
73
+ });
74
+ return {
75
+ isDark,
76
+ isNextTheme,
77
+ setDarkMode,
78
+ setNextTheme,
79
+ getComputedCSSVariableValue
80
+ };
81
+ }
82
+ __name(usePixelTheme, "usePixelTheme");
83
+
84
+ export {
85
+ usePixelTheme
86
+ };
@@ -44,11 +44,16 @@ function getNode(selector) {
44
44
  }
45
45
  }
46
46
  __name(getNode, "getNode");
47
+ function isNextTheme() {
48
+ return document.querySelector('[data-panda-theme="next"]') !== null;
49
+ }
50
+ __name(isNextTheme, "isNextTheme");
47
51
 
48
52
  export {
49
53
  canUseDOM,
50
54
  isElementVisible,
51
55
  scrollToTargetElement,
52
56
  getElement,
53
- getNode
57
+ getNode,
58
+ isNextTheme
54
59
  };
@@ -0,0 +1,2 @@
1
+ export { usePixelTheme } from './usePixelTheme.mjs';
2
+ import '@vueuse/core';
@@ -0,0 +1,2 @@
1
+ export { usePixelTheme } from './usePixelTheme.js';
2
+ import '@vueuse/core';
@@ -0,0 +1,111 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
7
+ var __export = (target, all) => {
8
+ for (var name in all)
9
+ __defProp(target, name, { get: all[name], enumerable: true });
10
+ };
11
+ var __copyProps = (to, from, except, desc) => {
12
+ if (from && typeof from === "object" || typeof from === "function") {
13
+ for (let key of __getOwnPropNames(from))
14
+ if (!__hasOwnProp.call(to, key) && key !== except)
15
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
16
+ }
17
+ return to;
18
+ };
19
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
20
+
21
+ // src/composables/index.ts
22
+ var composables_exports = {};
23
+ __export(composables_exports, {
24
+ usePixelTheme: () => usePixelTheme
25
+ });
26
+ module.exports = __toCommonJS(composables_exports);
27
+
28
+ // src/composables/usePixelTheme.ts
29
+ var import_vue = require("vue");
30
+ var import_core = require("@vueuse/core");
31
+
32
+ // src/dom.ts
33
+ var canUseDOM = !!(typeof window !== "undefined" && window.document && window.document.createElement);
34
+
35
+ // src/composables/usePixelTheme.ts
36
+ var isDark = (0, import_core.useStorage)("pixel-dark-mode", false);
37
+ var isNextTheme = (0, import_core.useStorage)("pixel-next-theme", false);
38
+ function usePixelTheme() {
39
+ function setDarkMode(value) {
40
+ isDark.value = value;
41
+ }
42
+ __name(setDarkMode, "setDarkMode");
43
+ function setNextTheme(value) {
44
+ isNextTheme.value = value;
45
+ }
46
+ __name(setNextTheme, "setNextTheme");
47
+ function showLightMode() {
48
+ if (!canUseDOM)
49
+ return;
50
+ document.documentElement.classList.add("light");
51
+ document.documentElement.classList.remove("dark");
52
+ }
53
+ __name(showLightMode, "showLightMode");
54
+ function showDarkMode() {
55
+ if (!canUseDOM)
56
+ return;
57
+ document.documentElement.classList.add("dark");
58
+ document.documentElement.classList.remove("light");
59
+ }
60
+ __name(showDarkMode, "showDarkMode");
61
+ function applyNextTheme() {
62
+ if (!canUseDOM)
63
+ return;
64
+ document.documentElement.setAttribute("data-panda-theme", "next");
65
+ }
66
+ __name(applyNextTheme, "applyNextTheme");
67
+ function removeNextTheme() {
68
+ if (!canUseDOM)
69
+ return;
70
+ document.documentElement.removeAttribute("data-panda-theme");
71
+ }
72
+ __name(removeNextTheme, "removeNextTheme");
73
+ function getComputedCSSVariableValue(variable) {
74
+ if (!canUseDOM)
75
+ return;
76
+ return getComputedStyle(document.documentElement).getPropertyValue(variable.slice(4, variable.length - 1)).trim();
77
+ }
78
+ __name(getComputedCSSVariableValue, "getComputedCSSVariableValue");
79
+ (0, import_vue.watch)(() => isDark.value, (value) => {
80
+ if (value) {
81
+ showDarkMode();
82
+ } else {
83
+ showLightMode();
84
+ }
85
+ }, {
86
+ immediate: true
87
+ });
88
+ (0, import_vue.watch)(() => isNextTheme.value, (value) => {
89
+ if (!canUseDOM)
90
+ return;
91
+ if (value) {
92
+ applyNextTheme();
93
+ } else {
94
+ removeNextTheme();
95
+ }
96
+ }, {
97
+ immediate: true
98
+ });
99
+ return {
100
+ isDark,
101
+ isNextTheme,
102
+ setDarkMode,
103
+ setNextTheme,
104
+ getComputedCSSVariableValue
105
+ };
106
+ }
107
+ __name(usePixelTheme, "usePixelTheme");
108
+ // Annotate the CommonJS export names for ESM import in node:
109
+ 0 && (module.exports = {
110
+ usePixelTheme
111
+ });
@@ -0,0 +1,10 @@
1
+ import "../chunk-34MJNZK5.mjs";
2
+ import {
3
+ usePixelTheme
4
+ } from "../chunk-BAQYFJRO.mjs";
5
+ import "../chunk-OVY52ELY.mjs";
6
+ import "../chunk-XE4ZKGPH.mjs";
7
+ import "../chunk-QZ7VFGWC.mjs";
8
+ export {
9
+ usePixelTheme
10
+ };
@@ -0,0 +1,21 @@
1
+ import * as _vueuse_core from '@vueuse/core';
2
+
3
+ /**
4
+ * Vue composable for managing theme preferences including dark mode and "next" theme in Pixel.
5
+ * Handles system preference detection, theme persistence, and real-time theme switching.
6
+ *
7
+ * @returns {Object} Theme control functions and state
8
+ * @property {ComputedRef<boolean>} isDark - Computed value indicating if dark mode is active
9
+ * @property {ComputedRef<boolean>} isNextTheme - Computed value indicating if next theme is active
10
+ * @property {(value: boolean) => void} setDarkMode - Function to toggle dark mode
11
+ * @property {(value: boolean) => void} setNextTheme - Function to toggle next theme.
12
+ */
13
+ declare function usePixelTheme(): {
14
+ isDark: _vueuse_core.RemovableRef<boolean>;
15
+ isNextTheme: _vueuse_core.RemovableRef<boolean>;
16
+ setDarkMode: (value: boolean) => void;
17
+ setNextTheme: (value: boolean) => void;
18
+ getComputedCSSVariableValue: (variable: string) => string | undefined;
19
+ };
20
+
21
+ export { usePixelTheme };
@@ -0,0 +1,21 @@
1
+ import * as _vueuse_core from '@vueuse/core';
2
+
3
+ /**
4
+ * Vue composable for managing theme preferences including dark mode and "next" theme in Pixel.
5
+ * Handles system preference detection, theme persistence, and real-time theme switching.
6
+ *
7
+ * @returns {Object} Theme control functions and state
8
+ * @property {ComputedRef<boolean>} isDark - Computed value indicating if dark mode is active
9
+ * @property {ComputedRef<boolean>} isNextTheme - Computed value indicating if next theme is active
10
+ * @property {(value: boolean) => void} setDarkMode - Function to toggle dark mode
11
+ * @property {(value: boolean) => void} setNextTheme - Function to toggle next theme.
12
+ */
13
+ declare function usePixelTheme(): {
14
+ isDark: _vueuse_core.RemovableRef<boolean>;
15
+ isNextTheme: _vueuse_core.RemovableRef<boolean>;
16
+ setDarkMode: (value: boolean) => void;
17
+ setNextTheme: (value: boolean) => void;
18
+ getComputedCSSVariableValue: (variable: string) => string | undefined;
19
+ };
20
+
21
+ export { usePixelTheme };
@@ -0,0 +1,109 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
7
+ var __export = (target, all) => {
8
+ for (var name in all)
9
+ __defProp(target, name, { get: all[name], enumerable: true });
10
+ };
11
+ var __copyProps = (to, from, except, desc) => {
12
+ if (from && typeof from === "object" || typeof from === "function") {
13
+ for (let key of __getOwnPropNames(from))
14
+ if (!__hasOwnProp.call(to, key) && key !== except)
15
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
16
+ }
17
+ return to;
18
+ };
19
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
20
+
21
+ // src/composables/usePixelTheme.ts
22
+ var usePixelTheme_exports = {};
23
+ __export(usePixelTheme_exports, {
24
+ usePixelTheme: () => usePixelTheme
25
+ });
26
+ module.exports = __toCommonJS(usePixelTheme_exports);
27
+ var import_vue = require("vue");
28
+ var import_core = require("@vueuse/core");
29
+
30
+ // src/dom.ts
31
+ var canUseDOM = !!(typeof window !== "undefined" && window.document && window.document.createElement);
32
+
33
+ // src/composables/usePixelTheme.ts
34
+ var isDark = (0, import_core.useStorage)("pixel-dark-mode", false);
35
+ var isNextTheme = (0, import_core.useStorage)("pixel-next-theme", false);
36
+ function usePixelTheme() {
37
+ function setDarkMode(value) {
38
+ isDark.value = value;
39
+ }
40
+ __name(setDarkMode, "setDarkMode");
41
+ function setNextTheme(value) {
42
+ isNextTheme.value = value;
43
+ }
44
+ __name(setNextTheme, "setNextTheme");
45
+ function showLightMode() {
46
+ if (!canUseDOM)
47
+ return;
48
+ document.documentElement.classList.add("light");
49
+ document.documentElement.classList.remove("dark");
50
+ }
51
+ __name(showLightMode, "showLightMode");
52
+ function showDarkMode() {
53
+ if (!canUseDOM)
54
+ return;
55
+ document.documentElement.classList.add("dark");
56
+ document.documentElement.classList.remove("light");
57
+ }
58
+ __name(showDarkMode, "showDarkMode");
59
+ function applyNextTheme() {
60
+ if (!canUseDOM)
61
+ return;
62
+ document.documentElement.setAttribute("data-panda-theme", "next");
63
+ }
64
+ __name(applyNextTheme, "applyNextTheme");
65
+ function removeNextTheme() {
66
+ if (!canUseDOM)
67
+ return;
68
+ document.documentElement.removeAttribute("data-panda-theme");
69
+ }
70
+ __name(removeNextTheme, "removeNextTheme");
71
+ function getComputedCSSVariableValue(variable) {
72
+ if (!canUseDOM)
73
+ return;
74
+ return getComputedStyle(document.documentElement).getPropertyValue(variable.slice(4, variable.length - 1)).trim();
75
+ }
76
+ __name(getComputedCSSVariableValue, "getComputedCSSVariableValue");
77
+ (0, import_vue.watch)(() => isDark.value, (value) => {
78
+ if (value) {
79
+ showDarkMode();
80
+ } else {
81
+ showLightMode();
82
+ }
83
+ }, {
84
+ immediate: true
85
+ });
86
+ (0, import_vue.watch)(() => isNextTheme.value, (value) => {
87
+ if (!canUseDOM)
88
+ return;
89
+ if (value) {
90
+ applyNextTheme();
91
+ } else {
92
+ removeNextTheme();
93
+ }
94
+ }, {
95
+ immediate: true
96
+ });
97
+ return {
98
+ isDark,
99
+ isNextTheme,
100
+ setDarkMode,
101
+ setNextTheme,
102
+ getComputedCSSVariableValue
103
+ };
104
+ }
105
+ __name(usePixelTheme, "usePixelTheme");
106
+ // Annotate the CommonJS export names for ESM import in node:
107
+ 0 && (module.exports = {
108
+ usePixelTheme
109
+ });
@@ -0,0 +1,9 @@
1
+ import {
2
+ usePixelTheme
3
+ } from "../chunk-BAQYFJRO.mjs";
4
+ import "../chunk-OVY52ELY.mjs";
5
+ import "../chunk-XE4ZKGPH.mjs";
6
+ import "../chunk-QZ7VFGWC.mjs";
7
+ export {
8
+ usePixelTheme
9
+ };
package/dist/dom.d.mts CHANGED
@@ -27,5 +27,10 @@ declare function getElement(selector: string, domain?: Element): Element | null;
27
27
  * @returns {Element | null}
28
28
  */
29
29
  declare function getNode(selector: string | ComponentPublicInstance): Element | null;
30
+ /**
31
+ * isNextTheme
32
+ * @returns {boolean}
33
+ */
34
+ declare function isNextTheme(): boolean;
30
35
 
31
- export { canUseDOM, getElement, getNode, isElementVisible, scrollToTargetElement };
36
+ export { canUseDOM, getElement, getNode, isElementVisible, isNextTheme, scrollToTargetElement };
package/dist/dom.d.ts CHANGED
@@ -27,5 +27,10 @@ declare function getElement(selector: string, domain?: Element): Element | null;
27
27
  * @returns {Element | null}
28
28
  */
29
29
  declare function getNode(selector: string | ComponentPublicInstance): Element | null;
30
+ /**
31
+ * isNextTheme
32
+ * @returns {boolean}
33
+ */
34
+ declare function isNextTheme(): boolean;
30
35
 
31
- export { canUseDOM, getElement, getNode, isElementVisible, scrollToTargetElement };
36
+ export { canUseDOM, getElement, getNode, isElementVisible, isNextTheme, scrollToTargetElement };
package/dist/dom.js CHANGED
@@ -25,6 +25,7 @@ __export(dom_exports, {
25
25
  getElement: () => getElement,
26
26
  getNode: () => getNode,
27
27
  isElementVisible: () => isElementVisible,
28
+ isNextTheme: () => isNextTheme,
28
29
  scrollToTargetElement: () => scrollToTargetElement
29
30
  });
30
31
  module.exports = __toCommonJS(dom_exports);
@@ -74,11 +75,16 @@ function getNode(selector) {
74
75
  }
75
76
  }
76
77
  __name(getNode, "getNode");
78
+ function isNextTheme() {
79
+ return document.querySelector('[data-panda-theme="next"]') !== null;
80
+ }
81
+ __name(isNextTheme, "isNextTheme");
77
82
  // Annotate the CommonJS export names for ESM import in node:
78
83
  0 && (module.exports = {
79
84
  canUseDOM,
80
85
  getElement,
81
86
  getNode,
82
87
  isElementVisible,
88
+ isNextTheme,
83
89
  scrollToTargetElement
84
90
  });
package/dist/dom.mjs CHANGED
@@ -3,8 +3,9 @@ import {
3
3
  getElement,
4
4
  getNode,
5
5
  isElementVisible,
6
+ isNextTheme,
6
7
  scrollToTargetElement
7
- } from "./chunk-OWHIB6RC.mjs";
8
+ } from "./chunk-OVY52ELY.mjs";
8
9
  import "./chunk-XE4ZKGPH.mjs";
9
10
  import "./chunk-QZ7VFGWC.mjs";
10
11
  export {
@@ -12,5 +13,6 @@ export {
12
13
  getElement,
13
14
  getNode,
14
15
  isElementVisible,
16
+ isNextTheme,
15
17
  scrollToTargetElement
16
18
  };
package/dist/index.d.mts CHANGED
@@ -3,9 +3,10 @@ export { isDef, isEqual, isPixelTagComponent, isUndef, isVueComponent } from './
3
3
  export { declareEmit, getUniqueId, useId } from './generators.mjs';
4
4
  export { getChildren, isObject, objectFilter, objectFilterUndefined } from './object.mjs';
5
5
  export { usePixelCreateContext } from './context.mjs';
6
- export { canUseDOM, getElement, getNode, isElementVisible, scrollToTargetElement } from './dom.mjs';
6
+ export { canUseDOM, getElement, getNode, isElementVisible, isNextTheme, scrollToTargetElement } from './dom.mjs';
7
7
  export { CombinedString, ComponentWithProps, Dict, FilterFn, Optional, PropTypes, PropsTable, definePropsTable } from './types.mjs';
8
8
  export { groupBy } from './array.mjs';
9
+ export { usePixelTheme } from './composables/usePixelTheme.mjs';
9
10
  export { onClickOutside, onKeyStroke, unrefElement, useInfiniteScroll, useIntersectionObserver, useScrollLock, useStorage, useStyleTag, useVirtualList } from '@vueuse/core';
10
11
  export { useFocusTrap } from '@vueuse/integrations/useFocusTrap';
11
12
  import 'vue';
package/dist/index.d.ts CHANGED
@@ -3,9 +3,10 @@ export { isDef, isEqual, isPixelTagComponent, isUndef, isVueComponent } from './
3
3
  export { declareEmit, getUniqueId, useId } from './generators.js';
4
4
  export { getChildren, isObject, objectFilter, objectFilterUndefined } from './object.js';
5
5
  export { usePixelCreateContext } from './context.js';
6
- export { canUseDOM, getElement, getNode, isElementVisible, scrollToTargetElement } from './dom.js';
6
+ export { canUseDOM, getElement, getNode, isElementVisible, isNextTheme, scrollToTargetElement } from './dom.js';
7
7
  export { CombinedString, ComponentWithProps, Dict, FilterFn, Optional, PropTypes, PropsTable, definePropsTable } from './types.js';
8
8
  export { groupBy } from './array.js';
9
+ export { usePixelTheme } from './composables/usePixelTheme.js';
9
10
  export { onClickOutside, onKeyStroke, unrefElement, useInfiniteScroll, useIntersectionObserver, useScrollLock, useStorage, useStyleTag, useVirtualList } from '@vueuse/core';
10
11
  export { useFocusTrap } from '@vueuse/integrations/useFocusTrap';
11
12
  import 'vue';
package/dist/index.js CHANGED
@@ -32,26 +32,28 @@ __export(src_exports, {
32
32
  isDef: () => isDef,
33
33
  isElementVisible: () => isElementVisible,
34
34
  isEqual: () => isEqual,
35
+ isNextTheme: () => isNextTheme,
35
36
  isObject: () => isObject,
36
37
  isPixelTagComponent: () => isPixelTagComponent,
37
38
  isUndef: () => isUndef,
38
39
  isVueComponent: () => isVueComponent,
39
40
  objectFilter: () => objectFilter,
40
41
  objectFilterUndefined: () => objectFilterUndefined,
41
- onClickOutside: () => import_core.onClickOutside,
42
- onKeyStroke: () => import_core.onKeyStroke,
42
+ onClickOutside: () => import_core2.onClickOutside,
43
+ onKeyStroke: () => import_core2.onKeyStroke,
43
44
  scrollToTargetElement: () => scrollToTargetElement,
44
- unrefElement: () => import_core.unrefElement,
45
+ unrefElement: () => import_core2.unrefElement,
45
46
  useFocusTrap: () => import_useFocusTrap.useFocusTrap,
46
47
  useId: () => useId,
47
- useInfiniteScroll: () => import_core.useInfiniteScroll,
48
- useIntersectionObserver: () => import_core.useIntersectionObserver,
48
+ useInfiniteScroll: () => import_core2.useInfiniteScroll,
49
+ useIntersectionObserver: () => import_core2.useIntersectionObserver,
49
50
  usePerformanceObserver: () => usePerformanceObserver,
50
51
  usePixelCreateContext: () => usePixelCreateContext,
51
- useScrollLock: () => import_core.useScrollLock,
52
- useStorage: () => import_core.useStorage,
53
- useStyleTag: () => import_core.useStyleTag,
54
- useVirtualList: () => import_core.useVirtualList
52
+ usePixelTheme: () => usePixelTheme,
53
+ useScrollLock: () => import_core2.useScrollLock,
54
+ useStorage: () => import_core2.useStorage,
55
+ useStyleTag: () => import_core2.useStyleTag,
56
+ useVirtualList: () => import_core2.useVirtualList
55
57
  });
56
58
  module.exports = __toCommonJS(src_exports);
57
59
 
@@ -266,6 +268,10 @@ function getNode(selector) {
266
268
  }
267
269
  }
268
270
  __name(getNode, "getNode");
271
+ function isNextTheme() {
272
+ return document.querySelector('[data-panda-theme="next"]') !== null;
273
+ }
274
+ __name(isNextTheme, "isNextTheme");
269
275
 
270
276
  // src/types.ts
271
277
  function definePropsTable(value) {
@@ -284,8 +290,84 @@ function groupBy(arr, key) {
284
290
  }
285
291
  __name(groupBy, "groupBy");
286
292
 
287
- // src/index.ts
293
+ // src/composables/usePixelTheme.ts
294
+ var import_vue5 = require("vue");
288
295
  var import_core = require("@vueuse/core");
296
+ var isDark = (0, import_core.useStorage)("pixel-dark-mode", false);
297
+ var isNextTheme2 = (0, import_core.useStorage)("pixel-next-theme", false);
298
+ function usePixelTheme() {
299
+ function setDarkMode(value) {
300
+ isDark.value = value;
301
+ }
302
+ __name(setDarkMode, "setDarkMode");
303
+ function setNextTheme(value) {
304
+ isNextTheme2.value = value;
305
+ }
306
+ __name(setNextTheme, "setNextTheme");
307
+ function showLightMode() {
308
+ if (!canUseDOM)
309
+ return;
310
+ document.documentElement.classList.add("light");
311
+ document.documentElement.classList.remove("dark");
312
+ }
313
+ __name(showLightMode, "showLightMode");
314
+ function showDarkMode() {
315
+ if (!canUseDOM)
316
+ return;
317
+ document.documentElement.classList.add("dark");
318
+ document.documentElement.classList.remove("light");
319
+ }
320
+ __name(showDarkMode, "showDarkMode");
321
+ function applyNextTheme() {
322
+ if (!canUseDOM)
323
+ return;
324
+ document.documentElement.setAttribute("data-panda-theme", "next");
325
+ }
326
+ __name(applyNextTheme, "applyNextTheme");
327
+ function removeNextTheme() {
328
+ if (!canUseDOM)
329
+ return;
330
+ document.documentElement.removeAttribute("data-panda-theme");
331
+ }
332
+ __name(removeNextTheme, "removeNextTheme");
333
+ function getComputedCSSVariableValue(variable) {
334
+ if (!canUseDOM)
335
+ return;
336
+ return getComputedStyle(document.documentElement).getPropertyValue(variable.slice(4, variable.length - 1)).trim();
337
+ }
338
+ __name(getComputedCSSVariableValue, "getComputedCSSVariableValue");
339
+ (0, import_vue5.watch)(() => isDark.value, (value) => {
340
+ if (value) {
341
+ showDarkMode();
342
+ } else {
343
+ showLightMode();
344
+ }
345
+ }, {
346
+ immediate: true
347
+ });
348
+ (0, import_vue5.watch)(() => isNextTheme2.value, (value) => {
349
+ if (!canUseDOM)
350
+ return;
351
+ if (value) {
352
+ applyNextTheme();
353
+ } else {
354
+ removeNextTheme();
355
+ }
356
+ }, {
357
+ immediate: true
358
+ });
359
+ return {
360
+ isDark,
361
+ isNextTheme: isNextTheme2,
362
+ setDarkMode,
363
+ setNextTheme,
364
+ getComputedCSSVariableValue
365
+ };
366
+ }
367
+ __name(usePixelTheme, "usePixelTheme");
368
+
369
+ // src/index.ts
370
+ var import_core2 = require("@vueuse/core");
289
371
  var import_useFocusTrap = require("@vueuse/integrations/useFocusTrap");
290
372
  // Annotate the CommonJS export names for ESM import in node:
291
373
  0 && (module.exports = {
@@ -300,6 +382,7 @@ var import_useFocusTrap = require("@vueuse/integrations/useFocusTrap");
300
382
  isDef,
301
383
  isElementVisible,
302
384
  isEqual,
385
+ isNextTheme,
303
386
  isObject,
304
387
  isPixelTagComponent,
305
388
  isUndef,
@@ -316,6 +399,7 @@ var import_useFocusTrap = require("@vueuse/integrations/useFocusTrap");
316
399
  useIntersectionObserver,
317
400
  usePerformanceObserver,
318
401
  usePixelCreateContext,
402
+ usePixelTheme,
319
403
  useScrollLock,
320
404
  useStorage,
321
405
  useStyleTag,
package/dist/index.mjs CHANGED
@@ -1,3 +1,7 @@
1
+ import "./chunk-34MJNZK5.mjs";
2
+ import {
3
+ usePixelTheme
4
+ } from "./chunk-BAQYFJRO.mjs";
1
5
  import {
2
6
  groupBy
3
7
  } from "./chunk-555RL46T.mjs";
@@ -9,8 +13,9 @@ import {
9
13
  getElement,
10
14
  getNode,
11
15
  isElementVisible,
16
+ isNextTheme,
12
17
  scrollToTargetElement
13
- } from "./chunk-OWHIB6RC.mjs";
18
+ } from "./chunk-OVY52ELY.mjs";
14
19
  import {
15
20
  isDef,
16
21
  isEqual,
@@ -52,6 +57,7 @@ export {
52
57
  isDef,
53
58
  isElementVisible,
54
59
  isEqual,
60
+ isNextTheme,
55
61
  isObject,
56
62
  isPixelTagComponent,
57
63
  isUndef,
@@ -68,6 +74,7 @@ export {
68
74
  useIntersectionObserver,
69
75
  usePerformanceObserver,
70
76
  usePixelCreateContext,
77
+ usePixelTheme,
71
78
  useScrollLock,
72
79
  useStorage,
73
80
  useStyleTag,
@@ -1 +1 @@
1
- {"inputs":{"src/array.ts":{"bytes":479,"imports":[{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/context.ts":{"bytes":493,"imports":[{"path":"vue","kind":"import-statement","external":true},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/validators.ts":{"bytes":1787,"imports":[{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/dom.ts":{"bytes":1850,"imports":[{"path":"src/validators.ts","kind":"import-statement","original":"./validators"},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/generators.ts":{"bytes":778,"imports":[{"path":"vue","kind":"import-statement","external":true},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/performance.ts":{"bytes":2171,"imports":[{"path":"vue","kind":"import-statement","external":true},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/object.ts":{"bytes":918,"imports":[{"path":"vue","kind":"import-statement","external":true},{"path":"./types","kind":"import-statement","external":true},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/types.ts":{"bytes":1205,"imports":[{"path":"vue","kind":"import-statement","external":true},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/index.ts":{"bytes":566,"imports":[{"path":"src/performance.ts","kind":"import-statement","original":"./performance"},{"path":"src/validators.ts","kind":"import-statement","original":"./validators"},{"path":"src/generators.ts","kind":"import-statement","original":"./generators"},{"path":"src/object.ts","kind":"import-statement","original":"./object"},{"path":"src/context.ts","kind":"import-statement","original":"./context"},{"path":"src/dom.ts","kind":"import-statement","original":"./dom"},{"path":"src/types.ts","kind":"import-statement","original":"./types"},{"path":"src/array.ts","kind":"import-statement","original":"./array"},{"path":"src/types.ts","kind":"import-statement","original":"./types"},{"path":"@vueuse/core","kind":"import-statement","external":true},{"path":"@vueuse/integrations/useFocusTrap","kind":"import-statement","external":true}],"format":"esm"}},"outputs":{"dist/array.js":{"imports":[],"exports":[],"entryPoint":"src/array.ts","inputs":{"src/array.ts":{"bytesInOutput":377}},"bytes":1384},"dist/context.js":{"imports":[{"path":"vue","kind":"require-call","external":true}],"exports":[],"entryPoint":"src/context.ts","inputs":{"src/context.ts":{"bytesInOutput":579}},"bytes":1602},"dist/dom.js":{"imports":[],"exports":[],"entryPoint":"src/dom.ts","inputs":{"src/dom.ts":{"bytesInOutput":1514},"src/validators.ts":{"bytesInOutput":110}},"bytes":2738},"dist/generators.js":{"imports":[{"path":"vue","kind":"require-call","external":true}],"exports":[],"entryPoint":"src/generators.ts","inputs":{"src/generators.ts":{"bytesInOutput":953}},"bytes":1993},"dist/index.js":{"imports":[{"path":"vue","kind":"require-call","external":true},{"path":"vue","kind":"require-call","external":true},{"path":"vue","kind":"require-call","external":true},{"path":"vue","kind":"require-call","external":true},{"path":"@vueuse/core","kind":"require-call","external":true},{"path":"@vueuse/integrations/useFocusTrap","kind":"require-call","external":true}],"exports":[],"entryPoint":"src/index.ts","inputs":{"src/index.ts":{"bytesInOutput":1502},"src/performance.ts":{"bytesInOutput":1935},"src/validators.ts":{"bytesInOutput":1355},"src/generators.ts":{"bytesInOutput":752},"src/object.ts":{"bytesInOutput":851},"src/context.ts":{"bytesInOutput":423},"src/dom.ts":{"bytesInOutput":1235},"src/types.ts":{"bytesInOutput":99},"src/array.ts":{"bytesInOutput":252}},"bytes":10091},"dist/object.js":{"imports":[{"path":"vue","kind":"require-call","external":true}],"exports":[],"entryPoint":"src/object.ts","inputs":{"src/object.ts":{"bytesInOutput":1103}},"bytes":2168},"dist/performance.js":{"imports":[{"path":"vue","kind":"require-call","external":true}],"exports":[],"entryPoint":"src/performance.ts","inputs":{"src/performance.ts":{"bytesInOutput":2108}},"bytes":3136},"dist/types.js":{"imports":[],"exports":[],"entryPoint":"src/types.ts","inputs":{"src/types.ts":{"bytesInOutput":242}},"bytes":1258},"dist/validators.js":{"imports":[],"exports":[],"entryPoint":"src/validators.ts","inputs":{"src/validators.ts":{"bytesInOutput":1633}},"bytes":2706}}}
1
+ {"inputs":{"src/array.ts":{"bytes":479,"imports":[{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/context.ts":{"bytes":493,"imports":[{"path":"vue","kind":"import-statement","external":true},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/validators.ts":{"bytes":1787,"imports":[{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/dom.ts":{"bytes":2010,"imports":[{"path":"src/validators.ts","kind":"import-statement","original":"./validators"},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/generators.ts":{"bytes":778,"imports":[{"path":"vue","kind":"import-statement","external":true},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/performance.ts":{"bytes":2171,"imports":[{"path":"vue","kind":"import-statement","external":true},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/object.ts":{"bytes":918,"imports":[{"path":"vue","kind":"import-statement","external":true},{"path":"./types","kind":"import-statement","external":true},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/types.ts":{"bytes":1205,"imports":[{"path":"vue","kind":"import-statement","external":true},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/composables/usePixelTheme.ts":{"bytes":2808,"imports":[{"path":"vue","kind":"import-statement","external":true},{"path":"@vueuse/core","kind":"import-statement","external":true},{"path":"src/dom.ts","kind":"import-statement","original":"../dom"},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/composables/index.ts":{"bytes":117,"imports":[{"path":"src/composables/usePixelTheme.ts","kind":"import-statement","original":"./usePixelTheme"}],"format":"esm"},"src/index.ts":{"bytes":597,"imports":[{"path":"src/performance.ts","kind":"import-statement","original":"./performance"},{"path":"src/validators.ts","kind":"import-statement","original":"./validators"},{"path":"src/generators.ts","kind":"import-statement","original":"./generators"},{"path":"src/object.ts","kind":"import-statement","original":"./object"},{"path":"src/context.ts","kind":"import-statement","original":"./context"},{"path":"src/dom.ts","kind":"import-statement","original":"./dom"},{"path":"src/types.ts","kind":"import-statement","original":"./types"},{"path":"src/array.ts","kind":"import-statement","original":"./array"},{"path":"src/types.ts","kind":"import-statement","original":"./types"},{"path":"src/composables/index.ts","kind":"import-statement","original":"./composables"},{"path":"@vueuse/core","kind":"import-statement","external":true},{"path":"@vueuse/integrations/useFocusTrap","kind":"import-statement","external":true}],"format":"esm"}},"outputs":{"dist/array.js":{"imports":[],"exports":[],"entryPoint":"src/array.ts","inputs":{"src/array.ts":{"bytesInOutput":377}},"bytes":1384},"dist/context.js":{"imports":[{"path":"vue","kind":"require-call","external":true}],"exports":[],"entryPoint":"src/context.ts","inputs":{"src/context.ts":{"bytesInOutput":579}},"bytes":1602},"dist/dom.js":{"imports":[],"exports":[],"entryPoint":"src/dom.ts","inputs":{"src/dom.ts":{"bytesInOutput":1682},"src/validators.ts":{"bytesInOutput":110}},"bytes":2921},"dist/generators.js":{"imports":[{"path":"vue","kind":"require-call","external":true}],"exports":[],"entryPoint":"src/generators.ts","inputs":{"src/generators.ts":{"bytesInOutput":953}},"bytes":1993},"dist/index.js":{"imports":[{"path":"vue","kind":"require-call","external":true},{"path":"vue","kind":"require-call","external":true},{"path":"vue","kind":"require-call","external":true},{"path":"vue","kind":"require-call","external":true},{"path":"vue","kind":"require-call","external":true},{"path":"@vueuse/core","kind":"require-call","external":true},{"path":"@vueuse/core","kind":"require-call","external":true},{"path":"@vueuse/integrations/useFocusTrap","kind":"require-call","external":true}],"exports":[],"entryPoint":"src/index.ts","inputs":{"src/index.ts":{"bytesInOutput":1584},"src/performance.ts":{"bytesInOutput":1935},"src/validators.ts":{"bytesInOutput":1355},"src/generators.ts":{"bytesInOutput":752},"src/object.ts":{"bytesInOutput":851},"src/context.ts":{"bytesInOutput":423},"src/dom.ts":{"bytesInOutput":1369},"src/types.ts":{"bytesInOutput":99},"src/array.ts":{"bytesInOutput":252},"src/composables/usePixelTheme.ts":{"bytesInOutput":2085},"src/composables/index.ts":{"bytesInOutput":0}},"bytes":12461},"dist/object.js":{"imports":[{"path":"vue","kind":"require-call","external":true}],"exports":[],"entryPoint":"src/object.ts","inputs":{"src/object.ts":{"bytesInOutput":1103}},"bytes":2168},"dist/performance.js":{"imports":[{"path":"vue","kind":"require-call","external":true}],"exports":[],"entryPoint":"src/performance.ts","inputs":{"src/performance.ts":{"bytesInOutput":2108}},"bytes":3136},"dist/types.js":{"imports":[],"exports":[],"entryPoint":"src/types.ts","inputs":{"src/types.ts":{"bytesInOutput":242}},"bytes":1258},"dist/validators.js":{"imports":[],"exports":[],"entryPoint":"src/validators.ts","inputs":{"src/validators.ts":{"bytesInOutput":1633}},"bytes":2706},"dist/composables/index.js":{"imports":[{"path":"vue","kind":"require-call","external":true},{"path":"@vueuse/core","kind":"require-call","external":true}],"exports":[],"entryPoint":"src/composables/index.ts","inputs":{"src/composables/index.ts":{"bytesInOutput":155},"src/composables/usePixelTheme.ts":{"bytesInOutput":2065},"src/dom.ts":{"bytesInOutput":103}},"bytes":3437},"dist/composables/usePixelTheme.js":{"imports":[{"path":"vue","kind":"require-call","external":true},{"path":"@vueuse/core","kind":"require-call","external":true}],"exports":[],"entryPoint":"src/composables/usePixelTheme.ts","inputs":{"src/composables/usePixelTheme.ts":{"bytesInOutput":2226},"src/dom.ts":{"bytesInOutput":103}},"bytes":3414}}}
@@ -1 +1 @@
1
- {"inputs":{"src/array.ts":{"bytes":479,"imports":[{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/context.ts":{"bytes":493,"imports":[{"path":"vue","kind":"import-statement","external":true},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/validators.ts":{"bytes":1787,"imports":[{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/dom.ts":{"bytes":1850,"imports":[{"path":"src/validators.ts","kind":"import-statement","original":"./validators"},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/generators.ts":{"bytes":778,"imports":[{"path":"vue","kind":"import-statement","external":true},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/performance.ts":{"bytes":2171,"imports":[{"path":"vue","kind":"import-statement","external":true},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/object.ts":{"bytes":918,"imports":[{"path":"vue","kind":"import-statement","external":true},{"path":"./types","kind":"import-statement","external":true},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/types.ts":{"bytes":1205,"imports":[{"path":"vue","kind":"import-statement","external":true},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/index.ts":{"bytes":566,"imports":[{"path":"src/performance.ts","kind":"import-statement","original":"./performance"},{"path":"src/validators.ts","kind":"import-statement","original":"./validators"},{"path":"src/generators.ts","kind":"import-statement","original":"./generators"},{"path":"src/object.ts","kind":"import-statement","original":"./object"},{"path":"src/context.ts","kind":"import-statement","original":"./context"},{"path":"src/dom.ts","kind":"import-statement","original":"./dom"},{"path":"src/types.ts","kind":"import-statement","original":"./types"},{"path":"src/array.ts","kind":"import-statement","original":"./array"},{"path":"src/types.ts","kind":"import-statement","original":"./types"},{"path":"@vueuse/core","kind":"import-statement","external":true},{"path":"@vueuse/integrations/useFocusTrap","kind":"import-statement","external":true}],"format":"esm"}},"outputs":{"dist/validators.mjs":{"imports":[{"path":"dist/chunk-XE4ZKGPH.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["isDef","isEqual","isPixelTagComponent","isUndef","isVueComponent"],"entryPoint":"src/validators.ts","inputs":{},"bytes":225},"dist/array.mjs":{"imports":[{"path":"dist/chunk-555RL46T.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["groupBy"],"entryPoint":"src/array.ts","inputs":{},"bytes":103},"dist/context.mjs":{"imports":[{"path":"dist/chunk-HXLTBFWE.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["usePixelCreateContext"],"entryPoint":"src/context.ts","inputs":{},"bytes":131},"dist/dom.mjs":{"imports":[{"path":"dist/chunk-OWHIB6RC.mjs","kind":"import-statement"},{"path":"dist/chunk-XE4ZKGPH.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["canUseDOM","getElement","getNode","isElementVisible","scrollToTargetElement"],"entryPoint":"src/dom.ts","inputs":{},"bytes":278},"dist/generators.mjs":{"imports":[{"path":"dist/chunk-TJIIVYQV.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["declareEmit","getUniqueId","useId"],"entryPoint":"src/generators.ts","inputs":{},"bytes":159},"dist/index.mjs":{"imports":[{"path":"dist/chunk-555RL46T.mjs","kind":"import-statement"},{"path":"dist/chunk-HXLTBFWE.mjs","kind":"import-statement"},{"path":"dist/chunk-OWHIB6RC.mjs","kind":"import-statement"},{"path":"dist/chunk-XE4ZKGPH.mjs","kind":"import-statement"},{"path":"dist/chunk-TJIIVYQV.mjs","kind":"import-statement"},{"path":"dist/chunk-PLTSXP5P.mjs","kind":"import-statement"},{"path":"dist/chunk-65WDFMBW.mjs","kind":"import-statement"},{"path":"dist/chunk-P3Q2WHZW.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"},{"path":"@vueuse/core","kind":"import-statement","external":true},{"path":"@vueuse/integrations/useFocusTrap","kind":"import-statement","external":true}],"exports":["canUseDOM","declareEmit","definePropsTable","getChildren","getElement","getNode","getUniqueId","groupBy","isDef","isElementVisible","isEqual","isObject","isPixelTagComponent","isUndef","isVueComponent","objectFilter","objectFilterUndefined","onClickOutside","onKeyStroke","scrollToTargetElement","unrefElement","useFocusTrap","useId","useInfiniteScroll","useIntersectionObserver","usePerformanceObserver","usePixelCreateContext","useScrollLock","useStorage","useStyleTag","useVirtualList"],"entryPoint":"src/index.ts","inputs":{"src/index.ts":{"bytesInOutput":240}},"bytes":1476},"dist/chunk-555RL46T.mjs":{"imports":[{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["groupBy"],"inputs":{"src/array.ts":{"bytesInOutput":252}},"bytes":341},"dist/chunk-HXLTBFWE.mjs":{"imports":[{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"},{"path":"vue","kind":"import-statement","external":true}],"exports":["usePixelCreateContext"],"inputs":{"src/context.ts":{"bytesInOutput":394}},"bytes":499},"dist/chunk-OWHIB6RC.mjs":{"imports":[{"path":"dist/chunk-XE4ZKGPH.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["canUseDOM","getElement","getNode","isElementVisible","scrollToTargetElement"],"inputs":{"src/dom.ts":{"bytesInOutput":1235}},"bytes":1451},"dist/chunk-XE4ZKGPH.mjs":{"imports":[{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["isDef","isEqual","isPixelTagComponent","isUndef","isVueComponent"],"inputs":{"src/validators.ts":{"bytesInOutput":1355}},"bytes":1510},"dist/chunk-TJIIVYQV.mjs":{"imports":[{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"},{"path":"vue","kind":"import-statement","external":true}],"exports":["declareEmit","getUniqueId","useId"],"inputs":{"src/generators.ts":{"bytesInOutput":721}},"bytes":843},"dist/object.mjs":{"imports":[{"path":"dist/chunk-PLTSXP5P.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["getChildren","isObject","objectFilter","objectFilterUndefined"],"entryPoint":"src/object.ts","inputs":{},"bytes":217},"dist/chunk-PLTSXP5P.mjs":{"imports":[{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"},{"path":"vue","kind":"import-statement","external":true}],"exports":["getChildren","isObject","objectFilter","objectFilterUndefined"],"inputs":{"src/object.ts":{"bytesInOutput":831}},"bytes":978},"dist/performance.mjs":{"imports":[{"path":"dist/chunk-65WDFMBW.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["usePerformanceObserver"],"entryPoint":"src/performance.ts","inputs":{},"bytes":133},"dist/chunk-65WDFMBW.mjs":{"imports":[{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"},{"path":"vue","kind":"import-statement","external":true}],"exports":["usePerformanceObserver"],"inputs":{"src/performance.ts":{"bytesInOutput":1880}},"bytes":1990},"dist/types.mjs":{"imports":[{"path":"dist/chunk-P3Q2WHZW.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["definePropsTable"],"entryPoint":"src/types.ts","inputs":{},"bytes":121},"dist/chunk-P3Q2WHZW.mjs":{"imports":[{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["definePropsTable"],"inputs":{"src/types.ts":{"bytesInOutput":99}},"bytes":197},"dist/chunk-QZ7VFGWC.mjs":{"imports":[],"exports":["__name"],"inputs":{},"bytes":151}}}
1
+ {"inputs":{"src/array.ts":{"bytes":479,"imports":[{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/context.ts":{"bytes":493,"imports":[{"path":"vue","kind":"import-statement","external":true},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/validators.ts":{"bytes":1787,"imports":[{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/dom.ts":{"bytes":2010,"imports":[{"path":"src/validators.ts","kind":"import-statement","original":"./validators"},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/generators.ts":{"bytes":778,"imports":[{"path":"vue","kind":"import-statement","external":true},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/performance.ts":{"bytes":2171,"imports":[{"path":"vue","kind":"import-statement","external":true},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/object.ts":{"bytes":918,"imports":[{"path":"vue","kind":"import-statement","external":true},{"path":"./types","kind":"import-statement","external":true},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/types.ts":{"bytes":1205,"imports":[{"path":"vue","kind":"import-statement","external":true},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/composables/usePixelTheme.ts":{"bytes":2808,"imports":[{"path":"vue","kind":"import-statement","external":true},{"path":"@vueuse/core","kind":"import-statement","external":true},{"path":"src/dom.ts","kind":"import-statement","original":"../dom"},{"path":"<runtime>","kind":"import-statement","external":true}],"format":"esm"},"src/composables/index.ts":{"bytes":117,"imports":[{"path":"src/composables/usePixelTheme.ts","kind":"import-statement","original":"./usePixelTheme"}],"format":"esm"},"src/index.ts":{"bytes":597,"imports":[{"path":"src/performance.ts","kind":"import-statement","original":"./performance"},{"path":"src/validators.ts","kind":"import-statement","original":"./validators"},{"path":"src/generators.ts","kind":"import-statement","original":"./generators"},{"path":"src/object.ts","kind":"import-statement","original":"./object"},{"path":"src/context.ts","kind":"import-statement","original":"./context"},{"path":"src/dom.ts","kind":"import-statement","original":"./dom"},{"path":"src/types.ts","kind":"import-statement","original":"./types"},{"path":"src/array.ts","kind":"import-statement","original":"./array"},{"path":"src/types.ts","kind":"import-statement","original":"./types"},{"path":"src/composables/index.ts","kind":"import-statement","original":"./composables"},{"path":"@vueuse/core","kind":"import-statement","external":true},{"path":"@vueuse/integrations/useFocusTrap","kind":"import-statement","external":true}],"format":"esm"}},"outputs":{"dist/validators.mjs":{"imports":[{"path":"dist/chunk-XE4ZKGPH.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["isDef","isEqual","isPixelTagComponent","isUndef","isVueComponent"],"entryPoint":"src/validators.ts","inputs":{},"bytes":225},"dist/composables/index.mjs":{"imports":[{"path":"dist/chunk-34MJNZK5.mjs","kind":"import-statement"},{"path":"dist/chunk-BAQYFJRO.mjs","kind":"import-statement"},{"path":"dist/chunk-OVY52ELY.mjs","kind":"import-statement"},{"path":"dist/chunk-XE4ZKGPH.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["usePixelTheme"],"entryPoint":"src/composables/index.ts","inputs":{},"bytes":213},"dist/composables/usePixelTheme.mjs":{"imports":[{"path":"dist/chunk-BAQYFJRO.mjs","kind":"import-statement"},{"path":"dist/chunk-OVY52ELY.mjs","kind":"import-statement"},{"path":"dist/chunk-XE4ZKGPH.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["usePixelTheme"],"entryPoint":"src/composables/usePixelTheme.ts","inputs":{},"bytes":181},"dist/array.mjs":{"imports":[{"path":"dist/chunk-555RL46T.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["groupBy"],"entryPoint":"src/array.ts","inputs":{},"bytes":103},"dist/context.mjs":{"imports":[{"path":"dist/chunk-HXLTBFWE.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["usePixelCreateContext"],"entryPoint":"src/context.ts","inputs":{},"bytes":131},"dist/dom.mjs":{"imports":[{"path":"dist/chunk-OVY52ELY.mjs","kind":"import-statement"},{"path":"dist/chunk-XE4ZKGPH.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["canUseDOM","getElement","getNode","isElementVisible","isNextTheme","scrollToTargetElement"],"entryPoint":"src/dom.ts","inputs":{},"bytes":308},"dist/generators.mjs":{"imports":[{"path":"dist/chunk-TJIIVYQV.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["declareEmit","getUniqueId","useId"],"entryPoint":"src/generators.ts","inputs":{},"bytes":159},"dist/index.mjs":{"imports":[{"path":"dist/chunk-34MJNZK5.mjs","kind":"import-statement"},{"path":"dist/chunk-BAQYFJRO.mjs","kind":"import-statement"},{"path":"dist/chunk-555RL46T.mjs","kind":"import-statement"},{"path":"dist/chunk-HXLTBFWE.mjs","kind":"import-statement"},{"path":"dist/chunk-OVY52ELY.mjs","kind":"import-statement"},{"path":"dist/chunk-XE4ZKGPH.mjs","kind":"import-statement"},{"path":"dist/chunk-TJIIVYQV.mjs","kind":"import-statement"},{"path":"dist/chunk-PLTSXP5P.mjs","kind":"import-statement"},{"path":"dist/chunk-65WDFMBW.mjs","kind":"import-statement"},{"path":"dist/chunk-P3Q2WHZW.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"},{"path":"@vueuse/core","kind":"import-statement","external":true},{"path":"@vueuse/integrations/useFocusTrap","kind":"import-statement","external":true}],"exports":["canUseDOM","declareEmit","definePropsTable","getChildren","getElement","getNode","getUniqueId","groupBy","isDef","isElementVisible","isEqual","isNextTheme","isObject","isPixelTagComponent","isUndef","isVueComponent","objectFilter","objectFilterUndefined","onClickOutside","onKeyStroke","scrollToTargetElement","unrefElement","useFocusTrap","useId","useInfiniteScroll","useIntersectionObserver","usePerformanceObserver","usePixelCreateContext","usePixelTheme","useScrollLock","useStorage","useStyleTag","useVirtualList"],"entryPoint":"src/index.ts","inputs":{"src/index.ts":{"bytesInOutput":240}},"bytes":1610},"dist/chunk-34MJNZK5.mjs":{"imports":[],"exports":[],"inputs":{"src/composables/index.ts":{"bytesInOutput":0}},"bytes":0},"dist/chunk-BAQYFJRO.mjs":{"imports":[{"path":"dist/chunk-OVY52ELY.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"},{"path":"vue","kind":"import-statement","external":true},{"path":"@vueuse/core","kind":"import-statement","external":true}],"exports":["usePixelTheme"],"inputs":{"src/composables/usePixelTheme.ts":{"bytesInOutput":1995}},"bytes":2162},"dist/chunk-555RL46T.mjs":{"imports":[{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["groupBy"],"inputs":{"src/array.ts":{"bytesInOutput":252}},"bytes":341},"dist/chunk-HXLTBFWE.mjs":{"imports":[{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"},{"path":"vue","kind":"import-statement","external":true}],"exports":["usePixelCreateContext"],"inputs":{"src/context.ts":{"bytesInOutput":394}},"bytes":499},"dist/chunk-OVY52ELY.mjs":{"imports":[{"path":"dist/chunk-XE4ZKGPH.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["canUseDOM","getElement","getNode","isElementVisible","isNextTheme","scrollToTargetElement"],"inputs":{"src/dom.ts":{"bytesInOutput":1369}},"bytes":1600},"dist/chunk-XE4ZKGPH.mjs":{"imports":[{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["isDef","isEqual","isPixelTagComponent","isUndef","isVueComponent"],"inputs":{"src/validators.ts":{"bytesInOutput":1355}},"bytes":1510},"dist/chunk-TJIIVYQV.mjs":{"imports":[{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"},{"path":"vue","kind":"import-statement","external":true}],"exports":["declareEmit","getUniqueId","useId"],"inputs":{"src/generators.ts":{"bytesInOutput":721}},"bytes":843},"dist/object.mjs":{"imports":[{"path":"dist/chunk-PLTSXP5P.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["getChildren","isObject","objectFilter","objectFilterUndefined"],"entryPoint":"src/object.ts","inputs":{},"bytes":217},"dist/chunk-PLTSXP5P.mjs":{"imports":[{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"},{"path":"vue","kind":"import-statement","external":true}],"exports":["getChildren","isObject","objectFilter","objectFilterUndefined"],"inputs":{"src/object.ts":{"bytesInOutput":831}},"bytes":978},"dist/performance.mjs":{"imports":[{"path":"dist/chunk-65WDFMBW.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["usePerformanceObserver"],"entryPoint":"src/performance.ts","inputs":{},"bytes":133},"dist/chunk-65WDFMBW.mjs":{"imports":[{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"},{"path":"vue","kind":"import-statement","external":true}],"exports":["usePerformanceObserver"],"inputs":{"src/performance.ts":{"bytesInOutput":1880}},"bytes":1990},"dist/types.mjs":{"imports":[{"path":"dist/chunk-P3Q2WHZW.mjs","kind":"import-statement"},{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["definePropsTable"],"entryPoint":"src/types.ts","inputs":{},"bytes":121},"dist/chunk-P3Q2WHZW.mjs":{"imports":[{"path":"dist/chunk-QZ7VFGWC.mjs","kind":"import-statement"}],"exports":["definePropsTable"],"inputs":{"src/types.ts":{"bytesInOutput":99}},"bytes":197},"dist/chunk-QZ7VFGWC.mjs":{"imports":[],"exports":["__name"],"inputs":{},"bytes":151}}}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@mekari/pixel3-utils",
3
3
  "description": "Utils for mekari pixel 3",
4
- "version": "0.0.6",
4
+ "version": "0.0.7-dev.1",
5
5
  "files": [
6
6
  "dist"
7
7
  ],
@@ -37,6 +37,7 @@
37
37
  "build:types": "tsup src --dts-only",
38
38
  "backup-config": "clean-package restore",
39
39
  "replace-config": "clean-package",
40
- "restore-config": "clean-package restore"
40
+ "restore-config": "clean-package restore",
41
+ "types:vue": "vue-tsc --noEmit"
41
42
  }
42
43
  }