Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    Nisheal John
    @NishealJ
    Hi,
    Getting error document not defined when using ck.model.document.on
    Long Lazuli
    @long-lazuli

    Hi,
    Going back to try to publish ckeditor5 plugins; lots of them.
    But I'm still stuck with the famous ckeditor-duplicated-modules error.

    Any leads on how to do it just with a config passed to the @ckeditor/ckeditor5-editor-classic ?

    Nisheal John
    @NishealJ
    hello,
    getting an error Cannot read property "document" of undefined while using
    editor.modal.document.on ('change')
    using CKEditor classic build help?anyone?
    Szymon Cofalik
    @scofalik
    You have typo modal -> model
    Nisheal John
    @NishealJ
    Hi, still the same
    Screenshot 2019-08-01 at 1.03.14 PM.png
    Screenshot 2019-08-01 at 1.02.50 PM.png
    take a look here
    Szymon Cofalik
    @scofalik
    could you please show what console.log( editor ) shows? I am not sure how it goes with framework integrations, but it seems that you are misusing create. Normally you go with something like that: ClassicEditor.create( ... ).then( editor => { window.editor; } );, so what ClassicEditor returns is a Promise.
    Nisheal John
    @NishealJ
    Hi console.log (editor) shows editor not defined same in console.log(ck)
    Szymon Cofalik
    @scofalik
    Sorry! I meant console.log( ck )
    Nisheal John
    @NishealJ
    Also while using ClassicEditor.create( ... ).then( editor => { window.editor; } ); shows property editor doesnot exist in Window
    Same in ck
    Szymon Cofalik
    @scofalik
    I guess I am not focused today. Still before the first coffee :sweat_smile:. Sorry. Anyway, what I meant is that the promise resolves with the editor instance so you assign it / use it in then callback. But I am not sure if it is the same in framework integrations. Give me a sec.
    Nisheal John
    @NishealJ
    I tired using it in callback but seems like i’m missing something
    Also i’m using the classic build not included framework in anyway
    we are migrating for 4 to 5, so few parts of initializing are complete we need on events to work with data models
    Szymon Cofalik
    @scofalik
    Okay so since you are using simply classic build, below should work
    ClassicEditor.create( <HTMLElement>(el[0].children[0].children[1]) ).then( ck => {
        console.log( ck.model.document );
    } );
    Nisheal John
    @NishealJ
    okay looks good , and further use on change events with ck.model.document.on ('change') right?
    Szymon Cofalik
    @scofalik
    yes, you should put your scripts inside then callback
    Nisheal John
    @NishealJ
    Thanks! i'll try this out
    Szymon Cofalik
    @scofalik
    Hope it will work well
    Nisheal John
    @NishealJ
    also do we have instanceReady or getsnapshot events that we had it Ckeditor4?
    Szymon Cofalik
    @scofalik
    there is ready event on Editor class instance but it is used when developing plugins. I don't know what is your use case for it. When the promise is resolved in then callback the editor is initialized and ready to work. For getsnapshot I am not sure what it did in CKE4.
    Please be aware that plugins written for CKE4 will not work with CKE5.
    (I am mentioning that since you noted that you are migrating)
    Nisheal John
    @NishealJ
    yes I am completely aware that the plugin will not work in ck5.
    Szymon Cofalik
    @scofalik
    :thumbsup: Good luck then :)
    Nisheal John
    @NishealJ
    we initalize our rte components as widgets here core/templates/dev/head/components/ck-editor-helpers/ck-editor-4-widgets.initializer.ts
    I've not started the work for it, i hope it will possible
    Evgenij Kopitsa
    @lasfin

    Could someone tell what is the issue with my code?
    I'm trying to handle copy/pasting of custom react element.
    Creating elements is working well for editingDowncast/dataDowncast.

    But then I'm trying to handle copy paste this way, I'm getting view-writer-insert-invalid-node error. But for me, it looks like I'm still inserting ContainerElement, so I'm not sure what the problem is.

    Code example is here:
    https://gist.github.com/lasfin/e95cca5e83445f3097a356f8f7cc588f
    Any help will be highly appreciated

    Evgenij Kopitsa
    @lasfin
    Anyone? :)
    Kirankumar Ambati
    @KirankumarAmbati
    How to enable a plugin by default on load of CKEditor5 ? For example, I want to enable 'bold' plugin on load of page, how can I do that in CKE5
    Thanks!
    Gaurav Jain
    @gauravjain028
    Hello Guys
    I have a question. Is it possible to add image between to list items ?
    Nisheal John
    @NishealJ
    Unhandled Promise rejection: Class constructor Plugin cannot be invoked without 'new' ; Zone: <root> ; Task: Promise.then ; Value: TypeError: Class constructor Plugin cannot be invoked without 'new'
    this happens while using the sample code for image plugin
    Nisheal John
    @NishealJ

    Hello can anyone look in the above isssue? Happens while adding custom plugins.

    Should i wait until all the issues related to plugin are resolved? #677 and #649

    The above issue are frequently appearing
    Suresh918
    @Suresh918
    Hi All, is there any way to highlight text in the text area while typing, programatically
    my requirement is like if the text exceeds 100 chars, then i need to show the text in red color from 100 chars
    can anyone give suggestions on this please
    Piotrek Koszuliński
    @Reinmar

    Hi everyone! We've been looking recently into this channel and we realised that it no longer works if 90% of messages are unanswered. Therefore, we made a decision to close it. We want to forward the questions that were asked here to GitHub and Stackoverflow where they make more sense and are easier for us and the community to process and handle.

    You can find more information about the rationale in ckeditor/ckeditor5#2037.

    We'll be updating the documentation and repositories soon.

    Thank you, everyone, for participation!

    tl;dr: This channel is closed. Use GitHub and Stackoverflow to contact us and the community instead.