Bläddra i källkod

switch from gulp to vite to build, add types for reveal.js config

Hakim El Hattab 1 år sedan
förälder
incheckning
a89af36022
90 ändrade filer med 10624 tillägg och 1041 borttagningar
  1. 30 0
      css/reset.css
  2. 8 9
      css/theme/beige.scss
  3. 6 10
      css/theme/black-contrast.scss
  4. 7 11
      css/theme/black.scss
  5. 25 18
      css/theme/blood.scss
  6. 3 3
      css/theme/dracula.scss
  7. 3 3
      css/theme/league.scss
  8. 18 21
      css/theme/moon.scss
  9. 5 9
      css/theme/night.scss
  10. 8 12
      css/theme/serif.scss
  11. 6 11
      css/theme/simple.scss
  12. 6 12
      css/theme/sky.scss
  13. 20 26
      css/theme/solarized.scss
  14. 6 10
      css/theme/white-contrast.scss
  15. 6 10
      css/theme/white.scss
  16. 9 3
      demo.html
  17. 84 0
      dist/config.d.ts
  18. 12 0
      dist/index.d.ts
  19. 0 0
      dist/plugin/highlight.js
  20. 1078 0
      dist/plugin/highlight.mjs
  21. 0 0
      dist/plugin/highlight/monokai.css
  22. 0 0
      dist/plugin/highlight/zenburn.css
  23. 0 0
      dist/plugin/markdown.js
  24. 1738 0
      dist/plugin/markdown.mjs
  25. 0 0
      dist/plugin/math.js
  26. 119 0
      dist/plugin/math.mjs
  27. 897 0
      dist/plugin/notes.js
  28. 2548 0
      dist/plugin/notes.mjs
  29. 6 0
      dist/plugin/search.js
  30. 83 0
      dist/plugin/search.mjs
  31. 8 0
      dist/plugin/zoom.js
  32. 102 0
      dist/plugin/zoom.mjs
  33. 1 30
      dist/reset.css
  34. 0 0
      dist/reveal.css
  35. 3 0
      dist/reveal.d.mts
  36. 1756 0
      dist/reveal.mjs
  37. 12 6
      dist/theme/black.css
  38. 0 360
      dist/theme/white_contrast_compact_verbatim_headers.css
  39. 20 8
      index.html
  40. 0 333
      js/config.js
  41. 651 0
      js/config.ts
  42. 8 3
      js/index.ts
  43. 1 1
      js/reveal.js
  44. 804 115
      package-lock.json
  45. 44 5
      package.json
  46. 0 0
      plugin/highlight/index.js
  47. 22 0
      plugin/highlight/vite.config.ts
  48. 0 0
      plugin/markdown/index.js
  49. 0 0
      plugin/markdown/markdown.esm.js
  50. 0 0
      plugin/markdown/markdown.js
  51. 22 0
      plugin/markdown/vite.config.ts
  52. 0 0
      plugin/math/index.js
  53. 22 0
      plugin/math/vite.config.ts
  54. 1 1
      plugin/notes/index.js
  55. 0 0
      plugin/notes/notes.esm.js
  56. 0 0
      plugin/notes/notes.js
  57. 22 0
      plugin/notes/vite.config.ts
  58. 0 0
      plugin/search/index.js
  59. 22 0
      plugin/search/vite.config.ts
  60. 0 0
      plugin/zoom/index.js
  61. 22 0
      plugin/zoom/vite.config.ts
  62. 0 3
      plugin/zoom/zoom.esm.js
  63. 0 3
      plugin/zoom/zoom.js
  64. 71 0
      public/plugin/highlight/monokai.css
  65. 80 0
      public/plugin/highlight/zenburn.css
  66. 2 0
      public/theme/fonts/league-gothic/LICENSE
  67. 10 0
      public/theme/fonts/league-gothic/league-gothic.css
  68. BIN
      public/theme/fonts/league-gothic/league-gothic.eot
  69. BIN
      public/theme/fonts/league-gothic/league-gothic.ttf
  70. BIN
      public/theme/fonts/league-gothic/league-gothic.woff
  71. 45 0
      public/theme/fonts/source-sans-pro/LICENSE
  72. BIN
      public/theme/fonts/source-sans-pro/source-sans-pro-italic.eot
  73. BIN
      public/theme/fonts/source-sans-pro/source-sans-pro-italic.ttf
  74. BIN
      public/theme/fonts/source-sans-pro/source-sans-pro-italic.woff
  75. BIN
      public/theme/fonts/source-sans-pro/source-sans-pro-regular.eot
  76. BIN
      public/theme/fonts/source-sans-pro/source-sans-pro-regular.ttf
  77. BIN
      public/theme/fonts/source-sans-pro/source-sans-pro-regular.woff
  78. BIN
      public/theme/fonts/source-sans-pro/source-sans-pro-semibold.eot
  79. BIN
      public/theme/fonts/source-sans-pro/source-sans-pro-semibold.ttf
  80. BIN
      public/theme/fonts/source-sans-pro/source-sans-pro-semibold.woff
  81. BIN
      public/theme/fonts/source-sans-pro/source-sans-pro-semibolditalic.eot
  82. BIN
      public/theme/fonts/source-sans-pro/source-sans-pro-semibolditalic.ttf
  83. BIN
      public/theme/fonts/source-sans-pro/source-sans-pro-semibolditalic.woff
  84. 39 0
      public/theme/fonts/source-sans-pro/source-sans-pro.css
  85. 3 3
      test/test-markdown.html
  86. 2 2
      test/test-multiple-instances.html
  87. 25 0
      tsconfig.json
  88. 11 0
      tsconfig.node.json
  89. 20 0
      vite.config.styles.ts
  90. 42 0
      vite.config.ts

+ 30 - 0
css/reset.css

@@ -0,0 +1,30 @@
+/* http://meyerweb.com/eric/tools/css/reset/
+   v4.0 | 20180602
+   License: none (public domain)
+*/
+
+html, body, div, span, applet, object, iframe,
+h1, h2, h3, h4, h5, h6, p, blockquote, pre,
+a, abbr, acronym, address, big, cite, code,
+del, dfn, em, img, ins, kbd, q, s, samp,
+small, strike, strong, sub, sup, tt, var,
+b, u, i, center,
+dl, dt, dd, ol, ul, li,
+fieldset, form, label, legend,
+table, caption, tbody, tfoot, thead, tr, th, td,
+article, aside, canvas, details, embed,
+figure, figcaption, footer, header, hgroup,
+main, menu, nav, output, ruby, section, summary,
+time, mark, audio, video {
+  margin: 0;
+  padding: 0;
+  border: 0;
+  font-size: 100%;
+  font: inherit;
+  vertical-align: baseline;
+}
+/* HTML5 display-role reset for older browsers */
+article, aside, details, figcaption, figure,
+footer, header, hgroup, main, menu, nav, section {
+  display: block;
+}

+ 8 - 9
css/theme/source/beige.scss → css/theme/beige.scss

@@ -4,42 +4,41 @@
  * Copyright (C) 2011-2012 Hakim El Hattab, http://hakim.se
  */
 
-
 // Default mixins and settings -----------------
 @use "sass:color";
 @import "../template/mixins";
 @import "../template/settings";
 // ---------------------------------------------
 
-
-
 // Include theme-specific fonts
 @import url(./fonts/league-gothic/league-gothic.css);
 @import url(https://fonts.googleapis.com/css?family=Lato:400,700,400italic,700italic);
 
-
 // Override theme settings (see ../template/settings.scss)
 $mainColor: #333;
 $headingColor: #333;
 $headingTextShadow: none;
 $backgroundColor: #f7f3de;
 $linkColor: #8b743d;
-$linkColorHover: color.scale( $linkColor, $lightness: 20% );
+$linkColorHover: color.scale($linkColor, $lightness: 20%);
 $selectionBackgroundColor: rgba(79, 64, 28, 0.99);
-$heading1TextShadow: 0 1px 0 #ccc, 0 2px 0 #c9c9c9, 0 3px 0 #bbb, 0 4px 0 #b9b9b9, 0 5px 0 #aaa, 0 6px 1px rgba(0,0,0,.1), 0 0 5px rgba(0,0,0,.1), 0 1px 3px rgba(0,0,0,.3), 0 3px 5px rgba(0,0,0,.2), 0 5px 10px rgba(0,0,0,.25), 0 20px 20px rgba(0,0,0,.15);
+$heading1TextShadow: 0 1px 0 #ccc, 0 2px 0 #c9c9c9, 0 3px 0 #bbb,
+  0 4px 0 #b9b9b9, 0 5px 0 #aaa, 0 6px 1px rgba(0, 0, 0, 0.1),
+  0 0 5px rgba(0, 0, 0, 0.1), 0 1px 3px rgba(0, 0, 0, 0.3),
+  0 3px 5px rgba(0, 0, 0, 0.2), 0 5px 10px rgba(0, 0, 0, 0.25),
+  0 20px 20px rgba(0, 0, 0, 0.15);
 
 $overlayElementBgColor: 0, 0, 0;
 $overlayElementFgColor: 240, 240, 240;
 
 // Background generator
 @mixin bodyBackground() {
-	@include radial-gradient( rgba(247,242,211,1), rgba(255,255,255,1) );
+  @include radial-gradient(rgba(247, 242, 211, 1), rgba(255, 255, 255, 1));
 }
 
 // Change text colors against dark slide backgrounds
 @include dark-bg-text-color(#fff);
 
-
 // Theme template ------------------------------
-@import "../template/theme";
+@import "./template/theme";
 // ---------------------------------------------

+ 6 - 10
css/theme/source/black-contrast.scss → css/theme/black-contrast.scss

@@ -7,18 +7,15 @@
  * - $mainFontSize controls code blocks, too (although under some ratio).
  */
 
-
 // Default mixins and settings -----------------
 @use "sass:color";
 @import "../template/mixins";
 @import "../template/settings";
 // ---------------------------------------------
 
-
 // Include theme-specific fonts
 @import url(./fonts/source-sans-pro/source-sans-pro.css);
 
-
 // Override theme settings (see ../template/settings.scss)
 $backgroundColor: #000000;
 
@@ -26,25 +23,24 @@ $mainColor: #fff;
 $headingColor: #fff;
 
 $mainFontSize: 42px;
-$mainFont: 'Source Sans Pro', Helvetica, sans-serif;
-$headingFont: 'Source Sans Pro', Helvetica, sans-serif;
+$mainFont: "Source Sans Pro", Helvetica, sans-serif;
+$headingFont: "Source Sans Pro", Helvetica, sans-serif;
 $headingTextShadow: none;
 $headingLetterSpacing: normal;
 $headingTextTransform: uppercase;
 $headingFontWeight: 600;
 $linkColor: #42affa;
-$linkColorHover: color.scale( $linkColor, $lightness: 15% );
-$selectionBackgroundColor: color.scale( $linkColor, $lightness: 25% );
+$linkColorHover: color.scale($linkColor, $lightness: 15%);
+$selectionBackgroundColor: color.scale($linkColor, $lightness: 25%);
 
 $heading1Size: 2.5em;
 $heading2Size: 1.6em;
 $heading3Size: 1.3em;
-$heading4Size: 1.0em;
+$heading4Size: 1em;
 
 // Change text colors against light slide backgrounds
 @include light-bg-text-color(#000);
 
-
 // Theme template ------------------------------
-@import "../template/theme";
+@import "./template/theme";
 // ---------------------------------------------

+ 7 - 11
css/theme/source/black.scss → css/theme/black.scss

@@ -4,17 +4,14 @@
  * By Hakim El Hattab, http://hakim.se
  */
 
-
 // Default mixins and settings -----------------
 @use "sass:color";
 @import "../template/mixins";
 @import "../template/settings";
 // ---------------------------------------------
 
-
 // Include theme-specific fonts
-@import url(./fonts/source-sans-pro/source-sans-pro.css);
-
+@import url("/theme/fonts/source-sans-pro/source-sans-pro.css");
 
 // Override theme settings (see ../template/settings.scss)
 $backgroundColor: #191919;
@@ -23,25 +20,24 @@ $mainColor: #fff;
 $headingColor: #fff;
 
 $mainFontSize: 42px;
-$mainFont: 'Source Sans Pro', Helvetica, sans-serif;
-$headingFont: 'Source Sans Pro', Helvetica, sans-serif;
+$mainFont: "Source Sans Pro", Helvetica, sans-serif;
+$headingFont: "Source Sans Pro", Helvetica, sans-serif;
 $headingTextShadow: none;
 $headingLetterSpacing: normal;
 $headingTextTransform: uppercase;
 $headingFontWeight: 600;
 $linkColor: #42affa;
-$linkColorHover: color.scale( $linkColor, $lightness: 15% );
-$selectionBackgroundColor: rgba( $linkColor, 0.75 );
+$linkColorHover: color.scale($linkColor, $lightness: 15%);
+$selectionBackgroundColor: rgba($linkColor, 0.75);
 
 $heading1Size: 2.5em;
 $heading2Size: 1.6em;
 $heading3Size: 1.3em;
-$heading4Size: 1.0em;
+$heading4Size: 1em;
 
 // Change text colors against light slide backgrounds
 @include light-bg-text-color(#222);
 
-
 // Theme template ------------------------------
-@import "../template/theme";
+@import "./template/theme";
 // ---------------------------------------------

+ 25 - 18
css/theme/source/blood.scss → css/theme/blood.scss

@@ -28,20 +28,24 @@ $codeBackground: #23241f;
 $backgroundColor: $coal;
 
 // Main text
-$mainFont: Ubuntu, 'sans-serif';
+$mainFont: Ubuntu, "sans-serif";
 $mainColor: #eee;
 
 // Headings
-$headingFont: Ubuntu, 'sans-serif';
+$headingFont: Ubuntu, "sans-serif";
 $headingTextShadow: 2px 2px 2px $coal;
 
-// h1 shadow, borrowed humbly from 
+// h1 shadow, borrowed humbly from
 // (c) Default theme by Hakim El Hattab
-$heading1TextShadow: 0 1px 0 #ccc, 0 2px 0 #c9c9c9, 0 3px 0 #bbb, 0 4px 0 #b9b9b9, 0 5px 0 #aaa, 0 6px 1px rgba(0,0,0,.1), 0 0 5px rgba(0,0,0,.1), 0 1px 3px rgba(0,0,0,.3), 0 3px 5px rgba(0,0,0,.2), 0 5px 10px rgba(0,0,0,.25), 0 20px 20px rgba(0,0,0,.15);
+$heading1TextShadow: 0 1px 0 #ccc, 0 2px 0 #c9c9c9, 0 3px 0 #bbb,
+  0 4px 0 #b9b9b9, 0 5px 0 #aaa, 0 6px 1px rgba(0, 0, 0, 0.1),
+  0 0 5px rgba(0, 0, 0, 0.1), 0 1px 3px rgba(0, 0, 0, 0.3),
+  0 3px 5px rgba(0, 0, 0, 0.2), 0 5px 10px rgba(0, 0, 0, 0.25),
+  0 20px 20px rgba(0, 0, 0, 0.15);
 
 // Links
 $linkColor: $blood;
-$linkColorHover: color.scale( $linkColor, $lightness: 20% );
+$linkColorHover: color.scale($linkColor, $lightness: 20%);
 
 // Text selection
 $selectionBackgroundColor: $blood;
@@ -50,22 +54,25 @@ $selectionColor: #fff;
 // Change text colors against dark slide backgrounds
 @include light-bg-text-color(#222);
 
-
 // Theme template ------------------------------
-@import "../template/theme";
+@import "./template/theme";
 // ---------------------------------------------
 
 // some overrides after theme template import
 
 .reveal p {
-    font-weight: 300;
-    text-shadow: 1px 1px $coal;
+  font-weight: 300;
+  text-shadow: 1px 1px $coal;
 }
 
 section.has-light-background {
-	p, h1, h2, h3, h4 {
-		text-shadow: none;
-	}
+  p,
+  h1,
+  h2,
+  h3,
+  h4 {
+    text-shadow: none;
+  }
 }
 
 .reveal h1,
@@ -74,15 +81,15 @@ section.has-light-background {
 .reveal h4,
 .reveal h5,
 .reveal h6 {
-    font-weight: 700;
+  font-weight: 700;
 }
 
 .reveal p code {
-    background-color: $codeBackground;
-    display: inline-block;
-    border-radius: 7px;
+  background-color: $codeBackground;
+  display: inline-block;
+  border-radius: 7px;
 }
 
 .reveal small code {
-    vertical-align: baseline;
-}
+  vertical-align: baseline;
+}

+ 3 - 3
css/theme/source/dracula.scss → css/theme/dracula.scss

@@ -5,8 +5,8 @@
 
 
 // Default mixins and settings -----------------
-@import "../template/mixins";
-@import "../template/settings";
+@import "./template/mixins";
+@import "./template/settings";
 // ---------------------------------------------
 
 // Include theme-specific fonts
@@ -75,7 +75,7 @@ $codeFont: "Fira Code", $systemFontsMono;
 @include light-bg-text-color($background);
 
 // Theme template ------------------------------
-@import "../template/theme";
+@import "./template/theme";
 // ---------------------------------------------
 
 // Define additional color effects based on Dracula spec

+ 3 - 3
css/theme/source/league.scss → css/theme/league.scss

@@ -8,8 +8,8 @@
 
 
 // Default mixins and settings -----------------
-@import "../template/mixins";
-@import "../template/settings";
+@import "./template/mixins";
+@import "./template/settings";
 // ---------------------------------------------
 
 
@@ -32,5 +32,5 @@ $heading1TextShadow: 0 1px 0 #ccc, 0 2px 0 #c9c9c9, 0 3px 0 #bbb, 0 4px 0 #b9b9b
 
 
 // Theme template ------------------------------
-@import "../template/theme";
+@import "./template/theme";
 // ---------------------------------------------

+ 18 - 21
css/theme/source/moon.scss → css/theme/moon.scss

@@ -3,15 +3,12 @@
  * Author: Achim Staebler
  */
 
-
 // Default mixins and settings -----------------
 @use "sass:color";
 @import "../template/mixins";
 @import "../template/settings";
 // ---------------------------------------------
 
-
-
 // Include theme-specific fonts
 @import url(./fonts/league-gothic/league-gothic.css);
 @import url(https://fonts.googleapis.com/css?family=Lato:400,700,400italic,700italic);
@@ -21,22 +18,22 @@
  */
 
 // Solarized colors
-$base03:    #002b36;
-$base02:    #073642;
-$base01:    #586e75;
-$base00:    #657b83;
-$base0:     #839496;
-$base1:     #93a1a1;
-$base2:     #eee8d5;
-$base3:     #fdf6e3;
-$yellow:    #b58900;
-$orange:    #cb4b16;
-$red:       #dc322f;
-$magenta:   #d33682;
-$violet:    #6c71c4;
-$blue:      #268bd2;
-$cyan:      #2aa198;
-$green:     #859900;
+$base03: #002b36;
+$base02: #073642;
+$base01: #586e75;
+$base00: #657b83;
+$base0: #839496;
+$base1: #93a1a1;
+$base2: #eee8d5;
+$base3: #fdf6e3;
+$yellow: #b58900;
+$orange: #cb4b16;
+$red: #dc322f;
+$magenta: #d33682;
+$violet: #6c71c4;
+$blue: #268bd2;
+$cyan: #2aa198;
+$green: #859900;
 
 // Override theme settings (see ../template/settings.scss)
 $mainColor: $base1;
@@ -44,12 +41,12 @@ $headingColor: $base2;
 $headingTextShadow: none;
 $backgroundColor: $base03;
 $linkColor: $blue;
-$linkColorHover: color.scale( $linkColor, $lightness: 20% );
+$linkColorHover: color.scale($linkColor, $lightness: 20%);
 $selectionBackgroundColor: $magenta;
 
 // Change text colors against light slide backgrounds
 @include light-bg-text-color(#222);
 
 // Theme template ------------------------------
-@import "../template/theme";
+@import "./template/theme";
 // ---------------------------------------------

+ 5 - 9
css/theme/source/night.scss → css/theme/night.scss

@@ -4,26 +4,23 @@
  * Copyright (C) 2011-2012 Hakim El Hattab, http://hakim.se
  */
 
-
 // Default mixins and settings -----------------
 @use "sass:color";
 @import "../template/mixins";
 @import "../template/settings";
 // ---------------------------------------------
 
-
 // Include theme-specific fonts
 @import url(https://fonts.googleapis.com/css?family=Montserrat:700);
 @import url(https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic,700italic);
 
-
 // Override theme settings (see ../template/settings.scss)
 $backgroundColor: #111;
 
-$mainFont: 'Open Sans', sans-serif;
+$mainFont: "Open Sans", sans-serif;
 $linkColor: #e7ad52;
-$linkColorHover: color.scale( $linkColor, $lightness: 20% );
-$headingFont: 'Montserrat', Impact, sans-serif;
+$linkColorHover: color.scale($linkColor, $lightness: 20%);
+$headingFont: "Montserrat", Impact, sans-serif;
 $headingTextShadow: none;
 $headingLetterSpacing: -0.03em;
 $headingTextTransform: none;
@@ -32,7 +29,6 @@ $selectionBackgroundColor: #e7ad52;
 // Change text colors against light slide backgrounds
 @include light-bg-text-color(#222);
 
-
 // Theme template ------------------------------
-@import "../template/theme";
-// ---------------------------------------------
+@import "./template/theme";
+// ---------------------------------------------

+ 8 - 12
css/theme/source/serif.scss → css/theme/serif.scss

@@ -5,26 +5,23 @@
  * This theme is Copyright (C) 2012-2013 Owen Versteeg, http://owenversteeg.com - it is MIT licensed.
  */
 
-
 // Default mixins and settings -----------------
 @use "sass:color";
 @import "../template/mixins";
 @import "../template/settings";
 // ---------------------------------------------
 
-
-
 // Override theme settings (see ../template/settings.scss)
-$mainFont: 'Palatino Linotype', 'Book Antiqua', Palatino, FreeSerif, serif;
+$mainFont: "Palatino Linotype", "Book Antiqua", Palatino, FreeSerif, serif;
 $mainColor: #000;
-$headingFont: 'Palatino Linotype', 'Book Antiqua', Palatino, FreeSerif, serif;
-$headingColor: #383D3D;
+$headingFont: "Palatino Linotype", "Book Antiqua", Palatino, FreeSerif, serif;
+$headingColor: #383d3d;
 $headingTextShadow: none;
 $headingTextTransform: none;
-$backgroundColor: #F0F1EB;
-$linkColor: #51483D;
-$linkColorHover: color.scale( $linkColor, $lightness: 20% );
-$selectionBackgroundColor: #26351C;
+$backgroundColor: #f0f1eb;
+$linkColor: #51483d;
+$linkColorHover: color.scale($linkColor, $lightness: 20%);
+$selectionBackgroundColor: #26351c;
 
 $overlayElementBgColor: 0, 0, 0;
 $overlayElementFgColor: 240, 240, 240;
@@ -36,7 +33,6 @@ $overlayElementFgColor: 240, 240, 240;
 // Change text colors against dark slide backgrounds
 @include dark-bg-text-color(#fff);
 
-
 // Theme template ------------------------------
-@import "../template/theme";
+@import "./template/theme";
 // ---------------------------------------------

+ 6 - 11
css/theme/source/simple.scss → css/theme/simple.scss

@@ -6,30 +6,26 @@
  * reveal.js is Copyright (C) 2011-2012 Hakim El Hattab, http://hakim.se
  */
 
-
 // Default mixins and settings -----------------
 @use "sass:color";
 @import "../template/mixins";
 @import "../template/settings";
 // ---------------------------------------------
 
-
-
 // Include theme-specific fonts
 @import url(https://fonts.googleapis.com/css?family=News+Cycle:400,700);
 @import url(https://fonts.googleapis.com/css?family=Lato:400,700,400italic,700italic);
 
-
 // Override theme settings (see ../template/settings.scss)
-$mainFont: 'Lato', sans-serif;
+$mainFont: "Lato", sans-serif;
 $mainColor: #000;
-$headingFont: 'News Cycle', Impact, sans-serif;
+$headingFont: "News Cycle", Impact, sans-serif;
 $headingColor: #000;
 $headingTextShadow: none;
 $headingTextTransform: none;
 $backgroundColor: #fff;
-$linkColor: #00008B;
-$linkColorHover: color.scale( $linkColor, $lightness: 20% );
+$linkColor: #00008b;
+$linkColorHover: color.scale($linkColor, $lightness: 20%);
 $selectionBackgroundColor: rgba(0, 0, 0, 0.99);
 
 $overlayElementBgColor: 0, 0, 0;
@@ -38,7 +34,6 @@ $overlayElementFgColor: 240, 240, 240;
 // Change text colors against dark slide backgrounds
 @include dark-bg-text-color(#fff);
 
-
 // Theme template ------------------------------
-@import "../template/theme";
-// ---------------------------------------------
+@import "./template/theme";
+// ---------------------------------------------

+ 6 - 12
css/theme/source/sky.scss → css/theme/sky.scss

@@ -4,30 +4,26 @@
  * Copyright (C) 2011-2012 Hakim El Hattab, http://hakim.se
  */
 
-
 // Default mixins and settings -----------------
 @use "sass:color";
 @import "../template/mixins";
 @import "../template/settings";
 // ---------------------------------------------
 
-
-
 // Include theme-specific fonts
 @import url(https://fonts.googleapis.com/css?family=Quicksand:400,700,400italic,700italic);
 @import url(https://fonts.googleapis.com/css?family=Open+Sans:400italic,700italic,400,700);
 
-
 // Override theme settings (see ../template/settings.scss)
-$mainFont: 'Open Sans', sans-serif;
+$mainFont: "Open Sans", sans-serif;
 $mainColor: #333;
-$headingFont: 'Quicksand', sans-serif;
+$headingFont: "Quicksand", sans-serif;
 $headingColor: #333;
 $headingLetterSpacing: -0.08em;
 $headingTextShadow: none;
 $backgroundColor: #f7fbfc;
 $linkColor: #3b759e;
-$linkColorHover: color.scale( $linkColor, $lightness: 20% );
+$linkColorHover: color.scale($linkColor, $lightness: 20%);
 $selectionBackgroundColor: #134674;
 
 $overlayElementBgColor: 0, 0, 0;
@@ -35,19 +31,17 @@ $overlayElementFgColor: 240, 240, 240;
 
 // Fix links so they are not cut off
 .reveal a {
-	line-height: 1.3em;
+  line-height: 1.3em;
 }
 
 // Background generator
 @mixin bodyBackground() {
-	@include radial-gradient( #add9e4, #f7fbfc );
+  @include radial-gradient(#add9e4, #f7fbfc);
 }
 
 // Change text colors against dark slide backgrounds
 @include dark-bg-text-color(#fff);
 
-
-
 // Theme template ------------------------------
-@import "../template/theme";
+@import "./template/theme";
 // ---------------------------------------------

+ 20 - 26
css/theme/source/solarized.scss → css/theme/solarized.scss

@@ -3,45 +3,41 @@
  * Author: Achim Staebler
  */
 
-
 // Default mixins and settings -----------------
 @use "sass:color";
 @import "../template/mixins";
 @import "../template/settings";
 // ---------------------------------------------
 
-
-
 // Include theme-specific fonts
 @import url(./fonts/league-gothic/league-gothic.css);
 @import url(https://fonts.googleapis.com/css?family=Lato:400,700,400italic,700italic);
 
-
 /**
  * Solarized colors by Ethan Schoonover
  */
 html * {
-	color-profile: sRGB;
-	rendering-intent: auto;
+  color-profile: sRGB;
+  rendering-intent: auto;
 }
 
 // Solarized colors
-$base03:    #002b36;
-$base02:    #073642;
-$base01:    #586e75;
-$base00:    #657b83;
-$base0:     #839496;
-$base1:     #93a1a1;
-$base2:     #eee8d5;
-$base3:     #fdf6e3;
-$yellow:    #b58900;
-$orange:    #cb4b16;
-$red:       #dc322f;
-$magenta:   #d33682;
-$violet:    #6c71c4;
-$blue:      #268bd2;
-$cyan:      #2aa198;
-$green:     #859900;
+$base03: #002b36;
+$base02: #073642;
+$base01: #586e75;
+$base00: #657b83;
+$base0: #839496;
+$base1: #93a1a1;
+$base2: #eee8d5;
+$base3: #fdf6e3;
+$yellow: #b58900;
+$orange: #cb4b16;
+$red: #dc322f;
+$magenta: #d33682;
+$violet: #6c71c4;
+$blue: #268bd2;
+$cyan: #2aa198;
+$green: #859900;
 
 // Override theme settings (see ../template/settings.scss)
 $mainColor: $base00;
@@ -49,7 +45,7 @@ $headingColor: $base01;
 $headingTextShadow: none;
 $backgroundColor: $base3;
 $linkColor: $blue;
-$linkColorHover: color.scale( $linkColor, $lightness: 20% );
+$linkColorHover: color.scale($linkColor, $lightness: 20%);
 $selectionBackgroundColor: $magenta;
 
 $overlayElementBgColor: 0, 0, 0;
@@ -60,8 +56,6 @@ $overlayElementFgColor: 240, 240, 240;
 // 	@include radial-gradient( rgba($base3,1), rgba(lighten($base3, 20%),1) );
 // }
 
-
-
 // Theme template ------------------------------
-@import "../template/theme";
+@import "./template/theme";
 // ---------------------------------------------

+ 6 - 10
css/theme/source/white-contrast.scss → css/theme/white-contrast.scss

@@ -7,18 +7,15 @@
  * - $mainFontSize controls code blocks, too (although under some ratio).
  */
 
-
 // Default mixins and settings -----------------
 @use "sass:color";
 @import "../template/mixins";
 @import "../template/settings";
 // ---------------------------------------------
 
-
 // Include theme-specific fonts
 @import url(./fonts/source-sans-pro/source-sans-pro.css);
 
-
 // Override theme settings (see ../template/settings.scss)
 $backgroundColor: #fff;
 
@@ -26,20 +23,20 @@ $mainColor: #000;
 $headingColor: #000;
 
 $mainFontSize: 42px;
-$mainFont: 'Source Sans Pro', Helvetica, sans-serif;
-$headingFont: 'Source Sans Pro', Helvetica, sans-serif;
+$mainFont: "Source Sans Pro", Helvetica, sans-serif;
+$headingFont: "Source Sans Pro", Helvetica, sans-serif;
 $headingTextShadow: none;
 $headingLetterSpacing: normal;
 $headingTextTransform: uppercase;
 $headingFontWeight: 600;
 $linkColor: #2a76dd;
-$linkColorHover: color.scale( $linkColor, $lightness: 15% );
-$selectionBackgroundColor: color.scale( $linkColor, $lightness: 25% );
+$linkColorHover: color.scale($linkColor, $lightness: 15%);
+$selectionBackgroundColor: color.scale($linkColor, $lightness: 25%);
 
 $heading1Size: 2.5em;
 $heading2Size: 1.6em;
 $heading3Size: 1.3em;
-$heading4Size: 1.0em;
+$heading4Size: 1em;
 
 $overlayElementBgColor: 0, 0, 0;
 $overlayElementFgColor: 240, 240, 240;
@@ -47,7 +44,6 @@ $overlayElementFgColor: 240, 240, 240;
 // Change text colors against dark slide backgrounds
 @include dark-bg-text-color(#fff);
 
-
 // Theme template ------------------------------
-@import "../template/theme";
+@import "./template/theme";
 // ---------------------------------------------

+ 6 - 10
css/theme/source/white.scss → css/theme/white.scss

@@ -4,18 +4,15 @@
  * By Hakim El Hattab, http://hakim.se
  */
 
-
 // Default mixins and settings -----------------
 @use "sass:color";
 @import "../template/mixins";
 @import "../template/settings";
 // ---------------------------------------------
 
-
 // Include theme-specific fonts
 @import url(./fonts/source-sans-pro/source-sans-pro.css);
 
-
 // Override theme settings (see ../template/settings.scss)
 $backgroundColor: #fff;
 
@@ -23,20 +20,20 @@ $mainColor: #222;
 $headingColor: #222;
 
 $mainFontSize: 42px;
-$mainFont: 'Source Sans Pro', Helvetica, sans-serif;
-$headingFont: 'Source Sans Pro', Helvetica, sans-serif;
+$mainFont: "Source Sans Pro", Helvetica, sans-serif;
+$headingFont: "Source Sans Pro", Helvetica, sans-serif;
 $headingTextShadow: none;
 $headingLetterSpacing: normal;
 $headingTextTransform: uppercase;
 $headingFontWeight: 600;
 $linkColor: #2a76dd;
-$linkColorHover: color.scale( $linkColor, $lightness: 15% );
-$selectionBackgroundColor: color.scale( $linkColor, $lightness: 25% );
+$linkColorHover: color.scale($linkColor, $lightness: 15%);
+$selectionBackgroundColor: color.scale($linkColor, $lightness: 25%);
 
 $heading1Size: 2.5em;
 $heading2Size: 1.6em;
 $heading3Size: 1.3em;
-$heading4Size: 1.0em;
+$heading4Size: 1em;
 
 $overlayElementBgColor: 0, 0, 0;
 $overlayElementFgColor: 240, 240, 240;
@@ -44,7 +41,6 @@ $overlayElementFgColor: 240, 240, 240;
 // Change text colors against dark slide backgrounds
 @include dark-bg-text-color(#fff);
 
-
 // Theme template ------------------------------
-@import "../template/theme";
+@import "./template/theme";
 // ---------------------------------------------

+ 9 - 3
demo.html

@@ -474,13 +474,19 @@ Reveal.on( 'customevent', function() {
 
 		</div>
 
-		<script src="dist/reveal.js"></script>
+		<!-- <script src="dist/reveal.js"></script>
 		<script src="plugin/zoom/zoom.js"></script>
 		<script src="plugin/notes/notes.js"></script>
 		<script src="plugin/search/search.js"></script>
 		<script src="plugin/markdown/markdown.js"></script>
-		<script src="plugin/highlight/highlight.js"></script>
-		<script>
+		<script src="plugin/highlight/highlight.js"></script> -->
+		<script type="module">
+			import Reveal from 'reveal.js';
+			import RevealZoom from 'reveal.js/plugin/zoom';
+			import RevealNotes from 'reveal.js/plugin/notes';
+			import RevealSearch from 'reveal.js/plugin/search';
+			import RevealMarkdown from 'reveal.js/plugin/markdown';
+			import RevealHighlight from 'reveal.js/plugin/highlight';
 
 			// Also available as an ES module, see:
 			// https://revealjs.com/initialization/

+ 84 - 0
dist/config.d.ts

@@ -0,0 +1,84 @@
+type RevealConfig = {
+    width: number | string;
+    height: number | string;
+    margin: number;
+    minScale: number;
+    maxScale: number;
+    controls: boolean;
+    controlsTutorial: boolean;
+    controlsLayout: 'edges' | 'bottom-right';
+    controlsBackArrows: 'faded' | 'hidden' | 'visible';
+    progress: boolean;
+    slideNumber: boolean | 'h.v' | 'h/v' | 'c' | 'c/t' | ((slide: any) => string | [string, string, string]);
+    showSlideNumber: 'all' | 'print' | 'speaker';
+    hashOneBasedIndex: boolean;
+    hash: boolean;
+    respondToHashChanges: boolean;
+    jumpToSlide: boolean;
+    history: boolean;
+    keyboard: boolean;
+    keyboardCondition: null | 'focused' | ((event: KeyboardEvent) => boolean);
+    disableLayout: boolean;
+    overview: boolean;
+    center: boolean;
+    touch: boolean;
+    loop: boolean;
+    rtl: boolean;
+    navigationMode: 'default' | 'linear' | 'grid';
+    shuffle: boolean;
+    fragments: boolean;
+    fragmentInURL: boolean;
+    embedded: boolean;
+    help: boolean;
+    pause: boolean;
+    showNotes: boolean;
+    showHiddenSlides: boolean;
+    autoPlayMedia: null | boolean;
+    preloadIframes: null | boolean;
+    autoAnimate: boolean;
+    autoAnimateMatcher: null | Function;
+    autoAnimateEasing: 'ease' | string;
+    autoAnimateDuration: number;
+    autoAnimateUnmatched: boolean;
+    autoAnimateStyles: string[];
+    autoSlide: number | false;
+    autoSlideStoppable: boolean;
+    autoSlideMethod: null | Function;
+    defaultTiming: null;
+    mouseWheel: boolean;
+    previewLinks: boolean;
+    postMessage: boolean;
+    postMessageEvents: boolean;
+    focusBodyOnPageVisibilityChange: boolean;
+    transition: 'none' | 'fade' | 'slide' | 'convex' | 'concave' | 'zoom';
+    transitionSpeed: 'default' | 'fast' | 'slow';
+    backgroundTransition: 'fade' | 'none' | 'slide' | 'convex' | 'concave' | 'zoom';
+    parallaxBackgroundImage: null | string;
+    parallaxBackgroundSize: null | string;
+    parallaxBackgroundRepeat: null | string;
+    parallaxBackgroundPosition: null | string;
+    parallaxBackgroundHorizontal: null | number;
+    parallaxBackgroundVertical: null | number;
+    view: null | 'print' | 'scroll';
+    scrollLayout: 'full' | 'compact';
+    scrollSnap: false | 'proximity' | 'mandatory';
+    scrollProgress: 'auto' | boolean;
+    scrollActivationWidth: number;
+    pdfMaxPagesPerSlide: number;
+    pdfSeparateFragments: boolean;
+    pdfPageHeightOffset: number;
+    viewDistance: number;
+    mobileViewDistance: number;
+    display: string;
+    hideInactiveCursor: boolean;
+    hideCursorTime: number;
+    sortFragmentsOnSync: boolean;
+    dependencies: any[];
+    plugins: any[];
+};
+export type PartialRevealConfig = Partial<RevealConfig>;
+/**
+ * The default reveal.js config object.
+ */
+declare const config: RevealConfig;
+export default config;

+ 12 - 0
dist/index.d.ts

@@ -0,0 +1,12 @@
+/**
+ * Expose the Reveal class to the window. To create a
+ * new instance:
+ * let deck = new Reveal( document.querySelector( '.reveal' ), {
+ *   controls: false
+ * } );
+ * deck.initialize().then(() => {
+ *   // reveal.js is ready
+ * });
+ */
+declare let Reveal: any;
+export default Reveal;

Filskillnaden har hållts tillbaka eftersom den är för stor
+ 0 - 0
dist/plugin/highlight.js


Filskillnaden har hållts tillbaka eftersom den är för stor
+ 1078 - 0
dist/plugin/highlight.mjs


+ 0 - 0
plugin/highlight/monokai.css → dist/plugin/highlight/monokai.css


+ 0 - 0
plugin/highlight/zenburn.css → dist/plugin/highlight/zenburn.css


Filskillnaden har hållts tillbaka eftersom den är för stor
+ 0 - 0
dist/plugin/markdown.js


+ 1738 - 0
dist/plugin/markdown.mjs

@@ -0,0 +1,1738 @@
+var ne = Object.defineProperty;
+var ie = (a, n, t) => n in a ? ne(a, n, { enumerable: !0, configurable: !0, writable: !0, value: t }) : a[n] = t;
+var B = (a, n, t) => (ie(a, typeof n != "symbol" ? n + "" : n, t), t);
+function X() {
+  return {
+    async: !1,
+    baseUrl: null,
+    breaks: !1,
+    extensions: null,
+    gfm: !0,
+    headerIds: !0,
+    headerPrefix: "",
+    highlight: null,
+    hooks: null,
+    langPrefix: "language-",
+    mangle: !0,
+    pedantic: !1,
+    renderer: null,
+    sanitize: !1,
+    sanitizer: null,
+    silent: !1,
+    smartypants: !1,
+    tokenizer: null,
+    walkTokens: null,
+    xhtml: !1
+  };
+}
+let L = X();
+function se(a) {
+  L = a;
+}
+const G = /[&<>"']/, re = new RegExp(G.source, "g"), W = /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/, le = new RegExp(W.source, "g"), ae = {
+  "&": "&amp;",
+  "<": "&lt;",
+  ">": "&gt;",
+  '"': "&quot;",
+  "'": "&#39;"
+}, U = (a) => ae[a];
+function z(a, n) {
+  if (n) {
+    if (G.test(a))
+      return a.replace(re, U);
+  } else if (W.test(a))
+    return a.replace(le, U);
+  return a;
+}
+const oe = /&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig;
+function J(a) {
+  return a.replace(oe, (n, t) => (t = t.toLowerCase(), t === "colon" ? ":" : t.charAt(0) === "#" ? t.charAt(1) === "x" ? String.fromCharCode(parseInt(t.substring(2), 16)) : String.fromCharCode(+t.substring(1)) : ""));
+}
+const ce = /(^|[^\[])\^/g;
+function S(a, n) {
+  a = typeof a == "string" ? a : a.source, n = n || "";
+  const t = {
+    replace: (e, i) => (i = i.source || i, i = i.replace(ce, "$1"), a = a.replace(e, i), t),
+    getRegex: () => new RegExp(a, n)
+  };
+  return t;
+}
+const he = /[^\w:]/g, ue = /^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;
+function Z(a, n, t) {
+  if (a) {
+    let e;
+    try {
+      e = decodeURIComponent(J(t)).replace(he, "").toLowerCase();
+    } catch {
+      return null;
+    }
+    if (e.indexOf("javascript:") === 0 || e.indexOf("vbscript:") === 0 || e.indexOf("data:") === 0)
+      return null;
+  }
+  n && !ue.test(t) && (t = de(n, t));
+  try {
+    t = encodeURI(t).replace(/%25/g, "%");
+  } catch {
+    return null;
+  }
+  return t;
+}
+const C = {}, pe = /^[^:]+:\/*[^/]*$/, fe = /^([^:]+:)[\s\S]*$/, ge = /^([^:]+:\/*[^/]*)[\s\S]*$/;
+function de(a, n) {
+  C[" " + a] || (pe.test(a) ? C[" " + a] = a + "/" : C[" " + a] = D(a, "/", !0)), a = C[" " + a];
+  const t = a.indexOf(":") === -1;
+  return n.substring(0, 2) === "//" ? t ? n : a.replace(fe, "$1") + n : n.charAt(0) === "/" ? t ? n : a.replace(ge, "$1") + n : a + n;
+}
+const P = { exec: function() {
+} };
+function H(a, n) {
+  const t = a.replace(/\|/g, (s, l, o) => {
+    let h = !1, w = l;
+    for (; --w >= 0 && o[w] === "\\"; )
+      h = !h;
+    return h ? "|" : " |";
+  }), e = t.split(/ \|/);
+  let i = 0;
+  if (e[0].trim() || e.shift(), e.length > 0 && !e[e.length - 1].trim() && e.pop(), e.length > n)
+    e.splice(n);
+  else
+    for (; e.length < n; )
+      e.push("");
+  for (; i < e.length; i++)
+    e[i] = e[i].trim().replace(/\\\|/g, "|");
+  return e;
+}
+function D(a, n, t) {
+  const e = a.length;
+  if (e === 0)
+    return "";
+  let i = 0;
+  for (; i < e; ) {
+    const s = a.charAt(e - i - 1);
+    if (s === n && !t)
+      i++;
+    else if (s !== n && t)
+      i++;
+    else
+      break;
+  }
+  return a.slice(0, e - i);
+}
+function ke(a, n) {
+  if (a.indexOf(n[1]) === -1)
+    return -1;
+  const t = a.length;
+  let e = 0, i = 0;
+  for (; i < t; i++)
+    if (a[i] === "\\")
+      i++;
+    else if (a[i] === n[0])
+      e++;
+    else if (a[i] === n[1] && (e--, e < 0))
+      return i;
+  return -1;
+}
+function me(a) {
+  a && a.sanitize && !a.silent && console.warn("marked(): sanitize and sanitizer parameters are deprecated since version 0.7.0, should not be used and will be removed in the future. Read more here: https://marked.js.org/#/USING_ADVANCED.md#options");
+}
+function j(a, n) {
+  if (n < 1)
+    return "";
+  let t = "";
+  for (; n > 1; )
+    n & 1 && (t += a), n >>= 1, a += a;
+  return t + a;
+}
+function F(a, n, t, e) {
+  const i = n.href, s = n.title ? z(n.title) : null, l = a[1].replace(/\\([\[\]])/g, "$1");
+  if (a[0].charAt(0) !== "!") {
+    e.state.inLink = !0;
+    const o = {
+      type: "link",
+      raw: t,
+      href: i,
+      title: s,
+      text: l,
+      tokens: e.inlineTokens(l)
+    };
+    return e.state.inLink = !1, o;
+  }
+  return {
+    type: "image",
+    raw: t,
+    href: i,
+    title: s,
+    text: z(l)
+  };
+}
+function xe(a, n) {
+  const t = a.match(/^(\s+)(?:```)/);
+  if (t === null)
+    return n;
+  const e = t[1];
+  return n.split(`
+`).map((i) => {
+    const s = i.match(/^\s+/);
+    if (s === null)
+      return i;
+    const [l] = s;
+    return l.length >= e.length ? i.slice(e.length) : i;
+  }).join(`
+`);
+}
+class N {
+  constructor(n) {
+    this.options = n || L;
+  }
+  space(n) {
+    const t = this.rules.block.newline.exec(n);
+    if (t && t[0].length > 0)
+      return {
+        type: "space",
+        raw: t[0]
+      };
+  }
+  code(n) {
+    const t = this.rules.block.code.exec(n);
+    if (t) {
+      const e = t[0].replace(/^ {1,4}/gm, "");
+      return {
+        type: "code",
+        raw: t[0],
+        codeBlockStyle: "indented",
+        text: this.options.pedantic ? e : D(e, `
+`)
+      };
+    }
+  }
+  fences(n) {
+    const t = this.rules.block.fences.exec(n);
+    if (t) {
+      const e = t[0], i = xe(e, t[3] || "");
+      return {
+        type: "code",
+        raw: e,
+        lang: t[2] ? t[2].trim().replace(this.rules.inline._escapes, "$1") : t[2],
+        text: i
+      };
+    }
+  }
+  heading(n) {
+    const t = this.rules.block.heading.exec(n);
+    if (t) {
+      let e = t[2].trim();
+      if (/#$/.test(e)) {
+        const i = D(e, "#");
+        (this.options.pedantic || !i || / $/.test(i)) && (e = i.trim());
+      }
+      return {
+        type: "heading",
+        raw: t[0],
+        depth: t[1].length,
+        text: e,
+        tokens: this.lexer.inline(e)
+      };
+    }
+  }
+  hr(n) {
+    const t = this.rules.block.hr.exec(n);
+    if (t)
+      return {
+        type: "hr",
+        raw: t[0]
+      };
+  }
+  blockquote(n) {
+    const t = this.rules.block.blockquote.exec(n);
+    if (t) {
+      const e = t[0].replace(/^ *>[ \t]?/gm, ""), i = this.lexer.state.top;
+      this.lexer.state.top = !0;
+      const s = this.lexer.blockTokens(e);
+      return this.lexer.state.top = i, {
+        type: "blockquote",
+        raw: t[0],
+        tokens: s,
+        text: e
+      };
+    }
+  }
+  list(n) {
+    let t = this.rules.block.list.exec(n);
+    if (t) {
+      let e, i, s, l, o, h, w, x, b, c, r, m, g = t[1].trim();
+      const y = g.length > 1, p = {
+        type: "list",
+        raw: "",
+        ordered: y,
+        start: y ? +g.slice(0, -1) : "",
+        loose: !1,
+        items: []
+      };
+      g = y ? `\\d{1,9}\\${g.slice(-1)}` : `\\${g}`, this.options.pedantic && (g = y ? g : "[*+-]");
+      const k = new RegExp(`^( {0,3}${g})((?:[	 ][^\\n]*)?(?:\\n|$))`);
+      for (; n && (m = !1, !(!(t = k.exec(n)) || this.rules.block.hr.test(n))); ) {
+        if (e = t[0], n = n.substring(e.length), x = t[2].split(`
+`, 1)[0].replace(/^\t+/, (T) => " ".repeat(3 * T.length)), b = n.split(`
+`, 1)[0], this.options.pedantic ? (l = 2, r = x.trimLeft()) : (l = t[2].search(/[^ ]/), l = l > 4 ? 1 : l, r = x.slice(l), l += t[1].length), h = !1, !x && /^ *$/.test(b) && (e += b + `
+`, n = n.substring(b.length + 1), m = !0), !m) {
+          const T = new RegExp(`^ {0,${Math.min(3, l - 1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ 	][^\\n]*)?(?:\\n|$))`), $ = new RegExp(`^ {0,${Math.min(3, l - 1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`), R = new RegExp(`^ {0,${Math.min(3, l - 1)}}(?:\`\`\`|~~~)`), A = new RegExp(`^ {0,${Math.min(3, l - 1)}}#`);
+          for (; n && (c = n.split(`
+`, 1)[0], b = c, this.options.pedantic && (b = b.replace(/^ {1,4}(?=( {4})*[^ ])/g, "  ")), !(R.test(b) || A.test(b) || T.test(b) || $.test(n))); ) {
+            if (b.search(/[^ ]/) >= l || !b.trim())
+              r += `
+` + b.slice(l);
+            else {
+              if (h || x.search(/[^ ]/) >= 4 || R.test(x) || A.test(x) || $.test(x))
+                break;
+              r += `
+` + b;
+            }
+            !h && !b.trim() && (h = !0), e += c + `
+`, n = n.substring(c.length + 1), x = b.slice(l);
+          }
+        }
+        p.loose || (w ? p.loose = !0 : /\n *\n *$/.test(e) && (w = !0)), this.options.gfm && (i = /^\[[ xX]\] /.exec(r), i && (s = i[0] !== "[ ] ", r = r.replace(/^\[[ xX]\] +/, ""))), p.items.push({
+          type: "list_item",
+          raw: e,
+          task: !!i,
+          checked: s,
+          loose: !1,
+          text: r
+        }), p.raw += e;
+      }
+      p.items[p.items.length - 1].raw = e.trimRight(), p.items[p.items.length - 1].text = r.trimRight(), p.raw = p.raw.trimRight();
+      const _ = p.items.length;
+      for (o = 0; o < _; o++)
+        if (this.lexer.state.top = !1, p.items[o].tokens = this.lexer.blockTokens(p.items[o].text, []), !p.loose) {
+          const T = p.items[o].tokens.filter((R) => R.type === "space"), $ = T.length > 0 && T.some((R) => /\n.*\n/.test(R.raw));
+          p.loose = $;
+        }
+      if (p.loose)
+        for (o = 0; o < _; o++)
+          p.items[o].loose = !0;
+      return p;
+    }
+  }
+  html(n) {
+    const t = this.rules.block.html.exec(n);
+    if (t) {
+      const e = {
+        type: "html",
+        raw: t[0],
+        pre: !this.options.sanitizer && (t[1] === "pre" || t[1] === "script" || t[1] === "style"),
+        text: t[0]
+      };
+      if (this.options.sanitize) {
+        const i = this.options.sanitizer ? this.options.sanitizer(t[0]) : z(t[0]);
+        e.type = "paragraph", e.text = i, e.tokens = this.lexer.inline(i);
+      }
+      return e;
+    }
+  }
+  def(n) {
+    const t = this.rules.block.def.exec(n);
+    if (t) {
+      const e = t[1].toLowerCase().replace(/\s+/g, " "), i = t[2] ? t[2].replace(/^<(.*)>$/, "$1").replace(this.rules.inline._escapes, "$1") : "", s = t[3] ? t[3].substring(1, t[3].length - 1).replace(this.rules.inline._escapes, "$1") : t[3];
+      return {
+        type: "def",
+        tag: e,
+        raw: t[0],
+        href: i,
+        title: s
+      };
+    }
+  }
+  table(n) {
+    const t = this.rules.block.table.exec(n);
+    if (t) {
+      const e = {
+        type: "table",
+        header: H(t[1]).map((i) => ({ text: i })),
+        align: t[2].replace(/^ *|\| *$/g, "").split(/ *\| */),
+        rows: t[3] && t[3].trim() ? t[3].replace(/\n[ \t]*$/, "").split(`
+`) : []
+      };
+      if (e.header.length === e.align.length) {
+        e.raw = t[0];
+        let i = e.align.length, s, l, o, h;
+        for (s = 0; s < i; s++)
+          /^ *-+: *$/.test(e.align[s]) ? e.align[s] = "right" : /^ *:-+: *$/.test(e.align[s]) ? e.align[s] = "center" : /^ *:-+ *$/.test(e.align[s]) ? e.align[s] = "left" : e.align[s] = null;
+        for (i = e.rows.length, s = 0; s < i; s++)
+          e.rows[s] = H(e.rows[s], e.header.length).map((w) => ({ text: w }));
+        for (i = e.header.length, l = 0; l < i; l++)
+          e.header[l].tokens = this.lexer.inline(e.header[l].text);
+        for (i = e.rows.length, l = 0; l < i; l++)
+          for (h = e.rows[l], o = 0; o < h.length; o++)
+            h[o].tokens = this.lexer.inline(h[o].text);
+        return e;
+      }
+    }
+  }
+  lheading(n) {
+    const t = this.rules.block.lheading.exec(n);
+    if (t)
+      return {
+        type: "heading",
+        raw: t[0],
+        depth: t[2].charAt(0) === "=" ? 1 : 2,
+        text: t[1],
+        tokens: this.lexer.inline(t[1])
+      };
+  }
+  paragraph(n) {
+    const t = this.rules.block.paragraph.exec(n);
+    if (t) {
+      const e = t[1].charAt(t[1].length - 1) === `
+` ? t[1].slice(0, -1) : t[1];
+      return {
+        type: "paragraph",
+        raw: t[0],
+        text: e,
+        tokens: this.lexer.inline(e)
+      };
+    }
+  }
+  text(n) {
+    const t = this.rules.block.text.exec(n);
+    if (t)
+      return {
+        type: "text",
+        raw: t[0],
+        text: t[0],
+        tokens: this.lexer.inline(t[0])
+      };
+  }
+  escape(n) {
+    const t = this.rules.inline.escape.exec(n);
+    if (t)
+      return {
+        type: "escape",
+        raw: t[0],
+        text: z(t[1])
+      };
+  }
+  tag(n) {
+    const t = this.rules.inline.tag.exec(n);
+    if (t)
+      return !this.lexer.state.inLink && /^<a /i.test(t[0]) ? this.lexer.state.inLink = !0 : this.lexer.state.inLink && /^<\/a>/i.test(t[0]) && (this.lexer.state.inLink = !1), !this.lexer.state.inRawBlock && /^<(pre|code|kbd|script)(\s|>)/i.test(t[0]) ? this.lexer.state.inRawBlock = !0 : this.lexer.state.inRawBlock && /^<\/(pre|code|kbd|script)(\s|>)/i.test(t[0]) && (this.lexer.state.inRawBlock = !1), {
+        type: this.options.sanitize ? "text" : "html",
+        raw: t[0],
+        inLink: this.lexer.state.inLink,
+        inRawBlock: this.lexer.state.inRawBlock,
+        text: this.options.sanitize ? this.options.sanitizer ? this.options.sanitizer(t[0]) : z(t[0]) : t[0]
+      };
+  }
+  link(n) {
+    const t = this.rules.inline.link.exec(n);
+    if (t) {
+      const e = t[2].trim();
+      if (!this.options.pedantic && /^</.test(e)) {
+        if (!/>$/.test(e))
+          return;
+        const l = D(e.slice(0, -1), "\\");
+        if ((e.length - l.length) % 2 === 0)
+          return;
+      } else {
+        const l = ke(t[2], "()");
+        if (l > -1) {
+          const h = (t[0].indexOf("!") === 0 ? 5 : 4) + t[1].length + l;
+          t[2] = t[2].substring(0, l), t[0] = t[0].substring(0, h).trim(), t[3] = "";
+        }
+      }
+      let i = t[2], s = "";
+      if (this.options.pedantic) {
+        const l = /^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(i);
+        l && (i = l[1], s = l[3]);
+      } else
+        s = t[3] ? t[3].slice(1, -1) : "";
+      return i = i.trim(), /^</.test(i) && (this.options.pedantic && !/>$/.test(e) ? i = i.slice(1) : i = i.slice(1, -1)), F(t, {
+        href: i && i.replace(this.rules.inline._escapes, "$1"),
+        title: s && s.replace(this.rules.inline._escapes, "$1")
+      }, t[0], this.lexer);
+    }
+  }
+  reflink(n, t) {
+    let e;
+    if ((e = this.rules.inline.reflink.exec(n)) || (e = this.rules.inline.nolink.exec(n))) {
+      let i = (e[2] || e[1]).replace(/\s+/g, " ");
+      if (i = t[i.toLowerCase()], !i) {
+        const s = e[0].charAt(0);
+        return {
+          type: "text",
+          raw: s,
+          text: s
+        };
+      }
+      return F(e, i, e[0], this.lexer);
+    }
+  }
+  emStrong(n, t, e = "") {
+    let i = this.rules.inline.emStrong.lDelim.exec(n);
+    if (!i || i[3] && e.match(/[\p{L}\p{N}]/u))
+      return;
+    const s = i[1] || i[2] || "";
+    if (!s || s && (e === "" || this.rules.inline.punctuation.exec(e))) {
+      const l = i[0].length - 1;
+      let o, h, w = l, x = 0;
+      const b = i[0][0] === "*" ? this.rules.inline.emStrong.rDelimAst : this.rules.inline.emStrong.rDelimUnd;
+      for (b.lastIndex = 0, t = t.slice(-1 * n.length + l); (i = b.exec(t)) != null; ) {
+        if (o = i[1] || i[2] || i[3] || i[4] || i[5] || i[6], !o)
+          continue;
+        if (h = o.length, i[3] || i[4]) {
+          w += h;
+          continue;
+        } else if ((i[5] || i[6]) && l % 3 && !((l + h) % 3)) {
+          x += h;
+          continue;
+        }
+        if (w -= h, w > 0)
+          continue;
+        h = Math.min(h, h + w + x);
+        const c = n.slice(0, l + i.index + (i[0].length - o.length) + h);
+        if (Math.min(l, h) % 2) {
+          const m = c.slice(1, -1);
+          return {
+            type: "em",
+            raw: c,
+            text: m,
+            tokens: this.lexer.inlineTokens(m)
+          };
+        }
+        const r = c.slice(2, -2);
+        return {
+          type: "strong",
+          raw: c,
+          text: r,
+          tokens: this.lexer.inlineTokens(r)
+        };
+      }
+    }
+  }
+  codespan(n) {
+    const t = this.rules.inline.code.exec(n);
+    if (t) {
+      let e = t[2].replace(/\n/g, " ");
+      const i = /[^ ]/.test(e), s = /^ /.test(e) && / $/.test(e);
+      return i && s && (e = e.substring(1, e.length - 1)), e = z(e, !0), {
+        type: "codespan",
+        raw: t[0],
+        text: e
+      };
+    }
+  }
+  br(n) {
+    const t = this.rules.inline.br.exec(n);
+    if (t)
+      return {
+        type: "br",
+        raw: t[0]
+      };
+  }
+  del(n) {
+    const t = this.rules.inline.del.exec(n);
+    if (t)
+      return {
+        type: "del",
+        raw: t[0],
+        text: t[2],
+        tokens: this.lexer.inlineTokens(t[2])
+      };
+  }
+  autolink(n, t) {
+    const e = this.rules.inline.autolink.exec(n);
+    if (e) {
+      let i, s;
+      return e[2] === "@" ? (i = z(this.options.mangle ? t(e[1]) : e[1]), s = "mailto:" + i) : (i = z(e[1]), s = i), {
+        type: "link",
+        raw: e[0],
+        text: i,
+        href: s,
+        tokens: [
+          {
+            type: "text",
+            raw: i,
+            text: i
+          }
+        ]
+      };
+    }
+  }
+  url(n, t) {
+    let e;
+    if (e = this.rules.inline.url.exec(n)) {
+      let i, s;
+      if (e[2] === "@")
+        i = z(this.options.mangle ? t(e[0]) : e[0]), s = "mailto:" + i;
+      else {
+        let l;
+        do
+          l = e[0], e[0] = this.rules.inline._backpedal.exec(e[0])[0];
+        while (l !== e[0]);
+        i = z(e[0]), e[1] === "www." ? s = "http://" + e[0] : s = e[0];
+      }
+      return {
+        type: "link",
+        raw: e[0],
+        text: i,
+        href: s,
+        tokens: [
+          {
+            type: "text",
+            raw: i,
+            text: i
+          }
+        ]
+      };
+    }
+  }
+  inlineText(n, t) {
+    const e = this.rules.inline.text.exec(n);
+    if (e) {
+      let i;
+      return this.lexer.state.inRawBlock ? i = this.options.sanitize ? this.options.sanitizer ? this.options.sanitizer(e[0]) : z(e[0]) : e[0] : i = z(this.options.smartypants ? t(e[0]) : e[0]), {
+        type: "text",
+        raw: e[0],
+        text: i
+      };
+    }
+  }
+}
+const d = {
+  newline: /^(?: *(?:\n|$))+/,
+  code: /^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/,
+  fences: /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,
+  hr: /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,
+  heading: /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,
+  blockquote: /^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,
+  list: /^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/,
+  html: "^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n *)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$))",
+  def: /^ {0,3}\[(label)\]: *(?:\n *)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/,
+  table: P,
+  lheading: /^((?:.|\n(?!\n))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,
+  // regex template, placeholders will be replaced according to different paragraph
+  // interruption rules of commonmark and the original markdown spec:
+  _paragraph: /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,
+  text: /^[^\n]+/
+};
+d._label = /(?!\s*\])(?:\\.|[^\[\]\\])+/;
+d._title = /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/;
+d.def = S(d.def).replace("label", d._label).replace("title", d._title).getRegex();
+d.bullet = /(?:[*+-]|\d{1,9}[.)])/;
+d.listItemStart = S(/^( *)(bull) */).replace("bull", d.bullet).getRegex();
+d.list = S(d.list).replace(/bull/g, d.bullet).replace("hr", "\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def", "\\n+(?=" + d.def.source + ")").getRegex();
+d._tag = "address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul";
+d._comment = /<!--(?!-?>)[\s\S]*?(?:-->|$)/;
+d.html = S(d.html, "i").replace("comment", d._comment).replace("tag", d._tag).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex();
+d.paragraph = S(d._paragraph).replace("hr", d.hr).replace("heading", " {0,3}#{1,6} ").replace("|lheading", "").replace("|table", "").replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", d._tag).getRegex();
+d.blockquote = S(d.blockquote).replace("paragraph", d.paragraph).getRegex();
+d.normal = { ...d };
+d.gfm = {
+  ...d.normal,
+  table: "^ *([^\\n ].*\\|.*)\\n {0,3}(?:\\| *)?(:?-+:? *(?:\\| *:?-+:? *)*)(?:\\| *)?(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)"
+  // Cells
+};
+d.gfm.table = S(d.gfm.table).replace("hr", d.hr).replace("heading", " {0,3}#{1,6} ").replace("blockquote", " {0,3}>").replace("code", " {4}[^\\n]").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", d._tag).getRegex();
+d.gfm.paragraph = S(d._paragraph).replace("hr", d.hr).replace("heading", " {0,3}#{1,6} ").replace("|lheading", "").replace("table", d.gfm.table).replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", d._tag).getRegex();
+d.pedantic = {
+  ...d.normal,
+  html: S(
+    `^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`
+  ).replace("comment", d._comment).replace(/tag/g, "(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),
+  def: /^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,
+  heading: /^(#{1,6})(.*)(?:\n+|$)/,
+  fences: P,
+  // fences not supported
+  lheading: /^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,
+  paragraph: S(d.normal._paragraph).replace("hr", d.hr).replace("heading", ` *#{1,6} *[^
+]`).replace("lheading", d.lheading).replace("blockquote", " {0,3}>").replace("|fences", "").replace("|list", "").replace("|html", "").getRegex()
+};
+const u = {
+  escape: /^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,
+  autolink: /^<(scheme:[^\s\x00-\x1f<>]*|email)>/,
+  url: P,
+  tag: "^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>",
+  // CDATA section
+  link: /^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/,
+  reflink: /^!?\[(label)\]\[(ref)\]/,
+  nolink: /^!?\[(ref)\](?:\[\])?/,
+  reflinkSearch: "reflink|nolink(?!\\()",
+  emStrong: {
+    lDelim: /^(?:\*+(?:([punct_])|[^\s*]))|^_+(?:([punct*])|([^\s_]))/,
+    //        (1) and (2) can only be a Right Delimiter. (3) and (4) can only be Left.  (5) and (6) can be either Left or Right.
+    //          () Skip orphan inside strong                                      () Consume to delim     (1) #***                (2) a***#, a***                             (3) #***a, ***a                 (4) ***#              (5) #***#                 (6) a***a
+    rDelimAst: /^(?:[^_*\\]|\\.)*?\_\_(?:[^_*\\]|\\.)*?\*(?:[^_*\\]|\\.)*?(?=\_\_)|(?:[^*\\]|\\.)+(?=[^*])|[punct_](\*+)(?=[\s]|$)|(?:[^punct*_\s\\]|\\.)(\*+)(?=[punct_\s]|$)|[punct_\s](\*+)(?=[^punct*_\s])|[\s](\*+)(?=[punct_])|[punct_](\*+)(?=[punct_])|(?:[^punct*_\s\\]|\\.)(\*+)(?=[^punct*_\s])/,
+    rDelimUnd: /^(?:[^_*\\]|\\.)*?\*\*(?:[^_*\\]|\\.)*?\_(?:[^_*\\]|\\.)*?(?=\*\*)|(?:[^_\\]|\\.)+(?=[^_])|[punct*](\_+)(?=[\s]|$)|(?:[^punct*_\s\\]|\\.)(\_+)(?=[punct*\s]|$)|[punct*\s](\_+)(?=[^punct*_\s])|[\s](\_+)(?=[punct*])|[punct*](\_+)(?=[punct*])/
+    // ^- Not allowed for _
+  },
+  code: /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,
+  br: /^( {2,}|\\)\n(?!\s*$)/,
+  del: P,
+  text: /^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,
+  punctuation: /^([\spunctuation])/
+};
+u._punctuation = "!\"#$%&'()+\\-.,/:;<=>?@\\[\\]`^{|}~";
+u.punctuation = S(u.punctuation).replace(/punctuation/g, u._punctuation).getRegex();
+u.blockSkip = /\[[^\]]*?\]\([^\)]*?\)|`[^`]*?`|<[^>]*?>/g;
+u.escapedEmSt = /(?:^|[^\\])(?:\\\\)*\\[*_]/g;
+u._comment = S(d._comment).replace("(?:-->|$)", "-->").getRegex();
+u.emStrong.lDelim = S(u.emStrong.lDelim).replace(/punct/g, u._punctuation).getRegex();
+u.emStrong.rDelimAst = S(u.emStrong.rDelimAst, "g").replace(/punct/g, u._punctuation).getRegex();
+u.emStrong.rDelimUnd = S(u.emStrong.rDelimUnd, "g").replace(/punct/g, u._punctuation).getRegex();
+u._escapes = /\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/g;
+u._scheme = /[a-zA-Z][a-zA-Z0-9+.-]{1,31}/;
+u._email = /[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/;
+u.autolink = S(u.autolink).replace("scheme", u._scheme).replace("email", u._email).getRegex();
+u._attribute = /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/;
+u.tag = S(u.tag).replace("comment", u._comment).replace("attribute", u._attribute).getRegex();
+u._label = /(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/;
+u._href = /<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/;
+u._title = /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/;
+u.link = S(u.link).replace("label", u._label).replace("href", u._href).replace("title", u._title).getRegex();
+u.reflink = S(u.reflink).replace("label", u._label).replace("ref", d._label).getRegex();
+u.nolink = S(u.nolink).replace("ref", d._label).getRegex();
+u.reflinkSearch = S(u.reflinkSearch, "g").replace("reflink", u.reflink).replace("nolink", u.nolink).getRegex();
+u.normal = { ...u };
+u.pedantic = {
+  ...u.normal,
+  strong: {
+    start: /^__|\*\*/,
+    middle: /^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,
+    endAst: /\*\*(?!\*)/g,
+    endUnd: /__(?!_)/g
+  },
+  em: {
+    start: /^_|\*/,
+    middle: /^()\*(?=\S)([\s\S]*?\S)\*(?!\*)|^_(?=\S)([\s\S]*?\S)_(?!_)/,
+    endAst: /\*(?!\*)/g,
+    endUnd: /_(?!_)/g
+  },
+  link: S(/^!?\[(label)\]\((.*?)\)/).replace("label", u._label).getRegex(),
+  reflink: S(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label", u._label).getRegex()
+};
+u.gfm = {
+  ...u.normal,
+  escape: S(u.escape).replace("])", "~|])").getRegex(),
+  _extended_email: /[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/,
+  url: /^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,
+  _backpedal: /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,
+  del: /^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,
+  text: /^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/
+};
+u.gfm.url = S(u.gfm.url, "i").replace("email", u.gfm._extended_email).getRegex();
+u.breaks = {
+  ...u.gfm,
+  br: S(u.br).replace("{2,}", "*").getRegex(),
+  text: S(u.gfm.text).replace("\\b_", "\\b_| {2,}\\n").replace(/\{2,\}/g, "*").getRegex()
+};
+function be(a) {
+  return a.replace(/---/g, "—").replace(/--/g, "–").replace(/(^|[-\u2014/(\[{"\s])'/g, "$1‘").replace(/'/g, "’").replace(/(^|[-\u2014/(\[{\u2018\s])"/g, "$1“").replace(/"/g, "”").replace(/\.{3}/g, "…");
+}
+function Q(a) {
+  let n = "", t, e;
+  const i = a.length;
+  for (t = 0; t < i; t++)
+    e = a.charCodeAt(t), Math.random() > 0.5 && (e = "x" + e.toString(16)), n += "&#" + e + ";";
+  return n;
+}
+class E {
+  constructor(n) {
+    this.tokens = [], this.tokens.links = /* @__PURE__ */ Object.create(null), this.options = n || L, this.options.tokenizer = this.options.tokenizer || new N(), this.tokenizer = this.options.tokenizer, this.tokenizer.options = this.options, this.tokenizer.lexer = this, this.inlineQueue = [], this.state = {
+      inLink: !1,
+      inRawBlock: !1,
+      top: !0
+    };
+    const t = {
+      block: d.normal,
+      inline: u.normal
+    };
+    this.options.pedantic ? (t.block = d.pedantic, t.inline = u.pedantic) : this.options.gfm && (t.block = d.gfm, this.options.breaks ? t.inline = u.breaks : t.inline = u.gfm), this.tokenizer.rules = t;
+  }
+  /**
+   * Expose Rules
+   */
+  static get rules() {
+    return {
+      block: d,
+      inline: u
+    };
+  }
+  /**
+   * Static Lex Method
+   */
+  static lex(n, t) {
+    return new E(t).lex(n);
+  }
+  /**
+   * Static Lex Inline Method
+   */
+  static lexInline(n, t) {
+    return new E(t).inlineTokens(n);
+  }
+  /**
+   * Preprocessing
+   */
+  lex(n) {
+    n = n.replace(/\r\n|\r/g, `
+`), this.blockTokens(n, this.tokens);
+    let t;
+    for (; t = this.inlineQueue.shift(); )
+      this.inlineTokens(t.src, t.tokens);
+    return this.tokens;
+  }
+  /**
+   * Lexing
+   */
+  blockTokens(n, t = []) {
+    this.options.pedantic ? n = n.replace(/\t/g, "    ").replace(/^ +$/gm, "") : n = n.replace(/^( *)(\t+)/gm, (o, h, w) => h + "    ".repeat(w.length));
+    let e, i, s, l;
+    for (; n; )
+      if (!(this.options.extensions && this.options.extensions.block && this.options.extensions.block.some((o) => (e = o.call({ lexer: this }, n, t)) ? (n = n.substring(e.raw.length), t.push(e), !0) : !1))) {
+        if (e = this.tokenizer.space(n)) {
+          n = n.substring(e.raw.length), e.raw.length === 1 && t.length > 0 ? t[t.length - 1].raw += `
+` : t.push(e);
+          continue;
+        }
+        if (e = this.tokenizer.code(n)) {
+          n = n.substring(e.raw.length), i = t[t.length - 1], i && (i.type === "paragraph" || i.type === "text") ? (i.raw += `
+` + e.raw, i.text += `
+` + e.text, this.inlineQueue[this.inlineQueue.length - 1].src = i.text) : t.push(e);
+          continue;
+        }
+        if (e = this.tokenizer.fences(n)) {
+          n = n.substring(e.raw.length), t.push(e);
+          continue;
+        }
+        if (e = this.tokenizer.heading(n)) {
+          n = n.substring(e.raw.length), t.push(e);
+          continue;
+        }
+        if (e = this.tokenizer.hr(n)) {
+          n = n.substring(e.raw.length), t.push(e);
+          continue;
+        }
+        if (e = this.tokenizer.blockquote(n)) {
+          n = n.substring(e.raw.length), t.push(e);
+          continue;
+        }
+        if (e = this.tokenizer.list(n)) {
+          n = n.substring(e.raw.length), t.push(e);
+          continue;
+        }
+        if (e = this.tokenizer.html(n)) {
+          n = n.substring(e.raw.length), t.push(e);
+          continue;
+        }
+        if (e = this.tokenizer.def(n)) {
+          n = n.substring(e.raw.length), i = t[t.length - 1], i && (i.type === "paragraph" || i.type === "text") ? (i.raw += `
+` + e.raw, i.text += `
+` + e.raw, this.inlineQueue[this.inlineQueue.length - 1].src = i.text) : this.tokens.links[e.tag] || (this.tokens.links[e.tag] = {
+            href: e.href,
+            title: e.title
+          });
+          continue;
+        }
+        if (e = this.tokenizer.table(n)) {
+          n = n.substring(e.raw.length), t.push(e);
+          continue;
+        }
+        if (e = this.tokenizer.lheading(n)) {
+          n = n.substring(e.raw.length), t.push(e);
+          continue;
+        }
+        if (s = n, this.options.extensions && this.options.extensions.startBlock) {
+          let o = 1 / 0;
+          const h = n.slice(1);
+          let w;
+          this.options.extensions.startBlock.forEach(function(x) {
+            w = x.call({ lexer: this }, h), typeof w == "number" && w >= 0 && (o = Math.min(o, w));
+          }), o < 1 / 0 && o >= 0 && (s = n.substring(0, o + 1));
+        }
+        if (this.state.top && (e = this.tokenizer.paragraph(s))) {
+          i = t[t.length - 1], l && i.type === "paragraph" ? (i.raw += `
+` + e.raw, i.text += `
+` + e.text, this.inlineQueue.pop(), this.inlineQueue[this.inlineQueue.length - 1].src = i.text) : t.push(e), l = s.length !== n.length, n = n.substring(e.raw.length);
+          continue;
+        }
+        if (e = this.tokenizer.text(n)) {
+          n = n.substring(e.raw.length), i = t[t.length - 1], i && i.type === "text" ? (i.raw += `
+` + e.raw, i.text += `
+` + e.text, this.inlineQueue.pop(), this.inlineQueue[this.inlineQueue.length - 1].src = i.text) : t.push(e);
+          continue;
+        }
+        if (n) {
+          const o = "Infinite loop on byte: " + n.charCodeAt(0);
+          if (this.options.silent) {
+            console.error(o);
+            break;
+          } else
+            throw new Error(o);
+        }
+      }
+    return this.state.top = !0, t;
+  }
+  inline(n, t = []) {
+    return this.inlineQueue.push({ src: n, tokens: t }), t;
+  }
+  /**
+   * Lexing/Compiling
+   */
+  inlineTokens(n, t = []) {
+    let e, i, s, l = n, o, h, w;
+    if (this.tokens.links) {
+      const x = Object.keys(this.tokens.links);
+      if (x.length > 0)
+        for (; (o = this.tokenizer.rules.inline.reflinkSearch.exec(l)) != null; )
+          x.includes(o[0].slice(o[0].lastIndexOf("[") + 1, -1)) && (l = l.slice(0, o.index) + "[" + j("a", o[0].length - 2) + "]" + l.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex));
+    }
+    for (; (o = this.tokenizer.rules.inline.blockSkip.exec(l)) != null; )
+      l = l.slice(0, o.index) + "[" + j("a", o[0].length - 2) + "]" + l.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);
+    for (; (o = this.tokenizer.rules.inline.escapedEmSt.exec(l)) != null; )
+      l = l.slice(0, o.index + o[0].length - 2) + "++" + l.slice(this.tokenizer.rules.inline.escapedEmSt.lastIndex), this.tokenizer.rules.inline.escapedEmSt.lastIndex--;
+    for (; n; )
+      if (h || (w = ""), h = !1, !(this.options.extensions && this.options.extensions.inline && this.options.extensions.inline.some((x) => (e = x.call({ lexer: this }, n, t)) ? (n = n.substring(e.raw.length), t.push(e), !0) : !1))) {
+        if (e = this.tokenizer.escape(n)) {
+          n = n.substring(e.raw.length), t.push(e);
+          continue;
+        }
+        if (e = this.tokenizer.tag(n)) {
+          n = n.substring(e.raw.length), i = t[t.length - 1], i && e.type === "text" && i.type === "text" ? (i.raw += e.raw, i.text += e.text) : t.push(e);
+          continue;
+        }
+        if (e = this.tokenizer.link(n)) {
+          n = n.substring(e.raw.length), t.push(e);
+          continue;
+        }
+        if (e = this.tokenizer.reflink(n, this.tokens.links)) {
+          n = n.substring(e.raw.length), i = t[t.length - 1], i && e.type === "text" && i.type === "text" ? (i.raw += e.raw, i.text += e.text) : t.push(e);
+          continue;
+        }
+        if (e = this.tokenizer.emStrong(n, l, w)) {
+          n = n.substring(e.raw.length), t.push(e);
+          continue;
+        }
+        if (e = this.tokenizer.codespan(n)) {
+          n = n.substring(e.raw.length), t.push(e);
+          continue;
+        }
+        if (e = this.tokenizer.br(n)) {
+          n = n.substring(e.raw.length), t.push(e);
+          continue;
+        }
+        if (e = this.tokenizer.del(n)) {
+          n = n.substring(e.raw.length), t.push(e);
+          continue;
+        }
+        if (e = this.tokenizer.autolink(n, Q)) {
+          n = n.substring(e.raw.length), t.push(e);
+          continue;
+        }
+        if (!this.state.inLink && (e = this.tokenizer.url(n, Q))) {
+          n = n.substring(e.raw.length), t.push(e);
+          continue;
+        }
+        if (s = n, this.options.extensions && this.options.extensions.startInline) {
+          let x = 1 / 0;
+          const b = n.slice(1);
+          let c;
+          this.options.extensions.startInline.forEach(function(r) {
+            c = r.call({ lexer: this }, b), typeof c == "number" && c >= 0 && (x = Math.min(x, c));
+          }), x < 1 / 0 && x >= 0 && (s = n.substring(0, x + 1));
+        }
+        if (e = this.tokenizer.inlineText(s, be)) {
+          n = n.substring(e.raw.length), e.raw.slice(-1) !== "_" && (w = e.raw.slice(-1)), h = !0, i = t[t.length - 1], i && i.type === "text" ? (i.raw += e.raw, i.text += e.text) : t.push(e);
+          continue;
+        }
+        if (n) {
+          const x = "Infinite loop on byte: " + n.charCodeAt(0);
+          if (this.options.silent) {
+            console.error(x);
+            break;
+          } else
+            throw new Error(x);
+        }
+      }
+    return t;
+  }
+}
+class q {
+  constructor(n) {
+    this.options = n || L;
+  }
+  code(n, t, e) {
+    const i = (t || "").match(/\S*/)[0];
+    if (this.options.highlight) {
+      const s = this.options.highlight(n, i);
+      s != null && s !== n && (e = !0, n = s);
+    }
+    return n = n.replace(/\n$/, "") + `
+`, i ? '<pre><code class="' + this.options.langPrefix + z(i) + '">' + (e ? n : z(n, !0)) + `</code></pre>
+` : "<pre><code>" + (e ? n : z(n, !0)) + `</code></pre>
+`;
+  }
+  /**
+   * @param {string} quote
+   */
+  blockquote(n) {
+    return `<blockquote>
+${n}</blockquote>
+`;
+  }
+  html(n) {
+    return n;
+  }
+  /**
+   * @param {string} text
+   * @param {string} level
+   * @param {string} raw
+   * @param {any} slugger
+   */
+  heading(n, t, e, i) {
+    if (this.options.headerIds) {
+      const s = this.options.headerPrefix + i.slug(e);
+      return `<h${t} id="${s}">${n}</h${t}>
+`;
+    }
+    return `<h${t}>${n}</h${t}>
+`;
+  }
+  hr() {
+    return this.options.xhtml ? `<hr/>
+` : `<hr>
+`;
+  }
+  list(n, t, e) {
+    const i = t ? "ol" : "ul", s = t && e !== 1 ? ' start="' + e + '"' : "";
+    return "<" + i + s + `>
+` + n + "</" + i + `>
+`;
+  }
+  /**
+   * @param {string} text
+   */
+  listitem(n) {
+    return `<li>${n}</li>
+`;
+  }
+  checkbox(n) {
+    return "<input " + (n ? 'checked="" ' : "") + 'disabled="" type="checkbox"' + (this.options.xhtml ? " /" : "") + "> ";
+  }
+  /**
+   * @param {string} text
+   */
+  paragraph(n) {
+    return `<p>${n}</p>
+`;
+  }
+  /**
+   * @param {string} header
+   * @param {string} body
+   */
+  table(n, t) {
+    return t && (t = `<tbody>${t}</tbody>`), `<table>
+<thead>
+` + n + `</thead>
+` + t + `</table>
+`;
+  }
+  /**
+   * @param {string} content
+   */
+  tablerow(n) {
+    return `<tr>
+${n}</tr>
+`;
+  }
+  tablecell(n, t) {
+    const e = t.header ? "th" : "td";
+    return (t.align ? `<${e} align="${t.align}">` : `<${e}>`) + n + `</${e}>
+`;
+  }
+  /**
+   * span level renderer
+   * @param {string} text
+   */
+  strong(n) {
+    return `<strong>${n}</strong>`;
+  }
+  /**
+   * @param {string} text
+   */
+  em(n) {
+    return `<em>${n}</em>`;
+  }
+  /**
+   * @param {string} text
+   */
+  codespan(n) {
+    return `<code>${n}</code>`;
+  }
+  br() {
+    return this.options.xhtml ? "<br/>" : "<br>";
+  }
+  /**
+   * @param {string} text
+   */
+  del(n) {
+    return `<del>${n}</del>`;
+  }
+  /**
+   * @param {string} href
+   * @param {string} title
+   * @param {string} text
+   */
+  link(n, t, e) {
+    if (n = Z(this.options.sanitize, this.options.baseUrl, n), n === null)
+      return e;
+    let i = '<a href="' + n + '"';
+    return t && (i += ' title="' + t + '"'), i += ">" + e + "</a>", i;
+  }
+  /**
+   * @param {string} href
+   * @param {string} title
+   * @param {string} text
+   */
+  image(n, t, e) {
+    if (n = Z(this.options.sanitize, this.options.baseUrl, n), n === null)
+      return e;
+    let i = `<img src="${n}" alt="${e}"`;
+    return t && (i += ` title="${t}"`), i += this.options.xhtml ? "/>" : ">", i;
+  }
+  text(n) {
+    return n;
+  }
+}
+class K {
+  // no need for block level renderers
+  strong(n) {
+    return n;
+  }
+  em(n) {
+    return n;
+  }
+  codespan(n) {
+    return n;
+  }
+  del(n) {
+    return n;
+  }
+  html(n) {
+    return n;
+  }
+  text(n) {
+    return n;
+  }
+  link(n, t, e) {
+    return "" + e;
+  }
+  image(n, t, e) {
+    return "" + e;
+  }
+  br() {
+    return "";
+  }
+}
+class Y {
+  constructor() {
+    this.seen = {};
+  }
+  /**
+   * @param {string} value
+   */
+  serialize(n) {
+    return n.toLowerCase().trim().replace(/<[!\/a-z].*?>/ig, "").replace(/[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,./:;<=>?@[\]^`{|}~]/g, "").replace(/\s/g, "-");
+  }
+  /**
+   * Finds the next safe (unique) slug to use
+   * @param {string} originalSlug
+   * @param {boolean} isDryRun
+   */
+  getNextSafeSlug(n, t) {
+    let e = n, i = 0;
+    if (this.seen.hasOwnProperty(e)) {
+      i = this.seen[n];
+      do
+        i++, e = n + "-" + i;
+      while (this.seen.hasOwnProperty(e));
+    }
+    return t || (this.seen[n] = i, this.seen[e] = 0), e;
+  }
+  /**
+   * Convert string to unique id
+   * @param {object} [options]
+   * @param {boolean} [options.dryrun] Generates the next unique slug without
+   * updating the internal accumulator.
+   */
+  slug(n, t = {}) {
+    const e = this.serialize(n);
+    return this.getNextSafeSlug(e, t.dryrun);
+  }
+}
+class I {
+  constructor(n) {
+    this.options = n || L, this.options.renderer = this.options.renderer || new q(), this.renderer = this.options.renderer, this.renderer.options = this.options, this.textRenderer = new K(), this.slugger = new Y();
+  }
+  /**
+   * Static Parse Method
+   */
+  static parse(n, t) {
+    return new I(t).parse(n);
+  }
+  /**
+   * Static Parse Inline Method
+   */
+  static parseInline(n, t) {
+    return new I(t).parseInline(n);
+  }
+  /**
+   * Parse Loop
+   */
+  parse(n, t = !0) {
+    let e = "", i, s, l, o, h, w, x, b, c, r, m, g, y, p, k, _, T, $, R;
+    const A = n.length;
+    for (i = 0; i < A; i++) {
+      if (r = n[i], this.options.extensions && this.options.extensions.renderers && this.options.extensions.renderers[r.type] && (R = this.options.extensions.renderers[r.type].call({ parser: this }, r), R !== !1 || !["space", "hr", "heading", "code", "table", "blockquote", "list", "html", "paragraph", "text"].includes(r.type))) {
+        e += R || "";
+        continue;
+      }
+      switch (r.type) {
+        case "space":
+          continue;
+        case "hr": {
+          e += this.renderer.hr();
+          continue;
+        }
+        case "heading": {
+          e += this.renderer.heading(
+            this.parseInline(r.tokens),
+            r.depth,
+            J(this.parseInline(r.tokens, this.textRenderer)),
+            this.slugger
+          );
+          continue;
+        }
+        case "code": {
+          e += this.renderer.code(
+            r.text,
+            r.lang,
+            r.escaped
+          );
+          continue;
+        }
+        case "table": {
+          for (b = "", x = "", o = r.header.length, s = 0; s < o; s++)
+            x += this.renderer.tablecell(
+              this.parseInline(r.header[s].tokens),
+              { header: !0, align: r.align[s] }
+            );
+          for (b += this.renderer.tablerow(x), c = "", o = r.rows.length, s = 0; s < o; s++) {
+            for (w = r.rows[s], x = "", h = w.length, l = 0; l < h; l++)
+              x += this.renderer.tablecell(
+                this.parseInline(w[l].tokens),
+                { header: !1, align: r.align[l] }
+              );
+            c += this.renderer.tablerow(x);
+          }
+          e += this.renderer.table(b, c);
+          continue;
+        }
+        case "blockquote": {
+          c = this.parse(r.tokens), e += this.renderer.blockquote(c);
+          continue;
+        }
+        case "list": {
+          for (m = r.ordered, g = r.start, y = r.loose, o = r.items.length, c = "", s = 0; s < o; s++)
+            k = r.items[s], _ = k.checked, T = k.task, p = "", k.task && ($ = this.renderer.checkbox(_), y ? k.tokens.length > 0 && k.tokens[0].type === "paragraph" ? (k.tokens[0].text = $ + " " + k.tokens[0].text, k.tokens[0].tokens && k.tokens[0].tokens.length > 0 && k.tokens[0].tokens[0].type === "text" && (k.tokens[0].tokens[0].text = $ + " " + k.tokens[0].tokens[0].text)) : k.tokens.unshift({
+              type: "text",
+              text: $
+            }) : p += $), p += this.parse(k.tokens, y), c += this.renderer.listitem(p, T, _);
+          e += this.renderer.list(c, m, g);
+          continue;
+        }
+        case "html": {
+          e += this.renderer.html(r.text);
+          continue;
+        }
+        case "paragraph": {
+          e += this.renderer.paragraph(this.parseInline(r.tokens));
+          continue;
+        }
+        case "text": {
+          for (c = r.tokens ? this.parseInline(r.tokens) : r.text; i + 1 < A && n[i + 1].type === "text"; )
+            r = n[++i], c += `
+` + (r.tokens ? this.parseInline(r.tokens) : r.text);
+          e += t ? this.renderer.paragraph(c) : c;
+          continue;
+        }
+        default: {
+          const v = 'Token with "' + r.type + '" type was not found.';
+          if (this.options.silent) {
+            console.error(v);
+            return;
+          } else
+            throw new Error(v);
+        }
+      }
+    }
+    return e;
+  }
+  /**
+   * Parse Inline Tokens
+   */
+  parseInline(n, t) {
+    t = t || this.renderer;
+    let e = "", i, s, l;
+    const o = n.length;
+    for (i = 0; i < o; i++) {
+      if (s = n[i], this.options.extensions && this.options.extensions.renderers && this.options.extensions.renderers[s.type] && (l = this.options.extensions.renderers[s.type].call({ parser: this }, s), l !== !1 || !["escape", "html", "link", "image", "strong", "em", "codespan", "br", "del", "text"].includes(s.type))) {
+        e += l || "";
+        continue;
+      }
+      switch (s.type) {
+        case "escape": {
+          e += t.text(s.text);
+          break;
+        }
+        case "html": {
+          e += t.html(s.text);
+          break;
+        }
+        case "link": {
+          e += t.link(s.href, s.title, this.parseInline(s.tokens, t));
+          break;
+        }
+        case "image": {
+          e += t.image(s.href, s.title, s.text);
+          break;
+        }
+        case "strong": {
+          e += t.strong(this.parseInline(s.tokens, t));
+          break;
+        }
+        case "em": {
+          e += t.em(this.parseInline(s.tokens, t));
+          break;
+        }
+        case "codespan": {
+          e += t.codespan(s.text);
+          break;
+        }
+        case "br": {
+          e += t.br();
+          break;
+        }
+        case "del": {
+          e += t.del(this.parseInline(s.tokens, t));
+          break;
+        }
+        case "text": {
+          e += t.text(s.text);
+          break;
+        }
+        default: {
+          const h = 'Token with "' + s.type + '" type was not found.';
+          if (this.options.silent) {
+            console.error(h);
+            return;
+          } else
+            throw new Error(h);
+        }
+      }
+    }
+    return e;
+  }
+}
+class O {
+  constructor(n) {
+    this.options = n || L;
+  }
+  /**
+   * Process markdown before marked
+   */
+  preprocess(n) {
+    return n;
+  }
+  /**
+   * Process HTML after marked is finished
+   */
+  postprocess(n) {
+    return n;
+  }
+}
+B(O, "passThroughHooks", /* @__PURE__ */ new Set([
+  "preprocess",
+  "postprocess"
+]));
+function we(a, n, t) {
+  return (e) => {
+    if (e.message += `
+Please report this to https://github.com/markedjs/marked.`, a) {
+      const i = "<p>An error occurred:</p><pre>" + z(e.message + "", !0) + "</pre>";
+      if (n)
+        return Promise.resolve(i);
+      if (t) {
+        t(null, i);
+        return;
+      }
+      return i;
+    }
+    if (n)
+      return Promise.reject(e);
+    if (t) {
+      t(e);
+      return;
+    }
+    throw e;
+  };
+}
+function ee(a, n) {
+  return (t, e, i) => {
+    typeof e == "function" && (i = e, e = null);
+    const s = { ...e };
+    e = { ...f.defaults, ...s };
+    const l = we(e.silent, e.async, i);
+    if (typeof t > "u" || t === null)
+      return l(new Error("marked(): input parameter is undefined or null"));
+    if (typeof t != "string")
+      return l(new Error("marked(): input parameter is of type " + Object.prototype.toString.call(t) + ", string expected"));
+    if (me(e), e.hooks && (e.hooks.options = e), i) {
+      const o = e.highlight;
+      let h;
+      try {
+        e.hooks && (t = e.hooks.preprocess(t)), h = a(t, e);
+      } catch (b) {
+        return l(b);
+      }
+      const w = function(b) {
+        let c;
+        if (!b)
+          try {
+            e.walkTokens && f.walkTokens(h, e.walkTokens), c = n(h, e), e.hooks && (c = e.hooks.postprocess(c));
+          } catch (r) {
+            b = r;
+          }
+        return e.highlight = o, b ? l(b) : i(null, c);
+      };
+      if (!o || o.length < 3 || (delete e.highlight, !h.length))
+        return w();
+      let x = 0;
+      f.walkTokens(h, function(b) {
+        b.type === "code" && (x++, setTimeout(() => {
+          o(b.text, b.lang, function(c, r) {
+            if (c)
+              return w(c);
+            r != null && r !== b.text && (b.text = r, b.escaped = !0), x--, x === 0 && w();
+          });
+        }, 0));
+      }), x === 0 && w();
+      return;
+    }
+    if (e.async)
+      return Promise.resolve(e.hooks ? e.hooks.preprocess(t) : t).then((o) => a(o, e)).then((o) => e.walkTokens ? Promise.all(f.walkTokens(o, e.walkTokens)).then(() => o) : o).then((o) => n(o, e)).then((o) => e.hooks ? e.hooks.postprocess(o) : o).catch(l);
+    try {
+      e.hooks && (t = e.hooks.preprocess(t));
+      const o = a(t, e);
+      e.walkTokens && f.walkTokens(o, e.walkTokens);
+      let h = n(o, e);
+      return e.hooks && (h = e.hooks.postprocess(h)), h;
+    } catch (o) {
+      return l(o);
+    }
+  };
+}
+function f(a, n, t) {
+  return ee(E.lex, I.parse)(a, n, t);
+}
+f.options = f.setOptions = function(a) {
+  return f.defaults = { ...f.defaults, ...a }, se(f.defaults), f;
+};
+f.getDefaults = X;
+f.defaults = L;
+f.use = function(...a) {
+  const n = f.defaults.extensions || { renderers: {}, childTokens: {} };
+  a.forEach((t) => {
+    const e = { ...t };
+    if (e.async = f.defaults.async || e.async || !1, t.extensions && (t.extensions.forEach((i) => {
+      if (!i.name)
+        throw new Error("extension name required");
+      if (i.renderer) {
+        const s = n.renderers[i.name];
+        s ? n.renderers[i.name] = function(...l) {
+          let o = i.renderer.apply(this, l);
+          return o === !1 && (o = s.apply(this, l)), o;
+        } : n.renderers[i.name] = i.renderer;
+      }
+      if (i.tokenizer) {
+        if (!i.level || i.level !== "block" && i.level !== "inline")
+          throw new Error("extension level must be 'block' or 'inline'");
+        n[i.level] ? n[i.level].unshift(i.tokenizer) : n[i.level] = [i.tokenizer], i.start && (i.level === "block" ? n.startBlock ? n.startBlock.push(i.start) : n.startBlock = [i.start] : i.level === "inline" && (n.startInline ? n.startInline.push(i.start) : n.startInline = [i.start]));
+      }
+      i.childTokens && (n.childTokens[i.name] = i.childTokens);
+    }), e.extensions = n), t.renderer) {
+      const i = f.defaults.renderer || new q();
+      for (const s in t.renderer) {
+        const l = i[s];
+        i[s] = (...o) => {
+          let h = t.renderer[s].apply(i, o);
+          return h === !1 && (h = l.apply(i, o)), h;
+        };
+      }
+      e.renderer = i;
+    }
+    if (t.tokenizer) {
+      const i = f.defaults.tokenizer || new N();
+      for (const s in t.tokenizer) {
+        const l = i[s];
+        i[s] = (...o) => {
+          let h = t.tokenizer[s].apply(i, o);
+          return h === !1 && (h = l.apply(i, o)), h;
+        };
+      }
+      e.tokenizer = i;
+    }
+    if (t.hooks) {
+      const i = f.defaults.hooks || new O();
+      for (const s in t.hooks) {
+        const l = i[s];
+        O.passThroughHooks.has(s) ? i[s] = (o) => {
+          if (f.defaults.async)
+            return Promise.resolve(t.hooks[s].call(i, o)).then((w) => l.call(i, w));
+          const h = t.hooks[s].call(i, o);
+          return l.call(i, h);
+        } : i[s] = (...o) => {
+          let h = t.hooks[s].apply(i, o);
+          return h === !1 && (h = l.apply(i, o)), h;
+        };
+      }
+      e.hooks = i;
+    }
+    if (t.walkTokens) {
+      const i = f.defaults.walkTokens;
+      e.walkTokens = function(s) {
+        let l = [];
+        return l.push(t.walkTokens.call(this, s)), i && (l = l.concat(i.call(this, s))), l;
+      };
+    }
+    f.setOptions(e);
+  });
+};
+f.walkTokens = function(a, n) {
+  let t = [];
+  for (const e of a)
+    switch (t = t.concat(n.call(f, e)), e.type) {
+      case "table": {
+        for (const i of e.header)
+          t = t.concat(f.walkTokens(i.tokens, n));
+        for (const i of e.rows)
+          for (const s of i)
+            t = t.concat(f.walkTokens(s.tokens, n));
+        break;
+      }
+      case "list": {
+        t = t.concat(f.walkTokens(e.items, n));
+        break;
+      }
+      default:
+        f.defaults.extensions && f.defaults.extensions.childTokens && f.defaults.extensions.childTokens[e.type] ? f.defaults.extensions.childTokens[e.type].forEach(function(i) {
+          t = t.concat(f.walkTokens(e[i], n));
+        }) : e.tokens && (t = t.concat(f.walkTokens(e.tokens, n)));
+    }
+  return t;
+};
+f.parseInline = ee(E.lexInline, I.parseInline);
+f.Parser = I;
+f.parser = I.parse;
+f.Renderer = q;
+f.TextRenderer = K;
+f.Lexer = E;
+f.lexer = E.lex;
+f.Tokenizer = N;
+f.Slugger = Y;
+f.Hooks = O;
+f.parse = f;
+f.options;
+f.setOptions;
+f.use;
+f.walkTokens;
+f.parseInline;
+I.parse;
+E.lex;
+/*!
+ * The reveal.js markdown plugin. Handles parsing of
+ * markdown inside of presentations as well as loading
+ * of external markdown documents.
+ */
+const _e = `\r?
+---\r?
+`, ye = null, $e = "^s*notes?:", Se = "\\.element\\s*?(.+?)$", Te = "\\.slide:\\s*?(\\S.+?)$", V = "__SCRIPT_END__", M = /\[\s*((\d*):)?\s*([\s\d,|-]*)\]/, Re = {
+  "&": "&amp;",
+  "<": "&lt;",
+  ">": "&gt;",
+  '"': "&quot;",
+  "'": "&#39;"
+}, Ae = () => {
+  let a;
+  function n(c) {
+    let m = (c.querySelector("[data-template]") || c.querySelector("script") || c).textContent;
+    m = m.replace(new RegExp(V, "g"), "<\/script>");
+    const g = m.match(/^\n?(\s*)/)[1].length, y = m.match(/^\n?(\t*)/)[1].length;
+    return y > 0 ? m = m.replace(new RegExp("\\n?\\t{" + y + "}(.*)", "g"), function(p, k) {
+      return `
+` + k;
+    }) : g > 1 && (m = m.replace(new RegExp("\\n? {" + g + "}(.*)", "g"), function(p, k) {
+      return `
+` + k;
+    })), m;
+  }
+  function t(c) {
+    const r = c.attributes, m = [];
+    for (let g = 0, y = r.length; g < y; g++) {
+      const p = r[g].name, k = r[g].value;
+      /data\-(markdown|separator|vertical|notes)/gi.test(p) || (k ? m.push(p + '="' + k + '"') : m.push(p));
+    }
+    return m.join(" ");
+  }
+  function e(c) {
+    var m;
+    const r = (m = a == null ? void 0 : a.getConfig) == null ? void 0 : m.call(a).markdown;
+    return c = c || {}, c.separator = c.separator || (r == null ? void 0 : r.separator) || _e, c.verticalSeparator = c.verticalSeparator || (r == null ? void 0 : r.verticalSeparator) || ye, c.notesSeparator = c.notesSeparator || (r == null ? void 0 : r.notesSeparator) || $e, c.attributes = c.attributes || "", c;
+  }
+  function i(c, r) {
+    r = e(r);
+    const m = c.split(new RegExp(r.notesSeparator, "mgi"));
+    return m.length === 2 && (c = m[0] + '<aside class="notes">' + f(m[1].trim()) + "</aside>"), c = c.replace(/<\/script>/g, V), '<script type="text/template">' + c + "<\/script>";
+  }
+  function s(c, r) {
+    r = e(r);
+    const m = new RegExp(r.separator + (r.verticalSeparator ? "|" + r.verticalSeparator : ""), "mg"), g = new RegExp(r.separator);
+    let y, p = 0, k, _ = !0, T, $ = [];
+    for (; y = m.exec(c); )
+      k = g.test(y[0]), !k && _ && $.push([]), T = c.substring(p, y.index), k && _ ? $.push(T) : $[$.length - 1].push(T), p = m.lastIndex, _ = k;
+    (_ ? $ : $[$.length - 1]).push(c.substring(p));
+    let R = "";
+    for (let A = 0, v = $.length; A < v; A++)
+      $[A] instanceof Array ? (R += "<section " + r.attributes + ">", $[A].forEach(function(te) {
+        R += "<section data-markdown>" + i(te, r) + "</section>";
+      }), R += "</section>") : R += "<section " + r.attributes + " data-markdown>" + i($[A], r) + "</section>";
+    return R;
+  }
+  function l(c) {
+    return new Promise(function(r) {
+      const m = [];
+      [].slice.call(c.querySelectorAll("section[data-markdown]:not([data-markdown-parsed])")).forEach(function(g, y) {
+        g.getAttribute("data-markdown").length ? m.push(o(g).then(
+          // Finished loading external file
+          function(p, k) {
+            g.outerHTML = s(p.responseText, {
+              separator: g.getAttribute("data-separator"),
+              verticalSeparator: g.getAttribute("data-separator-vertical"),
+              notesSeparator: g.getAttribute("data-separator-notes"),
+              attributes: t(g)
+            });
+          },
+          // Failed to load markdown
+          function(p, k) {
+            g.outerHTML = '<section data-state="alert">ERROR: The attempt to fetch ' + k + " failed with HTTP status " + p.status + ".Check your browser's JavaScript console for more details.<p>Remember that you need to serve the presentation HTML from a HTTP server.</p></section>";
+          }
+        )) : g.outerHTML = s(n(g), {
+          separator: g.getAttribute("data-separator"),
+          verticalSeparator: g.getAttribute("data-separator-vertical"),
+          notesSeparator: g.getAttribute("data-separator-notes"),
+          attributes: t(g)
+        });
+      }), Promise.all(m).then(r);
+    });
+  }
+  function o(c) {
+    return new Promise(function(r, m) {
+      const g = new XMLHttpRequest(), y = c.getAttribute("data-markdown"), p = c.getAttribute("data-charset");
+      p !== null && p !== "" && g.overrideMimeType("text/html; charset=" + p), g.onreadystatechange = (function(k, _) {
+        _.readyState === 4 && (_.status >= 200 && _.status < 300 || _.status === 0 ? r(_, y) : m(_, y));
+      }).bind(this, c, g), g.open("GET", y, !0);
+      try {
+        g.send();
+      } catch (k) {
+        console.warn("Failed to get the Markdown file " + y + ". Make sure that the presentation and the file are served by a HTTP server and the file can be found there. " + k), r(g, y);
+      }
+    });
+  }
+  function h(c, r, m) {
+    const g = new RegExp(m, "mg"), y = new RegExp('([^"= ]+?)="([^"]+?)"|(data-[^"= ]+?)(?=[" ])', "mg");
+    let p = c.nodeValue, k, _;
+    if (k = g.exec(p)) {
+      const T = k[1];
+      for (p = p.substring(0, k.index) + p.substring(g.lastIndex), c.nodeValue = p; _ = y.exec(T); )
+        _[2] ? r.setAttribute(_[1], _[2]) : r.setAttribute(_[3], "");
+      return !0;
+    }
+    return !1;
+  }
+  function w(c, r, m, g, y) {
+    if (r !== null && r.childNodes !== void 0 && r.childNodes.length > 0) {
+      let p = r;
+      for (let k = 0; k < r.childNodes.length; k++) {
+        const _ = r.childNodes[k];
+        if (k > 0) {
+          let $ = k - 1;
+          for (; $ >= 0; ) {
+            const R = r.childNodes[$];
+            if (typeof R.setAttribute == "function" && R.tagName !== "BR") {
+              p = R;
+              break;
+            }
+            $ = $ - 1;
+          }
+        }
+        let T = c;
+        _.nodeName === "section" && (T = _, p = _), (typeof _.setAttribute == "function" || _.nodeType === Node.COMMENT_NODE) && w(T, _, p, g, y);
+      }
+    }
+    r.nodeType === Node.COMMENT_NODE && h(r, m, g) === !1 && h(r, c, y);
+  }
+  function x() {
+    const c = a.getRevealElement().querySelectorAll("[data-markdown]:not([data-markdown-parsed])");
+    return [].slice.call(c).forEach(function(r) {
+      r.setAttribute("data-markdown-parsed", !0);
+      const m = r.querySelector("aside.notes"), g = n(r);
+      r.innerHTML = f(g), w(
+        r,
+        r,
+        null,
+        r.getAttribute("data-element-attributes") || r.parentNode.getAttribute("data-element-attributes") || Se,
+        r.getAttribute("data-attributes") || r.parentNode.getAttribute("data-attributes") || Te
+      ), m && r.appendChild(m);
+    }), Promise.resolve();
+  }
+  function b(c) {
+    return c.replace(/([&<>'"])/g, (r) => Re[r]);
+  }
+  return {
+    id: "markdown",
+    /**
+     * Starts processing and converting Markdown within the
+     * current reveal.js deck.
+     */
+    init: function(c) {
+      a = c;
+      let { renderer: r, animateLists: m, ...g } = a.getConfig().markdown || {};
+      return r || (r = new f.Renderer(), r.code = (y, p) => {
+        let k = "", _ = "";
+        if (M.test(p)) {
+          let T = p.match(M)[2];
+          T && (k = `data-ln-start-from="${T.trim()}"`), _ = p.match(M)[3].trim(), _ = `data-line-numbers="${_}"`, p = p.replace(M, "").trim();
+        }
+        return y = b(y), `<pre><code ${_} ${k} class="${p}">${y}</code></pre>`;
+      }), m === !0 && (r.listitem = (y) => `<li class="fragment">${y}</li>`), f.setOptions({
+        renderer: r,
+        ...g
+      }), l(a.getRevealElement()).then(x);
+    },
+    // TODO: Do these belong in the API?
+    processSlides: l,
+    convertSlides: x,
+    slidify: s,
+    marked: f
+  };
+};
+export {
+  Ae as default
+};

Filskillnaden har hållts tillbaka eftersom den är för stor
+ 0 - 0
dist/plugin/math.js


+ 119 - 0
dist/plugin/math.mjs

@@ -0,0 +1,119 @@
+const M = () => {
+  let n, s = {
+    version: "latest",
+    delimiters: [
+      { left: "$$", right: "$$", display: !0 },
+      // Note: $$ has to come before $
+      { left: "$", right: "$", display: !1 },
+      { left: "\\(", right: "\\)", display: !1 },
+      { left: "\\[", right: "\\]", display: !0 }
+    ],
+    ignoredTags: ["script", "noscript", "style", "textarea", "pre"]
+  };
+  const r = (t) => {
+    let e = document.createElement("link");
+    e.rel = "stylesheet", e.href = t, document.head.appendChild(e);
+  }, l = (t) => new Promise((e, i) => {
+    const o = document.createElement("script");
+    o.type = "text/javascript", o.onload = e, o.onerror = i, o.src = t, document.head.append(o);
+  });
+  async function a(t) {
+    for (const e of t)
+      await l(e);
+  }
+  return {
+    id: "katex",
+    init: function(t) {
+      n = t;
+      let e = n.getConfig().katex || {}, i = { ...s, ...e };
+      const { local: o, version: u, extensions: k, ...m } = i;
+      let c = i.local || "https://cdn.jsdelivr.net/npm/katex", d = i.local ? "" : "@" + i.version, f = c + d + "/dist/katex.min.css", y = c + d + "/dist/katex.min.js", g = c + d + "/dist/contrib/mhchem.min.js", j = c + d + "/dist/contrib/auto-render.min.js", p = [y];
+      i.extensions && i.extensions.includes("mhchem") && p.push(g), p.push(j);
+      const h = () => {
+        renderMathInElement(t.getSlidesElement(), m), n.layout();
+      };
+      r(f), a(p).then(() => {
+        n.isReady() ? h() : n.on("ready", h.bind(this));
+      });
+    }
+  };
+}, x = () => {
+  let n, s = {
+    messageStyle: "none",
+    tex2jax: {
+      inlineMath: [["$", "$"], ["\\(", "\\)"]],
+      skipTags: ["script", "noscript", "style", "textarea", "pre"]
+    },
+    skipStartupTypeset: !0
+  };
+  function r(l, a) {
+    let t = document.querySelector("head"), e = document.createElement("script");
+    e.type = "text/javascript", e.src = l;
+    let i = () => {
+      typeof a == "function" && (a.call(), a = null);
+    };
+    e.onload = i, e.onreadystatechange = () => {
+      this.readyState === "loaded" && i();
+    }, t.appendChild(e);
+  }
+  return {
+    id: "mathjax2",
+    init: function(l) {
+      n = l;
+      let a = n.getConfig().mathjax2 || n.getConfig().math || {}, t = { ...s, ...a }, e = t.mathjax || "https://cdn.jsdelivr.net/npm/mathjax@2/MathJax.js", i = t.config || "TeX-AMS_HTML-full", o = e + "?config=" + i;
+      t.tex2jax = { ...s.tex2jax, ...a.tex2jax }, t.mathjax = t.config = null, r(o, function() {
+        MathJax.Hub.Config(t), MathJax.Hub.Queue(["Typeset", MathJax.Hub, n.getRevealElement()]), MathJax.Hub.Queue(n.layout), n.on("slidechanged", function(u) {
+          MathJax.Hub.Queue(["Typeset", MathJax.Hub, u.currentSlide]);
+        });
+      });
+    }
+  };
+}, v = () => {
+  let n, s = {
+    tex: {
+      inlineMath: [["$", "$"], ["\\(", "\\)"]]
+    },
+    options: {
+      skipHtmlTags: ["script", "noscript", "style", "textarea", "pre"]
+    },
+    startup: {
+      ready: () => {
+        MathJax.startup.defaultReady(), MathJax.startup.promise.then(() => {
+          n.layout();
+        });
+      }
+    }
+  };
+  function r(l, a) {
+    let t = document.createElement("script");
+    t.type = "text/javascript", t.id = "MathJax-script", t.src = l, t.async = !0, t.onload = () => {
+      typeof a == "function" && (a.call(), a = null);
+    }, document.head.appendChild(t);
+  }
+  return {
+    id: "mathjax3",
+    init: function(l) {
+      n = l;
+      let a = n.getConfig().mathjax3 || {}, t = { ...s, ...a };
+      t.tex = { ...s.tex, ...a.tex }, t.options = { ...s.options, ...a.options }, t.startup = { ...s.startup, ...a.startup };
+      let e = t.mathjax || "https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js";
+      t.mathjax = null, window.MathJax = t, r(e, function() {
+        n.addEventListener("slidechanged", function(i) {
+          MathJax.typeset();
+        });
+      });
+    }
+  };
+}, J = x;
+/*!
+ * This plugin is a wrapper for the MathJax2,
+ * MathJax3 and KaTeX typesetter plugins.
+ */
+const S = Plugin = Object.assign(J(), {
+  KaTeX: M,
+  MathJax2: x,
+  MathJax3: v
+});
+export {
+  S as default
+};

Filskillnaden har hållts tillbaka eftersom den är för stor
+ 897 - 0
dist/plugin/notes.js


+ 2548 - 0
dist/plugin/notes.mjs

@@ -0,0 +1,2548 @@
+var G = Object.defineProperty;
+var tt = (l, n, e) => n in l ? G(l, n, { enumerable: !0, configurable: !0, writable: !0, value: e }) : l[n] = e;
+var D = (l, n, e) => (tt(l, typeof n != "symbol" ? n + "" : n, e), e);
+const et = `<!--
+	NOTE: You need to build the notes plugin after making changes to this file.
+-->
+<html lang="en">
+	<head>
+		<meta charset="utf-8">
+
+		<title>reveal.js - Speaker View</title>
+
+		<style>
+			body {
+				font-family: Helvetica;
+				font-size: 18px;
+			}
+
+			#current-slide,
+			#upcoming-slide,
+			#speaker-controls {
+				padding: 6px;
+				box-sizing: border-box;
+				-moz-box-sizing: border-box;
+			}
+
+			#current-slide iframe,
+			#upcoming-slide iframe {
+				width: 100%;
+				height: 100%;
+				border: 1px solid #ddd;
+			}
+
+			#current-slide .label,
+			#upcoming-slide .label {
+				position: absolute;
+				top: 10px;
+				left: 10px;
+				z-index: 2;
+			}
+
+			#connection-status {
+				position: absolute;
+				top: 0;
+				left: 0;
+				width: 100%;
+				height: 100%;
+				z-index: 20;
+				padding: 30% 20% 20% 20%;
+				font-size: 18px;
+				color: #222;
+				background: #fff;
+				text-align: center;
+				box-sizing: border-box;
+				line-height: 1.4;
+			}
+
+			.overlay-element {
+				height: 34px;
+				line-height: 34px;
+				padding: 0 10px;
+				text-shadow: none;
+				background: rgba( 220, 220, 220, 0.8 );
+				color: #222;
+				font-size: 14px;
+			}
+
+			.overlay-element.interactive:hover {
+				background: rgba( 220, 220, 220, 1 );
+			}
+
+			#current-slide {
+				position: absolute;
+				width: 60%;
+				height: 100%;
+				top: 0;
+				left: 0;
+				padding-right: 0;
+			}
+
+			#upcoming-slide {
+				position: absolute;
+				width: 40%;
+				height: 40%;
+				right: 0;
+				top: 0;
+			}
+
+			/* Speaker controls */
+			#speaker-controls {
+				position: absolute;
+				top: 40%;
+				right: 0;
+				width: 40%;
+				height: 60%;
+				overflow: auto;
+				font-size: 18px;
+			}
+
+				.speaker-controls-time.hidden,
+				.speaker-controls-notes.hidden {
+					display: none;
+				}
+
+				.speaker-controls-time .label,
+				.speaker-controls-pace .label,
+				.speaker-controls-notes .label {
+					text-transform: uppercase;
+					font-weight: normal;
+					font-size: 0.66em;
+					color: #666;
+					margin: 0;
+				}
+
+				.speaker-controls-time, .speaker-controls-pace {
+					border-bottom: 1px solid rgba( 200, 200, 200, 0.5 );
+					margin-bottom: 10px;
+					padding: 10px 16px;
+					padding-bottom: 20px;
+					cursor: pointer;
+				}
+
+				.speaker-controls-time .reset-button {
+					opacity: 0;
+					float: right;
+					color: #666;
+					text-decoration: none;
+				}
+				.speaker-controls-time:hover .reset-button {
+					opacity: 1;
+				}
+
+				.speaker-controls-time .timer,
+				.speaker-controls-time .clock {
+					width: 50%;
+				}
+
+				.speaker-controls-time .timer,
+				.speaker-controls-time .clock,
+				.speaker-controls-time .pacing .hours-value,
+				.speaker-controls-time .pacing .minutes-value,
+				.speaker-controls-time .pacing .seconds-value {
+					font-size: 1.9em;
+				}
+
+				.speaker-controls-time .timer {
+					float: left;
+				}
+
+				.speaker-controls-time .clock {
+					float: right;
+					text-align: right;
+				}
+
+				.speaker-controls-time span.mute {
+					opacity: 0.3;
+				}
+
+				.speaker-controls-time .pacing-title {
+					margin-top: 5px;
+				}
+
+				.speaker-controls-time .pacing.ahead {
+					color: blue;
+				}
+
+				.speaker-controls-time .pacing.on-track {
+					color: green;
+				}
+
+				.speaker-controls-time .pacing.behind {
+					color: red;
+				}
+
+				.speaker-controls-notes {
+					padding: 10px 16px;
+				}
+
+				.speaker-controls-notes .value {
+					margin-top: 5px;
+					line-height: 1.4;
+					font-size: 1.2em;
+				}
+
+			/* Layout selector */
+			#speaker-layout {
+				position: absolute;
+				top: 10px;
+				right: 10px;
+				color: #222;
+				z-index: 10;
+			}
+				#speaker-layout select {
+					position: absolute;
+					width: 100%;
+					height: 100%;
+					top: 0;
+					left: 0;
+					border: 0;
+					box-shadow: 0;
+					cursor: pointer;
+					opacity: 0;
+
+					font-size: 1em;
+					background-color: transparent;
+
+					-moz-appearance: none;
+					-webkit-appearance: none;
+					-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
+				}
+
+				#speaker-layout select:focus {
+					outline: none;
+					box-shadow: none;
+				}
+
+			.clear {
+				clear: both;
+			}
+
+			/* Speaker layout: Wide */
+			body[data-speaker-layout="wide"] #current-slide,
+			body[data-speaker-layout="wide"] #upcoming-slide {
+				width: 50%;
+				height: 45%;
+				padding: 6px;
+			}
+
+			body[data-speaker-layout="wide"] #current-slide {
+				top: 0;
+				left: 0;
+			}
+
+			body[data-speaker-layout="wide"] #upcoming-slide {
+				top: 0;
+				left: 50%;
+			}
+
+			body[data-speaker-layout="wide"] #speaker-controls {
+				top: 45%;
+				left: 0;
+				width: 100%;
+				height: 50%;
+				font-size: 1.25em;
+			}
+
+			/* Speaker layout: Tall */
+			body[data-speaker-layout="tall"] #current-slide,
+			body[data-speaker-layout="tall"] #upcoming-slide {
+				width: 45%;
+				height: 50%;
+				padding: 6px;
+			}
+
+			body[data-speaker-layout="tall"] #current-slide {
+				top: 0;
+				left: 0;
+			}
+
+			body[data-speaker-layout="tall"] #upcoming-slide {
+				top: 50%;
+				left: 0;
+			}
+
+			body[data-speaker-layout="tall"] #speaker-controls {
+				padding-top: 40px;
+				top: 0;
+				left: 45%;
+				width: 55%;
+				height: 100%;
+				font-size: 1.25em;
+			}
+
+			/* Speaker layout: Notes only */
+			body[data-speaker-layout="notes-only"] #current-slide,
+			body[data-speaker-layout="notes-only"] #upcoming-slide {
+				display: none;
+			}
+
+			body[data-speaker-layout="notes-only"] #speaker-controls {
+				padding-top: 40px;
+				top: 0;
+				left: 0;
+				width: 100%;
+				height: 100%;
+				font-size: 1.25em;
+			}
+
+			@media screen and (max-width: 1080px) {
+				body[data-speaker-layout="default"] #speaker-controls {
+					font-size: 16px;
+				}
+			}
+
+			@media screen and (max-width: 900px) {
+				body[data-speaker-layout="default"] #speaker-controls {
+					font-size: 14px;
+				}
+			}
+
+			@media screen and (max-width: 800px) {
+				body[data-speaker-layout="default"] #speaker-controls {
+					font-size: 12px;
+				}
+			}
+
+		</style>
+	</head>
+
+	<body>
+
+		<div id="connection-status">Loading speaker view...</div>
+
+		<div id="current-slide"></div>
+		<div id="upcoming-slide"><span class="overlay-element label">Upcoming</span></div>
+		<div id="speaker-controls">
+			<div class="speaker-controls-time">
+				<h4 class="label">Time <span class="reset-button">Click to Reset</span></h4>
+				<div class="clock">
+					<span class="clock-value">0:00 AM</span>
+				</div>
+				<div class="timer">
+					<span class="hours-value">00</span><span class="minutes-value">:00</span><span class="seconds-value">:00</span>
+				</div>
+				<div class="clear"></div>
+
+				<h4 class="label pacing-title" style="display: none">Pacing – Time to finish current slide</h4>
+				<div class="pacing" style="display: none">
+					<span class="hours-value">00</span><span class="minutes-value">:00</span><span class="seconds-value">:00</span>
+				</div>
+			</div>
+
+			<div class="speaker-controls-notes hidden">
+				<h4 class="label">Notes</h4>
+				<div class="value"></div>
+			</div>
+		</div>
+		<div id="speaker-layout" class="overlay-element interactive">
+			<span class="speaker-layout-label"></span>
+			<select class="speaker-layout-dropdown"></select>
+		</div>
+
+		<script>
+
+			(function() {
+
+				var notes,
+					notesValue,
+					currentState,
+					currentSlide,
+					upcomingSlide,
+					layoutLabel,
+					layoutDropdown,
+					pendingCalls = {},
+					lastRevealApiCallId = 0,
+					connected = false
+
+				var connectionStatus = document.querySelector( '#connection-status' );
+
+				var SPEAKER_LAYOUTS = {
+					'default': 'Default',
+					'wide': 'Wide',
+					'tall': 'Tall',
+					'notes-only': 'Notes only'
+				};
+
+				setupLayout();
+
+				let openerOrigin;
+
+				try {
+					openerOrigin = window.opener.location.origin;
+				}
+				catch ( error ) { console.warn( error ) }
+
+				// In order to prevent XSS, the speaker view will only run if its
+				// opener has the same origin as itself
+				if( window.location.origin !== openerOrigin ) {
+					connectionStatus.innerHTML = 'Cross origin error.<br>The speaker window can only be opened from the same origin.';
+					return;
+				}
+
+				var connectionTimeout = setTimeout( function() {
+					connectionStatus.innerHTML = 'Error connecting to main window.<br>Please try closing and reopening the speaker view.';
+				}, 5000 );
+
+				window.addEventListener( 'message', function( event ) {
+
+					// Validate the origin of all messages to avoid parsing messages
+					// that aren't meant for us. Ignore when running off file:// so
+					// that the speaker view continues to work without a web server.
+					if( window.location.origin !== event.origin && window.location.origin !== 'file://' ) {
+						return
+					}
+
+					clearTimeout( connectionTimeout );
+					connectionStatus.style.display = 'none';
+
+					var data = JSON.parse( event.data );
+
+					// The overview mode is only useful to the reveal.js instance
+					// where navigation occurs so we don't sync it
+					if( data.state ) delete data.state.overview;
+
+					// Messages sent by the notes plugin inside of the main window
+					if( data && data.namespace === 'reveal-notes' ) {
+						if( data.type === 'connect' ) {
+							handleConnectMessage( data );
+						}
+						else if( data.type === 'state' ) {
+							handleStateMessage( data );
+						}
+						else if( data.type === 'return' ) {
+							pendingCalls[data.callId](data.result);
+							delete pendingCalls[data.callId];
+						}
+					}
+					// Messages sent by the reveal.js inside of the current slide preview
+					else if( data && data.namespace === 'reveal' ) {
+						if( /ready/.test( data.eventName ) ) {
+							// Send a message back to notify that the handshake is complete
+							window.opener.postMessage( JSON.stringify({ namespace: 'reveal-notes', type: 'connected'} ), '*' );
+						}
+						else if( /slidechanged|fragmentshown|fragmenthidden|paused|resumed/.test( data.eventName ) && currentState !== JSON.stringify( data.state ) ) {
+
+							dispatchStateToMainWindow( data.state );
+
+						}
+					}
+
+				} );
+
+				/**
+				 * Updates the presentation in the main window to match the state
+				 * of the presentation in the notes window.
+				 */
+				const dispatchStateToMainWindow = debounce(( state ) => {
+					window.opener.postMessage( JSON.stringify({ method: 'setState', args: [ state ]} ), '*' );
+				}, 500);
+
+				/**
+				 * Asynchronously calls the Reveal.js API of the main frame.
+				 */
+				function callRevealApi( methodName, methodArguments, callback ) {
+
+					var callId = ++lastRevealApiCallId;
+					pendingCalls[callId] = callback;
+					window.opener.postMessage( JSON.stringify( {
+						namespace: 'reveal-notes',
+						type: 'call',
+						callId: callId,
+						methodName: methodName,
+						arguments: methodArguments
+					} ), '*' );
+
+				}
+
+				/**
+				 * Called when the main window is trying to establish a
+				 * connection.
+				 */
+				function handleConnectMessage( data ) {
+
+					if( connected === false ) {
+						connected = true;
+
+						setupIframes( data );
+						setupKeyboard();
+						setupNotes();
+						setupTimer();
+						setupHeartbeat();
+					}
+
+				}
+
+				/**
+				 * Called when the main window sends an updated state.
+				 */
+				function handleStateMessage( data ) {
+
+					// Store the most recently set state to avoid circular loops
+					// applying the same state
+					currentState = JSON.stringify( data.state );
+
+					// No need for updating the notes in case of fragment changes
+					if ( data.notes ) {
+						notes.classList.remove( 'hidden' );
+						notesValue.style.whiteSpace = data.whitespace;
+						if( data.markdown ) {
+							notesValue.innerHTML = marked( data.notes );
+						}
+						else {
+							notesValue.innerHTML = data.notes;
+						}
+					}
+					else {
+						notes.classList.add( 'hidden' );
+					}
+
+					// Update the note slides
+					currentSlide.contentWindow.postMessage( JSON.stringify({ method: 'setState', args: [ data.state ] }), '*' );
+					upcomingSlide.contentWindow.postMessage( JSON.stringify({ method: 'setState', args: [ data.state ] }), '*' );
+					upcomingSlide.contentWindow.postMessage( JSON.stringify({ method: 'next' }), '*' );
+
+				}
+
+				// Limit to max one state update per X ms
+				handleStateMessage = debounce( handleStateMessage, 200 );
+
+				/**
+				 * Forward keyboard events to the current slide window.
+				 * This enables keyboard events to work even if focus
+				 * isn't set on the current slide iframe.
+				 *
+				 * Block F5 default handling, it reloads and disconnects
+				 * the speaker notes window.
+				 */
+				function setupKeyboard() {
+
+					document.addEventListener( 'keydown', function( event ) {
+						if( event.keyCode === 116 || ( event.metaKey && event.keyCode === 82 ) ) {
+							event.preventDefault();
+							return false;
+						}
+						currentSlide.contentWindow.postMessage( JSON.stringify({ method: 'triggerKey', args: [ event.keyCode ] }), '*' );
+					} );
+
+				}
+
+				/**
+				 * Creates the preview iframes.
+				 */
+				function setupIframes( data ) {
+
+					var params = [
+						'receiver',
+						'progress=false',
+						'history=false',
+						'transition=none',
+						'autoSlide=0',
+						'backgroundTransition=none'
+					].join( '&' );
+
+					var urlSeparator = /\\?/.test(data.url) ? '&' : '?';
+					var hash = '#/' + data.state.indexh + '/' + data.state.indexv;
+					var currentURL = data.url + urlSeparator + params + '&scrollActivationWidth=false&postMessageEvents=true' + hash;
+					var upcomingURL = data.url + urlSeparator + params + '&scrollActivationWidth=false&controls=false' + hash;
+
+					currentSlide = document.createElement( 'iframe' );
+					currentSlide.setAttribute( 'width', 1280 );
+					currentSlide.setAttribute( 'height', 1024 );
+					currentSlide.setAttribute( 'src', currentURL );
+					document.querySelector( '#current-slide' ).appendChild( currentSlide );
+
+					upcomingSlide = document.createElement( 'iframe' );
+					upcomingSlide.setAttribute( 'width', 640 );
+					upcomingSlide.setAttribute( 'height', 512 );
+					upcomingSlide.setAttribute( 'src', upcomingURL );
+					document.querySelector( '#upcoming-slide' ).appendChild( upcomingSlide );
+
+				}
+
+				/**
+				 * Setup the notes UI.
+				 */
+				function setupNotes() {
+
+					notes = document.querySelector( '.speaker-controls-notes' );
+					notesValue = document.querySelector( '.speaker-controls-notes .value' );
+
+				}
+
+				/**
+				 * We send out a heartbeat at all times to ensure we can
+				 * reconnect with the main presentation window after reloads.
+				 */
+				function setupHeartbeat() {
+
+					setInterval( () => {
+						window.opener.postMessage( JSON.stringify({ namespace: 'reveal-notes', type: 'heartbeat'} ), '*' );
+					}, 1000 );
+
+				}
+
+				function getTimings( callback ) {
+
+					callRevealApi( 'getSlidesAttributes', [], function ( slideAttributes ) {
+						callRevealApi( 'getConfig', [], function ( config ) {
+							var totalTime = config.totalTime;
+							var minTimePerSlide = config.minimumTimePerSlide || 0;
+							var defaultTiming = config.defaultTiming;
+							if ((defaultTiming == null) && (totalTime == null)) {
+								callback(null);
+								return;
+							}
+							// Setting totalTime overrides defaultTiming
+							if (totalTime) {
+								defaultTiming = 0;
+							}
+							var timings = [];
+							for ( var i in slideAttributes ) {
+								var slide = slideAttributes[ i ];
+								var timing = defaultTiming;
+								if( slide.hasOwnProperty( 'data-timing' )) {
+									var t = slide[ 'data-timing' ];
+									timing = parseInt(t);
+									if( isNaN(timing) ) {
+										console.warn("Could not parse timing '" + t + "' of slide " + i + "; using default of " + defaultTiming);
+										timing = defaultTiming;
+									}
+								}
+								timings.push(timing);
+							}
+							if ( totalTime ) {
+								// After we've allocated time to individual slides, we summarize it and
+								// subtract it from the total time
+								var remainingTime = totalTime - timings.reduce( function(a, b) { return a + b; }, 0 );
+								// The remaining time is divided by the number of slides that have 0 seconds
+								// allocated at the moment, giving the average time-per-slide on the remaining slides
+								var remainingSlides = (timings.filter( function(x) { return x == 0 }) ).length
+								var timePerSlide = Math.round( remainingTime / remainingSlides, 0 )
+								// And now we replace every zero-value timing with that average
+								timings = timings.map( function(x) { return (x==0 ? timePerSlide : x) } );
+							}
+							var slidesUnderMinimum = timings.filter( function(x) { return (x < minTimePerSlide) } ).length
+							if ( slidesUnderMinimum ) {
+								message = "The pacing time for " + slidesUnderMinimum + " slide(s) is under the configured minimum of " + minTimePerSlide + " seconds. Check the data-timing attribute on individual slides, or consider increasing the totalTime or minimumTimePerSlide configuration options (or removing some slides).";
+								alert(message);
+							}
+							callback( timings );
+						} );
+					} );
+
+				}
+
+				/**
+				 * Return the number of seconds allocated for presenting
+				 * all slides up to and including this one.
+				 */
+				function getTimeAllocated( timings, callback ) {
+
+					callRevealApi( 'getSlidePastCount', [], function ( currentSlide ) {
+						var allocated = 0;
+						for (var i in timings.slice(0, currentSlide + 1)) {
+							allocated += timings[i];
+						}
+						callback( allocated );
+					} );
+
+				}
+
+				/**
+				 * Create the timer and clock and start updating them
+				 * at an interval.
+				 */
+				function setupTimer() {
+
+					var start = new Date(),
+					timeEl = document.querySelector( '.speaker-controls-time' ),
+					clockEl = timeEl.querySelector( '.clock-value' ),
+					hoursEl = timeEl.querySelector( '.hours-value' ),
+					minutesEl = timeEl.querySelector( '.minutes-value' ),
+					secondsEl = timeEl.querySelector( '.seconds-value' ),
+					pacingTitleEl = timeEl.querySelector( '.pacing-title' ),
+					pacingEl = timeEl.querySelector( '.pacing' ),
+					pacingHoursEl = pacingEl.querySelector( '.hours-value' ),
+					pacingMinutesEl = pacingEl.querySelector( '.minutes-value' ),
+					pacingSecondsEl = pacingEl.querySelector( '.seconds-value' );
+
+					var timings = null;
+					getTimings( function ( _timings ) {
+
+						timings = _timings;
+						if (_timings !== null) {
+							pacingTitleEl.style.removeProperty('display');
+							pacingEl.style.removeProperty('display');
+						}
+
+						// Update once directly
+						_updateTimer();
+
+						// Then update every second
+						setInterval( _updateTimer, 1000 );
+
+					} );
+
+
+					function _resetTimer() {
+
+						if (timings == null) {
+							start = new Date();
+							_updateTimer();
+						}
+						else {
+							// Reset timer to beginning of current slide
+							getTimeAllocated( timings, function ( slideEndTimingSeconds ) {
+								var slideEndTiming = slideEndTimingSeconds * 1000;
+								callRevealApi( 'getSlidePastCount', [], function ( currentSlide ) {
+									var currentSlideTiming = timings[currentSlide] * 1000;
+									var previousSlidesTiming = slideEndTiming - currentSlideTiming;
+									var now = new Date();
+									start = new Date(now.getTime() - previousSlidesTiming);
+									_updateTimer();
+								} );
+							} );
+						}
+
+					}
+
+					timeEl.addEventListener( 'click', function() {
+						_resetTimer();
+						return false;
+					} );
+
+					function _displayTime( hrEl, minEl, secEl, time) {
+
+						var sign = Math.sign(time) == -1 ? "-" : "";
+						time = Math.abs(Math.round(time / 1000));
+						var seconds = time % 60;
+						var minutes = Math.floor( time / 60 ) % 60 ;
+						var hours = Math.floor( time / ( 60 * 60 )) ;
+						hrEl.innerHTML = sign + zeroPadInteger( hours );
+						if (hours == 0) {
+							hrEl.classList.add( 'mute' );
+						}
+						else {
+							hrEl.classList.remove( 'mute' );
+						}
+						minEl.innerHTML = ':' + zeroPadInteger( minutes );
+						if (hours == 0 && minutes == 0) {
+							minEl.classList.add( 'mute' );
+						}
+						else {
+							minEl.classList.remove( 'mute' );
+						}
+						secEl.innerHTML = ':' + zeroPadInteger( seconds );
+					}
+
+					function _updateTimer() {
+
+						var diff, hours, minutes, seconds,
+						now = new Date();
+
+						diff = now.getTime() - start.getTime();
+
+						clockEl.innerHTML = now.toLocaleTimeString( 'en-US', { hour12: true, hour: '2-digit', minute:'2-digit' } );
+						_displayTime( hoursEl, minutesEl, secondsEl, diff );
+						if (timings !== null) {
+							_updatePacing(diff);
+						}
+
+					}
+
+					function _updatePacing(diff) {
+
+						getTimeAllocated( timings, function ( slideEndTimingSeconds ) {
+							var slideEndTiming = slideEndTimingSeconds * 1000;
+
+							callRevealApi( 'getSlidePastCount', [], function ( currentSlide ) {
+								var currentSlideTiming = timings[currentSlide] * 1000;
+								var timeLeftCurrentSlide = slideEndTiming - diff;
+								if (timeLeftCurrentSlide < 0) {
+									pacingEl.className = 'pacing behind';
+								}
+								else if (timeLeftCurrentSlide < currentSlideTiming) {
+									pacingEl.className = 'pacing on-track';
+								}
+								else {
+									pacingEl.className = 'pacing ahead';
+								}
+								_displayTime( pacingHoursEl, pacingMinutesEl, pacingSecondsEl, timeLeftCurrentSlide );
+							} );
+						} );
+					}
+
+				}
+
+				/**
+				 * Sets up the speaker view layout and layout selector.
+				 */
+				function setupLayout() {
+
+					layoutDropdown = document.querySelector( '.speaker-layout-dropdown' );
+					layoutLabel = document.querySelector( '.speaker-layout-label' );
+
+					// Render the list of available layouts
+					for( var id in SPEAKER_LAYOUTS ) {
+						var option = document.createElement( 'option' );
+						option.setAttribute( 'value', id );
+						option.textContent = SPEAKER_LAYOUTS[ id ];
+						layoutDropdown.appendChild( option );
+					}
+
+					// Monitor the dropdown for changes
+					layoutDropdown.addEventListener( 'change', function( event ) {
+
+						setLayout( layoutDropdown.value );
+
+					}, false );
+
+					// Restore any currently persisted layout
+					setLayout( getLayout() );
+
+				}
+
+				/**
+				 * Sets a new speaker view layout. The layout is persisted
+				 * in local storage.
+				 */
+				function setLayout( value ) {
+
+					var title = SPEAKER_LAYOUTS[ value ];
+
+					layoutLabel.innerHTML = 'Layout' + ( title ? ( ': ' + title ) : '' );
+					layoutDropdown.value = value;
+
+					document.body.setAttribute( 'data-speaker-layout', value );
+
+					// Persist locally
+					if( supportsLocalStorage() ) {
+						window.localStorage.setItem( 'reveal-speaker-layout', value );
+					}
+
+				}
+
+				/**
+				 * Returns the ID of the most recently set speaker layout
+				 * or our default layout if none has been set.
+				 */
+				function getLayout() {
+
+					if( supportsLocalStorage() ) {
+						var layout = window.localStorage.getItem( 'reveal-speaker-layout' );
+						if( layout ) {
+							return layout;
+						}
+					}
+
+					// Default to the first record in the layouts hash
+					for( var id in SPEAKER_LAYOUTS ) {
+						return id;
+					}
+
+				}
+
+				function supportsLocalStorage() {
+
+					try {
+						localStorage.setItem('test', 'test');
+						localStorage.removeItem('test');
+						return true;
+					}
+					catch( e ) {
+						return false;
+					}
+
+				}
+
+				function zeroPadInteger( num ) {
+
+					var str = '00' + parseInt( num );
+					return str.substring( str.length - 2 );
+
+				}
+
+				/**
+				 * Limits the frequency at which a function can be called.
+				 */
+				function debounce( fn, ms ) {
+
+					var lastTime = 0,
+						timeout;
+
+					return function() {
+
+						var args = arguments;
+						var context = this;
+
+						clearTimeout( timeout );
+
+						var timeSinceLastCall = Date.now() - lastTime;
+						if( timeSinceLastCall > ms ) {
+							fn.apply( context, args );
+							lastTime = Date.now();
+						}
+						else {
+							timeout = setTimeout( function() {
+								fn.apply( context, args );
+								lastTime = Date.now();
+							}, ms - timeSinceLastCall );
+						}
+
+					}
+
+				}
+
+			})();
+
+		<\/script>
+	</body>
+</html>`;
+function W() {
+  return {
+    async: !1,
+    baseUrl: null,
+    breaks: !1,
+    extensions: null,
+    gfm: !0,
+    headerIds: !0,
+    headerPrefix: "",
+    highlight: null,
+    hooks: null,
+    langPrefix: "language-",
+    mangle: !0,
+    pedantic: !1,
+    renderer: null,
+    sanitize: !1,
+    sanitizer: null,
+    silent: !1,
+    smartypants: !1,
+    tokenizer: null,
+    walkTokens: null,
+    xhtml: !1
+  };
+}
+let A = W();
+function nt(l) {
+  A = l;
+}
+const Q = /[&<>"']/, it = new RegExp(Q.source, "g"), K = /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/, st = new RegExp(K.source, "g"), rt = {
+  "&": "&amp;",
+  "<": "&lt;",
+  ">": "&gt;",
+  '"': "&quot;",
+  "'": "&#39;"
+}, U = (l) => rt[l];
+function S(l, n) {
+  if (n) {
+    if (Q.test(l))
+      return l.replace(it, U);
+  } else if (K.test(l))
+    return l.replace(st, U);
+  return l;
+}
+const at = /&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig;
+function V(l) {
+  return l.replace(at, (n, e) => (e = e.toLowerCase(), e === "colon" ? ":" : e.charAt(0) === "#" ? e.charAt(1) === "x" ? String.fromCharCode(parseInt(e.substring(2), 16)) : String.fromCharCode(+e.substring(1)) : ""));
+}
+const lt = /(^|[^\[])\^/g;
+function k(l, n) {
+  l = typeof l == "string" ? l : l.source, n = n || "";
+  const e = {
+    replace: (t, i) => (i = i.source || i, i = i.replace(lt, "$1"), l = l.replace(t, i), e),
+    getRegex: () => new RegExp(l, n)
+  };
+  return e;
+}
+const ot = /[^\w:]/g, ct = /^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;
+function B(l, n, e) {
+  if (l) {
+    let t;
+    try {
+      t = decodeURIComponent(V(e)).replace(ot, "").toLowerCase();
+    } catch {
+      return null;
+    }
+    if (t.indexOf("javascript:") === 0 || t.indexOf("vbscript:") === 0 || t.indexOf("data:") === 0)
+      return null;
+  }
+  n && !ct.test(e) && (e = ht(n, e));
+  try {
+    e = encodeURI(e).replace(/%25/g, "%");
+  } catch {
+    return null;
+  }
+  return e;
+}
+const I = {}, ut = /^[^:]+:\/*[^/]*$/, pt = /^([^:]+:)[\s\S]*$/, dt = /^([^:]+:\/*[^/]*)[\s\S]*$/;
+function ht(l, n) {
+  I[" " + l] || (ut.test(l) ? I[" " + l] = l + "/" : I[" " + l] = C(l, "/", !0)), l = I[" " + l];
+  const e = l.indexOf(":") === -1;
+  return n.substring(0, 2) === "//" ? e ? n : l.replace(pt, "$1") + n : n.charAt(0) === "/" ? e ? n : l.replace(dt, "$1") + n : l + n;
+}
+const M = { exec: function() {
+} };
+function Z(l, n) {
+  const e = l.replace(/\|/g, (s, a, r) => {
+    let c = !1, m = a;
+    for (; --m >= 0 && r[m] === "\\"; )
+      c = !c;
+    return c ? "|" : " |";
+  }), t = e.split(/ \|/);
+  let i = 0;
+  if (t[0].trim() || t.shift(), t.length > 0 && !t[t.length - 1].trim() && t.pop(), t.length > n)
+    t.splice(n);
+  else
+    for (; t.length < n; )
+      t.push("");
+  for (; i < t.length; i++)
+    t[i] = t[i].trim().replace(/\\\|/g, "|");
+  return t;
+}
+function C(l, n, e) {
+  const t = l.length;
+  if (t === 0)
+    return "";
+  let i = 0;
+  for (; i < t; ) {
+    const s = l.charAt(t - i - 1);
+    if (s === n && !e)
+      i++;
+    else if (s !== n && e)
+      i++;
+    else
+      break;
+  }
+  return l.slice(0, t - i);
+}
+function gt(l, n) {
+  if (l.indexOf(n[1]) === -1)
+    return -1;
+  const e = l.length;
+  let t = 0, i = 0;
+  for (; i < e; i++)
+    if (l[i] === "\\")
+      i++;
+    else if (l[i] === n[0])
+      t++;
+    else if (l[i] === n[1] && (t--, t < 0))
+      return i;
+  return -1;
+}
+function ft(l) {
+  l && l.sanitize && !l.silent && console.warn("marked(): sanitize and sanitizer parameters are deprecated since version 0.7.0, should not be used and will be removed in the future. Read more here: https://marked.js.org/#/USING_ADVANCED.md#options");
+}
+function H(l, n) {
+  if (n < 1)
+    return "";
+  let e = "";
+  for (; n > 1; )
+    n & 1 && (e += l), n >>= 1, l += l;
+  return e + l;
+}
+function j(l, n, e, t) {
+  const i = n.href, s = n.title ? S(n.title) : null, a = l[1].replace(/\\([\[\]])/g, "$1");
+  if (l[0].charAt(0) !== "!") {
+    t.state.inLink = !0;
+    const r = {
+      type: "link",
+      raw: e,
+      href: i,
+      title: s,
+      text: a,
+      tokens: t.inlineTokens(a)
+    };
+    return t.state.inLink = !1, r;
+  }
+  return {
+    type: "image",
+    raw: e,
+    href: i,
+    title: s,
+    text: S(a)
+  };
+}
+function mt(l, n) {
+  const e = l.match(/^(\s+)(?:```)/);
+  if (e === null)
+    return n;
+  const t = e[1];
+  return n.split(`
+`).map((i) => {
+    const s = i.match(/^\s+/);
+    if (s === null)
+      return i;
+    const [a] = s;
+    return a.length >= t.length ? i.slice(t.length) : i;
+  }).join(`
+`);
+}
+class P {
+  constructor(n) {
+    this.options = n || A;
+  }
+  space(n) {
+    const e = this.rules.block.newline.exec(n);
+    if (e && e[0].length > 0)
+      return {
+        type: "space",
+        raw: e[0]
+      };
+  }
+  code(n) {
+    const e = this.rules.block.code.exec(n);
+    if (e) {
+      const t = e[0].replace(/^ {1,4}/gm, "");
+      return {
+        type: "code",
+        raw: e[0],
+        codeBlockStyle: "indented",
+        text: this.options.pedantic ? t : C(t, `
+`)
+      };
+    }
+  }
+  fences(n) {
+    const e = this.rules.block.fences.exec(n);
+    if (e) {
+      const t = e[0], i = mt(t, e[3] || "");
+      return {
+        type: "code",
+        raw: t,
+        lang: e[2] ? e[2].trim().replace(this.rules.inline._escapes, "$1") : e[2],
+        text: i
+      };
+    }
+  }
+  heading(n) {
+    const e = this.rules.block.heading.exec(n);
+    if (e) {
+      let t = e[2].trim();
+      if (/#$/.test(t)) {
+        const i = C(t, "#");
+        (this.options.pedantic || !i || / $/.test(i)) && (t = i.trim());
+      }
+      return {
+        type: "heading",
+        raw: e[0],
+        depth: e[1].length,
+        text: t,
+        tokens: this.lexer.inline(t)
+      };
+    }
+  }
+  hr(n) {
+    const e = this.rules.block.hr.exec(n);
+    if (e)
+      return {
+        type: "hr",
+        raw: e[0]
+      };
+  }
+  blockquote(n) {
+    const e = this.rules.block.blockquote.exec(n);
+    if (e) {
+      const t = e[0].replace(/^ *>[ \t]?/gm, ""), i = this.lexer.state.top;
+      this.lexer.state.top = !0;
+      const s = this.lexer.blockTokens(t);
+      return this.lexer.state.top = i, {
+        type: "blockquote",
+        raw: e[0],
+        tokens: s,
+        text: t
+      };
+    }
+  }
+  list(n) {
+    let e = this.rules.block.list.exec(n);
+    if (e) {
+      let t, i, s, a, r, c, m, f, d, p, o, x, b = e[1].trim();
+      const v = b.length > 1, w = {
+        type: "list",
+        raw: "",
+        ordered: v,
+        start: v ? +b.slice(0, -1) : "",
+        loose: !1,
+        items: []
+      };
+      b = v ? `\\d{1,9}\\${b.slice(-1)}` : `\\${b}`, this.options.pedantic && (b = v ? b : "[*+-]");
+      const y = new RegExp(`^( {0,3}${b})((?:[	 ][^\\n]*)?(?:\\n|$))`);
+      for (; n && (x = !1, !(!(e = y.exec(n)) || this.rules.block.hr.test(n))); ) {
+        if (t = e[0], n = n.substring(t.length), f = e[2].split(`
+`, 1)[0].replace(/^\t+/, (z) => " ".repeat(3 * z.length)), d = n.split(`
+`, 1)[0], this.options.pedantic ? (a = 2, o = f.trimLeft()) : (a = e[2].search(/[^ ]/), a = a > 4 ? 1 : a, o = f.slice(a), a += e[1].length), c = !1, !f && /^ *$/.test(d) && (t += d + `
+`, n = n.substring(d.length + 1), x = !0), !x) {
+          const z = new RegExp(`^ {0,${Math.min(3, a - 1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ 	][^\\n]*)?(?:\\n|$))`), T = new RegExp(`^ {0,${Math.min(3, a - 1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`), _ = new RegExp(`^ {0,${Math.min(3, a - 1)}}(?:\`\`\`|~~~)`), L = new RegExp(`^ {0,${Math.min(3, a - 1)}}#`);
+          for (; n && (p = n.split(`
+`, 1)[0], d = p, this.options.pedantic && (d = d.replace(/^ {1,4}(?=( {4})*[^ ])/g, "  ")), !(_.test(d) || L.test(d) || z.test(d) || T.test(n))); ) {
+            if (d.search(/[^ ]/) >= a || !d.trim())
+              o += `
+` + d.slice(a);
+            else {
+              if (c || f.search(/[^ ]/) >= 4 || _.test(f) || L.test(f) || T.test(f))
+                break;
+              o += `
+` + d;
+            }
+            !c && !d.trim() && (c = !0), t += p + `
+`, n = n.substring(p.length + 1), f = d.slice(a);
+          }
+        }
+        w.loose || (m ? w.loose = !0 : /\n *\n *$/.test(t) && (m = !0)), this.options.gfm && (i = /^\[[ xX]\] /.exec(o), i && (s = i[0] !== "[ ] ", o = o.replace(/^\[[ xX]\] +/, ""))), w.items.push({
+          type: "list_item",
+          raw: t,
+          task: !!i,
+          checked: s,
+          loose: !1,
+          text: o
+        }), w.raw += t;
+      }
+      w.items[w.items.length - 1].raw = t.trimRight(), w.items[w.items.length - 1].text = o.trimRight(), w.raw = w.raw.trimRight();
+      const R = w.items.length;
+      for (r = 0; r < R; r++)
+        if (this.lexer.state.top = !1, w.items[r].tokens = this.lexer.blockTokens(w.items[r].text, []), !w.loose) {
+          const z = w.items[r].tokens.filter((_) => _.type === "space"), T = z.length > 0 && z.some((_) => /\n.*\n/.test(_.raw));
+          w.loose = T;
+        }
+      if (w.loose)
+        for (r = 0; r < R; r++)
+          w.items[r].loose = !0;
+      return w;
+    }
+  }
+  html(n) {
+    const e = this.rules.block.html.exec(n);
+    if (e) {
+      const t = {
+        type: "html",
+        raw: e[0],
+        pre: !this.options.sanitizer && (e[1] === "pre" || e[1] === "script" || e[1] === "style"),
+        text: e[0]
+      };
+      if (this.options.sanitize) {
+        const i = this.options.sanitizer ? this.options.sanitizer(e[0]) : S(e[0]);
+        t.type = "paragraph", t.text = i, t.tokens = this.lexer.inline(i);
+      }
+      return t;
+    }
+  }
+  def(n) {
+    const e = this.rules.block.def.exec(n);
+    if (e) {
+      const t = e[1].toLowerCase().replace(/\s+/g, " "), i = e[2] ? e[2].replace(/^<(.*)>$/, "$1").replace(this.rules.inline._escapes, "$1") : "", s = e[3] ? e[3].substring(1, e[3].length - 1).replace(this.rules.inline._escapes, "$1") : e[3];
+      return {
+        type: "def",
+        tag: t,
+        raw: e[0],
+        href: i,
+        title: s
+      };
+    }
+  }
+  table(n) {
+    const e = this.rules.block.table.exec(n);
+    if (e) {
+      const t = {
+        type: "table",
+        header: Z(e[1]).map((i) => ({ text: i })),
+        align: e[2].replace(/^ *|\| *$/g, "").split(/ *\| */),
+        rows: e[3] && e[3].trim() ? e[3].replace(/\n[ \t]*$/, "").split(`
+`) : []
+      };
+      if (t.header.length === t.align.length) {
+        t.raw = e[0];
+        let i = t.align.length, s, a, r, c;
+        for (s = 0; s < i; s++)
+          /^ *-+: *$/.test(t.align[s]) ? t.align[s] = "right" : /^ *:-+: *$/.test(t.align[s]) ? t.align[s] = "center" : /^ *:-+ *$/.test(t.align[s]) ? t.align[s] = "left" : t.align[s] = null;
+        for (i = t.rows.length, s = 0; s < i; s++)
+          t.rows[s] = Z(t.rows[s], t.header.length).map((m) => ({ text: m }));
+        for (i = t.header.length, a = 0; a < i; a++)
+          t.header[a].tokens = this.lexer.inline(t.header[a].text);
+        for (i = t.rows.length, a = 0; a < i; a++)
+          for (c = t.rows[a], r = 0; r < c.length; r++)
+            c[r].tokens = this.lexer.inline(c[r].text);
+        return t;
+      }
+    }
+  }
+  lheading(n) {
+    const e = this.rules.block.lheading.exec(n);
+    if (e)
+      return {
+        type: "heading",
+        raw: e[0],
+        depth: e[2].charAt(0) === "=" ? 1 : 2,
+        text: e[1],
+        tokens: this.lexer.inline(e[1])
+      };
+  }
+  paragraph(n) {
+    const e = this.rules.block.paragraph.exec(n);
+    if (e) {
+      const t = e[1].charAt(e[1].length - 1) === `
+` ? e[1].slice(0, -1) : e[1];
+      return {
+        type: "paragraph",
+        raw: e[0],
+        text: t,
+        tokens: this.lexer.inline(t)
+      };
+    }
+  }
+  text(n) {
+    const e = this.rules.block.text.exec(n);
+    if (e)
+      return {
+        type: "text",
+        raw: e[0],
+        text: e[0],
+        tokens: this.lexer.inline(e[0])
+      };
+  }
+  escape(n) {
+    const e = this.rules.inline.escape.exec(n);
+    if (e)
+      return {
+        type: "escape",
+        raw: e[0],
+        text: S(e[1])
+      };
+  }
+  tag(n) {
+    const e = this.rules.inline.tag.exec(n);
+    if (e)
+      return !this.lexer.state.inLink && /^<a /i.test(e[0]) ? this.lexer.state.inLink = !0 : this.lexer.state.inLink && /^<\/a>/i.test(e[0]) && (this.lexer.state.inLink = !1), !this.lexer.state.inRawBlock && /^<(pre|code|kbd|script)(\s|>)/i.test(e[0]) ? this.lexer.state.inRawBlock = !0 : this.lexer.state.inRawBlock && /^<\/(pre|code|kbd|script)(\s|>)/i.test(e[0]) && (this.lexer.state.inRawBlock = !1), {
+        type: this.options.sanitize ? "text" : "html",
+        raw: e[0],
+        inLink: this.lexer.state.inLink,
+        inRawBlock: this.lexer.state.inRawBlock,
+        text: this.options.sanitize ? this.options.sanitizer ? this.options.sanitizer(e[0]) : S(e[0]) : e[0]
+      };
+  }
+  link(n) {
+    const e = this.rules.inline.link.exec(n);
+    if (e) {
+      const t = e[2].trim();
+      if (!this.options.pedantic && /^</.test(t)) {
+        if (!/>$/.test(t))
+          return;
+        const a = C(t.slice(0, -1), "\\");
+        if ((t.length - a.length) % 2 === 0)
+          return;
+      } else {
+        const a = gt(e[2], "()");
+        if (a > -1) {
+          const c = (e[0].indexOf("!") === 0 ? 5 : 4) + e[1].length + a;
+          e[2] = e[2].substring(0, a), e[0] = e[0].substring(0, c).trim(), e[3] = "";
+        }
+      }
+      let i = e[2], s = "";
+      if (this.options.pedantic) {
+        const a = /^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(i);
+        a && (i = a[1], s = a[3]);
+      } else
+        s = e[3] ? e[3].slice(1, -1) : "";
+      return i = i.trim(), /^</.test(i) && (this.options.pedantic && !/>$/.test(t) ? i = i.slice(1) : i = i.slice(1, -1)), j(e, {
+        href: i && i.replace(this.rules.inline._escapes, "$1"),
+        title: s && s.replace(this.rules.inline._escapes, "$1")
+      }, e[0], this.lexer);
+    }
+  }
+  reflink(n, e) {
+    let t;
+    if ((t = this.rules.inline.reflink.exec(n)) || (t = this.rules.inline.nolink.exec(n))) {
+      let i = (t[2] || t[1]).replace(/\s+/g, " ");
+      if (i = e[i.toLowerCase()], !i) {
+        const s = t[0].charAt(0);
+        return {
+          type: "text",
+          raw: s,
+          text: s
+        };
+      }
+      return j(t, i, t[0], this.lexer);
+    }
+  }
+  emStrong(n, e, t = "") {
+    let i = this.rules.inline.emStrong.lDelim.exec(n);
+    if (!i || i[3] && t.match(/[\p{L}\p{N}]/u))
+      return;
+    const s = i[1] || i[2] || "";
+    if (!s || s && (t === "" || this.rules.inline.punctuation.exec(t))) {
+      const a = i[0].length - 1;
+      let r, c, m = a, f = 0;
+      const d = i[0][0] === "*" ? this.rules.inline.emStrong.rDelimAst : this.rules.inline.emStrong.rDelimUnd;
+      for (d.lastIndex = 0, e = e.slice(-1 * n.length + a); (i = d.exec(e)) != null; ) {
+        if (r = i[1] || i[2] || i[3] || i[4] || i[5] || i[6], !r)
+          continue;
+        if (c = r.length, i[3] || i[4]) {
+          m += c;
+          continue;
+        } else if ((i[5] || i[6]) && a % 3 && !((a + c) % 3)) {
+          f += c;
+          continue;
+        }
+        if (m -= c, m > 0)
+          continue;
+        c = Math.min(c, c + m + f);
+        const p = n.slice(0, a + i.index + (i[0].length - r.length) + c);
+        if (Math.min(a, c) % 2) {
+          const x = p.slice(1, -1);
+          return {
+            type: "em",
+            raw: p,
+            text: x,
+            tokens: this.lexer.inlineTokens(x)
+          };
+        }
+        const o = p.slice(2, -2);
+        return {
+          type: "strong",
+          raw: p,
+          text: o,
+          tokens: this.lexer.inlineTokens(o)
+        };
+      }
+    }
+  }
+  codespan(n) {
+    const e = this.rules.inline.code.exec(n);
+    if (e) {
+      let t = e[2].replace(/\n/g, " ");
+      const i = /[^ ]/.test(t), s = /^ /.test(t) && / $/.test(t);
+      return i && s && (t = t.substring(1, t.length - 1)), t = S(t, !0), {
+        type: "codespan",
+        raw: e[0],
+        text: t
+      };
+    }
+  }
+  br(n) {
+    const e = this.rules.inline.br.exec(n);
+    if (e)
+      return {
+        type: "br",
+        raw: e[0]
+      };
+  }
+  del(n) {
+    const e = this.rules.inline.del.exec(n);
+    if (e)
+      return {
+        type: "del",
+        raw: e[0],
+        text: e[2],
+        tokens: this.lexer.inlineTokens(e[2])
+      };
+  }
+  autolink(n, e) {
+    const t = this.rules.inline.autolink.exec(n);
+    if (t) {
+      let i, s;
+      return t[2] === "@" ? (i = S(this.options.mangle ? e(t[1]) : t[1]), s = "mailto:" + i) : (i = S(t[1]), s = i), {
+        type: "link",
+        raw: t[0],
+        text: i,
+        href: s,
+        tokens: [
+          {
+            type: "text",
+            raw: i,
+            text: i
+          }
+        ]
+      };
+    }
+  }
+  url(n, e) {
+    let t;
+    if (t = this.rules.inline.url.exec(n)) {
+      let i, s;
+      if (t[2] === "@")
+        i = S(this.options.mangle ? e(t[0]) : t[0]), s = "mailto:" + i;
+      else {
+        let a;
+        do
+          a = t[0], t[0] = this.rules.inline._backpedal.exec(t[0])[0];
+        while (a !== t[0]);
+        i = S(t[0]), t[1] === "www." ? s = "http://" + t[0] : s = t[0];
+      }
+      return {
+        type: "link",
+        raw: t[0],
+        text: i,
+        href: s,
+        tokens: [
+          {
+            type: "text",
+            raw: i,
+            text: i
+          }
+        ]
+      };
+    }
+  }
+  inlineText(n, e) {
+    const t = this.rules.inline.text.exec(n);
+    if (t) {
+      let i;
+      return this.lexer.state.inRawBlock ? i = this.options.sanitize ? this.options.sanitizer ? this.options.sanitizer(t[0]) : S(t[0]) : t[0] : i = S(this.options.smartypants ? e(t[0]) : t[0]), {
+        type: "text",
+        raw: t[0],
+        text: i
+      };
+    }
+  }
+}
+const h = {
+  newline: /^(?: *(?:\n|$))+/,
+  code: /^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/,
+  fences: /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,
+  hr: /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,
+  heading: /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,
+  blockquote: /^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,
+  list: /^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/,
+  html: "^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n *)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$))",
+  def: /^ {0,3}\[(label)\]: *(?:\n *)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/,
+  table: M,
+  lheading: /^((?:.|\n(?!\n))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,
+  // regex template, placeholders will be replaced according to different paragraph
+  // interruption rules of commonmark and the original markdown spec:
+  _paragraph: /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,
+  text: /^[^\n]+/
+};
+h._label = /(?!\s*\])(?:\\.|[^\[\]\\])+/;
+h._title = /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/;
+h.def = k(h.def).replace("label", h._label).replace("title", h._title).getRegex();
+h.bullet = /(?:[*+-]|\d{1,9}[.)])/;
+h.listItemStart = k(/^( *)(bull) */).replace("bull", h.bullet).getRegex();
+h.list = k(h.list).replace(/bull/g, h.bullet).replace("hr", "\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def", "\\n+(?=" + h.def.source + ")").getRegex();
+h._tag = "address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul";
+h._comment = /<!--(?!-?>)[\s\S]*?(?:-->|$)/;
+h.html = k(h.html, "i").replace("comment", h._comment).replace("tag", h._tag).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex();
+h.paragraph = k(h._paragraph).replace("hr", h.hr).replace("heading", " {0,3}#{1,6} ").replace("|lheading", "").replace("|table", "").replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", h._tag).getRegex();
+h.blockquote = k(h.blockquote).replace("paragraph", h.paragraph).getRegex();
+h.normal = { ...h };
+h.gfm = {
+  ...h.normal,
+  table: "^ *([^\\n ].*\\|.*)\\n {0,3}(?:\\| *)?(:?-+:? *(?:\\| *:?-+:? *)*)(?:\\| *)?(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)"
+  // Cells
+};
+h.gfm.table = k(h.gfm.table).replace("hr", h.hr).replace("heading", " {0,3}#{1,6} ").replace("blockquote", " {0,3}>").replace("code", " {4}[^\\n]").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", h._tag).getRegex();
+h.gfm.paragraph = k(h._paragraph).replace("hr", h.hr).replace("heading", " {0,3}#{1,6} ").replace("|lheading", "").replace("table", h.gfm.table).replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", h._tag).getRegex();
+h.pedantic = {
+  ...h.normal,
+  html: k(
+    `^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`
+  ).replace("comment", h._comment).replace(/tag/g, "(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),
+  def: /^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,
+  heading: /^(#{1,6})(.*)(?:\n+|$)/,
+  fences: M,
+  // fences not supported
+  lheading: /^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,
+  paragraph: k(h.normal._paragraph).replace("hr", h.hr).replace("heading", ` *#{1,6} *[^
+]`).replace("lheading", h.lheading).replace("blockquote", " {0,3}>").replace("|fences", "").replace("|list", "").replace("|html", "").getRegex()
+};
+const u = {
+  escape: /^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,
+  autolink: /^<(scheme:[^\s\x00-\x1f<>]*|email)>/,
+  url: M,
+  tag: "^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>",
+  // CDATA section
+  link: /^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/,
+  reflink: /^!?\[(label)\]\[(ref)\]/,
+  nolink: /^!?\[(ref)\](?:\[\])?/,
+  reflinkSearch: "reflink|nolink(?!\\()",
+  emStrong: {
+    lDelim: /^(?:\*+(?:([punct_])|[^\s*]))|^_+(?:([punct*])|([^\s_]))/,
+    //        (1) and (2) can only be a Right Delimiter. (3) and (4) can only be Left.  (5) and (6) can be either Left or Right.
+    //          () Skip orphan inside strong                                      () Consume to delim     (1) #***                (2) a***#, a***                             (3) #***a, ***a                 (4) ***#              (5) #***#                 (6) a***a
+    rDelimAst: /^(?:[^_*\\]|\\.)*?\_\_(?:[^_*\\]|\\.)*?\*(?:[^_*\\]|\\.)*?(?=\_\_)|(?:[^*\\]|\\.)+(?=[^*])|[punct_](\*+)(?=[\s]|$)|(?:[^punct*_\s\\]|\\.)(\*+)(?=[punct_\s]|$)|[punct_\s](\*+)(?=[^punct*_\s])|[\s](\*+)(?=[punct_])|[punct_](\*+)(?=[punct_])|(?:[^punct*_\s\\]|\\.)(\*+)(?=[^punct*_\s])/,
+    rDelimUnd: /^(?:[^_*\\]|\\.)*?\*\*(?:[^_*\\]|\\.)*?\_(?:[^_*\\]|\\.)*?(?=\*\*)|(?:[^_\\]|\\.)+(?=[^_])|[punct*](\_+)(?=[\s]|$)|(?:[^punct*_\s\\]|\\.)(\_+)(?=[punct*\s]|$)|[punct*\s](\_+)(?=[^punct*_\s])|[\s](\_+)(?=[punct*])|[punct*](\_+)(?=[punct*])/
+    // ^- Not allowed for _
+  },
+  code: /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,
+  br: /^( {2,}|\\)\n(?!\s*$)/,
+  del: M,
+  text: /^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,
+  punctuation: /^([\spunctuation])/
+};
+u._punctuation = "!\"#$%&'()+\\-.,/:;<=>?@\\[\\]`^{|}~";
+u.punctuation = k(u.punctuation).replace(/punctuation/g, u._punctuation).getRegex();
+u.blockSkip = /\[[^\]]*?\]\([^\)]*?\)|`[^`]*?`|<[^>]*?>/g;
+u.escapedEmSt = /(?:^|[^\\])(?:\\\\)*\\[*_]/g;
+u._comment = k(h._comment).replace("(?:-->|$)", "-->").getRegex();
+u.emStrong.lDelim = k(u.emStrong.lDelim).replace(/punct/g, u._punctuation).getRegex();
+u.emStrong.rDelimAst = k(u.emStrong.rDelimAst, "g").replace(/punct/g, u._punctuation).getRegex();
+u.emStrong.rDelimUnd = k(u.emStrong.rDelimUnd, "g").replace(/punct/g, u._punctuation).getRegex();
+u._escapes = /\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/g;
+u._scheme = /[a-zA-Z][a-zA-Z0-9+.-]{1,31}/;
+u._email = /[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/;
+u.autolink = k(u.autolink).replace("scheme", u._scheme).replace("email", u._email).getRegex();
+u._attribute = /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/;
+u.tag = k(u.tag).replace("comment", u._comment).replace("attribute", u._attribute).getRegex();
+u._label = /(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/;
+u._href = /<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/;
+u._title = /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/;
+u.link = k(u.link).replace("label", u._label).replace("href", u._href).replace("title", u._title).getRegex();
+u.reflink = k(u.reflink).replace("label", u._label).replace("ref", h._label).getRegex();
+u.nolink = k(u.nolink).replace("ref", h._label).getRegex();
+u.reflinkSearch = k(u.reflinkSearch, "g").replace("reflink", u.reflink).replace("nolink", u.nolink).getRegex();
+u.normal = { ...u };
+u.pedantic = {
+  ...u.normal,
+  strong: {
+    start: /^__|\*\*/,
+    middle: /^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,
+    endAst: /\*\*(?!\*)/g,
+    endUnd: /__(?!_)/g
+  },
+  em: {
+    start: /^_|\*/,
+    middle: /^()\*(?=\S)([\s\S]*?\S)\*(?!\*)|^_(?=\S)([\s\S]*?\S)_(?!_)/,
+    endAst: /\*(?!\*)/g,
+    endUnd: /_(?!_)/g
+  },
+  link: k(/^!?\[(label)\]\((.*?)\)/).replace("label", u._label).getRegex(),
+  reflink: k(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label", u._label).getRegex()
+};
+u.gfm = {
+  ...u.normal,
+  escape: k(u.escape).replace("])", "~|])").getRegex(),
+  _extended_email: /[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/,
+  url: /^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,
+  _backpedal: /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,
+  del: /^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,
+  text: /^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/
+};
+u.gfm.url = k(u.gfm.url, "i").replace("email", u.gfm._extended_email).getRegex();
+u.breaks = {
+  ...u.gfm,
+  br: k(u.br).replace("{2,}", "*").getRegex(),
+  text: k(u.gfm.text).replace("\\b_", "\\b_| {2,}\\n").replace(/\{2,\}/g, "*").getRegex()
+};
+function kt(l) {
+  return l.replace(/---/g, "—").replace(/--/g, "–").replace(/(^|[-\u2014/(\[{"\s])'/g, "$1‘").replace(/'/g, "’").replace(/(^|[-\u2014/(\[{\u2018\s])"/g, "$1“").replace(/"/g, "”").replace(/\.{3}/g, "…");
+}
+function J(l) {
+  let n = "", e, t;
+  const i = l.length;
+  for (e = 0; e < i; e++)
+    t = l.charCodeAt(e), Math.random() > 0.5 && (t = "x" + t.toString(16)), n += "&#" + t + ";";
+  return n;
+}
+class $ {
+  constructor(n) {
+    this.tokens = [], this.tokens.links = /* @__PURE__ */ Object.create(null), this.options = n || A, this.options.tokenizer = this.options.tokenizer || new P(), this.tokenizer = this.options.tokenizer, this.tokenizer.options = this.options, this.tokenizer.lexer = this, this.inlineQueue = [], this.state = {
+      inLink: !1,
+      inRawBlock: !1,
+      top: !0
+    };
+    const e = {
+      block: h.normal,
+      inline: u.normal
+    };
+    this.options.pedantic ? (e.block = h.pedantic, e.inline = u.pedantic) : this.options.gfm && (e.block = h.gfm, this.options.breaks ? e.inline = u.breaks : e.inline = u.gfm), this.tokenizer.rules = e;
+  }
+  /**
+   * Expose Rules
+   */
+  static get rules() {
+    return {
+      block: h,
+      inline: u
+    };
+  }
+  /**
+   * Static Lex Method
+   */
+  static lex(n, e) {
+    return new $(e).lex(n);
+  }
+  /**
+   * Static Lex Inline Method
+   */
+  static lexInline(n, e) {
+    return new $(e).inlineTokens(n);
+  }
+  /**
+   * Preprocessing
+   */
+  lex(n) {
+    n = n.replace(/\r\n|\r/g, `
+`), this.blockTokens(n, this.tokens);
+    let e;
+    for (; e = this.inlineQueue.shift(); )
+      this.inlineTokens(e.src, e.tokens);
+    return this.tokens;
+  }
+  /**
+   * Lexing
+   */
+  blockTokens(n, e = []) {
+    this.options.pedantic ? n = n.replace(/\t/g, "    ").replace(/^ +$/gm, "") : n = n.replace(/^( *)(\t+)/gm, (r, c, m) => c + "    ".repeat(m.length));
+    let t, i, s, a;
+    for (; n; )
+      if (!(this.options.extensions && this.options.extensions.block && this.options.extensions.block.some((r) => (t = r.call({ lexer: this }, n, e)) ? (n = n.substring(t.raw.length), e.push(t), !0) : !1))) {
+        if (t = this.tokenizer.space(n)) {
+          n = n.substring(t.raw.length), t.raw.length === 1 && e.length > 0 ? e[e.length - 1].raw += `
+` : e.push(t);
+          continue;
+        }
+        if (t = this.tokenizer.code(n)) {
+          n = n.substring(t.raw.length), i = e[e.length - 1], i && (i.type === "paragraph" || i.type === "text") ? (i.raw += `
+` + t.raw, i.text += `
+` + t.text, this.inlineQueue[this.inlineQueue.length - 1].src = i.text) : e.push(t);
+          continue;
+        }
+        if (t = this.tokenizer.fences(n)) {
+          n = n.substring(t.raw.length), e.push(t);
+          continue;
+        }
+        if (t = this.tokenizer.heading(n)) {
+          n = n.substring(t.raw.length), e.push(t);
+          continue;
+        }
+        if (t = this.tokenizer.hr(n)) {
+          n = n.substring(t.raw.length), e.push(t);
+          continue;
+        }
+        if (t = this.tokenizer.blockquote(n)) {
+          n = n.substring(t.raw.length), e.push(t);
+          continue;
+        }
+        if (t = this.tokenizer.list(n)) {
+          n = n.substring(t.raw.length), e.push(t);
+          continue;
+        }
+        if (t = this.tokenizer.html(n)) {
+          n = n.substring(t.raw.length), e.push(t);
+          continue;
+        }
+        if (t = this.tokenizer.def(n)) {
+          n = n.substring(t.raw.length), i = e[e.length - 1], i && (i.type === "paragraph" || i.type === "text") ? (i.raw += `
+` + t.raw, i.text += `
+` + t.raw, this.inlineQueue[this.inlineQueue.length - 1].src = i.text) : this.tokens.links[t.tag] || (this.tokens.links[t.tag] = {
+            href: t.href,
+            title: t.title
+          });
+          continue;
+        }
+        if (t = this.tokenizer.table(n)) {
+          n = n.substring(t.raw.length), e.push(t);
+          continue;
+        }
+        if (t = this.tokenizer.lheading(n)) {
+          n = n.substring(t.raw.length), e.push(t);
+          continue;
+        }
+        if (s = n, this.options.extensions && this.options.extensions.startBlock) {
+          let r = 1 / 0;
+          const c = n.slice(1);
+          let m;
+          this.options.extensions.startBlock.forEach(function(f) {
+            m = f.call({ lexer: this }, c), typeof m == "number" && m >= 0 && (r = Math.min(r, m));
+          }), r < 1 / 0 && r >= 0 && (s = n.substring(0, r + 1));
+        }
+        if (this.state.top && (t = this.tokenizer.paragraph(s))) {
+          i = e[e.length - 1], a && i.type === "paragraph" ? (i.raw += `
+` + t.raw, i.text += `
+` + t.text, this.inlineQueue.pop(), this.inlineQueue[this.inlineQueue.length - 1].src = i.text) : e.push(t), a = s.length !== n.length, n = n.substring(t.raw.length);
+          continue;
+        }
+        if (t = this.tokenizer.text(n)) {
+          n = n.substring(t.raw.length), i = e[e.length - 1], i && i.type === "text" ? (i.raw += `
+` + t.raw, i.text += `
+` + t.text, this.inlineQueue.pop(), this.inlineQueue[this.inlineQueue.length - 1].src = i.text) : e.push(t);
+          continue;
+        }
+        if (n) {
+          const r = "Infinite loop on byte: " + n.charCodeAt(0);
+          if (this.options.silent) {
+            console.error(r);
+            break;
+          } else
+            throw new Error(r);
+        }
+      }
+    return this.state.top = !0, e;
+  }
+  inline(n, e = []) {
+    return this.inlineQueue.push({ src: n, tokens: e }), e;
+  }
+  /**
+   * Lexing/Compiling
+   */
+  inlineTokens(n, e = []) {
+    let t, i, s, a = n, r, c, m;
+    if (this.tokens.links) {
+      const f = Object.keys(this.tokens.links);
+      if (f.length > 0)
+        for (; (r = this.tokenizer.rules.inline.reflinkSearch.exec(a)) != null; )
+          f.includes(r[0].slice(r[0].lastIndexOf("[") + 1, -1)) && (a = a.slice(0, r.index) + "[" + H("a", r[0].length - 2) + "]" + a.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex));
+    }
+    for (; (r = this.tokenizer.rules.inline.blockSkip.exec(a)) != null; )
+      a = a.slice(0, r.index) + "[" + H("a", r[0].length - 2) + "]" + a.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);
+    for (; (r = this.tokenizer.rules.inline.escapedEmSt.exec(a)) != null; )
+      a = a.slice(0, r.index + r[0].length - 2) + "++" + a.slice(this.tokenizer.rules.inline.escapedEmSt.lastIndex), this.tokenizer.rules.inline.escapedEmSt.lastIndex--;
+    for (; n; )
+      if (c || (m = ""), c = !1, !(this.options.extensions && this.options.extensions.inline && this.options.extensions.inline.some((f) => (t = f.call({ lexer: this }, n, e)) ? (n = n.substring(t.raw.length), e.push(t), !0) : !1))) {
+        if (t = this.tokenizer.escape(n)) {
+          n = n.substring(t.raw.length), e.push(t);
+          continue;
+        }
+        if (t = this.tokenizer.tag(n)) {
+          n = n.substring(t.raw.length), i = e[e.length - 1], i && t.type === "text" && i.type === "text" ? (i.raw += t.raw, i.text += t.text) : e.push(t);
+          continue;
+        }
+        if (t = this.tokenizer.link(n)) {
+          n = n.substring(t.raw.length), e.push(t);
+          continue;
+        }
+        if (t = this.tokenizer.reflink(n, this.tokens.links)) {
+          n = n.substring(t.raw.length), i = e[e.length - 1], i && t.type === "text" && i.type === "text" ? (i.raw += t.raw, i.text += t.text) : e.push(t);
+          continue;
+        }
+        if (t = this.tokenizer.emStrong(n, a, m)) {
+          n = n.substring(t.raw.length), e.push(t);
+          continue;
+        }
+        if (t = this.tokenizer.codespan(n)) {
+          n = n.substring(t.raw.length), e.push(t);
+          continue;
+        }
+        if (t = this.tokenizer.br(n)) {
+          n = n.substring(t.raw.length), e.push(t);
+          continue;
+        }
+        if (t = this.tokenizer.del(n)) {
+          n = n.substring(t.raw.length), e.push(t);
+          continue;
+        }
+        if (t = this.tokenizer.autolink(n, J)) {
+          n = n.substring(t.raw.length), e.push(t);
+          continue;
+        }
+        if (!this.state.inLink && (t = this.tokenizer.url(n, J))) {
+          n = n.substring(t.raw.length), e.push(t);
+          continue;
+        }
+        if (s = n, this.options.extensions && this.options.extensions.startInline) {
+          let f = 1 / 0;
+          const d = n.slice(1);
+          let p;
+          this.options.extensions.startInline.forEach(function(o) {
+            p = o.call({ lexer: this }, d), typeof p == "number" && p >= 0 && (f = Math.min(f, p));
+          }), f < 1 / 0 && f >= 0 && (s = n.substring(0, f + 1));
+        }
+        if (t = this.tokenizer.inlineText(s, kt)) {
+          n = n.substring(t.raw.length), t.raw.slice(-1) !== "_" && (m = t.raw.slice(-1)), c = !0, i = e[e.length - 1], i && i.type === "text" ? (i.raw += t.raw, i.text += t.text) : e.push(t);
+          continue;
+        }
+        if (n) {
+          const f = "Infinite loop on byte: " + n.charCodeAt(0);
+          if (this.options.silent) {
+            console.error(f);
+            break;
+          } else
+            throw new Error(f);
+        }
+      }
+    return e;
+  }
+}
+class q {
+  constructor(n) {
+    this.options = n || A;
+  }
+  code(n, e, t) {
+    const i = (e || "").match(/\S*/)[0];
+    if (this.options.highlight) {
+      const s = this.options.highlight(n, i);
+      s != null && s !== n && (t = !0, n = s);
+    }
+    return n = n.replace(/\n$/, "") + `
+`, i ? '<pre><code class="' + this.options.langPrefix + S(i) + '">' + (t ? n : S(n, !0)) + `</code></pre>
+` : "<pre><code>" + (t ? n : S(n, !0)) + `</code></pre>
+`;
+  }
+  /**
+   * @param {string} quote
+   */
+  blockquote(n) {
+    return `<blockquote>
+${n}</blockquote>
+`;
+  }
+  html(n) {
+    return n;
+  }
+  /**
+   * @param {string} text
+   * @param {string} level
+   * @param {string} raw
+   * @param {any} slugger
+   */
+  heading(n, e, t, i) {
+    if (this.options.headerIds) {
+      const s = this.options.headerPrefix + i.slug(t);
+      return `<h${e} id="${s}">${n}</h${e}>
+`;
+    }
+    return `<h${e}>${n}</h${e}>
+`;
+  }
+  hr() {
+    return this.options.xhtml ? `<hr/>
+` : `<hr>
+`;
+  }
+  list(n, e, t) {
+    const i = e ? "ol" : "ul", s = e && t !== 1 ? ' start="' + t + '"' : "";
+    return "<" + i + s + `>
+` + n + "</" + i + `>
+`;
+  }
+  /**
+   * @param {string} text
+   */
+  listitem(n) {
+    return `<li>${n}</li>
+`;
+  }
+  checkbox(n) {
+    return "<input " + (n ? 'checked="" ' : "") + 'disabled="" type="checkbox"' + (this.options.xhtml ? " /" : "") + "> ";
+  }
+  /**
+   * @param {string} text
+   */
+  paragraph(n) {
+    return `<p>${n}</p>
+`;
+  }
+  /**
+   * @param {string} header
+   * @param {string} body
+   */
+  table(n, e) {
+    return e && (e = `<tbody>${e}</tbody>`), `<table>
+<thead>
+` + n + `</thead>
+` + e + `</table>
+`;
+  }
+  /**
+   * @param {string} content
+   */
+  tablerow(n) {
+    return `<tr>
+${n}</tr>
+`;
+  }
+  tablecell(n, e) {
+    const t = e.header ? "th" : "td";
+    return (e.align ? `<${t} align="${e.align}">` : `<${t}>`) + n + `</${t}>
+`;
+  }
+  /**
+   * span level renderer
+   * @param {string} text
+   */
+  strong(n) {
+    return `<strong>${n}</strong>`;
+  }
+  /**
+   * @param {string} text
+   */
+  em(n) {
+    return `<em>${n}</em>`;
+  }
+  /**
+   * @param {string} text
+   */
+  codespan(n) {
+    return `<code>${n}</code>`;
+  }
+  br() {
+    return this.options.xhtml ? "<br/>" : "<br>";
+  }
+  /**
+   * @param {string} text
+   */
+  del(n) {
+    return `<del>${n}</del>`;
+  }
+  /**
+   * @param {string} href
+   * @param {string} title
+   * @param {string} text
+   */
+  link(n, e, t) {
+    if (n = B(this.options.sanitize, this.options.baseUrl, n), n === null)
+      return t;
+    let i = '<a href="' + n + '"';
+    return e && (i += ' title="' + e + '"'), i += ">" + t + "</a>", i;
+  }
+  /**
+   * @param {string} href
+   * @param {string} title
+   * @param {string} text
+   */
+  image(n, e, t) {
+    if (n = B(this.options.sanitize, this.options.baseUrl, n), n === null)
+      return t;
+    let i = `<img src="${n}" alt="${t}"`;
+    return e && (i += ` title="${e}"`), i += this.options.xhtml ? "/>" : ">", i;
+  }
+  text(n) {
+    return n;
+  }
+}
+class F {
+  // no need for block level renderers
+  strong(n) {
+    return n;
+  }
+  em(n) {
+    return n;
+  }
+  codespan(n) {
+    return n;
+  }
+  del(n) {
+    return n;
+  }
+  html(n) {
+    return n;
+  }
+  text(n) {
+    return n;
+  }
+  link(n, e, t) {
+    return "" + t;
+  }
+  image(n, e, t) {
+    return "" + t;
+  }
+  br() {
+    return "";
+  }
+}
+class Y {
+  constructor() {
+    this.seen = {};
+  }
+  /**
+   * @param {string} value
+   */
+  serialize(n) {
+    return n.toLowerCase().trim().replace(/<[!\/a-z].*?>/ig, "").replace(/[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,./:;<=>?@[\]^`{|}~]/g, "").replace(/\s/g, "-");
+  }
+  /**
+   * Finds the next safe (unique) slug to use
+   * @param {string} originalSlug
+   * @param {boolean} isDryRun
+   */
+  getNextSafeSlug(n, e) {
+    let t = n, i = 0;
+    if (this.seen.hasOwnProperty(t)) {
+      i = this.seen[n];
+      do
+        i++, t = n + "-" + i;
+      while (this.seen.hasOwnProperty(t));
+    }
+    return e || (this.seen[n] = i, this.seen[t] = 0), t;
+  }
+  /**
+   * Convert string to unique id
+   * @param {object} [options]
+   * @param {boolean} [options.dryrun] Generates the next unique slug without
+   * updating the internal accumulator.
+   */
+  slug(n, e = {}) {
+    const t = this.serialize(n);
+    return this.getNextSafeSlug(t, e.dryrun);
+  }
+}
+class E {
+  constructor(n) {
+    this.options = n || A, this.options.renderer = this.options.renderer || new q(), this.renderer = this.options.renderer, this.renderer.options = this.options, this.textRenderer = new F(), this.slugger = new Y();
+  }
+  /**
+   * Static Parse Method
+   */
+  static parse(n, e) {
+    return new E(e).parse(n);
+  }
+  /**
+   * Static Parse Inline Method
+   */
+  static parseInline(n, e) {
+    return new E(e).parseInline(n);
+  }
+  /**
+   * Parse Loop
+   */
+  parse(n, e = !0) {
+    let t = "", i, s, a, r, c, m, f, d, p, o, x, b, v, w, y, R, z, T, _;
+    const L = n.length;
+    for (i = 0; i < L; i++) {
+      if (o = n[i], this.options.extensions && this.options.extensions.renderers && this.options.extensions.renderers[o.type] && (_ = this.options.extensions.renderers[o.type].call({ parser: this }, o), _ !== !1 || !["space", "hr", "heading", "code", "table", "blockquote", "list", "html", "paragraph", "text"].includes(o.type))) {
+        t += _ || "";
+        continue;
+      }
+      switch (o.type) {
+        case "space":
+          continue;
+        case "hr": {
+          t += this.renderer.hr();
+          continue;
+        }
+        case "heading": {
+          t += this.renderer.heading(
+            this.parseInline(o.tokens),
+            o.depth,
+            V(this.parseInline(o.tokens, this.textRenderer)),
+            this.slugger
+          );
+          continue;
+        }
+        case "code": {
+          t += this.renderer.code(
+            o.text,
+            o.lang,
+            o.escaped
+          );
+          continue;
+        }
+        case "table": {
+          for (d = "", f = "", r = o.header.length, s = 0; s < r; s++)
+            f += this.renderer.tablecell(
+              this.parseInline(o.header[s].tokens),
+              { header: !0, align: o.align[s] }
+            );
+          for (d += this.renderer.tablerow(f), p = "", r = o.rows.length, s = 0; s < r; s++) {
+            for (m = o.rows[s], f = "", c = m.length, a = 0; a < c; a++)
+              f += this.renderer.tablecell(
+                this.parseInline(m[a].tokens),
+                { header: !1, align: o.align[a] }
+              );
+            p += this.renderer.tablerow(f);
+          }
+          t += this.renderer.table(d, p);
+          continue;
+        }
+        case "blockquote": {
+          p = this.parse(o.tokens), t += this.renderer.blockquote(p);
+          continue;
+        }
+        case "list": {
+          for (x = o.ordered, b = o.start, v = o.loose, r = o.items.length, p = "", s = 0; s < r; s++)
+            y = o.items[s], R = y.checked, z = y.task, w = "", y.task && (T = this.renderer.checkbox(R), v ? y.tokens.length > 0 && y.tokens[0].type === "paragraph" ? (y.tokens[0].text = T + " " + y.tokens[0].text, y.tokens[0].tokens && y.tokens[0].tokens.length > 0 && y.tokens[0].tokens[0].type === "text" && (y.tokens[0].tokens[0].text = T + " " + y.tokens[0].tokens[0].text)) : y.tokens.unshift({
+              type: "text",
+              text: T
+            }) : w += T), w += this.parse(y.tokens, v), p += this.renderer.listitem(w, z, R);
+          t += this.renderer.list(p, x, b);
+          continue;
+        }
+        case "html": {
+          t += this.renderer.html(o.text);
+          continue;
+        }
+        case "paragraph": {
+          t += this.renderer.paragraph(this.parseInline(o.tokens));
+          continue;
+        }
+        case "text": {
+          for (p = o.tokens ? this.parseInline(o.tokens) : o.text; i + 1 < L && n[i + 1].type === "text"; )
+            o = n[++i], p += `
+` + (o.tokens ? this.parseInline(o.tokens) : o.text);
+          t += e ? this.renderer.paragraph(p) : p;
+          continue;
+        }
+        default: {
+          const O = 'Token with "' + o.type + '" type was not found.';
+          if (this.options.silent) {
+            console.error(O);
+            return;
+          } else
+            throw new Error(O);
+        }
+      }
+    }
+    return t;
+  }
+  /**
+   * Parse Inline Tokens
+   */
+  parseInline(n, e) {
+    e = e || this.renderer;
+    let t = "", i, s, a;
+    const r = n.length;
+    for (i = 0; i < r; i++) {
+      if (s = n[i], this.options.extensions && this.options.extensions.renderers && this.options.extensions.renderers[s.type] && (a = this.options.extensions.renderers[s.type].call({ parser: this }, s), a !== !1 || !["escape", "html", "link", "image", "strong", "em", "codespan", "br", "del", "text"].includes(s.type))) {
+        t += a || "";
+        continue;
+      }
+      switch (s.type) {
+        case "escape": {
+          t += e.text(s.text);
+          break;
+        }
+        case "html": {
+          t += e.html(s.text);
+          break;
+        }
+        case "link": {
+          t += e.link(s.href, s.title, this.parseInline(s.tokens, e));
+          break;
+        }
+        case "image": {
+          t += e.image(s.href, s.title, s.text);
+          break;
+        }
+        case "strong": {
+          t += e.strong(this.parseInline(s.tokens, e));
+          break;
+        }
+        case "em": {
+          t += e.em(this.parseInline(s.tokens, e));
+          break;
+        }
+        case "codespan": {
+          t += e.codespan(s.text);
+          break;
+        }
+        case "br": {
+          t += e.br();
+          break;
+        }
+        case "del": {
+          t += e.del(this.parseInline(s.tokens, e));
+          break;
+        }
+        case "text": {
+          t += e.text(s.text);
+          break;
+        }
+        default: {
+          const c = 'Token with "' + s.type + '" type was not found.';
+          if (this.options.silent) {
+            console.error(c);
+            return;
+          } else
+            throw new Error(c);
+        }
+      }
+    }
+    return t;
+  }
+}
+class N {
+  constructor(n) {
+    this.options = n || A;
+  }
+  /**
+   * Process markdown before marked
+   */
+  preprocess(n) {
+    return n;
+  }
+  /**
+   * Process HTML after marked is finished
+   */
+  postprocess(n) {
+    return n;
+  }
+}
+D(N, "passThroughHooks", /* @__PURE__ */ new Set([
+  "preprocess",
+  "postprocess"
+]));
+function wt(l, n, e) {
+  return (t) => {
+    if (t.message += `
+Please report this to https://github.com/markedjs/marked.`, l) {
+      const i = "<p>An error occurred:</p><pre>" + S(t.message + "", !0) + "</pre>";
+      if (n)
+        return Promise.resolve(i);
+      if (e) {
+        e(null, i);
+        return;
+      }
+      return i;
+    }
+    if (n)
+      return Promise.reject(t);
+    if (e) {
+      e(t);
+      return;
+    }
+    throw t;
+  };
+}
+function X(l, n) {
+  return (e, t, i) => {
+    typeof t == "function" && (i = t, t = null);
+    const s = { ...t };
+    t = { ...g.defaults, ...s };
+    const a = wt(t.silent, t.async, i);
+    if (typeof e > "u" || e === null)
+      return a(new Error("marked(): input parameter is undefined or null"));
+    if (typeof e != "string")
+      return a(new Error("marked(): input parameter is of type " + Object.prototype.toString.call(e) + ", string expected"));
+    if (ft(t), t.hooks && (t.hooks.options = t), i) {
+      const r = t.highlight;
+      let c;
+      try {
+        t.hooks && (e = t.hooks.preprocess(e)), c = l(e, t);
+      } catch (d) {
+        return a(d);
+      }
+      const m = function(d) {
+        let p;
+        if (!d)
+          try {
+            t.walkTokens && g.walkTokens(c, t.walkTokens), p = n(c, t), t.hooks && (p = t.hooks.postprocess(p));
+          } catch (o) {
+            d = o;
+          }
+        return t.highlight = r, d ? a(d) : i(null, p);
+      };
+      if (!r || r.length < 3 || (delete t.highlight, !c.length))
+        return m();
+      let f = 0;
+      g.walkTokens(c, function(d) {
+        d.type === "code" && (f++, setTimeout(() => {
+          r(d.text, d.lang, function(p, o) {
+            if (p)
+              return m(p);
+            o != null && o !== d.text && (d.text = o, d.escaped = !0), f--, f === 0 && m();
+          });
+        }, 0));
+      }), f === 0 && m();
+      return;
+    }
+    if (t.async)
+      return Promise.resolve(t.hooks ? t.hooks.preprocess(e) : e).then((r) => l(r, t)).then((r) => t.walkTokens ? Promise.all(g.walkTokens(r, t.walkTokens)).then(() => r) : r).then((r) => n(r, t)).then((r) => t.hooks ? t.hooks.postprocess(r) : r).catch(a);
+    try {
+      t.hooks && (e = t.hooks.preprocess(e));
+      const r = l(e, t);
+      t.walkTokens && g.walkTokens(r, t.walkTokens);
+      let c = n(r, t);
+      return t.hooks && (c = t.hooks.postprocess(c)), c;
+    } catch (r) {
+      return a(r);
+    }
+  };
+}
+function g(l, n, e) {
+  return X($.lex, E.parse)(l, n, e);
+}
+g.options = g.setOptions = function(l) {
+  return g.defaults = { ...g.defaults, ...l }, nt(g.defaults), g;
+};
+g.getDefaults = W;
+g.defaults = A;
+g.use = function(...l) {
+  const n = g.defaults.extensions || { renderers: {}, childTokens: {} };
+  l.forEach((e) => {
+    const t = { ...e };
+    if (t.async = g.defaults.async || t.async || !1, e.extensions && (e.extensions.forEach((i) => {
+      if (!i.name)
+        throw new Error("extension name required");
+      if (i.renderer) {
+        const s = n.renderers[i.name];
+        s ? n.renderers[i.name] = function(...a) {
+          let r = i.renderer.apply(this, a);
+          return r === !1 && (r = s.apply(this, a)), r;
+        } : n.renderers[i.name] = i.renderer;
+      }
+      if (i.tokenizer) {
+        if (!i.level || i.level !== "block" && i.level !== "inline")
+          throw new Error("extension level must be 'block' or 'inline'");
+        n[i.level] ? n[i.level].unshift(i.tokenizer) : n[i.level] = [i.tokenizer], i.start && (i.level === "block" ? n.startBlock ? n.startBlock.push(i.start) : n.startBlock = [i.start] : i.level === "inline" && (n.startInline ? n.startInline.push(i.start) : n.startInline = [i.start]));
+      }
+      i.childTokens && (n.childTokens[i.name] = i.childTokens);
+    }), t.extensions = n), e.renderer) {
+      const i = g.defaults.renderer || new q();
+      for (const s in e.renderer) {
+        const a = i[s];
+        i[s] = (...r) => {
+          let c = e.renderer[s].apply(i, r);
+          return c === !1 && (c = a.apply(i, r)), c;
+        };
+      }
+      t.renderer = i;
+    }
+    if (e.tokenizer) {
+      const i = g.defaults.tokenizer || new P();
+      for (const s in e.tokenizer) {
+        const a = i[s];
+        i[s] = (...r) => {
+          let c = e.tokenizer[s].apply(i, r);
+          return c === !1 && (c = a.apply(i, r)), c;
+        };
+      }
+      t.tokenizer = i;
+    }
+    if (e.hooks) {
+      const i = g.defaults.hooks || new N();
+      for (const s in e.hooks) {
+        const a = i[s];
+        N.passThroughHooks.has(s) ? i[s] = (r) => {
+          if (g.defaults.async)
+            return Promise.resolve(e.hooks[s].call(i, r)).then((m) => a.call(i, m));
+          const c = e.hooks[s].call(i, r);
+          return a.call(i, c);
+        } : i[s] = (...r) => {
+          let c = e.hooks[s].apply(i, r);
+          return c === !1 && (c = a.apply(i, r)), c;
+        };
+      }
+      t.hooks = i;
+    }
+    if (e.walkTokens) {
+      const i = g.defaults.walkTokens;
+      t.walkTokens = function(s) {
+        let a = [];
+        return a.push(e.walkTokens.call(this, s)), i && (a = a.concat(i.call(this, s))), a;
+      };
+    }
+    g.setOptions(t);
+  });
+};
+g.walkTokens = function(l, n) {
+  let e = [];
+  for (const t of l)
+    switch (e = e.concat(n.call(g, t)), t.type) {
+      case "table": {
+        for (const i of t.header)
+          e = e.concat(g.walkTokens(i.tokens, n));
+        for (const i of t.rows)
+          for (const s of i)
+            e = e.concat(g.walkTokens(s.tokens, n));
+        break;
+      }
+      case "list": {
+        e = e.concat(g.walkTokens(t.items, n));
+        break;
+      }
+      default:
+        g.defaults.extensions && g.defaults.extensions.childTokens && g.defaults.extensions.childTokens[t.type] ? g.defaults.extensions.childTokens[t.type].forEach(function(i) {
+          e = e.concat(g.walkTokens(t[i], n));
+        }) : t.tokens && (e = e.concat(g.walkTokens(t.tokens, n)));
+    }
+  return e;
+};
+g.parseInline = X($.lexInline, E.parseInline);
+g.Parser = E;
+g.parser = E.parse;
+g.Renderer = q;
+g.TextRenderer = F;
+g.Lexer = $;
+g.lexer = $.lex;
+g.Tokenizer = P;
+g.Slugger = Y;
+g.Hooks = N;
+g.parse = g;
+g.options;
+g.setOptions;
+g.use;
+g.walkTokens;
+g.parseInline;
+E.parse;
+$.lex;
+const xt = () => {
+  let l, n = null, e;
+  function t() {
+    if (n && !n.closed)
+      n.focus();
+    else {
+      if (n = window.open("about:blank", "reveal.js - Notes", "width=1100,height=700"), n.marked = g, n.document.write(et), !n) {
+        alert("Speaker view popup failed to open. Please make sure popups are allowed and reopen the speaker view.");
+        return;
+      }
+      s();
+    }
+  }
+  function i(d) {
+    n && !n.closed ? n.focus() : (n = d, window.addEventListener("message", m), f());
+  }
+  function s() {
+    const d = e.getConfig().url, p = typeof d == "string" ? d : window.location.protocol + "//" + window.location.host + window.location.pathname + window.location.search;
+    l = setInterval(function() {
+      n.postMessage(JSON.stringify({
+        namespace: "reveal-notes",
+        type: "connect",
+        state: e.getState(),
+        url: p
+      }), "*");
+    }, 500), window.addEventListener("message", m);
+  }
+  function a(d, p, o) {
+    let x = e[d].apply(e, p);
+    n.postMessage(JSON.stringify({
+      namespace: "reveal-notes",
+      type: "return",
+      result: x,
+      callId: o
+    }), "*");
+  }
+  function r(d) {
+    let p = e.getCurrentSlide(), o = p.querySelectorAll("aside.notes"), x = p.querySelector(".current-fragment"), b = {
+      namespace: "reveal-notes",
+      type: "state",
+      notes: "",
+      markdown: !1,
+      whitespace: "normal",
+      state: e.getState()
+    };
+    if (p.hasAttribute("data-notes") && (b.notes = p.getAttribute("data-notes"), b.whitespace = "pre-wrap"), x) {
+      let v = x.querySelector("aside.notes");
+      v ? (b.notes = v.innerHTML, b.markdown = typeof v.getAttribute("data-markdown") == "string", o = null) : x.hasAttribute("data-notes") && (b.notes = x.getAttribute("data-notes"), b.whitespace = "pre-wrap", o = null);
+    }
+    o && o.length && (o = Array.from(o).filter((v) => v.closest(".fragment") === null), b.notes = o.map((v) => v.innerHTML).join(`
+`), b.markdown = o[0] && typeof o[0].getAttribute("data-markdown") == "string"), n.postMessage(JSON.stringify(b), "*");
+  }
+  function c(d) {
+    try {
+      return window.location.origin === d.source.location.origin;
+    } catch {
+      return !1;
+    }
+  }
+  function m(d) {
+    if (c(d))
+      try {
+        let p = JSON.parse(d.data);
+        p && p.namespace === "reveal-notes" && p.type === "connected" ? (clearInterval(l), f()) : p && p.namespace === "reveal-notes" && p.type === "call" && a(p.methodName, p.arguments, p.callId);
+      } catch {
+      }
+  }
+  function f() {
+    e.on("slidechanged", r), e.on("fragmentshown", r), e.on("fragmenthidden", r), e.on("overviewhidden", r), e.on("overviewshown", r), e.on("paused", r), e.on("resumed", r), r();
+  }
+  return {
+    id: "notes",
+    init: function(d) {
+      e = d, /receiver/i.test(window.location.search) || (window.location.search.match(/(\?|\&)notes/gi) !== null ? t() : window.addEventListener("message", (p) => {
+        if (!n && typeof p.data == "string") {
+          let o;
+          try {
+            o = JSON.parse(p.data);
+          } catch {
+          }
+          o && o.namespace === "reveal-notes" && o.type === "heartbeat" && i(p.source);
+        }
+      }), e.addKeyBinding({ keyCode: 83, key: "S", description: "Speaker notes view" }, function() {
+        t();
+      }));
+    },
+    open: t
+  };
+};
+export {
+  xt as default
+};

Filskillnaden har hållts tillbaka eftersom den är för stor
+ 6 - 0
dist/plugin/search.js


+ 83 - 0
dist/plugin/search.mjs

@@ -0,0 +1,83 @@
+/*!
+ * Handles finding a text string anywhere in the slides and showing the next occurrence to the user
+ * by navigatating to that slide and highlighting it.
+ *
+ * @author Jon Snyder <snyder.jon@gmail.com>, February 2013
+ */
+const D = () => {
+  let c, t, i, n, a, y, s;
+  function g() {
+    t = document.createElement("div"), t.classList.add("searchbox"), t.style.position = "absolute", t.style.top = "10px", t.style.right = "10px", t.style.zIndex = 10, t.innerHTML = `<input type="search" class="searchinput" placeholder="Search..." style="vertical-align: top;"/>
+		</span>`, i = t.querySelector(".searchinput"), i.style.width = "240px", i.style.fontSize = "14px", i.style.padding = "4px 6px", i.style.color = "#000", i.style.background = "#fff", i.style.borderRadius = "2px", i.style.border = "0", i.style.outline = "0", i.style.boxShadow = "0 2px 18px rgba(0, 0, 0, 0.2)", i.style["-webkit-appearance"] = "none", c.getRevealElement().appendChild(t), i.addEventListener("keyup", function(r) {
+      switch (r.keyCode) {
+        case 13:
+          r.preventDefault(), k(), y = !1;
+          break;
+        default:
+          y = !0;
+      }
+    }, !1), w();
+  }
+  function b() {
+    t || g(), t.style.display = "inline", i.focus(), i.select();
+  }
+  function w() {
+    t || g(), t.style.display = "none", s && s.remove();
+  }
+  function R() {
+    t || g(), t.style.display !== "inline" ? b() : w();
+  }
+  function k() {
+    if (y) {
+      var r = i.value;
+      r === "" ? (s && s.remove(), n = null) : (s = new T("slidecontent"), n = s.apply(r), a = 0);
+    }
+    n && (n.length && n.length <= a && (a = 0), n.length > a && (c.slide(n[a].h, n[a].v), a++));
+  }
+  function T(r, f) {
+    var L = document.getElementById(r) || document.body, v = f || "EM", I = new RegExp("^(?:" + v + "|SCRIPT|FORM)$"), C = ["#ff6", "#a0ffff", "#9f9", "#f99", "#f6f"], x = [], M = 0, p = "", d = [];
+    this.setRegex = function(e) {
+      e = e.trim(), p = new RegExp("(" + e + ")", "i");
+    }, this.getRegex = function() {
+      return p.toString().replace(/^\/\\b\(|\)\\b\/i$/g, "").replace(/\|/g, " ");
+    }, this.hiliteWords = function(e) {
+      if (!(e == null || !e) && p && !I.test(e.nodeName)) {
+        if (e.hasChildNodes())
+          for (var l = 0; l < e.childNodes.length; l++)
+            this.hiliteWords(e.childNodes[l]);
+        if (e.nodeType == 3) {
+          var E, o;
+          if ((E = e.nodeValue) && (o = p.exec(E))) {
+            for (var h = e; h != null && h.nodeName != "SECTION"; )
+              h = h.parentNode;
+            for (var m = c.getIndices(h), B = d.length, N = !1, l = 0; l < B; l++)
+              d[l].h === m.h && d[l].v === m.v && (N = !0);
+            N || d.push(m), x[o[0].toLowerCase()] || (x[o[0].toLowerCase()] = C[M++ % C.length]);
+            var u = document.createElement(v);
+            u.appendChild(document.createTextNode(o[0])), u.style.backgroundColor = x[o[0].toLowerCase()], u.style.fontStyle = "inherit", u.style.color = "#000";
+            var S = e.splitText(o.index);
+            S.nodeValue = S.nodeValue.substring(o[0].length), e.parentNode.insertBefore(u, S);
+          }
+        }
+      }
+    }, this.remove = function() {
+      for (var e = document.getElementsByTagName(v), l; e.length && (l = e[0]); )
+        l.parentNode.replaceChild(l.firstChild, l);
+    }, this.apply = function(e) {
+      if (!(e == null || !e))
+        return this.remove(), this.setRegex(e), this.hiliteWords(L), d;
+    };
+  }
+  return {
+    id: "search",
+    init: (r) => {
+      c = r, c.registerKeyboardShortcut("CTRL + Shift + F", "Search"), document.addEventListener("keydown", function(f) {
+        f.key == "F" && (f.ctrlKey || f.metaKey) && (f.preventDefault(), R());
+      }, !1);
+    },
+    open: b
+  };
+};
+export {
+  D as default
+};

Filskillnaden har hållts tillbaka eftersom den är för stor
+ 8 - 0
dist/plugin/zoom.js


+ 102 - 0
dist/plugin/zoom.mjs

@@ -0,0 +1,102 @@
+/*!
+ * reveal.js Zoom plugin
+ */
+const c = {
+  id: "zoom",
+  init: function(n) {
+    n.getRevealElement().addEventListener("mousedown", function(o) {
+      var l = /Linux/.test(window.navigator.platform) ? "ctrl" : "alt", f = (n.getConfig().zoomKey ? n.getConfig().zoomKey : l) + "Key", m = n.getConfig().zoomLevel ? n.getConfig().zoomLevel : 2;
+      o[f] && !n.isOverview() && (o.preventDefault(), r.to({
+        x: o.clientX,
+        y: o.clientY,
+        scale: m,
+        pan: !1
+      }));
+    });
+  },
+  destroy: () => {
+    r.reset();
+  }
+}, h = () => c;
+/*!
+ * zoom.js 0.3 (modified for use with reveal.js)
+ * http://lab.hakim.se/zoom-js
+ * MIT licensed
+ *
+ * Copyright (C) 2011-2014 Hakim El Hattab, http://hakim.se
+ */
+var r = function() {
+  var n = 1, o = 0, l = 0, f = -1, m = -1, u = "transform" in document.body.style;
+  u && (document.body.style.transition = "transform 0.8s ease"), document.addEventListener("keyup", function(e) {
+    n !== 1 && e.keyCode === 27 && r.out();
+  }), document.addEventListener("mousemove", function(e) {
+    n !== 1 && (o = e.clientX, l = e.clientY);
+  });
+  function y(e, t) {
+    var i = s();
+    if (e.width = e.width || 1, e.height = e.height || 1, e.x -= (window.innerWidth - e.width * t) / 2, e.y -= (window.innerHeight - e.height * t) / 2, u)
+      if (t === 1)
+        document.body.style.transform = "";
+      else {
+        var d = i.x + "px " + i.y + "px", w = "translate(" + -e.x + "px," + -e.y + "px) scale(" + t + ")";
+        document.body.style.transformOrigin = d, document.body.style.transform = w;
+      }
+    else
+      t === 1 ? (document.body.style.position = "", document.body.style.left = "", document.body.style.top = "", document.body.style.width = "", document.body.style.height = "", document.body.style.zoom = "") : (document.body.style.position = "relative", document.body.style.left = -(i.x + e.x) / t + "px", document.body.style.top = -(i.y + e.y) / t + "px", document.body.style.width = t * 100 + "%", document.body.style.height = t * 100 + "%", document.body.style.zoom = t);
+    n = t, document.documentElement.classList && (n !== 1 ? document.documentElement.classList.add("zoomed") : document.documentElement.classList.remove("zoomed"));
+  }
+  function a() {
+    var e = 0.12, t = window.innerWidth * e, i = window.innerHeight * e, d = s();
+    l < i ? window.scroll(d.x, d.y - (1 - l / i) * (14 / n)) : l > window.innerHeight - i && window.scroll(d.x, d.y + (1 - (window.innerHeight - l) / i) * (14 / n)), o < t ? window.scroll(d.x - (1 - o / t) * (14 / n), d.y) : o > window.innerWidth - t && window.scroll(d.x + (1 - (window.innerWidth - o) / t) * (14 / n), d.y);
+  }
+  function s() {
+    return {
+      x: window.scrollX !== void 0 ? window.scrollX : window.pageXOffset,
+      y: window.scrollY !== void 0 ? window.scrollY : window.pageYOffset
+    };
+  }
+  return {
+    /**
+     * Zooms in on either a rectangle or HTML element.
+     *
+     * @param {Object} options
+     *   - element: HTML element to zoom in on
+     *   OR
+     *   - x/y: coordinates in non-transformed space to zoom in on
+     *   - width/height: the portion of the screen to zoom in on
+     *   - scale: can be used instead of width/height to explicitly set scale
+     */
+    to: function(e) {
+      if (n !== 1)
+        r.out();
+      else {
+        if (e.x = e.x || 0, e.y = e.y || 0, e.element) {
+          var t = 20, i = e.element.getBoundingClientRect();
+          e.x = i.left - t, e.y = i.top - t, e.width = i.width + t * 2, e.height = i.height + t * 2;
+        }
+        e.width !== void 0 && e.height !== void 0 && (e.scale = Math.max(Math.min(window.innerWidth / e.width, window.innerHeight / e.height), 1)), e.scale > 1 && (e.x *= e.scale, e.y *= e.scale, y(e, e.scale), e.pan !== !1 && (f = setTimeout(function() {
+          m = setInterval(a, 1e3 / 60);
+        }, 800)));
+      }
+    },
+    /**
+     * Resets the document zoom state to its default.
+     */
+    out: function() {
+      clearTimeout(f), clearInterval(m), y({ x: 0, y: 0 }, 1), n = 1;
+    },
+    // Alias
+    magnify: function(e) {
+      this.to(e);
+    },
+    reset: function() {
+      this.out();
+    },
+    zoomLevel: function() {
+      return n;
+    }
+  };
+}();
+export {
+  h as default
+};

+ 1 - 30
dist/reset.css

@@ -1,30 +1 @@
-/* http://meyerweb.com/eric/tools/css/reset/
-   v4.0 | 20180602
-   License: none (public domain)
-*/
-
-html, body, div, span, applet, object, iframe,
-h1, h2, h3, h4, h5, h6, p, blockquote, pre,
-a, abbr, acronym, address, big, cite, code,
-del, dfn, em, img, ins, kbd, q, s, samp,
-small, strike, strong, sub, sup, tt, var,
-b, u, i, center,
-dl, dt, dd, ol, ul, li,
-fieldset, form, label, legend,
-table, caption, tbody, tfoot, thead, tr, th, td,
-article, aside, canvas, details, embed,
-figure, figcaption, footer, header, hgroup,
-main, menu, nav, output, ruby, section, summary,
-time, mark, audio, video {
-  margin: 0;
-  padding: 0;
-  border: 0;
-  font-size: 100%;
-  font: inherit;
-  vertical-align: baseline;
-}
-/* HTML5 display-role reset for older browsers */
-article, aside, details, figcaption, figure,
-footer, header, hgroup, main, menu, nav, section {
-  display: block;
-}
+html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,main,menu,nav,output,ruby,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;font-size:100%;font:inherit;vertical-align:baseline}article,aside,details,figcaption,figure,footer,header,hgroup,main,menu,nav,section{display:block}

Filskillnaden har hållts tillbaka eftersom den är för stor
+ 0 - 0
dist/reveal.css


+ 3 - 0
dist/reveal.d.mts

@@ -0,0 +1,3 @@
+export * from './index'
+import Reveal from './index'
+export default Reveal

Filskillnaden har hållts tillbaka eftersom den är för stor
+ 1756 - 0
dist/reveal.mjs


+ 12 - 6
dist/theme/black.css

@@ -4,7 +4,13 @@
  * By Hakim El Hattab, http://hakim.se
  */
 @import url(./fonts/source-sans-pro/source-sans-pro.css);
-section.has-light-background, section.has-light-background h1, section.has-light-background h2, section.has-light-background h3, section.has-light-background h4, section.has-light-background h5, section.has-light-background h6 {
+section.has-light-background,
+section.has-light-background h1,
+section.has-light-background h2,
+section.has-light-background h3,
+section.has-light-background h4,
+section.has-light-background h5,
+section.has-light-background h6 {
   color: #222;
 }
 
@@ -257,13 +263,13 @@ section.has-light-background, section.has-light-background h1, section.has-light
   border-bottom: 1px solid;
 }
 
-.reveal table th[align=center],
-.reveal table td[align=center] {
+.reveal table th[align="center"],
+.reveal table td[align="center"] {
   text-align: center;
 }
 
-.reveal table th[align=right],
-.reveal table td[align=right] {
+.reveal table th[align="right"],
+.reveal table td[align="right"] {
   text-align: right;
 }
 
@@ -356,4 +362,4 @@ section.has-light-background, section.has-light-background h1, section.has-light
   .backgrounds {
     background-color: var(--r-background-color);
   }
-}
+}

+ 0 - 360
dist/theme/white_contrast_compact_verbatim_headers.css

@@ -1,360 +0,0 @@
-/**
- * White compact & high contrast reveal.js theme, with headers not in capitals.
- *
- * By Peter Kehl. Based on white.(s)css by Hakim El Hattab, http://hakim.se
- *
- * - Keep the source similar to black.css - for easy comparison.
- * - $mainFontSize controls code blocks, too (although under some ratio).
- */
-@import url(./fonts/source-sans-pro/source-sans-pro.css);
-section.has-dark-background, section.has-dark-background h1, section.has-dark-background h2, section.has-dark-background h3, section.has-dark-background h4, section.has-dark-background h5, section.has-dark-background h6 {
-  color: #fff;
-}
-
-/*********************************************
- * GLOBAL STYLES
- *********************************************/
-:root {
-  --r-background-color: #fff;
-  --r-main-font: Source Sans Pro, Helvetica, sans-serif;
-  --r-main-font-size: 25px;
-  --r-main-color: #000;
-  --r-block-margin: 20px;
-  --r-heading-margin: 0 0 20px 0;
-  --r-heading-font: Source Sans Pro, Helvetica, sans-serif;
-  --r-heading-color: #000;
-  --r-heading-line-height: 1.2;
-  --r-heading-letter-spacing: normal;
-  --r-heading-text-transform: none;
-  --r-heading-text-shadow: none;
-  --r-heading-font-weight: 450;
-  --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: monospace;
-  --r-link-color: #2a76dd;
-  --r-link-color-dark: #1a53a1;
-  --r-link-color-hover: #6ca0e8;
-  --r-selection-background-color: #98bdef;
-  --r-selection-color: #fff;
-}
-
-.reveal-viewport {
-  background: #fff;
-  background-color: var(--r-background-color);
-}
-
-.reveal {
-  font-family: var(--r-main-font);
-  font-size: var(--r-main-font-size);
-  font-weight: normal;
-  color: var(--r-main-color);
-}
-
-.reveal ::selection {
-  color: var(--r-selection-color);
-  background: var(--r-selection-background-color);
-  text-shadow: none;
-}
-
-.reveal ::-moz-selection {
-  color: var(--r-selection-color);
-  background: var(--r-selection-background-color);
-  text-shadow: none;
-}
-
-.reveal .slides section,
-.reveal .slides section > section {
-  line-height: 1.3;
-  font-weight: inherit;
-}
-
-/*********************************************
- * HEADERS
- *********************************************/
-.reveal h1,
-.reveal h2,
-.reveal h3,
-.reveal h4,
-.reveal h5,
-.reveal h6 {
-  margin: var(--r-heading-margin);
-  color: var(--r-heading-color);
-  font-family: var(--r-heading-font);
-  font-weight: var(--r-heading-font-weight);
-  line-height: var(--r-heading-line-height);
-  letter-spacing: var(--r-heading-letter-spacing);
-  text-transform: var(--r-heading-text-transform);
-  text-shadow: var(--r-heading-text-shadow);
-  word-wrap: break-word;
-}
-
-.reveal h1 {
-  font-size: var(--r-heading1-size);
-}
-
-.reveal h2 {
-  font-size: var(--r-heading2-size);
-}
-
-.reveal h3 {
-  font-size: var(--r-heading3-size);
-}
-
-.reveal h4 {
-  font-size: var(--r-heading4-size);
-}
-
-.reveal h1 {
-  text-shadow: var(--r-heading1-text-shadow);
-}
-
-/*********************************************
- * OTHER
- *********************************************/
-.reveal p {
-  margin: var(--r-block-margin) 0;
-  line-height: 1.3;
-}
-
-/* Remove trailing margins after titles */
-.reveal h1:last-child,
-.reveal h2:last-child,
-.reveal h3:last-child,
-.reveal h4:last-child,
-.reveal h5:last-child,
-.reveal h6:last-child {
-  margin-bottom: 0;
-}
-
-/* Ensure certain elements are never larger than the slide itself */
-.reveal img,
-.reveal video,
-.reveal iframe {
-  max-width: 95%;
-  max-height: 95%;
-}
-
-.reveal strong,
-.reveal b {
-  font-weight: bold;
-}
-
-.reveal em {
-  font-style: italic;
-}
-
-.reveal ol,
-.reveal dl,
-.reveal ul {
-  display: inline-block;
-  text-align: left;
-  margin: 0 0 0 1em;
-}
-
-.reveal ol {
-  list-style-type: decimal;
-}
-
-.reveal ul {
-  list-style-type: disc;
-}
-
-.reveal ul ul {
-  list-style-type: square;
-}
-
-.reveal ul ul ul {
-  list-style-type: circle;
-}
-
-.reveal ul ul,
-.reveal ul ol,
-.reveal ol ol,
-.reveal ol ul {
-  display: block;
-  margin-left: 40px;
-}
-
-.reveal dt {
-  font-weight: bold;
-}
-
-.reveal dd {
-  margin-left: 40px;
-}
-
-.reveal blockquote {
-  display: block;
-  position: relative;
-  width: 70%;
-  margin: var(--r-block-margin) auto;
-  padding: 5px;
-  font-style: italic;
-  background: rgba(255, 255, 255, 0.05);
-  box-shadow: 0px 0px 2px rgba(0, 0, 0, 0.2);
-}
-
-.reveal blockquote p:first-child,
-.reveal blockquote p:last-child {
-  display: inline-block;
-}
-
-.reveal q {
-  font-style: italic;
-}
-
-.reveal pre {
-  display: block;
-  position: relative;
-  width: 90%;
-  margin: var(--r-block-margin) auto;
-  text-align: left;
-  font-size: 0.55em;
-  font-family: var(--r-code-font);
-  line-height: 1.2em;
-  word-wrap: break-word;
-  box-shadow: 0px 5px 15px rgba(0, 0, 0, 0.15);
-}
-
-.reveal code {
-  font-family: var(--r-code-font);
-  text-transform: none;
-  tab-size: 2;
-}
-
-.reveal pre code {
-  display: block;
-  padding: 5px;
-  overflow: auto;
-  max-height: 400px;
-  word-wrap: normal;
-}
-
-.reveal .code-wrapper {
-  white-space: normal;
-}
-
-.reveal .code-wrapper code {
-  white-space: pre;
-}
-
-.reveal table {
-  margin: auto;
-  border-collapse: collapse;
-  border-spacing: 0;
-}
-
-.reveal table th {
-  font-weight: bold;
-}
-
-.reveal table th,
-.reveal table td {
-  text-align: left;
-  padding: 0.2em 0.5em 0.2em 0.5em;
-  border-bottom: 1px solid;
-}
-
-.reveal table th[align=center],
-.reveal table td[align=center] {
-  text-align: center;
-}
-
-.reveal table th[align=right],
-.reveal table td[align=right] {
-  text-align: right;
-}
-
-.reveal table tbody tr:last-child th,
-.reveal table tbody tr:last-child td {
-  border-bottom: none;
-}
-
-.reveal sup {
-  vertical-align: super;
-  font-size: smaller;
-}
-
-.reveal sub {
-  vertical-align: sub;
-  font-size: smaller;
-}
-
-.reveal small {
-  display: inline-block;
-  font-size: 0.6em;
-  line-height: 1.2em;
-  vertical-align: top;
-}
-
-.reveal small * {
-  vertical-align: top;
-}
-
-.reveal img {
-  margin: var(--r-block-margin) 0;
-}
-
-/*********************************************
- * LINKS
- *********************************************/
-.reveal a {
-  color: var(--r-link-color);
-  text-decoration: none;
-  transition: color 0.15s ease;
-}
-
-.reveal a:hover {
-  color: var(--r-link-color-hover);
-  text-shadow: none;
-  border: none;
-}
-
-.reveal .roll span:after {
-  color: #fff;
-  background: var(--r-link-color-dark);
-}
-
-/*********************************************
- * Frame helper
- *********************************************/
-.reveal .r-frame {
-  border: 4px solid var(--r-main-color);
-  box-shadow: 0 0 10px rgba(0, 0, 0, 0.15);
-}
-
-.reveal a .r-frame {
-  transition: all 0.15s linear;
-}
-
-.reveal a:hover .r-frame {
-  border-color: var(--r-link-color);
-  box-shadow: 0 0 20px rgba(0, 0, 0, 0.55);
-}
-
-/*********************************************
- * NAVIGATION CONTROLS
- *********************************************/
-.reveal .controls {
-  color: var(--r-link-color);
-}
-
-/*********************************************
- * PROGRESS BAR
- *********************************************/
-.reveal .progress {
-  background: rgba(0, 0, 0, 0.2);
-  color: var(--r-link-color);
-}
-
-/*********************************************
- * PRINT BACKGROUND
- *********************************************/
-@media print {
-  .backgrounds {
-    background-color: var(--r-background-color);
-  }
-}

+ 20 - 8
index.html

@@ -6,9 +6,9 @@
 
 		<title>reveal.js</title>
 
-		<link rel="stylesheet" href="dist/reset.css">
-		<link rel="stylesheet" href="dist/reveal.css">
-		<link rel="stylesheet" href="dist/theme/black.css">
+		<link rel="stylesheet" href="css/reset.css">
+		<link rel="stylesheet" href="css/reveal.scss">
+		<link rel="stylesheet" href="css/theme/black.scss">
 
 		<!-- Theme used for syntax highlighted code -->
 		<link rel="stylesheet" href="plugin/highlight/monokai.css">
@@ -18,14 +18,26 @@
 			<div class="slides">
 				<section>Slide 1</section>
 				<section>Slide 2</section>
+				<section data-markdown>
+					<script type="text/template">
+						## Markdown Support
+
+						```html []
+						<section data-markdown>
+							## Markdown Support
+						</section>
+						```
+					</script>
+				</section>
 			</div>
 		</div>
 
-		<script src="dist/reveal.js"></script>
-		<script src="plugin/notes/notes.js"></script>
-		<script src="plugin/markdown/markdown.js"></script>
-		<script src="plugin/highlight/highlight.js"></script>
-		<script>
+		<script type="module">
+			import Reveal from 'reveal.js';
+			import RevealNotes from 'reveal.js/plugin/notes';
+			import RevealMarkdown from 'reveal.js/plugin/markdown';
+			import RevealHighlight from 'reveal.js/plugin/highlight';
+
 			// More info about initialization & config:
 			// - https://revealjs.com/initialization/
 			// - https://revealjs.com/config/

+ 0 - 333
js/config.js

@@ -1,333 +0,0 @@
-/**
- * The default reveal.js config object.
- */
-export default {
-
-	// The "normal" size of the presentation, aspect ratio will be preserved
-	// when the presentation is scaled to fit different resolutions
-	width: 960,
-	height: 700,
-
-	// Factor of the display size that should remain empty around the content
-	margin: 0.04,
-
-	// Bounds for smallest/largest possible scale to apply to content
-	minScale: 0.2,
-	maxScale: 2.0,
-
-	// Display presentation control arrows.
-	// - true: Display controls on all screens
-	// - false: Hide controls on all screens
-	// - "speaker-only": Only display controls in the speaker view
-	controls: true,
-
-	// Help the user learn the controls by providing hints, for example by
-	// bouncing the down arrow when they first encounter a vertical slide
-	controlsTutorial: true,
-
-	// Determines where controls appear, "edges" or "bottom-right"
-	controlsLayout: 'bottom-right',
-
-	// Visibility rule for backwards navigation arrows; "faded", "hidden"
-	// or "visible"
-	controlsBackArrows: 'faded',
-
-	// Display a presentation progress bar
-	progress: true,
-
-	// Display the page number of the current slide
-	// - true:    Show slide number
-	// - false:   Hide slide number
-	//
-	// Can optionally be set as a string that specifies the number formatting:
-	// - "h.v":	  Horizontal . vertical slide number (default)
-	// - "h/v":	  Horizontal / vertical slide number
-	// - "c":	  Flattened slide number
-	// - "c/t":	  Flattened slide number / total slides
-	//
-	// Alternatively, you can provide a function that returns the slide
-	// number for the current slide. The function should take in a slide
-	// object and return an array with one string [slideNumber] or
-	// three strings [n1,delimiter,n2]. See #formatSlideNumber().
-	slideNumber: false,
-
-	// Can be used to limit the contexts in which the slide number appears
-	// - "all":      Always show the slide number
-	// - "print":    Only when printing to PDF
-	// - "speaker":  Only in the speaker view
-	showSlideNumber: 'all',
-
-	// Use 1 based indexing for # links to match slide number (default is zero
-	// based)
-	hashOneBasedIndex: false,
-
-	// Add the current slide number to the URL hash so that reloading the
-	// page/copying the URL will return you to the same slide
-	hash: false,
-
-	// Flags if we should monitor the hash and change slides accordingly
-	respondToHashChanges: true,
-
-	// Enable support for jump-to-slide navigation shortcuts
-	jumpToSlide: true,
-
-	// Push each slide change to the browser history.  Implies `hash: true`
-	history: false,
-
-	// Enable keyboard shortcuts for navigation
-	keyboard: true,
-
-	// Optional function that blocks keyboard events when returning false
-	//
-	// If you set this to 'focused', we will only capture keyboard events
-	// for embedded decks when they are in focus
-	keyboardCondition: null,
-
-	// Disables the default reveal.js slide layout (scaling and centering)
-	// so that you can use custom CSS layout
-	disableLayout: false,
-
-	// Enable the slide overview mode
-	overview: true,
-
-	// Vertical centering of slides
-	center: true,
-
-	// Enables touch navigation on devices with touch input
-	touch: true,
-
-	// Loop the presentation
-	loop: false,
-
-	// Change the presentation direction to be RTL
-	rtl: false,
-
-	// Changes the behavior of our navigation directions.
-	//
-	// "default"
-	// Left/right arrow keys step between horizontal slides, up/down
-	// arrow keys step between vertical slides. Space key steps through
-	// all slides (both horizontal and vertical).
-	//
-	// "linear"
-	// Removes the up/down arrows. Left/right arrows step through all
-	// slides (both horizontal and vertical).
-	//
-	// "grid"
-	// When this is enabled, stepping left/right from a vertical stack
-	// to an adjacent vertical stack will land you at the same vertical
-	// index.
-	//
-	// Consider a deck with six slides ordered in two vertical stacks:
-	// 1.1    2.1
-	// 1.2    2.2
-	// 1.3    2.3
-	//
-	// If you're on slide 1.3 and navigate right, you will normally move
-	// from 1.3 -> 2.1. If "grid" is used, the same navigation takes you
-	// from 1.3 -> 2.3.
-	navigationMode: 'default',
-
-	// Randomizes the order of slides each time the presentation loads
-	shuffle: false,
-
-	// Turns fragments on and off globally
-	fragments: true,
-
-	// Flags whether to include the current fragment in the URL,
-	// so that reloading brings you to the same fragment position
-	fragmentInURL: true,
-
-	// Flags if the presentation is running in an embedded mode,
-	// i.e. contained within a limited portion of the screen
-	embedded: false,
-
-	// Flags if we should show a help overlay when the question-mark
-	// key is pressed
-	help: true,
-
-	// Flags if it should be possible to pause the presentation (blackout)
-	pause: true,
-
-	// Flags if speaker notes should be visible to all viewers
-	showNotes: false,
-
-	// Flags if slides with data-visibility="hidden" should be kep visible
-	showHiddenSlides: false,
-
-	// Global override for autoplaying embedded media (video/audio/iframe)
-	// - null:   Media will only autoplay if data-autoplay is present
-	// - true:   All media will autoplay, regardless of individual setting
-	// - false:  No media will autoplay, regardless of individual setting
-	autoPlayMedia: null,
-
-	// Global override for preloading lazy-loaded iframes
-	// - null:   Iframes with data-src AND data-preload will be loaded when within
-	//           the viewDistance, iframes with only data-src will be loaded when visible
-	// - true:   All iframes with data-src will be loaded when within the viewDistance
-	// - false:  All iframes with data-src will be loaded only when visible
-	preloadIframes: null,
-
-	// Can be used to globally disable auto-animation
-	autoAnimate: true,
-
-	// Optionally provide a custom element matcher that will be
-	// used to dictate which elements we can animate between.
-	autoAnimateMatcher: null,
-
-	// Default settings for our auto-animate transitions, can be
-	// overridden per-slide or per-element via data arguments
-	autoAnimateEasing: 'ease',
-	autoAnimateDuration: 1.0,
-	autoAnimateUnmatched: true,
-
-	// CSS properties that can be auto-animated. Position & scale
-	// is matched separately so there's no need to include styles
-	// like top/right/bottom/left, width/height or margin.
-	autoAnimateStyles: [
-		'opacity',
-		'color',
-		'background-color',
-		'padding',
-		'font-size',
-		'line-height',
-		'letter-spacing',
-		'border-width',
-		'border-color',
-		'border-radius',
-		'outline',
-		'outline-offset'
-	],
-
-	// Controls automatic progression to the next slide
-	// - 0:      Auto-sliding only happens if the data-autoslide HTML attribute
-	//           is present on the current slide or fragment
-	// - 1+:     All slides will progress automatically at the given interval
-	// - false:  No auto-sliding, even if data-autoslide is present
-	autoSlide: 0,
-
-	// Stop auto-sliding after user input
-	autoSlideStoppable: true,
-
-	// Use this method for navigation when auto-sliding (defaults to navigateNext)
-	autoSlideMethod: null,
-
-	// Specify the average time in seconds that you think you will spend
-	// presenting each slide. This is used to show a pacing timer in the
-	// speaker view
-	defaultTiming: null,
-
-	// Enable slide navigation via mouse wheel
-	mouseWheel: false,
-
-	// Opens links in an iframe preview overlay
-	// Add `data-preview-link` and `data-preview-link="false"` to customise each link
-	// individually
-	previewLinks: false,
-
-	// Exposes the reveal.js API through window.postMessage
-	postMessage: true,
-
-	// Dispatches all reveal.js events to the parent window through postMessage
-	postMessageEvents: false,
-
-	// Focuses body when page changes visibility to ensure keyboard shortcuts work
-	focusBodyOnPageVisibilityChange: true,
-
-	// Transition style
-	transition: 'slide', // none/fade/slide/convex/concave/zoom
-
-	// Transition speed
-	transitionSpeed: 'default', // default/fast/slow
-
-	// Transition style for full page slide backgrounds
-	backgroundTransition: 'fade', // none/fade/slide/convex/concave/zoom
-
-	// Parallax background image
-	parallaxBackgroundImage: '', // CSS syntax, e.g. "a.jpg"
-
-	// Parallax background size
-	parallaxBackgroundSize: '', // CSS syntax, e.g. "3000px 2000px"
-
-	// Parallax background repeat
-	parallaxBackgroundRepeat: '', // repeat/repeat-x/repeat-y/no-repeat/initial/inherit
-
-	// Parallax background position
-	parallaxBackgroundPosition: '', // CSS syntax, e.g. "top left"
-
-	// Amount of pixels to move the parallax background per slide step
-	parallaxBackgroundHorizontal: null,
-	parallaxBackgroundVertical: null,
-
-	// Can be used to initialize reveal.js in one of the following views:
-	// - print:   Render the presentation so that it can be printed to PDF
-	// - scroll:  Show the presentation as a tall scrollable page with scroll
-	//            triggered animations
-	view: null,
-
-	// Adjusts the height of each slide in the scroll view.
-	// - full:       Each slide is as tall as the viewport
-	// - compact:    Slides are as small as possible, allowing multiple slides
-	//               to be visible in parallel on tall devices
-	scrollLayout: 'full',
-
-	// Control how scroll snapping works in the scroll view.
-	// - false:   	No snapping, scrolling is continuous
-	// - proximity:  Snap when close to a slide
-	// - mandatory:  Always snap to the closest slide
-	//
-	// Only applies to presentations in scroll view.
-	scrollSnap: 'mandatory',
-
-	// Enables and configure the scroll view progress bar.
-	// - 'auto':    Show the scrollbar while scrolling, hide while idle
-	// - true:      Always show the scrollbar
-	// - false:     Never show the scrollbar
-	scrollProgress: 'auto',
-
-	// Automatically activate the scroll view when we the viewport falls
-	// below the given width.
-	scrollActivationWidth: 435,
-
-	// The maximum number of pages a single slide can expand onto when printing
-	// to PDF, unlimited by default
-	pdfMaxPagesPerSlide: Number.POSITIVE_INFINITY,
-
-	// Prints each fragment on a separate slide
-	pdfSeparateFragments: true,
-
-	// Offset used to reduce the height of content within exported PDF pages.
-	// This exists to account for environment differences based on how you
-	// print to PDF. CLI printing options, like phantomjs and wkpdf, can end
-	// on precisely the total height of the document whereas in-browser
-	// printing has to end one pixel before.
-	pdfPageHeightOffset: -1,
-
-	// Number of slides away from the current that are visible
-	viewDistance: 3,
-
-	// Number of slides away from the current that are visible on mobile
-	// devices. It is advisable to set this to a lower number than
-	// viewDistance in order to save resources.
-	mobileViewDistance: 2,
-
-	// The display mode that will be used to show slides
-	display: 'block',
-
-	// Hide cursor if inactive
-	hideInactiveCursor: true,
-
-	// Time before the cursor is hidden (in ms)
-	hideCursorTime: 5000,
-
-	// Should we automatically sort and set indices for fragments
-	// at each sync? (See Reveal.sync)
-	sortFragmentsOnSync: true,
-
-	// Script dependencies to load
-	dependencies: [],
-
-	// Plugin objects to register and use for this presentation
-	plugins: []
-
-}

+ 651 - 0
js/config.ts

@@ -0,0 +1,651 @@
+// TODO convert all line to blocks + add comments for each prop
+type RevealConfig = {
+	// The "normal" size of the presentation, aspect ratio will be preserved
+	// when the presentation is scaled to fit different resolutions
+	width: number | string;
+	height: number | string;
+
+	// Factor of the display size that should remain empty around the content
+	margin: number;
+
+	// Bounds for smallest/largest possible scale to apply to content
+	minScale: number;
+	maxScale: number;
+
+	// Display presentation control arrows
+	// - true: Display controls on all screens
+	// - false: Hide controls on all screens
+	// - "speaker-only": Only display controls in the speaker view
+	controls: boolean | 'speaker-only';
+
+	// Help the user learn the controls by providing hints, for example by
+	// bouncing the down arrow when they first encounter a vertical slide
+	controlsTutorial: boolean;
+
+	// Determines where controls appear, "edges" or "bottom-right"
+	controlsLayout: 'edges' | 'bottom-right';
+
+	// Visibility rule for backwards navigation arrows; "faded", "hidden"
+	// or "visible"
+	controlsBackArrows: 'faded' | 'hidden' | 'visible';
+
+	// Display a presentation progress bar
+	progress: boolean;
+
+	// Display the page number of the current slide
+	// - true:    Show slide number
+	// - false:   Hide slide number
+	//
+	// Can optionally be set as a string that specifies the number formatting:
+	// - "h.v":	  Horizontal . vertical slide number (default)
+	// - "h/v":	  Horizontal / vertical slide number
+	// - "c":	  Flattened slide number
+	// - "c/t":	  Flattened slide number / total slides
+	//
+	// Alternatively, you can provide a function that returns the slide
+	// number for the current slide. The function should take in a slide
+	// object and return an array with one string [slideNumber] or
+	// three strings [n1,delimiter,n2]. See #formatSlideNumber().
+	slideNumber: boolean | 'h.v' | 'h/v' | 'c' | 'c/t' | ((slide: any) => string | [string, string, string]);
+
+	// Can be used to limit the contexts in which the slide number appears
+	// - "all":      Always show the slide number
+	// - "print":    Only when printing to PDF
+	// - "speaker":  Only in the speaker view
+	showSlideNumber: 'all' | 'print' | 'speaker';
+
+	// Use 1 based indexing for # links to match slide number (default is zero
+	// based)
+	hashOneBasedIndex: boolean;
+
+	// Add the current slide number to the URL hash so that reloading the
+	// page/copying the URL will return you to the same slide
+	hash: boolean;
+
+	// Flags if we should monitor the hash and change slides accordingly
+	respondToHashChanges: boolean;
+
+	// Enable support for jump-to-slide navigation shortcuts
+	jumpToSlide: boolean;
+
+	// Push each slide change to the browser history.  Implies `hash: true`
+	history: boolean;
+
+	// Enable keyboard shortcuts for navigation
+	keyboard: boolean;
+
+	// Optional function that blocks keyboard events when retuning false
+	//
+	// If you set this to 'focused', we will only capture keyboard events
+	// for embedded decks when they are in focus
+	keyboardCondition: null | 'focused' | ((event: KeyboardEvent) => boolean);
+
+	// Disables the default reveal.js slide layout (scaling and centering)
+	// so that you can use custom CSS layout
+	disableLayout: boolean;
+
+	// Enable the slide overview mode
+	overview: boolean;
+
+	// Vertical centering of slides
+	center: boolean;
+
+	// Enables touch navigation on devices with touch input
+	touch: boolean;
+
+	// Loop the presentation
+	loop: boolean;
+
+	// Change the presentation direction to be RTL
+	rtl: boolean;
+
+	// Changes the behavior of our navigation directions.
+	//
+	// "default"
+	// Left/right arrow keys step between horizontal slides, up/down
+	// arrow keys step between vertical slides. Space key steps through
+	// all slides (both horizontal and vertical).
+	//
+	// "linear"
+	// Removes the up/down arrows. Left/right arrows step through all
+	// slides (both horizontal and vertical).
+	//
+	// "grid"
+	// When this is enabled, stepping left/right from a vertical stack
+	// to an adjacent vertical stack will land you at the same vertical
+	// index.
+	//
+	// Consider a deck with six slides ordered in two vertical stacks:
+	// 1.1    2.1
+	// 1.2    2.2
+	// 1.3    2.3
+	//
+	// If you're on slide 1.3 and navigate right, you will normally move
+	// from 1.3 -> 2.1. If "grid" is used, the same navigation takes you
+	// from 1.3 -> 2.3.
+	navigationMode: 'default' | 'linear' | 'grid';
+
+	// Randomizes the order of slides each time the presentation loads
+	shuffle: boolean;
+
+	// Turns fragments on and off globally
+	fragments: boolean;
+
+	// Flags whether to include the current fragment in the URL,
+	// so that reloading brings you to the same fragment position
+	fragmentInURL: boolean;
+
+	// Flags if the presentation is running in an embedded mode,
+	// i.e. contained within a limited portion of the screen
+	embedded: boolean;
+
+	// Flags if we should show a help overlay when the question-mark
+	// key is pressed
+	help: boolean;
+
+	// Flags if it should be possible to pause the presentation (blackout)
+	pause: boolean;
+
+	// Flags if speaker notes should be visible to all viewers
+	showNotes: boolean;
+
+	// Flags if slides with data-visibility="hidden" should be kep visible
+	showHiddenSlides: boolean;
+
+	// Global override for autoplaying embedded media (video/audio/iframe)
+	// - null:   Media will only autoplay if data-autoplay is present
+	// - true:   All media will autoplay, regardless of individual setting
+	// - false:  No media will autoplay, regardless of individual setting
+	autoPlayMedia: null | boolean;
+
+	// Global override for preloading lazy-loaded iframes
+	// - null:   Iframes with data-src AND data-preload will be loaded when within
+	//           the viewDistance, iframes with only data-src will be loaded when visible
+	// - true:   All iframes with data-src will be loaded when within the viewDistance
+	// - false:  All iframes with data-src will be loaded only when visible
+	preloadIframes: null | boolean;
+
+	// Can be used to globally disable auto-animation
+	autoAnimate: boolean;
+
+	// Optionally provide a custom element matcher that will be
+	// used to dictate which elements we can animate between.
+	autoAnimateMatcher: null | Function;
+
+	// Default settings for our auto-animate transitions, can be
+	// overridden per-slide or per-element via data arguments
+	autoAnimateEasing: 'ease' | string;
+	autoAnimateDuration: number
+	autoAnimateUnmatched: boolean;
+
+	// CSS properties that can be auto-animated. Position & scale
+	// is matched separately so there's no need to include styles
+	// like top/right/bottom/left, width/height or margin.
+	autoAnimateStyles: string[];
+
+	// Controls automatic progression to the next slide
+	// - 0:      Auto-sliding only happens if the data-autoslide HTML attribute
+	//           is present on the current slide or fragment
+	// - 1+:     All slides will progress automatically at the given interval
+	// - false:  No auto-sliding, even if data-autoslide is present
+	autoSlide: number | false;
+
+	// Stop auto-sliding after user input
+	autoSlideStoppable: boolean;
+
+	// Use this method for navigation when auto-sliding (defaults to navigateNext)
+	autoSlideMethod: null | Function;
+
+	// Specify the average time in seconds that you think you will spend
+	// presenting each slide. This is used to show a pacing timer in the
+	// speaker view
+	defaultTiming: null,
+
+	// Enable slide navigation via mouse wheel
+	mouseWheel: boolean;
+
+	// Opens links in an iframe preview overlay
+	// Add `data-preview-link` and `data-preview-link="false"` to customise each link
+	// individually
+	previewLinks: boolean;
+
+	// Exposes the reveal.js API through window.postMessage
+	postMessage: boolean;
+
+	// Dispatches all reveal.js events to the parent window through postMessage
+	postMessageEvents: boolean;
+
+	// Focuses body when page changes visibility to ensure keyboard shortcuts work
+	focusBodyOnPageVisibilityChange: boolean;
+
+	// Transition style
+	transition: 'none' | 'fade' | 'slide' | 'convex' | 'concave' | 'zoom';
+
+	// Transition speed
+	transitionSpeed: 'default' | 'fast' | 'slow';
+
+	// Transition style for full page slide backgrounds
+	backgroundTransition: 'fade' | 'none' | 'slide' | 'convex' | 'concave' | 'zoom';
+
+	// Parallax background image
+	parallaxBackgroundImage: null | string; // CSS syntax, e.g. "a.jpg"
+
+	// Parallax background size
+	parallaxBackgroundSize: null | string; // CSS syntax, e.g. "3000px 2000px"
+
+	// Parallax background repeat
+	parallaxBackgroundRepeat: null | string; // repeat/repeat-x/repeat-y/no-repeat/initial/inherit
+
+	// Parallax background position
+	parallaxBackgroundPosition: null | string; // CSS syntax, e.g. "top left"
+
+	// Amount of pixels to move the parallax background per slide step
+	parallaxBackgroundHorizontal: null | number;
+	parallaxBackgroundVertical: null | number;
+
+	// Can be used to initialize reveal.js in one of the following views:
+	// - print:   Render the presentation so that it can be printed to PDF
+	// - scroll:  Show the presentation as a tall scrollable page with scroll
+	//            triggered animations
+	view: null | 'print' | 'scroll';
+
+	// Adjusts the height of each slide in the scroll view.
+	// - full:       Each slide is as tall as the viewport
+	// - compact:    Slides are as small as possible, allowing multiple slides
+	//               to be visible in parallel on tall devices
+	scrollLayout: 'full' | 'compact';
+
+	// Control how scroll snapping works in the scroll view.
+	// - false:   	No snapping, scrolling is continuous
+	// - proximity:  Snap when close to a slide
+	// - mandatory:  Always snap to the closest slide
+	//
+	// Only applies to presentations in scroll view.
+	scrollSnap: false | 'proximity' | 'mandatory';
+
+	// Enables and configure the scroll view progress bar.
+	// - 'auto':    Show the scrollbar while scrolling, hide while idle
+	// - true:      Always show the scrollbar
+	// - false:     Never show the scrollbar
+	scrollProgress: 'auto' | boolean;
+
+	// Automatically activate the scroll view when we the viewport falls
+	// below the given width.
+	scrollActivationWidth: number;
+
+	// The maximum number of pages a single slide can expand onto when printing
+	// to PDF, unlimited by default
+	pdfMaxPagesPerSlide: number,
+
+	// Prints each fragment on a separate slide
+	pdfSeparateFragments: boolean;
+
+	// Offset used to reduce the height of content within exported PDF pages.
+	// This exists to account for environment differences based on how you
+	// print to PDF. CLI printing options, like phantomjs and wkpdf, can end
+	// on precisely the total height of the document whereas in-browser
+	// printing has to end one pixel before.
+	pdfPageHeightOffset: number
+
+	// Number of slides away from the current that are visible
+	viewDistance: number;
+
+	// Number of slides away from the current that are visible on mobile
+	// devices. It is advisable to set this to a lower number than
+	// viewDistance in order to save resources.
+	mobileViewDistance: number;
+
+	// The display mode that will be used to show slides
+	display: string;
+
+	// Hide cursor if inactive
+	hideInactiveCursor: boolean;
+
+	// Time before the cursor is hidden (in ms)
+	hideCursorTime: number;
+
+	// Should we automatically sort and set indices for fragments
+	// at each sync? (See Reveal.sync)
+	sortFragmentsOnSync: boolean;
+
+	// Script dependencies to load
+	dependencies: any[],
+
+	// Plugin objects to register and use for this presentation
+	plugins: any[]
+}
+
+export type PartialRevealConfig = Partial<RevealConfig>;
+
+/**
+ * The default reveal.js config object.
+ */
+const config : RevealConfig = {
+
+	// The "normal" size of the presentation, aspect ratio will be preserved
+	// when the presentation is scaled to fit different resolutions
+	width: 960,
+	height: 700,
+
+	// Factor of the display size that should remain empty around the content
+	margin: 0.04,
+
+	// Bounds for smallest/largest possible scale to apply to content
+	minScale: 0.2,
+	maxScale: 2.0,
+
+	// Display presentation control arrows
+	controls: true,
+
+	// Help the user learn the controls by providing hints, for example by
+	// bouncing the down arrow when they first encounter a vertical slide
+	controlsTutorial: true,
+
+	// Determines where controls appear, "edges" or "bottom-right"
+	controlsLayout: 'bottom-right',
+
+	// Visibility rule for backwards navigation arrows; "faded", "hidden"
+	// or "visible"
+	controlsBackArrows: 'faded',
+
+	// Display a presentation progress bar
+	progress: true,
+
+	// Display the page number of the current slide
+	// - true:    Show slide number
+	// - false:   Hide slide number
+	//
+	// Can optionally be set as a string that specifies the number formatting:
+	// - "h.v":	  Horizontal . vertical slide number (default)
+	// - "h/v":	  Horizontal / vertical slide number
+	// - "c":	  Flattened slide number
+	// - "c/t":	  Flattened slide number / total slides
+	//
+	// Alternatively, you can provide a function that returns the slide
+	// number for the current slide. The function should take in a slide
+	// object and return an array with one string [slideNumber] or
+	// three strings [n1,delimiter,n2]. See #formatSlideNumber().
+	slideNumber: false,
+
+	// Can be used to limit the contexts in which the slide number appears
+	// - "all":      Always show the slide number
+	// - "print":    Only when printing to PDF
+	// - "speaker":  Only in the speaker view
+	showSlideNumber: 'all',
+
+	// Use 1 based indexing for # links to match slide number (default is zero
+	// based)
+	hashOneBasedIndex: false,
+
+	// Add the current slide number to the URL hash so that reloading the
+	// page/copying the URL will return you to the same slide
+	hash: false,
+
+	// Flags if we should monitor the hash and change slides accordingly
+	respondToHashChanges: true,
+
+	// Enable support for jump-to-slide navigation shortcuts
+	jumpToSlide: true,
+
+	// Push each slide change to the browser history.  Implies `hash: true`
+	history: false,
+
+	// Enable keyboard shortcuts for navigation
+	keyboard: true,
+
+	// Optional function that blocks keyboard events when retuning false
+	//
+	// If you set this to 'focused', we will only capture keyboard events
+	// for embedded decks when they are in focus
+	keyboardCondition: null,
+
+	// Disables the default reveal.js slide layout (scaling and centering)
+	// so that you can use custom CSS layout
+	disableLayout: false,
+
+	// Enable the slide overview mode
+	overview: true,
+
+	// Vertical centering of slides
+	center: true,
+
+	// Enables touch navigation on devices with touch input
+	touch: true,
+
+	// Loop the presentation
+	loop: false,
+
+	// Change the presentation direction to be RTL
+	rtl: false,
+
+	// Changes the behavior of our navigation directions.
+	//
+	// "default"
+	// Left/right arrow keys step between horizontal slides, up/down
+	// arrow keys step between vertical slides. Space key steps through
+	// all slides (both horizontal and vertical).
+	//
+	// "linear"
+	// Removes the up/down arrows. Left/right arrows step through all
+	// slides (both horizontal and vertical).
+	//
+	// "grid"
+	// When this is enabled, stepping left/right from a vertical stack
+	// to an adjacent vertical stack will land you at the same vertical
+	// index.
+	//
+	// Consider a deck with six slides ordered in two vertical stacks:
+	// 1.1    2.1
+	// 1.2    2.2
+	// 1.3    2.3
+	//
+	// If you're on slide 1.3 and navigate right, you will normally move
+	// from 1.3 -> 2.1. If "grid" is used, the same navigation takes you
+	// from 1.3 -> 2.3.
+	navigationMode: 'default',
+
+	// Randomizes the order of slides each time the presentation loads
+	shuffle: false,
+
+	// Turns fragments on and off globally
+	fragments: true,
+
+	// Flags whether to include the current fragment in the URL,
+	// so that reloading brings you to the same fragment position
+	fragmentInURL: true,
+
+	// Flags if the presentation is running in an embedded mode,
+	// i.e. contained within a limited portion of the screen
+	embedded: false,
+
+	// Flags if we should show a help overlay when the question-mark
+	// key is pressed
+	help: true,
+
+	// Flags if it should be possible to pause the presentation (blackout)
+	pause: true,
+
+	// Flags if speaker notes should be visible to all viewers
+	showNotes: false,
+
+	// Flags if slides with data-visibility="hidden" should be kep visible
+	showHiddenSlides: false,
+
+	// Global override for autoplaying embedded media (video/audio/iframe)
+	// - null:   Media will only autoplay if data-autoplay is present
+	// - true:   All media will autoplay, regardless of individual setting
+	// - false:  No media will autoplay, regardless of individual setting
+	autoPlayMedia: null,
+
+	// Global override for preloading lazy-loaded iframes
+	// - null:   Iframes with data-src AND data-preload will be loaded when within
+	//           the viewDistance, iframes with only data-src will be loaded when visible
+	// - true:   All iframes with data-src will be loaded when within the viewDistance
+	// - false:  All iframes with data-src will be loaded only when visible
+	preloadIframes: null,
+
+	// Can be used to globally disable auto-animation
+	autoAnimate: true,
+
+	// Optionally provide a custom element matcher that will be
+	// used to dictate which elements we can animate between.
+	autoAnimateMatcher: null,
+
+	// Default settings for our auto-animate transitions, can be
+	// overridden per-slide or per-element via data arguments
+	autoAnimateEasing: 'ease',
+	autoAnimateDuration: 1.0,
+	autoAnimateUnmatched: true,
+
+	// CSS properties that can be auto-animated. Position & scale
+	// is matched separately so there's no need to include styles
+	// like top/right/bottom/left, width/height or margin.
+	autoAnimateStyles: [
+		'opacity',
+		'color',
+		'background-color',
+		'padding',
+		'font-size',
+		'line-height',
+		'letter-spacing',
+		'border-width',
+		'border-color',
+		'border-radius',
+		'outline',
+		'outline-offset'
+	],
+
+	// Controls automatic progression to the next slide
+	// - 0:      Auto-sliding only happens if the data-autoslide HTML attribute
+	//           is present on the current slide or fragment
+	// - 1+:     All slides will progress automatically at the given interval
+	// - false:  No auto-sliding, even if data-autoslide is present
+	autoSlide: 0,
+
+	// Stop auto-sliding after user input
+	autoSlideStoppable: true,
+
+	// Use this method for navigation when auto-sliding (defaults to navigateNext)
+	autoSlideMethod: null,
+
+	// Specify the average time in seconds that you think you will spend
+	// presenting each slide. This is used to show a pacing timer in the
+	// speaker view
+	defaultTiming: null,
+
+	// Enable slide navigation via mouse wheel
+	mouseWheel: false,
+
+	// Opens links in an iframe preview overlay
+	// Add `data-preview-link` and `data-preview-link="false"` to customise each link
+	// individually
+	previewLinks: false,
+
+	// Exposes the reveal.js API through window.postMessage
+	postMessage: true,
+
+	// Dispatches all reveal.js events to the parent window through postMessage
+	postMessageEvents: false,
+
+	// Focuses body when page changes visibility to ensure keyboard shortcuts work
+	focusBodyOnPageVisibilityChange: true,
+
+	// Transition style
+	transition: 'slide', // none/fade/slide/convex/concave/zoom
+
+	// Transition speed
+	transitionSpeed: 'default', // default/fast/slow
+
+	// Transition style for full page slide backgrounds
+	backgroundTransition: 'fade', // none/fade/slide/convex/concave/zoom
+
+	// Parallax background image
+	parallaxBackgroundImage: '', // CSS syntax, e.g. "a.jpg"
+
+	// Parallax background size
+	parallaxBackgroundSize: '', // CSS syntax, e.g. "3000px 2000px"
+
+	// Parallax background repeat
+	parallaxBackgroundRepeat: '', // repeat/repeat-x/repeat-y/no-repeat/initial/inherit
+
+	// Parallax background position
+	parallaxBackgroundPosition: '', // CSS syntax, e.g. "top left"
+
+	// Amount of pixels to move the parallax background per slide step
+	parallaxBackgroundHorizontal: null,
+	parallaxBackgroundVertical: null,
+
+	// Can be used to initialize reveal.js in one of the following views:
+	// - print:   Render the presentation so that it can be printed to PDF
+	// - scroll:  Show the presentation as a tall scrollable page with scroll
+	//            triggered animations
+	view: null,
+
+	// Adjusts the height of each slide in the scroll view.
+	// - full:       Each slide is as tall as the viewport
+	// - compact:    Slides are as small as possible, allowing multiple slides
+	//               to be visible in parallel on tall devices
+	scrollLayout: 'full',
+
+	// Control how scroll snapping works in the scroll view.
+	// - false:   	No snapping, scrolling is continuous
+	// - proximity:  Snap when close to a slide
+	// - mandatory:  Always snap to the closest slide
+	//
+	// Only applies to presentations in scroll view.
+	scrollSnap: 'mandatory',
+
+	// Enables and configure the scroll view progress bar.
+	// - 'auto':    Show the scrollbar while scrolling, hide while idle
+	// - true:      Always show the scrollbar
+	// - false:     Never show the scrollbar
+	scrollProgress: 'auto',
+
+	// Automatically activate the scroll view when we the viewport falls
+	// below the given width.
+	scrollActivationWidth: 435,
+
+	// The maximum number of pages a single slide can expand onto when printing
+	// to PDF, unlimited by default
+	pdfMaxPagesPerSlide: Number.POSITIVE_INFINITY,
+
+	// Prints each fragment on a separate slide
+	pdfSeparateFragments: true,
+
+	// Offset used to reduce the height of content within exported PDF pages.
+	// This exists to account for environment differences based on how you
+	// print to PDF. CLI printing options, like phantomjs and wkpdf, can end
+	// on precisely the total height of the document whereas in-browser
+	// printing has to end one pixel before.
+	pdfPageHeightOffset: -1,
+
+	// Number of slides away from the current that are visible
+	viewDistance: 3,
+
+	// Number of slides away from the current that are visible on mobile
+	// devices. It is advisable to set this to a lower number than
+	// viewDistance in order to save resources.
+	mobileViewDistance: 2,
+
+	// The display mode that will be used to show slides
+	display: 'block',
+
+	// Hide cursor if inactive
+	hideInactiveCursor: true,
+
+	// Time before the cursor is hidden (in ms)
+	hideCursorTime: 5000,
+
+	// Should we automatically sort and set indices for fragments
+	// at each sync? (See Reveal.sync)
+	sortFragmentsOnSync: true,
+
+	// Script dependencies to load
+	dependencies: [],
+
+	// Plugin objects to register and use for this presentation
+	plugins: []
+
+}
+
+export default config;

+ 8 - 3
js/index.js → js/index.ts

@@ -1,3 +1,6 @@
+import { PartialRevealConfig } from './config.js';
+
+//@ts-ignore
 import Deck, { VERSION } from './reveal.js'
 
 /**
@@ -25,9 +28,11 @@ let Reveal = Deck;
  * });
  */
 
-let enqueuedAPICalls = [];
+type RevealApiFunction = (...args: any[]) => any;
+
+let enqueuedAPICalls: RevealApiFunction[] = [];
 
-Reveal.initialize = options => {
+Reveal.initialize = ( options: PartialRevealConfig ) => {
 
 	// Create our singleton reveal.js instance
 	Object.assign( Reveal, new Deck( document.querySelector( '.reveal' ), options ) );
@@ -46,7 +51,7 @@ Reveal.initialize = options => {
  * of them when Reveal.initialize is called.
  */
 [ 'configure', 'on', 'off', 'addEventListener', 'removeEventListener', 'registerPlugin' ].forEach( method => {
-	Reveal[method] = ( ...args ) => {
+	Reveal[method] = ( ...args: any ) => {
 		enqueuedAPICalls.push( deck => deck[method].call( null, ...args ) );
 	}
 } );

+ 1 - 1
js/reveal.js

@@ -18,7 +18,7 @@ import Touch from './controllers/touch.js'
 import Focus from './controllers/focus.js'
 import Notes from './controllers/notes.js'
 import Playback from './components/playback.js'
-import defaultConfig from './config.js'
+import defaultConfig from './config.ts'
 import * as Util from './utils/util.js'
 import * as Device from './utils/device.js'
 import {

Filskillnaden har hållts tillbaka eftersom den är för stor
+ 804 - 115
package-lock.json


+ 44 - 5
package.json

@@ -4,13 +4,49 @@
   "description": "The HTML Presentation Framework",
   "homepage": "https://revealjs.com",
   "subdomain": "revealjs",
-  "main": "dist/reveal.js",
-  "module": "dist/reveal.esm.js",
   "license": "MIT",
+  "main": "dist/reveal.js",
+  "module": "dist/reveal.mjs",
+  "exports": {
+    ".": {
+      "import": "./dist/reveal.mjs",
+      "require": "./dist/reveal.js"
+    },
+
+    "./reveal.css": "./dist/reveal.css",
+    "./reset.css": "./dist/reset.css",
+
+    "./plugin/highlight": {
+      "import": "./dist/plugin/highlight.mjs",
+      "require": "./dist/plugin/highlight.js"
+    },
+    "./plugin/markdown": {
+      "import": "./dist/plugin/markdown.mjs",
+      "require": "./dist/plugin/markdown.js"
+    },
+    "./plugin/math": {
+      "import": "./dist/plugin/math.mjs",
+      "require": "./dist/plugin/math.js"
+    },
+    "./plugin/notes": {
+      "import": "./dist/plugin/notes.mjs",
+      "require": "./dist/plugin/notes.js"
+    },
+    "./plugin/search": {
+      "import": "./dist/plugin/search.mjs",
+      "require": "./dist/plugin/search.js"
+    },
+    "./plugin/zoom": {
+      "import": "./dist/plugin/zoom.mjs",
+      "require": "./dist/plugin/zoom.js"
+    }
+  },
   "scripts": {
+    "dev": "vite",
+    "build:core": "tsc && vite build && vite build -c vite.config.styles.ts",
+    "build": "tsc && vite build && vite build -c vite.config.styles.ts && vite build -c plugin/highlight/vite.config.ts && vite build -c plugin/markdown/vite.config.ts && vite build -c plugin/math/vite.config.ts && vite build -c plugin/notes/vite.config.ts && vite build -c plugin/search/vite.config.ts && vite build -c plugin/zoom/vite.config.ts",
     "test": "gulp test",
-    "start": "gulp serve",
-    "build": "gulp build"
+    "start": "vite"
   },
   "author": {
     "name": "Hakim El Hattab",
@@ -55,7 +91,10 @@
     "through2": "^4.0.2",
     "qunit": "^2.22.0",
     "rollup": "^4.1.5",
-    "sass": "^1.79.4",
+    "sass": "^1.69.5",
+    "typescript": "^5.2.2",
+    "vite": "^5.2.0",
+    "vite-plugin-dts": "^3.8.0",
     "yargs": "^17.7.2"
   },
   "overrides": {

+ 0 - 0
plugin/highlight/plugin.js → plugin/highlight/index.js


+ 22 - 0
plugin/highlight/vite.config.ts

@@ -0,0 +1,22 @@
+import { resolve } from 'path';
+import { defineConfig } from 'vite'
+import { appendExtension } from '../../vite.config.ts';
+
+// Once Vite supports multiple entries for plugins, this build can
+// be merged into the main vite.config.ts.
+// See https://github.com/vitejs/vite/pull/10609
+
+export default defineConfig({
+  build: {
+    emptyOutDir: false,
+    lib: {
+      formats: ['es', 'umd'],
+      entry: {
+        'plugin/highlight': resolve(__dirname, 'index.js'),
+      },
+      name: 'RevealHighlight',
+      fileName: appendExtension
+    }
+  },
+  plugins: [],
+})

+ 0 - 0
plugin/markdown/plugin.js → plugin/markdown/index.js


Filskillnaden har hållts tillbaka eftersom den är för stor
+ 0 - 0
plugin/markdown/markdown.esm.js


Filskillnaden har hållts tillbaka eftersom den är för stor
+ 0 - 0
plugin/markdown/markdown.js


+ 22 - 0
plugin/markdown/vite.config.ts

@@ -0,0 +1,22 @@
+import { resolve } from 'path';
+import { defineConfig } from 'vite'
+import { appendExtension } from '../../vite.config.ts';
+
+// Once Vite supports multiple entries for plugins, this build can
+// be merged into the main vite.config.ts.
+// See https://github.com/vitejs/vite/pull/10609
+
+export default defineConfig({
+  build: {
+    emptyOutDir: false,
+    lib: {
+      formats: ['es', 'umd'],
+      entry: {
+        'plugin/markdown': resolve(__dirname, 'index.js'),
+      },
+      name: 'RevealMarkdown',
+      fileName: appendExtension
+    }
+  },
+  plugins: [],
+})

+ 0 - 0
plugin/math/plugin.js → plugin/math/index.js


+ 22 - 0
plugin/math/vite.config.ts

@@ -0,0 +1,22 @@
+import { resolve } from 'path';
+import { defineConfig } from 'vite'
+import { appendExtension } from '../../vite.config.ts';
+
+// Once Vite supports multiple entries for plugins, this build can
+// be merged into the main vite.config.ts.
+// See https://github.com/vitejs/vite/pull/10609
+
+export default defineConfig({
+  build: {
+    emptyOutDir: false,
+    lib: {
+      formats: ['es', 'umd'],
+      entry: {
+        'plugin/math': resolve(__dirname, 'index.js'),
+      },
+      name: 'RevealMath',
+      fileName: appendExtension
+    }
+  },
+  plugins: [],
+})

+ 1 - 1
plugin/notes/plugin.js → plugin/notes/index.js

@@ -1,4 +1,4 @@
-import speakerViewHTML from './speaker-view.html'
+import speakerViewHTML from './speaker-view.html?raw'
 
 import { marked } from 'marked';
 

Filskillnaden har hållts tillbaka eftersom den är för stor
+ 0 - 0
plugin/notes/notes.esm.js


Filskillnaden har hållts tillbaka eftersom den är för stor
+ 0 - 0
plugin/notes/notes.js


+ 22 - 0
plugin/notes/vite.config.ts

@@ -0,0 +1,22 @@
+import { resolve } from 'path';
+import { defineConfig } from 'vite'
+import { appendExtension } from '../../vite.config.ts';
+
+// Once Vite supports multiple entries for plugins, this build can
+// be merged into the main vite.config.ts.
+// See https://github.com/vitejs/vite/pull/10609
+
+export default defineConfig({
+  build: {
+    emptyOutDir: false,
+    lib: {
+      formats: ['es', 'umd'],
+      entry: {
+        'plugin/notes': resolve(__dirname, 'index.js'),
+      },
+      name: 'RevealNotes',
+      fileName: appendExtension
+    }
+  },
+  plugins: [],
+})

+ 0 - 0
plugin/search/plugin.js → plugin/search/index.js


+ 22 - 0
plugin/search/vite.config.ts

@@ -0,0 +1,22 @@
+import { resolve } from 'path';
+import { defineConfig } from 'vite'
+import { appendExtension } from '../../vite.config.ts';
+
+// Once Vite supports multiple entries for plugins, this build can
+// be merged into the main vite.config.ts.
+// See https://github.com/vitejs/vite/pull/10609
+
+export default defineConfig({
+  build: {
+    emptyOutDir: false,
+    lib: {
+      formats: ['es', 'umd'],
+      entry: {
+        'plugin/search': resolve(__dirname, 'index.js'),
+      },
+      name: 'RevealSearch',
+      fileName: appendExtension
+    }
+  },
+  plugins: [],
+})

+ 0 - 0
plugin/zoom/plugin.js → plugin/zoom/index.js


+ 22 - 0
plugin/zoom/vite.config.ts

@@ -0,0 +1,22 @@
+import { resolve } from 'path';
+import { defineConfig } from 'vite'
+import { appendExtension } from '../../vite.config.ts';
+
+// Once Vite supports multiple entries for plugins, this build can
+// be merged into the main vite.config.ts.
+// See https://github.com/vitejs/vite/pull/10609
+
+export default defineConfig({
+  build: {
+    emptyOutDir: false,
+    lib: {
+      formats: ['es', 'umd'],
+      entry: {
+        'plugin/zoom': resolve(__dirname, 'index.js'),
+      },
+      name: 'RevealZoom',
+      fileName: appendExtension
+    }
+  },
+  plugins: [],
+})

Filskillnaden har hållts tillbaka eftersom den är för stor
+ 0 - 3
plugin/zoom/zoom.esm.js


Filskillnaden har hållts tillbaka eftersom den är för stor
+ 0 - 3
plugin/zoom/zoom.js


+ 71 - 0
public/plugin/highlight/monokai.css

@@ -0,0 +1,71 @@
+/*
+Monokai style - ported by Luigi Maselli - http://grigio.org
+*/
+
+.hljs {
+  display: block;
+  overflow-x: auto;
+  padding: 0.5em;
+  background: #272822;
+  color: #ddd;
+}
+
+.hljs-tag,
+.hljs-keyword,
+.hljs-selector-tag,
+.hljs-literal,
+.hljs-strong,
+.hljs-name {
+  color: #f92672;
+}
+
+.hljs-code {
+  color: #66d9ef;
+}
+
+.hljs-class .hljs-title {
+  color: white;
+}
+
+.hljs-attribute,
+.hljs-symbol,
+.hljs-regexp,
+.hljs-link {
+  color: #bf79db;
+}
+
+.hljs-string,
+.hljs-bullet,
+.hljs-subst,
+.hljs-title,
+.hljs-section,
+.hljs-emphasis,
+.hljs-type,
+.hljs-built_in,
+.hljs-builtin-name,
+.hljs-selector-attr,
+.hljs-selector-pseudo,
+.hljs-addition,
+.hljs-variable,
+.hljs-template-tag,
+.hljs-template-variable {
+  color: #a6e22e;
+}
+
+.hljs-comment,
+.hljs-quote,
+.hljs-deletion,
+.hljs-meta {
+  color: #75715e;
+}
+
+.hljs-keyword,
+.hljs-selector-tag,
+.hljs-literal,
+.hljs-doctag,
+.hljs-title,
+.hljs-section,
+.hljs-type,
+.hljs-selector-id {
+  font-weight: bold;
+}

+ 80 - 0
public/plugin/highlight/zenburn.css

@@ -0,0 +1,80 @@
+/*
+
+Zenburn style from voldmar.ru (c) Vladimir Epifanov <voldmar@voldmar.ru>
+based on dark.css by Ivan Sagalaev
+
+*/
+
+.hljs {
+  display: block;
+  overflow-x: auto;
+  padding: 0.5em;
+  background: #3f3f3f;
+  color: #dcdcdc;
+}
+
+.hljs-keyword,
+.hljs-selector-tag,
+.hljs-tag {
+  color: #e3ceab;
+}
+
+.hljs-template-tag {
+  color: #dcdcdc;
+}
+
+.hljs-number {
+  color: #8cd0d3;
+}
+
+.hljs-variable,
+.hljs-template-variable,
+.hljs-attribute {
+  color: #efdcbc;
+}
+
+.hljs-literal {
+  color: #efefaf;
+}
+
+.hljs-subst {
+  color: #8f8f8f;
+}
+
+.hljs-title,
+.hljs-name,
+.hljs-selector-id,
+.hljs-selector-class,
+.hljs-section,
+.hljs-type {
+  color: #efef8f;
+}
+
+.hljs-symbol,
+.hljs-bullet,
+.hljs-link {
+  color: #dca3a3;
+}
+
+.hljs-deletion,
+.hljs-string,
+.hljs-built_in,
+.hljs-builtin-name {
+  color: #cc9393;
+}
+
+.hljs-addition,
+.hljs-comment,
+.hljs-quote,
+.hljs-meta {
+  color: #7f9f7f;
+}
+
+
+.hljs-emphasis {
+  font-style: italic;
+}
+
+.hljs-strong {
+  font-weight: bold;
+}

+ 2 - 0
public/theme/fonts/league-gothic/LICENSE

@@ -0,0 +1,2 @@
+SIL Open Font License (OFL)
+http://scripts.sil.org/cms/scripts/page.php?site_id=nrsi&id=OFL

+ 10 - 0
public/theme/fonts/league-gothic/league-gothic.css

@@ -0,0 +1,10 @@
+@font-face {
+    font-family: 'League Gothic';
+    src: url('./league-gothic.eot');
+    src: url('./league-gothic.eot?#iefix') format('embedded-opentype'),
+         url('./league-gothic.woff') format('woff'),
+         url('./league-gothic.ttf') format('truetype');
+
+    font-weight: normal;
+    font-style: normal;
+}

BIN
public/theme/fonts/league-gothic/league-gothic.eot


BIN
public/theme/fonts/league-gothic/league-gothic.ttf


BIN
public/theme/fonts/league-gothic/league-gothic.woff


+ 45 - 0
public/theme/fonts/source-sans-pro/LICENSE

@@ -0,0 +1,45 @@
+SIL Open Font License
+
+Copyright 2010, 2012 Adobe Systems Incorporated (http://www.adobe.com/), with Reserved Font Name ‘Source’. All Rights Reserved. Source is a trademark of Adobe Systems Incorporated in the United States and/or other countries.
+
+This Font Software is licensed under the SIL Open Font License, Version 1.1.
+This license is copied below, and is also available with a FAQ at: http://scripts.sil.org/OFL
+
+—————————————————————————————-
+SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
+—————————————————————————————-
+
+PREAMBLE
+The goals of the Open Font License (OFL) are to stimulate worldwide development of collaborative font projects, to support the font creation efforts of academic and linguistic communities, and to provide a free and open framework in which fonts may be shared and improved in partnership with others.
+
+The OFL allows the licensed fonts to be used, studied, modified and redistributed freely as long as they are not sold by themselves. The fonts, including any derivative works, can be bundled, embedded, redistributed and/or sold with any software provided that any reserved names are not used by derivative works. The fonts and derivatives, however, cannot be released under any other type of license. The requirement for fonts to remain under this license does not apply to any document created using the fonts or their derivatives.
+
+DEFINITIONS
+“Font Software” refers to the set of files released by the Copyright Holder(s) under this license and clearly marked as such. This may include source files, build scripts and documentation.
+
+“Reserved Font Name” refers to any names specified as such after the copyright statement(s).
+
+“Original Version” refers to the collection of Font Software components as distributed by the Copyright Holder(s).
+
+“Modified Version” refers to any derivative made by adding to, deleting, or substituting—in part or in whole—any of the components of the Original Version, by changing formats or by porting the Font Software to a new environment.
+
+“Author” refers to any designer, engineer, programmer, technical writer or other person who contributed to the Font Software.
+
+PERMISSION & CONDITIONS
+Permission is hereby granted, free of charge, to any person obtaining a copy of the Font Software, to use, study, copy, merge, embed, modify, redistribute, and sell modified and unmodified copies of the Font Software, subject to the following conditions:
+
+1) Neither the Font Software nor any of its individual components, in Original or Modified Versions, may be sold by itself.
+
+2) Original or Modified Versions of the Font Software may be bundled, redistributed and/or sold with any software, provided that each copy contains the above copyright notice and this license. These can be included either as stand-alone text files, human-readable headers or in the appropriate machine-readable metadata fields within text or binary files as long as those fields can be easily viewed by the user.
+
+3) No Modified Version of the Font Software may use the Reserved Font Name(s) unless explicit written permission is granted by the corresponding Copyright Holder. This restriction only applies to the primary font name as presented to the users.
+
+4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font Software shall not be used to promote, endorse or advertise any Modified Version, except to acknowledge the contribution(s) of the Copyright Holder(s) and the Author(s) or with their explicit written permission.
+
+5) The Font Software, modified or unmodified, in part or in whole, must be distributed entirely under this license, and must not be distributed under any other license. The requirement for fonts to remain under this license does not apply to any document created using the Font Software.
+
+TERMINATION
+This license becomes null and void if any of the above conditions are not met.
+
+DISCLAIMER
+THE FONT SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE.

BIN
public/theme/fonts/source-sans-pro/source-sans-pro-italic.eot


BIN
public/theme/fonts/source-sans-pro/source-sans-pro-italic.ttf


BIN
public/theme/fonts/source-sans-pro/source-sans-pro-italic.woff


BIN
public/theme/fonts/source-sans-pro/source-sans-pro-regular.eot


BIN
public/theme/fonts/source-sans-pro/source-sans-pro-regular.ttf


BIN
public/theme/fonts/source-sans-pro/source-sans-pro-regular.woff


BIN
public/theme/fonts/source-sans-pro/source-sans-pro-semibold.eot


BIN
public/theme/fonts/source-sans-pro/source-sans-pro-semibold.ttf


BIN
public/theme/fonts/source-sans-pro/source-sans-pro-semibold.woff


BIN
public/theme/fonts/source-sans-pro/source-sans-pro-semibolditalic.eot


BIN
public/theme/fonts/source-sans-pro/source-sans-pro-semibolditalic.ttf


BIN
public/theme/fonts/source-sans-pro/source-sans-pro-semibolditalic.woff


+ 39 - 0
public/theme/fonts/source-sans-pro/source-sans-pro.css

@@ -0,0 +1,39 @@
+@font-face {
+    font-family: 'Source Sans Pro';
+    src: url('./source-sans-pro-regular.eot');
+    src: url('./source-sans-pro-regular.eot?#iefix') format('embedded-opentype'),
+         url('./source-sans-pro-regular.woff') format('woff'),
+         url('./source-sans-pro-regular.ttf') format('truetype');
+    font-weight: normal;
+    font-style: normal;
+}
+
+@font-face {
+    font-family: 'Source Sans Pro';
+    src: url('./source-sans-pro-italic.eot');
+    src: url('./source-sans-pro-italic.eot?#iefix') format('embedded-opentype'),
+         url('./source-sans-pro-italic.woff') format('woff'),
+         url('./source-sans-pro-italic.ttf') format('truetype');
+    font-weight: normal;
+    font-style: italic;
+}
+
+@font-face {
+    font-family: 'Source Sans Pro';
+    src: url('./source-sans-pro-semibold.eot');
+    src: url('./source-sans-pro-semibold.eot?#iefix') format('embedded-opentype'),
+         url('./source-sans-pro-semibold.woff') format('woff'),
+         url('./source-sans-pro-semibold.ttf') format('truetype');
+    font-weight: 600;
+    font-style: normal;
+}
+
+@font-face {
+    font-family: 'Source Sans Pro';
+    src: url('./source-sans-pro-semibolditalic.eot');
+    src: url('./source-sans-pro-semibolditalic.eot?#iefix') format('embedded-opentype'),
+         url('./source-sans-pro-semibolditalic.woff') format('woff'),
+         url('./source-sans-pro-semibolditalic.ttf') format('truetype');
+    font-weight: 600;
+    font-style: italic;
+}

+ 3 - 3
test/test-markdown.html

@@ -315,9 +315,9 @@
 		</div>
 
 		<script type="module">
-			import Reveal from '../dist/reveal.esm.js'
-			import Markdown from '../plugin/markdown/markdown.esm.js'
-			import Highlight from '../plugin/highlight/highlight.esm.js'
+			import Reveal from '../js';
+			import Markdown from '../plugin/markdown'
+			import Highlight from '../plugin/highlight'
 
 			QUnit.config.testTimeout = 30000;
 

+ 2 - 2
test/test-multiple-instances.html

@@ -38,8 +38,8 @@
 
 		<script type="module">
 
-			import Reveal from '../dist/reveal.esm.js';
-			import Zoom from '../plugin/zoom/zoom.esm.js';
+			import Reveal from '../js';
+			import Zoom from '../plugin/zoom';
 
 			QUnit.config.testTimeout = 30000;
 			QUnit.module( 'Multiple reveal.js instances' );

+ 25 - 0
tsconfig.json

@@ -0,0 +1,25 @@
+{
+  "compilerOptions": {
+    "target": "ES2020",
+    "useDefineForClassFields": true,
+    "lib": ["ES2020", "DOM", "DOM.Iterable"],
+    "module": "ESNext",
+    "skipLibCheck": true,
+
+    /* Bundler mode */
+    "moduleResolution": "bundler",
+    "allowImportingTsExtensions": true,
+    "resolveJsonModule": true,
+    "isolatedModules": true,
+    "noEmit": true,
+    "jsx": "react-jsx",
+
+    /* Linting */
+    "strict": true,
+    "noUnusedLocals": true,
+    "noUnusedParameters": true,
+    "noFallthroughCasesInSwitch": true
+  },
+  "include": ["js"],
+  "references": [{ "path": "./tsconfig.node.json" }]
+}

+ 11 - 0
tsconfig.node.json

@@ -0,0 +1,11 @@
+{
+  "compilerOptions": {
+    "composite": true,
+    "skipLibCheck": true,
+    "module": "ESNext",
+    "moduleResolution": "bundler",
+    "allowSyntheticDefaultImports": true,
+    "strict": true
+  },
+  "include": ["vite.config.ts"]
+}

+ 20 - 0
vite.config.styles.ts

@@ -0,0 +1,20 @@
+import { resolve } from 'path'
+import { defineConfig } from 'vite'
+
+export default defineConfig({
+  root: './',
+  build: {
+    emptyOutDir: false,
+    cssCodeSplit: true,
+    lib: {
+      formats: ['es'],
+      entry: {
+        'reveal': resolve(__dirname, 'css/reveal.scss'),
+        'reset': resolve(__dirname, 'css/reset.css'),
+
+        'theme/black': resolve(__dirname, 'css/theme/black.scss'),
+      },
+    }
+  },
+  plugins: [],
+})

+ 42 - 0
vite.config.ts

@@ -0,0 +1,42 @@
+import { resolve } from 'path'
+import { ModuleFormat } from 'rollup';
+import { defineConfig } from 'vite'
+import dts from 'vite-plugin-dts';
+
+export const appendExtension = (format:ModuleFormat, name:String) : string => {
+  if( format === 'es' ) {
+    return `${name}.mjs`;
+  }
+  else {
+    return `${name}.js`;
+  }
+}
+
+export default defineConfig({
+  build: {
+    emptyOutDir: true,
+    lib: {
+      formats: ['es', 'umd'],
+      entry:  resolve(__dirname, 'js/index.ts'),
+      name: 'Reveal',
+      fileName: (format, entryName) => {
+        return appendExtension(format, 'reveal');
+      }
+    },
+    rollupOptions: {
+      output: {
+        assetFileNames: "reveal.[ext]",
+      },
+    },
+  },
+  resolve: {
+    alias: {
+      // Matches the exported paths in package.json
+      'reveal.js/plugin': './plugin',
+      'reveal.js': '/js',
+    },
+  },
+  plugins: [
+    dts({ insertTypesEntry: true }),
+  ],
+})

Vissa filer visades inte eftersom för många filer har ändrats