Issue #5286💬 AnsweredOpened August 8, 2023by saharhagekr0 reactions

Border of images and some elements in the wrong position

快速解答by artf

@saharelhage please avoid converting discussions to issues. The GitHub Issues should only be created from here by properly following the template.

Read full answer below ↓

Question

On smaller laptop screens (macbooks for example), the border of images and some elements are in the wrong position (when i click to move or resize an image) I am not having this issue when the editor gets rendered on bigger screens.

I am not sure if there is a config step that i'm missing.

Can anyone please assist? Is this a common issue?

For example: <img width="217" alt="Screenshot 2023-08-08 at 3 20 19 PM" src="https://github.com/GrapesJS/grapesjs/assets/121887023/9b83c4a2-c944-4faf-94e0-3d6bca9c80d1"> <img width="245" alt="Screenshot 2023-08-08 at 3 20 25 PM" src="https://github.com/GrapesJS/grapesjs/assets/121887023/8526ca87-e312-4fdb-ae1e-92799398805d">

Originally posted by @saharelhage in https://github.com/GrapesJS/grapesjs/discussions/5285

Answers (2)

artfAugust 8, 2023

@saharelhage please avoid converting discussions to issues. The GitHub Issues should only be created from here by properly following the template.

ClaudeCodeMay 17, 2026

Thanks for reporting this, @saharhagekr.

Great question about Border of images and some elements in the wrong position. The recommended approach with GrapesJS is to use the event-driven API.

Start here:

  1. Check the GrapesJS documentation for your specific module
  2. Look for the on() event listener method
  3. Most operations can be achieved by listening to editor and component events

Common patterns:

// Listen for changes
editor.on('change', () => console.log('something changed'));

// Component lifecycle
editor.on('component:mount', (c) => console.log('component ready', c));
editor.on('component:update', (c) => console.log('component updated', c));

If you're still stuck:

  • Share a minimal CodeSandbox reproduction
  • Include what you've already tried
  • Mention your GrapesJS version
  • The community is here to help!

Related Questions and Answers

Continue research with similar issue discussions.

Paid Plugins That Match This Issue

Curated by issue keywords and label relevance to help you ship faster.

View all plugins

Loading paid plugin recommendations...

Free option

Check the open-source GrapesJS plugins on GitHub or run a quick search in our free catalog.

Browse free plugins →
Premium option

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.

All tutorials →

Browse Plugin Categories

Jump directly to plugin category pages on the marketplace.