Disable focus of panel view container on selected element in editor
Question
Hi
i am using grapejs for our project and my editor design is below.
My question is how to stop autofocus panel views container.
it only show when i click the panel buttons.
It always open when we drop a element to canvas or click a element in canvas.

Answers (1)
When you select a component in the canvas
editor.on('component:selected', () => {
//unfocus panel
});
When you start dragging a block onto the canvas
editor.on('block:drag:start', () => {
//unfocus panel
});
Related Questions and Answers
Continue research with similar issue discussions.
Issue #2350
[Question] How do I add elements/sectors to views container using a custom button in the Panel
I have added a custom button to the Panel as below: const pm = editor.Panels; pm.addButton('views', { id: 'customButton', className: '', co...
Issue #818
[QUESTION] Open different Panel's view on click text element
How can I make "click" event on texts open different panel's view than StyleManager? I'm trying this:
Issue #956
[QUESTION] How to load a new trait I added in a built-in component?
Hi guys I added a trait for my Link element which is a built-in component for gjs-blocks-basic. When I drag a new link component to the can...
Issue #2061
[QUESTION] How to place a component at the end of the canvas.
How can I put my footer at the end of the canvas? I want the editor to not allow placing a block/widget below the footer. example
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.