Component droped position is wrong when I changed canvas size under Absolute/Designer mode
@artf OK, I provide some screenshot for explaining.Sorry for my bad English.
Read full answer below βQuestion
WARNING
I changed the canvas size and I drop a compent from blocks panel. The result is compent postion is wrong. By the way, the editor is under 'Absolute/Designer' mode.
I read the source code of the drop part. I found the compent drag start position is not based on 'editor.Canvas.getFrameEl()'. So, is this right?
Answers (4)
@artf OK, I provide some screenshot for explaining.Sorry for my bad English.
Can you provide a live demo of the issue?
I close this issue as I'm planning to solve all ones related to absolute positioning here: https://github.com/artf/grapesjs/issues/3770
Thanks for reporting this, @xinyufyj. Great question about component droped position is wrong when I changed canvas size under Absolute/Designer mode. The recommended approach with Canvas is to use the event-driven API. Start here: Check the GrapesJS documentation for your specific module Look for...
Related Questions and Answers
Continue research with similar issue discussions.
Issue #4196
Ids gets changed while trying to set components on the canvas using json
GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? Chrome Reproducible demo link no link Desc...
Issue #5378
Uncaught TypeError: Cannot read properties of undefined (reading 'Canvas') while dragging a component in Layer Manager Panel
GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? Chrome v116.0.5845.97 Reproducible demo li...
Issue #3177
QUESTION/FEATURE REQUEST: Changing Selected Component Tooltip
Is there a way through the api to change the selected component tooltip or is that something that can only be done by editing the source? I...
Issue #6685
Custom component styles are not applied after deletion and re-addition
GrapesJS version [x] I confirm to use the latest version of GrapesJS What browser are you using? Chrome v143.0.7499.193 Reproducible demo l...
Paid Plugins That Match This Issue
Curated by issue keywords and label relevance to help you ship faster.
Loading paid plugin recommendations...
Check the open-source GrapesJS plugins on GitHub or run a quick search in our free catalog.
Browse free plugins βPremium plugins ship with support, regular updates, and production-ready features β save days of integration work.
Browse premium plugins βRelated tutorials
In-depth guides on the same topic.
Tutorial
How to integrate GrapesJS into an Astro app (complete guide 2026)
Embed GrapesJS in an Astro site: mount it in a client-side script, save content to an Astro API endpoint, and export clean HTML/CSS.
Tutorial
GrapesJS custom components guide (2026)
Define custom GrapesJS components with DomComponents.addType: detection with isComponent, a model with traits and defaults, and a view for canvas behavior.
Tutorial
How to integrate GrapesJS into a Django app (complete guide 2026)
Embed GrapesJS in a Django project: render the editor in a template, persist content to a view with CSRF, store the project JSON, and export HTML/CSS.
Browse Plugin Categories
Jump directly to plugin category pages on the marketplace.