katex 0.10.1 → 0.12.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +141 -0
- package/LICENSE +1 -1
- package/README.md +6 -6
- package/cli.js +0 -0
- package/contrib/auto-render/auto-render.js +12 -3
- package/contrib/copy-tex/README.md +3 -5
- package/contrib/mathtex-script-type/README.md +12 -14
- package/contrib/mhchem/README.md +3 -1
- package/contrib/render-a11y-string/render-a11y-string.js +712 -0
- package/contrib/render-a11y-string/test/render-a11y-string-spec.js +526 -0
- package/dist/README.md +6 -6
- package/dist/contrib/auto-render.js +14 -3
- package/dist/contrib/auto-render.min.js +1 -1
- package/dist/contrib/auto-render.mjs +14 -3
- package/dist/contrib/mhchem.min.js +1 -1
- package/dist/contrib/render-a11y-string.js +870 -0
- package/dist/contrib/render-a11y-string.min.js +1 -0
- package/dist/contrib/render-a11y-string.mjs +753 -0
- package/dist/fonts/KaTeX_AMS-Regular.ttf +0 -0
- package/dist/fonts/KaTeX_AMS-Regular.woff +0 -0
- package/dist/fonts/KaTeX_AMS-Regular.woff2 +0 -0
- package/dist/fonts/KaTeX_Caligraphic-Bold.ttf +0 -0
- package/dist/fonts/KaTeX_Caligraphic-Bold.woff +0 -0
- package/dist/fonts/KaTeX_Caligraphic-Bold.woff2 +0 -0
- package/dist/fonts/KaTeX_Caligraphic-Regular.ttf +0 -0
- package/dist/fonts/KaTeX_Caligraphic-Regular.woff +0 -0
- package/dist/fonts/KaTeX_Caligraphic-Regular.woff2 +0 -0
- package/dist/fonts/KaTeX_Fraktur-Bold.ttf +0 -0
- package/dist/fonts/KaTeX_Fraktur-Bold.woff +0 -0
- package/dist/fonts/KaTeX_Fraktur-Bold.woff2 +0 -0
- package/dist/fonts/KaTeX_Fraktur-Regular.ttf +0 -0
- package/dist/fonts/KaTeX_Fraktur-Regular.woff +0 -0
- package/dist/fonts/KaTeX_Fraktur-Regular.woff2 +0 -0
- package/dist/fonts/KaTeX_Main-Bold.ttf +0 -0
- package/dist/fonts/KaTeX_Main-Bold.woff +0 -0
- package/dist/fonts/KaTeX_Main-Bold.woff2 +0 -0
- package/dist/fonts/KaTeX_Main-BoldItalic.ttf +0 -0
- package/dist/fonts/KaTeX_Main-BoldItalic.woff +0 -0
- package/dist/fonts/KaTeX_Main-BoldItalic.woff2 +0 -0
- package/dist/fonts/KaTeX_Main-Italic.ttf +0 -0
- package/dist/fonts/KaTeX_Main-Italic.woff +0 -0
- package/dist/fonts/KaTeX_Main-Italic.woff2 +0 -0
- package/dist/fonts/KaTeX_Main-Regular.ttf +0 -0
- package/dist/fonts/KaTeX_Main-Regular.woff +0 -0
- package/dist/fonts/KaTeX_Main-Regular.woff2 +0 -0
- package/dist/fonts/KaTeX_Math-BoldItalic.ttf +0 -0
- package/dist/fonts/KaTeX_Math-BoldItalic.woff +0 -0
- package/dist/fonts/KaTeX_Math-BoldItalic.woff2 +0 -0
- package/dist/fonts/KaTeX_Math-Italic.ttf +0 -0
- package/dist/fonts/KaTeX_Math-Italic.woff +0 -0
- package/dist/fonts/KaTeX_Math-Italic.woff2 +0 -0
- package/dist/fonts/KaTeX_SansSerif-Bold.ttf +0 -0
- package/dist/fonts/KaTeX_SansSerif-Bold.woff +0 -0
- package/dist/fonts/KaTeX_SansSerif-Bold.woff2 +0 -0
- package/dist/fonts/KaTeX_SansSerif-Italic.ttf +0 -0
- package/dist/fonts/KaTeX_SansSerif-Italic.woff +0 -0
- package/dist/fonts/KaTeX_SansSerif-Italic.woff2 +0 -0
- package/dist/fonts/KaTeX_SansSerif-Regular.ttf +0 -0
- package/dist/fonts/KaTeX_SansSerif-Regular.woff +0 -0
- package/dist/fonts/KaTeX_SansSerif-Regular.woff2 +0 -0
- package/dist/fonts/KaTeX_Script-Regular.ttf +0 -0
- package/dist/fonts/KaTeX_Script-Regular.woff +0 -0
- package/dist/fonts/KaTeX_Script-Regular.woff2 +0 -0
- package/dist/fonts/KaTeX_Size1-Regular.ttf +0 -0
- package/dist/fonts/KaTeX_Size1-Regular.woff +0 -0
- package/dist/fonts/KaTeX_Size1-Regular.woff2 +0 -0
- package/dist/fonts/KaTeX_Size2-Regular.ttf +0 -0
- package/dist/fonts/KaTeX_Size2-Regular.woff +0 -0
- package/dist/fonts/KaTeX_Size2-Regular.woff2 +0 -0
- package/dist/fonts/KaTeX_Size3-Regular.ttf +0 -0
- package/dist/fonts/KaTeX_Size3-Regular.woff +0 -0
- package/dist/fonts/KaTeX_Size3-Regular.woff2 +0 -0
- package/dist/fonts/KaTeX_Size4-Regular.ttf +0 -0
- package/dist/fonts/KaTeX_Size4-Regular.woff +0 -0
- package/dist/fonts/KaTeX_Size4-Regular.woff2 +0 -0
- package/dist/fonts/KaTeX_Typewriter-Regular.ttf +0 -0
- package/dist/fonts/KaTeX_Typewriter-Regular.woff +0 -0
- package/dist/fonts/KaTeX_Typewriter-Regular.woff2 +0 -0
- package/dist/katex.css +34 -10
- package/dist/katex.js +2906 -2115
- package/dist/katex.min.css +1 -1
- package/dist/katex.min.js +1 -1
- package/dist/katex.mjs +2809 -2020
- package/package.json +12 -11
- package/src/Lexer.js +1 -0
- package/src/MacroExpander.js +39 -10
- package/src/Options.js +15 -75
- package/src/Parser.js +152 -115
- package/src/Settings.js +70 -7
- package/src/Token.js +2 -0
- package/src/buildCommon.js +24 -90
- package/src/buildHTML.js +31 -31
- package/src/buildMathML.js +52 -9
- package/src/buildTree.js +13 -6
- package/src/defineFunction.js +7 -22
- package/src/delimiter.js +66 -27
- package/src/domTree.js +71 -4
- package/src/environments/array.js +235 -25
- package/src/fontMetrics.js +11 -2
- package/src/functions/accent.js +9 -9
- package/src/functions/accentunder.js +2 -2
- package/src/functions/arrow.js +15 -5
- package/src/functions/color.js +9 -38
- package/src/functions/def.js +184 -0
- package/src/functions/delimsizing.js +32 -8
- package/src/functions/enclose.js +33 -6
- package/src/functions/font.js +4 -1
- package/src/functions/genfrac.js +39 -27
- package/src/functions/horizBrace.js +6 -7
- package/src/functions/href.js +16 -0
- package/src/functions/html.js +102 -0
- package/src/functions/includegraphics.js +153 -0
- package/src/functions/lap.js +4 -7
- package/src/functions/math.js +1 -5
- package/src/functions/mclass.js +41 -2
- package/src/functions/op.js +27 -111
- package/src/functions/operatorname.js +136 -92
- package/src/functions/ordgroup.js +1 -1
- package/src/functions/overline.js +3 -2
- package/src/functions/phantom.js +5 -2
- package/src/functions/raisebox.js +4 -16
- package/src/functions/rule.js +20 -9
- package/src/functions/styling.js +0 -9
- package/src/functions/supsub.js +27 -7
- package/src/functions/symbolsOp.js +4 -0
- package/src/functions/tag.js +20 -4
- package/src/functions/text.js +4 -3
- package/src/functions/underline.js +3 -2
- package/src/functions/utils/assembleSupSub.js +110 -0
- package/src/functions.js +3 -0
- package/src/katex.less +45 -9
- package/src/macros.js +259 -98
- package/src/mathMLTree.js +6 -4
- package/src/parseNode.js +37 -57
- package/src/stretchy.js +3 -1
- package/src/svgGeometry.js +136 -44
- package/src/symbols.js +52 -69
- package/src/tree.js +2 -2
- package/src/types.js +2 -1
- package/src/unicodeAccents.js +3 -1
- package/src/unicodeSymbols.js +30 -321
- package/src/utils.js +10 -0
- package/src/wide-character.js +2 -2
- package/src/unicodeMake.js +0 -70
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/dist/katex.css
CHANGED
|
@@ -124,10 +124,14 @@
|
|
|
124
124
|
line-height: 1.2;
|
|
125
125
|
text-indent: 0;
|
|
126
126
|
text-rendering: auto;
|
|
127
|
+
border-color: currentColor;
|
|
127
128
|
}
|
|
128
129
|
.katex * {
|
|
129
130
|
-ms-high-contrast-adjust: none !important;
|
|
130
131
|
}
|
|
132
|
+
.katex .katex-version::after {
|
|
133
|
+
content: "0.12.0";
|
|
134
|
+
}
|
|
131
135
|
.katex .katex-mathml {
|
|
132
136
|
position: absolute;
|
|
133
137
|
clip: rect(1px, 1px, 1px, 1px);
|
|
@@ -167,7 +171,7 @@
|
|
|
167
171
|
.katex .texttt {
|
|
168
172
|
font-family: KaTeX_Typewriter;
|
|
169
173
|
}
|
|
170
|
-
.katex .
|
|
174
|
+
.katex .mathnormal {
|
|
171
175
|
font-family: KaTeX_Math;
|
|
172
176
|
font-style: italic;
|
|
173
177
|
}
|
|
@@ -229,6 +233,7 @@
|
|
|
229
233
|
.katex .vlist-t {
|
|
230
234
|
display: inline-table;
|
|
231
235
|
table-layout: fixed;
|
|
236
|
+
border-collapse: collapse;
|
|
232
237
|
}
|
|
233
238
|
.katex .vlist-r {
|
|
234
239
|
display: table-row;
|
|
@@ -260,6 +265,26 @@
|
|
|
260
265
|
width: 2px;
|
|
261
266
|
min-width: 2px;
|
|
262
267
|
}
|
|
268
|
+
.katex .vbox {
|
|
269
|
+
display: -ms-inline-flexbox;
|
|
270
|
+
display: inline-flex;
|
|
271
|
+
-ms-flex-direction: column;
|
|
272
|
+
flex-direction: column;
|
|
273
|
+
align-items: baseline;
|
|
274
|
+
}
|
|
275
|
+
.katex .hbox {
|
|
276
|
+
display: -ms-inline-flexbox;
|
|
277
|
+
display: inline-flex;
|
|
278
|
+
-ms-flex-direction: row;
|
|
279
|
+
flex-direction: row;
|
|
280
|
+
width: 100%;
|
|
281
|
+
}
|
|
282
|
+
.katex .thinbox {
|
|
283
|
+
display: inline-flex;
|
|
284
|
+
flex-direction: row;
|
|
285
|
+
width: 0;
|
|
286
|
+
max-width: 0;
|
|
287
|
+
}
|
|
263
288
|
.katex .msupsub {
|
|
264
289
|
text-align: left;
|
|
265
290
|
}
|
|
@@ -330,10 +355,6 @@
|
|
|
330
355
|
margin-left: 0.27777778em;
|
|
331
356
|
margin-right: -0.55555556em;
|
|
332
357
|
}
|
|
333
|
-
.katex .sizing,
|
|
334
|
-
.katex .fontsize-ensurer {
|
|
335
|
-
display: inline-block;
|
|
336
|
-
}
|
|
337
358
|
.katex .sizing.reset-size1.size1,
|
|
338
359
|
.katex .fontsize-ensurer.reset-size1.size1 {
|
|
339
360
|
font-size: 1em;
|
|
@@ -869,13 +890,8 @@
|
|
|
869
890
|
}
|
|
870
891
|
.katex .mtable .vertical-separator {
|
|
871
892
|
display: inline-block;
|
|
872
|
-
margin: 0 -0.025em;
|
|
873
|
-
border-right: 0.05em solid;
|
|
874
893
|
min-width: 1px;
|
|
875
894
|
}
|
|
876
|
-
.katex .mtable .vs-dashed {
|
|
877
|
-
border-right: 0.05em dashed;
|
|
878
|
-
}
|
|
879
895
|
.katex .mtable .arraycolsep {
|
|
880
896
|
display: inline-block;
|
|
881
897
|
}
|
|
@@ -911,6 +927,13 @@
|
|
|
911
927
|
.katex svg path {
|
|
912
928
|
stroke: none;
|
|
913
929
|
}
|
|
930
|
+
.katex img {
|
|
931
|
+
border-style: none;
|
|
932
|
+
min-width: 0;
|
|
933
|
+
min-height: 0;
|
|
934
|
+
max-width: none;
|
|
935
|
+
max-height: none;
|
|
936
|
+
}
|
|
914
937
|
.katex .stretchy {
|
|
915
938
|
width: 100%;
|
|
916
939
|
display: block;
|
|
@@ -1007,5 +1030,6 @@
|
|
|
1007
1030
|
}
|
|
1008
1031
|
.katex-display.fleqn > .katex {
|
|
1009
1032
|
text-align: left;
|
|
1033
|
+
padding-left: 2em;
|
|
1010
1034
|
}
|
|
1011
1035
|
|