Search Issue Tracker
In Progress
Fix In Review for 6000.3.X
Votes
0
Found in
2022.3.63f1
6000.0.53f1
6000.1.11f1
6000.2.0b9
6000.3.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
- "Failed to load il2cpp" error when running a standalone build that uses static libraries
- Editor crashes when entering a lot of characters in the Quality name
- Multiple NullReferenceExceptions are being thrown on TMPro.TMP_MaterialManager.GetFallbackMaterial when adding a new fallback font in the Player
- Physics debugger window has no minimum width/height set
- Yellow colored text is barely visible in the TextMeshPro "Project Files GUID Remapping tool", and "Project Text Spacing Remapping tool" windows when using the Light Mode Editor theme
Add comment