-
-
Notifications
You must be signed in to change notification settings - Fork 4k
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
Replace depreciated division operator with math.div function #3336
Conversation
Signed-off-by: Thomas Citharel <[email protected]>
Signed-off-by: Thomas Citharel <[email protected]>
Signed-off-by: Thomas Citharel <[email protected]>
Signed-off-by: Thomas Citharel <[email protected]>
Signed-off-by: Thomas Citharel <[email protected]>
Signed-off-by: Thomas Citharel <[email protected]>
Maybe some of those could use multiplication instead of a division. It would be compatible with older libsass while removing a lot of deprecation warning for dart. Ex. margin-right: $block-spacing / 2 Would become: margin-right: $block-spacing * 0.5 Instead of: margin-right: math.div($block-spacing, 2) |
@service-paradis but if it only applies to "some", then measures still need to be taken for those cases where division cannot be replaced by multiplication. (And it therefore would not make too much sense, replacing division by multiplication some of the cases.) |
Sure, but it would (at least) reduce some of the warning waiting for a solution. Another way to reduce the number of warnings would be to create a custom function like: @function bulmaDivide($number, $div)
@return $number / $div A single warning would be issued and it would be easier to replace with |
in latest version |
The warning are annoying and I'm glad |
Bootstrap have a PR around this problem that might be a goop option for Bulma as well: |
Closed in favor of #3362 |
This is a bugfix.
It requires #3335 and will fix #3333, by replacing uses of the depreciated division operator.
Proposed solution
Replace uses of the division operator with the
math.div
function.Tradeoffs
Main drawback is that Bulma now requires
sass >= 1.33
to be build and used. Earlier versions ofsass
won't be able to build andnode-sass
won't be either. Since this is a very hard change, I'd recommend waiting as long as possible before merging and releasing this¹.Testing Done
Build the documentation and quick check for UI issues
Changelog updated?
Will do after #3335 is merged.
¹ The depreciated message from
sass
is quite annoying, however.