• Resolved retrovertigo

    (@retrovertigo)


    Hi there,

    It seems that having any selector inside a css @container query breaks the inlining of the styles applied to the block editor (.editor-styles-wrapper) via the add_editor_style( 'style-editor.css' ); file.

    The CSS from style-editor.css does simply not get applied at all. Removing all @container queries fixes that issue (but obviously leaves me without that code).

    This is the minimum test case where the issue appears

    @container  {
      .selector {}
    }

    Note: Without the .selector the query gets ignored and the styles are getting applied.

    Is there any known way around this issue besides removing all @container queries?

    I have a file which gets auto-generated alongside my style.css and having to revert my code to work without the @container queries would be a bit of a blow.

    Many thanks,
    Albert

    • This topic was modified 3 years, 1 month ago by retrovertigo.
    • This topic was modified 3 years, 1 month ago by retrovertigo. Reason: add link to MDN
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)

The topic ‘css @container queries break block editor styles’ is closed to new replies.