Skip to content

fix(contrib): widen the year select so the year is not clipped to "2··" - #541

Merged
chai-inu merged 1 commit into
masterfrom
fix/contrib-year-select-width
Aug 21, 2026
Merged

fix(contrib): widen the year select so the year is not clipped to "2··"#541
chai-inu merged 1 commit into
masterfrom
fix/contrib-year-select-width

Conversation

@chai-inu

Copy link
Copy Markdown
Member

Problem

The contribution graph's year select renders the year as 2·· on every user profile, e.g. https://cha.fan/users/chai_inu.

The value is correct — textContent is "2026" — it's the box that's too small.

Cause

ContribGraphs.vue:10 carried class="max-w-80"max-width: 80px (app.scss:37). That was enough under Vuetify 2. Vuetify 3's density="compact" select spends more of that box on its own padding and the dropdown arrow, so the selection text is left with a fraction of what it needs.

Measured on the live page:

max-width text scrollWidth text clientWidth clipped
80px (current) 36 18 yes
100px 36 36 no

Fix

max-w-80max-w-100, a utility that already exists in app.scss:41. Verified in the browser at 100px — "2026" renders in full.

Another silent Vuetify 2 → 3 sizing carry-over of the kind CLAUDE.md warns about: no error, no warning, just a wrong-looking control.

Checks

  • vitest run — 161 passed (run with .env moved aside, matching CI)
  • eslint on the changed file — clean
  • vite build — succeeds
  • Verified visually in Chrome against production

🤖 Generated with Claude Code

The contribution graph's year select carried `max-w-80` (80px), which was
enough under Vuetify 2. Vuetify 3's compact select spends more of that box on
its own padding and the dropdown arrow, leaving the selection text 18px of the
36px "2026" needs -- so it renders ellipsised as "2··" on every user profile.

Measured on cha.fan: at 80px the selection reports scrollWidth 36 against
clientWidth 18; at 100px clientWidth is 36 and nothing is clipped. `max-w-100`
already exists in app.scss.

Another silent Vuetify 2 -> 3 sizing carry-over: no error, no warning, just a
wrong-looking control.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@chai-inu
chai-inu merged commit 077086a into master Aug 21, 2026
3 checks passed
@chai-inu
chai-inu deleted the fix/contrib-year-select-width branch August 21, 2026 23:31
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