Skip to content

fix(ui): THI-346 — dropdown menu avatar, scrollbar redondante (suppression cap 440px)#373

Merged
thierryvm merged 1 commit into
mainfrom
feat/THI-346-dropdown-scroll
Jun 4, 2026
Merged

fix(ui): THI-346 — dropdown menu avatar, scrollbar redondante (suppression cap 440px)#373
thierryvm merged 1 commit into
mainfrom
feat/THI-346-dropdown-scroll

Conversation

@thierryvm

Copy link
Copy Markdown
Owner

THI-346 — Scroll du dropdown menu avatar (follow-up THI-341)

Bug @Thierry (2× signalé) : le dropdown du menu avatar affichait une scrollbar qui double celle de la sidebar Modules → visuellement cassé.

Cause : le fix anti-clip F-02 de THI-341 utilisait max-h-[min(440px,calc(100dvh-200px))]. Pour un super_admin, le menu fait ~454px (header + 8 items à py-3), juste au-dessus du cap 440px → scrollbar systématique sur tous les viewports (les rôles avec moins d'items ne scrollaient pas).

Fix (1 ligne, 2 dropdowns) : retirer le cap fixe 440pxmax-h-[calc(100dvh-200px)]. Le dropdown prend sa taille naturelle et ne scrolle que quand il ne tient vraiment pas (écrans courts), tout en gardant le filet anti-clip.

Voie A empirique (super_admin, 8 items)

Format Scroll dropdown Débordement
1280×800 (desktop) ✅ aucun ✅ fits
768×1024 (tablette) ✅ aucun ✅ fits
390×844 (mobile) ✅ aucun ✅ fits
1280×600 (écran court) scroll sécurité (nécessaire) ✅ fits, pas de clip

Screenshot desktop : .tmp/thi346-dropdown-desktop.png (8 items, 0 scrollbar interne).

type-check + lint clean, auth.test 16/16 (UserMenu, inchangés). Gate mobile-responsive-auditor en cours.

🤖 Generated with Claude Code

THI-341's anti-clip fix used max-h-[min(440px,calc(100dvh-200px))]. For a
super_admin the menu is ~454px (header + 8 items at py-3), just above the 440px
cap → a redundant scrollbar appeared on EVERY viewport and doubled the sidebar
modules scrollbar (visual bug reported by @Thierry).

Drop the fixed 440px cap → max-h-[calc(100dvh-200px)] alone: the dropdown takes
its natural height and only scrolls when it genuinely can't fit (short screens),
preserving the anti-clip safety net.

Voie A (super_admin, 8 items): no scroll at 1280×800 / 768×1024 / 390×844,
safety scroll without clipping at 1280×600. auth.test 16/16 unchanged.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry @thierryvm, you have reached your weekly rate limit of 500000 diff characters.

Please try again later or upgrade to continue using Sourcery

@vercel

vercel Bot commented Jun 4, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
terminal-learning Ready Ready Preview, Comment Jun 4, 2026 5:26pm

@thierryvm thierryvm merged commit dc320cb into main Jun 4, 2026
4 checks passed
@thierryvm thierryvm deleted the feat/THI-346-dropdown-scroll branch June 4, 2026 17:45
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