Skip to content

Fold a post card's tag chips after five - #1967

Merged
wintermeyer merged 1 commit into
mainfrom
worktree-5-tags
Sep 3, 2026
Merged

Fold a post card's tag chips after five#1967
wintermeyer merged 1 commit into
mainfrom
worktree-5-tags

Conversation

@wintermeyer

Copy link
Copy Markdown
Owner

A card in the feed could spend four lines on tag pills before you reached the post under it. A member is capped at five tags by the composer, so the long rows come from the Fediverse: of 6,390 cached posts, 2,641 close with a hashtag line and 847 of those name more than five — the longest 32.

A timeline card now shows five chips and folds the rest behind a native <details> "+N" pill; the permalink still shows every tag, since that page is the one post. Six get no control, because a "+1" pill costs the row what the chip it hides costs. Long tag names truncate (a tag may run to 255 characters; the longest here is 69) with the whole name in the title.

No JavaScript: <details> toggles natively and data-keep-open stops a patch from folding it shut. See tag_row/1 in VutuvWeb.PostComponents. Hot deploy.

An AI agent wrote this text in my name. I know that is problematic.

https://claude.ai/code/session_01GoRFwMYaLrAGRLgTAtKwnd

Ein Beitrag aus dem Fediverse schließt mit so vielen Hashtags, wie sein
Autor mochte: von 6.390 zwischengespeicherten Beiträgen tragen 2.641 eine
Schlusszeile, 847 davon nennen mehr als fünf Tags, der längste 32. Das
sind vier Zeilen Pillen zwischen einem Beitrag und dem nächsten. Eine
Timeline-Karte zeigt jetzt fünf und legt den Rest hinter ein natives
<details>; der Permalink zeigt weiter alle, denn diese Seite IST der eine
Beitrag. Sechs lohnen keine Bedienung, weil die "+1"-Pille die Zeile
genau so viel kostet wie der Chip, den sie verbirgt.

Offen löst sich das <details> ganz auf (display: contents auf ihm und auf
::details-content), damit Pille und Tags Flex-Elemente der Chip-Zeile
werden und die Zeile fortsetzen, statt eine eigene zu bekommen: 72 statt
112 Pixel. Jeder Chip kürzt außerdem lange Namen (max-w-56 + truncate,
der ganze Name im title) - ein Tag darf 255 Zeichen haben, der längste
hier hat 69.

Diesen Text hat ein KI-Agent in meinem Namen geschrieben. Ich weiß, dass
das problematisch ist.

Claude-Session: https://claude.ai/code/session_01GoRFwMYaLrAGRLgTAtKwnd
@wintermeyer
wintermeyer merged commit 749025a into main Sep 3, 2026
1 check passed
@wintermeyer
wintermeyer deleted the worktree-5-tags branch September 3, 2026 10:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant