is it possible ?, change the drag and drop event to on click when adding a new component, I want to add components by clicking the block then it will be added directly to the selected component, Thank's
artf
Not really, but I was already thinking about this possibility, so probably I'll add it in the next release. I'd ask what would you expect in case of your gif? On click, the block should be added inside the cell?
fmr411
Yes, I want when I click, the block is added to the cell, but can I know where the function handles the event to add the block?
Hello, I went through, the following GitHub issues: #857 #1622 #1215 Almost all of the issues, though a little different, provide a way to add font family to the list. Most common way to tackle, as far as I've understood: For both of this, I'm getting the typographySector and fontProperty as undefined. I don't know, i...
artf
Try using this editor.StyleManager.getProperty('typography', 'font-family')
workadev
Hi @ankitjainOfficial, I'm new to this so can you please help me how to add some Google fonts in detail? Thanks in advance.
lock[bot]
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
I'm looking to store data dynamically though a id that is called in, at the moment I'm loading in templates dynamically but cant seem to figure out a way to store them. below is a rough idea but something along those lines , any help is appreciated. `
Hi @artf , How can I insert image inside the link? Please share your ideas what I need to do. If I need to create any custom component, please share some code. Thanks
artf
On the demo, you should see the 'Link block' which is made for this purpose
lock[bot]
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
I have an input trait, I want to change the 2 attributes (name and type) on the selected input element, on canvas is appropriate, but in the final html(editor.getHtml()) it doesn't work, I've read https://grapesjs.com/docs/modules/Components.html#define-new-component but I didn't find a solution, Thank's
artf
You should change the model and not the view element this.model.setAttributes({ 'data-attr': 'value' })
lock[bot]
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Can I change the onclick event to hover when select objects and display a toolbar?
artf
You might need to extend the SelectComponent command (take a look at toggleSelectComponent method)
afdallah
@artf Is there any example on how to extend the SelectComponent?
artf
mmm not really, I hope to publish soon a general doc about Commands. BTW it's just about getting the command (https://grapesjs.com/docs/api/commands.html#get) and overwriting its method
I have a button with the show-left command, I want to make when the button is clicked a second time (or more) remains active, but when running Sender.set ('active') in the stop function, there is a loop on stop so that an error appears Maximum call stack size exceeded First click Second click My Commands
artf
Create a reproducible demo, please
edward1893
I have 3 buttons, I want when the button is clicked for the second time (or more), the button remains active, for example, when first clicking on the layer, the layer button becomes active, if clicked again the layer button will remain act...
How so that Placeholders can change when typing a word in the trait directly, current placeholders can change only when mouseover I have a trait like this, is there anything that isn't right? Thank you :
artf
I think you might need to create a new trait type for a custom behavior
lock[bot]
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
I'm trying to create dropdown menu (like the device selection menu) inside options panel. In the documentation is described how can create panels and buttons only. How to do that?
artf
It was created by its own view so nothing special, there is no API to create select inputs, do them as you wish with your framework of choice then on change just bind your actions
Soharab-Shaikh
@artf Could you please help me to add select input(dropdown) inside the device panel?
Hi, I want to change the icon of a Block in the Block Manager: I know it is part of the attributes in the manner: attributes: { class:'gjs-fonts gjs-f-b1' } and the class defines the icon to be used. Where is the list of icons? I didn't find it in the documentation: Block Manager. Thanks!
artf
There is no list of icons, we used fontawesome and some custom one but we're planning to remove them from the core
lock[bot]
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.