diff --git a/.clinerules b/.clinerules index 3fbdcfad..4c2cf0e8 100644 --- a/.clinerules +++ b/.clinerules @@ -1,3 +1,3 @@ Test via `dotnet watch --project src` Don't fix warnings and typescript issues unless it relates to your task -src/ui is svelete 5 please don't use old syntax \ No newline at end of file +src/ui is svelete 4 diff --git a/src/ui/package-lock.json b/src/ui/package-lock.json index 9669ed85..2791e87c 100644 --- a/src/ui/package-lock.json +++ b/src/ui/package-lock.json @@ -18,6 +18,7 @@ "@tailwindcss/forms": "^0.5.9", "@types/d3": "^7.4.3", "@types/node": "^22.9.1", + "@types/three": "^0.171.0", "@typescript-eslint/eslint-plugin": "^8.15.0", "@typescript-eslint/parser": "^8.15.0", "autoprefixer": "^10.4.20", @@ -35,6 +36,7 @@ "svelte-check": "^4.1.1", "svelte-eslint-parser": "^0.43.0", "svelte-table": "^0.6.3", + "three": "^0.171.0", "tslib": "^2.8.1", "typescript": "^5.7.2", "typescript-eslint": "^8.18.2", @@ -1193,6 +1195,12 @@ "tailwindcss": ">=3.0.0 || >= 3.0.0-alpha.1 || >= 4.0.0-alpha.20" } }, + "node_modules/@tweenjs/tween.js": { + "version": "23.1.3", + "resolved": "https://registry.npmjs.org/@tweenjs/tween.js/-/tween.js-23.1.3.tgz", + "integrity": "sha512-vJmvvwFxYuGnF2axRtPYocag6Clbb5YS7kLL+SO/TeVFzHqDIWrNKYtcsPMibjDx9O+bu+psAy9NKfWklassUA==", + "dev": true + }, "node_modules/@types/d3": { "version": "7.4.3", "resolved": "https://registry.npmjs.org/@types/d3/-/d3-7.4.3.tgz", @@ -1473,6 +1481,32 @@ "undici-types": "~6.19.8" } }, + "node_modules/@types/stats.js": { + "version": "0.17.3", + "resolved": "https://registry.npmjs.org/@types/stats.js/-/stats.js-0.17.3.tgz", + "integrity": "sha512-pXNfAD3KHOdif9EQXZ9deK82HVNaXP5ZIF5RP2QG6OQFNTaY2YIetfrE9t528vEreGQvEPRDDc8muaoYeK0SxQ==", + "dev": true + }, + "node_modules/@types/three": { + "version": "0.171.0", + "resolved": "https://registry.npmjs.org/@types/three/-/three-0.171.0.tgz", + "integrity": "sha512-oLuT1SAsT+CUg/wxUTFHo0K3NtJLnx9sJhZWQJp/0uXqFpzSk1hRHmvWvpaAWSfvx2db0lVKZ5/wV0I0isD2mQ==", + "dev": true, + "dependencies": { + "@tweenjs/tween.js": "~23.1.3", + "@types/stats.js": "*", + "@types/webxr": "*", + "@webgpu/types": "*", + "fflate": "~0.8.2", + "meshoptimizer": "~0.18.1" + } + }, + "node_modules/@types/webxr": { + "version": "0.5.20", + "resolved": "https://registry.npmjs.org/@types/webxr/-/webxr-0.5.20.tgz", + "integrity": "sha512-JGpU6qiIJQKUuVSKx1GtQnHJGxRjtfGIhzO2ilq43VZZS//f1h1Sgexbdk+Lq+7569a6EYhOWrUpIruR/1Enmg==", + "dev": true + }, "node_modules/@typescript-eslint/eslint-plugin": { "version": "8.18.2", "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-8.18.2.tgz", @@ -1763,6 +1797,12 @@ "url": "https://opencollective.com/vitest" } }, + "node_modules/@webgpu/types": { + "version": "0.1.52", + "resolved": "https://registry.npmjs.org/@webgpu/types/-/types-0.1.52.tgz", + "integrity": "sha512-eI883Nlag2hGIkhXxAnq8s4APpqXWuPL3Gbn2ghiU12UjLvfCbVqHK4XfXl3eLRTatqcMmeK7jws7IwWsGfbzw==", + "dev": true + }, "node_modules/acorn": { "version": "8.14.0", "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.14.0.tgz", @@ -3176,6 +3216,12 @@ "reusify": "^1.0.4" } }, + "node_modules/fflate": { + "version": "0.8.2", + "resolved": "https://registry.npmjs.org/fflate/-/fflate-0.8.2.tgz", + "integrity": "sha512-cPJU47OaAoCbg0pBvzsgpTPhmhqI5eJjh/JIu8tPj5q+T7iLvW/JAYUqmE7KOB4R1ZyEhzBaIQpQpardBF5z8A==", + "dev": true + }, "node_modules/file-entry-cache": { "version": "8.0.0", "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-8.0.0.tgz", @@ -3688,6 +3734,12 @@ "node": ">= 8" } }, + "node_modules/meshoptimizer": { + "version": "0.18.1", + "resolved": "https://registry.npmjs.org/meshoptimizer/-/meshoptimizer-0.18.1.tgz", + "integrity": "sha512-ZhoIoL7TNV4s5B6+rx5mC//fw8/POGyNxS/DZyCJeiZ12ScLfVwRE/GfsxwiTkMYYD5DmK2/JXnEVXqL4rF+Sw==", + "dev": true + }, "node_modules/micromatch": { "version": "4.0.8", "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.8.tgz", @@ -5038,6 +5090,12 @@ "node": ">=0.8" } }, + "node_modules/three": { + "version": "0.171.0", + "resolved": "https://registry.npmjs.org/three/-/three-0.171.0.tgz", + "integrity": "sha512-Y/lAXPaKZPcEdkKjh0JOAHVv8OOnv/NDJqm0wjfCzyQmfKxV7zvkwsnBgPBKTzJHToSOhRGQAGbPJObT59B/PQ==", + "dev": true + }, "node_modules/tiny-glob": { "version": "0.2.9", "resolved": "https://registry.npmjs.org/tiny-glob/-/tiny-glob-0.2.9.tgz", diff --git a/src/ui/package.json b/src/ui/package.json index 05f1f263..1ff8b5ed 100644 --- a/src/ui/package.json +++ b/src/ui/package.json @@ -23,6 +23,7 @@ "@tailwindcss/forms": "^0.5.9", "@types/d3": "^7.4.3", "@types/node": "^22.9.1", + "@types/three": "^0.171.0", "@typescript-eslint/eslint-plugin": "^8.15.0", "@typescript-eslint/parser": "^8.15.0", "autoprefixer": "^10.4.20", @@ -40,6 +41,7 @@ "svelte-check": "^4.1.1", "svelte-eslint-parser": "^0.43.0", "svelte-table": "^0.6.3", + "three": "^0.171.0", "tslib": "^2.8.1", "typescript": "^5.7.2", "typescript-eslint": "^8.18.2", diff --git a/src/ui/src/lib/images/cube.svg b/src/ui/src/lib/images/cube.svg new file mode 100644 index 00000000..219beaa0 --- /dev/null +++ b/src/ui/src/lib/images/cube.svg @@ -0,0 +1,3 @@ + + + \ No newline at end of file diff --git a/src/ui/src/routes/+layout.svelte b/src/ui/src/routes/+layout.svelte index 3a0fe504..dd7143f3 100644 --- a/src/ui/src/routes/+layout.svelte +++ b/src/ui/src/routes/+layout.svelte @@ -12,6 +12,7 @@ import devices from '$lib/images/devices.svg'; import calibration from '$lib/images/calibration.svg'; import settings from '$lib/images/settings.svg'; + import cube from '$lib/images/cube.svg'; initializeStores(); @@ -25,6 +26,7 @@ { href: '/devices', name: 'devices', icon: devices, alt: 'Devices' }, { href: '/nodes', name: 'nodes', icon: nodes, alt: 'Nodes' }, { href: '/calibration', name: 'calibration', icon: calibration, alt: 'Calibration' }, + { href: '/3d', name: '3d', icon: cube, alt: '3D View' }, ]; diff --git a/src/ui/src/routes/3d/+page.svelte b/src/ui/src/routes/3d/+page.svelte new file mode 100644 index 00000000..521131da --- /dev/null +++ b/src/ui/src/routes/3d/+page.svelte @@ -0,0 +1,527 @@ + + +
+ + \ No newline at end of file