@pretextbook/pretext-html 0.9.0 → 0.10.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/assets/upstream.json +1 -1
- package/dist/{cli-BUrNZxov.js → cli-C3B-AvUy.js} +129 -128
- package/dist/cli.js +1 -1
- package/dist/html-static.d.ts +1 -1
- package/dist/index.browser.d.ts +4 -0
- package/dist/index.browser.js +367 -362
- package/dist/index.js +1 -1
- package/dist/renderer.d.ts +18 -0
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { O as r, P as i, b as a, d as t, a as n, c as o, f as l, e as d, i as p, g as E, o as c, p as m, r as v, h as S, j as g, m as A, s as f, k as B, x as P } from "./cli-
|
|
1
|
+
import { O as r, P as i, b as a, d as t, a as n, c as o, f as l, e as d, i as p, g as E, o as c, p as m, r as v, h as S, j as g, m as A, s as f, k as B, x as P } from "./cli-C3B-AvUy.js";
|
|
2
2
|
import { injectRevealBridge as R, isRevealView as h, revealBridgeScript as _ } from "./reveal.js";
|
|
3
3
|
import { describeAsset as u, missingAssetPlaceholder as x, missingAssetSvg as M, rewriteAssetUrls as T } from "./assets.js";
|
|
4
4
|
import { PREVIEW_THEME_MESSAGE as G, injectThemeBridge as k, isPreviewTheme as H, previewThemeMessage as L, themeBridgeScript as O } from "./theme.js";
|
package/dist/renderer.d.ts
CHANGED
|
@@ -157,8 +157,26 @@ export interface RenderOptions {
|
|
|
157
157
|
*
|
|
158
158
|
* Supersedes `docinfoSourcePath`, since the skeleton carries the document's
|
|
159
159
|
* real `<docinfo>`. Only used in fragment mode; ignored for whole documents.
|
|
160
|
+
* Optional when `contextSourceContent` is given — see there — but still
|
|
161
|
+
* used as the virtual base for xi:include resolution and source-map paths
|
|
162
|
+
* even then, so pass it whenever a real path is available.
|
|
160
163
|
*/
|
|
161
164
|
contextSourcePath?: string;
|
|
165
|
+
/**
|
|
166
|
+
* The complete document's source text, used instead of reading
|
|
167
|
+
* `contextSourcePath` from disk. Lets a browser host that already holds the
|
|
168
|
+
* whole project in memory place a fragment in its document — with
|
|
169
|
+
* correct numbering and resolved `<xref>`s — without a filesystem or
|
|
170
|
+
* network round trip, and lets the skeleton see *unsaved* sibling
|
|
171
|
+
* divisions that a read from disk never would.
|
|
172
|
+
*
|
|
173
|
+
* `contextSourcePath` becomes optional when this is given, defaulting to
|
|
174
|
+
* `sourcePath` as the virtual base for resolving the document's own
|
|
175
|
+
* xi:includes; pass `contextSourcePath` too when a real one is available,
|
|
176
|
+
* for more useful source-map/error paths. Exactly parallel to
|
|
177
|
+
* `sourceContent` vs. `sourcePath`.
|
|
178
|
+
*/
|
|
179
|
+
contextSourceContent?: string;
|
|
162
180
|
/**
|
|
163
181
|
* Tooltip for links whose target is not on the previewed page — the table of
|
|
164
182
|
* contents, and cross-references reaching outside the fragment. Those cannot
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pretextbook/pretext-html",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.10.1",
|
|
4
4
|
"description": "Convert PreTeXt documents to HTML in pure JavaScript using the official PreTeXt XSLT stylesheets via libxslt-wasm. No Python or PreTeXt installation required.",
|
|
5
5
|
"author": "Oscar Levin",
|
|
6
6
|
"license": "MIT",
|