Launch-Countdown: Teaser vor dem Start, im Dashboard einstellbar
Unter Einstellungen > Launch-Countdown lassen sich Startzeitpunkt (deutsche Zeit), An/Aus und optionale Texte (DE/EN) pflegen. Solange der Countdown laeuft, sehen Besucher nur die Teaser-Seite; eingeloggte Admins sehen die normale Seite mit Hinweisleiste und koennen den Teaser unter /?countdown=vorschau ansehen. Bei 0 oeffnet sich die Website automatisch. Neue Spalten in app_settings werden per Auto-Migration nachgeruestet. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KSYBhvKhm4di3v331BkNjL
This commit is contained in:
parent
ad3d1b081d
commit
51c5e6e1c1
73 changed files with 2759 additions and 2036 deletions
|
|
@ -85,6 +85,7 @@ const EmailSettings = lazyPage(() => import('./pages/admin/settings/EmailSetting
|
|||
const DatabaseSettings = lazyPage(() => import('./pages/admin/settings/DatabaseSettings.jsx'));
|
||||
const ExportImportSettings = lazyPage(() => import('./pages/admin/settings/ExportImportSettings.jsx'));
|
||||
const MaintenanceSettings = lazyPage(() => import('./pages/admin/settings/MaintenanceSettings.jsx'));
|
||||
const CountdownSettings = lazyPage(() => import('./pages/admin/settings/CountdownSettings.jsx'));
|
||||
const ResetSettings = lazyPage(() => import('./pages/admin/settings/ResetSettings.jsx'));
|
||||
|
||||
const blankScreen = <div className="min-h-screen bg-white dark:bg-neutral-950" />;
|
||||
|
|
@ -159,6 +160,7 @@ export default function App() {
|
|||
<Route path="design" element={<RequirePermission permission="settings.manage"><WebsiteSettings section="design" /></RequirePermission>} />
|
||||
<Route path="legal" element={<RequirePermission permission="settings.manage"><LegalSettings /></RequirePermission>} />
|
||||
<Route path="maintenance" element={<RequirePermission permission="settings.manage"><MaintenanceSettings /></RequirePermission>} />
|
||||
<Route path="countdown" element={<RequirePermission permission="settings.manage"><CountdownSettings /></RequirePermission>} />
|
||||
<Route path="google" element={<RequirePermission permission="system.admin"><WebsiteSettings section="google" /></RequirePermission>} />
|
||||
<Route path="email" element={<RequirePermission permission="system.admin"><EmailSettings /></RequirePermission>} />
|
||||
<Route path="database" element={<RequirePermission permission="system.admin"><DatabaseSettings /></RequirePermission>} />
|
||||
|
|
|
|||
|
|
@ -38,6 +38,7 @@ const ICONS = {
|
|||
trash: 'M5 7h14M10 11v6m4-6v6M6 7l1 13h10l1-13M9 7V4h6v3',
|
||||
external: 'M14 4h6v6m0-6-9 9M19 14v5a1 1 0 0 1-1 1H5a1 1 0 0 1-1-1V6a1 1 0 0 1 1-1h5',
|
||||
pause: 'M12 21a9 9 0 1 0 0-18 9 9 0 0 0 0 18Zm-2-12v6m4-6v6',
|
||||
timer: 'M10 2h4M12 14l3-3M12 22a8 8 0 1 0 0-16 8 8 0 0 0 0 16Z',
|
||||
};
|
||||
|
||||
const Icon = ({ path }) => (
|
||||
|
|
@ -56,6 +57,7 @@ export default function AdminLayout() {
|
|||
// nie unbemerkt bleiben.
|
||||
const [hiddenAreas, setHiddenAreas] = useState([]);
|
||||
const [maintenanceOn, setMaintenanceOn] = useState(false);
|
||||
const [countdownUntil, setCountdownUntil] = useState(null);
|
||||
|
||||
// Wird auch von Seiten aufgerufen (useAdminUi().refreshCounters), z. B. nachdem eine Anfrage
|
||||
// auf "Erledigt" gesetzt oder ein Bereich ausgeblendet wurde - frueher blieb das Badge bis
|
||||
|
|
@ -65,7 +67,10 @@ export default function AdminLayout() {
|
|||
api.get('/contact').then((rows) => setNewContactCount(rows.filter((r) => r.status === 'new').length)).catch(() => {});
|
||||
}
|
||||
api.get('/site-settings').then((res) => setHiddenAreas(res.hidden_areas || [])).catch(() => {});
|
||||
api.get('/maintenance').then((res) => setMaintenanceOn(!!res?.global?.enabled)).catch(() => {});
|
||||
api.get('/maintenance').then((res) => {
|
||||
setMaintenanceOn(!!res?.global?.enabled);
|
||||
setCountdownUntil(res?.countdown?.active ? res.countdown.launch_at : null);
|
||||
}).catch(() => {});
|
||||
// eslint-disable-next-line react-hooks/exhaustive-deps
|
||||
}, [user?.id]);
|
||||
|
||||
|
|
@ -124,6 +129,7 @@ export default function AdminLayout() {
|
|||
{ to: '/admin/settings/design', label: 'Aussehen', icon: 'palette', permission: 'settings.manage' },
|
||||
{ to: '/admin/settings/legal', label: 'Rechtstexte', icon: 'file', permission: 'settings.manage' },
|
||||
{ to: '/admin/settings/maintenance', label: 'Wartungsmodus', icon: 'pause', permission: 'settings.manage' },
|
||||
{ to: '/admin/settings/countdown', label: 'Launch-Countdown', icon: 'timer', permission: 'settings.manage' },
|
||||
],
|
||||
},
|
||||
{
|
||||
|
|
@ -249,7 +255,7 @@ export default function AdminLayout() {
|
|||
</div>
|
||||
)}
|
||||
</header>
|
||||
{(maintenanceOn || hiddenAreaLabels.length > 0) && (
|
||||
{(maintenanceOn || countdownUntil || hiddenAreaLabels.length > 0) && (
|
||||
<div className="border-b border-amber-200 bg-amber-50 px-4 py-2 text-sm text-amber-900 dark:border-amber-900 dark:bg-amber-950 dark:text-amber-200 sm:px-6">
|
||||
{maintenanceOn && (
|
||||
<p>
|
||||
|
|
@ -257,6 +263,13 @@ export default function AdminLayout() {
|
|||
{hasPermission('settings.manage') && <Link to="/admin/settings/maintenance" className="underline">Ändern</Link>}
|
||||
</p>
|
||||
)}
|
||||
{countdownUntil && (
|
||||
<p>
|
||||
<strong>Launch-Countdown läuft</strong> – Besucher sehen bis{' '}
|
||||
{new Date(countdownUntil).toLocaleString('de-DE', { dateStyle: 'medium', timeStyle: 'short', timeZone: 'Europe/Berlin' })} Uhr nur den Countdown.{' '}
|
||||
{hasPermission('settings.manage') && <Link to="/admin/settings/countdown" className="underline">Ändern</Link>}
|
||||
</p>
|
||||
)}
|
||||
{hiddenAreaLabels.length > 0 && (
|
||||
<p>
|
||||
<strong>Ausgeblendet für Besucher:</strong> {hiddenAreaLabels.join(', ')}.{' '}
|
||||
|
|
|
|||
324
hifi-src/src/components/CountdownTeaser.jsx
Normal file
324
hifi-src/src/components/CountdownTeaser.jsx
Normal file
|
|
@ -0,0 +1,324 @@
|
|||
import { useEffect, useMemo, useState } from 'react';
|
||||
import { Link } from 'react-router-dom';
|
||||
import { AnimatePresence, motion, useReducedMotion } from 'framer-motion';
|
||||
import { CalendarPlus, LogIn, Phone, X } from 'lucide-react';
|
||||
import { useLanguage } from '../context/LanguageContext.jsx';
|
||||
import { telHref } from '../utils/contactLinks.js';
|
||||
import logoDark from '../assets/logo-dark.png';
|
||||
import defaultBackground from '../assets/photos/hero-trunk.webp';
|
||||
|
||||
const EASE = [0.16, 1, 0.3, 1];
|
||||
const michroma = { fontFamily: "'Michroma', sans-serif" };
|
||||
const condensed = { fontFamily: "'Barlow Condensed', sans-serif" };
|
||||
|
||||
// Restzeit in ms bis zum Launch - mit dem Uhr-Versatz zwischen Server und Browser, damit eine
|
||||
// falsch gehende Uhr beim Besucher den Countdown nicht verschiebt.
|
||||
export function countdownRemaining(countdown, clockOffset = 0) {
|
||||
if (!countdown?.launch_at) return 0;
|
||||
return new Date(countdown.launch_at).getTime() - (Date.now() + clockOffset);
|
||||
}
|
||||
|
||||
// Versatz Server-Uhr minus Browser-Uhr zum Zeitpunkt der Antwort (_received_at setzt PublicLayout).
|
||||
export function countdownClockOffset(countdown, receivedAt) {
|
||||
if (!countdown?.server_time || !receivedAt) return 0;
|
||||
return new Date(countdown.server_time).getTime() - receivedAt;
|
||||
}
|
||||
|
||||
function splitRemaining(ms) {
|
||||
const total = Math.max(0, Math.floor(ms / 1000));
|
||||
return {
|
||||
days: Math.floor(total / 86400),
|
||||
hours: Math.floor((total % 86400) / 3600),
|
||||
minutes: Math.floor((total % 3600) / 60),
|
||||
seconds: total % 60,
|
||||
};
|
||||
}
|
||||
|
||||
// Kalendereintrag (.ics) fuer "Erinnere mich" - laeuft komplett im Browser.
|
||||
function calendarHref(launchAt, title) {
|
||||
const start = new Date(launchAt);
|
||||
const end = new Date(start.getTime() + 60 * 60 * 1000);
|
||||
const fmt = (d) => d.toISOString().replace(/[-:]/g, '').replace(/\.\d{3}/, '');
|
||||
const ics = [
|
||||
'BEGIN:VCALENDAR',
|
||||
'VERSION:2.0',
|
||||
'PRODID:-//HifiPlanet//Countdown//DE',
|
||||
'BEGIN:VEVENT',
|
||||
`UID:launch-${fmt(start)}@hifi-planet.de`,
|
||||
`DTSTAMP:${fmt(new Date())}`,
|
||||
`DTSTART:${fmt(start)}`,
|
||||
`DTEND:${fmt(end)}`,
|
||||
`SUMMARY:${title}`,
|
||||
`URL:${window.location.origin}`,
|
||||
'END:VEVENT',
|
||||
'END:VCALENDAR',
|
||||
].join('\r\n');
|
||||
return `data:text/calendar;charset=utf-8,${encodeURIComponent(ics)}`;
|
||||
}
|
||||
|
||||
// Eine Ziffer, die beim Wechsel nach unten wegrollt - wie ein Zaehlwerk.
|
||||
function RollingDigit({ value, reduceMotion }) {
|
||||
return (
|
||||
<span className="relative inline-block h-[1.15em] w-[0.92em] overflow-hidden text-center">
|
||||
<AnimatePresence initial={false} mode="popLayout">
|
||||
<motion.span
|
||||
key={value}
|
||||
initial={reduceMotion ? { opacity: 0 } : { y: '-100%', opacity: 0, filter: 'blur(4px)' }}
|
||||
animate={{ y: '0%', opacity: 1, filter: 'blur(0px)' }}
|
||||
exit={reduceMotion ? { opacity: 0 } : { y: '100%', opacity: 0, filter: 'blur(4px)' }}
|
||||
transition={{ duration: 0.45, ease: EASE }}
|
||||
className="absolute inset-0"
|
||||
>
|
||||
{value}
|
||||
</motion.span>
|
||||
</AnimatePresence>
|
||||
</span>
|
||||
);
|
||||
}
|
||||
|
||||
function TimeTile({ value, label, reduceMotion, minDigits = 2 }) {
|
||||
const digits = String(value).padStart(minDigits, '0').split('');
|
||||
return (
|
||||
<div className="flex flex-col items-center">
|
||||
<div className="relative overflow-hidden rounded-2xl border border-white/10 bg-white/[0.04] px-2.5 py-3 shadow-[inset_0_1px_0_rgba(255,255,255,0.08),0_20px_50px_-20px_rgba(0,0,0,0.8)] backdrop-blur-md sm:rounded-3xl sm:px-5 sm:py-5">
|
||||
{/* Lichtkante oben + Trennlinie in der Mitte wie bei einer Fallblattanzeige */}
|
||||
<div className="pointer-events-none absolute inset-x-0 top-0 h-1/2 bg-gradient-to-b from-white/[0.06] to-transparent" />
|
||||
<div className="pointer-events-none absolute inset-x-0 top-1/2 h-px bg-black/40" />
|
||||
<div
|
||||
style={michroma}
|
||||
className="relative flex text-[1.5rem] leading-none tabular-nums text-white [text-shadow:0_0_30px_rgba(146,212,68,0.35)] min-[400px]:text-[1.85rem] sm:text-6xl lg:text-7xl"
|
||||
>
|
||||
{digits.map((d, i) => (
|
||||
<RollingDigit key={digits.length - i} value={d} reduceMotion={reduceMotion} />
|
||||
))}
|
||||
</div>
|
||||
</div>
|
||||
<span style={condensed} className="mt-3 text-[0.7rem] font-semibold uppercase tracking-[0.3em] text-neutral-400 sm:text-sm">
|
||||
{label}
|
||||
</span>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
// Equalizer am unteren Rand - der Car-Hifi-"Herzschlag" der Seite. Feste Pseudo-Zufallswerte,
|
||||
// damit nichts bei jedem Render springt.
|
||||
function Equalizer({ bars = 72 }) {
|
||||
const items = useMemo(
|
||||
() =>
|
||||
Array.from({ length: bars }, (_, i) => {
|
||||
const seed = Math.sin(i * 12.9898) * 43758.5453;
|
||||
const rand = seed - Math.floor(seed);
|
||||
const center = 1 - Math.abs(i / (bars - 1) - 0.5) * 1.3;
|
||||
return {
|
||||
height: 18 + center * 62 + rand * 20,
|
||||
duration: 0.9 + rand * 1.4,
|
||||
delay: -rand * 2,
|
||||
};
|
||||
}),
|
||||
[bars]
|
||||
);
|
||||
return (
|
||||
<div aria-hidden className="pointer-events-none absolute inset-x-0 bottom-0 flex h-40 items-end gap-[3px] px-2 opacity-80 [mask-image:linear-gradient(to_right,transparent,black_15%,black_85%,transparent)] sm:h-56 sm:gap-1">
|
||||
{items.map((bar, i) => (
|
||||
<span
|
||||
key={i}
|
||||
className="countdown-eq-bar flex-1 origin-bottom rounded-t-sm bg-gradient-to-t from-brand-500/80 via-brand-400/40 to-brand-300/0"
|
||||
style={{ height: `${bar.height}%`, animationDuration: `${bar.duration}s`, animationDelay: `${bar.delay}s` }}
|
||||
/>
|
||||
))}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
export default function CountdownTeaser({ countdown, clockOffset = 0, settings = {}, preview = false, onClosePreview, onLaunch }) {
|
||||
const { t, language, toggleLanguage } = useLanguage();
|
||||
const reduceMotion = useReducedMotion();
|
||||
const [remaining, setRemaining] = useState(() => countdownRemaining(countdown, clockOffset));
|
||||
const launched = remaining <= 0;
|
||||
|
||||
useEffect(() => {
|
||||
const tick = () => setRemaining(countdownRemaining(countdown, clockOffset));
|
||||
tick();
|
||||
const timer = setInterval(tick, 250);
|
||||
return () => clearInterval(timer);
|
||||
}, [countdown, clockOffset]);
|
||||
|
||||
// Bei 0: kurz "Wir sind live!" feiern, dann oeffnet sich die echte Seite.
|
||||
useEffect(() => {
|
||||
if (!launched || preview) return undefined;
|
||||
const timer = setTimeout(() => onLaunch?.(), 2600);
|
||||
return () => clearTimeout(timer);
|
||||
}, [launched, preview, onLaunch]);
|
||||
|
||||
useEffect(() => {
|
||||
const previous = document.title;
|
||||
document.title = `HifiPlanet – ${t('countdown.eyebrow')}`;
|
||||
return () => {
|
||||
document.title = previous;
|
||||
};
|
||||
}, [t]);
|
||||
|
||||
const parts = splitRemaining(remaining);
|
||||
const en = language === 'en';
|
||||
const title = (en ? countdown.title_en : countdown.title) || t('countdown.title');
|
||||
const message = (en ? countdown.message_en : countdown.message) || t('countdown.message');
|
||||
const launchDate = countdown.launch_at ? new Date(countdown.launch_at) : null;
|
||||
const dateLabel = launchDate
|
||||
? launchDate.toLocaleDateString(en ? 'en-GB' : 'de-DE', { weekday: 'long', day: 'numeric', month: 'long', year: 'numeric', timeZone: 'Europe/Berlin' })
|
||||
: '';
|
||||
const timeLabel = launchDate
|
||||
? launchDate.toLocaleTimeString(en ? 'en-GB' : 'de-DE', { hour: '2-digit', minute: '2-digit', timeZone: 'Europe/Berlin' })
|
||||
: '';
|
||||
const background = settings.hero_image_path || defaultBackground;
|
||||
|
||||
const fadeUp = (delay) => ({
|
||||
initial: reduceMotion ? { opacity: 0 } : { opacity: 0, y: 24, filter: 'blur(8px)' },
|
||||
animate: { opacity: 1, y: 0, filter: 'blur(0px)' },
|
||||
transition: { duration: 0.9, delay, ease: EASE },
|
||||
});
|
||||
|
||||
return (
|
||||
<div className="relative isolate flex min-h-[100svh] flex-col overflow-hidden bg-[#040604] text-white">
|
||||
{/* Hintergrund: Foto ganz dezent, gruener Lichtkegel von unten, feines Raster */}
|
||||
<div aria-hidden className="absolute inset-0 -z-10">
|
||||
<img
|
||||
src={background}
|
||||
alt=""
|
||||
className="countdown-kenburns h-full w-full object-cover opacity-[0.16] grayscale-[40%]"
|
||||
/>
|
||||
<div className="absolute inset-0 bg-gradient-to-b from-[#040604] via-[#040604]/70 to-[#040604]" />
|
||||
<div className="absolute inset-0 bg-[radial-gradient(ellipse_70%_55%_at_50%_105%,rgba(107,166,38,0.38),transparent_70%)]" />
|
||||
<div className="absolute inset-0 bg-[radial-gradient(ellipse_45%_35%_at_50%_-5%,rgba(146,212,68,0.12),transparent_70%)]" />
|
||||
<div className="absolute inset-0 opacity-[0.07] [background-image:linear-gradient(rgba(255,255,255,0.6)_1px,transparent_1px),linear-gradient(90deg,rgba(255,255,255,0.6)_1px,transparent_1px)] [background-size:56px_56px] [mask-image:radial-gradient(ellipse_at_center,black_20%,transparent_70%)]" />
|
||||
</div>
|
||||
<Equalizer />
|
||||
|
||||
{preview && (
|
||||
<div className="relative z-20 flex items-center justify-center gap-3 bg-brand-500 px-4 py-2 text-xs font-semibold text-white">
|
||||
{t('countdown.preview')}
|
||||
<button type="button" onClick={onClosePreview} className="inline-flex items-center gap-1 rounded-full bg-black/20 px-2.5 py-1 hover:bg-black/30">
|
||||
<X className="h-3.5 w-3.5" />
|
||||
{t('countdown.closePreview')}
|
||||
</button>
|
||||
</div>
|
||||
)}
|
||||
|
||||
<header className="relative z-10 flex items-center justify-between px-5 pt-5 sm:px-8 sm:pt-7">
|
||||
<motion.img {...fadeUp(0)} src={settings.logo_dark_path || logoDark} alt="HifiPlanet" className="h-12 w-auto sm:h-16" />
|
||||
<button
|
||||
type="button"
|
||||
onClick={toggleLanguage}
|
||||
aria-label={t('languageToggle.label')}
|
||||
style={condensed}
|
||||
className="rounded-full border border-white/15 px-3 py-1.5 text-sm font-semibold uppercase tracking-widest text-neutral-300 transition hover:border-brand-400 hover:text-white"
|
||||
>
|
||||
{language === 'de' ? 'EN' : 'DE'}
|
||||
</button>
|
||||
</header>
|
||||
|
||||
<main className="relative z-10 flex flex-1 flex-col items-center justify-center px-4 pb-24 pt-10 text-center sm:pb-28">
|
||||
<motion.div
|
||||
{...fadeUp(0.15)}
|
||||
style={condensed}
|
||||
className="mb-6 inline-flex items-center gap-2.5 rounded-full border border-brand-400/30 bg-brand-500/10 px-4 py-1.5 text-xs font-semibold uppercase tracking-[0.28em] text-brand-300 sm:text-sm"
|
||||
>
|
||||
<span className="relative flex h-2 w-2">
|
||||
<span className="absolute inline-flex h-full w-full animate-ping rounded-full bg-brand-400 opacity-75" />
|
||||
<span className="relative inline-flex h-2 w-2 rounded-full bg-brand-400" />
|
||||
</span>
|
||||
{launched ? t('countdown.liveEyebrow') : t('countdown.eyebrow')}
|
||||
</motion.div>
|
||||
|
||||
<AnimatePresence mode="wait">
|
||||
<motion.h1
|
||||
key={launched ? 'live' : 'soon'}
|
||||
initial={reduceMotion ? { opacity: 0 } : { opacity: 0, y: 30, filter: 'blur(10px)' }}
|
||||
animate={{ opacity: 1, y: 0, filter: 'blur(0px)' }}
|
||||
exit={{ opacity: 0, y: -20, filter: 'blur(10px)' }}
|
||||
transition={{ duration: 0.9, delay: launched ? 0 : 0.25, ease: EASE }}
|
||||
style={condensed}
|
||||
className="max-w-4xl bg-gradient-to-b from-white via-white to-neutral-400 bg-clip-text text-5xl font-semibold uppercase leading-[0.95] tracking-tight text-transparent sm:text-7xl lg:text-8xl"
|
||||
>
|
||||
{launched ? t('countdown.liveTitle') : title}
|
||||
</motion.h1>
|
||||
</AnimatePresence>
|
||||
|
||||
<motion.p {...fadeUp(0.4)} className="mt-6 max-w-xl text-base leading-relaxed text-neutral-300 sm:text-lg">
|
||||
{launched ? t('countdown.liveMessage') : message}
|
||||
</motion.p>
|
||||
|
||||
<motion.div
|
||||
{...fadeUp(0.55)}
|
||||
className={`mt-10 flex items-start gap-2 transition-all duration-700 min-[400px]:gap-3 sm:mt-14 sm:gap-5 ${launched ? 'scale-105 [filter:drop-shadow(0_0_40px_rgba(146,212,68,0.55))]' : ''}`}
|
||||
>
|
||||
<TimeTile value={parts.days} label={t('countdown.days')} reduceMotion={reduceMotion} />
|
||||
<TimeTile value={parts.hours} label={t('countdown.hours')} reduceMotion={reduceMotion} />
|
||||
<TimeTile value={parts.minutes} label={t('countdown.minutes')} reduceMotion={reduceMotion} />
|
||||
<TimeTile value={parts.seconds} label={t('countdown.seconds')} reduceMotion={reduceMotion} />
|
||||
</motion.div>
|
||||
|
||||
{launchDate && !launched && (
|
||||
<motion.div {...fadeUp(0.7)} className="mt-10 flex flex-col items-center gap-4 sm:flex-row sm:gap-5">
|
||||
<p style={condensed} className="text-base uppercase tracking-[0.18em] text-neutral-400 sm:text-lg">
|
||||
{t('countdown.launchPrefix')} <span className="text-white">{dateLabel}</span> {t('countdown.launchAt')}{' '}
|
||||
<span className="text-white">{timeLabel}</span> {t('countdown.clock')}
|
||||
</p>
|
||||
<a
|
||||
href={calendarHref(countdown.launch_at, t('countdown.calendarTitle'))}
|
||||
download="hifiplanet-launch.ics"
|
||||
className="inline-flex items-center gap-2 rounded-full bg-brand-500 px-4 py-2 text-sm font-semibold text-white shadow-[0_0_30px_-5px_rgba(107,166,38,0.7)] transition hover:bg-brand-400"
|
||||
>
|
||||
<CalendarPlus className="h-4 w-4" />
|
||||
{t('countdown.addToCalendar')}
|
||||
</a>
|
||||
</motion.div>
|
||||
)}
|
||||
</main>
|
||||
|
||||
<footer className="relative z-10 flex flex-col items-center justify-between gap-3 px-5 pb-5 text-xs text-neutral-400 sm:flex-row sm:px-8 sm:pb-7">
|
||||
<div className="flex flex-wrap items-center justify-center gap-x-4 gap-y-1">
|
||||
{settings.phone && (
|
||||
<a href={telHref(settings.phone)} className="inline-flex items-center gap-1.5 transition hover:text-white">
|
||||
<Phone className="h-3.5 w-3.5" />
|
||||
{t('countdown.questions')} {settings.phone}
|
||||
</a>
|
||||
)}
|
||||
{settings.address_city && (
|
||||
<span>
|
||||
{settings.address_street}, {settings.address_zip} {settings.address_city}
|
||||
</span>
|
||||
)}
|
||||
</div>
|
||||
<div className="flex items-center gap-4">
|
||||
<Link to="/impressum" className="transition hover:text-white">Impressum</Link>
|
||||
<Link to="/datenschutz" className="transition hover:text-white">{en ? 'Privacy' : 'Datenschutz'}</Link>
|
||||
<Link to="/admin/login" aria-label={t('maintenance.login')} title={t('maintenance.login')} className="transition hover:text-white">
|
||||
<LogIn className="h-3.5 w-3.5" />
|
||||
</Link>
|
||||
</div>
|
||||
</footer>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
// Schmale Leiste fuer eingeloggte Admins auf der normalen Seite, solange Besucher den Teaser sehen.
|
||||
export function CountdownAdminBanner({ countdown }) {
|
||||
const { t, language } = useLanguage();
|
||||
const date = new Date(countdown.launch_at).toLocaleString(language === 'en' ? 'en-GB' : 'de-DE', {
|
||||
day: '2-digit',
|
||||
month: '2-digit',
|
||||
year: 'numeric',
|
||||
hour: '2-digit',
|
||||
minute: '2-digit',
|
||||
timeZone: 'Europe/Berlin',
|
||||
});
|
||||
return (
|
||||
<div className="bg-neutral-900 px-4 py-2 text-center text-xs font-semibold text-neutral-200">
|
||||
<span className="mr-2 inline-block h-1.5 w-1.5 rounded-full bg-brand-400 align-middle" />
|
||||
{t('countdown.adminActive').replace('{date}', date)}{' '}
|
||||
<Link to="/?countdown=vorschau" className="text-brand-300 underline hover:text-brand-200">
|
||||
{t('countdown.adminPreview')}
|
||||
</Link>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
|
@ -1,11 +1,12 @@
|
|||
import { Suspense, useEffect, useState } from 'react';
|
||||
import { Navigate, Outlet, useLocation } from 'react-router-dom';
|
||||
import { Navigate, Outlet, useLocation, useNavigate } from 'react-router-dom';
|
||||
import Navbar from './Navbar.jsx';
|
||||
import Footer from './Footer.jsx';
|
||||
import ScrollProgress from './ScrollProgress.jsx';
|
||||
import MaintenanceNotice from './MaintenanceNotice.jsx';
|
||||
import MaintenanceBypassBanner from './MaintenanceBypassBanner.jsx';
|
||||
import CookieConsentBanner from './CookieConsentBanner.jsx';
|
||||
import CountdownTeaser, { CountdownAdminBanner, countdownClockOffset, countdownRemaining } from './CountdownTeaser.jsx';
|
||||
import GoogleAnalytics from './GoogleAnalytics.jsx';
|
||||
import { MaintenanceProvider } from '../context/MaintenanceContext.jsx';
|
||||
import { SiteSettingsProvider } from '../context/SiteSettingsContext.jsx';
|
||||
|
|
@ -134,13 +135,20 @@ export default function PublicLayout() {
|
|||
const [siteSettingsLoaded, setSiteSettingsLoaded] = useState(!!cachedSettings);
|
||||
const [textStyles, setTextStyles] = useState({});
|
||||
const [customFonts, setCustomFonts] = useState([]);
|
||||
const { loading: authLoading, hasPermission } = useAuth();
|
||||
const { loading: authLoading, hasPermission, user } = useAuth();
|
||||
const location = useLocation();
|
||||
const navigate = useNavigate();
|
||||
// Wird true, sobald der Countdown waehrend des Besuchs auf 0 laeuft - dann oeffnet sich die Seite.
|
||||
const [countdownFinished, setCountdownFinished] = useState(false);
|
||||
// Fuer die Admin-Vorschau ohne gesetzten (oder mit abgelaufenem) Startzeitpunkt.
|
||||
const [demoLaunchAt] = useState(() => new Date(Date.now() + (7 * 24 + 3) * 3600 * 1000 + 42 * 60 * 1000).toISOString());
|
||||
|
||||
useEffect(() => {
|
||||
api
|
||||
.get('/maintenance')
|
||||
.then((data) => {
|
||||
.then((response) => {
|
||||
// Empfangszeit merken: daraus rechnet der Countdown den Versatz zur Server-Uhr aus.
|
||||
const data = { ...response, _received_at: Date.now() };
|
||||
setStatus(data);
|
||||
writeCache(STATUS_CACHE_KEY, data);
|
||||
})
|
||||
|
|
@ -172,15 +180,42 @@ export default function PublicLayout() {
|
|||
if (siteSettingsLoaded) updateBusinessJsonLd(siteSettings);
|
||||
}, [siteSettings, siteSettingsLoaded]);
|
||||
|
||||
// Auf den Login-Status wird nur gewartet, wenn die Wartung aktiv ist (dann entscheidet er,
|
||||
// ob ein Admin die Seite trotzdem sieht) - normale Besucher sehen die Seite sofort.
|
||||
if (status === null || !siteSettingsLoaded || (status.global?.enabled && authLoading)) {
|
||||
const countdown = status?.countdown;
|
||||
const clockOffset = countdownClockOffset(countdown, status?._received_at);
|
||||
const countdownRunning = !!countdown?.active && !countdownFinished && countdownRemaining(countdown, clockOffset) > 0;
|
||||
|
||||
// Auf den Login-Status wird nur gewartet, wenn Wartung oder Countdown aktiv ist (dann entscheidet
|
||||
// er, ob ein Admin die Seite trotzdem sieht) - normale Besucher sehen die Seite sofort.
|
||||
if (status === null || !siteSettingsLoaded || ((status.global?.enabled || countdownRunning) && authLoading)) {
|
||||
return <div className="min-h-screen bg-white dark:bg-neutral-950" />;
|
||||
}
|
||||
|
||||
const bypass = hasPermission('maintenance.bypass');
|
||||
const isLegalPage = LEGAL_PATHS.includes(location.pathname);
|
||||
|
||||
// Countdown-Teaser vor dem Launch: Besucher sehen nur den Countdown, eingeloggte Admins die
|
||||
// normale Seite. Mit /?countdown=vorschau sehen Admins den Teaser trotzdem.
|
||||
const countdownPreview = !!user && new URLSearchParams(location.search).get('countdown') === 'vorschau';
|
||||
if (!isLegalPage && ((countdownRunning && !user) || countdownPreview)) {
|
||||
const shown = countdownPreview && !(countdown?.launch_at && countdownRemaining(countdown, clockOffset) > 0)
|
||||
? { ...countdown, launch_at: demoLaunchAt }
|
||||
: countdown;
|
||||
return (
|
||||
<LiveEditProvider serverOverrides={siteSettings.text_overrides}>
|
||||
<LanguageProvider>
|
||||
<CountdownTeaser
|
||||
countdown={shown}
|
||||
clockOffset={shown === countdown ? clockOffset : 0}
|
||||
settings={siteSettings}
|
||||
preview={countdownPreview}
|
||||
onClosePreview={() => navigate('/', { replace: true })}
|
||||
onLaunch={() => setCountdownFinished(true)}
|
||||
/>
|
||||
</LanguageProvider>
|
||||
</LiveEditProvider>
|
||||
);
|
||||
}
|
||||
|
||||
if (status.global.enabled && !bypass && !isLegalPage) {
|
||||
return (
|
||||
<LiveEditProvider serverOverrides={siteSettings.text_overrides}>
|
||||
|
|
@ -201,6 +236,7 @@ export default function PublicLayout() {
|
|||
<div className="page-texture flex min-h-screen flex-col text-neutral-900 dark:text-neutral-100">
|
||||
<CustomFontFaces />
|
||||
{bypass && status.global.enabled && <MaintenanceBypassBanner />}
|
||||
{!!user && countdownRunning && <CountdownAdminBanner countdown={countdown} />}
|
||||
<ScrollProgress />
|
||||
<Navbar />
|
||||
<main className="flex-1">
|
||||
|
|
|
|||
|
|
@ -63,6 +63,28 @@ export default {
|
|||
defaultMessage: 'Dieser Bereich wird gerade aktualisiert. Bitte schau in Kürze wieder vorbei.',
|
||||
login: 'Anmelden',
|
||||
},
|
||||
countdown: {
|
||||
eyebrow: 'Neue Website · Bald live',
|
||||
title: 'Bald wird’s laut.',
|
||||
message: 'Wir drehen gerade die letzten Schrauben fest. Unsere neue Website mit allen Paketen für dein Fahrzeug startet in Kürze.',
|
||||
days: 'Tage',
|
||||
hours: 'Stunden',
|
||||
minutes: 'Minuten',
|
||||
seconds: 'Sekunden',
|
||||
launchPrefix: 'Start',
|
||||
launchAt: 'um',
|
||||
clock: 'Uhr',
|
||||
addToCalendar: 'In den Kalender',
|
||||
calendarTitle: 'Launch der neuen HifiPlanet-Website',
|
||||
questions: 'Fragen vorab?',
|
||||
liveEyebrow: 'Neue Website · Jetzt online',
|
||||
liveTitle: 'Wir sind live!',
|
||||
liveMessage: 'Einen Moment, die Seite öffnet sich …',
|
||||
preview: 'Vorschau – nur für dich sichtbar',
|
||||
closePreview: 'Vorschau schließen',
|
||||
adminActive: 'Countdown aktiv – Besucher sehen bis {date} nur den Teaser.',
|
||||
adminPreview: 'Vorschau ansehen',
|
||||
},
|
||||
lightbox: {
|
||||
close: 'Schließen',
|
||||
previous: 'Vorheriges Bild',
|
||||
|
|
|
|||
|
|
@ -63,6 +63,28 @@ export default {
|
|||
defaultMessage: 'This area is currently being updated. Please check back shortly.',
|
||||
login: 'Log in',
|
||||
},
|
||||
countdown: {
|
||||
eyebrow: 'New website · Coming soon',
|
||||
title: 'Things are about to get loud.',
|
||||
message: 'We are tightening the last screws. Our new website with every package for your vehicle launches shortly.',
|
||||
days: 'Days',
|
||||
hours: 'Hours',
|
||||
minutes: 'Minutes',
|
||||
seconds: 'Seconds',
|
||||
launchPrefix: 'Launch',
|
||||
launchAt: 'at',
|
||||
clock: '',
|
||||
addToCalendar: 'Add to calendar',
|
||||
calendarTitle: 'Launch of the new HifiPlanet website',
|
||||
questions: 'Questions?',
|
||||
liveEyebrow: 'New website · Now online',
|
||||
liveTitle: 'We are live!',
|
||||
liveMessage: 'One moment, the site is opening …',
|
||||
preview: 'Preview – only visible to you',
|
||||
closePreview: 'Close preview',
|
||||
adminActive: 'Countdown active – visitors only see the teaser until {date}.',
|
||||
adminPreview: 'Open preview',
|
||||
},
|
||||
lightbox: {
|
||||
close: 'Close',
|
||||
previous: 'Previous image',
|
||||
|
|
|
|||
|
|
@ -349,3 +349,31 @@ html.hifi-cursor-on :is(input, textarea, [contenteditable='true']) {
|
|||
opacity: 0.5;
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
/* Countdown-Teaser vor dem Launch (components/CountdownTeaser.jsx): Equalizer-Balken und ein
|
||||
ganz langsamer Zoom auf das Hintergrundfoto. */
|
||||
@keyframes countdown-eq {
|
||||
0%, 100% { transform: scaleY(0.25); }
|
||||
35% { transform: scaleY(1); }
|
||||
60% { transform: scaleY(0.45); }
|
||||
80% { transform: scaleY(0.8); }
|
||||
}
|
||||
.countdown-eq-bar {
|
||||
animation: countdown-eq 1.6s ease-in-out infinite;
|
||||
}
|
||||
@keyframes countdown-kenburns {
|
||||
from { transform: scale(1.05); }
|
||||
to { transform: scale(1.18) translateY(-2%); }
|
||||
}
|
||||
.countdown-kenburns {
|
||||
animation: countdown-kenburns 30s ease-in-out infinite alternate;
|
||||
}
|
||||
@media (prefers-reduced-motion: reduce) {
|
||||
.countdown-eq-bar,
|
||||
.countdown-kenburns {
|
||||
animation: none;
|
||||
}
|
||||
.countdown-eq-bar {
|
||||
transform: scaleY(0.5);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -239,6 +239,7 @@ function QuickLinks({ hasPermission }) {
|
|||
{ to: '/admin/home-sections', label: 'Startseiten-Texte ändern', show: hasPermission('content.manage') },
|
||||
{ to: '/admin/settings/company', label: 'Öffnungszeiten & Kontakt', show: hasPermission('settings.manage') },
|
||||
{ to: '/admin/settings/maintenance', label: 'Wartungsmodus', show: hasPermission('settings.manage') },
|
||||
{ to: '/admin/settings/countdown', label: 'Launch-Countdown', show: hasPermission('settings.manage') },
|
||||
].filter((l) => l.show);
|
||||
return (
|
||||
<section className="rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900">
|
||||
|
|
|
|||
167
hifi-src/src/pages/admin/settings/CountdownSettings.jsx
Normal file
167
hifi-src/src/pages/admin/settings/CountdownSettings.jsx
Normal file
|
|
@ -0,0 +1,167 @@
|
|||
import { useEffect, useState } from 'react';
|
||||
import { api } from '../../../api/client.js';
|
||||
|
||||
const emptyForm = { enabled: false, launch_at: '', title: '', title_en: '', message: '', message_en: '' };
|
||||
|
||||
const toForm = (countdown = {}) => ({
|
||||
enabled: !!countdown.enabled,
|
||||
launch_at: countdown.launch_at_local || '',
|
||||
title: countdown.title || '',
|
||||
title_en: countdown.title_en || '',
|
||||
message: countdown.message || '',
|
||||
message_en: countdown.message_en || '',
|
||||
});
|
||||
|
||||
// Der Zeitpunkt wird als deutsche Ortszeit gespeichert (siehe MaintenanceController::countdown);
|
||||
// fuer die Restzeit-Anzeige hier reicht die Uhr des Browsers.
|
||||
function remainingLabel(launchAt) {
|
||||
if (!launchAt) return null;
|
||||
const ms = new Date(launchAt).getTime() - Date.now();
|
||||
if (Number.isNaN(ms)) return null;
|
||||
if (ms <= 0) return { past: true, text: 'Der Zeitpunkt liegt in der Vergangenheit – der Countdown wird Besuchern nicht angezeigt.' };
|
||||
const minutes = Math.floor(ms / 60000);
|
||||
const days = Math.floor(minutes / 1440);
|
||||
const hours = Math.floor((minutes % 1440) / 60);
|
||||
const mins = minutes % 60;
|
||||
const parts = [days && `${days} ${days === 1 ? 'Tag' : 'Tage'}`, hours && `${hours} Std.`, `${mins} Min.`].filter(Boolean);
|
||||
return { past: false, text: `Noch ${parts.join(' ')} bis zum Start.` };
|
||||
}
|
||||
|
||||
const inputClass = 'w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900';
|
||||
const labelClass = 'mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300';
|
||||
|
||||
export default function CountdownSettings() {
|
||||
const [form, setForm] = useState(emptyForm);
|
||||
const [loading, setLoading] = useState(true);
|
||||
const [busy, setBusy] = useState(false);
|
||||
const [saved, setSaved] = useState(false);
|
||||
const [error, setError] = useState('');
|
||||
const [, setTick] = useState(0);
|
||||
|
||||
useEffect(() => {
|
||||
api.get('/maintenance').then((res) => setForm(toForm(res.countdown))).finally(() => setLoading(false));
|
||||
}, []);
|
||||
|
||||
// Restzeit-Hinweis jede Minute aktualisieren.
|
||||
useEffect(() => {
|
||||
const timer = setInterval(() => setTick((n) => n + 1), 30000);
|
||||
return () => clearInterval(timer);
|
||||
}, []);
|
||||
|
||||
const update = (field, value) => {
|
||||
setForm((f) => ({ ...f, [field]: value }));
|
||||
setSaved(false);
|
||||
};
|
||||
|
||||
const handleSave = async (e) => {
|
||||
e.preventDefault();
|
||||
setBusy(true);
|
||||
setError('');
|
||||
setSaved(false);
|
||||
try {
|
||||
const result = await api.post('/countdown', form);
|
||||
setForm(toForm(result.countdown));
|
||||
setSaved(true);
|
||||
} catch (err) {
|
||||
setError(err.message);
|
||||
} finally {
|
||||
setBusy(false);
|
||||
}
|
||||
};
|
||||
|
||||
if (loading) {
|
||||
return <p className="text-sm text-neutral-400">Lädt…</p>;
|
||||
}
|
||||
|
||||
const remaining = remainingLabel(form.launch_at);
|
||||
const live = form.enabled && remaining && !remaining.past;
|
||||
|
||||
return (
|
||||
<form onSubmit={handleSave} className="max-w-2xl space-y-6">
|
||||
<section className="rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900">
|
||||
<div className="mb-1 flex items-center justify-between gap-3">
|
||||
<h2 className="font-semibold text-neutral-900 dark:text-white">Countdown anzeigen</h2>
|
||||
<label className="relative inline-flex cursor-pointer items-center">
|
||||
<input
|
||||
type="checkbox"
|
||||
checked={form.enabled}
|
||||
onChange={(e) => update('enabled', e.target.checked)}
|
||||
className="peer sr-only"
|
||||
/>
|
||||
<div className="h-6 w-11 rounded-full bg-neutral-200 transition peer-checked:bg-brand-500 dark:bg-neutral-700" />
|
||||
<div className="absolute left-1 top-1 h-4 w-4 rounded-full bg-white transition peer-checked:translate-x-5" />
|
||||
</label>
|
||||
</div>
|
||||
<p className="mb-4 text-sm text-neutral-500 dark:text-neutral-400">
|
||||
Besucher sehen statt der Website nur den Countdown bis zum Start. Ist der Zeitpunkt erreicht, öffnet sich die
|
||||
Website automatisch – du musst nichts mehr ausschalten. Eingeloggt siehst du weiterhin die normale Seite.
|
||||
</p>
|
||||
|
||||
<label className={labelClass} htmlFor="countdown-launch">Start (deutsche Zeit)</label>
|
||||
<input
|
||||
id="countdown-launch"
|
||||
type="datetime-local"
|
||||
value={form.launch_at}
|
||||
onChange={(e) => update('launch_at', e.target.value)}
|
||||
required={form.enabled}
|
||||
className={`${inputClass} max-w-xs`}
|
||||
/>
|
||||
{remaining && (
|
||||
<p className={`mt-2 text-sm ${remaining.past ? 'text-amber-600 dark:text-amber-400' : 'text-neutral-500 dark:text-neutral-400'}`}>
|
||||
{remaining.text}
|
||||
</p>
|
||||
)}
|
||||
|
||||
<div className="mt-4 flex flex-wrap items-center gap-3">
|
||||
<span
|
||||
className={`inline-flex items-center gap-2 rounded-full px-3 py-1 text-xs font-semibold ${
|
||||
live ? 'bg-brand-100 text-brand-700 dark:bg-brand-900/40 dark:text-brand-300' : 'bg-neutral-100 text-neutral-600 dark:bg-neutral-800 dark:text-neutral-400'
|
||||
}`}
|
||||
>
|
||||
<span className={`h-1.5 w-1.5 rounded-full ${live ? 'bg-brand-500' : 'bg-neutral-400'}`} />
|
||||
{live ? 'Besucher sehen den Countdown (nach dem Speichern)' : 'Besucher sehen die normale Website'}
|
||||
</span>
|
||||
<a href={`${import.meta.env.BASE_URL}?countdown=vorschau`} target="_blank" rel="noreferrer" className="text-sm font-medium text-brand-600 underline hover:text-brand-700 dark:text-brand-400">
|
||||
Vorschau öffnen
|
||||
</a>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section className="rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900">
|
||||
<h2 className="mb-1 font-semibold text-neutral-900 dark:text-white">Texte (optional)</h2>
|
||||
<p className="mb-4 text-sm text-neutral-500 dark:text-neutral-400">
|
||||
Leer lassen für die Standardtexte („Bald wird’s laut.“). Ohne englischen Text sehen englische Besucher den Standardtext.
|
||||
</p>
|
||||
<div className="grid gap-4 sm:grid-cols-2">
|
||||
<div>
|
||||
<label className={labelClass} htmlFor="countdown-title">Überschrift</label>
|
||||
<input id="countdown-title" maxLength={150} value={form.title} onChange={(e) => update('title', e.target.value)} placeholder="Bald wird’s laut." className={inputClass} />
|
||||
</div>
|
||||
<div>
|
||||
<label className={labelClass} htmlFor="countdown-title-en">Überschrift (Englisch)</label>
|
||||
<input id="countdown-title-en" maxLength={150} value={form.title_en} onChange={(e) => update('title_en', e.target.value)} placeholder="Things are about to get loud." className={inputClass} />
|
||||
</div>
|
||||
<div>
|
||||
<label className={labelClass} htmlFor="countdown-message">Text</label>
|
||||
<textarea id="countdown-message" rows={3} maxLength={500} value={form.message} onChange={(e) => update('message', e.target.value)} placeholder="Wir drehen gerade die letzten Schrauben fest …" className={inputClass} />
|
||||
</div>
|
||||
<div>
|
||||
<label className={labelClass} htmlFor="countdown-message-en">Text (Englisch)</label>
|
||||
<textarea id="countdown-message-en" rows={3} maxLength={500} value={form.message_en} onChange={(e) => update('message_en', e.target.value)} placeholder="We are tightening the last screws …" className={inputClass} />
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
{error && <p className="text-sm text-red-600">{error}</p>}
|
||||
{saved && <p className="text-sm text-green-600 dark:text-green-400">Gespeichert.</p>}
|
||||
|
||||
<button
|
||||
type="submit"
|
||||
disabled={busy}
|
||||
className="rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50"
|
||||
>
|
||||
{busy ? 'Speichere…' : 'Speichern'}
|
||||
</button>
|
||||
</form>
|
||||
);
|
||||
}
|
||||
|
|
@ -8,6 +8,7 @@ const PAGES = {
|
|||
design: ['Aussehen', 'Titelbild, Schriften und das Aussehen der Kacheln auf der Website.'],
|
||||
legal: ['Rechtstexte', 'Impressum, Datenschutzerklärung und AGB.'],
|
||||
maintenance: ['Wartungsmodus', 'Die ganze Website oder einzelne Bereiche vorübergehend für Besucher sperren.'],
|
||||
countdown: ['Launch-Countdown', 'Vor dem Start nur einen Countdown zeigen, der neugierig macht. Danach öffnet sich die Website von selbst.'],
|
||||
email: ['E-Mail-Versand', 'Zugangsdaten des Mail-Servers und die Texte der automatischen E-Mails.'],
|
||||
google: ['Google-Dienste', 'Google Analytics und Google-Bewertungen anbinden. Nur für Techniker.'],
|
||||
database: ['Datenbank', 'Verbindung und Struktur der Datenbank. Nur für Techniker.'],
|
||||
|
|
|
|||
8
hifi/api/database/migration_countdown.sql
Normal file
8
hifi/api/database/migration_countdown.sql
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
-- Countdown-Teaser vor dem Launch (Einstellungen > Countdown).
|
||||
-- Wird auch automatisch nachgeruestet (SchemaController::ensureCurrent).
|
||||
ALTER TABLE app_settings ADD COLUMN countdown_enabled TINYINT(1) NOT NULL DEFAULT 0;
|
||||
ALTER TABLE app_settings ADD COLUMN countdown_launch_at DATETIME NULL;
|
||||
ALTER TABLE app_settings ADD COLUMN countdown_title VARCHAR(150) NULL;
|
||||
ALTER TABLE app_settings ADD COLUMN countdown_title_en VARCHAR(150) NULL;
|
||||
ALTER TABLE app_settings ADD COLUMN countdown_message VARCHAR(500) NULL;
|
||||
ALTER TABLE app_settings ADD COLUMN countdown_message_en VARCHAR(500) NULL;
|
||||
|
|
@ -60,6 +60,12 @@ CREATE TABLE app_settings (
|
|||
mail_owner_body TEXT NULL,
|
||||
price_note VARCHAR(150) NULL,
|
||||
price_note_en VARCHAR(150) NULL,
|
||||
countdown_enabled TINYINT(1) NOT NULL DEFAULT 0,
|
||||
countdown_launch_at DATETIME NULL,
|
||||
countdown_title VARCHAR(150) NULL,
|
||||
countdown_title_en VARCHAR(150) NULL,
|
||||
countdown_message VARCHAR(500) NULL,
|
||||
countdown_message_en VARCHAR(500) NULL,
|
||||
updated_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP
|
||||
) ENGINE=InnoDB;
|
||||
|
||||
|
|
|
|||
|
|
@ -285,6 +285,7 @@ $router->get('/analytics/report', $admin(fn($p) => AnalyticsController::report()
|
|||
|
||||
$router->get('/maintenance', fn($p) => MaintenanceController::status());
|
||||
$router->post('/maintenance', $perm('settings.manage', fn($p) => MaintenanceController::update()));
|
||||
$router->post('/countdown', $perm('settings.manage', fn($p) => MaintenanceController::updateCountdown()));
|
||||
|
||||
$router->get('/site-settings', fn($p) => SiteSettingsController::show());
|
||||
// Live-Bearbeiten-Modus auf der Website: Berechtigung wird je Aenderung im Controller geprueft.
|
||||
|
|
|
|||
|
|
@ -30,9 +30,85 @@ class MaintenanceController
|
|||
'global' => ['enabled' => (bool) $row['maintenance_global'], 'message' => $row['maintenance_global_message']],
|
||||
'services' => ['enabled' => (bool) $row['maintenance_services'], 'message' => $row['maintenance_services_message']],
|
||||
'vehicles' => ['enabled' => (bool) $row['maintenance_vehicles'], 'message' => $row['maintenance_vehicles_message']],
|
||||
'countdown' => self::countdown($row),
|
||||
];
|
||||
}
|
||||
|
||||
// Der Startzeitpunkt wird im Admin als deutsche Ortszeit eingegeben und so gespeichert.
|
||||
private const COUNTDOWN_TIMEZONE = 'Europe/Berlin';
|
||||
|
||||
/**
|
||||
* Countdown-Teaser vor dem Launch. "active" ist nur wahr, solange der Schalter an ist UND der
|
||||
* Startzeitpunkt noch in der Zukunft liegt - danach ist die Seite automatisch offen.
|
||||
* server_time erlaubt dem Browser, eine falsch gehende Uhr beim Herunterzaehlen auszugleichen.
|
||||
*/
|
||||
private static function countdown(array $row): array
|
||||
{
|
||||
$tz = new \DateTimeZone(self::COUNTDOWN_TIMEZONE);
|
||||
$now = new \DateTimeImmutable('now', $tz);
|
||||
$launch = null;
|
||||
if (!empty($row['countdown_launch_at'])) {
|
||||
try {
|
||||
$launch = new \DateTimeImmutable($row['countdown_launch_at'], $tz);
|
||||
} catch (\Throwable $e) {
|
||||
$launch = null;
|
||||
}
|
||||
}
|
||||
$enabled = !empty($row['countdown_enabled']);
|
||||
|
||||
return [
|
||||
'enabled' => $enabled,
|
||||
'active' => $enabled && $launch !== null && $launch > $now,
|
||||
'launch_at' => $launch ? $launch->format(DATE_ATOM) : null,
|
||||
'launch_at_local' => $launch ? $launch->format('Y-m-d\\TH:i') : null,
|
||||
'server_time' => $now->format(DATE_ATOM),
|
||||
'title' => $row['countdown_title'] ?? null,
|
||||
'title_en' => $row['countdown_title_en'] ?? null,
|
||||
'message' => $row['countdown_message'] ?? null,
|
||||
'message_en' => $row['countdown_message_en'] ?? null,
|
||||
];
|
||||
}
|
||||
|
||||
public static function updateCountdown(): void
|
||||
{
|
||||
$body = Http::jsonBody();
|
||||
$enabled = !empty($body['enabled']);
|
||||
|
||||
$launch = null;
|
||||
$raw = trim((string) ($body['launch_at'] ?? ''));
|
||||
if ($raw !== '') {
|
||||
$parsed = \DateTimeImmutable::createFromFormat('!Y-m-d\\TH:i', substr($raw, 0, 16), new \DateTimeZone(self::COUNTDOWN_TIMEZONE));
|
||||
if (!$parsed) {
|
||||
Http::error('Bitte einen gültigen Startzeitpunkt angeben.', 422);
|
||||
}
|
||||
$launch = $parsed->format('Y-m-d H:i:s');
|
||||
}
|
||||
if ($enabled && $launch === null) {
|
||||
Http::error('Zum Einschalten braucht der Countdown einen Startzeitpunkt.', 422);
|
||||
}
|
||||
|
||||
$text = fn(string $key, int $max) => mb_substr(trim((string) ($body[$key] ?? '')), 0, $max) ?: null;
|
||||
|
||||
$db = Database::connection();
|
||||
$db->exec('INSERT IGNORE INTO app_settings (id) VALUES (1)');
|
||||
$db->prepare(
|
||||
'UPDATE app_settings SET
|
||||
countdown_enabled = ?, countdown_launch_at = ?,
|
||||
countdown_title = ?, countdown_title_en = ?,
|
||||
countdown_message = ?, countdown_message_en = ?
|
||||
WHERE id = 1'
|
||||
)->execute([
|
||||
$enabled ? 1 : 0,
|
||||
$launch,
|
||||
$text('title', 150),
|
||||
$text('title_en', 150),
|
||||
$text('message', 500),
|
||||
$text('message_en', 500),
|
||||
]);
|
||||
|
||||
Http::send(self::current());
|
||||
}
|
||||
|
||||
public static function status(): void
|
||||
{
|
||||
Http::send(self::current());
|
||||
|
|
|
|||
|
|
@ -48,6 +48,8 @@ class SettingsController
|
|||
'package_card_width', 'package_card_height', 'vehicle_tile_width', 'vehicle_tile_height',
|
||||
'gallery_card_text_x', 'gallery_card_text_y', 'site_font', 'page_loader_enabled', 'hidden_areas',
|
||||
'price_note', 'price_note_en',
|
||||
'countdown_enabled', 'countdown_launch_at', 'countdown_title', 'countdown_title_en',
|
||||
'countdown_message', 'countdown_message_en',
|
||||
'mail_host', 'mail_port', 'mail_username', 'mail_encryption',
|
||||
'mail_from_email', 'mail_from_name', 'mail_notify_email',
|
||||
'mail_customer_subject', 'mail_customer_body', 'mail_owner_subject', 'mail_owner_body',
|
||||
|
|
|
|||
|
|
@ -77,6 +77,12 @@ class Schema
|
|||
mail_owner_body TEXT NULL,
|
||||
price_note VARCHAR(150) NULL,
|
||||
price_note_en VARCHAR(150) NULL,
|
||||
countdown_enabled TINYINT(1) NOT NULL DEFAULT 0,
|
||||
countdown_launch_at DATETIME NULL,
|
||||
countdown_title VARCHAR(150) NULL,
|
||||
countdown_title_en VARCHAR(150) NULL,
|
||||
countdown_message VARCHAR(500) NULL,
|
||||
countdown_message_en VARCHAR(500) NULL,
|
||||
updated_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP
|
||||
) ENGINE=InnoDB",
|
||||
|
||||
|
|
@ -458,6 +464,12 @@ class Schema
|
|||
'mail_owner_body' => 'TEXT NULL',
|
||||
'price_note' => 'VARCHAR(150) NULL',
|
||||
'price_note_en' => 'VARCHAR(150) NULL',
|
||||
'countdown_enabled' => 'TINYINT(1) NOT NULL DEFAULT 0',
|
||||
'countdown_launch_at' => 'DATETIME NULL',
|
||||
'countdown_title' => 'VARCHAR(150) NULL',
|
||||
'countdown_title_en' => 'VARCHAR(150) NULL',
|
||||
'countdown_message' => 'VARCHAR(500) NULL',
|
||||
'countdown_message_en' => 'VARCHAR(500) NULL',
|
||||
'updated_at' => 'DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP',
|
||||
],
|
||||
'legal_pages' => [
|
||||
|
|
|
|||
|
|
@ -1 +0,0 @@
|
|||
import{j as e}from"./index-DPjtOB4k.js";import{L as i}from"./LegalPageView-CftQhY6B.js";function n(){return e.jsx(i,{slug:"agb",fallbackTitle:"AGB",description:"Allgemeine Geschäftsbedingungen von HifiPlanet Amorbach."})}export{n as default};
|
||||
1
hifi/assets/AGB-D95D02hw.js
Normal file
1
hifi/assets/AGB-D95D02hw.js
Normal file
|
|
@ -0,0 +1 @@
|
|||
import{j as e}from"./index-BZm7WrzT.js";import{L as i}from"./LegalPageView-BadVFDdZ.js";function n(){return e.jsx(i,{slug:"agb",fallbackTitle:"AGB",description:"Allgemeine Geschäftsbedingungen von HifiPlanet Amorbach."})}export{n as default};
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
1
hifi/assets/CountdownSettings-BbQGxn41.js
Normal file
1
hifi/assets/CountdownSettings-BbQGxn41.js
Normal file
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
|
@ -1 +1 @@
|
|||
import{j as t}from"./index-DPjtOB4k.js";import{L as e}from"./LegalPageView-CftQhY6B.js";function n(){return t.jsx(e,{slug:"datenschutz",fallbackTitle:"Datenschutzerklärung",description:"Datenschutzerklärung von HifiPlanet Amorbach gemäß Art. 13 DSGVO."})}export{n as default};
|
||||
import{j as t}from"./index-BZm7WrzT.js";import{L as e}from"./LegalPageView-BadVFDdZ.js";function n(){return t.jsx(e,{slug:"datenschutz",fallbackTitle:"Datenschutzerklärung",description:"Datenschutzerklärung von HifiPlanet Amorbach gemäß Art. 13 DSGVO."})}export{n as default};
|
||||
File diff suppressed because one or more lines are too long
|
|
@ -1 +1 @@
|
|||
import{r,u as y,b as v,j as e,e as S,R as D,c as I}from"./index-DPjtOB4k.js";import{f as _,a as E,b as F,i as L}from"./downloads-B9pqFegV.js";import{L as C,F as p,a as R,b as T,c as U,M,D as A}from"./music-KHqYrHBN.js";const K={audio:M,video:U,pdf:p,image:T,archive:R,document:p},n="hifi-downloads-password",z=()=>{try{return localStorage.getItem(n)||""}catch{return""}},f=t=>{try{t?localStorage.setItem(n,t):localStorage.removeItem(n)}catch{}},g=t=>I.get("/downloads",t?{headers:{"X-Download-Password":encodeURIComponent(t)}}:void 0);function W(){const[t,i]=r.useState(null),[c,x]=r.useState(!1),[o,b]=r.useState(""),[j,m]=r.useState(!1),[u,h]=r.useState(!1),[d,w]=r.useState(null),{t:s,language:k}=y();r.useEffect(()=>{const a=z();g(a).then(l=>{l.locked?(a&&f(""),x(!0)):i(l.items)}).catch(l=>w(l))},[]);const N=async a=>{a.preventDefault(),h(!0),m(!1);try{const l=await g(o);l.locked?m(!0):(f(o),x(!1),i(l.items))}catch(l){w(l.message)}finally{h(!1)}};return v({title:s("downloadsPage.metaTitle"),description:s("downloadsPage.metaDescription"),path:"/downloads"}),e.jsxs("div",{className:"mx-auto max-w-4xl px-4 py-12 sm:px-6",children:[e.jsx("h1",{className:"mb-2 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:s("downloadsPage.title")}),e.jsx("p",{className:"mb-10 max-w-2xl text-neutral-600 dark:text-neutral-300",children:s("downloadsPage.intro")}),d&&e.jsx("p",{className:"text-red-600",children:typeof d=="string"?d:S(d,s)}),!d&&!c&&t===null&&e.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:s("downloadsPage.loading")}),(t==null?void 0:t.length)===0&&e.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:s("downloadsPage.empty")}),c&&e.jsxs("form",{onSubmit:N,className:"max-w-md rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsxs("div",{className:"mb-2 flex items-center gap-2",children:[e.jsx(C,{className:"h-5 w-5 text-brand-500","aria-hidden":"true"}),e.jsx("h2",{className:"font-semibold text-neutral-900 dark:text-white",children:s("downloadsPage.lockedTitle")})]}),e.jsx("p",{className:"mb-4 text-sm text-neutral-600 dark:text-neutral-300",children:s("downloadsPage.lockedText")}),e.jsx("label",{htmlFor:"downloads-password",className:"sr-only",children:s("downloadsPage.passwordLabel")}),e.jsxs("div",{className:"flex flex-col gap-2 sm:flex-row",children:[e.jsx("input",{id:"downloads-password",type:"password",required:!0,autoComplete:"off",value:o,onChange:a=>b(a.target.value),placeholder:s("downloadsPage.passwordLabel"),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm text-neutral-900 dark:border-neutral-700 dark:bg-neutral-950 dark:text-white"}),e.jsx("button",{type:"submit",disabled:u,className:"shrink-0 rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:s(u?"downloadsPage.unlocking":"downloadsPage.unlock")})]}),j&&e.jsx("p",{className:"mt-2 text-sm text-red-600",role:"alert",children:s("downloadsPage.wrongPassword")})]}),e.jsx("div",{className:"space-y-4",children:t==null?void 0:t.map((a,l)=>{const P=K[_(a.file_name)];return e.jsx(D,{index:l%4,className:"rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:e.jsxs("div",{className:"flex flex-col gap-4 sm:flex-row sm:items-start",children:[e.jsx("div",{className:"flex h-12 w-12 shrink-0 items-center justify-center rounded-full bg-brand-500/10 text-brand-600 dark:text-brand-400",children:e.jsx(P,{className:"h-6 w-6","aria-hidden":"true"})}),e.jsxs("div",{className:"min-w-0 flex-1",children:[e.jsx("h2",{className:"font-semibold text-neutral-900 dark:text-white",children:a.title}),a.description&&e.jsx("p",{className:"mt-1 whitespace-pre-line text-sm text-neutral-600 dark:text-neutral-300",children:a.description}),e.jsxs("p",{className:"mt-1 text-xs text-neutral-400",children:[E(a.file_name).toUpperCase()," · ",F(a.file_size,k==="de"?"de-DE":"en-US")]}),L(a.file_name)&&e.jsx("audio",{controls:!0,preload:"none",src:a.file_path,className:"mt-3 w-full"})]}),e.jsxs("a",{href:a.file_path,download:a.file_name,className:"inline-flex shrink-0 items-center justify-center gap-2 rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:[e.jsx(A,{className:"h-4 w-4","aria-hidden":"true"}),s("downloadsPage.download")]})]})},a.id)})})]})}export{W as default};
|
||||
import{r,u as y,b as v,j as e,e as S,R as D,c as I}from"./index-BZm7WrzT.js";import{f as _,a as E,b as F,i as L}from"./downloads-B9pqFegV.js";import{L as C,F as p,a as R,b as T,c as U,M,D as A}from"./music-C2A-vRpg.js";const K={audio:M,video:U,pdf:p,image:T,archive:R,document:p},n="hifi-downloads-password",z=()=>{try{return localStorage.getItem(n)||""}catch{return""}},f=t=>{try{t?localStorage.setItem(n,t):localStorage.removeItem(n)}catch{}},g=t=>I.get("/downloads",t?{headers:{"X-Download-Password":encodeURIComponent(t)}}:void 0);function W(){const[t,i]=r.useState(null),[c,x]=r.useState(!1),[o,b]=r.useState(""),[j,m]=r.useState(!1),[u,h]=r.useState(!1),[d,w]=r.useState(null),{t:s,language:k}=y();r.useEffect(()=>{const a=z();g(a).then(l=>{l.locked?(a&&f(""),x(!0)):i(l.items)}).catch(l=>w(l))},[]);const N=async a=>{a.preventDefault(),h(!0),m(!1);try{const l=await g(o);l.locked?m(!0):(f(o),x(!1),i(l.items))}catch(l){w(l.message)}finally{h(!1)}};return v({title:s("downloadsPage.metaTitle"),description:s("downloadsPage.metaDescription"),path:"/downloads"}),e.jsxs("div",{className:"mx-auto max-w-4xl px-4 py-12 sm:px-6",children:[e.jsx("h1",{className:"mb-2 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:s("downloadsPage.title")}),e.jsx("p",{className:"mb-10 max-w-2xl text-neutral-600 dark:text-neutral-300",children:s("downloadsPage.intro")}),d&&e.jsx("p",{className:"text-red-600",children:typeof d=="string"?d:S(d,s)}),!d&&!c&&t===null&&e.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:s("downloadsPage.loading")}),(t==null?void 0:t.length)===0&&e.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:s("downloadsPage.empty")}),c&&e.jsxs("form",{onSubmit:N,className:"max-w-md rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsxs("div",{className:"mb-2 flex items-center gap-2",children:[e.jsx(C,{className:"h-5 w-5 text-brand-500","aria-hidden":"true"}),e.jsx("h2",{className:"font-semibold text-neutral-900 dark:text-white",children:s("downloadsPage.lockedTitle")})]}),e.jsx("p",{className:"mb-4 text-sm text-neutral-600 dark:text-neutral-300",children:s("downloadsPage.lockedText")}),e.jsx("label",{htmlFor:"downloads-password",className:"sr-only",children:s("downloadsPage.passwordLabel")}),e.jsxs("div",{className:"flex flex-col gap-2 sm:flex-row",children:[e.jsx("input",{id:"downloads-password",type:"password",required:!0,autoComplete:"off",value:o,onChange:a=>b(a.target.value),placeholder:s("downloadsPage.passwordLabel"),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm text-neutral-900 dark:border-neutral-700 dark:bg-neutral-950 dark:text-white"}),e.jsx("button",{type:"submit",disabled:u,className:"shrink-0 rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:s(u?"downloadsPage.unlocking":"downloadsPage.unlock")})]}),j&&e.jsx("p",{className:"mt-2 text-sm text-red-600",role:"alert",children:s("downloadsPage.wrongPassword")})]}),e.jsx("div",{className:"space-y-4",children:t==null?void 0:t.map((a,l)=>{const P=K[_(a.file_name)];return e.jsx(D,{index:l%4,className:"rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:e.jsxs("div",{className:"flex flex-col gap-4 sm:flex-row sm:items-start",children:[e.jsx("div",{className:"flex h-12 w-12 shrink-0 items-center justify-center rounded-full bg-brand-500/10 text-brand-600 dark:text-brand-400",children:e.jsx(P,{className:"h-6 w-6","aria-hidden":"true"})}),e.jsxs("div",{className:"min-w-0 flex-1",children:[e.jsx("h2",{className:"font-semibold text-neutral-900 dark:text-white",children:a.title}),a.description&&e.jsx("p",{className:"mt-1 whitespace-pre-line text-sm text-neutral-600 dark:text-neutral-300",children:a.description}),e.jsxs("p",{className:"mt-1 text-xs text-neutral-400",children:[E(a.file_name).toUpperCase()," · ",F(a.file_size,k==="de"?"de-DE":"en-US")]}),L(a.file_name)&&e.jsx("audio",{controls:!0,preload:"none",src:a.file_path,className:"mt-3 w-full"})]}),e.jsxs("a",{href:a.file_path,download:a.file_name,className:"inline-flex shrink-0 items-center justify-center gap-2 rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:[e.jsx(A,{className:"h-4 w-4","aria-hidden":"true"}),s("downloadsPage.download")]})]})},a.id)})})]})}export{W as default};
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
|
@ -1 +1 @@
|
|||
import{g,r as n,u as m,a as u,c as p,b as h,j as a,N as b,e as f,L as d,d as y,f as j}from"./index-DPjtOB4k.js";function N(){const{brandSlug:s}=g(),[e,i]=n.useState(null),[l,x]=n.useState(null),{t:r}=m(),{gallery_card_text_x:o,gallery_card_text_y:c}=u();return n.useEffect(()=>{p.get(`/gallery-brands/${s}/projects`).then(i).catch(t=>x(t))},[s]),h({title:e?r("galleryBrandPage.metaTitle")(e.brand.name):r("galleryBrandPage.metaTitleFallback"),description:e?r("galleryBrandPage.metaDescription")(e.brand.name):void 0,path:`/galerie/${s}`}),l?l.status===404?a.jsx(b,{}):a.jsx("p",{className:"mx-auto max-w-6xl px-4 py-12 text-red-600 sm:px-6",children:f(l,r)}):e?a.jsxs("div",{className:"mx-auto max-w-6xl px-4 py-12 sm:px-6",children:[a.jsxs("p",{className:"mb-1 text-sm text-neutral-500 dark:text-neutral-400",children:[a.jsx(d,{to:"/galerie",className:"hover:text-brand-500",children:r("galleryBrandPage.breadcrumbGallery")})," / ",e.brand.name]}),a.jsxs("h1",{className:"mb-8 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:[e.brand.name," – ",r("galleryBrandPage.titleSuffix")]}),e.projects.length===0&&a.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:r("galleryBrandPage.empty")}),a.jsx("div",{className:"grid grid-cols-2 gap-4 sm:grid-cols-3 md:grid-cols-4",children:e.projects.map(t=>a.jsxs(d,{to:`/galerie/${s}/${t.slug}`,className:"group relative block aspect-[4/3] overflow-hidden rounded-xl bg-neutral-900 shadow-sm transition hover:shadow-lg",children:[t.cover_image_path?a.jsx("img",{src:t.cover_image_path,alt:t.name,className:"h-full w-full object-cover transition duration-300 group-hover:scale-105"}):a.jsx("div",{className:"flex h-full w-full items-center justify-center bg-neutral-200 dark:bg-neutral-800"}),a.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black/85 via-black/10 to-transparent transition group-hover:from-black/95"}),a.jsx(y,{entity:"gallery_projects",id:t.id,field:"name",lang:"de",value:t.name,className:"absolute whitespace-nowrap p-4 text-lg font-extrabold text-white",style:j(o,c,{x:0,y:100})})]},t.id))})]}):a.jsx("p",{className:"mx-auto max-w-6xl px-4 py-12 text-neutral-500 sm:px-6",children:r("galleryBrandPage.loading")})}export{N as default};
|
||||
import{g,r as n,u as m,a as u,c as p,b as h,j as a,N as b,e as f,L as d,d as y,f as j}from"./index-BZm7WrzT.js";function N(){const{brandSlug:s}=g(),[e,i]=n.useState(null),[l,x]=n.useState(null),{t:r}=m(),{gallery_card_text_x:o,gallery_card_text_y:c}=u();return n.useEffect(()=>{p.get(`/gallery-brands/${s}/projects`).then(i).catch(t=>x(t))},[s]),h({title:e?r("galleryBrandPage.metaTitle")(e.brand.name):r("galleryBrandPage.metaTitleFallback"),description:e?r("galleryBrandPage.metaDescription")(e.brand.name):void 0,path:`/galerie/${s}`}),l?l.status===404?a.jsx(b,{}):a.jsx("p",{className:"mx-auto max-w-6xl px-4 py-12 text-red-600 sm:px-6",children:f(l,r)}):e?a.jsxs("div",{className:"mx-auto max-w-6xl px-4 py-12 sm:px-6",children:[a.jsxs("p",{className:"mb-1 text-sm text-neutral-500 dark:text-neutral-400",children:[a.jsx(d,{to:"/galerie",className:"hover:text-brand-500",children:r("galleryBrandPage.breadcrumbGallery")})," / ",e.brand.name]}),a.jsxs("h1",{className:"mb-8 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:[e.brand.name," – ",r("galleryBrandPage.titleSuffix")]}),e.projects.length===0&&a.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:r("galleryBrandPage.empty")}),a.jsx("div",{className:"grid grid-cols-2 gap-4 sm:grid-cols-3 md:grid-cols-4",children:e.projects.map(t=>a.jsxs(d,{to:`/galerie/${s}/${t.slug}`,className:"group relative block aspect-[4/3] overflow-hidden rounded-xl bg-neutral-900 shadow-sm transition hover:shadow-lg",children:[t.cover_image_path?a.jsx("img",{src:t.cover_image_path,alt:t.name,className:"h-full w-full object-cover transition duration-300 group-hover:scale-105"}):a.jsx("div",{className:"flex h-full w-full items-center justify-center bg-neutral-200 dark:bg-neutral-800"}),a.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black/85 via-black/10 to-transparent transition group-hover:from-black/95"}),a.jsx(y,{entity:"gallery_projects",id:t.id,field:"name",lang:"de",value:t.name,className:"absolute whitespace-nowrap p-4 text-lg font-extrabold text-white",style:j(o,c,{x:0,y:100})})]},t.id))})]}):a.jsx("p",{className:"mx-auto max-w-6xl px-4 py-12 text-neutral-500 sm:px-6",children:r("galleryBrandPage.loading")})}export{N as default};
|
||||
File diff suppressed because one or more lines are too long
|
|
@ -1 +1 @@
|
|||
import{r,u as d,a as g,b as u,c as m,j as e,E as i,e as p,L as v,d as h,f as y}from"./index-DPjtOB4k.js";function w(){const[a,o]=r.useState(null),[l,n]=r.useState(null),{t:s}=d(),{gallery_card_text_x:c,gallery_card_text_y:x}=g();return u({title:s("galleryOverview.metaTitle"),description:s("galleryOverview.metaDescription"),path:"/galerie"}),r.useEffect(()=>{m.get("/gallery-brands").then(o).catch(t=>n(t))},[]),e.jsxs("div",{className:"mx-auto max-w-6xl px-4 py-12 sm:px-6",children:[e.jsx(i,{k:"galleryOverview.title",as:"h1",className:"mb-2 block text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl"}),e.jsx(i,{k:"galleryOverview.intro",as:"p",className:"mb-8 block text-neutral-600 dark:text-neutral-300"}),l&&e.jsx("p",{className:"text-red-600",children:typeof l=="string"?l:p(l,s)}),!a&&!l&&e.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:s("galleryOverview.loading")}),a&&a.length===0&&e.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:s("galleryOverview.empty")}),e.jsx("div",{className:"grid grid-cols-2 gap-4 sm:grid-cols-3 md:grid-cols-4",children:a==null?void 0:a.map(t=>e.jsxs(v,{to:`/galerie/${t.slug}`,className:"group relative block aspect-[4/3] overflow-hidden rounded-xl bg-neutral-900 shadow-sm transition hover:shadow-lg",children:[t.cover_image_path?e.jsx("img",{src:t.cover_image_path,alt:t.name,className:"h-full w-full object-cover transition duration-300 group-hover:scale-105"}):e.jsx("div",{className:"flex h-full w-full items-center justify-center bg-neutral-200 dark:bg-neutral-800"}),e.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black/85 via-black/10 to-transparent transition group-hover:from-black/95"}),e.jsx(h,{entity:"gallery_brands",id:t.id,field:"name",lang:"de",value:t.name,className:"absolute whitespace-nowrap p-4 text-lg font-extrabold text-white",style:y(c,x,{x:0,y:100})})]},t.id))})]})}export{w as default};
|
||||
import{r,u as d,a as g,b as u,c as m,j as e,E as i,e as p,L as v,d as h,f as y}from"./index-BZm7WrzT.js";function w(){const[a,o]=r.useState(null),[l,n]=r.useState(null),{t:s}=d(),{gallery_card_text_x:c,gallery_card_text_y:x}=g();return u({title:s("galleryOverview.metaTitle"),description:s("galleryOverview.metaDescription"),path:"/galerie"}),r.useEffect(()=>{m.get("/gallery-brands").then(o).catch(t=>n(t))},[]),e.jsxs("div",{className:"mx-auto max-w-6xl px-4 py-12 sm:px-6",children:[e.jsx(i,{k:"galleryOverview.title",as:"h1",className:"mb-2 block text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl"}),e.jsx(i,{k:"galleryOverview.intro",as:"p",className:"mb-8 block text-neutral-600 dark:text-neutral-300"}),l&&e.jsx("p",{className:"text-red-600",children:typeof l=="string"?l:p(l,s)}),!a&&!l&&e.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:s("galleryOverview.loading")}),a&&a.length===0&&e.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:s("galleryOverview.empty")}),e.jsx("div",{className:"grid grid-cols-2 gap-4 sm:grid-cols-3 md:grid-cols-4",children:a==null?void 0:a.map(t=>e.jsxs(v,{to:`/galerie/${t.slug}`,className:"group relative block aspect-[4/3] overflow-hidden rounded-xl bg-neutral-900 shadow-sm transition hover:shadow-lg",children:[t.cover_image_path?e.jsx("img",{src:t.cover_image_path,alt:t.name,className:"h-full w-full object-cover transition duration-300 group-hover:scale-105"}):e.jsx("div",{className:"flex h-full w-full items-center justify-center bg-neutral-200 dark:bg-neutral-800"}),e.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black/85 via-black/10 to-transparent transition group-hover:from-black/95"}),e.jsx(h,{entity:"gallery_brands",id:t.id,field:"name",lang:"de",value:t.name,className:"absolute whitespace-nowrap p-4 text-lg font-extrabold text-white",style:y(c,x,{x:0,y:100})})]},t.id))})]})}export{w as default};
|
||||
|
|
@ -1,3 +1,3 @@
|
|||
import{g as z,r as l,q as B,c as d,j as t,L as C}from"./index-DPjtOB4k.js";import{S as M,s as D}from"./SortableList-BJ0lSjmQ.js";import{V as G}from"./ViewOnSite-BpPSiS-X.js";import{r as L,M as A,f as I}from"./resizeImage-C6PvAwh0.js";import"./sortable.esm-DcJMx5eJ.js";import"./grip-vertical-CUuB59gl.js";function J(){const{projectId:m}=z(),[u,h]=l.useState([]),[c,v]=l.useState(null),[f,j]=l.useState(""),[b,w]=l.useState(!1),[$,y]=l.useState(""),p=l.useRef(null),s=B(),x=()=>d.get(`/gallery-projects/${m}/photos`).then(h);l.useEffect(()=>{x(),d.get("/gallery-projects").then(e=>v(e.find(r=>String(r.id)===String(m))||null)).catch(()=>{})},[m]);const F=async e=>{const r=Array.from(e.target.files||[]);if(r.length===0)return;j(""),w(!0);let a=u.reduce((o,i)=>Math.max(o,Number(i.sort_order)||0),0),n=0;const g=[];for(let o=0;o<r.length;o++){y(`Foto ${o+1} von ${r.length} wird hochgeladen…`);try{const i=await L(r[o]);if(i.size>A)throw new Error(`zu groß (${I(i.size)}, max. 5 MB)`);const k=new FormData;k.append("file",i);const E=await d.post("/uploads",k);a+=10,await d.post("/gallery-photos",{gallery_project_id:Number(m),image_path:E.path,sort_order:a}),n++}catch(i){g.push(`${r[o].name}: ${i.message}`)}}w(!1),y(""),p.current&&(p.current.value=""),x(),g.length===0?s.success(n===1?"1 Foto hochgeladen.":`${n} Fotos hochgeladen.`):(j(`Nicht hochgeladen:
|
||||
import{g as z,r as l,q as B,c as d,j as t,L as C}from"./index-BZm7WrzT.js";import{S as M,s as D}from"./SortableList-C5yW5jP-.js";import{V as G}from"./ViewOnSite-Bc0L_bS5.js";import{r as L,M as A,f as I}from"./resizeImage-C6PvAwh0.js";import"./sortable.esm-BCFTlAdF.js";import"./grip-vertical-BM3sslIf.js";function J(){const{projectId:m}=z(),[u,h]=l.useState([]),[c,v]=l.useState(null),[f,j]=l.useState(""),[b,w]=l.useState(!1),[$,y]=l.useState(""),p=l.useRef(null),s=B(),x=()=>d.get(`/gallery-projects/${m}/photos`).then(h);l.useEffect(()=>{x(),d.get("/gallery-projects").then(e=>v(e.find(r=>String(r.id)===String(m))||null)).catch(()=>{})},[m]);const F=async e=>{const r=Array.from(e.target.files||[]);if(r.length===0)return;j(""),w(!0);let a=u.reduce((o,i)=>Math.max(o,Number(i.sort_order)||0),0),n=0;const g=[];for(let o=0;o<r.length;o++){y(`Foto ${o+1} von ${r.length} wird hochgeladen…`);try{const i=await L(r[o]);if(i.size>A)throw new Error(`zu groß (${I(i.size)}, max. 5 MB)`);const k=new FormData;k.append("file",i);const E=await d.post("/uploads",k);a+=10,await d.post("/gallery-photos",{gallery_project_id:Number(m),image_path:E.path,sort_order:a}),n++}catch(i){g.push(`${r[o].name}: ${i.message}`)}}w(!1),y(""),p.current&&(p.current.value=""),x(),g.length===0?s.success(n===1?"1 Foto hochgeladen.":`${n} Fotos hochgeladen.`):(j(`Nicht hochgeladen:
|
||||
${g.join(`
|
||||
`)}`),s.error(`${n} hochgeladen, ${g.length} fehlgeschlagen.`))},P=(e,r)=>{h(a=>a.map(n=>n.id===e.id?{...n,caption:r}:n))},N=l.useRef(null),S=async e=>{if((e.caption||"")!==N.current)try{await d.put(`/gallery-photos/${e.id}`,{caption:e.caption,sort_order:e.sort_order}),s.success("Bildunterschrift gespeichert.")}catch(r){s.error(`Speichern fehlgeschlagen: ${r.message}`)}},_=async e=>{if(confirm("Foto wirklich entfernen?"))try{await d.delete(`/gallery-photos/${e}`),s.success("Foto entfernt."),x()}catch(r){s.error(`Entfernen fehlgeschlagen: ${r.message}`)}},R=async e=>{const r=u;h(e);try{h(await D("gallery-photos",e)),s.success("Reihenfolge gespeichert.")}catch(a){h(r),s.error(`Reihenfolge konnte nicht gespeichert werden: ${a.message}`)}};return t.jsxs("div",{children:[t.jsx("p",{className:"mb-2 text-sm",children:t.jsx(C,{to:"/admin/gallery-projects",className:"text-brand-600 hover:underline",children:"← Zurück zu den Projekten"})}),t.jsxs("div",{className:"mb-4 flex items-center justify-between gap-3",children:[t.jsxs("h1",{className:"text-xl font-bold text-neutral-900 dark:text-white",children:["Fotos im Projekt",c?`: ${c.brand_name} ${c.name}`:""]}),c&&t.jsx(G,{to:`/galerie/${c.brand_slug}/${c.slug}`})]}),t.jsxs("div",{className:"mb-6 rounded-xl border border-neutral-200 bg-white p-4 dark:border-neutral-800 dark:bg-neutral-900",children:[t.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Fotos hinzufügen (Mehrfachauswahl möglich)"}),t.jsx("input",{ref:p,type:"file",multiple:!0,accept:"image/png,image/jpeg,image/webp",onChange:F,disabled:b,className:"text-sm"}),t.jsx("p",{className:"mt-1 text-xs text-neutral-400",children:"JPG, PNG oder WebP, große Fotos werden automatisch verkleinert."}),b&&t.jsx("p",{className:"mt-2 text-sm text-neutral-500","aria-live":"polite",children:$})]}),f&&t.jsx("p",{className:"mb-4 whitespace-pre-line text-sm text-red-600",children:f}),u.length>1&&t.jsx("p",{className:"mb-3 text-xs text-neutral-500 dark:text-neutral-400",children:"Reihenfolge am Griff per Ziehen ändern."}),t.jsx(M,{items:u,onReorder:R,as:"grid",className:"grid grid-cols-2 gap-4 sm:grid-cols-3 md:grid-cols-4",children:(e,r)=>t.jsxs("div",{className:"overflow-hidden rounded-xl border border-neutral-200 bg-white dark:border-neutral-800 dark:bg-neutral-900",children:[t.jsx("img",{src:e.image_path,alt:e.caption||"",className:"aspect-square w-full object-cover",loading:"lazy"}),t.jsxs("div",{className:"space-y-2 p-3",children:[t.jsx("input",{value:e.caption||"",onChange:a=>P(e,a.target.value),onFocus:()=>{N.current=e.caption||""},onBlur:()=>S(e),placeholder:"Bildunterschrift (optional)",className:"w-full rounded-md border border-neutral-300 bg-white px-2 py-1 text-xs dark:border-neutral-700 dark:bg-neutral-900"}),t.jsxs("div",{className:"flex items-center justify-between gap-2",children:[r,t.jsx("button",{onClick:()=>_(e.id),className:"text-xs text-red-600 hover:underline",children:"Entfernen"})]})]})]})}),u.length===0&&t.jsx("p",{className:"py-6 text-center text-neutral-400",children:"Noch keine Fotos in diesem Projekt."})]})}export{J as default};
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
|
@ -1 +1 @@
|
|||
import{r,c as u,j as e}from"./index-DPjtOB4k.js";function h({compact:m=!1}){const[n,i]=r.useState(!1),[s,l]=r.useState(null),[d,o]=r.useState(""),[t,c]=r.useState(null);r.useEffect(()=>{u.get("/settings/compress-status").then(a=>c(a.gd_available)).catch(()=>c(!1))},[]);const b=async()=>{i(!0),o(""),l(null);try{l(await u.post("/settings/compress-uploads",{}))}catch(a){o(a.message)}finally{i(!1)}};return e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsxs("div",{className:"mb-1 flex items-center justify-between gap-3",children:[e.jsx("h2",{className:"font-semibold text-neutral-900 dark:text-white",children:"Bilder optimieren"}),t!==null&&e.jsx("span",{className:`rounded-full px-3 py-1 text-xs font-semibold ${t?"bg-green-100 text-green-700 dark:bg-green-900/40 dark:text-green-300":"bg-red-100 text-red-700 dark:bg-red-900/40 dark:text-red-300"}`,children:t?"Aktiv":"Nicht verfügbar"})]}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:m?"Verkleinert alle bereits hochgeladenen Fotos, damit die Seite schneller lädt. Neue Bilder werden automatisch verkleinert.":"Neu hochgeladene Bilder werden automatisch verkleinert und komprimiert. Dieser Button holt das für alle bereits vorhandenen Bilder nach – nützlich, wenn die Seite durch zu hoch aufgelöste Fotos spürbar langsam lädt."}),t===!1&&e.jsx("p",{className:"mb-4 rounded-md bg-amber-50 p-3 text-sm text-amber-800 dark:bg-amber-900/20 dark:text-amber-300",children:'Diese Funktion braucht die PHP-Erweiterung "gd", die auf diesem Server aktuell nicht aktiv ist. Bei den meisten Hostern (auch All-Inkl) ist sie Teil jeder PHP-Version – bitte beim Hoster-Support nachfragen bzw. prüfen, ob in den Hosting-Einstellungen eine andere PHP-Version ausgewählt werden muss.'}),e.jsx("button",{type:"button",onClick:b,disabled:n||t===!1,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:n?"Optimiert… bitte warten":"Bestehende Bilder optimieren"}),d&&e.jsx("p",{className:"mt-3 text-sm text-red-600",children:d}),s&&e.jsxs("p",{className:"mt-3 text-sm text-green-600 dark:text-green-400",children:[s.processed," Bild(er) verkleinert: ",(s.before_bytes/1024/1024).toFixed(1)," MB"," → ",(s.after_bytes/1024/1024).toFixed(1)," MB."]})]})}export{h as I};
|
||||
import{r,c as u,j as e}from"./index-BZm7WrzT.js";function h({compact:m=!1}){const[n,i]=r.useState(!1),[s,l]=r.useState(null),[d,o]=r.useState(""),[t,c]=r.useState(null);r.useEffect(()=>{u.get("/settings/compress-status").then(a=>c(a.gd_available)).catch(()=>c(!1))},[]);const b=async()=>{i(!0),o(""),l(null);try{l(await u.post("/settings/compress-uploads",{}))}catch(a){o(a.message)}finally{i(!1)}};return e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsxs("div",{className:"mb-1 flex items-center justify-between gap-3",children:[e.jsx("h2",{className:"font-semibold text-neutral-900 dark:text-white",children:"Bilder optimieren"}),t!==null&&e.jsx("span",{className:`rounded-full px-3 py-1 text-xs font-semibold ${t?"bg-green-100 text-green-700 dark:bg-green-900/40 dark:text-green-300":"bg-red-100 text-red-700 dark:bg-red-900/40 dark:text-red-300"}`,children:t?"Aktiv":"Nicht verfügbar"})]}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:m?"Verkleinert alle bereits hochgeladenen Fotos, damit die Seite schneller lädt. Neue Bilder werden automatisch verkleinert.":"Neu hochgeladene Bilder werden automatisch verkleinert und komprimiert. Dieser Button holt das für alle bereits vorhandenen Bilder nach – nützlich, wenn die Seite durch zu hoch aufgelöste Fotos spürbar langsam lädt."}),t===!1&&e.jsx("p",{className:"mb-4 rounded-md bg-amber-50 p-3 text-sm text-amber-800 dark:bg-amber-900/20 dark:text-amber-300",children:'Diese Funktion braucht die PHP-Erweiterung "gd", die auf diesem Server aktuell nicht aktiv ist. Bei den meisten Hostern (auch All-Inkl) ist sie Teil jeder PHP-Version – bitte beim Hoster-Support nachfragen bzw. prüfen, ob in den Hosting-Einstellungen eine andere PHP-Version ausgewählt werden muss.'}),e.jsx("button",{type:"button",onClick:b,disabled:n||t===!1,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:n?"Optimiert… bitte warten":"Bestehende Bilder optimieren"}),d&&e.jsx("p",{className:"mt-3 text-sm text-red-600",children:d}),s&&e.jsxs("p",{className:"mt-3 text-sm text-green-600 dark:text-green-400",children:[s.processed," Bild(er) verkleinert: ",(s.before_bytes/1024/1024).toFixed(1)," MB"," → ",(s.after_bytes/1024/1024).toFixed(1)," MB."]})]})}export{h as I};
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
import{H as mt,r as m,j as u,c as ft}from"./index-DPjtOB4k.js";import{M as gt,f as vt}from"./resizeImage-C6PvAwh0.js";var V=!1,E,Z,k,N,_,rt,W,B,U,H,nt,G,X,st,at;function g(){if(!V){V=!0;var o=navigator.userAgent,e=/(?:MSIE.(\d+\.\d+))|(?:(?:Firefox|GranParadiso|Iceweasel).(\d+\.\d+))|(?:Opera(?:.+Version.|.)(\d+\.\d+))|(?:AppleWebKit.(\d+(?:\.\d+)?))|(?:Trident\/\d+\.\d+.*rv:(\d+\.\d+))/.exec(o),t=/(Mac OS X)|(Windows)|(Linux)/.exec(o);if(G=/\b(iPhone|iP[ao]d)/.exec(o),X=/\b(iP[ao]d)/.exec(o),H=/Android/i.exec(o),st=/FBAN\/\w+;/i.exec(o),at=/Mobile/i.exec(o),nt=!!/Win64/.exec(o),e){E=e[1]?parseFloat(e[1]):e[5]?parseFloat(e[5]):NaN,E&&document&&document.documentMode&&(E=document.documentMode);var i=/(?:Trident\/(\d+.\d+))/.exec(o);rt=i?parseFloat(i[1])+4:E,Z=e[2]?parseFloat(e[2]):NaN,k=e[3]?parseFloat(e[3]):NaN,N=e[4]?parseFloat(e[4]):NaN,N?(e=/(?:Chrome\/(\d+\.\d+))/.exec(o),_=e&&e[1]?parseFloat(e[1]):NaN):_=NaN}else E=Z=k=_=N=NaN;if(t){if(t[1]){var r=/(?:Mac OS X (\d+(?:[._]\d+)?))/.exec(o);W=r?parseFloat(r[1].replace("_",".")):!0}else W=!1;B=!!t[2],U=!!t[3]}else W=B=U=!1}}var Y={ie:function(){return g()||E},ieCompatibilityMode:function(){return g()||rt>E},ie64:function(){return Y.ie()&&nt},firefox:function(){return g()||Z},opera:function(){return g()||k},webkit:function(){return g()||N},safari:function(){return Y.webkit()},chrome:function(){return g()||_},windows:function(){return g()||B},osx:function(){return g()||W},linux:function(){return g()||U},iphone:function(){return g()||G},mobile:function(){return g()||G||X||H||at},nativeApp:function(){return g()||st},android:function(){return g()||H},ipad:function(){return g()||X}},wt=Y,bt=!!(typeof window<"u"&&window.document&&window.document.createElement),Ct={canUseDOM:bt},xt=Ct,ht=xt,ct;ht.canUseDOM&&(ct=document.implementation&&document.implementation.hasFeature&&document.implementation.hasFeature("","")!==!0);/**
|
||||
import{H as mt,r as m,j as u,c as ft}from"./index-BZm7WrzT.js";import{M as gt,f as vt}from"./resizeImage-C6PvAwh0.js";var V=!1,E,Z,k,N,_,rt,W,B,U,H,nt,G,X,st,at;function g(){if(!V){V=!0;var o=navigator.userAgent,e=/(?:MSIE.(\d+\.\d+))|(?:(?:Firefox|GranParadiso|Iceweasel).(\d+\.\d+))|(?:Opera(?:.+Version.|.)(\d+\.\d+))|(?:AppleWebKit.(\d+(?:\.\d+)?))|(?:Trident\/\d+\.\d+.*rv:(\d+\.\d+))/.exec(o),t=/(Mac OS X)|(Windows)|(Linux)/.exec(o);if(G=/\b(iPhone|iP[ao]d)/.exec(o),X=/\b(iP[ao]d)/.exec(o),H=/Android/i.exec(o),st=/FBAN\/\w+;/i.exec(o),at=/Mobile/i.exec(o),nt=!!/Win64/.exec(o),e){E=e[1]?parseFloat(e[1]):e[5]?parseFloat(e[5]):NaN,E&&document&&document.documentMode&&(E=document.documentMode);var i=/(?:Trident\/(\d+.\d+))/.exec(o);rt=i?parseFloat(i[1])+4:E,Z=e[2]?parseFloat(e[2]):NaN,k=e[3]?parseFloat(e[3]):NaN,N=e[4]?parseFloat(e[4]):NaN,N?(e=/(?:Chrome\/(\d+\.\d+))/.exec(o),_=e&&e[1]?parseFloat(e[1]):NaN):_=NaN}else E=Z=k=_=N=NaN;if(t){if(t[1]){var r=/(?:Mac OS X (\d+(?:[._]\d+)?))/.exec(o);W=r?parseFloat(r[1].replace("_",".")):!0}else W=!1;B=!!t[2],U=!!t[3]}else W=B=U=!1}}var Y={ie:function(){return g()||E},ieCompatibilityMode:function(){return g()||rt>E},ie64:function(){return Y.ie()&&nt},firefox:function(){return g()||Z},opera:function(){return g()||k},webkit:function(){return g()||N},safari:function(){return Y.webkit()},chrome:function(){return g()||_},windows:function(){return g()||B},osx:function(){return g()||W},linux:function(){return g()||U},iphone:function(){return g()||G},mobile:function(){return g()||G||X||H||at},nativeApp:function(){return g()||st},android:function(){return g()||H},ipad:function(){return g()||X}},wt=Y,bt=!!(typeof window<"u"&&window.document&&window.document.createElement),Ct={canUseDOM:bt},xt=Ct,ht=xt,ct;ht.canUseDOM&&(ct=document.implementation&&document.implementation.hasFeature&&document.implementation.hasFeature("","")!==!0);/**
|
||||
* Checks if an event is supported in the current execution environment.
|
||||
*
|
||||
* NOTE: This will not work correctly for non-generic events such as `change`,
|
||||
|
|
@ -1 +0,0 @@
|
|||
import{j as s}from"./index-DPjtOB4k.js";import{L as e}from"./LegalPageView-CftQhY6B.js";function i(){return s.jsx(e,{slug:"impressum",fallbackTitle:"Impressum",description:"Impressum von HifiPlanet Amorbach gemäß § 5 DDG."})}export{i as default};
|
||||
1
hifi/assets/Impressum-ChaXYjCF.js
Normal file
1
hifi/assets/Impressum-ChaXYjCF.js
Normal file
|
|
@ -0,0 +1 @@
|
|||
import{j as s}from"./index-BZm7WrzT.js";import{L as e}from"./LegalPageView-BadVFDdZ.js";function i(){return s.jsx(e,{slug:"impressum",fallbackTitle:"Impressum",description:"Impressum von HifiPlanet Amorbach gemäß § 5 DDG."})}export{i as default};
|
||||
|
|
@ -1 +1 @@
|
|||
import{r as l,c as n,b as r,j as a,d,i as m}from"./index-DPjtOB4k.js";function c({slug:e,fallbackTitle:s,description:i}){const[t,x]=l.useState(null);return l.useEffect(()=>{n.get(`/legal-pages/${e}`).then(x).catch(()=>{})},[e]),r({title:(t==null?void 0:t.title)||s,description:i,path:`/${e}`}),t?a.jsxs("div",{className:"mx-auto max-w-3xl px-4 py-12 sm:px-6",children:[a.jsx(d,{entity:"legal_pages",id:e,field:"title",lang:"de",value:t.title,as:"h1",className:"mb-8 block text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl"}),a.jsx(m,{entity:"legal_pages",id:e,field:"body_html",lang:"de",value:t.body_html,label:t.title,className:"legal-content text-sm text-neutral-600 dark:text-neutral-300"})]}):null}export{c as L};
|
||||
import{r as l,c as n,b as r,j as a,d,i as m}from"./index-BZm7WrzT.js";function c({slug:e,fallbackTitle:s,description:i}){const[t,x]=l.useState(null);return l.useEffect(()=>{n.get(`/legal-pages/${e}`).then(x).catch(()=>{})},[e]),r({title:(t==null?void 0:t.title)||s,description:i,path:`/${e}`}),t?a.jsxs("div",{className:"mx-auto max-w-3xl px-4 py-12 sm:px-6",children:[a.jsx(d,{entity:"legal_pages",id:e,field:"title",lang:"de",value:t.title,as:"h1",className:"mb-8 block text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl"}),a.jsx(m,{entity:"legal_pages",id:e,field:"body_html",lang:"de",value:t.body_html,label:t.title,className:"legal-content text-sm text-neutral-600 dark:text-neutral-300"})]}):null}export{c as L};
|
||||
|
|
@ -1 +1 @@
|
|||
import{r as s,c as b,j as e}from"./index-DPjtOB4k.js";import v from"./RichTextEditor-C9ovXVWM.js";const j=[{slug:"impressum",label:"Impressum"},{slug:"datenschutz",label:"Datenschutzerklärung"},{slug:"agb",label:"AGB"}];function k(){const[d,u]=s.useState(null),[r,h]=s.useState("impressum"),[c,i]=s.useState(!1),[o,n]=s.useState(""),[g,l]=s.useState(!1);if(s.useEffect(()=>{b.get("/legal-pages").then(u)},[]),!d)return e.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"});const a=d[r],m=(t,f)=>{u(x=>({...x,[r]:{...x[r],[t]:f}})),l(!1)},p=async()=>{i(!0),n(""),l(!1);try{await b.put(`/legal-pages/${r}`,{title:a.title,body_html:a.body_html}),l(!0)}catch(t){n(t.message)}finally{i(!1)}};return e.jsx("div",{className:"max-w-3xl space-y-6",children:e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Rechtstexte"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Impressum, Datenschutzerklärung und AGB direkt hier pflegen, statt einen Deploy für jede Textänderung zu brauchen. Bitte bei Rechtstexten im Zweifel rechtlich beraten lassen, bevor du größere Änderungen veröffentlichst."}),e.jsx("div",{className:"mb-4 flex flex-wrap gap-2",children:j.map(t=>e.jsx("button",{type:"button",onClick:()=>{h(t.slug),l(!1),n("")},className:`rounded-md px-3 py-1.5 text-sm font-medium transition ${r===t.slug?"bg-brand-500 text-white":"border border-neutral-300 text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800"}`,children:t.label},t.slug))}),e.jsxs("div",{className:"space-y-3",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Überschrift"}),e.jsx("input",{value:a.title,onChange:t=>m("title",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsx(v,{label:"Inhalt",value:a.body_html,onChange:t=>m("body_html",t)})]}),a.updated_at&&e.jsxs("p",{className:"mt-3 text-xs text-neutral-400",children:["Zuletzt geändert: ",new Date(a.updated_at.replace(" ","T")).toLocaleString("de-DE")]}),o&&e.jsx("p",{className:"mt-3 text-sm text-red-600",children:o}),g&&e.jsx("p",{className:"mt-3 text-sm text-green-600 dark:text-green-400",children:"Gespeichert."}),e.jsx("button",{type:"button",onClick:p,disabled:c,className:"mt-4 rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:c?"Speichere…":"Speichern"})]})})}export{k as default};
|
||||
import{r as s,c as b,j as e}from"./index-BZm7WrzT.js";import v from"./RichTextEditor-DBMbrheM.js";const j=[{slug:"impressum",label:"Impressum"},{slug:"datenschutz",label:"Datenschutzerklärung"},{slug:"agb",label:"AGB"}];function k(){const[d,u]=s.useState(null),[r,h]=s.useState("impressum"),[c,i]=s.useState(!1),[o,n]=s.useState(""),[g,l]=s.useState(!1);if(s.useEffect(()=>{b.get("/legal-pages").then(u)},[]),!d)return e.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"});const a=d[r],m=(t,f)=>{u(x=>({...x,[r]:{...x[r],[t]:f}})),l(!1)},p=async()=>{i(!0),n(""),l(!1);try{await b.put(`/legal-pages/${r}`,{title:a.title,body_html:a.body_html}),l(!0)}catch(t){n(t.message)}finally{i(!1)}};return e.jsx("div",{className:"max-w-3xl space-y-6",children:e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Rechtstexte"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Impressum, Datenschutzerklärung und AGB direkt hier pflegen, statt einen Deploy für jede Textänderung zu brauchen. Bitte bei Rechtstexten im Zweifel rechtlich beraten lassen, bevor du größere Änderungen veröffentlichst."}),e.jsx("div",{className:"mb-4 flex flex-wrap gap-2",children:j.map(t=>e.jsx("button",{type:"button",onClick:()=>{h(t.slug),l(!1),n("")},className:`rounded-md px-3 py-1.5 text-sm font-medium transition ${r===t.slug?"bg-brand-500 text-white":"border border-neutral-300 text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800"}`,children:t.label},t.slug))}),e.jsxs("div",{className:"space-y-3",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Überschrift"}),e.jsx("input",{value:a.title,onChange:t=>m("title",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsx(v,{label:"Inhalt",value:a.body_html,onChange:t=>m("body_html",t)})]}),a.updated_at&&e.jsxs("p",{className:"mt-3 text-xs text-neutral-400",children:["Zuletzt geändert: ",new Date(a.updated_at.replace(" ","T")).toLocaleString("de-DE")]}),o&&e.jsx("p",{className:"mt-3 text-sm text-red-600",children:o}),g&&e.jsx("p",{className:"mt-3 text-sm text-green-600 dark:text-green-400",children:"Gespeichert."}),e.jsx("button",{type:"button",onClick:p,disabled:c,className:"mt-4 rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:c?"Speichere…":"Speichern"})]})})}export{k as default};
|
||||
|
|
@ -1 +1 @@
|
|||
import{k as N,m as v,r,j as e,n as y,l as C,o as S}from"./index-DPjtOB4k.js";function P(){const{user:x,login:h,verifyTwoFactor:g}=N(),o=v(),[f,u]=r.useState("credentials"),[i,p]=r.useState(""),[c,w]=r.useState(""),[m,b]=r.useState(""),[s,a]=r.useState(""),[n,l]=r.useState(!1);if(x)return e.jsx(y,{to:"/admin",replace:!0});const k=async t=>{t.preventDefault(),l(!0),a("");try{(await h(i,c)).requires2fa?u("code"):o("/admin")}catch(d){a(d.message)}finally{l(!1)}},j=async t=>{t.preventDefault(),l(!0),a("");try{await g(m),o("/admin")}catch(d){a(d.message)}finally{l(!1)}};return e.jsxs("div",{className:"flex min-h-screen flex-col items-center justify-center gap-6 bg-neutral-50 px-4 dark:bg-neutral-950",children:[e.jsx("img",{src:C,alt:"HifiPlanet",className:"h-16 w-auto dark:hidden sm:h-20"}),e.jsx("img",{src:S,alt:"HifiPlanet",className:"hidden h-16 w-auto dark:block sm:h-20"}),f==="credentials"?e.jsxs("form",{onSubmit:k,className:"w-full max-w-sm rounded-xl border border-neutral-200 bg-white p-8 shadow-sm dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h1",{className:"mb-6 text-xl font-bold text-neutral-900 dark:text-white",children:"Admin-Login"}),e.jsxs("div",{className:"mb-4",children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Benutzername"}),e.jsx("input",{value:i,onChange:t=>p(t.target.value),required:!0,autoFocus:!0,className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm focus:border-brand-500 focus:outline-none dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{className:"mb-6",children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Passwort"}),e.jsx("input",{type:"password",value:c,onChange:t=>w(t.target.value),required:!0,className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm focus:border-brand-500 focus:outline-none dark:border-neutral-700 dark:bg-neutral-900"})]}),s&&e.jsx("p",{className:"mb-4 text-sm text-red-600",children:s}),e.jsx("button",{type:"submit",disabled:n,className:"w-full rounded-md bg-brand-500 px-4 py-2.5 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-60",children:n?"Anmelden…":"Anmelden"})]}):e.jsxs("form",{onSubmit:j,className:"w-full max-w-sm rounded-xl border border-neutral-200 bg-white p-8 shadow-sm dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h1",{className:"mb-2 text-xl font-bold text-neutral-900 dark:text-white",children:"Bestätigungscode"}),e.jsx("p",{className:"mb-6 text-sm text-neutral-500 dark:text-neutral-400",children:"Öffne die Google Authenticator App und gib den 6-stelligen Code ein. Alternativ kannst du auch einen deiner Wiederherstellungscodes verwenden."}),e.jsxs("div",{className:"mb-6",children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Code"}),e.jsx("input",{value:m,onChange:t=>b(t.target.value),required:!0,autoFocus:!0,inputMode:"numeric",placeholder:"123456",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-center text-lg tracking-widest focus:border-brand-500 focus:outline-none dark:border-neutral-700 dark:bg-neutral-900"})]}),s&&e.jsx("p",{className:"mb-4 text-sm text-red-600",children:s}),e.jsx("button",{type:"submit",disabled:n,className:"w-full rounded-md bg-brand-500 px-4 py-2.5 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-60",children:n?"Prüfe…":"Bestätigen"}),e.jsx("button",{type:"button",onClick:()=>{u("credentials"),b(""),a("")},className:"mt-3 w-full text-sm text-neutral-500 hover:underline dark:text-neutral-400",children:"Zurück zum Login"})]})]})}export{P as default};
|
||||
import{k as N,m as v,r,j as e,n as y,l as C,o as S}from"./index-BZm7WrzT.js";function P(){const{user:x,login:h,verifyTwoFactor:g}=N(),o=v(),[f,u]=r.useState("credentials"),[i,p]=r.useState(""),[c,w]=r.useState(""),[m,b]=r.useState(""),[s,a]=r.useState(""),[n,l]=r.useState(!1);if(x)return e.jsx(y,{to:"/admin",replace:!0});const k=async t=>{t.preventDefault(),l(!0),a("");try{(await h(i,c)).requires2fa?u("code"):o("/admin")}catch(d){a(d.message)}finally{l(!1)}},j=async t=>{t.preventDefault(),l(!0),a("");try{await g(m),o("/admin")}catch(d){a(d.message)}finally{l(!1)}};return e.jsxs("div",{className:"flex min-h-screen flex-col items-center justify-center gap-6 bg-neutral-50 px-4 dark:bg-neutral-950",children:[e.jsx("img",{src:C,alt:"HifiPlanet",className:"h-16 w-auto dark:hidden sm:h-20"}),e.jsx("img",{src:S,alt:"HifiPlanet",className:"hidden h-16 w-auto dark:block sm:h-20"}),f==="credentials"?e.jsxs("form",{onSubmit:k,className:"w-full max-w-sm rounded-xl border border-neutral-200 bg-white p-8 shadow-sm dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h1",{className:"mb-6 text-xl font-bold text-neutral-900 dark:text-white",children:"Admin-Login"}),e.jsxs("div",{className:"mb-4",children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Benutzername"}),e.jsx("input",{value:i,onChange:t=>p(t.target.value),required:!0,autoFocus:!0,className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm focus:border-brand-500 focus:outline-none dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{className:"mb-6",children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Passwort"}),e.jsx("input",{type:"password",value:c,onChange:t=>w(t.target.value),required:!0,className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm focus:border-brand-500 focus:outline-none dark:border-neutral-700 dark:bg-neutral-900"})]}),s&&e.jsx("p",{className:"mb-4 text-sm text-red-600",children:s}),e.jsx("button",{type:"submit",disabled:n,className:"w-full rounded-md bg-brand-500 px-4 py-2.5 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-60",children:n?"Anmelden…":"Anmelden"})]}):e.jsxs("form",{onSubmit:j,className:"w-full max-w-sm rounded-xl border border-neutral-200 bg-white p-8 shadow-sm dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h1",{className:"mb-2 text-xl font-bold text-neutral-900 dark:text-white",children:"Bestätigungscode"}),e.jsx("p",{className:"mb-6 text-sm text-neutral-500 dark:text-neutral-400",children:"Öffne die Google Authenticator App und gib den 6-stelligen Code ein. Alternativ kannst du auch einen deiner Wiederherstellungscodes verwenden."}),e.jsxs("div",{className:"mb-6",children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Code"}),e.jsx("input",{value:m,onChange:t=>b(t.target.value),required:!0,autoFocus:!0,inputMode:"numeric",placeholder:"123456",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-center text-lg tracking-widest focus:border-brand-500 focus:outline-none dark:border-neutral-700 dark:bg-neutral-900"})]}),s&&e.jsx("p",{className:"mb-4 text-sm text-red-600",children:s}),e.jsx("button",{type:"submit",disabled:n,className:"w-full rounded-md bg-brand-500 px-4 py-2.5 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-60",children:n?"Prüfe…":"Bestätigen"}),e.jsx("button",{type:"button",onClick:()=>{u("credentials"),b(""),a("")},className:"mt-3 w-full text-sm text-neutral-500 hover:underline dark:text-neutral-400",children:"Zurück zum Login"})]})]})}export{P as default};
|
||||
|
|
@ -1 +1 @@
|
|||
import{r as s,c as o,j as a}from"./index-DPjtOB4k.js";const v={global:{enabled:!1,message:""},services:{enabled:!1,message:""},vehicles:{enabled:!1,message:""}};function N(){const[l,n]=s.useState(v),[g,h]=s.useState(!0),[i,d]=s.useState(!1),[x,r]=s.useState(!1),[c,u]=s.useState("");s.useEffect(()=>{o.get("/maintenance").then(e=>{n({global:{enabled:e.global.enabled,message:e.global.message||""},services:{enabled:e.services.enabled,message:e.services.message||""},vehicles:{enabled:e.vehicles.enabled,message:e.vehicles.message||""}})}).finally(()=>h(!1))},[]);const m=(e,t,k)=>{n(b=>({...b,[e]:{...b[e],[t]:k}})),r(!1)},p=async e=>{e.preventDefault(),d(!0),u(""),r(!1);try{const t=await o.post("/maintenance",l);n({global:{enabled:t.global.enabled,message:t.global.message||""},services:{enabled:t.services.enabled,message:t.services.message||""},vehicles:{enabled:t.vehicles.enabled,message:t.vehicles.message||""}}),r(!0)}catch(t){u(t.message)}finally{d(!1)}},f=[{key:"global",title:"Gesamte Seite",hint:"Besucher sehen nur noch eine Wartungsmeldung – egal welche Seite sie aufrufen. Das Admin-Panel bleibt für dich erreichbar."},{key:"services",title:"Nur Leistungen",hint:"Nur die Leistungen-Seite zeigt eine Wartungsmeldung, der Rest der Website funktioniert normal."},{key:"vehicles",title:"Nur Fahrzeugkatalog",hint:"Nur die Fahrzeugauswahl (Marke → Modell → Pakete) zeigt eine Wartungsmeldung, der Rest der Website funktioniert normal."}];return g?a.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"}):a.jsxs("form",{onSubmit:p,className:"max-w-2xl space-y-6",children:[a.jsx("p",{className:"text-sm text-neutral-500 dark:text-neutral-400",children:'Ist "Gesamte Seite" aktiv, gewinnt das immer – die beiden anderen Schalter spielen dann keine Rolle mehr.'}),f.map(e=>a.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[a.jsxs("div",{className:"mb-1 flex items-center justify-between gap-3",children:[a.jsx("h2",{className:"font-semibold text-neutral-900 dark:text-white",children:e.title}),a.jsxs("label",{className:"relative inline-flex cursor-pointer items-center",children:[a.jsx("input",{type:"checkbox",checked:l[e.key].enabled,onChange:t=>m(e.key,"enabled",t.target.checked),className:"peer sr-only"}),a.jsx("div",{className:"h-6 w-11 rounded-full bg-neutral-200 transition peer-checked:bg-brand-500 dark:bg-neutral-700"}),a.jsx("div",{className:"absolute left-1 top-1 h-4 w-4 rounded-full bg-white transition peer-checked:translate-x-5"})]})]}),a.jsx("p",{className:"mb-3 text-sm text-neutral-500 dark:text-neutral-400",children:e.hint}),a.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Eigene Nachricht (optional)"}),a.jsx("textarea",{rows:2,value:l[e.key].message,onChange:t=>m(e.key,"message",t.target.value),placeholder:"z. B. Wir aktualisieren gerade unser Angebot. Schau bald wieder vorbei!",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]},e.key)),c&&a.jsx("p",{className:"text-sm text-red-600",children:c}),x&&a.jsx("p",{className:"text-sm text-green-600 dark:text-green-400",children:"Gespeichert."}),a.jsx("button",{type:"submit",disabled:i,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:i?"Speichere…":"Speichern"})]})}export{N as default};
|
||||
import{r as s,c as o,j as a}from"./index-BZm7WrzT.js";const v={global:{enabled:!1,message:""},services:{enabled:!1,message:""},vehicles:{enabled:!1,message:""}};function N(){const[l,n]=s.useState(v),[g,h]=s.useState(!0),[i,d]=s.useState(!1),[x,r]=s.useState(!1),[c,u]=s.useState("");s.useEffect(()=>{o.get("/maintenance").then(e=>{n({global:{enabled:e.global.enabled,message:e.global.message||""},services:{enabled:e.services.enabled,message:e.services.message||""},vehicles:{enabled:e.vehicles.enabled,message:e.vehicles.message||""}})}).finally(()=>h(!1))},[]);const m=(e,t,k)=>{n(b=>({...b,[e]:{...b[e],[t]:k}})),r(!1)},p=async e=>{e.preventDefault(),d(!0),u(""),r(!1);try{const t=await o.post("/maintenance",l);n({global:{enabled:t.global.enabled,message:t.global.message||""},services:{enabled:t.services.enabled,message:t.services.message||""},vehicles:{enabled:t.vehicles.enabled,message:t.vehicles.message||""}}),r(!0)}catch(t){u(t.message)}finally{d(!1)}},f=[{key:"global",title:"Gesamte Seite",hint:"Besucher sehen nur noch eine Wartungsmeldung – egal welche Seite sie aufrufen. Das Admin-Panel bleibt für dich erreichbar."},{key:"services",title:"Nur Leistungen",hint:"Nur die Leistungen-Seite zeigt eine Wartungsmeldung, der Rest der Website funktioniert normal."},{key:"vehicles",title:"Nur Fahrzeugkatalog",hint:"Nur die Fahrzeugauswahl (Marke → Modell → Pakete) zeigt eine Wartungsmeldung, der Rest der Website funktioniert normal."}];return g?a.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"}):a.jsxs("form",{onSubmit:p,className:"max-w-2xl space-y-6",children:[a.jsx("p",{className:"text-sm text-neutral-500 dark:text-neutral-400",children:'Ist "Gesamte Seite" aktiv, gewinnt das immer – die beiden anderen Schalter spielen dann keine Rolle mehr.'}),f.map(e=>a.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[a.jsxs("div",{className:"mb-1 flex items-center justify-between gap-3",children:[a.jsx("h2",{className:"font-semibold text-neutral-900 dark:text-white",children:e.title}),a.jsxs("label",{className:"relative inline-flex cursor-pointer items-center",children:[a.jsx("input",{type:"checkbox",checked:l[e.key].enabled,onChange:t=>m(e.key,"enabled",t.target.checked),className:"peer sr-only"}),a.jsx("div",{className:"h-6 w-11 rounded-full bg-neutral-200 transition peer-checked:bg-brand-500 dark:bg-neutral-700"}),a.jsx("div",{className:"absolute left-1 top-1 h-4 w-4 rounded-full bg-white transition peer-checked:translate-x-5"})]})]}),a.jsx("p",{className:"mb-3 text-sm text-neutral-500 dark:text-neutral-400",children:e.hint}),a.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Eigene Nachricht (optional)"}),a.jsx("textarea",{rows:2,value:l[e.key].message,onChange:t=>m(e.key,"message",t.target.value),placeholder:"z. B. Wir aktualisieren gerade unser Angebot. Schau bald wieder vorbei!",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]},e.key)),c&&a.jsx("p",{className:"text-sm text-red-600",children:c}),x&&a.jsx("p",{className:"text-sm text-green-600 dark:text-green-400",children:"Gespeichert."}),a.jsx("button",{type:"submit",disabled:i,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:i?"Speichere…":"Speichern"})]})}export{N as default};
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
|
@ -1 +1 @@
|
|||
import{r as n,j as e,c as i}from"./index-DPjtOB4k.js";const h={name:"",description:"",permissions:[]};function w(){const[c,b]=n.useState([]),[o,g]=n.useState([]),[r,a]=n.useState(h),[l,u]=n.useState(null),[m,x]=n.useState(""),d=()=>{i.get("/permission-groups").then(b),i.get("/permissions/catalog").then(g)};n.useEffect(d,[]);const j=t=>{u(t.id),a({name:t.name,description:t.description||"",permissions:t.permissions})},p=()=>{u(null),a(h)},N=t=>{a(s=>({...s,permissions:s.permissions.includes(t)?s.permissions.filter(y=>y!==t):[...s.permissions,t]}))},k=async t=>{t.preventDefault(),x("");try{l?await i.put(`/permission-groups/${l}`,r):await i.post("/permission-groups",r),p(),d()}catch(s){x(s.message)}},f=async t=>{confirm("Diese Berechtigungsgruppe wirklich löschen? Benutzer behalten ihre sonstigen Rechte.")&&(await i.delete(`/permission-groups/${t}`),d())};return e.jsxs("div",{className:"grid gap-6 lg:grid-cols-3",children:[e.jsxs("div",{className:"lg:col-span-2",children:[e.jsx("h1",{className:"mb-1 text-xl font-bold text-neutral-900 dark:text-white",children:"Berechtigungsgruppen"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:'Fasse mehrere Berechtigungen zu einer Gruppe zusammen (z. B. „Werkstatt"), die du dann bequem einem oder mehreren Benutzern zuweisen kannst.'}),e.jsx("div",{className:"overflow-hidden rounded-xl border border-neutral-200 dark:border-neutral-800",children:e.jsxs("table",{className:"w-full text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[e.jsx("th",{className:"px-4 py-2",children:"Name"}),e.jsx("th",{className:"px-4 py-2",children:"Berechtigungen"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsxs("tbody",{className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:[c.map(t=>e.jsxs("tr",{className:"bg-white dark:bg-neutral-950",children:[e.jsxs("td",{className:"px-4 py-2",children:[e.jsx("p",{className:"font-medium text-neutral-800 dark:text-neutral-100",children:t.name}),t.description&&e.jsx("p",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:t.description})]}),e.jsxs("td",{className:"px-4 py-2 text-neutral-500 dark:text-neutral-400",children:[t.permissions.length," von ",o.length]}),e.jsxs("td",{className:"px-4 py-2 text-right",children:[e.jsx("button",{onClick:()=>j(t),className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),e.jsx("button",{onClick:()=>f(t.id),className:"text-red-600 hover:underline",children:"Löschen"})]})]},t.id)),c.length===0&&e.jsx("tr",{children:e.jsx("td",{colSpan:3,className:"px-4 py-6 text-center text-neutral-400",children:"Noch keine Berechtigungsgruppen angelegt."})})]})]})})]}),e.jsxs("form",{onSubmit:k,className:"h-fit space-y-4 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:l?"Gruppe bearbeiten":"Neue Gruppe"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Name *"}),e.jsx("input",{required:!0,value:r.name,onChange:t=>a({...r,name:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Beschreibung"}),e.jsx("textarea",{rows:2,value:r.description,onChange:t=>a({...r,description:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("p",{className:"mb-1 text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Berechtigungen"}),e.jsx("div",{className:"space-y-1.5 rounded-md border border-neutral-200 p-3 dark:border-neutral-700",children:o.map(t=>e.jsxs("label",{className:"flex items-center gap-2 text-sm text-neutral-700 dark:text-neutral-300",children:[e.jsx("input",{type:"checkbox",checked:r.permissions.includes(t.key),onChange:()=>N(t.key),className:"h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500"}),t.label]},t.key))})]}),m&&e.jsx("p",{className:"text-sm text-red-600",children:m}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("button",{type:"submit",className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:l?"Speichern":"Anlegen"}),l&&e.jsx("button",{type:"button",onClick:p,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Abbrechen"})]})]})]})}export{w as default};
|
||||
import{r as n,j as e,c as i}from"./index-BZm7WrzT.js";const h={name:"",description:"",permissions:[]};function w(){const[c,b]=n.useState([]),[o,g]=n.useState([]),[r,a]=n.useState(h),[l,u]=n.useState(null),[m,x]=n.useState(""),d=()=>{i.get("/permission-groups").then(b),i.get("/permissions/catalog").then(g)};n.useEffect(d,[]);const j=t=>{u(t.id),a({name:t.name,description:t.description||"",permissions:t.permissions})},p=()=>{u(null),a(h)},N=t=>{a(s=>({...s,permissions:s.permissions.includes(t)?s.permissions.filter(y=>y!==t):[...s.permissions,t]}))},k=async t=>{t.preventDefault(),x("");try{l?await i.put(`/permission-groups/${l}`,r):await i.post("/permission-groups",r),p(),d()}catch(s){x(s.message)}},f=async t=>{confirm("Diese Berechtigungsgruppe wirklich löschen? Benutzer behalten ihre sonstigen Rechte.")&&(await i.delete(`/permission-groups/${t}`),d())};return e.jsxs("div",{className:"grid gap-6 lg:grid-cols-3",children:[e.jsxs("div",{className:"lg:col-span-2",children:[e.jsx("h1",{className:"mb-1 text-xl font-bold text-neutral-900 dark:text-white",children:"Berechtigungsgruppen"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:'Fasse mehrere Berechtigungen zu einer Gruppe zusammen (z. B. „Werkstatt"), die du dann bequem einem oder mehreren Benutzern zuweisen kannst.'}),e.jsx("div",{className:"overflow-hidden rounded-xl border border-neutral-200 dark:border-neutral-800",children:e.jsxs("table",{className:"w-full text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[e.jsx("th",{className:"px-4 py-2",children:"Name"}),e.jsx("th",{className:"px-4 py-2",children:"Berechtigungen"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsxs("tbody",{className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:[c.map(t=>e.jsxs("tr",{className:"bg-white dark:bg-neutral-950",children:[e.jsxs("td",{className:"px-4 py-2",children:[e.jsx("p",{className:"font-medium text-neutral-800 dark:text-neutral-100",children:t.name}),t.description&&e.jsx("p",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:t.description})]}),e.jsxs("td",{className:"px-4 py-2 text-neutral-500 dark:text-neutral-400",children:[t.permissions.length," von ",o.length]}),e.jsxs("td",{className:"px-4 py-2 text-right",children:[e.jsx("button",{onClick:()=>j(t),className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),e.jsx("button",{onClick:()=>f(t.id),className:"text-red-600 hover:underline",children:"Löschen"})]})]},t.id)),c.length===0&&e.jsx("tr",{children:e.jsx("td",{colSpan:3,className:"px-4 py-6 text-center text-neutral-400",children:"Noch keine Berechtigungsgruppen angelegt."})})]})]})})]}),e.jsxs("form",{onSubmit:k,className:"h-fit space-y-4 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:l?"Gruppe bearbeiten":"Neue Gruppe"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Name *"}),e.jsx("input",{required:!0,value:r.name,onChange:t=>a({...r,name:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Beschreibung"}),e.jsx("textarea",{rows:2,value:r.description,onChange:t=>a({...r,description:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("p",{className:"mb-1 text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Berechtigungen"}),e.jsx("div",{className:"space-y-1.5 rounded-md border border-neutral-200 p-3 dark:border-neutral-700",children:o.map(t=>e.jsxs("label",{className:"flex items-center gap-2 text-sm text-neutral-700 dark:text-neutral-300",children:[e.jsx("input",{type:"checkbox",checked:r.permissions.includes(t.key),onChange:()=>N(t.key),className:"h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500"}),t.label]},t.key))})]}),m&&e.jsx("p",{className:"text-sm text-red-600",children:m}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("button",{type:"submit",className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:l?"Speichern":"Anlegen"}),l&&e.jsx("button",{type:"button",onClick:p,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Abbrechen"})]})]})]})}export{w as default};
|
||||
File diff suppressed because one or more lines are too long
|
|
@ -1,4 +1,4 @@
|
|||
import{r as q,y as xt,j as R,ak as Gu,z as Yu}from"./index-DPjtOB4k.js";var Hl={exports:{}},jl={};/**
|
||||
import{r as q,y as xt,j as R,al as Gu,z as Yu}from"./index-BZm7WrzT.js";var Hl={exports:{}},jl={};/**
|
||||
* @license React
|
||||
* use-sync-external-store-shim.production.js
|
||||
*
|
||||
|
|
@ -1 +1 @@
|
|||
import{j as e}from"./index-DPjtOB4k.js";function m({dirty:t,busy:i,savedAt:a,onSave:n,label:s="Speichern",form:r}){return e.jsx("div",{className:"sticky bottom-0 z-20 -mx-4 mt-6 border-t border-neutral-200 bg-white/95 px-4 py-3 backdrop-blur dark:border-neutral-800 dark:bg-neutral-950/95 sm:-mx-6 sm:px-6",children:e.jsxs("div",{className:"flex flex-wrap items-center justify-between gap-3",children:[e.jsx("p",{className:`text-sm ${t?"font-medium text-amber-600 dark:text-amber-400":"text-neutral-500 dark:text-neutral-400"}`,children:t?"● Ungespeicherte Änderungen":a?`✓ Gespeichert um ${a.toLocaleTimeString("de-DE",{hour:"2-digit",minute:"2-digit"})} Uhr`:"Alles gespeichert"}),e.jsx("button",{type:r?"submit":"button",form:r,onClick:r?void 0:n,disabled:i||!t,className:"rounded-md bg-brand-500 px-5 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:i?"Speichere…":s})]})})}export{m as S};
|
||||
import{j as e}from"./index-BZm7WrzT.js";function m({dirty:t,busy:i,savedAt:a,onSave:n,label:s="Speichern",form:r}){return e.jsx("div",{className:"sticky bottom-0 z-20 -mx-4 mt-6 border-t border-neutral-200 bg-white/95 px-4 py-3 backdrop-blur dark:border-neutral-800 dark:bg-neutral-950/95 sm:-mx-6 sm:px-6",children:e.jsxs("div",{className:"flex flex-wrap items-center justify-between gap-3",children:[e.jsx("p",{className:`text-sm ${t?"font-medium text-amber-600 dark:text-amber-400":"text-neutral-500 dark:text-neutral-400"}`,children:t?"● Ungespeicherte Änderungen":a?`✓ Gespeichert um ${a.toLocaleTimeString("de-DE",{hour:"2-digit",minute:"2-digit"})} Uhr`:"Alles gespeichert"}),e.jsx("button",{type:r?"submit":"button",form:r,onClick:r?void 0:n,disabled:i||!t,className:"rounded-md bg-brand-500 px-5 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:i?"Speichere…":s})]})})}export{m as S};
|
||||
File diff suppressed because one or more lines are too long
1
hifi/assets/SettingsLayout-Bu4B0sev.js
Normal file
1
hifi/assets/SettingsLayout-Bu4B0sev.js
Normal file
|
|
@ -0,0 +1 @@
|
|||
import{B as a,j as e,r as i,O as u}from"./index-BZm7WrzT.js";const d={company:["Firmendaten","Telefon, Adresse, Öffnungszeiten, Logo und der Hinweis unter den Paketpreisen."],design:["Aussehen","Titelbild, Schriften und das Aussehen der Kacheln auf der Website."],legal:["Rechtstexte","Impressum, Datenschutzerklärung und AGB."],maintenance:["Wartungsmodus","Die ganze Website oder einzelne Bereiche vorübergehend für Besucher sperren."],countdown:["Launch-Countdown","Vor dem Start nur einen Countdown zeigen, der neugierig macht. Danach öffnet sich die Website von selbst."],email:["E-Mail-Versand","Zugangsdaten des Mail-Servers und die Texte der automatischen E-Mails."],google:["Google-Dienste","Google Analytics und Google-Bewertungen anbinden. Nur für Techniker."],database:["Datenbank","Verbindung und Struktur der Datenbank. Nur für Techniker."],"export-import":["Export & Import","Sicherung herunterladen oder auf einem anderen Server einspielen."],update:["Updates","Neue Versionen der Website installieren."],reset:["Zurücksetzen","Inhalte auf den Auslieferungszustand zurücksetzen. Vorher unbedingt exportieren."]};function l(){const{pathname:t}=a(),r=t.replace(/\/$/,"").split("/").pop(),[s,n]=d[r]||["Einstellungen",""];return e.jsxs("div",{children:[e.jsx("h1",{className:"mb-1 text-xl font-bold text-neutral-900 dark:text-white",children:s}),n&&e.jsx("p",{className:"mb-6 text-sm text-neutral-500 dark:text-neutral-400",children:n}),e.jsx(i.Suspense,{fallback:e.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"}),children:e.jsx(u,{})})]})}export{l as default};
|
||||
|
|
@ -1 +0,0 @@
|
|||
import{B as a,j as e,r as i,O as u}from"./index-DPjtOB4k.js";const d={company:["Firmendaten","Telefon, Adresse, Öffnungszeiten, Logo und der Hinweis unter den Paketpreisen."],design:["Aussehen","Titelbild, Schriften und das Aussehen der Kacheln auf der Website."],legal:["Rechtstexte","Impressum, Datenschutzerklärung und AGB."],maintenance:["Wartungsmodus","Die ganze Website oder einzelne Bereiche vorübergehend für Besucher sperren."],email:["E-Mail-Versand","Zugangsdaten des Mail-Servers und die Texte der automatischen E-Mails."],google:["Google-Dienste","Google Analytics und Google-Bewertungen anbinden. Nur für Techniker."],database:["Datenbank","Verbindung und Struktur der Datenbank. Nur für Techniker."],"export-import":["Export & Import","Sicherung herunterladen oder auf einem anderen Server einspielen."],update:["Updates","Neue Versionen der Website installieren."],reset:["Zurücksetzen","Inhalte auf den Auslieferungszustand zurücksetzen. Vorher unbedingt exportieren."]};function o(){const{pathname:t}=a(),r=t.replace(/\/$/,"").split("/").pop(),[s,n]=d[r]||["Einstellungen",""];return e.jsxs("div",{children:[e.jsx("h1",{className:"mb-1 text-xl font-bold text-neutral-900 dark:text-white",children:s}),n&&e.jsx("p",{className:"mb-6 text-sm text-neutral-500 dark:text-neutral-400",children:n}),e.jsx(i.Suspense,{fallback:e.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"}),children:e.jsx(u,{})})]})}export{o as default};
|
||||
File diff suppressed because one or more lines are too long
|
|
@ -1 +1 @@
|
|||
import{j as o,c as x}from"./index-DPjtOB4k.js";import{u as p,a as f,D as m,c as v,S as y,r as j,v as C,b as R,s as w,K as D,T as N,P as T,d as E,C as G}from"./sortable.esm-DcJMx5eJ.js";import{G as I}from"./grip-vertical-CUuB59gl.js";function P({items:t,onReorder:s,children:n,as:e="ul",className:d="",disabled:i=!1}){const l=p(f(T,{activationConstraint:{distance:4}}),f(N,{activationConstraint:{delay:150,tolerance:6}}),f(D,{coordinateGetter:w})),c=({active:r,over:a})=>{if(!a||r.id===a.id)return;const h=t.findIndex(b=>b.id===r.id),S=t.findIndex(b=>b.id===a.id);s(R(t,h,S))},u=e==="tbody"?"tbody":e==="grid"?"div":"ul",g=e==="tbody"?"tr":e==="grid"?"div":"li";return o.jsx(m,{sensors:l,collisionDetection:v,onDragEnd:c,children:o.jsx(y,{items:t.map(r=>r.id),strategy:e==="grid"?j:C,disabled:i,children:o.jsx(u,{className:d,children:t.map(r=>o.jsx(K,{id:r.id,tag:g,disabled:i,children:a=>n(r,a)},r.id))})})})}function K({id:t,tag:s,disabled:n,children:e}){const{attributes:d,listeners:i,setNodeRef:l,setActivatorNodeRef:c,transform:u,transition:g,isDragging:r}=E({id:t,disabled:n}),a=n?null:o.jsx("button",{type:"button",ref:c,...d,...i,title:"Ziehen, um die Reihenfolge zu ändern","aria-label":"Reihenfolge ändern",className:"cursor-grab touch-none rounded p-1 text-neutral-400 hover:bg-neutral-100 hover:text-neutral-600 active:cursor-grabbing dark:hover:bg-neutral-800",children:o.jsx(I,{className:"h-4 w-4"})});return o.jsx(s,{ref:l,style:{transform:G.Translate.toString(u),transition:g,position:"relative",zIndex:r?10:void 0},className:r?"bg-white shadow-lg ring-1 ring-brand-500 dark:bg-neutral-900":void 0,children:e(a)})}async function A(t,s){return await x.put(`/reorder/${t}`,{ids:s.map(n=>n.id)}),s.map((n,e)=>({...n,sort_order:(e+1)*10}))}export{P as S,A as s};
|
||||
import{j as o,c as x}from"./index-BZm7WrzT.js";import{u as p,a as f,D as m,c as v,S as y,r as j,v as C,b as R,s as w,K as D,T as N,P as T,d as E,C as G}from"./sortable.esm-BCFTlAdF.js";import{G as I}from"./grip-vertical-BM3sslIf.js";function P({items:t,onReorder:s,children:n,as:e="ul",className:d="",disabled:i=!1}){const l=p(f(T,{activationConstraint:{distance:4}}),f(N,{activationConstraint:{delay:150,tolerance:6}}),f(D,{coordinateGetter:w})),c=({active:r,over:a})=>{if(!a||r.id===a.id)return;const h=t.findIndex(b=>b.id===r.id),S=t.findIndex(b=>b.id===a.id);s(R(t,h,S))},u=e==="tbody"?"tbody":e==="grid"?"div":"ul",g=e==="tbody"?"tr":e==="grid"?"div":"li";return o.jsx(m,{sensors:l,collisionDetection:v,onDragEnd:c,children:o.jsx(y,{items:t.map(r=>r.id),strategy:e==="grid"?j:C,disabled:i,children:o.jsx(u,{className:d,children:t.map(r=>o.jsx(K,{id:r.id,tag:g,disabled:i,children:a=>n(r,a)},r.id))})})})}function K({id:t,tag:s,disabled:n,children:e}){const{attributes:d,listeners:i,setNodeRef:l,setActivatorNodeRef:c,transform:u,transition:g,isDragging:r}=E({id:t,disabled:n}),a=n?null:o.jsx("button",{type:"button",ref:c,...d,...i,title:"Ziehen, um die Reihenfolge zu ändern","aria-label":"Reihenfolge ändern",className:"cursor-grab touch-none rounded p-1 text-neutral-400 hover:bg-neutral-100 hover:text-neutral-600 active:cursor-grabbing dark:hover:bg-neutral-800",children:o.jsx(I,{className:"h-4 w-4"})});return o.jsx(s,{ref:l,style:{transform:G.Translate.toString(u),transition:g,position:"relative",zIndex:r?10:void 0},className:r?"bg-white shadow-lg ring-1 ring-brand-500 dark:bg-neutral-900":void 0,children:e(a)})}async function A(t,s){return await x.put(`/reorder/${t}`,{ids:s.map(n=>n.id)}),s.map((n,e)=>({...n,sort_order:(e+1)*10}))}export{P as S,A as s};
|
||||
|
|
@ -1 +1 @@
|
|||
import{z as g,r as l,c as x,j as t}from"./index-DPjtOB4k.js";const y=[{label:"Standard",value:""},{label:"S (14px)",value:"14px"},{label:"M (16px)",value:"16px"},{label:"L (18px)",value:"18px"},{label:"XL (20px)",value:"20px"},{label:"XXL (24px)",value:"24px"},{label:"XXXL (28px)",value:"28px"},{label:"Groß (36px)",value:"36px"},{label:"Riesig (48px)",value:"48px"}],s={font_family:"",font_size:"",color:""};function k({fieldKey:o,previewText:p="Beispieltext",label:c="Stil"}){const b=g(),[a,n]=l.useState(s),[m,u]=l.useState(!0),[d,i]=l.useState("");l.useEffect(()=>{u(!0),x.get(`/text-styles/one?key=${encodeURIComponent(o)}`).then(e=>n({font_family:e.font_family||"",font_size:e.font_size||"",color:e.color||""})).catch(()=>n(s)).finally(()=>u(!1))},[o]);const r=async e=>{n(e),i("");try{await x.put("/text-styles",{field_key:o,...e})}catch(v){i(v.message)}};if(m)return null;const f={fontFamily:a.font_family||void 0,fontSize:a.font_size||void 0,color:a.color||void 0};return t.jsxs("div",{className:"mt-1.5 flex flex-wrap items-center gap-2 rounded-md border border-neutral-200 bg-neutral-50 p-2 dark:border-neutral-700 dark:bg-neutral-800/50",children:[t.jsx("span",{className:"text-xs font-medium uppercase tracking-wide text-neutral-400",children:c}),t.jsx("select",{value:a.font_family,onChange:e=>r({...a,font_family:e.target.value}),className:"rounded-md border border-neutral-300 bg-white px-2 py-1 text-xs dark:border-neutral-700 dark:bg-neutral-900",children:b.map(e=>t.jsx("option",{value:e.value,children:e.label},e.label))}),t.jsx("select",{value:a.font_size,onChange:e=>r({...a,font_size:e.target.value}),className:"rounded-md border border-neutral-300 bg-white px-2 py-1 text-xs dark:border-neutral-700 dark:bg-neutral-900",children:y.map(e=>t.jsx("option",{value:e.value,children:e.label},e.label))}),t.jsx("input",{type:"color",value:a.color||"#000000",onChange:e=>r({...a,color:e.target.value}),className:"h-7 w-9 cursor-pointer rounded border border-neutral-300 bg-white p-0.5 dark:border-neutral-700 dark:bg-neutral-900",title:"Textfarbe"}),t.jsx("button",{type:"button",onClick:()=>r(s),className:"rounded-md border border-neutral-300 px-2 py-1 text-xs text-neutral-500 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-400 dark:hover:bg-neutral-700",children:"Zurücksetzen"}),t.jsx("span",{className:"ml-1 rounded px-2 py-1 text-sm",style:f,children:p}),d&&t.jsx("span",{className:"text-xs text-red-600",children:d})]})}export{k as T};
|
||||
import{z as g,r as l,c as x,j as t}from"./index-BZm7WrzT.js";const y=[{label:"Standard",value:""},{label:"S (14px)",value:"14px"},{label:"M (16px)",value:"16px"},{label:"L (18px)",value:"18px"},{label:"XL (20px)",value:"20px"},{label:"XXL (24px)",value:"24px"},{label:"XXXL (28px)",value:"28px"},{label:"Groß (36px)",value:"36px"},{label:"Riesig (48px)",value:"48px"}],s={font_family:"",font_size:"",color:""};function k({fieldKey:o,previewText:p="Beispieltext",label:c="Stil"}){const b=g(),[a,n]=l.useState(s),[m,u]=l.useState(!0),[d,i]=l.useState("");l.useEffect(()=>{u(!0),x.get(`/text-styles/one?key=${encodeURIComponent(o)}`).then(e=>n({font_family:e.font_family||"",font_size:e.font_size||"",color:e.color||""})).catch(()=>n(s)).finally(()=>u(!1))},[o]);const r=async e=>{n(e),i("");try{await x.put("/text-styles",{field_key:o,...e})}catch(v){i(v.message)}};if(m)return null;const f={fontFamily:a.font_family||void 0,fontSize:a.font_size||void 0,color:a.color||void 0};return t.jsxs("div",{className:"mt-1.5 flex flex-wrap items-center gap-2 rounded-md border border-neutral-200 bg-neutral-50 p-2 dark:border-neutral-700 dark:bg-neutral-800/50",children:[t.jsx("span",{className:"text-xs font-medium uppercase tracking-wide text-neutral-400",children:c}),t.jsx("select",{value:a.font_family,onChange:e=>r({...a,font_family:e.target.value}),className:"rounded-md border border-neutral-300 bg-white px-2 py-1 text-xs dark:border-neutral-700 dark:bg-neutral-900",children:b.map(e=>t.jsx("option",{value:e.value,children:e.label},e.label))}),t.jsx("select",{value:a.font_size,onChange:e=>r({...a,font_size:e.target.value}),className:"rounded-md border border-neutral-300 bg-white px-2 py-1 text-xs dark:border-neutral-700 dark:bg-neutral-900",children:y.map(e=>t.jsx("option",{value:e.value,children:e.label},e.label))}),t.jsx("input",{type:"color",value:a.color||"#000000",onChange:e=>r({...a,color:e.target.value}),className:"h-7 w-9 cursor-pointer rounded border border-neutral-300 bg-white p-0.5 dark:border-neutral-700 dark:bg-neutral-900",title:"Textfarbe"}),t.jsx("button",{type:"button",onClick:()=>r(s),className:"rounded-md border border-neutral-300 px-2 py-1 text-xs text-neutral-500 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-400 dark:hover:bg-neutral-700",children:"Zurücksetzen"}),t.jsx("span",{className:"ml-1 rounded px-2 py-1 text-sm",style:f,children:p}),d&&t.jsx("span",{className:"text-xs text-red-600",children:d})]})}export{k as T};
|
||||
File diff suppressed because one or more lines are too long
|
|
@ -1 +1 @@
|
|||
import{j as n,x as a}from"./index-DPjtOB4k.js";function i({to:e,label:r="Ansehen",className:t=""}){return e?n.jsxs("a",{href:e,target:"_blank",rel:"noopener noreferrer",title:"Auf der Website ansehen (neuer Tab)",className:`inline-flex items-center gap-1 text-xs font-medium text-neutral-500 hover:text-brand-600 dark:text-neutral-400 ${t}`,children:[n.jsx(a,{className:"h-3.5 w-3.5"}),r]}):null}export{i as V};
|
||||
import{j as n,x as a}from"./index-BZm7WrzT.js";function i({to:e,label:r="Ansehen",className:t=""}){return e?n.jsxs("a",{href:e,target:"_blank",rel:"noopener noreferrer",title:"Auf der Website ansehen (neuer Tab)",className:`inline-flex items-center gap-1 text-xs font-medium text-neutral-500 hover:text-brand-600 dark:text-neutral-400 ${t}`,children:[n.jsx(a,{className:"h-3.5 w-3.5"}),r]}):null}export{i as V};
|
||||
File diff suppressed because one or more lines are too long
|
|
@ -1,4 +1,4 @@
|
|||
import{I as e}from"./index-DPjtOB4k.js";/**
|
||||
import{I as e}from"./index-BZm7WrzT.js";/**
|
||||
* @license lucide-react v1.23.0 - ISC
|
||||
*
|
||||
* This source code is licensed under the ISC license.
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
import{I as c}from"./index-DPjtOB4k.js";/**
|
||||
import{I as c}from"./index-BZm7WrzT.js";/**
|
||||
* @license lucide-react v1.23.0 - ISC
|
||||
*
|
||||
* This source code is licensed under the ISC license.
|
||||
File diff suppressed because one or more lines are too long
296
hifi/assets/index-BZm7WrzT.js
Normal file
296
hifi/assets/index-BZm7WrzT.js
Normal file
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
1
hifi/assets/index-DsuTYTi3.css
Normal file
1
hifi/assets/index-DsuTYTi3.css
Normal file
File diff suppressed because one or more lines are too long
|
|
@ -1,4 +1,4 @@
|
|||
import{I as a}from"./index-DPjtOB4k.js";/**
|
||||
import{I as a}from"./index-BZm7WrzT.js";/**
|
||||
* @license lucide-react v1.23.0 - ISC
|
||||
*
|
||||
* This source code is licensed under the ISC license.
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
import{r as c,y as P,h as Oe}from"./index-DPjtOB4k.js";function Rn(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return c.useMemo(()=>r=>{t.forEach(o=>o(r))},t)}const et=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function me(e){const t=Object.prototype.toString.call(e);return t==="[object Window]"||t==="[object global]"}function pt(e){return"nodeType"in e}function B(e){var t,n;return e?me(e)?e:pt(e)&&(t=(n=e.ownerDocument)==null?void 0:n.defaultView)!=null?t:window:window}function bt(e){const{Document:t}=B(e);return e instanceof t}function Be(e){return me(e)?!1:e instanceof B(e).HTMLElement}function Ut(e){return e instanceof B(e).SVGElement}function ye(e){return e?me(e)?e.document:pt(e)?bt(e)?e:Be(e)||Ut(e)?e.ownerDocument:document:document:document}const Q=et?c.useLayoutEffect:c.useEffect;function wt(e){const t=c.useRef(e);return Q(()=>{t.current=e}),c.useCallback(function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return t.current==null?void 0:t.current(...r)},[])}function Sn(){const e=c.useRef(null),t=c.useCallback((r,o)=>{e.current=setInterval(r,o)},[]),n=c.useCallback(()=>{e.current!==null&&(clearInterval(e.current),e.current=null)},[]);return[t,n]}function ke(e,t){t===void 0&&(t=[e]);const n=c.useRef(e);return Q(()=>{n.current!==e&&(n.current=e)},t),n}function Fe(e,t){const n=c.useRef();return c.useMemo(()=>{const r=e(n.current);return n.current=r,r},[...t])}function Ge(e){const t=wt(e),n=c.useRef(null),r=c.useCallback(o=>{o!==n.current&&(t==null||t(o,n.current)),n.current=o},[]);return[n,r]}function dt(e){const t=c.useRef();return c.useEffect(()=>{t.current=e},[e]),t.current}let at={};function $e(e,t){return c.useMemo(()=>{if(t)return t;const n=at[e]==null?0:at[e]+1;return at[e]=n,e+"-"+n},[e,t])}function Wt(e){return function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return r.reduce((i,s)=>{const a=Object.entries(s);for(const[l,u]of a){const f=i[l];f!=null&&(i[l]=f+e*u)}return i},{...t})}}const we=Wt(1),ze=Wt(-1);function En(e){return"clientX"in e&&"clientY"in e}function mt(e){if(!e)return!1;const{KeyboardEvent:t}=B(e.target);return t&&e instanceof t}function Mn(e){if(!e)return!1;const{TouchEvent:t}=B(e.target);return t&&e instanceof t}function ft(e){if(Mn(e)){if(e.touches&&e.touches.length){const{clientX:t,clientY:n}=e.touches[0];return{x:t,y:n}}else if(e.changedTouches&&e.changedTouches.length){const{clientX:t,clientY:n}=e.changedTouches[0];return{x:t,y:n}}}return En(e)?{x:e.clientX,y:e.clientY}:null}const Je=Object.freeze({Translate:{toString(e){if(!e)return;const{x:t,y:n}=e;return"translate3d("+(t?Math.round(t):0)+"px, "+(n?Math.round(n):0)+"px, 0)"}},Scale:{toString(e){if(!e)return;const{scaleX:t,scaleY:n}=e;return"scaleX("+t+") scaleY("+n+")"}},Transform:{toString(e){if(e)return[Je.Translate.toString(e),Je.Scale.toString(e)].join(" ")}},Transition:{toString(e){let{property:t,duration:n,easing:r}=e;return t+" "+n+"ms "+r}}}),Ot="a,frame,iframe,input:not([type=hidden]):not(:disabled),select:not(:disabled),textarea:not(:disabled),button:not(:disabled),*[tabindex]";function In(e){return e.matches(Ot)?e:e.querySelector(Ot)}const An={display:"none"};function On(e){let{id:t,value:n}=e;return P.createElement("div",{id:t,style:An},n)}function Tn(e){let{id:t,announcement:n,ariaLiveType:r="assertive"}=e;const o={position:"fixed",top:0,left:0,width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0 0 0 0)",clipPath:"inset(100%)",whiteSpace:"nowrap"};return P.createElement("div",{id:t,style:o,role:"status","aria-live":r,"aria-atomic":!0},n)}function Nn(){const[e,t]=c.useState("");return{announce:c.useCallback(r=>{r!=null&&t(r)},[]),announcement:e}}const Ht=c.createContext(null);function Ln(e){const t=c.useContext(Ht);c.useEffect(()=>{if(!t)throw new Error("useDndMonitor must be used within a children of <DndContext>");return t(e)},[e,t])}function kn(){const[e]=c.useState(()=>new Set),t=c.useCallback(r=>(e.add(r),()=>e.delete(r)),[e]);return[c.useCallback(r=>{let{type:o,event:i}=r;e.forEach(s=>{var a;return(a=s[o])==null?void 0:a.call(s,i)})},[e]),t]}const zn={draggable:`
|
||||
import{r as c,y as P,h as Oe}from"./index-BZm7WrzT.js";function Rn(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return c.useMemo(()=>r=>{t.forEach(o=>o(r))},t)}const et=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function me(e){const t=Object.prototype.toString.call(e);return t==="[object Window]"||t==="[object global]"}function pt(e){return"nodeType"in e}function B(e){var t,n;return e?me(e)?e:pt(e)&&(t=(n=e.ownerDocument)==null?void 0:n.defaultView)!=null?t:window:window}function bt(e){const{Document:t}=B(e);return e instanceof t}function Be(e){return me(e)?!1:e instanceof B(e).HTMLElement}function Ut(e){return e instanceof B(e).SVGElement}function ye(e){return e?me(e)?e.document:pt(e)?bt(e)?e:Be(e)||Ut(e)?e.ownerDocument:document:document:document}const Q=et?c.useLayoutEffect:c.useEffect;function wt(e){const t=c.useRef(e);return Q(()=>{t.current=e}),c.useCallback(function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return t.current==null?void 0:t.current(...r)},[])}function Sn(){const e=c.useRef(null),t=c.useCallback((r,o)=>{e.current=setInterval(r,o)},[]),n=c.useCallback(()=>{e.current!==null&&(clearInterval(e.current),e.current=null)},[]);return[t,n]}function ke(e,t){t===void 0&&(t=[e]);const n=c.useRef(e);return Q(()=>{n.current!==e&&(n.current=e)},t),n}function Fe(e,t){const n=c.useRef();return c.useMemo(()=>{const r=e(n.current);return n.current=r,r},[...t])}function Ge(e){const t=wt(e),n=c.useRef(null),r=c.useCallback(o=>{o!==n.current&&(t==null||t(o,n.current)),n.current=o},[]);return[n,r]}function dt(e){const t=c.useRef();return c.useEffect(()=>{t.current=e},[e]),t.current}let at={};function $e(e,t){return c.useMemo(()=>{if(t)return t;const n=at[e]==null?0:at[e]+1;return at[e]=n,e+"-"+n},[e,t])}function Wt(e){return function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return r.reduce((i,s)=>{const a=Object.entries(s);for(const[l,u]of a){const f=i[l];f!=null&&(i[l]=f+e*u)}return i},{...t})}}const we=Wt(1),ze=Wt(-1);function En(e){return"clientX"in e&&"clientY"in e}function mt(e){if(!e)return!1;const{KeyboardEvent:t}=B(e.target);return t&&e instanceof t}function Mn(e){if(!e)return!1;const{TouchEvent:t}=B(e.target);return t&&e instanceof t}function ft(e){if(Mn(e)){if(e.touches&&e.touches.length){const{clientX:t,clientY:n}=e.touches[0];return{x:t,y:n}}else if(e.changedTouches&&e.changedTouches.length){const{clientX:t,clientY:n}=e.changedTouches[0];return{x:t,y:n}}}return En(e)?{x:e.clientX,y:e.clientY}:null}const Je=Object.freeze({Translate:{toString(e){if(!e)return;const{x:t,y:n}=e;return"translate3d("+(t?Math.round(t):0)+"px, "+(n?Math.round(n):0)+"px, 0)"}},Scale:{toString(e){if(!e)return;const{scaleX:t,scaleY:n}=e;return"scaleX("+t+") scaleY("+n+")"}},Transform:{toString(e){if(e)return[Je.Translate.toString(e),Je.Scale.toString(e)].join(" ")}},Transition:{toString(e){let{property:t,duration:n,easing:r}=e;return t+" "+n+"ms "+r}}}),Ot="a,frame,iframe,input:not([type=hidden]):not(:disabled),select:not(:disabled),textarea:not(:disabled),button:not(:disabled),*[tabindex]";function In(e){return e.matches(Ot)?e:e.querySelector(Ot)}const An={display:"none"};function On(e){let{id:t,value:n}=e;return P.createElement("div",{id:t,style:An},n)}function Tn(e){let{id:t,announcement:n,ariaLiveType:r="assertive"}=e;const o={position:"fixed",top:0,left:0,width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0 0 0 0)",clipPath:"inset(100%)",whiteSpace:"nowrap"};return P.createElement("div",{id:t,style:o,role:"status","aria-live":r,"aria-atomic":!0},n)}function Nn(){const[e,t]=c.useState("");return{announce:c.useCallback(r=>{r!=null&&t(r)},[]),announcement:e}}const Ht=c.createContext(null);function Ln(e){const t=c.useContext(Ht);c.useEffect(()=>{if(!t)throw new Error("useDndMonitor must be used within a children of <DndContext>");return t(e)},[e,t])}function kn(){const[e]=c.useState(()=>new Set),t=c.useCallback(r=>(e.add(r),()=>e.delete(r)),[e]);return[c.useCallback(r=>{let{type:o,event:i}=r;e.forEach(s=>{var a;return(a=s[o])==null?void 0:a.call(s,i)})},[e]),t]}const zn={draggable:`
|
||||
To pick up a draggable item, press the space bar.
|
||||
While dragging, use the arrow keys to move the item.
|
||||
Press space again to drop the item in its new position, or press escape to cancel.
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
import{I as a}from"./index-DPjtOB4k.js";/**
|
||||
import{I as a}from"./index-BZm7WrzT.js";/**
|
||||
* @license lucide-react v1.23.0 - ISC
|
||||
*
|
||||
* This source code is licensed under the ISC license.
|
||||
|
|
@ -49,8 +49,8 @@
|
|||
"sameAs": ["https://www.youtube.com/@hifiplanet2812"]
|
||||
}
|
||||
</script>
|
||||
<script type="module" crossorigin src="/assets/index-DPjtOB4k.js"></script>
|
||||
<link rel="stylesheet" crossorigin href="/assets/index-CvX9Fs7t.css">
|
||||
<script type="module" crossorigin src="/assets/index-BZm7WrzT.js"></script>
|
||||
<link rel="stylesheet" crossorigin href="/assets/index-DsuTYTi3.css">
|
||||
</head>
|
||||
<body class="bg-white text-slate-900 dark:bg-slate-950 dark:text-slate-100">
|
||||
<div id="root"></div>
|
||||
|
|
|
|||
Loading…
Reference in a new issue