chainlit icon indicating copy to clipboard operation
chainlit copied to clipboard

feat: enable resizing the side panel

Open tpatel opened this issue 2 years ago • 2 comments

  • The child component is hidden when resizing to speed up rendering
  • The handle has a 5px+ border around it to help users select it
  • Removed the code related to transitions as it wasn't working (transitions were activated on transform, transform wasn't used)

https://github.com/Chainlit/chainlit/assets/494686/de2e462c-8557-4bdc-95ec-6d685a00e8ac

tpatel avatar Jun 12 '23 13:06 tpatel

looks good! could you provide a minimal gif of the result before merging? Thanks!

willydouhard avatar Jun 12 '23 14:06 willydouhard

done!

tpatel avatar Jun 12 '23 14:06 tpatel

Moved away from hiding the children component, and used pointer-events: none when resizing. This solves the problem when hovering-over an iframe during resizing would mess the resizing state.

This might introduce a small performance degradation, but it gives more visual feedback to the user, so it's a better solution.

tpatel avatar Jun 13 '23 12:06 tpatel