sort: order early utility families by canonical rank#121
Merged
Conversation
tw emitted visibility, z-index, order, container and box-sizing out of Tailwind's canonical family order, drifting their rule positions from the reference sheet. Utility priority becomes per-variant (priority : t -> int) so families that share a handler module - layout's display/visibility/z-index, flex_props' order/flex - can occupy their distinct canonical slots.
samoht
force-pushed
the
fix-family-sort-order
branch
from
July 13, 2026 04:35
826a6c2 to
4dddd24
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR makes utility priority per-variant (
Utility.Handler.priority : t -> int) and uses it to place visibility, z-index,order, container and box-sizing in Tailwind's canonical family order.tw emitted these families out of order relative to the Tailwind reference: visibility (canonical rank 0) and z-index (rank 12) were lumped into
layout.ml's display-family priority,ordersat inflex_propsafter sizing, and container/box-sizing sorted ahead of grid-column/margin. Priority was a single per-module constant, so families sharing a handler could not occupy distinct canonical slots; making it per-variant lets layout's visibility/z-index and flex_props'ordersort into their own positions while the rest of each module stays put. The remaining mid- and late-section families are a separate, larger renumber left for a follow-up.