SA

Size: a a a
SA
DI
Ж
SA
R.
И
P
E
P
Р
K
const range = this.quill.getSelection();Но постоянно падает в ошибку
const value = prompt('please copy paste the image url here.');
if(value){
this.quill.insertEmbed(range.index, 'image', value, Quill.sources.USER);
}
Cannot read property 'quill' of undefinedНе могу понять в чем проблема. Может кто сможет подсказать?
export const QuillModules = {
toolbar: {
container:[
[{ 'header': '1'}, {'header': '2'}],
[{size: []}],
['bold', 'italic', 'underline', 'strike', 'blockquote', ],
[{ align: '' }, { align: 'center' }, { align: 'right' }, { align: 'justify' }],
[{ 'color': [] }, { 'background': [] }],
[{'list': 'ordered'}, {'list': 'bullet'},
{'indent': '-1'}, {'indent': '+1'}],
['link', 'image', 'video', 'code-block'],
],
handlers: {
'image': () => {
const range = this.quill.getSelection();
const value = prompt('please copy paste the image url here.');
if(value){
this.quill.insertEmbed(range.index, 'image', value, Quill.sources.USER);
}
},
}
},
clipboard: {
// toggle to add extra line breaks when pasting HTML:
matchVisual: false,
},
}
C
A
M
VK
M
VK
M