@farming-labs/theme 0.1.32 → 0.1.34

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.
package/dist/docs-api.mjs CHANGED
@@ -36,6 +36,9 @@ const DEFAULT_DOCS_API_ROUTE = "/api/docs";
36
36
  const DEFAULT_AGENT_SPEC_ROUTE = "/api/docs/agent/spec";
37
37
  const DEFAULT_AGENT_SPEC_WELL_KNOWN_ROUTE = "/.well-known/agent";
38
38
  const DEFAULT_AGENT_SPEC_WELL_KNOWN_JSON_ROUTE = "/.well-known/agent.json";
39
+ const DEFAULT_MCP_ROUTE = "/api/docs/mcp";
40
+ const DEFAULT_MCP_PUBLIC_ROUTE = "/mcp";
41
+ const DEFAULT_MCP_WELL_KNOWN_ROUTE = "/.well-known/mcp";
39
42
  const DEFAULT_LLMS_TXT_ROUTE = "/llms.txt";
40
43
  const DEFAULT_LLMS_FULL_TXT_ROUTE = "/llms-full.txt";
41
44
  const DEFAULT_LLMS_TXT_WELL_KNOWN_ROUTE = "/.well-known/llms.txt";
@@ -244,6 +247,11 @@ function buildAgentSpec({ origin, entry, i18n, search, mcp, feedback, llms }) {
244
247
  mcp: {
245
248
  enabled: mcp.enabled,
246
249
  endpoint: mcp.route,
250
+ defaultEndpoint: DEFAULT_MCP_PUBLIC_ROUTE,
251
+ publicEndpoint: DEFAULT_MCP_PUBLIC_ROUTE,
252
+ wellKnownEndpoint: DEFAULT_MCP_WELL_KNOWN_ROUTE,
253
+ publicEndpoints: [DEFAULT_MCP_PUBLIC_ROUTE, DEFAULT_MCP_WELL_KNOWN_ROUTE],
254
+ canonicalEndpoint: DEFAULT_MCP_ROUTE,
247
255
  name: mcp.name,
248
256
  version: mcp.version,
249
257
  tools: mcp.tools
@@ -165,7 +165,7 @@ function DocsPageClient({ tocEnabled, tocStyle = "default", breadcrumbEnabled =
165
165
  const [browserPath, setBrowserPath] = useState(null);
166
166
  const pathname = usePathname();
167
167
  const activeLocale = resolveClientLocale(useWindowSearchParams(), locale);
168
- const llmsLangParam = activeLocale ? `&lang=${encodeURIComponent(activeLocale)}` : "";
168
+ const llmsLangQuery = activeLocale ? `?lang=${encodeURIComponent(activeLocale)}` : "";
169
169
  const pageDescription = description ?? descriptionMap?.[pathname.replace(/\/$/, "") || "/"];
170
170
  const normalizedPath = (browserPath ?? pathname).replace(/\/$/, "") || "/";
171
171
  const isChangelogRoute = !!(changelogBasePath && (normalizedPath === changelogBasePath || normalizedPath.startsWith(`${changelogBasePath}/`)));
@@ -361,13 +361,13 @@ function DocsPageClient({ tocEnabled, tocStyle = "default", breadcrumbEnabled =
361
361
  llmsTxtEnabled && /* @__PURE__ */ jsxs("span", {
362
362
  className: "fd-llms-txt-links",
363
363
  children: [/* @__PURE__ */ jsx("a", {
364
- href: `/api/docs?format=llms${llmsLangParam}`,
364
+ href: `/llms.txt${llmsLangQuery}`,
365
365
  target: "_blank",
366
366
  rel: "noopener noreferrer",
367
367
  className: "fd-llms-txt-link",
368
368
  children: "llms.txt"
369
369
  }), /* @__PURE__ */ jsx("a", {
370
- href: `/api/docs?format=llms-full${llmsLangParam}`,
370
+ href: `/llms-full.txt${llmsLangQuery}`,
371
371
  target: "_blank",
372
372
  rel: "noopener noreferrer",
373
373
  className: "fd-llms-txt-link",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@farming-labs/theme",
3
- "version": "0.1.32",
3
+ "version": "0.1.34",
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.32"
136
+ "@farming-labs/docs": "0.1.34"
137
137
  },
138
138
  "peerDependencies": {
139
139
  "@farming-labs/docs": ">=0.0.1",