Issue #2128💬 AnsweredOpened July 11, 2019by leetuanIncepit0 reactions

How to add device manager mobile landscape?

快速解答by artf

Check the DeviceManager API For now, it's only possible to use a single condition (configurable via mainConfigObject.mediaCondition option, max-width is the default)

Read full answer below ↓

Question

Hi,

代码片段TEXT
Please help me add device manager mobile landscape with structure example: 
@media only screen 
  and (min-device-width: 375px) 
  and (max-device-width: 667px) 
  and (-webkit-min-device-pixel-ratio: 2)
  and (orientation: landscape) { 

}
Currently, i have device manager with structure:
@media (max-width: 480px) {

} 

Thanks

Answers (2)

artfJuly 14, 2019

Check the DeviceManager API For now, it's only possible to use a single condition (configurable via mainConfigObject.mediaCondition option, max-width is the default)

EnsaphelonSeptember 20, 2023

@artf Is there any reason why grapesjs still does not support this feature? It seems that it could be resolved just by removing mediaCondition option from the EditorConfig at all, and allowing to pass any media query for each device in the widthMedia field.

At this moment this feature is crucial to me, is there any way the result CSS could be modified? I see that there is an option to pass custom css parser but the styles related to the media queries are missing there.

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 →

Browse Plugin Categories

Jump directly to plugin category pages on the marketplace.