Custom css 'selector' for all breakpoints #23859
xmedia-nl
started this conversation in
Feature Request
Replies: 2 comments 2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment



Uh oh!
There was an error while loading. Please reload this page.
Prerequisites
What problem is your feature request going to solve? Please describe.
When adding custom css, it's always hard to get the breakpoints correct. Different websites could use different breakpoints or the breakpoints might change.
Most (non-developer) users also don't know how to write a css media queries for a display size.
Describe the solution you'd like
I found it's rather easy to extend the magic css 'selector' prefix with others. I suggest to add the breakpoints to these functions (add_post_css, add_page_settings_css in /elementor-pro/modules/custom-css/module.php)
Code change required is minimal:
This allows a user to write media queries this way, which seems users friendly to me
Describe alternatives you've considered
This could also be solved by creating a custom css area for each breakpoint, but that would make the interface messy and would require much more changes.
There was an extension that did this, but that stopped working a while ago.
Additional context
Some additional changes are required so that the editor accepts the magic tags as valid
All reactions