Skip to content

chore(tui): upgrade tamboui to 0.4.0#76

Merged
ayagmar merged 6 commits into
masterfrom
chore/tamboui-0.4-maintenance
Jun 25, 2026
Merged

chore(tui): upgrade tamboui to 0.4.0#76
ayagmar merged 6 commits into
masterfrom
chore/tamboui-0.4-maintenance

Conversation

@ayagmar

@ayagmar ayagmar commented Jun 25, 2026

Copy link
Copy Markdown
Owner

Summary by CodeRabbit

Summary

  • New Features

    • Added/expanded Vim-style navigation and shortcut coverage across the TUI (including command palette and menu selection).
    • Documented new productivity/form shortcuts: selected-only filter, next favorite, and next/previous invalid field focus (Alt+N / Alt+P).
  • Bug Fixes

    • Improved consistency of digit-based selection and navigation handling using key-event codepoints.
    • Refined text input key behavior for more reliable cursor/edit handling.
  • Documentation

    • Updated UI keybinding and troubleshooting guidance, including the correct rendering-framework link and Windows console instructions.
  • Tests

    • Updated and expanded keybinding and input-handling test coverage.

@coderabbitai

coderabbitai Bot commented Jun 25, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

The PR updates Tamboui dependency management to use a BOM and toolkit, switches app bindings to vim-based key maps, refactors TUI key handlers to direct key-state checks or toolkit delegation, and updates matching tests and docs.

Changes

Tamboui dependency and UI wiring

Layer / File(s) Summary
Tamboui BOM and docs
pom.xml, docs/modules/ROOT/pages/architecture.adoc, docs/modules/ROOT/pages/troubleshooting.adoc, README.md, docs/modules/ROOT/pages/ui/keybindings.adoc, docs/modules/ROOT/pages/usage/tui.adoc
pom.xml switches Tamboui dependency management to the BOM, adds dev.tamboui:tamboui-toolkit, and updates Tamboui dependency declarations; the docs update the framework link, backend guidance, and keyboard shortcut references.
Bindings and shortcut predicates
src/main/java/dev/ayagmar/quarkusforge/runtime/AppBindingsProfile.java, src/main/java/dev/ayagmar/quarkusforge/ui/AppKeyActions.java, src/main/java/dev/ayagmar/quarkusforge/ui/UiKeyPredicates.java, src/main/java/dev/ayagmar/quarkusforge/ui/UiKeyMatchers.java
AppBindingsProfile switches to BindingSets.vim() and binds shortcuts to AppKeyActions; AppKeyActions updates shortcut predicates to use event matching and char/modifier checks, UiKeyPredicates adds digit detection, and UiKeyMatchers is removed.
Key routing and input handling
src/main/java/dev/ayagmar/quarkusforge/ui/CoreTuiController.java, src/main/java/dev/ayagmar/quarkusforge/ui/CoreUiReducer.java, src/main/java/dev/ayagmar/quarkusforge/ui/ExtensionCatalogNavigation.java, src/main/java/dev/ayagmar/quarkusforge/ui/InputEffects.java, src/main/java/dev/ayagmar/quarkusforge/ui/PostGenerationMenuState.java, src/main/java/dev/ayagmar/quarkusforge/ui/UiTextInputKeys.java
Command-palette digit handling, reducer navigation predicates, metadata/text-input gating, and post-generation menu selection now use direct key-state checks; text input delegates to Toolkit, and UiTextInputKeys is removed.
Runtime backend and test updates
src/main/java/dev/ayagmar/quarkusforge/runtime/TuiBootstrapService.java, src/test/java/dev/ayagmar/quarkusforge/TuiBootstrapServiceTest.java, src/test/java/dev/ayagmar/quarkusforge/cli/QuarkusForgeCliBindingsProfileTest.java, src/test/java/dev/ayagmar/quarkusforge/ui/AppKeyActionsTest.java, src/test/java/dev/ayagmar/quarkusforge/ui/CoreTuiShellPilotTest.java, src/test/java/dev/ayagmar/quarkusforge/ui/CoreUiReducerTest.java, src/test/java/dev/ayagmar/quarkusforge/ui/ExtensionCatalogNavigationTest.java, src/test/java/dev/ayagmar/quarkusforge/ui/InputEffectsTest.java, src/test/java/dev/ayagmar/quarkusforge/ui/PostGenerationMenuStateTest.java
TuiBootstrapService simplifies backend selection and property restoration, and the tests update backend coverage, key-event construction, bindings assertions, and input-flow expectations.

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~60 minutes

Possibly related PRs

  • ayagmar/quarkus-forge#2: Both PRs refactor the TUI input/key-handling architecture, including key routing and shortcut matching.
  • ayagmar/quarkus-forge#26: This PR also updates TuiBootstrapServiceTest alongside backend-selection behavior in TuiBootstrapService.
  • ayagmar/quarkus-forge#32: Both PRs touch AppKeyActions and shortcut behavior for TUI key handling.

Poem

🐇 I hopped through keys with vimmy cheer,
The toolkit hummed, the path grew clear.
No stray hops for h, j, k, or g,
My whiskers twitch in binding glee.
Carrots for tests, and docs align —
This bunny’s UI leaps just fine.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 2.33% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly matches the main change: upgrading Tamboui to 0.4.0.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch chore/tamboui-0.4-maintenance

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@codecov

codecov Bot commented Jun 25, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

ayagmar added 5 commits June 25, 2026 16:27
The Windows-specific jline3-first preference let the backend factory settle
on a JLine terminal that constructs successfully but does not deliver key
events, since the factory only falls through when create() throws. Panama
gained a first-class Win32 console backend (SetConsoleMode +
ENABLE_VIRTUAL_TERMINAL_INPUT + ReadConsoleInput) in tamboui 0.4.0, so it is
now the default on every platform. The tamboui.backend / TAMBOUI_BACKEND
override still allows forcing jline3 when needed.

Drops the Windows backend special-case and the org.jline.terminal.dumb
fallback workaround.
…n jumps

Cover the full TUI keybinding surface: Vim-style motion keys (j/k/h/l/g/G),
case-insensitive letter shortcuts, Shift variants of every Ctrl/Alt shortcut,
the selected-only filter (Alt+S), and invalid-field navigation (Alt+N/Alt+P).

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@docs/modules/ROOT/pages/troubleshooting.adoc`:
- Line 30: The troubleshooting note for the backend fallback uses the wrong JVM
property syntax, so update the instruction in the relevant documentation section
to use the executable system-property form with the same symbol,
tamboui.backend, as described alongside the Forge backend fallback. Keep the
environment-variable alternative as-is, but change the property example to the
-D form so users can pass it when launching the jar.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: f8ed916a-32e6-4068-8b24-42362fdcdb43

📥 Commits

Reviewing files that changed from the base of the PR and between 28d721d and 49135c5.

📒 Files selected for processing (14)
  • README.md
  • docs/modules/ROOT/pages/troubleshooting.adoc
  • docs/modules/ROOT/pages/ui/keybindings.adoc
  • docs/modules/ROOT/pages/usage/tui.adoc
  • src/main/java/dev/ayagmar/quarkusforge/runtime/TuiBootstrapService.java
  • src/main/java/dev/ayagmar/quarkusforge/ui/CoreTuiController.java
  • src/main/java/dev/ayagmar/quarkusforge/ui/PostGenerationMenuState.java
  • src/main/java/dev/ayagmar/quarkusforge/ui/UiKeyPredicates.java
  • src/test/java/dev/ayagmar/quarkusforge/TuiBootstrapServiceTest.java
  • src/test/java/dev/ayagmar/quarkusforge/ui/AppKeyActionsTest.java
  • src/test/java/dev/ayagmar/quarkusforge/ui/CoreTuiShellPilotTest.java
  • src/test/java/dev/ayagmar/quarkusforge/ui/CoreUiReducerTest.java
  • src/test/java/dev/ayagmar/quarkusforge/ui/InputEffectsTest.java
  • src/test/java/dev/ayagmar/quarkusforge/ui/PostGenerationMenuStateTest.java
✅ Files skipped from review due to trivial changes (2)
  • docs/modules/ROOT/pages/ui/keybindings.adoc
  • README.md
🚧 Files skipped from review as they are similar to previous changes (1)
  • src/test/java/dev/ayagmar/quarkusforge/ui/CoreTuiShellPilotTest.java

----
. Verify your terminal supports 256-color or true-color (e.g., `echo $TERM`). Recommended: `xterm-256color`, `alacritty`, `kitty`, or `wezterm`.
. On Windows, use Windows Terminal or a recent ConEmu/Git Bash with VT mode enabled. Forge now defaults to the JLine backend on Windows to preserve arrow-key navigation; avoid forcing `tamboui.backend=panama` unless you are debugging backend behavior.
. On Windows, run inside a real console (Windows Terminal, PowerShell, or `cmd.exe`) so the Panama backend can enable virtual-terminal input; Git Bash/MSYS `mintty` does not expose a Win32 console and leaves keys unregistered without `winpty`. Forge defaults to the Panama backend on every platform; set `tamboui.backend=jline3` (or `TAMBOUI_BACKEND=jline3`) only if you need to fall back to JLine.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Use the JVM -D form in the fallback instruction.

Line 30 currently shows tamboui.backend=jline3, but users need -Dtamboui.backend=jline3 when launching the jar. As written, the documented system-property override is not executable.

Suggested wording
-. On Windows, run inside a real console (Windows Terminal, PowerShell, or `cmd.exe`) so the Panama backend can enable virtual-terminal input; Git Bash/MSYS `mintty` does not expose a Win32 console and leaves keys unregistered without `winpty`. Forge defaults to the Panama backend on every platform; set `tamboui.backend=jline3` (or `TAMBOUI_BACKEND=jline3`) only if you need to fall back to JLine.
+. On Windows, run inside a real console (Windows Terminal, PowerShell, or `cmd.exe`) so the Panama backend can enable virtual-terminal input; Git Bash/MSYS `mintty` does not expose a Win32 console and leaves keys unregistered without `winpty`. Forge defaults to the Panama backend on every platform; start the JVM with `-Dtamboui.backend=jline3` (or set `TAMBOUI_BACKEND=jline3`) only if you need to fall back to JLine.
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
. On Windows, run inside a real console (Windows Terminal, PowerShell, or `cmd.exe`) so the Panama backend can enable virtual-terminal input; Git Bash/MSYS `mintty` does not expose a Win32 console and leaves keys unregistered without `winpty`. Forge defaults to the Panama backend on every platform; set `tamboui.backend=jline3` (or `TAMBOUI_BACKEND=jline3`) only if you need to fall back to JLine.
. On Windows, run inside a real console (Windows Terminal, PowerShell, or `cmd.exe`) so the Panama backend can enable virtual-terminal input; Git Bash/MSYS `mintty` does not expose a Win32 console and leaves keys unregistered without `winpty`. Forge defaults to the Panama backend on every platform; start the JVM with `-Dtamboui.backend=jline3` (or set `TAMBOUI_BACKEND=jline3`) only if you need to fall back to JLine.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@docs/modules/ROOT/pages/troubleshooting.adoc` at line 30, The troubleshooting
note for the backend fallback uses the wrong JVM property syntax, so update the
instruction in the relevant documentation section to use the executable
system-property form with the same symbol, tamboui.backend, as described
alongside the Forge backend fallback. Keep the environment-variable alternative
as-is, but change the property example to the -D form so users can pass it when
launching the jar.

@ayagmar
ayagmar merged commit 7a464d6 into master Jun 25, 2026
12 checks passed
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.

1 participant