Issue #1537Opened October 23, 2018by hpruvot1 reactions

Duplicate component not style

Question

Hi,

First of all, thanks a lot for the awesome work ❤️ !!!

I've a question about the duplication tool so here the steps to follow :

  • I drag&drop a text component
  • I change the style (color in green, weight, size, etc...)
  • I duplicate it
  • I change the color in red BUT the original component changes in red too because they have the same class

==> So is this possible to duplicate a component (or block) with the same style/attributes but continue to edit the cloned component without impacting the original component ?

Thanks a lot in advance 🙏

Answers (3)

artfOctober 30, 20181 reactions

Hi @hpruvot I'd like to say, at first, if you clone a component with a class and you change it, you see changes on both, this is because how classes work. If you want to avoid the editor creating classes for you, use this option:

grapesjs.init({
	...
	forceClass: false,
})
hpruvotOctober 30, 20180 reactions

Oh sorry I missed that option, thanks 👌

lock[bot]October 30, 20190 reactions

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.

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...

Browse Plugin Categories

Jump directly to plugin category pages on the marketplace.