diff options
author | Bob Zeleznik <zzzman@gmail.com> | 2019-06-23 21:14:34 -0400 |
---|---|---|
committer | Bob Zeleznik <zzzman@gmail.com> | 2019-06-23 21:14:34 -0400 |
commit | 818d3a367648f7dbb279e13aa197ffbae412fbd0 (patch) | |
tree | ceb2def99c4060fcc7113cd3ed2a7df169512aa2 | |
parent | 73b3304d0865fc34ad1f21af2bbca20a3eca8a8a (diff) |
added arbitrary font size mark
-rw-r--r-- | src/client/util/RichTextSchema.tsx | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/client/util/RichTextSchema.tsx b/src/client/util/RichTextSchema.tsx index 820d17a14..f3f6655af 100644 --- a/src/client/util/RichTextSchema.tsx +++ b/src/client/util/RichTextSchema.tsx @@ -350,6 +350,16 @@ export const marks: { [index: string]: MarkSpec } = { /** FONT SIZES */ + pFontSize: { + attrs: { + fontSize: { default: 10 } + }, + inclusive: false, + parseDOM: [{ style: 'font-size: 10px;' }], + toDOM: (node) => ['span', { + style: `font-size: ${node.attrs.fontSize}px;` + }] + }, p10: { parseDOM: [{ style: 'font-size: 10px;' }], |