feat: Sprint 5 — xterm.js terminal with WebSocket mock shell, Alpine tab management

This commit is contained in:
swanadiva
2026-07-07 13:39:35 +07:00
parent 941a67b6ea
commit 04d9cfb096
10 changed files with 571 additions and 12 deletions
+10 -9
View File
@@ -39,7 +39,7 @@ Lihat [ARCHITECTURE_HTMX.md](ARCHITECTURE_HTMX.md) untuk detail.
| Sprint 2 — Snippets + Keychain | DONE |
| Sprint 3 — Settings + Brief | DONE |
| Sprint 4 — SFTP Dual-Pane | DONE |
| Sprint 5 — Terminal + xterm.js | NOT STARTED |
| Sprint 5 — Terminal + xterm.js | DONE |
| Sprint 6 — Storage Integration | NOT STARTED |
---
@@ -108,13 +108,13 @@ Lihat [ARCHITECTURE_HTMX.md](ARCHITECTURE_HTMX.md) untuk detail.
- **Verify**: Dual-pane renders, file list per type icons, CRUD works, drop-zone + toast present
### Sprint 5 — Terminal + xterm.js
- [ ] Download xterm.js
- [ ] Terminal handler (page)
- [ ] WebSocket handler
- [ ] Terminal template
- [ ] Terminal JS (xterm init + WS)
- [ ] Tab management
- [ ] SSH pipe (mock)
- [x] Download xterm.js v5.3.0 + xterm.css (`static/xterm/`)
- [x] Install gofiber/contrib/websocket v1.3.4
- [x] Terminal handler (`internal/handler/terminal.go`) — page + WebSocket mock shell (ls, pwd, cd, cat, whoami, etc.)
- [x] Terminal template (`views/terminal.html`) — dark theme, tab bar with Alpine, xterm containers
- [x] Terminal JS (`static/js/terminal.js`) — Alpine terminalManager, xterm init, WS connect, tab CRUD
- [x] Tab management — add/switch/close tabs, random host assignment
- **Verify**: Terminal page renders, xterm.js loaded, WS endpoint returns Upgrade Required
### Sprint 6 — Data Store Integration
- [ ] replace directive go.mod
@@ -146,7 +146,8 @@ Lihat [ARCHITECTURE_HTMX.md](ARCHITECTURE_HTMX.md) untuk detail.
| 2026-07-07 | Sprint 2 dimulai: Snippet + Keychain models created | — |
| 2026-07-07 | Sprint 2 selesai: all CRUD, standalone templates, clipboard.js, utils.js, fix template {{define}} conflict | `c4b0d7d` |
| 2026-07-07 | Sprint 3 selesai: settings page, tabs, toggles, connected devices, danger zone, brief page | `c5ac07e` |
| 2026-07-07 | Sprint 4 selesai: SFTP dual-pane, breadcrumb, per-type icons, create/delete, toast, drop-zone | `(pending)` |
| 2026-07-07 | Sprint 4 selesai: SFTP dual-pane, breadcrumb, per-type icons, create/delete, toast, drop-zone | `941a67b` |
| 2026-07-07 | Sprint 5 selesai: xterm.js terminal, WebSocket mock shell, tab management | `(pending)` |
---