Skip to content

Media queries are not merged together #1677

@hteumeuleu

Description

@hteumeuleu

On the latest Maizzle (Framework v5.4.0, CLI v2.0.0), with the base starter, I add the following style in the existing <style> in layouts/main.html:

<style>
    @tailwind components;
    @tailwind utilities;

    img {
      @apply max-w-full align-middle;
    }

    @layer utilities {
      .hidden {
        @apply sm:w-[100px];
      }
    }
</style>

npm run build then turns it into this:

<style>
    @media (max-width: 600px) {
      .hidden {
        width: 100px;
      }
    }
    .hover-bg-slate-800:hover {
      background-color: #1e293b !important;
    }
    @media (max-width: 600px) {
      .sm-p-6 {
        padding: 24px !important;
      }
      .sm-px-4 {
        padding-left: 16px !important;
        padding-right: 16px !important;
      }
      .sm-px-6 {
        padding-left: 24px !important;
        padding-right: 24px !important;
      }
    }
</style>

My expectation would be for the two (max-width: 600px) media queries to be merged in a single one.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions