tui-widgets
tui-widgets copied to clipboard
feat: Implement interactive popup dragging and resizing
This commit introduces interactive dragging and resizing functionality to the tui-popup crate.
Changes include:
- Added an
interactiveexample demonstrating the new features. - Updated
PopupStateto manage interaction state (dragging and resizing). - Modified
Popupwidget to render a resize handle. - Implemented mouse event handling for dragging and resizing.
- Added constraints to keep the popup within terminal bounds and enforce minimum size.
These changes allow users to interactively reposition and resize popups within the terminal, improving the user experience.
Codecov Report
Attention: Patch coverage is 76.28458% with 60 lines in your changes missing coverage. Please review.
Project coverage is 72.28%. Comparing base (
cad0d3e) to head (e322341).
| Files with missing lines | Patch % | Lines |
|---|---|---|
| tui-popup/src/popup_state.rs | 78.01% | 42 Missing :warning: |
| tui-popup/src/popup.rs | 70.96% | 18 Missing :warning: |
Additional details and impacted files
@@ Coverage Diff @@
## main #59 +/- ##
==========================================
+ Coverage 71.51% 72.28% +0.76%
==========================================
Files 15 15
Lines 2503 2742 +239
==========================================
+ Hits 1790 1982 +192
- Misses 713 760 +47
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.