GithubHelp home page GithubHelp logo

Comments (8)

blaiz avatar blaiz commented on July 28, 2024 1

Here's a PR written by my coworker that fixes the current issue

from compass-mixins.

blaiz avatar blaiz commented on July 28, 2024

We're having the exact same issue here. We were able to fix all the instances in our own code by wrapping divisions with calc() but we can't fix the warnings related to compass-mixins since it's in node_modules. Could the fix be as simple as wrapping those in calc()? I could open a PR if that's the case.

from compass-mixins.

hiratsuka-r avatar hiratsuka-r commented on July 28, 2024

@blaiz
Thank you for your comment.

Could the fix be as simple as wrapping those in calc ()?

Yes, that's right. The official page also says:

This deprecation does not affect uses of / inside calc () expressions.

Alternatively, users can wrap division operations inside a calc() expression, which Sass will simplify to a single number.
// WRONG, will not work in future Sass versions.
@debug (12px/4px); // 3

// RIGHT, will work in future Sass versions.
@debug calc(12px / 4px); // 3

https://sass-lang.com/d/slash-div
We apologize for the inconvenience, but we would be grateful if you could fix it.

from compass-mixins.

hiratsuka-r avatar hiratsuka-r commented on July 28, 2024

I got the following warning:

Deprecation Warning: Using / for division outside of calc() is deprecated and will be removed in Dart Sass 2.0.0.

32 │ $base-rhythm-unit: $base-line-height / $base-font-size * $font-unit;
   │                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    node_modules/compass-mixins/lib/compass/typography/_vertical_rhythm.scss 32:20  @import


36 │ $base-leader: ($base-line-height - $base-font-size) * $font-unit / $base-font-size;
   │               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    node_modules/compass-mixins/lib/compass/typography/_vertical_rhythm.scss 36:15  @import


40 │ $base-half-leader: $base-leader / 2;
   │                    ^^^^^^^^^^^^^^^^
    node_modules/compass-mixins/lib/compass/typography/_vertical_rhythm.scss 40:20  @import


120 │   $rhythm: $font-unit * ($lines * $base-line-height - $offset) / $font-size;
    │            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    node_modules/compass-mixins/lib/compass/typography/_vertical_rhythm.scss 120:12  rhythm()

Maybe there are other things I missed.
I'm not confident ..., but I also get the source and are looking for parts to repair.

from compass-mixins.

Igosuki avatar Igosuki commented on July 28, 2024

Could you please submit a PR with the changes ? Thanks

from compass-mixins.

blaiz avatar blaiz commented on July 28, 2024

from compass-mixins.

hiratsuka-r avatar hiratsuka-r commented on July 28, 2024

I don't get any warnings at hand.

Pushing to github.com:Igosuki/compass-mixins.git
ERROR: Permission to Igosuki/compass-mixins.git denied to hiratsuka-r.
fatal: Could not read from remote repository.

Please add to the team with write access to the repository.
↑ It doesn't matter if it's temporary.

from compass-mixins.

hiratsuka-r avatar hiratsuka-r commented on July 28, 2024

@blaiz @SiriVadlapudi
I'm sorry it took a long time
Thank you for the fix! I checked the contents of the pull request.

There was only one difference from what I fixed. I made a comment.
Please check them when you have time.

from compass-mixins.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.