Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Columns in Grape Editor are hard to manipulate #7

Closed
Dahercode opened this issue May 10, 2021 · 12 comments
Closed

Columns in Grape Editor are hard to manipulate #7

Dahercode opened this issue May 10, 2021 · 12 comments

Comments

@Dahercode
Copy link
Contributor

Dahercode commented May 10, 2021

Hello Aimeos, I added grapejs to my aimeos project (Laravel), and i figured that the editor in the content section (JQADM) has a small issue : After inserting the columns, it's really hard to insert text or any content inside.

Is it a general issue ?

Thank you

@Dahercode Dahercode changed the title Columns in Grape Editor are hard to insert Columns in Grape Editor are hard to manipulate May 10, 2021
@aimeos
Copy link
Owner

aimeos commented May 10, 2021

That depends on what you think the problem is. If the column is too small, you could add more padding or add a minimum height for columns:
https://github.com/aimeos/ai-cms-grapesjs/blob/master/admin/jqadm/themes/custom.js#L418

@Dahercode
Copy link
Contributor Author

Dahercode commented May 10, 2021

That depends on what you think the problem is. If the column is too small, you could add more padding or add a minimum height for columns:
https://github.com/aimeos/ai-cms-grapesjs/blob/master/admin/jqadm/themes/custom.js#L418

Thank you, it solved the issue. I think it's better to put a bigger padding by default, the 10 px value is nearly impossible to work with (I may be wrong^^)

@aimeos
Copy link
Owner

aimeos commented May 10, 2021

A padding has the problem that is may interfere too much with the design of the frontend. Is this change enough for you?

.gjs-dashed .row, .gjs-dashed .col, .gjs-dashed [class^="col-"] {
	min-height: 3rem !important;
}

@Dahercode
Copy link
Contributor Author

Dahercode commented May 11, 2021

Understood, but it's not enough, i'm obliged to add it in .row
.row { display: flex; padding: 10px 0; width: auto; min-height: 3rem; }
The div class value is only set to "row" when the columns are not hovered (row gjs-hovered) or not selected (row gjs-selected)

@aimeos
Copy link
Owner

aimeos commented May 11, 2021

If you need more space between the row and the columns, we should use the padding instead. Is it enough to increase the row padding from 10px to 20px?

@Dahercode
Copy link
Contributor Author

Dahercode commented May 11, 2021

Indeed, i think it's enough, but, it still has a weird behaviour compared to adding "min-height".
I recorded quikcly the impact (Orginal code / Increasing padding / Adding a min-height)

@aimeos
Copy link
Owner

aimeos commented May 11, 2021

Your screenshots always shows the same image so we can't see what you mean

@Dahercode
Copy link
Contributor Author

It's a .gif (animated screenshots), you just have to wait some seconds to charge :D

@aimeos
Copy link
Owner

aimeos commented May 12, 2021

OK, can you create a pull request with the necessary changes?

@Dahercode
Copy link
Contributor Author

Sure, can you first choose beetween the last 2 behaviours ? ( With padding or min-height )

@aimeos
Copy link
Owner

aimeos commented May 12, 2021

Think, the min-height way would be preferrable

@Dahercode
Copy link
Contributor Author

Done : #8

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants