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

Implement a better way to represent fractional values #140

Open
jverkoey opened this issue Aug 10, 2024 · 0 comments
Open

Implement a better way to represent fractional values #140

jverkoey opened this issue Aug 10, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@jverkoey
Copy link
Collaborator

Many Tailwind CSS utilities support expressions like 1/2 or 3/4 to represent fractional values. For Slipstream modifiers that support fractional values, Slipstream currently treats any value between 0..<1 as a potential fractional value. So 0.25 will be treated as 1/4.

This is a bit of a hack, isn't super intuitive, and unfortunately due to compiler limitations does not let the developer use the more natural 1/4 to represent the fraction.

A better solution is not immediately apparent, so I'm filing this issue to track the desire for an improvement here.

@jverkoey jverkoey added the enhancement New feature or request label Aug 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant