- Neue CalDAV-Route mit PROPFIND und GET-Endpoints - ICS-Format-Generator für Buchungsdaten - Token-basierte Authentifizierung für CalDAV-Zugriff - Admin-Interface mit CalDAV-Link-Generator - Schritt-für-Schritt-Anleitung für Kalender-Apps - 24h-Token-Ablaufzeit für Sicherheit - Unterstützung für Outlook, Google Calendar, Apple Calendar, Thunderbird Fixes: Admin kann jetzt Terminkalender in externen Apps abonnieren
29 lines
1.8 KiB
JavaScript
29 lines
1.8 KiB
JavaScript
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "hono/jsx/jsx-runtime";
|
|
import { readFileSync } from "fs";
|
|
import { join } from "path";
|
|
export function clientEntry(c) {
|
|
let jsFile = "/src/client/main.tsx";
|
|
let cssFiles = null;
|
|
if (process.env.NODE_ENV === 'production') {
|
|
try {
|
|
// Read Vite manifest to get the correct file names
|
|
const manifestPath = join(process.cwd(), 'dist', '.vite', 'manifest.json');
|
|
const manifest = JSON.parse(readFileSync(manifestPath, 'utf-8'));
|
|
const entry = manifest['index.html'];
|
|
if (entry) {
|
|
jsFile = `/${entry.file}`;
|
|
if (entry.css) {
|
|
cssFiles = entry.css.map((css) => `/${css}`);
|
|
}
|
|
}
|
|
}
|
|
catch (error) {
|
|
console.warn('Could not read Vite manifest, using fallback:', error);
|
|
// Fallback to a generic path
|
|
jsFile = "/assets/index-Ccx6A0bN.js";
|
|
cssFiles = ["/assets/index-RdX4PbOO.css"];
|
|
}
|
|
}
|
|
return c.html(_jsxs("html", { lang: "en", children: [_jsxs("head", { children: [_jsx("meta", { charSet: "utf-8" }), _jsx("meta", { content: "width=device-width, initial-scale=1", name: "viewport" }), _jsx("title", { children: "Stargirlnails Kiel" }), _jsx("link", { rel: "icon", type: "image/png", href: "/favicon.png" }), cssFiles && cssFiles.map((css) => (_jsx("link", { rel: "stylesheet", href: css }, css))), process.env.NODE_ENV === 'production' ? (_jsx("script", { src: jsFile, type: "module" })) : (_jsxs(_Fragment, { children: [_jsx("script", { src: "/@vite/client", type: "module" }), _jsx("script", { src: jsFile, type: "module" })] }))] }), _jsx("body", { children: _jsx("div", { id: "root" }) })] }));
|
|
}
|