Skip to content

Commit

Permalink
add new classes to all emphasis and inline-code elements
Browse files Browse the repository at this point in the history
  • Loading branch information
pmario committed Apr 22, 2024
1 parent dca0326 commit 11af157
Show file tree
Hide file tree
Showing 8 changed files with 23 additions and 1 deletion.
3 changes: 3 additions & 0 deletions core/modules/parsers/wikiparser/rules/codeinline.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,9 @@ exports.parse = function() {
tag: "code",
children: [{
type: "text",
attributes: {
class: {type: "string", value: "tc-emphasis tc-code"}
},
text: text
}]
}];
Expand Down
3 changes: 3 additions & 0 deletions core/modules/parsers/wikiparser/rules/emphasis/bold.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,9 @@ exports.parse = function() {
return [{
type: "element",
tag: "strong",
attributes: {
class: {type: "string", value: "tc-emphasis tc-strong"}
},
children: tree
}];
};
Expand Down
4 changes: 4 additions & 0 deletions core/modules/parsers/wikiparser/rules/emphasis/italic.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,10 @@ exports.parse = function() {
return [{
type: "element",
tag: "em",
attributes: {
class: {type: "string", value: "tc-emphasis tc-italic"}
},

children: tree
}];
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,9 @@ exports.parse = function() {
return [{
type: "element",
tag: "strike",
attributes: {
class: {type: "string", value: "tc-emphasis tc-strike"}
},
children: tree
}];
};
Expand Down
3 changes: 3 additions & 0 deletions core/modules/parsers/wikiparser/rules/emphasis/subscript.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,9 @@ exports.parse = function() {
return [{
type: "element",
tag: "sub",
attributes: {
class: {type: "string", value: "tc-emphasis tc-sub"}
},
children: tree
}];
};
Expand Down
3 changes: 3 additions & 0 deletions core/modules/parsers/wikiparser/rules/emphasis/superscript.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,9 @@ exports.parse = function() {
return [{
type: "element",
tag: "sup",
attributes: {
class: {type: "string", value: "tc-emphasis tc-sup"}
},
children: tree
}];
};
Expand Down
3 changes: 3 additions & 0 deletions core/modules/parsers/wikiparser/rules/emphasis/underscore.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,9 @@ exports.parse = function() {
return [{
type: "element",
tag: "u",
attributes: {
class: {type: "string", value: "tc-emphasis tc-underscore"}
},
children: tree
}];
};
Expand Down
2 changes: 1 addition & 1 deletion themes/tiddlywiki/vanilla/base.tid
Original file line number Diff line number Diff line change
Expand Up @@ -469,7 +469,7 @@ a.tc-tiddlylink-external:hover {
}

/* wikitext bold for ''[[internal link]]'' */
strong .tc-tiddlylink {
strong.tc-strong .tc-tiddlylink {
font-weight: bolder;
}

Expand Down

0 comments on commit 11af157

Please sign in to comment.