+ This is the title of the page.
+
+
+
+
+
+```
+
+# Scyrumve spiro subitusque mente
+
+```{.sql caption="Pallas nuper longusque cratere habuisse sepulcro pectore fertur."}
+CREATE TYPE person_t AS (
+ firstName VARCHAR(50) NOT NULL,
+ lastName VARCHAR(50) NOT NULL
+);
+
+CREATE Or REPLACE FUNCTION getFormattedName(person) RETURNS text AS
+ $$ SELECT 'P: ' || initcap($1.firstName); $$
+LANGUAGE SQL;
+```
\ No newline at end of file
diff --git a/_extensions/drwater/dwev/demo/book.qmd b/_extensions/drwater/dwev/demo/book.qmd
new file mode 100644
index 0000000..4b3c42c
--- /dev/null
+++ b/_extensions/drwater/dwev/demo/book.qmd
@@ -0,0 +1,110 @@
+---
+title: "Example PDF"
+author: [Author]
+date: "2017-02-20"
+subject: "Markdown"
+keywords: [Markdown, Example]
+book: true
+classoption: [oneside]
+titlepage: true,
+# titlepage-rule-color: "360049"
+titlepage-text-color: "FFFFFF"
+titlepage-rule-height: 0
+titlepage-background: "inst/title-page-custom/background.pdf"
+format: dwev-pdf
+---
+
+# Crinis mixtaque factisque ille
+
+## Aut nunc furori ad latarumque Philomela
+
+Lorem markdownum includite volenti monticolae videre vocem hac sparsit puta
+gelidis vestros egressus sex. Undis eris per auguris armis. Est saevior pater.
+Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.
+
+## Gaudet Silenus iuvenis
+
+Mulciber denique faces ingratus, in umeros umeri cum, iram ira custos non.
+Pariterque admissa nubes, in ait ecce setae summis sacrorum me gaudete tellus.
+Ille tu perire ille, artificis caede.
+
+```scala
+def sumLeaves(t: Tree): Int = t match {
+ case Branch(l, r) => sumLeaves(l) + sumLeaves(r)
+ case Leaf(x) => x
+}
+```
+
+Cephea rector minorque, quem corpora,
+Argus. Superi hoc tenuavit timebant ossibus totque non serpere animo corpore
+superas gelidae, comitate deus Iunonigenaeque
+pectora.
+
+- Tuis Cereris armiferae fugiunt suus derepta vel
+- Veniam mea cum sollertior arbore flore
+- Ceae saecula
+- Tamen est
+
+## Dies tunc in enim
+
+Gerunt urimur violaeque agricolis iussa locis puppis
+simul cognita, vertentia Romana
+obprobrium pignora superem est certe nondum suffuderat. Nox Pasiphaeia domo:
+**abiit** catenas utro crimine gramina ingemuere mixtae. Quem trabibus etiamnum
+orbe addita, eiaculatur videri cervo artus. Nutritur cupidine silentia Maeoniam
+aere enim gemuit adgreditur, telasque *annis* nos cum Arctonque ingens lateri
+cum iaculoque ferus.
+
+## Et dextra utque per lenius portus eburnae
+
+Cui vittas aris ibi putat dicere; factum sedere antiqua? Cognita Lyncides iuste
+insuetum lacerum in sinamus arces; aves aevum spatiumque de utrumque moveret in?
+Tertia ordine, Epidaurius, *has sed et* et novat: quod superare concubitusque
+retia quoque, ne totiens.
+
+Est paenitet Cerealia sparsit; carne insignia in maris; tibi Nec, que Peleu meum
+buxus. Propoetides formae magna auro ad gerat cohibentur facienda partem at
+nunc, foret? **Ad stirpe**! Ut latius pararet: vestibus cumque pedibus ficta
+prior summas cancer ipsa Marte Buten es
+terruit. Opifex dixit oculos Oete quoque, quot silvarum abrepti nutrix concita
+obsidis consistere fibula saxum, Antigonen minabitur tota.
+
+# Vagata eiectatamque sidera satis reducet
+
+## Talem ex aliquo ingemuit
+
+Lorem markdownum solus miserabile sitae. Tantum Syron limenque cupidine: litore
+modo coniuge: in huc, illo crimen novena, vocisque gratia, quae. Sua manusque
+patris nec meritorum pedibus hominis virgine, ruere tamen virtus aliter. Tunc
+ego. Solitaque remittant fagus omnia eat.
+
+$$r_d^i(t+1) = \min\{r_s,\max\{0, r_d^i(t) + \beta(n_t - \lvert N_i(t)\rvert)\}\}$$
+
+Obstitit silentia et novi non, huic metitur, coronantur lucos. Bracchia aura;
+donis quod volucris illi futurae, ut
+*venturorumque tellus* arma: saxumque.
+
+## Vera tum est putes adspicit noxque
+
+Hora et vidit figere tangi! Omni bis *prior nunc* capilli, pulsat tuam Pallante,
+*suis*. Solae decore ipso armorum coitusque paro audita *viveret tibi* apparuit
+flammasque lapides. Cursu anas usus eundo anticipata, intabescere quae concita
+fallit. Dea corpore fabrae: nec Neptunus membris, falsa murice; fac Marte quam
+in.
+
+Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et.
+
+## Arachnes deus tum penetralia tempore aurea populante
+
+Lentae spissisque *carne*. Fixit inquit cautes et iugis novus sim quisquam nisi
+haesurum vel deorum fetibus virgo.
+
+Sub nautae, tegebat clamat. Credas Parrhasio. Commemorat nescio liceatque
+excipit! Uris clipeo ego visa amplexas meos ibitis condidit Taenaria, si. Tua
+ora tempus patrio revulsos, tellus curru facies, Gange gemit agitata!
+
+Ruinam ipsaque sibi ovis Teucer Iovis tibi; erat versus neque victa attonitus
+doque, quod! Dixit carmina, eo, per capillis quid lina, qua, ille. Siqua
+caelestum flammas ferre super et saevissime inmisit quoque suis sic aspergine
+vis praerupit. Et puellae summa eventu.
+Placeat ut medio *plectrumque inferni* Talia; pertimui opem.
diff --git a/_extensions/drwater/dwev/demo/boxes-with-pandoc-latex-environment-and-awesomebox.qmd b/_extensions/drwater/dwev/demo/boxes-with-pandoc-latex-environment-and-awesomebox.qmd
new file mode 100644
index 0000000..3c26ccd
--- /dev/null
+++ b/_extensions/drwater/dwev/demo/boxes-with-pandoc-latex-environment-and-awesomebox.qmd
@@ -0,0 +1,131 @@
+---
+title: "Boxes with pandoc-latex-environment and awesomebox"
+author: [Author]
+date: "2020-01-01"
+subject: "Markdown"
+keywords: [Markdown, Example]
+lang: "en"
+colorlinks: true
+header-includes:
+- |
+ ```{=latex}
+ \usepackage{awesomebox}
+ ```
+pandoc-latex-environment:
+ noteblock: [note]
+ tipblock: [tip]
+ warningblock: [warning]
+ cautionblock: [caution]
+ importantblock: [important]
+format: dwev-pdf
+---
+
+# Boxes with `pandoc-latex-environment` and `awesomebox`
+
+This example demonstrates the use of the filter [`pandoc-latex-environments`] to create custom boxes with the [`awesomebox`] package. *pandoc-latex-environment* is a pandoc filter for adding LaTeX environment on specific HTML div tags.
+
+
+## Box Types
+
+For a list of all available boxes and options visit the [`awesomebox` documentation](https://ctan.org/pkg/awesomebox).
+
+```markdown
+::: note
+Lorem ipsum dolor ...
+:::
+```
+
+::: note
+Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam aliquet libero
+quis lectus elementum fermentum.
+
+Fusce aliquet augue sapien, non efficitur mi ornare sed. Morbi at dictum
+felis. Pellentesque tortor lacus, semper et neque vitae, egestas commodo nisl.
+:::
+
+```markdown
+::: tip
+Lorem ipsum dolor ...
+:::
+```
+
+::: tip
+Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam aliquet libero
+quis lectus elementum fermentum.
+
+Fusce aliquet augue sapien, non efficitur mi ornare sed. Morbi at dictum
+felis. Pellentesque tortor lacus, semper et neque vitae, egestas commodo nisl.
+:::
+
+```markdown
+::: warning
+Lorem ipsum dolor ...
+:::
+```
+
+::: warning
+Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam aliquet libero
+quis lectus elementum fermentum.
+
+Fusce aliquet augue sapien, non efficitur mi ornare sed. Morbi at dictum
+felis. Pellentesque tortor lacus, semper et neque vitae, egestas commodo nisl.
+:::
+
+```markdown
+::: caution
+Lorem ipsum dolor ...
+:::
+```
+
+::: caution
+Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam aliquet libero
+quis lectus elementum fermentum.
+
+Fusce aliquet augue sapien, non efficitur mi ornare sed. Morbi at dictum
+felis. Pellentesque tortor lacus, semper et neque vitae, egestas commodo nisl.
+:::
+
+```markdown
+::: important
+Lorem ipsum dolor ...
+:::
+```
+
+::: important
+Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam aliquet libero
+quis lectus elementum fermentum.
+
+Fusce aliquet augue sapien, non efficitur mi ornare sed. Morbi at dictum
+felis. Pellentesque tortor lacus, semper et neque vitae, egestas commodo nisl.
+:::
+
+One can also use raw HTML `div` tags to create the custom environments.
+
+```markdown
+
+Lorem ipsum dolor ...
+
+```
+
+
+Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam aliquet libero
+quis lectus elementum fermentum.
+
+
+Markdown formatting inside the environments is supported.
+
+::: important
+**Lorem ipsum dolor** sit amet, `consectetur adipiscing` elit.
+
+```
+if(args.length < 2) {
+ System.out.println("Lorem ipsum dolor sit amet");
+}
+```
+
+*Nam aliquet libero
+quis lectus elementum fermentum.*
+:::
+
+[`pandoc-latex-environments`]: https://github.com/chdemko/pandoc-latex-environment/
+[`awesomebox`]: https://ctan.org/pkg/awesomebox
\ No newline at end of file
diff --git a/_extensions/drwater/dwev/demo/boxes-with-pandoc-latex-environment-and-tcolorbox.qmd b/_extensions/drwater/dwev/demo/boxes-with-pandoc-latex-environment-and-tcolorbox.qmd
new file mode 100644
index 0000000..5d460eb
--- /dev/null
+++ b/_extensions/drwater/dwev/demo/boxes-with-pandoc-latex-environment-and-tcolorbox.qmd
@@ -0,0 +1,79 @@
+---
+title: "Boxes with pandoc-latex-environment and tcolorbox"
+author: [Author]
+date: "2020-01-01"
+subject: "Markdown"
+keywords: [Markdown, Example]
+lang: "en"
+colorlinks: true
+header-includes:
+- |
+ ```{=latex}
+ \usepackage{tcolorbox}
+
+ \newtcolorbox{info-box}{colback=cyan!5!white,arc=0pt,outer arc=0pt,colframe=cyan!60!black}
+ \newtcolorbox{warning-box}{colback=orange!5!white,arc=0pt,outer arc=0pt,colframe=orange!80!black}
+ \newtcolorbox{error-box}{colback=red!5!white,arc=0pt,outer arc=0pt,colframe=red!75!black}
+ ```
+pandoc-latex-environment:
+ tcolorbox: [box]
+ info-box: [info]
+ warning-box: [warning]
+ error-box: [error]
+format: dwev-pdf
+---
+
+# Boxes with `pandoc-latex-environment` and `tcolorbox`
+
+This example demonstrates the use of the filter [`pandoc-latex-environments`]
+to create custom boxes with the [`tcolorbox`] package.
+*pandoc-latex-environment* is a pandoc filter for adding LaTeX environment on
+specific HTML div tags. For a list of all available options visit the
+[`tcolorbox` documentation](https://ctan.org/pkg/tcolorbox).
+
+## Simple Box
+
+::: box
+Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam aliquet libero
+quis lectus elementum fermentum.
+:::
+
+## Markdown inside the Box
+
+Markdown formatting inside the environment is supported.
+
+::: box
+Lorem ipsum **dolor** sit amet, `consectetur adipiscing` elit.
+
+```
+if(args.length < 2) {
+ System.out.println("Lorem ipsum dolor sit amet");
+}
+```
+
+*Nam aliquet libero
+quis lectus elementum fermentum.*
+:::
+
+## Custom Box
+
+One can define custom boxes in the LaTeX preamble with the variable
+`header-includes` at the top of this document.
+
+::: info
+**Info**: This is a custom box that may be used to show info messages in your
+document.
+:::
+
+::: warning
+**Warning**: This is a custom box that may be used to show warning messages in
+your document.
+:::
+
+::: error
+**Error**: This is a custom box that may be used to show error messages in your
+document.
+:::
+
+[`pandoc-latex-environments`]: https://github.com/chdemko/pandoc-latex-environment/
+[`tcolorbox`]: https://ctan.org/pkg/tcolorbox
\ No newline at end of file
diff --git a/_extensions/drwater/dwev/demo/code-blocks-listings.qmd b/_extensions/drwater/dwev/demo/code-blocks-listings.qmd
new file mode 100644
index 0000000..5adf4d2
--- /dev/null
+++ b/_extensions/drwater/dwev/demo/code-blocks-listings.qmd
@@ -0,0 +1,56 @@
+---
+title: "Example PDF"
+author: [Author]
+date: "2017-02-20"
+subject: "Markdown"
+keywords: [Markdown, Example]
+format: dwev-pdf
+---
+
+# Vinaque sanguine metuenti cuiquam Alcyone fixus
+
+## Aesculeae domus vincemur et Veneris adsuetus lapsum
+
+Lorem markdownum Letoia, et alios -- "figurae flectentem annis aliquid Peneosque" ab
+esse, 'obstat' gravitate.
+
+```java
+public class Example implements LoremIpsum {
+ public static void main(String[] args) {
+ if(args.length < 2) {
+ System.out.println("Lorem ipsum dolor sit amet");
+ }
+ } // Obscura atque coniuge, per de coniunx
+}
+```
+
+Porrigitur et Pallas nuper longusque cratere habuisse sepulcro pectore fertur. Obscura atque coniuge, per de coniunx, sibi medias
+commentaque virgine anima tamen comitemque petis, sed.
+
+```{.html caption="Porrigitur et Pallas nuper longusque cratere habuisse sepulcro pectore fertur. Obscura atque coniuge, per de coniunx, sibi medias
+commentaque virgine anima tamen comitemque petis, sed."}
+
+
+
+ This is the title of the page.
+
+
+ This is a link.
+
+
+
+```
+
+Vertitur iura tum nepotis causa; motus. Diva virtus! Acrota
+destruitis vos iubet quo et classis excessere Scyrumve spiro subitusque mente
+Pirithoi abstulit, lapides.
+
+```sql
+CREATE TYPE person_t AS (
+ firstName VARCHAR(50) NOT NULL,
+ lastName VARCHAR(50) NOT NULL
+);
+CREATE Or REPLACE FUNCTION getFormattedName(person) RETURNS text AS
+ $$ SELECT 'P: ' || initcap($1.firstName); $$
+LANGUAGE SQL;
+```
\ No newline at end of file
diff --git a/_extensions/drwater/dwev/demo/code-blocks-without-listings.qmd b/_extensions/drwater/dwev/demo/code-blocks-without-listings.qmd
new file mode 100644
index 0000000..d16aee7
--- /dev/null
+++ b/_extensions/drwater/dwev/demo/code-blocks-without-listings.qmd
@@ -0,0 +1,53 @@
+---
+title: "Example PDF"
+author: [Author]
+date: "2017-02-20"
+subject: "Markdown"
+keywords: [Markdown, Example]
+lang: "en"
+format: dwev-pdf
+---
+
+# Vinaque sanguine metuenti cuiquam Alcyone fixus
+
+Lorem markdownum Letoia, et alios: figurae flectentem annis aliquid Peneosque
+abesse obstat.
+
+```java
+public class Example implements LoremIpsum {
+ public static void map(String[] sortedLeft, Long[] sortedRight, int splitIndex) {
+ if(sortedLeft == null || sortedRight == null) {
+ System.err.println("Lorem ipsum dolor sit amet");
+ }
+ } // Obscura atque coniuge, per de coniunx
+}
+```
+
+Porrigitur et Pallas nuper longusque cratere habuisse sepulcro pectore fertur
+obscura atque coniuge.
+
+```html
+
+
+
+ This is the title of the page.
+
+
+ This is a link.
+
+
+
+```
+
+Vertitur iura tum nepotis causa; motus. Diva virtus! Acrota destruitis vos
+iubet quo et classis excessere.
+
+```sql
+CREATE TYPE person_t AS (
+ firstName VARCHAR(50) NOT NULL,
+);
+
+CREATE Or REPLACE FUNCTION getFormattedName(person) RETURNS text AS
+ $$ SELECT 'P: ' || initcap($1.firstName); $$
+LANGUAGE SQL;
+```
\ No newline at end of file
diff --git a/_extensions/drwater/dwev/demo/header-and-footer.qmd b/_extensions/drwater/dwev/demo/header-and-footer.qmd
new file mode 100644
index 0000000..a8f230c
--- /dev/null
+++ b/_extensions/drwater/dwev/demo/header-and-footer.qmd
@@ -0,0 +1,63 @@
+---
+title: "Example PDF"
+author: [Author]
+date: "2017-02-20"
+subject: "Markdown"
+keywords: [Markdown, Example]
+header-left: "\\hspace{1cm}"
+header-center: "\\leftmark"
+header-right: "Page \\thepage"
+footer-left: "\\thetitle"
+footer-center: "This is \\LaTeX{}"
+footer-right: "\\theauthor"
+format: dwev-pdf
+---
+
+# Vinaque sanguine metuenti cuiquam Alcyone fixus
+
+## Aesculeae domus vincemur et Veneris adsuetus lapsum
+
+Lorem markdownum Letoia, et alios: figurae flectentem annis aliquid Peneosque ab
+esse, obstat gravitate. Obscura atque coniuge, per de coniunx, sibi **medias
+commentaque virgine** anima tamen comitemque petis, sed. In Amphion vestros
+hamos ire arceor mandere spicula, in licet aliquando.
+
+```java
+public class Example implements LoremIpsum {
+ public static void main(String[] args) {
+ if(args.length < 2) {
+ System.out.println("Lorem ipsum dolor sit amet");
+ }
+ } // Obscura atque coniuge, per de coniunx
+}
+```
+
+Porrigitur et Pallas nuper longusque cratere habuisse sepulcro pectore fertur.
+Laudat ille auditi; vertitur iura tum nepotis causa; motus. Diva virtus! Acrota
+destruitis vos iubet quo et classis excessere Scyrumve spiro subitusque mente
+Pirithoi abstulit, lapides.
+
+## Lydia caelo recenti haerebat lacerum ratae at
+
+Te concepit pollice fugit vias alumno **oras** quam potest
+[rursus](http://example.com#rursus) optat. Non evadere orbem equorum, spatiis,
+vel pede inter si.
+
+1. De neque iura aquis
+2. Frangitur gaudia mihi eo umor terrae quos
+3. Recens diffudit ille tantum
+
+\begin{equation}\label{eq:neighbor-propability}
+ p_{ij}(t) = \frac{\ell_j(t) - \ell_i(t)}{\sum_{k \in N_i(t)}^{} \ell_k(t) - \ell_i(t)}
+\end{equation}
+
+Tamen condeturque saxa Pallorque num et ferarum promittis inveni lilia iuvencae
+adessent arbor. Florente perque at condeturque saxa et ferarum promittis tendebat. Armos nisi obortas refugit me.
+
+> Et nepotes poterat, se qui. Euntem ego pater desuetaque aethera Maeandri, et
+[Dardanio geminaque](http://example.com#Dardanio_geminaque) cernit. Lassaque poenas
+nec, manifesta $\pi r^2$ mirantia captivarum prohibebant scelerato gradus unusque
+dura.
+
+- Permulcens flebile simul
+- Iura tum nepotis causa motus diva virtus Acrota. Tamen condeturque saxa Pallorque num et ferarum promittis inveni lilia iuvencae adessent arbor. Florente perque at ire arcum.
\ No newline at end of file
diff --git a/_extensions/drwater/dwev/demo/images-and-tables.qmd b/_extensions/drwater/dwev/demo/images-and-tables.qmd
new file mode 100644
index 0000000..043e46d
--- /dev/null
+++ b/_extensions/drwater/dwev/demo/images-and-tables.qmd
@@ -0,0 +1,66 @@
+---
+title: "Example PDF"
+author: [Author]
+date: "2017-02-20"
+subject: "Markdown"
+keywords: [Markdown, Example]
+lang: "en"
+table-use-row-colors: false
+format: dwev-pdf
+---
+
+# Images and Tables
+
+## LaTeX Table with Caption
+
+At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr.
+
+\begin{longtable}[]{llllllll}
+\caption[tbl-aa]{Nam liber tempor cum soluta nobis eleifend option congue nihil imperdiet doming id quod mazim placerat facer possim assum. Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.} \\
+\toprule
+Test Nr. & Position & Radius & Rot & Grün & Blau &
+beste Fitness & Abweichung\tabularnewline
+\midrule
+\endhead
+1 & 20 \% & 20 \% & 20 \% & 20 \% & 20 \% & 7,5219 &
+0,9115\tabularnewline
+2 & 0 \% & 25 \% & 25 \% & 25 \% & 25 \% & 8,0566 &
+1,4462\tabularnewline
+3 & 0 \% & 0 \% & 33 \% & 33 \% & 33 \% & 8,7402 & 2,1298\tabularnewline
+4 & 50 \% & 20 \% & 10 \% & 10 \% & 10 \% & 6,6104 &
+0,0000\tabularnewline
+5 & 70 \% & 0 \% & 10 \% & 10 \% & 10 \% & 7,0696 &
+0,4592\tabularnewline
+6 & 20 \% & 50 \% & 10 \% & 10 \% & 10 \% & 7,0034 &
+0,3930\tabularnewline
+\bottomrule
+\end{longtable}
+
+At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr.
+
+## Image with Caption
+
+
+
+## Markdown Table without Caption
+
+Lorem markdownum Letoia, et alios: figurae flectentem annis aliquid Peneosque abesse, obstat gravitate. Obscura atque coniuge, per de coniunx, sibi medias
+commentaque virgine anima tamen comitemque petis, sed. In Amphion vestros
+hamos ire arceor mandere spicula, in licet aliquando.
+
+Test Nr. | Position | Radius | Rot | Grün | Blau | beste Fitness | Abweichung |
+|---|---|---|---|---|---|---|---|
+1 | 20 % | 20 % | 20 % | 20 % | 20 % | 7,5219 | 0,9115 |
+2 | 0 % | 25 % | 25 % | 25 % | 25 % | 8,0566 | 1,4462 |
+3 | 0 % | 0 % | 33 % | 33 % | 33 % | 8,7402 | 2,1298 |
+4 | 50 % | 20 % | 10 % | 10 % | 10 % | 6,6104 | 0,0000 |
+5 | 70 % | 0 % | 10 % | 10 % | 10 % | 7,0696 | 0,4592 |
+6 | 20 % | 50 % | 10 % | 10 % | 10 % | 7,0034 | 0,3930 |
+7 | 40 % | 15 % | 15 % | 15 % | 15 % | 6,9122 | 0,3018 |
+
+Porrigitur et Pallas nuper longusque cratere habuisse sepulcro pectore fertur.
+Laudat ille auditi; vertitur iura tum nepotis causa; motus. Diva virtus! Acrota destruitis vos iubet quo et classis excessere Scyrumve spiro subitusque mente Pirithoi abstulit, lapides.
+
+## Image without Caption
+
+
diff --git a/_extensions/drwater/dwev/demo/images-and-tables.tex b/_extensions/drwater/dwev/demo/images-and-tables.tex
new file mode 100644
index 0000000..d136a59
--- /dev/null
+++ b/_extensions/drwater/dwev/demo/images-and-tables.tex
@@ -0,0 +1,504 @@
+%%
+% Copyright (c) 2017 - 2024, Pascal Wagler;
+% Copyright (c) 2014 - 2024, John MacFarlane
+%
+% All rights reserved.
+%
+% Redistribution and use in source and binary forms, with or without
+% modification, are permitted provided that the following conditions
+% are met:
+%
+% - Redistributions of source code must retain the above copyright
+% notice, this list of conditions and the following disclaimer.
+%
+% - Redistributions in binary form must reproduce the above copyright
+% notice, this list of conditions and the following disclaimer in the
+% documentation and/or other materials provided with the distribution.
+%
+% - Neither the name of John MacFarlane nor the names of other
+% contributors may be used to endorse or promote products derived
+% from this software without specific prior written permission.
+%
+% THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+% "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+% LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+% FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+% COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+% INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+% BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+% LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+% CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+% LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
+% ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+% POSSIBILITY OF SUCH DAMAGE.
+%%
+
+%%
+% This is the Eisvogel pandoc LaTeX template.
+%
+% For usage information and examples visit the official GitHub page:
+% https://github.com/Wandmalfarbe/pandoc-latex-template
+%%
+
+% Options for packages loaded elsewhere
+\PassOptionsToPackage{unicode}{hyperref}
+\PassOptionsToPackage{hyphens}{url}
+\PassOptionsToPackage{dvipsnames,svgnames,x11names,table}{xcolor}
+%
+\documentclass[
+ paper=a4,
+ ,captions=tableheading
+]{scrartcl}
+\usepackage{amsmath,amssymb}
+% Use setspace anyway because we change the default line spacing.
+% The spacing is changed early to affect the titlepage and the TOC.
+\usepackage{setspace}
+\setstretch{1.2}
+\usepackage{iftex}
+\ifPDFTeX
+ \usepackage[T1]{fontenc}
+ \usepackage[utf8]{inputenc}
+ \usepackage{textcomp} % provide euro and other symbols
+\else % if luatex or xetex
+ \usepackage{unicode-math} % this also loads fontspec
+ \defaultfontfeatures{Scale=MatchLowercase}
+ \defaultfontfeatures[\rmfamily]{Ligatures=TeX,Scale=1}
+\fi
+\usepackage{lmodern}
+\ifPDFTeX\else
+ % xetex/luatex font selection
+\fi
+% Use upquote if available, for straight quotes in verbatim environments
+\IfFileExists{upquote.sty}{\usepackage{upquote}}{}
+\IfFileExists{microtype.sty}{% use microtype if available
+ \usepackage[]{microtype}
+ \UseMicrotypeSet[protrusion]{basicmath} % disable protrusion for tt fonts
+}{}
+\makeatletter
+\@ifundefined{KOMAClassName}{% if non-KOMA class
+ \IfFileExists{parskip.sty}{%
+ \usepackage{parskip}
+ }{% else
+ \setlength{\parindent}{0pt}
+ \setlength{\parskip}{6pt plus 2pt minus 1pt}}
+}{% if KOMA class
+ \KOMAoptions{parskip=half}}
+\makeatother
+\usepackage{xcolor}
+\definecolor{default-linkcolor}{HTML}{A50000}
+\definecolor{default-filecolor}{HTML}{A50000}
+\definecolor{default-citecolor}{HTML}{4077C0}
+\definecolor{default-urlcolor}{HTML}{4077C0}
+\usepackage[margin=2.5cm,includehead=true,includefoot=true,centering,]{geometry}
+\usepackage{longtable,booktabs,array}
+\usepackage{calc} % for calculating minipage widths
+% Correct order of tables after \paragraph or \subparagraph
+\usepackage{etoolbox}
+\makeatletter
+\patchcmd\longtable{\par}{\if@noskipsec\mbox{}\fi\par}{}{}
+\makeatother
+% Allow footnotes in longtable head/foot
+\IfFileExists{footnotehyper.sty}{\usepackage{footnotehyper}}{\usepackage{footnote}}
+\makesavenoteenv{longtable}
+% add backlinks to footnote references, cf. https://tex.stackexchange.com/questions/302266/make-footnote-clickable-both-ways
+\usepackage{footnotebackref}
+\usepackage{graphicx}
+\makeatletter
+% \def\maxwidth{\ifdim\Gin@nat@width>\linewidth\linewidth\else\Gin@nat@width\fi}
+% \def\maxheight{\ifdim\Gin@nat@height>\textheight\textheight\else\Gin@nat@height\fi}
+% \makeatother
+% % Scale images if necessary, so that they will not overflow the page
+% % margins by default, and it is still possible to overwrite the defaults
+% % using explicit options in \includegraphics[width, height, ...]{}
+% \setkeys{Gin}{width=\maxwidth,height=\maxheight,keepaspectratio}
+\newsavebox\pandoc@box
+\newcommand*\pandocbounded[1]{% scales image to fit in text height/width
+ \sbox\pandoc@box{#1}%
+ \Gscale@div\@tempa{\textheight}{\dimexpr\ht\pandoc@box+\dp\pandoc@box\relax}%
+ \Gscale@div\@tempb{\linewidth}{\wd\pandoc@box}%
+ \ifdim\@tempb\p@<\@tempa\p@\let\@tempa\@tempb\fi% select the smaller of both
+ \ifdim\@tempa\p@<\p@\scalebox{\@tempa}{\usebox\pandoc@box}%
+ \else\usebox{\pandoc@box}%
+ \fi%
+}
+% Set default figure placement to htbp
+\makeatletter
+\def\fps@figure{htbp}
+\makeatother
+% \makeatletter Old options from template, replaced with quarto defaults above
+% \newsavebox\pandoc@box
+% \newcommand*\pandocbounded[1]{% scales image to fit in text height/width
+% \sbox\pandoc@box{#1}%
+% \Gscale@div\@tempa{\textheight}{\dimexpr\ht\pandoc@box+\dp\pandoc@box\relax}%
+% \Gscale@div\@tempb{\linewidth}{\wd\pandoc@box}%
+% \ifdim\@tempb\p@<\@tempa\p@\let\@tempa\@tempb\fi% select the smaller of both
+% \ifdim\@tempa\p@<\p@\scalebox{\@tempa}{\usebox\pandoc@box}%
+% \else\usebox{\pandoc@box}%
+% \fi%
+% }
+% % Set default figure placement to htbp
+% % Make use of float-package and set default placement for figures to H.
+% % The option H means 'PUT IT HERE' (as opposed to the standard h option which means 'You may put it here if you like').
+% \usepackage{float}
+% \floatplacement{figure}{H}
+% \makeatother
+\setlength{\emergencystretch}{3em} % prevent overfull lines
+\providecommand{\tightlist}{%
+ \setlength{\itemsep}{0pt}\setlength{\parskip}{0pt}}
+\setcounter{secnumdepth}{-\maxdimen} % remove section numbering
+% Make \paragraph and \subparagraph free-standing
+\makeatletter
+\ifx\paragraph\undefined\else
+ \let\oldparagraph\paragraph
+ \renewcommand{\paragraph}{
+ \@ifstar
+ \xxxParagraphStar
+ \xxxParagraphNoStar
+ }
+ \newcommand{\xxxParagraphStar}[1]{\oldparagraph*{#1}\mbox{}}
+ \newcommand{\xxxParagraphNoStar}[1]{\oldparagraph{#1}\mbox{}}
+\fi
+\ifx\subparagraph\undefined\else
+ \let\oldsubparagraph\subparagraph
+ \renewcommand{\subparagraph}{
+ \@ifstar
+ \xxxSubParagraphStar
+ \xxxSubParagraphNoStar
+ }
+ \newcommand{\xxxSubParagraphStar}[1]{\oldsubparagraph*{#1}\mbox{}}
+ \newcommand{\xxxSubParagraphNoStar}[1]{\oldsubparagraph{#1}\mbox{}}
+\fi
+\makeatother
+\ifLuaTeX
+\usepackage[bidi=basic]{babel}
+\else
+\usepackage[bidi=default]{babel}
+\fi
+\babelprovide[main,import]{english}
+% get rid of language-specific shorthands (see #6817):
+\let\LanguageShortHands\languageshorthands
+\def\languageshorthands#1{}
+\ifLuaTeX
+ \usepackage[english]{selnolig} % disable illegal ligatures
+\fi
+\makeatletter
+\@ifpackageloaded{caption}{}{\usepackage{caption}}
+\AtBeginDocument{%
+\ifdefined\contentsname
+ \renewcommand*\contentsname{Table of contents}
+\else
+ \newcommand\contentsname{Table of contents}
+\fi
+\ifdefined\listfigurename
+ \renewcommand*\listfigurename{List of Figures}
+\else
+ \newcommand\listfigurename{List of Figures}
+\fi
+\ifdefined\listtablename
+ \renewcommand*\listtablename{List of Tables}
+\else
+ \newcommand\listtablename{List of Tables}
+\fi
+\ifdefined\figurename
+ \renewcommand*\figurename{Figure}
+\else
+ \newcommand\figurename{Figure}
+\fi
+\ifdefined\tablename
+ \renewcommand*\tablename{Table}
+\else
+ \newcommand\tablename{Table}
+\fi
+}
+\@ifpackageloaded{float}{}{\usepackage{float}}
+\floatstyle{ruled}
+\@ifundefined{c@chapter}{\newfloat{codelisting}{h}{lop}}{\newfloat{codelisting}{h}{lop}[chapter]}
+\floatname{codelisting}{Listing}
+\newcommand*\listoflistings{\listof{codelisting}{List of Listings}}
+\makeatother
+\makeatletter
+\makeatother
+\makeatletter
+\@ifpackageloaded{caption}{}{\usepackage{caption}}
+\@ifpackageloaded{subcaption}{}{\usepackage{subcaption}}
+\makeatother
+\usepackage{bookmark}
+\IfFileExists{xurl.sty}{\usepackage{xurl}}{} % add URL line breaks if available
+\urlstyle{same}
+\hypersetup{
+ pdftitle={Example PDF},
+ pdfauthor={Author},
+ pdflang={en},
+ pdfsubject={Markdown},
+ pdfkeywords={Markdown, Example},
+ colorlinks=true,
+ linkcolor={blue},
+ filecolor={default-filecolor},
+ citecolor={default-citecolor},
+ urlcolor={default-urlcolor},
+ breaklinks=true,
+ pdfcreator={LaTeX via pandoc with the Eisvogel template}}
+\title{Example PDF}
+\author{Author}
+\date{2017-02-20}
+
+
+
+%%
+%% added
+%%
+
+
+%
+% for the background color of the title page
+%
+
+%
+% break urls
+%
+\PassOptionsToPackage{hyphens}{url}
+
+%
+% When using babel or polyglossia with biblatex, loading csquotes is recommended
+% to ensure that quoted texts are typeset according to the rules of your main language.
+%
+\usepackage{csquotes}
+
+%
+% captions
+%
+\definecolor{caption-color}{HTML}{777777}
+\usepackage[font={stretch=1.2}, textfont={color=caption-color}, position=top, skip=4mm, labelfont=bf, singlelinecheck=false, justification=raggedright]{caption}
+\setcapindent{0em}
+
+%
+% blockquote
+%
+\definecolor{blockquote-border}{RGB}{221,221,221}
+\definecolor{blockquote-text}{RGB}{119,119,119}
+\usepackage{mdframed}
+\newmdenv[rightline=false,bottomline=false,topline=false,linewidth=3pt,linecolor=blockquote-border,skipabove=\parskip]{customblockquote}
+\renewenvironment{quote}{\begin{customblockquote}\list{}{\rightmargin=0em\leftmargin=0em}%
+\item\relax\color{blockquote-text}\ignorespaces}{\unskip\unskip\endlist\end{customblockquote}}
+
+%
+% Source Sans Pro as the default font family
+% Source Code Pro for monospace text
+%
+% 'default' option sets the default
+% font family to Source Sans Pro, not \sfdefault.
+%
+\ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex
+ \usepackage[default]{sourcesanspro}
+ \usepackage{sourcecodepro}
+ \else % if not pdftex
+ \usepackage[default]{sourcesanspro}
+ \usepackage{sourcecodepro}
+
+ % XeLaTeX specific adjustments for straight quotes: https://tex.stackexchange.com/a/354887
+ % This issue is already fixed (see https://github.com/silkeh/latex-sourcecodepro/pull/5) but the
+ % fix is still unreleased.
+ % TODO: Remove this workaround when the new version of sourcecodepro is released on CTAN.
+ \ifxetex
+ \makeatletter
+ \defaultfontfeatures[\ttfamily]
+ { Numbers = \sourcecodepro@figurestyle,
+ Scale = \SourceCodePro@scale,
+ Extension = .otf }
+ \setmonofont
+ [ UprightFont = *-\sourcecodepro@regstyle,
+ ItalicFont = *-\sourcecodepro@regstyle It,
+ BoldFont = *-\sourcecodepro@boldstyle,
+ BoldItalicFont = *-\sourcecodepro@boldstyle It ]
+ {SourceCodePro}
+ \makeatother
+ \fi
+ \fi
+
+%
+% heading color
+%
+\definecolor{heading-color}{RGB}{40,40,40}
+\addtokomafont{section}{\color{heading-color}}
+% When using the classes report, scrreprt, book,
+% scrbook or memoir, uncomment the following line.
+%\addtokomafont{chapter}{\color{heading-color}}
+
+%
+% variables for title, author and date
+%
+\usepackage{titling}
+\title{Example PDF}
+\author{Author}
+\date{2017-02-20}
+
+%
+% tables
+%
+
+\definecolor{table-row-color}{HTML}{F5F5F5}
+\definecolor{table-rule-color}{HTML}{999999}
+
+%\arrayrulecolor{black!40}
+\arrayrulecolor{table-rule-color} % color of \toprule, \midrule, \bottomrule
+\setlength\heavyrulewidth{0.3ex} % thickness of \toprule, \bottomrule
+\renewcommand{\arraystretch}{1.3} % spacing (padding)
+
+
+%
+% remove paragraph indentation
+%
+\setlength{\parindent}{0pt}
+\setlength{\parskip}{6pt plus 2pt minus 1pt}
+\setlength{\emergencystretch}{3em} % prevent overfull lines
+
+%
+%
+% Listings
+%
+%
+
+
+%
+% header and footer
+%
+\usepackage[headsepline,footsepline]{scrlayer-scrpage}
+
+\newpairofpagestyles{eisvogel-header-footer}{
+ \clearpairofpagestyles
+ \ihead*{Example PDF}
+ \chead*{}
+ \ohead*{2017-02-20}
+ \ifoot*{Author}
+ \cfoot*{}
+ \ofoot*{\thepage}
+ \addtokomafont{pageheadfoot}{\upshape}
+}
+\pagestyle{eisvogel-header-footer}
+
+
+
+%%
+%% end added
+%%
+
+\begin{document}
+
+%%
+%% begin titlepage
+%%
+
+%%
+%% end titlepage
+%%
+
+% \maketitle
+
+
+\section{Images and Tables}\label{images-and-tables}
+
+\subsection{LaTeX Table with Caption}\label{latex-table-with-caption}
+
+At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd
+gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem
+ipsum dolor sit amet, consetetur sadipscing elitr.
+
+\begin{longtable*}[]{llllllll}
+\caption[tbl-aa]{Nam liber tempor cum soluta nobis eleifend option congue nihil imperdiet doming id quod mazim placerat facer possim assum. Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.} \\
+\toprule
+Test Nr. & Position & Radius & Rot & Grün & Blau &
+beste Fitness & Abweichung\tabularnewline
+\midrule
+\endhead
+1 & 20 \% & 20 \% & 20 \% & 20 \% & 20 \% & 7,5219 &
+0,9115\tabularnewline
+2 & 0 \% & 25 \% & 25 \% & 25 \% & 25 \% & 8,0566 &
+1,4462\tabularnewline
+3 & 0 \% & 0 \% & 33 \% & 33 \% & 33 \% & 8,7402 & 2,1298\tabularnewline
+4 & 50 \% & 20 \% & 10 \% & 10 \% & 10 \% & 6,6104 &
+0,0000\tabularnewline
+5 & 70 \% & 0 \% & 10 \% & 10 \% & 10 \% & 7,0696 &
+0,4592\tabularnewline
+6 & 20 \% & 50 \% & 10 \% & 10 \% & 10 \% & 7,0034 &
+0,3930\tabularnewline
+\bottomrule
+\end{longtable*}
+
+At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd
+gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem
+ipsum dolor sit amet, consetetur sadipscing elitr.
+
+\subsection{Image with Caption}\label{image-with-caption}
+
+\begin{figure}[H]
+
+{\centering \pandocbounded{\includegraphics[keepaspectratio]{inst/images-and-tables/image.png}}
+
+}
+
+\caption{Nam liber tempor cum soluta nobis eleifend option congue nihil
+imperdiet doming id quod mazim placerat facer possim assum. Lorem ipsum
+dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh
+euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.}
+
+\end{figure}%
+
+\subsection{Markdown Table without
+Caption}\label{markdown-table-without-caption}
+
+Lorem markdownum Letoia, et alios: figurae flectentem annis aliquid
+Peneosque abesse, obstat gravitate. Obscura atque coniuge, per de
+coniunx, sibi medias commentaque virgine anima tamen comitemque petis,
+sed. In Amphion vestros hamos ire arceor mandere spicula, in licet
+aliquando.
+
+\begin{longtable}[]{@{}
+ >{\raggedright\arraybackslash}p{(\linewidth - 14\tabcolsep) * \real{0.1250}}
+ >{\raggedright\arraybackslash}p{(\linewidth - 14\tabcolsep) * \real{0.1250}}
+ >{\raggedright\arraybackslash}p{(\linewidth - 14\tabcolsep) * \real{0.1250}}
+ >{\raggedright\arraybackslash}p{(\linewidth - 14\tabcolsep) * \real{0.1250}}
+ >{\raggedright\arraybackslash}p{(\linewidth - 14\tabcolsep) * \real{0.1250}}
+ >{\raggedright\arraybackslash}p{(\linewidth - 14\tabcolsep) * \real{0.1250}}
+ >{\raggedright\arraybackslash}p{(\linewidth - 14\tabcolsep) * \real{0.1250}}
+ >{\raggedright\arraybackslash}p{(\linewidth - 14\tabcolsep) * \real{0.1250}}@{}}
+\toprule\noalign{}
+\begin{minipage}[b]{\linewidth}\raggedright
+Test Nr.
+\end{minipage} & \begin{minipage}[b]{\linewidth}\raggedright
+Position
+\end{minipage} & \begin{minipage}[b]{\linewidth}\raggedright
+Radius
+\end{minipage} & \begin{minipage}[b]{\linewidth}\raggedright
+Rot
+\end{minipage} & \begin{minipage}[b]{\linewidth}\raggedright
+Grün
+\end{minipage} & \begin{minipage}[b]{\linewidth}\raggedright
+Blau
+\end{minipage} & \begin{minipage}[b]{\linewidth}\raggedright
+beste Fitness
+\end{minipage} & \begin{minipage}[b]{\linewidth}\raggedright
+Abweichung
+\end{minipage} \\
+\midrule\noalign{}
+\endhead
+\bottomrule\noalign{}
+\endlastfoot
+1 & 20 \% & 20 \% & 20 \% & 20 \% & 20 \% & 7,5219 & 0,9115 \\
+2 & 0 \% & 25 \% & 25 \% & 25 \% & 25 \% & 8,0566 & 1,4462 \\
+3 & 0 \% & 0 \% & 33 \% & 33 \% & 33 \% & 8,7402 & 2,1298 \\
+4 & 50 \% & 20 \% & 10 \% & 10 \% & 10 \% & 6,6104 & 0,0000 \\
+5 & 70 \% & 0 \% & 10 \% & 10 \% & 10 \% & 7,0696 & 0,4592 \\
+6 & 20 \% & 50 \% & 10 \% & 10 \% & 10 \% & 7,0034 & 0,3930 \\
+7 & 40 \% & 15 \% & 15 \% & 15 \% & 15 \% & 6,9122 & 0,3018 \\
+\end{longtable}
+
+Porrigitur et Pallas nuper longusque cratere habuisse sepulcro pectore
+fertur. Laudat ille auditi; vertitur iura tum nepotis causa; motus. Diva
+virtus! Acrota destruitis vos iubet quo et classis excessere Scyrumve
+spiro subitusque mente Pirithoi abstulit, lapides.
+
+\subsection{Image without Caption}\label{image-without-caption}
+
+\pandocbounded{\includegraphics[keepaspectratio]{inst/images-and-tables/image.png}}
+
+\end{document}
diff --git a/_extensions/drwater/dwev/demo/language-chinese.qmd b/_extensions/drwater/dwev/demo/language-chinese.qmd
new file mode 100644
index 0000000..ea6665a
--- /dev/null
+++ b/_extensions/drwater/dwev/demo/language-chinese.qmd
@@ -0,0 +1,52 @@
+---
+title: "価備手述改陸夜数木田了転由。"
+author: [作者日期]
+date: "2019-01-10"
+subject: "Markdown"
+keywords: [Markdown, Example]
+lang: zh-CN
+svg: true
+fig-pos: "!t"
+colorlinks: true
+urlcolor: blue
+sansfont: "Gill Sans"
+sansfontoptions:
+ - Color=39729E
+mainfont: "Source Sans 3" #| Verdana (fontsize: 11pt) # Source Sans 3 | Times New Roman| Helvetica | PT Sans
+monofont: "JetBrains Mono"
+mathfont: "Cambria Math"
+CJKmainfont: "Noto Serif CJK SC"
+CJKsansfont: "Noto Sans CJK SC"
+CJKmonofont: "Noto Sans Mono CJK SC"
+# 确保中文标点符号正确处理
+CJKoptions: |
+ AutoFakeBold=true
+format: dwev-pdf
+---
+
+# 陣委百三秋康経重示面合雪減背井足府迷根間。
+
+陣委百三秋康経重示面合雪減背井足府迷根間。米式十良提馬紀研園要中募用刊。考稿協中写万捜寄三誠女文惑応担。動忍負陣表要回厳盛質属全任。意渡稿針当京注合在成唱皇月諸感丘売。業暮題武同海変公飯伝習真質期込者。読性聞点社質求庫勢応系飛。読有約求不政球県台却観展明来連使。暗双属場證北日増吉望団私録写日奈惑紙。
+
+賞方広選付疑京将主豊祉歳兆。亮行災視民信軒全太当刑際大。設紙校系顔実困講将用求年作。禁査調線無聞銅案性約会有整兄名城敬番棋。催題趣蔵今権全演権専治整。記査調埼毎断読犬石川年実作問情設情経。地面観参軽地多愛提帯瀬面側天側。価備手述改陸夜数木田了転由。上転為護吾載何研防著取足調出声的与歯。
+
+
+```{r}
+"asdfads阿斯顿发斯蒂芬"
+```
+
+
+
+## 参街能業南達伊市無百兆無聞手覧常努団他。
+
+参街能業南達伊市無百兆無聞手覧常努団他。応臨覧処面板施盛会同交展安期。善無継東約知紙地言展掲世起都幕紙仕。配稿理第心酸知月勝庭上図真全。本顕品毎信稿蓄秀神池課道。空米打資級油週報白受支写住文科権初航逮政。売打込箕長陳雪択選男真庭。改取確育迎田袴者豊尾京毎景終彦思。意試役能五子込宙転知校細。内速排索医林経一応係古測辺水。
+
+紋正介市及早拒木霊記済複治中。了岐都援盛手価民選覧必庭温背木済円力治。年生算純投器小市系統出字明稚喫部秘集。背伝歳適虫解無集園意明属賞方社件。公紹情高無主考全度監授掲。三退新田面封一基会功康売詳夜増義芸。特積夫紀北赤子演載識顔産済再測質。新岐張年読原体畑住郎門当合止吹士天意藤。明延立派購新政医士定速農。
+
+神図先名当揃存工紙広渡民晩記各面得続告増。将枝素実更造藤胞界投健記室申張講訴。店裁山党手政者校訓会清終定浪案。普大的比将響認経変度与合兄退景意経。歌池京割覧製断訳載割写載女作想用魂覚申。舞夜負亡古特在事準催進不全先自代上業後者。学上育手係真最芋本代定作供下能読分。
+
+- 汁酬英性向竹室比著給稿刻学年機稿生写。投面記偏回必写際著危女競林思。対事管現馬打能夜月顧身最恵共谷盟社必出。事退問更理併裏少切写禁権丁金提限最写求。者打記舎作馬研作辞家地子無遠者情島。諸井訓団取転燃大広応毎断略並。力持極業育権者住今展線際玉。集政謙期伝変争一他拉方海話連委下混必。囲渡園早位形量英酒椅食始発児政。
+- 年京船装街論初維器送遂考都連。携訪後細断点洋再説月間必道休光事築河。聞直電原竹銭報発興埼校球米口暮定奨重芸聞。京和使検聞服運加航認著著真技事実。弘断機試勢感金換稼治山谷皇真人肥霧。夜需崎影書属葉総登抜見発養内日現際園。場小行評歳映徹浸力政中募暮日朝金子武東。映申地換方無次記暮動練供事惑部意喜半戦壇。
+- 勝技枝図辞決受温見会図休自意少帰質者栄。務単時幹典盟園先入販江紀聞択色務。逮人覇品努博関復際部給体寛明理。限袖住教催広州係響体回接決治過銀。世提応枝録少説営援紙遠勤災宿。試電重捕切譜練治真戦将東。在最真休治義地杉調掲参親平。必整能怒哲希存雪注気付終表転県横隊早。覧教夕徹八学然害犬米無調億立図平受受位編。
+
+昌手挨一主要入削禁図送無高慕収後毎投業。感心台観道際町存更団打目今。生記投報重東点回際護高田独東。球野技検業大芸聞共最集飛禁。無黄手著凱縮産総智幕配示。名旧合提丼畿幅間任問場投悪変団。津地全真罪禁友容崩図新足連問完。域勲市録関写気意傷遣米安極漢。個疑調尾陸能案相浮接格校田新本下能。日銭信茶岡実締繰先分読独娘製商損真情。
diff --git a/_extensions/drwater/dwev/demo/language-german.qmd b/_extensions/drwater/dwev/demo/language-german.qmd
new file mode 100644
index 0000000..55ca7d1
--- /dev/null
+++ b/_extensions/drwater/dwev/demo/language-german.qmd
@@ -0,0 +1,58 @@
+---
+title: "Vinaque sanguine metuenti cuiquam Alcyone fixus"
+author: [Author Name]
+date: "2017-02-20"
+subject: "Markdown"
+keywords: [Markdown, Example]
+lang: "de"
+format: dwev-pdf
+---
+
+# Vinaque sanguine metuenti cuiquam Alcyone fixus
+
+## Aesculeae domus vincemur et Veneris adsuetus lapsum
+
+Lorem markdownum Letoia, et alios: figurae flectentem annis aliquid Peneosque ab
+esse, obstat gravitate. Obscura atque coniuge, per de coniunx, sibi **medias
+commentaque virgine** anima tamen comitemque petis, sed. In Amphion vestros
+hamos ire arceor mandere spicula, in licet aliquando.
+
+```java
+public class Example implements LoremIpsum {
+ public static void main(String[] args) {
+ if(args.length < 2) {
+ System.out.println("Lorem ipsum dolor sit amet");
+ }
+ } // Obscura atque coniuge, per de coniunx
+}
+```
+
+Porrigitur et Pallas nuper longusque cratere habuisse sepulcro pectore fertur.
+Laudat ille auditi; vertitur iura tum nepotis causa; motus. Diva virtus! Acrota
+destruitis vos iubet quo et classis excessere Scyrumve spiro subitusque mente
+Pirithoi abstulit, lapides.
+
+## Lydia caelo recenti haerebat lacerum ratae at
+
+Te concepit pollice fugit vias alumno **oras** quam potest
+[rursus](http://example.com#rursus) optat. Non evadere orbem equorum, spatiis,
+vel pede inter si.
+
+1. De neque iura aquis
+2. Frangitur gaudia mihi eo umor terrae quos
+3. Recens diffudit ille tantum
+
+\begin{equation}\label{eq:neighbor-propability}
+ p_{ij}(t) = \frac{\ell_j(t) - \ell_i(t)}{\sum_{k \in N_i(t)}^{} \ell_k(t) - \ell_i(t)}
+\end{equation}
+
+Tamen condeturque saxa Pallorque num et ferarum promittis inveni lilia iuvencae
+adessent arbor. Florente perque at condeturque saxa et ferarum promittis tendebat. Armos nisi obortas refugit me.
+
+Et nepotes poterat, se qui. Euntem ego pater desuetaque aethera Maeandri, et
+[Dardanio geminaque](http://example.com#Dardanio_geminaque) cernit. Lassaque poenas
+nec, manifesta $\pi r^2$ mirantia captivarum prohibebant scelerato gradus unusque
+dura.
+
+- Permulcens flebile simul
+- Iura tum nepotis causa motus diva virtus Acrota. Tamen condeturque saxa Pallorque num et ferarum promittis inveni lilia iuvencae adessent arbor. Florente perque at ire arcum.
\ No newline at end of file
diff --git a/_extensions/drwater/dwev/demo/language-japanese.qmd b/_extensions/drwater/dwev/demo/language-japanese.qmd
new file mode 100644
index 0000000..7932964
--- /dev/null
+++ b/_extensions/drwater/dwev/demo/language-japanese.qmd
@@ -0,0 +1,33 @@
+---
+title: "よ派にへたひ素ヘムナフュてるあてっはれねね区露。巣擢"
+author: [むて絵ヤイヤ手津絵]
+date: "2017-02-20"
+subject: "Markdown"
+keywords: [Markdown, Example]
+format: dwev-pdf
+---
+
+# よ派にへたひ素ヘムナフュてるあてっはれねね区露。巣擢
+
+
+もに氏留列阿ゃけんリヌョソュろまけやほこまネクフコテユうめね瀬雲舳目ょ舳鵜みやいみま。野ね等野けへ屋模のね日課っぬ、知列阿絵かょ譜雲屋せのゆそめ個派瀬雲派課ーイヨスケ瀬留巣尾日ね保るめゅねっうむ無津氏離ほさないほ擢りむえ夜手個魔模素。
+
+よ派にへたひ素ヘムナフュてるあてっはれねね区露。巣擢。むて絵ヤイヤ手津絵舳ふち屋区根っクキオ氏露すムフヘゅ二遊むねれみらなまそ瀬ぬゆたヘクアウはてとしまる知。
+
+むゆくら雲津手都あもは日遊れりゅへらっ日保留鵜絵す。の露日無ゆ遊二日りスツ毛留御遊擢御無模無ょやゆ樹毛阿留等、樹ルキテひょとて区列屋。うかるゃええま二擢きかしあんつ擢、っさく遊手名区列手ウヌマ区根以擢模擢素けせのれひんほおはよこふきなろ樹舳野尾尾ゃほふ列擢瀬舳名個区等こに名津、根夜、お。ろやほ保素根列らゆやしえろむっンサハラオ。
+
+## とほ知他え目絵樹せ津素舳雲巣魔氏派夜列魔
+
+まの課譜都手、やいゆぬてほめてよかおそふおょこ尾夜く阿差課根ぬナヒメケ舳二しけやろこち譜は巣津やれま、ネョセカあきあメシみ根根るあ、ろへ離都課ろうらくぬさにせぬ尾模等せ樹魔いそょ毛もし御名氏知。
+
+課瀬毛御都列ヒャマナカフモ絵区区遊譜ほ、ほすゃもキウぬノサクサめろそなる他他津ふまお、譜阿手派夜っ他個かたか舳鵜日魔日雲派二離、にひ巣氏めすおひふめへな区っ鵜名瀬むう。ヨツミメ区素他都めすそか課区なうよ以遊へ。いり他譜けっへつ。保阿模野列魔てえ。以区素。
+
+離擢留舳区クツコこつろと魔、ょもさよ尾うとほ知他え目絵樹せ津素舳雲巣魔氏派夜列魔氏絵夜課阿ふ知知区擢魔野さうにりよりうゅ個課列野ゃす毛二絵手ぬえ派尾樹屋夜。夜絵毛毛すりおいし遊手夜毛無とゆ瀬野毛名個ふふえゃ無都名無他氏等ふこたも。
+
+以たろきお都ゆし阿列鵜擢おんか、ッロマオゅ露他野列せ譜模ョー鵜尾野手毛素、ひす素野ろ氏御氏屋ほはもらりむふ離個とろいそつむ差手こつけっとへせっ。りぬ目無舳めむや離離ょほんく阿せえのんやや離雲雲魔はゃれひ。りそさ無阿樹さかん屋絵氏、つ区差。しレヨオキホテゆもお尾巣けのすもめきむやひけ。尾御津区列列課都雲り樹めぬやむては、舳名夜ッラチユ列都、保露、魔鵜。
+
+1. りぬ目無舳めむや離離ょほんく阿せえのんやや離雲雲魔はゃれひ。りそさ無阿樹さかん屋絵氏、つ区差。しレヨオキホテゆもお
+2. へ舳列っに「屋素留御以根」露派差離鵜けきうっ雲目以ナシ。日氏すゅともむ樹留素ふりう氏日夜れと
+3. 他根かかぬ、くきれみけおへえほん保派絵くけよ譜モヌッアアウカ留譜絵目課離根以名阿さ樹他クッカクラ無課課瀬めつ列氏課そ目知屋舳手らへ舳列っに「屋素留御以根」露派差離鵜けきうっ雲目以ナシ。日氏すゅともむ樹留素ふりう氏日夜れとせさ鵜知めっゃ瀬露めゅむに遊雲舳野ひひよやめほくさめう舳名都とにてめは無めもはすにちひ遊モシルもねたらやょや。知以ほ以名さきにまむろせちょったか毛御差巣夜氏、きまむこ列模模阿。
+
+阿瀬鵜屋さねや、う他列舳ヤマりれえんか、尾瀬カコノヒ名課巣鵜津せやおひく知二保手、そ派毛遊へろへよ。みす派毛はうよ樹二御派派等メノコせ区さ巣屋名のせ野毛。
\ No newline at end of file
diff --git a/_extensions/drwater/dwev/demo/page-background.qmd b/_extensions/drwater/dwev/demo/page-background.qmd
new file mode 100644
index 0000000..8172385
--- /dev/null
+++ b/_extensions/drwater/dwev/demo/page-background.qmd
@@ -0,0 +1,60 @@
+---
+title: "Vinaque sanguine metuenti cuiquam Alcyone fixus"
+author: [Author Name]
+date: "2017-02-20"
+subject: "Markdown"
+keywords: [Markdown, Example]
+subtitle: "Aesculeae domus vincemur et Veneris adsuetus lapsum"
+lang: "en"
+page-background: "inst/page-background/backgrounds/background1.pdf"
+format: dwev-pdf
+---
+
+# Vinaque sanguine metuenti cuiquam Alcyone fixus
+
+## Aesculeae domus vincemur et Veneris adsuetus lapsum
+
+Lorem markdownum Letoia, et alios: figurae flectentem annis aliquid Peneosque ab
+esse, obstat gravitate. Obscura atque coniuge, per de coniunx, sibi **medias
+commentaque virgine** anima tamen comitemque petis, sed. In Amphion vestros
+hamos ire arceor mandere spicula, in licet aliquando.
+
+```java
+public class Example implements LoremIpsum {
+ public static void main(String[] args) {
+ if(args.length < 2) {
+ System.out.println("Lorem ipsum dolor sit amet");
+ }
+ } // Obscura atque coniuge, per de coniunx
+}
+```
+
+Porrigitur et Pallas nuper longusque cratere habuisse sepulcro pectore fertur.
+Laudat ille auditi; vertitur iura tum nepotis causa; motus. Diva virtus! Acrota
+destruitis vos iubet quo et classis excessere Scyrumve spiro subitusque mente
+Pirithoi abstulit, lapides.
+
+## Lydia caelo recenti haerebat lacerum ratae at
+
+Te concepit pollice fugit vias alumno **oras** quam potest
+[rursus](http://example.com#rursus) optat. Non evadere orbem equorum, spatiis,
+vel pede inter si.
+
+1. De neque iura aquis
+2. Frangitur gaudia mihi eo umor terrae quos
+3. Recens diffudit ille tantum
+
+\begin{equation}\label{eq:neighbor-propability}
+ p_{ij}(t) = \frac{\ell_j(t) - \ell_i(t)}{\sum_{k \in N_i(t)}^{} \ell_k(t) - \ell_i(t)}
+\end{equation}
+
+Tamen condeturque saxa Pallorque num et ferarum promittis inveni lilia iuvencae
+adessent arbor. Florente perque at condeturque saxa et ferarum promittis tendebat. Armos nisi obortas refugit me.
+
+Et nepotes poterat, se qui. Euntem ego pater desuetaque aethera Maeandri, et
+[Dardanio geminaque](http://example.com#Dardanio_geminaque) cernit. Lassaque poenas
+nec, manifesta $\pi r^2$ mirantia captivarum prohibebant scelerato gradus unusque
+dura.
+
+- Permulcens flebile simul
+- Iura tum nepotis causa motus diva virtus Acrota. Tamen condeturque saxa Pallorque num et ferarum promittis inveni lilia iuvencae adessent arbor. Florente perque at ire arcum.
diff --git a/_extensions/drwater/dwev/demo/table-of-contents.qmd b/_extensions/drwater/dwev/demo/table-of-contents.qmd
new file mode 100644
index 0000000..9ff46e1
--- /dev/null
+++ b/_extensions/drwater/dwev/demo/table-of-contents.qmd
@@ -0,0 +1,60 @@
+---
+title: "Example PDF"
+author: [Author]
+date: "2022-03-04"
+subject: "Markdown"
+keywords: [Markdown, Example]
+lang: "en"
+toc: true
+toc-own-page: true
+format: dwev-pdf
+---
+
+# Vinaque sanguine metuenti cuiquam Alcyone fixus
+
+## Aesculeae domus vincemur et Veneris adsuetus lapsum
+
+Lorem markdownum Letoia, et alios: figurae flectentem annis aliquid Peneosque ab
+esse, obstat gravitate. Obscura atque coniuge, per de coniunx, sibi **medias
+commentaque virgine** anima tamen comitemque petis, sed. In Amphion vestros
+hamos ire arceor mandere spicula, in licet aliquando.
+
+```java
+public class Example implements LoremIpsum {
+ public static void main(String[] args) {
+ if(args.length < 2) {
+ System.out.println("Lorem ipsum dolor sit amet");
+ }
+ } // Obscura atque coniuge, per de coniunx
+}
+```
+
+Porrigitur et Pallas nuper longusque cratere habuisse sepulcro pectore fertur.
+Laudat ille auditi; vertitur iura tum nepotis causa; motus. Diva virtus! Acrota
+destruitis vos iubet quo et classis excessere Scyrumve spiro subitusque mente
+Pirithoi abstulit, lapides.
+
+## Lydia caelo recenti haerebat lacerum ratae at
+
+Te concepit pollice fugit vias alumno **oras** quam potest
+[rursus](http://example.com#rursus) optat. Non evadere orbem equorum, spatiis,
+vel pede inter si.
+
+1. De neque iura aquis
+2. Frangitur gaudia mihi eo umor terrae quos
+3. Recens diffudit ille tantum
+
+\begin{equation}\label{eq:neighbor-propability}
+ p_{ij}(t) = \frac{\ell_j(t) - \ell_i(t)}{\sum_{k \in N_i(t)}^{} \ell_k(t) - \ell_i(t)}
+\end{equation}
+
+Tamen condeturque saxa Pallorque num et ferarum promittis inveni lilia iuvencae
+adessent arbor. Florente perque at condeturque saxa et ferarum promittis tendebat. Armos nisi obortas refugit me.
+
+> Et nepotes poterat, se qui. Euntem ego pater desuetaque aethera Maeandri, et
+[Dardanio geminaque](http://example.com#Dardanio_geminaque) cernit. Lassaque poenas
+nec, manifesta $\pi r^2$ mirantia captivarum prohibebant scelerato gradus unusque
+dura.
+
+- Permulcens flebile simul
+- Iura tum nepotis causa motus diva virtus Acrota. Tamen condeturque saxa Pallorque num et ferarum promittis inveni lilia iuvencae adessent arbor. Florente perque at ire arcum.
\ No newline at end of file
diff --git a/_extensions/drwater/dwev/demo/title-page-background.qmd b/_extensions/drwater/dwev/demo/title-page-background.qmd
new file mode 100644
index 0000000..15cc07d
--- /dev/null
+++ b/_extensions/drwater/dwev/demo/title-page-background.qmd
@@ -0,0 +1,62 @@
+---
+title: "Vinaque sanguine metuenti cuiquam Alcyone fixus"
+author: [Author Name]
+date: "2017-02-20"
+subject: "Markdown"
+keywords: [Markdown, Example]
+subtitle: "Aesculeae domus vincemur et Veneris adsuetus lapsum"
+lang: "en"
+titlepage: true,
+titlepage-rule-color: "360049"
+titlepage-background: "inst/title-page-background/backgrounds/background1.pdf"
+format: dwev-pdf
+---
+
+# Vinaque sanguine metuenti cuiquam Alcyone fixus
+
+## Aesculeae domus vincemur et Veneris adsuetus lapsum
+
+Lorem markdownum Letoia, et alios: figurae flectentem annis aliquid Peneosque ab
+esse, obstat gravitate. Obscura atque coniuge, per de coniunx, sibi **medias
+commentaque virgine** anima tamen comitemque petis, sed. In Amphion vestros
+hamos ire arceor mandere spicula, in licet aliquando.
+
+```java
+public class Example implements LoremIpsum {
+ public static void main(String[] args) {
+ if(args.length < 2) {
+ System.out.println("Lorem ipsum dolor sit amet");
+ }
+ } // Obscura atque coniuge, per de coniunx
+}
+```
+
+Porrigitur et Pallas nuper longusque cratere habuisse sepulcro pectore fertur.
+Laudat ille auditi; vertitur iura tum nepotis causa; motus. Diva virtus! Acrota
+destruitis vos iubet quo et classis excessere Scyrumve spiro subitusque mente
+Pirithoi abstulit, lapides.
+
+## Lydia caelo recenti haerebat lacerum ratae at
+
+Te concepit pollice fugit vias alumno **oras** quam potest
+[rursus](http://example.com#rursus) optat. Non evadere orbem equorum, spatiis,
+vel pede inter si.
+
+1. De neque iura aquis
+2. Frangitur gaudia mihi eo umor terrae quos
+3. Recens diffudit ille tantum
+
+\begin{equation}\label{eq:neighbor-propability}
+ p_{ij}(t) = \frac{\ell_j(t) - \ell_i(t)}{\sum_{k \in N_i(t)}^{} \ell_k(t) - \ell_i(t)}
+\end{equation}
+
+Tamen condeturque saxa Pallorque num et ferarum promittis inveni lilia iuvencae
+adessent arbor. Florente perque at condeturque saxa et ferarum promittis tendebat. Armos nisi obortas refugit me.
+
+Et nepotes poterat, se qui. Euntem ego pater desuetaque aethera Maeandri, et
+[Dardanio geminaque](http://example.com#Dardanio_geminaque) cernit. Lassaque poenas
+nec, manifesta $\pi r^2$ mirantia captivarum prohibebant scelerato gradus unusque
+dura.
+
+- Permulcens flebile simul
+- Iura tum nepotis causa motus diva virtus Acrota. Tamen condeturque saxa Pallorque num et ferarum promittis inveni lilia iuvencae adessent arbor. Florente perque at ire arcum.
diff --git a/_extensions/drwater/dwev/demo/title-page-custom.qmd b/_extensions/drwater/dwev/demo/title-page-custom.qmd
new file mode 100644
index 0000000..4cad5ba
--- /dev/null
+++ b/_extensions/drwater/dwev/demo/title-page-custom.qmd
@@ -0,0 +1,64 @@
+---
+title: "Vinaque sanguine metuenti cuiquam Alcyone fixus"
+author: [Author Name]
+date: "2017-02-20"
+subject: "Markdown"
+keywords: [Markdown, Example]
+subtitle: "Aesculeae domus vincemur et Veneris adsuetus lapsum"
+lang: "en"
+titlepage: true,
+titlepage-text-color: "FFFFFF"
+titlepage-rule-color: "360049"
+titlepage-rule-height: 0
+titlepage-background: "inst/title-page-custom/background.pdf"
+format: dwev-pdf
+---
+
+# Vinaque sanguine metuenti cuiquam Alcyone fixus
+
+## Aesculeae domus vincemur et Veneris adsuetus lapsum
+
+Lorem markdownum Letoia, et alios: figurae flectentem annis aliquid Peneosque ab
+esse, obstat gravitate. Obscura atque coniuge, per de coniunx, sibi **medias
+commentaque virgine** anima tamen comitemque petis, sed. In Amphion vestros
+hamos ire arceor mandere spicula, in licet aliquando.
+
+```java
+public class Example implements LoremIpsum {
+ public static void main(String[] args) {
+ if(args.length < 2) {
+ System.out.println("Lorem ipsum dolor sit amet");
+ }
+ } // Obscura atque coniuge, per de coniunx
+}
+```
+
+Porrigitur et Pallas nuper longusque cratere habuisse sepulcro pectore fertur.
+Laudat ille auditi; vertitur iura tum nepotis causa; motus. Diva virtus! Acrota
+destruitis vos iubet quo et classis excessere Scyrumve spiro subitusque mente
+Pirithoi abstulit, lapides.
+
+## Lydia caelo recenti haerebat lacerum ratae at
+
+Te concepit pollice fugit vias alumno **oras** quam potest
+[rursus](http://example.com#rursus) optat. Non evadere orbem equorum, spatiis,
+vel pede inter si.
+
+1. De neque iura aquis
+2. Frangitur gaudia mihi eo umor terrae quos
+3. Recens diffudit ille tantum
+
+\begin{equation}\label{eq:neighbor-propability}
+ p_{ij}(t) = \frac{\ell_j(t) - \ell_i(t)}{\sum_{k \in N_i(t)}^{} \ell_k(t) - \ell_i(t)}
+\end{equation}
+
+Tamen condeturque saxa Pallorque num et ferarum promittis inveni lilia iuvencae
+adessent arbor. Florente perque at condeturque saxa et ferarum promittis tendebat. Armos nisi obortas refugit me.
+
+Et nepotes poterat, se qui. Euntem ego pater desuetaque aethera Maeandri, et
+[Dardanio geminaque](http://example.com#Dardanio_geminaque) cernit. Lassaque poenas
+nec, manifesta $\pi r^2$ mirantia captivarum prohibebant scelerato gradus unusque
+dura.
+
+- Permulcens flebile simul
+- Iura tum nepotis causa motus diva virtus Acrota. Tamen condeturque saxa Pallorque num et ferarum promittis inveni lilia iuvencae adessent arbor. Florente perque at ire arcum.
diff --git a/_extensions/drwater/dwev/demo/title-page-default.qmd b/_extensions/drwater/dwev/demo/title-page-default.qmd
new file mode 100644
index 0000000..fc33703
--- /dev/null
+++ b/_extensions/drwater/dwev/demo/title-page-default.qmd
@@ -0,0 +1,60 @@
+---
+title: "Vinaque sanguine metuenti cuiquam Alcyone fixus"
+author: [Author Name]
+date: "2017-02-20"
+subject: "Markdown"
+keywords: [Markdown, Example]
+subtitle: "Aesculeae domus vincemur et Veneris adsuetus lapsum"
+lang: "en"
+titlepage: true
+format: dwev-pdf
+---
+
+# Vinaque sanguine metuenti cuiquam Alcyone fixus
+
+## Aesculeae domus vincemur et Veneris adsuetus lapsum
+
+Lorem markdownum Letoia, et alios: figurae flectentem annis aliquid Peneosque ab
+esse, obstat gravitate. Obscura atque coniuge, per de coniunx, sibi **medias
+commentaque virgine** anima tamen comitemque petis, sed. In Amphion vestros
+hamos ire arceor mandere spicula, in licet aliquando.
+
+```java
+public class Example implements LoremIpsum {
+ public static void main(String[] args) {
+ if(args.length < 2) {
+ System.out.println("Lorem ipsum dolor sit amet");
+ }
+ } // Obscura atque coniuge, per de coniunx
+}
+```
+
+Porrigitur et Pallas nuper longusque cratere habuisse sepulcro pectore fertur.
+Laudat ille auditi; vertitur iura tum nepotis causa; motus. Diva virtus! Acrota
+destruitis vos iubet quo et classis excessere Scyrumve spiro subitusque mente
+Pirithoi abstulit, lapides.
+
+## Lydia caelo recenti haerebat lacerum ratae at
+
+Te concepit pollice fugit vias alumno **oras** quam potest
+[rursus](http://example.com#rursus) optat. Non evadere orbem equorum, spatiis,
+vel pede inter si.
+
+1. De neque iura aquis
+2. Frangitur gaudia mihi eo umor terrae quos
+3. Recens diffudit ille tantum
+
+\begin{equation}\label{eq:neighbor-propability}
+ p_{ij}(t) = \frac{\ell_j(t) - \ell_i(t)}{\sum_{k \in N_i(t)}^{} \ell_k(t) - \ell_i(t)}
+\end{equation}
+
+Tamen condeturque saxa Pallorque num et ferarum promittis inveni lilia iuvencae
+adessent arbor. Florente perque at condeturque saxa et ferarum promittis tendebat. Armos nisi obortas refugit me.
+
+Et nepotes poterat, se qui. Euntem ego pater desuetaque aethera Maeandri, et
+[Dardanio geminaque](http://example.com#Dardanio_geminaque) cernit. Lassaque poenas
+nec, manifesta $\pi r^2$ mirantia captivarum prohibebant scelerato gradus unusque
+dura.
+
+- Permulcens flebile simul
+- Iura tum nepotis causa motus diva virtus Acrota. Tamen condeturque saxa Pallorque num et ferarum promittis inveni lilia iuvencae adessent arbor. Florente perque at ire arcum.
\ No newline at end of file
diff --git a/_extensions/drwater/dwev/demo/title-page-green.qmd b/_extensions/drwater/dwev/demo/title-page-green.qmd
new file mode 100644
index 0000000..2e64412
--- /dev/null
+++ b/_extensions/drwater/dwev/demo/title-page-green.qmd
@@ -0,0 +1,64 @@
+---
+title: "Vinaque sanguine metuenti cuiquam Alcyone fixus"
+author: [Author Name]
+date: "2017-02-20"
+subject: "Markdown"
+keywords: [Markdown, Example]
+subtitle: "Aesculeae domus vincemur et Veneris adsuetus lapsum"
+lang: "en"
+titlepage: true
+titlepage-color: "3C9F53"
+titlepage-text-color: "FFFFFF"
+titlepage-rule-color: "FFFFFF"
+titlepage-rule-height: 2
+format: dwev-pdf
+---
+
+# Vinaque sanguine metuenti cuiquam Alcyone fixus
+
+## Aesculeae domus vincemur et Veneris adsuetus lapsum
+
+Lorem markdownum Letoia, et alios: figurae flectentem annis aliquid Peneosque ab
+esse, obstat gravitate. Obscura atque coniuge, per de coniunx, sibi **medias
+commentaque virgine** anima tamen comitemque petis, sed. In Amphion vestros
+hamos ire arceor mandere spicula, in licet aliquando.
+
+```java
+public class Example implements LoremIpsum {
+ public static void main(String[] args) {
+ if(args.length < 2) {
+ System.out.println("Lorem ipsum dolor sit amet");
+ }
+ } // Obscura atque coniuge, per de coniunx
+}
+```
+
+Porrigitur et Pallas nuper longusque cratere habuisse sepulcro pectore fertur.
+Laudat ille auditi; vertitur iura tum nepotis causa; motus. Diva virtus! Acrota
+destruitis vos iubet quo et classis excessere Scyrumve spiro subitusque mente
+Pirithoi abstulit, lapides.
+
+## Lydia caelo recenti haerebat lacerum ratae at
+
+Te concepit pollice fugit vias alumno **oras** quam potest
+[rursus](http://example.com#rursus) optat. Non evadere orbem equorum, spatiis,
+vel pede inter si.
+
+1. De neque iura aquis
+2. Frangitur gaudia mihi eo umor terrae quos
+3. Recens diffudit ille tantum
+
+\begin{equation}\label{eq:neighbor-propability}
+ p_{ij}(t) = \frac{\ell_j(t) - \ell_i(t)}{\sum_{k \in N_i(t)}^{} \ell_k(t) - \ell_i(t)}
+\end{equation}
+
+Tamen condeturque saxa Pallorque num et ferarum promittis inveni lilia iuvencae
+adessent arbor. Florente perque at condeturque saxa et ferarum promittis tendebat. Armos nisi obortas refugit me.
+
+Et nepotes poterat, se qui. Euntem ego pater desuetaque aethera Maeandri, et
+[Dardanio geminaque](http://example.com#Dardanio_geminaque) cernit. Lassaque poenas
+nec, manifesta $\pi r^2$ mirantia captivarum prohibebant scelerato gradus unusque
+dura.
+
+- Permulcens flebile simul
+- Iura tum nepotis causa motus diva virtus Acrota. Tamen condeturque saxa Pallorque num et ferarum promittis inveni lilia iuvencae adessent arbor. Florente perque at ire arcum.
\ No newline at end of file
diff --git a/_extensions/drwater/dwev/demo/title-page-logo.qmd b/_extensions/drwater/dwev/demo/title-page-logo.qmd
new file mode 100644
index 0000000..000cd42
--- /dev/null
+++ b/_extensions/drwater/dwev/demo/title-page-logo.qmd
@@ -0,0 +1,65 @@
+---
+title: "Vinaque sanguine metuenti cuiquam Alcyone fixus"
+author: [Author Name]
+date: "2017-02-20"
+subject: "Markdown"
+keywords: [Markdown, Example]
+subtitle: "Aesculeae domus vincemur et Veneris adsuetus lapsum"
+lang: "en"
+titlepage: true
+titlepage-text-color: "7137C8"
+titlepage-rule-color: "7137C8"
+titlepage-rule-height: 2
+titlepage-logo: "inst/title-page-logo/logo.pdf"
+logo-width: 30mm
+format: dwev-pdf
+---
+
+# Vinaque sanguine metuenti cuiquam Alcyone fixus
+
+## Aesculeae domus vincemur et Veneris adsuetus lapsum
+
+Lorem markdownum Letoia, et alios: figurae flectentem annis aliquid Peneosque ab
+esse, obstat gravitate. Obscura atque coniuge, per de coniunx, sibi **medias
+commentaque virgine** anima tamen comitemque petis, sed. In Amphion vestros
+hamos ire arceor mandere spicula, in licet aliquando.
+
+```java
+public class Example implements LoremIpsum {
+ public static void main(String[] args) {
+ if(args.length < 2) {
+ System.out.println("Lorem ipsum dolor sit amet");
+ }
+ } // Obscura atque coniuge, per de coniunx
+}
+```
+
+Porrigitur et Pallas nuper longusque cratere habuisse sepulcro pectore fertur.
+Laudat ille auditi; vertitur iura tum nepotis causa; motus. Diva virtus! Acrota
+destruitis vos iubet quo et classis excessere Scyrumve spiro subitusque mente
+Pirithoi abstulit, lapides.
+
+## Lydia caelo recenti haerebat lacerum ratae at
+
+Te concepit pollice fugit vias alumno **oras** quam potest
+[rursus](http://example.com#rursus) optat. Non evadere orbem equorum, spatiis,
+vel pede inter si.
+
+1. De neque iura aquis
+2. Frangitur gaudia mihi eo umor terrae quos
+3. Recens diffudit ille tantum
+
+\begin{equation}\label{eq:neighbor-propability}
+ p_{ij}(t) = \frac{\ell_j(t) - \ell_i(t)}{\sum_{k \in N_i(t)}^{} \ell_k(t) - \ell_i(t)}
+\end{equation}
+
+Tamen condeturque saxa Pallorque num et ferarum promittis inveni lilia iuvencae
+adessent arbor. Florente perque at condeturque saxa et ferarum promittis tendebat. Armos nisi obortas refugit me.
+
+Et nepotes poterat, se qui. Euntem ego pater desuetaque aethera Maeandri, et
+[Dardanio geminaque](http://example.com#Dardanio_geminaque) cernit. Lassaque poenas
+nec, manifesta $\pi r^2$ mirantia captivarum prohibebant scelerato gradus unusque
+dura.
+
+- Permulcens flebile simul
+- Iura tum nepotis causa motus diva virtus Acrota. Tamen condeturque saxa Pallorque num et ferarum promittis inveni lilia iuvencae adessent arbor. Florente perque at ire arcum.
diff --git a/_extensions/drwater/dwev/dweisvogel.tex b/_extensions/drwater/dwev/dweisvogel.tex
new file mode 100644
index 0000000..50b9664
--- /dev/null
+++ b/_extensions/drwater/dwev/dweisvogel.tex
@@ -0,0 +1,1323 @@
+%%
+% Copyright (c) 2017 - 2024, Pascal Wagler;
+% Copyright (c) 2014 - 2024, John MacFarlane
+%
+% All rights reserved.
+%
+% Redistribution and use in source and binary forms, with or without
+% modification, are permitted provided that the following conditions
+% are met:
+%
+% - Redistributions of source code must retain the above copyright
+% notice, this list of conditions and the following disclaimer.
+%
+% - Redistributions in binary form must reproduce the above copyright
+% notice, this list of conditions and the following disclaimer in the
+% documentation and/or other materials provided with the distribution.
+%
+% - Neither the name of John MacFarlane nor the names of other
+% contributors may be used to endorse or promote products derived
+% from this software without specific prior written permission.
+%
+% THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+% "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+% LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+% FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+% COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+% INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+% BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+% LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+% CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+% LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
+% ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+% POSSIBILITY OF SUCH DAMAGE.
+%%
+
+%%
+% This is the Eisvogel pandoc LaTeX template.
+%
+% For usage information and examples visit the official GitHub page:
+% https://github.com/Wandmalfarbe/pandoc-latex-template
+%%
+
+% Options for packages loaded elsewhere
+\PassOptionsToPackage{unicode$for(hyperrefoptions)$,$hyperrefoptions$$endfor$}{hyperref}
+\PassOptionsToPackage{hyphens}{url}
+\PassOptionsToPackage{dvipsnames,svgnames,x11names,table}{xcolor}
+$if(CJKmainfont)$
+\PassOptionsToPackage{space}{xeCJK}
+$endif$
+%
+\documentclass[
+$if(fontsize)$
+ $fontsize$,
+$endif$
+$if(papersize)$
+ $papersize$paper,
+$else$
+ paper=a4,
+$endif$
+$if(beamer)$
+ ignorenonframetext,
+$if(handout)$
+ handout,
+$endif$
+$if(aspectratio)$
+ aspectratio=$aspectratio$,
+$endif$
+$if(babel-lang)$
+ $babel-lang$,
+$endif$
+$endif$
+$for(classoption)$
+ $classoption$$sep$,
+$endfor$
+ ,captions=tableheading
+]{$if(beamer)$$documentclass$$else$$if(isbook)$scrbook$else$scrartcl$endif$$endif$}
+$if(beamer)$
+$if(background-image)$
+\usebackgroundtemplate{%
+ \includegraphics[width=\paperwidth]{$background-image$}%
+}
+% In beamer background-image does not work well when other images are used, so this is the workaround
+\pgfdeclareimage[width=\paperwidth,height=\paperheight]{background}{$background-image$}
+\usebackgroundtemplate{\pgfuseimage{background}}
+$endif$
+
+\usepackage{pgfpages}
+\setbeamertemplate{caption}[numbered]
+\setbeamertemplate{caption label separator}{: }
+\setbeamercolor{caption name}{fg=normal text.fg}
+\beamertemplatenavigationsymbols$if(navigation)$$navigation$$else$empty$endif$
+$for(beameroption)$
+\setbeameroption{$beameroption$}
+$endfor$
+% Prevent slide breaks in the middle of a paragraph
+\widowpenalties 1 10000
+\raggedbottom
+$if(section-titles)$
+\setbeamertemplate{part page}{
+ \centering
+ \begin{beamercolorbox}[sep=16pt,center]{part title}
+ \usebeamerfont{part title}\insertpart\par
+ \end{beamercolorbox}
+}
+\setbeamertemplate{section page}{
+ \centering
+ \begin{beamercolorbox}[sep=12pt,center]{section title}
+ \usebeamerfont{section title}\insertsection\par
+ \end{beamercolorbox}
+}
+\setbeamertemplate{subsection page}{
+ \centering
+ \begin{beamercolorbox}[sep=8pt,center]{subsection title}
+ \usebeamerfont{subsection title}\insertsubsection\par
+ \end{beamercolorbox}
+}
+\AtBeginPart{
+ \frame{\partpage}
+}
+\AtBeginSection{
+ \ifbibliography
+ \else
+ \frame{\sectionpage}
+ \fi
+}
+\AtBeginSubsection{
+ \frame{\subsectionpage}
+}
+$endif$
+$endif$
+$if(beamerarticle)$
+\usepackage{beamerarticle} % needs to be loaded first
+$endif$
+\usepackage{amsmath,amssymb}
+$if(linestretch)$
+\usepackage{setspace}
+$else$
+% Use setspace anyway because we change the default line spacing.
+% The spacing is changed early to affect the titlepage and the TOC.
+\usepackage{setspace}
+\setstretch{1.2}
+$endif$
+\usepackage{iftex}
+\ifPDFTeX
+ \usepackage[$if(fontenc)$$fontenc$$else$T1$endif$]{fontenc}
+ \usepackage[utf8]{inputenc}
+ \usepackage{textcomp} % provide euro and other symbols
+\else % if luatex or xetex
+$if(mathspec)$
+ \ifXeTeX
+ \usepackage{mathspec} % this also loads fontspec
+ \else
+ \usepackage{unicode-math} % this also loads fontspec
+ \fi
+$else$
+ \usepackage{unicode-math} % this also loads fontspec
+$endif$
+ \defaultfontfeatures{Scale=MatchLowercase}$-- must come before Beamer theme
+ \defaultfontfeatures[\rmfamily]{Ligatures=TeX,Scale=1}
+\fi
+$if(fontfamily)$
+$else$
+$-- Set default font before Beamer theme so the theme can override it
+\usepackage{lmodern}
+$endif$
+$-- Set Beamer theme before user font settings so they can override theme
+$if(beamer)$
+$if(theme)$
+\usetheme[$for(themeoptions)$$themeoptions$$sep$,$endfor$]{$theme$}
+$endif$
+$if(colortheme)$
+\usecolortheme{$colortheme$}
+$endif$
+$if(fonttheme)$
+\usefonttheme{$fonttheme$}
+$endif$
+$if(mainfont)$
+\usefonttheme{serif} % use mainfont rather than sansfont for slide text
+$endif$
+$if(innertheme)$
+\useinnertheme{$innertheme$}
+$endif$
+$if(outertheme)$
+\useoutertheme{$outertheme$}
+$endif$
+$endif$
+$-- User font settings (must come after default font and Beamer theme)
+$if(fontfamily)$
+\usepackage[$for(fontfamilyoptions)$$fontfamilyoptions$$sep$,$endfor$]{$fontfamily$}
+$endif$
+\ifPDFTeX\else
+ % xetex/luatex font selection
+$if(mainfont)$
+ $if(mainfontfallback)$
+ \ifLuaTeX
+ \usepackage{luaotfload}
+ \directlua{luaotfload.add_fallback("mainfontfallback",{
+ $for(mainfontfallback)$"$mainfontfallback$"$sep$,$endfor$
+ })}
+ \fi
+ $endif$
+ \setmainfont[$for(mainfontoptions)$$mainfontoptions$$sep$,$endfor$$if(mainfontfallback)$,RawFeature={fallback=mainfontfallback}$endif$]{$mainfont$}
+$endif$
+$if(sansfont)$
+ $if(sansfontfallback)$
+ \ifLuaTeX
+ \usepackage{luaotfload}
+ \directlua{luaotfload.add_fallback("sansfontfallback",{
+ $for(sansfontfallback)$"$sansfontfallback$"$sep$,$endfor$
+ })}
+ \fi
+ $endif$
+ \setsansfont[$for(sansfontoptions)$$sansfontoptions$$sep$,$endfor$$if(sansfontfallback)$,RawFeature={fallback=sansfontfallback}$endif$]{$sansfont$}
+$endif$
+$if(monofont)$
+ $if(monofontfallback)$
+ \ifLuaTeX
+ \usepackage{luaotfload}
+ \directlua{luaotfload.add_fallback("monofontfallback",{
+ $for(monofontfallback)$"$monofontfallback$"$sep$,$endfor$
+ })}
+ \fi
+ $endif$
+ \setmonofont[$for(monofontoptions)$$monofontoptions$$sep$,$endfor$$if(monofontfallback)$,RawFeature={fallback=monofontfallback}$endif$]{$monofont$}
+$endif$
+$for(fontfamilies)$
+ \newfontfamily{$fontfamilies.name$}[$for(fontfamilies.options)$$fontfamilies.options$$sep$,$endfor$]{$fontfamilies.font$}
+$endfor$
+$if(mathfont)$
+$if(mathspec)$
+ \ifXeTeX
+ \setmathfont(Digits,Latin,Greek)[$for(mathfontoptions)$$mathfontoptions$$sep$,$endfor$]{$mathfont$}
+ \else
+ \setmathfont[$for(mathfontoptions)$$mathfontoptions$$sep$,$endfor$]{$mathfont$}
+ \fi
+$else$
+ \setmathfont[$for(mathfontoptions)$$mathfontoptions$$sep$,$endfor$]{$mathfont$}
+$endif$
+$endif$
+$if(CJKmainfont)$
+ \ifXeTeX
+ \usepackage{xeCJK}
+ \setCJKmainfont[$for(CJKoptions)$$CJKoptions$$sep$,$endfor$]{$CJKmainfont$}
+ $if(CJKsansfont)$
+ \setCJKsansfont[$for(CJKoptions)$$CJKoptions$$sep$,$endfor$]{$CJKsansfont$}
+ $endif$
+ $if(CJKmonofont)$
+ \setCJKmonofont[$for(CJKoptions)$$CJKoptions$$sep$,$endfor$]{$CJKmonofont$}
+ $endif$
+ \fi
+$endif$
+$if(luatexjapresetoptions)$
+ \ifLuaTeX
+ \usepackage[$for(luatexjapresetoptions)$$luatexjapresetoptions$$sep$,$endfor$]{luatexja-preset}
+ \fi
+$endif$
+$if(CJKmainfont)$
+ \ifLuaTeX
+ \usepackage[$for(luatexjafontspecoptions)$$luatexjafontspecoptions$$sep$,$endfor$]{luatexja-fontspec}
+ \setmainjfont[$for(CJKoptions)$$CJKoptions$$sep$,$endfor$]{$CJKmainfont$}
+ \fi
+$endif$
+\fi
+$if(zero-width-non-joiner)$
+%% Support for zero-width non-joiner characters.
+\makeatletter
+\def\zerowidthnonjoiner{%
+ % Prevent ligatures and adjust kerning, but still support hyphenating.
+ \texorpdfstring{%
+ \TextOrMath{\nobreak\discretionary{-}{}{\kern.03em}%
+ \ifvmode\else\nobreak\hskip\z@skip\fi}{}%
+ }{}%
+}
+\makeatother
+\ifPDFTeX
+ \DeclareUnicodeCharacter{200C}{\zerowidthnonjoiner}
+\else
+ \catcode`^^^^200c=\active
+ \protected\def ^^^^200c{\zerowidthnonjoiner}
+\fi
+%% End of ZWNJ support
+$endif$
+% Use upquote if available, for straight quotes in verbatim environments
+\IfFileExists{upquote.sty}{\usepackage{upquote}}{}
+\IfFileExists{microtype.sty}{% use microtype if available
+ \usepackage[$for(microtypeoptions)$$microtypeoptions$$sep$,$endfor$]{microtype}
+ \UseMicrotypeSet[protrusion]{basicmath} % disable protrusion for tt fonts
+}{}
+$if(indent)$
+$else$
+\makeatletter
+\@ifundefined{KOMAClassName}{% if non-KOMA class
+ \IfFileExists{parskip.sty}{%
+ \usepackage{parskip}
+ }{% else
+ \setlength{\parindent}{0pt}
+ \setlength{\parskip}{6pt plus 2pt minus 1pt}}
+}{% if KOMA class
+ \KOMAoptions{parskip=half}}
+\makeatother
+$endif$
+$if(verbatim-in-note)$
+\usepackage{fancyvrb}
+$endif$
+\usepackage{xcolor}
+\definecolor{default-linkcolor}{HTML}{A50000}
+\definecolor{default-filecolor}{HTML}{A50000}
+\definecolor{default-citecolor}{HTML}{4077C0}
+\definecolor{default-urlcolor}{HTML}{4077C0}
+$if(footnotes-pretty)$
+% load footmisc in order to customize footnotes (footmisc has to be loaded before hyperref, cf. https://tex.stackexchange.com/a/169124/144087)
+\usepackage[hang,flushmargin,bottom,multiple]{footmisc}
+\setlength{\footnotemargin}{0.8em} % set space between footnote nr and text
+\setlength{\footnotesep}{\baselineskip} % set space between multiple footnotes
+\setlength{\skip\footins}{0.3cm} % set space between page content and footnote
+\setlength{\footskip}{0.9cm} % set space between footnote and page bottom
+$endif$
+$if(geometry)$
+$if(beamer)$
+\geometry{$for(geometry)$$geometry$$sep$,$endfor$}
+$else$
+\usepackage[$for(geometry)$$geometry$$sep$,$endfor$]{geometry}
+$endif$
+$else$
+$if(beamer)$
+$else$
+\usepackage[margin=2.5cm,includehead=true,includefoot=true,centering,$for(geometry)$$geometry$$sep$,$endfor$]{geometry}
+$endif$
+$endif$
+$if(titlepage-logo)$
+\usepackage[export]{adjustbox}
+\usepackage{graphicx}
+$endif$
+$if(beamer)$
+\newif\ifbibliography
+$endif$
+$if(listings)$
+\usepackage{listings}
+\newcommand{\passthrough}[1]{#1}
+\lstset{defaultdialect=[5.3]Lua}
+\lstset{defaultdialect=[x86masm]Assembler}
+$endif$
+$if(listings-no-page-break)$
+\usepackage{etoolbox}
+\BeforeBeginEnvironment{lstlisting}{\par\noindent\begin{minipage}{\linewidth}}
+\AfterEndEnvironment{lstlisting}{\end{minipage}\par\addvspace{\topskip}}
+$endif$
+$if(lhs)$
+\lstnewenvironment{code}{\lstset{language=Haskell,basicstyle=\small\ttfamily}}{}
+$endif$
+$if(highlighting-macros)$
+$highlighting-macros$
+
+% Workaround/bugfix from jannick0.
+% See https://github.com/jgm/pandoc/issues/4302#issuecomment-360669013)
+% or https://github.com/Wandmalfarbe/pandoc-latex-template/issues/2
+%
+% Redefine the verbatim environment 'Highlighting' to break long lines (with
+% the help of fvextra). Redefinition is necessary because it is unlikely that
+% pandoc includes fvextra in the default template.
+\usepackage{fvextra}
+\DefineVerbatimEnvironment{Highlighting}{Verbatim}{breaklines,fontsize=$if(code-block-font-size)$$code-block-font-size$$else$\small$endif$,commandchars=\\\{\}}
+
+$endif$
+
+% 为中文添加支持 by Ming Su
+$if(CJK)$
+$if(isbook)$
+\usepackage{ctex} %调用中文字体宏包
+\usepackage{indentfirst} %调用首行缩进宏包
+\usepackage{ctex} % 确保中文字体支持
+\usepackage{zhnumber}
+% 修改 chapter 格式为 "第X章"
+% \renewcommand{\chapterformat}{第~\thechapter~章}
+% \renewcommand{\chapterformat}{第\zhnumber{\thechapter}章}
+\renewcommand{\chaptermarkformat}{第~\zhnumber{\thechapter}~章}
+\renewcommand{\chapterformat}{第\zhnumber{\thechapter}章}
+\renewcommand*{\chapterlinesformat}[3]{%
+ \parbox{\linewidth}{\centering #2~\quad~#3} % 居中 + "·" 分隔
+ % 或改用冒号分隔:
+ % \parbox{\linewidth}{\centering #2:#3}
+}
+\RedeclareSectionCommand[
+ beforeskip=1.5em plus 0.5em minus 0.5em,
+ afterskip=1em plus 0.2em,
+ font=\large\bfseries
+]{section}
+\usepackage{zhnumber} % 确保已加载(或直接用 ctex)
+% 修改目录中的章节编号为中文
+\addtokomafont{chapterentry}{\normalfont} % 可选:调整目录字体
+\renewcommand*{\chapterformat}{第\zhnumber{\thechapter}章} % 正文标题格式
+\renewcommand*{\chaptermarkformat}{第\zhnumber{\thechapter}章\quad} % 页眉标题格式
+% 关键!覆盖目录中的章节编号
+\renewcommand{\addchaptertocentry}[2]{%
+ \addtocentrydefault{chapter}{第\zhnumber{#1}章}{#2}%
+}
+\RedeclareSectionCommand[
+ tocentryindent=0pt,
+ tocentrynumwidth=3.5em % 确保编号区域足够宽
+]{chapter}
+$endif$
+$endif$
+
+$if(tables)$
+\usepackage{longtable,booktabs,array}
+$if(multirow)$
+\usepackage{multirow}
+$endif$
+\usepackage{calc} % for calculating minipage widths
+$if(beamer)$
+\usepackage{caption}
+% Make caption package work with longtable
+\makeatletter
+\def\fnum@table{\tablename~\thetable}
+\makeatother
+$else$
+% Correct order of tables after \paragraph or \subparagraph
+\usepackage{etoolbox}
+\makeatletter
+\patchcmd\longtable{\par}{\if@noskipsec\mbox{}\fi\par}{}{}
+\makeatother
+% Allow footnotes in longtable head/foot
+\IfFileExists{footnotehyper.sty}{\usepackage{footnotehyper}}{\usepackage{footnote}}
+\makesavenoteenv{longtable}
+$endif$
+$endif$
+% add backlinks to footnote references, cf. https://tex.stackexchange.com/questions/302266/make-footnote-clickable-both-ways
+$if(footnotes-disable-backlinks)$
+$else$
+\usepackage{footnotebackref}
+$endif$
+$if(graphics)$
+\usepackage{graphicx}
+\makeatletter
+% \def\maxwidth{\ifdim\Gin@nat@width>\linewidth\linewidth\else\Gin@nat@width\fi}
+% \def\maxheight{\ifdim\Gin@nat@height>\textheight\textheight\else\Gin@nat@height\fi}
+% \makeatother
+% % Scale images if necessary, so that they will not overflow the page
+% % margins by default, and it is still possible to overwrite the defaults
+% % using explicit options in \includegraphics[width, height, ...]{}
+% \setkeys{Gin}{width=\maxwidth,height=\maxheight,keepaspectratio}
+\newsavebox\pandoc@box
+\newcommand*\pandocbounded[1]{% scales image to fit in text height/width
+ \sbox\pandoc@box{#1}%
+ \Gscale@div\@tempa{\textheight}{\dimexpr\ht\pandoc@box+\dp\pandoc@box\relax}%
+ \Gscale@div\@tempb{\linewidth}{\wd\pandoc@box}%
+ \ifdim\@tempb\p@<\@tempa\p@\let\@tempa\@tempb\fi% select the smaller of both
+ \ifdim\@tempa\p@<\p@\scalebox{\@tempa}{\usebox\pandoc@box}%
+ \else\usebox{\pandoc@box}%
+ \fi%
+}
+% Set default figure placement to htbp
+\makeatletter
+\def\fps@figure{htbp}
+\makeatother
+% \makeatletter Old options from template, replaced with quarto defaults above
+% \newsavebox\pandoc@box
+% \newcommand*\pandocbounded[1]{% scales image to fit in text height/width
+% \sbox\pandoc@box{#1}%
+% \Gscale@div\@tempa{\textheight}{\dimexpr\ht\pandoc@box+\dp\pandoc@box\relax}%
+% \Gscale@div\@tempb{\linewidth}{\wd\pandoc@box}%
+% \ifdim\@tempb\p@<\@tempa\p@\let\@tempa\@tempb\fi% select the smaller of both
+% \ifdim\@tempa\p@<\p@\scalebox{\@tempa}{\usebox\pandoc@box}%
+% \else\usebox{\pandoc@box}%
+% \fi%
+% }
+% % Set default figure placement to htbp
+% % Make use of float-package and set default placement for figures to H.
+% % The option H means 'PUT IT HERE' (as opposed to the standard h option which means 'You may put it here if you like').
+% \usepackage{float}
+% \floatplacement{figure}{$if(float-placement-figure)$$float-placement-figure$$else$H$endif$}
+% \makeatother
+$endif$
+$if(svg)$
+\usepackage{svg}
+$endif$
+$if(strikeout)$
+$-- also used for underline
+\ifLuaTeX
+ \usepackage{luacolor}
+ \usepackage[soul]{lua-ul}
+\else
+\usepackage{soul}
+$if(beamer)$
+ \makeatletter
+ \let\HL\hl
+ \renewcommand\hl{% fix for beamer highlighting
+ \let\set@color\beamerorig@set@color
+ \let\reset@color\beamerorig@reset@color
+ \HL}
+ \makeatother
+$endif$
+$if(CJKmainfont)$
+ \ifXeTeX
+ % soul's \st doesn't work for CJK:
+ \usepackage{xeCJKfntef}
+ \renewcommand{\st}[1]{\sout{#1}}
+ \fi
+$endif$
+\fi
+$endif$
+\setlength{\emergencystretch}{3em} % prevent overfull lines
+\providecommand{\tightlist}{%
+ \setlength{\itemsep}{0pt}\setlength{\parskip}{0pt}}
+$if(numbersections)$
+\setcounter{secnumdepth}{$if(secnumdepth)$$secnumdepth$$else$5$endif$}
+$else$
+\setcounter{secnumdepth}{-\maxdimen} % remove section numbering
+$endif$
+$if(subfigure)$
+\usepackage{subcaption}
+$endif$
+$if(beamer)$
+$else$
+$if(block-headings)$
+% Make \paragraph and \subparagraph free-standing
+\makeatletter
+\ifx\paragraph\undefined\else
+ \let\oldparagraph\paragraph
+ \renewcommand{\paragraph}{
+ \@ifstar
+ \xxxParagraphStar
+ \xxxParagraphNoStar
+ }
+ \newcommand{\xxxParagraphStar}[1]{\oldparagraph*{#1}\mbox{}}
+ \newcommand{\xxxParagraphNoStar}[1]{\oldparagraph{#1}\mbox{}}
+\fi
+\ifx\subparagraph\undefined\else
+ \let\oldsubparagraph\subparagraph
+ \renewcommand{\subparagraph}{
+ \@ifstar
+ \xxxSubParagraphStar
+ \xxxSubParagraphNoStar
+ }
+ \newcommand{\xxxSubParagraphStar}[1]{\oldsubparagraph*{#1}\mbox{}}
+ \newcommand{\xxxSubParagraphNoStar}[1]{\oldsubparagraph{#1}\mbox{}}
+\fi
+\makeatother
+$endif$
+$endif$
+$if(pagestyle)$
+\pagestyle{$pagestyle$}
+$endif$
+$if(csl-refs)$
+% definitions for citeproc citations
+\NewDocumentCommand\citeproctext{}{}
+\NewDocumentCommand\citeproc{mm}{%
+ \begingroup\def\citeproctext{#2}\cite{#1}\endgroup}
+\makeatletter
+ % allow citations to break across lines
+ \let\@cite@ofmt\@firstofone
+ % avoid brackets around text for \cite:
+ \def\@biblabel#1{}
+ \def\@cite#1#2{{#1\if@tempswa , #2\fi}}
+\makeatother
+\newlength{\cslhangindent}
+\setlength{\cslhangindent}{1.5em}
+\newlength{\csllabelwidth}
+\setlength{\csllabelwidth}{3em}
+\newenvironment{CSLReferences}[2] % #1 hanging-indent, #2 entry-spacing
+ {\begin{list}{}{%
+ \setlength{\itemindent}{0pt}
+ \setlength{\leftmargin}{0pt}
+ \setlength{\parsep}{0pt}
+ % turn on hanging indent if param 1 is 1
+ \ifodd #1
+ \setlength{\leftmargin}{\cslhangindent}
+ \setlength{\itemindent}{-1\cslhangindent}
+ \fi
+ % set entry spacing
+ \setlength{\itemsep}{#2\baselineskip}}}
+ {\end{list}}
+\usepackage{calc}
+\newcommand{\CSLBlock}[1]{\hfill\break\parbox[t]{\linewidth}{\strut\ignorespaces#1\strut}}
+\newcommand{\CSLLeftMargin}[1]{\parbox[t]{\csllabelwidth}{\strut#1\strut}}
+\newcommand{\CSLRightInline}[1]{\parbox[t]{\linewidth - \csllabelwidth}{\strut#1\strut}}
+\newcommand{\CSLIndent}[1]{\hspace{\cslhangindent}#1}
+$endif$
+$if(lang)$
+\ifLuaTeX
+\usepackage[bidi=basic]{babel}
+\else
+\usepackage[bidi=default]{babel}
+\fi
+$if(babel-lang)$
+\babelprovide[main,import]{$babel-lang$}
+$if(mainfont)$
+\ifPDFTeX
+\else
+\babelfont{rm}[$for(mainfontoptions)$$mainfontoptions$$sep$,$endfor$$if(mainfontfallback)$,RawFeature={fallback=mainfontfallback}$endif$]{$mainfont$}
+\fi
+$endif$
+$endif$
+$for(babel-otherlangs)$
+\babelprovide[import]{$babel-otherlangs$}
+$endfor$
+$for(babelfonts/pairs)$
+\babelfont[$babelfonts.key$]{rm}{$babelfonts.value$}
+$endfor$
+% get rid of language-specific shorthands (see #6817):
+\let\LanguageShortHands\languageshorthands
+\def\languageshorthands#1{}
+$if(selnolig-langs)$
+\ifLuaTeX
+ \usepackage[$for(selnolig-langs)$$it$$sep$,$endfor$]{selnolig} % disable illegal ligatures
+\fi
+$endif$
+$endif$
+$for(header-includes)$
+$header-includes$
+$endfor$
+$if(dir)$
+\ifPDFTeX
+ \TeXXeTstate=1
+ \newcommand{\RL}[1]{\beginR #1\endR}
+ \newcommand{\LR}[1]{\beginL #1\endL}
+ \newenvironment{RTL}{\beginR}{\endR}
+ \newenvironment{LTR}{\beginL}{\endL}
+\fi
+$endif$
+$if(natbib)$
+\usepackage[$natbiboptions$]{natbib}
+\bibliographystyle{$if(biblio-style)$$biblio-style$$else$plainnat$endif$}
+$endif$
+$if(biblatex)$
+\usepackage[$if(biblio-style)$style=$biblio-style$,$endif$$for(biblatexoptions)$$biblatexoptions$$sep$,$endfor$]{biblatex}
+$for(bibliography)$
+\addbibresource{$bibliography$}
+$endfor$
+$endif$
+$if(nocite-ids)$
+\nocite{$for(nocite-ids)$$it$$sep$, $endfor$}
+$endif$
+$if(csquotes)$
+\usepackage{csquotes}
+$endif$
+\usepackage{bookmark}
+\IfFileExists{xurl.sty}{\usepackage{xurl}}{} % add URL line breaks if available
+\urlstyle{$if(urlstyle)$$urlstyle$$else$same$endif$}
+$if(links-as-notes)$
+% Make links footnotes instead of hotlinks:
+\DeclareRobustCommand{\href}[2]{#2\footnote{\url{#1}}}
+$endif$
+$if(verbatim-in-note)$
+\VerbatimFootnotes % allow verbatim text in footnotes
+$endif$
+\hypersetup{
+$if(title-meta)$
+ pdftitle={$title-meta$},
+$endif$
+$if(author-meta)$
+ pdfauthor={$author-meta$},
+$endif$
+$if(lang)$
+ pdflang={$lang$},
+$endif$
+$if(subject)$
+pdfsubject={$subject$},
+$endif$
+$if(keywords)$
+ pdfkeywords={$for(keywords)$$keywords$$sep$, $endfor$},
+$endif$
+$if(colorlinks)$
+ colorlinks=true,
+ linkcolor={$if(linkcolor)$$linkcolor$$else$default-linkcolor$endif$},
+ filecolor={$if(filecolor)$$filecolor$$else$default-filecolor$endif$},
+ citecolor={$if(citecolor)$$citecolor$$else$default-citecolor$endif$},
+ urlcolor={$if(urlcolor)$$urlcolor$$else$default-urlcolor$endif$},
+$else$
+$if(boxlinks)$
+$else$
+ hidelinks,
+$endif$
+$endif$
+ breaklinks=true,
+ pdfcreator={LaTeX via pandoc with the Eisvogel template}}
+$if(title)$
+\title{$title$$if(thanks)$\thanks{$thanks$}$endif$}
+$endif$
+$if(subtitle)$
+$if(beamer)$
+$else$
+\usepackage{etoolbox}
+\makeatletter
+\providecommand{\subtitle}[1]{% add subtitle to \maketitle
+ \apptocmd{\@title}{\par {\large #1 \par}}{}{}
+}
+\makeatother
+$endif$
+\subtitle{$subtitle$}
+$endif$
+\author{$for(author)$$author$$sep$ \and $endfor$}
+\date{$date$}
+$if(beamer)$
+$if(institute)$
+\institute{$for(institute)$$institute$$sep$ \and $endfor$}
+$endif$
+$if(titlegraphic)$
+\titlegraphic{\includegraphics$if(titlegraphicoptions)$[$for(titlegraphicoptions)$$titlegraphicoptions$$sep$, $endfor$]$endif${$titlegraphic$}}
+$endif$
+$if(logo)$
+\logo{\includegraphics{$logo$}}
+$endif$
+$endif$
+
+
+
+%%
+%% added
+%%
+
+$if(page-background)$
+\usepackage[pages=all]{background}
+$endif$
+
+%
+% for the background color of the title page
+%
+$if(titlepage)$
+\usepackage{pagecolor}
+\usepackage{afterpage}
+$if(titlepage-background)$
+\usepackage{tikz}
+$endif$
+$if(geometry)$
+$else$
+\usepackage[margin=2.5cm,includehead=true,includefoot=true,centering]{geometry}
+$endif$
+$endif$
+
+%
+% break urls
+%
+\PassOptionsToPackage{hyphens}{url}
+
+%
+% When using babel or polyglossia with biblatex, loading csquotes is recommended
+% to ensure that quoted texts are typeset according to the rules of your main language.
+%
+\usepackage{csquotes}
+
+%
+% captions
+%
+\definecolor{caption-color}{HTML}{777777}
+$if(beamer)$
+$else$
+\usepackage[font={stretch=1.2}, textfont={color=caption-color}, position=top, skip=4mm, labelfont=bf, singlelinecheck=false, justification=$if(caption-justification)$$caption-justification$$else$raggedright$endif$]{caption}
+\setcapindent{0em}
+$endif$
+
+%
+% blockquote
+%
+\definecolor{blockquote-border}{RGB}{221,221,221}
+\definecolor{blockquote-text}{RGB}{119,119,119}
+\usepackage{mdframed}
+\newmdenv[rightline=false,bottomline=false,topline=false,linewidth=3pt,linecolor=blockquote-border,skipabove=\parskip]{customblockquote}
+\renewenvironment{quote}{\begin{customblockquote}\list{}{\rightmargin=0em\leftmargin=0em}%
+\item\relax\color{blockquote-text}\ignorespaces}{\unskip\unskip\endlist\end{customblockquote}}
+
+%
+% Source Sans Pro as the default font family
+% Source Code Pro for monospace text
+%
+% 'default' option sets the default
+% font family to Source Sans Pro, not \sfdefault.
+%
+\ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex
+ $if(fontfamily)$
+ $else$
+ \usepackage[default]{sourcesanspro}
+ \usepackage{sourcecodepro}
+ $endif$
+\else % if not pdftex
+ $if(mainfont)$
+ $else$
+ \usepackage[default]{sourcesanspro}
+ \usepackage{sourcecodepro}
+
+ % XeLaTeX specific adjustments for straight quotes: https://tex.stackexchange.com/a/354887
+ % This issue is already fixed (see https://github.com/silkeh/latex-sourcecodepro/pull/5) but the
+ % fix is still unreleased.
+ % TODO: Remove this workaround when the new version of sourcecodepro is released on CTAN.
+ \ifxetex
+ \makeatletter
+ \defaultfontfeatures[\ttfamily]
+ { Numbers = \sourcecodepro@figurestyle,
+ Scale = \SourceCodePro@scale,
+ Extension = .otf }
+ \setmonofont
+ [ UprightFont = *-\sourcecodepro@regstyle,
+ ItalicFont = *-\sourcecodepro@regstyle It,
+ BoldFont = *-\sourcecodepro@boldstyle,
+ BoldItalicFont = *-\sourcecodepro@boldstyle It ]
+ {SourceCodePro}
+ \makeatother
+ \fi
+ $endif$
+\fi
+
+
+% setup for chinese font, by Ming
+\setCJKmainfont{$CJKmainfont$}[BoldFont=$CJKboldfont$, ItalicFont=$CJKitalicfont$]
+
+%
+% heading color
+%
+\definecolor{heading-color}{RGB}{40,40,40}
+$if(beamer)$
+$else$
+\addtokomafont{section}{\color{heading-color}}
+$endif$
+% When using the classes report, scrreprt, book,
+% scrbook or memoir, uncomment the following line.
+%\addtokomafont{chapter}{\color{heading-color}}
+
+%
+% variables for title, author and date
+%
+$if(beamer)$
+$else$
+\usepackage{titling}
+\title{$title$}
+\author{$for(author)$$author$$sep$, $endfor$}
+\date{$date$}
+$endif$
+
+%
+% tables
+%
+$if(tables)$
+
+\definecolor{table-row-color}{HTML}{F5F5F5}
+\definecolor{table-rule-color}{HTML}{999999}
+
+%\arrayrulecolor{black!40}
+\arrayrulecolor{table-rule-color} % color of \toprule, \midrule, \bottomrule
+\setlength\heavyrulewidth{0.3ex} % thickness of \toprule, \bottomrule
+\renewcommand{\arraystretch}{1.3} % spacing (padding)
+
+$if(table-use-row-colors)$
+% Unfortunately the colored cells extend beyond the edge of the
+% table because pandoc uses @-expressions (@{}) like so:
+%
+% \begin{longtable}[]{@{}ll@{}}
+% \end{longtable}
+%
+% https://en.wikibooks.org/wiki/LaTeX/Tables#.40-expressions
+\usepackage{etoolbox}
+\AtBeginEnvironment{longtable}{\rowcolors{2}{}{table-row-color!100}}
+\preto{\toprule}{\hiderowcolors}{}{}
+\appto{\endhead}{\showrowcolors}{}{}
+\appto{\endfirsthead}{\showrowcolors}{}{}
+$endif$
+$endif$
+
+%
+% remove paragraph indentation
+%
+% \setlength{\parindent}{0pt}
+$if(parindent)$
+\setlength{\parindent}{2em} %设置首行缩进为2字符
+$else$
+\setlength{\parindent}{0pt}
+$endif$
+\setlength{\parskip}{6pt plus 2pt minus 1pt}
+\setlength{\emergencystretch}{3em} % prevent overfull lines
+
+
+
+%
+%
+% Listings
+%
+%
+
+$if(listings)$
+
+%
+% general listing colors
+%
+\definecolor{listing-background}{HTML}{F7F7F7}
+\definecolor{listing-rule}{HTML}{B3B2B3}
+\definecolor{listing-numbers}{HTML}{B3B2B3}
+\definecolor{listing-text-color}{HTML}{000000}
+\definecolor{listing-keyword}{HTML}{435489}
+\definecolor{listing-keyword-2}{HTML}{1284CA} % additional keywords
+\definecolor{listing-keyword-3}{HTML}{9137CB} % additional keywords
+\definecolor{listing-identifier}{HTML}{435489}
+\definecolor{listing-string}{HTML}{00999A}
+\definecolor{listing-comment}{HTML}{8E8E8E}
+
+\lstdefinestyle{eisvogel_listing_style}{
+ language = java,
+$if(listings-disable-line-numbers)$
+ xleftmargin = 0.6em,
+ framexleftmargin = 0.4em,
+$else$
+ numbers = left,
+ xleftmargin = 2.7em,
+ framexleftmargin = 2.5em,
+$endif$
+ backgroundcolor = \color{listing-background},
+ basicstyle = \color{listing-text-color}\linespread{1.0}%
+ \lst@ifdisplaystyle%
+ $if(code-block-font-size)$$code-block-font-size$$else$\small$endif$%
+ \fi\ttfamily{},
+ breaklines = true,
+ frame = single,
+ framesep = 0.19em,
+ rulecolor = \color{listing-rule},
+ frameround = ffff,
+ tabsize = 4,
+ numberstyle = \color{listing-numbers},
+ aboveskip = 1.0em,
+ belowskip = 0.1em,
+ abovecaptionskip = 0em,
+ belowcaptionskip = 1.0em,
+ keywordstyle = {\color{listing-keyword}\bfseries},
+ keywordstyle = {[2]\color{listing-keyword-2}\bfseries},
+ keywordstyle = {[3]\color{listing-keyword-3}\bfseries\itshape},
+ sensitive = true,
+ identifierstyle = \color{listing-identifier},
+ commentstyle = \color{listing-comment},
+ stringstyle = \color{listing-string},
+ showstringspaces = false,
+ escapeinside = {/*@}{@*/}, % Allow LaTeX inside these special comments
+ literate =
+ {á}{{\'a}}1 {é}{{\'e}}1 {í}{{\'i}}1 {ó}{{\'o}}1 {ú}{{\'u}}1
+ {Á}{{\'A}}1 {É}{{\'E}}1 {Í}{{\'I}}1 {Ó}{{\'O}}1 {Ú}{{\'U}}1
+ {à}{{\`a}}1 {è}{{\`e}}1 {ì}{{\`i}}1 {ò}{{\`o}}1 {ù}{{\`u}}1
+ {À}{{\`A}}1 {È}{{\`E}}1 {Ì}{{\`I}}1 {Ò}{{\`O}}1 {Ù}{{\`U}}1
+ {ä}{{\"a}}1 {ë}{{\"e}}1 {ï}{{\"i}}1 {ö}{{\"o}}1 {ü}{{\"u}}1
+ {Ä}{{\"A}}1 {Ë}{{\"E}}1 {Ï}{{\"I}}1 {Ö}{{\"O}}1 {Ü}{{\"U}}1
+ {â}{{\^a}}1 {ê}{{\^e}}1 {î}{{\^i}}1 {ô}{{\^o}}1 {û}{{\^u}}1
+ {Â}{{\^A}}1 {Ê}{{\^E}}1 {Î}{{\^I}}1 {Ô}{{\^O}}1 {Û}{{\^U}}1
+ {œ}{{\oe}}1 {Œ}{{\OE}}1 {æ}{{\ae}}1 {Æ}{{\AE}}1 {ß}{{\ss}}1
+ {ç}{{\c c}}1 {Ç}{{\c C}}1 {ø}{{\o}}1 {å}{{\r a}}1 {Å}{{\r A}}1
+ {€}{{\EUR}}1 {£}{{\pounds}}1 {«}{{\guillemotleft}}1
+ {»}{{\guillemotright}}1 {ñ}{{\~n}}1 {Ñ}{{\~N}}1 {¿}{{?`}}1
+ {…}{{\ldots}}1 {≥}{{>=}}1 {≤}{{<=}}1 {„}{{\glqq}}1 {“}{{\grqq}}1
+ {”}{{''}}1
+}
+\lstset{style=eisvogel_listing_style}
+
+%
+% Java (Java SE 12, 2019-06-22)
+%
+\lstdefinelanguage{Java}{
+ morekeywords={
+ % normal keywords (without data types)
+ abstract,assert,break,case,catch,class,continue,default,
+ do,else,enum,exports,extends,final,finally,for,if,implements,
+ import,instanceof,interface,module,native,new,package,private,
+ protected,public,requires,return,static,strictfp,super,switch,
+ synchronized,this,throw,throws,transient,try,volatile,while,
+ % var is an identifier
+ var
+ },
+ morekeywords={[2] % data types
+ % primitive data types
+ boolean,byte,char,double,float,int,long,short,
+ % String
+ String,
+ % primitive wrapper types
+ Boolean,Byte,Character,Double,Float,Integer,Long,Short
+ % number types
+ Number,AtomicInteger,AtomicLong,BigDecimal,BigInteger,DoubleAccumulator,DoubleAdder,LongAccumulator,LongAdder,Short,
+ % other
+ Object,Void,void
+ },
+ morekeywords={[3] % literals
+ % reserved words for literal values
+ null,true,false,
+ },
+ sensitive,
+ morecomment = [l]//,
+ morecomment = [s]{/*}{*/},
+ morecomment = [s]{/**}{*/},
+ morestring = [b]",
+ morestring = [b]',
+}
+
+\lstdefinelanguage{XML}{
+ morestring = [b]",
+ moredelim = [s][\bfseries\color{listing-keyword}]{<}{\ },
+ moredelim = [s][\bfseries\color{listing-keyword}]{}{>},
+ moredelim = [l][\bfseries\color{listing-keyword}]{/>},
+ moredelim = [l][\bfseries\color{listing-keyword}]{>},
+ morecomment = [s]{}{?>},
+ morecomment = [s]{},
+ commentstyle = \color{listing-comment},
+ stringstyle = \color{listing-string},
+ identifierstyle = \color{listing-identifier}
+}
+$endif$
+
+%
+% header and footer
+%
+$if(beamer)$
+$else$
+$if(disable-header-and-footer)$
+$else$
+\usepackage[headsepline,footsepline]{scrlayer-scrpage}
+
+\newpairofpagestyles{eisvogel-header-footer}{
+ \clearpairofpagestyles
+ \ihead*{$if(header-left)$$header-left$$else$$title$$endif$}
+ \chead*{$if(header-center)$$header-center$$else$$endif$}
+ \ohead*{$if(header-right)$$header-right$$else$$date$$endif$}
+ \ifoot*{$if(footer-left)$$footer-left$$else$$for(author)$$author$$sep$, $endfor$$endif$}
+ \cfoot*{$if(footer-center)$$footer-center$$else$$endif$}
+ \ofoot*{$if(footer-right)$$footer-right$$else$\thepage$endif$}
+ \addtokomafont{pageheadfoot}{\upshape}
+}
+\pagestyle{eisvogel-header-footer}
+
+\newpairofpagestyles{eisvogel-chapterpage-header-footer}{
+ \clearpairofpagestyles
+ \setheadtopline{0pt} % 移除页眉顶部的横线(如果有)
+ \setheadsepline{0pt}
+ \ifoot*{$if(footer-left)$$footer-left$$else$$for(author)$$author$$sep$, $endfor$$endif$}
+ \cfoot*{$if(footer-center)$$footer-center$$else$$endif$}
+ \ofoot*{$if(footer-right)$$footer-right$$else$\thepage$endif$}
+ \addtokomafont{pageheadfoot}{\upshape}
+}
+
+
+$if(isbook)$
+% \deftripstyle{ChapterStyle}{}{}{}{}{\pagemark}{}
+% \renewcommand*{\chapterpagestyle}{ChapterStyle}
+\renewcommand*{\chapterpagestyle}{eisvogel-chapterpage-header-footer}
+$endif$
+
+
+$if(page-background)$
+\backgroundsetup{
+scale=1,
+color=black,
+opacity=$if(page-background-opacity)$$page-background-opacity$$else$0.2$endif$,
+angle=0,
+contents={%
+ \includegraphics[width=\paperwidth,height=\paperheight]{$page-background$}
+ }%
+}
+$endif$
+$endif$
+$endif$
+
+% watermark
+$if(watermark)$
+\usepackage{draftwatermark,xcolor}
+\SetWatermarkText{\textcolor{$if(watermark-color)$$watermark-color$$else$gray!3$endif$}{$watermark$}}
+\SetWatermarkScale{1.2} % 缩小水印尺寸(数值越小越密集)
+\SetWatermarkAngle{45} % 斜角排列(经典水印样式)
+\SetWatermarkLightness{0.99} % 亮度调节
+$endif$
+
+%%
+%% end added
+%%
+
+\begin{document}
+
+%%
+%% begin titlepage
+%%
+$if(beamer)$
+$else$
+$if(titlepage)$
+\begin{titlepage}
+$if(titlepage-background)$
+\newgeometry{top=2cm, right=4cm, bottom=3cm, left=4cm}
+$else$
+\newgeometry{left=2cm}
+$endif$
+$if(titlepage-color)$
+\definecolor{titlepage-color}{HTML}{$titlepage-color$}
+\newpagecolor{titlepage-color}\afterpage{\restorepagecolor}
+$endif$
+$if(titlepage-background)$
+\tikz[remember picture,overlay] \node[inner sep=0pt] at (current page.center){\includegraphics[width=\paperwidth,height=\paperheight]{$titlepage-background$}};
+$endif$
+\newcommand{\colorRule}[3][black]{\textcolor[HTML]{#1}{\rule{#2}{#3}}}
+
+\NewDocumentEnvironment{dynalign}{}
+ {\begin{$if(titlepage-halign)$$titlepage-halign$$else$center$endif$}}
+ {\end{$if(titlepage-halign)$$titlepage-halign$$else$center$endif$}}
+
+\begin{dynalign}
+\noindent
+\\[-1em]
+\color[HTML]{$if(titlepage-text-color)$$titlepage-text-color$$else$5F5F5F$endif$}
+\makebox[0pt][l]{\colorRule[$if(titlepage-rule-color)$$titlepage-rule-color$$else$435488$endif$]{1.3\textwidth}{$if(titlepage-rule-height)$$titlepage-rule-height$$else$4$endif$pt}}
+\par
+\noindent
+
+$if(titlepage-logo)$
+\noindent
+\vskip $if(logo-vskip)$$logo-vskip$$else$-8em$endif$
+\hskip $if(logo-hskip)$$logo-hskip$$else$-6em$endif$
+\includegraphics[width=$if(logo-width)$$logo-width$$else$35mm$endif$, left]{$titlepage-logo$}
+$endif$
+
+$if(titlepage-background)$
+% The titlepage with a background image has other text spacing and text size
+{
+ \setstretch{2}
+ \vfill
+ \vskip -8em
+ $if(title-vskip)$
+ \vskip $title-vskip$
+ $endif$
+ $if(title-hskip)$
+ \vskip $title-hskip$
+ $endif$
+ \noindent {
+ $if(title-size)$
+ \$title-size$
+ $else$
+ \huge
+ $endif$
+\textbf{\textsf{$title$}}}
+ $if(subtitle)$
+ \vskip 1em
+ {
+ $if(subtitle-size)$
+ \$subtitle-size$
+ $else$
+ \Large
+ $endif$
+ \textsf{$subtitle$}}
+ $endif$
+ \vskip 2em
+ $if(author-vskip)$
+ \vskip $author-vskip$
+ $endif$
+ \noindent {
+ $if(author-size)$
+ $author-size$
+ $else$
+ \Large
+ $endif$
+
+\textsf{$for(author)$$author$$sep$, $endfor$}
+\vskip 0.6em
+ $if(date-vskip)$
+ \vskip $date-vskip$
+ $endif$
+{\textsf{$if(institute)$$institute$\vskip 0.6em$endif$$date$}}
+}
+ \vfill
+}
+$else$
+{
+ \setstretch{1.4}
+ \vfill
+ \vskip 8em
+ $if(title-vskip)$
+ \vskip $title-vskip$
+ $endif$
+ $if(title-hskip)$
+ \vskip $title-hskip$
+ $endif$
+ \noindent {\huge \textbf{\textsf{$title$}}}
+ $if(subtitle)$
+ \vskip 1em
+ {\Large \textsf{$subtitle$}}
+ $endif$
+ \vskip 4em
+ $if(author-vskip)$
+ \vskip $author-vskip$
+ $endif$
+ \noindent {
+ $if(author-size)$
+ $author-size$
+ $else$
+ \Large
+ $endif$
+
+\textsf{$for(author)$$author$$sep$, $endfor$}
+\vskip 0.6em
+ $if(date-vskip)$
+ \vskip $date-vskip$
+ $endif$
+}
+ \vfill
+}
+$endif$
+
+
+$if(titlepage-background)$
+$else$
+
+ $if(author-size)$
+ $author-size$
+ $else$
+ \Large
+ $endif$
+{\textsf{$if(institute)$$institute$\vskip 0.6em$endif$$date$}}
+$endif$
+\end{dynalign}
+\end{titlepage}
+\restoregeometry
+\pagenumbering{arabic}
+$endif$
+$endif$
+
+
+
+%%
+%% end titlepage
+%%
+
+$if(has-frontmatter)$
+\frontmatter
+$endif$
+$if(title)$
+$if(beamer)$
+\frame{\titlepage}
+% don't generate the default title
+% $else$
+% \maketitle
+$endif$
+$if(abstract)$
+\begin{abstract}
+$abstract$
+\end{abstract}
+$endif$
+$endif$
+
+$if(first-chapter)$
+\setcounter{chapter}{$first-chapter$}
+\addtocounter{chapter}{-1}
+$endif$
+
+$for(include-before)$
+$include-before$
+
+$endfor$
+$if(toc)$
+$if(toc-title)$
+\renewcommand*\contentsname{$toc-title$}
+$endif$
+$if(beamer)$
+\begin{frame}[allowframebreaks]
+$if(toc-title)$
+ \frametitle{$toc-title$}
+$endif$
+ \setcounter{tocdepth}{$toc-depth$}
+ \tableofcontents
+\end{frame}
+$if(toc-own-page)$
+\newpage
+$endif$
+$else$
+{
+$if(colorlinks)$
+\hypersetup{linkcolor=$if(toccolor)$$toccolor$$else$$endif$}
+$endif$
+\setcounter{tocdepth}{$toc-depth$}
+\tableofcontents
+$if(toc-own-page)$
+\newpage
+$endif$
+}
+$endif$
+$endif$
+$if(lof)$
+\listoffigures
+$endif$
+$if(lot)$
+\listoftables
+$endif$
+$if(linestretch)$
+\setstretch{$linestretch$}
+$endif$
+$if(has-frontmatter)$
+\mainmatter
+$endif$
+$body$
+
+$if(has-frontmatter)$
+\backmatter
+$endif$
+$if(natbib)$
+$if(bibliography)$
+$if(biblio-title)$
+$if(has-chapters)$
+\renewcommand\bibname{$biblio-title$}
+$else$
+\renewcommand\refname{$biblio-title$}
+$endif$
+$endif$
+$if(beamer)$
+\begin{frame}[allowframebreaks]{$biblio-title$}
+ \bibliographytrue
+$endif$
+ \bibliography{$for(bibliography)$$bibliography$$sep$,$endfor$}
+$if(beamer)$
+\end{frame}
+$endif$
+
+$endif$
+$endif$
+$if(biblatex)$
+$if(beamer)$
+\begin{frame}[allowframebreaks]{$biblio-title$}
+ \bibliographytrue
+ \printbibliography[heading=none]
+\end{frame}
+$else$
+\printbibliography$if(biblio-title)$[title=$biblio-title$]$endif$
+$endif$
+
+$endif$
+$for(include-after)$
+$include-after$
+
+$endfor$
+\end{document}
diff --git a/_extensions/drwater/dwev/inst/CL.docx b/_extensions/drwater/dwev/inst/CL.docx
new file mode 100755
index 0000000..3727b07
Binary files /dev/null and b/_extensions/drwater/dwev/inst/CL.docx differ
diff --git a/_extensions/drwater/dwev/inst/MS.docx b/_extensions/drwater/dwev/inst/MS.docx
new file mode 100755
index 0000000..5b9ad12
Binary files /dev/null and b/_extensions/drwater/dwev/inst/MS.docx differ
diff --git a/_extensions/drwater/dwev/inst/RN.docx b/_extensions/drwater/dwev/inst/RN.docx
new file mode 100755
index 0000000..a74403c
Binary files /dev/null and b/_extensions/drwater/dwev/inst/RN.docx differ
diff --git a/_extensions/drwater/dwev/inst/RP.docx b/_extensions/drwater/dwev/inst/RP.docx
new file mode 100755
index 0000000..18580b1
Binary files /dev/null and b/_extensions/drwater/dwev/inst/RP.docx differ
diff --git a/_extensions/drwater/dwev/inst/american-chemical-society.csl b/_extensions/drwater/dwev/inst/american-chemical-society.csl
new file mode 100755
index 0000000..01f8c49
--- /dev/null
+++ b/_extensions/drwater/dwev/inst/american-chemical-society.csl
@@ -0,0 +1,280 @@
+
+
diff --git a/_extensions/drwater/dwev/inst/china-national-standard-gb-t-7714-2015-numeric.csl b/_extensions/drwater/dwev/inst/china-national-standard-gb-t-7714-2015-numeric.csl
new file mode 100755
index 0000000..f7c84f0
--- /dev/null
+++ b/_extensions/drwater/dwev/inst/china-national-standard-gb-t-7714-2015-numeric.csl
@@ -0,0 +1,435 @@
+
+
diff --git a/_extensions/drwater/dwev/inst/cover1.pdf b/_extensions/drwater/dwev/inst/cover1.pdf
new file mode 100644
index 0000000..9111c08
Binary files /dev/null and b/_extensions/drwater/dwev/inst/cover1.pdf differ
diff --git a/_extensions/drwater/dwev/inst/cover2.pdf b/_extensions/drwater/dwev/inst/cover2.pdf
new file mode 100644
index 0000000..7b8b2a1
Binary files /dev/null and b/_extensions/drwater/dwev/inst/cover2.pdf differ
diff --git a/_extensions/drwater/dwev/inst/cover3.pdf b/_extensions/drwater/dwev/inst/cover3.pdf
new file mode 100644
index 0000000..4bc55bf
Binary files /dev/null and b/_extensions/drwater/dwev/inst/cover3.pdf differ
diff --git a/_extensions/drwater/dwev/inst/cover4.pdf b/_extensions/drwater/dwev/inst/cover4.pdf
new file mode 100644
index 0000000..2eaf27f
Binary files /dev/null and b/_extensions/drwater/dwev/inst/cover4.pdf differ
diff --git a/_extensions/drwater/dwev/inst/covers.pdf b/_extensions/drwater/dwev/inst/covers.pdf
new file mode 100644
index 0000000..845d1f0
Binary files /dev/null and b/_extensions/drwater/dwev/inst/covers.pdf differ
diff --git a/_extensions/drwater/dwev/inst/covers.pptx b/_extensions/drwater/dwev/inst/covers.pptx
new file mode 100644
index 0000000..0bcbfab
Binary files /dev/null and b/_extensions/drwater/dwev/inst/covers.pptx differ
diff --git a/_extensions/drwater/dwev/inst/drwater-gray1.pdf b/_extensions/drwater/dwev/inst/drwater-gray1.pdf
new file mode 100644
index 0000000..7fa9b94
Binary files /dev/null and b/_extensions/drwater/dwev/inst/drwater-gray1.pdf differ
diff --git a/_extensions/drwater/dwev/inst/drwater-gray1.svg b/_extensions/drwater/dwev/inst/drwater-gray1.svg
new file mode 100644
index 0000000..68a8fc9
--- /dev/null
+++ b/_extensions/drwater/dwev/inst/drwater-gray1.svg
@@ -0,0 +1,53 @@
+
+
diff --git a/_extensions/drwater/dwev/inst/drwater-green0.pdf b/_extensions/drwater/dwev/inst/drwater-green0.pdf
new file mode 100644
index 0000000..88b7fda
Binary files /dev/null and b/_extensions/drwater/dwev/inst/drwater-green0.pdf differ
diff --git a/_extensions/drwater/dwev/inst/drwater-green0.svg b/_extensions/drwater/dwev/inst/drwater-green0.svg
new file mode 100644
index 0000000..00fe227
--- /dev/null
+++ b/_extensions/drwater/dwev/inst/drwater-green0.svg
@@ -0,0 +1,13 @@
+
+
diff --git a/_extensions/drwater/dwev/inst/drwater-green1.pdf b/_extensions/drwater/dwev/inst/drwater-green1.pdf
new file mode 100644
index 0000000..091548e
Binary files /dev/null and b/_extensions/drwater/dwev/inst/drwater-green1.pdf differ
diff --git a/_extensions/drwater/dwev/inst/drwater-green1.svg b/_extensions/drwater/dwev/inst/drwater-green1.svg
new file mode 100644
index 0000000..b6990aa
--- /dev/null
+++ b/_extensions/drwater/dwev/inst/drwater-green1.svg
@@ -0,0 +1,52 @@
+
+
diff --git a/_extensions/drwater/dwev/inst/drwater-greenline0.pdf b/_extensions/drwater/dwev/inst/drwater-greenline0.pdf
new file mode 100644
index 0000000..86786fa
Binary files /dev/null and b/_extensions/drwater/dwev/inst/drwater-greenline0.pdf differ
diff --git a/_extensions/drwater/dwev/inst/drwater-greenline0.svg b/_extensions/drwater/dwev/inst/drwater-greenline0.svg
new file mode 100644
index 0000000..7eec8c8
--- /dev/null
+++ b/_extensions/drwater/dwev/inst/drwater-greenline0.svg
@@ -0,0 +1,31 @@
+
+
diff --git a/_extensions/drwater/dwev/inst/drwater-white0.pdf b/_extensions/drwater/dwev/inst/drwater-white0.pdf
new file mode 100644
index 0000000..ca69ef8
Binary files /dev/null and b/_extensions/drwater/dwev/inst/drwater-white0.pdf differ
diff --git a/_extensions/drwater/dwev/inst/drwater-white0.svg b/_extensions/drwater/dwev/inst/drwater-white0.svg
new file mode 100644
index 0000000..0a12a38
--- /dev/null
+++ b/_extensions/drwater/dwev/inst/drwater-white0.svg
@@ -0,0 +1,13 @@
+
+
diff --git a/_extensions/drwater/dwev/inst/drwater.css b/_extensions/drwater/dwev/inst/drwater.css
new file mode 100755
index 0000000..0bbdcff
--- /dev/null
+++ b/_extensions/drwater/dwev/inst/drwater.css
@@ -0,0 +1,109 @@
+.udot {
+ text-decoration-line: underline;
+ text-decoration-color: rgb(50, 50, 50);
+ text-decoration-style: dashed;
+ text-decoration-thickness: 1px;
+}
+
+.good {
+ background-color: forestgreen;
+ color: lightyellow;
+}
+
+.bad {
+ background-color: orangered;
+ color: lightyellow;
+}
+
+.del {
+ text-decoration-line: line-through;
+ text-decoration-color: rgb(222 13 13);
+ text-decoration-style: initial;
+ text-decoration-thickness: 1.5px;
+}
+
+
+.todo {
+ background-color: darkorange;
+ color: lightyellow;
+}
+
+.com {
+ background-color: #0025ff;
+ font-weight: bold;
+ color: lightyellow;
+}
+
+.add {
+ text-decoration-line: underline;
+ text-decoration-color: rgb(222 13 13);
+ background-color: violet;
+ text-decoration-style: initial;
+ text-decoration-thickness: 2px;
+}
+
+
+del {
+ text-decoration-line: line-through;
+ text-decoration-color: rgb(222 13 13);
+ text-decoration-style: initial;
+ text-decoration-thickness: 1.0px;
+}
+
+
+ins {
+ text-decoration-color: rgb(222 93 93);
+ background-color: violet;
+ text-decoration-style: initial;
+ text-decoration-thickness: 2px;
+}
+
+.clab {
+ background-color: rgb(255, 245, 240);
+}
+
+.rem {
+ background-color: darkorange;
+ color: lightyellow;
+ text-decoration-thickness: 2px;
+}
+
+
+#criticnav {
+ position: fixed;
+ z-index: 1100;
+ top: 0;
+ right: 0;
+ width: 120px;
+ border-bottom: solid 1px #ffffff;
+ margin: 0;
+ padding: 10;
+ background-color: rgb(143 38 38 / 95%);
+ color: #ffffff;
+ font-size: 12px;
+ font-family: "Helvetica Neue", helvetica, arial, sans-serif !important
+}
+
+#criticnav ul {
+ list-style-type: none;
+ width: 90%;
+ margin: 0 auto;
+ padding: 0
+}
+
+#criticnav ul li {
+ display: block;
+ width: 100px;
+ min-width: 80px;
+ text-align: center;
+ padding: 5px 0 3px !important;
+ margin: 5px 2px !important;
+ line-height: 1em;
+ float: center;
+ text-transform: uppercase;
+ cursor: pointer;
+ border-radius: 20px;
+ border: 3px solid rgba(255,255,255,0);
+ color: #fff !important
+}
+
diff --git a/_extensions/drwater/dwev/inst/dweisvogel.tex b/_extensions/drwater/dwev/inst/dweisvogel.tex
new file mode 100644
index 0000000..50b9664
--- /dev/null
+++ b/_extensions/drwater/dwev/inst/dweisvogel.tex
@@ -0,0 +1,1323 @@
+%%
+% Copyright (c) 2017 - 2024, Pascal Wagler;
+% Copyright (c) 2014 - 2024, John MacFarlane
+%
+% All rights reserved.
+%
+% Redistribution and use in source and binary forms, with or without
+% modification, are permitted provided that the following conditions
+% are met:
+%
+% - Redistributions of source code must retain the above copyright
+% notice, this list of conditions and the following disclaimer.
+%
+% - Redistributions in binary form must reproduce the above copyright
+% notice, this list of conditions and the following disclaimer in the
+% documentation and/or other materials provided with the distribution.
+%
+% - Neither the name of John MacFarlane nor the names of other
+% contributors may be used to endorse or promote products derived
+% from this software without specific prior written permission.
+%
+% THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+% "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+% LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+% FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+% COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+% INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+% BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+% LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+% CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+% LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
+% ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+% POSSIBILITY OF SUCH DAMAGE.
+%%
+
+%%
+% This is the Eisvogel pandoc LaTeX template.
+%
+% For usage information and examples visit the official GitHub page:
+% https://github.com/Wandmalfarbe/pandoc-latex-template
+%%
+
+% Options for packages loaded elsewhere
+\PassOptionsToPackage{unicode$for(hyperrefoptions)$,$hyperrefoptions$$endfor$}{hyperref}
+\PassOptionsToPackage{hyphens}{url}
+\PassOptionsToPackage{dvipsnames,svgnames,x11names,table}{xcolor}
+$if(CJKmainfont)$
+\PassOptionsToPackage{space}{xeCJK}
+$endif$
+%
+\documentclass[
+$if(fontsize)$
+ $fontsize$,
+$endif$
+$if(papersize)$
+ $papersize$paper,
+$else$
+ paper=a4,
+$endif$
+$if(beamer)$
+ ignorenonframetext,
+$if(handout)$
+ handout,
+$endif$
+$if(aspectratio)$
+ aspectratio=$aspectratio$,
+$endif$
+$if(babel-lang)$
+ $babel-lang$,
+$endif$
+$endif$
+$for(classoption)$
+ $classoption$$sep$,
+$endfor$
+ ,captions=tableheading
+]{$if(beamer)$$documentclass$$else$$if(isbook)$scrbook$else$scrartcl$endif$$endif$}
+$if(beamer)$
+$if(background-image)$
+\usebackgroundtemplate{%
+ \includegraphics[width=\paperwidth]{$background-image$}%
+}
+% In beamer background-image does not work well when other images are used, so this is the workaround
+\pgfdeclareimage[width=\paperwidth,height=\paperheight]{background}{$background-image$}
+\usebackgroundtemplate{\pgfuseimage{background}}
+$endif$
+
+\usepackage{pgfpages}
+\setbeamertemplate{caption}[numbered]
+\setbeamertemplate{caption label separator}{: }
+\setbeamercolor{caption name}{fg=normal text.fg}
+\beamertemplatenavigationsymbols$if(navigation)$$navigation$$else$empty$endif$
+$for(beameroption)$
+\setbeameroption{$beameroption$}
+$endfor$
+% Prevent slide breaks in the middle of a paragraph
+\widowpenalties 1 10000
+\raggedbottom
+$if(section-titles)$
+\setbeamertemplate{part page}{
+ \centering
+ \begin{beamercolorbox}[sep=16pt,center]{part title}
+ \usebeamerfont{part title}\insertpart\par
+ \end{beamercolorbox}
+}
+\setbeamertemplate{section page}{
+ \centering
+ \begin{beamercolorbox}[sep=12pt,center]{section title}
+ \usebeamerfont{section title}\insertsection\par
+ \end{beamercolorbox}
+}
+\setbeamertemplate{subsection page}{
+ \centering
+ \begin{beamercolorbox}[sep=8pt,center]{subsection title}
+ \usebeamerfont{subsection title}\insertsubsection\par
+ \end{beamercolorbox}
+}
+\AtBeginPart{
+ \frame{\partpage}
+}
+\AtBeginSection{
+ \ifbibliography
+ \else
+ \frame{\sectionpage}
+ \fi
+}
+\AtBeginSubsection{
+ \frame{\subsectionpage}
+}
+$endif$
+$endif$
+$if(beamerarticle)$
+\usepackage{beamerarticle} % needs to be loaded first
+$endif$
+\usepackage{amsmath,amssymb}
+$if(linestretch)$
+\usepackage{setspace}
+$else$
+% Use setspace anyway because we change the default line spacing.
+% The spacing is changed early to affect the titlepage and the TOC.
+\usepackage{setspace}
+\setstretch{1.2}
+$endif$
+\usepackage{iftex}
+\ifPDFTeX
+ \usepackage[$if(fontenc)$$fontenc$$else$T1$endif$]{fontenc}
+ \usepackage[utf8]{inputenc}
+ \usepackage{textcomp} % provide euro and other symbols
+\else % if luatex or xetex
+$if(mathspec)$
+ \ifXeTeX
+ \usepackage{mathspec} % this also loads fontspec
+ \else
+ \usepackage{unicode-math} % this also loads fontspec
+ \fi
+$else$
+ \usepackage{unicode-math} % this also loads fontspec
+$endif$
+ \defaultfontfeatures{Scale=MatchLowercase}$-- must come before Beamer theme
+ \defaultfontfeatures[\rmfamily]{Ligatures=TeX,Scale=1}
+\fi
+$if(fontfamily)$
+$else$
+$-- Set default font before Beamer theme so the theme can override it
+\usepackage{lmodern}
+$endif$
+$-- Set Beamer theme before user font settings so they can override theme
+$if(beamer)$
+$if(theme)$
+\usetheme[$for(themeoptions)$$themeoptions$$sep$,$endfor$]{$theme$}
+$endif$
+$if(colortheme)$
+\usecolortheme{$colortheme$}
+$endif$
+$if(fonttheme)$
+\usefonttheme{$fonttheme$}
+$endif$
+$if(mainfont)$
+\usefonttheme{serif} % use mainfont rather than sansfont for slide text
+$endif$
+$if(innertheme)$
+\useinnertheme{$innertheme$}
+$endif$
+$if(outertheme)$
+\useoutertheme{$outertheme$}
+$endif$
+$endif$
+$-- User font settings (must come after default font and Beamer theme)
+$if(fontfamily)$
+\usepackage[$for(fontfamilyoptions)$$fontfamilyoptions$$sep$,$endfor$]{$fontfamily$}
+$endif$
+\ifPDFTeX\else
+ % xetex/luatex font selection
+$if(mainfont)$
+ $if(mainfontfallback)$
+ \ifLuaTeX
+ \usepackage{luaotfload}
+ \directlua{luaotfload.add_fallback("mainfontfallback",{
+ $for(mainfontfallback)$"$mainfontfallback$"$sep$,$endfor$
+ })}
+ \fi
+ $endif$
+ \setmainfont[$for(mainfontoptions)$$mainfontoptions$$sep$,$endfor$$if(mainfontfallback)$,RawFeature={fallback=mainfontfallback}$endif$]{$mainfont$}
+$endif$
+$if(sansfont)$
+ $if(sansfontfallback)$
+ \ifLuaTeX
+ \usepackage{luaotfload}
+ \directlua{luaotfload.add_fallback("sansfontfallback",{
+ $for(sansfontfallback)$"$sansfontfallback$"$sep$,$endfor$
+ })}
+ \fi
+ $endif$
+ \setsansfont[$for(sansfontoptions)$$sansfontoptions$$sep$,$endfor$$if(sansfontfallback)$,RawFeature={fallback=sansfontfallback}$endif$]{$sansfont$}
+$endif$
+$if(monofont)$
+ $if(monofontfallback)$
+ \ifLuaTeX
+ \usepackage{luaotfload}
+ \directlua{luaotfload.add_fallback("monofontfallback",{
+ $for(monofontfallback)$"$monofontfallback$"$sep$,$endfor$
+ })}
+ \fi
+ $endif$
+ \setmonofont[$for(monofontoptions)$$monofontoptions$$sep$,$endfor$$if(monofontfallback)$,RawFeature={fallback=monofontfallback}$endif$]{$monofont$}
+$endif$
+$for(fontfamilies)$
+ \newfontfamily{$fontfamilies.name$}[$for(fontfamilies.options)$$fontfamilies.options$$sep$,$endfor$]{$fontfamilies.font$}
+$endfor$
+$if(mathfont)$
+$if(mathspec)$
+ \ifXeTeX
+ \setmathfont(Digits,Latin,Greek)[$for(mathfontoptions)$$mathfontoptions$$sep$,$endfor$]{$mathfont$}
+ \else
+ \setmathfont[$for(mathfontoptions)$$mathfontoptions$$sep$,$endfor$]{$mathfont$}
+ \fi
+$else$
+ \setmathfont[$for(mathfontoptions)$$mathfontoptions$$sep$,$endfor$]{$mathfont$}
+$endif$
+$endif$
+$if(CJKmainfont)$
+ \ifXeTeX
+ \usepackage{xeCJK}
+ \setCJKmainfont[$for(CJKoptions)$$CJKoptions$$sep$,$endfor$]{$CJKmainfont$}
+ $if(CJKsansfont)$
+ \setCJKsansfont[$for(CJKoptions)$$CJKoptions$$sep$,$endfor$]{$CJKsansfont$}
+ $endif$
+ $if(CJKmonofont)$
+ \setCJKmonofont[$for(CJKoptions)$$CJKoptions$$sep$,$endfor$]{$CJKmonofont$}
+ $endif$
+ \fi
+$endif$
+$if(luatexjapresetoptions)$
+ \ifLuaTeX
+ \usepackage[$for(luatexjapresetoptions)$$luatexjapresetoptions$$sep$,$endfor$]{luatexja-preset}
+ \fi
+$endif$
+$if(CJKmainfont)$
+ \ifLuaTeX
+ \usepackage[$for(luatexjafontspecoptions)$$luatexjafontspecoptions$$sep$,$endfor$]{luatexja-fontspec}
+ \setmainjfont[$for(CJKoptions)$$CJKoptions$$sep$,$endfor$]{$CJKmainfont$}
+ \fi
+$endif$
+\fi
+$if(zero-width-non-joiner)$
+%% Support for zero-width non-joiner characters.
+\makeatletter
+\def\zerowidthnonjoiner{%
+ % Prevent ligatures and adjust kerning, but still support hyphenating.
+ \texorpdfstring{%
+ \TextOrMath{\nobreak\discretionary{-}{}{\kern.03em}%
+ \ifvmode\else\nobreak\hskip\z@skip\fi}{}%
+ }{}%
+}
+\makeatother
+\ifPDFTeX
+ \DeclareUnicodeCharacter{200C}{\zerowidthnonjoiner}
+\else
+ \catcode`^^^^200c=\active
+ \protected\def ^^^^200c{\zerowidthnonjoiner}
+\fi
+%% End of ZWNJ support
+$endif$
+% Use upquote if available, for straight quotes in verbatim environments
+\IfFileExists{upquote.sty}{\usepackage{upquote}}{}
+\IfFileExists{microtype.sty}{% use microtype if available
+ \usepackage[$for(microtypeoptions)$$microtypeoptions$$sep$,$endfor$]{microtype}
+ \UseMicrotypeSet[protrusion]{basicmath} % disable protrusion for tt fonts
+}{}
+$if(indent)$
+$else$
+\makeatletter
+\@ifundefined{KOMAClassName}{% if non-KOMA class
+ \IfFileExists{parskip.sty}{%
+ \usepackage{parskip}
+ }{% else
+ \setlength{\parindent}{0pt}
+ \setlength{\parskip}{6pt plus 2pt minus 1pt}}
+}{% if KOMA class
+ \KOMAoptions{parskip=half}}
+\makeatother
+$endif$
+$if(verbatim-in-note)$
+\usepackage{fancyvrb}
+$endif$
+\usepackage{xcolor}
+\definecolor{default-linkcolor}{HTML}{A50000}
+\definecolor{default-filecolor}{HTML}{A50000}
+\definecolor{default-citecolor}{HTML}{4077C0}
+\definecolor{default-urlcolor}{HTML}{4077C0}
+$if(footnotes-pretty)$
+% load footmisc in order to customize footnotes (footmisc has to be loaded before hyperref, cf. https://tex.stackexchange.com/a/169124/144087)
+\usepackage[hang,flushmargin,bottom,multiple]{footmisc}
+\setlength{\footnotemargin}{0.8em} % set space between footnote nr and text
+\setlength{\footnotesep}{\baselineskip} % set space between multiple footnotes
+\setlength{\skip\footins}{0.3cm} % set space between page content and footnote
+\setlength{\footskip}{0.9cm} % set space between footnote and page bottom
+$endif$
+$if(geometry)$
+$if(beamer)$
+\geometry{$for(geometry)$$geometry$$sep$,$endfor$}
+$else$
+\usepackage[$for(geometry)$$geometry$$sep$,$endfor$]{geometry}
+$endif$
+$else$
+$if(beamer)$
+$else$
+\usepackage[margin=2.5cm,includehead=true,includefoot=true,centering,$for(geometry)$$geometry$$sep$,$endfor$]{geometry}
+$endif$
+$endif$
+$if(titlepage-logo)$
+\usepackage[export]{adjustbox}
+\usepackage{graphicx}
+$endif$
+$if(beamer)$
+\newif\ifbibliography
+$endif$
+$if(listings)$
+\usepackage{listings}
+\newcommand{\passthrough}[1]{#1}
+\lstset{defaultdialect=[5.3]Lua}
+\lstset{defaultdialect=[x86masm]Assembler}
+$endif$
+$if(listings-no-page-break)$
+\usepackage{etoolbox}
+\BeforeBeginEnvironment{lstlisting}{\par\noindent\begin{minipage}{\linewidth}}
+\AfterEndEnvironment{lstlisting}{\end{minipage}\par\addvspace{\topskip}}
+$endif$
+$if(lhs)$
+\lstnewenvironment{code}{\lstset{language=Haskell,basicstyle=\small\ttfamily}}{}
+$endif$
+$if(highlighting-macros)$
+$highlighting-macros$
+
+% Workaround/bugfix from jannick0.
+% See https://github.com/jgm/pandoc/issues/4302#issuecomment-360669013)
+% or https://github.com/Wandmalfarbe/pandoc-latex-template/issues/2
+%
+% Redefine the verbatim environment 'Highlighting' to break long lines (with
+% the help of fvextra). Redefinition is necessary because it is unlikely that
+% pandoc includes fvextra in the default template.
+\usepackage{fvextra}
+\DefineVerbatimEnvironment{Highlighting}{Verbatim}{breaklines,fontsize=$if(code-block-font-size)$$code-block-font-size$$else$\small$endif$,commandchars=\\\{\}}
+
+$endif$
+
+% 为中文添加支持 by Ming Su
+$if(CJK)$
+$if(isbook)$
+\usepackage{ctex} %调用中文字体宏包
+\usepackage{indentfirst} %调用首行缩进宏包
+\usepackage{ctex} % 确保中文字体支持
+\usepackage{zhnumber}
+% 修改 chapter 格式为 "第X章"
+% \renewcommand{\chapterformat}{第~\thechapter~章}
+% \renewcommand{\chapterformat}{第\zhnumber{\thechapter}章}
+\renewcommand{\chaptermarkformat}{第~\zhnumber{\thechapter}~章}
+\renewcommand{\chapterformat}{第\zhnumber{\thechapter}章}
+\renewcommand*{\chapterlinesformat}[3]{%
+ \parbox{\linewidth}{\centering #2~\quad~#3} % 居中 + "·" 分隔
+ % 或改用冒号分隔:
+ % \parbox{\linewidth}{\centering #2:#3}
+}
+\RedeclareSectionCommand[
+ beforeskip=1.5em plus 0.5em minus 0.5em,
+ afterskip=1em plus 0.2em,
+ font=\large\bfseries
+]{section}
+\usepackage{zhnumber} % 确保已加载(或直接用 ctex)
+% 修改目录中的章节编号为中文
+\addtokomafont{chapterentry}{\normalfont} % 可选:调整目录字体
+\renewcommand*{\chapterformat}{第\zhnumber{\thechapter}章} % 正文标题格式
+\renewcommand*{\chaptermarkformat}{第\zhnumber{\thechapter}章\quad} % 页眉标题格式
+% 关键!覆盖目录中的章节编号
+\renewcommand{\addchaptertocentry}[2]{%
+ \addtocentrydefault{chapter}{第\zhnumber{#1}章}{#2}%
+}
+\RedeclareSectionCommand[
+ tocentryindent=0pt,
+ tocentrynumwidth=3.5em % 确保编号区域足够宽
+]{chapter}
+$endif$
+$endif$
+
+$if(tables)$
+\usepackage{longtable,booktabs,array}
+$if(multirow)$
+\usepackage{multirow}
+$endif$
+\usepackage{calc} % for calculating minipage widths
+$if(beamer)$
+\usepackage{caption}
+% Make caption package work with longtable
+\makeatletter
+\def\fnum@table{\tablename~\thetable}
+\makeatother
+$else$
+% Correct order of tables after \paragraph or \subparagraph
+\usepackage{etoolbox}
+\makeatletter
+\patchcmd\longtable{\par}{\if@noskipsec\mbox{}\fi\par}{}{}
+\makeatother
+% Allow footnotes in longtable head/foot
+\IfFileExists{footnotehyper.sty}{\usepackage{footnotehyper}}{\usepackage{footnote}}
+\makesavenoteenv{longtable}
+$endif$
+$endif$
+% add backlinks to footnote references, cf. https://tex.stackexchange.com/questions/302266/make-footnote-clickable-both-ways
+$if(footnotes-disable-backlinks)$
+$else$
+\usepackage{footnotebackref}
+$endif$
+$if(graphics)$
+\usepackage{graphicx}
+\makeatletter
+% \def\maxwidth{\ifdim\Gin@nat@width>\linewidth\linewidth\else\Gin@nat@width\fi}
+% \def\maxheight{\ifdim\Gin@nat@height>\textheight\textheight\else\Gin@nat@height\fi}
+% \makeatother
+% % Scale images if necessary, so that they will not overflow the page
+% % margins by default, and it is still possible to overwrite the defaults
+% % using explicit options in \includegraphics[width, height, ...]{}
+% \setkeys{Gin}{width=\maxwidth,height=\maxheight,keepaspectratio}
+\newsavebox\pandoc@box
+\newcommand*\pandocbounded[1]{% scales image to fit in text height/width
+ \sbox\pandoc@box{#1}%
+ \Gscale@div\@tempa{\textheight}{\dimexpr\ht\pandoc@box+\dp\pandoc@box\relax}%
+ \Gscale@div\@tempb{\linewidth}{\wd\pandoc@box}%
+ \ifdim\@tempb\p@<\@tempa\p@\let\@tempa\@tempb\fi% select the smaller of both
+ \ifdim\@tempa\p@<\p@\scalebox{\@tempa}{\usebox\pandoc@box}%
+ \else\usebox{\pandoc@box}%
+ \fi%
+}
+% Set default figure placement to htbp
+\makeatletter
+\def\fps@figure{htbp}
+\makeatother
+% \makeatletter Old options from template, replaced with quarto defaults above
+% \newsavebox\pandoc@box
+% \newcommand*\pandocbounded[1]{% scales image to fit in text height/width
+% \sbox\pandoc@box{#1}%
+% \Gscale@div\@tempa{\textheight}{\dimexpr\ht\pandoc@box+\dp\pandoc@box\relax}%
+% \Gscale@div\@tempb{\linewidth}{\wd\pandoc@box}%
+% \ifdim\@tempb\p@<\@tempa\p@\let\@tempa\@tempb\fi% select the smaller of both
+% \ifdim\@tempa\p@<\p@\scalebox{\@tempa}{\usebox\pandoc@box}%
+% \else\usebox{\pandoc@box}%
+% \fi%
+% }
+% % Set default figure placement to htbp
+% % Make use of float-package and set default placement for figures to H.
+% % The option H means 'PUT IT HERE' (as opposed to the standard h option which means 'You may put it here if you like').
+% \usepackage{float}
+% \floatplacement{figure}{$if(float-placement-figure)$$float-placement-figure$$else$H$endif$}
+% \makeatother
+$endif$
+$if(svg)$
+\usepackage{svg}
+$endif$
+$if(strikeout)$
+$-- also used for underline
+\ifLuaTeX
+ \usepackage{luacolor}
+ \usepackage[soul]{lua-ul}
+\else
+\usepackage{soul}
+$if(beamer)$
+ \makeatletter
+ \let\HL\hl
+ \renewcommand\hl{% fix for beamer highlighting
+ \let\set@color\beamerorig@set@color
+ \let\reset@color\beamerorig@reset@color
+ \HL}
+ \makeatother
+$endif$
+$if(CJKmainfont)$
+ \ifXeTeX
+ % soul's \st doesn't work for CJK:
+ \usepackage{xeCJKfntef}
+ \renewcommand{\st}[1]{\sout{#1}}
+ \fi
+$endif$
+\fi
+$endif$
+\setlength{\emergencystretch}{3em} % prevent overfull lines
+\providecommand{\tightlist}{%
+ \setlength{\itemsep}{0pt}\setlength{\parskip}{0pt}}
+$if(numbersections)$
+\setcounter{secnumdepth}{$if(secnumdepth)$$secnumdepth$$else$5$endif$}
+$else$
+\setcounter{secnumdepth}{-\maxdimen} % remove section numbering
+$endif$
+$if(subfigure)$
+\usepackage{subcaption}
+$endif$
+$if(beamer)$
+$else$
+$if(block-headings)$
+% Make \paragraph and \subparagraph free-standing
+\makeatletter
+\ifx\paragraph\undefined\else
+ \let\oldparagraph\paragraph
+ \renewcommand{\paragraph}{
+ \@ifstar
+ \xxxParagraphStar
+ \xxxParagraphNoStar
+ }
+ \newcommand{\xxxParagraphStar}[1]{\oldparagraph*{#1}\mbox{}}
+ \newcommand{\xxxParagraphNoStar}[1]{\oldparagraph{#1}\mbox{}}
+\fi
+\ifx\subparagraph\undefined\else
+ \let\oldsubparagraph\subparagraph
+ \renewcommand{\subparagraph}{
+ \@ifstar
+ \xxxSubParagraphStar
+ \xxxSubParagraphNoStar
+ }
+ \newcommand{\xxxSubParagraphStar}[1]{\oldsubparagraph*{#1}\mbox{}}
+ \newcommand{\xxxSubParagraphNoStar}[1]{\oldsubparagraph{#1}\mbox{}}
+\fi
+\makeatother
+$endif$
+$endif$
+$if(pagestyle)$
+\pagestyle{$pagestyle$}
+$endif$
+$if(csl-refs)$
+% definitions for citeproc citations
+\NewDocumentCommand\citeproctext{}{}
+\NewDocumentCommand\citeproc{mm}{%
+ \begingroup\def\citeproctext{#2}\cite{#1}\endgroup}
+\makeatletter
+ % allow citations to break across lines
+ \let\@cite@ofmt\@firstofone
+ % avoid brackets around text for \cite:
+ \def\@biblabel#1{}
+ \def\@cite#1#2{{#1\if@tempswa , #2\fi}}
+\makeatother
+\newlength{\cslhangindent}
+\setlength{\cslhangindent}{1.5em}
+\newlength{\csllabelwidth}
+\setlength{\csllabelwidth}{3em}
+\newenvironment{CSLReferences}[2] % #1 hanging-indent, #2 entry-spacing
+ {\begin{list}{}{%
+ \setlength{\itemindent}{0pt}
+ \setlength{\leftmargin}{0pt}
+ \setlength{\parsep}{0pt}
+ % turn on hanging indent if param 1 is 1
+ \ifodd #1
+ \setlength{\leftmargin}{\cslhangindent}
+ \setlength{\itemindent}{-1\cslhangindent}
+ \fi
+ % set entry spacing
+ \setlength{\itemsep}{#2\baselineskip}}}
+ {\end{list}}
+\usepackage{calc}
+\newcommand{\CSLBlock}[1]{\hfill\break\parbox[t]{\linewidth}{\strut\ignorespaces#1\strut}}
+\newcommand{\CSLLeftMargin}[1]{\parbox[t]{\csllabelwidth}{\strut#1\strut}}
+\newcommand{\CSLRightInline}[1]{\parbox[t]{\linewidth - \csllabelwidth}{\strut#1\strut}}
+\newcommand{\CSLIndent}[1]{\hspace{\cslhangindent}#1}
+$endif$
+$if(lang)$
+\ifLuaTeX
+\usepackage[bidi=basic]{babel}
+\else
+\usepackage[bidi=default]{babel}
+\fi
+$if(babel-lang)$
+\babelprovide[main,import]{$babel-lang$}
+$if(mainfont)$
+\ifPDFTeX
+\else
+\babelfont{rm}[$for(mainfontoptions)$$mainfontoptions$$sep$,$endfor$$if(mainfontfallback)$,RawFeature={fallback=mainfontfallback}$endif$]{$mainfont$}
+\fi
+$endif$
+$endif$
+$for(babel-otherlangs)$
+\babelprovide[import]{$babel-otherlangs$}
+$endfor$
+$for(babelfonts/pairs)$
+\babelfont[$babelfonts.key$]{rm}{$babelfonts.value$}
+$endfor$
+% get rid of language-specific shorthands (see #6817):
+\let\LanguageShortHands\languageshorthands
+\def\languageshorthands#1{}
+$if(selnolig-langs)$
+\ifLuaTeX
+ \usepackage[$for(selnolig-langs)$$it$$sep$,$endfor$]{selnolig} % disable illegal ligatures
+\fi
+$endif$
+$endif$
+$for(header-includes)$
+$header-includes$
+$endfor$
+$if(dir)$
+\ifPDFTeX
+ \TeXXeTstate=1
+ \newcommand{\RL}[1]{\beginR #1\endR}
+ \newcommand{\LR}[1]{\beginL #1\endL}
+ \newenvironment{RTL}{\beginR}{\endR}
+ \newenvironment{LTR}{\beginL}{\endL}
+\fi
+$endif$
+$if(natbib)$
+\usepackage[$natbiboptions$]{natbib}
+\bibliographystyle{$if(biblio-style)$$biblio-style$$else$plainnat$endif$}
+$endif$
+$if(biblatex)$
+\usepackage[$if(biblio-style)$style=$biblio-style$,$endif$$for(biblatexoptions)$$biblatexoptions$$sep$,$endfor$]{biblatex}
+$for(bibliography)$
+\addbibresource{$bibliography$}
+$endfor$
+$endif$
+$if(nocite-ids)$
+\nocite{$for(nocite-ids)$$it$$sep$, $endfor$}
+$endif$
+$if(csquotes)$
+\usepackage{csquotes}
+$endif$
+\usepackage{bookmark}
+\IfFileExists{xurl.sty}{\usepackage{xurl}}{} % add URL line breaks if available
+\urlstyle{$if(urlstyle)$$urlstyle$$else$same$endif$}
+$if(links-as-notes)$
+% Make links footnotes instead of hotlinks:
+\DeclareRobustCommand{\href}[2]{#2\footnote{\url{#1}}}
+$endif$
+$if(verbatim-in-note)$
+\VerbatimFootnotes % allow verbatim text in footnotes
+$endif$
+\hypersetup{
+$if(title-meta)$
+ pdftitle={$title-meta$},
+$endif$
+$if(author-meta)$
+ pdfauthor={$author-meta$},
+$endif$
+$if(lang)$
+ pdflang={$lang$},
+$endif$
+$if(subject)$
+pdfsubject={$subject$},
+$endif$
+$if(keywords)$
+ pdfkeywords={$for(keywords)$$keywords$$sep$, $endfor$},
+$endif$
+$if(colorlinks)$
+ colorlinks=true,
+ linkcolor={$if(linkcolor)$$linkcolor$$else$default-linkcolor$endif$},
+ filecolor={$if(filecolor)$$filecolor$$else$default-filecolor$endif$},
+ citecolor={$if(citecolor)$$citecolor$$else$default-citecolor$endif$},
+ urlcolor={$if(urlcolor)$$urlcolor$$else$default-urlcolor$endif$},
+$else$
+$if(boxlinks)$
+$else$
+ hidelinks,
+$endif$
+$endif$
+ breaklinks=true,
+ pdfcreator={LaTeX via pandoc with the Eisvogel template}}
+$if(title)$
+\title{$title$$if(thanks)$\thanks{$thanks$}$endif$}
+$endif$
+$if(subtitle)$
+$if(beamer)$
+$else$
+\usepackage{etoolbox}
+\makeatletter
+\providecommand{\subtitle}[1]{% add subtitle to \maketitle
+ \apptocmd{\@title}{\par {\large #1 \par}}{}{}
+}
+\makeatother
+$endif$
+\subtitle{$subtitle$}
+$endif$
+\author{$for(author)$$author$$sep$ \and $endfor$}
+\date{$date$}
+$if(beamer)$
+$if(institute)$
+\institute{$for(institute)$$institute$$sep$ \and $endfor$}
+$endif$
+$if(titlegraphic)$
+\titlegraphic{\includegraphics$if(titlegraphicoptions)$[$for(titlegraphicoptions)$$titlegraphicoptions$$sep$, $endfor$]$endif${$titlegraphic$}}
+$endif$
+$if(logo)$
+\logo{\includegraphics{$logo$}}
+$endif$
+$endif$
+
+
+
+%%
+%% added
+%%
+
+$if(page-background)$
+\usepackage[pages=all]{background}
+$endif$
+
+%
+% for the background color of the title page
+%
+$if(titlepage)$
+\usepackage{pagecolor}
+\usepackage{afterpage}
+$if(titlepage-background)$
+\usepackage{tikz}
+$endif$
+$if(geometry)$
+$else$
+\usepackage[margin=2.5cm,includehead=true,includefoot=true,centering]{geometry}
+$endif$
+$endif$
+
+%
+% break urls
+%
+\PassOptionsToPackage{hyphens}{url}
+
+%
+% When using babel or polyglossia with biblatex, loading csquotes is recommended
+% to ensure that quoted texts are typeset according to the rules of your main language.
+%
+\usepackage{csquotes}
+
+%
+% captions
+%
+\definecolor{caption-color}{HTML}{777777}
+$if(beamer)$
+$else$
+\usepackage[font={stretch=1.2}, textfont={color=caption-color}, position=top, skip=4mm, labelfont=bf, singlelinecheck=false, justification=$if(caption-justification)$$caption-justification$$else$raggedright$endif$]{caption}
+\setcapindent{0em}
+$endif$
+
+%
+% blockquote
+%
+\definecolor{blockquote-border}{RGB}{221,221,221}
+\definecolor{blockquote-text}{RGB}{119,119,119}
+\usepackage{mdframed}
+\newmdenv[rightline=false,bottomline=false,topline=false,linewidth=3pt,linecolor=blockquote-border,skipabove=\parskip]{customblockquote}
+\renewenvironment{quote}{\begin{customblockquote}\list{}{\rightmargin=0em\leftmargin=0em}%
+\item\relax\color{blockquote-text}\ignorespaces}{\unskip\unskip\endlist\end{customblockquote}}
+
+%
+% Source Sans Pro as the default font family
+% Source Code Pro for monospace text
+%
+% 'default' option sets the default
+% font family to Source Sans Pro, not \sfdefault.
+%
+\ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex
+ $if(fontfamily)$
+ $else$
+ \usepackage[default]{sourcesanspro}
+ \usepackage{sourcecodepro}
+ $endif$
+\else % if not pdftex
+ $if(mainfont)$
+ $else$
+ \usepackage[default]{sourcesanspro}
+ \usepackage{sourcecodepro}
+
+ % XeLaTeX specific adjustments for straight quotes: https://tex.stackexchange.com/a/354887
+ % This issue is already fixed (see https://github.com/silkeh/latex-sourcecodepro/pull/5) but the
+ % fix is still unreleased.
+ % TODO: Remove this workaround when the new version of sourcecodepro is released on CTAN.
+ \ifxetex
+ \makeatletter
+ \defaultfontfeatures[\ttfamily]
+ { Numbers = \sourcecodepro@figurestyle,
+ Scale = \SourceCodePro@scale,
+ Extension = .otf }
+ \setmonofont
+ [ UprightFont = *-\sourcecodepro@regstyle,
+ ItalicFont = *-\sourcecodepro@regstyle It,
+ BoldFont = *-\sourcecodepro@boldstyle,
+ BoldItalicFont = *-\sourcecodepro@boldstyle It ]
+ {SourceCodePro}
+ \makeatother
+ \fi
+ $endif$
+\fi
+
+
+% setup for chinese font, by Ming
+\setCJKmainfont{$CJKmainfont$}[BoldFont=$CJKboldfont$, ItalicFont=$CJKitalicfont$]
+
+%
+% heading color
+%
+\definecolor{heading-color}{RGB}{40,40,40}
+$if(beamer)$
+$else$
+\addtokomafont{section}{\color{heading-color}}
+$endif$
+% When using the classes report, scrreprt, book,
+% scrbook or memoir, uncomment the following line.
+%\addtokomafont{chapter}{\color{heading-color}}
+
+%
+% variables for title, author and date
+%
+$if(beamer)$
+$else$
+\usepackage{titling}
+\title{$title$}
+\author{$for(author)$$author$$sep$, $endfor$}
+\date{$date$}
+$endif$
+
+%
+% tables
+%
+$if(tables)$
+
+\definecolor{table-row-color}{HTML}{F5F5F5}
+\definecolor{table-rule-color}{HTML}{999999}
+
+%\arrayrulecolor{black!40}
+\arrayrulecolor{table-rule-color} % color of \toprule, \midrule, \bottomrule
+\setlength\heavyrulewidth{0.3ex} % thickness of \toprule, \bottomrule
+\renewcommand{\arraystretch}{1.3} % spacing (padding)
+
+$if(table-use-row-colors)$
+% Unfortunately the colored cells extend beyond the edge of the
+% table because pandoc uses @-expressions (@{}) like so:
+%
+% \begin{longtable}[]{@{}ll@{}}
+% \end{longtable}
+%
+% https://en.wikibooks.org/wiki/LaTeX/Tables#.40-expressions
+\usepackage{etoolbox}
+\AtBeginEnvironment{longtable}{\rowcolors{2}{}{table-row-color!100}}
+\preto{\toprule}{\hiderowcolors}{}{}
+\appto{\endhead}{\showrowcolors}{}{}
+\appto{\endfirsthead}{\showrowcolors}{}{}
+$endif$
+$endif$
+
+%
+% remove paragraph indentation
+%
+% \setlength{\parindent}{0pt}
+$if(parindent)$
+\setlength{\parindent}{2em} %设置首行缩进为2字符
+$else$
+\setlength{\parindent}{0pt}
+$endif$
+\setlength{\parskip}{6pt plus 2pt minus 1pt}
+\setlength{\emergencystretch}{3em} % prevent overfull lines
+
+
+
+%
+%
+% Listings
+%
+%
+
+$if(listings)$
+
+%
+% general listing colors
+%
+\definecolor{listing-background}{HTML}{F7F7F7}
+\definecolor{listing-rule}{HTML}{B3B2B3}
+\definecolor{listing-numbers}{HTML}{B3B2B3}
+\definecolor{listing-text-color}{HTML}{000000}
+\definecolor{listing-keyword}{HTML}{435489}
+\definecolor{listing-keyword-2}{HTML}{1284CA} % additional keywords
+\definecolor{listing-keyword-3}{HTML}{9137CB} % additional keywords
+\definecolor{listing-identifier}{HTML}{435489}
+\definecolor{listing-string}{HTML}{00999A}
+\definecolor{listing-comment}{HTML}{8E8E8E}
+
+\lstdefinestyle{eisvogel_listing_style}{
+ language = java,
+$if(listings-disable-line-numbers)$
+ xleftmargin = 0.6em,
+ framexleftmargin = 0.4em,
+$else$
+ numbers = left,
+ xleftmargin = 2.7em,
+ framexleftmargin = 2.5em,
+$endif$
+ backgroundcolor = \color{listing-background},
+ basicstyle = \color{listing-text-color}\linespread{1.0}%
+ \lst@ifdisplaystyle%
+ $if(code-block-font-size)$$code-block-font-size$$else$\small$endif$%
+ \fi\ttfamily{},
+ breaklines = true,
+ frame = single,
+ framesep = 0.19em,
+ rulecolor = \color{listing-rule},
+ frameround = ffff,
+ tabsize = 4,
+ numberstyle = \color{listing-numbers},
+ aboveskip = 1.0em,
+ belowskip = 0.1em,
+ abovecaptionskip = 0em,
+ belowcaptionskip = 1.0em,
+ keywordstyle = {\color{listing-keyword}\bfseries},
+ keywordstyle = {[2]\color{listing-keyword-2}\bfseries},
+ keywordstyle = {[3]\color{listing-keyword-3}\bfseries\itshape},
+ sensitive = true,
+ identifierstyle = \color{listing-identifier},
+ commentstyle = \color{listing-comment},
+ stringstyle = \color{listing-string},
+ showstringspaces = false,
+ escapeinside = {/*@}{@*/}, % Allow LaTeX inside these special comments
+ literate =
+ {á}{{\'a}}1 {é}{{\'e}}1 {í}{{\'i}}1 {ó}{{\'o}}1 {ú}{{\'u}}1
+ {Á}{{\'A}}1 {É}{{\'E}}1 {Í}{{\'I}}1 {Ó}{{\'O}}1 {Ú}{{\'U}}1
+ {à}{{\`a}}1 {è}{{\`e}}1 {ì}{{\`i}}1 {ò}{{\`o}}1 {ù}{{\`u}}1
+ {À}{{\`A}}1 {È}{{\`E}}1 {Ì}{{\`I}}1 {Ò}{{\`O}}1 {Ù}{{\`U}}1
+ {ä}{{\"a}}1 {ë}{{\"e}}1 {ï}{{\"i}}1 {ö}{{\"o}}1 {ü}{{\"u}}1
+ {Ä}{{\"A}}1 {Ë}{{\"E}}1 {Ï}{{\"I}}1 {Ö}{{\"O}}1 {Ü}{{\"U}}1
+ {â}{{\^a}}1 {ê}{{\^e}}1 {î}{{\^i}}1 {ô}{{\^o}}1 {û}{{\^u}}1
+ {Â}{{\^A}}1 {Ê}{{\^E}}1 {Î}{{\^I}}1 {Ô}{{\^O}}1 {Û}{{\^U}}1
+ {œ}{{\oe}}1 {Œ}{{\OE}}1 {æ}{{\ae}}1 {Æ}{{\AE}}1 {ß}{{\ss}}1
+ {ç}{{\c c}}1 {Ç}{{\c C}}1 {ø}{{\o}}1 {å}{{\r a}}1 {Å}{{\r A}}1
+ {€}{{\EUR}}1 {£}{{\pounds}}1 {«}{{\guillemotleft}}1
+ {»}{{\guillemotright}}1 {ñ}{{\~n}}1 {Ñ}{{\~N}}1 {¿}{{?`}}1
+ {…}{{\ldots}}1 {≥}{{>=}}1 {≤}{{<=}}1 {„}{{\glqq}}1 {“}{{\grqq}}1
+ {”}{{''}}1
+}
+\lstset{style=eisvogel_listing_style}
+
+%
+% Java (Java SE 12, 2019-06-22)
+%
+\lstdefinelanguage{Java}{
+ morekeywords={
+ % normal keywords (without data types)
+ abstract,assert,break,case,catch,class,continue,default,
+ do,else,enum,exports,extends,final,finally,for,if,implements,
+ import,instanceof,interface,module,native,new,package,private,
+ protected,public,requires,return,static,strictfp,super,switch,
+ synchronized,this,throw,throws,transient,try,volatile,while,
+ % var is an identifier
+ var
+ },
+ morekeywords={[2] % data types
+ % primitive data types
+ boolean,byte,char,double,float,int,long,short,
+ % String
+ String,
+ % primitive wrapper types
+ Boolean,Byte,Character,Double,Float,Integer,Long,Short
+ % number types
+ Number,AtomicInteger,AtomicLong,BigDecimal,BigInteger,DoubleAccumulator,DoubleAdder,LongAccumulator,LongAdder,Short,
+ % other
+ Object,Void,void
+ },
+ morekeywords={[3] % literals
+ % reserved words for literal values
+ null,true,false,
+ },
+ sensitive,
+ morecomment = [l]//,
+ morecomment = [s]{/*}{*/},
+ morecomment = [s]{/**}{*/},
+ morestring = [b]",
+ morestring = [b]',
+}
+
+\lstdefinelanguage{XML}{
+ morestring = [b]",
+ moredelim = [s][\bfseries\color{listing-keyword}]{<}{\ },
+ moredelim = [s][\bfseries\color{listing-keyword}]{}{>},
+ moredelim = [l][\bfseries\color{listing-keyword}]{/>},
+ moredelim = [l][\bfseries\color{listing-keyword}]{>},
+ morecomment = [s]{}{?>},
+ morecomment = [s]{},
+ commentstyle = \color{listing-comment},
+ stringstyle = \color{listing-string},
+ identifierstyle = \color{listing-identifier}
+}
+$endif$
+
+%
+% header and footer
+%
+$if(beamer)$
+$else$
+$if(disable-header-and-footer)$
+$else$
+\usepackage[headsepline,footsepline]{scrlayer-scrpage}
+
+\newpairofpagestyles{eisvogel-header-footer}{
+ \clearpairofpagestyles
+ \ihead*{$if(header-left)$$header-left$$else$$title$$endif$}
+ \chead*{$if(header-center)$$header-center$$else$$endif$}
+ \ohead*{$if(header-right)$$header-right$$else$$date$$endif$}
+ \ifoot*{$if(footer-left)$$footer-left$$else$$for(author)$$author$$sep$, $endfor$$endif$}
+ \cfoot*{$if(footer-center)$$footer-center$$else$$endif$}
+ \ofoot*{$if(footer-right)$$footer-right$$else$\thepage$endif$}
+ \addtokomafont{pageheadfoot}{\upshape}
+}
+\pagestyle{eisvogel-header-footer}
+
+\newpairofpagestyles{eisvogel-chapterpage-header-footer}{
+ \clearpairofpagestyles
+ \setheadtopline{0pt} % 移除页眉顶部的横线(如果有)
+ \setheadsepline{0pt}
+ \ifoot*{$if(footer-left)$$footer-left$$else$$for(author)$$author$$sep$, $endfor$$endif$}
+ \cfoot*{$if(footer-center)$$footer-center$$else$$endif$}
+ \ofoot*{$if(footer-right)$$footer-right$$else$\thepage$endif$}
+ \addtokomafont{pageheadfoot}{\upshape}
+}
+
+
+$if(isbook)$
+% \deftripstyle{ChapterStyle}{}{}{}{}{\pagemark}{}
+% \renewcommand*{\chapterpagestyle}{ChapterStyle}
+\renewcommand*{\chapterpagestyle}{eisvogel-chapterpage-header-footer}
+$endif$
+
+
+$if(page-background)$
+\backgroundsetup{
+scale=1,
+color=black,
+opacity=$if(page-background-opacity)$$page-background-opacity$$else$0.2$endif$,
+angle=0,
+contents={%
+ \includegraphics[width=\paperwidth,height=\paperheight]{$page-background$}
+ }%
+}
+$endif$
+$endif$
+$endif$
+
+% watermark
+$if(watermark)$
+\usepackage{draftwatermark,xcolor}
+\SetWatermarkText{\textcolor{$if(watermark-color)$$watermark-color$$else$gray!3$endif$}{$watermark$}}
+\SetWatermarkScale{1.2} % 缩小水印尺寸(数值越小越密集)
+\SetWatermarkAngle{45} % 斜角排列(经典水印样式)
+\SetWatermarkLightness{0.99} % 亮度调节
+$endif$
+
+%%
+%% end added
+%%
+
+\begin{document}
+
+%%
+%% begin titlepage
+%%
+$if(beamer)$
+$else$
+$if(titlepage)$
+\begin{titlepage}
+$if(titlepage-background)$
+\newgeometry{top=2cm, right=4cm, bottom=3cm, left=4cm}
+$else$
+\newgeometry{left=2cm}
+$endif$
+$if(titlepage-color)$
+\definecolor{titlepage-color}{HTML}{$titlepage-color$}
+\newpagecolor{titlepage-color}\afterpage{\restorepagecolor}
+$endif$
+$if(titlepage-background)$
+\tikz[remember picture,overlay] \node[inner sep=0pt] at (current page.center){\includegraphics[width=\paperwidth,height=\paperheight]{$titlepage-background$}};
+$endif$
+\newcommand{\colorRule}[3][black]{\textcolor[HTML]{#1}{\rule{#2}{#3}}}
+
+\NewDocumentEnvironment{dynalign}{}
+ {\begin{$if(titlepage-halign)$$titlepage-halign$$else$center$endif$}}
+ {\end{$if(titlepage-halign)$$titlepage-halign$$else$center$endif$}}
+
+\begin{dynalign}
+\noindent
+\\[-1em]
+\color[HTML]{$if(titlepage-text-color)$$titlepage-text-color$$else$5F5F5F$endif$}
+\makebox[0pt][l]{\colorRule[$if(titlepage-rule-color)$$titlepage-rule-color$$else$435488$endif$]{1.3\textwidth}{$if(titlepage-rule-height)$$titlepage-rule-height$$else$4$endif$pt}}
+\par
+\noindent
+
+$if(titlepage-logo)$
+\noindent
+\vskip $if(logo-vskip)$$logo-vskip$$else$-8em$endif$
+\hskip $if(logo-hskip)$$logo-hskip$$else$-6em$endif$
+\includegraphics[width=$if(logo-width)$$logo-width$$else$35mm$endif$, left]{$titlepage-logo$}
+$endif$
+
+$if(titlepage-background)$
+% The titlepage with a background image has other text spacing and text size
+{
+ \setstretch{2}
+ \vfill
+ \vskip -8em
+ $if(title-vskip)$
+ \vskip $title-vskip$
+ $endif$
+ $if(title-hskip)$
+ \vskip $title-hskip$
+ $endif$
+ \noindent {
+ $if(title-size)$
+ \$title-size$
+ $else$
+ \huge
+ $endif$
+\textbf{\textsf{$title$}}}
+ $if(subtitle)$
+ \vskip 1em
+ {
+ $if(subtitle-size)$
+ \$subtitle-size$
+ $else$
+ \Large
+ $endif$
+ \textsf{$subtitle$}}
+ $endif$
+ \vskip 2em
+ $if(author-vskip)$
+ \vskip $author-vskip$
+ $endif$
+ \noindent {
+ $if(author-size)$
+ $author-size$
+ $else$
+ \Large
+ $endif$
+
+\textsf{$for(author)$$author$$sep$, $endfor$}
+\vskip 0.6em
+ $if(date-vskip)$
+ \vskip $date-vskip$
+ $endif$
+{\textsf{$if(institute)$$institute$\vskip 0.6em$endif$$date$}}
+}
+ \vfill
+}
+$else$
+{
+ \setstretch{1.4}
+ \vfill
+ \vskip 8em
+ $if(title-vskip)$
+ \vskip $title-vskip$
+ $endif$
+ $if(title-hskip)$
+ \vskip $title-hskip$
+ $endif$
+ \noindent {\huge \textbf{\textsf{$title$}}}
+ $if(subtitle)$
+ \vskip 1em
+ {\Large \textsf{$subtitle$}}
+ $endif$
+ \vskip 4em
+ $if(author-vskip)$
+ \vskip $author-vskip$
+ $endif$
+ \noindent {
+ $if(author-size)$
+ $author-size$
+ $else$
+ \Large
+ $endif$
+
+\textsf{$for(author)$$author$$sep$, $endfor$}
+\vskip 0.6em
+ $if(date-vskip)$
+ \vskip $date-vskip$
+ $endif$
+}
+ \vfill
+}
+$endif$
+
+
+$if(titlepage-background)$
+$else$
+
+ $if(author-size)$
+ $author-size$
+ $else$
+ \Large
+ $endif$
+{\textsf{$if(institute)$$institute$\vskip 0.6em$endif$$date$}}
+$endif$
+\end{dynalign}
+\end{titlepage}
+\restoregeometry
+\pagenumbering{arabic}
+$endif$
+$endif$
+
+
+
+%%
+%% end titlepage
+%%
+
+$if(has-frontmatter)$
+\frontmatter
+$endif$
+$if(title)$
+$if(beamer)$
+\frame{\titlepage}
+% don't generate the default title
+% $else$
+% \maketitle
+$endif$
+$if(abstract)$
+\begin{abstract}
+$abstract$
+\end{abstract}
+$endif$
+$endif$
+
+$if(first-chapter)$
+\setcounter{chapter}{$first-chapter$}
+\addtocounter{chapter}{-1}
+$endif$
+
+$for(include-before)$
+$include-before$
+
+$endfor$
+$if(toc)$
+$if(toc-title)$
+\renewcommand*\contentsname{$toc-title$}
+$endif$
+$if(beamer)$
+\begin{frame}[allowframebreaks]
+$if(toc-title)$
+ \frametitle{$toc-title$}
+$endif$
+ \setcounter{tocdepth}{$toc-depth$}
+ \tableofcontents
+\end{frame}
+$if(toc-own-page)$
+\newpage
+$endif$
+$else$
+{
+$if(colorlinks)$
+\hypersetup{linkcolor=$if(toccolor)$$toccolor$$else$$endif$}
+$endif$
+\setcounter{tocdepth}{$toc-depth$}
+\tableofcontents
+$if(toc-own-page)$
+\newpage
+$endif$
+}
+$endif$
+$endif$
+$if(lof)$
+\listoffigures
+$endif$
+$if(lot)$
+\listoftables
+$endif$
+$if(linestretch)$
+\setstretch{$linestretch$}
+$endif$
+$if(has-frontmatter)$
+\mainmatter
+$endif$
+$body$
+
+$if(has-frontmatter)$
+\backmatter
+$endif$
+$if(natbib)$
+$if(bibliography)$
+$if(biblio-title)$
+$if(has-chapters)$
+\renewcommand\bibname{$biblio-title$}
+$else$
+\renewcommand\refname{$biblio-title$}
+$endif$
+$endif$
+$if(beamer)$
+\begin{frame}[allowframebreaks]{$biblio-title$}
+ \bibliographytrue
+$endif$
+ \bibliography{$for(bibliography)$$bibliography$$sep$,$endfor$}
+$if(beamer)$
+\end{frame}
+$endif$
+
+$endif$
+$endif$
+$if(biblatex)$
+$if(beamer)$
+\begin{frame}[allowframebreaks]{$biblio-title$}
+ \bibliographytrue
+ \printbibliography[heading=none]
+\end{frame}
+$else$
+\printbibliography$if(biblio-title)$[title=$biblio-title$]$endif$
+$endif$
+
+$endif$
+$for(include-after)$
+$include-after$
+
+$endfor$
+\end{document}
diff --git a/_extensions/drwater/dwev/inst/elsevier-harvard.csl b/_extensions/drwater/dwev/inst/elsevier-harvard.csl
new file mode 100755
index 0000000..5d88c51
--- /dev/null
+++ b/_extensions/drwater/dwev/inst/elsevier-harvard.csl
@@ -0,0 +1,239 @@
+
+
diff --git a/_extensions/drwater/dwev/inst/nature-biotechnology.csl b/_extensions/drwater/dwev/inst/nature-biotechnology.csl
new file mode 100644
index 0000000..216c8b9
--- /dev/null
+++ b/_extensions/drwater/dwev/inst/nature-biotechnology.csl
@@ -0,0 +1,17 @@
+
+
diff --git a/_extensions/drwater/dwev/inst/nature.csl b/_extensions/drwater/dwev/inst/nature.csl
new file mode 100644
index 0000000..7b058ba
--- /dev/null
+++ b/_extensions/drwater/dwev/inst/nature.csl
@@ -0,0 +1,154 @@
+
+
diff --git a/_extensions/drwater/dwev/inst/rceeslogo.pdf b/_extensions/drwater/dwev/inst/rceeslogo.pdf
new file mode 100644
index 0000000..51d1a45
Binary files /dev/null and b/_extensions/drwater/dwev/inst/rceeslogo.pdf differ
diff --git a/_extensions/drwater/dwev/inst/rceeslogo.svg b/_extensions/drwater/dwev/inst/rceeslogo.svg
new file mode 100644
index 0000000..44431ff
--- /dev/null
+++ b/_extensions/drwater/dwev/inst/rceeslogo.svg
@@ -0,0 +1,5 @@
+
+
diff --git a/_extensions/drwater/dwev/inst/rceeslonglogo.pdf b/_extensions/drwater/dwev/inst/rceeslonglogo.pdf
new file mode 100644
index 0000000..50017f7
Binary files /dev/null and b/_extensions/drwater/dwev/inst/rceeslonglogo.pdf differ
diff --git a/_extensions/drwater/dwev/inst/rceeslonglogo.svg b/_extensions/drwater/dwev/inst/rceeslonglogo.svg
new file mode 100644
index 0000000..013b69d
--- /dev/null
+++ b/_extensions/drwater/dwev/inst/rceeslonglogo.svg
@@ -0,0 +1,352 @@
+
+
diff --git a/_extensions/drwater/dwev/inst/signms.pdf b/_extensions/drwater/dwev/inst/signms.pdf
new file mode 100644
index 0000000..8b9afc3
Binary files /dev/null and b/_extensions/drwater/dwev/inst/signms.pdf differ
diff --git a/_extensions/drwater/dwev/inst/signms.png b/_extensions/drwater/dwev/inst/signms.png
new file mode 100644
index 0000000..c292ad6
Binary files /dev/null and b/_extensions/drwater/dwev/inst/signms.png differ
diff --git a/_extensions/drwater/dwev/inst/signms.pptx b/_extensions/drwater/dwev/inst/signms.pptx
new file mode 100644
index 0000000..94e54f5
Binary files /dev/null and b/_extensions/drwater/dwev/inst/signms.pptx differ
diff --git a/_extensions/drwater/dwev/inst/signms.svg b/_extensions/drwater/dwev/inst/signms.svg
new file mode 100644
index 0000000..1218831
--- /dev/null
+++ b/_extensions/drwater/dwev/inst/signms.svg
@@ -0,0 +1,111 @@
+
+
diff --git a/_extensions/drwater/dwev/inst/signmy.pdf b/_extensions/drwater/dwev/inst/signmy.pdf
new file mode 100644
index 0000000..26d4e5f
Binary files /dev/null and b/_extensions/drwater/dwev/inst/signmy.pdf differ
diff --git a/_extensions/drwater/dwev/inst/signmy.png b/_extensions/drwater/dwev/inst/signmy.png
new file mode 100755
index 0000000..83e6904
Binary files /dev/null and b/_extensions/drwater/dwev/inst/signmy.png differ
diff --git a/_extensions/drwater/dwev/inst/signmy.pptx b/_extensions/drwater/dwev/inst/signmy.pptx
new file mode 100644
index 0000000..0a8c283
Binary files /dev/null and b/_extensions/drwater/dwev/inst/signmy.pptx differ
diff --git a/_extensions/drwater/dwev/inst/signmy.svg b/_extensions/drwater/dwev/inst/signmy.svg
new file mode 100644
index 0000000..fde7fff
--- /dev/null
+++ b/_extensions/drwater/dwev/inst/signmy.svg
@@ -0,0 +1,26 @@
+
+
diff --git a/_extensions/drwater/dwev/inst/the-isme-j.csl b/_extensions/drwater/dwev/inst/the-isme-j.csl
new file mode 100755
index 0000000..730aefc
--- /dev/null
+++ b/_extensions/drwater/dwev/inst/the-isme-j.csl
@@ -0,0 +1,181 @@
+
+
diff --git a/_extensions/drwater/dwev/template.qmd b/_extensions/drwater/dwev/template.qmd
new file mode 100644
index 0000000..cce05ef
--- /dev/null
+++ b/_extensions/drwater/dwev/template.qmd
@@ -0,0 +1,149 @@
+---
+title: "中文报告模板"
+author: "苏命"
+institute: "中国科学院生态环境研究中心"
+date: "today"
+subject: "Markdown"
+keywords: [Markdown, Example]
+isbook: true
+top-level-division: chapter
+classoption:
+ - fntef
+ - UTF8
+ - zihao=-4 # 正文字号小四
+ - lang=cn
+ # - chinesefont=founder # founder|ctexfont|nofont
+ - scheme=chinese
+ - color=blue # blue|green|
+ - titlestyle=hang
+# classoption: [oneside]
+titlepage: true
+keep-tex: false
+titlepage-rule-color: "360049"
+titlepage-text-color: "360049"
+titlepage-rule-height: 0
+titlepage-background: "_extensions/drwater/dwev/inst/cover1.pdf"
+titlepage-halign: "center" # flushleft | flushright
+title-vskip: -30em
+title-size: "Huge"
+author-vskip: -4em
+date-vskip: -1em
+caption-justification: centering
+numbersections: true
+parindent: true
+# titlepage-logo: "inst/rceeslogo.pdf"
+# logo-width: 20mm
+# logo-vskip: -8em
+# logo-hskip: "-6em"
+lang: zh-CN # 不能改为cn,否则目录等不是中文
+CJK: true
+fig-pos: "!t"
+colorlinks: true
+urlcolor: blue
+header-left: "\\leftmark"
+header-center: "\\hspace{1cm}"
+header-right: "第\\thepage 页"
+footer-left: "\\hspace{1cm}" # \\thetitle
+footer-center: "\\includegraphics[height=1.5em]{_extensions/drwater/dwev/inst/drwater-gray1.pdf}"
+footer-right: "\\hspace{1cm}"
+toc: true
+toc-own-page: true
+fig-toc: true
+CJKmainfont: "Noto Serif CJK SC"
+CJKmainboldfont: "NotoSerifCJKsc-Bold"
+CJKmainitalicfont: "NotoSansCJKsc-Light"
+CJKsansfont: "Noto Sans CJK SC"
+CJKmonofont: "Noto Sans Mono CJK SC"
+CJKoptions: |
+ AutoFakeBold=true
+# include-in-header: header.tex
+# watermark: "drwater"
+# watermark-color: "gray!3"
+format: dwev-pdf
+---
+
+```{r}
+#| label: setup
+#| include: false
+#| cache: false
+lang <- "cn"
+RM <- "F" # global rendermode, L: load pdata; F: fast load pdf
+isRendering <- !isTRUE(getOption('knitr.in.progress'))
+require(lubridate)
+require(tidyverse)
+require(patchwork)
+require(drwateR)
+rmdify::rmd_init()
+```
+
+
+# 摘要
+
+# 项目背景与国内外现状介绍
+
+
+
+::: callout-warning
+Book in early development. Planned release in 202X.
+:::
+
+*asdfsd* *你好* 阿斯顿发 **你好** asdf。本书分三大部分,分别是机器学习、贝叶斯建模和空间分析。三个部分分别依据任务类型、模型种类和数据类型展开,不同的写作出发点将呈现不一样的写作风格。应用机器学习首先需要确定任务类型,根据不同的任务选用不同的算法。贝叶斯建模从简单到复杂分频率和贝叶斯方法介绍主流的统计模型。应用空间分析方法需要根据空间数据类型(生成机理)而定,不同的生成机理将对应不同的建模和分析方法。机器学习根据任务类型分聚类、分类、回归和排序四个章节。贝叶斯建模根据模型种类分概率推理框架、线性模型、广义线性模型、分层正态模型、混合效应模型、广义可加模型、高斯过程回归、时间序列回归等八个章节。空间分析部分根据空间数据类型分点模式数据分析、点参考数据分析和区域数据分析三个章节。如[@fig-fig1]所示。
+
+
+```{r}
+#| label: fig-fig1
+#| fig-cap: "asdf"
+
+plot(1)
+```
+
+
+
+## 环境信息
+
+本书采用科学和技术写作排版系统 [Quarto](https://quarto.org/) 编写,所有代码和文本混编在 qmd 格式的纯文本文件中,具有计算可重复性,即内含的 R 语言、Stan 语言和 Python 语言代码都可运行,并将计算结果插入到最终的文档中,本书使用的主要 R 包及版本信息如[@eq-eq1]所示:
+
+$$
+x^2+y^2+z^2=a^2
+$$ {#eq-eq1}
+
+
+
+
+# 主要进展1
+
+## 主要进展2
+
+本书分三大部分,分别是机器学习、贝叶斯建模和空间分析。三个部分分别依据任务类型、模型种类和数据类型展开,不同的写作出发点将呈现不一样的写作风格。应用机器学习首先需要确定任务类型,根据不同的任务选用不同的算法。贝叶斯建模从简单到复杂分频率和贝叶斯方法介绍主流的统计模型。应用空间分析方法需要根据空间数据类型(生成机理)而定,不同的生成机理将对应不同的建模和分析方法。机器学习根据任务类型分聚类、分类、回归和排序四个章节。贝叶斯建模根据模型种类分概率推理框架、线性模型、广义线性模型、分层正态模型、混合效应模型、广义可加模型、高斯过程回归、时间序列回归等八个章节。空间分析部分根据空间数据类型分点模式数据分析、点参考数据分析和区域数据分析三个章节。
+
+## 主要进展2
+
+本书分三大部分,分别是机器学习、贝叶斯建模和空间分析。三个部分分别依据任务类型、模型种类和数据类型展开,不同的写作出发点将呈现不一样的写作风格。应用机器学习首先需要确定任务类型,根据不同的任务选用不同的算法。贝叶斯建模从简单到复杂分频率和贝叶斯方法介绍主流的统计模型。应用空间分析方法需要根据空间数据类型(生成机理)而定,不同的生成机理将对应不同的建模和分析方法。机器学习根据任务类型分聚类、分类、回归和排序四个章节。贝叶斯建模根据模型种类分概率推理框架、线性模型、广义线性模型、分层正态模型、混合效应模型、广义可加模型、高斯过程回归、时间序列回归等八个章节。空间分析部分根据空间数据类型分点模式数据分析、点参考数据分析和区域数据分析三个章节。
+
+
+# 主要进展2
+
+## 主要进展2
+
+本书分三大部分,分别是机器学习、贝叶斯建模和空间分析。三个部分分别依据任务类型、模型种类和数据类型展开,不同的写作出发点将呈现不一样的写作风格。应用机器学习首先需要确定任务类型,根据不同的任务选用不同的算法。贝叶斯建模从简单到复杂分频率和贝叶斯方法介绍主流的统计模型。应用空间分析方法需要根据空间数据类型(生成机理)而定,不同的生成机理将对应不同的建模和分析方法。机器学习根据任务类型分聚类、分类、回归和排序四个章节。贝叶斯建模根据模型种类分概率推理框架、线性模型、广义线性模型、分层正态模型、混合效应模型、广义可加模型、高斯过程回归、时间序列回归等八个章节。空间分析部分根据空间数据类型分点模式数据分析、点参考数据分析和区域数据分析三个章节。
+
+## 主要进展2
+
+本书分三大部分,分别是机器学习、贝叶斯建模和空间分析。三个部分分别依据任务类型、模型种类和数据类型展开,不同的写作出发点将呈现不一样的写作风格。应用机器学习首先需要确定任务类型,根据不同的任务选用不同的算法。贝叶斯建模从简单到复杂分频率和贝叶斯方法介绍主流的统计模型。应用空间分析方法需要根据空间数据类型(生成机理)而定,不同的生成机理将对应不同的建模和分析方法。机器学习根据任务类型分聚类、分类、回归和排序四个章节。贝叶斯建模根据模型种类分概率推理框架、线性模型、广义线性模型、分层正态模型、混合效应模型、广义可加模型、高斯过程回归、时间序列回归等八个章节。空间分析部分根据空间数据类型分点模式数据分析、点参考数据分析和区域数据分析三个章节。
+
+## 主要进展2
+
+本书分三大部分,分别是机器学习、贝叶斯建模和空间分析。三个部分分别依据任务类型、模型种类和数据类型展开,不同的写作出发点将呈现不一样的写作风格。应用机器学习首先需要确定任务类型,根据不同的任务选用不同的算法。贝叶斯建模从简单到复杂分频率和贝叶斯方法介绍主流的统计模型。应用空间分析方法需要根据空间数据类型(生成机理)而定,不同的生成机理将对应不同的建模和分析方法。机器学习根据任务类型分聚类、分类、回归和排序四个章节。贝叶斯建模根据模型种类分概率推理框架、线性模型、广义线性模型、分层正态模型、混合效应模型、广义可加模型、高斯过程回归、时间序列回归等八个章节。空间分析部分根据空间数据类型分点模式数据分析、点参考数据分析和区域数据分析三个章节。
+
+## 主要进展2
+
+本书分三大部分,分别是机器学习、贝叶斯建模和空间分析。三个部分分别依据任务类型、模型种类和数据类型展开,不同的写作出发点将呈现不一样的写作风格。应用机器学习首先需要确定任务类型,根据不同的任务选用不同的算法。贝叶斯建模从简单到复杂分频率和贝叶斯方法介绍主流的统计模型。应用空间分析方法需要根据空间数据类型(生成机理)而定,不同的生成机理将对应不同的建模和分析方法。机器学习根据任务类型分聚类、分类、回归和排序四个章节。贝叶斯建模根据模型种类分概率推理框架、线性模型、广义线性模型、分层正态模型、混合效应模型、广义可加模型、高斯过程回归、时间序列回归等八个章节。空间分析部分根据空间数据类型分点模式数据分析、点参考数据分析和区域数据分析三个章节。
+
+
+# 结论与下一步计划
+
+本书分三大部分,分别是机器学习、贝叶斯建模和空间分析。三个部分分别依据任务类型、模型种类和数据类型展开,不同的写作出发点将呈现不一样的写作风格。应用机器学习首先需要确定任务类型,根据不同的任务选用不同的算法。贝叶斯建模从简单到复杂分频率和贝叶斯方法介绍主流的统计模型。应用空间分析方法需要根据空间数据类型(生成机理)而定,不同的生成机理将对应不同的建模和分析方法。机器学习根据任务类型分聚类、分类、回归和排序四个章节。贝叶斯建模根据模型种类分概率推理框架、线性模型、广义线性模型、分层正态模型、混合效应模型、广义可加模型、高斯过程回归、时间序列回归等八个章节。空间分析部分根据空间数据类型分点模式数据分析、点参考数据分析和区域数据分析三个章节。
+
+# 参考文献{-}
+
+
diff --git a/_extensions/drwater/dwhm/_extension.yml b/_extensions/drwater/dwhm/_extension.yml
new file mode 100644
index 0000000..b6cf7e7
--- /dev/null
+++ b/_extensions/drwater/dwhm/_extension.yml
@@ -0,0 +1,10 @@
+title: html
+author: ming
+version: 1.0.0
+quarto-required: ">=1.7.0"
+contributes:
+ formats:
+ html:
+ toc: true
+ css: _extensions/drwater/dwhm/inst/drwater.css
+ theme: _extensions/drwater/dwhm/inst/drwater.scss
diff --git a/_extensions/drwater/dwhm/inst/clab-tooltip.js b/_extensions/drwater/dwhm/inst/clab-tooltip.js
new file mode 100644
index 0000000..900b133
--- /dev/null
+++ b/_extensions/drwater/dwhm/inst/clab-tooltip.js
@@ -0,0 +1,418 @@
+// clab-tooltip.js - 完全隔离事件版本(修改后的显示位置逻辑)
+(function() {
+ // 全局变量存储从 RN.html 提取的内容
+ let rnContentCache = {};
+ let isRnContentLoaded = false;
+ let activeTooltip = null;
+ let hideTimer = null;
+ let isMouseOverTooltip = false;
+
+ // 从 RN.html 提取内容(保持不变)
+ async function loadRnContent() {
+ try {
+ console.log('加载 RN.html...');
+ const response = await fetch('RN.html');
+ if (!response.ok) throw new Error(`HTTP error: ${response.status}`);
+
+ const htmlText = await response.text();
+ const parser = new DOMParser();
+ const rnDoc = parser.parseFromString(htmlText, 'text/html');
+
+ // 查找所有包含 data-options 的元素
+ const optionElements = rnDoc.querySelectorAll('[data-options]');
+ console.log(`找到 ${optionElements.length} 个 data-options 元素`);
+
+ optionElements.forEach(element => {
+ const optionValue = element.getAttribute('data-options');
+ if (!optionValue) return;
+
+ // 向前查找最近的 blockquote
+ let prevElement = element.previousElementSibling;
+ let blockquote = null;
+
+ // 先找前一个兄弟元素
+ while (prevElement) {
+ if (prevElement.tagName === 'BLOCKQUOTE') {
+ blockquote = prevElement;
+ break;
+ }
+ prevElement = prevElement.previousElementSibling;
+ }
+
+ // 如果没找到,向上查找
+ if (!blockquote) {
+ let parent = element.parentElement;
+ while (parent) {
+ let sibling = parent.previousElementSibling;
+ while (sibling) {
+ if (sibling.tagName === 'BLOCKQUOTE') {
+ blockquote = sibling;
+ break;
+ }
+ sibling = sibling.previousElementSibling;
+ }
+ if (blockquote) break;
+ parent = parent.parentElement;
+ }
+ }
+
+ if (blockquote) {
+ const lis = blockquote.querySelectorAll('li');
+ if (lis.length > 0) {
+ const liContents = Array.from(lis).map(li => li.textContent.trim());
+
+ if (!rnContentCache[optionValue]) {
+ rnContentCache[optionValue] = [];
+ }
+
+ // 存储所有引用
+ rnContentCache[optionValue].push({
+ contents: liContents
+ });
+ }
+ }
+ });
+
+ isRnContentLoaded = true;
+
+ console.log('内容加载完成');
+ Object.keys(rnContentCache).forEach(key => {
+ console.log(`"${key}": ${rnContentCache[key].length} Questions`);
+ });
+
+ } catch (error) {
+ console.error('加载失败:', error);
+ }
+ }
+
+ // 创建 tooltip(保持不变)
+ function createTooltip() {
+ const tooltip = document.createElement('div');
+ tooltip.className = 'clab-tooltip';
+ tooltip.id = 'clab-tooltip-element';
+
+ // 完全阻止所有事件冒泡
+ const stopAllEvents = (e) => {
+ e.stopPropagation();
+ e.stopImmediatePropagation();
+ e.preventDefault();
+ return false;
+ };
+
+ // 阻止所有可能的事件
+ const events = [
+ 'mousedown', 'mouseup', 'click', 'dblclick',
+ 'mousemove', 'mouseover', 'mouseout', 'mouseenter', 'mouseleave',
+ 'wheel', 'scroll',
+ 'touchstart', 'touchmove', 'touchend', 'touchcancel',
+ 'pointerdown', 'pointermove', 'pointerup', 'pointercancel',
+ 'dragstart', 'dragover', 'drop'
+ ];
+
+ events.forEach(eventType => {
+ tooltip.addEventListener(eventType, stopAllEvents, true); // 捕获阶段
+ tooltip.addEventListener(eventType, stopAllEvents, false); // 冒泡阶段
+ });
+
+ // 允许 wheel 事件用于滚动,但阻止冒泡
+ tooltip.addEventListener('wheel', function(e) {
+ e.stopPropagation();
+ e.stopImmediatePropagation();
+ // 允许默认的滚动行为
+ }, { passive: false });
+
+ // 允许鼠标在 tooltip 内移动
+ tooltip.addEventListener('mousemove', function(e) {
+ e.stopPropagation();
+ }, { passive: true });
+
+ document.body.appendChild(tooltip);
+ return tooltip;
+ }
+
+ // 显示 tooltip - 已修改位置逻辑
+ function showTooltip(element, tooltip) {
+ const rect = element.getBoundingClientRect();
+ const optionValue = element.getAttribute('data-options');
+
+ // 清空内容
+ tooltip.innerHTML = '';
+
+ if (rnContentCache[optionValue] && rnContentCache[optionValue].length > 0) {
+ const entries = rnContentCache[optionValue];
+
+ // 标题显示选项
+ const title = document.createElement('div');
+ title.className = 'tooltip-title';
+ title.textContent = optionValue;
+ if (entries.length > 1) {
+ title.textContent += ` (${entries.length} questions)`;
+ }
+ tooltip.appendChild(title);
+
+ // 显示所有引用
+ entries.forEach((entry, entryIndex) => {
+ const content = entry.contents;
+
+ if (content.length === 1) {
+ // 单一条目
+ const entryDiv = document.createElement('div');
+ entryDiv.className = 'entry-single';
+
+ if (entries.length >= 1) {
+ entryDiv.innerHTML = `Q${entryIndex + 1}: ${content[0]}`;
+ } else {
+ entryDiv.textContent = content[0];
+ }
+
+ tooltip.appendChild(entryDiv);
+ } else {
+ // 多个条目
+ const entryDiv = document.createElement('div');
+ entryDiv.className = 'entry-multiple';
+
+ if (entries.length > 1) {
+ const header = document.createElement('div');
+ header.className = 'q-header';
+ header.textContent = `Q${entryIndex + 1}:`;
+ entryDiv.appendChild(header);
+ }
+
+ const ol = document.createElement('ol');
+ ol.className = 'q-list';
+
+ content.forEach((item, itemIndex) => {
+ const li = document.createElement('li');
+ li.innerHTML = `${entryIndex + 1}.${itemIndex + 1} ${item}`;
+ ol.appendChild(li);
+ });
+
+ entryDiv.appendChild(ol);
+ tooltip.appendChild(entryDiv);
+ }
+ });
+ } else {
+ // 没有找到内容
+ const noContent = document.createElement('div');
+ noContent.className = 'tooltip-no-content';
+ noContent.textContent = '未找到相关内容';
+ tooltip.appendChild(noContent);
+ }
+
+ // 确保 tooltip 有合适的尺寸
+ tooltip.style.position = 'fixed';
+ tooltip.style.zIndex = '10000';
+ tooltip.style.maxWidth = '400px';
+ tooltip.style.maxHeight = '500px';
+ tooltip.style.overflowY = 'auto';
+ tooltip.style.boxSizing = 'border-box';
+
+ // 首先隐藏并获取尺寸
+ tooltip.style.visibility = 'hidden';
+ tooltip.classList.add('active');
+ document.body.appendChild(tooltip);
+
+ const tooltipWidth = Math.min(tooltip.scrollWidth, 400);
+ const tooltipHeight = Math.min(tooltip.scrollHeight, 500);
+
+ tooltip.style.width = tooltipWidth + 'px';
+ tooltip.style.height = 'auto';
+
+ const padding = 5;
+ const minDistanceFromEdge = 20;
+
+ let left, top;
+ let position = 'right'; // 首选右侧
+
+ // 检查右侧空间
+ if (rect.right + padding + tooltipWidth <= window.innerWidth - minDistanceFromEdge) {
+ // 右侧有足够空间
+ left = rect.right + padding;
+ top = rect.top;
+ position = 'right';
+ } else if (rect.left - padding - tooltipWidth >= minDistanceFromEdge) {
+ // 左侧有足够空间
+ left = rect.left - padding - tooltipWidth;
+ top = rect.top;
+ position = 'left';
+ } else {
+ // 两侧都没有足够空间,显示在下方
+ left = Math.max(
+ minDistanceFromEdge,
+ Math.min(
+ rect.left + (rect.width - tooltipWidth) / 2,
+ window.innerWidth - tooltipWidth - minDistanceFromEdge
+ )
+ );
+ top = rect.bottom + padding;
+ position = 'bottom';
+ }
+
+ // 垂直边界检查 - 确保不超出屏幕
+ if (top + tooltipHeight > window.innerHeight - minDistanceFromEdge) {
+ // 如果下方空间不足,尝试显示在上方
+ if (rect.top - padding - tooltipHeight >= minDistanceFromEdge) {
+ top = rect.top - padding - tooltipHeight;
+ } else {
+ // 上下都不够,显示在中间
+ top = Math.max(
+ minDistanceFromEdge,
+ Math.min(
+ top,
+ window.innerHeight - tooltipHeight - minDistanceFromEdge
+ )
+ );
+ }
+ }
+
+ // 水平边界检查 - 确保不超出屏幕
+ if (position === 'right' || position === 'left') {
+ left = Math.max(
+ minDistanceFromEdge,
+ Math.min(left, window.innerWidth - tooltipWidth - minDistanceFromEdge)
+ );
+ }
+
+ tooltip.style.left = left + 'px';
+ tooltip.style.top = top + 'px';
+ tooltip.style.visibility = 'visible';
+
+ // 添加一个小箭头指示方向
+ tooltip.setAttribute('data-position', position);
+
+ activeTooltip = tooltip;
+ isMouseOverTooltip = true;
+
+ // 添加 overlay 防止 body 交互
+ addOverlay();
+ }
+
+ // 添加半透明 overlay(保持不变)
+ function addOverlay() {
+ // 移除现有的 overlay
+ removeOverlay();
+
+ const overlay = document.createElement('div');
+ overlay.id = 'tooltip-overlay';
+ overlay.style.cssText = `
+ position: fixed;
+ top: 0;
+ left: 0;
+ width: 100%;
+ height: 100%;
+ z-index: 9999;
+ background: transparent;
+ pointer-events: none;
+ `;
+ document.body.appendChild(overlay);
+
+ // 将 overlay 的 pointer-events 设为 auto,但阻止所有事件
+ overlay.addEventListener('mousedown', stopEvent, true);
+ overlay.addEventListener('mouseup', stopEvent, true);
+ overlay.addEventListener('click', stopEvent, true);
+ overlay.addEventListener('mousemove', stopEvent, true);
+ overlay.addEventListener('wheel', stopEvent, true);
+
+ function stopEvent(e) {
+ e.preventDefault();
+ e.stopPropagation();
+ e.stopImmediatePropagation();
+ return false;
+ }
+ }
+
+ // 移除 overlay(保持不变)
+ function removeOverlay() {
+ const overlay = document.getElementById('tooltip-overlay');
+ if (overlay) {
+ overlay.remove();
+ }
+ }
+
+ // 隐藏 tooltip(保持不变)
+ function hideTooltip() {
+ if (!isMouseOverTooltip && activeTooltip) {
+ activeTooltip.classList.remove('active');
+ activeTooltip = null;
+ removeOverlay();
+ }
+ }
+
+ // 强制隐藏 tooltip(保持不变)
+ function forceHideTooltip() {
+ if (activeTooltip) {
+ activeTooltip.classList.remove('active');
+ activeTooltip = null;
+ isMouseOverTooltip = false;
+ removeOverlay();
+ }
+ }
+
+ // 初始化(保持不变)
+ document.addEventListener('DOMContentLoaded', function() {
+ console.log('初始化 clab-tooltip');
+
+ const clabElements = document.querySelectorAll('.clab[data-options]');
+ console.log(`找到 ${clabElements.length} 个 .clab 元素`);
+
+ if (clabElements.length === 0) return;
+
+ // 加载内容
+ loadRnContent();
+
+ // 创建 tooltip
+ const tooltip = createTooltip();
+
+ // tooltip 鼠标进入/离开
+ tooltip.addEventListener('mouseenter', function() {
+ isMouseOverTooltip = true;
+ clearTimeout(hideTimer);
+ });
+
+ tooltip.addEventListener('mouseleave', function() {
+ isMouseOverTooltip = false;
+ hideTimer = setTimeout(() => {
+ forceHideTooltip();
+ }, 100);
+ });
+
+ // 为所有 .clab 元素添加事件监听
+ clabElements.forEach(clab => {
+ clab.addEventListener('mouseenter', function() {
+ clearTimeout(hideTimer);
+
+ setTimeout(() => {
+ if (isRnContentLoaded) {
+ showTooltip(this, tooltip);
+ }
+ }, 100);
+ });
+
+ clab.addEventListener('mouseleave', function() {
+ hideTimer = setTimeout(() => {
+ hideTooltip();
+ }, 100);
+ });
+ });
+
+ // ESC 键隐藏 tooltip
+ document.addEventListener('keydown', function(e) {
+ if (e.key === 'Escape' && activeTooltip) {
+ forceHideTooltip();
+ }
+ });
+
+ // 点击其他地方隐藏 tooltip
+ document.addEventListener('click', function(e) {
+ if (activeTooltip && !activeTooltip.contains(e.target)) {
+ forceHideTooltip();
+ }
+ });
+
+ // 窗口大小改变时隐藏 tooltip
+ window.addEventListener('resize', forceHideTooltip);
+
+ // 滚动时隐藏 tooltip
+ window.addEventListener('scroll', forceHideTooltip);
+ });
+})();
diff --git a/_extensions/drwater/dwhm/inst/drwater.css b/_extensions/drwater/dwhm/inst/drwater.css
new file mode 100755
index 0000000..1c92fe3
--- /dev/null
+++ b/_extensions/drwater/dwhm/inst/drwater.css
@@ -0,0 +1,384 @@
+.udot {
+ text-decoration-line: underline;
+ text-decoration-color: rgb(50, 50, 50);
+ text-decoration-style: dashed;
+ text-decoration-thickness: 1px;
+}
+
+.good {
+ background-color: forestgreen;
+ color: lightyellow;
+}
+
+.bad {
+ background-color: orangered;
+ color: lightyellow;
+}
+
+.del {
+ text-decoration-line: line-through;
+ text-decoration-color: rgb(222 13 13);
+ text-decoration-style: initial;
+ text-decoration-thickness: 1.5px;
+}
+
+
+.todo {
+ background-color: darkorange;
+ color: lightyellow;
+}
+
+.com {
+ background-color: #0025ff;
+ font-weight: bold;
+ color: lightyellow;
+}
+
+.add {
+ text-decoration-line: underline;
+ text-decoration-color: rgb(222 13 13);
+ background-color: violet;
+ text-decoration-style: initial;
+ text-decoration-thickness: 2px;
+}
+
+
+del {
+ text-decoration-line: line-through;
+ text-decoration-color: rgb(222 13 13);
+ text-decoration-style: initial;
+ text-decoration-thickness: 1.0px;
+}
+
+
+ins {
+ text-decoration-color: rgb(222 93 93);
+ background-color: violet;
+ text-decoration-style: initial;
+ text-decoration-thickness: 2px;
+}
+
+
+
+/* clab-style.css */
+.clab {
+ display: inline !important;
+ position: relative !important;
+ cursor: pointer !important;
+ padding: 2px 4px !important;
+ margin: 0 1px !important;
+ border-radius: 3px !important;
+ font: inherit !important;
+ color: #000000 !important;
+ text-decoration: none !important;
+ vertical-align: baseline !important;
+ line-height: inherit !important;
+ z-index: 1 !important;
+}
+
+/* 随机背景色(使用预定义颜色) */
+.clab:nth-child(10n+1) { background-color: #E3F2FD !important; }
+.clab:nth-child(10n+2) { background-color: #F3E5F5 !important; }
+.clab:nth-child(10n+3) { background-color: #E8F5E9 !important; }
+.clab:nth-child(10n+4) { background-color: #FFF3E0 !important; }
+.clab:nth-child(10n+5) { background-color: #FCE4EC !important; }
+.clab:nth-child(10n+6) { background-color: #E0F7FA !important; }
+.clab:nth-child(10n+7) { background-color: #F1F8E9 !important; }
+.clab:nth-child(10n+8) { background-color: #FFF8E1 !important; }
+.clab:nth-child(10n+9) { background-color: #EDE7F6 !important; }
+.clab:nth-child(10n+10) { background-color: #E8EAF6 !important; }
+
+/* 基础hover效果 */
+span.clab:hover {
+ outline: 2px solid rgba(0,0,0,0.2) !important;
+ outline-offset: 2px !important;
+ z-index: 1000 !important;
+}
+
+
+
+
+/* clab-tooltip 下方显示样式 */
+.clab-tooltip {
+ font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
+ color: white;
+ padding: 5px;
+ border: 1px solid #444;
+ /* -webkit-user-select: none; */
+ position: fixed;
+ background: rgba(0, 0, 0, 0.95);
+ border-radius: 8px;
+ z-index: 10000;
+ box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3),
+ 0 0 0 1px rgba(255, 255, 255, 0.1);
+ font-size: 14px;
+ line-height: 1.1;
+ max-width: 500px;
+ max-height: 800px;
+ overflow-y: auto;
+ opacity: 0;
+ visibility: hidden;
+ transition: opacity 0.2s ease, visibility 0.2s ease, transform 0.2s ease;
+ overscroll-behavior: contain;
+ pointer-events: auto !important;
+}
+
+
+/* Tooltip 箭头 */
+.tooltip-arrow {
+ position: absolute;
+ width: 0;
+ height: 0;
+ border: 6px solid transparent;
+ border-bottom-color: #2a2a2a;
+ border-top: none;
+}
+
+/* tooltip 在上方的箭头(向下) */
+.clab-tooltip.above .tooltip-arrow {
+ border-top-color: #2a2a2a;
+ border-bottom: none;
+}
+
+/* 标题 */
+.tooltip-title {
+ font-weight: 600;
+ color: #FF9800;
+ margin-bottom: 6px;
+ padding-bottom: 4px;
+ border-bottom: 1px solid #444;
+ font-size: 14px;
+ font-family: monospace;
+ line-height: 0.8;
+ pointer-events: none;
+}
+
+/* 单一条目 */
+.entry-single {
+ padding: 4px 4px;
+ margin-bottom: 6px;
+ background: rgba(255, 255, 255, 0.05);
+ border-radius: 6px;
+ border-left: 3px solid #ffffff;
+ line-height: 1.2;
+ cursor: default;
+}
+
+/* Q标签样式 */
+.q-label {
+ display: inline-block;
+ color: #FF9800;
+ font-weight: 600;
+ margin-right: 8px;
+ min-width: 35px;
+}
+
+/* 多个条目的引用 */
+.entry-multiple {
+ padding: 4px 4px;
+ margin-bottom: 6px;
+ background: rgba(255, 255, 255, 0.05);
+ border-radius: 6px;
+ border-left: 3px solid #ffffff;
+ line-height: 1.2;
+ cursor: default;
+}
+
+/* 多引用标题 */
+.q-header {
+ color: #FF9800;
+ font-weight: 600;
+ margin-bottom: 8px;
+ font-size: 13px;
+ pointer-events: none;
+}
+
+/* 列表 */
+.q-list {
+ margin: 0;
+ padding-left: 0;
+ list-style: none;
+}
+
+.q-list li {
+ margin-bottom: 10px;
+ padding-left: 0;
+ line-height: 1.2;
+ position: relative;
+ cursor: default;
+ padding: 4px 0;
+}
+
+/* 子标签样式 */
+.q-sublabel {
+ display: inline-block;
+ color: #4CAF50;
+ font-weight: 600;
+ margin-right: 2px;
+ min-width: 25px;
+}
+
+/* 条目间空行 */
+/* .entry-spacer { */
+/* height: 12px; */
+/* pointer-events: none; */
+/* } */
+
+/* 无内容 */
+.tooltip-no-content {
+ color: #ff6b6b;
+ font-style: italic;
+ padding: 20px;
+ text-align: center;
+ background: rgba(255, 107, 107, 0.05);
+ border-radius: 6px;
+ cursor: default;
+}
+
+/* 滚动条 */
+.clab-tooltip::-webkit-scrollbar {
+ width: 8px;
+ height: 8px;
+}
+
+.clab-tooltip::-webkit-scrollbar-track {
+ background: #1a1a1a;
+ border-radius: 4px;
+}
+
+.clab-tooltip::-webkit-scrollbar-thumb {
+ background: #4CAF50;
+ border-radius: 4px;
+}
+
+.clab-tooltip::-webkit-scrollbar-thumb:hover {
+ background: #45a049;
+}
+
+
+/* 允许内容文本选择 */
+.entry-single,
+.entry-multiple,
+.q-list li {
+ user-select: text;
+ -webkit-user-select: text;
+}
+
+/* 鼠标在 tooltip 上时的样式 */
+.clab-tooltip:hover {
+ cursor: default;
+}
+
+
+.clab-tooltip.active {
+ opacity: 1;
+ visibility: visible;
+ transform: translateY(0);
+}
+
+.clab-tooltip ul {
+ margin: 0;
+ padding-left: 20px;
+}
+
+.clab-tooltip li {
+ margin-bottom: 8px;
+ position: relative;
+}
+
+.clab-tooltip .source {
+ margin-top: 10px;
+ padding-top: 10px;
+ border-top: 1px solid rgba(255,255,255,0.1);
+ font-size: 11px;
+ color: #aaa;
+ font-style: italic;
+}
+
+.clab-tooltip .entry {
+ margin-bottom: 15px;
+ padding-bottom: 10px;
+ border-bottom: 1px solid rgba(255,255,255,0.1);
+}
+
+.clab-tooltip .entry:last-child {
+ border-bottom: none;
+}
+
+
+
+.rem {
+ background-color: darkorange;
+ color: lightyellow;
+ text-decoration-thickness: 2px;
+}
+
+
+#criticnav {
+ position: fixed;
+ z-index: 1100;
+ top: 0;
+ right: 0;
+ width: 120px;
+ border-bottom: solid 1px #ffffff;
+ margin: 0;
+ padding: 10;
+ background-color: rgb(143 38 38 / 95%);
+ color: #ffffff;
+ font-size: 12px;
+ font-family: "Helvetica Neue", helvetica, arial, sans-serif !important
+}
+
+#criticnav ul {
+ list-style-type: none;
+ width: 90%;
+ margin: 0 auto;
+ padding: 0
+}
+
+#criticnav ul li {
+ display: block;
+ width: 100px;
+ min-width: 80px;
+ text-align: center;
+ padding: 5px 0 3px !important;
+ margin: 5px 2px !important;
+ line-height: 1em;
+ float: center;
+ text-transform: uppercase;
+ cursor: pointer;
+ border-radius: 20px;
+ border: 3px solid rgba(255,255,255,0);
+ color: #fff !important
+}
+
+p {
+ text-align: left; /* 小屏幕左对齐 */
+}
+
+@media (min-width: 768px) {
+ p {
+ text-align: justify;
+ hyphens: auto; /* 自动断字 */
+ -webkit-hyphens: auto; /* Safari 支持 */
+ /* 可选:控制断字行为 */
+ hyphenate-limit-chars: 6 3 2; /* 最小单词长度 前/后最小字符数 */
+ }
+}
+
+@media (min-width: 992px) {
+ body .page-columns {
+ display: grid;
+ gap: 0;
+ grid-template-columns: [screen-start] 0.5em [screen-start-inset] 0fr [page-start page-start-inset] 5px [body-start-outset] 5px [body-start] 0.5em [body-content-start] minmax(350px, calc(855px - 0em)) [body-content-end] 0.5em [body-end] 5px [body-end-outset] minmax(75px, 550px) [page-end-inset] 1px [page-end] 1fr [screen-end-inset] 0.5em [screen-end];
+ }
+}
+
+
+@media (min-width: 1280px) {
+ body .page-columns {
+ display: grid;
+ gap: 0;
+ grid-template-columns: [screen-start] 3.5em [screen-start-inset] 2fr [page-start page-start-inset] 35px [body-start-outset] 35px [body-start] 3.5em [body-content-start] minmax(500px, calc(850px - 3em)) [body-content-end] 1.5em [body-end] 35px [body-end-outset] minmax(75px, 400px) [page-end-inset] 35px [page-end] 2fr [screen-end-inset] 1.5em [screen-end];
+ }
+}
diff --git a/_extensions/drwater/dwhm/inst/drwater.scss b/_extensions/drwater/dwhm/inst/drwater.scss
new file mode 100644
index 0000000..93672cf
--- /dev/null
+++ b/_extensions/drwater/dwhm/inst/drwater.scss
@@ -0,0 +1,415 @@
+/*-- scss:defaults --*/
+
+$theme: "drwater" !default;
+
+//
+// Color system
+//
+
+$white: #ffffff !default;
+$gray-100: #f8f9fa !default;
+$gray-200: #e9ecef !default;
+$gray-300: #dee2e6 !default;
+$gray-400: #ced4da !default;
+$gray-500: #adb5bd !default;
+$gray-600: #868e96 !default;
+$gray-700: #495057 !default;
+$gray-800: #373a3c !default;
+$gray-900: #212529 !default;
+$black: #000000 !default;
+
+$blue: #2780e3 !default;
+$indigo: #6610f2 !default;
+$purple: #170c3a !default;
+$pink: #a52c60 !default;
+$red: #cf4446 !default;
+$orange: #ee6a24 !default;
+$light-orange: #fb9e07 !default;
+$yellow: #f6d645 !default;
+$green: #118230 !default;
+$teal: #20c997 !default;
+$cyan: #3093cf !default;
+
+$primary: $pink !default;
+$secondary: $gray-700 !default;
+$success: $green !default;
+$info: $cyan !default;
+$warning: $orange !default;
+$danger: $red !default;
+$light: $gray-400 !default;
+$dark: $black !default;
+
+// Fonts
+
+$font-family-sans-serif: "Libre Franklin" !default;
+
+$headings-font-family: "Jost" !default;
+$headings-font-weight: 600 !default;
+
+$navbar-font-family: "Jost" !default;
+$toc-font-family: "Jost" !default;
+$footer-font-family: "Jost" !default;
+
+// Body
+$body-color: $gray-900 !default;
+
+// Links
+$link-color: $orange !default;
+$link-decoration: none !default;
+$link-hover-color: $red !default;
+$link-hover-decoration: underline !default;
+
+// Inline code
+$code-bg: $gray-200 !default;
+$code-color: $gray-900 !default;
+
+// Code copy
+$btn-code-copy-color-active: $orange !default;
+
+// TOC
+$toc-color: $orange;
+$toc-font-size: 1em;
+
+// Navbar
+$navbar-bg: $purple !default;
+$navbar-fg: $white !default;
+$navbar-hl: $light-orange !default;
+
+// Footer
+$footer-bg: $gray-900 !default;
+$footer-fg: $gray-300 !default;
+
+/*-- scss:rules --*/
+
+$web-font-path: "https://fonts.googleapis.com/css2?family=Jost:ital,wght@0,100..900;1,100..900&family=Libre+Franklin:ital,wght@0,100..900;1,100..900&display=swap" !default;
+
+@if $web-font-path {
+ @import url($web-font-path);
+}
+
+body {
+ -webkit-font-smoothing: antialiased;
+}
+
+/* Logo 悬停效果 */
+.navbar-brand img {
+ transition: all 0.3s ease;
+ filter: brightness(0) invert(1);
+
+ &:hover {
+ filter: brightness(0) invert(0.55) sepia(1) saturate(2000%) hue-rotate(-8deg) brightness(1.05) contrast(1.2);
+ transform: scale(1.05);
+ }
+}
+
+// =============================================
+// 桌面端样式 - 使用悬停展开下拉菜单
+// =============================================
+@media (min-width: 992px) {
+ /* 导航栏主菜单项样式 */
+ .navbar-nav .nav-item {
+ position: relative;
+ margin: 0 0.2rem;
+
+ .nav-link {
+ position: relative;
+ color: $navbar-fg !important;
+ font-weight: 500;
+ padding: 0.75rem 1rem !important;
+ border-radius: 8px;
+ transition: all 0.3s ease;
+ z-index: 1;
+
+ /* 玻璃效果背景 */
+ &::before {
+ content: '';
+ position: absolute;
+ top: 0;
+ left: 0;
+ right: 0;
+ bottom: 0;
+ background: rgba($white, 0.1);
+ backdrop-filter: blur(10px);
+ border-radius: 8px;
+ opacity: 0;
+ transition: all 0.3s ease;
+ z-index: -1;
+ border: 1px solid rgba($white, 0.2);
+ }
+
+ &:hover {
+ color: $light-orange !important;
+ transform: translateY(-2px);
+
+ &::before {
+ opacity: 1;
+ background: rgba($white, 0.15);
+ backdrop-filter: blur(15px);
+ box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
+ }
+ }
+
+ /* 激活状态 */
+ &.active {
+ color: $light-orange !important;
+ font-weight: 600;
+
+ &::before {
+ opacity: 1;
+ background: rgba($light-orange, 0.2);
+ backdrop-filter: blur(15px);
+ border: 1px solid rgba($light-orange, 0.3);
+ }
+ }
+ }
+ }
+
+ /* 有下拉菜单的主菜单项特殊样式 */
+ .navbar-nav .nav-item.dropdown {
+ .nav-link {
+ padding-right: 2rem !important;
+
+ &::after {
+ position: absolute;
+ right: 1rem;
+ top: 50%;
+ transform: translateY(-50%);
+ transition: all 0.3s ease;
+ }
+ }
+
+ &:hover .nav-link::before {
+ opacity: 1;
+ background: rgba($white, 0.2);
+ backdrop-filter: blur(20px);
+ border-bottom-left-radius: 0;
+ border-bottom-right-radius: 0;
+ }
+
+ &:hover .nav-link::after {
+ transform: translateY(-50%) rotate(-180deg);
+ border-top-color: $light-orange;
+ }
+ }
+
+ /* 桌面端下拉菜单悬停效果 */
+ .navbar-nav .nav-item.dropdown:hover .dropdown-menu {
+ display: block !important;
+ opacity: 1 !important;
+ visibility: visible !important;
+ transform: translateY(0) !important;
+ }
+
+ .dropdown-menu {
+ display: block;
+ opacity: 0;
+ visibility: hidden;
+ transform: translateY(-10px);
+ transition: all 0.3s ease;
+ background: rgba($purple, 0.98) !important;
+ backdrop-filter: blur(20px);
+ border: 1px solid rgba($white, 0.1);
+ border-top: none;
+ border-radius: 0 0 8px 8px;
+ box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
+ margin-top: -1px;
+ padding: 0.5rem 0;
+
+ &.show {
+ display: block;
+ opacity: 1;
+ visibility: visible;
+ transform: translateY(0);
+ }
+ }
+
+ .dropdown-item {
+ color: $white !important;
+ font-family: $navbar-font-family;
+ padding: 0.75rem 1.5rem;
+ transition: all 0.2s ease;
+ position: relative;
+
+ /* 下拉菜单项的玻璃效果 */
+ &::before {
+ content: '';
+ position: absolute;
+ top: 0;
+ left: 0;
+ right: 0;
+ bottom: 0;
+ background: rgba($white, 0.05);
+ border-radius: 4px;
+ opacity: 0;
+ transition: all 0.2s ease;
+ z-index: -1;
+ }
+
+ &:hover, &:focus {
+ color: $light-orange !important;
+ transform: translateX(5px);
+ background: transparent !important;
+
+ &::before {
+ opacity: 1;
+ background: rgba($white, 0.1);
+ }
+ }
+ }
+
+ /* 确保下拉菜单与主菜单视觉上连接 */
+ .navbar-nav .nav-item.dropdown:hover .nav-link {
+ border-bottom-left-radius: 0;
+ border-bottom-right-radius: 0;
+ }
+}
+
+// =============================================
+// 移动端样式 - 使用点击展开下拉菜单
+// =============================================
+@media (max-width: 991.98px) {
+ /* 完全重置移动端导航样式,使用 Bootstrap 默认行为 */
+ .navbar-collapse {
+ background: rgba($purple, 0.98);
+ backdrop-filter: blur(10px);
+ border-top: 1px solid rgba($white, 0.1);
+ margin-top: 0.5rem;
+ padding: 0.5rem 0;
+
+ .navbar-nav {
+ .nav-item {
+ margin: 0;
+
+ .nav-link {
+ color: $navbar-fg !important;
+ padding: 1rem 1.5rem !important;
+ border-radius: 0;
+ transition: all 0.2s ease;
+ display: flex;
+ justify-content: space-between;
+ align-items: center;
+
+ &:hover {
+ color: $light-orange !important;
+ background: rgba($white, 0.1);
+ }
+
+ &.active {
+ color: $light-orange !important;
+ background: rgba($light-orange, 0.1);
+ font-weight: 600;
+ }
+ }
+
+ /* 下拉菜单项样式 */
+ &.dropdown {
+ .dropdown-toggle::after {
+ transition: transform 0.3s ease;
+ }
+
+ &.show {
+ .dropdown-toggle {
+ color: $light-orange !important;
+ background: rgba($white, 0.15);
+
+ &::after {
+ transform: rotate(-180deg);
+ }
+ }
+ }
+
+ .dropdown-menu {
+ background: rgba(darken($purple, 5%), 0.95) !important;
+ border: none;
+ border-radius: 0;
+ padding: 0;
+ margin: 0;
+ position: static;
+ float: none;
+ display: none;
+
+ &.show {
+ display: block !important;
+ }
+ }
+ }
+ }
+ }
+ }
+
+ /* 移动端下拉菜单项 */
+ .dropdown-item {
+ color: $navbar-fg !important;
+ padding: 0.875rem 1.5rem 0.875rem 2.5rem !important;
+ border-radius: 0;
+ transition: all 0.2s ease;
+
+ &:hover, &:focus {
+ color: $light-orange !important;
+ background: rgba($white, 0.1) !important;
+ transform: none;
+ }
+
+ &.active {
+ color: $light-orange !important;
+ background: rgba($light-orange, 0.1) !important;
+ font-weight: 600;
+ }
+ }
+
+ /* 移动端导航栏折叠按钮 */
+ .navbar-toggler {
+ border: 1px solid rgba($white, 0.2);
+ padding: 0.5rem 0.75rem;
+
+ &:focus {
+ box-shadow: 0 0 0 0.2rem rgba($light-orange, 0.25);
+ }
+
+ .navbar-toggler-icon {
+ background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.8%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
+ }
+ }
+
+ /* 禁用桌面端的悬停效果 */
+ .navbar-nav .nav-item .nav-link::before {
+ display: none;
+ }
+
+ .navbar-nav .nav-item.dropdown:hover .dropdown-menu {
+ display: none !important;
+ }
+}
+
+// =============================================
+// 通用样式
+// =============================================
+
+/* 导航栏整体样式 */
+.navbar {
+ backdrop-filter: blur(10px);
+ background: rgba($purple, 0.95) !important;
+ border-bottom: 1px solid rgba($white, 0.1);
+}
+
+/* 为有下拉菜单的导航项添加视觉指示 */
+.navbar-nav .nav-item.dropdown > .nav-link::after {
+ display: inline-block;
+ margin-left: 0.255em;
+ vertical-align: 0.255em;
+ content: "";
+ border-top: 0.3em solid;
+ border-right: 0.3em solid transparent;
+ border-bottom: 0;
+ border-left: 0.3em solid transparent;
+}
+
+/* 确保 Bootstrap 的 JavaScript 交互正常工作 */
+.navbar-nav .dropdown-toggle::after {
+ display: inline-block !important;
+}
+
+/* 修复移动端点击事件 */
+.navbar-nav .nav-item.dropdown .nav-link {
+ cursor: pointer;
+}
diff --git a/_extensions/drwater/dwhm/template.qmd b/_extensions/drwater/dwhm/template.qmd
new file mode 100644
index 0000000..aaee17c
--- /dev/null
+++ b/_extensions/drwater/dwhm/template.qmd
@@ -0,0 +1,16 @@
+---
+title: Untitled
+format:
+ dwhm-html: default
+author: Ming Su
+date: last-modified
+---
+
+## Introduction
+
+*TODO* Create an example file that demonstrates the formatting and features of your format.
+
+## More Information
+
+You can learn more about controlling the appearance of HTML output here:
+
diff --git a/_extensions/drwater/dwinst/CL.docx b/_extensions/drwater/dwinst/CL.docx
new file mode 100755
index 0000000..3727b07
Binary files /dev/null and b/_extensions/drwater/dwinst/CL.docx differ
diff --git a/_extensions/drwater/dwinst/MS.docx b/_extensions/drwater/dwinst/MS.docx
new file mode 100644
index 0000000..0165cf5
Binary files /dev/null and b/_extensions/drwater/dwinst/MS.docx differ
diff --git a/_extensions/drwater/dwinst/RN.docx b/_extensions/drwater/dwinst/RN.docx
new file mode 100755
index 0000000..a74403c
Binary files /dev/null and b/_extensions/drwater/dwinst/RN.docx differ
diff --git a/_extensions/drwater/dwinst/RP.docx b/_extensions/drwater/dwinst/RP.docx
new file mode 100755
index 0000000..18580b1
Binary files /dev/null and b/_extensions/drwater/dwinst/RP.docx differ
diff --git a/_extensions/drwater/dwinst/american-chemical-society.csl b/_extensions/drwater/dwinst/american-chemical-society.csl
new file mode 100755
index 0000000..01f8c49
--- /dev/null
+++ b/_extensions/drwater/dwinst/american-chemical-society.csl
@@ -0,0 +1,280 @@
+
+
diff --git a/_extensions/drwater/dwinst/china-national-standard-gb-t-7714-2015-numeric.csl b/_extensions/drwater/dwinst/china-national-standard-gb-t-7714-2015-numeric.csl
new file mode 100755
index 0000000..f7c84f0
--- /dev/null
+++ b/_extensions/drwater/dwinst/china-national-standard-gb-t-7714-2015-numeric.csl
@@ -0,0 +1,435 @@
+
+
diff --git a/_extensions/drwater/dwinst/clab-tooltip.js b/_extensions/drwater/dwinst/clab-tooltip.js
new file mode 100644
index 0000000..900b133
--- /dev/null
+++ b/_extensions/drwater/dwinst/clab-tooltip.js
@@ -0,0 +1,418 @@
+// clab-tooltip.js - 完全隔离事件版本(修改后的显示位置逻辑)
+(function() {
+ // 全局变量存储从 RN.html 提取的内容
+ let rnContentCache = {};
+ let isRnContentLoaded = false;
+ let activeTooltip = null;
+ let hideTimer = null;
+ let isMouseOverTooltip = false;
+
+ // 从 RN.html 提取内容(保持不变)
+ async function loadRnContent() {
+ try {
+ console.log('加载 RN.html...');
+ const response = await fetch('RN.html');
+ if (!response.ok) throw new Error(`HTTP error: ${response.status}`);
+
+ const htmlText = await response.text();
+ const parser = new DOMParser();
+ const rnDoc = parser.parseFromString(htmlText, 'text/html');
+
+ // 查找所有包含 data-options 的元素
+ const optionElements = rnDoc.querySelectorAll('[data-options]');
+ console.log(`找到 ${optionElements.length} 个 data-options 元素`);
+
+ optionElements.forEach(element => {
+ const optionValue = element.getAttribute('data-options');
+ if (!optionValue) return;
+
+ // 向前查找最近的 blockquote
+ let prevElement = element.previousElementSibling;
+ let blockquote = null;
+
+ // 先找前一个兄弟元素
+ while (prevElement) {
+ if (prevElement.tagName === 'BLOCKQUOTE') {
+ blockquote = prevElement;
+ break;
+ }
+ prevElement = prevElement.previousElementSibling;
+ }
+
+ // 如果没找到,向上查找
+ if (!blockquote) {
+ let parent = element.parentElement;
+ while (parent) {
+ let sibling = parent.previousElementSibling;
+ while (sibling) {
+ if (sibling.tagName === 'BLOCKQUOTE') {
+ blockquote = sibling;
+ break;
+ }
+ sibling = sibling.previousElementSibling;
+ }
+ if (blockquote) break;
+ parent = parent.parentElement;
+ }
+ }
+
+ if (blockquote) {
+ const lis = blockquote.querySelectorAll('li');
+ if (lis.length > 0) {
+ const liContents = Array.from(lis).map(li => li.textContent.trim());
+
+ if (!rnContentCache[optionValue]) {
+ rnContentCache[optionValue] = [];
+ }
+
+ // 存储所有引用
+ rnContentCache[optionValue].push({
+ contents: liContents
+ });
+ }
+ }
+ });
+
+ isRnContentLoaded = true;
+
+ console.log('内容加载完成');
+ Object.keys(rnContentCache).forEach(key => {
+ console.log(`"${key}": ${rnContentCache[key].length} Questions`);
+ });
+
+ } catch (error) {
+ console.error('加载失败:', error);
+ }
+ }
+
+ // 创建 tooltip(保持不变)
+ function createTooltip() {
+ const tooltip = document.createElement('div');
+ tooltip.className = 'clab-tooltip';
+ tooltip.id = 'clab-tooltip-element';
+
+ // 完全阻止所有事件冒泡
+ const stopAllEvents = (e) => {
+ e.stopPropagation();
+ e.stopImmediatePropagation();
+ e.preventDefault();
+ return false;
+ };
+
+ // 阻止所有可能的事件
+ const events = [
+ 'mousedown', 'mouseup', 'click', 'dblclick',
+ 'mousemove', 'mouseover', 'mouseout', 'mouseenter', 'mouseleave',
+ 'wheel', 'scroll',
+ 'touchstart', 'touchmove', 'touchend', 'touchcancel',
+ 'pointerdown', 'pointermove', 'pointerup', 'pointercancel',
+ 'dragstart', 'dragover', 'drop'
+ ];
+
+ events.forEach(eventType => {
+ tooltip.addEventListener(eventType, stopAllEvents, true); // 捕获阶段
+ tooltip.addEventListener(eventType, stopAllEvents, false); // 冒泡阶段
+ });
+
+ // 允许 wheel 事件用于滚动,但阻止冒泡
+ tooltip.addEventListener('wheel', function(e) {
+ e.stopPropagation();
+ e.stopImmediatePropagation();
+ // 允许默认的滚动行为
+ }, { passive: false });
+
+ // 允许鼠标在 tooltip 内移动
+ tooltip.addEventListener('mousemove', function(e) {
+ e.stopPropagation();
+ }, { passive: true });
+
+ document.body.appendChild(tooltip);
+ return tooltip;
+ }
+
+ // 显示 tooltip - 已修改位置逻辑
+ function showTooltip(element, tooltip) {
+ const rect = element.getBoundingClientRect();
+ const optionValue = element.getAttribute('data-options');
+
+ // 清空内容
+ tooltip.innerHTML = '';
+
+ if (rnContentCache[optionValue] && rnContentCache[optionValue].length > 0) {
+ const entries = rnContentCache[optionValue];
+
+ // 标题显示选项
+ const title = document.createElement('div');
+ title.className = 'tooltip-title';
+ title.textContent = optionValue;
+ if (entries.length > 1) {
+ title.textContent += ` (${entries.length} questions)`;
+ }
+ tooltip.appendChild(title);
+
+ // 显示所有引用
+ entries.forEach((entry, entryIndex) => {
+ const content = entry.contents;
+
+ if (content.length === 1) {
+ // 单一条目
+ const entryDiv = document.createElement('div');
+ entryDiv.className = 'entry-single';
+
+ if (entries.length >= 1) {
+ entryDiv.innerHTML = `Q${entryIndex + 1}: ${content[0]}`;
+ } else {
+ entryDiv.textContent = content[0];
+ }
+
+ tooltip.appendChild(entryDiv);
+ } else {
+ // 多个条目
+ const entryDiv = document.createElement('div');
+ entryDiv.className = 'entry-multiple';
+
+ if (entries.length > 1) {
+ const header = document.createElement('div');
+ header.className = 'q-header';
+ header.textContent = `Q${entryIndex + 1}:`;
+ entryDiv.appendChild(header);
+ }
+
+ const ol = document.createElement('ol');
+ ol.className = 'q-list';
+
+ content.forEach((item, itemIndex) => {
+ const li = document.createElement('li');
+ li.innerHTML = `${entryIndex + 1}.${itemIndex + 1} ${item}`;
+ ol.appendChild(li);
+ });
+
+ entryDiv.appendChild(ol);
+ tooltip.appendChild(entryDiv);
+ }
+ });
+ } else {
+ // 没有找到内容
+ const noContent = document.createElement('div');
+ noContent.className = 'tooltip-no-content';
+ noContent.textContent = '未找到相关内容';
+ tooltip.appendChild(noContent);
+ }
+
+ // 确保 tooltip 有合适的尺寸
+ tooltip.style.position = 'fixed';
+ tooltip.style.zIndex = '10000';
+ tooltip.style.maxWidth = '400px';
+ tooltip.style.maxHeight = '500px';
+ tooltip.style.overflowY = 'auto';
+ tooltip.style.boxSizing = 'border-box';
+
+ // 首先隐藏并获取尺寸
+ tooltip.style.visibility = 'hidden';
+ tooltip.classList.add('active');
+ document.body.appendChild(tooltip);
+
+ const tooltipWidth = Math.min(tooltip.scrollWidth, 400);
+ const tooltipHeight = Math.min(tooltip.scrollHeight, 500);
+
+ tooltip.style.width = tooltipWidth + 'px';
+ tooltip.style.height = 'auto';
+
+ const padding = 5;
+ const minDistanceFromEdge = 20;
+
+ let left, top;
+ let position = 'right'; // 首选右侧
+
+ // 检查右侧空间
+ if (rect.right + padding + tooltipWidth <= window.innerWidth - minDistanceFromEdge) {
+ // 右侧有足够空间
+ left = rect.right + padding;
+ top = rect.top;
+ position = 'right';
+ } else if (rect.left - padding - tooltipWidth >= minDistanceFromEdge) {
+ // 左侧有足够空间
+ left = rect.left - padding - tooltipWidth;
+ top = rect.top;
+ position = 'left';
+ } else {
+ // 两侧都没有足够空间,显示在下方
+ left = Math.max(
+ minDistanceFromEdge,
+ Math.min(
+ rect.left + (rect.width - tooltipWidth) / 2,
+ window.innerWidth - tooltipWidth - minDistanceFromEdge
+ )
+ );
+ top = rect.bottom + padding;
+ position = 'bottom';
+ }
+
+ // 垂直边界检查 - 确保不超出屏幕
+ if (top + tooltipHeight > window.innerHeight - minDistanceFromEdge) {
+ // 如果下方空间不足,尝试显示在上方
+ if (rect.top - padding - tooltipHeight >= minDistanceFromEdge) {
+ top = rect.top - padding - tooltipHeight;
+ } else {
+ // 上下都不够,显示在中间
+ top = Math.max(
+ minDistanceFromEdge,
+ Math.min(
+ top,
+ window.innerHeight - tooltipHeight - minDistanceFromEdge
+ )
+ );
+ }
+ }
+
+ // 水平边界检查 - 确保不超出屏幕
+ if (position === 'right' || position === 'left') {
+ left = Math.max(
+ minDistanceFromEdge,
+ Math.min(left, window.innerWidth - tooltipWidth - minDistanceFromEdge)
+ );
+ }
+
+ tooltip.style.left = left + 'px';
+ tooltip.style.top = top + 'px';
+ tooltip.style.visibility = 'visible';
+
+ // 添加一个小箭头指示方向
+ tooltip.setAttribute('data-position', position);
+
+ activeTooltip = tooltip;
+ isMouseOverTooltip = true;
+
+ // 添加 overlay 防止 body 交互
+ addOverlay();
+ }
+
+ // 添加半透明 overlay(保持不变)
+ function addOverlay() {
+ // 移除现有的 overlay
+ removeOverlay();
+
+ const overlay = document.createElement('div');
+ overlay.id = 'tooltip-overlay';
+ overlay.style.cssText = `
+ position: fixed;
+ top: 0;
+ left: 0;
+ width: 100%;
+ height: 100%;
+ z-index: 9999;
+ background: transparent;
+ pointer-events: none;
+ `;
+ document.body.appendChild(overlay);
+
+ // 将 overlay 的 pointer-events 设为 auto,但阻止所有事件
+ overlay.addEventListener('mousedown', stopEvent, true);
+ overlay.addEventListener('mouseup', stopEvent, true);
+ overlay.addEventListener('click', stopEvent, true);
+ overlay.addEventListener('mousemove', stopEvent, true);
+ overlay.addEventListener('wheel', stopEvent, true);
+
+ function stopEvent(e) {
+ e.preventDefault();
+ e.stopPropagation();
+ e.stopImmediatePropagation();
+ return false;
+ }
+ }
+
+ // 移除 overlay(保持不变)
+ function removeOverlay() {
+ const overlay = document.getElementById('tooltip-overlay');
+ if (overlay) {
+ overlay.remove();
+ }
+ }
+
+ // 隐藏 tooltip(保持不变)
+ function hideTooltip() {
+ if (!isMouseOverTooltip && activeTooltip) {
+ activeTooltip.classList.remove('active');
+ activeTooltip = null;
+ removeOverlay();
+ }
+ }
+
+ // 强制隐藏 tooltip(保持不变)
+ function forceHideTooltip() {
+ if (activeTooltip) {
+ activeTooltip.classList.remove('active');
+ activeTooltip = null;
+ isMouseOverTooltip = false;
+ removeOverlay();
+ }
+ }
+
+ // 初始化(保持不变)
+ document.addEventListener('DOMContentLoaded', function() {
+ console.log('初始化 clab-tooltip');
+
+ const clabElements = document.querySelectorAll('.clab[data-options]');
+ console.log(`找到 ${clabElements.length} 个 .clab 元素`);
+
+ if (clabElements.length === 0) return;
+
+ // 加载内容
+ loadRnContent();
+
+ // 创建 tooltip
+ const tooltip = createTooltip();
+
+ // tooltip 鼠标进入/离开
+ tooltip.addEventListener('mouseenter', function() {
+ isMouseOverTooltip = true;
+ clearTimeout(hideTimer);
+ });
+
+ tooltip.addEventListener('mouseleave', function() {
+ isMouseOverTooltip = false;
+ hideTimer = setTimeout(() => {
+ forceHideTooltip();
+ }, 100);
+ });
+
+ // 为所有 .clab 元素添加事件监听
+ clabElements.forEach(clab => {
+ clab.addEventListener('mouseenter', function() {
+ clearTimeout(hideTimer);
+
+ setTimeout(() => {
+ if (isRnContentLoaded) {
+ showTooltip(this, tooltip);
+ }
+ }, 100);
+ });
+
+ clab.addEventListener('mouseleave', function() {
+ hideTimer = setTimeout(() => {
+ hideTooltip();
+ }, 100);
+ });
+ });
+
+ // ESC 键隐藏 tooltip
+ document.addEventListener('keydown', function(e) {
+ if (e.key === 'Escape' && activeTooltip) {
+ forceHideTooltip();
+ }
+ });
+
+ // 点击其他地方隐藏 tooltip
+ document.addEventListener('click', function(e) {
+ if (activeTooltip && !activeTooltip.contains(e.target)) {
+ forceHideTooltip();
+ }
+ });
+
+ // 窗口大小改变时隐藏 tooltip
+ window.addEventListener('resize', forceHideTooltip);
+
+ // 滚动时隐藏 tooltip
+ window.addEventListener('scroll', forceHideTooltip);
+ });
+})();
diff --git a/_extensions/drwater/dwinst/drwater-white0.png b/_extensions/drwater/dwinst/drwater-white0.png
new file mode 100644
index 0000000..cdb43c1
Binary files /dev/null and b/_extensions/drwater/dwinst/drwater-white0.png differ
diff --git a/_extensions/drwater/dwinst/drwater-white0.svg b/_extensions/drwater/dwinst/drwater-white0.svg
new file mode 100644
index 0000000..0a12a38
--- /dev/null
+++ b/_extensions/drwater/dwinst/drwater-white0.svg
@@ -0,0 +1,13 @@
+
+
diff --git a/_extensions/drwater/dwinst/drwater.css b/_extensions/drwater/dwinst/drwater.css
new file mode 100755
index 0000000..1c92fe3
--- /dev/null
+++ b/_extensions/drwater/dwinst/drwater.css
@@ -0,0 +1,384 @@
+.udot {
+ text-decoration-line: underline;
+ text-decoration-color: rgb(50, 50, 50);
+ text-decoration-style: dashed;
+ text-decoration-thickness: 1px;
+}
+
+.good {
+ background-color: forestgreen;
+ color: lightyellow;
+}
+
+.bad {
+ background-color: orangered;
+ color: lightyellow;
+}
+
+.del {
+ text-decoration-line: line-through;
+ text-decoration-color: rgb(222 13 13);
+ text-decoration-style: initial;
+ text-decoration-thickness: 1.5px;
+}
+
+
+.todo {
+ background-color: darkorange;
+ color: lightyellow;
+}
+
+.com {
+ background-color: #0025ff;
+ font-weight: bold;
+ color: lightyellow;
+}
+
+.add {
+ text-decoration-line: underline;
+ text-decoration-color: rgb(222 13 13);
+ background-color: violet;
+ text-decoration-style: initial;
+ text-decoration-thickness: 2px;
+}
+
+
+del {
+ text-decoration-line: line-through;
+ text-decoration-color: rgb(222 13 13);
+ text-decoration-style: initial;
+ text-decoration-thickness: 1.0px;
+}
+
+
+ins {
+ text-decoration-color: rgb(222 93 93);
+ background-color: violet;
+ text-decoration-style: initial;
+ text-decoration-thickness: 2px;
+}
+
+
+
+/* clab-style.css */
+.clab {
+ display: inline !important;
+ position: relative !important;
+ cursor: pointer !important;
+ padding: 2px 4px !important;
+ margin: 0 1px !important;
+ border-radius: 3px !important;
+ font: inherit !important;
+ color: #000000 !important;
+ text-decoration: none !important;
+ vertical-align: baseline !important;
+ line-height: inherit !important;
+ z-index: 1 !important;
+}
+
+/* 随机背景色(使用预定义颜色) */
+.clab:nth-child(10n+1) { background-color: #E3F2FD !important; }
+.clab:nth-child(10n+2) { background-color: #F3E5F5 !important; }
+.clab:nth-child(10n+3) { background-color: #E8F5E9 !important; }
+.clab:nth-child(10n+4) { background-color: #FFF3E0 !important; }
+.clab:nth-child(10n+5) { background-color: #FCE4EC !important; }
+.clab:nth-child(10n+6) { background-color: #E0F7FA !important; }
+.clab:nth-child(10n+7) { background-color: #F1F8E9 !important; }
+.clab:nth-child(10n+8) { background-color: #FFF8E1 !important; }
+.clab:nth-child(10n+9) { background-color: #EDE7F6 !important; }
+.clab:nth-child(10n+10) { background-color: #E8EAF6 !important; }
+
+/* 基础hover效果 */
+span.clab:hover {
+ outline: 2px solid rgba(0,0,0,0.2) !important;
+ outline-offset: 2px !important;
+ z-index: 1000 !important;
+}
+
+
+
+
+/* clab-tooltip 下方显示样式 */
+.clab-tooltip {
+ font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
+ color: white;
+ padding: 5px;
+ border: 1px solid #444;
+ /* -webkit-user-select: none; */
+ position: fixed;
+ background: rgba(0, 0, 0, 0.95);
+ border-radius: 8px;
+ z-index: 10000;
+ box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3),
+ 0 0 0 1px rgba(255, 255, 255, 0.1);
+ font-size: 14px;
+ line-height: 1.1;
+ max-width: 500px;
+ max-height: 800px;
+ overflow-y: auto;
+ opacity: 0;
+ visibility: hidden;
+ transition: opacity 0.2s ease, visibility 0.2s ease, transform 0.2s ease;
+ overscroll-behavior: contain;
+ pointer-events: auto !important;
+}
+
+
+/* Tooltip 箭头 */
+.tooltip-arrow {
+ position: absolute;
+ width: 0;
+ height: 0;
+ border: 6px solid transparent;
+ border-bottom-color: #2a2a2a;
+ border-top: none;
+}
+
+/* tooltip 在上方的箭头(向下) */
+.clab-tooltip.above .tooltip-arrow {
+ border-top-color: #2a2a2a;
+ border-bottom: none;
+}
+
+/* 标题 */
+.tooltip-title {
+ font-weight: 600;
+ color: #FF9800;
+ margin-bottom: 6px;
+ padding-bottom: 4px;
+ border-bottom: 1px solid #444;
+ font-size: 14px;
+ font-family: monospace;
+ line-height: 0.8;
+ pointer-events: none;
+}
+
+/* 单一条目 */
+.entry-single {
+ padding: 4px 4px;
+ margin-bottom: 6px;
+ background: rgba(255, 255, 255, 0.05);
+ border-radius: 6px;
+ border-left: 3px solid #ffffff;
+ line-height: 1.2;
+ cursor: default;
+}
+
+/* Q标签样式 */
+.q-label {
+ display: inline-block;
+ color: #FF9800;
+ font-weight: 600;
+ margin-right: 8px;
+ min-width: 35px;
+}
+
+/* 多个条目的引用 */
+.entry-multiple {
+ padding: 4px 4px;
+ margin-bottom: 6px;
+ background: rgba(255, 255, 255, 0.05);
+ border-radius: 6px;
+ border-left: 3px solid #ffffff;
+ line-height: 1.2;
+ cursor: default;
+}
+
+/* 多引用标题 */
+.q-header {
+ color: #FF9800;
+ font-weight: 600;
+ margin-bottom: 8px;
+ font-size: 13px;
+ pointer-events: none;
+}
+
+/* 列表 */
+.q-list {
+ margin: 0;
+ padding-left: 0;
+ list-style: none;
+}
+
+.q-list li {
+ margin-bottom: 10px;
+ padding-left: 0;
+ line-height: 1.2;
+ position: relative;
+ cursor: default;
+ padding: 4px 0;
+}
+
+/* 子标签样式 */
+.q-sublabel {
+ display: inline-block;
+ color: #4CAF50;
+ font-weight: 600;
+ margin-right: 2px;
+ min-width: 25px;
+}
+
+/* 条目间空行 */
+/* .entry-spacer { */
+/* height: 12px; */
+/* pointer-events: none; */
+/* } */
+
+/* 无内容 */
+.tooltip-no-content {
+ color: #ff6b6b;
+ font-style: italic;
+ padding: 20px;
+ text-align: center;
+ background: rgba(255, 107, 107, 0.05);
+ border-radius: 6px;
+ cursor: default;
+}
+
+/* 滚动条 */
+.clab-tooltip::-webkit-scrollbar {
+ width: 8px;
+ height: 8px;
+}
+
+.clab-tooltip::-webkit-scrollbar-track {
+ background: #1a1a1a;
+ border-radius: 4px;
+}
+
+.clab-tooltip::-webkit-scrollbar-thumb {
+ background: #4CAF50;
+ border-radius: 4px;
+}
+
+.clab-tooltip::-webkit-scrollbar-thumb:hover {
+ background: #45a049;
+}
+
+
+/* 允许内容文本选择 */
+.entry-single,
+.entry-multiple,
+.q-list li {
+ user-select: text;
+ -webkit-user-select: text;
+}
+
+/* 鼠标在 tooltip 上时的样式 */
+.clab-tooltip:hover {
+ cursor: default;
+}
+
+
+.clab-tooltip.active {
+ opacity: 1;
+ visibility: visible;
+ transform: translateY(0);
+}
+
+.clab-tooltip ul {
+ margin: 0;
+ padding-left: 20px;
+}
+
+.clab-tooltip li {
+ margin-bottom: 8px;
+ position: relative;
+}
+
+.clab-tooltip .source {
+ margin-top: 10px;
+ padding-top: 10px;
+ border-top: 1px solid rgba(255,255,255,0.1);
+ font-size: 11px;
+ color: #aaa;
+ font-style: italic;
+}
+
+.clab-tooltip .entry {
+ margin-bottom: 15px;
+ padding-bottom: 10px;
+ border-bottom: 1px solid rgba(255,255,255,0.1);
+}
+
+.clab-tooltip .entry:last-child {
+ border-bottom: none;
+}
+
+
+
+.rem {
+ background-color: darkorange;
+ color: lightyellow;
+ text-decoration-thickness: 2px;
+}
+
+
+#criticnav {
+ position: fixed;
+ z-index: 1100;
+ top: 0;
+ right: 0;
+ width: 120px;
+ border-bottom: solid 1px #ffffff;
+ margin: 0;
+ padding: 10;
+ background-color: rgb(143 38 38 / 95%);
+ color: #ffffff;
+ font-size: 12px;
+ font-family: "Helvetica Neue", helvetica, arial, sans-serif !important
+}
+
+#criticnav ul {
+ list-style-type: none;
+ width: 90%;
+ margin: 0 auto;
+ padding: 0
+}
+
+#criticnav ul li {
+ display: block;
+ width: 100px;
+ min-width: 80px;
+ text-align: center;
+ padding: 5px 0 3px !important;
+ margin: 5px 2px !important;
+ line-height: 1em;
+ float: center;
+ text-transform: uppercase;
+ cursor: pointer;
+ border-radius: 20px;
+ border: 3px solid rgba(255,255,255,0);
+ color: #fff !important
+}
+
+p {
+ text-align: left; /* 小屏幕左对齐 */
+}
+
+@media (min-width: 768px) {
+ p {
+ text-align: justify;
+ hyphens: auto; /* 自动断字 */
+ -webkit-hyphens: auto; /* Safari 支持 */
+ /* 可选:控制断字行为 */
+ hyphenate-limit-chars: 6 3 2; /* 最小单词长度 前/后最小字符数 */
+ }
+}
+
+@media (min-width: 992px) {
+ body .page-columns {
+ display: grid;
+ gap: 0;
+ grid-template-columns: [screen-start] 0.5em [screen-start-inset] 0fr [page-start page-start-inset] 5px [body-start-outset] 5px [body-start] 0.5em [body-content-start] minmax(350px, calc(855px - 0em)) [body-content-end] 0.5em [body-end] 5px [body-end-outset] minmax(75px, 550px) [page-end-inset] 1px [page-end] 1fr [screen-end-inset] 0.5em [screen-end];
+ }
+}
+
+
+@media (min-width: 1280px) {
+ body .page-columns {
+ display: grid;
+ gap: 0;
+ grid-template-columns: [screen-start] 3.5em [screen-start-inset] 2fr [page-start page-start-inset] 35px [body-start-outset] 35px [body-start] 3.5em [body-content-start] minmax(500px, calc(850px - 3em)) [body-content-end] 1.5em [body-end] 35px [body-end-outset] minmax(75px, 400px) [page-end-inset] 35px [page-end] 2fr [screen-end-inset] 1.5em [screen-end];
+ }
+}
diff --git a/_extensions/drwater/dwinst/drwater.scss b/_extensions/drwater/dwinst/drwater.scss
new file mode 100644
index 0000000..93672cf
--- /dev/null
+++ b/_extensions/drwater/dwinst/drwater.scss
@@ -0,0 +1,415 @@
+/*-- scss:defaults --*/
+
+$theme: "drwater" !default;
+
+//
+// Color system
+//
+
+$white: #ffffff !default;
+$gray-100: #f8f9fa !default;
+$gray-200: #e9ecef !default;
+$gray-300: #dee2e6 !default;
+$gray-400: #ced4da !default;
+$gray-500: #adb5bd !default;
+$gray-600: #868e96 !default;
+$gray-700: #495057 !default;
+$gray-800: #373a3c !default;
+$gray-900: #212529 !default;
+$black: #000000 !default;
+
+$blue: #2780e3 !default;
+$indigo: #6610f2 !default;
+$purple: #170c3a !default;
+$pink: #a52c60 !default;
+$red: #cf4446 !default;
+$orange: #ee6a24 !default;
+$light-orange: #fb9e07 !default;
+$yellow: #f6d645 !default;
+$green: #118230 !default;
+$teal: #20c997 !default;
+$cyan: #3093cf !default;
+
+$primary: $pink !default;
+$secondary: $gray-700 !default;
+$success: $green !default;
+$info: $cyan !default;
+$warning: $orange !default;
+$danger: $red !default;
+$light: $gray-400 !default;
+$dark: $black !default;
+
+// Fonts
+
+$font-family-sans-serif: "Libre Franklin" !default;
+
+$headings-font-family: "Jost" !default;
+$headings-font-weight: 600 !default;
+
+$navbar-font-family: "Jost" !default;
+$toc-font-family: "Jost" !default;
+$footer-font-family: "Jost" !default;
+
+// Body
+$body-color: $gray-900 !default;
+
+// Links
+$link-color: $orange !default;
+$link-decoration: none !default;
+$link-hover-color: $red !default;
+$link-hover-decoration: underline !default;
+
+// Inline code
+$code-bg: $gray-200 !default;
+$code-color: $gray-900 !default;
+
+// Code copy
+$btn-code-copy-color-active: $orange !default;
+
+// TOC
+$toc-color: $orange;
+$toc-font-size: 1em;
+
+// Navbar
+$navbar-bg: $purple !default;
+$navbar-fg: $white !default;
+$navbar-hl: $light-orange !default;
+
+// Footer
+$footer-bg: $gray-900 !default;
+$footer-fg: $gray-300 !default;
+
+/*-- scss:rules --*/
+
+$web-font-path: "https://fonts.googleapis.com/css2?family=Jost:ital,wght@0,100..900;1,100..900&family=Libre+Franklin:ital,wght@0,100..900;1,100..900&display=swap" !default;
+
+@if $web-font-path {
+ @import url($web-font-path);
+}
+
+body {
+ -webkit-font-smoothing: antialiased;
+}
+
+/* Logo 悬停效果 */
+.navbar-brand img {
+ transition: all 0.3s ease;
+ filter: brightness(0) invert(1);
+
+ &:hover {
+ filter: brightness(0) invert(0.55) sepia(1) saturate(2000%) hue-rotate(-8deg) brightness(1.05) contrast(1.2);
+ transform: scale(1.05);
+ }
+}
+
+// =============================================
+// 桌面端样式 - 使用悬停展开下拉菜单
+// =============================================
+@media (min-width: 992px) {
+ /* 导航栏主菜单项样式 */
+ .navbar-nav .nav-item {
+ position: relative;
+ margin: 0 0.2rem;
+
+ .nav-link {
+ position: relative;
+ color: $navbar-fg !important;
+ font-weight: 500;
+ padding: 0.75rem 1rem !important;
+ border-radius: 8px;
+ transition: all 0.3s ease;
+ z-index: 1;
+
+ /* 玻璃效果背景 */
+ &::before {
+ content: '';
+ position: absolute;
+ top: 0;
+ left: 0;
+ right: 0;
+ bottom: 0;
+ background: rgba($white, 0.1);
+ backdrop-filter: blur(10px);
+ border-radius: 8px;
+ opacity: 0;
+ transition: all 0.3s ease;
+ z-index: -1;
+ border: 1px solid rgba($white, 0.2);
+ }
+
+ &:hover {
+ color: $light-orange !important;
+ transform: translateY(-2px);
+
+ &::before {
+ opacity: 1;
+ background: rgba($white, 0.15);
+ backdrop-filter: blur(15px);
+ box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
+ }
+ }
+
+ /* 激活状态 */
+ &.active {
+ color: $light-orange !important;
+ font-weight: 600;
+
+ &::before {
+ opacity: 1;
+ background: rgba($light-orange, 0.2);
+ backdrop-filter: blur(15px);
+ border: 1px solid rgba($light-orange, 0.3);
+ }
+ }
+ }
+ }
+
+ /* 有下拉菜单的主菜单项特殊样式 */
+ .navbar-nav .nav-item.dropdown {
+ .nav-link {
+ padding-right: 2rem !important;
+
+ &::after {
+ position: absolute;
+ right: 1rem;
+ top: 50%;
+ transform: translateY(-50%);
+ transition: all 0.3s ease;
+ }
+ }
+
+ &:hover .nav-link::before {
+ opacity: 1;
+ background: rgba($white, 0.2);
+ backdrop-filter: blur(20px);
+ border-bottom-left-radius: 0;
+ border-bottom-right-radius: 0;
+ }
+
+ &:hover .nav-link::after {
+ transform: translateY(-50%) rotate(-180deg);
+ border-top-color: $light-orange;
+ }
+ }
+
+ /* 桌面端下拉菜单悬停效果 */
+ .navbar-nav .nav-item.dropdown:hover .dropdown-menu {
+ display: block !important;
+ opacity: 1 !important;
+ visibility: visible !important;
+ transform: translateY(0) !important;
+ }
+
+ .dropdown-menu {
+ display: block;
+ opacity: 0;
+ visibility: hidden;
+ transform: translateY(-10px);
+ transition: all 0.3s ease;
+ background: rgba($purple, 0.98) !important;
+ backdrop-filter: blur(20px);
+ border: 1px solid rgba($white, 0.1);
+ border-top: none;
+ border-radius: 0 0 8px 8px;
+ box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
+ margin-top: -1px;
+ padding: 0.5rem 0;
+
+ &.show {
+ display: block;
+ opacity: 1;
+ visibility: visible;
+ transform: translateY(0);
+ }
+ }
+
+ .dropdown-item {
+ color: $white !important;
+ font-family: $navbar-font-family;
+ padding: 0.75rem 1.5rem;
+ transition: all 0.2s ease;
+ position: relative;
+
+ /* 下拉菜单项的玻璃效果 */
+ &::before {
+ content: '';
+ position: absolute;
+ top: 0;
+ left: 0;
+ right: 0;
+ bottom: 0;
+ background: rgba($white, 0.05);
+ border-radius: 4px;
+ opacity: 0;
+ transition: all 0.2s ease;
+ z-index: -1;
+ }
+
+ &:hover, &:focus {
+ color: $light-orange !important;
+ transform: translateX(5px);
+ background: transparent !important;
+
+ &::before {
+ opacity: 1;
+ background: rgba($white, 0.1);
+ }
+ }
+ }
+
+ /* 确保下拉菜单与主菜单视觉上连接 */
+ .navbar-nav .nav-item.dropdown:hover .nav-link {
+ border-bottom-left-radius: 0;
+ border-bottom-right-radius: 0;
+ }
+}
+
+// =============================================
+// 移动端样式 - 使用点击展开下拉菜单
+// =============================================
+@media (max-width: 991.98px) {
+ /* 完全重置移动端导航样式,使用 Bootstrap 默认行为 */
+ .navbar-collapse {
+ background: rgba($purple, 0.98);
+ backdrop-filter: blur(10px);
+ border-top: 1px solid rgba($white, 0.1);
+ margin-top: 0.5rem;
+ padding: 0.5rem 0;
+
+ .navbar-nav {
+ .nav-item {
+ margin: 0;
+
+ .nav-link {
+ color: $navbar-fg !important;
+ padding: 1rem 1.5rem !important;
+ border-radius: 0;
+ transition: all 0.2s ease;
+ display: flex;
+ justify-content: space-between;
+ align-items: center;
+
+ &:hover {
+ color: $light-orange !important;
+ background: rgba($white, 0.1);
+ }
+
+ &.active {
+ color: $light-orange !important;
+ background: rgba($light-orange, 0.1);
+ font-weight: 600;
+ }
+ }
+
+ /* 下拉菜单项样式 */
+ &.dropdown {
+ .dropdown-toggle::after {
+ transition: transform 0.3s ease;
+ }
+
+ &.show {
+ .dropdown-toggle {
+ color: $light-orange !important;
+ background: rgba($white, 0.15);
+
+ &::after {
+ transform: rotate(-180deg);
+ }
+ }
+ }
+
+ .dropdown-menu {
+ background: rgba(darken($purple, 5%), 0.95) !important;
+ border: none;
+ border-radius: 0;
+ padding: 0;
+ margin: 0;
+ position: static;
+ float: none;
+ display: none;
+
+ &.show {
+ display: block !important;
+ }
+ }
+ }
+ }
+ }
+ }
+
+ /* 移动端下拉菜单项 */
+ .dropdown-item {
+ color: $navbar-fg !important;
+ padding: 0.875rem 1.5rem 0.875rem 2.5rem !important;
+ border-radius: 0;
+ transition: all 0.2s ease;
+
+ &:hover, &:focus {
+ color: $light-orange !important;
+ background: rgba($white, 0.1) !important;
+ transform: none;
+ }
+
+ &.active {
+ color: $light-orange !important;
+ background: rgba($light-orange, 0.1) !important;
+ font-weight: 600;
+ }
+ }
+
+ /* 移动端导航栏折叠按钮 */
+ .navbar-toggler {
+ border: 1px solid rgba($white, 0.2);
+ padding: 0.5rem 0.75rem;
+
+ &:focus {
+ box-shadow: 0 0 0 0.2rem rgba($light-orange, 0.25);
+ }
+
+ .navbar-toggler-icon {
+ background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.8%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
+ }
+ }
+
+ /* 禁用桌面端的悬停效果 */
+ .navbar-nav .nav-item .nav-link::before {
+ display: none;
+ }
+
+ .navbar-nav .nav-item.dropdown:hover .dropdown-menu {
+ display: none !important;
+ }
+}
+
+// =============================================
+// 通用样式
+// =============================================
+
+/* 导航栏整体样式 */
+.navbar {
+ backdrop-filter: blur(10px);
+ background: rgba($purple, 0.95) !important;
+ border-bottom: 1px solid rgba($white, 0.1);
+}
+
+/* 为有下拉菜单的导航项添加视觉指示 */
+.navbar-nav .nav-item.dropdown > .nav-link::after {
+ display: inline-block;
+ margin-left: 0.255em;
+ vertical-align: 0.255em;
+ content: "";
+ border-top: 0.3em solid;
+ border-right: 0.3em solid transparent;
+ border-bottom: 0;
+ border-left: 0.3em solid transparent;
+}
+
+/* 确保 Bootstrap 的 JavaScript 交互正常工作 */
+.navbar-nav .dropdown-toggle::after {
+ display: inline-block !important;
+}
+
+/* 修复移动端点击事件 */
+.navbar-nav .nav-item.dropdown .nav-link {
+ cursor: pointer;
+}
diff --git a/_extensions/drwater/dwinst/dweisvogel.tex b/_extensions/drwater/dwinst/dweisvogel.tex
new file mode 100644
index 0000000..50b9664
--- /dev/null
+++ b/_extensions/drwater/dwinst/dweisvogel.tex
@@ -0,0 +1,1323 @@
+%%
+% Copyright (c) 2017 - 2024, Pascal Wagler;
+% Copyright (c) 2014 - 2024, John MacFarlane
+%
+% All rights reserved.
+%
+% Redistribution and use in source and binary forms, with or without
+% modification, are permitted provided that the following conditions
+% are met:
+%
+% - Redistributions of source code must retain the above copyright
+% notice, this list of conditions and the following disclaimer.
+%
+% - Redistributions in binary form must reproduce the above copyright
+% notice, this list of conditions and the following disclaimer in the
+% documentation and/or other materials provided with the distribution.
+%
+% - Neither the name of John MacFarlane nor the names of other
+% contributors may be used to endorse or promote products derived
+% from this software without specific prior written permission.
+%
+% THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+% "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+% LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+% FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+% COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+% INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+% BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+% LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+% CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+% LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
+% ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+% POSSIBILITY OF SUCH DAMAGE.
+%%
+
+%%
+% This is the Eisvogel pandoc LaTeX template.
+%
+% For usage information and examples visit the official GitHub page:
+% https://github.com/Wandmalfarbe/pandoc-latex-template
+%%
+
+% Options for packages loaded elsewhere
+\PassOptionsToPackage{unicode$for(hyperrefoptions)$,$hyperrefoptions$$endfor$}{hyperref}
+\PassOptionsToPackage{hyphens}{url}
+\PassOptionsToPackage{dvipsnames,svgnames,x11names,table}{xcolor}
+$if(CJKmainfont)$
+\PassOptionsToPackage{space}{xeCJK}
+$endif$
+%
+\documentclass[
+$if(fontsize)$
+ $fontsize$,
+$endif$
+$if(papersize)$
+ $papersize$paper,
+$else$
+ paper=a4,
+$endif$
+$if(beamer)$
+ ignorenonframetext,
+$if(handout)$
+ handout,
+$endif$
+$if(aspectratio)$
+ aspectratio=$aspectratio$,
+$endif$
+$if(babel-lang)$
+ $babel-lang$,
+$endif$
+$endif$
+$for(classoption)$
+ $classoption$$sep$,
+$endfor$
+ ,captions=tableheading
+]{$if(beamer)$$documentclass$$else$$if(isbook)$scrbook$else$scrartcl$endif$$endif$}
+$if(beamer)$
+$if(background-image)$
+\usebackgroundtemplate{%
+ \includegraphics[width=\paperwidth]{$background-image$}%
+}
+% In beamer background-image does not work well when other images are used, so this is the workaround
+\pgfdeclareimage[width=\paperwidth,height=\paperheight]{background}{$background-image$}
+\usebackgroundtemplate{\pgfuseimage{background}}
+$endif$
+
+\usepackage{pgfpages}
+\setbeamertemplate{caption}[numbered]
+\setbeamertemplate{caption label separator}{: }
+\setbeamercolor{caption name}{fg=normal text.fg}
+\beamertemplatenavigationsymbols$if(navigation)$$navigation$$else$empty$endif$
+$for(beameroption)$
+\setbeameroption{$beameroption$}
+$endfor$
+% Prevent slide breaks in the middle of a paragraph
+\widowpenalties 1 10000
+\raggedbottom
+$if(section-titles)$
+\setbeamertemplate{part page}{
+ \centering
+ \begin{beamercolorbox}[sep=16pt,center]{part title}
+ \usebeamerfont{part title}\insertpart\par
+ \end{beamercolorbox}
+}
+\setbeamertemplate{section page}{
+ \centering
+ \begin{beamercolorbox}[sep=12pt,center]{section title}
+ \usebeamerfont{section title}\insertsection\par
+ \end{beamercolorbox}
+}
+\setbeamertemplate{subsection page}{
+ \centering
+ \begin{beamercolorbox}[sep=8pt,center]{subsection title}
+ \usebeamerfont{subsection title}\insertsubsection\par
+ \end{beamercolorbox}
+}
+\AtBeginPart{
+ \frame{\partpage}
+}
+\AtBeginSection{
+ \ifbibliography
+ \else
+ \frame{\sectionpage}
+ \fi
+}
+\AtBeginSubsection{
+ \frame{\subsectionpage}
+}
+$endif$
+$endif$
+$if(beamerarticle)$
+\usepackage{beamerarticle} % needs to be loaded first
+$endif$
+\usepackage{amsmath,amssymb}
+$if(linestretch)$
+\usepackage{setspace}
+$else$
+% Use setspace anyway because we change the default line spacing.
+% The spacing is changed early to affect the titlepage and the TOC.
+\usepackage{setspace}
+\setstretch{1.2}
+$endif$
+\usepackage{iftex}
+\ifPDFTeX
+ \usepackage[$if(fontenc)$$fontenc$$else$T1$endif$]{fontenc}
+ \usepackage[utf8]{inputenc}
+ \usepackage{textcomp} % provide euro and other symbols
+\else % if luatex or xetex
+$if(mathspec)$
+ \ifXeTeX
+ \usepackage{mathspec} % this also loads fontspec
+ \else
+ \usepackage{unicode-math} % this also loads fontspec
+ \fi
+$else$
+ \usepackage{unicode-math} % this also loads fontspec
+$endif$
+ \defaultfontfeatures{Scale=MatchLowercase}$-- must come before Beamer theme
+ \defaultfontfeatures[\rmfamily]{Ligatures=TeX,Scale=1}
+\fi
+$if(fontfamily)$
+$else$
+$-- Set default font before Beamer theme so the theme can override it
+\usepackage{lmodern}
+$endif$
+$-- Set Beamer theme before user font settings so they can override theme
+$if(beamer)$
+$if(theme)$
+\usetheme[$for(themeoptions)$$themeoptions$$sep$,$endfor$]{$theme$}
+$endif$
+$if(colortheme)$
+\usecolortheme{$colortheme$}
+$endif$
+$if(fonttheme)$
+\usefonttheme{$fonttheme$}
+$endif$
+$if(mainfont)$
+\usefonttheme{serif} % use mainfont rather than sansfont for slide text
+$endif$
+$if(innertheme)$
+\useinnertheme{$innertheme$}
+$endif$
+$if(outertheme)$
+\useoutertheme{$outertheme$}
+$endif$
+$endif$
+$-- User font settings (must come after default font and Beamer theme)
+$if(fontfamily)$
+\usepackage[$for(fontfamilyoptions)$$fontfamilyoptions$$sep$,$endfor$]{$fontfamily$}
+$endif$
+\ifPDFTeX\else
+ % xetex/luatex font selection
+$if(mainfont)$
+ $if(mainfontfallback)$
+ \ifLuaTeX
+ \usepackage{luaotfload}
+ \directlua{luaotfload.add_fallback("mainfontfallback",{
+ $for(mainfontfallback)$"$mainfontfallback$"$sep$,$endfor$
+ })}
+ \fi
+ $endif$
+ \setmainfont[$for(mainfontoptions)$$mainfontoptions$$sep$,$endfor$$if(mainfontfallback)$,RawFeature={fallback=mainfontfallback}$endif$]{$mainfont$}
+$endif$
+$if(sansfont)$
+ $if(sansfontfallback)$
+ \ifLuaTeX
+ \usepackage{luaotfload}
+ \directlua{luaotfload.add_fallback("sansfontfallback",{
+ $for(sansfontfallback)$"$sansfontfallback$"$sep$,$endfor$
+ })}
+ \fi
+ $endif$
+ \setsansfont[$for(sansfontoptions)$$sansfontoptions$$sep$,$endfor$$if(sansfontfallback)$,RawFeature={fallback=sansfontfallback}$endif$]{$sansfont$}
+$endif$
+$if(monofont)$
+ $if(monofontfallback)$
+ \ifLuaTeX
+ \usepackage{luaotfload}
+ \directlua{luaotfload.add_fallback("monofontfallback",{
+ $for(monofontfallback)$"$monofontfallback$"$sep$,$endfor$
+ })}
+ \fi
+ $endif$
+ \setmonofont[$for(monofontoptions)$$monofontoptions$$sep$,$endfor$$if(monofontfallback)$,RawFeature={fallback=monofontfallback}$endif$]{$monofont$}
+$endif$
+$for(fontfamilies)$
+ \newfontfamily{$fontfamilies.name$}[$for(fontfamilies.options)$$fontfamilies.options$$sep$,$endfor$]{$fontfamilies.font$}
+$endfor$
+$if(mathfont)$
+$if(mathspec)$
+ \ifXeTeX
+ \setmathfont(Digits,Latin,Greek)[$for(mathfontoptions)$$mathfontoptions$$sep$,$endfor$]{$mathfont$}
+ \else
+ \setmathfont[$for(mathfontoptions)$$mathfontoptions$$sep$,$endfor$]{$mathfont$}
+ \fi
+$else$
+ \setmathfont[$for(mathfontoptions)$$mathfontoptions$$sep$,$endfor$]{$mathfont$}
+$endif$
+$endif$
+$if(CJKmainfont)$
+ \ifXeTeX
+ \usepackage{xeCJK}
+ \setCJKmainfont[$for(CJKoptions)$$CJKoptions$$sep$,$endfor$]{$CJKmainfont$}
+ $if(CJKsansfont)$
+ \setCJKsansfont[$for(CJKoptions)$$CJKoptions$$sep$,$endfor$]{$CJKsansfont$}
+ $endif$
+ $if(CJKmonofont)$
+ \setCJKmonofont[$for(CJKoptions)$$CJKoptions$$sep$,$endfor$]{$CJKmonofont$}
+ $endif$
+ \fi
+$endif$
+$if(luatexjapresetoptions)$
+ \ifLuaTeX
+ \usepackage[$for(luatexjapresetoptions)$$luatexjapresetoptions$$sep$,$endfor$]{luatexja-preset}
+ \fi
+$endif$
+$if(CJKmainfont)$
+ \ifLuaTeX
+ \usepackage[$for(luatexjafontspecoptions)$$luatexjafontspecoptions$$sep$,$endfor$]{luatexja-fontspec}
+ \setmainjfont[$for(CJKoptions)$$CJKoptions$$sep$,$endfor$]{$CJKmainfont$}
+ \fi
+$endif$
+\fi
+$if(zero-width-non-joiner)$
+%% Support for zero-width non-joiner characters.
+\makeatletter
+\def\zerowidthnonjoiner{%
+ % Prevent ligatures and adjust kerning, but still support hyphenating.
+ \texorpdfstring{%
+ \TextOrMath{\nobreak\discretionary{-}{}{\kern.03em}%
+ \ifvmode\else\nobreak\hskip\z@skip\fi}{}%
+ }{}%
+}
+\makeatother
+\ifPDFTeX
+ \DeclareUnicodeCharacter{200C}{\zerowidthnonjoiner}
+\else
+ \catcode`^^^^200c=\active
+ \protected\def ^^^^200c{\zerowidthnonjoiner}
+\fi
+%% End of ZWNJ support
+$endif$
+% Use upquote if available, for straight quotes in verbatim environments
+\IfFileExists{upquote.sty}{\usepackage{upquote}}{}
+\IfFileExists{microtype.sty}{% use microtype if available
+ \usepackage[$for(microtypeoptions)$$microtypeoptions$$sep$,$endfor$]{microtype}
+ \UseMicrotypeSet[protrusion]{basicmath} % disable protrusion for tt fonts
+}{}
+$if(indent)$
+$else$
+\makeatletter
+\@ifundefined{KOMAClassName}{% if non-KOMA class
+ \IfFileExists{parskip.sty}{%
+ \usepackage{parskip}
+ }{% else
+ \setlength{\parindent}{0pt}
+ \setlength{\parskip}{6pt plus 2pt minus 1pt}}
+}{% if KOMA class
+ \KOMAoptions{parskip=half}}
+\makeatother
+$endif$
+$if(verbatim-in-note)$
+\usepackage{fancyvrb}
+$endif$
+\usepackage{xcolor}
+\definecolor{default-linkcolor}{HTML}{A50000}
+\definecolor{default-filecolor}{HTML}{A50000}
+\definecolor{default-citecolor}{HTML}{4077C0}
+\definecolor{default-urlcolor}{HTML}{4077C0}
+$if(footnotes-pretty)$
+% load footmisc in order to customize footnotes (footmisc has to be loaded before hyperref, cf. https://tex.stackexchange.com/a/169124/144087)
+\usepackage[hang,flushmargin,bottom,multiple]{footmisc}
+\setlength{\footnotemargin}{0.8em} % set space between footnote nr and text
+\setlength{\footnotesep}{\baselineskip} % set space between multiple footnotes
+\setlength{\skip\footins}{0.3cm} % set space between page content and footnote
+\setlength{\footskip}{0.9cm} % set space between footnote and page bottom
+$endif$
+$if(geometry)$
+$if(beamer)$
+\geometry{$for(geometry)$$geometry$$sep$,$endfor$}
+$else$
+\usepackage[$for(geometry)$$geometry$$sep$,$endfor$]{geometry}
+$endif$
+$else$
+$if(beamer)$
+$else$
+\usepackage[margin=2.5cm,includehead=true,includefoot=true,centering,$for(geometry)$$geometry$$sep$,$endfor$]{geometry}
+$endif$
+$endif$
+$if(titlepage-logo)$
+\usepackage[export]{adjustbox}
+\usepackage{graphicx}
+$endif$
+$if(beamer)$
+\newif\ifbibliography
+$endif$
+$if(listings)$
+\usepackage{listings}
+\newcommand{\passthrough}[1]{#1}
+\lstset{defaultdialect=[5.3]Lua}
+\lstset{defaultdialect=[x86masm]Assembler}
+$endif$
+$if(listings-no-page-break)$
+\usepackage{etoolbox}
+\BeforeBeginEnvironment{lstlisting}{\par\noindent\begin{minipage}{\linewidth}}
+\AfterEndEnvironment{lstlisting}{\end{minipage}\par\addvspace{\topskip}}
+$endif$
+$if(lhs)$
+\lstnewenvironment{code}{\lstset{language=Haskell,basicstyle=\small\ttfamily}}{}
+$endif$
+$if(highlighting-macros)$
+$highlighting-macros$
+
+% Workaround/bugfix from jannick0.
+% See https://github.com/jgm/pandoc/issues/4302#issuecomment-360669013)
+% or https://github.com/Wandmalfarbe/pandoc-latex-template/issues/2
+%
+% Redefine the verbatim environment 'Highlighting' to break long lines (with
+% the help of fvextra). Redefinition is necessary because it is unlikely that
+% pandoc includes fvextra in the default template.
+\usepackage{fvextra}
+\DefineVerbatimEnvironment{Highlighting}{Verbatim}{breaklines,fontsize=$if(code-block-font-size)$$code-block-font-size$$else$\small$endif$,commandchars=\\\{\}}
+
+$endif$
+
+% 为中文添加支持 by Ming Su
+$if(CJK)$
+$if(isbook)$
+\usepackage{ctex} %调用中文字体宏包
+\usepackage{indentfirst} %调用首行缩进宏包
+\usepackage{ctex} % 确保中文字体支持
+\usepackage{zhnumber}
+% 修改 chapter 格式为 "第X章"
+% \renewcommand{\chapterformat}{第~\thechapter~章}
+% \renewcommand{\chapterformat}{第\zhnumber{\thechapter}章}
+\renewcommand{\chaptermarkformat}{第~\zhnumber{\thechapter}~章}
+\renewcommand{\chapterformat}{第\zhnumber{\thechapter}章}
+\renewcommand*{\chapterlinesformat}[3]{%
+ \parbox{\linewidth}{\centering #2~\quad~#3} % 居中 + "·" 分隔
+ % 或改用冒号分隔:
+ % \parbox{\linewidth}{\centering #2:#3}
+}
+\RedeclareSectionCommand[
+ beforeskip=1.5em plus 0.5em minus 0.5em,
+ afterskip=1em plus 0.2em,
+ font=\large\bfseries
+]{section}
+\usepackage{zhnumber} % 确保已加载(或直接用 ctex)
+% 修改目录中的章节编号为中文
+\addtokomafont{chapterentry}{\normalfont} % 可选:调整目录字体
+\renewcommand*{\chapterformat}{第\zhnumber{\thechapter}章} % 正文标题格式
+\renewcommand*{\chaptermarkformat}{第\zhnumber{\thechapter}章\quad} % 页眉标题格式
+% 关键!覆盖目录中的章节编号
+\renewcommand{\addchaptertocentry}[2]{%
+ \addtocentrydefault{chapter}{第\zhnumber{#1}章}{#2}%
+}
+\RedeclareSectionCommand[
+ tocentryindent=0pt,
+ tocentrynumwidth=3.5em % 确保编号区域足够宽
+]{chapter}
+$endif$
+$endif$
+
+$if(tables)$
+\usepackage{longtable,booktabs,array}
+$if(multirow)$
+\usepackage{multirow}
+$endif$
+\usepackage{calc} % for calculating minipage widths
+$if(beamer)$
+\usepackage{caption}
+% Make caption package work with longtable
+\makeatletter
+\def\fnum@table{\tablename~\thetable}
+\makeatother
+$else$
+% Correct order of tables after \paragraph or \subparagraph
+\usepackage{etoolbox}
+\makeatletter
+\patchcmd\longtable{\par}{\if@noskipsec\mbox{}\fi\par}{}{}
+\makeatother
+% Allow footnotes in longtable head/foot
+\IfFileExists{footnotehyper.sty}{\usepackage{footnotehyper}}{\usepackage{footnote}}
+\makesavenoteenv{longtable}
+$endif$
+$endif$
+% add backlinks to footnote references, cf. https://tex.stackexchange.com/questions/302266/make-footnote-clickable-both-ways
+$if(footnotes-disable-backlinks)$
+$else$
+\usepackage{footnotebackref}
+$endif$
+$if(graphics)$
+\usepackage{graphicx}
+\makeatletter
+% \def\maxwidth{\ifdim\Gin@nat@width>\linewidth\linewidth\else\Gin@nat@width\fi}
+% \def\maxheight{\ifdim\Gin@nat@height>\textheight\textheight\else\Gin@nat@height\fi}
+% \makeatother
+% % Scale images if necessary, so that they will not overflow the page
+% % margins by default, and it is still possible to overwrite the defaults
+% % using explicit options in \includegraphics[width, height, ...]{}
+% \setkeys{Gin}{width=\maxwidth,height=\maxheight,keepaspectratio}
+\newsavebox\pandoc@box
+\newcommand*\pandocbounded[1]{% scales image to fit in text height/width
+ \sbox\pandoc@box{#1}%
+ \Gscale@div\@tempa{\textheight}{\dimexpr\ht\pandoc@box+\dp\pandoc@box\relax}%
+ \Gscale@div\@tempb{\linewidth}{\wd\pandoc@box}%
+ \ifdim\@tempb\p@<\@tempa\p@\let\@tempa\@tempb\fi% select the smaller of both
+ \ifdim\@tempa\p@<\p@\scalebox{\@tempa}{\usebox\pandoc@box}%
+ \else\usebox{\pandoc@box}%
+ \fi%
+}
+% Set default figure placement to htbp
+\makeatletter
+\def\fps@figure{htbp}
+\makeatother
+% \makeatletter Old options from template, replaced with quarto defaults above
+% \newsavebox\pandoc@box
+% \newcommand*\pandocbounded[1]{% scales image to fit in text height/width
+% \sbox\pandoc@box{#1}%
+% \Gscale@div\@tempa{\textheight}{\dimexpr\ht\pandoc@box+\dp\pandoc@box\relax}%
+% \Gscale@div\@tempb{\linewidth}{\wd\pandoc@box}%
+% \ifdim\@tempb\p@<\@tempa\p@\let\@tempa\@tempb\fi% select the smaller of both
+% \ifdim\@tempa\p@<\p@\scalebox{\@tempa}{\usebox\pandoc@box}%
+% \else\usebox{\pandoc@box}%
+% \fi%
+% }
+% % Set default figure placement to htbp
+% % Make use of float-package and set default placement for figures to H.
+% % The option H means 'PUT IT HERE' (as opposed to the standard h option which means 'You may put it here if you like').
+% \usepackage{float}
+% \floatplacement{figure}{$if(float-placement-figure)$$float-placement-figure$$else$H$endif$}
+% \makeatother
+$endif$
+$if(svg)$
+\usepackage{svg}
+$endif$
+$if(strikeout)$
+$-- also used for underline
+\ifLuaTeX
+ \usepackage{luacolor}
+ \usepackage[soul]{lua-ul}
+\else
+\usepackage{soul}
+$if(beamer)$
+ \makeatletter
+ \let\HL\hl
+ \renewcommand\hl{% fix for beamer highlighting
+ \let\set@color\beamerorig@set@color
+ \let\reset@color\beamerorig@reset@color
+ \HL}
+ \makeatother
+$endif$
+$if(CJKmainfont)$
+ \ifXeTeX
+ % soul's \st doesn't work for CJK:
+ \usepackage{xeCJKfntef}
+ \renewcommand{\st}[1]{\sout{#1}}
+ \fi
+$endif$
+\fi
+$endif$
+\setlength{\emergencystretch}{3em} % prevent overfull lines
+\providecommand{\tightlist}{%
+ \setlength{\itemsep}{0pt}\setlength{\parskip}{0pt}}
+$if(numbersections)$
+\setcounter{secnumdepth}{$if(secnumdepth)$$secnumdepth$$else$5$endif$}
+$else$
+\setcounter{secnumdepth}{-\maxdimen} % remove section numbering
+$endif$
+$if(subfigure)$
+\usepackage{subcaption}
+$endif$
+$if(beamer)$
+$else$
+$if(block-headings)$
+% Make \paragraph and \subparagraph free-standing
+\makeatletter
+\ifx\paragraph\undefined\else
+ \let\oldparagraph\paragraph
+ \renewcommand{\paragraph}{
+ \@ifstar
+ \xxxParagraphStar
+ \xxxParagraphNoStar
+ }
+ \newcommand{\xxxParagraphStar}[1]{\oldparagraph*{#1}\mbox{}}
+ \newcommand{\xxxParagraphNoStar}[1]{\oldparagraph{#1}\mbox{}}
+\fi
+\ifx\subparagraph\undefined\else
+ \let\oldsubparagraph\subparagraph
+ \renewcommand{\subparagraph}{
+ \@ifstar
+ \xxxSubParagraphStar
+ \xxxSubParagraphNoStar
+ }
+ \newcommand{\xxxSubParagraphStar}[1]{\oldsubparagraph*{#1}\mbox{}}
+ \newcommand{\xxxSubParagraphNoStar}[1]{\oldsubparagraph{#1}\mbox{}}
+\fi
+\makeatother
+$endif$
+$endif$
+$if(pagestyle)$
+\pagestyle{$pagestyle$}
+$endif$
+$if(csl-refs)$
+% definitions for citeproc citations
+\NewDocumentCommand\citeproctext{}{}
+\NewDocumentCommand\citeproc{mm}{%
+ \begingroup\def\citeproctext{#2}\cite{#1}\endgroup}
+\makeatletter
+ % allow citations to break across lines
+ \let\@cite@ofmt\@firstofone
+ % avoid brackets around text for \cite:
+ \def\@biblabel#1{}
+ \def\@cite#1#2{{#1\if@tempswa , #2\fi}}
+\makeatother
+\newlength{\cslhangindent}
+\setlength{\cslhangindent}{1.5em}
+\newlength{\csllabelwidth}
+\setlength{\csllabelwidth}{3em}
+\newenvironment{CSLReferences}[2] % #1 hanging-indent, #2 entry-spacing
+ {\begin{list}{}{%
+ \setlength{\itemindent}{0pt}
+ \setlength{\leftmargin}{0pt}
+ \setlength{\parsep}{0pt}
+ % turn on hanging indent if param 1 is 1
+ \ifodd #1
+ \setlength{\leftmargin}{\cslhangindent}
+ \setlength{\itemindent}{-1\cslhangindent}
+ \fi
+ % set entry spacing
+ \setlength{\itemsep}{#2\baselineskip}}}
+ {\end{list}}
+\usepackage{calc}
+\newcommand{\CSLBlock}[1]{\hfill\break\parbox[t]{\linewidth}{\strut\ignorespaces#1\strut}}
+\newcommand{\CSLLeftMargin}[1]{\parbox[t]{\csllabelwidth}{\strut#1\strut}}
+\newcommand{\CSLRightInline}[1]{\parbox[t]{\linewidth - \csllabelwidth}{\strut#1\strut}}
+\newcommand{\CSLIndent}[1]{\hspace{\cslhangindent}#1}
+$endif$
+$if(lang)$
+\ifLuaTeX
+\usepackage[bidi=basic]{babel}
+\else
+\usepackage[bidi=default]{babel}
+\fi
+$if(babel-lang)$
+\babelprovide[main,import]{$babel-lang$}
+$if(mainfont)$
+\ifPDFTeX
+\else
+\babelfont{rm}[$for(mainfontoptions)$$mainfontoptions$$sep$,$endfor$$if(mainfontfallback)$,RawFeature={fallback=mainfontfallback}$endif$]{$mainfont$}
+\fi
+$endif$
+$endif$
+$for(babel-otherlangs)$
+\babelprovide[import]{$babel-otherlangs$}
+$endfor$
+$for(babelfonts/pairs)$
+\babelfont[$babelfonts.key$]{rm}{$babelfonts.value$}
+$endfor$
+% get rid of language-specific shorthands (see #6817):
+\let\LanguageShortHands\languageshorthands
+\def\languageshorthands#1{}
+$if(selnolig-langs)$
+\ifLuaTeX
+ \usepackage[$for(selnolig-langs)$$it$$sep$,$endfor$]{selnolig} % disable illegal ligatures
+\fi
+$endif$
+$endif$
+$for(header-includes)$
+$header-includes$
+$endfor$
+$if(dir)$
+\ifPDFTeX
+ \TeXXeTstate=1
+ \newcommand{\RL}[1]{\beginR #1\endR}
+ \newcommand{\LR}[1]{\beginL #1\endL}
+ \newenvironment{RTL}{\beginR}{\endR}
+ \newenvironment{LTR}{\beginL}{\endL}
+\fi
+$endif$
+$if(natbib)$
+\usepackage[$natbiboptions$]{natbib}
+\bibliographystyle{$if(biblio-style)$$biblio-style$$else$plainnat$endif$}
+$endif$
+$if(biblatex)$
+\usepackage[$if(biblio-style)$style=$biblio-style$,$endif$$for(biblatexoptions)$$biblatexoptions$$sep$,$endfor$]{biblatex}
+$for(bibliography)$
+\addbibresource{$bibliography$}
+$endfor$
+$endif$
+$if(nocite-ids)$
+\nocite{$for(nocite-ids)$$it$$sep$, $endfor$}
+$endif$
+$if(csquotes)$
+\usepackage{csquotes}
+$endif$
+\usepackage{bookmark}
+\IfFileExists{xurl.sty}{\usepackage{xurl}}{} % add URL line breaks if available
+\urlstyle{$if(urlstyle)$$urlstyle$$else$same$endif$}
+$if(links-as-notes)$
+% Make links footnotes instead of hotlinks:
+\DeclareRobustCommand{\href}[2]{#2\footnote{\url{#1}}}
+$endif$
+$if(verbatim-in-note)$
+\VerbatimFootnotes % allow verbatim text in footnotes
+$endif$
+\hypersetup{
+$if(title-meta)$
+ pdftitle={$title-meta$},
+$endif$
+$if(author-meta)$
+ pdfauthor={$author-meta$},
+$endif$
+$if(lang)$
+ pdflang={$lang$},
+$endif$
+$if(subject)$
+pdfsubject={$subject$},
+$endif$
+$if(keywords)$
+ pdfkeywords={$for(keywords)$$keywords$$sep$, $endfor$},
+$endif$
+$if(colorlinks)$
+ colorlinks=true,
+ linkcolor={$if(linkcolor)$$linkcolor$$else$default-linkcolor$endif$},
+ filecolor={$if(filecolor)$$filecolor$$else$default-filecolor$endif$},
+ citecolor={$if(citecolor)$$citecolor$$else$default-citecolor$endif$},
+ urlcolor={$if(urlcolor)$$urlcolor$$else$default-urlcolor$endif$},
+$else$
+$if(boxlinks)$
+$else$
+ hidelinks,
+$endif$
+$endif$
+ breaklinks=true,
+ pdfcreator={LaTeX via pandoc with the Eisvogel template}}
+$if(title)$
+\title{$title$$if(thanks)$\thanks{$thanks$}$endif$}
+$endif$
+$if(subtitle)$
+$if(beamer)$
+$else$
+\usepackage{etoolbox}
+\makeatletter
+\providecommand{\subtitle}[1]{% add subtitle to \maketitle
+ \apptocmd{\@title}{\par {\large #1 \par}}{}{}
+}
+\makeatother
+$endif$
+\subtitle{$subtitle$}
+$endif$
+\author{$for(author)$$author$$sep$ \and $endfor$}
+\date{$date$}
+$if(beamer)$
+$if(institute)$
+\institute{$for(institute)$$institute$$sep$ \and $endfor$}
+$endif$
+$if(titlegraphic)$
+\titlegraphic{\includegraphics$if(titlegraphicoptions)$[$for(titlegraphicoptions)$$titlegraphicoptions$$sep$, $endfor$]$endif${$titlegraphic$}}
+$endif$
+$if(logo)$
+\logo{\includegraphics{$logo$}}
+$endif$
+$endif$
+
+
+
+%%
+%% added
+%%
+
+$if(page-background)$
+\usepackage[pages=all]{background}
+$endif$
+
+%
+% for the background color of the title page
+%
+$if(titlepage)$
+\usepackage{pagecolor}
+\usepackage{afterpage}
+$if(titlepage-background)$
+\usepackage{tikz}
+$endif$
+$if(geometry)$
+$else$
+\usepackage[margin=2.5cm,includehead=true,includefoot=true,centering]{geometry}
+$endif$
+$endif$
+
+%
+% break urls
+%
+\PassOptionsToPackage{hyphens}{url}
+
+%
+% When using babel or polyglossia with biblatex, loading csquotes is recommended
+% to ensure that quoted texts are typeset according to the rules of your main language.
+%
+\usepackage{csquotes}
+
+%
+% captions
+%
+\definecolor{caption-color}{HTML}{777777}
+$if(beamer)$
+$else$
+\usepackage[font={stretch=1.2}, textfont={color=caption-color}, position=top, skip=4mm, labelfont=bf, singlelinecheck=false, justification=$if(caption-justification)$$caption-justification$$else$raggedright$endif$]{caption}
+\setcapindent{0em}
+$endif$
+
+%
+% blockquote
+%
+\definecolor{blockquote-border}{RGB}{221,221,221}
+\definecolor{blockquote-text}{RGB}{119,119,119}
+\usepackage{mdframed}
+\newmdenv[rightline=false,bottomline=false,topline=false,linewidth=3pt,linecolor=blockquote-border,skipabove=\parskip]{customblockquote}
+\renewenvironment{quote}{\begin{customblockquote}\list{}{\rightmargin=0em\leftmargin=0em}%
+\item\relax\color{blockquote-text}\ignorespaces}{\unskip\unskip\endlist\end{customblockquote}}
+
+%
+% Source Sans Pro as the default font family
+% Source Code Pro for monospace text
+%
+% 'default' option sets the default
+% font family to Source Sans Pro, not \sfdefault.
+%
+\ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex
+ $if(fontfamily)$
+ $else$
+ \usepackage[default]{sourcesanspro}
+ \usepackage{sourcecodepro}
+ $endif$
+\else % if not pdftex
+ $if(mainfont)$
+ $else$
+ \usepackage[default]{sourcesanspro}
+ \usepackage{sourcecodepro}
+
+ % XeLaTeX specific adjustments for straight quotes: https://tex.stackexchange.com/a/354887
+ % This issue is already fixed (see https://github.com/silkeh/latex-sourcecodepro/pull/5) but the
+ % fix is still unreleased.
+ % TODO: Remove this workaround when the new version of sourcecodepro is released on CTAN.
+ \ifxetex
+ \makeatletter
+ \defaultfontfeatures[\ttfamily]
+ { Numbers = \sourcecodepro@figurestyle,
+ Scale = \SourceCodePro@scale,
+ Extension = .otf }
+ \setmonofont
+ [ UprightFont = *-\sourcecodepro@regstyle,
+ ItalicFont = *-\sourcecodepro@regstyle It,
+ BoldFont = *-\sourcecodepro@boldstyle,
+ BoldItalicFont = *-\sourcecodepro@boldstyle It ]
+ {SourceCodePro}
+ \makeatother
+ \fi
+ $endif$
+\fi
+
+
+% setup for chinese font, by Ming
+\setCJKmainfont{$CJKmainfont$}[BoldFont=$CJKboldfont$, ItalicFont=$CJKitalicfont$]
+
+%
+% heading color
+%
+\definecolor{heading-color}{RGB}{40,40,40}
+$if(beamer)$
+$else$
+\addtokomafont{section}{\color{heading-color}}
+$endif$
+% When using the classes report, scrreprt, book,
+% scrbook or memoir, uncomment the following line.
+%\addtokomafont{chapter}{\color{heading-color}}
+
+%
+% variables for title, author and date
+%
+$if(beamer)$
+$else$
+\usepackage{titling}
+\title{$title$}
+\author{$for(author)$$author$$sep$, $endfor$}
+\date{$date$}
+$endif$
+
+%
+% tables
+%
+$if(tables)$
+
+\definecolor{table-row-color}{HTML}{F5F5F5}
+\definecolor{table-rule-color}{HTML}{999999}
+
+%\arrayrulecolor{black!40}
+\arrayrulecolor{table-rule-color} % color of \toprule, \midrule, \bottomrule
+\setlength\heavyrulewidth{0.3ex} % thickness of \toprule, \bottomrule
+\renewcommand{\arraystretch}{1.3} % spacing (padding)
+
+$if(table-use-row-colors)$
+% Unfortunately the colored cells extend beyond the edge of the
+% table because pandoc uses @-expressions (@{}) like so:
+%
+% \begin{longtable}[]{@{}ll@{}}
+% \end{longtable}
+%
+% https://en.wikibooks.org/wiki/LaTeX/Tables#.40-expressions
+\usepackage{etoolbox}
+\AtBeginEnvironment{longtable}{\rowcolors{2}{}{table-row-color!100}}
+\preto{\toprule}{\hiderowcolors}{}{}
+\appto{\endhead}{\showrowcolors}{}{}
+\appto{\endfirsthead}{\showrowcolors}{}{}
+$endif$
+$endif$
+
+%
+% remove paragraph indentation
+%
+% \setlength{\parindent}{0pt}
+$if(parindent)$
+\setlength{\parindent}{2em} %设置首行缩进为2字符
+$else$
+\setlength{\parindent}{0pt}
+$endif$
+\setlength{\parskip}{6pt plus 2pt minus 1pt}
+\setlength{\emergencystretch}{3em} % prevent overfull lines
+
+
+
+%
+%
+% Listings
+%
+%
+
+$if(listings)$
+
+%
+% general listing colors
+%
+\definecolor{listing-background}{HTML}{F7F7F7}
+\definecolor{listing-rule}{HTML}{B3B2B3}
+\definecolor{listing-numbers}{HTML}{B3B2B3}
+\definecolor{listing-text-color}{HTML}{000000}
+\definecolor{listing-keyword}{HTML}{435489}
+\definecolor{listing-keyword-2}{HTML}{1284CA} % additional keywords
+\definecolor{listing-keyword-3}{HTML}{9137CB} % additional keywords
+\definecolor{listing-identifier}{HTML}{435489}
+\definecolor{listing-string}{HTML}{00999A}
+\definecolor{listing-comment}{HTML}{8E8E8E}
+
+\lstdefinestyle{eisvogel_listing_style}{
+ language = java,
+$if(listings-disable-line-numbers)$
+ xleftmargin = 0.6em,
+ framexleftmargin = 0.4em,
+$else$
+ numbers = left,
+ xleftmargin = 2.7em,
+ framexleftmargin = 2.5em,
+$endif$
+ backgroundcolor = \color{listing-background},
+ basicstyle = \color{listing-text-color}\linespread{1.0}%
+ \lst@ifdisplaystyle%
+ $if(code-block-font-size)$$code-block-font-size$$else$\small$endif$%
+ \fi\ttfamily{},
+ breaklines = true,
+ frame = single,
+ framesep = 0.19em,
+ rulecolor = \color{listing-rule},
+ frameround = ffff,
+ tabsize = 4,
+ numberstyle = \color{listing-numbers},
+ aboveskip = 1.0em,
+ belowskip = 0.1em,
+ abovecaptionskip = 0em,
+ belowcaptionskip = 1.0em,
+ keywordstyle = {\color{listing-keyword}\bfseries},
+ keywordstyle = {[2]\color{listing-keyword-2}\bfseries},
+ keywordstyle = {[3]\color{listing-keyword-3}\bfseries\itshape},
+ sensitive = true,
+ identifierstyle = \color{listing-identifier},
+ commentstyle = \color{listing-comment},
+ stringstyle = \color{listing-string},
+ showstringspaces = false,
+ escapeinside = {/*@}{@*/}, % Allow LaTeX inside these special comments
+ literate =
+ {á}{{\'a}}1 {é}{{\'e}}1 {í}{{\'i}}1 {ó}{{\'o}}1 {ú}{{\'u}}1
+ {Á}{{\'A}}1 {É}{{\'E}}1 {Í}{{\'I}}1 {Ó}{{\'O}}1 {Ú}{{\'U}}1
+ {à}{{\`a}}1 {è}{{\`e}}1 {ì}{{\`i}}1 {ò}{{\`o}}1 {ù}{{\`u}}1
+ {À}{{\`A}}1 {È}{{\`E}}1 {Ì}{{\`I}}1 {Ò}{{\`O}}1 {Ù}{{\`U}}1
+ {ä}{{\"a}}1 {ë}{{\"e}}1 {ï}{{\"i}}1 {ö}{{\"o}}1 {ü}{{\"u}}1
+ {Ä}{{\"A}}1 {Ë}{{\"E}}1 {Ï}{{\"I}}1 {Ö}{{\"O}}1 {Ü}{{\"U}}1
+ {â}{{\^a}}1 {ê}{{\^e}}1 {î}{{\^i}}1 {ô}{{\^o}}1 {û}{{\^u}}1
+ {Â}{{\^A}}1 {Ê}{{\^E}}1 {Î}{{\^I}}1 {Ô}{{\^O}}1 {Û}{{\^U}}1
+ {œ}{{\oe}}1 {Œ}{{\OE}}1 {æ}{{\ae}}1 {Æ}{{\AE}}1 {ß}{{\ss}}1
+ {ç}{{\c c}}1 {Ç}{{\c C}}1 {ø}{{\o}}1 {å}{{\r a}}1 {Å}{{\r A}}1
+ {€}{{\EUR}}1 {£}{{\pounds}}1 {«}{{\guillemotleft}}1
+ {»}{{\guillemotright}}1 {ñ}{{\~n}}1 {Ñ}{{\~N}}1 {¿}{{?`}}1
+ {…}{{\ldots}}1 {≥}{{>=}}1 {≤}{{<=}}1 {„}{{\glqq}}1 {“}{{\grqq}}1
+ {”}{{''}}1
+}
+\lstset{style=eisvogel_listing_style}
+
+%
+% Java (Java SE 12, 2019-06-22)
+%
+\lstdefinelanguage{Java}{
+ morekeywords={
+ % normal keywords (without data types)
+ abstract,assert,break,case,catch,class,continue,default,
+ do,else,enum,exports,extends,final,finally,for,if,implements,
+ import,instanceof,interface,module,native,new,package,private,
+ protected,public,requires,return,static,strictfp,super,switch,
+ synchronized,this,throw,throws,transient,try,volatile,while,
+ % var is an identifier
+ var
+ },
+ morekeywords={[2] % data types
+ % primitive data types
+ boolean,byte,char,double,float,int,long,short,
+ % String
+ String,
+ % primitive wrapper types
+ Boolean,Byte,Character,Double,Float,Integer,Long,Short
+ % number types
+ Number,AtomicInteger,AtomicLong,BigDecimal,BigInteger,DoubleAccumulator,DoubleAdder,LongAccumulator,LongAdder,Short,
+ % other
+ Object,Void,void
+ },
+ morekeywords={[3] % literals
+ % reserved words for literal values
+ null,true,false,
+ },
+ sensitive,
+ morecomment = [l]//,
+ morecomment = [s]{/*}{*/},
+ morecomment = [s]{/**}{*/},
+ morestring = [b]",
+ morestring = [b]',
+}
+
+\lstdefinelanguage{XML}{
+ morestring = [b]",
+ moredelim = [s][\bfseries\color{listing-keyword}]{<}{\ },
+ moredelim = [s][\bfseries\color{listing-keyword}]{}{>},
+ moredelim = [l][\bfseries\color{listing-keyword}]{/>},
+ moredelim = [l][\bfseries\color{listing-keyword}]{>},
+ morecomment = [s]{}{?>},
+ morecomment = [s]{},
+ commentstyle = \color{listing-comment},
+ stringstyle = \color{listing-string},
+ identifierstyle = \color{listing-identifier}
+}
+$endif$
+
+%
+% header and footer
+%
+$if(beamer)$
+$else$
+$if(disable-header-and-footer)$
+$else$
+\usepackage[headsepline,footsepline]{scrlayer-scrpage}
+
+\newpairofpagestyles{eisvogel-header-footer}{
+ \clearpairofpagestyles
+ \ihead*{$if(header-left)$$header-left$$else$$title$$endif$}
+ \chead*{$if(header-center)$$header-center$$else$$endif$}
+ \ohead*{$if(header-right)$$header-right$$else$$date$$endif$}
+ \ifoot*{$if(footer-left)$$footer-left$$else$$for(author)$$author$$sep$, $endfor$$endif$}
+ \cfoot*{$if(footer-center)$$footer-center$$else$$endif$}
+ \ofoot*{$if(footer-right)$$footer-right$$else$\thepage$endif$}
+ \addtokomafont{pageheadfoot}{\upshape}
+}
+\pagestyle{eisvogel-header-footer}
+
+\newpairofpagestyles{eisvogel-chapterpage-header-footer}{
+ \clearpairofpagestyles
+ \setheadtopline{0pt} % 移除页眉顶部的横线(如果有)
+ \setheadsepline{0pt}
+ \ifoot*{$if(footer-left)$$footer-left$$else$$for(author)$$author$$sep$, $endfor$$endif$}
+ \cfoot*{$if(footer-center)$$footer-center$$else$$endif$}
+ \ofoot*{$if(footer-right)$$footer-right$$else$\thepage$endif$}
+ \addtokomafont{pageheadfoot}{\upshape}
+}
+
+
+$if(isbook)$
+% \deftripstyle{ChapterStyle}{}{}{}{}{\pagemark}{}
+% \renewcommand*{\chapterpagestyle}{ChapterStyle}
+\renewcommand*{\chapterpagestyle}{eisvogel-chapterpage-header-footer}
+$endif$
+
+
+$if(page-background)$
+\backgroundsetup{
+scale=1,
+color=black,
+opacity=$if(page-background-opacity)$$page-background-opacity$$else$0.2$endif$,
+angle=0,
+contents={%
+ \includegraphics[width=\paperwidth,height=\paperheight]{$page-background$}
+ }%
+}
+$endif$
+$endif$
+$endif$
+
+% watermark
+$if(watermark)$
+\usepackage{draftwatermark,xcolor}
+\SetWatermarkText{\textcolor{$if(watermark-color)$$watermark-color$$else$gray!3$endif$}{$watermark$}}
+\SetWatermarkScale{1.2} % 缩小水印尺寸(数值越小越密集)
+\SetWatermarkAngle{45} % 斜角排列(经典水印样式)
+\SetWatermarkLightness{0.99} % 亮度调节
+$endif$
+
+%%
+%% end added
+%%
+
+\begin{document}
+
+%%
+%% begin titlepage
+%%
+$if(beamer)$
+$else$
+$if(titlepage)$
+\begin{titlepage}
+$if(titlepage-background)$
+\newgeometry{top=2cm, right=4cm, bottom=3cm, left=4cm}
+$else$
+\newgeometry{left=2cm}
+$endif$
+$if(titlepage-color)$
+\definecolor{titlepage-color}{HTML}{$titlepage-color$}
+\newpagecolor{titlepage-color}\afterpage{\restorepagecolor}
+$endif$
+$if(titlepage-background)$
+\tikz[remember picture,overlay] \node[inner sep=0pt] at (current page.center){\includegraphics[width=\paperwidth,height=\paperheight]{$titlepage-background$}};
+$endif$
+\newcommand{\colorRule}[3][black]{\textcolor[HTML]{#1}{\rule{#2}{#3}}}
+
+\NewDocumentEnvironment{dynalign}{}
+ {\begin{$if(titlepage-halign)$$titlepage-halign$$else$center$endif$}}
+ {\end{$if(titlepage-halign)$$titlepage-halign$$else$center$endif$}}
+
+\begin{dynalign}
+\noindent
+\\[-1em]
+\color[HTML]{$if(titlepage-text-color)$$titlepage-text-color$$else$5F5F5F$endif$}
+\makebox[0pt][l]{\colorRule[$if(titlepage-rule-color)$$titlepage-rule-color$$else$435488$endif$]{1.3\textwidth}{$if(titlepage-rule-height)$$titlepage-rule-height$$else$4$endif$pt}}
+\par
+\noindent
+
+$if(titlepage-logo)$
+\noindent
+\vskip $if(logo-vskip)$$logo-vskip$$else$-8em$endif$
+\hskip $if(logo-hskip)$$logo-hskip$$else$-6em$endif$
+\includegraphics[width=$if(logo-width)$$logo-width$$else$35mm$endif$, left]{$titlepage-logo$}
+$endif$
+
+$if(titlepage-background)$
+% The titlepage with a background image has other text spacing and text size
+{
+ \setstretch{2}
+ \vfill
+ \vskip -8em
+ $if(title-vskip)$
+ \vskip $title-vskip$
+ $endif$
+ $if(title-hskip)$
+ \vskip $title-hskip$
+ $endif$
+ \noindent {
+ $if(title-size)$
+ \$title-size$
+ $else$
+ \huge
+ $endif$
+\textbf{\textsf{$title$}}}
+ $if(subtitle)$
+ \vskip 1em
+ {
+ $if(subtitle-size)$
+ \$subtitle-size$
+ $else$
+ \Large
+ $endif$
+ \textsf{$subtitle$}}
+ $endif$
+ \vskip 2em
+ $if(author-vskip)$
+ \vskip $author-vskip$
+ $endif$
+ \noindent {
+ $if(author-size)$
+ $author-size$
+ $else$
+ \Large
+ $endif$
+
+\textsf{$for(author)$$author$$sep$, $endfor$}
+\vskip 0.6em
+ $if(date-vskip)$
+ \vskip $date-vskip$
+ $endif$
+{\textsf{$if(institute)$$institute$\vskip 0.6em$endif$$date$}}
+}
+ \vfill
+}
+$else$
+{
+ \setstretch{1.4}
+ \vfill
+ \vskip 8em
+ $if(title-vskip)$
+ \vskip $title-vskip$
+ $endif$
+ $if(title-hskip)$
+ \vskip $title-hskip$
+ $endif$
+ \noindent {\huge \textbf{\textsf{$title$}}}
+ $if(subtitle)$
+ \vskip 1em
+ {\Large \textsf{$subtitle$}}
+ $endif$
+ \vskip 4em
+ $if(author-vskip)$
+ \vskip $author-vskip$
+ $endif$
+ \noindent {
+ $if(author-size)$
+ $author-size$
+ $else$
+ \Large
+ $endif$
+
+\textsf{$for(author)$$author$$sep$, $endfor$}
+\vskip 0.6em
+ $if(date-vskip)$
+ \vskip $date-vskip$
+ $endif$
+}
+ \vfill
+}
+$endif$
+
+
+$if(titlepage-background)$
+$else$
+
+ $if(author-size)$
+ $author-size$
+ $else$
+ \Large
+ $endif$
+{\textsf{$if(institute)$$institute$\vskip 0.6em$endif$$date$}}
+$endif$
+\end{dynalign}
+\end{titlepage}
+\restoregeometry
+\pagenumbering{arabic}
+$endif$
+$endif$
+
+
+
+%%
+%% end titlepage
+%%
+
+$if(has-frontmatter)$
+\frontmatter
+$endif$
+$if(title)$
+$if(beamer)$
+\frame{\titlepage}
+% don't generate the default title
+% $else$
+% \maketitle
+$endif$
+$if(abstract)$
+\begin{abstract}
+$abstract$
+\end{abstract}
+$endif$
+$endif$
+
+$if(first-chapter)$
+\setcounter{chapter}{$first-chapter$}
+\addtocounter{chapter}{-1}
+$endif$
+
+$for(include-before)$
+$include-before$
+
+$endfor$
+$if(toc)$
+$if(toc-title)$
+\renewcommand*\contentsname{$toc-title$}
+$endif$
+$if(beamer)$
+\begin{frame}[allowframebreaks]
+$if(toc-title)$
+ \frametitle{$toc-title$}
+$endif$
+ \setcounter{tocdepth}{$toc-depth$}
+ \tableofcontents
+\end{frame}
+$if(toc-own-page)$
+\newpage
+$endif$
+$else$
+{
+$if(colorlinks)$
+\hypersetup{linkcolor=$if(toccolor)$$toccolor$$else$$endif$}
+$endif$
+\setcounter{tocdepth}{$toc-depth$}
+\tableofcontents
+$if(toc-own-page)$
+\newpage
+$endif$
+}
+$endif$
+$endif$
+$if(lof)$
+\listoffigures
+$endif$
+$if(lot)$
+\listoftables
+$endif$
+$if(linestretch)$
+\setstretch{$linestretch$}
+$endif$
+$if(has-frontmatter)$
+\mainmatter
+$endif$
+$body$
+
+$if(has-frontmatter)$
+\backmatter
+$endif$
+$if(natbib)$
+$if(bibliography)$
+$if(biblio-title)$
+$if(has-chapters)$
+\renewcommand\bibname{$biblio-title$}
+$else$
+\renewcommand\refname{$biblio-title$}
+$endif$
+$endif$
+$if(beamer)$
+\begin{frame}[allowframebreaks]{$biblio-title$}
+ \bibliographytrue
+$endif$
+ \bibliography{$for(bibliography)$$bibliography$$sep$,$endfor$}
+$if(beamer)$
+\end{frame}
+$endif$
+
+$endif$
+$endif$
+$if(biblatex)$
+$if(beamer)$
+\begin{frame}[allowframebreaks]{$biblio-title$}
+ \bibliographytrue
+ \printbibliography[heading=none]
+\end{frame}
+$else$
+\printbibliography$if(biblio-title)$[title=$biblio-title$]$endif$
+$endif$
+
+$endif$
+$for(include-after)$
+$include-after$
+
+$endfor$
+\end{document}
diff --git a/_extensions/drwater/dwinst/elsevier-harvard.csl b/_extensions/drwater/dwinst/elsevier-harvard.csl
new file mode 100755
index 0000000..5d88c51
--- /dev/null
+++ b/_extensions/drwater/dwinst/elsevier-harvard.csl
@@ -0,0 +1,239 @@
+
+
diff --git a/_extensions/drwater/dwinst/global-change-biology.csl b/_extensions/drwater/dwinst/global-change-biology.csl
new file mode 100644
index 0000000..5b5b69b
--- /dev/null
+++ b/_extensions/drwater/dwinst/global-change-biology.csl
@@ -0,0 +1,16 @@
+
+
diff --git a/_extensions/drwater/dwinst/journal-of-hazardous-materials.csl b/_extensions/drwater/dwinst/journal-of-hazardous-materials.csl
new file mode 100644
index 0000000..0f98259
--- /dev/null
+++ b/_extensions/drwater/dwinst/journal-of-hazardous-materials.csl
@@ -0,0 +1,165 @@
+
+
diff --git a/_extensions/drwater/dwinst/nature-biotechnology.csl b/_extensions/drwater/dwinst/nature-biotechnology.csl
new file mode 100644
index 0000000..216c8b9
--- /dev/null
+++ b/_extensions/drwater/dwinst/nature-biotechnology.csl
@@ -0,0 +1,17 @@
+
+
diff --git a/_extensions/drwater/dwinst/nature.csl b/_extensions/drwater/dwinst/nature.csl
new file mode 100644
index 0000000..7b058ba
--- /dev/null
+++ b/_extensions/drwater/dwinst/nature.csl
@@ -0,0 +1,154 @@
+
+
diff --git a/_extensions/drwater/dwinst/pnas.csl b/_extensions/drwater/dwinst/pnas.csl
new file mode 100644
index 0000000..1911e9e
--- /dev/null
+++ b/_extensions/drwater/dwinst/pnas.csl
@@ -0,0 +1,229 @@
+
+
diff --git a/_extensions/drwater/dwinst/rceeslogo.pdf b/_extensions/drwater/dwinst/rceeslogo.pdf
new file mode 100644
index 0000000..51d1a45
Binary files /dev/null and b/_extensions/drwater/dwinst/rceeslogo.pdf differ
diff --git a/_extensions/drwater/dwinst/rceeslogo.svg b/_extensions/drwater/dwinst/rceeslogo.svg
new file mode 100644
index 0000000..44431ff
--- /dev/null
+++ b/_extensions/drwater/dwinst/rceeslogo.svg
@@ -0,0 +1,5 @@
+
+
diff --git a/_extensions/drwater/dwinst/rceeslonglogo.pdf b/_extensions/drwater/dwinst/rceeslonglogo.pdf
new file mode 100644
index 0000000..50017f7
Binary files /dev/null and b/_extensions/drwater/dwinst/rceeslonglogo.pdf differ
diff --git a/_extensions/drwater/dwinst/rceeslonglogo.svg b/_extensions/drwater/dwinst/rceeslonglogo.svg
new file mode 100644
index 0000000..013b69d
--- /dev/null
+++ b/_extensions/drwater/dwinst/rceeslonglogo.svg
@@ -0,0 +1,352 @@
+
+
diff --git a/_extensions/drwater/dwinst/slides.scss b/_extensions/drwater/dwinst/slides.scss
new file mode 100644
index 0000000..17a8585
--- /dev/null
+++ b/_extensions/drwater/dwinst/slides.scss
@@ -0,0 +1,33 @@
+/*-- scss:defaults --*/
+
+/*-- scss:rules --*/
+
+:root {
+ --r-background-color: #fff;
+ --r-main-font: Source Sans Pro, simhei, microsoft yahei;
+ --r-main-font-size: 32px; // 正文字体大小
+ --r-main-color: #434343; // 正文颜色,松烟墨:#434343 乌墨:#1A1A1A;#006D6D
+ --r-block-margin: 12px;
+ --r-heading-margin: 0 0 12px 0;
+ --r-heading-font: Source Sans Pro, simhei, microsoft yahei;
+ --r-heading-color: #0c4c8a; //标题颜色:深青蓝色:296364;海军蓝或藏青色:0c4c8a;深青色:006D6D;钻蓝色:0F52BA;酒红:800020
+ --r-heading-line-height: 1.2em;
+ --r-heading-letter-spacing: normal;
+ --r-heading-text-transform: none;
+ --r-heading-text-shadow: none;
+ --r-heading-font-weight: 900;
+ --r-heading1-text-shadow: none;
+ --r-heading1-size: 2.5em;
+ --r-heading2-size: 1.6em;
+ --r-heading3-size: 1.3em;
+ --r-heading4-size: 1em;
+ --r-code-font: SFMono-Regular, Menlo, Monaco, Consolas, Liberation Mono,
+ Courier New, monospace;
+ --r-link-color: #ef562d;
+ --r-link-color-dark: #ef562d;
+ --r-link-color-hover: #d13076;
+ --r-selection-background-color: #98bdef;
+ --r-selection-color: #fff;
+ --quarto-hl-fu-color: #c53800;
+}
+
diff --git a/_extensions/drwater/dwinst/the-isme-j.csl b/_extensions/drwater/dwinst/the-isme-j.csl
new file mode 100755
index 0000000..730aefc
--- /dev/null
+++ b/_extensions/drwater/dwinst/the-isme-j.csl
@@ -0,0 +1,181 @@
+
+
diff --git a/_extensions/drwater/dwinst/water-research.csl b/_extensions/drwater/dwinst/water-research.csl
new file mode 100644
index 0000000..69e34f5
--- /dev/null
+++ b/_extensions/drwater/dwinst/water-research.csl
@@ -0,0 +1,14 @@
+
+
diff --git a/_extensions/drwater/dwms/.gitignore b/_extensions/drwater/dwms/.gitignore
new file mode 100644
index 0000000..dc719c9
--- /dev/null
+++ b/_extensions/drwater/dwms/.gitignore
@@ -0,0 +1,16 @@
+.Rproj.user
+.Rhistory
+.RData
+.Ruserdata
+site_libs/
+/.quarto/
+site_libs/
+BB/Ref.bib
+_variables.yml
+_freeze/
+www/
+.source_state
+*_files/
+/*.pdf
+/*.html
+
diff --git a/_extensions/drwater/dwms/MS.qmd b/_extensions/drwater/dwms/MS.qmd
new file mode 100644
index 0000000..34b821d
--- /dev/null
+++ b/_extensions/drwater/dwms/MS.qmd
@@ -0,0 +1,56 @@
+---
+msname: MS
+smname: SM
+isMS: true
+date: ""
+# bibliography: [../BB/Ref.bib, ../BB/localRef.bib]
+# csl: _extensions/drwater/dwms/inst/nature.csl
+endfloat: true
+doublespacing: true
+linenumbers: true
+latex-clean: false # to keep aux
+format:
+ dwms-html: default
+ dwms-docx: default
+ dwms-pdf: default
+# filters:
+# - latex-environment
+# - authoraffil
+# lightbox: auto
+# commands: [clab]
+---
+
+
+```{r}
+#| include: false
+#| cache: false
+
+lang <- "en"
+isRendering <- isTRUE(getOption("knitr.in.progress"))
+require(tidyverse)
+require(drwateR)
+require(patchwork)
+rmdify::rmd_init()
+dwfun::init()
+```
+
+
+{{< pagebreak >}}
+
+# Abstract {-}
+
+This is a demo of abstract.
+
+
+{{< pagebreak >}}
+
+
+
+# References {-}
+
+::: {#refs}
+:::
+
+{{< pagebreak >}}
+
+
diff --git a/_extensions/drwater/dwms/RN.qmd b/_extensions/drwater/dwms/RN.qmd
new file mode 100644
index 0000000..3d6b890
--- /dev/null
+++ b/_extensions/drwater/dwms/RN.qmd
@@ -0,0 +1,62 @@
+---
+subtitle: "Revision Note"
+msname: MS
+smname: SM
+isRN: true
+date: ""
+# bibliography: [../BB/Ref.bib, ../BB/localRef.bib]
+# csl: _extensions/drwater/dwinst/nature.csl
+doublespacing: true
+format:
+ dwms-html: default
+ dwms-docx: default
+ dwms-pdf:
+ number-sections: true
+# filters:
+# - latex-environment
+# - authoraffil
+# lightbox: auto
+# commands: [clab]
+---
+
+```{r}
+#| include: false
+#| cache: false
+lang <- "en"
+RM <- "F" # global rendermode, L: load pdata; F: fast load pdf
+isrendering <- isTRUE(getOption('knitr.in.progress'))
+require(tidyverse)
+require(patchwork)
+require(drwateR)
+rmdify::rmd_init()
+```
+
+# Response to Editor
+
+> 0. I very much regret to have to tell you that publication in our journal is not recommended. An explanation for this decision is given in the attached review reports (and on https://www.editorialmanager.com/wr/). I hope that the comments contained therein will be of use to you.
+
+**Response/Action:**
+
+Thank you.
+
+::: {#rfg-figr1}
+
+```{r}
+plot(1)
+```
+
+A figure in RN
+:::
+
+
+
+# Reviewer #1:
+
+> 0. COMMENT 1
+
+**Response/Action:**
+
+Thank you very much for your revision. We made changes as shown below.
+
+`r cref("r1q0101")`
+
diff --git a/_extensions/drwater/dwms/SM.qmd b/_extensions/drwater/dwms/SM.qmd
new file mode 100644
index 0000000..735145b
--- /dev/null
+++ b/_extensions/drwater/dwms/SM.qmd
@@ -0,0 +1,65 @@
+---
+msname: MS
+smname: SM
+isSM: true
+# bibliography: [../BB/Ref.bib, ../BB/localRef.bib]
+# csl: _extensions/drwater/dwinst/nature.csl
+subtitle: "Supplementary Information"
+date: ""
+latex-clean: false # to keep aux
+format:
+ dwms-html: default
+ dwms-docx: default
+ dwms-pdf:
+ toc: false # 手动设置了
+# filters:
+# - latex-environment
+# - authoraffil
+# lightbox: auto
+# commands: [clab]
+---
+
+\thispagestyle{empty}
+
+```{r}
+#| include: false
+#| cache: false
+options(tinytex.clean = FALSE)
+lang <- "en"
+RM <- "F" # global rendermode, L: load pdata; F: fast load pdf
+isRendering <- isTRUE(getOption('knitr.in.progress'))
+require(tidyverse)
+require(patchwork)
+require(drwateR)
+rmdify::rmd_init()
+```
+
+
+Figures and/or tables are provided below as the supplementary evidences to the main text.
+
+
+```{=latex}
+\clearpage
+{
+\hypersetup{linkcolor=black}
+\setcounter{tocdepth}{3}
+\tableofcontents
+}
+```
+
+
+# [@sfg-demo]
+
+::: {#sfg-demo}
+
+```{r}
+#| out-width: "40%"
+data.frame(x = 1:10, y = 1:10) |>
+ ggplot(aes(x, y)) +
+ geom_point() +
+ dwfun::theme_sci(3, 2.0)
+```
+
+Caption of demo figure
+:::
+
diff --git a/_extensions/drwater/dwms/_extension.yml b/_extensions/drwater/dwms/_extension.yml
new file mode 100644
index 0000000..6acfb0d
--- /dev/null
+++ b/_extensions/drwater/dwms/_extension.yml
@@ -0,0 +1,54 @@
+title: dwms-pdf-quarto
+author: Ming Su
+version: 0.0.1
+quarto-required: ">=1.3.0"
+contributes:
+ formats:
+ common:
+ knitr:
+ opts_chunk:
+ echo: false
+ message: false
+ warning: false
+ docx:
+ reference-doc: _extensions/drwater/dwms/inst/MS.docx
+ html:
+ toc: true
+ css: _extensions/drwater/dwms/inst/drwater.css
+ theme:
+ - _extensions/drwater/dwms/inst/drwater.scss
+ author-location: bottom
+ author-links: [email, orcid, website]
+ include-after-body:
+ text: |
+
+ pdf:
+ pdf-engine: xelatex
+ documentclass: article
+ toc: false
+ papersize: letter
+ fontsize: 12pt
+ geometry: margin=1in
+ fig-height: 4 # smaller fig heights make floating easier
+ fig-width: 7.5 # set to the (full width - margins) of letter
+ fig-pos: "!t"
+ colorlinks: true
+ urlcolor: blue
+ sansfont: "Gill Sans"
+ sansfontoptions:
+ - Color=39729E
+ mainfont: "Source Sans 3" #| Verdana (fontsize: 11pt) # Source Sans 3 | Times New Roman| Helvetica | PT Sans
+ monofont: "JetBrains Mono"
+ mathfont: "Cambria Math"
+ CJKmainfont: SimHei
+ block-headings: false # to deal with titlesec problems
+ include-in-header: header.tex
+ template-partials:
+ - "partials/title.tex"
+ - "partials/before-body.tex"
+ - "partials/after-body.tex"
+filters:
+ - latex-environment
+ - authoraffil.lua
+lightbox: auto
+commands: [clab]
diff --git a/_extensions/drwater/dwms/_quarto.yml b/_extensions/drwater/dwms/_quarto.yml
new file mode 100644
index 0000000..29b5bb9
--- /dev/null
+++ b/_extensions/drwater/dwms/_quarto.yml
@@ -0,0 +1,121 @@
+title: "MANUSCRIPT TITLE"
+submitjournal: "JOURNAL"
+submitid:
+lang: en
+date: last-modified
+# bibliography: [BB/Ref.bib, BB/localRef.bib]
+affilstyle: alphabeta # number
+author:
+ - name: Xxxxx Yyyy
+ affiliations:
+ - ref: kleac
+ # email: 13586740928@163.com
+ attributes:
+ corresponding: false
+ equal-contributor: true
+ role:
+ - data-curation: lead
+ - methodology: lead
+ - formalanalysis: lead
+ - writingoriginal: equal
+ - writingediting: eqaul
+ - visualisation: supporting
+ - name: Ming Su
+ email: mingsu@rcees.ac.cn
+ orcid: 0000-0001-9821-1268
+ url: https://drwater.net/team/ming-su/
+ role:
+ - conceptualization: lead
+ - methodology: supporting
+ - formalanalysis: lead
+ - writingoriginal: equal
+ - writingediting: equal
+ - visualisation: lead
+ - projectadmin: lead
+ - supervision
+ affiliations:
+ - ref: kleac
+ - ref: ucas
+ attributes:
+ corresponding: true
+ equal-contributor: true
+ - name: Min Yang
+ email: yangmin@rcees.ac.cn
+ affiliations:
+ - ref: kleac
+ - ref: ucas
+ attributes:
+ corresponding: true
+affiliations:
+ - id: kleac
+ name: Key Laboratory of Environmental Aguatic Chemistry, State Key Laboratory of Regional Environment and Sustainability, Research Center for Eco-Environmental Sciences, Chinese Academy of Sciences
+ # address: No. 18 Shuangqing Road
+ city: Beijing
+ postal-code: 100085
+ country: China
+ url: https://www.skleac.ac.cn
+ - id: ucas
+ name: University of Chinese Academy of Sciences
+ # address: No. 19A Yuquan Road
+ city: Beijing
+ postal-code: 100049
+ country: China
+ url: https://www.ucas.ac.cn
+crossref:
+ fig-title: Fig. # (default is "Figure")
+ tbl-title: Table # (default is "Table")
+ eq-title: Eq. # (default is "Equation")
+ title-delim: ":" # (default is ":")
+ fig-prefix: Fig. # (default is "Figure")
+ tbl-prefix: Table # (default is "Table")
+ eq-prefix: Eq.
+ ref-hyperlink: true # (default is true)
+ custom:
+ - kind: float
+ key: sfg
+ reference-prefix: "Supplementary Fig."
+ space-before-numbering: true
+ caption-prefix: "Supplementary Fig."
+ latex-env: sfg
+ latex-list-of-file-extension: lost
+ latex-list-of-description: Supplementary Figure
+ - kind: float
+ key: stb
+ reference-prefix: "Supplementary Table"
+ space-before-numbering: true
+ caption-prefix: "Supplementary Table"
+ latex-env: stb
+ latex-list-of-file-extension: lost
+ latex-list-of-description: Supplementary Table
+ - kind: float
+ key: seq
+ reference-prefix: "Supplementary Eq."
+ space-before-numbering: true
+ caption-prefix: "Supplementary Eq."
+ latex-env: seq
+ latex-list-of-file-extension: lost
+ latex-list-of-description: Supplementary Equation
+ - kind: float
+ key: rfg
+ reference-prefix: "Fig. R"
+ space-before-numbering: false
+ caption-prefix: "Fig. R"
+ latex-env: rfg
+ latex-list-of-file-extension: lost
+ latex-list-of-description: Revision Figure
+ - kind: float
+ key: rtb
+ reference-prefix: "Table R"
+ space-before-numbering: false
+ caption-prefix: "Table R"
+ latex-env: rtb
+ latex-list-of-file-extension: lost
+ latex-list-of-description: Revision Table
+ - kind: float
+ key: req
+ reference-prefix: "Eq R"
+ space-before-numbering: false
+ caption-prefix: "Eq R"
+ latex-env: req
+ latex-list-of-file-extension: lost
+ latex-list-of-description: Revision Equation
diff --git a/_extensions/drwater/dwms/header.tex b/_extensions/drwater/dwms/header.tex
new file mode 100644
index 0000000..40b8751
--- /dev/null
+++ b/_extensions/drwater/dwms/header.tex
@@ -0,0 +1,137 @@
+% -----------------------
+% CUSTOM PREAMBLE STUFF
+% -----------------------
+\usepackage{enumitem}
+\usepackage{fontspec}
+\usepackage{float}
+\usepackage[normalem]{ulem}
+\usepackage{hyperref}
+\usepackage{nameref} %needed by zref-xr
+\usepackage{zref-xr,zref-hyperref,zref-user}
+\usepackage{xr-hyper}
+\usepackage[normalem]{ulem}
+\usepackage{setspace}
+\usepackage{lineno}
+\usepackage[UTF8, scheme=plain]{ctex}
+\usepackage{orcidlink}
+
+% \setkomafont{author}{\normalsize}
+
+% for revision
+\usepackage{adjustbox}
+% \usepackage{xcolor}
+\usepackage{mdframed}
+\newmdenv[topline=false,
+ leftline=true,
+ bottomline=false,
+ rightline=false,
+ linewidth=3pt,
+ %backgroundcolor=lightgray,
+ linecolor=gray!30,
+ backgroundcolor=gray!5,
+ skipabove=\topsep,
+ skipbelow=\topsep,
+ leftmargin=0pt,
+ rightmargin=0pt,
+ innertopmargin=0pt,
+ innerbottommargin=0pt
+ ]{refquote}
+\newmdenv[topline=false,
+ leftline=true,
+ bottomline=false,
+ rightline=false,
+ linewidth=3pt,
+ %backgroundcolor=lightgray,
+ backgroundcolor=red!3!white,
+ linecolor=red!30!white,
+ skipabove=\topsep,
+ skipbelow=\topsep,
+ leftmargin=0pt,
+ rightmargin=0pt,
+ innertopmargin=10pt,
+ innerbottommargin=10pt
+ ]{question}
+% setup hyperlink for page and line number
+\def\msname{MS}
+\def\smname{SM}
+\setenumerate{labelsep=*, leftmargin=1.0pc}
+%\zexternaldocument*{ManuscriptNew\veraa}
+\zexternaldocument*{\msname}
+\zexternaldocument*{\smname}
+\newcommand{\hlabel}[1]{\label{#1}\hypertarget{#1}{
+ \linelabel{line:#1}}}
+%\externaldocument[si-]{\smname\veraa}[\smname\veraa.pdf]
+\makeatletter
+\newcommand{\clab}[2][]{
+ \protected@write\@auxout{\let\clab\@secondoftwo}{
+ \string\newlabel{r:#1}{{#2}{}}}%
+ \hlabel{#1}#2\hlabel{#1end}}
+\makeatother
+\newcommand{\zhypera}[1]{\href[pdfnewwindow]{\msname.pdf\##1}{\\[1ex]\textbf{Page \zpageref{#1}, Line
+\zref{line:#1}--\zref{line:#1end}:}\\}}
+\newcommand{\cref}[1]{\begin{refquote}\zhypera{#1}{\zref{r:#1}}\\[-0.5ex]\end{refquote}}
+% \newenvironment{ra}[1][\unskip]{\par \noindent \\[-1ex] \textbf{Response/Action:}\par\bf}{\ \\}
+% \renewenvironment{verbatim}{\begin{ra}}{\end{ra}}
+\renewenvironment{quote}{%
+ \vspace{12pt plus 4pt minus 2pt}% 12pt基础间距,可伸缩
+ \begin{question}%
+}{%
+ \end{question}%
+ % \vspace{12pt plus 4pt minus 2pt}%
+}
+
+
+
+
+% -----------------
+% Title block stuff
+% -----------------
+
+% Title
+\makeatletter
+\renewcommand{\title}[1]{\gdef\@title{\large\textbf{#1}}} % Adjust \Huge or other font commands
+\makeatother
+
+
+% ------------------
+% Section headings
+% ------------------
+\usepackage{titlesec}
+\titleformat*{\section}{\Large\sffamily\bfseries\raggedright}
+\titleformat*{\subsection}{\large\sffamily\bfseries\raggedright}
+\titleformat*{\subsubsection}{\normalsize\sffamily\bfseries\raggedright}
+\titleformat*{\paragraph}{\small\sffamily\bfseries\raggedright}
+
+%\titlespacing{}{}{}{}
+% Starred version removes indentation in following paragraph
+% \titlespacing*{\section}{0em}{2em}{0.1em}
+% \titlespacing*{\subsection}{0em}{1.25em}{0.1em}
+% \titlespacing*{\subsubsection}{0em}{0.75em}{0em}
+
+% ------------------
+% Headers/Footers
+% ------------------
+% \usepackage{fancyhdr}
+% \pagestyle{fancy}
+% \fancyhf{}
+% \fancyhead[L,C,R]{}
+% \fancyfoot[L,C]{}
+% \fancyfoot[R]{\thepage}
+% \renewcommand{\headrulewidth}{1pt}
+% \fancypagestyle{plain}{%
+% \renewcommand{\headrulewidth}{0pt}%
+% \fancyhf{}%
+% \fancyfoot[R]{\thepage}%
+% }
+% \renewcommand\footnoterule{\rule{\linewidth}{0.1pt}\vspace{5pt}}
+
+% ------------------
+% Captions
+% ------------------
+\usepackage[labelfont=bf,labelsep=period]{caption}
+\captionsetup[figure]{font=footnotesize,justification=centering,singlelinecheck=false,format=hang}
+
+
+% ---------------------------
+% END CUSTOM PREAMBLE STUFF
+% ---------------------------
diff --git a/_extensions/drwater/dwms/inst/CL.docx b/_extensions/drwater/dwms/inst/CL.docx
new file mode 100755
index 0000000..3727b07
Binary files /dev/null and b/_extensions/drwater/dwms/inst/CL.docx differ
diff --git a/_extensions/drwater/dwms/inst/MS.docx b/_extensions/drwater/dwms/inst/MS.docx
new file mode 100644
index 0000000..0165cf5
Binary files /dev/null and b/_extensions/drwater/dwms/inst/MS.docx differ
diff --git a/_extensions/drwater/dwms/inst/RN.docx b/_extensions/drwater/dwms/inst/RN.docx
new file mode 100755
index 0000000..a74403c
Binary files /dev/null and b/_extensions/drwater/dwms/inst/RN.docx differ
diff --git a/_extensions/drwater/dwms/inst/RP.docx b/_extensions/drwater/dwms/inst/RP.docx
new file mode 100755
index 0000000..18580b1
Binary files /dev/null and b/_extensions/drwater/dwms/inst/RP.docx differ
diff --git a/_extensions/drwater/dwms/inst/clab-tooltip.js b/_extensions/drwater/dwms/inst/clab-tooltip.js
new file mode 100644
index 0000000..900b133
--- /dev/null
+++ b/_extensions/drwater/dwms/inst/clab-tooltip.js
@@ -0,0 +1,418 @@
+// clab-tooltip.js - 完全隔离事件版本(修改后的显示位置逻辑)
+(function() {
+ // 全局变量存储从 RN.html 提取的内容
+ let rnContentCache = {};
+ let isRnContentLoaded = false;
+ let activeTooltip = null;
+ let hideTimer = null;
+ let isMouseOverTooltip = false;
+
+ // 从 RN.html 提取内容(保持不变)
+ async function loadRnContent() {
+ try {
+ console.log('加载 RN.html...');
+ const response = await fetch('RN.html');
+ if (!response.ok) throw new Error(`HTTP error: ${response.status}`);
+
+ const htmlText = await response.text();
+ const parser = new DOMParser();
+ const rnDoc = parser.parseFromString(htmlText, 'text/html');
+
+ // 查找所有包含 data-options 的元素
+ const optionElements = rnDoc.querySelectorAll('[data-options]');
+ console.log(`找到 ${optionElements.length} 个 data-options 元素`);
+
+ optionElements.forEach(element => {
+ const optionValue = element.getAttribute('data-options');
+ if (!optionValue) return;
+
+ // 向前查找最近的 blockquote
+ let prevElement = element.previousElementSibling;
+ let blockquote = null;
+
+ // 先找前一个兄弟元素
+ while (prevElement) {
+ if (prevElement.tagName === 'BLOCKQUOTE') {
+ blockquote = prevElement;
+ break;
+ }
+ prevElement = prevElement.previousElementSibling;
+ }
+
+ // 如果没找到,向上查找
+ if (!blockquote) {
+ let parent = element.parentElement;
+ while (parent) {
+ let sibling = parent.previousElementSibling;
+ while (sibling) {
+ if (sibling.tagName === 'BLOCKQUOTE') {
+ blockquote = sibling;
+ break;
+ }
+ sibling = sibling.previousElementSibling;
+ }
+ if (blockquote) break;
+ parent = parent.parentElement;
+ }
+ }
+
+ if (blockquote) {
+ const lis = blockquote.querySelectorAll('li');
+ if (lis.length > 0) {
+ const liContents = Array.from(lis).map(li => li.textContent.trim());
+
+ if (!rnContentCache[optionValue]) {
+ rnContentCache[optionValue] = [];
+ }
+
+ // 存储所有引用
+ rnContentCache[optionValue].push({
+ contents: liContents
+ });
+ }
+ }
+ });
+
+ isRnContentLoaded = true;
+
+ console.log('内容加载完成');
+ Object.keys(rnContentCache).forEach(key => {
+ console.log(`"${key}": ${rnContentCache[key].length} Questions`);
+ });
+
+ } catch (error) {
+ console.error('加载失败:', error);
+ }
+ }
+
+ // 创建 tooltip(保持不变)
+ function createTooltip() {
+ const tooltip = document.createElement('div');
+ tooltip.className = 'clab-tooltip';
+ tooltip.id = 'clab-tooltip-element';
+
+ // 完全阻止所有事件冒泡
+ const stopAllEvents = (e) => {
+ e.stopPropagation();
+ e.stopImmediatePropagation();
+ e.preventDefault();
+ return false;
+ };
+
+ // 阻止所有可能的事件
+ const events = [
+ 'mousedown', 'mouseup', 'click', 'dblclick',
+ 'mousemove', 'mouseover', 'mouseout', 'mouseenter', 'mouseleave',
+ 'wheel', 'scroll',
+ 'touchstart', 'touchmove', 'touchend', 'touchcancel',
+ 'pointerdown', 'pointermove', 'pointerup', 'pointercancel',
+ 'dragstart', 'dragover', 'drop'
+ ];
+
+ events.forEach(eventType => {
+ tooltip.addEventListener(eventType, stopAllEvents, true); // 捕获阶段
+ tooltip.addEventListener(eventType, stopAllEvents, false); // 冒泡阶段
+ });
+
+ // 允许 wheel 事件用于滚动,但阻止冒泡
+ tooltip.addEventListener('wheel', function(e) {
+ e.stopPropagation();
+ e.stopImmediatePropagation();
+ // 允许默认的滚动行为
+ }, { passive: false });
+
+ // 允许鼠标在 tooltip 内移动
+ tooltip.addEventListener('mousemove', function(e) {
+ e.stopPropagation();
+ }, { passive: true });
+
+ document.body.appendChild(tooltip);
+ return tooltip;
+ }
+
+ // 显示 tooltip - 已修改位置逻辑
+ function showTooltip(element, tooltip) {
+ const rect = element.getBoundingClientRect();
+ const optionValue = element.getAttribute('data-options');
+
+ // 清空内容
+ tooltip.innerHTML = '';
+
+ if (rnContentCache[optionValue] && rnContentCache[optionValue].length > 0) {
+ const entries = rnContentCache[optionValue];
+
+ // 标题显示选项
+ const title = document.createElement('div');
+ title.className = 'tooltip-title';
+ title.textContent = optionValue;
+ if (entries.length > 1) {
+ title.textContent += ` (${entries.length} questions)`;
+ }
+ tooltip.appendChild(title);
+
+ // 显示所有引用
+ entries.forEach((entry, entryIndex) => {
+ const content = entry.contents;
+
+ if (content.length === 1) {
+ // 单一条目
+ const entryDiv = document.createElement('div');
+ entryDiv.className = 'entry-single';
+
+ if (entries.length >= 1) {
+ entryDiv.innerHTML = `Q${entryIndex + 1}: ${content[0]}`;
+ } else {
+ entryDiv.textContent = content[0];
+ }
+
+ tooltip.appendChild(entryDiv);
+ } else {
+ // 多个条目
+ const entryDiv = document.createElement('div');
+ entryDiv.className = 'entry-multiple';
+
+ if (entries.length > 1) {
+ const header = document.createElement('div');
+ header.className = 'q-header';
+ header.textContent = `Q${entryIndex + 1}:`;
+ entryDiv.appendChild(header);
+ }
+
+ const ol = document.createElement('ol');
+ ol.className = 'q-list';
+
+ content.forEach((item, itemIndex) => {
+ const li = document.createElement('li');
+ li.innerHTML = `${entryIndex + 1}.${itemIndex + 1} ${item}`;
+ ol.appendChild(li);
+ });
+
+ entryDiv.appendChild(ol);
+ tooltip.appendChild(entryDiv);
+ }
+ });
+ } else {
+ // 没有找到内容
+ const noContent = document.createElement('div');
+ noContent.className = 'tooltip-no-content';
+ noContent.textContent = '未找到相关内容';
+ tooltip.appendChild(noContent);
+ }
+
+ // 确保 tooltip 有合适的尺寸
+ tooltip.style.position = 'fixed';
+ tooltip.style.zIndex = '10000';
+ tooltip.style.maxWidth = '400px';
+ tooltip.style.maxHeight = '500px';
+ tooltip.style.overflowY = 'auto';
+ tooltip.style.boxSizing = 'border-box';
+
+ // 首先隐藏并获取尺寸
+ tooltip.style.visibility = 'hidden';
+ tooltip.classList.add('active');
+ document.body.appendChild(tooltip);
+
+ const tooltipWidth = Math.min(tooltip.scrollWidth, 400);
+ const tooltipHeight = Math.min(tooltip.scrollHeight, 500);
+
+ tooltip.style.width = tooltipWidth + 'px';
+ tooltip.style.height = 'auto';
+
+ const padding = 5;
+ const minDistanceFromEdge = 20;
+
+ let left, top;
+ let position = 'right'; // 首选右侧
+
+ // 检查右侧空间
+ if (rect.right + padding + tooltipWidth <= window.innerWidth - minDistanceFromEdge) {
+ // 右侧有足够空间
+ left = rect.right + padding;
+ top = rect.top;
+ position = 'right';
+ } else if (rect.left - padding - tooltipWidth >= minDistanceFromEdge) {
+ // 左侧有足够空间
+ left = rect.left - padding - tooltipWidth;
+ top = rect.top;
+ position = 'left';
+ } else {
+ // 两侧都没有足够空间,显示在下方
+ left = Math.max(
+ minDistanceFromEdge,
+ Math.min(
+ rect.left + (rect.width - tooltipWidth) / 2,
+ window.innerWidth - tooltipWidth - minDistanceFromEdge
+ )
+ );
+ top = rect.bottom + padding;
+ position = 'bottom';
+ }
+
+ // 垂直边界检查 - 确保不超出屏幕
+ if (top + tooltipHeight > window.innerHeight - minDistanceFromEdge) {
+ // 如果下方空间不足,尝试显示在上方
+ if (rect.top - padding - tooltipHeight >= minDistanceFromEdge) {
+ top = rect.top - padding - tooltipHeight;
+ } else {
+ // 上下都不够,显示在中间
+ top = Math.max(
+ minDistanceFromEdge,
+ Math.min(
+ top,
+ window.innerHeight - tooltipHeight - minDistanceFromEdge
+ )
+ );
+ }
+ }
+
+ // 水平边界检查 - 确保不超出屏幕
+ if (position === 'right' || position === 'left') {
+ left = Math.max(
+ minDistanceFromEdge,
+ Math.min(left, window.innerWidth - tooltipWidth - minDistanceFromEdge)
+ );
+ }
+
+ tooltip.style.left = left + 'px';
+ tooltip.style.top = top + 'px';
+ tooltip.style.visibility = 'visible';
+
+ // 添加一个小箭头指示方向
+ tooltip.setAttribute('data-position', position);
+
+ activeTooltip = tooltip;
+ isMouseOverTooltip = true;
+
+ // 添加 overlay 防止 body 交互
+ addOverlay();
+ }
+
+ // 添加半透明 overlay(保持不变)
+ function addOverlay() {
+ // 移除现有的 overlay
+ removeOverlay();
+
+ const overlay = document.createElement('div');
+ overlay.id = 'tooltip-overlay';
+ overlay.style.cssText = `
+ position: fixed;
+ top: 0;
+ left: 0;
+ width: 100%;
+ height: 100%;
+ z-index: 9999;
+ background: transparent;
+ pointer-events: none;
+ `;
+ document.body.appendChild(overlay);
+
+ // 将 overlay 的 pointer-events 设为 auto,但阻止所有事件
+ overlay.addEventListener('mousedown', stopEvent, true);
+ overlay.addEventListener('mouseup', stopEvent, true);
+ overlay.addEventListener('click', stopEvent, true);
+ overlay.addEventListener('mousemove', stopEvent, true);
+ overlay.addEventListener('wheel', stopEvent, true);
+
+ function stopEvent(e) {
+ e.preventDefault();
+ e.stopPropagation();
+ e.stopImmediatePropagation();
+ return false;
+ }
+ }
+
+ // 移除 overlay(保持不变)
+ function removeOverlay() {
+ const overlay = document.getElementById('tooltip-overlay');
+ if (overlay) {
+ overlay.remove();
+ }
+ }
+
+ // 隐藏 tooltip(保持不变)
+ function hideTooltip() {
+ if (!isMouseOverTooltip && activeTooltip) {
+ activeTooltip.classList.remove('active');
+ activeTooltip = null;
+ removeOverlay();
+ }
+ }
+
+ // 强制隐藏 tooltip(保持不变)
+ function forceHideTooltip() {
+ if (activeTooltip) {
+ activeTooltip.classList.remove('active');
+ activeTooltip = null;
+ isMouseOverTooltip = false;
+ removeOverlay();
+ }
+ }
+
+ // 初始化(保持不变)
+ document.addEventListener('DOMContentLoaded', function() {
+ console.log('初始化 clab-tooltip');
+
+ const clabElements = document.querySelectorAll('.clab[data-options]');
+ console.log(`找到 ${clabElements.length} 个 .clab 元素`);
+
+ if (clabElements.length === 0) return;
+
+ // 加载内容
+ loadRnContent();
+
+ // 创建 tooltip
+ const tooltip = createTooltip();
+
+ // tooltip 鼠标进入/离开
+ tooltip.addEventListener('mouseenter', function() {
+ isMouseOverTooltip = true;
+ clearTimeout(hideTimer);
+ });
+
+ tooltip.addEventListener('mouseleave', function() {
+ isMouseOverTooltip = false;
+ hideTimer = setTimeout(() => {
+ forceHideTooltip();
+ }, 100);
+ });
+
+ // 为所有 .clab 元素添加事件监听
+ clabElements.forEach(clab => {
+ clab.addEventListener('mouseenter', function() {
+ clearTimeout(hideTimer);
+
+ setTimeout(() => {
+ if (isRnContentLoaded) {
+ showTooltip(this, tooltip);
+ }
+ }, 100);
+ });
+
+ clab.addEventListener('mouseleave', function() {
+ hideTimer = setTimeout(() => {
+ hideTooltip();
+ }, 100);
+ });
+ });
+
+ // ESC 键隐藏 tooltip
+ document.addEventListener('keydown', function(e) {
+ if (e.key === 'Escape' && activeTooltip) {
+ forceHideTooltip();
+ }
+ });
+
+ // 点击其他地方隐藏 tooltip
+ document.addEventListener('click', function(e) {
+ if (activeTooltip && !activeTooltip.contains(e.target)) {
+ forceHideTooltip();
+ }
+ });
+
+ // 窗口大小改变时隐藏 tooltip
+ window.addEventListener('resize', forceHideTooltip);
+
+ // 滚动时隐藏 tooltip
+ window.addEventListener('scroll', forceHideTooltip);
+ });
+})();
diff --git a/_extensions/drwater/dwms/inst/drwater.css b/_extensions/drwater/dwms/inst/drwater.css
new file mode 100755
index 0000000..0c6328b
--- /dev/null
+++ b/_extensions/drwater/dwms/inst/drwater.css
@@ -0,0 +1,395 @@
+.udot {
+ text-decoration-line: underline;
+ text-decoration-color: rgb(50, 50, 50);
+ text-decoration-style: dashed;
+ text-decoration-thickness: 1px;
+}
+
+.good {
+ background-color: forestgreen;
+ color: lightyellow;
+}
+
+.bad {
+ background-color: orangered;
+ color: lightyellow;
+}
+
+.del {
+ text-decoration-line: line-through;
+ text-decoration-color: rgb(222 13 13);
+ text-decoration-style: initial;
+ text-decoration-thickness: 1.5px;
+}
+
+
+.todo {
+ background-color: darkorange;
+ color: lightyellow;
+}
+
+.com {
+ background-color: #0025ff;
+ font-weight: bold;
+ color: lightyellow;
+}
+
+.add {
+ text-decoration-line: underline;
+ text-decoration-color: rgb(222 13 13);
+ background-color: violet;
+ text-decoration-style: initial;
+ text-decoration-thickness: 2px;
+}
+
+
+del {
+ text-decoration-line: line-through;
+ text-decoration-color: rgb(222 13 13);
+ text-decoration-style: initial;
+ text-decoration-thickness: 1.0px;
+}
+
+
+ins {
+ text-decoration-color: rgb(222 93 93);
+ background-color: violet;
+ text-decoration-style: initial;
+ text-decoration-thickness: 2px;
+}
+
+
+.blockquote {
+ font-size: inherit;
+ padding-left: 1rem;
+ padding-right: 1.5rem;
+ color: black;
+ font-weight: 500;
+ margin: 0 0 1rem;
+ padding: .625rem 1.25rem;
+ border-left: .25rem solid #ffb3b3;
+ background-color: #ffb2b32b;
+}
+
+/* clab-style.css */
+.clab {
+ display: inline !important;
+ position: relative !important;
+ cursor: pointer !important;
+ padding: 2px 4px !important;
+ margin: 0 1px !important;
+ border-radius: 3px !important;
+ font: inherit !important;
+ color: #000000 !important;
+ text-decoration: none !important;
+ vertical-align: baseline !important;
+ line-height: inherit !important;
+ z-index: 1 !important;
+}
+
+/* 随机背景色(使用预定义颜色) */
+.clab:nth-child(10n+1) { background-color: #E3F2FD !important; }
+.clab:nth-child(10n+2) { background-color: #F3E5F5 !important; }
+.clab:nth-child(10n+3) { background-color: #E8F5E9 !important; }
+.clab:nth-child(10n+4) { background-color: #FFF3E0 !important; }
+.clab:nth-child(10n+5) { background-color: #FCE4EC !important; }
+.clab:nth-child(10n+6) { background-color: #E0F7FA !important; }
+.clab:nth-child(10n+7) { background-color: #F1F8E9 !important; }
+.clab:nth-child(10n+8) { background-color: #FFF8E1 !important; }
+.clab:nth-child(10n+9) { background-color: #EDE7F6 !important; }
+.clab:nth-child(10n+10) { background-color: #E8EAF6 !important; }
+
+/* 基础hover效果 */
+span.clab:hover {
+ outline: 2px solid rgba(0,0,0,0.2) !important;
+ outline-offset: 2px !important;
+ z-index: 1000 !important;
+}
+
+
+
+
+/* clab-tooltip 下方显示样式 */
+.clab-tooltip {
+ font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
+ color: white;
+ padding: 5px;
+ border: 1px solid #444;
+ /* -webkit-user-select: none; */
+ position: fixed;
+ background: rgba(0, 0, 0, 0.95);
+ border-radius: 8px;
+ z-index: 10000;
+ box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3),
+ 0 0 0 1px rgba(255, 255, 255, 0.1);
+ font-size: 14px;
+ line-height: 1.1;
+ max-width: 500px;
+ max-height: 800px;
+ overflow-y: auto;
+ opacity: 0;
+ visibility: hidden;
+ transition: opacity 0.2s ease, visibility 0.2s ease, transform 0.2s ease;
+ overscroll-behavior: contain;
+ pointer-events: auto !important;
+}
+
+
+/* Tooltip 箭头 */
+.tooltip-arrow {
+ position: absolute;
+ width: 0;
+ height: 0;
+ border: 6px solid transparent;
+ border-bottom-color: #2a2a2a;
+ border-top: none;
+}
+
+/* tooltip 在上方的箭头(向下) */
+.clab-tooltip.above .tooltip-arrow {
+ border-top-color: #2a2a2a;
+ border-bottom: none;
+}
+
+/* 标题 */
+.tooltip-title {
+ font-weight: 600;
+ color: #FF9800;
+ margin-bottom: 6px;
+ padding-bottom: 4px;
+ border-bottom: 1px solid #444;
+ font-size: 14px;
+ font-family: monospace;
+ line-height: 0.8;
+ pointer-events: none;
+}
+
+/* 单一条目 */
+.entry-single {
+ padding: 4px 4px;
+ margin-bottom: 6px;
+ background: rgba(255, 255, 255, 0.05);
+ border-radius: 6px;
+ border-left: 3px solid #ffffff;
+ line-height: 1.2;
+ cursor: default;
+}
+
+/* Q标签样式 */
+.q-label {
+ display: inline-block;
+ color: #FF9800;
+ font-weight: 600;
+ margin-right: 8px;
+ min-width: 35px;
+}
+
+/* 多个条目的引用 */
+.entry-multiple {
+ padding: 4px 4px;
+ margin-bottom: 6px;
+ background: rgba(255, 255, 255, 0.05);
+ border-radius: 6px;
+ border-left: 3px solid #ffffff;
+ line-height: 1.2;
+ cursor: default;
+}
+
+/* 多引用标题 */
+.q-header {
+ color: #FF9800;
+ font-weight: 600;
+ margin-bottom: 8px;
+ font-size: 13px;
+ pointer-events: none;
+}
+
+/* 列表 */
+.q-list {
+ margin: 0;
+ padding-left: 0;
+ list-style: none;
+}
+
+.q-list li {
+ margin-bottom: 10px;
+ padding-left: 0;
+ line-height: 1.2;
+ position: relative;
+ cursor: default;
+ padding: 4px 0;
+}
+
+/* 子标签样式 */
+.q-sublabel {
+ display: inline-block;
+ color: #4CAF50;
+ font-weight: 600;
+ margin-right: 2px;
+ min-width: 25px;
+}
+
+/* 条目间空行 */
+/* .entry-spacer { */
+/* height: 12px; */
+/* pointer-events: none; */
+/* } */
+
+/* 无内容 */
+.tooltip-no-content {
+ color: #ff6b6b;
+ font-style: italic;
+ padding: 20px;
+ text-align: center;
+ background: rgba(255, 107, 107, 0.05);
+ border-radius: 6px;
+ cursor: default;
+}
+
+/* 滚动条 */
+.clab-tooltip::-webkit-scrollbar {
+ width: 8px;
+ height: 8px;
+}
+
+.clab-tooltip::-webkit-scrollbar-track {
+ background: #1a1a1a;
+ border-radius: 4px;
+}
+
+.clab-tooltip::-webkit-scrollbar-thumb {
+ background: #4CAF50;
+ border-radius: 4px;
+}
+
+.clab-tooltip::-webkit-scrollbar-thumb:hover {
+ background: #45a049;
+}
+
+
+/* 允许内容文本选择 */
+.entry-single,
+.entry-multiple,
+.q-list li {
+ user-select: text;
+ -webkit-user-select: text;
+}
+
+/* 鼠标在 tooltip 上时的样式 */
+.clab-tooltip:hover {
+ cursor: default;
+}
+
+
+.clab-tooltip.active {
+ opacity: 1;
+ visibility: visible;
+ transform: translateY(0);
+}
+
+.clab-tooltip ul {
+ margin: 0;
+ padding-left: 20px;
+}
+
+.clab-tooltip li {
+ margin-bottom: 8px;
+ position: relative;
+}
+
+.clab-tooltip .source {
+ margin-top: 10px;
+ padding-top: 10px;
+ border-top: 1px solid rgba(255,255,255,0.1);
+ font-size: 11px;
+ color: #aaa;
+ font-style: italic;
+}
+
+.clab-tooltip .entry {
+ margin-bottom: 15px;
+ padding-bottom: 10px;
+ border-bottom: 1px solid rgba(255,255,255,0.1);
+}
+
+.clab-tooltip .entry:last-child {
+ border-bottom: none;
+}
+
+
+
+.rem {
+ background-color: darkorange;
+ color: lightyellow;
+ text-decoration-thickness: 2px;
+}
+
+
+#criticnav {
+ position: fixed;
+ z-index: 1100;
+ top: 0;
+ right: 0;
+ width: 120px;
+ border-bottom: solid 1px #ffffff;
+ margin: 0;
+ padding: 10;
+ background-color: rgb(143 38 38 / 95%);
+ color: #ffffff;
+ font-size: 12px;
+ font-family: "Helvetica Neue", helvetica, arial, sans-serif !important
+}
+
+#criticnav ul {
+ list-style-type: none;
+ width: 90%;
+ margin: 0 auto;
+ padding: 0
+}
+
+#criticnav ul li {
+ display: block;
+ width: 100px;
+ min-width: 80px;
+ text-align: center;
+ padding: 5px 0 3px !important;
+ margin: 5px 2px !important;
+ line-height: 1em;
+ float: center;
+ text-transform: uppercase;
+ cursor: pointer;
+ border-radius: 20px;
+ border: 3px solid rgba(255,255,255,0);
+ color: #fff !important
+}
+
+p {
+ text-align: left; /* 小屏幕左对齐 */
+}
+
+@media (min-width: 768px) {
+ p {
+ text-align: justify;
+ hyphens: auto; /* 自动断字 */
+ -webkit-hyphens: auto; /* Safari 支持 */
+ /* 可选:控制断字行为 */
+ hyphenate-limit-chars: 6 3 2; /* 最小单词长度 前/后最小字符数 */
+ }
+}
+
+@media (min-width: 992px) {
+ body .page-columns {
+ display: grid;
+ gap: 0;
+ grid-template-columns: [screen-start] 0.5em [screen-start-inset] 0fr [page-start page-start-inset] 5px [body-start-outset] 5px [body-start] 0.5em [body-content-start] minmax(350px, calc(855px - 0em)) [body-content-end] 0.5em [body-end] 5px [body-end-outset] minmax(75px, 550px) [page-end-inset] 1px [page-end] 1fr [screen-end-inset] 0.5em [screen-end];
+ }
+}
+
+
+@media (min-width: 1280px) {
+ body .page-columns {
+ display: grid;
+ gap: 0;
+ grid-template-columns: [screen-start] 3.5em [screen-start-inset] 2fr [page-start page-start-inset] 35px [body-start-outset] 35px [body-start] 3.5em [body-content-start] minmax(500px, calc(850px - 3em)) [body-content-end] 1.5em [body-end] 35px [body-end-outset] minmax(75px, 400px) [page-end-inset] 35px [page-end] 2fr [screen-end-inset] 1.5em [screen-end];
+ }
+}
diff --git a/_extensions/drwater/dwms/inst/drwater.scss b/_extensions/drwater/dwms/inst/drwater.scss
new file mode 100644
index 0000000..93672cf
--- /dev/null
+++ b/_extensions/drwater/dwms/inst/drwater.scss
@@ -0,0 +1,415 @@
+/*-- scss:defaults --*/
+
+$theme: "drwater" !default;
+
+//
+// Color system
+//
+
+$white: #ffffff !default;
+$gray-100: #f8f9fa !default;
+$gray-200: #e9ecef !default;
+$gray-300: #dee2e6 !default;
+$gray-400: #ced4da !default;
+$gray-500: #adb5bd !default;
+$gray-600: #868e96 !default;
+$gray-700: #495057 !default;
+$gray-800: #373a3c !default;
+$gray-900: #212529 !default;
+$black: #000000 !default;
+
+$blue: #2780e3 !default;
+$indigo: #6610f2 !default;
+$purple: #170c3a !default;
+$pink: #a52c60 !default;
+$red: #cf4446 !default;
+$orange: #ee6a24 !default;
+$light-orange: #fb9e07 !default;
+$yellow: #f6d645 !default;
+$green: #118230 !default;
+$teal: #20c997 !default;
+$cyan: #3093cf !default;
+
+$primary: $pink !default;
+$secondary: $gray-700 !default;
+$success: $green !default;
+$info: $cyan !default;
+$warning: $orange !default;
+$danger: $red !default;
+$light: $gray-400 !default;
+$dark: $black !default;
+
+// Fonts
+
+$font-family-sans-serif: "Libre Franklin" !default;
+
+$headings-font-family: "Jost" !default;
+$headings-font-weight: 600 !default;
+
+$navbar-font-family: "Jost" !default;
+$toc-font-family: "Jost" !default;
+$footer-font-family: "Jost" !default;
+
+// Body
+$body-color: $gray-900 !default;
+
+// Links
+$link-color: $orange !default;
+$link-decoration: none !default;
+$link-hover-color: $red !default;
+$link-hover-decoration: underline !default;
+
+// Inline code
+$code-bg: $gray-200 !default;
+$code-color: $gray-900 !default;
+
+// Code copy
+$btn-code-copy-color-active: $orange !default;
+
+// TOC
+$toc-color: $orange;
+$toc-font-size: 1em;
+
+// Navbar
+$navbar-bg: $purple !default;
+$navbar-fg: $white !default;
+$navbar-hl: $light-orange !default;
+
+// Footer
+$footer-bg: $gray-900 !default;
+$footer-fg: $gray-300 !default;
+
+/*-- scss:rules --*/
+
+$web-font-path: "https://fonts.googleapis.com/css2?family=Jost:ital,wght@0,100..900;1,100..900&family=Libre+Franklin:ital,wght@0,100..900;1,100..900&display=swap" !default;
+
+@if $web-font-path {
+ @import url($web-font-path);
+}
+
+body {
+ -webkit-font-smoothing: antialiased;
+}
+
+/* Logo 悬停效果 */
+.navbar-brand img {
+ transition: all 0.3s ease;
+ filter: brightness(0) invert(1);
+
+ &:hover {
+ filter: brightness(0) invert(0.55) sepia(1) saturate(2000%) hue-rotate(-8deg) brightness(1.05) contrast(1.2);
+ transform: scale(1.05);
+ }
+}
+
+// =============================================
+// 桌面端样式 - 使用悬停展开下拉菜单
+// =============================================
+@media (min-width: 992px) {
+ /* 导航栏主菜单项样式 */
+ .navbar-nav .nav-item {
+ position: relative;
+ margin: 0 0.2rem;
+
+ .nav-link {
+ position: relative;
+ color: $navbar-fg !important;
+ font-weight: 500;
+ padding: 0.75rem 1rem !important;
+ border-radius: 8px;
+ transition: all 0.3s ease;
+ z-index: 1;
+
+ /* 玻璃效果背景 */
+ &::before {
+ content: '';
+ position: absolute;
+ top: 0;
+ left: 0;
+ right: 0;
+ bottom: 0;
+ background: rgba($white, 0.1);
+ backdrop-filter: blur(10px);
+ border-radius: 8px;
+ opacity: 0;
+ transition: all 0.3s ease;
+ z-index: -1;
+ border: 1px solid rgba($white, 0.2);
+ }
+
+ &:hover {
+ color: $light-orange !important;
+ transform: translateY(-2px);
+
+ &::before {
+ opacity: 1;
+ background: rgba($white, 0.15);
+ backdrop-filter: blur(15px);
+ box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
+ }
+ }
+
+ /* 激活状态 */
+ &.active {
+ color: $light-orange !important;
+ font-weight: 600;
+
+ &::before {
+ opacity: 1;
+ background: rgba($light-orange, 0.2);
+ backdrop-filter: blur(15px);
+ border: 1px solid rgba($light-orange, 0.3);
+ }
+ }
+ }
+ }
+
+ /* 有下拉菜单的主菜单项特殊样式 */
+ .navbar-nav .nav-item.dropdown {
+ .nav-link {
+ padding-right: 2rem !important;
+
+ &::after {
+ position: absolute;
+ right: 1rem;
+ top: 50%;
+ transform: translateY(-50%);
+ transition: all 0.3s ease;
+ }
+ }
+
+ &:hover .nav-link::before {
+ opacity: 1;
+ background: rgba($white, 0.2);
+ backdrop-filter: blur(20px);
+ border-bottom-left-radius: 0;
+ border-bottom-right-radius: 0;
+ }
+
+ &:hover .nav-link::after {
+ transform: translateY(-50%) rotate(-180deg);
+ border-top-color: $light-orange;
+ }
+ }
+
+ /* 桌面端下拉菜单悬停效果 */
+ .navbar-nav .nav-item.dropdown:hover .dropdown-menu {
+ display: block !important;
+ opacity: 1 !important;
+ visibility: visible !important;
+ transform: translateY(0) !important;
+ }
+
+ .dropdown-menu {
+ display: block;
+ opacity: 0;
+ visibility: hidden;
+ transform: translateY(-10px);
+ transition: all 0.3s ease;
+ background: rgba($purple, 0.98) !important;
+ backdrop-filter: blur(20px);
+ border: 1px solid rgba($white, 0.1);
+ border-top: none;
+ border-radius: 0 0 8px 8px;
+ box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
+ margin-top: -1px;
+ padding: 0.5rem 0;
+
+ &.show {
+ display: block;
+ opacity: 1;
+ visibility: visible;
+ transform: translateY(0);
+ }
+ }
+
+ .dropdown-item {
+ color: $white !important;
+ font-family: $navbar-font-family;
+ padding: 0.75rem 1.5rem;
+ transition: all 0.2s ease;
+ position: relative;
+
+ /* 下拉菜单项的玻璃效果 */
+ &::before {
+ content: '';
+ position: absolute;
+ top: 0;
+ left: 0;
+ right: 0;
+ bottom: 0;
+ background: rgba($white, 0.05);
+ border-radius: 4px;
+ opacity: 0;
+ transition: all 0.2s ease;
+ z-index: -1;
+ }
+
+ &:hover, &:focus {
+ color: $light-orange !important;
+ transform: translateX(5px);
+ background: transparent !important;
+
+ &::before {
+ opacity: 1;
+ background: rgba($white, 0.1);
+ }
+ }
+ }
+
+ /* 确保下拉菜单与主菜单视觉上连接 */
+ .navbar-nav .nav-item.dropdown:hover .nav-link {
+ border-bottom-left-radius: 0;
+ border-bottom-right-radius: 0;
+ }
+}
+
+// =============================================
+// 移动端样式 - 使用点击展开下拉菜单
+// =============================================
+@media (max-width: 991.98px) {
+ /* 完全重置移动端导航样式,使用 Bootstrap 默认行为 */
+ .navbar-collapse {
+ background: rgba($purple, 0.98);
+ backdrop-filter: blur(10px);
+ border-top: 1px solid rgba($white, 0.1);
+ margin-top: 0.5rem;
+ padding: 0.5rem 0;
+
+ .navbar-nav {
+ .nav-item {
+ margin: 0;
+
+ .nav-link {
+ color: $navbar-fg !important;
+ padding: 1rem 1.5rem !important;
+ border-radius: 0;
+ transition: all 0.2s ease;
+ display: flex;
+ justify-content: space-between;
+ align-items: center;
+
+ &:hover {
+ color: $light-orange !important;
+ background: rgba($white, 0.1);
+ }
+
+ &.active {
+ color: $light-orange !important;
+ background: rgba($light-orange, 0.1);
+ font-weight: 600;
+ }
+ }
+
+ /* 下拉菜单项样式 */
+ &.dropdown {
+ .dropdown-toggle::after {
+ transition: transform 0.3s ease;
+ }
+
+ &.show {
+ .dropdown-toggle {
+ color: $light-orange !important;
+ background: rgba($white, 0.15);
+
+ &::after {
+ transform: rotate(-180deg);
+ }
+ }
+ }
+
+ .dropdown-menu {
+ background: rgba(darken($purple, 5%), 0.95) !important;
+ border: none;
+ border-radius: 0;
+ padding: 0;
+ margin: 0;
+ position: static;
+ float: none;
+ display: none;
+
+ &.show {
+ display: block !important;
+ }
+ }
+ }
+ }
+ }
+ }
+
+ /* 移动端下拉菜单项 */
+ .dropdown-item {
+ color: $navbar-fg !important;
+ padding: 0.875rem 1.5rem 0.875rem 2.5rem !important;
+ border-radius: 0;
+ transition: all 0.2s ease;
+
+ &:hover, &:focus {
+ color: $light-orange !important;
+ background: rgba($white, 0.1) !important;
+ transform: none;
+ }
+
+ &.active {
+ color: $light-orange !important;
+ background: rgba($light-orange, 0.1) !important;
+ font-weight: 600;
+ }
+ }
+
+ /* 移动端导航栏折叠按钮 */
+ .navbar-toggler {
+ border: 1px solid rgba($white, 0.2);
+ padding: 0.5rem 0.75rem;
+
+ &:focus {
+ box-shadow: 0 0 0 0.2rem rgba($light-orange, 0.25);
+ }
+
+ .navbar-toggler-icon {
+ background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.8%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
+ }
+ }
+
+ /* 禁用桌面端的悬停效果 */
+ .navbar-nav .nav-item .nav-link::before {
+ display: none;
+ }
+
+ .navbar-nav .nav-item.dropdown:hover .dropdown-menu {
+ display: none !important;
+ }
+}
+
+// =============================================
+// 通用样式
+// =============================================
+
+/* 导航栏整体样式 */
+.navbar {
+ backdrop-filter: blur(10px);
+ background: rgba($purple, 0.95) !important;
+ border-bottom: 1px solid rgba($white, 0.1);
+}
+
+/* 为有下拉菜单的导航项添加视觉指示 */
+.navbar-nav .nav-item.dropdown > .nav-link::after {
+ display: inline-block;
+ margin-left: 0.255em;
+ vertical-align: 0.255em;
+ content: "";
+ border-top: 0.3em solid;
+ border-right: 0.3em solid transparent;
+ border-bottom: 0;
+ border-left: 0.3em solid transparent;
+}
+
+/* 确保 Bootstrap 的 JavaScript 交互正常工作 */
+.navbar-nav .dropdown-toggle::after {
+ display: inline-block !important;
+}
+
+/* 修复移动端点击事件 */
+.navbar-nav .nav-item.dropdown .nav-link {
+ cursor: pointer;
+}
diff --git a/_extensions/drwater/dwms/partials/after-body.tex b/_extensions/drwater/dwms/partials/after-body.tex
new file mode 100644
index 0000000..e69de29
diff --git a/_extensions/drwater/dwms/partials/before-body.tex b/_extensions/drwater/dwms/partials/before-body.tex
new file mode 100644
index 0000000..577d5aa
--- /dev/null
+++ b/_extensions/drwater/dwms/partials/before-body.tex
@@ -0,0 +1,35 @@
+$-- Implements the frontmatter, title page, and abstract.
+
+% for some reason this does not work in header
+\renewcommand{\abstractname}{Abstract.}
+
+% add the short title to the fancy header
+$if(shorttitle)$
+\fancyhead[R]{$shorttitle$}
+$endif$
+$if(shortauthors)$
+\fancyhead[L]{$shortauthors$}
+$endif$
+
+$if(has-frontmatter)$
+\frontmatter
+$endif$
+$if(title)$
+\maketitle
+%\noindent \rule{\linewidth}{.5pt}
+$if(abstract)$
+\begin{abstract}
+$abstract$
+\end{abstract}
+$if(keywords)$
+\begin{keywords}
+\def\sep{;\ }
+$for(keywords/allbutlast)$$keywords$\sep $endfor$
+$for(keywords/last)$$keywords$$endfor$
+\end{keywords}
+$endif$
+$endif$
+%\noindent \rule{\linewidth}{.5pt}
+$endif$
+
+
diff --git a/_extensions/drwater/dwms/partials/title.tex b/_extensions/drwater/dwms/partials/title.tex
new file mode 100644
index 0000000..4d7473d
--- /dev/null
+++ b/_extensions/drwater/dwms/partials/title.tex
@@ -0,0 +1,58 @@
+$if(title)$
+\title{$title$$if(thanks)$\thanks{$thanks$}$endif$}
+$endif$
+$if(subtitle)$
+\usepackage{etoolbox}
+\makeatletter
+\providecommand{\subtitle}[1]{% add subtitle to \maketitle
+ \apptocmd{\@title}{\par {\large\sffamily\bfseries #1 \par}}{}{}
+}
+\makeatother
+\subtitle{$subtitle$}
+$endif$
+$-- This supports Quarto's authors normalization
+\author{$for(authors)$\footnotesize $it.name.literal$$sep$ \and $endfor$}
+\date{$date$}
+$if(isSM)$
+\let\oldsection\section
+\renewcommand{\section}{\clearpage\oldsection}
+$if(newpagesubsection)$
+\let\oldsubsection\subsection
+\renewcommand{\subsection}{\clearpage\oldsubsection}
+$endif$
+\renewcommand{\thetable}{S\arabic{table}}
+\renewcommand{\thefigure}{S\arabic{figure}}
+\renewcommand{\theequation}{S\arabic{equation}}
+\renewcommand{\figurename}{Figure}
+\renewcommand{\tablename}{Table}
+\usepackage{titlesec}
+\newcommand{\sectionbreak}{\clearpage}
+$endif$
+$if(isRN)$
+\renewcommand{\thetable}{R\arabic{table}}
+\renewcommand{\thefigure}{R\arabic{figure}}
+\renewcommand{\theequation}{R\arabic{equation}}
+\renewcommand{\figurename}{Figure}
+\renewcommand{\tablename}{Table}
+\usepackage{titlesec}
+\newcommand{\sectionbreak}{\clearpage}
+$endif$
+$if(endfloat)$
+\usepackage{endfloat}
+\renewcommand{\efloatseparator}{\vspace{\floatsep}}
+\DeclareDelayedFloatFlavor{sidewaystable}{table}
+\DeclareDelayedFloatFlavor{sidewaysfigure}{figure}
+\DeclareDelayedFloatFlavor{landscape}{table}
+
+\let\normallongtable=\longtable
+\renewcommand{\longtable}{\clearpage\normallongtable}
+
+\DeclareDelayedFloatFlavour*{longtable}{table}
+
+$endif$
+$if(linenumber)$
+\linenumbers
+$endif$
+$if(doublespacing)$
+\doublespacing
+$endif$
diff --git a/_extensions/drwater/dwsd/.gitignore b/_extensions/drwater/dwsd/.gitignore
new file mode 100644
index 0000000..7708a1d
--- /dev/null
+++ b/_extensions/drwater/dwsd/.gitignore
@@ -0,0 +1,3 @@
+*_files
+*.html
+/*.png
diff --git a/_extensions/drwater/dwsd/_extension.yml b/_extensions/drwater/dwsd/_extension.yml
new file mode 100644
index 0000000..bca6464
--- /dev/null
+++ b/_extensions/drwater/dwsd/_extension.yml
@@ -0,0 +1,21 @@
+title: revealjs format for drwater
+author: Ming Su
+version: 1.0.0
+quarto-required: ">=1.3.0"
+contributes:
+ formats:
+ revealjs:
+ theme: [default, _extensions/drwater/dwsd/inst/dwsd.scss]
+ css: _extensions/drwater/dwsd/inst/dwsd.css
+ slide-number: true
+ logo: _extensions/drwater/dwsd/inst/rceeslogo.svg
+ include-after-body: _extensions/drwater/dwsd/inst/autoscale.js
+ chalkboard:
+ buttons: true
+ preview-links: auto
+ toc: true
+ toc-depth: 1
+ pointer:
+ key: "p"
+ color: "#FF0000"
+ pointerSize: 32
diff --git a/_extensions/drwater/dwsd/inst/autoscale.js b/_extensions/drwater/dwsd/inst/autoscale.js
new file mode 100644
index 0000000..d6062c1
--- /dev/null
+++ b/_extensions/drwater/dwsd/inst/autoscale.js
@@ -0,0 +1,17 @@
+
diff --git a/_extensions/drwater/dwsd/inst/drwater-green0.svg b/_extensions/drwater/dwsd/inst/drwater-green0.svg
new file mode 100644
index 0000000..00fe227
--- /dev/null
+++ b/_extensions/drwater/dwsd/inst/drwater-green0.svg
@@ -0,0 +1,13 @@
+
+
diff --git a/_extensions/drwater/dwsd/inst/drwater.css b/_extensions/drwater/dwsd/inst/drwater.css
new file mode 100755
index 0000000..0bbdcff
--- /dev/null
+++ b/_extensions/drwater/dwsd/inst/drwater.css
@@ -0,0 +1,109 @@
+.udot {
+ text-decoration-line: underline;
+ text-decoration-color: rgb(50, 50, 50);
+ text-decoration-style: dashed;
+ text-decoration-thickness: 1px;
+}
+
+.good {
+ background-color: forestgreen;
+ color: lightyellow;
+}
+
+.bad {
+ background-color: orangered;
+ color: lightyellow;
+}
+
+.del {
+ text-decoration-line: line-through;
+ text-decoration-color: rgb(222 13 13);
+ text-decoration-style: initial;
+ text-decoration-thickness: 1.5px;
+}
+
+
+.todo {
+ background-color: darkorange;
+ color: lightyellow;
+}
+
+.com {
+ background-color: #0025ff;
+ font-weight: bold;
+ color: lightyellow;
+}
+
+.add {
+ text-decoration-line: underline;
+ text-decoration-color: rgb(222 13 13);
+ background-color: violet;
+ text-decoration-style: initial;
+ text-decoration-thickness: 2px;
+}
+
+
+del {
+ text-decoration-line: line-through;
+ text-decoration-color: rgb(222 13 13);
+ text-decoration-style: initial;
+ text-decoration-thickness: 1.0px;
+}
+
+
+ins {
+ text-decoration-color: rgb(222 93 93);
+ background-color: violet;
+ text-decoration-style: initial;
+ text-decoration-thickness: 2px;
+}
+
+.clab {
+ background-color: rgb(255, 245, 240);
+}
+
+.rem {
+ background-color: darkorange;
+ color: lightyellow;
+ text-decoration-thickness: 2px;
+}
+
+
+#criticnav {
+ position: fixed;
+ z-index: 1100;
+ top: 0;
+ right: 0;
+ width: 120px;
+ border-bottom: solid 1px #ffffff;
+ margin: 0;
+ padding: 10;
+ background-color: rgb(143 38 38 / 95%);
+ color: #ffffff;
+ font-size: 12px;
+ font-family: "Helvetica Neue", helvetica, arial, sans-serif !important
+}
+
+#criticnav ul {
+ list-style-type: none;
+ width: 90%;
+ margin: 0 auto;
+ padding: 0
+}
+
+#criticnav ul li {
+ display: block;
+ width: 100px;
+ min-width: 80px;
+ text-align: center;
+ padding: 5px 0 3px !important;
+ margin: 5px 2px !important;
+ line-height: 1em;
+ float: center;
+ text-transform: uppercase;
+ cursor: pointer;
+ border-radius: 20px;
+ border: 3px solid rgba(255,255,255,0);
+ color: #fff !important
+}
+
diff --git a/_extensions/drwater/dwsd/inst/drwater.scss b/_extensions/drwater/dwsd/inst/drwater.scss
new file mode 100644
index 0000000..93672cf
--- /dev/null
+++ b/_extensions/drwater/dwsd/inst/drwater.scss
@@ -0,0 +1,415 @@
+/*-- scss:defaults --*/
+
+$theme: "drwater" !default;
+
+//
+// Color system
+//
+
+$white: #ffffff !default;
+$gray-100: #f8f9fa !default;
+$gray-200: #e9ecef !default;
+$gray-300: #dee2e6 !default;
+$gray-400: #ced4da !default;
+$gray-500: #adb5bd !default;
+$gray-600: #868e96 !default;
+$gray-700: #495057 !default;
+$gray-800: #373a3c !default;
+$gray-900: #212529 !default;
+$black: #000000 !default;
+
+$blue: #2780e3 !default;
+$indigo: #6610f2 !default;
+$purple: #170c3a !default;
+$pink: #a52c60 !default;
+$red: #cf4446 !default;
+$orange: #ee6a24 !default;
+$light-orange: #fb9e07 !default;
+$yellow: #f6d645 !default;
+$green: #118230 !default;
+$teal: #20c997 !default;
+$cyan: #3093cf !default;
+
+$primary: $pink !default;
+$secondary: $gray-700 !default;
+$success: $green !default;
+$info: $cyan !default;
+$warning: $orange !default;
+$danger: $red !default;
+$light: $gray-400 !default;
+$dark: $black !default;
+
+// Fonts
+
+$font-family-sans-serif: "Libre Franklin" !default;
+
+$headings-font-family: "Jost" !default;
+$headings-font-weight: 600 !default;
+
+$navbar-font-family: "Jost" !default;
+$toc-font-family: "Jost" !default;
+$footer-font-family: "Jost" !default;
+
+// Body
+$body-color: $gray-900 !default;
+
+// Links
+$link-color: $orange !default;
+$link-decoration: none !default;
+$link-hover-color: $red !default;
+$link-hover-decoration: underline !default;
+
+// Inline code
+$code-bg: $gray-200 !default;
+$code-color: $gray-900 !default;
+
+// Code copy
+$btn-code-copy-color-active: $orange !default;
+
+// TOC
+$toc-color: $orange;
+$toc-font-size: 1em;
+
+// Navbar
+$navbar-bg: $purple !default;
+$navbar-fg: $white !default;
+$navbar-hl: $light-orange !default;
+
+// Footer
+$footer-bg: $gray-900 !default;
+$footer-fg: $gray-300 !default;
+
+/*-- scss:rules --*/
+
+$web-font-path: "https://fonts.googleapis.com/css2?family=Jost:ital,wght@0,100..900;1,100..900&family=Libre+Franklin:ital,wght@0,100..900;1,100..900&display=swap" !default;
+
+@if $web-font-path {
+ @import url($web-font-path);
+}
+
+body {
+ -webkit-font-smoothing: antialiased;
+}
+
+/* Logo 悬停效果 */
+.navbar-brand img {
+ transition: all 0.3s ease;
+ filter: brightness(0) invert(1);
+
+ &:hover {
+ filter: brightness(0) invert(0.55) sepia(1) saturate(2000%) hue-rotate(-8deg) brightness(1.05) contrast(1.2);
+ transform: scale(1.05);
+ }
+}
+
+// =============================================
+// 桌面端样式 - 使用悬停展开下拉菜单
+// =============================================
+@media (min-width: 992px) {
+ /* 导航栏主菜单项样式 */
+ .navbar-nav .nav-item {
+ position: relative;
+ margin: 0 0.2rem;
+
+ .nav-link {
+ position: relative;
+ color: $navbar-fg !important;
+ font-weight: 500;
+ padding: 0.75rem 1rem !important;
+ border-radius: 8px;
+ transition: all 0.3s ease;
+ z-index: 1;
+
+ /* 玻璃效果背景 */
+ &::before {
+ content: '';
+ position: absolute;
+ top: 0;
+ left: 0;
+ right: 0;
+ bottom: 0;
+ background: rgba($white, 0.1);
+ backdrop-filter: blur(10px);
+ border-radius: 8px;
+ opacity: 0;
+ transition: all 0.3s ease;
+ z-index: -1;
+ border: 1px solid rgba($white, 0.2);
+ }
+
+ &:hover {
+ color: $light-orange !important;
+ transform: translateY(-2px);
+
+ &::before {
+ opacity: 1;
+ background: rgba($white, 0.15);
+ backdrop-filter: blur(15px);
+ box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
+ }
+ }
+
+ /* 激活状态 */
+ &.active {
+ color: $light-orange !important;
+ font-weight: 600;
+
+ &::before {
+ opacity: 1;
+ background: rgba($light-orange, 0.2);
+ backdrop-filter: blur(15px);
+ border: 1px solid rgba($light-orange, 0.3);
+ }
+ }
+ }
+ }
+
+ /* 有下拉菜单的主菜单项特殊样式 */
+ .navbar-nav .nav-item.dropdown {
+ .nav-link {
+ padding-right: 2rem !important;
+
+ &::after {
+ position: absolute;
+ right: 1rem;
+ top: 50%;
+ transform: translateY(-50%);
+ transition: all 0.3s ease;
+ }
+ }
+
+ &:hover .nav-link::before {
+ opacity: 1;
+ background: rgba($white, 0.2);
+ backdrop-filter: blur(20px);
+ border-bottom-left-radius: 0;
+ border-bottom-right-radius: 0;
+ }
+
+ &:hover .nav-link::after {
+ transform: translateY(-50%) rotate(-180deg);
+ border-top-color: $light-orange;
+ }
+ }
+
+ /* 桌面端下拉菜单悬停效果 */
+ .navbar-nav .nav-item.dropdown:hover .dropdown-menu {
+ display: block !important;
+ opacity: 1 !important;
+ visibility: visible !important;
+ transform: translateY(0) !important;
+ }
+
+ .dropdown-menu {
+ display: block;
+ opacity: 0;
+ visibility: hidden;
+ transform: translateY(-10px);
+ transition: all 0.3s ease;
+ background: rgba($purple, 0.98) !important;
+ backdrop-filter: blur(20px);
+ border: 1px solid rgba($white, 0.1);
+ border-top: none;
+ border-radius: 0 0 8px 8px;
+ box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
+ margin-top: -1px;
+ padding: 0.5rem 0;
+
+ &.show {
+ display: block;
+ opacity: 1;
+ visibility: visible;
+ transform: translateY(0);
+ }
+ }
+
+ .dropdown-item {
+ color: $white !important;
+ font-family: $navbar-font-family;
+ padding: 0.75rem 1.5rem;
+ transition: all 0.2s ease;
+ position: relative;
+
+ /* 下拉菜单项的玻璃效果 */
+ &::before {
+ content: '';
+ position: absolute;
+ top: 0;
+ left: 0;
+ right: 0;
+ bottom: 0;
+ background: rgba($white, 0.05);
+ border-radius: 4px;
+ opacity: 0;
+ transition: all 0.2s ease;
+ z-index: -1;
+ }
+
+ &:hover, &:focus {
+ color: $light-orange !important;
+ transform: translateX(5px);
+ background: transparent !important;
+
+ &::before {
+ opacity: 1;
+ background: rgba($white, 0.1);
+ }
+ }
+ }
+
+ /* 确保下拉菜单与主菜单视觉上连接 */
+ .navbar-nav .nav-item.dropdown:hover .nav-link {
+ border-bottom-left-radius: 0;
+ border-bottom-right-radius: 0;
+ }
+}
+
+// =============================================
+// 移动端样式 - 使用点击展开下拉菜单
+// =============================================
+@media (max-width: 991.98px) {
+ /* 完全重置移动端导航样式,使用 Bootstrap 默认行为 */
+ .navbar-collapse {
+ background: rgba($purple, 0.98);
+ backdrop-filter: blur(10px);
+ border-top: 1px solid rgba($white, 0.1);
+ margin-top: 0.5rem;
+ padding: 0.5rem 0;
+
+ .navbar-nav {
+ .nav-item {
+ margin: 0;
+
+ .nav-link {
+ color: $navbar-fg !important;
+ padding: 1rem 1.5rem !important;
+ border-radius: 0;
+ transition: all 0.2s ease;
+ display: flex;
+ justify-content: space-between;
+ align-items: center;
+
+ &:hover {
+ color: $light-orange !important;
+ background: rgba($white, 0.1);
+ }
+
+ &.active {
+ color: $light-orange !important;
+ background: rgba($light-orange, 0.1);
+ font-weight: 600;
+ }
+ }
+
+ /* 下拉菜单项样式 */
+ &.dropdown {
+ .dropdown-toggle::after {
+ transition: transform 0.3s ease;
+ }
+
+ &.show {
+ .dropdown-toggle {
+ color: $light-orange !important;
+ background: rgba($white, 0.15);
+
+ &::after {
+ transform: rotate(-180deg);
+ }
+ }
+ }
+
+ .dropdown-menu {
+ background: rgba(darken($purple, 5%), 0.95) !important;
+ border: none;
+ border-radius: 0;
+ padding: 0;
+ margin: 0;
+ position: static;
+ float: none;
+ display: none;
+
+ &.show {
+ display: block !important;
+ }
+ }
+ }
+ }
+ }
+ }
+
+ /* 移动端下拉菜单项 */
+ .dropdown-item {
+ color: $navbar-fg !important;
+ padding: 0.875rem 1.5rem 0.875rem 2.5rem !important;
+ border-radius: 0;
+ transition: all 0.2s ease;
+
+ &:hover, &:focus {
+ color: $light-orange !important;
+ background: rgba($white, 0.1) !important;
+ transform: none;
+ }
+
+ &.active {
+ color: $light-orange !important;
+ background: rgba($light-orange, 0.1) !important;
+ font-weight: 600;
+ }
+ }
+
+ /* 移动端导航栏折叠按钮 */
+ .navbar-toggler {
+ border: 1px solid rgba($white, 0.2);
+ padding: 0.5rem 0.75rem;
+
+ &:focus {
+ box-shadow: 0 0 0 0.2rem rgba($light-orange, 0.25);
+ }
+
+ .navbar-toggler-icon {
+ background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.8%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
+ }
+ }
+
+ /* 禁用桌面端的悬停效果 */
+ .navbar-nav .nav-item .nav-link::before {
+ display: none;
+ }
+
+ .navbar-nav .nav-item.dropdown:hover .dropdown-menu {
+ display: none !important;
+ }
+}
+
+// =============================================
+// 通用样式
+// =============================================
+
+/* 导航栏整体样式 */
+.navbar {
+ backdrop-filter: blur(10px);
+ background: rgba($purple, 0.95) !important;
+ border-bottom: 1px solid rgba($white, 0.1);
+}
+
+/* 为有下拉菜单的导航项添加视觉指示 */
+.navbar-nav .nav-item.dropdown > .nav-link::after {
+ display: inline-block;
+ margin-left: 0.255em;
+ vertical-align: 0.255em;
+ content: "";
+ border-top: 0.3em solid;
+ border-right: 0.3em solid transparent;
+ border-bottom: 0;
+ border-left: 0.3em solid transparent;
+}
+
+/* 确保 Bootstrap 的 JavaScript 交互正常工作 */
+.navbar-nav .dropdown-toggle::after {
+ display: inline-block !important;
+}
+
+/* 修复移动端点击事件 */
+.navbar-nav .nav-item.dropdown .nav-link {
+ cursor: pointer;
+}
diff --git a/_extensions/drwater/dwsd/inst/dwsd.css b/_extensions/drwater/dwsd/inst/dwsd.css
new file mode 100644
index 0000000..c237b06
--- /dev/null
+++ b/_extensions/drwater/dwsd/inst/dwsd.css
@@ -0,0 +1,478 @@
+
+
+.quarto-title-author-name {
+ font-size: var(--r-heading3-size);
+ /* color: var(--r-heading-color); */
+}
+
+.quarto-title-affiliation {
+ font-size: 1.2em;
+ /* color: var(--r-heading-color); */
+}
+
+.reveal .quarto-title-block .quarto-title-authors .quarto-title-author .quarto-title-affiliation {
+ font-size: 1.2em;
+ /* color: var(--r-heading-color); */
+ margin-top: 0px;
+ margin-bottom: 8px;
+}
+
+
+section#title-slide p.date {
+ font-size: 1.2em;
+ /* font-size: var(--r-heading3-size); */
+}
+
+section#title-slide h1.title {
+ position: relative;
+ padding-bottom: 30px; /* 留空间(可调整) */
+}
+
+/* 长细线 —— 在上 */
+section#title-slide h1.title::after {
+ content: "";
+ position: absolute;
+ left: 50%;
+ transform: translateX(-50%);
+ bottom: 0px; /* 粗线的高度,让两条底对齐 */
+ width: 360px;
+ height: 1px;
+ background-color: var(--r-heading-color);
+ opacity: 0.8;
+}
+
+/* 短粗线 —— 在下 */
+section#title-slide h1.title::before {
+ content: "";
+ position: absolute;
+ left: 50%;
+ transform: translateX(-50%);
+ bottom: 0; /* 底边紧贴标题的“底部参考线” */
+ width: 60px;
+ height: 3px;
+ background-color: var(--r-heading-color);
+ opacity: 0.8;
+}
+
+
+section#title-slide p.subtitle {
+ font-size: var(--r-heading2-size);
+ /* text-decoration: underline; */
+ color: var(--r-heading-color);
+}
+
+section#title-slide a {
+ color: var(--r-link-color);
+}
+
+.reveal .slide-number a {
+ color: #bbbbbb;
+ font-size: 10pt;
+}
+
+section#title-slide a:hover {
+ color: var(--r-link-color-hover);
+}
+
+.reveal[data-navigation-mode="linear"] .title-slide h1 {
+ font-size: var(--r-heading2-size);
+}
+
+/* 最后的TOC不显示 */
+#TOC ul li:last-child {
+ display: none !important;
+}
+
+
+/* 1) 让 TOC section 成为一个居中列容器(垂直方向可调) */
+section#TOC {
+ display: flex;
+ flex-direction: column;
+ align-items: center; /* 水平居中子内容(h2 与 ul 的容器) */
+ justify-content: flex-start;/* 若想垂直居中用 'center' */
+ padding-top: 6vh; /* 页面顶部留白,可按需调整 */
+ box-sizing: border-box;
+ height: 100%; /* 保证填满 slide 区域,方便垂直定位 */
+ text-align: center; /* 默认居中(标题) */
+}
+
+/* 2) 标题样式 - 宽度随内容自适应并居中 */
+section#TOC h2 {
+ display: inline-block; /* 宽度随文本 */
+ margin: 0 0 18px 0; /* 标题与下面线/正文的距离(可调) */
+ position: relative;
+ padding-bottom: 0; /* 不要多余的内边距 */
+ line-height: 1.1;
+}
+
+section#TOC h2:after {
+ content: "";
+ position: absolute;
+ top: 100%;
+ margin-top: 8px;
+ left: 50%;
+ transform: translateX(-50%);
+ width: 360px;
+ height: 1px;
+ background-color: var(--r-heading-color);
+ opacity: 0.8;
+}
+
+/* 粗短线 */
+section#TOC h2:before {
+ content: "";
+ position: absolute;
+ top: 100%;
+ margin-top: 5px; /* 调整这两个 margin 差值可控制细/粗线相对位置 */
+ left: 50%;
+ transform: translateX(-50%);
+ width: 60px;
+ height: 3px;
+ background-color: var(--r-heading-color);
+ opacity: 0.8;
+}
+
+
+
+/* 3) 将 nav 内部内容限制到中间 60% 宽度区域并水平居中 */
+section#TOC nav {
+ width: 100%;
+ display: flex;
+ flex-direction: column;
+ align-items: center; /* 把 ul 的容器居中 */
+}
+
+/* 4) 列表限制为中间 60% 区域,内容左对齐 */
+
+/* 默认/英文样式 */
+section#TOC ul,
+section#TOC ol {
+ width: 50%;
+ max-width: 760px;
+ min-width: 280px;
+ margin: 0;
+ padding-left: 1.0em;
+ text-align: left;
+ list-style-position: inside;
+ list-style-type: decimal; /* 英文默认使用数字 */
+ box-sizing: border-box;
+ line-height: 2.6em;
+}
+
+/* 中文样式 */
+section#TOC[lang|="zh"] ul,
+section#TOC[lang|="zh"] ol,
+html[lang|="zh"] section#TOC ul,
+html[lang|="zh"] section#TOC ol {
+ list-style-type: cjk-ideographic;
+ padding-left: 1.2em; /* 中文可能需要稍大缩进 */
+}
+
+
+/* 5) 单项样式(覆盖你之前重复的规则,确保优先级) */
+section#TOC ul li,
+section#TOC ol li {
+ font-size: var(--r-heading3-size);
+ color: var(--r-heading-color);
+ font-weight: bold;
+ margin: .35em 0;
+ word-break: break-word;
+}
+
+
+/* 链接配色 */
+section#TOC a {
+ color: var(--r-heading-color);
+ text-decoration: none;
+}
+section#TOC a:hover {
+ color: var(--r-link-color-hover);
+ text-decoration: underline;
+ /* font-size: var(--r-heading3-size); */
+}
+
+/* 6) 响应式微调(小屏幕时让列表宽度更宽占比) */
+@media (max-width: 900px) {
+ section#TOC ul,
+ section#TOC ol {
+ width: 80%;
+ }
+}
+
+
+.reveal .title-slide h1 {
+ text-align: center;
+ line-height: var(--r-heading-line-height);
+ position: relative;
+ display: inline-block;
+}
+
+/* 细长线 */
+.reveal .title-slide h1:after {
+ content: "";
+ position: absolute;
+ top: 100%;
+ margin-top: 8px;
+ left: 50%;
+ transform: translateX(-50%);
+ width: 360px;
+ height: 1px;
+ background-color: var(--r-heading-color);
+ opacity: 0.8;
+}
+
+/* 粗短线 */
+.reveal .title-slide h1:before {
+ content: "";
+ position: absolute;
+ top: 100%;
+ margin-top: 5px; /* 调整这两个 margin 差值可控制细/粗线相对位置 */
+ left: 50%;
+ transform: translateX(-50%);
+ width: 60px;
+ height: 3px;
+ background-color: var(--r-heading-color);
+ opacity: 0.8;
+}
+
+
+
+.reveal h2 {
+ text-align: left;
+ margin-top: 0px;
+ line-height: var(--r-heading-line-height);
+ width: auto;
+ position: relative; /* 关键:建立相对定位容器 */
+ display: inline-block; /* 让h2宽度自适应内容 */
+}
+
+.reveal h2:after {
+ content: "";
+ position: absolute;
+ left: 0; /* 跟随h2的左对齐 */
+ top: 100%;
+ margin-top: 8px;
+ width: 360px;
+ height: 1px;
+ background-color: var(--r-heading-color);
+ opacity: 0.8;
+}
+
+.reveal h2:before {
+ content: "";
+ position: absolute;
+ left: 0; /* 跟随h2的左对齐 */
+ top: 100%;
+ margin-top: 5px;
+ width: 60px;
+ height: 3px;
+ background-color: var(--r-heading-color);
+ opacity: 0.8;
+}
+
+
+.reveal ul {
+ list-style-type: circle;
+}
+
+li:hover {
+ font-weight: bold;
+}
+
+.reveal p:hover {
+ font-weight: bold;
+}
+
+.reveal ul li {
+ line-height: 1.2em;
+}
+
+.reveal .thank h2 {
+ font-size: var(--r-heading1-size);
+ line-height: var(--r-heading-line-height);
+}
+
+.reveal .thank {
+ text-align: center;
+}
+
+.reveal .thank h2:after {
+ content: "";
+ position: absolute;
+ left: 50%;
+ transform: translateX(-50%);
+ bottom: 0px; /* 粗线的高度,让两条底对齐 */
+ width: 360px;
+ height: 1px;
+ background-color: var(--r-heading-color);
+ opacity: 0.8;
+}
+
+/* 短粗线 —— 在下 */
+.reveal .thank h2:before {
+ content: "";
+ position: absolute;
+ left: 50%;
+ transform: translateX(-50%);
+ bottom: 0; /* 底边紧贴标题的“底部参考线” */
+ width: 60px;
+ height: 3px;
+ background-color: var(--r-heading-color);
+ opacity: 0.8;
+}
+
+
+
+.panel-tabset [role="tab"] {
+ border-bottom: 1px solid red;
+}
+
+.panel-tabset [role="tab"][aria-selected="true"] {
+ background-color: #ffdddd;
+ border-bottom: 1px solid red;
+}
+
+.white {
+ color: #ffffff;
+}
+.orange {
+ color: #e09a25;
+}
+.green {
+ color: #006e51;
+}
+.pink {
+ color: #d13076;
+}
+
+.dusty {
+ color: #ad5d5d;
+}
+
+.flame {
+ color: #ef562d;
+}
+.kale {
+ color: #5c7148;
+}
+.blue {
+ color: #0c4c8a;
+}
+.red {
+ color: #b93a32;
+}
+.clay {
+ color: #9e4624;
+}
+.bodacious {
+ color: #b76ba3;
+}
+.serenity {
+ color: #91a8d0;
+}
+
+.cognac {
+ color: #60413c;
+}
+.sangria {
+ color: #760030;
+}
+
+.alumium {
+ color: #75796a;
+}
+
+.marsala {
+ color: #964f4c;
+}
+.purple {
+ color: #702fa8;
+}
+
+.blank {
+ background-color: "Yellow";
+ width: 100%;
+ color: red;
+}
+
+.reveal .slide aside {
+ position: absolute;
+ margin: 0 auto;
+ left: 2%;
+ font-size: 0.7em;
+ text-align: end;
+ max-width: 90%;
+ width: fit-content;
+ color: gray;
+ bottom: -6%;
+}
+
+.ref {
+ position: absolute;
+ margin: 0 auto;
+ right: 2%;
+ font-size: 1em;
+ text-align: end;
+ max-width: 90%;
+ width: fit-content;
+ color: gray;
+ bottom: -6%;
+}
+
+.con {
+ position: absolute;
+ margin: 0 auto;
+ font-size: 1.4em;
+ text-align: center;
+ font-family: inherit;
+ max-width: 100%;
+ width: fit-content;
+ color: #023047;
+ bottom: -2%;
+}
+
+.center {
+ text-align: center;
+}
+
+.tiny {
+ font-size: 60%;
+}
+
+figure > figcaption {
+ margin-top: -0.5em;
+}
+
+.reveal .slide figure > figcaption,
+.reveal .slide img.stretch + p.caption,
+.reveal .slide img.r-stretch + p.caption {
+ font-size: 0.9em;
+ text-align: center;
+}
+
+.reveal strong, .reveal b {
+ font-weight: bold;
+ color: crimson;
+}
+
+.reveal pre code {
+ background-color: #554433;
+ line-height: 1.2em;
+ color: #fff;
+ /* font-size: x-large; */
+}
+
+.reveal pre code:hover{
+ font-size: x-large;
+ line-height: 120%;
+}
+
+.reveal div.sourceCode pre code {
+ background-color: #002233;
+ min-height: 100%;
+ /* font-size: x-large; */
+}
+
+.reveal div.sourceCode pre code:hover {
+ font-size: x-large;
+}
diff --git a/_extensions/drwater/dwsd/inst/dwsd.scss b/_extensions/drwater/dwsd/inst/dwsd.scss
new file mode 100644
index 0000000..b649947
--- /dev/null
+++ b/_extensions/drwater/dwsd/inst/dwsd.scss
@@ -0,0 +1,76 @@
+/*-- scss:defaults --*/
+
+/* Modified version of the metropolis theme ported into Quarto by Patrick Schwartz */
+
+// fonts
+@import url("https://fonts.googleapis.com/css?family=Fira+Sans:300,300i,400,400i,500,500i,700,700i");
+@import url("https://fonts.googleapis.com/css?family=Fira+Code:300,300i,400,400i,500,500i,700,700i");
+@import url("https://fonts.googleapis.com/css?family=Roboto+Mono|JetBrains+Mono&display=swap");
+@import url("https://fonts.googleapis.com/css?family=Roboto:300,400,500,700&display=swap");
+
+$font-family-sans-serif: "Fira Sans", "Roboto", "Droid Serif", serif !default;
+$font-family-monospace: "Fira Code", "JetBrains Mono", monospace;
+$presentation-font-size-root: 32px;
+$presentation-line-height: 1.5em;
+$presentation-heading-font-weight: 400;
+
+// colors
+$body-bg: #fafafa !default;
+$body-color: #fff !default;
+// $link-color: #EB811B !default;
+$selection-bg: #26351c;
+
+/* #2A6465 */
+
+// headings
+// $presentation-heading-font: "Palatino Linotype", "Book Antiqua", Palatino,
+// FreeSerif, serif !default;
+// $presentation-heading-color: #383d3d !default;
+
+/*-- scss:rules --*/
+
+:root {
+ --r-background-color: #fff;
+ --r-main-font: Source Sans Pro, simhei, microsoft yahei;
+ --r-main-font-size: 32px;
+ --r-main-color: #434343; // 正文颜色,松烟墨:#434343 乌墨:#1A1A1A
+ --r-block-margin: 12px;
+ --r-heading-margin: 0 0 12px 0;
+ --r-heading-font: Source Sans Pro, simhei, microsoft yahei;
+ --r-heading-color: #0c4c8a; //标题颜色:深青蓝色:296364;海军蓝或藏青色:0c4c8a;深青色:006D6D;钻蓝色:0F52BA;酒红:800020
+ --r-heading-line-height: 1.2em;
+ --r-heading-letter-spacing: normal;
+ --r-heading-text-transform: none;
+ --r-heading-text-shadow: none;
+ --r-heading-font-weight: 900;
+ --r-heading1-text-shadow: none;
+ --r-heading1-size: 2.5em;
+ --r-heading2-size: 1.6em;
+ --r-heading3-size: 1.3em;
+ --r-heading4-size: 1em;
+ --r-code-font: SFMono-Regular, Menlo, Monaco, Consolas, Liberation Mono,
+ Courier New, monospace;
+ --r-link-color: #ef562d;
+ --r-link-color-dark: #ef562d;
+ --r-link-color-hover: #d13076;
+ --r-selection-background-color: #98bdef;
+ --r-selection-color: #fff;
+ --quarto-hl-fu-color: #c53800;
+}
+
+// 设置背景图片
+$background-image: url('');
+$background-position: center center;
+$background-size: 40%;
+$background-repeat: no-repeat;
+$background-opacity: 0.04;
+
+// 应用到 reveal.js
+.reveal .backgrounds {
+ background-image: $background-image;
+ background-position: $background-position;
+ background-size: $background-size;
+ background-repeat: $background-repeat;
+ opacity: $background-opacity;
+}
+
diff --git a/_extensions/drwater/dwsd/inst/rceeslogo.pdf b/_extensions/drwater/dwsd/inst/rceeslogo.pdf
new file mode 100644
index 0000000..51d1a45
Binary files /dev/null and b/_extensions/drwater/dwsd/inst/rceeslogo.pdf differ
diff --git a/_extensions/drwater/dwsd/inst/rceeslogo.svg b/_extensions/drwater/dwsd/inst/rceeslogo.svg
new file mode 100644
index 0000000..44431ff
--- /dev/null
+++ b/_extensions/drwater/dwsd/inst/rceeslogo.svg
@@ -0,0 +1,5 @@
+
+
diff --git a/_extensions/drwater/dwsd/inst/rceeslonglogo.pdf b/_extensions/drwater/dwsd/inst/rceeslonglogo.pdf
new file mode 100644
index 0000000..50017f7
Binary files /dev/null and b/_extensions/drwater/dwsd/inst/rceeslonglogo.pdf differ
diff --git a/_extensions/drwater/dwsd/inst/rceeslonglogo.svg b/_extensions/drwater/dwsd/inst/rceeslonglogo.svg
new file mode 100644
index 0000000..013b69d
--- /dev/null
+++ b/_extensions/drwater/dwsd/inst/rceeslonglogo.svg
@@ -0,0 +1,352 @@
+
+
diff --git a/_extensions/drwater/dwsd/inst/ucaslogo.png b/_extensions/drwater/dwsd/inst/ucaslogo.png
new file mode 100644
index 0000000..6dabf3f
Binary files /dev/null and b/_extensions/drwater/dwsd/inst/ucaslogo.png differ
diff --git a/_extensions/drwater/dwsd/template.qmd b/_extensions/drwater/dwsd/template.qmd
new file mode 100644
index 0000000..e96fffb
--- /dev/null
+++ b/_extensions/drwater/dwsd/template.qmd
@@ -0,0 +1,35 @@
+---
+title: "〇、R语言实践前篇"
+subtitle: 《区域水环境污染数据分析实践》 Data analysis practice of regional water environment pollution
+author: 苏命、王为东 中国科学院大学资源与环境学院 中国科学院生态环境研究中心
+date: today
+lang: zh
+format:
+ dwsd-revealjs: default
+---
+
+```{r}
+#| include: false
+#| cache: false
+lang <- "cn"
+require(tidyverse)
+knitr::opts_chunk$set(echo = TRUE)
+```
+
+## R语言实践部分课程简介
+
+**接下来的课程由我来带着大家一起学习、实践基于R语言的数据分析。**
+
+### 自我介绍
+
+- 苏命:来自中国科学院生态环境研究中心
+- 主要从事**水源水质水生态**方面的研究
+
+
+
+
+
+## 欢迎讨论!{.center}
+
+
+`r rmdify::slideend(wechat = FALSE, type = "public", tel = FALSE, thislink = "../")`
diff --git a/_extensions/drwater/embedpdf/_extension.yml b/_extensions/drwater/embedpdf/_extension.yml
new file mode 100644
index 0000000..49b990e
--- /dev/null
+++ b/_extensions/drwater/embedpdf/_extension.yml
@@ -0,0 +1,8 @@
+title: embedpdf
+author: Jeffrey Girard
+version: 0.5.0
+quarto-required: ">=1.3.0"
+contributes:
+ shortcodes:
+ - embedpdf.lua
+
diff --git a/_extensions/drwater/embedpdf/embedpdf.lua b/_extensions/drwater/embedpdf/embedpdf.lua
new file mode 100644
index 0000000..178f74f
--- /dev/null
+++ b/_extensions/drwater/embedpdf/embedpdf.lua
@@ -0,0 +1,106 @@
+-- simple HTML escaper for text nodes
+local function html_escape(s)
+ s = tostring(s or "")
+ s = s:gsub("&", "&")
+ :gsub("<", "<")
+ :gsub(">", ">")
+ :gsub('"', """)
+ :gsub("'", "'")
+ return s
+end
+
+function pdf(args, kwargs)
+ local data = pandoc.utils.stringify(args[1]) or pandoc.utils.stringify(kwargs['file'])
+ local width = pandoc.utils.stringify(kwargs['width'])
+ local height = pandoc.utils.stringify(kwargs['height'])
+ local border = pandoc.utils.stringify(kwargs['border'])
+ local class = pandoc.utils.stringify(kwargs['class'])
+ local button = pandoc.utils.stringify(kwargs['button'])
+ local image = pandoc.utils.stringify(kwargs['image'])
+ local image_force = pandoc.utils.stringify(kwargs['image_force'])
+ local image_width = pandoc.utils.stringify(kwargs['image_width'])
+ local image_height = pandoc.utils.stringify(kwargs['image_height'])
+ local image_border = pandoc.utils.stringify(kwargs['image_border'])
+ local image_class = pandoc.utils.stringify(kwargs['image_class'])
+
+ if width ~= '' then
+ width = ' width="' .. width .. '"'
+ end
+
+ if height ~= '' then
+ height = ' height="' .. height .. '"'
+ end
+
+ if border ~= '' then
+ border = ' border="' .. border .. '"'
+ end
+
+ if class ~= '' then
+ class = ' class="' .. class .. '"'
+ end
+
+ if image_width ~= '' then
+ image_width = ' width="' .. image_width .. '"'
+ end
+
+ if image_height ~= '' then
+ image_height = ' height="' .. image_height .. '"'
+ end
+
+ if image_border ~= '' then
+ image_border = ' border="' .. image_border .. '"'
+ end
+
+ if image_class ~= '' then
+ image_class = ' class="' .. image_class .. '"'
+ end
+
+ local button_html = ""
+ if button ~= '' then
+ button_html =
+ " " ..
+ html_escape(button) ..
+ ""
+ end
+
+ if quarto.doc.isFormat("html:js") then
+ local html = ""
+
+ if image_force == 'TRUE' then
+ -- image only, linked to pdf
+ html = '' ..
+ '' ..
+ ''
+ elseif image ~= '' then
+ -- pdf object with image fallback
+ html = ''
+ else
+ -- pdf object with text fallback
+ html = ''
+ end
+
+ -- wrap main content + optional button
+ if button_html ~= "" then
+ html = "