PageSourceSearch

https://quickpic.co.za/_content/Blazored.TextEditor/Blazored-BlazorQuill.js

js quickpic.co.za collected 2026-09-30 14:33:46 UTC 2,612 bytes, 73 lines download raw bytes

1(function () {
2    window.QuillFunctions = {        
3        createQuill: function (
4            quillElement, toolBar, readOnly,
5            placeholder, theme, formats, debugLevel) {  
6
7            Quill.register('modules/blotFormatter', QuillBlotFormatter.default);
8
9            var options = {
10                debug: debugLevel,
11                modules: {
12                    toolbar: toolBar,
13                    blotFormatter: {}
14                },
15                placeholder: placeholder,
16                readOnly: readOnly,
17                theme: theme
18            };
19
20            if (formats) {
21                options.formats = formats;
22            }
23
24            new Quill(quillElement, options);
25        },
26        getQuillContent: function(quillElement) {
27            return JSON.stringify(quillElement.__quill.getContents());
28        },
29        getQuillText: function(quillElement) {
30            return quillElement.__quill.getText();
31        },
32        getQuillHTML: function(quillElement) {
33            return quillElement.__quill.root.innerHTML;
34        },
35        loadQuillContent: function(quillElement, quillContent) {
36            content = JSON.parse(quillContent);
37            return quillElement.__quill.setContents(content, 'api');
38        },
39        loadQuillHTMLContent: function (quillElement, quillHTMLContent) {
40            return quillElement.__quill.root.innerHTML = quillHTMLContent;
41        },
42        enableQuillEditor: function (quillElement, mode) {
43            quillElement.__quill.enable(mode);
44        },
45        insertQuillImage: function (quillElement, imageURL) {
46            var Delta = Quill.import('delta');
47            editorIndex = 0;
48
49            if (quillElement.__quill.getSelection() !== null) {
50                editorIndex = quillElement.__quill.getSelection().index;
51            }
52
53            return quillElement.__quill.updateContents(
54                new Delta()
55                    .retain(editorIndex)
56                    .insert({ image: imageURL },
57                        { alt: imageURL }));
58        },
59        insertQuillText: function (quillElement, text) {
60            editorIndex = 0;
61            selectionLength = 0;
62
63            if (quillElement.__quill.getSelection() !== null) {
64                selection = quillElement.__quill.getSelection();
65                editorIndex = selection.index;
66                selectionLength = selection.length;
67            }
68
69            return quillElement.__quill.deleteText(editorIndex, selectionLength)
70                .concat(quillElement.__quill.insertText(editorIndex, text));
71        }
72    };
73})();

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.