-
Notifications
You must be signed in to change notification settings - Fork 4.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
RNMobile: Fix column horizonal layout #35479
Conversation
Size Change: 0 B Total Size: 1.07 MB ℹ️ View Unchanged
|
@@ -262,6 +262,7 @@ export class BlockList extends Component { | |||
{ flex: isRootList ? 1 : 0 }, | |||
! isRootList && styles.overflowVisible, | |||
] } | |||
horizontal={ horizontal } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unfortunately, reinstating the horizontal
prop results in a broken layout on a wider-screen devices when there are multiple columns. This may be related to #34200 (comment).
I spent a little time debugging this, attempting to find an alternative solution. Unfortunately, I was not able to find one quickly. My guess is that we will need to refactor some of the styles to achieve the end goal without reinstating the invalid flex-wrap
property.
A few things I have observed...
flex-wrap
"is not supported" byVirtualizedList
, it is recommended to usenumColumns
instead.horizontal
andnumColumns
cannot be used in tandem.- We are likely missing a
align-items: stretch
orjustify-content: stretch
somewhere, which causes the column item not to fill its parent.
If you'd rather not spend time searching for an alternative fix, it appears we could likely revert 3437ce3 as a quick fix. Doing so appears to avoid the overflowing column issue and fix the target issue of this PR. It, of course, would reinstate the warning #34200 attempted to address. I support a quick revert if that is your preference. WDYT?
Thank you for addressing this issue. 🙇🏻
I am closing this since this solution is not the one we want to go with. |
Description
This PR intendes to fix wordpress-mobile/gutenberg-mobile#4081
The regression was due to #34200.
This PR revert the fix partially.
How has this been tested?
Notice that
Screenshots
Before:
After:
Types of changes
Bug fix
Checklist:
*.native.js
files for terms that need renaming or removal).