apostrophe icon indicating copy to clipboard operation
apostrophe copied to clipboard

Scss Mixed Declarations Warnings

Open LeviticusMaximus opened this issue 1 year ago • 1 comments

Loads of scss deprecation warnings in the console - making it pretty busy and harder to spot any other unrelated errors

Deprecation Warning: Sass's behavior for declarations that appear after nested
rules will be changing to match the behavior specified by CSS in an upcoming
version. To keep the existing behavior, move the declaration above the nested
rule. To opt into the new behavior, wrap the declaration in `& {}`.

More info: https://sass-lang.com/d/mixed-decls

    ╷
92  │ ┌   .apos-theme--primary-blue {
93  │ │     @include apos-primary-mixin(#0062ff);
94  │ │   }
    │ └─── nested rule
... │
96  │     --a-base-1: #d1d3d5;
    │     ^^^^^^^^^^^^^^^^^^^ declaration
    ╵
    apos-build/default/apos/modules/@apostrophecms/ui/scss/global/_theme.scss 96:3      @import
    apos-build/default/apos/modules/@apostrophecms/ui/scss/global/import-all.scss 11:9  root stylesheet

So I'm wondering if there's a fix to mute these warnings and/or if the Apostrophe team are planning to opt-in with the new behaviour and then release updated global scss files?

Thanks

LeviticusMaximus avatar Jul 19 '24 13:07 LeviticusMaximus

Our next release will have a fix for this. In the meantime, I think the warnings won't display if you don't rebuild the admin UI, so only with APOS_DEV=1

BoDonkey avatar Jul 19 '24 13:07 BoDonkey