-
+
{{ $t(`common.live.${status}`) }}
-
+
-
+
diff --git a/web/app/pages/templates/index.vue b/web/app/pages/templates/index.vue
index 81d95a0..d723882 100644
--- a/web/app/pages/templates/index.vue
+++ b/web/app/pages/templates/index.vue
@@ -1,14 +1,14 @@
-
+
{{ $t(`common.live.${status}`) }}
-
+
-
+
diff --git a/web/app/plugins/icons.ts b/web/app/plugins/icons.ts
new file mode 100644
index 0000000..d90df48
--- /dev/null
+++ b/web/app/plugins/icons.ts
@@ -0,0 +1,55 @@
+import {
+ mdiAlertCircleOutline,
+ mdiArrowLeft,
+ mdiAlertOutline,
+ mdiCheckCircleOutline,
+ mdiContentCopy,
+ mdiContentSaveOutline,
+ mdiClose,
+ mdiCubeOutline,
+ mdiDeleteSweepOutline,
+ mdiDownloadOutline,
+ mdiFilterOffOutline,
+ mdiInformationOutline,
+ mdiLayersOutline,
+ mdiMenu,
+ mdiPause,
+ mdiTagMultipleOutline,
+ mdiTimelineTextOutline,
+ mdiTrayFull,
+ mdiTranslate,
+ mdiViewDashboardOutline,
+ mdiWrenchOutline,
+ mdiWeatherNight,
+ mdiWeatherSunny,
+} from '@mdi/js'
+
+// Grus icons, registered with the Pavo icon registry (M3Icon, M3Button icon, M3Chip icon). Only the listed icons end
+// up in the bundle. Add an entry when a page needs a new icon. Pavo's own icons are built in.
+export default defineNuxtPlugin(() => {
+ registerIcons({
+ 'mdi-alert-circle-outline': mdiAlertCircleOutline,
+ 'mdi-alert-outline': mdiAlertOutline,
+ 'mdi-arrow-left': mdiArrowLeft,
+ 'mdi-check-circle-outline': mdiCheckCircleOutline,
+ 'mdi-content-copy': mdiContentCopy,
+ 'mdi-content-save-outline': mdiContentSaveOutline,
+ 'mdi-close': mdiClose,
+ 'mdi-cube-outline': mdiCubeOutline,
+ 'mdi-delete-sweep-outline': mdiDeleteSweepOutline,
+ 'mdi-download-outline': mdiDownloadOutline,
+ 'mdi-filter-off-outline': mdiFilterOffOutline,
+ 'mdi-information-outline': mdiInformationOutline,
+ 'mdi-layers-outline': mdiLayersOutline,
+ 'mdi-menu': mdiMenu,
+ 'mdi-pause': mdiPause,
+ 'mdi-tag-multiple-outline': mdiTagMultipleOutline,
+ 'mdi-timeline-text-outline': mdiTimelineTextOutline,
+ 'mdi-tray-full': mdiTrayFull,
+ 'mdi-translate': mdiTranslate,
+ 'mdi-view-dashboard-outline': mdiViewDashboardOutline,
+ 'mdi-weather-night': mdiWeatherNight,
+ 'mdi-weather-sunny': mdiWeatherSunny,
+ 'mdi-wrench-outline': mdiWrenchOutline,
+ })
+})
diff --git a/web/i18n/locales/de/common.json b/web/i18n/locales/de/common.json
index 22446a3..d687482 100644
--- a/web/i18n/locales/de/common.json
+++ b/web/i18n/locales/de/common.json
@@ -1,15 +1,6 @@
{
"common": {
"appName": "Grus",
- "skipToContent": "Zum Inhalt springen",
- "menu": "Menü",
- "navigation": "Navigation",
- "close": "Schließen",
- "language": "Sprache wechseln",
- "lightTheme": "Helles Design",
- "darkTheme": "Dunkles Design",
- "cancel": "Abbrechen",
- "confirm": "Bestätigen",
"nav": {
"overview": "Übersicht",
"pools": "Pools",
@@ -23,11 +14,6 @@
"open": "Live",
"reconnecting": "Live: verbindet neu",
"closed": "Live: getrennt"
- },
- "problem": {
- "network": "Keine Verbindung zur Grus-API",
- "networkHint": "Die Oberfläche erreicht den Server nicht. Die Verbindung wird automatisch erneut versucht.",
- "unexpected": "Unerwarteter Fehler"
}
}
}
diff --git a/web/i18n/locales/en/common.json b/web/i18n/locales/en/common.json
index b3ef8c9..e586f2f 100644
--- a/web/i18n/locales/en/common.json
+++ b/web/i18n/locales/en/common.json
@@ -1,15 +1,6 @@
{
"common": {
"appName": "Grus",
- "skipToContent": "Skip to content",
- "menu": "Menu",
- "navigation": "Navigation",
- "close": "Close",
- "language": "Switch language",
- "lightTheme": "Light theme",
- "darkTheme": "Dark theme",
- "cancel": "Cancel",
- "confirm": "Confirm",
"nav": {
"overview": "Overview",
"pools": "Pools",
@@ -23,11 +14,6 @@
"open": "Live",
"reconnecting": "Live: reconnecting",
"closed": "Live: disconnected"
- },
- "problem": {
- "network": "No connection to the Grus API",
- "networkHint": "The interface cannot reach the server. It retries automatically.",
- "unexpected": "Unexpected error"
}
}
}
diff --git a/web/nuxt.config.ts b/web/nuxt.config.ts
index ba9a628..fda9665 100644
--- a/web/nuxt.config.ts
+++ b/web/nuxt.config.ts
@@ -8,7 +8,7 @@ export default defineNuxtConfig({
devtools: { enabled: false },
telemetry: false,
- // Area components keep their own names (PoolTable, not PoolsPoolTable); m3/ keeps its M3 prefix.
+ // Area components keep their own names (PoolTable, not PoolsPoolTable); the M3 kit comes from Pavo.
components: [
{ path: '~/components/pools', pathPrefix: false },
{ path: '~/components/templates', pathPrefix: false },
@@ -18,6 +18,7 @@ export default defineNuxtConfig({
modules: [
'@nuxt/eslint',
'@nuxtjs/i18n',
+ '@onelitefeathernet/pavo',
],
runtimeConfig: {
@@ -39,12 +40,7 @@ export default defineNuxtConfig({
},
},
- css: [
- '@fontsource/roboto/400.css',
- '@fontsource/roboto/500.css',
- '@fontsource/roboto/700.css',
- '~/assets/css/main.css',
- ],
+ css: ['~/assets/css/main.css'],
vite: {
plugins: [tailwindcss()],
diff --git a/web/package.json b/web/package.json
index ec993f1..32ca4c1 100644
--- a/web/package.json
+++ b/web/package.json
@@ -16,18 +16,16 @@
"lint": "eslint .",
"typecheck": "nuxt typecheck",
"test": "vitest run --maxWorkers=2",
- "tokens": "node scripts/m3-tokens.mjs",
"gen:api": "openapi-typescript ../api/openapi.yaml -o app/types/grus-api.d.ts"
},
"dependencies": {
- "@fontsource/roboto": "^5.3.0",
"@mdi/js": "^7.4.47",
"@nuxtjs/i18n": "^10.6.0",
+ "@onelitefeathernet/pavo": "^0.2.0",
"nuxt": "^4.7.0",
"vue": "^3.5.46"
},
"devDependencies": {
- "@material/material-color-utilities": "^0.3.0",
"@nuxt/eslint": "^1.17.0",
"@tailwindcss/vite": "^4.3.5",
"@vitejs/plugin-vue": "^6.0.11",
diff --git a/web/pnpm-lock.yaml b/web/pnpm-lock.yaml
index 827130c..f688cce 100644
--- a/web/pnpm-lock.yaml
+++ b/web/pnpm-lock.yaml
@@ -8,15 +8,15 @@ importers:
.:
dependencies:
- '@fontsource/roboto':
- specifier: ^5.3.0
- version: 5.3.0
'@mdi/js':
specifier: ^7.4.47
version: 7.4.47
'@nuxtjs/i18n':
specifier: ^10.6.0
version: 10.6.0(@nuxt/schema@4.7.0)(@vue/compiler-dom@3.5.46)(db0@0.3.4)(dotenv@17.4.2)(esbuild@0.28.2)(giget@3.3.1)(jiti@2.7.0)(rolldown@1.2.19)(rollup@4.68.8)(typescript@5.9.3)(vite@8.3.8(@types/node@26.6.9)(esbuild@0.28.2)(jiti@2.7.0)(terser@5.51.4)(yaml@2.9.1))(vue@3.5.46(typescript@5.9.3))
+ '@onelitefeathernet/pavo':
+ specifier: ^0.2.0
+ version: 0.2.0(confbox@0.2.4)(dotenv@17.4.2)(giget@3.3.1)(jiti@2.7.0)(magic-string@1.4.5)(mlly@1.8.2)(oxc-parser@0.141.0)(rolldown@1.2.19)(tailwindcss@4.3.5)(unplugin@3.7.0(esbuild@0.28.2)(rolldown@1.2.19)(rollup@4.68.8)(vite@8.3.8(@types/node@26.6.9)(esbuild@0.28.2)(jiti@2.7.0)(terser@5.51.4)(yaml@2.9.1)))(vue@3.5.46(typescript@5.9.3))
nuxt:
specifier: ^4.7.0
version: 4.7.0(@babel/plugin-syntax-jsx@7.29.7(@babel/core@7.29.13))(@babel/plugin-syntax-typescript@7.29.7(@babel/core@7.29.13))(@oxc-project/types@0.156.0)(@types/node@26.6.9)(@vue/compiler-sfc@3.5.46)(acorn@8.19.0)(bare-buffer@3.7.3)(confbox@0.2.4)(db0@0.3.4)(dotenv@17.4.2)(esbuild@0.28.2)(eslint@10.15.0(jiti@2.7.0))(giget@3.3.1)(lightningcss@1.33.0)(mlly@1.8.2)(optionator@0.9.4)(oxc-parser@0.141.0)(rolldown@1.2.19)(rollup-plugin-visualizer@7.3.0(rolldown@1.2.19)(rollup@4.68.8))(rollup@4.68.8)(srvx@1.0.8)(terser@5.51.4)(typescript@5.9.3)(vite@8.3.8(@types/node@26.6.9)(esbuild@0.28.2)(jiti@2.7.0)(terser@5.51.4)(yaml@2.9.1))(vue-tsc@3.3.14(typescript@5.9.3))(yaml@2.9.1)
@@ -24,9 +24,6 @@ importers:
specifier: ^3.5.46
version: 3.5.46(typescript@5.9.3)
devDependencies:
- '@material/material-color-utilities':
- specifier: ^0.3.0
- version: 0.3.0
'@nuxt/eslint':
specifier: ^1.17.0
version: 1.17.0(@nuxt/schema@4.7.0)(@typescript-eslint/utils@8.74.0(eslint@10.15.0(jiti@2.7.0))(typescript@5.9.3))(@vue/compiler-sfc@3.5.46)(confbox@0.2.4)(crossws@0.4.17(srvx@1.0.8))(dotenv@17.4.2)(esbuild@0.28.2)(eslint@10.15.0(jiti@2.7.0))(giget@3.3.1)(jiti@2.7.0)(magic-string@1.4.5)(oxc-parser@0.141.0)(rolldown@1.2.19)(rollup@4.68.8)(srvx@1.0.8)(typescript@5.9.3)(unplugin@3.7.0(esbuild@0.28.2)(rolldown@1.2.19)(rollup@4.68.8)(vite@8.3.8(@types/node@26.6.9)(esbuild@0.28.2)(jiti@2.7.0)(terser@5.51.4)(yaml@2.9.1)))(vite@8.3.8(@types/node@26.6.9)(esbuild@0.28.2)(jiti@2.7.0)(terser@5.51.4)(yaml@2.9.1))
@@ -1019,6 +1016,13 @@ packages:
'@one-ini/wasm@0.2.1':
resolution: {integrity: sha512-TUqERXGNTifZ9y2g3wPxQrw3HpHv/02DsW3D90T9x0hhonrL1ZqpSmNrU2XkoIq0fP1N6gZfVQzy2Fw1ZvGBNg==}
+ '@onelitefeathernet/pavo@0.2.0':
+ resolution: {integrity: sha512-nxM4iP7DypN+E5RtJ7LmyfTXZjTcKCtnH6RfgiecTWuhoppuEEKZ9ivKTjrEOzLK9OpXHZEC3oXcMAv03fD0Hw==, tarball: https://npm.pkg.github.com/download/@onelitefeathernet/pavo/0.2.0/fb8e97d327d1f174185837eec3cbe645f4fb0e21}
+ hasBin: true
+ peerDependencies:
+ tailwindcss: ^4.3.5
+ vue: ^3.5.46
+
'@oxc-parser/binding-android-arm-eabi@0.141.0':
resolution: {integrity: sha512-jk7086MFvR/T4DG9IY7MKBVt1PMxvSZoz/TvnifodvS0pjghVwJHRttnAExhlwdMOgHv1TmLdENnbNpYk2zjvA==}
engines: {node: ^20.19.0 || >=22.12.0}
@@ -6013,6 +6017,26 @@ snapshots:
'@one-ini/wasm@0.2.1': {}
+ '@onelitefeathernet/pavo@0.2.0(confbox@0.2.4)(dotenv@17.4.2)(giget@3.3.1)(jiti@2.7.0)(magic-string@1.4.5)(mlly@1.8.2)(oxc-parser@0.141.0)(rolldown@1.2.19)(tailwindcss@4.3.5)(unplugin@3.7.0(esbuild@0.28.2)(rolldown@1.2.19)(rollup@4.68.8)(vite@8.3.8(@types/node@26.6.9)(esbuild@0.28.2)(jiti@2.7.0)(terser@5.51.4)(yaml@2.9.1)))(vue@3.5.46(typescript@5.9.3))':
+ dependencies:
+ '@fontsource/roboto': 5.3.0
+ '@material/material-color-utilities': 0.3.0
+ '@mdi/js': 7.4.47
+ '@nuxt/kit': 4.7.0(@nuxt/schema@4.7.0)(confbox@0.2.4)(dotenv@17.4.2)(giget@3.3.1)(jiti@2.7.0)(magic-string@1.4.5)(mlly@1.8.2)(oxc-parser@0.141.0)(rolldown@1.2.19)(unplugin@3.7.0(esbuild@0.28.2)(rolldown@1.2.19)(rollup@4.68.8)(vite@8.3.8(@types/node@26.6.9)(esbuild@0.28.2)(jiti@2.7.0)(terser@5.51.4)(yaml@2.9.1)))
+ '@nuxt/schema': 4.7.0
+ tailwindcss: 4.3.5
+ vue: 3.5.46(typescript@5.9.3)
+ transitivePeerDependencies:
+ - confbox
+ - dotenv
+ - giget
+ - jiti
+ - magic-string
+ - mlly
+ - oxc-parser
+ - rolldown
+ - unplugin
+
'@oxc-parser/binding-android-arm-eabi@0.141.0':
optional: true
diff --git a/web/scripts/m3-tokens.mjs b/web/scripts/m3-tokens.mjs
deleted file mode 100644
index ada0deb..0000000
--- a/web/scripts/m3-tokens.mjs
+++ /dev/null
@@ -1,74 +0,0 @@
-// Generates app/assets/css/m3-tokens.css: every Material 3 colour role (--md-sys-color-*) for the light and
-// the dark scheme, from one seed colour. Run `pnpm tokens` after changing SEED; the test in
-// m3-tokens.test.ts fails when the committed file is stale.
-//
-// Seed: OLF blue #114cc8 (the blue of the feather mark). Vibrant keeps the seed chroma, so the primary stays recognisably OLF blue (#0051df) while the
-// surfaces stay calm; the roles reach WCAG AA (on-* roles are 4.5:1 or better by construction). The
-// error role stays red and never collides with the primary hue, which a magenta seed would not guarantee.
-// Success and warning are not part of M3; they are tonal palettes of the OLF green and yellow with the same
-// tone mapping the standard roles use.
-import { writeFileSync } from 'node:fs'
-import { fileURLToPath } from 'node:url'
-import {
- argbFromHex,
- Hct,
- hexFromArgb,
- MaterialDynamicColors,
- SchemeVibrant,
- TonalPalette,
-} from '@material/material-color-utilities'
-
-export const SEED = '#114cc8'
-const GREEN = '#1bc755'
-const YELLOW = '#f7cc2e'
-
-const kebab = name => name.replace(/[A-Z]/g, c => `-${c.toLowerCase()}`)
-
-// The roles of MaterialDynamicColors that are colours (the rest are helpers or palette key colours).
-const ROLES = Object.getOwnPropertyNames(MaterialDynamicColors).filter(
- n => !/KeyColor$|^highestSurface$|^contentAccentToneDelta$/.test(n)
- && MaterialDynamicColors[n] && typeof MaterialDynamicColors[n].getArgb === 'function',
-)
-
-// Tones for [color, on-color, container, on-container].
-const EXTRA = { light: [40, 100, 90, 10], dark: [80, 20, 30, 90] }
-
-function scheme(dark) {
- const s = new SchemeVibrant(Hct.fromInt(argbFromHex(SEED)), dark, 0)
- const out = {}
- for (const role of ROLES) out[kebab(role)] = hexFromArgb(MaterialDynamicColors[role].getArgb(s))
- const tones = dark ? EXTRA.dark : EXTRA.light
- for (const [name, hex] of [['success', GREEN], ['warning', YELLOW]]) {
- const p = TonalPalette.fromInt(argbFromHex(hex))
- const [c, on, cont, onCont] = tones.map(t => hexFromArgb(p.tone(t)))
- out[name] = c
- out[`on-${name}`] = on
- out[`${name}-container`] = cont
- out[`on-${name}-container`] = onCont
- }
- return out
-}
-
-const block = (selector, vars, colorScheme, indent = '') =>
- `${indent}${selector} {\n${indent} color-scheme: ${colorScheme};\n`
- + Object.entries(vars).map(([k, v]) => `${indent} --md-sys-color-${k}: ${v};`).join('\n')
- + `\n${indent}}\n`
-
-export function buildTokensCss() {
- const light = scheme(false)
- const dark = scheme(true)
- return `/* Generated by scripts/m3-tokens.mjs from seed ${SEED} (Vibrant). Do not edit; run \`pnpm tokens\`. */\n\n`
- + block(':root', light, 'light')
- + '\n/* Dark scheme: the system preference, unless the user picked a theme explicitly. */\n'
- + `@media (prefers-color-scheme: dark) {\n${block(':root:not([data-theme="light"])', dark, 'dark', ' ')}}\n\n`
- + block(':root[data-theme="dark"]', dark, 'dark')
- + '\n/* Tailwind utilities: bg-primary, text-on-surface, border-outline-variant, ... */\n'
- + `@theme inline {\n${Object.keys(light).map(k => ` --color-${k}: var(--md-sys-color-${k});`).join('\n')}\n}\n`
-}
-
-export const TOKENS_PATH = fileURLToPath(new URL('../app/assets/css/m3-tokens.css', import.meta.url))
-
-if (process.argv[1] === fileURLToPath(import.meta.url)) {
- writeFileSync(TOKENS_PATH, buildTokensCss())
- console.log(`wrote ${TOKENS_PATH}`)
-}