An open-source, self-hosted system for apps built with web technologies.
Reorganize and simplify the client view
zohayrslileh94c2d9ccb064
diff --git a/bun.lock b/bun.lockindex 1193639..f96f56b 100644--- a/bun.lock+++ b/bun.lock@@ -6,8 +6,6 @@"name": "phreshos","dependencies": {"@fontsource/roboto": "^5.3.0",- "@heroui/react": "3.2.4",- "@heroui/styles": "3.2.4","@hono/node-server": "^2.1.1","@msgpack/msgpack": "^3.1.3","@react-aria/i18n": "^3.13.1",@@ -18,7 +16,6 @@"gsap": "^3.15.0","hono": "^4.13.2","keyv": "^5.6.0",- "next-themes": "0.4.6","node-rsa": "^2.0.0","react": "^19.2.8","react-aria": "^3.51.0",@@ -52,12 +49,6 @@},},"packages": {- "@adobe/react-spectrum": ["@adobe/[email protected]", "", { "dependencies": { "@internationalized/date": "^3.12.3", "@react-types/shared": "^3.36.1", "@spectrum-icons/ui": "^3.7.1", "@spectrum-icons/workflow": "^4.3.1", "@swc/helpers": "^0.5.0", "client-only": "^0.0.1", "clsx": "^2.0.0", "react-aria": "3.51.0", "react-aria-components": "1.20.0", "react-stately": "3.49.0", "react-transition-group": "^4.4.5", "use-sync-external-store": "^1.6.0" }, "peerDependencies": { "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1", "react-dom": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1" } }, "sha512-tWZG59+xTbXIqeZB4uyuo2qljk3nRK66IkdBmMgbl2p6peApkKbrtJ/YOM8rW4gemdmv7qoJlbIHvy8aJkYsCQ=="],-- "@adobe/react-spectrum-ui": ["@adobe/[email protected]", "", { "peerDependencies": { "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0", "react-dom": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0" } }, "sha512-wcrbEE2O/9WnEn6avBnaVRRx88S5PLFsPLr4wffzlbMfXeQsy+RMQwaJd3cbzrn18/j04Isit7f7Emfn0dhrJA=="],-- "@adobe/react-spectrum-workflow": ["@adobe/[email protected]", "", { "peerDependencies": { "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0", "react-dom": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0" } }, "sha512-b53VIPwPWKb/T5gzE3qs+QlGP5gVrw/LnWV3xMksDU+CRl3rzOKUwxIGiZO8ICyYh1WiyqY4myGlPU/nAynBUg=="],-"@babel/code-frame": ["@babel/[email protected]", "", { "dependencies": { "@babel/helper-validator-identifier": "^7.29.7", "js-tokens": "^4.0.0", "picocolors": "^1.1.1" } }, "sha512-Aup7aUOfpbAUg2ROOJN6Iw5f9DMBlzu0mIkm/malLQFN/YQgO48wCj0Kxa3sEHJvPVFg7siR+qRInwXd2qhQKw=="],"@babel/compat-data": ["@babel/[email protected]", "", {}, "sha512-locTkQyKvwIEgBzVrn8693ebc97F2U8ZHjbXwDXJ5Fn2TCpNwTlKcaKLkdHop5c/icOFE7qt7Q9JC5hnKNa6Gg=="],@@ -176,10 +167,6 @@"@formatjs/intl-localematcher": ["@formatjs/[email protected]", "", { "dependencies": { "tslib": "^2.8.0" } }, "sha512-XOMO2Hupl0wdd172Y06h6kLpBz6Dv+J4okPLl4LPtzbr8f66WbIoy4ev98EBuZ6ZK4h5ydTN6XneT4QVpD7cdA=="],- "@heroui/react": ["@heroui/[email protected]", "", { "dependencies": { "@heroui/styles": "3.2.4", "@radix-ui/react-avatar": "1.1.11", "@react-stately/utils": "3.12.1", "@react-types/color": "3.2.0", "@react-types/shared": "3.36.1", "input-otp": "1.4.2", "tailwind-merge": "3.4.0", "tailwind-variants": "3.3.1" }, "peerDependencies": { "@react-aria/i18n": "^3.13.1", "@react-aria/ssr": "^3.10.1", "@react-aria/utils": "^3.34.1", "react": ">=19.0.0", "react-aria": "^3.51.0", "react-aria-components": "^1.20.0", "react-dom": ">=19.0.0", "tailwindcss": ">=4.0.0" } }, "sha512-ZXCTyz1G7bgCdHVxRPy4vIRI/wdb0ZvzEUJGG7CAEp0zqQsKrTH1o9i3Ns8yM6EidtAyfMosULN29gFA3wegBA=="],-- "@heroui/styles": ["@heroui/[email protected]", "", { "dependencies": { "tailwind-variants": "3.3.1", "tw-animate-css": "1.4.0" }, "peerDependencies": { "tailwindcss": ">=4.0.0" } }, "sha512-tjiT7VFUSjw7TA6ZjeT+D3oX62+D27l7dhPwW+emwPnkdkRoKALFJEPBsxpmEI/x18uNkKFIoTk85bICyOO8Vg=="],-"@hono/node-server": ["@hono/[email protected]", "", { "peerDependencies": { "hono": "^4" } }, "sha512-ELuehkj5VCBdgEw9zs+ivkKwyzzUCSQuE96YmiPvn1ECBoZCczbFXJLeEGMTYjphP6gydh4pHMqEYPVMYUVgQg=="],"@img/colour": ["@img/[email protected]", "", {}, "sha512-Td76q7j57o/tLVdgS746cYARfSyxk8iEfRxewL9h4OMzYhbW4TAcppl0mT4eyqXddh6L/jwoM75mo7ixa/pCeQ=="],@@ -266,40 +253,12 @@"@phreshos/react-ui": ["@phreshos/[email protected]", "", { "dependencies": { "react-aria-components": "^1.20.0" }, "peerDependencies": { "@phreshos/core": "^0.1.15", "react": "^19.2.0", "react-dom": "^19.2.0" } }, "sha512-b3QC9cjYNKeEettVpat2UkmxvR0gvYz7ViAZEoG7mgIQvdOPTOgJP6QQj21U3Pwaz5xEAy/y/0qqewFNAqJYKQ=="],- "@radix-ui/react-avatar": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/react-context": "1.1.3", "@radix-ui/react-primitive": "2.1.4", "@radix-ui/react-use-callback-ref": "1.1.1", "@radix-ui/react-use-is-hydrated": "0.1.0", "@radix-ui/react-use-layout-effect": "1.1.1" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react", "@types/react-dom"] }, "sha512-0Qk603AHGV28BOBO34p7IgD5m+V5Sg/YovfayABkoDDBM5d3NCx0Mp4gGrjzLGes1jV5eNOE1r3itqOR33VC6Q=="],-- "@radix-ui/react-compose-refs": ["@radix-ui/[email protected]", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-z4eqJvfiNnFMHIIvXP3CY57y2WJs5g2v3X0zm9mEJkrkNv4rDxu+sg9Jh8EkXyeqBkB7SOcboo9dMVqhyrACIg=="],-- "@radix-ui/react-context": ["@radix-ui/[email protected]", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-ieIFACdMpYfMEjF0rEf5KLvfVyIkOz6PDGyNnP+u+4xQ6jny3VCgA4OgXOwNx2aUkxn8zx9fiVcM8CfFYv9Lxw=="],-- "@radix-ui/react-primitive": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/react-slot": "1.2.4" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react", "@types/react-dom"] }, "sha512-9hQc4+GNVtJAIEPEqlYqW5RiYdrr8ea5XQ0ZOnD6fgru+83kqT15mq2OCcbe8KnjRZl5vF3ks69AKz3kh1jrhg=="],-- "@radix-ui/react-slot": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-Jl+bCv8HxKnlTLVrcDE8zTMJ09R9/ukw4qBs/oZClOfoQk/cOTbDn+NceXfV7j09YPVQUryJPHurafcSg6EVKA=="],-- "@radix-ui/react-use-callback-ref": ["@radix-ui/[email protected]", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-FkBMwD+qbGQeMu1cOHnuGB6x4yzPjho8ap5WtbEJ26umhgqVXbhekKUQO+hZEL1vU92a3wHwdp0HAcqAUF5iDg=="],-- "@radix-ui/react-use-is-hydrated": ["@radix-ui/[email protected]", "", { "dependencies": { "use-sync-external-store": "^1.5.0" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-U+UORVEq+cTnRIaostJv9AGdV3G6Y+zbVd+12e18jQ5A3c0xL03IhnHuiU4UV69wolOQp5GfR58NW/EgdQhwOA=="],-- "@radix-ui/react-use-layout-effect": ["@radix-ui/[email protected]", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-RbJRS4UWQFkzHTTwVymMTUv8EqYhOp8dOOviLj2ugtTiXRaRQS7GLGxZTLL1jWhMeoSCf5zmcZkqTl9IiYfXcQ=="],-- "@react-aria/color": ["@react-aria/[email protected]", "", { "dependencies": { "@swc/helpers": "^0.5.0", "react-aria": "^3.48.0" }, "peerDependencies": { "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1", "react-dom": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1" } }, "sha512-v/pZh1yBNeayQ5Kio0xRIX0gBf6uu+KjCRW4QSydTyRpmhvk6sMzHT9i9/vIMdaDHaYHBXlXF+Tp/mvS9CG4Zw=="],-"@react-aria/i18n": ["@react-aria/[email protected]", "", { "dependencies": { "@internationalized/date": "^3.12.1", "@internationalized/message": "^3.1.9", "@internationalized/string": "^3.2.8", "@swc/helpers": "^0.5.0", "react-aria": "^3.48.0" }, "peerDependencies": { "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1", "react-dom": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1" } }, "sha512-z56ZYcbfpNmMyiGLhyEjytpmEfoTlBaksk84q4kds3HvNkf7QWKj+DJVfVDrJX+c1LyuBsszLSX7yxJRiHsYKQ=="],"@react-aria/ssr": ["@react-aria/[email protected]", "", { "dependencies": { "@swc/helpers": "^0.5.0", "react-aria": "^3.48.0" }, "peerDependencies": { "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1", "react-dom": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1" } }, "sha512-jn038/ZYmu6DpfXJ6r2U9zFFppjbc9wnApPJSCxao2RZVEqep4YyoniHSy8qv6V21/xyS4IV7W9a+X2jOjSuag=="],"@react-aria/utils": ["@react-aria/[email protected]", "", { "dependencies": { "@swc/helpers": "^0.5.0", "react-aria": "^3.48.0", "react-stately": "^3.46.0" }, "peerDependencies": { "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1", "react-dom": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1" } }, "sha512-H6+rGZL+0f58bBNaUMfctEnT+NogqwAk+nHiB8sR3K+YlQ37GTuCijy2U/pPvQtFMS5mURrjZeBH5JNNXsx14A=="],- "@react-spectrum/color": ["@react-spectrum/[email protected]", "", { "dependencies": { "@adobe/react-spectrum": "^3.47.0", "@swc/helpers": "^0.5.0", "react-stately": "^3.46.0" }, "peerDependencies": { "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1", "react-dom": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1" } }, "sha512-FbB+GaVufsN+obNJmUAe8XGZTeJjEWvEf/k/7nxDxoDCBdg/o6eEPONAZyID5Dj1f8BZKNym8VURxDZx7IIyuQ=="],-- "@react-spectrum/provider": ["@react-spectrum/[email protected]", "", { "dependencies": { "@adobe/react-spectrum": "^3.47.0", "@swc/helpers": "^0.5.0" }, "peerDependencies": { "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1", "react-dom": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1" } }, "sha512-TsoNdVdmlQ7L+75ILq5Yb3+wp/I1AtIeat0o+Y+ZBxP+TtWpwT1ZtCB5l3cplFVzHzOpZlzO0VaDrDP9ElGYDw=="],-- "@react-stately/color": ["@react-stately/[email protected]", "", { "dependencies": { "@swc/helpers": "^0.5.0", "react-stately": "^3.46.0" }, "peerDependencies": { "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1", "react-dom": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1" } }, "sha512-v4YlLa/oRQpPa/M9Yq1e0Bl8Z7xzGZdNDAIbfIMZuiJtacaOKriPW+AOgjjT/Ab0fNX2YDbwIYvkiMOJBnTi5A=="],-- "@react-stately/utils": ["@react-stately/[email protected]", "", { "dependencies": { "@swc/helpers": "^0.5.0", "react-stately": "^3.46.0" }, "peerDependencies": { "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1", "react-dom": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1" } }, "sha512-NqKfzrknpfwiewx7R2vk1P+CneClInPDsIhw15+jOcUYSEfej0nta4cJywuKQJ2gsPwqX/ojDNixedCve9FWGw=="],-- "@react-types/color": ["@react-types/[email protected]", "", { "dependencies": { "@react-aria/color": "^3.2.0", "@react-spectrum/color": "^3.2.0", "@react-stately/color": "^3.10.0" }, "peerDependencies": { "@react-spectrum/provider": "^3.0.0", "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1", "react-dom": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1" } }, "sha512-beV3vz80nzZ1EuYUM7296Kyi3AHcMrbQw0qub/9yzHWVTKKc5sy/e4dCMKcWL/ArkeAyc7jDOiui190RQ4l0Fw=="],-"@react-types/shared": ["@react-types/[email protected]", "", { "peerDependencies": { "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1" } }, "sha512-AzsuD9OfxTOZMMvTRhlN3oHBwOmFN7tDh27LzqmHt4+uOgPhJT7ZM7/kVs/8/o0WxayMUIk3hBmCFRHv1FUoag=="],"@rolldown/binding-android-arm64": ["@rolldown/[email protected]", "", { "os": "android", "cpu": "arm64" }, "sha512-jHC2cnyKz5xU2fhECtFl8OZ83cYNt13GZQD+0uMJ/X3o+ijmd56okHhTUwxVSHPx1IRVIJEZ1/1pPzeLCU6XKA=="],@@ -334,10 +293,6 @@"@rolldown/pluginutils": ["@rolldown/[email protected]", "", {}, "sha512-2j9bGt5Jh8hj+vPtgzPtl72j0yRxHAyumoo6TNfAjsLB04UtpSvPbPcDcBMxz7n+9CYB0c1GxQFxYRg2jimqGw=="],- "@spectrum-icons/ui": ["@spectrum-icons/[email protected]", "", { "dependencies": { "@adobe/react-spectrum-ui": "1.2.1", "@babel/runtime": "^7.24.4", "@swc/helpers": "^0.5.0" }, "peerDependencies": { "@adobe/react-spectrum": "^3.47.0", "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1", "react-dom": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1" } }, "sha512-veQymocUYo5OciXQajSailOdbWe+k6+2ehfF8D4d0V923D4xOUadtT253xXZ5vEQjPat6Kyp2WDKeQNjd7kL1w=="],-- "@spectrum-icons/workflow": ["@spectrum-icons/[email protected]", "", { "dependencies": { "@adobe/react-spectrum-workflow": "2.3.5", "@swc/helpers": "^0.5.0" }, "peerDependencies": { "@adobe/react-spectrum": "^3.47.0", "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1", "react-dom": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1" } }, "sha512-kDF+/EbFVyLGytotqqdYt4uSij4j/PQmDQO5km/C6DyzKjyuic3FnSBFinR+mA6oFv1OjMcLvrrDBqK3wbqRlA=="],-"@swc/helpers": ["@swc/[email protected]", "", { "dependencies": { "tslib": "^2.8.0" } }, "sha512-5lSsMOTXURePglDfvuAQUqkGek9Hg2kksOYay2m0+XR++b2NWYL/4sWyuvVBIs8oKnJaxkdi9whaL/sqN13afw=="],"@tailwindcss/node": ["@tailwindcss/[email protected]", "", { "dependencies": { "@jridgewell/remapping": "^2.3.5", "enhanced-resolve": "^5.24.1", "jiti": "^2.7.0", "lightningcss": "1.32.0", "magic-string": "^0.30.21", "source-map-js": "^1.2.1", "tailwindcss": "4.3.3" } }, "sha512-/T8IKEsf9VTU6tLjgC7+sv2mOPtQxzE2jMw7u4Tt40Tx+QSZxpzh95/H6cMKoja9XuW7iMdLJYBB0o9G1CaAgg=="],@@ -414,8 +369,6 @@"detect-libc": ["[email protected]", "", {}, "sha512-Btj2BOOO83o3WyH59e8MgXsxEQVcarkUOpEYrubB0urwnN10yQ364rsiByU11nZlqWYZm05i/of7io4mzihBtQ=="],- "dom-helpers": ["[email protected]", "", { "dependencies": { "@babel/runtime": "^7.8.7", "csstype": "^3.0.2" } }, "sha512-nRCa7CK3VTrM2NmGkIy4cbK7IZlgBE/PYMn55rrXefr5xXDP0LdtfPnblFDoVdcAfslJ7or6iqAUnx0CCGIWQA=="],-"electron-to-chromium": ["[email protected]", "", {}, "sha512-ChI4N44d0B4A6C8prnNjMOaGgE59fUyEVYcRYm2XEXIjMbbvF5i9UL1cblDbpGqiU0uS8FE8UcKxqZqTXdmzbQ=="],"enhanced-resolve": ["[email protected]", "", { "dependencies": { "graceful-fs": "^4.2.4", "tapable": "^2.3.3" } }, "sha512-L1l8TNvomm6UVW5B253AGxQagSQr+vGwhMlrrfRS2qmhx46AMpMVJKQYLvWYbysTMY8VoicOvzHzoHMbyzB+4A=="],@@ -446,8 +399,6 @@"hono": ["[email protected]", "", {}, "sha512-r8AO2mYHoLxSHkgafNeC/BXyb2vWRxD3jem4Ts+ptav8oTG5FIRifAjuJEmZI4bSvvc2ns0GxmIYiZnHqN3mMw=="],- "input-otp": ["[email protected]", "", { "peerDependencies": { "react": "^16.8 || ^17.0 || ^18.0 || ^19.0.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0.0 || ^19.0.0-rc" } }, "sha512-l3jWwYNvrEa6NTCt7BECfCm48GvwuZzkoeG3gBL2w4CHeOXW3eKFmf9UNYkNfYc3mxMrthMnxjIE07MT0zLBQA=="],-"intl-messageformat": ["[email protected]", "", { "dependencies": { "@formatjs/ecma402-abstract": "2.3.6", "@formatjs/fast-memoize": "2.2.7", "@formatjs/icu-messageformat-parser": "2.11.4", "tslib": "^2.8.0" } }, "sha512-m3Ofv/X/tV8Y3tHXLohcuVuhWKo7BBq62cqY15etqmLxg2DZ34AGGgQDeR+SCta2+zICb1NX83af0GJmbQ1++g=="],"is-accessor-descriptor": ["[email protected]", "", { "dependencies": { "hasown": "^2.0.3" } }, "sha512-AIbwAcazqP3R65dGvqk1V+a+vE5Fg1yu/ZKMOiBWSUIXXiwQkYmXQcVa2O0nh0tSDKDFKxG2mY7dB1Sr4hEP1g=="],@@ -496,8 +447,6 @@"lightningcss-win32-x64-msvc": ["[email protected]", "", { "os": "win32", "cpu": "x64" }, "sha512-OlEICDx/Xl0FqSp4bry8zFnCvGpig3Gl4gCquvYwHuqJKEC1+n9NgDniFvqHGmMv1ZkqDJrDqKKSykTDX+ehuA=="],- "loose-envify": ["[email protected]", "", { "dependencies": { "js-tokens": "^3.0.0 || ^4.0.0" }, "bin": { "loose-envify": "cli.js" } }, "sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q=="],-"lru-cache": ["[email protected]", "", { "dependencies": { "yallist": "^3.0.2" } }, "sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w=="],"magic-string": ["[email protected]", "", { "dependencies": { "@jridgewell/sourcemap-codec": "^1.5.5" } }, "sha512-vd2F4YUyEXKGcLHoq+TEyCjxueSeHnFxyyjNp80yg0XV4vUhnDer/lvvlqM/arB5bXQN5K2/3oinyCRyx8T2CQ=="],@@ -506,14 +455,10 @@"nanoid": ["[email protected]", "", { "bin": { "nanoid": "bin/nanoid.cjs" } }, "sha512-DTg4MJbGMWkfi6VZFdNt2/caMbQy4Ou+Op/hJQvGEWcnVfoA1QA+xzRKAzw9jD6+GVOOeYr/mIcuDSdug6F6+w=="],- "next-themes": ["[email protected]", "", { "peerDependencies": { "react": "^16.8 || ^17 || ^18 || ^19 || ^19.0.0-rc", "react-dom": "^16.8 || ^17 || ^18 || ^19 || ^19.0.0-rc" } }, "sha512-pZvgD5L0IEvX5/9GWyHMf3m8BKiVQwsCMHfoFosXtXBMnaS0ZnIJ9ST4b4NqLVKDEm8QBxoNNGNaBv2JNF6XNA=="],-"node-releases": ["[email protected]", "", {}, "sha512-D9UOmYG3UH1V+ENW56t5QXBwJw1YEY18ruVeus89Rw+SyIgjPkCO84bRzO3uNIYosJbNwiabWVn48o3uJLjxFQ=="],"node-rsa": ["[email protected]", "", { "dependencies": { "@noble/hashes": "^2.2.0" } }, "sha512-7yfzccmBd5rm7pALJf709tPwLL987WvdT7LC/QK5Oxa5S2aabdBPjxRDxhWKkbfCc9/FiC82lwSc+ulGZHH44g=="],- "object-assign": ["[email protected]", "", {}, "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg=="],-"obug": ["[email protected]", "", {}, "sha512-4a+OsYv9UktOJKE+l1A4OufDgdRF9PifWj+tJnHURo/P+WOxpG4GzUFL9qCalmWauao6ogiG+QvnCovwPoyAWA=="],"pathe": ["[email protected]", "", {}, "sha512-WUjGcAqP1gQacoQe+OBJsFA7Ld4DyXuUIjZ5cc75cLHvJ7dtNsTugphxIADwspS+AraAUePCKrSVtPLFj/F88w=="],@@ -524,8 +469,6 @@"postcss": ["[email protected]", "", { "dependencies": { "nanoid": "^3.3.17", "picocolors": "^1.1.1", "source-map-js": "^1.2.1" } }, "sha512-u82N74LFzG8ca+dD8puPnplTXoGH4fTPpVGuIbt36G3qvNlkvfD0lEAZSxaly3KX8TS/L1A1gsCEmvKmBcVbkQ=="],- "prop-types": ["[email protected]", "", { "dependencies": { "loose-envify": "^1.4.0", "object-assign": "^4.1.1", "react-is": "^16.13.1" } }, "sha512-oj87CgZICdulUohogVAR7AjlC0327U4el4L6eAvOqCeudMDVU0NThNaV+b9Df4dXgSP1gXMTnPdhfe/2qDH5cg=="],-"react": ["[email protected]", "", {}, "sha512-PWaYA1L/q9u2u7xYQi+Y3L3Yfnie7XyLeaJICV1MGD6LprsBxcAqGjYyr0eY3p+QdsA+x/Irkt4Qif8D63+Sbw=="],"react-aria": ["[email protected]", "", { "dependencies": { "@internationalized/date": "^3.12.3", "@internationalized/number": "^3.6.7", "@internationalized/string": "^3.2.10", "@react-types/shared": "^3.36.1", "@swc/helpers": "^0.5.0", "aria-hidden": "^1.2.3", "clsx": "^2.0.0", "react-stately": "3.49.0", "use-sync-external-store": "^1.6.0" }, "peerDependencies": { "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1", "react-dom": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1" } }, "sha512-AyWLw0XR38cFPwBu/ErgGaVrc5dupLEKmRlMXTGvFKOtbaGRQ2+yQJkjVhpdHhoRhU4+G+tJDFeHDTS8tK3bfQ=="],@@ -534,12 +477,8 @@"react-dom": ["[email protected]", "", { "dependencies": { "scheduler": "^0.27.0" }, "peerDependencies": { "react": "^19.2.8" } }, "sha512-rVprimfGBG3DR+Tq0IQG2DT5PxKth1WIGDmj5yPmlzr4YBe7uyE+Du4oVqTDXZSHGGGXRtTJEGSSePyQCMBglQ=="],- "react-is": ["[email protected]", "", {}, "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ=="],-"react-stately": ["[email protected]", "", { "dependencies": { "@internationalized/date": "^3.12.3", "@internationalized/number": "^3.6.7", "@internationalized/string": "^3.2.10", "@react-types/shared": "^3.36.1", "@swc/helpers": "^0.5.0", "use-sync-external-store": "^1.6.0" }, "peerDependencies": { "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1" } }, "sha512-13iNq2KzBrRAzxRc+n53hgROfIistiYY/sPtIhCw1qUB7/kmo+X1xEU2uiS5zcCIrc55AUPwoHqOIIpKWSwB9A=="],- "react-transition-group": ["[email protected]", "", { "dependencies": { "@babel/runtime": "^7.5.5", "dom-helpers": "^5.0.1", "loose-envify": "^1.4.0", "prop-types": "^15.6.2" }, "peerDependencies": { "react": ">=16.6.0", "react-dom": ">=16.6.0" } }, "sha512-pZcd1MCJoiKiBR2NRxeCRg13uCXbydPnmB4EOeRrY7480qNWO8IIgQG6zlDkm6uRMsURXPuKq0GWtiM59a5Q6g=="],-"rolldown": ["[email protected]", "", { "dependencies": { "@oxc-project/types": "=0.144.0", "@rolldown/pluginutils": "^1.0.0" }, "optionalDependencies": { "@rolldown/binding-android-arm64": "1.2.4", "@rolldown/binding-darwin-arm64": "1.2.4", "@rolldown/binding-darwin-x64": "1.2.4", "@rolldown/binding-freebsd-x64": "1.2.4", "@rolldown/binding-linux-arm-gnueabihf": "1.2.4", "@rolldown/binding-linux-arm64-gnu": "1.2.4", "@rolldown/binding-linux-arm64-musl": "1.2.4", "@rolldown/binding-linux-ppc64-gnu": "1.2.4", "@rolldown/binding-linux-s390x-gnu": "1.2.4", "@rolldown/binding-linux-x64-gnu": "1.2.4", "@rolldown/binding-linux-x64-musl": "1.2.4", "@rolldown/binding-openharmony-arm64": "1.2.4", "@rolldown/binding-win32-arm64-msvc": "1.2.4", "@rolldown/binding-win32-x64-msvc": "1.2.4" }, "bin": { "rolldown": "./bin/cli.mjs" } }, "sha512-rSr7irW0K7QRWzjdJXqZowkcRdDtjRduh43rBltnVKd0VFq839l1lJoDvGJb6gl7+4rTTCrPWu+YfujUL8Ug7w=="],"scheduler": ["[email protected]", "", {}, "sha512-eNv+WrVbKu1f3vbYJT/xtiF5syA5HPIMtf9IgY/nKg0sWqzAUEvqY/xm7OcZc/qafLx/iO9FgOmeSAp4v5ti/Q=="],@@ -552,10 +491,6 @@"supports-color": ["[email protected]", "", { "dependencies": { "has-flag": "^4.0.0" } }, "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q=="],- "tailwind-merge": ["[email protected]", "", {}, "sha512-uSaO4gnW+b3Y2aWoWfFpX62vn2sR3skfhbjsEnaBI81WD1wBLlHZe5sWf0AqjksNdYTbGBEd0UasQMT3SNV15g=="],-- "tailwind-variants": ["[email protected]", "", { "peerDependencies": { "tailwind-merge": ">=3.0.0", "tailwindcss": "*" }, "optionalPeers": ["tailwind-merge", "tailwindcss"] }, "sha512-4pAvwUtM4HKBiRZftncAbpn6V9Hhwoa5Fl7O2u5zbp7Z5Cvu+/o/6+176WY3WCEES209543quG8zFIcXCsc5Jw=="],-"tailwindcss": ["[email protected]", "", {}, "sha512-gOhV3P7ufE62QDGg1zVaTgCR+EtPv92k2nIhVcVKcLmxT1sUBsQGhnZj175j+MqRt4zLF7ic+sCYjfhxMxj7YQ=="],"tapable": ["[email protected]", "", {}, "sha512-uxc/zpqFg6x7C8vOE7lh6Lbda8eEL9zmVm/PLeTPBRhh1xCgdWaQ+J1CUieGpIfm2HdtsUpRv+HshiasBMcc6A=="],@@ -566,8 +501,6 @@"tsx": ["[email protected]", "", { "dependencies": { "esbuild": "~0.28.0" }, "optionalDependencies": { "fsevents": "~2.3.3" }, "bin": { "tsx": "dist/cli.mjs" } }, "sha512-FDf4L4sYzKtzWYhU/Xm0AQFdTjdIxNo9ElTf2mxXM6k8YMHXzYUe4yODVaXP4V9uMFbVg8c0qyBccK2OOxb45Q=="],- "tw-animate-css": ["[email protected]", "", {}, "sha512-7bziOlRqH0hJx80h/3mbicLW7o8qLsH5+RaLR2t+OHM3D0JlWGODQKQ4cxbK7WlvmUxpcj6Kgu6EKqjrGFe3QQ=="],-"typescript": ["[email protected]", "", { "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" } }, "sha512-y2TvuxSZPDyQakkFRPZHKFm+KKVqIisdg9/CZwm9ftvKXLP8NRWj38/ODjNbr43SsoXqNuAisEf1GdCxqWcdBw=="],"undici-types": ["[email protected]", "", {}, "sha512-WRNW+sJgj5OBN4/0JpHFqtqzhpbnV0GuB+OozA9gCL7a993SmU+1JBZCzLNxYsbMfIeDL+lTsphD5jN5N+n0zg=="],diff --git a/package.json b/package.jsonindex e219bbf..8991986 100644--- a/package.json+++ b/package.json@@ -36,8 +36,6 @@},"dependencies": {"@fontsource/roboto": "^5.3.0",- "@heroui/react": "3.2.4",- "@heroui/styles": "3.2.4","@hono/node-server": "^2.1.1","@msgpack/msgpack": "^3.1.3","@react-aria/i18n": "^3.13.1",@@ -48,7 +46,6 @@"gsap": "^3.15.0","hono": "^4.13.2","keyv": "^5.6.0",- "next-themes": "0.4.6","node-rsa": "^2.0.0","react": "^19.2.8","react-aria": "^3.51.0",diff --git a/source/client/main.ts b/source/client/main.tsindex fe1397c..79c73c7 100644--- a/source/client/main.ts+++ b/source/client/main.ts@@ -1,5 +1,5 @@import { displayName, name, version } from "@/package.json"import doors from "@server/view/doors"-import view from "./view2/view"+import view from "./view/view"view({ name, displayName, version, doors, document })diff --git a/source/client/view/appearance/appearance.css b/source/client/view/appearance/appearance.cssindex 2e5e656..8a09c5e 100644--- a/source/client/view/appearance/appearance.css+++ b/source/client/view/appearance/appearance.css@@ -13,7 +13,7 @@--text-taskbar-status: 0.625rem;- --spacing-taskbar: 3.125rem;+ --spacing-taskbar: 2.75rem;--shadow-taskbar: 0 20px 40px -16px rgba(12, 30, 60, 0.45);diff --git a/source/client/view/appearance/appearance.tsx b/source/client/view/appearance/appearance.tsxindex ade9b63..e65b911 100644--- a/source/client/view/appearance/appearance.tsx+++ b/source/client/view/appearance/appearance.tsx@@ -9,11 +9,7 @@ export default function ({ children, reducedMotion }: AppearanceProps) {<div className="relative isolate grid h-dvh overflow-hidden font-roboto" style={{ backgroundColor: standardTheme.background }}>- <div className="relative grid min-h-0">-- {children}-- </div>+ {children}</div>diff --git a/source/client/view/components/desktop-host/client-host.ts b/source/client/view/components/desktop-host/client-host.tsindex 00333d2..89baf6e 100644--- a/source/client/view/components/desktop-host/client-host.ts+++ b/source/client/view/components/desktop-host/client-host.ts@@ -17,7 +17,7 @@ import messagepack from "@libs/messagepack"*/export default function useClientHost(authManager: AuthManager, desktop: RefObject<HTMLDivElement | null>, sources: Map<string, HTMLIFrameElement | null>, localWindow: LocalWindowHost) {- const windowSurfaceRef = useRef<HTMLElement>(null)+ const windowSurfaceRef = useRef<HTMLDivElement>(null)const frameOwners = useRef(new Map<string, string>())diff --git a/source/client/view/components/loading.tsx b/source/client/view/components/loading.tsxindex a242f61..d696d6c 100644--- a/source/client/view/components/loading.tsx+++ b/source/client/view/components/loading.tsx@@ -12,8 +12,8 @@ interface LoadingProps extends ComponentProps<"div"> {blur?: boolean}-/** A loading surface that obscures unresolved content, with blur by default. */-export default function ({ blur = true, className, ...props }: LoadingProps) {+/** A loading surface that obscures unresolved content. Blur is explicitly opt-in. */+export default function ({ blur = false, className, ...props }: LoadingProps) {return <divdiff --git a/source/client/view/components/program-access.tsx b/source/client/view/components/program-access.tsxindex 29ce905..8dbc0a7 100644--- a/source/client/view/components/program-access.tsx+++ b/source/client/view/components/program-access.tsx@@ -101,17 +101,17 @@ export const blockedProgramDocument = `<!doctype html>:root { color-scheme: light; font-family: system-ui, sans-serif; color: #233548; background: #eef8ff; }* { box-sizing: border-box; }body { min-height: 100vh; margin: 0; display: grid; place-items: center; padding: 2rem; background: radial-gradient(circle at top left, #ffffff 0, #eef8ff 48%, #dff4ff 100%); }- main { width: min(34rem, 100%); padding: 1.5rem; border: 1px solid rgba(89, 151, 191, .28); border-radius: 1.25rem; background: rgba(255, 255, 255, .82); box-shadow: 0 1.25rem 3rem rgba(47, 104, 145, .15); }+ .message { width: min(34rem, 100%); padding: 1.5rem; border: 1px solid rgba(89, 151, 191, .28); border-radius: 1.25rem; background: rgba(255, 255, 255, .82); box-shadow: 0 1.25rem 3rem rgba(47, 104, 145, .15); }h1 { margin: 0 0 .75rem; font-size: 1.35rem; }p { margin: 0; line-height: 1.6; }p + p { margin-top: .8rem; color: #526b7f; font-size: .92rem; }</style></head><body>-<main>+<div class="message"><h1>This Program cannot load</h1><p>The desktop is connected, but this hosting server blocks requests made by isolated Program frames.</p><p>Configure the server or reverse proxy to preserve the CORS headers on <code>/program/*</code>, including requests whose origin is <code>null</code>, then reload the desktop.</p>-</main>+</div></body></html>`diff --git a/source/client/view/components/window-manager/window-geometry.ts b/source/client/view/components/window-manager/window-geometry.tsindex 58267ee..c4dc654 100644--- a/source/client/view/components/window-manager/window-geometry.ts+++ b/source/client/view/components/window-manager/window-geometry.ts@@ -1,5 +1,4 @@import { parseRelativeValue, type Position, type RelativeValue, type Size, type Value } from "@phreshos/core"-import { windowPaintInset } from "../../desktop/geometry"export interface WindowRegion {@@ -66,7 +65,7 @@ export function resolveWindowGeometry(position: Position, size: Size, surface: W* on edges that do not touch that box's containing surface. Snap previews use* this same function, so preview and final paint cannot disagree.*/-export function windowPaintInsets(position: Position, size: Size, surface: WindowSurfaceSize, current?: WindowRegion) {+export function windowPaintInsets(position: Position, size: Size, surface: WindowSurfaceSize, inset: number, current?: WindowRegion) {const x = current?.x ?? pixels(position.x, surface.width)@@ -78,13 +77,13 @@ export function windowPaintInsets(position: Position, size: Size, surface: Windoreturn {- top: startsAtBoundary(position.y, y, surface.height) ? 0 : windowPaintInset,+ top: startsAtBoundary(position.y, y, surface.height) ? 0 : inset,- right: endsAtBoundary(position.x, size.width, x, width, surface.width) ? 0 : windowPaintInset,+ right: endsAtBoundary(position.x, size.width, x, width, surface.width) ? 0 : inset,- bottom: endsAtBoundary(position.y, size.height, y, height, surface.height) ? 0 : windowPaintInset,+ bottom: endsAtBoundary(position.y, size.height, y, height, surface.height) ? 0 : inset,- left: startsAtBoundary(position.x, x, surface.width) ? 0 : windowPaintInset+ left: startsAtBoundary(position.x, x, surface.width) ? 0 : inset}}diff --git a/source/client/view/desktop/geometry.ts b/source/client/view/desktop/geometry.tsdeleted file mode 100644index 8fe0613..0000000--- a/source/client/view/desktop/geometry.ts+++ /dev/null@@ -1,68 +0,0 @@-import { type CSSProperties } from "react"--/**- * The gap between adjacent painted windows, in pixels. Each window uses- * half inside its own box; the ordinary workspace uses the other half- * at its boundary. The gutter remains private desktop layout state and never- * enters the layer-independent value returned by `host.desktop.size()`.- *- * The visible window edge, taskbar edge and Start Menu geometry derive from- * this value rather than restating its pixel or rem equivalent.- */-export const desktopGutter = 12--/** Paint inset for an ordinary window edge that touches no workspace boundary. */-export const windowPaintInset = desktopGutter / 2--/** The display core uses the same spacing between itself and its tracks. */-export const desktopDisplayStyle = {-- margin: desktopGutter,-- gap: desktopGutter--} satisfies CSSProperties--/** The shared CSS anchor joining the taskbar and its Start Menu. */-export const taskbarAnchorName = "--desktop-taskbar"--/**- * The Start Menu stays in the browser's top layer while CSS anchor positioning- * keeps its geometry attached to the taskbar.- */-export const startMenuStyle = {-- positionAnchor: taskbarAnchorName,-- top: "auto",-- right: "auto",-- bottom: `calc(anchor(top) + ${desktopGutter}px)`,-- left: "anchor(left)",-- maxHeight: `min(32rem, calc(100vh - var(--spacing-taskbar) - ${desktopGutter * 3}px))`,-- width: `min(22rem, calc(100vw - ${desktopGutter * 2}px))`--} satisfies CSSProperties--/** System dialogs share the Start Menu's taskbar offset and center on it. */-export const systemDialogStyle = {-- positionAnchor: taskbarAnchorName,-- top: "auto",-- right: "auto",-- bottom: `calc(anchor(top) + ${desktopGutter}px)`,-- left: "anchor(center)",-- translate: "-50% 0",-- width: `min(28rem, calc(100vw - ${desktopGutter * 2}px))`--} satisfies CSSPropertiesdiff --git a/source/client/view/desktop/start-menu/programs-section.tsx b/source/client/view/desktop/start-menu/programs-section.tsxdeleted file mode 100644index 48f53c3..0000000--- a/source/client/view/desktop/start-menu/programs-section.tsx+++ /dev/null@@ -1,48 +0,0 @@-import LauncherItem from "../taskbar/launcher-item"-import programIcon from "../programs/program-icon"-import usePrograms from "../programs/programs"-import { ApplicationContext } from "../../contexts"--interface ProgramsSectionProps {-- onChoose: () => void-}--/** The installed-program section of the Start Menu. */-export default function ProgramsSection({ onChoose }: ProgramsSectionProps) {-- const application = ApplicationContext.useValue()-- const programs = usePrograms()-- return <section aria-label="Programs" className="grid gap-1">-- {programs.length-- ? programs.map(record => <LauncherItem-- key={record.identity}-- label={record.name}-- icon={programIcon(application.doors.program, record.assetId)}-- description={record.description}-- onClick={() => {-- onChoose()-- record.createProcess().catch(console.error)- }}-- >-- {record.name}-- </LauncherItem>)-- : <p className="px-3 py-8 text-center text-sm text-slate-600">No installed programs</p>}-- </section>-}diff --git a/source/client/view/desktop/session/session.tsx b/source/client/view/structure/authentication/authentication.tsxsimilarity index 95%rename from source/client/view/desktop/session/session.tsxrename to source/client/view/structure/authentication/authentication.tsxindex 8ac262e..2c0087c 100644--- a/source/client/view/desktop/session/session.tsx+++ b/source/client/view/structure/authentication/authentication.tsx@@ -4,13 +4,13 @@ import Alert from "../../components/alert"import usePromise from "@libs/react-promise"import useStorage from "@libs/storage-hook"import useCleanup from "@libs/cleanup-hook"-import Workspace from "../workspace"+import Desktop from "../desktop/desktop"import SignIn from "./sign-in"import Register from "./register"import { useState, type ReactNode } from "react"import { type AuthenticationState } from "@server/core/authentication/authentication"import useProperty from "@libs/the-link/plugins/react-helper/property-hook"-import { WallpaperStage } from "../../components/wallpaper"+import { WallpaperStage } from "../desktop/wallpaper/wallpaper"import { useReady } from "@libs/readiness/main"export default function () {@@ -75,7 +75,7 @@ export default function () {<AuthManagerContext.Provider value={sessionAuthenticate.solve.authManager}>- <Workspace />+ <Desktop /></AuthManagerContext.Provider>diff --git a/source/client/view/desktop/session/credentials-form.tsx b/source/client/view/structure/authentication/credentials-form.tsxsimilarity index 93%rename from source/client/view/desktop/session/credentials-form.tsxrename to source/client/view/structure/authentication/credentials-form.tsxindex 058cc62..954039e 100644--- a/source/client/view/desktop/session/credentials-form.tsx+++ b/source/client/view/structure/authentication/credentials-form.tsx@@ -5,7 +5,7 @@ import { Surface, useTheme } from "@phreshos/react-ui"import { numericScale } from "@phreshos/core"import { obscuredBackground } from "../../components/loading"import Alert from "../../components/alert"-import { type FormEvent, useLayoutEffect, useRef } from "react"+import { type SyntheticEvent, useLayoutEffect, useRef } from "react"/** The common username-and-password surface for registration and sign-in. */export default function CredentialsForm({ title, description, submitLabel, passwordAutocomplete, requirements, error, onSubmit }: CredentialsFormProps) {@@ -35,7 +35,7 @@ export default function CredentialsForm({ title, description, submitLabel, passw}, [reducedMotion])- function submit(event: FormEvent<HTMLFormElement>) {+ function submit(event: SyntheticEvent<HTMLFormElement, SubmitEvent>) {event.preventDefault()@@ -58,15 +58,15 @@ export default function CredentialsForm({ title, description, submitLabel, passw>- <Surface aria-hidden="true" style={{ borderRadius: "inherit" }} className="pointer-events-none absolute inset-0" />+ <Surface aria-hidden="true" className="pointer-events-none absolute inset-0 rounded-[inherit]" />- <header className="relative grid gap-1 px-5 py-4 text-shadow-chrome">+ <div className="relative grid gap-1 px-5 py-4 text-shadow-chrome"><h1 className="text-xl font-semibold">{title}</h1><p className="text-sm leading-5 text-slate-600/90">{description}</p>- </header>+ </div><div style={{ borderRadius: innerRadius }} className="relative m-1.5 mt-0 grid gap-5 bg-white/25 p-5 shadow-window-content">diff --git a/source/client/view/desktop/session/register.tsx b/source/client/view/structure/authentication/register.tsxsimilarity index 100%rename from source/client/view/desktop/session/register.tsxrename to source/client/view/structure/authentication/register.tsxdiff --git a/source/client/view/desktop/session/sign-in.tsx b/source/client/view/structure/authentication/sign-in.tsxsimilarity index 100%rename from source/client/view/desktop/session/sign-in.tsxrename to source/client/view/structure/authentication/sign-in.tsxdiff --git a/source/client/view/desktop/desktop-display.tsx b/source/client/view/structure/desktop/desktop-display.tsxsimilarity index 50%rename from source/client/view/desktop/desktop-display.tsxrename to source/client/view/structure/desktop/desktop-display.tsxindex dda2a7e..d8ec999 100644--- a/source/client/view/desktop/desktop-display.tsx+++ b/source/client/view/structure/desktop/desktop-display.tsx@@ -7,35 +7,35 @@ import { desktopDisplayStyle } from "./geometry"*/export default function DesktopDisplay({ wallpaper, underWindows, windows, overWindows, windowSurfaceRef, taskbar }: DesktopDisplayProps) {- return <main aria-label="Desktop display" className="grid min-h-0 grid-cols-1 grid-rows-[1fr_auto]" style={desktopDisplayStyle}>+ return <div className="m-(--desktop-gutter) grid min-h-0 grid-cols-1 grid-rows-[1fr_auto] gap-(--desktop-gutter)" style={desktopDisplayStyle}>- <section aria-label="Desktop wallpaper" className="absolute inset-0 z-0 overflow-hidden">+ <div className="absolute inset-0 z-0 overflow-hidden">{wallpaper}- </section>+ </div>- <section aria-label="Under windows" className="pointer-events-none absolute inset-0 z-1 overflow-hidden">+ <div className="pointer-events-none absolute inset-0 z-1 overflow-hidden">{underWindows}- </section>+ </div>- <section ref={windowSurfaceRef} aria-label="Windows" className="pointer-events-none relative z-2">+ <div ref={windowSurfaceRef} className="pointer-events-none relative z-2">{windows}- </section>+ </div>- <section aria-label="Over windows" className="pointer-events-none absolute inset-0 z-3 overflow-hidden">+ <div className="pointer-events-none absolute inset-0 z-3 overflow-hidden">{overWindows}- </section>+ </div>{taskbar}- </main>+ </div>}interface DesktopDisplayProps {@@ -48,7 +48,7 @@ interface DesktopDisplayProps {overWindows: ReactNode- windowSurfaceRef: Ref<HTMLElement>+ windowSurfaceRef: Ref<HTMLDivElement>taskbar: ReactNode}diff --git a/source/client/view/desktop/desktop-focus.ts b/source/client/view/structure/desktop/desktop-focus.tssimilarity index 97%rename from source/client/view/desktop/desktop-focus.tsrename to source/client/view/structure/desktop/desktop-focus.tsindex c614da1..9e2dfb9 100644--- a/source/client/view/desktop/desktop-focus.ts+++ b/source/client/view/structure/desktop/desktop-focus.ts@@ -1,5 +1,5 @@import Process from "@client/core/link-manager/auth-manager/process-manager/process"-import useWindows from "../components/window-manager/window-manager"+import useWindows from "../../components/window-manager/window-manager"import { type FocusEvent, type RefObject, useCallback, useRef } from "react"/** Focus transfer between the workspace, its windows and their taskbar items. */diff --git a/source/client/view/desktop/workspace.tsx b/source/client/view/structure/desktop/desktop.tsxsimilarity index 90%rename from source/client/view/desktop/workspace.tsxrename to source/client/view/structure/desktop/desktop.tsxindex 44eabc1..89f1dd0 100644--- a/source/client/view/desktop/workspace.tsx+++ b/source/client/view/structure/desktop/desktop.tsx@@ -1,23 +1,23 @@import { type Layer } from "@server/core/link-manager/auth-manager/program-manager/config"import { type SyntheticEvent, useCallback, useEffect, useRef, useState } from "react"-import { ApplicationContext, AuthManagerContext } from "../contexts"-import useClientHost from "../components/desktop-host/client-host"+import { ApplicationContext, AuthManagerContext } from "../../contexts"+import useClientHost from "../../components/desktop-host/client-host"import DesktopDisplay from "./desktop-display"import useDesktopFocus from "./desktop-focus"import programIcon from "./programs/program-icon"-import ProgramAccessProbe, { type ProgramAccess } from "../components/program-access"-import StartMenu from "./start-menu/start-menu"-import OverflowRow from "./taskbar/overflow-row"-import SignOut from "./taskbar/sign-out"-import SystemDialogs from "./taskbar/system-dialogs"+import ProgramAccessProbe, { type ProgramAccess } from "../../components/program-access"+import StartMenu from "./taskbar/launcher/start-menu"+import OverflowRow from "./taskbar/programs/overflow-row"+import SignOut from "./taskbar/system/sign-out"+import SystemDialogs from "./taskbar/system/system-dialogs"import Taskbar from "./taskbar/taskbar"-import WindowTaskbarItem from "./taskbar/window-taskbar-item"-import ProcessWindow from "./window-manager/process-window"-import useWindows from "../components/window-manager/window-manager"+import WindowTaskbarItem from "./taskbar/programs/window-taskbar-item"+import ProcessWindow from "./windows/process-window"+import useWindows from "../../components/window-manager/window-manager"import useProperty from "@libs/the-link/plugins/react-helper/property-hook"-import { ReadyWallpaper, WallpaperBackground } from "../components/wallpaper"-import ProgramFrame from "../components/program-frame"-import Loading from "../components/loading"+import { ReadyWallpaper, WallpaperBackground } from "./wallpaper/wallpaper"+import ProgramFrame from "../../components/program-frame"+import Loading from "../../components/loading"import { useRequirement } from "@libs/readiness/main"export default function Workspace() {diff --git a/source/client/view/structure/desktop/geometry.ts b/source/client/view/structure/desktop/geometry.tsnew file mode 100644index 0000000..94f3aa6--- /dev/null+++ b/source/client/view/structure/desktop/geometry.ts@@ -0,0 +1,22 @@+import { type CSSProperties } from "react"++/**+ * The gap between adjacent painted windows, in pixels. Each window uses+ * half inside its own box; the ordinary workspace uses the other half+ * at its boundary. The gutter remains private desktop layout state and never+ * enters the layer-independent value returned by `host.desktop.size()`.+ *+ * The visible window edge, taskbar edge and Start Menu geometry derive from+ * this value rather than restating its pixel or rem equivalent.+ */+export const desktopGutter = 10++/** Paint inset for an ordinary window edge that touches no workspace boundary. */+export const windowPaintInset = desktopGutter / 2++/** The display core uses the same spacing between itself and its tracks. */+export const desktopDisplayStyle = {++ "--desktop-gutter": `${desktopGutter}px`++} as CSSPropertiesdiff --git a/source/client/view/desktop/programs/program-icon.ts b/source/client/view/structure/desktop/programs/program-icon.tssimilarity index 100%rename from source/client/view/desktop/programs/program-icon.tsrename to source/client/view/structure/desktop/programs/program-icon.tsdiff --git a/source/client/view/desktop/programs/programs.ts b/source/client/view/structure/desktop/programs/programs.tssimilarity index 91%rename from source/client/view/desktop/programs/programs.tsrename to source/client/view/structure/desktop/programs/programs.tsindex 8518b86..3f0a84d 100644--- a/source/client/view/desktop/programs/programs.ts+++ b/source/client/view/structure/desktop/programs/programs.ts@@ -1,5 +1,5 @@import ReactTunnel from "@libs/the-link/plugins/react-helper/react-tunnel"-import { AuthManagerContext } from "../../contexts"+import { AuthManagerContext } from "../../../contexts"/*** The authorized view's programs: the list the peer re-emits on itsdiff --git a/source/client/view/desktop/taskbar/launcher-item.tsx b/source/client/view/structure/desktop/taskbar/launcher/launcher-item.tsxsimilarity index 82%rename from source/client/view/desktop/taskbar/launcher-item.tsxrename to source/client/view/structure/desktop/taskbar/launcher/launcher-item.tsxindex ccc4bf5..01139ce 100644--- a/source/client/view/desktop/taskbar/launcher-item.tsx+++ b/source/client/view/structure/desktop/taskbar/launcher/launcher-item.tsx@@ -9,7 +9,7 @@ export default function ({ icon, label, description, children, className, ...protype="button"- className={`group grid w-full grid-cols-[auto_minmax(0,1fr)] items-center gap-3 rounded-xl px-3 py-2 text-left outline-none hover:bg-white/45 focus-visible:bg-white/55 focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-white/85 active:bg-white/65 ${className ?? ""}`}+ className={`group grid w-full grid-cols-[auto_minmax(0,1fr)] items-center gap-3 rounded-xl px-3 py-2 text-start outline-none hover:bg-white/45 focus-visible:bg-white/55 focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-white/85 active:bg-white/65 ${className ?? ""}`}>diff --git a/source/client/view/desktop/taskbar/launcher.tsx b/source/client/view/structure/desktop/taskbar/launcher/launcher.tsxsimilarity index 95%rename from source/client/view/desktop/taskbar/launcher.tsxrename to source/client/view/structure/desktop/taskbar/launcher/launcher.tsxindex 35f3722..b656add 100644--- a/source/client/view/desktop/taskbar/launcher.tsx+++ b/source/client/view/structure/desktop/taskbar/launcher/launcher.tsx@@ -1,10 +1,10 @@import { ComponentProps, ReactNode, useCallback, useEffect, useId, useRef, useState } from "react"-import { enterSurface, prepareSurfaceEntrance, restSurface } from "../../appearance/surface-presence"+import { enterSurface, prepareSurfaceEntrance, restSurface } from "../../../../appearance/surface-presence"import { useReducedMotion } from "@libs/react-motion"import { useTheme } from "@phreshos/react-ui"import { numericScale } from "@phreshos/core"-import TaskbarSurface, { taskbarSurfaceClassName } from "./taskbar-surface"-import TaskbarButton from "./taskbar-button"+import TaskbarSurface, { taskbarSurfaceClassName } from "../taskbar-surface"+import TaskbarButton from "../taskbar-button"/*** A button and the dismissible surface it opens. Placement, contents anddiff --git a/source/client/view/structure/desktop/taskbar/launcher/programs-section.tsx b/source/client/view/structure/desktop/taskbar/launcher/programs-section.tsxnew file mode 100644index 0000000..0414ea1--- /dev/null+++ b/source/client/view/structure/desktop/taskbar/launcher/programs-section.tsx@@ -0,0 +1,74 @@+import LauncherItem from "./launcher-item"+import programIcon from "../../programs/program-icon"+import usePrograms from "../../programs/programs"+import { ApplicationContext } from "../../../../contexts"+import Program from "@client/core/link-manager/auth-manager/program-manager/program"+import usePromise from "@libs/react-promise"+import Alert from "../../../../components/alert"++interface ProgramsSectionProps {++ onChoose: () => void+}++/** The installed-program section of the Start Menu. */+export default function ProgramsSection({ onChoose }: ProgramsSectionProps) {++ const application = ApplicationContext.useValue()++ const programs = usePrograms()++ return <div role="group" aria-label="Programs" className="grid gap-1">++ {programs.length++ ? programs.map(record => <ProgramItem++ key={record.identity}++ icon={programIcon(application.doors.program, record.assetId)}++ record={record}++ onChoose={onChoose}++ />)++ : <p className="px-3 py-8 text-center text-sm text-slate-600">No installed programs</p>}++ </div>+}++function ProgramItem({ icon, record, onChoose }: { icon: string, record: Program, onChoose: () => void }) {++ const launch = usePromise(async function () {++ onChoose()++ await record.createProcess()+ })++ return <>++ <LauncherItem++ label={record.name}++ icon={icon}++ description={record.description}++ disabled={launch.isPending}++ onClick={() => launch.safeExecute()}++ >++ {record.name}++ </LauncherItem>++ {launch.exception && <Alert className="text-sm">{String(launch.exception.current)}</Alert>}++ </>+}diff --git a/source/client/view/desktop/start-menu/start-menu.tsx b/source/client/view/structure/desktop/taskbar/launcher/start-menu.tsxsimilarity index 69%rename from source/client/view/desktop/start-menu/start-menu.tsxrename to source/client/view/structure/desktop/taskbar/launcher/start-menu.tsxindex 88a0d2f..3073227 100644--- a/source/client/view/desktop/start-menu/start-menu.tsx+++ b/source/client/view/structure/desktop/taskbar/launcher/start-menu.tsx@@ -1,7 +1,6 @@import logo from "@/assets/bundled/logo.png"import { memo } from "react"-import { startMenuStyle } from "../geometry"-import Launcher from "../taskbar/launcher"+import Launcher from "./launcher"import ProgramsSection from "./programs-section"/** The taskbar entry point for current and future desktop actions. */@@ -19,7 +18,7 @@ export default memo(function StartMenu() {</>}- style={startMenuStyle}+ className="inset-auto inset-be-[calc(anchor(top)+var(--desktop-gutter))] inset-s-[anchor(start)] max-h-[min(32rem,calc(100vh-var(--spacing-taskbar)-var(--desktop-gutter)*3))] w-[min(22rem,calc(100vw-var(--desktop-gutter)*2))] [position-anchor:--desktop-taskbar]">diff --git a/source/client/view/desktop/taskbar/overflow-row.tsx b/source/client/view/structure/desktop/taskbar/programs/overflow-row.tsxsimilarity index 85%rename from source/client/view/desktop/taskbar/overflow-row.tsxrename to source/client/view/structure/desktop/taskbar/programs/overflow-row.tsxindex 6eb5b6f..34df720 100644--- a/source/client/view/desktop/taskbar/overflow-row.tsx+++ b/source/client/view/structure/desktop/taskbar/programs/overflow-row.tsx@@ -30,6 +30,8 @@ export default function OverflowRow({ children, backwardLabel = "Scroll backwardconst end = Math.max(0, view!.scrollWidth - view!.clientWidth)+ const offset = getComputedStyle(view!).direction === "rtl" ? -view!.scrollLeft : view!.scrollLeft+const next = {// Compare natural content with the whole row, not the@@ -37,9 +39,9 @@ export default function OverflowRow({ children, backwardLabel = "Scroll backward// controls keeping themselves alive after content shrinks.overflowing: row!.scrollWidth > box!.clientWidth + 1,- start: view!.scrollLeft <= 1,+ start: offset <= 1,- end: view!.scrollLeft >= end - 1+ end: offset >= end - 1}setEdges(current => current.overflowing === next.overflowing && current.start === next.start && current.end === next.end ? current : next)@@ -72,7 +74,9 @@ export default function OverflowRow({ children, backwardLabel = "Scroll backwardif (!view) return- view.scrollBy({ left: direction * view.clientWidth * 0.8, behavior: reducedMotion ? "auto" : "smooth" })+ const inlineDirection = getComputedStyle(view).direction === "rtl" ? -1 : 1++ view.scrollBy({ left: inlineDirection * direction * view.clientWidth * 0.8, behavior: reducedMotion ? "auto" : "smooth" })}return <div ref={container} role="group" className={`flex min-w-0 items-center gap-1 ${className ?? ""}`} {...props}>@@ -108,11 +112,11 @@ function ScrollButton({ label, controls, direction, disabled, reducedMotion, onConClick={onClick}- className={`grid size-7 shrink-0 place-items-center rounded-lg border border-white/45 bg-white/55 text-slate-700 shadow-sm outline-none backdrop-blur-sm focus-visible:ring-2 focus-visible:ring-white disabled:opacity-35 ${reducedMotion ? "" : "transition-colors hover:bg-white/80 active:scale-95"}`}+ className={`grid size-7 shrink-0 place-items-center rounded-lg border border-white/45 bg-white/55 text-slate-700 shadow-sm outline-none focus-visible:ring-2 focus-visible:ring-white disabled:opacity-35 ${reducedMotion ? "" : "transition-colors hover:bg-white/80 active:scale-95"}`}>- <svg aria-hidden="true" viewBox="0 0 12 12" fill="none" stroke="currentColor" strokeWidth="1.6" strokeLinecap="round" strokeLinejoin="round" className="size-3">+ <svg aria-hidden="true" viewBox="0 0 12 12" fill="none" stroke="currentColor" strokeWidth="1.6" strokeLinecap="round" strokeLinejoin="round" className="size-3 rtl:-scale-x-100"><path d={direction === "backward" ? "m7.5 2.5-3.5 3.5 3.5 3.5" : "m4.5 2.5 3.5 3.5-3.5 3.5"} />diff --git a/source/client/view/desktop/taskbar/taskbar-item.tsx b/source/client/view/structure/desktop/taskbar/programs/taskbar-item.tsxsimilarity index 100%rename from source/client/view/desktop/taskbar/taskbar-item.tsxrename to source/client/view/structure/desktop/taskbar/programs/taskbar-item.tsxdiff --git a/source/client/view/desktop/taskbar/window-taskbar-item.tsx b/source/client/view/structure/desktop/taskbar/programs/window-taskbar-item.tsxsimilarity index 100%rename from source/client/view/desktop/taskbar/window-taskbar-item.tsxrename to source/client/view/structure/desktop/taskbar/programs/window-taskbar-item.tsxdiff --git a/source/client/view/desktop/taskbar/sign-out.tsx b/source/client/view/structure/desktop/taskbar/system/sign-out.tsxsimilarity index 91%rename from source/client/view/desktop/taskbar/sign-out.tsxrename to source/client/view/structure/desktop/taskbar/system/sign-out.tsxindex a30f19e..ed3f23b 100644--- a/source/client/view/desktop/taskbar/sign-out.tsx+++ b/source/client/view/structure/desktop/taskbar/system/sign-out.tsx@@ -1,6 +1,6 @@import useStorage from "@libs/storage-hook"import { ComponentProps, memo } from "react"-import TaskbarButton from "./taskbar-button"+import TaskbarButton from "../taskbar-button"export default memo(function (props: ComponentProps<typeof TaskbarButton>) {diff --git a/source/client/view/desktop/taskbar/system-dialogs.tsx b/source/client/view/structure/desktop/taskbar/system/system-dialogs.tsxsimilarity index 71%rename from source/client/view/desktop/taskbar/system-dialogs.tsxrename to source/client/view/structure/desktop/taskbar/system/system-dialogs.tsxindex 9126e5c..3a587c9 100644--- a/source/client/view/desktop/taskbar/system-dialogs.tsx+++ b/source/client/view/structure/desktop/taskbar/system/system-dialogs.tsx@@ -1,14 +1,15 @@import { type PermissionChoice, type PermissionDialog, type ServerCrashDialog } from "@server/core/dialog-manager"import ReactTunnel from "@libs/the-link/plugins/react-helper/react-tunnel"-import { enterSurface, prepareSurfaceEntrance, restSurface } from "../../appearance/surface-presence"-import { systemDialogStyle } from "../geometry"+import { enterSurface, prepareSurfaceEntrance, restSurface } from "../../../../appearance/surface-presence"import { useReducedMotion } from "@libs/react-motion"import { useTheme } from "@phreshos/react-ui"import { numericScale } from "@phreshos/core"import { useEffect, useId, useRef } from "react"-import { AuthManagerContext } from "../../contexts"-import TaskbarSurface, { taskbarSurfaceClassName } from "./taskbar-surface"-import TaskbarButton from "./taskbar-button"+import { AuthManagerContext } from "../../../../contexts"+import TaskbarSurface, { taskbarSurfaceClassName } from "../taskbar-surface"+import TaskbarButton from "../taskbar-button"+import usePromise from "@libs/react-promise"+import Alert from "../../../../components/alert"/** Taskbar-owned presentation of the system's authoritative dialog queue. */export default function SystemDialogs() {@@ -70,11 +71,11 @@ export default function SystemDialogs() {aria-describedby={description}- style={{ ...systemDialogStyle, borderRadius: radius }}+ style={{ borderRadius: radius }}onCancel={event => event.preventDefault()}- className={`${taskbarSurfaceClassName} backdrop:bg-transparent`}+ className={`${taskbarSurfaceClassName} inset-auto inset-be-[calc(anchor(top)+var(--desktop-gutter))] inset-s-[anchor(center)] w-[min(28rem,calc(100vw-var(--desktop-gutter)*2))] -translate-x-1/2 backdrop:bg-transparent [position-anchor:--desktop-taskbar]`}>@@ -82,9 +83,9 @@ export default function SystemDialogs() {{dialog.kind === "permission"- ? <PermissionRequest dialog={dialog} description={description} decide={choice => dialogManager.resolvePermission(dialog.identity, choice)} />+ ? <PermissionRequest key={dialog.identity} dialog={dialog} description={description} decide={choice => dialogManager.resolvePermission(dialog.identity, choice)} />- : <CrashReport dialog={dialog} description={description} acknowledge={() => dialogManager.acknowledge(dialog.identity)} />}+ : <CrashReport key={dialog.identity} dialog={dialog} description={description} acknowledge={() => dialogManager.acknowledge(dialog.identity)} />}</TaskbarSurface>@@ -93,6 +94,8 @@ export default function SystemDialogs() {function PermissionRequest({ dialog, description, decide }: PermissionRequestProps) {+ const decision = usePromise(decide)+return <div className="grid gap-5 p-4"><div className="grid grid-cols-[auto_minmax(0,1fr)] items-start gap-3">@@ -111,21 +114,25 @@ function PermissionRequest({ dialog, description, decide }: PermissionRequestPro<div className="flex flex-wrap justify-end gap-2">- <TaskbarButton small onClick={() => decide(false).catch(() => undefined)}>Deny</TaskbarButton>+ <TaskbarButton small disabled={decision.isPending} onClick={() => decision.safeExecute(false)}>Deny</TaskbarButton>- <TaskbarButton small autoFocus onClick={() => decide(null).catch(() => undefined)}>Later</TaskbarButton>+ <TaskbarButton small autoFocus disabled={decision.isPending} onClick={() => decision.safeExecute(null)}>Later</TaskbarButton>- <TaskbarButton small onClick={() => decide("process").catch(() => undefined)}>Allow for this Process</TaskbarButton>+ <TaskbarButton small disabled={decision.isPending} onClick={() => decision.safeExecute("process")}>Allow for this Process</TaskbarButton>- <TaskbarButton small onClick={() => decide("always").catch(() => undefined)}>Always allow</TaskbarButton>+ <TaskbarButton small disabled={decision.isPending} onClick={() => decision.safeExecute("always")}>Always allow</TaskbarButton></div>+ {decision.exception && <Alert className="text-sm">{String(decision.exception.current)}</Alert>}+</div>}function CrashReport({ dialog, description, acknowledge }: CrashReportProps) {+ const acknowledgment = usePromise(acknowledge)+return <div className="grid gap-5 p-4"><div className="grid grid-cols-[auto_minmax(0,1fr)] items-start gap-3">@@ -150,7 +157,9 @@ function CrashReport({ dialog, description, acknowledge }: CrashReportProps) {autoFocus- onClick={() => acknowledge().catch(() => undefined)}+ disabled={acknowledgment.isPending}++ onClick={() => acknowledgment.safeExecute()}className="font-medium"@@ -162,6 +171,8 @@ function CrashReport({ dialog, description, acknowledge }: CrashReportProps) {</div>+ {acknowledgment.exception && <Alert className="text-sm">{String(acknowledgment.exception.current)}</Alert>}+</div>}diff --git a/source/client/view/desktop/taskbar/taskbar-button.tsx b/source/client/view/structure/desktop/taskbar/taskbar-button.tsxsimilarity index 100%rename from source/client/view/desktop/taskbar/taskbar-button.tsxrename to source/client/view/structure/desktop/taskbar/taskbar-button.tsxdiff --git a/source/client/view/desktop/taskbar/taskbar-separator.tsx b/source/client/view/structure/desktop/taskbar/taskbar-separator.tsxsimilarity index 100%rename from source/client/view/desktop/taskbar/taskbar-separator.tsxrename to source/client/view/structure/desktop/taskbar/taskbar-separator.tsxdiff --git a/source/client/view/desktop/taskbar/taskbar-surface.tsx b/source/client/view/structure/desktop/taskbar/taskbar-surface.tsxsimilarity index 86%rename from source/client/view/desktop/taskbar/taskbar-surface.tsxrename to source/client/view/structure/desktop/taskbar/taskbar-surface.tsxindex 4e02b26..fdafd90 100644--- a/source/client/view/desktop/taskbar/taskbar-surface.tsx+++ b/source/client/view/structure/desktop/taskbar/taskbar-surface.tsx@@ -9,7 +9,7 @@ export default function TaskbarSurface({ label, labelId, children }: TaskbarSurfconst contentRadius = numericScale(useTheme().radius).medium- return <Surface style={{ borderRadius: "inherit" }} className="grid min-h-0 max-h-[inherit] grid-rows-[auto_minmax(0,1fr)] overflow-hidden">+ return <Surface className="grid min-h-0 max-h-[inherit] grid-rows-[auto_minmax(0,1fr)] overflow-hidden rounded-[inherit]"><h2 id={labelId} className="relative grid h-10 items-center px-3.5 text-window-title font-medium text-shadow-chrome select-none">{label}</h2>diff --git a/source/client/view/desktop/taskbar/taskbar.tsx b/source/client/view/structure/desktop/taskbar/taskbar.tsxsimilarity index 81%rename from source/client/view/desktop/taskbar/taskbar.tsxrename to source/client/view/structure/desktop/taskbar/taskbar.tsxindex 7d507f6..3f3534b 100644--- a/source/client/view/desktop/taskbar/taskbar.tsx+++ b/source/client/view/structure/desktop/taskbar/taskbar.tsx@@ -1,7 +1,6 @@import { ReactNode } from "react"import { Surface, useTheme, type SurfaceProps } from "@phreshos/react-ui"import { numericScale } from "@phreshos/core"-import { taskbarAnchorName } from "../geometry"import TaskbarSeparator from "./taskbar-separator"/**@@ -14,15 +13,15 @@ export default function Taskbar({ leading, trailing, dialogs, className, style,return <Surface- className={`relative isolate h-taskbar overflow-hidden shadow-taskbar ${className ?? ""}`}+ className={`relative isolate h-taskbar overflow-hidden shadow-taskbar [anchor-name:--desktop-taskbar] ${className ?? ""}`}- style={{ anchorName: taskbarAnchorName, ...style, borderRadius: radius }}+ style={{ ...style, borderRadius: radius }}{...props}>- <div className="relative grid h-full min-w-0 grid-cols-[auto_auto_minmax(0,1fr)_auto_auto] items-center gap-1.5 p-2">+ <div className="relative grid h-full min-w-0 grid-cols-[auto_auto_minmax(0,1fr)_auto_auto] items-center gap-1.5 p-1.5">{leading}diff --git a/source/client/view/components/wallpaper.tsx b/source/client/view/structure/desktop/wallpaper/wallpaper.tsxsimilarity index 97%rename from source/client/view/components/wallpaper.tsxrename to source/client/view/structure/desktop/wallpaper/wallpaper.tsxindex 701dcd3..16e6f5a 100644--- a/source/client/view/components/wallpaper.tsx+++ b/source/client/view/structure/desktop/wallpaper/wallpaper.tsx@@ -1,7 +1,7 @@import bundledWallpaper from "@/assets/bundled/wallpaper.jpg"-import { ApplicationContext } from "../contexts"+import { ApplicationContext } from "../../../contexts"import { useMemo, useState, type ReactNode } from "react"-import Loading from "./loading"+import Loading from "../../../components/loading"import { useReady } from "@libs/readiness/main"type WallpaperSource = Readonly<{diff --git a/source/client/view/desktop/window-manager/process-window.tsx b/source/client/view/structure/desktop/windows/process-window.tsxsimilarity index 94%rename from source/client/view/desktop/window-manager/process-window.tsxrename to source/client/view/structure/desktop/windows/process-window.tsxindex 8fbb4c9..5fa2a09 100644--- a/source/client/view/desktop/window-manager/process-window.tsx+++ b/source/client/view/structure/desktop/windows/process-window.tsx@@ -1,13 +1,13 @@import Process from "@client/core/link-manager/auth-manager/process-manager/process"import ClientState from "@client/core/link-manager/auth-manager/process-manager/client-state"-import { type WindowSurfaceSize } from "../../components/window-manager/window-geometry"-import { type LocalAnimation, type LocalSurfaceState } from "../../components/desktop-host/local-window"-import { type LocalGeometryReader } from "../../components/window-manager/local-windows"-import { type ProgramAccess } from "../../components/program-access"+import { type WindowSurfaceSize } from "../../../components/window-manager/window-geometry"+import { type LocalAnimation, type LocalSurfaceState } from "../../../components/desktop-host/local-window"+import { type LocalGeometryReader } from "../../../components/window-manager/local-windows"+import { type ProgramAccess } from "../../../components/program-access"import { type Position, type Size } from "@phreshos/core"-import Spinner from "../../components/spinner"+import Spinner from "../../../components/spinner"import Window from "./window"-import ProgramFrame, { programFrameSource } from "../../components/program-frame"+import ProgramFrame, { programFrameSource } from "../../../components/program-frame"import { memo, type SyntheticEvent, useCallback, useEffect, useState } from "react"const settleDelay = 80diff --git a/source/client/view/desktop/window-manager/snap-preview.tsx b/source/client/view/structure/desktop/windows/snap-preview.tsxsimilarity index 86%rename from source/client/view/desktop/window-manager/snap-preview.tsxrename to source/client/view/structure/desktop/windows/snap-preview.tsxindex 64d52c8..181fef5 100644--- a/source/client/view/desktop/window-manager/snap-preview.tsx+++ b/source/client/view/structure/desktop/windows/snap-preview.tsx@@ -1,6 +1,7 @@import { type CSSProperties, useLayoutEffect, useRef, useState } from "react"-import gsap, { motionEase } from "../../appearance/motion"-import { resolveWindowGeometry, resolveWindowValue, windowPaintInsets, type WindowSurfaceSize } from "../../components/window-manager/window-geometry"+import gsap, { motionEase } from "../../../appearance/motion"+import { resolveWindowGeometry, resolveWindowValue, windowPaintInsets, type WindowSurfaceSize } from "../../../components/window-manager/window-geometry"+import { windowPaintInset } from "../geometry"import { type Position, type Size } from "@phreshos/core"/** GSAP-owned preview of the placement currently offered by a drag. */@@ -76,8 +77,8 @@ export default function SnapPreview({ shown, visible, bare, paintSurfaceSize, ra><divdata-snap-preview-frame- className="absolute border border-white/50 bg-white/25 shadow-snap-preview backdrop-blur-sm"- style={bare ? { inset: 0 } : { ...windowPaintInsets(shown.position, shown.size, paintSurfaceSize), borderRadius: radius }}+ className={`absolute border border-white/50 bg-white/25 shadow-snap-preview ${bare ? "inset-0" : ""}`}+ style={bare ? undefined : { ...windowPaintInsets(shown.position, shown.size, paintSurfaceSize, windowPaintInset), borderRadius: radius }}/></div>}diff --git a/source/client/view/desktop/window-manager/window-header.tsx b/source/client/view/structure/desktop/windows/window-header.tsxsimilarity index 99%rename from source/client/view/desktop/window-manager/window-header.tsxrename to source/client/view/structure/desktop/windows/window-header.tsxindex d03094d..2b75d60 100644--- a/source/client/view/desktop/window-manager/window-header.tsx+++ b/source/client/view/structure/desktop/windows/window-header.tsx@@ -1,5 +1,5 @@import { ComponentProps, PointerEvent as ReactPointerEvent, ReactNode, useLayoutEffect, useRef, useState } from "react"-import gsap, { motionEase } from "../../appearance/motion"+import gsap, { motionEase } from "../../../appearance/motion"/** The visible chrome above an ordinary window's content. */export default function WindowHeader({ title, icon, active, whole, reducedMotion, stopping, onGrab, onMinimize, onMaximize, onClose }: WindowHeaderProps) {diff --git a/source/client/view/desktop/window-manager/window-surface.tsx b/source/client/view/structure/desktop/windows/window-surface.tsxsimilarity index 93%rename from source/client/view/desktop/window-manager/window-surface.tsxrename to source/client/view/structure/desktop/windows/window-surface.tsxindex 627c2ef..7903cc8 100644--- a/source/client/view/desktop/window-manager/window-surface.tsx+++ b/source/client/view/structure/desktop/windows/window-surface.tsx@@ -1,8 +1,8 @@import { useReducedMotion } from "@libs/react-motion"import { Surface } from "@phreshos/react-ui"import { useLayoutEffect, useRef, useState } from "react"-import { type LocalSurfaceState } from "../../components/desktop-host/local-window"-import gsap, { motionDuration, motionEase } from "../../appearance/motion"+import { type LocalSurfaceState } from "../../../components/desktop-host/local-window"+import gsap, { motionDuration, motionEase } from "../../../appearance/motion"const systemDuration = 240diff --git a/source/client/view/desktop/window-manager/window.tsx b/source/client/view/structure/desktop/windows/window.tsxsimilarity index 97%rename from source/client/view/desktop/window-manager/window.tsxrename to source/client/view/structure/desktop/windows/window.tsxindex 346a72e..7bd5cd4 100644--- a/source/client/view/desktop/window-manager/window.tsx+++ b/source/client/view/structure/desktop/windows/window.tsx@@ -1,15 +1,16 @@import { ComponentProps, PointerEvent as ReactPointerEvent, ReactNode, useLayoutEffect, useRef, useState } from "react"import { useReducedMotion } from "@libs/react-motion"-import { enterSurface, prepareSurfaceEntrance, restSurface } from "../../appearance/surface-presence"+import { enterSurface, prepareSurfaceEntrance, restSurface } from "../../../appearance/surface-presence"import { Surface, useTheme } from "@phreshos/react-ui"-import { absoluteWindowGeometry, resolveWindowGeometry, resolveWindowValue, wholeWindowGeometry, windowPaintInsets, type WindowRegion, type WindowSurfaceSize } from "../../components/window-manager/window-geometry"+import { absoluteWindowGeometry, resolveWindowGeometry, resolveWindowValue, wholeWindowGeometry, windowPaintInsets, type WindowRegion, type WindowSurfaceSize } from "../../../components/window-manager/window-geometry"import { numericScale, type Position, type Size, type WindowGeometry } from "@phreshos/core"import WindowHeader from "./window-header"import WindowSurface from "./window-surface"-import { type LocalAnimation, type LocalSurfaceState } from "../../components/desktop-host/local-window"-import { type LocalGeometryReader } from "../../components/window-manager/local-windows"-import gsap, { motionDuration, motionEase } from "../../appearance/motion"+import { type LocalAnimation, type LocalSurfaceState } from "../../../components/desktop-host/local-window"+import { type LocalGeometryReader } from "../../../components/window-manager/local-windows"+import gsap, { motionDuration, motionEase } from "../../../appearance/motion"import SnapPreview, { type SnapTarget } from "./snap-preview"+import { windowPaintInset } from "../geometry"/*** A window: a pure function of the record it is given. Every render@@ -673,7 +674,7 @@ export default function ({ title, icon, children, onClose, onClosed, onMinimize,: "shadow-window-inactive"- const paintedInsets = windowPaintInsets(position, size, paintSurfaceSize, gesture?.current)+ const paintedInsets = windowPaintInsets(position, size, paintSurfaceSize, windowPaintInset, gesture?.current)return <>@@ -724,7 +725,7 @@ export default function ({ title, icon, children, onClose, onClosed, onMinimize,Bare, there is no difference: the frame fills the box, sothe window is exactly as large as it asked to be and itsboundaries are the ones its own content draws. */}- <div data-window-container ref={surfaceElement} style={bare ? { inset: 0 } : { ...paintedInsets, borderRadius: outerRadius, color: theme.foreground }} className={`absolute isolate grid ${bare ? "grid-rows-1" : `overflow-hidden grid-rows-[auto_minmax(0,1fr)] ${surface}`}`}>+ <div data-window-container ref={surfaceElement} style={bare ? undefined : { ...paintedInsets, borderRadius: outerRadius, color: theme.foreground }} className={`absolute isolate grid ${bare ? "inset-0 grid-rows-1" : `overflow-hidden grid-rows-[auto_minmax(0,1fr)] ${surface}`}`}>{/* Material is paint, not the interaction container. Keepingit as a sibling behind the window contents prevents plain@@ -736,9 +737,7 @@ export default function ({ title, icon, children, onClose, onClosed, onMinimize,aria-hidden="true"- className="pointer-events-none absolute inset-0"-- style={{ borderRadius: "inherit", zIndex: -1 }}+ className="pointer-events-none absolute inset-0 -z-1 rounded-[inherit]"/>}diff --git a/source/client/view/desktop/desktop.tsx b/source/client/view/structure/structure.tsxsimilarity index 72%rename from source/client/view/desktop/desktop.tsxrename to source/client/view/structure/structure.tsxindex 628aded..d873e44 100644--- a/source/client/view/desktop/desktop.tsx+++ b/source/client/view/structure/structure.tsx@@ -5,9 +5,10 @@ import SocketLink from "@libs/the-link/plugins/client-link/socket-link"import LinkManager from "@client/core/link-manager/link-manager"import { ThemeProvider } from "@phreshos/react-ui"import Loading from "../components/loading"+import Alert from "../components/alert"import { ApplicationContext, LinkManagerContext } from "../contexts"import usePromise from "@libs/react-promise"-import Session from "./session/session"+import Authentication from "./authentication/authentication"import { useCallback, useState } from "react"import Readiness, { useReady } from "@libs/readiness/main"import { standardTheme } from "@phreshos/core"@@ -28,7 +29,7 @@ export default function () {className={`transition-opacity duration-200 ease-out ${pending.length ? "" : "pointer-events-none opacity-0"}`}- style={{ backgroundColor: standardTheme.background, backdropFilter: "none" }}+ style={{ backgroundColor: standardTheme.background }}/>}@@ -43,6 +44,8 @@ function Desktop() {const [linkManager, setLinkManager] = useState<LinkManager | null>(null)+ const [connectionRevision, setConnectionRevision] = useState(0)+const internal = ReactTunnel.useFactory(application.clientLink.$internal)internal.useSubscribe("subscribe", useCallback(function (socketLink: SocketLink<[TransmittedLinkManager, string]>) {@@ -54,13 +57,38 @@ function Desktop() {setLinkManager(new LinkManager(application, socketLink, payload, connectionIdentity))}, [application]))- usePromise(async () => application.clientLink.subscribe(), [])+ const connection = usePromise(async () => application.clientLink.subscribe(), [application, connectionRevision])++ if (connection.exception) return <FailedConnection++ exception={connection.exception.current}++ retry={() => setConnectionRevision(revision => revision + 1)}++ />if (!linkManager) return nullreturn <ConnectedDesktop linkManager={linkManager} />}+function FailedConnection({ exception, retry }: { exception: unknown, retry: () => void }) {++ useReady("connection")++ useReady("session")++ useReady("wallpaper")++ return <Alert className="m-auto grid w-fit gap-3">++ <span>{String(exception)}</span>++ <button type="button" className="cursor-pointer justify-self-end" onClick={retry}>Try again</button>++ </Alert>+}+function ConnectedDesktop({ linkManager }: { linkManager: LinkManager }) {useReady("connection")@@ -73,7 +101,7 @@ function ConnectedDesktop({ linkManager }: { linkManager: LinkManager }) {<div className="grid min-h-0" style={{ backgroundColor: theme.background }}>- <Session />+ <Authentication /></div>diff --git a/source/client/view/view.tsx b/source/client/view/view.tsxindex 9603823..8df97ec 100644--- a/source/client/view/view.tsx+++ b/source/client/view/view.tsx@@ -1,7 +1,7 @@import Appearance from "./appearance/appearance"import Application, { type Doors } from "@client/core/application"import { ApplicationContext } from "./contexts"-import Desktop from "./desktop/desktop"+import Structure from "./structure/structure"import client from "react-dom/client"import logo from "@/assets/bundled/logo.png"@@ -25,7 +25,7 @@ export default function (config: Config) {<Appearance>- <Desktop />+ <Structure /></Appearance>diff --git a/source/client/view2/appearance/appearance.css b/source/client/view2/appearance/appearance.cssdeleted file mode 100644index bbcf9ee..0000000--- a/source/client/view2/appearance/appearance.css+++ /dev/null@@ -1,10 +0,0 @@-@import "tailwindcss";--@import "@heroui/styles";--@import "@fontsource/roboto";--@theme inline {-- --font-roboto: "Roboto", sans-serif;-}diff --git a/source/client/view2/appearance/appearance.tsx b/source/client/view2/appearance/appearance.tsxdeleted file mode 100644index 8772233..0000000--- a/source/client/view2/appearance/appearance.tsx+++ /dev/null@@ -1,25 +0,0 @@-import { type ComponentProps, Fragment, useLayoutEffect } from "react"-import { ThemeProvider } from "next-themes"-import useStorage from "@libs/storage-hook"-import "./appearance.css"--export default function ({ children }: ComponentProps<typeof Fragment>) {-- const direction = useStorage("direction")-- useLayoutEffect(function () {-- document.documentElement.dir = direction.value === "rtl" ? "rtl" : "ltr"-- }, [direction.value])-- return <ThemeProvider attribute="class" defaultTheme="system">-- <div className="relative grid min-h-dvh bg-background font-roboto text-foreground">-- {children}-- </div>-- </ThemeProvider>-}diff --git a/source/client/view2/components/direction-switch.tsx b/source/client/view2/components/direction-switch.tsxdeleted file mode 100644index ed3d4b7..0000000--- a/source/client/view2/components/direction-switch.tsx+++ /dev/null@@ -1,21 +0,0 @@-import { Switch } from "@heroui/react"-import useStorage from "@libs/storage-hook"--export default function () {-- const direction = useStorage("direction")-- const reversed = direction.value === "rtl"-- return <Switch isSelected={reversed} onChange={value => direction.update(value ? "rtl" : "ltr")}>-- <Switch.Content>-- <Switch.Control><Switch.Thumb /></Switch.Control>-- Reverse reading direction-- </Switch.Content>-- </Switch>-}diff --git a/source/client/view2/components/failure.tsx b/source/client/view2/components/failure.tsxdeleted file mode 100644index 3b4e7ee..0000000--- a/source/client/view2/components/failure.tsx+++ /dev/null@@ -1,23 +0,0 @@-import { Button } from "@heroui/react"--export default function ({ title, error, retry }: FailureProps) {-- return <div className="grid place-self-center justify-items-center gap-4 p-6 text-center">-- <h1 className="text-xl font-semibold">{title}</h1>-- <p className="text-muted">{error instanceof Error ? error.message : String(error)}</p>-- <Button onPress={() => void retry()}>Try again</Button>-- </div>-}--interface FailureProps {-- title: string-- error: unknown-- retry: () => Promise<unknown>-}diff --git a/source/client/view2/components/theme-switch.tsx b/source/client/view2/components/theme-switch.tsxdeleted file mode 100644index ce7c47d..0000000--- a/source/client/view2/components/theme-switch.tsx+++ /dev/null@@ -1,19 +0,0 @@-import { Switch } from "@heroui/react"-import { useTheme } from "next-themes"--export default function () {-- const { resolvedTheme, setTheme } = useTheme()-- return <Switch isSelected={resolvedTheme === "dark"} onChange={dark => setTheme(dark ? "dark" : "light")}>-- <Switch.Content>-- <Switch.Control><Switch.Thumb /></Switch.Control>-- Dark theme-- </Switch.Content>-- </Switch>-}diff --git a/source/client/view2/contexts.ts b/source/client/view2/contexts.tsdeleted file mode 100644index 6045333..0000000--- a/source/client/view2/contexts.ts+++ /dev/null@@ -1,10 +0,0 @@-import AuthManager from "@client/core/link-manager/auth-manager/auth-manager"-import LinkManager from "@client/core/link-manager/link-manager"-import Application from "@client/core/application"-import ReactContext from "@libs/react-context"--export const ApplicationContext = new ReactContext<Application>()--export const LinkManagerContext = new ReactContext<LinkManager>()--export const AuthManagerContext = new ReactContext<AuthManager>()diff --git a/source/client/view2/structure/authentication/authentication.tsx b/source/client/view2/structure/authentication/authentication.tsxdeleted file mode 100644index 4ca9eb0..0000000--- a/source/client/view2/structure/authentication/authentication.tsx+++ /dev/null@@ -1,98 +0,0 @@-import AuthManager from "@client/core/link-manager/auth-manager/auth-manager"-import { AuthManagerContext, LinkManagerContext } from "../../contexts"-import { Spinner, SwitchGroup } from "@heroui/react"-import DirectionSwitch from "../../components/direction-switch"-import ThemeSwitch from "../../components/theme-switch"-import Credentials from "./credentials"-import Desktop from "../desktop/desktop"-import Failure from "../../components/failure"-import usePromise from "@libs/react-promise"-import useStorage from "@libs/storage-hook"-import { useEffect, useState } from "react"-import { type AuthenticationState } from "@server/core/authentication/authentication"--export default function () {-- const linkManager = LinkManagerContext.useValue()-- const authorization = useStorage("authorization")-- const [revision, setRevision] = useState(0)-- const session = usePromise<Session>(async function () {-- const response = await linkManager.sessionAuthenticate(authorization.value)-- if (!response) return {-- kind: "anonymous",-- state: await linkManager.authenticationState()- }-- const [token, payload] = response-- return {-- kind: "authenticated",-- manager: new AuthManager(linkManager, token, payload)- }-- }, [linkManager, authorization.value, revision])-- useEffect(function () {-- if (session.solve?.kind !== "authenticated") return-- const manager = session.solve.manager-- return () => manager.disconnect()-- }, [session.solve])-- if (session.isPending) return <Spinner aria-label="Restoring your session" className="place-self-center" />-- if (session.exception) return <Failure title="Your session could not be restored" error={session.exception.current} retry={session.safeExecute} />-- if (session.solve.kind === "authenticated") return <AuthManagerContext.Provider value={session.solve.manager}>-- <Desktop />-- </AuthManagerContext.Provider>-- return <>-- <SwitchGroup orientation="horizontal" className="absolute top-0 inset-e-0 p-4">-- <ThemeSwitch />-- <DirectionSwitch />-- </SwitchGroup>-- <Credentials-- mode={session.solve.state.registered ? "sign-in" : "register"}-- requirements={session.solve.state.requirements}-- onRegistered={() => setRevision(current => current + 1)}-- />-- </>-}--type Session = {-- kind: "anonymous"-- state: AuthenticationState--} | {-- kind: "authenticated"-- manager: AuthManager-}diff --git a/source/client/view2/structure/authentication/credentials.tsx b/source/client/view2/structure/authentication/credentials.tsxdeleted file mode 100644index 4227180..0000000--- a/source/client/view2/structure/authentication/credentials.tsx+++ /dev/null@@ -1,124 +0,0 @@-import { Alert, Button, Description, FieldError, Form, Input, Label, Spinner, TextField } from "@heroui/react"-import { LinkManagerContext } from "../../contexts"-import usePromise from "@libs/react-promise"-import useStorage from "@libs/storage-hook"-import { type AuthenticationState, type RegistrationError } from "@server/core/authentication/authentication"--export default function ({ mode, requirements, onRegistered }: CredentialsProps) {-- const linkManager = LinkManagerContext.useValue()-- const authorization = useStorage("authorization")-- const submission = usePromise(async function (username: string, password: string) {-- if (mode === "sign-in") {-- const token = await linkManager.signIn(username, password)-- if (token) authorization.update(token)-- return token ? null : "The username or password is incorrect."- }-- const response = await linkManager.register(username, password)-- if ("authorization" in response) authorization.update(response.authorization)-- else if (response.error === "registered") onRegistered()-- return "error" in response ? registrationMessage(response.error, requirements) : null- })-- function submit(data: FormData) {-- void submission.safeExecute(String(data.get("username") ?? ""), String(data.get("password") ?? ""))- }-- const register = mode === "register"-- const error = submission.exception-- ? submission.exception.current instanceof Error ? submission.exception.current.message : String(submission.exception.current)-- : submission.solve?.current-- return <Form aria-label={register ? "Create owner account" : "Sign in"} onSubmit={event => {-- event.preventDefault()-- submit(new FormData(event.currentTarget))-- }} className="grid w-[min(24rem,calc(100%-2rem))] place-self-center gap-5 p-6">-- <h1 className="text-2xl font-semibold">{register ? "Set up PhreshOS" : "Welcome back"}</h1>-- <p className="text-muted">{register ? "Create the credentials for this system's owner." : "Sign in as the system owner."}</p>-- <TextField fullWidth isRequired name="username" minLength={requirements.username.minimumLength} maxLength={requirements.username.maximumLength}>-- <Label>Username</Label>-- <Input autoFocus autoComplete="username" />-- <FieldError />-- </TextField>-- <TextField fullWidth isRequired name="password" type="password" minLength={requirements.password.minimumLength} maxLength={requirements.password.maximumLength}>-- <Label>Password</Label>-- <Input autoComplete={register ? "new-password" : "current-password"} />-- {register && <Description>Use at least {requirements.password.minimumLength} characters.</Description>}-- <FieldError />-- </TextField>-- {error && <Alert status="danger">-- <Alert.Indicator />-- <Alert.Content><Alert.Description>{error}</Alert.Description></Alert.Content>-- </Alert>}-- <Button fullWidth type="submit" isDisabled={submission.isPending}>-- {submission.isPending && <Spinner size="sm" color="current" />}-- {register ? "Create owner" : "Sign in"}-- </Button>-- </Form>-}--function registrationMessage(error: RegistrationError, requirements: AuthenticationState["requirements"]) {-- switch (error) {-- case "registered": return "Registration is already complete."-- case "username-required": return "Enter a username."-- case "username-invalid": return `Use a username of at most ${requirements.username.maximumLength} characters without control characters.`-- case "password-too-short": return `Use at least ${requirements.password.minimumLength} characters.`-- case "password-too-long": return `Use at most ${requirements.password.maximumLength} characters.`-- case "password-matches-username": return "The password must not be the username."- }-}--interface CredentialsProps {-- mode: "register" | "sign-in"-- requirements: AuthenticationState["requirements"]-- onRegistered: () => void-}diff --git a/source/client/view2/structure/desktop/context.ts b/source/client/view2/structure/desktop/context.tsdeleted file mode 100644index 2814f89..0000000--- a/source/client/view2/structure/desktop/context.ts+++ /dev/null@@ -1,12 +0,0 @@-import ReactContext from "@libs/react-context"-import { type ClientHost } from "@client/view/components/desktop-host/client-host"-import { type DesktopWindows } from "@client/view/components/window-manager/window-manager"--export const DesktopContext = new ReactContext<DesktopEnvironment>()--interface DesktopEnvironment {-- host: ClientHost-- windows: DesktopWindows-}diff --git a/source/client/view2/structure/desktop/desktop.tsx b/source/client/view2/structure/desktop/desktop.tsxdeleted file mode 100644index c53c8b8..0000000--- a/source/client/view2/structure/desktop/desktop.tsx+++ /dev/null@@ -1,41 +0,0 @@-import Wallpaper from "./wallpaper/wallpaper"-import UnderWindows from "./under-windows/under-windows"-import Windows from "./windows/windows"-import OverWindows from "./over-windows/over-windows"-import Taskbar from "./taskbar/taskbar"-import { AuthManagerContext } from "@client/view2/contexts"-import { DesktopContext } from "./context"-import useClientHost from "@client/view/components/desktop-host/client-host"-import useWindows from "@client/view/components/window-manager/window-manager"-import { useRef } from "react"--export default function () {-- const authManager = AuthManagerContext.useValue()-- const desktop = useRef<HTMLDivElement>(null)-- const sources = useRef(new Map<string, HTMLIFrameElement | null>())-- const windows = useWindows(authManager)-- const host = useClientHost(authManager, desktop, sources.current, windows.localWindow)-- return <DesktopContext.Provider value={{ host, windows }}>-- <div ref={desktop} className="relative isolate grid min-h-0 grid-cols-1 grid-rows-[minmax(0,1fr)_auto] gap-2.5 p-2.5">-- <Wallpaper />-- <UnderWindows />-- <Windows />-- <OverWindows />-- <Taskbar />-- </div>-- </DesktopContext.Provider>-}diff --git a/source/client/view2/structure/desktop/over-windows/over-windows.tsx b/source/client/view2/structure/desktop/over-windows/over-windows.tsxdeleted file mode 100644index 34a6c3b..0000000--- a/source/client/view2/structure/desktop/over-windows/over-windows.tsx+++ /dev/null@@ -1,4 +0,0 @@-export default function () {-- return <div className="pointer-events-none absolute inset-0 z-3 overflow-hidden" />-}diff --git a/source/client/view2/structure/desktop/taskbar/launcher/launcher.tsx b/source/client/view2/structure/desktop/taskbar/launcher/launcher.tsxdeleted file mode 100644index a7f650c..0000000--- a/source/client/view2/structure/desktop/taskbar/launcher/launcher.tsx+++ /dev/null@@ -1,15 +0,0 @@-import { useId } from "react"-import StartMenu from "./start-menu"--export default function () {-- const id = useId()-- return <>-- <button type="button" popoverTarget={id} aria-label="Start Menu" className="h-full min-w-[2.2rem] bg-danger" />-- <StartMenu id={id} />-- </>-}diff --git a/source/client/view2/structure/desktop/taskbar/launcher/start-menu.tsx b/source/client/view2/structure/desktop/taskbar/launcher/start-menu.tsxdeleted file mode 100644index 3162247..0000000--- a/source/client/view2/structure/desktop/taskbar/launcher/start-menu.tsx+++ /dev/null@@ -1,16 +0,0 @@-import { Surface } from "@heroui/react"--export default function ({ id }: { id: string }) {-- return <Surface-- id={id}-- popover="auto"-- aria-label="Start Menu"-- className="inset-auto inset-be-[calc(anchor(top)+var(--spacing)*2.5)] inset-s-[anchor(start)] m-0 size-80 rounded-lg border-0 p-0 outline-none [position-anchor:--desktop-taskbar]"-- >{null}</Surface>-}diff --git a/source/client/view2/structure/desktop/taskbar/programs/programs.tsx b/source/client/view2/structure/desktop/taskbar/programs/programs.tsxdeleted file mode 100644index ed0c144..0000000--- a/source/client/view2/structure/desktop/taskbar/programs/programs.tsx+++ /dev/null@@ -1,4 +0,0 @@-export default function () {-- return <div className="min-w-0 bg-accent/20" />-}diff --git a/source/client/view2/structure/desktop/taskbar/system/system.tsx b/source/client/view2/structure/desktop/taskbar/system/system.tsxdeleted file mode 100644index 3095c3a..0000000--- a/source/client/view2/structure/desktop/taskbar/system/system.tsx+++ /dev/null@@ -1,4 +0,0 @@-export default function () {-- return <div className="h-full min-w-[2.2rem] bg-warning/20" />-}diff --git a/source/client/view2/structure/desktop/taskbar/taskbar.tsx b/source/client/view2/structure/desktop/taskbar/taskbar.tsxdeleted file mode 100644index cf98113..0000000--- a/source/client/view2/structure/desktop/taskbar/taskbar.tsx+++ /dev/null@@ -1,16 +0,0 @@-import Launcher from "./launcher/launcher"-import Programs from "./programs/programs"-import System from "./system/system"--export default function () {-- return <div className="relative z-4 grid h-[2.2rem] grid-cols-[auto_1fr_auto] gap-1.25 overflow-hidden rounded-lg bg-success/20 p-1.25 [anchor-name:--desktop-taskbar]">-- <Launcher />-- <Programs />-- <System />-- </div>-}diff --git a/source/client/view2/structure/desktop/under-windows/under-windows.tsx b/source/client/view2/structure/desktop/under-windows/under-windows.tsxdeleted file mode 100644index ec4770e..0000000--- a/source/client/view2/structure/desktop/under-windows/under-windows.tsx+++ /dev/null@@ -1,4 +0,0 @@-export default function () {-- return <div className="pointer-events-none absolute inset-0 z-1 overflow-hidden" />-}diff --git a/source/client/view2/structure/desktop/wallpaper/background/background.tsx b/source/client/view2/structure/desktop/wallpaper/background/background.tsxdeleted file mode 100644index 23bcc9b..0000000--- a/source/client/view2/structure/desktop/wallpaper/background/background.tsx+++ /dev/null@@ -1,54 +0,0 @@-import bundledWallpaper from "@/assets/bundled/wallpaper.jpg"-import { ApplicationContext } from "@client/view2/contexts"-import Source, { type WallpaperSource } from "./source"-import { useMemo, useState } from "react"--const bundled: WallpaperSource = {-- identity: "bundled",-- source: bundledWallpaper,-- type: "image"-}--export default function ({ file, visible }: Properties) {-- const application = ApplicationContext.useValue()-- const requested = useMemo<WallpaperSource | null>(() => file === undefined ? null : file === null ? bundled : {-- identity: `file:${file}`,-- source: `${application.doors.uploads}/${encodeURIComponent(file)}`,-- type: /\.html?$/i.test(file) ? "document" : "image"-- }, [application.doors.uploads, file])-- const [displayed, setDisplayed] = useState<WallpaperSource>(bundled)-- const sources = !requested || requested.identity === displayed.identity ? [displayed] : [displayed, requested]-- return <>{sources.map(source => <Source-- key={source.identity}-- value={source}-- visible={visible && source.identity === displayed.identity}-- loaded={() => {-- if (source.identity === requested?.identity) setDisplayed(source)- }}-- />)}</>-}--interface Properties {-- file: string | null | undefined-- visible: boolean-}diff --git a/source/client/view2/structure/desktop/wallpaper/background/source.tsx b/source/client/view2/structure/desktop/wallpaper/background/source.tsxdeleted file mode 100644index aabfe28..0000000--- a/source/client/view2/structure/desktop/wallpaper/background/source.tsx+++ /dev/null@@ -1,50 +0,0 @@-export default function ({ value, visible, loaded }: Properties) {-- if (value.type === "document") return <iframe-- src={value.source}-- title="Wallpaper"-- sandbox="allow-scripts"-- className={`absolute inset-0 size-full border-0 ${visible ? "" : "pointer-events-none opacity-0"}`}-- onLoad={loaded}-- />-- return <>-- <div-- aria-hidden="true"-- className={`pointer-events-none absolute inset-0 bg-cover bg-center bg-no-repeat ${visible ? "" : "opacity-0"}`}-- style={{ backgroundImage: `url(${value.source})` }}-- />-- {!visible && <img src={value.source} alt="" className="hidden" onLoad={loaded} />}-- </>-}--export interface WallpaperSource {-- identity: string-- source: string-- type: "image" | "document"-}--interface Properties {-- value: WallpaperSource-- visible: boolean-- loaded: () => void-}diff --git a/source/client/view2/structure/desktop/wallpaper/wallpaper.tsx b/source/client/view2/structure/desktop/wallpaper/wallpaper.tsxdeleted file mode 100644index 8f67a5c..0000000--- a/source/client/view2/structure/desktop/wallpaper/wallpaper.tsx+++ /dev/null@@ -1,64 +0,0 @@-import { ApplicationContext, AuthManagerContext } from "@client/view2/contexts"-import { DesktopContext } from "../context"-import Background from "./background/background"-import useProperty from "@libs/the-link/plugins/react-helper/property-hook"-import ProgramAccessProbe, { type ProgramAccess } from "@client/view/components/program-access"-import ProgramFrame from "@client/view/components/program-frame"-import { type SyntheticEvent, useCallback, useState } from "react"--export default function () {-- const authManager = AuthManagerContext.useValue()-- const application = ApplicationContext.useValue()-- const { host, windows } = DesktopContext.useValue()-- const wallpaper = useProperty(authManager.linkManager.desktopWallpaper)-- const program = windows.wallpaper-- const [access, setAccess] = useState<ProgramAccess>("checking")-- const [ready, setReady] = useState<string | null>(null)-- const programReady = program !== null && ready === program.identity-- const loaded = useCallback(function (event: SyntheticEvent<HTMLIFrameElement>) {-- if (!program) return-- host.frameLoaded(program.identity, event.currentTarget)-- setReady(program.identity)-- }, [host, program])-- return <div className="absolute inset-0 z-0 overflow-hidden">-- <ProgramAccessProbe door={application.doors.program} setAccess={setAccess} />-- <Background file={program ? undefined : wallpaper} visible={!programReady} />-- {program?.client && access !== "checking" && <ProgramFrame-- record={program}-- client={program.client}-- title={program.client.window.title}-- door={application.doors.program}-- access={access}-- className={`absolute inset-0 size-full border-0 ${programReady ? "" : "pointer-events-none opacity-0"}`}-- onFrame={host.frame}-- onLoad={loaded}-- />}-- </div>-}diff --git a/source/client/view2/structure/desktop/windows/windows.tsx b/source/client/view2/structure/desktop/windows/windows.tsxdeleted file mode 100644index 65b00b6..0000000--- a/source/client/view2/structure/desktop/windows/windows.tsx+++ /dev/null@@ -1,14 +0,0 @@-import { DesktopContext } from "../context"--export default function () {-- const { host } = DesktopContext.useValue()-- return <div-- ref={element => { host.windowSurfaceRef.current = element }}-- className="pointer-events-none relative z-2 min-h-0 bg-accent/20"-- />-}diff --git a/source/client/view2/structure/structure.tsx b/source/client/view2/structure/structure.tsxdeleted file mode 100644index 06293cf..0000000--- a/source/client/view2/structure/structure.tsx+++ /dev/null@@ -1,47 +0,0 @@-import ReactTunnel from "@libs/the-link/plugins/react-helper/react-tunnel"-import { type TransmittedLinkManager } from "@server/core/link-manager/link-manager"-import SocketLink from "@libs/the-link/plugins/client-link/socket-link"-import LinkManager from "@client/core/link-manager/link-manager"-import { Spinner } from "@heroui/react"-import { ApplicationContext, LinkManagerContext } from "../contexts"-import Authentication from "./authentication/authentication"-import Failure from "../components/failure"-import usePromise from "@libs/react-promise"-import { useCallback, useState } from "react"--export default function () {-- const application = ApplicationContext.useValue()-- const [linkManager, setLinkManager] = useState<LinkManager | null>(null)-- const internal = ReactTunnel.useFactory(application.clientLink.$internal)-- internal.useSubscribe("subscribe", useCallback(function (socketLink: SocketLink<[TransmittedLinkManager, string]>) {-- const [payload, connectionIdentity] = socketLink.payload-- const connected = new LinkManager(application, socketLink, payload, connectionIdentity)-- socketLink.$internal.subscribeOnce("unsubscribe", () => setLinkManager(current => current === connected ? null : current))-- setLinkManager(connected)-- }, [application]))-- const connection = usePromise(async function () {-- application.clientLink.subscribe()-- }, [])-- if (connection.exception) return <Failure title="PhreshOS is unavailable" error={connection.exception.current} retry={connection.safeExecute} />-- if (!linkManager) return <Spinner aria-label="Connecting to PhreshOS" className="place-self-center" />-- return <LinkManagerContext.Provider value={linkManager}>-- <Authentication />-- </LinkManagerContext.Provider>-}diff --git a/source/client/view2/view.tsx b/source/client/view2/view.tsxdeleted file mode 100644index bc75125..0000000--- a/source/client/view2/view.tsx+++ /dev/null@@ -1,47 +0,0 @@-import Appearance from "./appearance/appearance"-import Structure from "./structure/structure"-import Application, { type Doors } from "@client/core/application"-import { ApplicationContext } from "./contexts"-import client from "react-dom/client"-import logo from "@/assets/bundled/logo.png"--export default function (config: Config) {-- config.document.title = `${config.displayName} v${config.version}`-- const icon = config.document.createElement("link")-- icon.rel = "icon"-- icon.href = logo-- config.document.head.appendChild(icon)-- const application = new Application(config.name, config.displayName, config.version, config.doors)-- client.createRoot(config.document.body).render(-- <ApplicationContext.Provider value={application}>-- <Appearance>-- <Structure />-- </Appearance>-- </ApplicationContext.Provider>- )-}--interface Config {-- name: string-- displayName: string-- version: string-- doors: Doors-- document: Document-}