fix(wardrobe): keep item detail actions visible with long names - #196
Open
salah153 wants to merge 1 commit into
Open
fix(wardrobe): keep item detail actions visible with long names#196salah153 wants to merge 1 commit into
salah153 wants to merge 1 commit into
Conversation
Reviewer's guide (collapsed on small PRs)Reviewer's GuideAdjusts responsive flex sizing in the item detail dialog header: wide-screen titles now yield space to a content-sized action row and truncate long names, while mobile scrolling and reachability behavior remain unchanged. File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
Contributor
|
Thanks for your first pull request to Wardrowbe! Please make sure you've read the CONTRIBUTING guide, especially the PR title format section. A maintainer will review this soon. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
The item detail dialog header drops action buttons when an item has a long
name. The edit control disappeared on my wardrobe, and a longer name took its
neighbours with it.
DialogTitlecarriedmax-w-[45%] sm:max-w-none, so fromsmup the titlehad no cap. A flex item claims its content width before a
flex-1siblingdoes, so the title took the space the actions row needed and the row
collapsed. The row hides its scrollbar too, so nothing suggests the missing
buttons are still scrolled off to the right.
The existing comment already describes this failure for narrow screens, where
a 45% cap handles it. That cap was not applied at wider breakpoints.
The fix leaves mobile behaviour alone and swaps the priority from
smup: thetitle becomes the flexible item and the actions row is sized to its content,
so every action stays visible and the name truncates.
Related Issue
No issue filed. Reproduction is in the Testing section below.
Type of Change
Checklist
No test is included. This is a Tailwind class change and I could not see an
existing suite it would fit into. Happy to add one if you have a preferred
approach for layout regressions.
Testing
Built the frontend image from this branch and ran it against the same backend
and the same item as the released build, so the only difference between the
two screenshots below is this change. The item is named
"Brandon PantBrandon PantBrandon Pant" and has nine actions available.
Test Environment
Tests Performed
are visible. Remove background, undo background removal, replace image and
edit are all pushed out of the row.
I first tried removing
sm:max-w-noneso the 45% cap applied at every width.That was not enough: the title truncated, but with every conditional action
rendered (remove background and undo background removal both present), edit
and replace-image were still clipped. Sizing the actions row to its content
from
smup is what fixes it.Screenshots (if applicable)
Before:

After:

Additional Notes
The action row keeps
overflow-x-autobelowsm, so the phone behaviour theoriginal comment protects is preserved.
Summary by Sourcery
Bug Fixes: