Skip to content

bug: Whitespace stripped from certain CSS selectors in ionic.bundle.css #25766

@sean-perkins

Description

@sean-perkins

Prerequisites

Ionic Framework Version

  • v4.x
  • v5.x
  • v6.x
  • Nightly

Current Behavior

The minified stylesheet ionic.bundle.css has whitespace stripped in :not selectors. This leads to existing selectors such as:

ion-modal .ion-page:not(ion-nav .ion-page) {
  position: relative;

  contain: layout style;

  height: 100%;
}

to become:

ion-modal .ion-page:not(ion-nav.ion-page) {
  position: relative;

  contain: layout style;

  height: 100%;
}

Expected Behavior

Whitespace should be preserved during the minification of the CSS bundle.

Steps to Reproduce

  1. Visit the minified CSS bundle: https://cdn.jsdelivr.net/npm/@ionic/core/css/ionic.bundle.css
  2. Search for the invalid output: ion-modal .ion-page:not(ion-nav.ion-page)
  3. Observe: Selector is missing a space between ion-nav and .ion-page (as seen in the source code)

Code Reproduction URL

N/A

Ionic Info

N/A

Additional Information

No response

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions