blume 0.0.0 → 0.1.1
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/bin/blume.mjs +18 -0
- package/dist/cli/index.js +12696 -0
- package/dist/cli/index.js.map +145 -0
- package/dist/types/core/bridge.d.ts +24 -0
- package/dist/types/core/config.d.ts +35 -0
- package/dist/types/core/data.d.ts +129 -0
- package/dist/types/core/define-components.d.ts +27 -0
- package/dist/types/core/define-meta.d.ts +16 -0
- package/dist/types/core/deployment-env.d.ts +9 -0
- package/dist/types/core/diagnostics.d.ts +17 -0
- package/dist/types/core/i18n-ui.d.ts +500 -0
- package/dist/types/core/load-module.d.ts +7 -0
- package/dist/types/core/package-root.d.ts +17 -0
- package/dist/types/core/project.d.ts +9 -0
- package/dist/types/core/schema.d.ts +3451 -0
- package/dist/types/core/sources/types.d.ts +107 -0
- package/dist/types/core/types.d.ts +245 -0
- package/dist/types/core/ui-packs/ar.d.ts +3 -0
- package/dist/types/core/ui-packs/bg.d.ts +3 -0
- package/dist/types/core/ui-packs/bn.d.ts +3 -0
- package/dist/types/core/ui-packs/ca.d.ts +3 -0
- package/dist/types/core/ui-packs/cs.d.ts +3 -0
- package/dist/types/core/ui-packs/da.d.ts +3 -0
- package/dist/types/core/ui-packs/de.d.ts +3 -0
- package/dist/types/core/ui-packs/el.d.ts +3 -0
- package/dist/types/core/ui-packs/es.d.ts +3 -0
- package/dist/types/core/ui-packs/fa.d.ts +3 -0
- package/dist/types/core/ui-packs/fi.d.ts +3 -0
- package/dist/types/core/ui-packs/fr.d.ts +3 -0
- package/dist/types/core/ui-packs/he.d.ts +3 -0
- package/dist/types/core/ui-packs/hi.d.ts +3 -0
- package/dist/types/core/ui-packs/hr.d.ts +3 -0
- package/dist/types/core/ui-packs/hu.d.ts +3 -0
- package/dist/types/core/ui-packs/id.d.ts +3 -0
- package/dist/types/core/ui-packs/index.d.ts +13 -0
- package/dist/types/core/ui-packs/it.d.ts +3 -0
- package/dist/types/core/ui-packs/ja.d.ts +3 -0
- package/dist/types/core/ui-packs/ko.d.ts +3 -0
- package/dist/types/core/ui-packs/nl.d.ts +3 -0
- package/dist/types/core/ui-packs/no.d.ts +3 -0
- package/dist/types/core/ui-packs/pl.d.ts +3 -0
- package/dist/types/core/ui-packs/pt-br.d.ts +3 -0
- package/dist/types/core/ui-packs/pt.d.ts +3 -0
- package/dist/types/core/ui-packs/ro.d.ts +3 -0
- package/dist/types/core/ui-packs/ru.d.ts +3 -0
- package/dist/types/core/ui-packs/sk.d.ts +3 -0
- package/dist/types/core/ui-packs/sr.d.ts +3 -0
- package/dist/types/core/ui-packs/sv.d.ts +3 -0
- package/dist/types/core/ui-packs/th.d.ts +3 -0
- package/dist/types/core/ui-packs/tr.d.ts +3 -0
- package/dist/types/core/ui-packs/uk.d.ts +3 -0
- package/dist/types/core/ui-packs/vi.d.ts +3 -0
- package/dist/types/core/ui-packs/zh-tw.d.ts +3 -0
- package/dist/types/core/ui-packs/zh.d.ts +3 -0
- package/dist/types/core/version.d.ts +8 -0
- package/dist/types/index.d.ts +10 -0
- package/dist/types/migrate/mintlify/config.d.ts +2 -0
- package/dist/types/migrate/mintlify/i18n.d.ts +7 -0
- package/dist/types/theme/fonts.d.ts +163 -0
- package/docs/01-quickstart.mdx +99 -0
- package/docs/02-deployment.mdx +129 -0
- package/docs/advanced/api-reference.mdx +114 -0
- package/docs/advanced/blog.mdx +121 -0
- package/docs/advanced/changelog.mdx +113 -0
- package/docs/advanced/custom-pages.mdx +268 -0
- package/docs/advanced/meta.ts +7 -0
- package/docs/changelog/v0-1-0.mdx +12 -0
- package/docs/changelog/v0-2-0.mdx +16 -0
- package/docs/configuration/ai.mdx +228 -0
- package/docs/configuration/analytics.mdx +98 -0
- package/docs/configuration/customization.mdx +91 -0
- package/docs/configuration/export.mdx +70 -0
- package/docs/configuration/index.mdx +290 -0
- package/docs/configuration/meta.ts +15 -0
- package/docs/configuration/search.mdx +172 -0
- package/docs/configuration/seo.mdx +196 -0
- package/docs/configuration/theming.mdx +178 -0
- package/docs/content/components.mdx +651 -0
- package/docs/content/i18n.mdx +205 -0
- package/docs/content/index.mdx +161 -0
- package/docs/content/islands.mdx +94 -0
- package/docs/content/meta.mdx +119 -0
- package/docs/content/meta.ts +15 -0
- package/docs/content/navigation.mdx +168 -0
- package/docs/content/sources.mdx +216 -0
- package/docs/content/syntax.mdx +445 -0
- package/docs/index.mdx +112 -0
- package/docs/reference/cli.mdx +43 -0
- package/docs/reference/frontmatter.mdx +74 -0
- package/docs/reference/meta.ts +7 -0
- package/package.json +150 -6
- package/src/ai/ask.ts +93 -0
- package/src/ai/llms.ts +64 -0
- package/src/ai/markdown.ts +31 -0
- package/src/ai/mcp/data.ts +74 -0
- package/src/ai/mcp/discovery.ts +49 -0
- package/src/ai/mcp/server.ts +225 -0
- package/src/ai/mcp/tools.ts +47 -0
- package/src/assets/icon.png +0 -0
- package/src/astro/examples.ts +104 -0
- package/src/astro/generate.ts +1006 -0
- package/src/astro/index.ts +4 -0
- package/src/astro/integration.ts +74 -0
- package/src/astro/islands.ts +131 -0
- package/src/astro/markdown-negotiation.ts +68 -0
- package/src/astro/pages.ts +87 -0
- package/src/astro/templates.ts +1326 -0
- package/src/cli/commands/add.ts +81 -0
- package/src/cli/commands/build.ts +103 -0
- package/src/cli/commands/dev.ts +108 -0
- package/src/cli/commands/doctor.ts +74 -0
- package/src/cli/commands/eject.ts +57 -0
- package/src/cli/commands/init.ts +98 -0
- package/src/cli/commands/migrate.ts +39 -0
- package/src/cli/commands/preview.ts +39 -0
- package/src/cli/commands/sync.ts +52 -0
- package/src/cli/commands/validate.ts +61 -0
- package/src/cli/index.ts +35 -0
- package/src/cli/log.ts +37 -0
- package/src/cli/prepare.ts +80 -0
- package/src/components/Icon.astro +99 -0
- package/src/components/content/Accordion.astro +8 -0
- package/src/components/content/AccordionItem.astro +121 -0
- package/src/components/content/AutoTypeTable.astro +51 -0
- package/src/components/content/Badge.astro +124 -0
- package/src/components/content/Callout.astro +73 -0
- package/src/components/content/Card.astro +104 -0
- package/src/components/content/CardGroup.astro +14 -0
- package/src/components/content/CodeBlock.astro +28 -0
- package/src/components/content/CodeGroup.astro +13 -0
- package/src/components/content/Color.astro +15 -0
- package/src/components/content/ColorItem.astro +87 -0
- package/src/components/content/ColorRow.astro +10 -0
- package/src/components/content/Column.astro +6 -0
- package/src/components/content/Columns.astro +9 -0
- package/src/components/content/Component.astro +65 -0
- package/src/components/content/Diff.astro +44 -0
- package/src/components/content/Expandable.astro +11 -0
- package/src/components/content/FileTree.astro +8 -0
- package/src/components/content/Frame.astro +70 -0
- package/src/components/content/GithubInfo.astro +110 -0
- package/src/components/content/Math.astro +24 -0
- package/src/components/content/Panel.astro +20 -0
- package/src/components/content/Prompt.astro +129 -0
- package/src/components/content/Step.astro +34 -0
- package/src/components/content/Steps.astro +20 -0
- package/src/components/content/Tab.astro +46 -0
- package/src/components/content/Tabs.astro +273 -0
- package/src/components/content/Tile.astro +42 -0
- package/src/components/content/Tooltip.astro +68 -0
- package/src/components/content/Tree.astro +300 -0
- package/src/components/content/TreeFile.astro +15 -0
- package/src/components/content/TreeFolder.astro +62 -0
- package/src/components/content/TypeTable.astro +106 -0
- package/src/components/content/Update.astro +66 -0
- package/src/components/content/Visibility.astro +12 -0
- package/src/components/content/Warning.astro +9 -0
- package/src/components/content/auto-type-table.ts +141 -0
- package/src/components/content/diff.ts +95 -0
- package/src/components/content/github-info.ts +79 -0
- package/src/components/content/mermaid-element.ts +68 -0
- package/src/components/github-mark.ts +9 -0
- package/src/components/index.ts +14 -0
- package/src/components/islands/AskAI.astro +12 -0
- package/src/components/islands/ask-ai.tsx +156 -0
- package/src/components/layout/Analytics.astro +63 -0
- package/src/components/layout/Banner.astro +50 -0
- package/src/components/layout/Breadcrumbs.astro +31 -0
- package/src/components/layout/Favicon.astro +22 -0
- package/src/components/layout/Fonts.astro +14 -0
- package/src/components/layout/Header.astro +188 -0
- package/src/components/layout/LanguageSwitcher.astro +56 -0
- package/src/components/layout/NavTree.astro +462 -0
- package/src/components/layout/PageActions.astro +438 -0
- package/src/components/layout/PageFeedback.astro +58 -0
- package/src/components/layout/PageLayout.astro +173 -0
- package/src/components/layout/Pagination.astro +56 -0
- package/src/components/layout/ReferenceLayout.astro +107 -0
- package/src/components/layout/RootLayout.astro +537 -0
- package/src/components/layout/Search.astro +608 -0
- package/src/components/layout/TableOfContents.astro +68 -0
- package/src/components/layout/analytics-client.ts +38 -0
- package/src/components/layout/head-scripts.ts +19 -0
- package/src/components/layout/nav-utils.ts +87 -0
- package/src/components/layout/overrides.ts +32 -0
- package/src/components/layout/search/algolia.ts +43 -0
- package/src/components/layout/search/endpoint.ts +22 -0
- package/src/components/layout/search/flexsearch.ts +52 -0
- package/src/components/layout/search/orama-cloud.ts +41 -0
- package/src/components/layout/search/orama.ts +26 -0
- package/src/components/layout/search/pagefind.ts +43 -0
- package/src/components/layout/search/types.ts +163 -0
- package/src/components/layout/search/typesense.ts +60 -0
- package/src/components/layout/toc-element.ts +108 -0
- package/src/core/bridge.ts +92 -0
- package/src/core/config.ts +112 -0
- package/src/core/content.ts +50 -0
- package/src/core/data.ts +128 -0
- package/src/core/define-components.ts +34 -0
- package/src/core/define-meta.ts +20 -0
- package/src/core/deployment-env.ts +73 -0
- package/src/core/diagnostics.ts +104 -0
- package/src/core/frontmatter.ts +43 -0
- package/src/core/graph.ts +128 -0
- package/src/core/i18n-ui.ts +171 -0
- package/src/core/i18n.ts +169 -0
- package/src/core/last-modified.ts +88 -0
- package/src/core/links.ts +352 -0
- package/src/core/load-module.ts +15 -0
- package/src/core/manifest.ts +126 -0
- package/src/core/meta.ts +97 -0
- package/src/core/navigation.ts +392 -0
- package/src/core/package-root.ts +37 -0
- package/src/core/project-graph.ts +153 -0
- package/src/core/project.ts +56 -0
- package/src/core/schema.ts +1057 -0
- package/src/core/server-features.ts +23 -0
- package/src/core/sources/assets.ts +77 -0
- package/src/core/sources/cache.ts +122 -0
- package/src/core/sources/filesystem.ts +99 -0
- package/src/core/sources/mdx-remote.ts +215 -0
- package/src/core/sources/mintlify.ts +161 -0
- package/src/core/sources/normalize.ts +243 -0
- package/src/core/sources/notion.ts +440 -0
- package/src/core/sources/portable-text.ts +143 -0
- package/src/core/sources/read.ts +36 -0
- package/src/core/sources/resolve.ts +158 -0
- package/src/core/sources/sanity.ts +218 -0
- package/src/core/sources/types.ts +105 -0
- package/src/core/tsconfig-aliases.ts +201 -0
- package/src/core/types.ts +261 -0
- package/src/core/ui-packs/ar.ts +47 -0
- package/src/core/ui-packs/bg.ts +47 -0
- package/src/core/ui-packs/bn.ts +47 -0
- package/src/core/ui-packs/ca.ts +47 -0
- package/src/core/ui-packs/cs.ts +47 -0
- package/src/core/ui-packs/da.ts +47 -0
- package/src/core/ui-packs/de.ts +47 -0
- package/src/core/ui-packs/el.ts +47 -0
- package/src/core/ui-packs/es.ts +47 -0
- package/src/core/ui-packs/fa.ts +47 -0
- package/src/core/ui-packs/fi.ts +47 -0
- package/src/core/ui-packs/fr.ts +47 -0
- package/src/core/ui-packs/he.ts +47 -0
- package/src/core/ui-packs/hi.ts +47 -0
- package/src/core/ui-packs/hr.ts +47 -0
- package/src/core/ui-packs/hu.ts +47 -0
- package/src/core/ui-packs/id.ts +47 -0
- package/src/core/ui-packs/index.ts +87 -0
- package/src/core/ui-packs/it.ts +47 -0
- package/src/core/ui-packs/ja.ts +47 -0
- package/src/core/ui-packs/ko.ts +47 -0
- package/src/core/ui-packs/nl.ts +47 -0
- package/src/core/ui-packs/no.ts +47 -0
- package/src/core/ui-packs/pl.ts +47 -0
- package/src/core/ui-packs/pt-br.ts +47 -0
- package/src/core/ui-packs/pt.ts +47 -0
- package/src/core/ui-packs/ro.ts +47 -0
- package/src/core/ui-packs/ru.ts +47 -0
- package/src/core/ui-packs/sk.ts +47 -0
- package/src/core/ui-packs/sr.ts +47 -0
- package/src/core/ui-packs/sv.ts +47 -0
- package/src/core/ui-packs/th.ts +47 -0
- package/src/core/ui-packs/tr.ts +47 -0
- package/src/core/ui-packs/uk.ts +47 -0
- package/src/core/ui-packs/vi.ts +47 -0
- package/src/core/ui-packs/zh-tw.ts +47 -0
- package/src/core/ui-packs/zh.ts +47 -0
- package/src/core/version.ts +23 -0
- package/src/deploy/robots.ts +20 -0
- package/src/deploy/rss.ts +128 -0
- package/src/deploy/sitemap.ts +28 -0
- package/src/index.ts +39 -0
- package/src/markdown/code-title.ts +71 -0
- package/src/markdown/directives.ts +83 -0
- package/src/markdown/heading-anchors.ts +137 -0
- package/src/markdown/index.ts +228 -0
- package/src/markdown/inline-code.ts +108 -0
- package/src/markdown/language-icon.ts +172 -0
- package/src/markdown/math.ts +32 -0
- package/src/markdown/mdast.ts +48 -0
- package/src/markdown/mermaid.ts +37 -0
- package/src/markdown/package-commands.ts +159 -0
- package/src/markdown/package-install.ts +40 -0
- package/src/migrate/fumadocs/config.ts +155 -0
- package/src/migrate/fumadocs/content.ts +365 -0
- package/src/migrate/fumadocs/frontmatter.ts +18 -0
- package/src/migrate/fumadocs/groups.ts +230 -0
- package/src/migrate/fumadocs/index.ts +337 -0
- package/src/migrate/fumadocs/meta.ts +244 -0
- package/src/migrate/migrate.ts +53 -0
- package/src/migrate/mintlify/config.ts +1040 -0
- package/src/migrate/mintlify/content.ts +98 -0
- package/src/migrate/mintlify/frontmatter.ts +126 -0
- package/src/migrate/mintlify/i18n.ts +51 -0
- package/src/migrate/mintlify/icons.ts +128 -0
- package/src/migrate/mintlify/index.ts +266 -0
- package/src/migrate/mintlify/snippets.ts +306 -0
- package/src/migrate/mintlify/transform.ts +80 -0
- package/src/migrate/nextra/content.ts +46 -0
- package/src/migrate/nextra/frontmatter.ts +40 -0
- package/src/migrate/nextra/index.ts +374 -0
- package/src/migrate/nextra/meta.ts +266 -0
- package/src/migrate/shared.ts +720 -0
- package/src/migrate/starlight/config.ts +459 -0
- package/src/migrate/starlight/content.ts +78 -0
- package/src/migrate/starlight/frontmatter.ts +111 -0
- package/src/migrate/starlight/i18n.ts +54 -0
- package/src/migrate/starlight/index.ts +131 -0
- package/src/og/card.ts +92 -0
- package/src/og/index.ts +2 -0
- package/src/openapi/scalar.ts +246 -0
- package/src/registry/eject.ts +310 -0
- package/src/registry/registry.ts +100 -0
- package/src/registry/rewrite-imports.ts +39 -0
- package/src/runtime/index.ts +14 -0
- package/src/search/build.ts +23 -0
- package/src/search/documents.ts +164 -0
- package/src/search/orama-index.ts +66 -0
- package/src/search/providers.ts +91 -0
- package/src/search/sync/algolia.ts +30 -0
- package/src/search/sync/index.ts +50 -0
- package/src/search/sync/orama-cloud.ts +40 -0
- package/src/search/sync/typesense.ts +65 -0
- package/src/seo/jsonld.ts +113 -0
- package/src/theme/entry.ts +637 -0
- package/src/theme/fonts.ts +198 -0
- package/src/theme/icons.ts +184 -0
- package/src/theme/palette.ts +143 -0
- package/src/theme/twoslash.ts +81 -0
|
@@ -0,0 +1,201 @@
|
|
|
1
|
+
import { existsSync, readFileSync, statSync } from "node:fs";
|
|
2
|
+
import { createRequire } from "node:module";
|
|
3
|
+
import { pathToFileURL } from "node:url";
|
|
4
|
+
|
|
5
|
+
import { dirname, isAbsolute, join, resolve } from "pathe";
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* Read the project's TypeScript path aliases (`compilerOptions.paths`) and turn
|
|
9
|
+
* them into Vite `resolve.alias` entries, so `@/`-style imports in custom pages,
|
|
10
|
+
* islands, and components resolve in the generated Astro build exactly as they
|
|
11
|
+
* do in the user's own tooling.
|
|
12
|
+
*
|
|
13
|
+
* The generated `.blume/` runtime is its own Astro project with its own tsconfig
|
|
14
|
+
* and never inherits the project's, so without this every shadcn-style `@/…`
|
|
15
|
+
* import would have to be rewritten to a relative path. Reading the aliases here
|
|
16
|
+
* lets those components port over unchanged.
|
|
17
|
+
*
|
|
18
|
+
* Best-effort and non-fatal: tsconfig is parsed leniently (it is JSONC —
|
|
19
|
+
* comments and trailing commas), a single `extends` chain is followed to the
|
|
20
|
+
* file that actually declares `paths`, and anything unparseable yields no
|
|
21
|
+
* aliases (the prior behavior).
|
|
22
|
+
*/
|
|
23
|
+
|
|
24
|
+
/** Strip `//` line and `/* *\/` block comments that sit outside strings. */
|
|
25
|
+
const stripJsonComments = (text: string): string => {
|
|
26
|
+
let out = "";
|
|
27
|
+
let inString = false;
|
|
28
|
+
for (let index = 0; index < text.length; index += 1) {
|
|
29
|
+
const char = text[index];
|
|
30
|
+
if (inString) {
|
|
31
|
+
out += char;
|
|
32
|
+
if (char === "\\") {
|
|
33
|
+
out += text[index + 1] ?? "";
|
|
34
|
+
index += 1;
|
|
35
|
+
} else if (char === '"') {
|
|
36
|
+
inString = false;
|
|
37
|
+
}
|
|
38
|
+
continue;
|
|
39
|
+
}
|
|
40
|
+
if (char === '"') {
|
|
41
|
+
inString = true;
|
|
42
|
+
out += char;
|
|
43
|
+
continue;
|
|
44
|
+
}
|
|
45
|
+
if (char === "/" && text[index + 1] === "/") {
|
|
46
|
+
const newline = text.indexOf("\n", index + 2);
|
|
47
|
+
index = newline === -1 ? text.length : newline - 1;
|
|
48
|
+
continue;
|
|
49
|
+
}
|
|
50
|
+
if (char === "/" && text[index + 1] === "*") {
|
|
51
|
+
const end = text.indexOf("*/", index + 2);
|
|
52
|
+
index = end === -1 ? text.length : end + 1;
|
|
53
|
+
continue;
|
|
54
|
+
}
|
|
55
|
+
out += char;
|
|
56
|
+
}
|
|
57
|
+
return out;
|
|
58
|
+
};
|
|
59
|
+
|
|
60
|
+
const TRAILING_COMMA = /,(?<rest>\s*[}\]])/gu;
|
|
61
|
+
|
|
62
|
+
/** Parse JSONC (tsconfig) into a plain object, or null if it can't be read. */
|
|
63
|
+
const parseJsonc = (text: string): Record<string, unknown> | null => {
|
|
64
|
+
try {
|
|
65
|
+
const cleaned = stripJsonComments(text).replaceAll(
|
|
66
|
+
TRAILING_COMMA,
|
|
67
|
+
"$<rest>"
|
|
68
|
+
);
|
|
69
|
+
const value: unknown = JSON.parse(cleaned);
|
|
70
|
+
return value && typeof value === "object" && !Array.isArray(value)
|
|
71
|
+
? (value as Record<string, unknown>)
|
|
72
|
+
: null;
|
|
73
|
+
} catch {
|
|
74
|
+
return null;
|
|
75
|
+
}
|
|
76
|
+
};
|
|
77
|
+
|
|
78
|
+
const isFile = (path: string): boolean => {
|
|
79
|
+
try {
|
|
80
|
+
return statSync(path).isFile();
|
|
81
|
+
} catch {
|
|
82
|
+
return false;
|
|
83
|
+
}
|
|
84
|
+
};
|
|
85
|
+
|
|
86
|
+
/** Resolve a tsconfig `extends` target (relative path, directory, or package). */
|
|
87
|
+
const resolveExtends = (spec: string, fromDir: string): string | null => {
|
|
88
|
+
if (spec.startsWith(".") || isAbsolute(spec)) {
|
|
89
|
+
const candidates = spec.endsWith(".json")
|
|
90
|
+
? [resolve(fromDir, spec)]
|
|
91
|
+
: [
|
|
92
|
+
resolve(fromDir, `${spec}.json`),
|
|
93
|
+
resolve(fromDir, spec, "tsconfig.json"),
|
|
94
|
+
resolve(fromDir, spec),
|
|
95
|
+
];
|
|
96
|
+
return candidates.find(isFile) ?? null;
|
|
97
|
+
}
|
|
98
|
+
// A bare specifier points at a package's shared config (e.g. `@tsconfig/*`).
|
|
99
|
+
try {
|
|
100
|
+
const require_ = createRequire(pathToFileURL(join(fromDir, "_.js")).href);
|
|
101
|
+
for (const sub of [`${spec}/tsconfig.json`, spec]) {
|
|
102
|
+
try {
|
|
103
|
+
return require_.resolve(sub);
|
|
104
|
+
} catch {
|
|
105
|
+
// try the next candidate
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
} catch {
|
|
109
|
+
// createRequire failed; fall through
|
|
110
|
+
}
|
|
111
|
+
return null;
|
|
112
|
+
};
|
|
113
|
+
|
|
114
|
+
interface LoadedPaths {
|
|
115
|
+
/** Directory `paths` entries resolve against (`dirname(file)` + `baseUrl`). */
|
|
116
|
+
baseDir: string;
|
|
117
|
+
paths: Record<string, unknown>;
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
/** Find the nearest tsconfig in an `extends` chain that declares `paths`. */
|
|
121
|
+
const loadPaths = (file: string, seen: Set<string>): LoadedPaths | null => {
|
|
122
|
+
if (seen.has(file) || !existsSync(file)) {
|
|
123
|
+
return null;
|
|
124
|
+
}
|
|
125
|
+
seen.add(file);
|
|
126
|
+
const json = parseJsonc(readFileSync(file, "utf-8"));
|
|
127
|
+
if (!json) {
|
|
128
|
+
return null;
|
|
129
|
+
}
|
|
130
|
+
const options = (json.compilerOptions ?? {}) as Record<string, unknown>;
|
|
131
|
+
if (options.paths && typeof options.paths === "object") {
|
|
132
|
+
const baseUrl = typeof options.baseUrl === "string" ? options.baseUrl : ".";
|
|
133
|
+
return {
|
|
134
|
+
baseDir: resolve(dirname(file), baseUrl),
|
|
135
|
+
paths: options.paths as Record<string, unknown>,
|
|
136
|
+
};
|
|
137
|
+
}
|
|
138
|
+
// `extends` is a string or, since TS 5.0, an array searched first-to-last.
|
|
139
|
+
const bases = Array.isArray(json.extends)
|
|
140
|
+
? json.extends
|
|
141
|
+
: [json.extends].filter(Boolean);
|
|
142
|
+
for (const base of bases) {
|
|
143
|
+
if (typeof base !== "string") {
|
|
144
|
+
continue;
|
|
145
|
+
}
|
|
146
|
+
const resolved = resolveExtends(base, dirname(file));
|
|
147
|
+
const found = resolved ? loadPaths(resolved, seen) : null;
|
|
148
|
+
if (found) {
|
|
149
|
+
return found;
|
|
150
|
+
}
|
|
151
|
+
}
|
|
152
|
+
return null;
|
|
153
|
+
};
|
|
154
|
+
|
|
155
|
+
/** Convert one tsconfig `paths` mapping to a Vite alias, or null to skip. */
|
|
156
|
+
const toAlias = (
|
|
157
|
+
key: string,
|
|
158
|
+
value: unknown,
|
|
159
|
+
baseDir: string
|
|
160
|
+
): { find: string; replacement: string } | null => {
|
|
161
|
+
// tsconfig allows a fallback array; Vite aliases are 1:1, so take the first.
|
|
162
|
+
const first = Array.isArray(value) ? value[0] : value;
|
|
163
|
+
if (typeof first !== "string") {
|
|
164
|
+
return null;
|
|
165
|
+
}
|
|
166
|
+
const find = key.endsWith("/*") ? key.slice(0, -2) : key;
|
|
167
|
+
const target = first.endsWith("/*") ? first.slice(0, -2) : first;
|
|
168
|
+
// A bare `*`/`/*` catch-all would alias every import — never wire that.
|
|
169
|
+
if (find === "" || find === "*") {
|
|
170
|
+
return null;
|
|
171
|
+
}
|
|
172
|
+
return { find, replacement: resolve(baseDir, target) };
|
|
173
|
+
};
|
|
174
|
+
|
|
175
|
+
/**
|
|
176
|
+
* Resolve the project's tsconfig/jsconfig path aliases to absolute Vite
|
|
177
|
+
* `resolve.alias` entries (`find` → absolute replacement). Returns `{}` when no
|
|
178
|
+
* config or no usable `paths` is found.
|
|
179
|
+
*/
|
|
180
|
+
export const resolveTsconfigAliases = (
|
|
181
|
+
root: string
|
|
182
|
+
): Record<string, string> => {
|
|
183
|
+
const entry = ["tsconfig.json", "jsconfig.json"]
|
|
184
|
+
.map((name) => join(root, name))
|
|
185
|
+
.find((file) => existsSync(file));
|
|
186
|
+
if (!entry) {
|
|
187
|
+
return {};
|
|
188
|
+
}
|
|
189
|
+
const loaded = loadPaths(entry, new Set());
|
|
190
|
+
if (!loaded) {
|
|
191
|
+
return {};
|
|
192
|
+
}
|
|
193
|
+
const aliases: Record<string, string> = {};
|
|
194
|
+
for (const [key, value] of Object.entries(loaded.paths)) {
|
|
195
|
+
const alias = toAlias(key, value, loaded.baseDir);
|
|
196
|
+
if (alias) {
|
|
197
|
+
aliases[alias.find] = alias.replacement;
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
return aliases;
|
|
201
|
+
};
|
|
@@ -0,0 +1,261 @@
|
|
|
1
|
+
import type {
|
|
2
|
+
DirectoryMode,
|
|
3
|
+
PageMeta,
|
|
4
|
+
ResolvedConfig,
|
|
5
|
+
SidebarDisplay,
|
|
6
|
+
} from "./schema.ts";
|
|
7
|
+
|
|
8
|
+
/** Severity levels for Blume diagnostics. */
|
|
9
|
+
export type DiagnosticSeverity = "error" | "warning" | "info";
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
* A single actionable diagnostic. Diagnostics are printable in the CLI, the
|
|
13
|
+
* Astro/Vite overlay, and as JSON for editor integrations.
|
|
14
|
+
*/
|
|
15
|
+
export interface Diagnostic {
|
|
16
|
+
code: string;
|
|
17
|
+
severity: DiagnosticSeverity;
|
|
18
|
+
message: string;
|
|
19
|
+
file?: string;
|
|
20
|
+
line?: number;
|
|
21
|
+
column?: number;
|
|
22
|
+
schemaPath?: string;
|
|
23
|
+
suggestion?: string;
|
|
24
|
+
docsUrl?: string;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
/** A heading extracted from page content, used for the TOC and search. */
|
|
28
|
+
export interface Heading {
|
|
29
|
+
depth: number;
|
|
30
|
+
text: string;
|
|
31
|
+
slug: string;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
/** A link target discovered in page content, anchored to its source line. */
|
|
35
|
+
export interface PageLink {
|
|
36
|
+
/** Raw link target as written, e.g. `./foo`, `/api#auth`, `https://x.dev`. */
|
|
37
|
+
target: string;
|
|
38
|
+
/** 1-based line number in the source file. */
|
|
39
|
+
line: number;
|
|
40
|
+
/** 1-based column of the target within the line. */
|
|
41
|
+
column: number;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
/**
|
|
45
|
+
* Resolved project paths. Computed once per CLI invocation and threaded
|
|
46
|
+
* through the core pipeline.
|
|
47
|
+
*/
|
|
48
|
+
export interface ProjectContext {
|
|
49
|
+
/** Absolute path to the user project root. */
|
|
50
|
+
root: string;
|
|
51
|
+
/** Absolute path to the content root (e.g. `<root>/docs`). */
|
|
52
|
+
contentRoot: string;
|
|
53
|
+
/** Absolute path to the custom pages dir, if it exists. */
|
|
54
|
+
pagesRoot: string | null;
|
|
55
|
+
/** Absolute path to the generated runtime (`<root>/.blume`). */
|
|
56
|
+
outDir: string;
|
|
57
|
+
/** Absolute path to the user `theme.css`, if present. */
|
|
58
|
+
themeFile: string | null;
|
|
59
|
+
/** Absolute path to the user `components.ts`/`.tsx`, if present. */
|
|
60
|
+
componentsFile: string | null;
|
|
61
|
+
/** Absolute path to the resolved config file, if any was found. */
|
|
62
|
+
configFile: string | null;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
/**
|
|
66
|
+
* A normalized content page. This is the unit the route manifest, nav graph,
|
|
67
|
+
* and search index are derived from.
|
|
68
|
+
*/
|
|
69
|
+
export interface PageRecord {
|
|
70
|
+
/** Stable, globally-unique id: `"<source>:<ref>"`, e.g. `filesystem:api/auth.mdx`. */
|
|
71
|
+
id: string;
|
|
72
|
+
/** Provenance: the owning source's name and its source-local ref. */
|
|
73
|
+
source: { name: string; ref: string };
|
|
74
|
+
/** Absolute source path. Populated by the filesystem adapter only (back-compat). */
|
|
75
|
+
sourcePath?: string;
|
|
76
|
+
/**
|
|
77
|
+
* Renderable body captured at scan time. Set for staged (non-filesystem)
|
|
78
|
+
* sources so they can be materialized to `.blume/content` and so soft
|
|
79
|
+
* consumers need no re-read; omitted for filesystem entries (read from disk).
|
|
80
|
+
*/
|
|
81
|
+
body?: { format: "md" | "mdx"; text: string };
|
|
82
|
+
/** Adapter-supplied "edit this page" URL (non-filesystem sources). */
|
|
83
|
+
editUrl?: string;
|
|
84
|
+
/** Astro collection this entry renders through; defaults to `"docs"`. */
|
|
85
|
+
collection?: string;
|
|
86
|
+
/** Astro collection-relative entry id for `getEntry`; defaults to the ref. */
|
|
87
|
+
entryId?: string;
|
|
88
|
+
/** URL route, e.g. `/api/auth`. Always starts with `/`. Locale-prefixed under i18n. */
|
|
89
|
+
route: string;
|
|
90
|
+
/** Resolved locale code; the default locale when not under i18n. */
|
|
91
|
+
locale: string;
|
|
92
|
+
/**
|
|
93
|
+
* Locale-agnostic logical route shared by every translation (e.g.
|
|
94
|
+
* `/guides/x`). Pages with the same key are translations of each other.
|
|
95
|
+
*/
|
|
96
|
+
translationKey: string;
|
|
97
|
+
/**
|
|
98
|
+
* Content-relative path with the leading locale directory stripped, used for
|
|
99
|
+
* sidebar grouping so the locale dir is not surfaced as a nav group. Equals
|
|
100
|
+
* `id` for single-locale projects.
|
|
101
|
+
*/
|
|
102
|
+
navPath: string;
|
|
103
|
+
/** Path segments without numeric prefixes, e.g. `["api", "auth"]`. */
|
|
104
|
+
segments: string[];
|
|
105
|
+
/** Group-folder labels this page lives under, e.g. `["guides"]`. */
|
|
106
|
+
groups: string[];
|
|
107
|
+
title: string;
|
|
108
|
+
description?: string;
|
|
109
|
+
contentType: string;
|
|
110
|
+
meta: PageMeta;
|
|
111
|
+
headings: Heading[];
|
|
112
|
+
/** Whether the file is `.md`/`.mdx`. */
|
|
113
|
+
format: "md" | "mdx";
|
|
114
|
+
/** Internal/asset links discovered in the page (for validation). */
|
|
115
|
+
links: PageLink[];
|
|
116
|
+
/** Resolved "last updated" ISO date, when the feature is enabled. */
|
|
117
|
+
lastModified?: string;
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
/** A node in the generated navigation tree. */
|
|
121
|
+
export type NavNode =
|
|
122
|
+
| {
|
|
123
|
+
kind: "page";
|
|
124
|
+
label: string;
|
|
125
|
+
route: string;
|
|
126
|
+
description?: string;
|
|
127
|
+
icon?: string;
|
|
128
|
+
badge?: string;
|
|
129
|
+
deprecated?: boolean;
|
|
130
|
+
pageId: string;
|
|
131
|
+
}
|
|
132
|
+
| {
|
|
133
|
+
kind: "group";
|
|
134
|
+
label: string;
|
|
135
|
+
badge?: string;
|
|
136
|
+
directory?: DirectoryMode;
|
|
137
|
+
display?: SidebarDisplay;
|
|
138
|
+
icon?: string;
|
|
139
|
+
route?: string;
|
|
140
|
+
collapsed?: boolean;
|
|
141
|
+
children: NavNode[];
|
|
142
|
+
};
|
|
143
|
+
|
|
144
|
+
/** Top-level tab/section. */
|
|
145
|
+
export interface NavTab {
|
|
146
|
+
label: string;
|
|
147
|
+
path: string;
|
|
148
|
+
icon?: string;
|
|
149
|
+
items?: NavSelectorItem[];
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
/** A selectable navigation option inside a tab menu or top selector. */
|
|
153
|
+
export interface NavSelectorItem {
|
|
154
|
+
label: string;
|
|
155
|
+
path: string;
|
|
156
|
+
description?: string;
|
|
157
|
+
icon?: string;
|
|
158
|
+
tag?: string;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
/** Top-level Mintlify-style partition selectors. */
|
|
162
|
+
export interface NavSelector {
|
|
163
|
+
label: string;
|
|
164
|
+
kind: "dropdown" | "language" | "product" | "version";
|
|
165
|
+
items: NavSelectorItem[];
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
/** Sidebar tree used when the current route belongs to a nav partition. */
|
|
169
|
+
export interface NavSidebarVariant {
|
|
170
|
+
path: string;
|
|
171
|
+
sidebar: NavNode[];
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
/** Chrome overrides used when the current route belongs to a nav partition. */
|
|
175
|
+
export interface NavChromeVariant {
|
|
176
|
+
path: string;
|
|
177
|
+
banner?: ResolvedConfig["banner"];
|
|
178
|
+
footer?: ResolvedConfig["footer"];
|
|
179
|
+
navbar?: ResolvedConfig["navbar"];
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
/** The complete navigation model derived from the content graph. */
|
|
183
|
+
export interface Navigation {
|
|
184
|
+
tabs: NavTab[];
|
|
185
|
+
selectors: NavSelector[];
|
|
186
|
+
chromeVariants: NavChromeVariant[];
|
|
187
|
+
sidebar: NavNode[];
|
|
188
|
+
sidebarVariants: NavSidebarVariant[];
|
|
189
|
+
/** Repo URL for the header link, or null when hidden (`navigation.repo`). */
|
|
190
|
+
repoUrl?: string | null;
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
/** The full content graph: the source of truth for generated modules. */
|
|
194
|
+
export interface ContentGraph {
|
|
195
|
+
pages: PageRecord[];
|
|
196
|
+
/** Default-locale navigation (the whole site when not under i18n). */
|
|
197
|
+
navigation: Navigation;
|
|
198
|
+
/** Navigation per locale; one entry per configured locale under i18n. */
|
|
199
|
+
navigationByLocale: Record<string, Navigation>;
|
|
200
|
+
/** Map of route -> pageId for fast lookup and duplicate detection. */
|
|
201
|
+
routes: Map<string, string>;
|
|
202
|
+
diagnostics: Diagnostic[];
|
|
203
|
+
}
|
|
204
|
+
|
|
205
|
+
/** A locale a logical page exists in, for the switcher and `hreflang`. */
|
|
206
|
+
export interface RouteAlternate {
|
|
207
|
+
locale: string;
|
|
208
|
+
path: string;
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
/** A resolved language-switcher entry for the current page. */
|
|
212
|
+
export interface LocaleSwitchOption {
|
|
213
|
+
code: string;
|
|
214
|
+
label: string;
|
|
215
|
+
dir: "ltr" | "rtl";
|
|
216
|
+
/** Target URL: the real translation, or the localized fallback URL. */
|
|
217
|
+
href: string;
|
|
218
|
+
current: boolean;
|
|
219
|
+
/** True when this locale has no real translation (renders fallback content). */
|
|
220
|
+
untranslated: boolean;
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
/** A route entry written to `blume.manifest.json`. */
|
|
224
|
+
export interface RouteManifestEntry {
|
|
225
|
+
id: string;
|
|
226
|
+
/** Provenance: the owning source's name and its source-local ref. */
|
|
227
|
+
source: { name: string; ref: string };
|
|
228
|
+
/** Astro collection this entry renders through (`"docs"` | `"staged"`). */
|
|
229
|
+
collection: string;
|
|
230
|
+
/** Astro collection-relative entry id, passed to `getEntry`. */
|
|
231
|
+
entryId: string;
|
|
232
|
+
path: string;
|
|
233
|
+
/** Absolute source path; populated for filesystem entries only (back-compat). */
|
|
234
|
+
sourcePath?: string;
|
|
235
|
+
/** Adapter-supplied "edit this page" URL (non-filesystem sources). */
|
|
236
|
+
editUrl?: string;
|
|
237
|
+
title: string;
|
|
238
|
+
contentType: string;
|
|
239
|
+
hidden: boolean;
|
|
240
|
+
draft: boolean;
|
|
241
|
+
/** Whether the page should be included in the search index. */
|
|
242
|
+
indexable: boolean;
|
|
243
|
+
/** Resolved locale code; the default locale when not under i18n. */
|
|
244
|
+
locale: string;
|
|
245
|
+
/** Locales this logical page is genuinely translated into (excludes fallbacks). */
|
|
246
|
+
alternates: RouteAlternate[];
|
|
247
|
+
/** True when this route renders fallback content for a missing translation. */
|
|
248
|
+
fallback?: boolean;
|
|
249
|
+
/** Resolved "last updated" ISO date, when the feature is enabled. */
|
|
250
|
+
lastModified?: string;
|
|
251
|
+
}
|
|
252
|
+
|
|
253
|
+
/** The generated runtime contract between core and the Astro project. */
|
|
254
|
+
export interface BlumeManifest {
|
|
255
|
+
version: number;
|
|
256
|
+
blumeVersion: string;
|
|
257
|
+
projectRoot: string;
|
|
258
|
+
contentRoot: string;
|
|
259
|
+
output: ResolvedConfig["deployment"]["output"];
|
|
260
|
+
routes: RouteManifestEntry[];
|
|
261
|
+
}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import type { UIStringsOverride } from "../i18n-ui.ts";
|
|
2
|
+
|
|
3
|
+
/** Arabic (ar) UI strings. */
|
|
4
|
+
export const ar: UIStringsOverride = {
|
|
5
|
+
actions: {
|
|
6
|
+
addToCursor: "إضافة إلى Cursor",
|
|
7
|
+
addToVscode: "إضافة إلى VS Code",
|
|
8
|
+
askAI: "اسأل الذكاء الاصطناعي عن هذه الصفحة",
|
|
9
|
+
connectMcp: "الاتصال بـ MCP",
|
|
10
|
+
copied: "تم النسخ!",
|
|
11
|
+
copyClaudeCode: "نسخ أمر Claude Code",
|
|
12
|
+
copyMarkdown: "نسخ بصيغة Markdown",
|
|
13
|
+
copyServerUrl: "نسخ عنوان URL للخادم",
|
|
14
|
+
edit: "التعديل على GitHub",
|
|
15
|
+
openInChat: "فتح في المحادثة",
|
|
16
|
+
scrollToTop: "العودة إلى الأعلى",
|
|
17
|
+
},
|
|
18
|
+
ask: {
|
|
19
|
+
empty: "اطرح سؤالاً حول الوثائق.",
|
|
20
|
+
error: "عذراً، حدث خطأ ما.",
|
|
21
|
+
label: "اطرح سؤالاً",
|
|
22
|
+
placeholder: "اطرح سؤالاً…",
|
|
23
|
+
send: "إرسال",
|
|
24
|
+
title: "اسأل الذكاء الاصطناعي",
|
|
25
|
+
},
|
|
26
|
+
feedback: {
|
|
27
|
+
no: "لا",
|
|
28
|
+
question: "هل كانت هذه الصفحة مفيدة؟",
|
|
29
|
+
thanks: "شكراً على ملاحظاتك!",
|
|
30
|
+
yes: "نعم",
|
|
31
|
+
},
|
|
32
|
+
languageSwitcher: { label: "اللغة", untranslated: "غير مترجم" },
|
|
33
|
+
page: {
|
|
34
|
+
lastUpdated: "آخر تحديث في",
|
|
35
|
+
next: "التالي",
|
|
36
|
+
previous: "السابق",
|
|
37
|
+
skipToContent: "الانتقال إلى المحتوى",
|
|
38
|
+
},
|
|
39
|
+
search: {
|
|
40
|
+
button: "بحث",
|
|
41
|
+
devOnly: "البحث متاح في إصدار الإنتاج.",
|
|
42
|
+
label: "البحث في الوثائق",
|
|
43
|
+
noResults: "لم يتم العثور على نتائج.",
|
|
44
|
+
placeholder: "البحث في الوثائق…",
|
|
45
|
+
},
|
|
46
|
+
toc: { title: "في هذه الصفحة" },
|
|
47
|
+
};
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import type { UIStringsOverride } from "../i18n-ui.ts";
|
|
2
|
+
|
|
3
|
+
/** Bulgarian (bg) UI strings. */
|
|
4
|
+
export const bg: UIStringsOverride = {
|
|
5
|
+
actions: {
|
|
6
|
+
addToCursor: "Добави в Cursor",
|
|
7
|
+
addToVscode: "Добави във VS Code",
|
|
8
|
+
askAI: "Попитай ИИ за тази страница",
|
|
9
|
+
connectMcp: "Свържи се с MCP",
|
|
10
|
+
copied: "Копирано!",
|
|
11
|
+
copyClaudeCode: "Копирай командата на Claude Code",
|
|
12
|
+
copyMarkdown: "Копирай като Markdown",
|
|
13
|
+
copyServerUrl: "Копирай URL на сървъра",
|
|
14
|
+
edit: "Редактирай в GitHub",
|
|
15
|
+
openInChat: "Отвори в чата",
|
|
16
|
+
scrollToTop: "Нагоре",
|
|
17
|
+
},
|
|
18
|
+
ask: {
|
|
19
|
+
empty: "Задайте въпрос за документацията.",
|
|
20
|
+
error: "Съжаляваме, нещо се обърка.",
|
|
21
|
+
label: "Задайте въпрос",
|
|
22
|
+
placeholder: "Задайте въпрос…",
|
|
23
|
+
send: "Изпрати",
|
|
24
|
+
title: "Попитай ИИ",
|
|
25
|
+
},
|
|
26
|
+
feedback: {
|
|
27
|
+
no: "Не",
|
|
28
|
+
question: "Беше ли полезна тази страница?",
|
|
29
|
+
thanks: "Благодарим за обратната връзка!",
|
|
30
|
+
yes: "Да",
|
|
31
|
+
},
|
|
32
|
+
languageSwitcher: { label: "Език", untranslated: "Непреведено" },
|
|
33
|
+
page: {
|
|
34
|
+
lastUpdated: "Последна актуализация",
|
|
35
|
+
next: "Напред",
|
|
36
|
+
previous: "Назад",
|
|
37
|
+
skipToContent: "Към съдържанието",
|
|
38
|
+
},
|
|
39
|
+
search: {
|
|
40
|
+
button: "Търсене",
|
|
41
|
+
devOnly: "Търсенето е достъпно в производствената компилация.",
|
|
42
|
+
label: "Търсене в документацията",
|
|
43
|
+
noResults: "Няма намерени резултати.",
|
|
44
|
+
placeholder: "Търсене в документацията…",
|
|
45
|
+
},
|
|
46
|
+
toc: { title: "На тази страница" },
|
|
47
|
+
};
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import type { UIStringsOverride } from "../i18n-ui.ts";
|
|
2
|
+
|
|
3
|
+
/** Bengali (bn) UI strings. */
|
|
4
|
+
export const bn: UIStringsOverride = {
|
|
5
|
+
actions: {
|
|
6
|
+
addToCursor: "Cursor-এ যোগ করুন",
|
|
7
|
+
addToVscode: "VS Code-এ যোগ করুন",
|
|
8
|
+
askAI: "এই পৃষ্ঠা সম্পর্কে AI-কে জিজ্ঞাসা করুন",
|
|
9
|
+
connectMcp: "MCP-তে সংযোগ করুন",
|
|
10
|
+
copied: "অনুলিপি করা হয়েছে!",
|
|
11
|
+
copyClaudeCode: "Claude Code কমান্ড অনুলিপি করুন",
|
|
12
|
+
copyMarkdown: "Markdown হিসেবে অনুলিপি করুন",
|
|
13
|
+
copyServerUrl: "সার্ভার URL অনুলিপি করুন",
|
|
14
|
+
edit: "GitHub-এ সম্পাদনা করুন",
|
|
15
|
+
openInChat: "চ্যাটে খুলুন",
|
|
16
|
+
scrollToTop: "উপরে যান",
|
|
17
|
+
},
|
|
18
|
+
ask: {
|
|
19
|
+
empty: "ডকুমেন্টেশন সম্পর্কে একটি প্রশ্ন করুন।",
|
|
20
|
+
error: "দুঃখিত, কিছু একটা ভুল হয়েছে।",
|
|
21
|
+
label: "একটি প্রশ্ন করুন",
|
|
22
|
+
placeholder: "একটি প্রশ্ন করুন…",
|
|
23
|
+
send: "পাঠান",
|
|
24
|
+
title: "AI-কে জিজ্ঞাসা করুন",
|
|
25
|
+
},
|
|
26
|
+
feedback: {
|
|
27
|
+
no: "না",
|
|
28
|
+
question: "এই পৃষ্ঠাটি কি সহায়ক ছিল?",
|
|
29
|
+
thanks: "আপনার মতামতের জন্য ধন্যবাদ!",
|
|
30
|
+
yes: "হ্যাঁ",
|
|
31
|
+
},
|
|
32
|
+
languageSwitcher: { label: "ভাষা", untranslated: "অনূদিত নয়" },
|
|
33
|
+
page: {
|
|
34
|
+
lastUpdated: "সর্বশেষ আপডেট",
|
|
35
|
+
next: "পরবর্তী",
|
|
36
|
+
previous: "পূর্ববর্তী",
|
|
37
|
+
skipToContent: "বিষয়বস্তুতে যান",
|
|
38
|
+
},
|
|
39
|
+
search: {
|
|
40
|
+
button: "অনুসন্ধান",
|
|
41
|
+
devOnly: "অনুসন্ধান প্রোডাকশন বিল্ডে উপলব্ধ।",
|
|
42
|
+
label: "ডকুমেন্টেশন অনুসন্ধান করুন",
|
|
43
|
+
noResults: "কোনো ফলাফল পাওয়া যায়নি।",
|
|
44
|
+
placeholder: "ডকুমেন্টেশন অনুসন্ধান করুন…",
|
|
45
|
+
},
|
|
46
|
+
toc: { title: "এই পৃষ্ঠায়" },
|
|
47
|
+
};
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import type { UIStringsOverride } from "../i18n-ui.ts";
|
|
2
|
+
|
|
3
|
+
/** Catalan (ca) UI strings. */
|
|
4
|
+
export const ca: UIStringsOverride = {
|
|
5
|
+
actions: {
|
|
6
|
+
addToCursor: "Afegeix a Cursor",
|
|
7
|
+
addToVscode: "Afegeix a VS Code",
|
|
8
|
+
askAI: "Pregunta a la IA sobre aquesta pàgina",
|
|
9
|
+
connectMcp: "Connecta a MCP",
|
|
10
|
+
copied: "Copiat!",
|
|
11
|
+
copyClaudeCode: "Copia l'ordre de Claude Code",
|
|
12
|
+
copyMarkdown: "Copia com a Markdown",
|
|
13
|
+
copyServerUrl: "Copia l'URL del servidor",
|
|
14
|
+
edit: "Edita a GitHub",
|
|
15
|
+
openInChat: "Obre al xat",
|
|
16
|
+
scrollToTop: "Torna a dalt",
|
|
17
|
+
},
|
|
18
|
+
ask: {
|
|
19
|
+
empty: "Fes una pregunta sobre la documentació.",
|
|
20
|
+
error: "Ho sentim, alguna cosa ha anat malament.",
|
|
21
|
+
label: "Fes una pregunta",
|
|
22
|
+
placeholder: "Fes una pregunta…",
|
|
23
|
+
send: "Envia",
|
|
24
|
+
title: "Pregunta a la IA",
|
|
25
|
+
},
|
|
26
|
+
feedback: {
|
|
27
|
+
no: "No",
|
|
28
|
+
question: "Aquesta pàgina t'ha estat útil?",
|
|
29
|
+
thanks: "Gràcies pels teus comentaris!",
|
|
30
|
+
yes: "Sí",
|
|
31
|
+
},
|
|
32
|
+
languageSwitcher: { label: "Idioma", untranslated: "Sense traduir" },
|
|
33
|
+
page: {
|
|
34
|
+
lastUpdated: "Última actualització el",
|
|
35
|
+
next: "Següent",
|
|
36
|
+
previous: "Anterior",
|
|
37
|
+
skipToContent: "Vés al contingut",
|
|
38
|
+
},
|
|
39
|
+
search: {
|
|
40
|
+
button: "Cerca",
|
|
41
|
+
devOnly: "La cerca està disponible a la compilació de producció.",
|
|
42
|
+
label: "Cerca a la documentació",
|
|
43
|
+
noResults: "No s'ha trobat cap resultat.",
|
|
44
|
+
placeholder: "Cerca a la documentació…",
|
|
45
|
+
},
|
|
46
|
+
toc: { title: "En aquesta pàgina" },
|
|
47
|
+
};
|