fix(ui): put the mobile notification checkbox in the title line - #3620
Closed
MattDHill wants to merge 1 commit into
Closed
fix(ui): put the mobile notification checkbox in the title line#3620MattDHill wants to merge 1 commit into
MattDHill wants to merge 1 commit into
Conversation
840019c reordered the mobile row layout — title from grid row 2 to row 1, message to row 2, date to row 3 — but the checkbox kept its hard-coded `top: 2.875rem`, an offset tuned to the title sitting on row 2. In selection mode the icon blanks at the top of the card while the checkbox floats 22-24px lower, over the first line of the message. Project the checkbox into `.title` ahead of the icon instead, so on mobile it is an in-flow flex item and `.title`'s `align-items: center` places it — the same rule that places the icon it stands in for. The two swap via `display`; both are 1rem behind the same gap, so nothing on the card moves. Desktop keeps absolute positioning, now anchored to the row rather than to the date cell the checkbox no longer lives in. That commit also pinned `.service` to grid row 1, so a service avatar makes the title row 32px against 27.4px without one. No single offset could have been right for both, and there is no offset constant left to go stale. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Member
Author
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.
Summary
On a phone, selecting notifications draws the checkboxes over the message text instead of in the notification icon's place on the title line.
840019c60reordered the mobile row grid initem.component.ts— title from grid row 2 to row 1, message to row 2, date to row 3 — and pinned.serviceto row 1.table.component.tskept the checkbox's hard-codedtop: 2.875rem, an offset tuned to the title sitting on row 2, so the checkbox now lands 22–24px low, on the first line of the message, while the icon it stands in for blanks out at the top of the card. It shipped in 0.4.0 and is still in 0.4.0.1; 0.4.0-beta.9 was the last release without it.Rather than retune the constant, the checkbox now lives in the title line:
<ng-content />moves from the date cell into.title, ahead of<tui-icon>. On mobile it becomes an in-flow flex item, so.title's existingalign-items: centerplaces it — the same rule that places the icon.displayrather thanopacity. Both are 1rem behind the same 0.375rem gap, so nothing on the card moves as selection turns on.:host-context(tui-root:not(._mobile))) and anchored to the row rather than the date cell the checkbox no longer sits in, so mobile has nothing to undo.No offset constant survives, so a future change to the row layout can't reintroduce this. That matters here beyond tidiness: because
.serviceis now pinned to grid row 1, a service avatar makes the title row 32px against 27.4px without one, so no single offset would have been correct for both kinds of notification.Verified against a static harness reproducing the component's DOM and Taiga's metrics: checkbox and icon land at identical coordinates both with an avatar (y=16.0) and without (y=13.7), and the title text starts at the same x whether or not selection is active. Desktop is unchanged apart from a 0.5px horizontal shift — the collapsed-border half-pixel from anchoring to the row rather than the cell.
npm run check:uiand prettier are clean.Credit
@BeeJoe found and reported this regression and proposed a fix in #3616. This supersedes that PR with a different approach, but the diagnosis there is what pointed at these two files.
Deliberately not included
No 0.4.0.2 bump and no changelog entry. #3616 and #3617 each already add their own
shared-libs/crates/start-core/src/version/v0_4_0_2.rsand bump the manifest, so those two conflict with each other as things stand — whichever lands first should carry the plumbing for the release.🤖 Generated with Claude Code