mirror of
https://github.com/zadam/trilium.git
synced 2025-12-04 14:34:24 +01:00
fixed whitespace and redundant lines.
This commit is contained in:
parent
52bb83e878
commit
4f6dfeb773
@ -50,7 +50,7 @@ const TRILIUM_PLUGINS: typeof Plugin[] = [
|
|||||||
CodeBlockLanguageDropdown,
|
CodeBlockLanguageDropdown,
|
||||||
CodeBlockToolbar,
|
CodeBlockToolbar,
|
||||||
MoveBlockUpDownPlugin,
|
MoveBlockUpDownPlugin,
|
||||||
ScrollOnUndoRedoPlugin,
|
ScrollOnUndoRedoPlugin,
|
||||||
InlineCodeNoSpellcheck,
|
InlineCodeNoSpellcheck,
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|||||||
@ -3,14 +3,13 @@ import { Plugin } from "ckeditor5";
|
|||||||
export default class InlineCodeNoSpellcheck extends Plugin {
|
export default class InlineCodeNoSpellcheck extends Plugin {
|
||||||
|
|
||||||
init() {
|
init() {
|
||||||
const editor = this.editor;
|
this.editor.conversion.for('downcast').attributeToElement({
|
||||||
editor.conversion.for('downcast').attributeToElement({
|
|
||||||
model: 'code',
|
model: 'code',
|
||||||
view: (modelAttributeValue, conversionApi) => {
|
view: (modelAttributeValue, conversionApi) => {
|
||||||
const { writer } = conversionApi;
|
const { writer } = conversionApi;
|
||||||
return writer.createAttributeElement('code', {
|
return writer.createAttributeElement('code', {
|
||||||
spellcheck: 'false'
|
spellcheck: 'false'
|
||||||
}, { priority: 5 });
|
});
|
||||||
},
|
},
|
||||||
converterPriority: 'high'
|
converterPriority: 'high'
|
||||||
});
|
});
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user