Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Strict unary deprecation in Sass #17593

Closed
2 tasks done
frankharkins opened this issue Sep 27, 2024 · 0 comments · Fixed by #17595
Closed
2 tasks done

[Bug]: Strict unary deprecation in Sass #17593

frankharkins opened this issue Sep 27, 2024 · 0 comments · Fixed by #17595
Labels
package: styles @carbon/styles severity: 3 https://ibm.biz/carbon-severity type: bug 🐛

Comments

@frankharkins
Copy link
Contributor

Package

@carbon/styles

Browser

No response

Package version

1.66.0

React version

18.2.0

Description

I get this warning when building:

DEPRECATION WARNING on line 128, column 20 of ../../node_modules/@carbon/styles/scss/components/modal/_modal.scss: 
This operation is parsed as:

    -$spacing-05 - $spacing-05

but you may have intended it to mean:

    -$spacing-05 (-$spacing-05)

Add a space after - to clarify that it's meant to be a binary operation, or wrap
it in parentheses to make it a unary operation. This will be an error in future
versions of Sass.

More info and automated migrator: https://sass-lang.com/d/strict-unary
    ╷
128 │     margin-inline: -$spacing-05 -$spacing-05;
    │                    ^^^^^^^^^^^^^^^^^^^^^^^^^
    ╵

I'm using Sass 1.69.7

Reproduction/example

https://codesandbox.io/p/devbox/practical-bush-ywp9pq

Steps to reproduce

Open the CodeSandbox link and run the following in a terminal.

npm install && sass --load-path=./node_modules style.scss output.css

Suggested Severity

Severity 4 = Unrelated to a user task, has a workaround or does not need a workaround.

Application/PAL

No response

Code of Conduct

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
package: styles @carbon/styles severity: 3 https://ibm.biz/carbon-severity type: bug 🐛
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

2 participants