@tresjs/leches 0.15.0-next.3 → 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (31) hide show
  1. package/dist/components/BooleanControl.vue.d.ts +7 -18
  2. package/dist/components/ButtonControl.vue.d.ts +5 -16
  3. package/dist/components/ColorControl.vue.d.ts +7 -18
  4. package/dist/components/ControlInput.vue.d.ts +7 -17
  5. package/dist/components/ControlLabel.vue.d.ts +5 -16
  6. package/dist/components/FPSGraph.vue.d.ts +7 -16
  7. package/dist/components/Folder.vue.d.ts +9 -16
  8. package/dist/components/GraphControl.vue.d.ts +9 -0
  9. package/dist/components/NumberControl.vue.d.ts +7 -18
  10. package/dist/components/SelectControl.vue.d.ts +7 -18
  11. package/dist/components/SliderControl.vue.d.ts +7 -18
  12. package/dist/components/TextControl.vue.d.ts +7 -18
  13. package/dist/components/TresLeches.vue.d.ts +38 -12
  14. package/dist/components/VectorControl.vue.d.ts +7 -18
  15. package/dist/composables/useControls.d.ts +8 -10
  16. package/dist/composables/useDraggable/component.d.ts +3 -3
  17. package/dist/composables/useDraggable/index.d.ts +21 -6
  18. package/dist/index.d.ts +2 -4
  19. package/dist/tresleches.js +2667 -829
  20. package/dist/types/index.d.ts +77 -0
  21. package/dist/utils/index.d.ts +1 -2
  22. package/package.json +61 -64
  23. package/dist/components/Graph.vue.d.ts +0 -21
  24. package/dist/components/Perf.vue.d.ts +0 -2
  25. package/dist/components/performance-monitor/Pane.vue.d.ts +0 -22
  26. package/dist/components/performance-monitor/Tree.vue.d.ts +0 -42
  27. package/dist/components/performance-monitor/index.vue.d.ts +0 -21
  28. package/dist/composables/usePerf.d.ts +0 -37
  29. package/dist/style.css +0 -8
  30. package/dist/tresleches.umd.cjs +0 -8
  31. package/dist/utils/perf.d.ts +0 -6
@@ -0,0 +1,77 @@
1
+ export interface LechesSelectOption {
2
+ text: string;
3
+ alias: string;
4
+ value: string | number;
5
+ }
6
+ export type LechesValue = string | number | boolean;
7
+ export type LechesCotrolConfigTypes = 'select' | 'button' | 'range' | 'boolean' | 'text' | 'number';
8
+ export interface LechesBaseControlConfig {
9
+ value: unknown;
10
+ label?: string;
11
+ icon?: string;
12
+ type?: LechesCotrolConfigTypes;
13
+ }
14
+ export interface LechesSelectControlConfig extends LechesBaseControlConfig {
15
+ options: string[] | LechesSelectOption[];
16
+ }
17
+ export interface LechesSelectControlButton extends LechesBaseControlConfig {
18
+ variant: 'primary' | 'secondary';
19
+ onClick?: () => void;
20
+ size?: 'xs' | 'sm' | 'md' | 'lg' | 'xl' | 'block';
21
+ }
22
+ export interface LechesBooleanControl extends Omit<LechesControl<boolean>, 'type'> {
23
+ type: 'boolean';
24
+ value: boolean;
25
+ }
26
+ export interface LechesNumberControl extends Omit<LechesControl<number>, 'type'> {
27
+ type: 'number' | 'range';
28
+ value: number;
29
+ min?: number;
30
+ max?: number;
31
+ step?: number;
32
+ }
33
+ export interface LechesStringControl extends Omit<LechesControl<string>, 'type'> {
34
+ type: 'text' | 'color';
35
+ value: string;
36
+ }
37
+ export interface LechesSelectControl extends Omit<LechesControl<string | number>, 'type'> {
38
+ type: 'select';
39
+ value: string | number;
40
+ options: LechesSelectOption[];
41
+ }
42
+ export interface LechesButtonControl extends Omit<LechesControl<LechesSelectControlButton>, 'type'> {
43
+ type: 'button';
44
+ value: LechesSelectControlButton;
45
+ }
46
+ export interface LechesVectorControl extends Omit<LechesControl<any>, 'type'> {
47
+ type: 'vector';
48
+ value: any;
49
+ }
50
+ export interface LechesGraphControl extends Omit<LechesControl<any>, 'type'> {
51
+ type: 'graph' | 'fpsgraph';
52
+ value: any;
53
+ }
54
+ export type LechesControlUnion = LechesBooleanControl | LechesNumberControl | LechesStringControl | LechesSelectControl | LechesButtonControl | LechesVectorControl | LechesGraphControl;
55
+ export declare function isBooleanControl(control: LechesControlUnion): control is LechesBooleanControl;
56
+ export declare function isNumberControl(control: LechesControlUnion): control is LechesNumberControl;
57
+ export declare function isStringControl(control: LechesControlUnion): control is LechesStringControl;
58
+ export declare function isSelectControl(control: LechesControlUnion): control is LechesSelectControl;
59
+ export declare function isButtonControl(control: LechesControlUnion): control is LechesButtonControl;
60
+ export declare function isVectorControl(control: LechesControlUnion): control is LechesVectorControl;
61
+ export declare function isGraphControl(control: LechesControlUnion): control is LechesGraphControl;
62
+ export interface LechesControl<T = unknown> {
63
+ key: string;
64
+ label: string;
65
+ name: string;
66
+ type: string;
67
+ value: T;
68
+ visible: boolean;
69
+ icon?: string;
70
+ uniqueKey: string;
71
+ folder?: string;
72
+ options?: LechesSelectOption[];
73
+ min?: number;
74
+ max?: number;
75
+ step?: number;
76
+ onUpdate?: (values: unknown[]) => void;
77
+ }
@@ -1,3 +1,2 @@
1
- export * from './normalize';
2
1
  export * from './is';
3
- export * from './perf';
2
+ export * from './normalize';
package/package.json CHANGED
@@ -1,11 +1,14 @@
1
1
  {
2
2
  "name": "@tresjs/leches",
3
3
  "type": "module",
4
- "version": "0.15.0-next.3",
5
- "packageManager": "pnpm@8.3.1",
4
+ "version": "1.0.0",
6
5
  "description": "Tasty GUI for Vue controls 🍰",
7
6
  "author": "Alvaro Saburido <hola@alvarosaburido.dev> (https://github.com/alvarosabu/)",
8
7
  "license": "MIT",
8
+ "repository": {
9
+ "type": "git",
10
+ "url": "git+https://github.com/Tresjs/leches.git"
11
+ },
9
12
  "keywords": [
10
13
  "vue",
11
14
  "gui",
@@ -18,86 +21,80 @@
18
21
  "types": "./dist/index.d.ts",
19
22
  "import": "./dist/tresleches.js"
20
23
  },
21
- "./styles": "./dist/style.css",
24
+ "./styles": "./dist/tresleches.css",
22
25
  "./*": "./*"
23
26
  },
24
27
  "main": "./dist/tresleches.js",
25
28
  "module": "./dist/tresleches.js",
26
29
  "types": "./dist/index.d.ts",
27
30
  "files": [
28
- "dist",
29
- "*.d.ts"
31
+ "*.d.ts",
32
+ "dist"
30
33
  ],
31
34
  "publishConfig": {
32
35
  "access": "public"
33
36
  },
37
+ "peerDependencies": {
38
+ "vue": ">=3.3.4"
39
+ },
40
+ "dependencies": {
41
+ "@unocss/core": "66.3.2",
42
+ "@vueuse/components": "^13.0.0",
43
+ "@vueuse/motion": "^3.0.3",
44
+ "unocss-preset-scrollbar": "^3.2.0"
45
+ },
46
+ "devDependencies": {
47
+ "@iconify-json/ic": "^1.2.2",
48
+ "@iconify/json": "^2.2.320",
49
+ "@typescript-eslint/eslint-plugin": "^8.42.0",
50
+ "@typescript-eslint/parser": "^8.42.0",
51
+ "@vitejs/plugin-vue": "^6.0.1",
52
+ "@vitest/browser": "^3.0.9",
53
+ "@vitest/ui": "^3.2.4",
54
+ "@vue/test-utils": "^2.4.6",
55
+ "@vueuse/core": "^13.9.0",
56
+ "@vueuse/shared": "^13.0.0",
57
+ "eslint": "^9.34.0",
58
+ "eslint-plugin-vitest-globals": "^1.5.0",
59
+ "eslint-plugin-vue": "^10.4.0",
60
+ "kolorist": "^1.8.0",
61
+ "pathe": "^2.0.3",
62
+ "rollup-plugin-analyzer": "^4.0.0",
63
+ "rollup-plugin-visualizer": "^6.0.3",
64
+ "typescript": "^5.8.3",
65
+ "unocss": "^66.1.2",
66
+ "unplugin-vue-components": "^28.8.0",
67
+ "vite": "^7.1.6",
68
+ "vite-plugin-banner": "^0.8.1",
69
+ "vite-plugin-css-injected-by-js": "^3.5.2",
70
+ "vite-plugin-dts": "4.5.4",
71
+ "vite-plugin-inspect": "^11.3.0",
72
+ "vite-svg-loader": "^5.1.0",
73
+ "vitepress": "1.6.4",
74
+ "vitest": "3.2.4",
75
+ "vue": "^3.5.21",
76
+ "webdriverio": "^9.12.1",
77
+ "@tresjs/eslint-config": "1.4.1"
78
+ },
79
+ "nx": {
80
+ "implicitDependencies": [
81
+ "!@tresjs/leches-*"
82
+ ]
83
+ },
34
84
  "scripts": {
35
- "dev": "cd playground && npm run dev",
36
- "build": "vue-tsc && vite build",
85
+ "dev": "cd playground && pnpm run dev",
86
+ "build": "vite build",
37
87
  "preview": "vite preview",
38
- "playground": "cd playground && npm run dev",
88
+ "playground": "cd playground && pnpm run dev",
39
89
  "test": "vitest",
40
- "test:ci": "vitest run",
90
+ "test:ci": "echo 'Tests disabled for this branch'",
41
91
  "test:ui": "vitest --ui",
42
92
  "test:browser": "BROWSER_TEST=true HEADLESS=true vitest",
43
93
  "test:browser:ui": "BROWSER_TEST=true vitest",
44
- "release": "release-it",
45
94
  "coverage": "vitest run --coverage",
46
- "lint": "eslint . --ext .js,.jsx,.ts,.tsx,.vue",
47
- "story:dev": "histoire dev",
48
- "story:build": "histoire build",
49
- "story:preview": "histoire preview",
95
+ "lint": "eslint .",
50
96
  "docs:dev": "vitepress dev docs",
51
97
  "docs:build": "vitepress build docs",
52
98
  "docs:preview": "vitepress preview docs"
53
- },
54
- "peerDependencies": {
55
- "three": ">=0.133",
56
- "vue": ">=3.3.4"
57
- },
58
- "dependencies": {
59
- "@tresjs/core": "3.5.1",
60
- "@types/three": "^0.158.1",
61
- "@unocss/core": "^0.57.2",
62
- "@vueuse/components": "^10.5.0",
63
- "vite-plugin-css-injected-by-js": "^3.3.0"
64
- },
65
- "devDependencies": {
66
- "@histoire/plugin-vue": "^0.17.6",
67
- "@iconify-json/ic": "^1.1.16",
68
- "@iconify-json/iconoir": "^1.1.33",
69
- "@iconify/json": "^2.2.150",
70
- "@release-it/conventional-changelog": "^8.0.1",
71
- "@tresjs/eslint-config-vue": "^0.2.1",
72
- "@types/webgl2": "^0.0.10",
73
- "@typescript-eslint/eslint-plugin": "^6.13.1",
74
- "@typescript-eslint/parser": "^6.13.1",
75
- "@vitejs/plugin-vue": "^4.5.0",
76
- "@vitest/browser": "^0.34.6",
77
- "@vitest/ui": "^0.34.6",
78
- "@vue/test-utils": "^2.4.3",
79
- "@vueuse/core": "^10.6.1",
80
- "@vueuse/shared": "^10.6.1",
81
- "eslint": "^8.54.0",
82
- "eslint-plugin-vitest-globals": "^1.4.0",
83
- "eslint-plugin-vue": "^9.19.2",
84
- "histoire": "^0.17.6",
85
- "kolorist": "^1.8.0",
86
- "pathe": "^1.1.1",
87
- "release-it": "^17.0.0",
88
- "rollup-plugin-analyzer": "^4.0.0",
89
- "rollup-plugin-visualizer": "^5.9.3",
90
- "three": "^0.159.0",
91
- "typescript": "^5.3.2",
92
- "unocss": "^0.57.7",
93
- "unplugin-vue-components": "^0.25.2",
94
- "vite": "^5.0.4",
95
- "vite-plugin-banner": "^0.7.1",
96
- "vite-plugin-dts": "^3.6.4",
97
- "vitepress": "1.0.0-rc.31",
98
- "vitest": "^0.34.6",
99
- "vue": "^3.3.9",
100
- "vue-tsc": "^1.8.24",
101
- "webdriverio": "^8.24.5"
102
99
  }
103
- }
100
+ }
@@ -1,21 +0,0 @@
1
- declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
2
- points: Array<number>;
3
- value: number;
4
- unit: string;
5
- label: string;
6
- }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToRuntimeProps<{
7
- points: Array<number>;
8
- value: number;
9
- unit: string;
10
- label: string;
11
- }>>>, {}, {}>;
12
- export default _default;
13
- type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
14
- type __VLS_TypePropsToRuntimeProps<T> = {
15
- [K in keyof T]-?: {} extends Pick<T, K> ? {
16
- type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
17
- } : {
18
- type: import('vue').PropType<T[K]>;
19
- required: true;
20
- };
21
- };
@@ -1,2 +0,0 @@
1
- declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}, {}>;
2
- export default _default;
@@ -1,22 +0,0 @@
1
- declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
2
- title: string;
3
- }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToRuntimeProps<{
4
- title: string;
5
- }>>>, {}, {}>, {
6
- default?(_: {}): any;
7
- }>;
8
- export default _default;
9
- type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
10
- type __VLS_TypePropsToRuntimeProps<T> = {
11
- [K in keyof T]-?: {} extends Pick<T, K> ? {
12
- type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
13
- } : {
14
- type: import('vue').PropType<T[K]>;
15
- required: true;
16
- };
17
- };
18
- type __VLS_WithTemplateSlots<T, S> = T & {
19
- new (): {
20
- $slots: S;
21
- };
22
- };
@@ -1,42 +0,0 @@
1
- interface TreeItem {
2
- name: string;
3
- slug?: string;
4
- children?: TreeItem[];
5
- isOpen?: boolean;
6
- }
7
- declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
8
- items: TreeItem[];
9
- depth?: number | undefined;
10
- }>, {
11
- depth: number;
12
- }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
13
- items: TreeItem[];
14
- depth?: number | undefined;
15
- }>, {
16
- depth: number;
17
- }>>>, {
18
- depth: number;
19
- }, {}>, any>;
20
- export default _default;
21
- type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
22
- type __VLS_TypePropsToRuntimeProps<T> = {
23
- [K in keyof T]-?: {} extends Pick<T, K> ? {
24
- type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
25
- } : {
26
- type: import('vue').PropType<T[K]>;
27
- required: true;
28
- };
29
- };
30
- type __VLS_WithDefaults<P, D> = {
31
- [K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
32
- default: D[K];
33
- }> : P[K];
34
- };
35
- type __VLS_Prettify<T> = {
36
- [K in keyof T]: T[K];
37
- } & {};
38
- type __VLS_WithTemplateSlots<T, S> = T & {
39
- new (): {
40
- $slots: S;
41
- };
42
- };
@@ -1,21 +0,0 @@
1
- export interface WebGL2Program extends WebGLProgram {
2
- name: string;
3
- type: string;
4
- uniforms: Record<string, any>;
5
- getUniforms: () => Record<string, any>;
6
- }
7
- declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimeProps<{
8
- uuid?: string | undefined;
9
- }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToRuntimeProps<{
10
- uuid?: string | undefined;
11
- }>>>, {}, {}>;
12
- export default _default;
13
- type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
14
- type __VLS_TypePropsToRuntimeProps<T> = {
15
- [K in keyof T]-?: {} extends Pick<T, K> ? {
16
- type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
17
- } : {
18
- type: import('vue').PropType<T[K]>;
19
- required: true;
20
- };
21
- };
@@ -1,37 +0,0 @@
1
- import type { Ref } from 'vue';
2
- import type { Scene, WebGLRenderer } from 'three';
3
- interface MemoryUsageData {
4
- currentMem: number;
5
- averageMem: number;
6
- allocatedMem: number;
7
- maxMemory: number;
8
- accumulator: number[];
9
- lastLoggedTime: number;
10
- logInterval: number;
11
- }
12
- interface FpsData {
13
- value: number;
14
- accumulator: number[];
15
- lastLoggedTime: number;
16
- logInterval: number;
17
- }
18
- interface PerfData {
19
- fps: FpsData;
20
- memory: MemoryUsageData;
21
- gl: WebGLRenderer | undefined;
22
- scene: Scene | undefined;
23
- }
24
- export declare const PERF_CONTEXT_KEY: unique symbol;
25
- export declare function usePerfProvider(uuid?: string): PerfData;
26
- export interface TresPerfOptions {
27
- renderer?: Ref<WebGLRenderer>;
28
- }
29
- export declare function usePerf(options?: TresPerfOptions): {
30
- perf: PerfData;
31
- fps: FpsData;
32
- memory: MemoryUsageData;
33
- gl: WebGLRenderer;
34
- pausePerfTracking: import("@vueuse/shared").Fn;
35
- resumePerfTracking: import("@vueuse/shared").Fn;
36
- };
37
- export {};
package/dist/style.css DELETED
@@ -1,8 +0,0 @@
1
- /**
2
- * name: @tresjs/leches
3
- * version: v0.15.0-next.3
4
- * (c) 2023
5
- * description: Tasty GUI for Vue controls 🍰
6
- * author: Alvaro Saburido <hola@alvarosaburido.dev> (https://github.com/alvarosabu/)
7
- */
8
- *,:before,:after{--tl-rotate:0;--tl-rotate-x:0;--tl-rotate-y:0;--tl-rotate-z:0;--tl-scale-x:1;--tl-scale-y:1;--tl-scale-z:1;--tl-skew-x:0;--tl-skew-y:0;--tl-translate-x:0;--tl-translate-y:0;--tl-translate-z:0;--tl-pan-x: ;--tl-pan-y: ;--tl-pinch-zoom: ;--tl-scroll-snap-strictness:proximity;--tl-ordinal: ;--tl-slashed-zero: ;--tl-numeric-figure: ;--tl-numeric-spacing: ;--tl-numeric-fraction: ;--tl-border-spacing-x:0;--tl-border-spacing-y:0;--tl-ring-offset-shadow:0 0 rgb(0 0 0 / 0);--tl-ring-shadow:0 0 rgb(0 0 0 / 0);--tl-shadow-inset: ;--tl-shadow:0 0 rgb(0 0 0 / 0);--tl-ring-inset: ;--tl-ring-offset-width:0px;--tl-ring-offset-color:#fff;--tl-ring-width:0px;--tl-ring-color:rgb(147 197 253 / .5);--tl-blur: ;--tl-brightness: ;--tl-contrast: ;--tl-drop-shadow: ;--tl-grayscale: ;--tl-hue-rotate: ;--tl-invert: ;--tl-saturate: ;--tl-sepia: ;--tl-backdrop-blur: ;--tl-backdrop-brightness: ;--tl-backdrop-contrast: ;--tl-backdrop-grayscale: ;--tl-backdrop-hue-rotate: ;--tl-backdrop-invert: ;--tl-backdrop-opacity: ;--tl-backdrop-saturate: ;--tl-backdrop-sepia: }::backdrop{--tl-rotate:0;--tl-rotate-x:0;--tl-rotate-y:0;--tl-rotate-z:0;--tl-scale-x:1;--tl-scale-y:1;--tl-scale-z:1;--tl-skew-x:0;--tl-skew-y:0;--tl-translate-x:0;--tl-translate-y:0;--tl-translate-z:0;--tl-pan-x: ;--tl-pan-y: ;--tl-pinch-zoom: ;--tl-scroll-snap-strictness:proximity;--tl-ordinal: ;--tl-slashed-zero: ;--tl-numeric-figure: ;--tl-numeric-spacing: ;--tl-numeric-fraction: ;--tl-border-spacing-x:0;--tl-border-spacing-y:0;--tl-ring-offset-shadow:0 0 rgb(0 0 0 / 0);--tl-ring-shadow:0 0 rgb(0 0 0 / 0);--tl-shadow-inset: ;--tl-shadow:0 0 rgb(0 0 0 / 0);--tl-ring-inset: ;--tl-ring-offset-width:0px;--tl-ring-offset-color:#fff;--tl-ring-width:0px;--tl-ring-color:rgb(147 197 253 / .5);--tl-blur: ;--tl-brightness: ;--tl-contrast: ;--tl-drop-shadow: ;--tl-grayscale: ;--tl-hue-rotate: ;--tl-invert: ;--tl-saturate: ;--tl-sepia: ;--tl-backdrop-blur: ;--tl-backdrop-brightness: ;--tl-backdrop-contrast: ;--tl-backdrop-grayscale: ;--tl-backdrop-hue-rotate: ;--tl-backdrop-invert: ;--tl-backdrop-opacity: ;--tl-backdrop-saturate: ;--tl-backdrop-sepia: }@font-face{font-family:Roboto Mono;font-style:normal;font-weight:400;font-display:swap;src:url(https://fonts.gstatic.com/s/robotomono/v23/L0xuDF4xlVMF-BfR8bXMIhJHg45mwgGEFl0_3vq_SeW4Ep0.woff2) format("woff2");unicode-range:U+0460-052F,U+1C80-1C88,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:Roboto Mono;font-style:normal;font-weight:400;font-display:swap;src:url(https://fonts.gstatic.com/s/robotomono/v23/L0xuDF4xlVMF-BfR8bXMIhJHg45mwgGEFl0_3vq_QOW4Ep0.woff2) format("woff2");unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:Roboto Mono;font-style:normal;font-weight:400;font-display:swap;src:url(https://fonts.gstatic.com/s/robotomono/v23/L0xuDF4xlVMF-BfR8bXMIhJHg45mwgGEFl0_3vq_R-W4Ep0.woff2) format("woff2");unicode-range:U+0370-03FF}@font-face{font-family:Roboto Mono;font-style:normal;font-weight:400;font-display:swap;src:url(https://fonts.gstatic.com/s/robotomono/v23/L0xuDF4xlVMF-BfR8bXMIhJHg45mwgGEFl0_3vq_S-W4Ep0.woff2) format("woff2");unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:Roboto Mono;font-style:normal;font-weight:400;font-display:swap;src:url(https://fonts.gstatic.com/s/robotomono/v23/L0xuDF4xlVMF-BfR8bXMIhJHg45mwgGEFl0_3vq_SuW4Ep0.woff2) format("woff2");unicode-range:U+0100-02AF,U+0304,U+0308,U+0329,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20CF,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Roboto Mono;font-style:normal;font-weight:400;font-display:swap;src:url(https://fonts.gstatic.com/s/robotomono/v23/L0xuDF4xlVMF-BfR8bXMIhJHg45mwgGEFl0_3vq_ROW4.woff2) format("woff2");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+2074,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}.i-ic-baseline-drag-indicator{--tl-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' display='inline-block' vertical-align='middle' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='currentColor' d='M11 18c0 1.1-.9 2-2 2s-2-.9-2-2s.9-2 2-2s2 .9 2 2zm-2-8c-1.1 0-2 .9-2 2s.9 2 2 2s2-.9 2-2s-.9-2-2-2zm0-6c-1.1 0-2 .9-2 2s.9 2 2 2s2-.9 2-2s-.9-2-2-2zm6 4c1.1 0 2-.9 2-2s-.9-2-2-2s-2 .9-2 2s.9 2 2 2zm0 2c-1.1 0-2 .9-2 2s.9 2 2 2s2-.9 2-2s-.9-2-2-2zm0 6c-1.1 0-2 .9-2 2s.9 2 2 2s2-.9 2-2s-.9-2-2-2z'/%3E%3C/svg%3E");-webkit-mask:var(--tl-icon) no-repeat;mask:var(--tl-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;display:inline-block;vertical-align:middle;width:1.2em;height:1.2em}.i-ic\:baseline-check{--tl-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' display='inline-block' vertical-align='middle' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='currentColor' d='M9 16.17L4.83 12l-1.42 1.41L9 19L21 7l-1.41-1.41z'/%3E%3C/svg%3E");-webkit-mask:var(--tl-icon) no-repeat;mask:var(--tl-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;display:inline-block;vertical-align:middle;width:1.2em;height:1.2em}.i-ic\:baseline-keyboard-arrow-down{--tl-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' display='inline-block' vertical-align='middle' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='currentColor' d='M7.41 8.59L12 13.17l4.59-4.58L18 10l-6 6l-6-6l1.41-1.41z'/%3E%3C/svg%3E");-webkit-mask:var(--tl-icon) no-repeat;mask:var(--tl-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;display:inline-block;vertical-align:middle;width:1.2em;height:1.2em}.i-ic\:baseline-keyboard-arrow-up{--tl-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' display='inline-block' vertical-align='middle' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='currentColor' d='M7.41 15.41L12 10.83l4.59 4.58L18 14l-6-6l-6 6z'/%3E%3C/svg%3E");-webkit-mask:var(--tl-icon) no-repeat;mask:var(--tl-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;display:inline-block;vertical-align:middle;width:1.2em;height:1.2em}.i-iconoir-box-3d-three-points{--tl-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' display='inline-block' vertical-align='middle' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cg fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5'%3E%3Cpath fill='currentColor' d='M12 23a1 1 0 1 0 0-2a1 1 0 0 0 0 2ZM3 8a1 1 0 1 0 0-2a1 1 0 0 0 0 2Zm0 10a1 1 0 1 0 0-2a1 1 0 0 0 0 2Z'/%3E%3Cpath d='M21 7.353v9.294a.6.6 0 0 1-.309.525l-8.4 4.666a.6.6 0 0 1-.582 0l-8.4-4.666A.6.6 0 0 1 3 16.647V7.353a.6.6 0 0 1 .309-.524l8.4-4.667a.6.6 0 0 1 .582 0l8.4 4.667a.6.6 0 0 1 .309.524Z'/%3E%3Cpath d='m3.528 7.294l8.18 4.544a.6.6 0 0 0 .583 0l8.209-4.56M12 21v-9'/%3E%3C/g%3E%3C/svg%3E");-webkit-mask:var(--tl-icon) no-repeat;mask:var(--tl-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;display:inline-block;vertical-align:middle;width:1.2em;height:1.2em}.i-iconoir-comp-align-left{--tl-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' display='inline-block' vertical-align='middle' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cg fill='none' stroke='currentColor' stroke-width='1.5'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M3 22V2'/%3E%3Cpath d='M19 16H9a2 2 0 0 1-2-2v-4a2 2 0 0 1 2-2h10a2 2 0 0 1 2 2v4a2 2 0 0 1-2 2Z'/%3E%3C/g%3E%3C/svg%3E");-webkit-mask:var(--tl-icon) no-repeat;mask:var(--tl-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;display:inline-block;vertical-align:middle;width:1.2em;height:1.2em}.i-iconoir-dashboard-speed{--tl-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' display='inline-block' vertical-align='middle' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cg fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5'%3E%3Cpath d='M12 4v4M4 8l2.5 2.5m11 0L20 8M3 17h3m6 0l1-6m5 6h3M8.5 20.001H4A9.956 9.956 0 0 1 2 14C2 8.477 6.477 4 12 4s10 4.477 10 10c0 2.252-.744 4.33-2 6.001L15.5 20'/%3E%3Cpath d='M12 23a3 3 0 1 0 0-6a3 3 0 0 0 0 6Z'/%3E%3C/g%3E%3C/svg%3E");-webkit-mask:var(--tl-icon) no-repeat;mask:var(--tl-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;display:inline-block;vertical-align:middle;width:1.2em;height:1.2em}.i-iconoir-linear{--tl-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' display='inline-block' vertical-align='middle' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M3 20L21 4'/%3E%3C/svg%3E");-webkit-mask:var(--tl-icon) no-repeat;mask:var(--tl-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;display:inline-block;vertical-align:middle;width:1.2em;height:1.2em}.i-iconoir-one-point-circle{--tl-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' display='inline-block' vertical-align='middle' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cg fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5'%3E%3Cpath d='M12 22c5.523 0 10-4.477 10-10S17.523 2 12 2S2 6.477 2 12s4.477 10 10 10Z'/%3E%3Cpath fill='currentColor' d='M12 13a1 1 0 1 0 0-2a1 1 0 0 0 0 2Z'/%3E%3Cpath d='m19 19l-1.5-1.5m-2-2l-1-1'/%3E%3C/g%3E%3C/svg%3E");-webkit-mask:var(--tl-icon) no-repeat;mask:var(--tl-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;display:inline-block;vertical-align:middle;width:1.2em;height:1.2em}.i-iconoir-select-face-3d{--tl-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' display='inline-block' vertical-align='middle' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cg fill='none' stroke='currentColor' stroke-linejoin='round' stroke-width='1.5'%3E%3Cpath stroke-linecap='round' d='M21 7.353v9.294a.6.6 0 0 1-.309.525l-8.4 4.666a.6.6 0 0 1-.582 0l-8.4-4.666A.6.6 0 0 1 3 16.647V7.353a.6.6 0 0 1 .309-.524l8.4-4.667a.6.6 0 0 1 .582 0l8.4 4.667a.6.6 0 0 1 .309.524Z'/%3E%3Cpath stroke-linecap='round' d='m3.528 7.294l8.18 4.544a.6.6 0 0 0 .583 0l8.209-4.56M12 21v-9'/%3E%3Cpath fill='currentColor' d='m11.691 11.829l-7.8-4.334A.6.6 0 0 0 3 8.02v8.627a.6.6 0 0 0 .309.525l7.8 4.333A.6.6 0 0 0 12 20.98v-8.627a.6.6 0 0 0-.309-.524Z'/%3E%3C/g%3E%3C/svg%3E");-webkit-mask:var(--tl-icon) no-repeat;mask:var(--tl-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;display:inline-block;vertical-align:middle;width:1.2em;height:1.2em}.i-iconoir-triangle{--tl-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' display='inline-block' vertical-align='middle' width='1.2em' height='1.2em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M11.475 2.947a.6.6 0 0 1 1.05 0l9.373 16.912a.6.6 0 0 1-.524.891H2.626a.6.6 0 0 1-.525-.89l9.374-16.913Z'/%3E%3C/svg%3E");-webkit-mask:var(--tl-icon) no-repeat;mask:var(--tl-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;display:inline-block;vertical-align:middle;width:1.2em;height:1.2em}.tl-absolute{position:absolute}.tl-relative{position:relative}.-tl-top-2{top:-.5rem}.tl-bottom-0\.5{bottom:.125rem}.tl-left-2{left:.5rem}.tl-right-0\.5{right:.125rem}.tl-z-24{z-index:24}.tl-grid{display:grid}.tl-grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.tl-my-4{margin-top:1rem;margin-bottom:1rem}.-tl-mt-0\.5{margin-top:-.125rem}.tl-mb-2{margin-bottom:.5rem}.tl-mb-4{margin-bottom:1rem}.tl-ml-2{margin-left:.5rem}.tl-mr-1{margin-right:.25rem}.tl-mr-2{margin-right:.5rem}.tl-box-border{box-sizing:border-box}.tl-block{display:block}.tl-hidden{display:none}.tl-h-0\.75{height:.1875rem}.tl-h-30px{height:30px}.tl-h-4{height:1rem}.tl-min-h-32px{min-height:32px}.tl-w-1\/2{width:50%}.tl-w-1\/3{width:33.3333333333%}.tl-w-1\/4{width:25%}.tl-w-2\/3{width:66.6666666667%}.tl-w-2\/5{width:40%}.tl-w-280px{width:280px}.tl-w-3{width:.75rem}.tl-w-30px{width:30px}.tl-w-4{width:1rem}.tl-w-full{width:100%}.tl-flex{display:flex}.tl-inline-flex{display:inline-flex}.tl-flex-col{flex-direction:column}.tl-rotate-90{--tl-rotate-x:0;--tl-rotate-y:0;--tl-rotate-z:0;--tl-rotate:90deg;transform:translate(var(--tl-translate-x)) translateY(var(--tl-translate-y)) translateZ(var(--tl-translate-z)) rotate(var(--tl-rotate)) rotateX(var(--tl-rotate-x)) rotateY(var(--tl-rotate-y)) rotate(var(--tl-rotate-z)) skew(var(--tl-skew-x)) skewY(var(--tl-skew-y)) scaleX(var(--tl-scale-x)) scaleY(var(--tl-scale-y)) scaleZ(var(--tl-scale-z))}.tl-transform{transform:translate(var(--tl-translate-x)) translateY(var(--tl-translate-y)) translateZ(var(--tl-translate-z)) rotate(var(--tl-rotate)) rotateX(var(--tl-rotate-x)) rotateY(var(--tl-rotate-y)) rotate(var(--tl-rotate-z)) skew(var(--tl-skew-x)) skewY(var(--tl-skew-y)) scaleX(var(--tl-scale-x)) scaleY(var(--tl-scale-y)) scaleZ(var(--tl-scale-z))}@keyframes fade-in{0%{opacity:0}to{opacity:1}}@keyframes fade-out{0%{opacity:1}to{opacity:0}}.tl-animate-fade-in{animation:fade-in 1s linear 1}.tl-animate-fade-out{animation:fade-out 1s linear 1}.tl-animate-duration-200{animation-duration:.2s}.tl-animate-ease-in-out{animation-timing-function:cubic-bezier(.4,0,.2,1)}.tl-cursor-pointer{cursor:pointer}.tl-cursor-grabbing{cursor:grabbing}.tl-cursor-ew-resize{cursor:ew-resize}.tl-select-none{-webkit-user-select:none;user-select:none}.tl-list-none{list-style-type:none}.tl-appearance-none{-webkit-appearance:none;-moz-appearance:none;appearance:none}.tl-items-center{align-items:center}.tl-justify-start{justify-content:flex-start}.tl-justify-center{justify-content:center}.tl-justify-between{justify-content:space-between}.tl-gap-0\.5{gap:.125rem}.tl-gap-1{gap:.25rem}.tl-gap-2{gap:.5rem}.tl-gap-4{gap:1rem}.tl-truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.tl-border{border-width:1px}.tl-border-2{border-width:2px}.tl-border-4{border-width:4px}.tl-border-l-2{border-left-width:2px}.tl-border-black{--tl-border-opacity:1;border-color:rgb(0 0 0 / var(--tl-border-opacity))}.tl-border-gray-300{--tl-border-opacity:1;border-color:rgb(209 213 219 / var(--tl-border-opacity))}.tl-border-transparent{border-color:transparent}.focus\:tl-border-gray-200:focus{--tl-border-opacity:1;border-color:rgb(229 231 235 / var(--tl-border-opacity))}.tl-border-l-gray-200{--tl-border-opacity:1;--tl-border-left-opacity:var(--tl-border-opacity);border-left-color:rgb(229 231 235 / var(--tl-border-left-opacity))}.tl-rounded{border-radius:.25rem}.tl-rounded-full{border-radius:9999px}.tl-rounded-md{border-radius:.375rem}.tl-rounded-sm{border-radius:.125rem}.tl-rounded-b{border-bottom-left-radius:.25rem;border-bottom-right-radius:.25rem}.tl-border-none{border-style:none}.tl-border-solid{border-style:solid}.tl-bg-dark-200{--tl-bg-opacity:1;background-color:rgb(50 50 50 / var(--tl-bg-opacity))}.tl-bg-dark-500{--tl-bg-opacity:1;background-color:rgb(31 31 31 / var(--tl-bg-opacity))}.tl-bg-dark-600{--tl-bg-opacity:1;background-color:rgb(28 28 30 / var(--tl-bg-opacity))}.tl-bg-dark-700{--tl-bg-opacity:1;background-color:rgb(27 27 27 / var(--tl-bg-opacity))}.tl-bg-gray-100{--tl-bg-opacity:1;background-color:rgb(243 244 246 / var(--tl-bg-opacity))}.tl-bg-gray-200{--tl-bg-opacity:1;background-color:rgb(229 231 235 / var(--tl-bg-opacity))}.tl-bg-transparent{background-color:transparent}.tl-bg-white{--tl-bg-opacity:1;background-color:rgb(255 255 255 / var(--tl-bg-opacity))}.tl-p-0{padding:0}.tl-p-1{padding:.25rem}.tl-p-1\.5{padding:.375rem}.tl-p-2{padding:.5rem}.tl-p-4{padding:1rem}.tl-px-0{padding-left:0;padding-right:0}.tl-px-1{padding-left:.25rem;padding-right:.25rem}.tl-px-2{padding-left:.5rem;padding-right:.5rem}.tl-px-2\.5{padding-left:.625rem;padding-right:.625rem}.tl-px-3{padding-left:.75rem;padding-right:.75rem}.tl-px-4{padding-left:1rem;padding-right:1rem}.tl-py-1{padding-top:.25rem;padding-bottom:.25rem}.tl-py-2{padding-top:.5rem;padding-bottom:.5rem}.tl-py-6{padding-top:1.5rem;padding-bottom:1.5rem}.tl-pl,.tl-pl-4{padding-left:1rem}.tl-pl-0{padding-left:0}.tl-pt-4{padding-top:1rem}.tl-text-left{text-align:left}.tl-text-right{text-align:right}.tl-text-0\.65rem{font-size:.65rem}.tl-text-base{font-size:1rem;line-height:1.5rem}.tl-text-sm{font-size:.875rem;line-height:1.25rem}.tl-text-xs{font-size:.75rem;line-height:1rem}.tl-font-bold{font-weight:700}.tl-line-height-0{line-height:0}.tl-font-sans{font-family:Roboto Mono,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji"}.tl-text-gray-200{--tl-text-opacity:1;color:rgb(229 231 235 / var(--tl-text-opacity))}.tl-text-gray-300{--tl-text-opacity:1;color:rgb(209 213 219 / var(--tl-text-opacity))}.tl-text-gray-400{--tl-text-opacity:1;color:rgb(156 163 175 / var(--tl-text-opacity))}.tl-text-gray-500{--tl-text-opacity:1;color:rgb(107 114 128 / var(--tl-text-opacity))}.tl-text-gray-600{--tl-text-opacity:1;color:rgb(75 85 99 / var(--tl-text-opacity))}.tl-text-gray-700{--tl-text-opacity:1;color:rgb(55 65 81 / var(--tl-text-opacity))}.tl-text-light{--tl-text-opacity:1;color:rgb(246 246 246 / var(--tl-text-opacity))}.tl-text-light-100{--tl-text-opacity:1;color:rgb(252 252 252 / var(--tl-text-opacity))}.tl-shadow-lg{--tl-shadow:var(--tl-shadow-inset) 0 10px 15px -3px var(--tl-shadow-color, rgb(0 0 0 / .1)),var(--tl-shadow-inset) 0 4px 6px -4px var(--tl-shadow-color, rgb(0 0 0 / .1));box-shadow:var(--tl-ring-offset-shadow),var(--tl-ring-shadow),var(--tl-shadow)}.tl-shadow-xl{--tl-shadow:var(--tl-shadow-inset) 0 20px 25px -5px var(--tl-shadow-color, rgb(0 0 0 / .1)),var(--tl-shadow-inset) 0 8px 10px -6px var(--tl-shadow-color, rgb(0 0 0 / .1));box-shadow:var(--tl-ring-offset-shadow),var(--tl-ring-shadow),var(--tl-shadow)}.important-tl-outline-gray-200{--tl-outline-color-opacity:1 !important;outline-color:rgb(229 231 235 / var(--tl-outline-color-opacity))!important}.tl-outline-none{outline:2px solid transparent;outline-offset:2px}.focus\:tl-outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus\:tl-ring-2:focus{--tl-ring-width:2px;--tl-ring-offset-shadow:var(--tl-ring-inset) 0 0 0 var(--tl-ring-offset-width) var(--tl-ring-offset-color);--tl-ring-shadow:var(--tl-ring-inset) 0 0 0 calc(var(--tl-ring-width) + var(--tl-ring-offset-width)) var(--tl-ring-color);box-shadow:var(--tl-ring-offset-shadow),var(--tl-ring-shadow),var(--tl-shadow)}.focus\:tl-ring-blue-600:focus{--tl-ring-opacity:1;--tl-ring-color:rgb(37 99 235 / var(--tl-ring-opacity))}.tl-transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.tl-transition-colors{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.tl-transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.tl-duration-200{transition-duration:.2s}input[type=range][data-v-e775088a]{outline:none;appearance:none;-webkit-appearance:none;-moz-appearance:none}input[type=range][data-v-e775088a]::-webkit-slider-thumb{height:1rem;width:.75rem;cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-width:2px;border-radius:.125rem;--tl-bg-opacity:1;background-color:rgb(50 50 50 / var(--tl-bg-opacity));--tl-shadow:var(--tl-shadow-inset) 0 10px 15px -3px var(--tl-shadow-color, rgb(0 0 0 / .1)),var(--tl-shadow-inset) 0 4px 6px -4px var(--tl-shadow-color, rgb(0 0 0 / .1));box-shadow:var(--tl-ring-offset-shadow),var(--tl-ring-shadow),var(--tl-shadow)}input[type=range][data-v-e775088a]::-moz-range-thumb{height:1rem;width:.75rem;cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-width:2px;border-radius:.125rem;--tl-bg-opacity:1;background-color:rgb(50 50 50 / var(--tl-bg-opacity));--tl-shadow:var(--tl-shadow-inset) 0 10px 15px -3px var(--tl-shadow-color, rgb(0 0 0 / .1)),var(--tl-shadow-inset) 0 4px 6px -4px var(--tl-shadow-color, rgb(0 0 0 / .1));box-shadow:var(--tl-ring-offset-shadow),var(--tl-ring-shadow),var(--tl-shadow)}input[type=color]{box-sizing:border-box;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-radius:.125rem;border-style:none;background-color:transparent;padding:0;outline:2px solid transparent;outline-offset:2px;cursor:pointer}input[type=color]::-webkit-color-swatch-wrapper{border-style:none;padding:0}input[type=color]::-webkit-color-swatch{margin-top:-.125rem;height:30px;width:30px;border-radius:.125rem;border-style:none;padding:0}.leches-btn[data-v-6a95ac59]{display:flex;cursor:pointer;align-items:center;border-radius:.375rem;border-style:none;font-weight:700;transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s;transition-duration:.2s}.leches-btn-sm[data-v-6a95ac59]{padding:.5rem .625rem;font-size:.75rem;line-height:1rem}.leches-btn-md[data-v-6a95ac59]{padding:.5rem .75rem;font-size:.875rem;line-height:1.25rem}.leches-btn-lg[data-v-6a95ac59]{padding:.5rem 1rem;font-size:1rem;line-height:1.5rem}.leches-btn-block[data-v-6a95ac59]{width:100%;justify-content:center;padding:.5rem 1rem;font-size:1rem;line-height:1.5rem}.leches-btn-primary[data-v-6a95ac59]{--tl-bg-opacity:1;background-color:rgb(243 244 246 / var(--tl-bg-opacity));--tl-text-opacity:1;color:rgb(55 65 81 / var(--tl-text-opacity))}.leches-btn-primary[data-v-6a95ac59]:hover{--tl-bg-opacity:1;background-color:rgb(229 231 235 / var(--tl-bg-opacity))}.leches-btn-secondary[data-v-6a95ac59]{--tl-bg-opacity:1;background-color:rgb(27 27 27 / var(--tl-bg-opacity));--tl-text-opacity:1;color:rgb(252 252 252 / var(--tl-text-opacity))}.leches-btn-secondary[data-v-6a95ac59]:hover{--tl-bg-opacity:1;background-color:rgb(28 28 30 / var(--tl-bg-opacity))}
@@ -1,8 +0,0 @@
1
- /**
2
- * name: @tresjs/leches
3
- * version: v0.15.0-next.3
4
- * (c) 2023
5
- * description: Tasty GUI for Vue controls 🍰
6
- * author: Alvaro Saburido <hola@alvarosaburido.dev> (https://github.com/alvarosabu/)
7
- */
8
- (function(B,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue"),require("@vueuse/core"),require("@tresjs/core")):typeof define=="function"&&define.amd?define(["exports","vue","@vueuse/core","@tresjs/core"],e):(B=typeof globalThis<"u"?globalThis:B||self,e(B.tresleches={},B.Vue,B.VueUseCore,B.TresjsCore))})(this,function(B,e,k,Z){"use strict";function $(l){return typeof l=="function"?l():e.unref(l)}const q=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;function v(l,r={}){if(!e.isRef(l))return e.toRefs(l);const o=Array.isArray(l.value)?Array.from({length:l.value.length}):{};for(const n in l.value)o[n]=e.customRef(()=>({get(){return l.value[n]},set(t){var i;if((i=$(r.replaceRef))!=null?i:!0)if(Array.isArray(l.value)){const c=[...l.value];c[n]=t,l.value=c}else{const c={...l.value,[n]:t};Object.setPrototypeOf(c,Object.getPrototypeOf(l.value)),l.value=c}else l.value[n]=t}}));return o}const ee=q?window:void 0;function te(l,r={}){const{pointerTypes:o,preventDefault:n,stopPropagation:t,exact:i,onMove:s,onEnd:c,onStart:m,initialValue:g,axis:u="both",draggingElement:d=ee,handle:a=l}=r,{width:p}=k.useWindowSize();let E=p.value;const f=e.ref($(g)??{x:0,y:0});e.watch(p,()=>{const b=p.value-E;f.value.x+=b,E=p.value});const w=e.ref(),N=b=>o?o.includes(b.pointerType):!0,x=b=>{$(n)&&b.preventDefault(),$(t)&&b.stopPropagation()},C=b=>{if(!N(b)||$(i)&&b.target!==$(l))return;const h=$(l).getBoundingClientRect(),_={x:b.clientX-h.left,y:b.clientY-h.top};(m==null?void 0:m(_,b))!==!1&&(w.value=_,x(b))},M=b=>{if(!N(b)||!w.value)return;let{x:h,y:_}=f.value;(u==="x"||u==="both")&&(h=b.clientX-w.value.x),(u==="y"||u==="both")&&(_=b.clientY-w.value.y),f.value={x:h,y:_},s==null||s(f.value,b),x(b)},F=b=>{N(b)&&w.value&&(w.value=void 0,c==null||c(f.value,b),x(b))};if(q){const b={capture:r.capture??!0};k.useEventListener(a,"pointerdown",C,b),k.useEventListener(d,"pointermove",M,b),k.useEventListener(d,"pointerup",F,b)}return{...v(f),position:f,isDragging:e.computed(()=>!!w.value),style:e.computed(()=>`left:${f.value.x}px;top:${f.value.y}px;`)}}const le=e.defineComponent({name:"UseDraggable",props:["storageKey","storageType","initialValue","exact","preventDefault","stopPropagation","pointerTypes","as","handle","axis","onStart","onMove","onEnd"],setup(l,{slots:r}){const o=e.ref(),n=e.computed(()=>l.handle??o.value),t=l.storageKey&&k.useStorage(l.storageKey,$(l.initialValue)||{x:0,y:0},k.isClient?l.storageType==="session"?sessionStorage:localStorage:void 0),i=t||l.initialValue||{x:0,y:0},s=(m,g)=>{var u;(u=l.onEnd)==null||u.call(l,m,g),t&&(t.value.x=m.x,t.value.y=m.y)},c=e.reactive(te(o,{...l,handle:n,initialValue:i,onEnd:s}));return()=>{if(r.default)return e.h(l.as||"div",{ref:o,style:`touch-action:none;${c.style}`},r.default(c))}}}),oe=Symbol("CONTROLS_CONTEXT_KEY"),j="default",T=e.reactive({});function X(l=j){return e.provide(oe,T),T[l]}const I=l=>{const r=/^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$|^0x([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/;return typeof l=="boolean"?"boolean":typeof l=="number"?"number":typeof l=="string"&&r.test(l)?"color":typeof l=="string"?"string":l.isVector3||l.isVector2||l.isEuler||l.value instanceof Array||l.value.isVector3||l.value.isVector2||l.value.isEuler||l.value.value instanceof Array?"vector":l.min!==void 0||l.max!==void 0||l.step!==void 0?"range":l.options&&Array.isArray(l.options)?"select":"unknown"},z=(l,r,o,n)=>{const t={key:e.ref(l),label:e.ref(l),name:e.ref(l),type:e.ref(o),value:e.ref(r),visible:e.ref(!0),icon:e.ref(),uniqueKey:e.ref(l),[l]:e.ref(r)};return n&&(t.folder=e.ref(n)),t},ne=(l,r,o)=>{const n={},t=typeof l=="string"?l:null,i=t?r:l,s=t&&t!=="fpsgraph"?o:r,c=(s==null?void 0:s.uuid)||j;if(T[c]||(T[c]=e.reactive({})),l==="fpsgraph"){const d=z("fpsgraph",null,"fpsgraph",null);return T[c].fpsgraph=d,n.fpsgraph=d,e.toRefs(e.reactive(n))}const m=T[c],g=e.isReactive(i),u=g?e.toRefs(i):{};for(const d in i){let a=i[d],p=d;if(g&&u[d]&&(a=u[d]),t&&(p=`${t}${d.charAt(0).toUpperCase()+d.slice(1)}`),typeof a=="object"&&!e.isRef(a)&&!Array.isArray(a)&&a.value!==void 0){const f=a,w=e.isRef(f.value)?f.value:e.ref(f.value),N=f.type||I(f),x=z(d,w,N,t);N==="select"&&(x.options=e.ref(f.options.map(C=>typeof C=="object"&&C.text&&C.value?C:{text:C,value:C}))),N==="range"&&(x.min=e.ref(f.min||0),x.max=e.ref(f.max||1),x.step=e.ref(f.step||.1)),x.label.value=f.label||d,x.icon.value=f.icon,x.visible.value=f.visible!==void 0?f.visible:!0,x.uniqueKey.value=p,m[p]=x,n[p]=x;continue}if(e.isRef(a)){const f=z(d,a,a.value.type||I(a.value),t);m[p]=f,n[p]=f;continue}else if(typeof a=="object"&&!Array.isArray(a)){const f=e.toRefs(a);f[d]&&(a=f[d])}const E=z(d,a,a.type||I(a),t);m[p]=E,n[p]=E,E.uniqueKey.value=p}return Object.keys(n).length>1?e.toRefs(e.reactive(n)):Object.values(n)[0]};function re(l){if(typeof l=="number")return[l,l,l];if(A(l)){const{x:r,y:o,z:n}=l;return[r,o,n]}if(P(l)){const{x:r,y:o}=l;return[r,o]}return l}function P(l){return l&&typeof l.x=="number"&&typeof l.y=="number"}function A(l){return l&&typeof l.x=="number"&&typeof l.y=="number"&&typeof l.z=="number"}function ae(l){let r=0;return l.traverse(o=>{if(o.isMesh&&o.geometry){const n=o.geometry,t=n.attributes.position.count*3*Float32Array.BYTES_PER_ELEMENT,i=n.index?n.index.count*Uint32Array.BYTES_PER_ELEMENT:0,s=n.attributes.normal?n.attributes.normal.count*3*Float32Array.BYTES_PER_ELEMENT:0,c=n.attributes.uv?n.attributes.uv.count*2*Float32Array.BYTES_PER_ELEMENT:0,m=t+i+s+c;r+=m}}),r}function se(l){return(l/1024).toFixed(2)}const ce=Symbol("PERF_CONTEXT_KEY"),K="default",L=e.reactive({[K]:{perf:{fps:e.reactive({value:0,accumulator:[],lastLoggedTime:Date.now(),logInterval:1e3}),memory:e.reactive({currentMem:0,averageMem:0,maxMemory:0,allocatedMem:0,accumulator:[],lastLoggedTime:Date.now(),logInterval:1e3}),gl:void 0,scene:void 0}}});function R(l=K){return e.provide(ce,L),L[l].perf}function Y(l){const{renderer:r,scene:o}=Z.useTresContext(),n=(l==null?void 0:l.renderer)||r.value;if(!n)throw new Error("Renderer not found");const t=L[K].perf;t.gl=n,t.scene=o.value;const i=100,s=k.useFps({every:i}),{isSupported:c,memory:m}=k.useMemory({interval:i}),g=80;let u=performance.now();const d=({timestamp:E})=>{t.memory.allocatedMem=ae(e.unref(o)),E-u>=i&&(u=E,t.fps.accumulator.push(s.value),t.fps.accumulator.length>g&&t.fps.accumulator.shift(),t.fps.value=t.fps.accumulator.reduce((f,w)=>f+w,0)/t.fps.accumulator.length,c.value&&m.value&&(t.memory.accumulator.push(m.value.usedJSHeapSize/1024/1024),t.memory.accumulator.length>g&&t.memory.accumulator.shift(),t.memory.currentMem=t.memory.accumulator.reduce((f,w)=>f+w,0)/t.memory.accumulator.length))},{pause:a,resume:p}=k.useRafFn(d,{immediate:!0});return e.onUnmounted(()=>{a()}),{perf:t,fps:t.fps,memory:t.memory,gl:t.gl,pausePerfTracking:a,resumePerfTracking:p}}const ie=["for","title"],D=e.defineComponent({__name:"ControlLabel",props:{label:{},control:{}},setup(l){return(r,o)=>(e.openBlock(),e.createElementBlock("label",{for:r.control.uniqueKey,title:r.label,class:"tl-text-gray-500 tl-w-1/3 tl-truncate"},[r.control.icon?(e.openBlock(),e.createElementBlock("i",{key:0,class:e.normalizeClass(r.control.icon)},null,2)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(r.label),1)],64))],8,ie))}}),de={class:"tl-flex tl-px-4 tl-justify-between tl-gap-4 tl-items-center tl-mb-2"},pe=["id","value","min","max","step"],me=e.defineComponent({__name:"NumberControl",props:{label:{},control:{}},emits:["change"],setup(l,{emit:r}){const o=l,n=r;function t(d){const{target:a}=d;n("change",a.valueAsNumber)}const i=k.useMouse(),s=e.ref(0),c=e.ref(!1),m=d=>{s.value=d.clientX,c.value=!0},g=()=>{c.value=!1},u=d=>Math.floor(Math.abs(d)/10);return e.watch(i.x,d=>{if(c.value){const a=d-s.value,p=u(a);a>0?n("change",o.control.value+1+p):a<0&&n("change",o.control.value-1+p),o.control.min!==void 0&&o.control.value<o.control.min&&n("change",o.control.min),o.control.max!==void 0&&o.control.value>o.control.max&&n("change",o.control.max),s.value=d}}),(d,a)=>(e.openBlock(),e.createElementBlock("div",de,[e.createVNode(D,{label:d.label,control:d.control},null,8,["label","control"]),e.createElementVNode("input",{id:d.control.uniqueKey,value:d.control.value,class:e.normalizeClass(["tl-p-2 tl-w-1/3 tl-rounded tl-text-right tl-text-xs tl-text-gray-400 tl-bg-gray-100 tl-focus:border-gray-200 tl-outline-none tl-border-none tl-font-sans",{"tl-cursor-ew-resize":c.value}]),type:"number",min:d.control.min,max:d.control.max,step:d.control.step,onInput:t,onMousedown:m,onMouseup:g},null,42,pe)]))}}),fe={class:"tl-flex tl-px-4 tl-justify-between tl-gap-4 tl-items-center tl-mb-2 tl-min-h-32px"},ue=["id","value","aria-label"],ge=e.defineComponent({__name:"TextControl",props:{label:{},control:{}},emits:["change"],setup(l,{emit:r}){const o=r;function n(t){const{target:i}=t;o("change",i.value)}return(t,i)=>(e.openBlock(),e.createElementBlock("div",fe,[e.createVNode(D,{label:t.label,control:t.control},null,8,["label","control"]),e.createElementVNode("input",{id:t.control.uniqueKey,value:t.control.value,type:"text",tabindex:"0",class:"tl-p-2 tl-w-2/3 tl-rounded tl-text-right tl-text-xs tl-text-gray-400 tl-bg-gray-100 focus:tl-border-gray-200 tl-border-none tl-font-sans","aria-label":t.label,placeholder:"Enter value here...",onChange:n},null,40,ue)]))}}),he={class:"tl-flex tl-px-4 tl-justify-start tl-gap-2 tl-items-center tl-mb-2 tl-min-h-32px"},be={class:"tl-text-gray-500 tl-w-1/3"},ye=["id","checked"],_e=["for"],ke=["aria-checked"],Ee={class:"i-ic:baseline-check tl-text-light"},xe=e.defineComponent({__name:"BooleanControl",props:{label:{},control:{}},emits:["change"],setup(l,{emit:r}){const o=l,n=r;function t(s){const{target:c}=s;n("change",c.checked)}function i(s){(s.code==="Space"||s.code==="Enter")&&(s.preventDefault(),n("change",!o.control.value))}return(s,c)=>(e.openBlock(),e.createElementBlock("div",he,[e.createElementVNode("label",be,e.toDisplayString(s.label),1),e.createElementVNode("input",{id:s.control.uniqueKey,checked:s.control.value,class:"tl-hidden",type:"checkbox",onInput:t},null,40,ye),e.createElementVNode("label",{for:s.control.uniqueKey,class:"tl-inline-flex tl-items-center tl-cursor-pointer"},[e.createElementVNode("span",{tabindex:"0",role:"checkbox","aria-checked":s.control.value.toString(),class:e.normalizeClass([{"tl-bg-dark-500":s.control.value,"tl-bg-gray-200":!s.control.value},"tl-w-4 tl-h-4 tl-flex tl-justify-center tl-items-center tl-rounded tl-border tl-border-gray-300 tl-mr-2 tl-transition-colors tl-duration-200"]),onKeydown:i},[e.withDirectives(e.createElementVNode("i",Ee,null,512),[[e.vShow,s.control.value]])],42,ke)],8,_e)]))}}),we={class:"tl-px-4 tl-relative tl-flex tl-justify-between tl-gap-4 tl-items-center tl-mb-2"},Be=["value","min","max","step"],Ce=["value","min","max","step"],Ve=e.defineComponent({__name:"SliderControl",props:{label:{},control:{}},emits:["change"],setup(l,{emit:r}){const o=l,n=r;function t(a){const{target:p}=a;n("change",p.valueAsNumber)}const i=e.computed(()=>({backgroundImage:`linear-gradient(to right, #333 0% ${100*(o.control.value-(o.control.min||0))/((o.control.max||100)-(o.control.min||0))}%, #e2e2e2 0%)`})),s=k.useMouse(),c=e.ref(0),m=e.ref(!1),g=a=>{c.value=a.clientX,m.value=!0},u=()=>{m.value=!1},d=a=>Math.floor(Math.abs(a)/10);return e.watch(s.x,a=>{if(m.value){const p=a-c.value,E=d(p);p>0?n("change",o.control.value+1+E):p<0&&n("change",o.control.value-1+E),o.control.min!==void 0&&o.control.value<o.control.min&&n("change",o.control.min),o.control.max!==void 0&&o.control.value>o.control.max&&n("change",o.control.max),c.value=a}}),(a,p)=>(e.openBlock(),e.createElementBlock("div",we,[e.createVNode(D,{label:a.label,control:a.control},null,8,["label","control"]),e.createElementVNode("input",{value:a.control.value,class:"tl-w-1/2 tl-h-0.75 tl-bg-dark-200 tl-rounded-full tl-appearance-none",style:e.normalizeStyle(i.value),type:"range",min:a.control.min,max:a.control.max,step:a.control.step,onInput:t},null,44,Be),e.createElementVNode("input",{value:a.control.value,class:e.normalizeClass(["tl-p-2 tl-w-1/4 tl-rounded tl-text-right tl-text-xs tl-text-gray-400 tl-bg-gray-100 tl-focus:border-gray-200 tl-outline-none tl-border-none tl-font-sans",{"tl-cursor-ew-resize":m.value}]),type:"number",min:a.control.min,max:a.control.max,step:a.control.step,onInput:t,onMousedown:g,onMouseup:u},null,42,Ce)]))}}),W=(l,r)=>{const o=l.__vccOpts||l;for(const[n,t]of r)o[n]=t;return o},Ne=W(Ve,[["__scopeId","data-v-e775088a"]]),$e={class:"tl-flex tl-px-4 tl-justify-between tl-gap-4 tl-items-center tl-mb-2"},Me={class:"tl-text-gray-500 tl-w-1/3"},Se=["id","value","aria-label"],Te=["id","aria-label","value"],De=e.defineComponent({__name:"ColorControl",props:{label:{},control:{}},emits:["change"],setup(l,{emit:r}){const o=r;function n(t){const{target:i}=t;o("change",i.value)}return(t,i)=>(e.openBlock(),e.createElementBlock("div",$e,[e.createElementVNode("label",Me,e.toDisplayString(t.label),1),e.createElementVNode("input",{id:t.control.uniqueKey,tabindex:"0",value:t.control.value,"aria-label":t.label,class:e.normalizeClass(["focus:tl-outline-none focus:tl-ring-2 focus:tl-ring-blue-600",{"important-tl-outline-gray-200":t.control.value==="#ffffff"}]),type:"color",onInput:n},null,42,Se),e.createElementVNode("input",{id:t.control.uniqueKey,tabindex:"0","aria-label":t.label,value:t.control.value,class:"tl-p-2 tl-w-2/3 tl-rounded tl-text-right tl-text-xs tl-text-gray-400 tl-bg-gray-100 tl-border-none tl-font-sans",type:"text",onInput:n},null,40,Te)]))}}),Fe={class:"tl-relative tl-w-2/3 tl-flex tl-justify-between tl-gap-0.5"},ze={key:0,class:"tl-font-bold tl-px-1 tl-py-1 tl-text-0.65rem tl-text-gray-300"},Ie=["id","step","value","onInput","onMousedown","onMouseup","onFocus"],Pe=e.defineComponent({__name:"VectorControl",props:{label:{},control:{}},emits:["change"],setup(l,{emit:r}){const o=l,n=r,t=k.useMouse(),{pressed:i}=k.useMousePressed(),s=e.ref(0),c=e.ref(!1),m=e.ref(0),g=e.ref(null),u=e.ref(1),d=k.useKeyModifier("Shift"),a=k.useKeyModifier("Alt");e.watch(d,h=>{u.value=h?10:1}),e.watch(a,h=>{u.value=h?.1:1});const p=h=>{g.value=h},E=()=>{g.value=null},f=(h,_)=>{m.value=_,s.value=h.clientX,c.value=!0},w=(h,_)=>{m.value=_,c.value=!1},N=()=>{c.value=!1};e.watch(i,h=>{h||(c.value=!1)});const x=h=>Math.floor(Math.abs(h)/10),C=e.computed(()=>re(o.control.value)),M=e.ref(["x","y","z"]),F=e.computed(()=>P(o.control.value)||A(o.control.value));function b(h,_){const{value:S}=o.control,{target:y}=h;m.value=_,S[F.value?M.value[m.value]:m.value]=parseFloat(y.value),n("change",S)}return e.watch(t.x,h=>{if(c.value){const _=h-s.value,S=x(_),{value:y}=o.control,V=F.value?M.value[m.value]:m.value;_>0?y[V]+=u.value+S:_<0&&(y[V]-=u.value+S),o.control.min!==void 0&&y<o.control.min&&(y[V]=o.control.min),o.control.max!==void 0&&y>o.control.max&&(y[V]=o.control.max),n("change",y),s.value=h}}),(h,_)=>(e.openBlock(),e.createElementBlock("div",{class:"tl-flex tl-px-4 tl-justify-between tl-gap-1 tl-items-center tl-mb-2",onMouseup:_[0]||(_[0]=S=>N())},[e.createVNode(D,{label:h.label,control:h.control},null,8,["label","control"]),e.createElementVNode("div",Fe,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(C.value,(S,y)=>(e.openBlock(),e.createElementBlock("div",{key:h.label+y,class:e.normalizeClass(["tl-flex tl-items-center tl-bg-gray-100 tl-rounded",{"tl-w-2/5":g.value===y,"tl-w-1/3":e.unref(A)(h.control.value),"tl-w-1/2":e.unref(P)(h.control.value)}])},[M.value[y]&&F.value?(e.openBlock(),e.createElementBlock("span",ze,e.toDisplayString(M.value[y]),1)):e.createCommentVNode("",!0),e.createElementVNode("input",{id:`${h.control.uniqueKey}-${M.value[y]}`,type:"number",step:u.value,class:e.normalizeClass(["tl-w-full tl-px-0 tl-p-1 tl-text-right tl-text-0.65rem tl-text-gray-400 tl-bg-transparent focus:tl-border-gray-200 tl-outline-none tl-border-none tl-font-sans tl-appearence-none",{"tl-cursor-ew-resize":c.value}]),value:C.value[y].toFixed(2),onInput:V=>b(V,y),onMousedown:V=>f(V,y),onMouseup:V=>w(V,y),onFocus:V=>p(y),onBlur:E},null,42,Ie)],2))),128))])],32))}}),Ae={class:"tl-flex tl-px-4 tl-justify-between tl-gap-4 tl-items-center tl-mb-2"},Ke={class:"tl-text-gray-500 tl-w-1/3"},Le={class:"tl-relative tl-w-2/3 tl-p-1 tl-rounded tl-text-right tl-text-xs tl-text-gray-400 tl-bg-gray-100 tl-focus:border-gray-200 tl-outline-none tl-border-none tl-font-sans"},Re={class:"tl-absolute tl-bottom-0.5 tl-right-0.5 tl-font-sans tl-text-xs"},Ue=["points"],Oe=160,U=40,G=2,H=e.defineComponent({__name:"Graph",props:{points:{},value:{},unit:{},label:{}},setup(l){const r=l,o=e.ref(140);e.watchEffect(()=>{const t=Math.max(...r.points,30);o.value=Math.max(t,o.value)});const n=e.computed(()=>r.points.map((t,i)=>`${i*G},${U-t*U/o.value}`).join(" "));return(t,i)=>(e.openBlock(),e.createElementBlock("div",Ae,[e.createElementVNode("label",Ke,e.toDisplayString(t.label),1),e.createElementVNode("div",Le,[e.createElementVNode("div",Re,e.toDisplayString(Math.round(t.value))+" "+e.toDisplayString(t.unit),1),(e.openBlock(),e.createElementBlock("svg",{width:Oe,height:U,xmlns:"http://www.w3.org/2000/svg",class:"tl-bg-gray-100"},[e.createElementVNode("polyline",{points:n.value,fill:"none",stroke:"lightgray","stroke-width":G,"stroke-linecap":"round","stroke-linejoin":"round"},null,8,Ue)]))])]))}}),qe=e.defineComponent({__name:"FPSGraph",props:{label:{},control:{}},setup(l){const{fps:r}=R();return(o,n)=>(e.openBlock(),e.createBlock(H,{points:e.unref(r).accumulator,value:e.unref(r).value,unit:"FPS",label:o.label},null,8,["points","value","label"]))}}),je={class:"tl-flex tl-px-4 tl-justify-between tl-gap-4 tl-items-center tl-mb-2 tl-min-h-32px"},Xe=["id","value"],Ye=["value"],We=e.defineComponent({__name:"SelectControl",props:{label:{},control:{}},emits:["change"],setup(l,{emit:r}){const o=r;function n(t){o("change",t.target.value)}return(t,i)=>(e.openBlock(),e.createElementBlock("div",je,[e.createVNode(D,{label:t.label,control:t.control},null,8,["label","control"]),e.createElementVNode("select",{id:t.control.uniqueKey,value:t.control.value,class:"tl-p-2 tl-w-2/3 tl-rounded tl-text-left tl-text-xs tl-text-gray-400 tl-bg-gray-100 focus:tl-border-gray-200 tl-outline-none tl-border-none tl-font-sans",onChange:n},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.control.options,s=>(e.openBlock(),e.createElementBlock("option",{key:s.value,value:s.value},e.toDisplayString(s.text),9,Ye))),128))],40,Xe)]))}}),Ge=W(e.defineComponent({__name:"ButtonControl",props:{label:{},control:{}},setup(l){const r=l,o=e.computed(()=>{const n="leches-btn",t=`leches-btn-${r.control.value.variant||"primary"}`,i=`leches-btn-${r.control.value.size||"sm"}`;return[n,t,i]});return(n,t)=>(e.openBlock(),e.createElementBlock("button",{class:e.normalizeClass(o.value),onClick:t[0]||(t[0]=(...i)=>n.control.value.onClick&&n.control.value.onClick(...i))},[e.createElementVNode("i",{class:e.normalizeClass([n.control.value.icon,n.control.value.label?"mr-1":""])},null,2),e.createTextVNode(" "+e.toDisplayString(n.control.value.label),1)],2))}}),[["__scopeId","data-v-6a95ac59"]]),J=e.defineComponent({__name:"ControlInput",props:{control:{}},emits:["change"],setup(l,{emit:r}){const o=r;function n(t){o("change",t)}return(t,i)=>t.control.visible?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[t.control.type==="color"?(e.openBlock(),e.createBlock(De,{key:0,label:t.control.label,control:t.control,onChange:n},null,8,["label","control"])):t.control.type==="select"?(e.openBlock(),e.createBlock(We,{key:1,label:t.control.label,control:t.control,onChange:n},null,8,["label","control"])):t.control.type==="vector"?(e.openBlock(),e.createBlock(Pe,{key:2,label:t.control.label,control:t.control,onChange:n},null,8,["label","control"])):t.control.type==="boolean"?(e.openBlock(),e.createBlock(xe,{key:3,label:t.control.label,control:t.control,onChange:n},null,8,["label","control"])):t.control.type==="fpsgraph"?(e.openBlock(),e.createBlock(qe,{key:4,label:t.control.label,control:t.control},null,8,["label","control"])):t.control.type==="number"?(e.openBlock(),e.createBlock(me,{key:5,label:t.control.label,control:t.control,onChange:n},null,8,["label","control"])):t.control.type==="range"?(e.openBlock(),e.createBlock(Ne,{key:6,label:t.control.label,control:t.control,onChange:n},null,8,["label","control"])):t.control.type==="button"?(e.openBlock(),e.createElementBlock("div",{key:7,class:e.normalizeClass(["tl-p-2",t.control.value.size==="tl-block"?"tl-flex":"tl-inline-flex"])},[e.createVNode(Ge,{label:t.control.label,control:t.control},null,8,["label","control"])],2)):(e.openBlock(),e.createBlock(ge,{key:8,label:t.control.label,control:t.control,onChange:n},null,8,["label","control"]))],64)):e.createCommentVNode("",!0)}}),He={class:"tl-mb-4"},Je=["aria-expanded","data-folder"],Qe={class:"tl-bg-white tl-rounded-b tl-pt-4",role:"menu"},Ze=e.defineComponent({__name:"Folder",props:{controls:{},label:{}},setup(l){function r(t,i){i.value=t}const o=e.ref(!1),n=()=>{o.value=!o.value};return(t,i)=>(e.openBlock(),e.createElementBlock("div",He,[e.createElementVNode("button",{class:"tl-flex tl-items-center tl-justify-between tl-w-full tl-py-2 tl-px-4 tl-bg-gray-100 tl-border-none tl-text-gray-400 tl-font-bold tl-text-xs tl-font-sans tl-cursor-pointer","aria-expanded":o.value,"aria-haspopup":"true",role:"button","data-folder":t.label,tabindex:"0",onClick:n},[e.createElementVNode("span",null,e.toDisplayString(t.label),1),e.createElementVNode("i",{class:e.normalizeClass(o.value?"i-ic:baseline-keyboard-arrow-up":"i-ic:baseline-keyboard-arrow-down")},null,2)],8,Je),e.createVNode(e.Transition,{name:"slide","enter-active-class":"tl-animate-fade-in tl-animate-duration-200 tl-animate-ease-in-out","leave-active-class":"tl-animate-fade-out tl-animate-duration-200 tl-animate-ease-in-out"},{default:e.withCtx(()=>[e.withDirectives(e.createElementVNode("div",Qe,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.controls,s=>(e.openBlock(),e.createBlock(J,{key:s.label,control:s,role:"menuitem",onChange:c=>r(c,s)},null,8,["control","onChange"]))),128))],512),[[e.vShow,o.value]])]),_:1})]))}}),ve={class:"tl-relative tl-px-4 tl-py-6 tl-grid tl-grid-cols-2 tl-border tl-border-solid tl-border-gray-300 tl-rounded tl-my-4"},et={class:"tl-absolute tl-bg-white tl-text-gray-400 tl-px-2 tl-rounded -tl-top-2 tl-left-2"},O=e.defineComponent({__name:"Pane",props:{title:{}},setup(l){return(r,o)=>(e.openBlock(),e.createElementBlock("div",ve,[e.createElementVNode("span",et,e.toDisplayString(r.title),1),e.renderSlot(r.$slots,"default")]))}}),tt={class:""},lt=["onClick"],ot={class:"tl-cursor-pointer tl-flex tl-items-center"},nt={class:"tl-mr-2 tl-py-2"},rt=[e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M9 5l7 7-7 7"},null,-1)],at={class:"tl-border-l-2 tl-border-transparent tl-border-l-gray-200 tl-border-2 tl-border-solid tl-ml-2 tl-pl-4"},Q=e.defineComponent({__name:"Tree",props:{items:{},depth:{default:0}},setup(l){const r=l,o=e.computed(()=>{var t;return(t=r.items)==null?void 0:t.map(i=>e.reactive({...i,isOpen:!1}))});function n(t){t.isOpen=!t.isOpen}return(t,i)=>(e.openBlock(),e.createElementBlock("div",tt,[e.createElementVNode("ul",{class:e.normalizeClass(["tl-list-none",{"tl-pl-0":t.depth===0}]),"V-IF":""},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.value,(s,c)=>(e.openBlock(),e.createElementBlock("li",{key:c,onClick:m=>n(s)},[e.createElementVNode("div",ot,[e.createElementVNode("span",nt,[(e.openBlock(),e.createElementBlock("svg",{class:e.normalizeClass([s.isOpen?"tl-transform tl-rotate-90":"","tl-w-4 tl-h-4 tl-transition-transform tl-text-gray-300"]),xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor"},rt,2))]),e.createTextVNode(" "+e.toDisplayString(s.name),1)]),e.withDirectives(e.createElementVNode("div",at,[e.renderSlot(t.$slots,`depth-${t.depth}`,{item:s},()=>[e.createVNode(Q,{items:s.children,depth:t.depth+1},null,8,["items","depth"])])],512),[[e.vShow,s.isOpen]])],8,lt))),128))],2)]))}}),st={class:"tl-mb-4"},ct=["aria-expanded"],it=e.createElementVNode("span",null,[e.createElementVNode("i",{class:"i-iconoir-dashboard-speed"}),e.createTextVNode(" Performance ")],-1),dt={class:"tl-bg-white tl-rounded-b tl-pt-4",role:"menu"},pt={class:"tl-p-2"},mt={class:"tl-flex tl-items-center tl-mb-2"},ft={class:"tl-bg-gray-200 tl-text-gray-600 tl-rounded tl-p-1 tl-flex tl-w-4 tl-mr-1"},ut={class:"tl-ml-2 tl-font-bold tl-text"},gt={class:"tl-text-xs tl-text-gray-500"},ht={class:"tl-flex tl-items-center tl-mb-2"},bt={class:"tl-bg-gray-200 tl-text-gray-600 tl-rounded tl-p-1 tl-flex tl-w-4 tl-mr-1"},yt={class:"tl-ml-2 tl-font-bold tl-text"},_t={class:"tl-text-xs tl-text-gray-500"},kt={class:"tl-w-full tl-overflow tl-text-xxs"},Et=e.defineComponent({__name:"index",props:{uuid:{}},setup(l){const r=l,{uuid:o}=e.toRefs(r),{gl:n,memory:t}=R(o==null?void 0:o.value),i=[{label:"geometries",icon:"i-iconoir-box-3d-three-points"},{label:"textures",icon:"i-iconoir-select-face-3d"}],s=[{label:"calls",icon:"i-iconoir-comp-align-left"},{label:"triangles",icon:"i-iconoir-triangle"},{label:"points",icon:"i-iconoir-one-point-circle"},{label:"lines",icon:"i-iconoir-linear"}],c=e.reactive({geometries:0,textures:0,calls:0,triangles:0,points:0,lines:0,programs:[]});k.useRafFn(()=>{n&&(c.geometries=n.info.memory.geometries,c.textures=n.info.memory.textures,c.calls=n.info.render.calls,c.triangles=n.info.render.triangles,c.points=n.info.render.points,c.lines=n.info.render.lines,c.programs=n.info.programs)});const m=e.ref(!1),g=()=>{m.value=!m.value},u=e.computed(()=>c.programs.map(d=>({...d,name:d.type,uniforms:d.getUniforms()})));return(d,a)=>(e.openBlock(),e.createElementBlock("div",st,[e.createElementVNode("button",{class:"tl-flex tl-items-center tl-justify-between tl-w-full tl-py-2 tl-px-4 tl-bg-gray-100 tl-border-none tl-text-gray-400 tl-font-bold tl-text-xs tl-font-sans tl-cursor-pointer","aria-expanded":m.value,"aria-haspopup":"true",role:"button",tabindex:"0",onClick:g},[it,e.createElementVNode("i",{class:e.normalizeClass(m.value?"i-ic:baseline-keyboard-arrow-up":"i-ic:baseline-keyboard-arrow-down")},null,2)],8,ct),e.createVNode(e.Transition,{name:"slide","enter-active-class":"tl-animate-fade-in tl-animate-duration-200 tl-animate-ease-in-out","leave-active-class":"tl-animate-fade-out tl-animate-duration-200 tl-animate-ease-in-out"},{default:e.withCtx(()=>[e.withDirectives(e.createElementVNode("div",dt,[e.createElementVNode("div",pt,[e.createVNode(O,{title:`Memory ${e.unref(se)(e.unref(t).allocatedMem)}KB`},{default:e.withCtx(()=>[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(i,p=>e.createElementVNode("div",{key:p,class:"tl-flex tl-flex-col tl-items-center"},[e.createElementVNode("div",mt,[e.createElementVNode("span",ft,[e.createElementVNode("i",{class:e.normalizeClass(["tl-pl tl-text-sm",p.icon])},null,2)]),e.createElementVNode("span",ut,e.toDisplayString(c[p.label]),1)]),e.createElementVNode("span",gt,e.toDisplayString(p.label),1)])),64))]),_:1},8,["title"]),e.createVNode(H,{points:e.unref(t).accumulator,value:e.unref(t).currentMem,unit:"MB",label:"memory"},null,8,["points","value"]),e.createVNode(O,{title:"Render"},{default:e.withCtx(()=>[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(s,p=>e.createElementVNode("div",{key:p,class:"tl-flex tl-flex-col tl-items-center tl-mb-2"},[e.createElementVNode("div",ht,[e.createElementVNode("span",bt,[e.createElementVNode("i",{class:e.normalizeClass(["tl-pl tl-text-sm",p.icon])},null,2)]),e.createElementVNode("span",yt,e.toDisplayString(c[p.label]),1)]),e.createElementVNode("span",_t,e.toDisplayString(p.label),1)])),64))]),_:1}),e.createVNode(O,{title:"Programs"},{default:e.withCtx(()=>[e.createVNode(Q,{items:u.value},{"depth-0":e.withCtx(({item:p})=>[e.createElementVNode("pre",kt,e.toDisplayString(p),1)]),_:1},8,["items"])]),_:1})])],512),[[e.vShow,m.value]])]),_:1})]))}}),xt={tabindex:"0",class:"tl-bg-white tl-shadow-xl tl-rounded tl-border-4 tl-border-solid tl-border-black"},wt=[e.createElementVNode("i",{class:"tl-h-4 tl-w-4 tl-p-1.5 tl-flex tl-items-center tl-line-height-0 tl-rounded-full tl-bg-gray-100 tl-text-xs"},"🍰",-1),e.createElementVNode("div",null,[e.createElementVNode("i",{class:"i-ic-baseline-drag-indicator"}),e.createElementVNode("i",{class:"i-ic-baseline-drag-indicator"}),e.createElementVNode("i",{class:"i-ic-baseline-drag-indicator"})],-1),e.createElementVNode("div",null,null,-1)],Bt=280,Ct=e.defineComponent({__name:"TresLeches",props:{uuid:{}},setup(l){const r=l,{uuid:o}=e.toRefs(r),{width:n}=k.useWindowSize(),t=e.ref(null),i=X(o==null?void 0:o.value),s=R(o==null?void 0:o.value);function c(g,u){i[e.unref(g)].value=u,i[e.unref(g)][e.unref(g)]=u}const m=e.computed(()=>{const g={};for(const u in i){const d=i[u],a=d.folder||"default";g[a]||(g[a]=[]),g[a].push(d)}return g});return(g,u)=>(e.openBlock(),e.createBlock(e.unref(le),{id:e.unref(o),"initial-value":{x:e.unref(n)-Bt-40,y:10},class:e.normalizeClass(["tl-absolute tl-select-none tl-z-24 tl-w-280px tl-font-sans tl-text-xs",g.$attrs.class]),handle:t.value},{default:e.withCtx(()=>[e.createElementVNode("div",xt,[e.createElementVNode("header",{ref_key:"handle",ref:t,class:"tl-relative tl-cursor-grabbing tl-p-4 tl-flex tl-justify-between tl-text-gray-200 tl-relative"},wt,512),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,(d,a)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:a},[a!=="default"?(e.openBlock(),e.createBlock(Ze,{key:0,label:a,controls:d},null,8,["label","controls"])):e.createCommentVNode("",!0),a==="default"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(d,p=>(e.openBlock(),e.createBlock(J,{key:p.label,control:p,onChange:E=>c(p.key,E)},null,8,["control","onChange"]))),128)):e.createCommentVNode("",!0)],64))),128)),e.unref(s).gl?(e.openBlock(),e.createBlock(Et,{key:0,uuid:e.unref(o)},null,8,["uuid"])):e.createCommentVNode("",!0)])]),_:1},8,["id","initial-value","class","handle"]))}}),Vt=e.defineComponent({__name:"Perf",setup(l){return Y(),()=>{}}});B.Perf=Vt,B.TresLeches=Ct,B.useControls=ne,B.useControlsProvider=X,B.usePerf=Y,Object.defineProperty(B,Symbol.toStringTag,{value:"Module"})});
@@ -1,6 +0,0 @@
1
- import type { TresObject } from '@tresjs/core';
2
- import type { Scene } from 'three';
3
- export declare function calculateMemoryUsage(object: TresObject | Scene): number;
4
- export declare function bytesToKB(bytes: number): string;
5
- export declare function bytesToMB(bytes: number): string;
6
- export declare function bytesToGB(bytes: number): string;