fumadocs-core 16.19.4 → 16.19.5
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/{dynamic-BOCEF-LU.js → dynamic-DuFpoLBl.js} +2 -1
- package/dist/mdx-plugins/index.js +1 -1
- package/dist/mdx-plugins/rehype-code.core.js +1 -1
- package/dist/mdx-plugins/rehype-code.js +1 -1
- package/dist/{rehype-code.core-DNLXo8St.js → rehype-code.core-6imPTPeR.js} +5 -1
- package/dist/source/dynamic.js +1 -1
- package/dist/source/index.js +1 -1
- package/package.json +1 -1
|
@@ -283,7 +283,8 @@ function createContentStorageBuilder(loaderConfig) {
|
|
|
283
283
|
};
|
|
284
284
|
if (inputFile.dataAt) metaDataAt.set(file, inputFile.dataAt);
|
|
285
285
|
}
|
|
286
|
-
const [
|
|
286
|
+
const [key, locale = i18n ? i18n.defaultLanguage : EmptyLang] = i18n && inputFile.locale ? [inputFile.path, inputFile.locale] : parser(normalize(inputFile.path));
|
|
287
|
+
const storageKey = normalize(source.baseDir ? `${source.baseDir}/${key}` : key);
|
|
287
288
|
if (files) for (const item of files) add(storageKey, locale, item);
|
|
288
289
|
else add(storageKey, locale, file);
|
|
289
290
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { remarkGfm } from "./remark-gfm.js";
|
|
2
2
|
import { rehypeCode, rehypeCodeDefaultOptions } from "./rehype-code.js";
|
|
3
3
|
import { remarkImage } from "./remark-image.js";
|
|
4
|
-
import { i as transformerTab } from "../rehype-code.core-
|
|
4
|
+
import { i as transformerTab } from "../rehype-code.core-6imPTPeR.js";
|
|
5
5
|
import { transformerIcon } from "./transformer-icon.js";
|
|
6
6
|
import { extractCodeRegion, remarkInclude } from "./remark-include.js";
|
|
7
7
|
import { n as remarkStructureDefaultOptions, r as structure, t as remarkStructure } from "../remark-structure-DUU7_xF1.js";
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { i as transformerTab, n as rehypeCodeDefaultOptions, r as rehypeCodeFromHighlighter, t as createRehypeCode } from "../rehype-code.core-
|
|
1
|
+
import { i as transformerTab, n as rehypeCodeDefaultOptions, r as rehypeCodeFromHighlighter, t as createRehypeCode } from "../rehype-code.core-6imPTPeR.js";
|
|
2
2
|
import { transformerIcon } from "./transformer-icon.js";
|
|
3
3
|
export { createRehypeCode, rehypeCodeDefaultOptions, rehypeCodeFromHighlighter, transformerIcon, transformerTab };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defaultShikiFactory, wasmShikiFactory } from "../highlight/shiki/full.js";
|
|
2
|
-
import { i as transformerTab, n as rehypeCodeDefaultOptions$1, t as createRehypeCode } from "../rehype-code.core-
|
|
2
|
+
import { i as transformerTab, n as rehypeCodeDefaultOptions$1, t as createRehypeCode } from "../rehype-code.core-6imPTPeR.js";
|
|
3
3
|
import { transformerIcon } from "./transformer-icon.js";
|
|
4
4
|
// src/mdx-plugins/rehype-code.ts
|
|
5
5
|
const rehypeCodeDefaultOptions = {
|
|
@@ -526,7 +526,11 @@ function createRehypeCode(highlighterFactory) {
|
|
|
526
526
|
return {
|
|
527
527
|
...shiki,
|
|
528
528
|
codeToHast(code, options) {
|
|
529
|
-
if (!isSpecialLang(options.lang))
|
|
529
|
+
if (!isSpecialLang(options.lang)) try {
|
|
530
|
+
highlighter.getLanguage(options.lang);
|
|
531
|
+
} catch (error) {
|
|
532
|
+
throw new Error(`Unknown language "${options.lang}" in a code block. Correct it, or set \`fallbackLanguage: 'plaintext'\` in the Rehype Code options.`, { cause: error });
|
|
533
|
+
}
|
|
530
534
|
return shiki.codeToHast(code, options);
|
|
531
535
|
}
|
|
532
536
|
};
|
package/dist/source/dynamic.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export { t as dynamicLoader } from "../dynamic-
|
|
1
|
+
export { t as dynamicLoader } from "../dynamic-DuFpoLBl.js";
|
package/dist/source/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as isDynamicPath, c as FileSystem, i as getStaticParams, n as createGetUrl, o as multiple, r as loader, s as update, t as dynamicLoader } from "../dynamic-
|
|
1
|
+
import { a as isDynamicPath, c as FileSystem, i as getStaticParams, n as createGetUrl, o as multiple, r as loader, s as update, t as dynamicLoader } from "../dynamic-DuFpoLBl.js";
|
|
2
2
|
import { getSlugs } from "./plugins/slugs.js";
|
|
3
3
|
import { o as path_exports } from "../path-B8old5-F.js";
|
|
4
4
|
import { llms } from "./llms.js";
|