Add additional input rules to typography extension
superscriptTwo superscriptThree oneQuarter threeQuarters
This commit is contained in:
@@ -19,6 +19,10 @@ export const notEqual = new InputRule(/!=$/, '≠')
|
|||||||
export const laquo = new InputRule(/<<$/, '«')
|
export const laquo = new InputRule(/<<$/, '«')
|
||||||
export const raquo = new InputRule(/>>$/, '»')
|
export const raquo = new InputRule(/>>$/, '»')
|
||||||
export const multiplication = new InputRule(/\d+\s?([*x])\s?\d+$/, '×')
|
export const multiplication = new InputRule(/\d+\s?([*x])\s?\d+$/, '×')
|
||||||
|
export const superscriptTwo = new InputRule(/\^2$/, '²')
|
||||||
|
export const superscriptThree = new InputRule(/\^3$/, '³')
|
||||||
|
export const oneQuarter = new InputRule(/1\/4$/, '¼')
|
||||||
|
export const threeQuarters = new InputRule(/3\/4$/, '¾')
|
||||||
|
|
||||||
export const Typography = Extension.create({
|
export const Typography = Extension.create({
|
||||||
name: 'typography',
|
name: 'typography',
|
||||||
@@ -41,6 +45,10 @@ export const Typography = Extension.create({
|
|||||||
laquo,
|
laquo,
|
||||||
raquo,
|
raquo,
|
||||||
multiplication,
|
multiplication,
|
||||||
|
superscriptTwo,
|
||||||
|
superscriptThree,
|
||||||
|
oneQuarter,
|
||||||
|
threeQuarters,
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user