Skip to content

fix(cards): keep the sticker chart overflow count on one line (#1070) - #1072

Merged
tempus2016 merged 1 commit into
mainfrom
fix/1070-sticker-overflow-wrap
Oct 15, 2026
Merged

tempus2016 merged 1 commit into
mainfrom
fix/1070-sticker-overflow-wrap

Conversation

@tempus2016

Copy link
Copy Markdown
Owner

Fixes #1070

What was wrong

The sticker row on the Sticker Chart card uses word-break: break-all so the emoji wrap tightly. The overflow count after the last sticker (for example +10) inherited it, so it could split across lines: +1 at the end of the row and a stray 0 on the line below.

Fix

.overflow is now display: inline-block; white-space: nowrap; word-break: normal. The count still wraps to the next line when there is no room, but it moves as one piece. CSS only.

Testing

  • Found during the v6.4.0 release check on the dev Home Assistant: a child with 50 stickers (40 shown) showed +1 / 0.
  • Injected the new rule into the live card on the dev instance. The badge now reads +10 in one piece (checked in a screenshot).
  • node --check passes.

The sticker row uses word-break: break-all so emoji wrap tightly, and the
overflow badge inherited it, so +10 could split into +1 and a stray 0 on
the next line. The badge is now an unbreakable inline block.
@github-actions github-actions Bot added the cards Lovelace cards / frontend (www/*.js) label Oct 15, 2026
@tempus2016
tempus2016 merged commit 816b66d into main Oct 15, 2026
16 checks passed
@tempus2016
tempus2016 deleted the fix/1070-sticker-overflow-wrap branch October 15, 2026 16:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cards Lovelace cards / frontend (www/*.js)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Sticker chart: the sticker overflow count wraps onto two lines

1 participant