This commit is contained in:
Philipp Kühn
2020-11-17 22:45:56 +01:00
parent 786c86f4b8
commit 91377be21e
6 changed files with 22 additions and 22 deletions

View File

@@ -43,9 +43,9 @@ const Bold = Mark.create({
addCommands() {
return {
/**
* Set a bold mark
* Add a bold mark
*/
setBold: (): Command => ({ commands }) => {
addBold: (): Command => ({ commands }) => {
return commands.addMark('bold')
},
/**
@@ -55,9 +55,9 @@ const Bold = Mark.create({
return commands.toggleMark('bold')
},
/**
* Unset a bold mark
* Remove a bold mark
*/
unsetBold: (): Command => ({ commands }) => {
removeBold: (): Command => ({ commands }) => {
return commands.removeMark('bold')
},
}

View File

@@ -36,9 +36,9 @@ const Code = Mark.create({
addCommands() {
return {
/**
* Set a code mark
* Add a code mark
*/
setCode: (): Command => ({ commands }) => {
addCode: (): Command => ({ commands }) => {
return commands.addMark('code')
},
/**
@@ -48,9 +48,9 @@ const Code = Mark.create({
return commands.toggleMark('code')
},
/**
* Unset a code mark
* Remove a code mark
*/
unsetCode: (): Command => ({ commands }) => {
removeCode: (): Command => ({ commands }) => {
return commands.addMark('code')
},
}

View File

@@ -59,9 +59,9 @@ const Highlight = Mark.create({
addCommands() {
return {
/**
* Set a highlight mark
* Add a highlight mark
*/
setHighlight: (attributes?: { color: string }): Command => ({ commands }) => {
addHighlight: (attributes?: { color: string }): Command => ({ commands }) => {
return commands.addMark('highlight', attributes)
},
/**
@@ -71,9 +71,9 @@ const Highlight = Mark.create({
return commands.toggleMark('highlight', attributes)
},
/**
* Set a highlight mark
* Remove a highlight mark
*/
unsetHighlight: (): Command => ({ commands }) => {
removeHighlight: (): Command => ({ commands }) => {
return commands.removeMark('highlight')
},
}

View File

@@ -45,9 +45,9 @@ const Italic = Mark.create({
addCommands() {
return {
/**
* Set an italic mark
* Add an italic mark
*/
setItalic: (): Command => ({ commands }) => {
addItalic: (): Command => ({ commands }) => {
return commands.addMark('italic')
},
/**
@@ -57,9 +57,9 @@ const Italic = Mark.create({
return commands.toggleMark('italic')
},
/**
* Unset an italic mark
* Remove an italic mark
*/
unsetItalic: (): Command => ({ commands }) => {
removeItalic: (): Command => ({ commands }) => {
return commands.addMark('italic')
},
}

View File

@@ -45,9 +45,9 @@ const Strike = Mark.create({
addCommands() {
return {
/**
* Set a strike mark
* Add a strike mark
*/
setStrike: (): Command => ({ commands }) => {
addStrike: (): Command => ({ commands }) => {
return commands.addMark('strike')
},
/**
@@ -57,9 +57,9 @@ const Strike = Mark.create({
return commands.toggleMark('strike')
},
/**
* Unset a strike mark
* Remove a strike mark
*/
unsetStrike: (): Command => ({ commands }) => {
removeStrike: (): Command => ({ commands }) => {
return commands.addMark('strike')
},
}

View File

@@ -33,7 +33,7 @@ const Underline = Mark.create({
/**
* Set an underline mark
*/
setUnderline: (): Command => ({ commands }) => {
addUnderline: (): Command => ({ commands }) => {
return commands.addMark('underline')
},
/**
@@ -45,7 +45,7 @@ const Underline = Mark.create({
/**
* Unset an underline mark
*/
unsetUnderline: (): Command => ({ commands }) => {
removeUnderline: (): Command => ({ commands }) => {
return commands.addMark('underline')
},
}