fix(ui): prevent long usernames from overflowing Edit User modal, User Preview modal, and sidebar (#25185)

Long usernames overflow the Edit User modal, User Preview modal header,
and the sidebar user area because the flex containers lack width
constraints.

- EditUserModal: add min-w-0 to the flex-1 container so the existing
  truncate class takes effect
- UserPreviewModal: add min-w-0 and truncate to the title container,
  flex-shrink-0 to the close button so it stays visible
- Sidebar: add truncate to the username display and flex-shrink-0 to
  the avatar container to prevent it from being squeezed
This commit is contained in:
G30 authored and GitHub committed 2026-05-31 14:51:56 -07:00
1 parent c428ad0c1a
commit c665d4a7c6
4 files changed
+6 -6

No files matched your search

@@ -35,14 +35,14 @@
<Modal size="md" bind:show>
<div>
<div class=" flex justify-between dark:text-gray-100 px-5 pt-4 mb-1.5">
<div class=" text-lg font-medium self-center font-primary">
<div class=" text-lg font-medium self-center font-primary min-w-0 truncate">
{$i18n.t('User Preview')}
{#if userName}
<span class="text-sm font-normal text-gray-500 ml-1">{userName}</span>
{/if}
</div>
<button
class="self-center"
class="self-center flex-shrink-0"
on:click={() => {
show = false;
}}