[3.0] Theme split (wave 8, part 2) — float with logical properties instead of left and right - #9569
Merged
jdarwood007 merged 1 commit intoSep 2, 2026
Conversation
This was referenced Aug 29, 2026
Merged
Closed
float: inline-start and float: inline-end follow the writing direction on their own, so a rule that uses them needs no right-to-left counterpart. This converts the 26 floats where rtl.css was doing nothing more than mirroring the value, and drops those overrides. The 26 are the ones where the override is an exact mirror: index.css and profile.css say left and rtl.css says right, or the other way round. Floats whose right-to-left value is not the mirror of the left-to-right one are left alone, because a single logical declaration cannot reproduce two different values; the same goes for the floats rtl.css adds where the base sheet has none. #post_header dt/dd shared a rule with #event_options dt/dd, and only the first pair has a mirror in rtl.css. Converting the pair together would have started mirroring the event editor, which is not mirrored today, so the rule is split and #event_options keeps a physical float with a comment saying why. Checked by recording float, clear, text-align, the inline margins and padding, and the bounding rectangle of every element on 26 pages, before and after, captured back to back so nothing else about the forum could move in between: - left-to-right: 8018 elements, the only differences are the 82 float keywords themselves. No geometry changes at all. - right-to-left: 8017 elements, 81 float keywords, and again nothing else. The keyword is expected to differ: getComputedStyle reports inline-start rather than resolving it to left or right. What matters is that every x, y, width, height, margin and padding is identical in both directions. rtl.css goes from 555 lines to 480. Signed-off-by: albertlast <mathiaspapealbert@hotmail.com>
albertlast
force-pushed
the
3.0/theme-rtl-float
branch
from
September 2, 2026 05:02
131451c to
e0e985b
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.
Description
Part 2 of wave 8 of the #7933 split.
float: inline-startandfloat: inline-endfollow the writing direction by themselves,so a rule written that way needs no right-to-left counterpart at all. This converts the
floats where
rtl.csswas doing nothing except mirroring the value, and deletes thoseoverrides.
This is the same move #9356 and #9357 made for the float/align utilities and for
dl.settings, applied to the rest of the theme.What is and is not converted
Only the 26 floats whose override is an exact mirror —
index.css,profile.cssorcalendar.csssaysleftandrtl.csssaysright, or the reverse. Those are the oneswhere one logical declaration reproduces both directions exactly.
Deliberately left alone:
single logical declaration cannot express two different values, so converting them
would change how one direction renders.
rtl.cssadds where the base stylesheet has none. Same reason.#post_header dt/ddshared a rule with#event_options dt/dd, and only the firstpair has a mirror in
rtl.css. Converting them together would have started mirroring theevent editor, which is not mirrored today, so the rule is split and
#event_optionskeeps a physical float with a comment recording why. That the event editor is unmirrored
in right-to-left looks like a real gap, but it is a behaviour change and does not belong
in a no-op PR.
How this was checked
The criterion for this part is that nothing moves, in either direction.
For every element on 26 pages I recorded
float,clear,text-align, the inlinemargins and padding, and the full bounding rectangle — before and after, captured back to
back across a stash so no other forum state could shift in between.
floatkeywordfloatkeywordNo geometry changed anywhere — not one x, y, width, height, margin or padding.
The keyword itself is expected to differ:
getComputedStylereportsinline-startrather than resolving it back to
leftorright. The geometry is the part that provesthe rendering is untouched.
Worth recording for anyone repeating this: a first attempt showed six extra differences
on the board index, all on the "Users online" line. That was the online-member count
changing between captures, not the CSS — the element's right edge and its
<strong>child were identical and only the text width moved. Capturing the pair back to back makes
it go away.
rtl.cssgoes from 555 lines to 480.Issues References (Fixes|Related|Closes)
Related to #7933.
On the ordering of these four
These were originally stacked. They are not any more — each of #9569, #9570, #9571 and
#9572 now branches from
release-3.0on its own and contains exactly one commit, so eachdiff shows only its own property and nothing else. They can be reviewed in any order.
They cannot all be merged without a rebase in between, and that is worth being straight
about. One
rtl.cssrule usually mirrors several properties at once, so these PRs editsome of the same declaration blocks.
release-3.0has:#9569 removes both
floats, #9570 removes thetext-align, #9571 removes theclear—and a rule only disappears once its last declaration is gone. Merging any one of these is
fine; after that I will rebase the rest, which is a few minutes of work each time. Of the
six pairs,
text-align+clearandclear+margins merge cleanly as they stand; thefloatone overlaps with all three, so merging that one first costs the least.