typerighter 0.42.0 → 0.43.0

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.
Files changed (54) hide show
  1. package/dist/{app-xAspP0Kq.js → app-DjpuKzvd.js} +17 -5
  2. package/dist/{cli-xL59SSOm.js → cli-DKDYNRYe.js} +5 -5
  3. package/dist/cli.js +1 -1
  4. package/dist/client/app/index.d.ts +29 -5
  5. package/dist/client/app/index.d.ts.map +1 -1
  6. package/dist/client/app/router.d.ts.map +1 -1
  7. package/dist/client/index.d.ts +2 -1
  8. package/dist/client/index.d.ts.map +1 -1
  9. package/dist/client/theme-default.js +822 -715
  10. package/dist/client.js +1 -1
  11. package/dist/fonts.css +2 -0
  12. package/dist/index.js +3 -3
  13. package/dist/{init-vb1LEYkf.js → init-sdwwozr2.js} +3 -2
  14. package/dist/inlineRe-Cn-J_E76.js +4 -0
  15. package/dist/{jsonld-Du1iJ_fG.js → jsonld-Crj_9xpa.js} +1 -1
  16. package/dist/node/build/fonts.d.ts +2 -0
  17. package/dist/node/build/fonts.d.ts.map +1 -0
  18. package/dist/node/build/index.d.ts.map +1 -1
  19. package/dist/node/build/prerender.d.ts.map +1 -1
  20. package/dist/node/cli/init.d.ts.map +1 -1
  21. package/dist/node/lib/codegen/app-entry.d.ts +30 -0
  22. package/dist/node/lib/codegen/app-entry.d.ts.map +1 -0
  23. package/dist/node/lib/codegen/components.d.ts +7 -0
  24. package/dist/node/lib/codegen/components.d.ts.map +1 -0
  25. package/dist/node/lib/codegen/index.d.ts +4 -0
  26. package/dist/node/lib/codegen/index.d.ts.map +1 -0
  27. package/dist/node/lib/codegen/theme.d.ts +5 -0
  28. package/dist/node/lib/codegen/theme.d.ts.map +1 -0
  29. package/dist/node/lib/render/postprocess.d.ts +1 -0
  30. package/dist/node/lib/render/postprocess.d.ts.map +1 -1
  31. package/dist/node/lib/render/vue.d.ts.map +1 -1
  32. package/dist/node/plugin/vite/constants.d.ts +2 -0
  33. package/dist/node/plugin/vite/constants.d.ts.map +1 -1
  34. package/dist/node/plugin/vite/index.d.ts +1 -1
  35. package/dist/node/plugin/vite/index.d.ts.map +1 -1
  36. package/dist/node/plugin/vite/virtual/app.d.ts +3 -21
  37. package/dist/node/plugin/vite/virtual/app.d.ts.map +1 -1
  38. package/dist/node/plugin/vite/virtual/theme.d.ts +7 -0
  39. package/dist/node/plugin/vite/virtual/theme.d.ts.map +1 -0
  40. package/dist/prerenderWorker.js +2 -2
  41. package/dist/renderMath-C2Z7HdfG.js +19 -0
  42. package/dist/shared/types/ssg.d.ts +4 -0
  43. package/dist/shared/types/ssg.d.ts.map +1 -1
  44. package/dist/shared/utils/format.d.ts +2 -0
  45. package/dist/shared/utils/format.d.ts.map +1 -1
  46. package/dist/shared/utils/format.test.d.ts +2 -0
  47. package/dist/shared/utils/format.test.d.ts.map +1 -0
  48. package/dist/{shared-BMujDY3P.js → shared-QuBFygxT.js} +104 -98
  49. package/dist/shared.js +1 -1
  50. package/dist/typedown.schema.json +133 -0
  51. package/dist/typerighter.css +1 -1
  52. package/dist/{vite-Dup9wBL7.js → vite-Cj1Ofykq.js} +540 -425
  53. package/dist/vite.js +1 -1
  54. package/package.json +6 -4
package/dist/client.js CHANGED
@@ -1 +1 @@
1
- export { s as Content, t as createTypedownApp, c as useRoute, l as useRouter, r as useSiteConfig, i as useSiteData, a as useTdContent } from "./app-xAspP0Kq.js";
1
+ export { s as Content, t as createTypedownApp, c as useRoute, l as useRouter, r as useSiteConfig, i as useSiteData, a as useTdContent, o as useTheme } from "./app-DjpuKzvd.js";
package/dist/fonts.css ADDED
@@ -0,0 +1,2 @@
1
+ @import "@fontsource-variable/inter";
2
+ @import "@fontsource-variable/jetbrains-mono";
package/dist/index.js CHANGED
@@ -1,3 +1,3 @@
1
- import { n as e, r as t, t as n } from "./vite-Dup9wBL7.js";
2
- import { t as r } from "./cli-xL59SSOm.js";
3
- export { t as buildSite, r as cli, e as generateClientAppEntry, n as typedown };
1
+ import { a as e, i as t, n, o as r, r as i, s as a, t as o } from "./vite-Cj1Ofykq.js";
2
+ import { t as s } from "./cli-DKDYNRYe.js";
3
+ export { n as PAGES_ID, i as PAGE_DATA_EVENT, t as SEARCH_INDEX_ID, e as SITE_DATA_ID, r as THEME_ID, a as buildSite, s as cli, o as typedown };
@@ -746,7 +746,7 @@ function He(e) {
746
746
  build: "typerighter build",
747
747
  preview: "typerighter preview"
748
748
  },
749
- devDependencies: { typerighter: "^0.42.0" }
749
+ devDependencies: { typerighter: "^0.43.0" }
750
750
  }, void 0, 2) + "\n";
751
751
  }
752
752
  function Ue() {
@@ -760,7 +760,8 @@ function Ge() {
760
760
  }
761
761
  function Ke(e) {
762
762
  let t = e.siteOrigin === "" ? "" : `\n origin: "${e.siteOrigin}"`;
763
- return `version: "1.0.0"
763
+ return `# yaml-language-server: $schema=./node_modules/typerighter/dist/typedown.schema.json
764
+ version: "1.0.0"
764
765
  vault:
765
766
  root_dir: "vault"
766
767
  site:
@@ -0,0 +1,4 @@
1
+ //#region src/client/theme-default/utils/inlineRe.ts
2
+ var e = /`([^`]+)`|\$([^$]+)\$/g;
3
+ //#endregion
4
+ export { e as t };
@@ -1,4 +1,4 @@
1
- import { W as e, c as t, i as n } from "./shared-BMujDY3P.js";
1
+ import { K as e, c as t, i as n } from "./shared-QuBFygxT.js";
2
2
  //#region src/node/lib/htmlTemplate.ts
3
3
  function r(e) {
4
4
  let n = t(e.title), r = t(e.description), i = e.siteTitle !== void 0 && e.title !== e.siteTitle ? `${n} - ${t(e.siteTitle)}` : n, a = e.origin ?? "", o = e.canonicalUrl === void 0 ? void 0 : a + e.canonicalUrl, s = o === void 0 ? "" : `\n <link rel="canonical" href="${t(o)}">`, c = o === void 0 ? "" : `\n <meta property="og:url" content="${t(o)}">`, l = e.ogImagePath === void 0 ? `${a}${e.base}og-image.png` : `${a}${e.ogImagePath}`, u = e.author === void 0 ? "" : `\n <meta name="author" content="${t(e.author)}">`, d = e.siteTitle === void 0 ? "" : `\n <meta property="og:site_name" content="${t(e.siteTitle)}">`, f = a === "" ? "" : `\n <link rel="alternate" type="application/rss+xml" title="${e.siteTitle === void 0 ? "RSS Feed" : t(e.siteTitle)}" href="${a}${e.base}feed.xml">`, p = (e.jsonLdBlocks ?? []).map((e) => `\n <script type="application/ld+json">${e}<\/script>`).join(""), m = e.headExtra === void 0 ? "" : e.headExtra + "\n";
@@ -0,0 +1,2 @@
1
+ export declare function isCriticalFontFile(filePath: string): boolean;
2
+ //# sourceMappingURL=fonts.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fonts.d.ts","sourceRoot":"","sources":["../../../src/node/build/fonts.ts"],"names":[],"mappings":"AAMA,wBAAgB,kBAAkB,CAAE,QAAQ,EAAE,MAAM,GAAG,OAAO,CAO7D"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/node/build/index.ts"],"names":[],"mappings":"AAEA,OAAO,EACE,KAAK,YAAY,EACzB,MAAM,MAAM,CAAC;AAcd,OAAO,KAAK,EACV,UAAU,EACX,MAAM,YAAY,CAAC;AAOpB,MAAM,WAAW,YAAY;IAC3B,6DAA6D;IAC7D,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,sCAAsC;IACtC,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,uCAAuC;IACvC,UAAU,CAAC,EAAE,YAAY,CAAC;CAC3B;AAGD,wBAAsB,SAAS,CAAE,GAAG,EAAE,UAAU,EAAE,OAAO,GAAE,YAAiB,GAAG,OAAO,CAAC,IAAI,CAAC,CAwM3F"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/node/build/index.ts"],"names":[],"mappings":"AAEA,OAAO,EACE,KAAK,YAAY,EACzB,MAAM,MAAM,CAAC;AAkBd,OAAO,KAAK,EACV,UAAU,EACX,MAAM,YAAY,CAAC;AAMpB,MAAM,WAAW,YAAY;IAC3B,6DAA6D;IAC7D,MAAM,CAAC,EAAE,MAAM,CAAC;I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kB,CAAE,OAAO,EAAE,gBAAgB,GAAG,OAAO,CAAC,IAAI,CAAC,CAmBlF"}
@@ -1 +1 @@
1
- {"version":3,"file":"init.d.ts","sourceRoot":"","sources":["../../../src/node/cli/init.ts"],"names":[],"mappings":"AAYA,MAAM,WAAW,eAAe;IAC9B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,GAAG,CAAC,EAAE,OAAO,CAAC;CACf;AAED,wBAAsB,UAAU,CAAE,IAAI,EAAE,MAAM,EAAE,KAAK,GAAE,eAAoB,GAAG,OAAO,CAAC,IAAI,CAAC,CAW1F"}
1
+ {"version":3,"file":"init.d.ts","sourceRoot":"","sources":["../../../src/node/cli/init.ts"],"names":[],"mappings":"AAsBA,MAAM,WAAW,eAAe;IAC9B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,GAAG,CAAC,EAAE,OAAO,CAAC;CACf;AAED,wBAAsB,UAAU,CAC9B,IAAI,EAAE,MAAM,EACZ,KAAK,GAAE,eAAoB,GAC1B,OAAO,CAAC,IAAI,CAAC,CAWf"}
@@ -0,0 +1,30 @@
1
+ import type { UserComponent } from './components';
2
+ export interface AppEntryOptions {
3
+ rootDir?: string;
4
+ basePath?: string;
5
+ origin?: string;
6
+ lang?: string;
7
+ siteTitle: string;
8
+ siteDescription: string;
9
+ repo?: {
10
+ url: string;
11
+ root: string;
12
+ };
13
+ author?: string;
14
+ license?: string;
15
+ nav?: {
16
+ title: string;
17
+ link: string;
18
+ icon?: string;
19
+ }[];
20
+ userComponents?: UserComponent[];
21
+ }
22
+ export interface VirtualModuleIds {
23
+ theme: string;
24
+ pages: string;
25
+ siteData: string;
26
+ searchIndex: string;
27
+ pageDataEvent: string;
28
+ }
29
+ export declare function generateAppEntry(options: AppEntryOptions, ids: VirtualModuleIds): string;
30
+ //# sourceMappingURL=app-entry.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"app-entry.d.ts","sourceRoot":"","sources":["../../../../src/node/lib/codegen/app-entry.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,aAAa,EACd,MAAM,cAAc,CAAC;AAKtB,MAAM,WAAW,eAAe;IAC9B,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,SAAS,EAAE,MAAM,CAAC;IAClB,eAAe,EAAE,MAAM,CAAC;IACxB,IAAI,CAAC,EAAE;QACL,GAAG,EAAE,MAAM,CAAC;QACZ,IAAI,EAAE,MAAM,CAAC;KACd,CAAC;IACF,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,GAAG,CAAC,EAAE;QACJ,KAAK,EAAE,MAAM,CAAC;QACd,IAAI,EAAE,MAAM,CAAC;QACb,IAAI,CAAC,EAAE,MAAM,CAAC;KACf,EAAE,CAAC;IACJ,cAAc,CAAC,EAAE,aAAa,EAAE,CAAC;CAClC;AAGD,MAAM,WAAW,gBAAgB;IAC/B,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,aAAa,EAAE,MAAM,CAAC;CACvB;AAID,wBAAgB,gBAAgB,CAAE,OAAO,EAAE,eAAe,EAAE,GAAG,EAAE,gBAAgB,GAAG,MAAM,CA8GzF"}
@@ -0,0 +1,7 @@
1
+ import type { TdComponentEntry } from '@typerighter/rpc-client';
2
+ export interface UserComponent {
3
+ name: string;
4
+ absolutePath: string;
5
+ }
6
+ export declare function resolveUserComponents(entries: TdComponentEntry[], projectRoot: string): Promise<UserComponent[]>;
7
+ //# sourceMappingURL=components.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"components.d.ts","sourceRoot":"","sources":["../../../../src/node/lib/codegen/components.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EACV,gBAAgB,EACjB,MAAM,yBAAyB,CAAC;AAEjC,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,MAAM,CAAC;IACb,YAAY,EAAE,MAAM,CAAC;CACtB;AAGD,wBAAsB,qBAAqB,CACzC,OAAO,EAAE,gBAAgB,EAAE,EAC3B,WAAW,EAAE,MAAM,GAClB,OAAO,CAAC,aAAa,EAAE,CAAC,CAiC1B"}
@@ -0,0 +1,4 @@
1
+ export { generateAppEntry, type AppEntryOptions, type VirtualModuleIds, } from './app-entry';
2
+ export { generateThemeModule, } from './theme';
3
+ export { resolveUserComponents, type UserComponent, } from './components';
4
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/node/lib/codegen/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,gBAAgB,EAChB,KAAK,eAAe,EACpB,KAAK,gBAAgB,GACtB,MAAM,aAAa,CAAC;AACrB,OAAO,EACL,mBAAmB,GACpB,MAAM,SAAS,CAAC;AACjB,OAAO,EACL,qBAAqB,EACrB,KAAK,aAAa,GACnB,MAAM,cAAc,CAAC"}
@@ -0,0 +1,5 @@
1
+ export declare function generateThemeModule(layout: {
2
+ component: string | undefined;
3
+ slots: Record<string, string>;
4
+ } | undefined, projectRoot?: string): string;
5
+ //# sourceMappingURL=theme.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"theme.d.ts","sourceRoot":"","sources":["../../../../src/node/lib/codegen/theme.ts"],"names":[],"mappings":"AASA,wBAAgB,mBAAmB,CACjC,MAAM,EAAE;IACN,SAAS,EAAE,MAAM,GAAG,SAAS,CAAC;IAC9B,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CAC/B,GAAG,SAAS,EACb,WAAW,CAAC,EAAE,MAAM,GACnB,MAAM,CA4BR"}
@@ -1,2 +1,3 @@
1
1
  export declare function postprocessHtml(html: string): Promise<string>;
2
+ export declare function renderInlineTitleHtml(text: string): string;
2
3
  //# sourceMappingURL=postprocess.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"postprocess.d.ts","sourceRoot":"","sources":["../../../../src/node/lib/render/postprocess.ts"],"names":[],"mappings":"AAaA,wBAAsB,eAAe,CAAE,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAKpE"}
1
+ {"version":3,"file":"postprocess.d.ts","sourceRoot":"","sources":["../../../../src/node/lib/render/postprocess.ts"],"names":[],"mappings":"AAaA,wBAAsB,eAAe,CAAE,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAKpE;AAgHD,wBAAgB,qBAAqB,CAAE,IAAI,EAAE,MAAM,GAAG,MAAM,CAyB3D"}
@@ -1 +1 @@
1
- {"version":3,"file":"vue.d.ts","sourceRoot":"","sources":["../../../../src/node/lib/render/vue.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,eAAe,EAChB,MAAM,yBAAyB,CAAC;AACjC,OAAO,KAAK,EACV,eAAe,EAChB,MAAM,qBAAqB,CAAC;AAI7B,OAAO,KAAK,EAEV,QAAQ,EACT,MAAM,UAAU,CAAC;AAKlB,MAAM,WAAW,eAAe;IAC9B,kCAAkC;IAClC,MAAM,EAAE,MAAM,CAAC;IACf,oBAAoB;IACpB,QAAQ,EAAE,QAAQ,CAAC;CACpB;AAGD,wBAAsB,aAAa,CACjC,OAAO,EAAE,eAAe,EACxB,QAAQ,EAAE,eAAe,EACzB,QAAQ,EAAE,MAAM,GACf,OAAO,CAAC,QAAQ,CAAC,CAgBnB;AAGD,wBAAsB,cAAc,CAClC,OAAO,EAAE,eAAe,EACxB,QAAQ,EAAE,eAAe,EACzB,QAAQ,EAAE,MAAM,GACf,OAAO,CAAC,eAAe,CAAC,CAuB1B"}
1
+ {"version":3,"file":"vue.d.ts","sourceRoot":"","sources":["../../../../src/node/lib/render/vue.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,eAAe,EAChB,MAAM,yBAAyB,CAAC;AACjC,OAAO,KAAK,EACV,eAAe,EAChB,MAAM,qBAAqB,CAAC;AAI7B,OAAO,KAAK,EAEV,QAAQ,EACT,MAAM,UAAU,CAAC;AAKlB,MAAM,WAAW,eAAe;IAC9B,kCAAkC;IAClC,MAAM,EAAE,MAAM,CAAC;IACf,oBAAoB;IACpB,QAAQ,EAAE,QAAQ,CAAC;CACpB;AAGD,wBAAsB,aAAa,CACjC,OAAO,EAAE,eAAe,EACxB,QAAQ,EAAE,eAAe,EACzB,QAAQ,EAAE,MAAM,GACf,OAAO,CAAC,QAAQ,CAAC,CAkBnB;AAGD,wBAAsB,cAAc,CAClC,OAAO,EAAE,eAAe,EACxB,QAAQ,EAAE,eAAe,EACzB,QAAQ,EAAE,MAAM,GACf,OAAO,CAAC,eAAe,CAAC,CAuB1B"}
@@ -8,5 +8,7 @@ export declare const SITE_DATA_ID = "@typedown/site-data";
8
8
  export declare const RESOLVED_SITE_DATA_ID: string;
9
9
  export declare const SEARCH_INDEX_ID = "@typedown/search-index";
10
10
  export declare const RESOLVED_SEARCH_INDEX_ID: string;
11
+ export declare const THEME_ID = "@typedown/theme";
12
+ export declare const RESOLVED_THEME_ID: string;
11
13
  export declare const PAGE_DATA_EVENT = "typedown:page-data";
12
14
  //# sourceMappingURL=constants.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../src/node/plugin/vite/constants.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,cAAc,kBAAkB,CAAC;AAC9C,eAAO,MAAM,uBAAuB,QAAwB,CAAC;AAE7D,eAAO,MAAM,QAAQ,oBAAoB,CAAC;AAC1C,eAAO,MAAM,iBAAiB,QAAkB,CAAC;AACjD,eAAO,MAAM,gBAAgB,QAA0B,CAAC;AACxD,eAAO,MAAM,yBAAyB,QAA0B,CAAC;AAEjE,eAAO,MAAM,YAAY,wBAAwB,CAAC;AAClD,eAAO,MAAM,qBAAqB,QAAsB,CAAC;AAEzD,eAAO,MAAM,eAAe,2BAA2B,CAAC;AACxD,eAAO,MAAM,wBAAwB,QAAyB,CAAC;AAE/D,eAAO,MAAM,eAAe,uBAAuB,CAAC"}
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../src/node/plugin/vite/constants.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,cAAc,kBAAkB,CAAC;AAC9C,eAAO,MAAM,uBAAuB,QAAwB,CAAC;AAE7D,eAAO,MAAM,QAAQ,oBAAoB,CAAC;AAC1C,eAAO,MAAM,iBAAiB,QAAkB,CAAC;AACjD,eAAO,MAAM,gBAAgB,QAA0B,CAAC;AACxD,eAAO,MAAM,yBAAyB,QAA0B,CAAC;AAEjE,eAAO,MAAM,YAAY,wBAAwB,CAAC;AAClD,eAAO,MAAM,qBAAqB,QAAsB,CAAC;AAEzD,eAAO,MAAM,eAAe,2BAA2B,CAAC;AACxD,eAAO,MAAM,wBAAwB,QAAyB,CAAC;AAE/D,eAAO,MAAM,QAAQ,oBAAoB,CAAC;AAC1C,eAAO,MAAM,iBAAiB,QAAkB,CAAC;AAEjD,eAAO,MAAM,eAAe,uBAAuB,CAAC"}
@@ -1,6 +1,6 @@
1
1
  import { type Plugin } from 'vite';
2
2
  import { type AppContext } from '../../context';
3
- export { generate as generateClientAppEntry, type AppEntryOptions as ClientAppEntryOptions, } from './virtual/app';
3
+ export { THEME_ID, PAGES_ID, SITE_DATA_ID, SEARCH_INDEX_ID, PAGE_DATA_EVENT, } from './constants';
4
4
  export interface TypedownPluginCache {
5
5
  devHtml: string | undefined;
6
6
  basePath: string;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/node/plugin/vite/index.ts"],"names":[],"mappings":"AAMA,OAAO,EAEL,KAAK,MAAM,EACZ,MAAM,MAAM,CAAC;AAOd,OAAO,EACiC,KAAK,UAAU,EACtD,MAAM,eAAe,CAAC;AAiCvB,OAAO,EACL,QAAQ,IAAI,sBAAsB,EAClC,KAAK,eAAe,IAAI,qBAAqB,GAC9C,MAAM,eAAe,CAAC;AAEvB,MAAM,WAAW,mBAAmB;IAClC,OAAO,EAAE,MAAM,GAAG,SAAS,CAAC;IAC5B,QAAQ,EAAE,MAAM,CAAC;IACjB,aAAa,EAAE,MAAM,CAAC;CACvB;AAED,MAAM,WAAW,qBAAqB;IAEpC,OAAO,CAAC,EAAE,UAAU,CAAC;IACrB,wDAAwD;IACxD,IAAI,CAAC,EAAE,MAAM,CAAC;CACf;AAED,wBAAgB,QAAQ,CAAE,OAAO,GAAE,qBAA0B,GAAG,MAAM,EAAE,CA+TvE"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/node/plugin/vite/index.ts"],"names":[],"mappings":"AAMA,OAAO,EAEL,KAAK,MAAM,EACZ,MAAM,MAAM,CAAC;AAOd,OAAO,EACiC,KAAK,UAAU,EACtD,MAAM,eAAe,CAAC;AAoCvB,OAAO,EACL,QAAQ,EAAE,QAAQ,EAAE,YAAY,EAAE,eAAe,EAAE,eAAe,GACnE,MAAM,aAAa,CAAC;AAErB,MAAM,WAAW,mBAAmB;IAClC,OAAO,EAAE,MAAM,GAAG,SAAS,CAAC;IAC5B,QAAQ,EAAE,MAAM,CAAC;IACjB,aAAa,EAAE,MAAM,CAAC;CACvB;AAED,MAAM,WAAW,qBAAqB;IAEpC,OAAO,CAAC,EAAE,UAAU,CAAC;IACrB,wDAAwD;IACxD,IAAI,CAAC,EAAE,MAAM,CAAC;CACf;AAED,wBAAgB,QAAQ,CAAE,OAAO,GAAE,qBAA0B,GAAG,MAAM,EAAE,CA2UvE"}
@@ -1,25 +1,7 @@
1
1
  import type { ViteDevServer } from 'vite';
2
- import { type VirtualModule } from './utils';
3
- import type { TypedownContext } from '@/node/lib/typedown-context';
4
- export interface AppEntryOptions {
5
- rootDir?: string;
6
- basePath?: string;
7
- origin?: string;
8
- lang?: string;
9
- siteTitle: string;
10
- siteDescription: string;
11
- repo?: string;
12
- author?: string;
13
- license?: string;
14
- nav?: {
15
- title: string;
16
- link: string;
17
- icon?: string;
18
- }[];
19
- }
20
- export declare class VirtualApp implements VirtualModule {
21
- load(context: TypedownContext): Promise<string>;
2
+ import type { AppContext } from '@/node/context';
3
+ export declare class VirtualApp {
4
+ load(context: AppContext): Promise<string>;
22
5
  invalidate(server: ViteDevServer): void;
23
6
  }
24
- export declare function generate(options: AppEntryOptions): string;
25
7
  //# sourceMappingURL=app.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"app.d.ts","sourceRoot":"","sources":["../../../../../src/node/plugin/vite/virtual/app.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,aAAa,EACd,MAAM,MAAM,CAAC;AAQd,OAAO,EAEL,KAAK,aAAa,EACnB,MAAM,SAAS,CAAC;AACjB,OAAO,KAAK,EACV,eAAe,EAChB,MAAM,6BAA6B,CAAC;AAKrC,MAAM,WAAW,eAAe;IAC9B,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,SAAS,EAAE,MAAM,CAAC;IAClB,eAAe,EAAE,MAAM,CAAC;IACxB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,GAAG,CAAC,EAAE;QACJ,KAAK,EAAE,MAAM,CAAC;QACd,IAAI,EAAE,MAAM,CAAC;QACb,IAAI,CAAC,EAAE,MAAM,CAAC;KACf,EAAE,CAAC;CACL;AAED,qBAAa,UAAW,YAAW,aAAa;IACxC,IAAI,CAAE,OAAO,EAAE,eAAe,GAAG,OAAO,CAAC,MAAM,CAAC;IAStD,UAAU,CAAE,MAAM,EAAE,aAAa,GAAG,IAAI;CAGzC;AAGD,wBAAgB,QAAQ,CAAE,OAAO,EAAE,eAAe,GAAG,MAAM,CA2F1D"}
1
+ {"version":3,"file":"app.d.ts","sourceRoot":"","sources":["../../../../../src/node/plugin/vite/virtual/app.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,aAAa,EACd,MAAM,MAAM,CAAC;AAYd,OAAO,KAAK,EACV,UAAU,EACX,MAAM,gBAAgB,CAAC;AAKxB,qBAAa,UAAU;IACf,IAAI,CAAE,OAAO,EAAE,UAAU,GAAG,OAAO,CAAC,MAAM,CAAC;IA0BjD,UAAU,CAAE,MAAM,EAAE,aAAa,GAAG,IAAI;CAGzC"}
@@ -0,0 +1,7 @@
1
+ import type { ViteDevServer } from 'vite';
2
+ import type { AppContext } from '@/node/context';
3
+ export declare class VirtualTheme {
4
+ load(context: AppContext): Promise<string>;
5
+ invalidate(server: ViteDevServer): void;
6
+ }
7
+ //# sourceMappingURL=theme.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"theme.d.ts","sourceRoot":"","sources":["../../../../../src/node/plugin/vite/virtual/theme.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,aAAa,EACd,MAAM,MAAM,CAAC;AAOd,OAAO,KAAK,EACV,UAAU,EACX,MAAM,gBAAgB,CAAC;AAKxB,qBAAa,YAAY;IACjB,IAAI,CAAE,OAAO,EAAE,UAAU,GAAG,OAAO,CAAC,MAAM,CAAC;IAUjD,UAAU,CAAE,MAAM,EAAE,aAAa,GAAG,IAAI;CAGzC"}
@@ -1,5 +1,5 @@
1
- import { P as e } from "./shared-BMujDY3P.js";
2
- import { a as t, i as n, n as r, o as i, r as a, s as o, t as s } from "./jsonld-Du1iJ_fG.js";
1
+ import { P as e } from "./shared-QuBFygxT.js";
2
+ import { a as t, i as n, n as r, o as i, r as a, s as o, t as s } from "./jsonld-Crj_9xpa.js";
3
3
  import { pathToFileURL as c } from "node:url";
4
4
  import { parentPort as l, workerData as u } from "node:worker_threads";
5
5
  //#region src/node/build/prerenderWorker.ts
@@ -0,0 +1,19 @@
1
+ import { c as e } from "./shared-QuBFygxT.js";
2
+ import { t } from "./temml-D47Z4xZ2.js";
3
+ import { t as n } from "./inlineRe-Cn-J_E76.js";
4
+ //#region src/client/theme-default/utils/renderMath.ts
5
+ function r(r) {
6
+ let i = 0, a = "";
7
+ for (let o of r.matchAll(n)) {
8
+ if (a += e(r.slice(i, o.index)), o[1] !== void 0) a += `<code>${e(o[1])}</code>`;
9
+ else if (o[2] !== void 0) try {
10
+ a += t.renderToString(o[2], { throwOnError: !1 });
11
+ } catch {
12
+ a += e(o[0]);
13
+ }
14
+ i = o.index + o[0].length;
15
+ }
16
+ return a += e(r.slice(i)), a;
17
+ }
18
+ //#endregion
19
+ export { r as renderInlineMarkup };
@@ -21,6 +21,10 @@ export interface PageData {
21
21
  frontmatter: Record<string, unknown>;
22
22
  headings: MarkdownHeading[];
23
23
  title: string;
24
+ /** HTML-rendered title with inline code/math; safe for v-html */
25
+ titleHtml: string;
26
+ /** Path of the source file relative to the vault root (e.g. "people/alice.td") */
27
+ filepath: string;
24
28
  fileMetadata?: FileMetadata;
25
29
  seoMetadata?: SeoMeta;
26
30
  }
@@ -1 +1 @@
1
- {"version":3,"file":"ssg.d.ts","sourceRoot":"","sources":["../../../src/shared/types/ssg.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,SAAS,EAAE,GAAG,EACf,MAAM,KAAK,CAAC;AACb,OAAO,KAAK,EACV,WAAW,EAAE,YAAY,EAC1B,MAAM,WAAW,CAAC;AAEnB,MAAM,WAAW,eAAe;IAC9B,0BAA0B;IAC1B,KAAK,EAAE,MAAM,CAAC;IACd,kDAAkD;IAClD,KAAK,EAAE,MAAM,CAAC;IACd,+DAA+D;IAC/D,SAAS,EAAE,MAAM,CAAC;IAClB,uCAAuC;IACvC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ACnB,sBAAsB;IACtB,MAAM,EAAE,GAAG,CAAC,OAAO,CAAC,CAAC;CACtB"}
@@ -1,6 +1,8 @@
1
+ export declare function kebabToPascal(string_: string): string;
1
2
  export declare function parseNumericPrefix(name: string): {
2
3
  order: number;
3
4
  rest: string;
4
5
  };
6
+ export declare function snakeToKebab(string_: string): string;
5
7
  export declare function unslugify(slug: string): string;
6
8
  //# sourceMappingURL=format.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"format.d.ts","sourceRoot":"","sources":["../../../src/shared/utils/format.ts"],"names":[],"mappings":"AAGA,wBAAgB,kBAAkB,CAAE,IAAI,EAAE,MAAM,GAAG;IACjD,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;CACd,CAYA;AAID,wBAAgB,SAAS,CAAE,IAAI,EAAE,MAAM,GAAG,MAAM,CAW/C"}
1
+ {"version":3,"file":"format.d.ts","sourceRoot":"","sources":["../../../src/shared/utils/format.ts"],"names":[],"mappings":"AAEA,wBAAgB,aAAa,CAAE,OAAO,EAAE,MAAM,GAAG,MAAM,CAEtD;AAKD,wBAAgB,kBAAkB,CAAE,IAAI,EAAE,MAAM,GAAG;IACjD,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;CACd,CAYA;AAID,wBAAgB,YAAY,CAAE,OAAO,EAAE,MAAM,GAAG,MAAM,CAErD;AAID,wBAAgB,SAAS,CAAE,IAAI,EAAE,MAAM,GAAG,MAAM,CAW/C"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=format.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"format.test.d.ts","sourceRoot":"","sources":["../../../src/shared/utils/format.test.ts"],"names":[],"mappings":""}