1- import remarkDirective from ' remark-directive' ;
1+ import remarkDirective from " remark-directive" ;
22import {
33 remarkDirectiveAdmonition ,
44 remarkMdxFiles ,
5- } from ' fumadocs-core/mdx-plugins' ;
6- import { remarkImage } from ' fumadocs-core/mdx-plugins' ;
5+ } from " fumadocs-core/mdx-plugins" ;
6+ import { remarkImage } from " fumadocs-core/mdx-plugins" ;
77import {
88 defineConfig ,
99 defineDocs ,
1010 frontmatterSchema ,
1111 metaSchema ,
12- } from ' fumadocs-mdx/config' ;
13- import lastModified from ' fumadocs-mdx/plugins/last-modified' ;
14- import { z } from ' zod' ;
15- import convert from ' npm-to-yarn' ;
12+ } from " fumadocs-mdx/config" ;
13+ import lastModified from " fumadocs-mdx/plugins/last-modified" ;
14+ import { z } from " zod" ;
15+ import convert from " npm-to-yarn" ;
1616
1717// You can customise Zod schemas for frontmatter and `meta.json` here
1818// see https://fumadocs.dev/docs/mdx/collections
1919export const docs = defineDocs ( {
20- dir : ' content/docs' ,
20+ dir : " content/docs" ,
2121 docs : {
2222 schema : frontmatterSchema . extend ( {
2323 image : z . string ( ) . optional ( ) ,
24- badge : z . enum ( [ ' early-access' , ' deprecated' , ' preview' ] ) . optional ( ) ,
24+ badge : z . enum ( [ " early-access" , " deprecated" , " preview" ] ) . optional ( ) ,
2525 url : z . string ( ) ,
2626 metaTitle : z . string ( ) ,
2727 metaDescription : z . string ( ) ,
@@ -37,11 +37,11 @@ export const docs = defineDocs({
3737
3838// v6 docs collection
3939export const docsV6 = defineDocs ( {
40- dir : ' content/docs.v6' ,
40+ dir : " content/docs.v6" ,
4141 docs : {
4242 schema : frontmatterSchema . extend ( {
4343 image : z . string ( ) . optional ( ) ,
44- badge : z . enum ( [ ' early-access' , ' deprecated' , ' preview' ] ) . optional ( ) ,
44+ badge : z . enum ( [ " early-access" , " deprecated" , " preview" ] ) . optional ( ) ,
4545 url : z . string ( ) ,
4646 metaTitle : z . string ( ) . optional ( ) ,
4747 metaDescription : z . string ( ) . optional ( ) ,
@@ -60,7 +60,22 @@ export default defineConfig({
6060 mdxOptions : {
6161 remarkPlugins : [
6262 remarkDirective ,
63- remarkDirectiveAdmonition ,
63+ [
64+ remarkDirectiveAdmonition ,
65+ {
66+ types : {
67+ note : "info" ,
68+ tip : "info" ,
69+ info : "info" ,
70+ warn : "warning" ,
71+ warning : "warning" ,
72+ danger : "error" ,
73+ success : "success" ,
74+ ppg : "ppg" ,
75+ error : "error" ,
76+ } ,
77+ } ,
78+ ] ,
6479 [ remarkImage , { useImport : false } ] ,
6580 remarkMdxFiles ,
6681 ] ,
@@ -69,19 +84,19 @@ export default defineConfig({
6984 } ,
7085 remarkNpmOptions : {
7186 persist : {
72- id : ' package-manager' ,
87+ id : " package-manager" ,
7388 } ,
7489 packageManagers : [
75- { command : ( cmd : string ) => convert ( cmd , ' npm' ) , name : ' npm' } ,
76- { command : ( cmd : string ) => convert ( cmd , ' pnpm' ) , name : ' pnpm' } ,
77- { command : ( cmd : string ) => convert ( cmd , ' yarn' ) , name : ' yarn' } ,
90+ { command : ( cmd : string ) => convert ( cmd , " npm" ) , name : " npm" } ,
91+ { command : ( cmd : string ) => convert ( cmd , " pnpm" ) , name : " pnpm" } ,
92+ { command : ( cmd : string ) => convert ( cmd , " yarn" ) , name : " yarn" } ,
7893 {
7994 command : ( cmd : string ) => {
80- const converted = convert ( cmd , ' bun' ) ;
95+ const converted = convert ( cmd , " bun" ) ;
8196 if ( ! converted ) return undefined ;
82- return converted . replace ( / ^ b u n x / , ' bunx --bun ' ) ;
97+ return converted . replace ( / ^ b u n x / , " bunx --bun " ) ;
8398 } ,
84- name : ' bun' ,
99+ name : " bun" ,
85100 } ,
86101 ] ,
87102 } ,
0 commit comments