Skip to content

Only compile arbitrary values ending in ] #15503

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

Merged
merged 3 commits into from
Jan 6, 2025
Merged

Conversation

RobinMalfait
Copy link
Member

This PR ensures that if you are using an arbitrary value such as bg-[red that it only compiles if it's a properly closed arbitrary value.

Currently what happens is that it assumes the ] is there, and cuts it off. This then results in the bg-[red to be compiled as:

.bg-\[red {
  background-color: re;
}

Note how the d in red is cut off. That's the assumption that the ] is there.

This PR fixes that by ensuring that the arbitrary value is properly closed.

Fixes: #15484

@RobinMalfait RobinMalfait changed the title Ensure arbitrary values end with ] Only compile arbitrary values ending in ] Dec 29, 2024
@RobinMalfait RobinMalfait marked this pull request as ready for review January 6, 2025 09:54
@RobinMalfait RobinMalfait requested a review from a team as a code owner January 6, 2025 09:54
@RobinMalfait RobinMalfait merged commit 52325a8 into next Jan 6, 2025
5 checks passed
@RobinMalfait RobinMalfait deleted the fix/issue-15484 branch January 6, 2025 11:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[v4] Arbitrary value with typo compiles
2 participants