1
0
mirror of https://github.com/BookStackApp/BookStack.git synced 2025-06-27 16:41:53 +03:00

Added strike, sup and sub marks

This commit is contained in:
Dan Brown
2022-01-11 16:00:57 +00:00
parent a8f48185b5
commit c3595b1807
4 changed files with 45 additions and 2 deletions

View File

@ -13,6 +13,21 @@ marks.underline = {
close: '</span>',
};
marks.strike = {
open: '<span style="text-decoration: line-through;">',
close: '</span>',
};
marks.superscript = {
open: '<sup>',
close: '</sup>',
};
marks.subscript = {
open: '<sub>',
close: '</sub>',
};
function writeNodeAsHtml(state, node) {
const html = docToHtml({ content: [node] });
state.write(html);