@pretextbook/pretext-html 0.8.0 → 0.9.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.
- package/assets/preview-html.xsl +16 -0
- package/assets/upstream.json +1 -1
- package/assets/xsl/extract-dynamic.xsl +54 -3
- package/assets/xsl/extract-gdscript.xsl +61 -0
- package/assets/xsl/extract-sageplot.xsl +3 -0
- package/assets/xsl/localizations/it-IT.xml +37 -41
- package/assets/xsl/pretext-assembly.xsl +188 -24
- package/assets/xsl/pretext-beamer.xsl +57 -12
- package/assets/xsl/pretext-common.xsl +156 -28
- package/assets/xsl/pretext-epub.xsl +0 -5
- package/assets/xsl/pretext-fo.xsl +110 -48
- package/assets/xsl/pretext-html.xsl +147 -54
- package/assets/xsl/pretext-jupyter.xsl +1 -0
- package/assets/xsl/pretext-latex-classic.xsl +2 -2
- package/assets/xsl/pretext-latex-common.xsl +268 -134
- package/assets/xsl/pretext-latex.xsl +16 -6
- package/assets/xsl/pretext-numbers.xsl +10 -0
- package/assets/xsl/pretext-revealjs.xsl +68 -1
- package/assets/xsl/pretext-runestone-fitb.xsl +179 -84
- package/assets/xsl/pretext-runestone-static.xsl +72 -20
- package/assets/xsl/pretext-runestone.xsl +27 -4
- package/assets/xsl/pretext-text-utilities.xsl +7 -0
- package/assets/xsl/pretext-text.xsl +17 -0
- package/assets/xsl/publisher-variables.xsl +39 -0
- package/assets/xsl-bundle.json +1 -1
- package/dist/cli-BUrNZxov.js +1098 -0
- package/dist/cli.js +1 -1
- package/dist/html-static.d.ts +2 -2
- package/dist/index.browser.js +595 -386
- package/dist/index.d.ts +4 -0
- package/dist/index.js +35 -30
- package/dist/renderer.d.ts +35 -0
- package/dist/skeleton.d.ts +41 -0
- package/dist/xrefs.d.ts +54 -0
- package/package.json +1 -1
- package/dist/cli-Bcn4t3B1.js +0 -871
|
@@ -224,6 +224,7 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
|
|
|
224
224
|
<xsl:variable name="b-has-myopenmath" select="boolean($document-root//myopenmath)"/>
|
|
225
225
|
<xsl:variable name="b-has-stack" select="boolean($document-root//exercise/stack)"/>
|
|
226
226
|
<xsl:variable name="b-has-program" select="boolean($document-root//program)"/>
|
|
227
|
+
<xsl:variable name="b-has-gdscript" select="boolean($document-root//program[@language='gdscript'])"/>
|
|
227
228
|
<xsl:variable name="b-has-sage" select="boolean($document-root//sage)"/>
|
|
228
229
|
<xsl:variable name="b-has-sfrac" select="boolean($document-root//m[contains(text(),'sfrac')] or $document-root//mrow[contains(text(),'sfrac')])" />
|
|
229
230
|
<xsl:variable name="b-has-geogebra" select="boolean($document-root//interactive[@platform='geogebra'])"/>
|
|
@@ -249,17 +250,6 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
|
|
|
249
250
|
<xsl:variable name="b-needs-custom-marker-css" select="boolean(exsl:node-set($ol-markers)/ol-markers/ol-marker)"/>
|
|
250
251
|
|
|
251
252
|
|
|
252
|
-
<!-- ######## -->
|
|
253
|
-
<!-- WeBWorK -->
|
|
254
|
-
<!-- ######## -->
|
|
255
|
-
|
|
256
|
-
<!-- We mine some values from the first "WW representation" to have been -->
|
|
257
|
-
<!-- inserted into the source by the pre-processor ("assembly") when -->
|
|
258
|
-
<!-- making dynamic exercises. -->
|
|
259
|
-
|
|
260
|
-
<xsl:variable name="webwork-major-version" select="$document-root//webwork-reps[1]/@webwork2_major_version"/>
|
|
261
|
-
<xsl:variable name="webwork-minor-version" select="$document-root//webwork-reps[1]/@webwork2_minor_version"/>
|
|
262
|
-
|
|
263
253
|
<!-- #### EXPERIMENTAL #### -->
|
|
264
254
|
<!-- We allow for the HTML conversion to chunk output, starting -->
|
|
265
255
|
<!-- from an arbitrary node. $subtree-node needs context. -->
|
|
@@ -562,6 +552,7 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
|
|
|
562
552
|
<xsl:if test="not($num = '')">
|
|
563
553
|
<span class="codenumber">
|
|
564
554
|
<xsl:value-of select="$num" />
|
|
555
|
+
<xsl:apply-templates select="." mode="division-number-separator"/>
|
|
565
556
|
</span>
|
|
566
557
|
<xsl:text> </xsl:text>
|
|
567
558
|
</xsl:if>
|
|
@@ -983,6 +974,7 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
|
|
|
983
974
|
<xsl:call-template name="space-styled"/>
|
|
984
975
|
<span class="codenumber">
|
|
985
976
|
<xsl:apply-templates select="." mode="number" />
|
|
977
|
+
<xsl:apply-templates select="." mode="division-number-separator"/>
|
|
986
978
|
</span>
|
|
987
979
|
<xsl:call-template name="space-styled"/>
|
|
988
980
|
<span class="title">
|
|
@@ -1176,6 +1168,12 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
|
|
|
1176
1168
|
</xsl:template>
|
|
1177
1169
|
|
|
1178
1170
|
<xsl:template match="affiliation">
|
|
1171
|
+
<xsl:if test="position">
|
|
1172
|
+
<xsl:apply-templates select="position" />
|
|
1173
|
+
<xsl:if test="position/following-sibling::*">
|
|
1174
|
+
<br />
|
|
1175
|
+
</xsl:if>
|
|
1176
|
+
</xsl:if>
|
|
1179
1177
|
<xsl:if test="department">
|
|
1180
1178
|
<xsl:apply-templates select="department" />
|
|
1181
1179
|
<xsl:if test="department/following-sibling::*">
|
|
@@ -1197,11 +1195,11 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
|
|
|
1197
1195
|
</xsl:template>
|
|
1198
1196
|
|
|
1199
1197
|
<!-- Departments and Institutions are free-form, or sequences of lines -->
|
|
1200
|
-
<xsl:template match="department|institution|location">
|
|
1198
|
+
<xsl:template match="position|department|institution|location">
|
|
1201
1199
|
<xsl:apply-templates/>
|
|
1202
1200
|
</xsl:template>
|
|
1203
1201
|
|
|
1204
|
-
<xsl:template match="department[line]|institution[line]|location[line]">
|
|
1202
|
+
<xsl:template match="position[line]|department[line]|institution[line]|location[line]">
|
|
1205
1203
|
<xsl:apply-templates select="line" />
|
|
1206
1204
|
</xsl:template>
|
|
1207
1205
|
|
|
@@ -1216,10 +1214,11 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
|
|
|
1216
1214
|
</div>
|
|
1217
1215
|
</xsl:template>
|
|
1218
1216
|
|
|
1219
|
-
<!-- General support (not for a particular author) -->
|
|
1217
|
+
<!-- General support (not for a particular author). The schema -->
|
|
1218
|
+
<!-- says a "support" statement is text-level, mixed content -->
|
|
1220
1219
|
<xsl:template match="bibinfo/support">
|
|
1221
1220
|
<div class="support">
|
|
1222
|
-
<xsl:apply-templates select="
|
|
1221
|
+
<xsl:apply-templates select="node()"/>
|
|
1223
1222
|
</div>
|
|
1224
1223
|
</xsl:template>
|
|
1225
1224
|
|
|
@@ -1752,11 +1751,25 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
|
|
|
1752
1751
|
<!-- https://stackoverflow.com/questions/538293/find-common-parent-using-xpath -->
|
|
1753
1752
|
<xsl:variable name="nearest-common-ancestor"
|
|
1754
1753
|
select="./ancestor::*[count(. | $link/ancestor::*) = count($link/ancestor::*)] [1]"/>
|
|
1755
|
-
<xsl:
|
|
1756
|
-
|
|
1757
|
-
|
|
1758
|
-
|
|
1759
|
-
|
|
1754
|
+
<xsl:choose>
|
|
1755
|
+
<!-- A division's "introduction" or "conclusion" renders on -->
|
|
1756
|
+
<!-- its division's page, whole, whatever the chunk level. -->
|
|
1757
|
+
<!-- So a link and target together inside one companion are -->
|
|
1758
|
+
<!-- always on one page, though the companion's level would -->
|
|
1759
|
+
<!-- say otherwise. Deliberately a containment test, not -->
|
|
1760
|
+
<!-- level arithmetic: the levels of these companions are -->
|
|
1761
|
+
<!-- slated for rework. -->
|
|
1762
|
+
<xsl:when test="$nearest-common-ancestor/ancestor-or-self::introduction[parent::*[&STRUCTURAL-FILTER;]] or $nearest-common-ancestor/ancestor-or-self::conclusion[parent::*[&STRUCTURAL-FILTER;]]">
|
|
1763
|
+
<xsl:value-of select="false()"/>
|
|
1764
|
+
</xsl:when>
|
|
1765
|
+
<xsl:otherwise>
|
|
1766
|
+
<xsl:variable name="nearest-ancestor-level">
|
|
1767
|
+
<xsl:apply-templates select="$nearest-common-ancestor" mode="enclosing-level"/>
|
|
1768
|
+
</xsl:variable>
|
|
1769
|
+
<!-- remove not(), replace operator with <, then radically different behavior -->
|
|
1770
|
+
<xsl:value-of select="not($nearest-ancestor-level >= $chunk-level)"/>
|
|
1771
|
+
</xsl:otherwise>
|
|
1772
|
+
</xsl:choose>
|
|
1760
1773
|
</xsl:otherwise>
|
|
1761
1774
|
</xsl:choose>
|
|
1762
1775
|
</xsl:template>
|
|
@@ -2746,6 +2759,35 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
|
|
|
2746
2759
|
<!-- Footnotes -->
|
|
2747
2760
|
<!-- ######### -->
|
|
2748
2761
|
|
|
2762
|
+
<!-- A table note ("tn") drops only its superscript letter mark at the -->
|
|
2763
|
+
<!-- cell location, linked to the note text collected below the table -->
|
|
2764
|
+
<!-- in the "tabular-inclusion" template. Letters count per-tabular -->
|
|
2765
|
+
<!-- in document order (Notes to tables: CMoS 18th ed., 3.77-3.81; -->
|
|
2766
|
+
<!-- specific notes at 3.80). Adjacency is the presentation: a note -->
|
|
2767
|
+
<!-- sits just below its table, so there is no knowl. -->
|
|
2768
|
+
<xsl:template match="tabular//tn">
|
|
2769
|
+
<xsl:variable name="note-number">
|
|
2770
|
+
<xsl:apply-templates select="." mode="number"/>
|
|
2771
|
+
</xsl:variable>
|
|
2772
|
+
<sup class="tablenote-mark">
|
|
2773
|
+
<xsl:apply-templates select="." mode="html-id-attribute"/>
|
|
2774
|
+
<a>
|
|
2775
|
+
<xsl:attribute name="href">
|
|
2776
|
+
<xsl:text>#</xsl:text>
|
|
2777
|
+
<xsl:apply-templates select="." mode="html-id"/>
|
|
2778
|
+
<xsl:text>-note</xsl:text>
|
|
2779
|
+
</xsl:attribute>
|
|
2780
|
+
<xsl:attribute name="aria-label">
|
|
2781
|
+
<xsl:text>Go to table note </xsl:text>
|
|
2782
|
+
<xsl:value-of select="$note-number"/>
|
|
2783
|
+
</xsl:attribute>
|
|
2784
|
+
<i>
|
|
2785
|
+
<xsl:value-of select="$note-number"/>
|
|
2786
|
+
</i>
|
|
2787
|
+
</a>
|
|
2788
|
+
</sup>
|
|
2789
|
+
</xsl:template>
|
|
2790
|
+
|
|
2749
2791
|
<!-- Currently implemented as a details html element with no guardrails -->
|
|
2750
2792
|
<!-- on nested content. Other footnotes, block content, etc... will all -->
|
|
2751
2793
|
<!-- be rendered, but perhaps not well. Caveat emptor. -->
|
|
@@ -6072,10 +6114,11 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
|
|
|
6072
6114
|
</xsl:element>
|
|
6073
6115
|
</xsl:template>
|
|
6074
6116
|
|
|
6075
|
-
<!-- A "headnote" prefaces the
|
|
6076
|
-
<!--
|
|
6077
|
-
<!--
|
|
6078
|
-
|
|
6117
|
+
<!-- A "headnote" prefaces the list of a list-like division: a -->
|
|
6118
|
+
<!-- "glossary", a "references", an "index", an "appendix" -->
|
|
6119
|
+
<!-- that is a notation list. Below is modeled on block -->
|
|
6120
|
+
<!-- introductions (just above), but with no "title". -->
|
|
6121
|
+
<xsl:template match="glossary/headnote|references/headnote|index/headnote|appendix/headnote">
|
|
6079
6122
|
<xsl:param name="b-original" select="true()" />
|
|
6080
6123
|
<section class="headnote">
|
|
6081
6124
|
<xsl:if test="$b-original">
|
|
@@ -8141,6 +8184,44 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
|
|
|
8141
8184
|
<xsl:with-param name="ambient-relative-width" select="$width" />
|
|
8142
8185
|
</xsl:apply-templates>
|
|
8143
8186
|
</table>
|
|
8187
|
+
<!-- Table notes ("tn") collect just below the table, lettered in -->
|
|
8188
|
+
<!-- reading order, which is document order of the marks (Notes -->
|
|
8189
|
+
<!-- to tables: CMoS 18th ed., 3.77-3.81; specific notes at -->
|
|
8190
|
+
<!-- 3.80). Disjoint from true footnote numbering. -->
|
|
8191
|
+
<xsl:if test=".//tn">
|
|
8192
|
+
<!-- each note is a list item (not a "p"): one tight -->
|
|
8193
|
+
<!-- line per note, free of paragraph margins -->
|
|
8194
|
+
<ol class="tablenotes" aria-label="Table notes">
|
|
8195
|
+
<xsl:for-each select=".//tn">
|
|
8196
|
+
<xsl:variable name="note-number">
|
|
8197
|
+
<xsl:apply-templates select="." mode="number"/>
|
|
8198
|
+
</xsl:variable>
|
|
8199
|
+
<li class="tablenote">
|
|
8200
|
+
<xsl:attribute name="id">
|
|
8201
|
+
<xsl:apply-templates select="." mode="html-id"/>
|
|
8202
|
+
<xsl:text>-note</xsl:text>
|
|
8203
|
+
</xsl:attribute>
|
|
8204
|
+
<sup>
|
|
8205
|
+
<a>
|
|
8206
|
+
<xsl:attribute name="href">
|
|
8207
|
+
<xsl:text>#</xsl:text>
|
|
8208
|
+
<xsl:apply-templates select="." mode="html-id"/>
|
|
8209
|
+
</xsl:attribute>
|
|
8210
|
+
<xsl:attribute name="aria-label">
|
|
8211
|
+
<xsl:text>Back to table note reference </xsl:text>
|
|
8212
|
+
<xsl:value-of select="$note-number"/>
|
|
8213
|
+
</xsl:attribute>
|
|
8214
|
+
<i>
|
|
8215
|
+
<xsl:value-of select="$note-number"/>
|
|
8216
|
+
</i>
|
|
8217
|
+
</a>
|
|
8218
|
+
</sup>
|
|
8219
|
+
<xsl:text> </xsl:text>
|
|
8220
|
+
<xsl:apply-templates/>
|
|
8221
|
+
</li>
|
|
8222
|
+
</xsl:for-each>
|
|
8223
|
+
</ol>
|
|
8224
|
+
</xsl:if>
|
|
8144
8225
|
</xsl:template>
|
|
8145
8226
|
|
|
8146
8227
|
<!-- A row of table -->
|
|
@@ -9069,8 +9150,13 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
|
|
|
9069
9150
|
</code>
|
|
9070
9151
|
</xsl:template>
|
|
9071
9152
|
|
|
9153
|
+
<!-- A copy button serves a block of code; within a "tabular" -->
|
|
9154
|
+
<!-- cell the content is short and the floating button crowds -->
|
|
9155
|
+
<!-- the cell, so there we decline to provide one. -->
|
|
9072
9156
|
<xsl:template name="insert-clipboardable-class">
|
|
9073
|
-
<xsl:
|
|
9157
|
+
<xsl:if test="not(ancestor::tabular)">
|
|
9158
|
+
<xsl:text> clipboardable</xsl:text>
|
|
9159
|
+
</xsl:if>
|
|
9074
9160
|
</xsl:template>
|
|
9075
9161
|
|
|
9076
9162
|
<!-- 100% analogue of LaTeX's verbatim -->
|
|
@@ -10372,30 +10458,30 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
|
|
|
10372
10458
|
</xsl:template>
|
|
10373
10459
|
|
|
10374
10460
|
<!-- HTML Code -->
|
|
10375
|
-
<!-- Simply create deep-copy of HTML elements -->
|
|
10376
10461
|
<!-- TODO: should this be a div, with width and height? -->
|
|
10377
|
-
<!-- Authored HTML goes into the page
|
|
10378
|
-
<!--
|
|
10379
|
-
<!--
|
|
10380
|
-
<!--
|
|
10381
|
-
<!--
|
|
10382
|
-
<!--
|
|
10383
|
-
<!--
|
|
10462
|
+
<!-- Authored HTML goes into the page, which is the content's -->
|
|
10463
|
+
<!-- only destination, and an HTML parser has no notion of -->
|
|
10464
|
+
<!-- namespaces. So the copy keeps just the local name of each -->
|
|
10465
|
+
<!-- element: an author declares the XHTML namespace once (say, -->
|
|
10466
|
+
<!-- a prefix on the "slate") to satisfy validation, and the -->
|
|
10467
|
+
<!-- output carries plain HTML tags with no declarations at -->
|
|
10468
|
+
<!-- all. (This utility may serve other embedded-markup -->
|
|
10469
|
+
<!-- copying; nothing about it is specific to a "slate".) -->
|
|
10384
10470
|
<xsl:template match="slate[@surface = 'html']">
|
|
10385
|
-
<xsl:apply-templates select="*" mode="copy-authored-
|
|
10471
|
+
<xsl:apply-templates select="*" mode="copy-authored-xml"/>
|
|
10386
10472
|
</xsl:template>
|
|
10387
10473
|
|
|
10388
10474
|
<!-- Attributes in the internal namespace are the assembly's -->
|
|
10389
10475
|
<!-- identification stamps, not the author's work, so they stay -->
|
|
10390
10476
|
<!-- out of the copy. -->
|
|
10391
|
-
<xsl:template match="*" mode="copy-authored-
|
|
10392
|
-
<xsl:element name="{name()}"
|
|
10477
|
+
<xsl:template match="*" mode="copy-authored-xml">
|
|
10478
|
+
<xsl:element name="{local-name()}">
|
|
10393
10479
|
<xsl:copy-of select="@*[namespace-uri(.) != 'http://pretextbook.org/2020/pretext/internal']"/>
|
|
10394
|
-
<xsl:apply-templates select="node()" mode="copy-authored-
|
|
10480
|
+
<xsl:apply-templates select="node()" mode="copy-authored-xml"/>
|
|
10395
10481
|
</xsl:element>
|
|
10396
10482
|
</xsl:template>
|
|
10397
10483
|
|
|
10398
|
-
<xsl:template match="text()|comment()|processing-instruction()" mode="copy-authored-
|
|
10484
|
+
<xsl:template match="text()|comment()|processing-instruction()" mode="copy-authored-xml">
|
|
10399
10485
|
<xsl:copy/>
|
|
10400
10486
|
</xsl:template>
|
|
10401
10487
|
|
|
@@ -11097,7 +11183,7 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
|
|
|
11097
11183
|
<!-- WeBWorK Javascript header -->
|
|
11098
11184
|
<xsl:template name="webwork-js">
|
|
11099
11185
|
<xsl:if test="$b-has-webwork-reps">
|
|
11100
|
-
<script src="{$html.js.dir}/pretext-webwork
|
|
11186
|
+
<script src="{$html.js.dir}/pretext-webwork.js"></script>
|
|
11101
11187
|
<script src="{$webwork-server}/webwork2_files/node_modules/iframe-resizer/js/iframeResizer.min.js"></script>
|
|
11102
11188
|
</xsl:if>
|
|
11103
11189
|
</xsl:template>
|
|
@@ -11168,19 +11254,22 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
|
|
|
11168
11254
|
<xsl:param name="b-has-answer"/>
|
|
11169
11255
|
<xsl:param name="b-has-solution"/>
|
|
11170
11256
|
|
|
11171
|
-
<!-- For Runestone, the WW problem is handled in isolation,
|
|
11172
|
-
<!-- yet capturing and storing student work/results needs
|
|
11173
|
-
<!-- to be associated with the parent/enclosing "exercise"
|
|
11174
|
-
<!-- (or PROJECT-LIKE). So in this case (only) we place
|
|
11175
|
-
<!-- an id value on the div.exercise-wrapper that is
|
|
11176
|
-
<!-- derived from the parent. Otherwise, we use the
|
|
11177
|
-
<!--
|
|
11178
|
-
<!--
|
|
11179
|
-
<!--
|
|
11180
|
-
<!--
|
|
11181
|
-
<!--
|
|
11182
|
-
<!--
|
|
11183
|
-
<!--
|
|
11257
|
+
<!-- For Runestone, the WW problem is handled in isolation, -->
|
|
11258
|
+
<!-- yet capturing and storing student work/results needs -->
|
|
11259
|
+
<!-- to be associated with the parent/enclosing "exercise" -->
|
|
11260
|
+
<!-- (or PROJECT-LIKE). So in this case (only) we place -->
|
|
11261
|
+
<!-- an id value on the div.exercise-wrapper that is -->
|
|
11262
|
+
<!-- derived from the parent. Otherwise, we use the -->
|
|
11263
|
+
<!-- @assembly-id of this "webwork-reps" with a "-ww-inner" -->
|
|
11264
|
+
<!-- suffix. That attribute is NOT the assembly stamp and -->
|
|
11265
|
+
<!-- carries no "pi" prefix: it is written by webwork.py into -->
|
|
11266
|
+
<!-- the generated representation file, naming it for the -->
|
|
11267
|
+
<!-- exercise it belongs to. The suffix ensures the inner -->
|
|
11268
|
+
<!-- wrapper's DOM id is distinct from the enclosing -->
|
|
11269
|
+
<!-- "exercise" article's id, which holds the same value. -->
|
|
11270
|
+
<!-- Without the suffix, JavaScript (handleWW) would -->
|
|
11271
|
+
<!-- look up the inner id with getElementById and find -->
|
|
11272
|
+
<!-- the outer "exercise" article instead. -->
|
|
11184
11273
|
<xsl:variable name="inner-id">
|
|
11185
11274
|
<xsl:choose>
|
|
11186
11275
|
<xsl:when test="$b-host-runestone">
|
|
@@ -11188,7 +11277,7 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
|
|
|
11188
11277
|
<xsl:text>-ww-rs</xsl:text>
|
|
11189
11278
|
</xsl:when>
|
|
11190
11279
|
<xsl:otherwise>
|
|
11191
|
-
<xsl:value-of select="concat(@
|
|
11280
|
+
<xsl:value-of select="concat(@assembly-id, '-ww-inner')"/>
|
|
11192
11281
|
</xsl:otherwise>
|
|
11193
11282
|
</xsl:choose>
|
|
11194
11283
|
</xsl:variable>
|
|
@@ -11336,7 +11425,7 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
|
|
|
11336
11425
|
</xsl:variable>
|
|
11337
11426
|
<!-- build the iframe -->
|
|
11338
11427
|
<!-- mimicking Mike Gage's blog post -->
|
|
11339
|
-
<iframe name="{concat(@
|
|
11428
|
+
<iframe name="{concat(@assembly-id, '-ww-inner')}" width="{$design-width}" src="{$the-url}" data-seed="{static/@seed}"/>
|
|
11340
11429
|
<script>
|
|
11341
11430
|
<xsl:text>iFrameResize({log:true,inPageLinks:true,resizeFrom:'child',checkOrigin:["</xsl:text>
|
|
11342
11431
|
<xsl:value-of select="$webwork-server" />
|
|
@@ -13196,6 +13285,7 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
|
|
|
13196
13285
|
<xsl:if test="not($the-number = '')">
|
|
13197
13286
|
<span class="codenumber">
|
|
13198
13287
|
<xsl:value-of select="$the-number" />
|
|
13288
|
+
<xsl:apply-templates select="." mode="division-number-separator"/>
|
|
13199
13289
|
</span>
|
|
13200
13290
|
<!-- separating space, only if needed -->
|
|
13201
13291
|
<xsl:text> </xsl:text>
|
|
@@ -14247,6 +14337,9 @@ TODO:
|
|
|
14247
14337
|
<xsl:if test="$b-has-program and not($b-debug-react)">
|
|
14248
14338
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/prism/1.26.0/components/prism-core.min.js"></script>
|
|
14249
14339
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/prism/1.26.0/plugins/autoloader/prism-autoloader.min.js"></script>
|
|
14340
|
+
<xsl:if test="$b-has-gdscript">
|
|
14341
|
+
<script src="{$html.js.dir}/prism/gdscript-prism.js"></script>
|
|
14342
|
+
</xsl:if>
|
|
14250
14343
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/prism/1.26.0/plugins/line-numbers/prism-line-numbers.min.js" integrity="sha512-dubtf8xMHSQlExGRQ5R7toxHLgSDZ0K7AunqPWHXmJQ8XyVIG19S1T95gBxlAeGOK02P4Da2RTnQz0Za0H0ebQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
|
|
14251
14344
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/prism/1.26.0/plugins/line-highlight/prism-line-highlight.min.js" integrity="sha512-93uCmm0q+qO5Lb1huDqr7tywS8A2TFA+1/WHvyiWaK6/pvsFl6USnILagntBx8JnVbQH5s3n0vQZY6xNthNfKA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
|
|
14252
14345
|
<xsl:if test="$b-html-theme-legacy or $b-reveal-build" >
|
|
@@ -353,6 +353,7 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
|
|
|
353
353
|
<xsl:text>.mathbook-content td.r {text-align: right;}
</xsl:text>
|
|
354
354
|
<xsl:text>.mathbook-content table tr.header-vertical th {writing-mode: vertical-rl; padding-left: 2em;}
</xsl:text>
|
|
355
355
|
<xsl:text>.mathbook-content .sbspanel img {max-width: 100%;}
</xsl:text>
|
|
356
|
+
<xsl:text>.mathbook-content .tablenotes {list-style: none; padding-left: 0;}
</xsl:text>
|
|
356
357
|
<xsl:text></style></xsl:text>
|
|
357
358
|
<xsl:call-template name="end-string" />
|
|
358
359
|
</xsl:with-param>
|
|
@@ -683,7 +683,7 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
|
|
|
683
683
|
|
|
684
684
|
<!-- Introductions and Conclusions -->
|
|
685
685
|
<!-- Introductions and conclusions are just their contents at their position. -->
|
|
686
|
-
<xsl:template match="article/introduction|chapter/introduction|section/introduction|subsection/introduction|appendix/introduction|exercises/introduction|solutions/introduction|worksheet/introduction|reading-questions/introduction
|
|
686
|
+
<xsl:template match="article/introduction|chapter/introduction|section/introduction|subsection/introduction|appendix/introduction|exercises/introduction|solutions/introduction|worksheet/introduction|reading-questions/introduction">
|
|
687
687
|
<xsl:text>% Introduction
</xsl:text>
|
|
688
688
|
<!-- an authored @xml:id suggests a cross-reference target -->
|
|
689
689
|
<xsl:if test="@xml:id">
|
|
@@ -694,7 +694,7 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
|
|
|
694
694
|
<xsl:text>% end of introduction
</xsl:text>
|
|
695
695
|
</xsl:template>
|
|
696
696
|
|
|
697
|
-
<xsl:template match="article/conclusion|chapter/conclusion|section/conclusion|subsection/conclusion|appendix/conclusion|exercises/conclusion|solutions/conclusion|worksheet/conclusion|reading-questions/conclusion
|
|
697
|
+
<xsl:template match="article/conclusion|chapter/conclusion|section/conclusion|subsection/conclusion|appendix/conclusion|exercises/conclusion|solutions/conclusion|worksheet/conclusion|reading-questions/conclusion">
|
|
698
698
|
<xsl:text>% Conclusion
</xsl:text>
|
|
699
699
|
<!-- an authored @xml:id suggests a cross-reference target -->
|
|
700
700
|
<xsl:if test="@xml:id">
|