mirror of
https://github.com/Smaug123/KaTeX
synced 2025-10-10 05:28:41 +00:00
[breaking] trust setting to indicate whether input text is trusted (#1794)
* trust option to indicate whether input text is trusted * Revamp into trust contexts beyond just command * Document new trust function style * Fix screenshot testing * Use trust setting in \url and \href * Check `isTrusted` in `\url` and `\href` (so now disabled by default) * Automatically compute `protocol` from `url` in `isTrusted`, so it doesn't need to be passed into every context. * Document untrusted features in support list/table * Existing tests trust by default * remove allowedProtocols and fix flow errors * remove 'allowedProtocols' from documentation * add a comment about a flow error, rename urlToProtocol to protocolFromUrl * add tests test that use function version of trust option * default trust to false in MathML tests * fix test title, remove 'trust: false' from test settings since it's the default
This commit is contained in:
committed by
Kevin Barabash
parent
fc79f79c78
commit
3800dc49c1
@@ -453,7 +453,7 @@ use `\ce` instead|
|
||||
|\hookleftarrow|$\hookleftarrow$||
|
||||
|\hookrightarrow|$\hookrightarrow$||
|
||||
|\hphantom|$a\hphantom{bc}d$|`a\hphantom{bc}d`|
|
||||
|\href|$\href{https://katex.org/}{\KaTeX}$|`\href{https://katex.org/}{\KaTeX}`|
|
||||
|\href|$\href{https://katex.org/}{\KaTeX}$|`\href{https://katex.org/}{\KaTeX}` Requires `trust` [option](options.md)|
|
||||
|\hskip|$w\hskip1em i\hskip2em d$|`w\hskip1em i\hskip2em d`|
|
||||
|\hslash|$\hslash$||
|
||||
|\hspace|$s\hspace7ex k$|`s\hspace7ex k`|
|
||||
@@ -1105,7 +1105,7 @@ use `\ce` instead|
|
||||
|\upsilon|$\upsilon$||
|
||||
|\upuparrows|$\upuparrows$||
|
||||
|\urcorner|$\urcorner$||
|
||||
|\url|$\footnotesize\url{https://katex.org/}$|`\url{https://katex.org/}`|
|
||||
|\url|$\footnotesize\url{https://katex.org/}$|`\url{https://katex.org/}` Requires `trust` [option](options.md)|
|
||||
|\utilde|$\utilde{AB}$|`\utilde{AB}`|
|
||||
|
||||
## V
|
||||
|
Reference in New Issue
Block a user