PWA fixed

added systemd service howto

traefik

nginix set_real_ip_from

improved readme

visuals fixed on mobile

labels removed

updated readme

fixed visuals

overlay for the hotkey

disable screen lock

clean up

git precommit hooks

clean up

clean up

update

check for update feature

added build-time information

fixed date

clean up

added hook script

fix

fix

fix

hooks fixed

webhook setup

players stay in run all timers mode

mqtt

mqtt allways connected

mqtt messages work

capturing mqtt in edit player

mqtt in Setup

updated readme

state of the mqtt

Global Pass turn
This commit is contained in:
cpu
2025-05-08 15:36:17 +02:00
parent d741efa62d
commit 19fbae06fc
51 changed files with 6992 additions and 2 deletions

53
vite.config.js Normal file
View File

@@ -0,0 +1,53 @@
import { defineConfig } from 'vite';
import vue from '@vitejs/plugin-vue';
import fs from 'fs';
import { resolve } from 'path';
const packageJson = JSON.parse(fs.readFileSync('./package.json', 'utf8'));
const appVersion = packageJson.version;
// Get current date (this will be the server's local time where the build runs)
const now = new Date();
// Options for date formatting, targeting CET/CEST
const dateTimeFormatOptionsCEST = {
year: 'numeric', month: '2-digit', day: '2-digit',
hour: '2-digit', minute: '2-digit', second: '2-digit',
hour12: false, // Use 24-hour format
timeZone: 'Europe/Bratislava' // Or 'Europe/Prague', 'Europe/Berlin', etc. (any major CET/CEST city)
// This will automatically handle Daylight Saving Time (CEST vs CET)
};
// Generate build time string using a specific time zone that observes CET/CEST
const appBuildTime = now.toLocaleString('sk-SK', dateTimeFormatOptionsCEST) + " CEST/CET"; // Add timezone indicator for clarity
export default defineConfig({
plugins: [vue()],
server: {
port: 8080
},
define: {
'import.meta.env.VITE_APP_BUILD_TIME': JSON.stringify(appBuildTime),
'__APP_CACHE_VERSION__': JSON.stringify(`nexus-timer-cache-v${appVersion}-${Date.now()}`)
},
build: {
rollupOptions: {
input: {
main: resolve(__dirname, 'index.html'),
sw: resolve(__dirname, 'src/sw.js')
},
output: {
entryFileNames: assetInfo => {
if (assetInfo.name === 'sw') {
return 'service-worker.js';
}
return 'assets/[name]-[hash].js';
},
chunkFileNames: 'assets/[name]-[hash].js',
assetFileNames: 'assets/[name]-[hash].[ext]',
}
},
emptyOutDir: true,
}
});