Issue #896✓ SolvedOpened February 23, 2018by maxtacco4 reactions

Media query rules are overridden by class rules in canvas

Quick answerby vrudikov2

@artf Created the PR

Read full answer below ↓

Question

Hi @artf , I've noticed an issue while testing one of my templates using different device configurations that supposed to trigger media queries. My template has styles generated as following: It looks like this JSON is used to generate styles inside canvas as in this screenshot: You can see here that the '.cell' style is added last and it overrides the corresponding media query style from above and as a result it is impossible to test responsive components. So, It would be really nice if media query styles where included after their corresponding 'normal' styles to guarantee they are taken in...

Answers (3)

👍 Most helpfulvrudikovMarch 29, 2018

@artf Created the PR

artfMarch 8, 2018

Thanks for the catch guys and the great video @vrudikov, was really helpful. I'll investigate this

vrudikovMarch 19, 2018

So now we have the following structure: And you want something like this:

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.