diff --git a/packages/kitbook/src/lib/routes/[...file]/MainPage.svelte b/packages/kitbook/src/lib/routes/[...file]/MainPage.svelte index 8eadb444..20a6ce7c 100644 --- a/packages/kitbook/src/lib/routes/[...file]/MainPage.svelte +++ b/packages/kitbook/src/lib/routes/[...file]/MainPage.svelte @@ -22,7 +22,7 @@ pagesStore, loadedModules: { variantsModule: initialVariantsModule, compositionsModules: initialCompositionsModules, markdown: initialMarkdown }, pageKey, - settings, + kitbook_settings: settings, rpc_client, } = data) $: ({ viewports: projectViewports, addLanguageToUrl, githubURL, title: kitbookTitle, darkMode } = settings) diff --git a/packages/kitbook/src/lib/routes/[...file]/MainPage.variants.ts b/packages/kitbook/src/lib/routes/[...file]/MainPage.variants.ts index ee44f59e..b0e63dc7 100644 --- a/packages/kitbook/src/lib/routes/[...file]/MainPage.variants.ts +++ b/packages/kitbook/src/lib/routes/[...file]/MainPage.variants.ts @@ -11,7 +11,7 @@ export const shared_meta: VariantMeta = { } const shared_data = { - settings: { + kitbook_settings: { title: 'Demo Kitbook', description: '', }, @@ -119,7 +119,7 @@ const docs_page: GroupedPage = { export const i18n: Variant = { data: { ...shared_data, - settings: { + kitbook_settings: { title: 'i18n Kitbook', description: '', expandTree: true, diff --git a/packages/kitbook/src/lib/routes/layoutLoad.ts b/packages/kitbook/src/lib/routes/layoutLoad.ts index 4764f4a9..bea44be6 100644 --- a/packages/kitbook/src/lib/routes/layoutLoad.ts +++ b/packages/kitbook/src/lib/routes/layoutLoad.ts @@ -12,7 +12,7 @@ interface LayoutLoadInput { export interface LayoutLoadResult { pages: GroupedPageMap pagesStore: typeof pagesStore - settings: KitbookSettings + kitbook_settings: KitbookSettings // prefixed to allow users to use the settings keyword in the mockedPageData rpc_client: typeof rpc_client } @@ -37,7 +37,7 @@ export function layoutLoad({ return { pages: initialPages, pagesStore, - settings, + kitbook_settings: settings, rpc_client, ...(mockedPageData || {}), } diff --git a/packages/kitbook/src/lib/routes/sandbox/[...file]/SandboxPage.variants.ts b/packages/kitbook/src/lib/routes/sandbox/[...file]/SandboxPage.variants.ts index 774ba320..40240315 100644 --- a/packages/kitbook/src/lib/routes/sandbox/[...file]/SandboxPage.variants.ts +++ b/packages/kitbook/src/lib/routes/sandbox/[...file]/SandboxPage.variants.ts @@ -12,7 +12,7 @@ const shared_data = { canMount: true, darkMode: false, - settings: null, + kitbook_settings: null, rpc_client: null, } satisfies Partial['data']> diff --git a/packages/kitbook/src/lib/routes/tools/Tools.svelte b/packages/kitbook/src/lib/routes/tools/Tools.svelte index 75642e4a..b6b79dc4 100644 --- a/packages/kitbook/src/lib/routes/tools/Tools.svelte +++ b/packages/kitbook/src/lib/routes/tools/Tools.svelte @@ -10,7 +10,7 @@ export let detailsForTools: ToolsComponentDetails export let changeState: (data: ToolsChangeState) => void - $: ({ viewports, _languageInsertedKitbookRoute } = data.settings) + $: ({ viewports, _languageInsertedKitbookRoute } = data.kitbook_settings) $: ({ filename, tagName, serializedState } = detailsForTools) $: variantsFilename = filename?.replace('.svelte', '.variants.ts') $: svxFilename = filename?.replace('.svelte', '.md') diff --git a/packages/kitbook/src/lib/routes/tools/Tools.variants.ts b/packages/kitbook/src/lib/routes/tools/Tools.variants.ts index 00ae5d0e..13ef183e 100644 --- a/packages/kitbook/src/lib/routes/tools/Tools.variants.ts +++ b/packages/kitbook/src/lib/routes/tools/Tools.variants.ts @@ -4,7 +4,7 @@ import type Component from './Tools.svelte' const shared = { changeState: data => console.info({ changeState: data }), data: { - settings: { + kitbook_settings: { description: 'This is a description', title: 'This is a title', viewports: [{ width: 500, height: 200 }],