Skip to content

SASS changes in mixed declarations #1952

@stefanv

Description

@stefanv

When compiling the style files from PDST using dart-sass, it emits warnings related to changes is how SASS will deal in the future with mixed declarations.

Short story, before a declaration like:

.example {
  color: red;

  a {
    font-weight: bold;
  }

  font-weight: normal;
}

Would pull font-weight to the top of .example, and define a font-weight after. Now, they leave the ordering alone.

At least the following cases are present in PDST:

_color.scss:349
_breadcrumbs.scss:30
_admonitions.scss:49
_admonitions.scss:52
_quotes.scss:24
_tables.scss:46

The workaround? As Dart Sass reports:

To keep the existing behavior, move the declaration above the nested
rule. To opt into the new behavior, wrap the declaration in & {}.

Metadata

Metadata

Assignees

No one assigned

    Labels

    needs: more informationNeeds more information from the author before we can move forwardtag: CSSCSS and SCSS related issues

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions