From 0f1cc8bca1b22419b03170b55c0d19d59617407d Mon Sep 17 00:00:00 2001 From: John MacFarlane Date: Tue, 20 Jan 2026 10:41:15 +0100 Subject: Wasm: Format-specific options, line endings. --- wasm/index.html | 96 +++++++++++++++++++++++++++++---------------------------- 1 file changed, 49 insertions(+), 47 deletions(-) diff --git a/wasm/index.html b/wasm/index.html index 4e4244eff..5e4ddf5a0 100644 --- a/wasm/index.html +++ b/wasm/index.html @@ -755,7 +755,6 @@ - @@ -823,16 +822,20 @@ +
+ + +
-
- - -
@@ -982,6 +985,15 @@
+ +
+
+
+ + +
+
+
@@ -1140,36 +1152,35 @@
-
- - -
-
-
- - - - -
-
- - - -
-
- 🔠 - {{ file.name }} - + +
+
+
+ + + + +
+
+ + + +
+
+ 🔠 + {{ file.name }} + +
-
-
- - -
-
- - +
+ + +
+
+ + +
@@ -1444,6 +1455,7 @@ shiftHeading: '0', preserveTabs: false, tabStop: '4', + eol: '', stripComments: false, trackChanges: '', citationMethod: '', @@ -1636,28 +1648,17 @@ get showFormatTab() { const fmt = this.effectiveOutputFormat; - return this.isHtmlFormat || this.isMarkdownFormat || fmt === 'rst' || + return this.showStripComments || this.isHtmlFormat || this.isMarkdownFormat || fmt === 'rst' || ['latex', 'beamer'].includes(fmt) || ['typst', 'pdf-typst'].includes(fmt) || this.supportsCaptionPosition || this.supportsAscii || this.supportsTopLevelDivision || this.supportsListOf || this.docFormats.includes(fmt); }, get formatTabName() { - const fmt = this.effectiveOutputFormat; - if (this.isHtmlFormat) return 'HTML'; - if (this.isMarkdownFormat) return 'Markdown'; - if (fmt === 'rst') return 'RST'; - if (fmt === 'latex') return 'LaTeX'; - if (fmt === 'beamer') return 'Beamer'; - if (['typst', 'pdf-typst'].includes(fmt)) return 'Typst'; - if (fmt === 'context') return 'ConTeXt'; - if (fmt === 'tei') return 'TEI'; - if (fmt.startsWith('docbook')) return 'DocBook'; - if (this.docFormats.includes(fmt)) return fmt.toUpperCase(); - return fmt; + return 'Format-Specific'; }, - get showEpubTab() { return ['epub', 'epub2', 'epub3'].includes(this.effectiveOutputFormat); }, + get isEpubFormat() { return ['epub', 'epub2', 'epub3'].includes(this.effectiveOutputFormat); }, get showChunkedTab() { return this.effectiveOutputFormat === 'chunkedhtml'; }, get showIpynbTab() { return this.effectiveOutputFormat === 'ipynb'; }, get showSlidesTab() { return this.slideFormats.includes(this.effectiveOutputFormat); }, @@ -2255,6 +2256,7 @@ if (this.opts.preserveTabs) opts['preserve-tabs'] = true; const tabStop = parseInt(this.opts.tabStop); if (tabStop !== 4) opts['tab-stop'] = tabStop; + if (this.opts.eol) opts.eol = this.opts.eol; if (this.opts.stripComments) opts['strip-comments'] = true; // Track changes -- cgit v1.2.3