Skip to content
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

Fix component replacement with a composable that has layout and DesignCompose children #903

Open
rylin8 opened this issue Mar 27, 2024 · 1 comment
Assignees
Labels
❗ P1 Priority for next release layout
Milestone

Comments

@rylin8
Copy link
Collaborator

rylin8 commented Mar 27, 2024

When performing a component replacement on a node with a composable that has layout such as Row() or Column(), and the children of the Row() or Column() are DesignCompose generated composables, those children have the wrong layout. The children take the LocalCompositionParentLayout info from the replacement node, causing them all to resize to the size of that node.

@rylin8 rylin8 added the layout label Mar 27, 2024
@rylin8 rylin8 added this to the 0.25 milestone Mar 27, 2024
@rylin8 rylin8 self-assigned this Mar 27, 2024
@rylin8 rylin8 added the ❗ P1 Priority for next release label Mar 27, 2024
@rylin8 rylin8 modified the milestones: 0.25, 0.26 Mar 28, 2024
@rylin8
Copy link
Collaborator Author

rylin8 commented Mar 28, 2024

Unfortunately we currently don't have a good solution to this, but will work on a fix in a future release. The problem is that DesignCompose calculates layout for all nodes, and replacing a component with a custom composable that does its own layout such as a Row or Column will conflict with the DesignCompose calculated layout. We support Row and Column custom content using our list widget.

@iamralpht iamralpht modified the milestones: 0.26, 0.27 Apr 17, 2024
@iamralpht iamralpht modified the milestones: 0.27, 0.28 May 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
❗ P1 Priority for next release layout
Projects
Status: Todo
Development

No branches or pull requests

2 participants