What's the best way to let a user resize a box or ...
# compose
m
What's the best way to let a user resize a box or something with their mouse cursor? Something like column resizing in excel? I would've gone with draggable modifier, but I think this might be to complicated.
z
https://github.com/JetBrains/compose-multiplatform/tree/master/components/SplitPane/library has resizing like that, might be good to look at to see how its implemented
s
https://github.com/JetBrains/compose-multiplatform/blob/98794d337dc3d53dc885ff8118[…]mmonMain/kotlin/org/jetbrains/compose/splitpane/SplitPaneDSL.kt Looks to not be too complex how the drag modifier is used too. Thanks for the link Nicholas! It is only 2D though, if your needs also require you to adjust both vertically and horizontally too it may get a bit more tricky 😄