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

Variable for subtract .02px #41192

Open
2 tasks done
illycz opened this issue Jan 30, 2025 · 5 comments · May be fixed by #41195
Open
2 tasks done

Variable for subtract .02px #41192

illycz opened this issue Jan 30, 2025 · 5 comments · May be fixed by #41195

Comments

@illycz
Copy link

illycz commented Jan 30, 2025

Prerequisites

Proposal

Switching px to em for media queries.

Motivation and context

When I want to switch units from px to em, I will also need convert 0.02 (for px) to 0.00125 (for em) in breakpoint-max function which is now hardcoded.

What do you think?

@illycz illycz added the feature label Jan 30, 2025
@julien-deramond
Copy link
Member

Just to be sure to understand the request, you'd like a new Sass variable set to .02 so you can override it on your side, instead of the following?

@return if($max and $max > 0, $max - .02, null);

@illycz
Copy link
Author

illycz commented Jan 30, 2025

Yes, exactly.

@julien-deramond julien-deramond moved this to Needs review in v5.4.0 Jan 30, 2025
@julien-deramond julien-deramond linked a pull request Jan 30, 2025 that will close this issue
4 tasks
@julien-deramond
Copy link
Member

I don’t mind making it customizable via a Sass variable. I’ve proposed a solution in #41195—let’s see what the other core team members think! 🙂

@mdo
Copy link
Member

mdo commented Jan 31, 2025

Do we still need this at all? Feel like #41046 was hinting at not needing it.

@illycz
Copy link
Author

illycz commented Feb 1, 2025

@mdo Yes, I know about that, but it's planned for v6.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Needs review
Development

Successfully merging a pull request may close this issue.

3 participants