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

Passing percentage units to the global abs() function is deprecated #5073

Open
WissamProgress opened this issue Jun 11, 2024 · 0 comments
Open
Labels
Bug Something isn't working

Comments

@WissamProgress
Copy link

Describe the bug
When building a project that has kendo-themes, the following warning appears:

DEPRECATION WARNING: Passing percentage units to the global abs() function is deprecated.
In the future, this will emit a CSS abs() function to be resolved by the browser.
To preserve current behavior: math.abs(-80%)
To emit a CSS abs() now: abs(#{-80%})
More info: https://sass-lang.com/d/abs-percent

  ╷
8 │     @return abs( $number );
  │             ^^^^^^^^^^^^^^
  ╵
    ..\node_modules\@progress\kendo-theme-core\scss\functions\_math.import.scss 8:13                 k-math-abs()
    ..\node_modules\@progress\kendo-theme-core\scss\functions\_color-manipulation.import.scss 18:13  k-color-level()
    ..\node_modules\@progress\kendo-theme-core\scss\functions\_color-manipulation.import.scss 38:13  k-color-tint()
    ..\node_modules\@progress\kendo-theme-core\scss\functions\_color-manipulation.import.scss 83:13  k-try-tint()
    ..\node_modules\@progress\kendo-theme-core\scss\functions\_color-variations.import.scss 33:82    k-generate-color-variations()
    src\app.scss 6:43          

based on their docs, one possible solution would be to replace it with math.abs
https://sass-lang.com/documentation/breaking-changes/abs-percent/

The other option would be to not use percentage values.

Percentage values in abs is used in the below two files:

https://github.com/telerik/kendo-themes/blob/develop/packages/core/scss/functions/_color-manipulation.import.scss

https://github.com/telerik/kendo-themes/blob/develop/packages/core/scss/functions/_math.import.scss

To reproduce

Build a React project for production that includes kendo-themes.

Expected behavior
Deprecated methods are not used.

Affected package

  • theme-default
  • theme-bootstrap
  • theme-material
  • theme-tasks

Affected suites (please remove the unneeded items)

  • Kendo UI for React (possibly all of them, but it was reproduced in KendoReact)

Reported in Ticket ID: 1654744

@WissamProgress WissamProgress added the Bug Something isn't working label Jun 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant