diff --git a/packages/builder/src/pages/builder/app/[application]/design/[screenId]/[componentId]/_components/Navigation/index.svelte b/packages/builder/src/pages/builder/app/[application]/design/[screenId]/[componentId]/_components/Navigation/index.svelte index 50e1ad0cf8..4db218f60b 100644 --- a/packages/builder/src/pages/builder/app/[application]/design/[screenId]/[componentId]/_components/Navigation/index.svelte +++ b/packages/builder/src/pages/builder/app/[application]/design/[screenId]/[componentId]/_components/Navigation/index.svelte @@ -24,6 +24,13 @@ navigationStore, } from "stores/builder" import { DefaultAppTheme } from "constants" + import BarButtonList from "/src/components/design/settings/controls/BarButtonList.svelte" + + $: alignmentOptions = [ + { value: "Left", barIcon: "TextAlignLeft" }, + { value: "Center", barIcon: "TextAlignCenter" }, + { value: "Right", barIcon: "TextAlignRight" }, + ] $: screenRouteOptions = $screenStore.screens .map(screen => screen.routing?.route) @@ -46,6 +53,10 @@ notifications.error("Error updating navigation settings") } } + + const updateTextAlign = textAlignValue => { + navigationStore.syncAppNavigation({ textAlign: textAlignValue }) + } update("title", e.detail)} updateOnChange={false} /> + +
+ +
+ {/if}
diff --git a/packages/builder/src/stores/builder/navigation.js b/packages/builder/src/stores/builder/navigation.js index 88565de99d..0cc4923c56 100644 --- a/packages/builder/src/stores/builder/navigation.js +++ b/packages/builder/src/stores/builder/navigation.js @@ -11,6 +11,7 @@ export const INITIAL_NAVIGATION_STATE = { hideLogo: null, logoUrl: null, hideTitle: null, + textAlign: "Left", navBackground: null, navWidth: null, navTextColor: null, diff --git a/packages/client/src/components/app/Layout.svelte b/packages/client/src/components/app/Layout.svelte index f1dcdf6b37..1b92c0fefc 100644 --- a/packages/client/src/components/app/Layout.svelte +++ b/packages/client/src/components/app/Layout.svelte @@ -36,6 +36,7 @@ export let pageWidth export let logoLinkUrl export let openLogoLinkInNewTab + export let textAlign export let embedded = false @@ -226,7 +227,7 @@ {/if} {/if} {#if !hideTitle && title} - {title} + {title} {/if}
{#if !embedded}