How to use the ckeditor4.replace function in ckeditor4

To help you get started, we’ve selected a few ckeditor4 examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github Enalean / tuleap / plugins / tracker / scripts / angular-artifact-modal / src / common / RichTextEditor.vue View on Github external
createCKEditor() {
            this.editor = CKEDITOR.replace(this.$refs.textarea, this.ckeditor_config);
            this.editor.on("instanceReady", this.onInstanceReady);
        },
github Enalean / tuleap / src / scripts / codendi / RichTextEditor.js View on Github external
/*
             This is done for IE
             If we load the page and the RTE is displayed, IE will not
             catch the instanceCreated event on load (it will catch it later if we change
             the format between Text and HTML). So we have to set this option when loading
             */

        replace_options.toolbar = toolbar;
        if (!this.can_be_resized()) {
            replace_options.resize_enabled = false;
        }

        replace_options = Object.assign(replace_options, {
            ...getUploadImageOptions(this.element),
        });
        this.rte = CKEDITOR.replace(this.element.id, replace_options);
        initiateUploadImage(this.rte, replace_options, this.element);

        /*CKEDITOR filters HTML tags
              So, if your default text is like , this will not be displayed.
              To "fix" this, we escape the textarea content.
              However, we don't need to espace this for non default values.
            */

        if (this.element.readAttribute("data-field-default-value") !== null) {
            var escaped_value = tuleap.escaper.html(this.element.value);
            this.rte.setData(escaped_value);
        }

        CKEDITOR.on("dialogDefinition", function (ev) {
            var tab,
                dialog = ev.data.name,
github Enalean / tuleap / src / scripts / site-admin / massmail.js View on Github external
function initHTMLEditor() {
        editor = CKEDITOR.replace("mail_message", tuleap.ckeditor.config);
    }
github Enalean / tuleap / src / scripts / frs / admin / license-agreement.js View on Github external
* (at your option) any later version.
 *
 * Tuleap is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with Tuleap. If not, see .
 *
 */

import CKEDITOR from "ckeditor4";
import tuleap from "tuleap";

CKEDITOR.replace("license-agreement-content", tuleap.ckeditor.config);
github Enalean / tuleap / src / scripts / dashboards / widgets / contact-modal.js View on Github external
[].forEach.call(massmail_project_member_links, function (massmail_project_member_link) {
        massmail_project_member_link.addEventListener("click", function () {
            document.getElementById("massmail-project-members-project-id").value =
                massmail_project_member_link.dataset.projectId;

            var contact_modal = createModal(document.getElementById("massmail-project-members"));
            contact_modal.show();
        });
    });

    var textarea = document.getElementById("massmail-project-members-body");
    if (!textarea) {
        return;
    }

    CKEDITOR.replace(textarea, ckeditor_config);
});
github Enalean / tuleap / plugins / statistics / scripts / admin.js View on Github external
[].forEach.call(ckeditor_selector, function (ckeditor_element) {
        CKEDITOR.replace(ckeditor_element.id, tuleap.ckeditor.config);
    });

ckeditor4

JavaScript WYSIWYG web text editor.

SEE LICENSE IN LICENSE.md
Latest version published 3 months ago

Package Health Score

71 / 100
Full package analysis