[QUESTIONS] ckeditor is not initialized when replace trait text
Question
why when i change the ckeditor trait text it is not initialized
my trait
<pre>
domComps.addType('text',{
model: dModel.extend({
defaults: Object.assign({}, dModel.prototype.defaults, {
traits: [
{label:"Font Size", type:"text_fontsize"}
],
}),
},
{
isComponent: function(el) {
if (el.getAttribute && "text" == el.getAttribute("data-gjs-type")) return {type: "text"}
},
}),
view: dView,
});
</pre>
there is no ckeditor class in the component
Answers (3)
As you're still using the old API definition (which is quite an error-prone) I recommend reading first the documentation about Component then probably you'll find the issue
or is there another way to add trait (for text) so that ckeditor can work
In the documentation you can see how to extend other components
Related Questions and Answers
Continue research with similar issue discussions.
Issue #738
image reverted to original size after resized
hi, i got a strange issue with component: i got 2 types, image and icon the issue is when i first drag and drop the image component, i'm ab...
Issue #852
[QUESTION] How to change <a> content in traits?
I'm re-declaring a link type like this: When my button (<a>) is created, it is creating like this: <a class="btn botao-roxo">Botão</a> I wo...
Issue #1959
[Question] Edit innerHTML in a custom button
Hi All, I am trying to change the text in a button component, but I am not able to edit it. I added this type: I included the editable: tru...
Issue #709
isComponent is not returning trait
Happy new year! I am having an issue with isComponent(). Here is my code: For some reason the only time the trait shows up in component set...
Paid Plugins That Match This Issue
Curated by issue keywords and label relevance to help you ship faster.
Loading paid plugin recommendations...
Browse Plugin Categories
Jump directly to plugin category pages on the marketplace.