grapesjs icon indicating copy to clipboard operation
grapesjs copied to clipboard

[QUESTIONS] Stop the style manager from replacing AUTO with the pixel units

Open adamwpe opened this issue 7 years ago • 3 comments

Not too sure how to explain it, but it appears that the style manager replaces 'AUTO' with the actual units. But if the user changes a value, e.g. margin-top. It saves the units, not the 'AUTO' value within the other fields that were not amended. Meaning the behavior of the div is unexpectedly different. e.g. no longer centered when the canvas is resized.

Example:

Before amending top-margin (centered on a small screen): image

Before amending top-margin (centered on a largescreen): image

Amending only the top-margin field: image

Resize the canvas (ideally, the right and left margin should still be set to AUTO: image

Is the expected behavior and is there anything I can do to prevent it?

adamwpe avatar Jun 07 '19 20:06 adamwpe

One of my settings was incorrect during testing.

adamwpe avatar Jun 09 '19 12:06 adamwpe

Hi @adamwpe

I have the exact same issue. What setting did you change to solve this?

Thanks & best regards

danielwirz avatar Nov 05 '20 11:11 danielwirz

@adamwpe

I have the same issue. How did you solve it?

AnnaSu avatar Jan 27 '21 04:01 AnnaSu