123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808 |
- // Jest Snapshot v1, https://goo.gl/fbAQLP
- exports[`A MathML builder \\html@mathml makes clean symbols 1`] = `
- <math>
- <semantics>
- <mrow>
- <mtext>
- ©
- </mtext>
- <mi mathvariant="normal">
- ≠
- </mi>
- <mi mathvariant="normal">
- ∉
- </mi>
- <mi mathvariant="normal">
- ≘
- </mi>
- <mtext>
- KaTeX
- </mtext>
- </mrow>
- <annotation encoding="application/x-tex">
- \\copyright\\neq\\notin≘\\KaTeX
- </annotation>
- </semantics>
- </math>
- `;
- exports[`A MathML builder \\text fonts become mathvariant 1`] = `
- <math>
- <semantics>
- <mrow>
- <mtext>
- roman
- </mtext>
- <mrow>
- <mtext mathvariant="italic">
- italic
- </mtext>
- <mrow>
- <mtext mathvariant="bold-italic">
- bold
- </mtext>
- <mtext>
- </mtext>
- <mtext mathvariant="bold-italic">
- italic
- </mtext>
- </mrow>
- </mrow>
- <mtext mathvariant="bold">
- bold
- </mtext>
- <mrow>
- <mtext mathvariant="sans-serif">
- ss
- </mtext>
- <mrow>
- <mtext mathvariant="sans-serif-italic">
- italic
- </mtext>
- <mrow>
- <mtext mathvariant="sans-serif-bold-italic">
- bold
- </mtext>
- <mtext>
- </mtext>
- <mtext mathvariant="sans-serif-bold-italic">
- italic
- </mtext>
- </mrow>
- </mrow>
- <mtext mathvariant="bold-sans-serif">
- bold
- </mtext>
- </mrow>
- <mrow>
- <mtext mathvariant="monospace">
- tt
- </mtext>
- <mrow>
- <mtext mathvariant="monospace">
- italic
- </mtext>
- <mrow>
- <mtext mathvariant="monospace">
- bold
- </mtext>
- <mtext>
- </mtext>
- <mtext mathvariant="monospace">
- italic
- </mtext>
- </mrow>
- </mrow>
- <mtext mathvariant="monospace">
- bold
- </mtext>
- </mrow>
- </mrow>
- <annotation encoding="application/x-tex">
- \\text{roman\\textit{italic\\textbf{bold italic}}\\textbf{bold}\\textsf{ss\\textit{italic\\textbf{bold italic}}\\textbf{bold}}\\texttt{tt\\textit{italic\\textbf{bold italic}}\\textbf{bold}}}
- </annotation>
- </semantics>
- </math>
- `;
- exports[`A MathML builder accents turn into <mover accent="true"> in MathML 1`] = `
- <math>
- <semantics>
- <mrow>
- <mover accent="true">
- <mi>
- u
- </mi>
- <mo>
- ¨
- </mo>
- </mover>
- <mi>
- b
- </mi>
- <mi>
- e
- </mi>
- <mi>
- r
- </mi>
- <mi>
- f
- </mi>
- <mi>
- i
- </mi>
- <mi>
- a
- </mi>
- <mi>
- n
- </mi>
- <mi>
- c
- </mi>
- <mover accent="true">
- <mi>
- e
- </mi>
- <mo>
- ˊ
- </mo>
- </mover>
- <mi>
- e
- </mi>
- </mrow>
- <annotation encoding="application/x-tex">
- über fiancée
- </annotation>
- </semantics>
- </math>
- `;
- exports[`A MathML builder ligatures render properly 1`] = `
- <math>
- <semantics>
- <mrow>
- <mtext>
- “‘Hi—-”’
- </mtext>
- <mo>
- −
- </mo>
- <mo>
- −
- </mo>
- <mtext mathvariant="monospace">
- \`\`‘Hi----''’
- </mtext>
- <mrow>
- <mtext>
- \`\`
- </mtext>
- <mtext mathvariant="monospace">
- ‘Hi
- </mtext>
- <mtext>
- ---
- </mtext>
- <mtext mathvariant="monospace">
- -
- </mtext>
- <mtext>
- ''
- </mtext>
- <mtext mathvariant="monospace">
- ’
- </mtext>
- </mrow>
- </mrow>
- <annotation encoding="application/x-tex">
- \\text{\`\`\`Hi----'''}--\\texttt{\`\`\`Hi----'''}\\text{\\tt \`\`\`Hi----'''}
- </annotation>
- </semantics>
- </math>
- `;
- exports[`A MathML builder normal spaces render normally 1`] = `
- <math>
- <semantics>
- <mrow>
- <mspace width="1em">
- </mspace>
- <mspace width="0.431em">
- </mspace>
- </mrow>
- <annotation encoding="application/x-tex">
- \\kern1em\\kern1ex
- </annotation>
- </semantics>
- </math>
- `;
- exports[`A MathML builder should concatenate digits into single <mn> 1`] = `
- <math>
- <semantics>
- <mrow>
- <mi>
- sin
- </mi>
- <mo>
-
- </mo>
- <mi>
- α
- </mi>
- <mo>
- =
- </mo>
- <mn>
- 0.34
- </mn>
- </mrow>
- <annotation encoding="application/x-tex">
- \\sin{\\alpha}=0.34
- </annotation>
- </semantics>
- </math>
- `;
- exports[`A MathML builder should generate <mphantom> nodes for \\phantom 1`] = `
- <math>
- <semantics>
- <mrow>
- <mphantom>
- <mi>
- x
- </mi>
- </mphantom>
- </mrow>
- <annotation encoding="application/x-tex">
- \\phantom{x}
- </annotation>
- </semantics>
- </math>
- `;
- exports[`A MathML builder should generate the right types of nodes 1`] = `
- <math>
- <semantics>
- <mrow>
- <mi>
- sin
- </mi>
- <mo>
-
- </mo>
- <mi>
- x
- </mi>
- <mo>
- +
- </mo>
- <mn>
- 1
- </mn>
- <mtext>
-   
- </mtext>
- <mtext>
- a
- </mtext>
- </mrow>
- <annotation encoding="application/x-tex">
- \\sin{x}+1\\;\\text{a}
- </annotation>
- </semantics>
- </math>
- `;
- exports[`A MathML builder should make prime operators into <mo> nodes 1`] = `
- <math>
- <semantics>
- <mrow>
- <msup>
- <mi>
- f
- </mi>
- <mo mathvariant="normal">
- ′
- </mo>
- </msup>
- </mrow>
- <annotation encoding="application/x-tex">
- f'
- </annotation>
- </semantics>
- </math>
- `;
- exports[`A MathML builder should output \\limsup_{x \\rightarrow \\infty} correctly in \\textstyle 1`] = `
- <math>
- <semantics>
- <mrow>
- <msub>
- <mo>
- <mi mathvariant="normal">
- lim sup
- </mi>
- <mo>
-
- </mo>
- </mo>
- <mrow>
- <mi>
- x
- </mi>
- <mo>
- →
- </mo>
- <mi mathvariant="normal">
- ∞
- </mi>
- </mrow>
- </msub>
- </mrow>
- <annotation encoding="application/x-tex">
- \\limsup_{x \\rightarrow \\infty}
- </annotation>
- </semantics>
- </math>
- `;
- exports[`A MathML builder should output \\limsup_{x \\rightarrow \\infty} in displaymode correctly 1`] = `
- <math>
- <semantics>
- <mrow>
- <munder>
- <mo>
- <mi mathvariant="normal">
- lim sup
- </mi>
- <mo>
-
- </mo>
- </mo>
- <mrow>
- <mi>
- x
- </mi>
- <mo>
- →
- </mo>
- <mi mathvariant="normal">
- ∞
- </mi>
- </mrow>
- </munder>
- </mrow>
- <annotation encoding="application/x-tex">
- \\limsup_{x \\rightarrow \\infty}
- </annotation>
- </semantics>
- </math>
- `;
- exports[`A MathML builder should render boldsymbol with the correct mathvariants 1`] = `
- <math>
- <semantics>
- <mrow>
- <mrow>
- <mi mathvariant="bold-italic">
- A
- </mi>
- <mi mathvariant="bold-italic">
- x
- </mi>
- <mn mathvariant="bold-italic">
- 2
- </mn>
- <mi mathvariant="bold-italic">
- k
- </mi>
- <mi mathvariant="bold-italic">
- ω
- </mi>
- <mi mathvariant="bold-italic">
- Ω
- </mi>
- <mi mathvariant="bold-italic">
- ı
- </mi>
- <mo mathvariant="bold-italic">
- +
- </mo>
- </mrow>
- </mrow>
- <annotation encoding="application/x-tex">
- \\boldsymbol{Ax2k\\omega\\Omega\\imath+}
- </annotation>
- </semantics>
- </math>
- `;
- exports[`A MathML builder should render mathchoice as if there was nothing 1`] = `
- <math>
- <semantics>
- <mrow>
- <mstyle scriptlevel="0"
- displaystyle="true"
- >
- <mrow>
- <munderover>
- <mo>
- ∑
- </mo>
- <mrow>
- <mi>
- k
- </mi>
- <mo>
- =
- </mo>
- <mn>
- 0
- </mn>
- </mrow>
- <mi mathvariant="normal">
- ∞
- </mi>
- </munderover>
- <msup>
- <mi>
- x
- </mi>
- <mi>
- k
- </mi>
- </msup>
- </mrow>
- </mstyle>
- </mrow>
- <annotation encoding="application/x-tex">
- \\displaystyle\\mathchoice{\\sum_{k = 0}^{\\infty} x^k}{T}{S}{SS}
- </annotation>
- </semantics>
- </math>
- `;
- exports[`A MathML builder should render mathchoice as if there was nothing 2`] = `
- <math>
- <semantics>
- <mrow>
- <msubsup>
- <mo>
- ∑
- </mo>
- <mrow>
- <mi>
- k
- </mi>
- <mo>
- =
- </mo>
- <mn>
- 0
- </mn>
- </mrow>
- <mi mathvariant="normal">
- ∞
- </mi>
- </msubsup>
- <msup>
- <mi>
- x
- </mi>
- <mi>
- k
- </mi>
- </msup>
- </mrow>
- <annotation encoding="application/x-tex">
- \\mathchoice{D}{\\sum_{k = 0}^{\\infty} x^k}{S}{SS}
- </annotation>
- </semantics>
- </math>
- `;
- exports[`A MathML builder should render mathchoice as if there was nothing 3`] = `
- <math>
- <semantics>
- <mrow>
- <msub>
- <mi>
- x
- </mi>
- <mi>
- T
- </mi>
- </msub>
- </mrow>
- <annotation encoding="application/x-tex">
- x_{\\mathchoice{D}{T}{\\sum_{k = 0}^{\\infty} x^k}{SS}}
- </annotation>
- </semantics>
- </math>
- `;
- exports[`A MathML builder should render mathchoice as if there was nothing 4`] = `
- <math>
- <semantics>
- <mrow>
- <msub>
- <mi>
- x
- </mi>
- <msub>
- <mi>
- y
- </mi>
- <mi>
- T
- </mi>
- </msub>
- </msub>
- </mrow>
- <annotation encoding="application/x-tex">
- x_{y_{\\mathchoice{D}{T}{S}{\\sum_{k = 0}^{\\infty} x^k}}}
- </annotation>
- </semantics>
- </math>
- `;
- exports[`A MathML builder should set href attribute for href appropriately 1`] = `
- <math>
- <semantics>
- <mrow>
- <mi href="http://example.org">
- α
- </mi>
- </mrow>
- <annotation encoding="application/x-tex">
- \\href{http://example.org}{\\alpha}
- </annotation>
- </semantics>
- </math>
- `;
- exports[`A MathML builder should use <menclose> for colorbox 1`] = `
- <math>
- <semantics>
- <mrow>
- <menclose mathbackground="red">
- <mtext>
- b
- </mtext>
- </menclose>
- </mrow>
- <annotation encoding="application/x-tex">
- \\colorbox{red}{b}
- </annotation>
- </semantics>
- </math>
- `;
- exports[`A MathML builder should use <mpadded> for raisebox 1`] = `
- <math>
- <semantics>
- <mrow>
- <mpadded voffset="0.25em">
- <mtext>
- b
- </mtext>
- </mpadded>
- </mrow>
- <annotation encoding="application/x-tex">
- \\raisebox{0.25em}{b}
- </annotation>
- </semantics>
- </math>
- `;
- exports[`A MathML builder should use <msupsub> for regular operators 1`] = `
- <math>
- <semantics>
- <mrow>
- <mstyle scriptlevel="0"
- displaystyle="false"
- >
- <msubsup>
- <mo>
- ∑
- </mo>
- <mi>
- a
- </mi>
- <mi>
- b
- </mi>
- </msubsup>
- </mstyle>
- </mrow>
- <annotation encoding="application/x-tex">
- \\textstyle\\sum_a^b
- </annotation>
- </semantics>
- </math>
- `;
- exports[`A MathML builder should use <munderover> for large operators 1`] = `
- <math>
- <semantics>
- <mrow>
- <mstyle scriptlevel="0"
- displaystyle="true"
- >
- <munderover>
- <mo>
- ∑
- </mo>
- <mi>
- a
- </mi>
- <mi>
- b
- </mi>
- </munderover>
- </mstyle>
- </mrow>
- <annotation encoding="application/x-tex">
- \\displaystyle\\sum_a^b
- </annotation>
- </semantics>
- </math>
- `;
- exports[`A MathML builder special spaces render specially 1`] = `
- <math>
- <semantics>
- <mrow>
- <mtext>
-  
- </mtext>
- <mtext>
-  
- </mtext>
- <mtext>
-  
- </mtext>
- <mtext>
-  
- </mtext>
- <mtext>
-  
- </mtext>
- <mtext>
-   
- </mtext>
- <mtext>
-   
- </mtext>
- <mtext>
- ​
- </mtext>
- <mtext>
- ​
- </mtext>
- <mtext>
- ​
- </mtext>
- <mtext>
- ​
- </mtext>
- <mtext>
-  
- </mtext>
- <mtext>
-  
- </mtext>
- <mtext>
-  
- </mtext>
- <mtext>
-   
- </mtext>
- <mtext>
- ​
- </mtext>
- <mtext>
- ​
- </mtext>
- <mtext>
- ​
- </mtext>
- <mtext>
- ​
- </mtext>
- </mrow>
- <annotation encoding="application/x-tex">
- \\,\\thinspace\\:\\>\\medspace\\;\\thickspace\\!\\negthinspace\\negmedspace\\negthickspace\\mkern1mu\\mkern3mu\\mkern4mu\\mkern5mu\\mkern-1mu\\mkern-3mu\\mkern-4mu\\mkern-5mu
- </annotation>
- </semantics>
- </math>
- `;
- exports[`A MathML builder tags use <mlabeledtr> 1`] = `
- <math>
- <semantics>
- <mtable side="right">
- <mlabeledtr>
- <mtd>
- <mtext>
- (hi)
- </mtext>
- </mtd>
- <mtd>
- <mrow>
- <mi>
- x
- </mi>
- <mo>
- +
- </mo>
- <msup>
- <mi>
- y
- </mi>
- <mn>
- 2
- </mn>
- </msup>
- </mrow>
- </mtd>
- </mlabeledtr>
- </mtable>
- <annotation encoding="application/x-tex">
- \\tag{hi} x+y^2
- </annotation>
- </semantics>
- </math>
- `;
|