Skip to content

Commit

Permalink
improve css for KaTeX, MathJax issue workaround
Browse files Browse the repository at this point in the history
  • Loading branch information
KevinWang15 committed Mar 17, 2023
1 parent ba56890 commit ed0b7ca
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@notelix/web-marker",
"version": "2.0.5",
"version": "2.0.6",
"description": "a web page highlighter",
"main": "./build/web-marker.js",
"types": "./build/libroot.d.ts",
Expand Down
3 changes: 1 addition & 2 deletions src/lib/classes/Marker.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,7 @@ const AttributeNameHighlightId = "highlight-id";

const defaultCharsToKeepForTextBeforeAndTextAfter = 128;
const blackListedElementStyle = document.createElement("style");
blackListedElementStyle.innerText = `.${HighlightBlacklistedElementClassName}, .MJX_Assistive_MathML>math>mi, .MJX_Assistive_MathML>math>mo, .MJX_Assistive_MathML>math> mn, math>semantics mi, math>semantics mo, math>semantics mn {display:none!important;};`;

blackListedElementStyle.innerText = `.${HighlightBlacklistedElementClassName}, .MJX_Assistive_MathML>math>*, math>semantics>* {display:none!important;};`;
interface MarkerConstructorArgs {
rootElement?: HTMLElement;
eventHandler?: EventHandler;
Expand Down

0 comments on commit ed0b7ca

Please sign in to comment.