feat(board): size a worded copy chip to its label, not to the icon square - #314
Merged
Conversation
…uare `button.copy` is a fixed 2.6rem square, which is exactly right for a bare clipboard glyph and a trap for a button that carries words: the label wraps inside 42px into a one-word-per-line column and spills out of its own box. Reported from a laptop against the health board's "clear them all" line, the one place in the family that gives a copy button a worded face. `button.copy.text` sizes to the label and holds it on one line the way `.pill` does — elided rather than allowed to push the page sideways. Opt-in, so every bare-glyph button in every board keeps the square it was drawn for. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_018q6ZrgG6u8o8ENYZ7cq3Lr
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.
Reported from a laptop against the health board: under the Evidence gaps heading, the one-tap clear them all button reads as a thin column of text.
The cause
button.copyis a fixed 2.6rem square — exactly right for the bare clipboard glyph every board puts beside a row, and a trap for a button that carries words. At 42px wide the label wraps to one word per line and overflows its own 42px height.Every sibling board emits only the bare glyph, so the health board — the one place in the family that gives a copy button a worded face — is where it showed up.
The fix
An opt-in modifier beside the existing
button.copy.term:Sized to the label, held on one line the way
.pillis — elided rather than allowed to push the page sideways, with the samevertical-align:bottomthatoverflow:hidden's baseline shift needs. Being opt-in, every bare-glyph button in every board keeps the square it was drawn for.Verification
pytest tests/test_board_theme.py tests/test_board.py tests/test_intake_dashboard.py→ 141 passed.repos_sync.py --check --only "tenant firewall (organ code)").Companion: PyAutoLabs/PyAutoHeart#192 adds the class at the two call sites. Either order is safe — the class without the rule renders exactly as today.
🤖 Generated with Claude Code
https://claude.ai/code/session_018q6ZrgG6u8o8ENYZ7cq3Lr