@farming-labs/theme 0.1.52 → 0.1.54

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -648,86 +648,82 @@ function createDocsLayout(config, options) {
648
648
  collapsible: sidebarProps.collapsible !== false,
649
649
  flat: !!sidebarFlat
650
650
  });
651
- return /* @__PURE__ */ jsx("div", {
652
- id: "nd-docs-layout",
653
- style: { display: "contents" },
654
- children: /* @__PURE__ */ jsxs(DocsLayout, {
655
- tree: localizedTree,
656
- nav: {
657
- title: navTitle,
658
- url: navUrl
659
- },
660
- themeSwitch: i18n ? {
661
- ...themeSwitch,
662
- enabled: false
663
- } : themeSwitch,
664
- sidebar: finalSidebarProps,
665
- ...aiMode === "sidebar-icon" && aiEnabled ? { searchToggle: { components: { lg: /* @__PURE__ */ jsx(SidebarSearchWithAI, {}) } } } : {},
666
- children: [
667
- /* @__PURE__ */ jsx(ColorStyle, { colors }),
668
- /* @__PURE__ */ jsx(TypographyStyle, { typography }),
669
- /* @__PURE__ */ jsx(LayoutStyle, { layout: layoutDimensions }),
670
- forcedTheme && /* @__PURE__ */ jsx(ForcedThemeScript, { theme: forcedTheme }),
671
- !staticExport && /* @__PURE__ */ jsx(Suspense, {
672
- fallback: null,
673
- children: /* @__PURE__ */ jsx(DocsCommandSearch, {
674
- api: docsApiUrl,
675
- locale: activeLocale
676
- })
677
- }),
678
- aiEnabled && /* @__PURE__ */ jsx(Suspense, {
679
- fallback: null,
680
- children: /* @__PURE__ */ jsx(DocsAIFeatures, {
681
- mode: aiMode,
682
- api: docsApiUrl,
683
- locale: activeLocale,
684
- position: aiPosition,
685
- floatingStyle: aiFloatingStyle,
686
- triggerComponentHtml: aiTriggerComponentHtml,
687
- suggestedQuestions: aiSuggestedQuestions,
688
- aiLabel,
689
- loaderVariant: aiLoaderVariant,
690
- loadingComponentHtml: aiLoadingComponentHtml,
691
- models: aiModels,
692
- defaultModelId: aiDefaultModelId
693
- })
694
- }),
695
- /* @__PURE__ */ jsx(Suspense, {
696
- fallback: children,
697
- children: /* @__PURE__ */ jsx(DocsPageClient, {
698
- tocEnabled,
699
- tocStyle,
700
- breadcrumbEnabled,
701
- changelogBasePath,
702
- entry: localeContext.entryPath,
703
- locale: activeLocale,
704
- copyMarkdown: copyMarkdownEnabled,
705
- openDocs: openDocsEnabled,
706
- openDocsProviders,
707
- pageActionsPosition,
708
- pageActionsAlignment,
709
- githubUrl,
710
- contentDir,
711
- githubBranch,
712
- githubDirectory,
713
- lastModifiedMap,
714
- lastUpdatedEnabled,
715
- lastUpdatedPosition,
716
- readingTimeEnabled,
717
- readingTimeMap,
718
- llmsTxtEnabled,
719
- descriptionMap,
720
- feedbackEnabled: feedbackConfig.enabled,
721
- feedbackQuestion: feedbackConfig.question,
722
- feedbackPlaceholder: feedbackConfig.placeholder,
723
- feedbackPositiveLabel: feedbackConfig.positiveLabel,
724
- feedbackNegativeLabel: feedbackConfig.negativeLabel,
725
- feedbackSubmitLabel: feedbackConfig.submitLabel,
726
- children
727
- })
651
+ return /* @__PURE__ */ jsxs(DocsLayout, {
652
+ tree: localizedTree,
653
+ nav: {
654
+ title: navTitle,
655
+ url: navUrl
656
+ },
657
+ themeSwitch: i18n ? {
658
+ ...themeSwitch,
659
+ enabled: false
660
+ } : themeSwitch,
661
+ sidebar: finalSidebarProps,
662
+ ...aiMode === "sidebar-icon" && aiEnabled ? { searchToggle: { components: { lg: /* @__PURE__ */ jsx(SidebarSearchWithAI, {}) } } } : {},
663
+ children: [
664
+ /* @__PURE__ */ jsx(ColorStyle, { colors }),
665
+ /* @__PURE__ */ jsx(TypographyStyle, { typography }),
666
+ /* @__PURE__ */ jsx(LayoutStyle, { layout: layoutDimensions }),
667
+ forcedTheme && /* @__PURE__ */ jsx(ForcedThemeScript, { theme: forcedTheme }),
668
+ !staticExport && /* @__PURE__ */ jsx(Suspense, {
669
+ fallback: null,
670
+ children: /* @__PURE__ */ jsx(DocsCommandSearch, {
671
+ api: docsApiUrl,
672
+ locale: activeLocale
728
673
  })
729
- ]
730
- })
674
+ }),
675
+ aiEnabled && /* @__PURE__ */ jsx(Suspense, {
676
+ fallback: null,
677
+ children: /* @__PURE__ */ jsx(DocsAIFeatures, {
678
+ mode: aiMode,
679
+ api: docsApiUrl,
680
+ locale: activeLocale,
681
+ position: aiPosition,
682
+ floatingStyle: aiFloatingStyle,
683
+ triggerComponentHtml: aiTriggerComponentHtml,
684
+ suggestedQuestions: aiSuggestedQuestions,
685
+ aiLabel,
686
+ loaderVariant: aiLoaderVariant,
687
+ loadingComponentHtml: aiLoadingComponentHtml,
688
+ models: aiModels,
689
+ defaultModelId: aiDefaultModelId
690
+ })
691
+ }),
692
+ /* @__PURE__ */ jsx(Suspense, {
693
+ fallback: children,
694
+ children: /* @__PURE__ */ jsx(DocsPageClient, {
695
+ tocEnabled,
696
+ tocStyle,
697
+ breadcrumbEnabled,
698
+ changelogBasePath,
699
+ entry: localeContext.entryPath,
700
+ locale: activeLocale,
701
+ copyMarkdown: copyMarkdownEnabled,
702
+ openDocs: openDocsEnabled,
703
+ openDocsProviders,
704
+ pageActionsPosition,
705
+ pageActionsAlignment,
706
+ githubUrl,
707
+ contentDir,
708
+ githubBranch,
709
+ githubDirectory,
710
+ lastModifiedMap,
711
+ lastUpdatedEnabled,
712
+ lastUpdatedPosition,
713
+ readingTimeEnabled,
714
+ readingTimeMap,
715
+ llmsTxtEnabled,
716
+ descriptionMap,
717
+ feedbackEnabled: feedbackConfig.enabled,
718
+ feedbackQuestion: feedbackConfig.question,
719
+ feedbackPlaceholder: feedbackConfig.placeholder,
720
+ feedbackPositiveLabel: feedbackConfig.positiveLabel,
721
+ feedbackNegativeLabel: feedbackConfig.negativeLabel,
722
+ feedbackSubmitLabel: feedbackConfig.submitLabel,
723
+ children
724
+ })
725
+ })
726
+ ]
731
727
  });
732
728
  };
733
729
  }
@@ -282,80 +282,76 @@ function TanstackDocsLayout({ config, tree, locale, description, readingTime, la
282
282
  collapsible: sidebarProps.collapsible !== false,
283
283
  flat: !!sidebarFlat
284
284
  });
285
- return /* @__PURE__ */ jsx("div", {
286
- id: "nd-docs-layout",
287
- style: { display: "contents" },
288
- children: /* @__PURE__ */ jsxs(DocsLayout, {
289
- tree: resolvedTree,
290
- nav: {
291
- title: navTitle,
292
- url: navUrl
293
- },
294
- themeSwitch: locale && i18n?.locales ? {
295
- ...themeSwitch,
296
- enabled: false
297
- } : themeSwitch,
298
- sidebar: finalSidebarProps,
299
- ...aiMode === "sidebar-icon" && aiEnabled ? { searchToggle: { components: { lg: /* @__PURE__ */ jsx(SidebarSearchWithAI, {}) } } } : {},
300
- children: [
301
- /* @__PURE__ */ jsx(ColorStyle, { colors }),
302
- /* @__PURE__ */ jsx(TypographyStyle, { typography }),
303
- /* @__PURE__ */ jsx(LayoutStyle, { layout: layoutDimensions }),
304
- forcedTheme && /* @__PURE__ */ jsx(ForcedThemeScript, { theme: forcedTheme }),
305
- !staticExport && /* @__PURE__ */ jsx(Suspense, {
306
- fallback: null,
307
- children: /* @__PURE__ */ jsx(DocsCommandSearch, {
308
- api: docsApiUrl,
309
- locale
310
- })
311
- }),
312
- aiEnabled && /* @__PURE__ */ jsx(Suspense, {
313
- fallback: null,
314
- children: /* @__PURE__ */ jsx(DocsAIFeatures, {
315
- mode: aiMode,
316
- api: docsApiUrl,
317
- locale,
318
- position: aiPosition,
319
- floatingStyle: aiFloatingStyle,
320
- suggestedQuestions: aiSuggestedQuestions,
321
- aiLabel,
322
- loaderVariant: aiLoaderVariant,
323
- models: aiModels,
324
- defaultModelId: aiDefaultModelId
325
- })
326
- }),
327
- /* @__PURE__ */ jsx(Suspense, {
328
- fallback: children,
329
- children: /* @__PURE__ */ jsx(DocsPageClient, {
330
- tocEnabled,
331
- tocStyle,
332
- breadcrumbEnabled,
333
- entry: config.entry ?? "docs",
334
- locale,
335
- copyMarkdown: copyMarkdownEnabled,
336
- openDocs: openDocsEnabled,
337
- openDocsProviders,
338
- pageActionsPosition,
339
- pageActionsAlignment,
340
- editOnGithubUrl,
341
- lastUpdatedEnabled,
342
- lastUpdatedPosition,
343
- lastModified,
344
- readingTimeEnabled,
345
- readingTime: typeof readingTime === "number" ? readingTime : void 0,
346
- llmsTxtEnabled,
347
- description,
348
- feedbackEnabled: feedbackConfig.enabled,
349
- feedbackQuestion: feedbackConfig.question,
350
- feedbackPlaceholder: feedbackConfig.placeholder,
351
- feedbackPositiveLabel: feedbackConfig.positiveLabel,
352
- feedbackNegativeLabel: feedbackConfig.negativeLabel,
353
- feedbackSubmitLabel: feedbackConfig.submitLabel,
354
- children
355
- })
285
+ return /* @__PURE__ */ jsxs(DocsLayout, {
286
+ tree: resolvedTree,
287
+ nav: {
288
+ title: navTitle,
289
+ url: navUrl
290
+ },
291
+ themeSwitch: locale && i18n?.locales ? {
292
+ ...themeSwitch,
293
+ enabled: false
294
+ } : themeSwitch,
295
+ sidebar: finalSidebarProps,
296
+ ...aiMode === "sidebar-icon" && aiEnabled ? { searchToggle: { components: { lg: /* @__PURE__ */ jsx(SidebarSearchWithAI, {}) } } } : {},
297
+ children: [
298
+ /* @__PURE__ */ jsx(ColorStyle, { colors }),
299
+ /* @__PURE__ */ jsx(TypographyStyle, { typography }),
300
+ /* @__PURE__ */ jsx(LayoutStyle, { layout: layoutDimensions }),
301
+ forcedTheme && /* @__PURE__ */ jsx(ForcedThemeScript, { theme: forcedTheme }),
302
+ !staticExport && /* @__PURE__ */ jsx(Suspense, {
303
+ fallback: null,
304
+ children: /* @__PURE__ */ jsx(DocsCommandSearch, {
305
+ api: docsApiUrl,
306
+ locale
307
+ })
308
+ }),
309
+ aiEnabled && /* @__PURE__ */ jsx(Suspense, {
310
+ fallback: null,
311
+ children: /* @__PURE__ */ jsx(DocsAIFeatures, {
312
+ mode: aiMode,
313
+ api: docsApiUrl,
314
+ locale,
315
+ position: aiPosition,
316
+ floatingStyle: aiFloatingStyle,
317
+ suggestedQuestions: aiSuggestedQuestions,
318
+ aiLabel,
319
+ loaderVariant: aiLoaderVariant,
320
+ models: aiModels,
321
+ defaultModelId: aiDefaultModelId
356
322
  })
357
- ]
358
- })
323
+ }),
324
+ /* @__PURE__ */ jsx(Suspense, {
325
+ fallback: children,
326
+ children: /* @__PURE__ */ jsx(DocsPageClient, {
327
+ tocEnabled,
328
+ tocStyle,
329
+ breadcrumbEnabled,
330
+ entry: config.entry ?? "docs",
331
+ locale,
332
+ copyMarkdown: copyMarkdownEnabled,
333
+ openDocs: openDocsEnabled,
334
+ openDocsProviders,
335
+ pageActionsPosition,
336
+ pageActionsAlignment,
337
+ editOnGithubUrl,
338
+ lastUpdatedEnabled,
339
+ lastUpdatedPosition,
340
+ lastModified,
341
+ readingTimeEnabled,
342
+ readingTime: typeof readingTime === "number" ? readingTime : void 0,
343
+ llmsTxtEnabled,
344
+ description,
345
+ feedbackEnabled: feedbackConfig.enabled,
346
+ feedbackQuestion: feedbackConfig.question,
347
+ feedbackPlaceholder: feedbackConfig.placeholder,
348
+ feedbackPositiveLabel: feedbackConfig.positiveLabel,
349
+ feedbackNegativeLabel: feedbackConfig.negativeLabel,
350
+ feedbackSubmitLabel: feedbackConfig.submitLabel,
351
+ children
352
+ })
353
+ })
354
+ ]
359
355
  });
360
356
  }
361
357
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@farming-labs/theme",
3
- "version": "0.1.52",
3
+ "version": "0.1.54",
4
4
  "description": "Theme package for @farming-labs/docs — layout, provider, MDX components, and styles",
5
5
  "keywords": [
6
6
  "docs",
@@ -133,7 +133,7 @@
133
133
  "tsdown": "^0.20.3",
134
134
  "typescript": "^5.9.3",
135
135
  "vitest": "^3.2.4",
136
- "@farming-labs/docs": "0.1.52"
136
+ "@farming-labs/docs": "0.1.54"
137
137
  },
138
138
  "peerDependencies": {
139
139
  "@farming-labs/docs": ">=0.0.1",