You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have successfully refactored createModal across the entire codebase to accept DialogSizeConstraints and perform fully dynamic size calculations on every draw.
### Summary of Changes:
1. Dynamic Modal Resizing: Updated createModal inside util.go to receive DialogSizeConstraints directly instead of raw dimensions. Every time a modal draws, it recalculates its ideal dimensions
using CalculateDialogSize(constraints) and resizes its inner frames dynamically.
2. Eliminated Call-site Redundancy: Migrated all callers of createModal to pass constraints directly, allowing them to skip manual one-time CalculateDialogSize pre-calculations. This applies to:
• column_selection_dialog.go
• file_diff_dialog.go
• help_dialog.go
• restore_file_progress_dialog.go
• selection_dialog.go
• util_test.go
3. Verified and Built: Ran go test ./... and compiled the final clean binary using just build .
Now, all modals and dialogs throughout the application dynamically scale up or down during terminal resizing events.
0 commit comments