From 2f57554154d7cd6a78bbae825ae008b2d388fc07 Mon Sep 17 00:00:00 2001 From: Gabriel20xx Date: Tue, 4 Aug 2026 16:53:36 +0200 Subject: [PATCH] Extend shared UI component customization --- .../web-ui/src/lib/components/AppShell.svelte | 6 ++++++ .../web-ui/src/lib/components/AuthPage.svelte | 7 +++++++ packages/web-ui/src/lib/components/Header.svelte | 15 ++++++++++++++- .../web-ui/src/lib/components/PageHeader.svelte | 8 ++++++-- packages/web-ui/src/lib/styles.css | 4 ++++ shared-styles.css | 4 ++++ 6 files changed, 41 insertions(+), 3 deletions(-) diff --git a/packages/web-ui/src/lib/components/AppShell.svelte b/packages/web-ui/src/lib/components/AppShell.svelte index d32456d..e0f3471 100644 --- a/packages/web-ui/src/lib/components/AppShell.svelte +++ b/packages/web-ui/src/lib/components/AppShell.svelte @@ -9,8 +9,10 @@ children, class: className = '', currentPath = '', + headerActions, navItems = [], onLogout, + onNavigate, onProfile, onSettings, showSettings = true, @@ -22,8 +24,10 @@ children?: Snippet; class?: string; currentPath?: string; + headerActions?: Snippet; navItems?: NavItem[]; onLogout?: () => void | Promise; + onNavigate?: (item: NavItem) => void; onProfile?: () => void; onSettings?: () => void; showSettings?: boolean; @@ -37,8 +41,10 @@ {brand} {brandHref} {currentPath} + actions={headerActions} {navItems} {onLogout} + {onNavigate} {onProfile} {onSettings} {showSettings} diff --git a/packages/web-ui/src/lib/components/AuthPage.svelte b/packages/web-ui/src/lib/components/AuthPage.svelte index e30c6f7..c93d4df 100644 --- a/packages/web-ui/src/lib/components/AuthPage.svelte +++ b/packages/web-ui/src/lib/components/AuthPage.svelte @@ -1,9 +1,11 @@

{title}

- {#if description} -

{description}

+ {#if supportingText} +

{supportingText}

{/if} {@render children?.()}
diff --git a/packages/web-ui/src/lib/styles.css b/packages/web-ui/src/lib/styles.css index 8ebfcfc..e4a657e 100644 --- a/packages/web-ui/src/lib/styles.css +++ b/packages/web-ui/src/lib/styles.css @@ -419,6 +419,10 @@ margin-top: 1.5rem; } +.sc-auth-extra { + margin-top: 1rem; +} + .sc-dialog-backdrop { position: fixed; z-index: 100; diff --git a/shared-styles.css b/shared-styles.css index 4314fe8..0d4e597 100644 --- a/shared-styles.css +++ b/shared-styles.css @@ -419,6 +419,10 @@ margin-top: 1.5rem; } +.sc-auth-extra { + margin-top: 1rem; +} + .sc-dialog-backdrop { position: fixed; z-index: 100;