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

feat: enable resizing the side panel #54

Merged
merged 2 commits into from
Jun 13, 2023
Merged

Conversation

tpatel
Copy link
Contributor

@tpatel tpatel commented Jun 12, 2023

  • 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)
Kapture.2023-06-13.at.14.55.00.mp4

@tpatel tpatel requested a review from willydouhard June 12, 2023 13:40
@tpatel tpatel self-assigned this Jun 12, 2023
@willydouhard
Copy link
Collaborator

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

@tpatel
Copy link
Contributor Author

tpatel commented Jun 12, 2023

done!

@tpatel
Copy link
Contributor Author

tpatel commented Jun 13, 2023

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 added 2 commits June 13, 2023 16:29
- 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)
- Instead of hiding the children, we use `pointer-events` to prevent a potential iframe from messing the resizing
@tpatel tpatel merged commit 1eb74b7 into Chainlit:main Jun 13, 2023
@tpatel tpatel deleted the resize-side branch June 13, 2023 14:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants