Search Issue Tracker
In Progress
Fix In Review for 6000.3.X
Under Consideration for 6000.4.X
Votes
0
Found in
2022.3.63f1
6000.0.53f1
6000.1.11f1
6000.2.0b9
6000.3.0a1
6000.4.0a1
6000.5.0a1
Issue ID
UUM-110585
Regression
No
FlexShrink fails when the first of two Label elements is set to FlexGrow="0" and the second is set to FlexGrow="1"
Reproduction steps:
1. Open the attached “IN-106329.zip” project
2. Open the “MyScene” Scene
3. From the Hierarchy, select the “GameObject”
4. In the Inspector, observe the ”MyClass (Script)” Component
5. Make the Inspector wider
6. Observe the green Label expanding while the orange one remains the same size
7. Shrink the Inspector so that it is less than 300px
8. Observe the Labels
Expected result: Both Labels start shrinking when the Width is less than 300px
Actual result: Only the green Label is shrinking and the orange remains the same size
Reproducible with: 2022.1.0a1, 2022.3.63f1, 6000.0.53f1, 6000.1.11f1, 6000.2.0b9, 6000.3.0a1
Reproducible on: Windows 11
Not reproducible on: no other environment tested
Notes:
- The core issue is that an element's flex-grow setting is incorrectly preventing it from shrinking. The 300px width is the critical point because each Label has a flex-basis of 150px (150px + 150px = 300px). The flex-shrink: 1 property on both labels means they should both shrink when the container becomes narrower than this. However, the flex-grow: 0 on the first label is incorrectly overriding this, making it a fixed size during shrinking
- The same incorrect behaviour can be reproduced using C# and a Custom Inspector, UXML and a Custom Inspector and the UI Builder. To test in the UI Builder - open the “MyUXML.asset” (Assets > Resources) and repeat the reproduction steps by narrowing the viewport
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- ”Lighting data asset ‘LightingData’ is incompatible with the current Unity version…” warnings are thrown when saving Indoors (URP) and Outdoors (URP) Scenes as Scene Templates
- [iOS] The screen blinks when transitioning from custom to Unity splash screen
- [macOS] ”Ignoring depth surface load action as it is memoryless” warnings are thrown when taking Game View Snapshot
- UI Builder Inspector scrolls back up when changes on an expanded but not fully displayed Inspector tab are saved
- Group Node name text is way smaller in the renaming state than the actual display size
Add comment