fix(config): ensure is_demo_mode is persisted in site.config.json and typed in SiteConfig interface
This commit is contained in:
@@ -72,12 +72,13 @@ const presets = Object.values(THEME_PRESETS);
|
|||||||
<textarea id="metaDescription" rows="2" class="w-full glass-panel bg-slate-950/60 rounded-xl p-3 text-xs text-white focus:outline-none focus:border-sky-400 resize-none">{siteConfig.metaDescription}</textarea>
|
<textarea id="metaDescription" rows="2" class="w-full glass-panel bg-slate-950/60 rounded-xl p-3 text-xs text-white focus:outline-none focus:border-sky-400 resize-none">{siteConfig.metaDescription}</textarea>
|
||||||
</div>
|
</div>
|
||||||
<label class="flex items-center gap-3 pt-2 p-3 bg-amber-500/10 border border-amber-500/20 rounded-xl cursor-pointer">
|
<label class="flex items-center gap-3 pt-2 p-3 bg-amber-500/10 border border-amber-500/20 rounded-xl cursor-pointer">
|
||||||
<input type="checkbox" id="isDemoMode" checked={(siteConfig as any).is_demo_mode ?? false} class="rounded text-amber-400 focus:ring-0 h-4 w-4" />
|
<input type="checkbox" id="isDemoMode" checked={!!siteConfig.is_demo_mode} class="rounded text-amber-400 focus:ring-0 h-4 w-4" />
|
||||||
<div>
|
<div>
|
||||||
<span class="text-xs text-amber-400 font-bold block">🎭 Demo-Modus aktivieren</span>
|
<span class="text-xs text-amber-400 font-bold block">🎭 Demo-Modus aktivieren</span>
|
||||||
<span class="text-[10px] text-slate-400">Zeigt einen festen Demo-Hinweis für Interessenten auf der Live-Website</span>
|
<span class="text-[10px] text-slate-400">Zeigt einen festen Demo-Hinweis für Interessenten auf der Live-Website</span>
|
||||||
</div>
|
</div>
|
||||||
</label>
|
</label>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<h3 class="text-xs font-bold text-slate-400 uppercase tracking-wider pt-2 border-t border-white/10">Unternehmens-Stammdaten (Dynamic Data Binding)</h3>
|
<h3 class="text-xs font-bold text-slate-400 uppercase tracking-wider pt-2 border-t border-white/10">Unternehmens-Stammdaten (Dynamic Data Binding)</h3>
|
||||||
|
|||||||
@@ -73,6 +73,7 @@ export interface SiteConfig {
|
|||||||
sectionsOrder: string[];
|
sectionsOrder: string[];
|
||||||
|
|
||||||
sectionsDetails?: SectionConfig[];
|
sectionsDetails?: SectionConfig[];
|
||||||
|
is_demo_mode?: boolean;
|
||||||
site_info?: {
|
site_info?: {
|
||||||
title?: string;
|
title?: string;
|
||||||
company_name?: string;
|
company_name?: string;
|
||||||
@@ -117,6 +118,8 @@ export interface SmtpConfig {
|
|||||||
export const FALLBACK_SITE_CONFIG: SiteConfig = {
|
export const FALLBACK_SITE_CONFIG: SiteConfig = {
|
||||||
siteName: 'N&D IT Solutions',
|
siteName: 'N&D IT Solutions',
|
||||||
metaDescription: 'High-Performance Webdesign & Digital Solutions - 100% DSGVO-konform.',
|
metaDescription: 'High-Performance Webdesign & Digital Solutions - 100% DSGVO-konform.',
|
||||||
|
is_demo_mode: false,
|
||||||
|
|
||||||
header: {
|
header: {
|
||||||
brandName: 'N&D',
|
brandName: 'N&D',
|
||||||
brandHighlight: 'i-t SOLUTIONS',
|
brandHighlight: 'i-t SOLUTIONS',
|
||||||
|
|||||||
Reference in New Issue
Block a user