contexted link highlight + adjust prettier
This commit is contained in:
@@ -1,9 +1,16 @@
|
||||
import Plugin from '@ckeditor/ckeditor5-core/src/plugin'
|
||||
import { TwoStepCaretMovement, inlineHighlight } from 'ckeditor5/src/typing'
|
||||
|
||||
const HIGHLIGHT_CLASS = 'ck-link_selected'
|
||||
|
||||
export default class ContextedLinkEditing extends Plugin {
|
||||
init() {
|
||||
this._defineSchema() // ADDED
|
||||
this._defineConverters() // ADDED
|
||||
const twoStepCaretMovementPlugin = this.editor.plugins.get(TwoStepCaretMovement)
|
||||
twoStepCaretMovementPlugin.registerAttribute('contextedLink')
|
||||
|
||||
inlineHighlight(this.editor, 'contextedLink', 'a', HIGHLIGHT_CLASS)
|
||||
}
|
||||
_defineSchema() {
|
||||
// ADDED
|
||||
|
||||
Reference in New Issue
Block a user