Commit Graph

75 Commits

Author SHA1 Message Date
Calmcacil
1187ae0046 Add screen transition animations for polished UX 2026-01-12 23:40:01 +01:00
Calmcacil
b7ddd54cf6 bd sync: 2026-01-12 23:34:33 2026-01-12 23:34:33 +01:00
Calmcacil
5b8b9b66f5 Add keyboard shortcut discoverability hints on each screen 2026-01-12 23:34:14 +01:00
Calmcacil
f0e26e4a0a bd sync: 2026-01-12 23:24:02 2026-01-12 23:24:02 +01:00
Calmcacil
dd62458515 Add text selection and copy capability to terminal UI 2026-01-12 23:23:48 +01:00
Calmcacil
17f4d52c8a bd sync: 2026-01-12 23:21:29 2026-01-12 23:21:29 +01:00
Calmcacil
4787f3b863 bd sync: 2026-01-12 23:19:12 2026-01-12 23:19:12 +01:00
Calmcacil
3631339f8b Add loading spinners for async operations 2026-01-12 23:18:57 +01:00
Calmcacil
1c03a706d1 bd sync: 2026-01-12 23:12:04 2026-01-12 23:12:04 +01:00
Calmcacil
a3c2828ec2 Integrate theme system across all screens 2026-01-12 23:11:53 +01:00
Calmcacil
d669adc094 bd sync: 2026-01-12 23:07:02 2026-01-12 23:07:02 +01:00
Calmcacil
ea36f03393 bd sync: 2026-01-12 23:05:10 2026-01-12 23:05:10 +01:00
Calmcacil
aadcfbf810 Create dedicated error screen with user-friendly messages and recovery options 2026-01-12 23:04:58 +01:00
Calmcacil
34951221d3 bd sync: 2026-01-12 23:04:56 2026-01-12 23:04:56 +01:00
Calmcacil
68939cdc08 Reduce status refresh interval to 3 seconds and add last updated indicator 2026-01-12 23:04:48 +01:00
Calmcacil
5136484cd2 bd sync: 2026-01-12 23:03:09 2026-01-12 23:03:09 +01:00
Calmcacil
575faa8c68 Improve empty state messages with actionable guidance 2026-01-12 23:03:00 +01:00
Calmcacil
8b49fbfd3a bd sync: 2026-01-12 23:02:08 2026-01-12 23:02:08 +01:00
Calmcacil
78a100112c Fix q key behavior in client details view 2026-01-12 23:01:59 +01:00
Calmcacil
707464e61e Fix help screen documentation - incorrect key binding for viewing details 2026-01-12 23:00:16 +01:00
Calmcacil
153c001483 bd sync: 2026-01-12 22:57:05 2026-01-12 22:57:05 +01:00
Calmcacil
23d1cae737 bd sync: 2026-01-12 22:54:34 2026-01-12 22:54:34 +01:00
Calmcacil
3f60ab8355 fix: add background dimming to config display modal
Config display modal now dims background content before showing,
following the same pattern as delete confirmation modal.
This provides visual consistency across all modals and makes
it clear to users when a modal is active.

Fixes: wg-admin-bfe
2026-01-12 22:44:11 +01:00
Calmcacil
fd0a1c45e7 feat: replace clipboard copy with config display for SSH sessions
Created ConfigDisplay component that shows full client configuration
in a scrollable modal window, replacing non-functional clipboard copy.

Benefits:
- Works over SSH sessions (no clipboard API needed)
- Shows complete configuration, not just public key
- Scrollable for long configs with keyboard navigation
- Users can select and copy text directly in terminal

Changes:
- Created internal/tui/components/config-display.go
- Updated detail.go to replace copyPublicKey with loadConfig
- Removed clipboard-related fields and message type
- Updated help text: 'c' now shows config
- Key bindings for scrolling: ↑↓, pgup/pgdn, g/G, Esc/q to close

Fixes: wg-admin-qtb
2026-01-12 22:36:40 +01:00
Calmcacil
8fb3fe7031 fix: critical navigation bug - users trapped in detail and restore screens
Changed return value from 'return s, nil' to 'return nil, nil' in:
- detail.go (line 116): Back navigation from client details
- restore.go (line 101): Back navigation from restore screen

Root cause: Main model's navigation logic checks if newScreen == nil.
When screens returned (s, nil), the check failed and screen never changed.
Now properly returns (nil, nil) to signal screen change to parent.

Fixes: wg-admin-rfo
2026-01-12 22:27:16 +01:00
Calmcacil
e7d81674c8 chore: add wg-tui binary to gitignore 2026-01-12 22:18:09 +01:00
Calmcacil
d2dc361620 fix: change back navigation to 'b' key and improve deletion confirmation with name verification
- Changed 'q' key to 'b' for back navigation in client details
- Added 'esc' key binding for back navigation
- Updated help text to reflect new key bindings
- Created new DeleteConfirmModal component with name verification
- User must type exact client name to confirm deletion (safety feature)
- Improved modal styling with visual feedback (red/green indicators)
- Case-sensitive name matching to prevent accidental deletions

Fixes: wg-admin-az7
2026-01-12 22:17:27 +01:00
Calmcacil
0798b72858 bd sync: 2026-01-12 22:17:09 2026-01-12 22:17:09 +01:00
Calmcacil
f1712b5f9e bd sync: 2026-01-12 21:41:27 2026-01-12 21:41:27 +01:00
Calmcacil
5d129562e2 fix: Properly parse compound handshake time and fix q key handling
- Fix parseHandshake to correctly parse number-unit pairs from '14 hours, 24 minutes, 40 seconds ago'
  Previous logic tried to parse unit words instead of finding associated numbers
  Now correctly accumulates all time units (hours, minutes, seconds)
- Fix q key handling to properly check screen type before quitting
  Only quit application when 'q' is pressed on list screen
  Other screens (detail, add, help) now handle 'q' to navigate back

Note: q key navigation may still need investigation for edge cases
2026-01-12 19:27:21 +01:00
Calmcacil
e0f8210c17 fix: Fix 'q' key handling and connectivity status issues
- Fix 'q' key in detail/add/help screens to return to list instead of quitting
- Only quit application with 'q' when on main list screen
- Fix parseHandshake to accumulate all time units instead of returning early
  This resolves handshake timing discrepancy with wg show output
- Increase connection status threshold from 3 to 5 minutes
  Allows ~12 missed keepalive intervals (25s each)
  Improves connectivity status accuracy for peers with marginal connections
2026-01-12 19:17:51 +01:00
Calmcacil
85f2e521c9 feat: Add Dracula and Everforest color themes, set Everforest as default
- Add DraculaTheme with official Dracula color palette
- Add EverforestTheme with natural Everforest dark color scheme
- Set Everforest as default theme (was 'default')
- Update README with theming documentation and THEME env var usage
- Build verified successfully
2026-01-12 19:10:46 +01:00
Calmcacil
26120b8bc2 Add WireGuard TUI implementation
- Add Go TUI with bubbletea for WireGuard management
- Implement client CRUD operations with QR code generation
- Add configuration and validation modules
- Install/update scripts for client setup
- Update Makefile to build binaries to bin/ directory
- Add .gitignore for Go projects
2026-01-12 19:03:35 +01:00
Calmcacil
5ac68db854 Fix Makefile: use -C flag to set module root 2026-01-12 19:00:35 +01:00
Calmcacil
bbc8e77e99 Fix Makefile: run go commands from project root 2026-01-12 18:59:07 +01:00
Calmcacil
320a9454fe Add Makefile for build automation 2026-01-12 18:54:55 +01:00
Calmcacil
aeea977884 bd sync: 2026-01-12 18:06:59 2026-01-12 18:06:59 +01:00
Calmcacil
a55629bb7f bd sync: 2026-01-12 18:06:08 2026-01-12 18:06:08 +01:00
Calmcacil
900cbad4cd bd sync: 2026-01-12 18:05:24 2026-01-12 18:05:24 +01:00
Calmcacil
c638800137 bd sync: 2026-01-12 18:04:46 2026-01-12 18:04:46 +01:00
Calmcacil
88d4ca79d1 bd sync: 2026-01-12 17:59:34 2026-01-12 17:59:34 +01:00
Calmcacil
427e3b402c bd sync: 2026-01-12 17:56:53 2026-01-12 17:56:53 +01:00
Calmcacil
9c7990c192 bd sync: 2026-01-12 17:54:28 2026-01-12 17:54:28 +01:00
Calmcacil
acab9f95b4 bd sync: 2026-01-12 17:51:29 2026-01-12 17:51:29 +01:00
Calmcacil
e86f968c5f bd sync: 2026-01-12 17:51:02 2026-01-12 17:51:02 +01:00
Calmcacil
cb7844c730 bd sync: 2026-01-12 17:48:32 2026-01-12 17:48:32 +01:00
Calmcacil
09a3524a71 bd sync: 2026-01-12 17:47:26 2026-01-12 17:47:26 +01:00
Calmcacil
93a3615a60 Add keyboard shortcuts help screen
- Created help.go with Screen interface implementation
- Help screen displays all shortcuts in two-column layout
- Categories: Navigation (j/k, arrows, Enter, Esc), Actions (a, d, D, Q, r, l), Other (?, /, q)
- Added '?' key handler in main.go to switch to help screen
- Help reference added to status bar
- Press q or Esc to return from help screen
- Styled with lipgloss for clear readability
2026-01-12 17:46:38 +01:00
Calmcacil
b53e1af96a bd sync: 2026-01-12 17:46:34 2026-01-12 17:46:34 +01:00
Calmcacil
efb8b5da72 bd sync: 2026-01-12 17:46:25 2026-01-12 17:46:25 +01:00