510ebdf885
The page is now web/ (Vue 3 + Vite + TypeScript), built into screen_manager/app/static with hashed file names; server.py serves index.html as built and /assets/. The Python API, the data and the firmware are unchanged. Your screens sit in a sidebar, the pages of a screen stand next to each other at the screen's own shape, the library sits on the right, and a tile's settings slide in as a drawer while the mockup stays in view. New screen, Firmware & USB, Alerts, Override YAML and Settings are pages of their own. Fonts moved to web/src/assets; the tests read the source through tests/editor_sources.py. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
21 lines
754 B
TypeScript
21 lines
754 B
TypeScript
import vue from "@vitejs/plugin-vue";
|
|
import { defineConfig } from "vite";
|
|
|
|
// The add-on serves the built page from screen_manager/app/static behind Home Assistant ingress,
|
|
// which lives on a sub path with a token. Everything is relative so the page works there and on
|
|
// a bare http://127.0.0.1:8099 (SCREEN_DEV). The Python server keeps serving /api; only the static
|
|
// files change. `npm run dev` proxies /api to a running server (the demo home or SCREEN_DEV).
|
|
export default defineConfig({
|
|
base: "./",
|
|
plugins: [vue()],
|
|
build: {
|
|
outDir: "../screen_manager/app/static",
|
|
emptyOutDir: false,
|
|
target: "es2022",
|
|
},
|
|
server: {
|
|
port: 5173,
|
|
proxy: { "/api": { target: "http://127.0.0.1:8099", changeOrigin: false } },
|
|
},
|
|
});
|