rustpad icon indicating copy to clipboard operation
rustpad copied to clipboard

Implement collapsible sidebar with smooth animation

Open ntninja opened this issue 1 year ago • 5 comments

The connection indicator was moved to the right so that it always remains visible everything else is collapsed, when pressing the new menu button. A few places use slightly different spacing to making everything work.

Unfortunately, Chakra does not provide a “Horizontal Collapsible” component (only a vertical collapsible and an horizontal overlay drawer), so a DIY approach inspired by https://v2.chakra-ui.com/community/recipes/horizontal-collapse was needed by to implement this with nice animations.

Updates to React 18 + Chakra 2 + Framer-Motion 11, since animation support needs a newer Framer-Motion version which pulls in newer React which again is only supported by newer Chakra.

Fixes https://github.com/ekzhang/rustpad/issues/61

Based on #75, no real dependency through.

It looks pretty decent :slightly_smiling_face:

ntninja avatar Jul 19 '24 12:07 ntninja

Sweet!

Updates to React 18 + Chakra 2 + Framer-Motion 11

Would you mind actually separating this? I'm very open to having a collapsible sidebar now and so on, but it would be nice to collaborate a bit on it between the two of us and that becomes easier if we split up the dependency stuff 🙏

ekzhang avatar Jul 20 '24 01:07 ekzhang

@ekzhang: Done! (The dependency stuff is entirely constraint to the package*.json files, except for that one commit to initialize the DOM differently.)

ntninja avatar Jul 23 '24 15:07 ntninja

Can we take the PR in @ekzhang

hanisntsolo avatar Aug 30 '24 14:08 hanisntsolo

Could you separate the dependency changes into a different PR? I don't really want to review a +1300 line feature PR

ekzhang avatar Sep 04 '24 16:09 ekzhang

@ekzhang: Just in case you’re not aware: You can review the commits individually by just clicking on each in turn and reviewing them that way.

In any case, I've also pushed the first 2 commits over at #83. Thanks for reviewing/merging so far!

ntninja avatar Sep 10 '24 09:09 ntninja

Sorry it's been several months @ntninja — I think we should have the collapsible sidebar, but the interface designer in me isn't happy with the implementation here (specifically the choice of icons, the layout, and so on). I have some time now though so I probably think it'll be quicker to implement from scratch.

ekzhang avatar Dec 31 '24 02:12 ekzhang

Not really sure what you mean, but I guess I’ll see what you mean when its published.

ntninja avatar Jan 01 '25 07:01 ntninja