From 32b725dd4d12e3a8bd06b47416b8ff72a1d97b83 Mon Sep 17 00:00:00 2001 From: Sean Boult <996134+Hacksore@users.noreply.github.com> Date: Sat, 21 Sep 2024 11:10:45 -0500 Subject: [PATCH] Use vite for preview envs and development (#170) --- .gitignore | 2 +- CONTRIBUTING.md | 11 + examples/font/minecraft.woff2 | 1 - examples/index.html | 813 ++++------- examples/main.ts | 273 ++++ examples/offscreen-render.html | 88 +- examples/offscreen-renderer.ts | 62 + examples/public/font/minecraft.woff2 | Bin 0 -> 2676 bytes .../{ => public}/img/1_8_texturemap_redux.png | Bin examples/{ => public}/img/deadmau5.png | Bin examples/{ => public}/img/ears.png | Bin examples/{ => public}/img/hacksore.png | Bin examples/{ => public}/img/haka.png | Bin examples/{ => public}/img/hatsune_miku.png | Bin examples/{ => public}/img/hd_cape.png | Bin examples/{ => public}/img/ironman_hd.png | Bin examples/{ => public}/img/legacy_cape.png | Bin examples/{ => public}/img/mojang_cape.png | Bin examples/{ => public}/img/panorama.png | Bin examples/{ => public}/img/sethbling.png | Bin examples/style.css | 97 ++ package-lock.json | 1195 ++++++++++++++++- package.json | 12 +- vite.config.ts | 14 + 24 files changed, 1900 insertions(+), 668 deletions(-) create mode 100644 CONTRIBUTING.md delete mode 120000 examples/font/minecraft.woff2 create mode 100644 examples/main.ts create mode 100644 examples/offscreen-renderer.ts create mode 100644 examples/public/font/minecraft.woff2 rename examples/{ => public}/img/1_8_texturemap_redux.png (100%) rename examples/{ => public}/img/deadmau5.png (100%) rename examples/{ => public}/img/ears.png (100%) rename examples/{ => public}/img/hacksore.png (100%) rename examples/{ => public}/img/haka.png (100%) rename examples/{ => public}/img/hatsune_miku.png (100%) rename examples/{ => public}/img/hd_cape.png (100%) rename examples/{ => public}/img/ironman_hd.png (100%) rename examples/{ => public}/img/legacy_cape.png (100%) rename examples/{ => public}/img/mojang_cape.png (100%) rename examples/{ => public}/img/panorama.png (100%) rename examples/{ => public}/img/sethbling.png (100%) create mode 100644 examples/style.css create mode 100644 vite.config.ts diff --git a/.gitignore b/.gitignore index 7d9eb70..d360994 100644 --- a/.gitignore +++ b/.gitignore @@ -62,6 +62,6 @@ libs/ _ignore/ .DS_Store .rpt2_cache -public/ docs/ +dist/ diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000..d475d7b --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,11 @@ +## Contributing + +Get the preview app running locally: + +1. `npm install` +2. `npm run dev` +3. open http://localhost:5173 + +## Offscreen Renderer + +1. open http://localhost:5173/offscreen-render.html diff --git a/examples/font/minecraft.woff2 b/examples/font/minecraft.woff2 deleted file mode 120000 index 2864683..0000000 --- a/examples/font/minecraft.woff2 +++ /dev/null @@ -1 +0,0 @@ -../../assets/minecraft.woff2 \ No newline at end of file diff --git a/examples/index.html b/examples/index.html index 5619843..fa5e3ce 100644 --- a/examples/index.html +++ b/examples/index.html @@ -1,595 +1,288 @@ - + - - - - - - skinview3d - - - - - - - -
- - - -
-

Viewport

-
- - + + + + skinview3d + + + + + +
+ + +
+

Viewport

+
+ + +
+
+ + +
-
- - + +
+

Light

+ +
-
-
-

Light

- - -
+
+

Rotation

+ + +
-
-

Rotation

- - -
+
+

Animation

+
+ + + + + +
+ + +
-
-

Animation

-
- - - - - +
+

Mouse Control

+
+ + + +
- - -
-
-

Mouse Control

-
- - - +
+

Skin Layers

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
headbodyright armleft armright legleft leg
inner
outer
+
+

Back Equipment

+
+ + +
+
-
-
-

Skin Layers

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
headbodyright armleft armright legleft leg
inner
outer
-
-

Back Equipment

-
- - +
+

Skin

+
+
+ + + + + + + + + + + + + +
+
+
+
-
-
-

Skin

-
+
+

Cape

- - -
-
- -
-
-
-

Cape

-
- - - - - - +
+

Ears

+
+ +
+
+ + + + + + + + + +
-
-
-

Ears

-
- -
-
- - - - - - +
+

Panorama

+
+ + + + + + + + +
-
-
-

Panorama

-
- - - - - - +
+

Name Tag

+
+ +
-
-
-

Name Tag

-
- +
+

Other examples

+
-
-

Other examples

- -
- -
- - - - - + + + - - - - - + requestAnimationFrame(loop); + + diff --git a/examples/main.ts b/examples/main.ts new file mode 100644 index 0000000..0d544ff --- /dev/null +++ b/examples/main.ts @@ -0,0 +1,273 @@ +import * as skinview3d from "../src/skinview3d"; +import "./style.css"; + +const skinParts = ["head", "body", "rightArm", "leftArm", "rightLeg", "leftLeg"]; +const skinLayers = ["innerLayer", "outerLayer"]; +const availableAnimations = { + idle: new skinview3d.IdleAnimation(), + walk: new skinview3d.WalkingAnimation(), + run: new skinview3d.RunningAnimation(), + fly: new skinview3d.FlyingAnimation(), +}; + +let skinViewer: skinview3d.SkinViewer; + +function obtainTextureUrl(id: string) { + const urlInput = document.getElementById(id); + const fileInput = document.getElementById(id + "_upload"); + const unsetButton = document.getElementById(id + "_unset"); + const file = fileInput.files[0]; + if (file === undefined) { + if (!unsetButton.classList.contains("hidden")) { + unsetButton.classList.add("hidden"); + } + return urlInput.value; + } else { + unsetButton.classList.remove("hidden"); + urlInput.value = `Local file: ${file.name}`; + urlInput.readOnly = true; + return URL.createObjectURL(file); + } +} + +function reloadSkin() { + const input = document.getElementById("skin_url"); + const url = obtainTextureUrl("skin_url"); + if (url === "") { + skinViewer.loadSkin(null); + input.setCustomValidity(""); + } else { + skinViewer + .loadSkin(url, { + model: document.getElementById("skin_model").value, + ears: document.getElementById("ears_source").value === "current_skin", + }) + .then(() => input.setCustomValidity("")) + .catch(e => { + input.setCustomValidity("Image can't be loaded."); + console.error(e); + }); + } +} + +function reloadCape() { + const input = document.getElementById("cape_url"); + const url = obtainTextureUrl("cape_url"); + if (url === "") { + skinViewer.loadCape(null); + input.setCustomValidity(""); + } else { + const selectedBackEquipment = document.querySelector('input[type="radio"][name="back_equipment"]:checked'); + skinViewer + .loadCape(url, { backEquipment: selectedBackEquipment.value }) + .then(() => input.setCustomValidity("")) + .catch(e => { + input.setCustomValidity("Image can't be loaded."); + console.error(e); + }); + } +} + +function reloadEars(skipSkinReload = false) { + const sourceType = document.getElementById("ears_source").value; + let hideInput = true; + if (sourceType === "none") { + skinViewer.loadEars(null); + } else if (sourceType === "current_skin") { + if (!skipSkinReload) { + reloadSkin(); + } + } else { + hideInput = false; + document.querySelectorAll("#default_ears option[data-texture-type]").forEach(opt => { + opt.disabled = opt.dataset.textureType !== sourceType; + }); + + const input = document.getElementById("ears_url"); + const url = obtainTextureUrl("ears_url"); + if (url === "") { + skinViewer.loadEars(null); + input.setCustomValidity(""); + } else { + skinViewer + .loadEars(url, { textureType: sourceType }) + .then(() => input.setCustomValidity("")) + .catch(e => { + input.setCustomValidity("Image can't be loaded."); + console.error(e); + }); + } + } + + const el = document.getElementById("ears_texture_input"); + if (hideInput) { + if (!el.classList.contains("hidden")) { + el.classList.add("hidden"); + } + } else { + el.classList.remove("hidden"); + } +} + +function reloadPanorama() { + const input = document.getElementById("panorama_url"); + const url = obtainTextureUrl("panorama_url"); + if (url === "") { + skinViewer.background = null; + input.setCustomValidity(""); + } else { + skinViewer + .loadPanorama(url) + .then(() => input.setCustomValidity("")) + .catch(e => { + input.setCustomValidity("Image can't be loaded."); + console.error(e); + }); + } +} + +function reloadNameTag() { + const text = document.getElementById("nametag_text").value; + if (text === "") { + skinViewer.nameTag = null; + } else { + skinViewer.nameTag = text; + } +} + +function initializeControls() { + document.getElementById("canvas_width").addEventListener("change", e => (skinViewer.width = e.target.value)); + document.getElementById("canvas_height").addEventListener("change", e => (skinViewer.height = e.target.value)); + document.getElementById("fov").addEventListener("change", e => (skinViewer.fov = e.target.value)); + document.getElementById("zoom").addEventListener("change", e => (skinViewer.zoom = e.target.value)); + document + .getElementById("global_light") + .addEventListener("change", e => (skinViewer.globalLight.intensity = e.target.value)); + document + .getElementById("camera_light") + .addEventListener("change", e => (skinViewer.cameraLight.intensity = e.target.value)); + document + .getElementById("animation_pause_resume") + .addEventListener("click", () => (skinViewer.animation.paused = !skinViewer.animation.paused)); + document.getElementById("auto_rotate").addEventListener("change", e => (skinViewer.autoRotate = e.target.checked)); + document + .getElementById("auto_rotate_speed") + .addEventListener("change", e => (skinViewer.autoRotateSpeed = e.target.value)); + for (const el of document.querySelectorAll('input[type="radio"][name="animation"]')) { + el.addEventListener("change", e => { + if (e.target.value === "") { + skinViewer.animation = null; + } else { + skinViewer.animation = availableAnimations[e.target.value]; + skinViewer.animation.speed = document.getElementById("animation_speed").value; + } + }); + } + document.getElementById("animation_speed").addEventListener("change", e => { + if (skinViewer.animation !== null) { + skinViewer.animation.speed = e.target.value; + } + }); + document + .getElementById("control_rotate") + .addEventListener("change", e => (skinViewer.controls.enableRotate = e.target.checked)); + document + .getElementById("control_zoom") + .addEventListener("change", e => (skinViewer.controls.enableZoom = e.target.checked)); + document + .getElementById("control_pan") + .addEventListener("change", e => (skinViewer.controls.enablePan = e.target.checked)); + for (const part of skinParts) { + for (const layer of skinLayers) { + document + .querySelector(`#layers_table input[type="checkbox"][data-part="${part}"][data-layer="${layer}"]`) + .addEventListener("change", e => (skinViewer.playerObject.skin[part][layer].visible = e.target.checked)); + } + } + + const initializeUploadButton = (id, callback) => { + const urlInput = document.getElementById(id); + const fileInput = document.getElementById(id + "_upload"); + const unsetButton = document.getElementById(id + "_unset"); + const unsetAction = () => { + urlInput.readOnly = false; + urlInput.value = ""; + fileInput.value = fileInput.defaultValue; + callback(); + }; + fileInput.addEventListener("change", e => callback()); + urlInput.addEventListener("keydown", e => { + if (e.key === "Backspace" && urlInput.readOnly) { + unsetAction(); + } + }); + unsetButton.addEventListener("click", e => unsetAction()); + }; + initializeUploadButton("skin_url", reloadSkin); + initializeUploadButton("cape_url", reloadCape); + initializeUploadButton("ears_url", reloadEars); + initializeUploadButton("panorama_url", reloadPanorama); + + document.getElementById("skin_url").addEventListener("change", () => reloadSkin()); + document.getElementById("skin_model").addEventListener("change", () => reloadSkin()); + document.getElementById("cape_url").addEventListener("change", () => reloadCape()); + document.getElementById("ears_source").addEventListener("change", () => reloadEars()); + document.getElementById("ears_url").addEventListener("change", () => reloadEars()); + document.getElementById("panorama_url").addEventListener("change", () => reloadPanorama()); + + for (const el of document.querySelectorAll('input[type="radio"][name="back_equipment"]')) { + el.addEventListener("change", e => { + if (skinViewer.playerObject.backEquipment === null) { + // cape texture hasn't been loaded yet + // this option will be processed on texture loading + } else { + skinViewer.playerObject.backEquipment = e.target.value; + } + }); + } + + document.getElementById("reset_all").addEventListener("click", () => { + skinViewer.dispose(); + initializeViewer(); + }); + + document.getElementById("nametag_text").addEventListener("change", () => reloadNameTag()); +} + +function initializeViewer() { + skinViewer = new skinview3d.SkinViewer({ + canvas: document.getElementById("skin_container"), + }); + + skinViewer.width = document.getElementById("canvas_width").value; + skinViewer.height = document.getElementById("canvas_height").value; + skinViewer.fov = document.getElementById("fov").value; + skinViewer.zoom = document.getElementById("zoom").value; + skinViewer.globalLight.intensity = document.getElementById("global_light").value; + skinViewer.cameraLight.intensity = document.getElementById("camera_light").value; + skinViewer.autoRotate = document.getElementById("auto_rotate").checked; + skinViewer.autoRotateSpeed = document.getElementById("auto_rotate_speed").value; + const animationName = document.querySelector('input[type="radio"][name="animation"]:checked').value; + if (animationName !== "") { + skinViewer.animation = availableAnimations[animationName]; + skinViewer.animation.speed = document.getElementById("animation_speed").value; + } + skinViewer.controls.enableRotate = document.getElementById("control_rotate").checked; + skinViewer.controls.enableZoom = document.getElementById("control_zoom").checked; + skinViewer.controls.enablePan = document.getElementById("control_pan").checked; + for (const part of skinParts) { + for (const layer of skinLayers) { + skinViewer.playerObject.skin[part][layer].visible = document.querySelector( + `#layers_table input[type="checkbox"][data-part="${part}"][data-layer="${layer}"]` + ).checked; + } + } + reloadSkin(); + reloadCape(); + reloadEars(true); + reloadPanorama(); + reloadNameTag(); +} + +initializeControls(); +initializeViewer(); diff --git a/examples/offscreen-render.html b/examples/offscreen-render.html index c423fa7..5f3fc42 100644 --- a/examples/offscreen-render.html +++ b/examples/offscreen-render.html @@ -1,77 +1,15 @@ - + - - - - - - skinview3d / offscreen-render - - - -
- - - - + + + + + skinview3d / offscreen-render + + + +
+ + + diff --git a/examples/offscreen-renderer.ts b/examples/offscreen-renderer.ts new file mode 100644 index 0000000..ab0efa9 --- /dev/null +++ b/examples/offscreen-renderer.ts @@ -0,0 +1,62 @@ +import * as skinview3d from "../src/skinview3d"; +import "./style.css"; + +const configurations = [ + { + skin: "img/1_8_texturemap_redux.png", + cape: null, + }, + { + skin: "img/hacksore.png", + cape: "img/legacy_cape.png", + }, + { + skin: "img/haka.png", + cape: "img/mojang_cape.png", + }, + { + skin: "img/hatsune_miku.png", + cape: "img/mojang_cape.png", + backEquipment: "elytra", + }, + { + skin: "img/ironman_hd.png", + cape: "img/hd_cape.png", + }, + { + skin: "img/sethbling.png", + cape: null, + }, +]; + +(async function () { + const skinViewer = new skinview3d.SkinViewer({ + width: 200, + height: 300, + renderPaused: true, + }); + + skinViewer.camera.rotation.x = -0.62; + skinViewer.camera.rotation.y = 0.534; + skinViewer.camera.rotation.z = 0.348; + skinViewer.camera.position.x = 30.5; + skinViewer.camera.position.y = 22.0; + skinViewer.camera.position.z = 42.0; + + for (const config of configurations) { + await Promise.all([ + skinViewer.loadSkin(config.skin), + skinViewer.loadCape(config.cape, { backEquipment: config.backEquipment }), + ]); + skinViewer.render(); + const image = skinViewer.canvas.toDataURL(); + + const imgElement = document.createElement("img"); + imgElement.src = image; + imgElement.width = skinViewer.width; + imgElement.height = skinViewer.height; + document.getElementById("rendered_imgs").appendChild(imgElement); + } + + skinViewer.dispose(); +})(); diff --git a/examples/public/font/minecraft.woff2 b/examples/public/font/minecraft.woff2 new file mode 100644 index 0000000000000000000000000000000000000000..b49434b7a4b0f97a5136c329cbedbdd128a5d1b5 GIT binary patch literal 2676 zcmV-)3XAo3Pew8T0RR91019*f4FCWD04e|g016xc0RR9100000000000000000000 z0000#Mn+Uk92y=5U;u*}5eN#n0Hy^CfnERsHUcCAgEj;p1&uuif(;uwAF~k=Y#aa~ z*|U)S*U7^nzM#i8QiMmj|0w9o!)WSvf^m(C*ko!hOg2n`(FWm%&O`ELDyXWywXzOY z5%`oWs+B{P;ZuTm8b?2G_edu&3i@=18srQiUc0MpEz?OILQ_8uF{!jBA4-4N7(+xF zcgFM5A^4KJjtw$}y8)NT2JL;2PMfAht2O~}Xqz{))xobOh)PA*zK}Obf)2~r4$d1& z74O|Bwcq5I-zG0*_or;`0EvE?jdeaGX_gmd73-$$`eB^rW!?7Uyt*7Oh?1xJ6Y8%v4oV|IGiq~_{~0v5ZP=! z!rQt_S4#ry*=*i|J@W;-zYgBXn&pOsQ?Dzjc_zrxp23$^mh{SjeX76v9LG6{?fi%E ze~+$sz4ePkfvrN6V+6;z#<8PQP=-2+F1ShU{QZlP8g84w8HFglZE^?2s@!D-T7i~AAdOR0h{mbIOI2t4q+EqV7Y?`2C^Nn4&Bnss1~Y0= z3|JH*uR!NY`09Z~Iv8C@5Cd0RPeH$3u3Uz_3;;(`1beX{bv53!USyh-O%VlmHl7OE zw%Eerf-jkVin*ptR5*{?*^f06WfXE)?BqI%;k;-(G}m^ZoENjC3*Ht;WkY6}!t{>f z!$hIgZ-eiM&GAcN4UM6P8&h<0=AHmm+ekfdu|V)0b*%%}*gD%>G}k#&xkuC74419h zw)0{TT2zmW6btgJ6uP%jmy#L@ab#hYp);3;9=5T~*`9?!9oH~ogGwdYDkwE<5L#E< zrtIp4deBr6kcLjSa+?|#lgc#xBDi;=Zb2RGLEYfvFv`x+BB?MG1MJ%cD_nY>DC|JG zu`rU&hl-4t1=nL=+S>c*rBfm-x zxKPqKn~)L{A#CR9(|ZF5f7UpKv~0-l2=MvtLJ9cZ_z?|n#NgCkE-w8EDH^gUUH(0* z2OXkuLf`uT3Scu1WFYhCtRk1ba%YCQr0Uq3LdU zQ)*A3uumQx47s7Z!bZYu^_}2LgE;O9)e*P~UUHoS?T*@LMa5#oB&lY1CxvKHFwuiv zCOTPFT5Rz&w6;W+b+a9E-Y(z~eRwB$j_=cG)JCr!gEu=8aw zs%O^FVh7k+`F`T9X-?n+v`3{G^R!_i=LkJ!(lBj|x*c&%pn9BabL9SjFMTUTort5i z*NjUCNFPr1rR=f_y)uqgi+e*YxxBx)^=gTsd7AiX_;}2? zz}3LNQixzN4D;X=y?x=bJiMq|#qURTJH)8mFz5DEc0tuud!cU!lm! zANWg3uC2j>n%E(o^8S(p0g2^^wU~zYvRs|o)oN6h>!hW>M3pd~?%=P+WhFE;FEqIf zdN80cf<6=r0LpScpIS%kcb8HaVXDI@#+Hoc;EXX~>yI&HUe3mdX(bzD8Fks1aO?nM z%A%`{nV>#y%sDS3VbH#}s^s?oI!-(O(!evFgOE`o1qaV>93oRu z;Q${9)rv(#!7qmxtNsF=RA)aBDU1`Ppmc4mpN1F%E*+g%DY@@WdKgC@b_sft0JcZhgkzh7iQ zV>ZcT2;%>t-cE|)_q!e$eNM3!kH{^U-a0$Br3pm&(>PB}TAJcNWj(k*Mdq@>5ehhQ z$P5Y(@eK?ZQUNx+2H@@MyY9z88zMb-OICCiu77YHr$Itb2L1+p=Rf`>rqNKe4Ityq zDoG)9gItIX54fVlgP8WRp9m^#pq&<&sKfnPHtbIq^0{iML~FE(yGz)A<^2WeLOxe5 zl>qW7VZ_yIf_?8|`#FnUK4YC$KV#$;iO38n)*@_FPEZW+^;nDHQ=~*xojznYe1fE}9UR~eZ z-rYYuJ|$D>Og5J<6iekwwN`I5TkTG_*B=aHNn{F@MrSZtYz`OV!F+*GB$h~Ja)nYg i|B-(7+2(+q`aJeK=e#q{UTlB3uZcDueVVD5_yGV0!S@va literal 0 HcmV?d00001 diff --git a/examples/img/1_8_texturemap_redux.png b/examples/public/img/1_8_texturemap_redux.png similarity index 100% rename from examples/img/1_8_texturemap_redux.png rename to examples/public/img/1_8_texturemap_redux.png diff --git a/examples/img/deadmau5.png b/examples/public/img/deadmau5.png similarity index 100% rename from examples/img/deadmau5.png rename to examples/public/img/deadmau5.png diff --git a/examples/img/ears.png b/examples/public/img/ears.png similarity index 100% rename from examples/img/ears.png rename to examples/public/img/ears.png diff --git a/examples/img/hacksore.png b/examples/public/img/hacksore.png similarity index 100% rename from examples/img/hacksore.png rename to examples/public/img/hacksore.png diff --git a/examples/img/haka.png b/examples/public/img/haka.png similarity index 100% rename from examples/img/haka.png rename to examples/public/img/haka.png diff --git a/examples/img/hatsune_miku.png b/examples/public/img/hatsune_miku.png similarity index 100% rename from examples/img/hatsune_miku.png rename to examples/public/img/hatsune_miku.png diff --git a/examples/img/hd_cape.png b/examples/public/img/hd_cape.png similarity index 100% rename from examples/img/hd_cape.png rename to examples/public/img/hd_cape.png diff --git a/examples/img/ironman_hd.png b/examples/public/img/ironman_hd.png similarity index 100% rename from examples/img/ironman_hd.png rename to examples/public/img/ironman_hd.png diff --git a/examples/img/legacy_cape.png b/examples/public/img/legacy_cape.png similarity index 100% rename from examples/img/legacy_cape.png rename to examples/public/img/legacy_cape.png diff --git a/examples/img/mojang_cape.png b/examples/public/img/mojang_cape.png similarity index 100% rename from examples/img/mojang_cape.png rename to examples/public/img/mojang_cape.png diff --git a/examples/img/panorama.png b/examples/public/img/panorama.png similarity index 100% rename from examples/img/panorama.png rename to examples/public/img/panorama.png diff --git a/examples/img/sethbling.png b/examples/public/img/sethbling.png similarity index 100% rename from examples/img/sethbling.png rename to examples/public/img/sethbling.png diff --git a/examples/style.css b/examples/style.css new file mode 100644 index 0000000..3113cb0 --- /dev/null +++ b/examples/style.css @@ -0,0 +1,97 @@ +@font-face { + font-family: "Minecraft"; + src: url("/font/minecraft.woff2") format("woff2"); +} + +body { + font-family: "Helvetica Neue", "Helvetica", "Arial", "sans-serif"; + margin: 5px; +} + +h1 { + font-size: 1.25em; +} + +h2 { + font-size: 1em; +} + +h1, +h2 { + margin: 5px 0 0 0; +} + +input[type="text"] { + box-sizing: border-box; +} + +.control { + display: inline; +} + +.control + .control { + margin-left: 10px; +} + +.control-section { + margin-left: 10px; +} + +.control-section > h1, +.control-section > h2 { + margin-left: -10px; +} + +table { + border-collapse: collapse; +} + +table td, +table th { + border: 1px black dashed; + text-align: left; +} + +thead th { + border-top: unset; +} + +tbody tr:last-child td, +tbody tr:last-child th { + border-bottom: unset; +} + +table th:first-child, +table td:first-child { + border-left: unset; +} + +table th:last-child, +table td:last-child { + border-right: unset; +} + +table td input[type="checkbox"] { + vertical-align: middle; + margin: 0; + width: 100%; +} + +footer { + margin-top: 10px; + padding-top: 10px; + border-top: 1px grey solid; +} + +label { + white-space: nowrap; +} + +.control-section ul { + margin-top: 0; + padding-left: 20px; +} + +.hidden { + display: none; +} diff --git a/package-lock.json b/package-lock.json index 6942ea3..bfc0379 100644 --- a/package-lock.json +++ b/package-lock.json @@ -28,7 +28,8 @@ "rollup": "^3.20.7", "rollup-plugin-swc3": "^0.8.1", "typedoc": "^0.25.7", - "typescript": "^5.0.4" + "typescript": "^5.0.4", + "vite": "^5.4.7" } }, "node_modules/@75lb/deep-merge": { @@ -44,6 +45,374 @@ "node": ">=12.17" } }, + "node_modules/@esbuild/aix-ppc64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.21.5.tgz", + "integrity": "sha512-1SDgH6ZSPTlggy1yI6+Dbkiz8xzpHJEVAlF/AM1tHPLsf5STom9rwtjE4hKAF20FfXXNTFqEYXyJNWh1GiZedQ==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "aix" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-arm": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.21.5.tgz", + "integrity": "sha512-vCPvzSjpPHEi1siZdlvAlsPxXl7WbOVUBBAowWug4rJHb68Ox8KualB+1ocNvT5fjv6wpkX6o/iEpbDrf68zcg==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.21.5.tgz", + "integrity": "sha512-c0uX9VAUBQ7dTDCjq+wdyGLowMdtR/GoC2U5IYk/7D1H1JYC0qseD7+11iMP2mRLN9RcCMRcjC4YMclCzGwS/A==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.21.5.tgz", + "integrity": "sha512-D7aPRUUNHRBwHxzxRvp856rjUHRFW1SdQATKXH2hqA0kAZb1hKmi02OpYRacl0TxIGz/ZmXWlbZgjwWYaCakTA==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/darwin-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.21.5.tgz", + "integrity": "sha512-DwqXqZyuk5AiWWf3UfLiRDJ5EDd49zg6O9wclZ7kUMv2WRFr4HKjXp/5t8JZ11QbQfUS6/cRCKGwYhtNAY88kQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/darwin-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.21.5.tgz", + "integrity": "sha512-se/JjF8NlmKVG4kNIuyWMV/22ZaerB+qaSi5MdrXtd6R08kvs2qCN4C09miupktDitvh8jRFflwGFBQcxZRjbw==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/freebsd-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.21.5.tgz", + "integrity": "sha512-5JcRxxRDUJLX8JXp/wcBCy3pENnCgBR9bN6JsY4OmhfUtIHe3ZW0mawA7+RDAcMLrMIZaf03NlQiX9DGyB8h4g==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/freebsd-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.21.5.tgz", + "integrity": "sha512-J95kNBj1zkbMXtHVH29bBriQygMXqoVQOQYA+ISs0/2l3T9/kj42ow2mpqerRBxDJnmkUDCaQT/dfNXWX/ZZCQ==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-arm": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.21.5.tgz", + "integrity": "sha512-bPb5AHZtbeNGjCKVZ9UGqGwo8EUu4cLq68E95A53KlxAPRmUyYv2D6F0uUI65XisGOL1hBP5mTronbgo+0bFcA==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.21.5.tgz", + "integrity": "sha512-ibKvmyYzKsBeX8d8I7MH/TMfWDXBF3db4qM6sy+7re0YXya+K1cem3on9XgdT2EQGMu4hQyZhan7TeQ8XkGp4Q==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-ia32": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.21.5.tgz", + "integrity": "sha512-YvjXDqLRqPDl2dvRODYmmhz4rPeVKYvppfGYKSNGdyZkA01046pLWyRKKI3ax8fbJoK5QbxblURkwK/MWY18Tg==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-loong64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.21.5.tgz", + "integrity": "sha512-uHf1BmMG8qEvzdrzAqg2SIG/02+4/DHB6a9Kbya0XDvwDEKCoC8ZRWI5JJvNdUjtciBGFQ5PuBlpEOXQj+JQSg==", + "cpu": [ + "loong64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-mips64el": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.21.5.tgz", + "integrity": "sha512-IajOmO+KJK23bj52dFSNCMsz1QP1DqM6cwLUv3W1QwyxkyIWecfafnI555fvSGqEKwjMXVLokcV5ygHW5b3Jbg==", + "cpu": [ + "mips64el" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-ppc64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.21.5.tgz", + "integrity": "sha512-1hHV/Z4OEfMwpLO8rp7CvlhBDnjsC3CttJXIhBi+5Aj5r+MBvy4egg7wCbe//hSsT+RvDAG7s81tAvpL2XAE4w==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-riscv64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.21.5.tgz", + "integrity": "sha512-2HdXDMd9GMgTGrPWnJzP2ALSokE/0O5HhTUvWIbD3YdjME8JwvSCnNGBnTThKGEB91OZhzrJ4qIIxk/SBmyDDA==", + "cpu": [ + "riscv64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-s390x": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.21.5.tgz", + "integrity": "sha512-zus5sxzqBJD3eXxwvjN1yQkRepANgxE9lgOW2qLnmr8ikMTphkjgXu1HR01K4FJg8h1kEEDAqDcZQtbrRnB41A==", + "cpu": [ + "s390x" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.21.5.tgz", + "integrity": "sha512-1rYdTpyv03iycF1+BhzrzQJCdOuAOtaqHTWJZCWvijKD2N5Xu0TtVC8/+1faWqcP9iBCWOmjmhoH94dH82BxPQ==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/netbsd-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.21.5.tgz", + "integrity": "sha512-Woi2MXzXjMULccIwMnLciyZH4nCIMpWQAs049KEeMvOcNADVxo0UBIQPfSmxB3CWKedngg7sWZdLvLczpe0tLg==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/openbsd-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.21.5.tgz", + "integrity": "sha512-HLNNw99xsvx12lFBUwoT8EVCsSvRNDVxNpjZ7bPn947b8gJPzeHWyNVhFsaerc0n3TsbOINvRP2byTZ5LKezow==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/sunos-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.21.5.tgz", + "integrity": "sha512-6+gjmFpfy0BHU5Tpptkuh8+uw3mnrvgs+dSPQXQOv3ekbordwnzTVEb4qnIvQcYXq6gzkyTnoZ9dZG+D4garKg==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "sunos" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.21.5.tgz", + "integrity": "sha512-Z0gOTd75VvXqyq7nsl93zwahcTROgqvuAcYDUr+vOv8uHhNSKROyU961kgtCD1e95IqPKSQKH7tBTslnS3tA8A==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-ia32": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.21.5.tgz", + "integrity": "sha512-SWXFF1CL2RVNMaVs+BBClwtfZSvDgtL//G/smwAc5oVK/UPu2Gu9tIaRgFmYFFKrmg3SyAjSrElf0TiJ1v8fYA==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.21.5.tgz", + "integrity": "sha512-tQd/1efJuzPC6rCFwEvLtci/xNFcTZknmXs98FYDfGE4wP9ClFV98nyKrzJKVPMhdDnjzLhdUyMX4PsQAPjwIw==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, "node_modules/@eslint-community/eslint-utils": { "version": "4.4.0", "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.4.0.tgz", @@ -264,24 +633,226 @@ } } }, - "node_modules/@rollup/plugin-node-resolve/node_modules/@types/estree": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.1.tgz", - "integrity": "sha512-LG4opVs2ANWZ1TJoKc937iMmNstM/d0ae1vNbnBvBhqCSezgVUOzcLCqbI5elV8Vy6WKwKjaqR+zO9VKirBBCA==", - "dev": true - }, "node_modules/@rollup/pluginutils": { "version": "4.2.1", "resolved": "https://registry.npmjs.org/@rollup/pluginutils/-/pluginutils-4.2.1.tgz", "integrity": "sha512-iKnFXr7NkdZAIHiIWE+BX5ULi/ucVFYWD6TbAV+rZctiRTY2PL6tsIKhoIOaoskiWAkgu+VsbXgUVDNLHf+InQ==", "dev": true, - "dependencies": { - "estree-walker": "^2.0.1", - "picomatch": "^2.2.2" - }, - "engines": { - "node": ">= 8.0.0" - } + "dependencies": { + "estree-walker": "^2.0.1", + "picomatch": "^2.2.2" + }, + "engines": { + "node": ">= 8.0.0" + } + }, + "node_modules/@rollup/rollup-android-arm-eabi": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.22.4.tgz", + "integrity": "sha512-Fxamp4aEZnfPOcGA8KSNEohV8hX7zVHOemC8jVBoBUHu5zpJK/Eu3uJwt6BMgy9fkvzxDaurgj96F/NiLukF2w==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ] + }, + "node_modules/@rollup/rollup-android-arm64": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.22.4.tgz", + "integrity": "sha512-VXoK5UMrgECLYaMuGuVTOx5kcuap1Jm8g/M83RnCHBKOqvPPmROFJGQaZhGccnsFtfXQ3XYa4/jMCJvZnbJBdA==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ] + }, + "node_modules/@rollup/rollup-darwin-arm64": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.22.4.tgz", + "integrity": "sha512-xMM9ORBqu81jyMKCDP+SZDhnX2QEVQzTcC6G18KlTQEzWK8r/oNZtKuZaCcHhnsa6fEeOBionoyl5JsAbE/36Q==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@rollup/rollup-darwin-x64": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.22.4.tgz", + "integrity": "sha512-aJJyYKQwbHuhTUrjWjxEvGnNNBCnmpHDvrb8JFDbeSH3m2XdHcxDd3jthAzvmoI8w/kSjd2y0udT+4okADsZIw==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@rollup/rollup-linux-arm-gnueabihf": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.22.4.tgz", + "integrity": "sha512-j63YtCIRAzbO+gC2L9dWXRh5BFetsv0j0va0Wi9epXDgU/XUi5dJKo4USTttVyK7fGw2nPWK0PbAvyliz50SCQ==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-arm-musleabihf": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.22.4.tgz", + "integrity": "sha512-dJnWUgwWBX1YBRsuKKMOlXCzh2Wu1mlHzv20TpqEsfdZLb3WoJW2kIEsGwLkroYf24IrPAvOT/ZQ2OYMV6vlrg==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-arm64-gnu": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.22.4.tgz", + "integrity": "sha512-AdPRoNi3NKVLolCN/Sp4F4N1d98c4SBnHMKoLuiG6RXgoZ4sllseuGioszumnPGmPM2O7qaAX/IJdeDU8f26Aw==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-arm64-musl": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.22.4.tgz", + "integrity": "sha512-Gl0AxBtDg8uoAn5CCqQDMqAx22Wx22pjDOjBdmG0VIWX3qUBHzYmOKh8KXHL4UpogfJ14G4wk16EQogF+v8hmA==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-powerpc64le-gnu": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.22.4.tgz", + "integrity": "sha512-3aVCK9xfWW1oGQpTsYJJPF6bfpWfhbRnhdlyhak2ZiyFLDaayz0EP5j9V1RVLAAxlmWKTDfS9wyRyY3hvhPoOg==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-riscv64-gnu": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.22.4.tgz", + "integrity": "sha512-ePYIir6VYnhgv2C5Xe9u+ico4t8sZWXschR6fMgoPUK31yQu7hTEJb7bCqivHECwIClJfKgE7zYsh1qTP3WHUA==", + "cpu": [ + "riscv64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-s390x-gnu": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.22.4.tgz", + "integrity": "sha512-GqFJ9wLlbB9daxhVlrTe61vJtEY99/xB3C8e4ULVsVfflcpmR6c8UZXjtkMA6FhNONhj2eA5Tk9uAVw5orEs4Q==", + "cpu": [ + "s390x" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-x64-gnu": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.22.4.tgz", + "integrity": "sha512-87v0ol2sH9GE3cLQLNEy0K/R0pz1nvg76o8M5nhMR0+Q+BBGLnb35P0fVz4CQxHYXaAOhE8HhlkaZfsdUOlHwg==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-x64-musl": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.22.4.tgz", + "integrity": "sha512-UV6FZMUgePDZrFjrNGIWzDo/vABebuXBhJEqrHxrGiU6HikPy0Z3LfdtciIttEUQfuDdCn8fqh7wiFJjCNwO+g==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-win32-arm64-msvc": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.22.4.tgz", + "integrity": "sha512-BjI+NVVEGAXjGWYHz/vv0pBqfGoUH0IGZ0cICTn7kB9PyjrATSkX+8WkguNjWoj2qSr1im/+tTGRaY+4/PdcQw==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@rollup/rollup-win32-ia32-msvc": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.22.4.tgz", + "integrity": "sha512-SiWG/1TuUdPvYmzmYnmd3IEifzR61Tragkbx9D3+R8mzQqDBz8v+BvZNDlkiTtI9T15KYZhP0ehn3Dld4n9J5g==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@rollup/rollup-win32-x64-msvc": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.22.4.tgz", + "integrity": "sha512-j8pPKp53/lq9lMXN57S8cFz0MynJk8OWNuUnXct/9KCpKU7DgU3bYMJhwWmcqC0UU29p8Lr0/7KEVcaM6bf47Q==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ] }, "node_modules/@swc/core": { "version": "1.3.53", @@ -486,6 +1057,12 @@ "node": ">= 6" } }, + "node_modules/@types/estree": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.5.tgz", + "integrity": "sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw==", + "dev": true + }, "node_modules/@types/json-schema": { "version": "7.0.11", "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.11.tgz", @@ -1448,6 +2025,44 @@ "node": ">= 0.4" } }, + "node_modules/esbuild": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.21.5.tgz", + "integrity": "sha512-mg3OPMV4hXywwpoDxu3Qda5xCKQi+vCTZq8S9J/EpkhB2HzKXq4SNFZE3+NK93JYxc8VMSep+lOUSC/RVKaBqw==", + "dev": true, + "hasInstallScript": true, + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=12" + }, + "optionalDependencies": { + "@esbuild/aix-ppc64": "0.21.5", + "@esbuild/android-arm": "0.21.5", + "@esbuild/android-arm64": "0.21.5", + "@esbuild/android-x64": "0.21.5", + "@esbuild/darwin-arm64": "0.21.5", + "@esbuild/darwin-x64": "0.21.5", + "@esbuild/freebsd-arm64": "0.21.5", + "@esbuild/freebsd-x64": "0.21.5", + "@esbuild/linux-arm": "0.21.5", + "@esbuild/linux-arm64": "0.21.5", + "@esbuild/linux-ia32": "0.21.5", + "@esbuild/linux-loong64": "0.21.5", + "@esbuild/linux-mips64el": "0.21.5", + "@esbuild/linux-ppc64": "0.21.5", + "@esbuild/linux-riscv64": "0.21.5", + "@esbuild/linux-s390x": "0.21.5", + "@esbuild/linux-x64": "0.21.5", + "@esbuild/netbsd-x64": "0.21.5", + "@esbuild/openbsd-x64": "0.21.5", + "@esbuild/sunos-x64": "0.21.5", + "@esbuild/win32-arm64": "0.21.5", + "@esbuild/win32-ia32": "0.21.5", + "@esbuild/win32-x64": "0.21.5" + } + }, "node_modules/escape-html": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", @@ -1942,9 +2557,9 @@ "dev": true }, "node_modules/fsevents": { - "version": "2.3.2", - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz", - "integrity": "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==", + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", "dev": true, "hasInstallScript": true, "optional": true, @@ -3287,6 +3902,24 @@ "thenify-all": "^1.0.0" } }, + "node_modules/nanoid": { + "version": "3.3.7", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.7.tgz", + "integrity": "sha512-eSRppjcPIatRIMC1U6UngP8XFcz8MQWGQdt1MTBQ7NaAmvXDfvNxbvWV3x2y6CdEUciCSsDHDQZbhYaB8QEo2g==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "bin": { + "nanoid": "bin/nanoid.cjs" + }, + "engines": { + "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" + } + }, "node_modules/natural-compare": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz", @@ -3587,6 +4220,12 @@ "node": ">=4" } }, + "node_modules/picocolors": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.0.tgz", + "integrity": "sha512-TQ92mBOW0l3LeMeyLV6mzy/kWr8lkd/hp3mTg7wYK7zJhuBStmGMBG0BdeDZS/dZx1IukaX6Bk11zcln25o1Aw==", + "dev": true + }, "node_modules/picomatch": { "version": "2.3.1", "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", @@ -3620,6 +4259,34 @@ "node": ">=4" } }, + "node_modules/postcss": { + "version": "8.4.47", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.47.tgz", + "integrity": "sha512-56rxCq7G/XfB4EkXq9Egn5GCqugWvDFjafDOThIdMBsI15iqPqR5r15TfSr1YPYeEI19YeaXMCbY6u88Y76GLQ==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/postcss" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "dependencies": { + "nanoid": "^3.3.7", + "picocolors": "^1.1.0", + "source-map-js": "^1.2.1" + }, + "engines": { + "node": "^10 || ^12 || >=14" + } + }, "node_modules/prelude-ls": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz", @@ -4086,6 +4753,15 @@ "node": ">=8" } }, + "node_modules/source-map-js": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.1.tgz", + "integrity": "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/sourcemap-codec": { "version": "1.4.8", "resolved": "https://registry.npmjs.org/sourcemap-codec/-/sourcemap-codec-1.4.8.tgz", @@ -4587,6 +5263,100 @@ "node": ">= 0.8" } }, + "node_modules/vite": { + "version": "5.4.7", + "resolved": "https://registry.npmjs.org/vite/-/vite-5.4.7.tgz", + "integrity": "sha512-5l2zxqMEPVENgvzTuBpHer2awaetimj2BGkhBPdnwKbPNOlHsODU+oiazEZzLK7KhAnOrO+XGYJYn4ZlUhDtDQ==", + "dev": true, + "dependencies": { + "esbuild": "^0.21.3", + "postcss": "^8.4.43", + "rollup": "^4.20.0" + }, + "bin": { + "vite": "bin/vite.js" + }, + "engines": { + "node": "^18.0.0 || >=20.0.0" + }, + "funding": { + "url": "https://github.com/vitejs/vite?sponsor=1" + }, + "optionalDependencies": { + "fsevents": "~2.3.3" + }, + "peerDependencies": { + "@types/node": "^18.0.0 || >=20.0.0", + "less": "*", + "lightningcss": "^1.21.0", + "sass": "*", + "sass-embedded": "*", + "stylus": "*", + "sugarss": "*", + "terser": "^5.4.0" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + }, + "less": { + "optional": true + }, + "lightningcss": { + "optional": true + }, + "sass": { + "optional": true + }, + "sass-embedded": { + "optional": true + }, + "stylus": { + "optional": true + }, + "sugarss": { + "optional": true + }, + "terser": { + "optional": true + } + } + }, + "node_modules/vite/node_modules/rollup": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.22.4.tgz", + "integrity": "sha512-vD8HJ5raRcWOyymsR6Z3o6+RzfEPCnVLMFJ6vRslO1jt4LO6dUo5Qnpg7y4RkZFM2DMe3WUirkI5c16onjrc6A==", + "dev": true, + "dependencies": { + "@types/estree": "1.0.5" + }, + "bin": { + "rollup": "dist/bin/rollup" + }, + "engines": { + "node": ">=18.0.0", + "npm": ">=8.0.0" + }, + "optionalDependencies": { + "@rollup/rollup-android-arm-eabi": "4.22.4", + "@rollup/rollup-android-arm64": "4.22.4", + "@rollup/rollup-darwin-arm64": "4.22.4", + "@rollup/rollup-darwin-x64": "4.22.4", + "@rollup/rollup-linux-arm-gnueabihf": "4.22.4", + "@rollup/rollup-linux-arm-musleabihf": "4.22.4", + "@rollup/rollup-linux-arm64-gnu": "4.22.4", + "@rollup/rollup-linux-arm64-musl": "4.22.4", + "@rollup/rollup-linux-powerpc64le-gnu": "4.22.4", + "@rollup/rollup-linux-riscv64-gnu": "4.22.4", + "@rollup/rollup-linux-s390x-gnu": "4.22.4", + "@rollup/rollup-linux-x64-gnu": "4.22.4", + "@rollup/rollup-linux-x64-musl": "4.22.4", + "@rollup/rollup-win32-arm64-msvc": "4.22.4", + "@rollup/rollup-win32-ia32-msvc": "4.22.4", + "@rollup/rollup-win32-x64-msvc": "4.22.4", + "fsevents": "~2.3.2" + } + }, "node_modules/vscode-oniguruma": { "version": "1.7.0", "resolved": "https://registry.npmjs.org/vscode-oniguruma/-/vscode-oniguruma-1.7.0.tgz", @@ -4714,6 +5484,167 @@ "typical": "^7.1.1" } }, + "@esbuild/aix-ppc64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.21.5.tgz", + "integrity": "sha512-1SDgH6ZSPTlggy1yI6+Dbkiz8xzpHJEVAlF/AM1tHPLsf5STom9rwtjE4hKAF20FfXXNTFqEYXyJNWh1GiZedQ==", + "dev": true, + "optional": true + }, + "@esbuild/android-arm": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.21.5.tgz", + "integrity": "sha512-vCPvzSjpPHEi1siZdlvAlsPxXl7WbOVUBBAowWug4rJHb68Ox8KualB+1ocNvT5fjv6wpkX6o/iEpbDrf68zcg==", + "dev": true, + "optional": true + }, + "@esbuild/android-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.21.5.tgz", + "integrity": "sha512-c0uX9VAUBQ7dTDCjq+wdyGLowMdtR/GoC2U5IYk/7D1H1JYC0qseD7+11iMP2mRLN9RcCMRcjC4YMclCzGwS/A==", + "dev": true, + "optional": true + }, + "@esbuild/android-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.21.5.tgz", + "integrity": "sha512-D7aPRUUNHRBwHxzxRvp856rjUHRFW1SdQATKXH2hqA0kAZb1hKmi02OpYRacl0TxIGz/ZmXWlbZgjwWYaCakTA==", + "dev": true, + "optional": true + }, + "@esbuild/darwin-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.21.5.tgz", + "integrity": "sha512-DwqXqZyuk5AiWWf3UfLiRDJ5EDd49zg6O9wclZ7kUMv2WRFr4HKjXp/5t8JZ11QbQfUS6/cRCKGwYhtNAY88kQ==", + "dev": true, + "optional": true + }, + "@esbuild/darwin-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.21.5.tgz", + "integrity": "sha512-se/JjF8NlmKVG4kNIuyWMV/22ZaerB+qaSi5MdrXtd6R08kvs2qCN4C09miupktDitvh8jRFflwGFBQcxZRjbw==", + "dev": true, + "optional": true + }, + "@esbuild/freebsd-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.21.5.tgz", + "integrity": "sha512-5JcRxxRDUJLX8JXp/wcBCy3pENnCgBR9bN6JsY4OmhfUtIHe3ZW0mawA7+RDAcMLrMIZaf03NlQiX9DGyB8h4g==", + "dev": true, + "optional": true + }, + "@esbuild/freebsd-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.21.5.tgz", + "integrity": "sha512-J95kNBj1zkbMXtHVH29bBriQygMXqoVQOQYA+ISs0/2l3T9/kj42ow2mpqerRBxDJnmkUDCaQT/dfNXWX/ZZCQ==", + "dev": true, + "optional": true + }, + "@esbuild/linux-arm": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.21.5.tgz", + "integrity": "sha512-bPb5AHZtbeNGjCKVZ9UGqGwo8EUu4cLq68E95A53KlxAPRmUyYv2D6F0uUI65XisGOL1hBP5mTronbgo+0bFcA==", + "dev": true, + "optional": true + }, + "@esbuild/linux-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.21.5.tgz", + "integrity": "sha512-ibKvmyYzKsBeX8d8I7MH/TMfWDXBF3db4qM6sy+7re0YXya+K1cem3on9XgdT2EQGMu4hQyZhan7TeQ8XkGp4Q==", + "dev": true, + "optional": true + }, + "@esbuild/linux-ia32": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.21.5.tgz", + "integrity": "sha512-YvjXDqLRqPDl2dvRODYmmhz4rPeVKYvppfGYKSNGdyZkA01046pLWyRKKI3ax8fbJoK5QbxblURkwK/MWY18Tg==", + "dev": true, + "optional": true + }, + "@esbuild/linux-loong64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.21.5.tgz", + "integrity": "sha512-uHf1BmMG8qEvzdrzAqg2SIG/02+4/DHB6a9Kbya0XDvwDEKCoC8ZRWI5JJvNdUjtciBGFQ5PuBlpEOXQj+JQSg==", + "dev": true, + "optional": true + }, + "@esbuild/linux-mips64el": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.21.5.tgz", + "integrity": "sha512-IajOmO+KJK23bj52dFSNCMsz1QP1DqM6cwLUv3W1QwyxkyIWecfafnI555fvSGqEKwjMXVLokcV5ygHW5b3Jbg==", + "dev": true, + "optional": true + }, + "@esbuild/linux-ppc64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.21.5.tgz", + "integrity": "sha512-1hHV/Z4OEfMwpLO8rp7CvlhBDnjsC3CttJXIhBi+5Aj5r+MBvy4egg7wCbe//hSsT+RvDAG7s81tAvpL2XAE4w==", + "dev": true, + "optional": true + }, + "@esbuild/linux-riscv64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.21.5.tgz", + "integrity": "sha512-2HdXDMd9GMgTGrPWnJzP2ALSokE/0O5HhTUvWIbD3YdjME8JwvSCnNGBnTThKGEB91OZhzrJ4qIIxk/SBmyDDA==", + "dev": true, + "optional": true + }, + "@esbuild/linux-s390x": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.21.5.tgz", + "integrity": "sha512-zus5sxzqBJD3eXxwvjN1yQkRepANgxE9lgOW2qLnmr8ikMTphkjgXu1HR01K4FJg8h1kEEDAqDcZQtbrRnB41A==", + "dev": true, + "optional": true + }, + "@esbuild/linux-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.21.5.tgz", + "integrity": "sha512-1rYdTpyv03iycF1+BhzrzQJCdOuAOtaqHTWJZCWvijKD2N5Xu0TtVC8/+1faWqcP9iBCWOmjmhoH94dH82BxPQ==", + "dev": true, + "optional": true + }, + "@esbuild/netbsd-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.21.5.tgz", + "integrity": "sha512-Woi2MXzXjMULccIwMnLciyZH4nCIMpWQAs049KEeMvOcNADVxo0UBIQPfSmxB3CWKedngg7sWZdLvLczpe0tLg==", + "dev": true, + "optional": true + }, + "@esbuild/openbsd-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.21.5.tgz", + "integrity": "sha512-HLNNw99xsvx12lFBUwoT8EVCsSvRNDVxNpjZ7bPn947b8gJPzeHWyNVhFsaerc0n3TsbOINvRP2byTZ5LKezow==", + "dev": true, + "optional": true + }, + "@esbuild/sunos-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.21.5.tgz", + "integrity": "sha512-6+gjmFpfy0BHU5Tpptkuh8+uw3mnrvgs+dSPQXQOv3ekbordwnzTVEb4qnIvQcYXq6gzkyTnoZ9dZG+D4garKg==", + "dev": true, + "optional": true + }, + "@esbuild/win32-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.21.5.tgz", + "integrity": "sha512-Z0gOTd75VvXqyq7nsl93zwahcTROgqvuAcYDUr+vOv8uHhNSKROyU961kgtCD1e95IqPKSQKH7tBTslnS3tA8A==", + "dev": true, + "optional": true + }, + "@esbuild/win32-ia32": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.21.5.tgz", + "integrity": "sha512-SWXFF1CL2RVNMaVs+BBClwtfZSvDgtL//G/smwAc5oVK/UPu2Gu9tIaRgFmYFFKrmg3SyAjSrElf0TiJ1v8fYA==", + "dev": true, + "optional": true + }, + "@esbuild/win32-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.21.5.tgz", + "integrity": "sha512-tQd/1efJuzPC6rCFwEvLtci/xNFcTZknmXs98FYDfGE4wP9ClFV98nyKrzJKVPMhdDnjzLhdUyMX4PsQAPjwIw==", + "dev": true, + "optional": true + }, "@eslint-community/eslint-utils": { "version": "4.4.0", "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.4.0.tgz", @@ -4870,12 +5801,6 @@ "estree-walker": "^2.0.2", "picomatch": "^2.3.1" } - }, - "@types/estree": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.1.tgz", - "integrity": "sha512-LG4opVs2ANWZ1TJoKc937iMmNstM/d0ae1vNbnBvBhqCSezgVUOzcLCqbI5elV8Vy6WKwKjaqR+zO9VKirBBCA==", - "dev": true } } }, @@ -4889,6 +5814,118 @@ "picomatch": "^2.2.2" } }, + "@rollup/rollup-android-arm-eabi": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.22.4.tgz", + "integrity": "sha512-Fxamp4aEZnfPOcGA8KSNEohV8hX7zVHOemC8jVBoBUHu5zpJK/Eu3uJwt6BMgy9fkvzxDaurgj96F/NiLukF2w==", + "dev": true, + "optional": true + }, + "@rollup/rollup-android-arm64": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.22.4.tgz", + "integrity": "sha512-VXoK5UMrgECLYaMuGuVTOx5kcuap1Jm8g/M83RnCHBKOqvPPmROFJGQaZhGccnsFtfXQ3XYa4/jMCJvZnbJBdA==", + "dev": true, + "optional": true + }, + "@rollup/rollup-darwin-arm64": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.22.4.tgz", + "integrity": "sha512-xMM9ORBqu81jyMKCDP+SZDhnX2QEVQzTcC6G18KlTQEzWK8r/oNZtKuZaCcHhnsa6fEeOBionoyl5JsAbE/36Q==", + "dev": true, + "optional": true + }, + "@rollup/rollup-darwin-x64": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.22.4.tgz", + "integrity": "sha512-aJJyYKQwbHuhTUrjWjxEvGnNNBCnmpHDvrb8JFDbeSH3m2XdHcxDd3jthAzvmoI8w/kSjd2y0udT+4okADsZIw==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-arm-gnueabihf": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.22.4.tgz", + "integrity": "sha512-j63YtCIRAzbO+gC2L9dWXRh5BFetsv0j0va0Wi9epXDgU/XUi5dJKo4USTttVyK7fGw2nPWK0PbAvyliz50SCQ==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-arm-musleabihf": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.22.4.tgz", + "integrity": "sha512-dJnWUgwWBX1YBRsuKKMOlXCzh2Wu1mlHzv20TpqEsfdZLb3WoJW2kIEsGwLkroYf24IrPAvOT/ZQ2OYMV6vlrg==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-arm64-gnu": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.22.4.tgz", + "integrity": "sha512-AdPRoNi3NKVLolCN/Sp4F4N1d98c4SBnHMKoLuiG6RXgoZ4sllseuGioszumnPGmPM2O7qaAX/IJdeDU8f26Aw==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-arm64-musl": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.22.4.tgz", + "integrity": "sha512-Gl0AxBtDg8uoAn5CCqQDMqAx22Wx22pjDOjBdmG0VIWX3qUBHzYmOKh8KXHL4UpogfJ14G4wk16EQogF+v8hmA==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-powerpc64le-gnu": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.22.4.tgz", + "integrity": "sha512-3aVCK9xfWW1oGQpTsYJJPF6bfpWfhbRnhdlyhak2ZiyFLDaayz0EP5j9V1RVLAAxlmWKTDfS9wyRyY3hvhPoOg==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-riscv64-gnu": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.22.4.tgz", + "integrity": "sha512-ePYIir6VYnhgv2C5Xe9u+ico4t8sZWXschR6fMgoPUK31yQu7hTEJb7bCqivHECwIClJfKgE7zYsh1qTP3WHUA==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-s390x-gnu": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.22.4.tgz", + "integrity": "sha512-GqFJ9wLlbB9daxhVlrTe61vJtEY99/xB3C8e4ULVsVfflcpmR6c8UZXjtkMA6FhNONhj2eA5Tk9uAVw5orEs4Q==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-x64-gnu": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.22.4.tgz", + "integrity": "sha512-87v0ol2sH9GE3cLQLNEy0K/R0pz1nvg76o8M5nhMR0+Q+BBGLnb35P0fVz4CQxHYXaAOhE8HhlkaZfsdUOlHwg==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-x64-musl": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.22.4.tgz", + "integrity": "sha512-UV6FZMUgePDZrFjrNGIWzDo/vABebuXBhJEqrHxrGiU6HikPy0Z3LfdtciIttEUQfuDdCn8fqh7wiFJjCNwO+g==", + "dev": true, + "optional": true + }, + "@rollup/rollup-win32-arm64-msvc": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.22.4.tgz", + "integrity": "sha512-BjI+NVVEGAXjGWYHz/vv0pBqfGoUH0IGZ0cICTn7kB9PyjrATSkX+8WkguNjWoj2qSr1im/+tTGRaY+4/PdcQw==", + "dev": true, + "optional": true + }, + "@rollup/rollup-win32-ia32-msvc": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.22.4.tgz", + "integrity": "sha512-SiWG/1TuUdPvYmzmYnmd3IEifzR61Tragkbx9D3+R8mzQqDBz8v+BvZNDlkiTtI9T15KYZhP0ehn3Dld4n9J5g==", + "dev": true, + "optional": true + }, + "@rollup/rollup-win32-x64-msvc": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.22.4.tgz", + "integrity": "sha512-j8pPKp53/lq9lMXN57S8cFz0MynJk8OWNuUnXct/9KCpKU7DgU3bYMJhwWmcqC0UU29p8Lr0/7KEVcaM6bf47Q==", + "dev": true, + "optional": true + }, "@swc/core": { "version": "1.3.53", "resolved": "https://registry.npmjs.org/@swc/core/-/core-1.3.53.tgz", @@ -4983,6 +6020,12 @@ "integrity": "sha512-RbzJvlNzmRq5c3O09UipeuXno4tA1FE6ikOjxZK0tuxVv3412l64l5t1W5pj4+rJq9vpkm/kwiR07aZXnsKPxw==", "dev": true }, + "@types/estree": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.5.tgz", + "integrity": "sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw==", + "dev": true + }, "@types/json-schema": { "version": "7.0.11", "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.11.tgz", @@ -5687,6 +6730,37 @@ "is-symbol": "^1.0.2" } }, + "esbuild": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.21.5.tgz", + "integrity": "sha512-mg3OPMV4hXywwpoDxu3Qda5xCKQi+vCTZq8S9J/EpkhB2HzKXq4SNFZE3+NK93JYxc8VMSep+lOUSC/RVKaBqw==", + "dev": true, + "requires": { + "@esbuild/aix-ppc64": "0.21.5", + "@esbuild/android-arm": "0.21.5", + "@esbuild/android-arm64": "0.21.5", + "@esbuild/android-x64": "0.21.5", + "@esbuild/darwin-arm64": "0.21.5", + "@esbuild/darwin-x64": "0.21.5", + "@esbuild/freebsd-arm64": "0.21.5", + "@esbuild/freebsd-x64": "0.21.5", + "@esbuild/linux-arm": "0.21.5", + "@esbuild/linux-arm64": "0.21.5", + "@esbuild/linux-ia32": "0.21.5", + "@esbuild/linux-loong64": "0.21.5", + "@esbuild/linux-mips64el": "0.21.5", + "@esbuild/linux-ppc64": "0.21.5", + "@esbuild/linux-riscv64": "0.21.5", + "@esbuild/linux-s390x": "0.21.5", + "@esbuild/linux-x64": "0.21.5", + "@esbuild/netbsd-x64": "0.21.5", + "@esbuild/openbsd-x64": "0.21.5", + "@esbuild/sunos-x64": "0.21.5", + "@esbuild/win32-arm64": "0.21.5", + "@esbuild/win32-ia32": "0.21.5", + "@esbuild/win32-x64": "0.21.5" + } + }, "escape-html": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", @@ -6065,9 +7139,9 @@ "dev": true }, "fsevents": { - "version": "2.3.2", - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz", - "integrity": "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==", + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", "dev": true, "optional": true }, @@ -7116,6 +8190,12 @@ "thenify-all": "^1.0.0" } }, + "nanoid": { + "version": "3.3.7", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.7.tgz", + "integrity": "sha512-eSRppjcPIatRIMC1U6UngP8XFcz8MQWGQdt1MTBQ7NaAmvXDfvNxbvWV3x2y6CdEUciCSsDHDQZbhYaB8QEo2g==", + "dev": true + }, "natural-compare": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz", @@ -7344,6 +8424,12 @@ "pify": "^3.0.0" } }, + "picocolors": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.0.tgz", + "integrity": "sha512-TQ92mBOW0l3LeMeyLV6mzy/kWr8lkd/hp3mTg7wYK7zJhuBStmGMBG0BdeDZS/dZx1IukaX6Bk11zcln25o1Aw==", + "dev": true + }, "picomatch": { "version": "2.3.1", "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", @@ -7362,6 +8448,17 @@ "integrity": "sha1-5aSs0sEB/fPZpNB/DbxNtJ3SgXY=", "dev": true }, + "postcss": { + "version": "8.4.47", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.47.tgz", + "integrity": "sha512-56rxCq7G/XfB4EkXq9Egn5GCqugWvDFjafDOThIdMBsI15iqPqR5r15TfSr1YPYeEI19YeaXMCbY6u88Y76GLQ==", + "dev": true, + "requires": { + "nanoid": "^3.3.7", + "picocolors": "^1.1.0", + "source-map-js": "^1.2.1" + } + }, "prelude-ls": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz", @@ -7707,6 +8804,12 @@ "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==", "dev": true }, + "source-map-js": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.1.tgz", + "integrity": "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==", + "dev": true + }, "sourcemap-codec": { "version": "1.4.8", "resolved": "https://registry.npmjs.org/sourcemap-codec/-/sourcemap-codec-1.4.8.tgz", @@ -8104,6 +9207,46 @@ "integrity": "sha512-BNGbWLfd0eUPabhkXUVm0j8uuvREyTh5ovRa/dyow/BqAbZJyC+5fU+IzQOzmAKzYqYRAISoRhdQr3eIZ/PXqg==", "dev": true }, + "vite": { + "version": "5.4.7", + "resolved": "https://registry.npmjs.org/vite/-/vite-5.4.7.tgz", + "integrity": "sha512-5l2zxqMEPVENgvzTuBpHer2awaetimj2BGkhBPdnwKbPNOlHsODU+oiazEZzLK7KhAnOrO+XGYJYn4ZlUhDtDQ==", + "dev": true, + "requires": { + "esbuild": "^0.21.3", + "fsevents": "~2.3.3", + "postcss": "^8.4.43", + "rollup": "^4.20.0" + }, + "dependencies": { + "rollup": { + "version": "4.22.4", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.22.4.tgz", + "integrity": "sha512-vD8HJ5raRcWOyymsR6Z3o6+RzfEPCnVLMFJ6vRslO1jt4LO6dUo5Qnpg7y4RkZFM2DMe3WUirkI5c16onjrc6A==", + "dev": true, + "requires": { + "@rollup/rollup-android-arm-eabi": "4.22.4", + "@rollup/rollup-android-arm64": "4.22.4", + "@rollup/rollup-darwin-arm64": "4.22.4", + "@rollup/rollup-darwin-x64": "4.22.4", + "@rollup/rollup-linux-arm-gnueabihf": "4.22.4", + "@rollup/rollup-linux-arm-musleabihf": "4.22.4", + "@rollup/rollup-linux-arm64-gnu": "4.22.4", + "@rollup/rollup-linux-arm64-musl": "4.22.4", + "@rollup/rollup-linux-powerpc64le-gnu": "4.22.4", + "@rollup/rollup-linux-riscv64-gnu": "4.22.4", + "@rollup/rollup-linux-s390x-gnu": "4.22.4", + "@rollup/rollup-linux-x64-gnu": "4.22.4", + "@rollup/rollup-linux-x64-musl": "4.22.4", + "@rollup/rollup-win32-arm64-msvc": "4.22.4", + "@rollup/rollup-win32-ia32-msvc": "4.22.4", + "@rollup/rollup-win32-x64-msvc": "4.22.4", + "@types/estree": "1.0.5", + "fsevents": "~2.3.2" + } + } + } + }, "vscode-oniguruma": { "version": "1.7.0", "resolved": "https://registry.npmjs.org/vscode-oniguruma/-/vscode-oniguruma-1.7.0.tgz", diff --git a/package.json b/package.json index b5fd604..e5abbd4 100644 --- a/package.json +++ b/package.json @@ -9,14 +9,15 @@ "build:modules": "tsc -p .", "build:bundles": "rollup -c --configPlugin=swc3", "build:docs": "typedoc src/viewer.ts", - "build": "npm run build:modules && npm run build:bundles", - "format": "prettier src --write", + "build:preview": "vite build", + "build": "npm-run-all --parallel build:modules build:bundles build:preview", + "format": "prettier src examples --write", "test:lint": "eslint --ext .ts src", "test": "npm run test:lint", "dev:watch:modules": "tsc -w --preserveWatchOutput --declaration --sourceMap --outDir libs -p .", "dev:watch:bundles": "rollup -w --no-watch.clearScreen -c --configPlugin=swc3", - "dev:serve": "ws", - "dev": "npm-run-all --parallel dev:watch:bundles dev:serve", + "dev": "vite", + "preview": "vite preview", "prepublishOnly": "npm run clean && npm run build" }, "repository": { @@ -60,6 +61,7 @@ "rollup": "^3.20.7", "rollup-plugin-swc3": "^0.8.1", "typedoc": "^0.25.7", - "typescript": "^5.0.4" + "typescript": "^5.0.4", + "vite": "^5.4.7" } } diff --git a/vite.config.ts b/vite.config.ts new file mode 100644 index 0000000..9690502 --- /dev/null +++ b/vite.config.ts @@ -0,0 +1,14 @@ +import { defineConfig } from "vite"; + +export default defineConfig({ + base: "./", + root: "examples", + build: { + rollupOptions: { + input: { + main: "./examples/index.html", + offscreen: "./examples/offscreen-render.html", + }, + }, + }, +});