Make WordPress Core

Opened 3 weeks ago

Closed 13 days ago

#63260 closed defect (bug) (duplicate)

Long user display names overflow in media modal (grid view)

Reported by: sainathpoojary's profile sainathpoojary Owned by:
Milestone: Awaiting Review Priority: normal
Severity: normal Version:
Component: Media Keywords: has-patch
Focuses: ui, css Cc:

Description

When clicking on a media item in grid view in the Media Library, the edit modal opens. If the author of the media has a very long, unbroken display name (e.g., ThisDisplayNameIsUnreasonablyLongAndBreaksTheModalLayout), the name overflows its container in the modal.

This affects the “Uploaded by” field, causing layout issues in the modal UI.

Related to #63243

Steps to Reproduce:

  1. Create a user with a long, unbroken display name, e.g.: ThisDisplayNameIsUnreasonablyLongAndBreaksTheModalLayout
  2. Log in as that user.
  3. Go to "Users" → "Profile" and set "Display name publicly as" to the long name.
  4. Navigate to "Media" → "Library", switch to grid view.
  5. Upload a media file.
  6. Click on the uploaded media to open the edit modal.
  7. Observe that the "Uploaded by" field overflows or breaks the modal layout.

Environment

  • WordPress: 6.9-alpha-60093-src
  • PHP: 8.2.28
  • Server: nginx/1.27.4
  • Database: mysqli (Server: 8.4.4 / Client: mysqlnd 8.2.28)
  • Browser: Chrome 135.0.0.0
  • OS: macOS
  • Theme: Twenty Twenty-Five 1.1
  • MU Plugins: None activated
  • Plugins: Test Reports 1.2.0

Screenshot

https://rioudcpuyg.ufs.sh/f/PL8E4NiPUWyOpGA53OaQVMXblTwtAz0NaoWOrjEIdxin63gS

Change History (7)

This ticket was mentioned in PR #8673 on WordPress/wordpress-develop by @sainathpoojary.


3 weeks ago
#1

  • Keywords has-patch added

Fixes a layout issue in the media modal where long, unbroken user display names can overflow the "Uploaded by" field. This applies word-wrap: break-word; to .attachment-info .uploaded-by to ensure the layout remains intact.

Trac ticket: #63260

Before:
https://github.com/user-attachments/assets/368c40de-57fd-4c9f-9d78-730672aca2fc

After:
https://github.com/user-attachments/assets/6d5067db-8a94-4a05-abba-10fa31664f83

#2 @audrasjb
3 weeks ago

  • Severity changed from minor to normal
  • Version trunk deleted

I recommend to address this issue in the related ticket: #63243

#3 @sainathpoojary
3 weeks ago

Thanks for the heads up, @audrasjb! I’ll move the modal related fix over to ticket #63243 and consolidate everything there since they’re all related to long display names affecting layout.

Appreciate the guidance!

#4 @sainathpoojary
3 weeks ago

Hey @audrasjb, I have address this issue in PR #8658

This ticket was mentioned in Slack in #core-test by oglekler. View the logs.


13 days ago

#6 @oglekler
13 days ago

To avoid confusion, move the conversation to #63243 as recommended above. Thank you!

#7 @SirLouen
13 days ago

  • Resolution set to duplicate
  • Status changed from new to closed

Duplicate of #63243.

Note: See TracTickets for help on using tickets.