i может изменить значение текста, но я не могу изменить текст в раскрывающемся списке ngx-quill
Я пробовал оба способа, ts, и создание нового контейнера все еще не решает мою проблему. просмотрел документ и все еще не смог найти подходящего решения этой проблемы. Поскольку документ не определяет, как изменить метки
html
<div id = "toolBarConfig"></div>
ts
const sizeVal = Quill.import('attributors/style/size');
sizeVal.whitelist = ['14px', '16px', '72px'];
Quill.register(sizeVal, true);
const quill = new Quill('#toolBarConfig', {
modules: {
toolbar: [
['bold', 'italic', 'underline', 'strike'], // toggled buttons
['blockquote', 'code-block'],
[{ header: 1 }, { header: 2 }], // custom button values
[{ list: 'ordered' }, { list: 'bullet' }],
[{ script: 'sub' }, { script: 'super' }], // superscript/subscript
[{ indent: '-1' }, { indent: '+1' }], // outdent/indent
[{ direction: 'rtl' }], // text direction
[{ size: ['14px', '16px', '72px'] }], // custom dropdown
[{ header: [1, 2, 3, 4, 5, 6, false] }],
[{ color: [] }, { background: [] }], // dropdown with defaults from theme
[{ font: [] }],
[{ align: [] }],
['clean'],
['table'], // remove formatting button
['link', 'image', 'video'], //
link and image, video
],
},
theme: 'snow',
});
SCSS
.ql-snow .ql-picker.ql-size span[data-label = "14px"]::before,
.ql-snow .ql-picker.ql-size .ql-picker-item[data-
value = "14px"]::before {
content: '14px'!important;
font-size: 14px !important;
}
.ql-snow .ql-picker.ql-size span[data-label = "16px"]::before,
.ql-snow .ql-picker.ql-size .ql-picker-item[data-
value = "16px"]::before {
content: '16px'!important;
font-size: 16px !important;
}
.ql-snow .ql-picker.ql-size span[data-label = "72px"]::before,
.ql-snow .ql-picker.ql-size .ql-picker-item[data-
value = "72px"]::before {
content: '72px'!important;
font-size: 72px !important;
}