← Back to PRs

#7528: feat: Adds slash command suggestions to chat

by JohnnyD1776 open 2026-02-02 23:03 View on GitHub →
app: web-ui
Implements slash command suggestions in the chat input, showing available commands as the user types. Adds command history navigation using arrow keys for quick access to previous commands. AI: Assisted Development Testing: Unit test Added and Tested in live environment build. <!-- greptile_comment --> <h2>Greptile Overview</h2> <h3>Greptile Summary</h3> Adds chat slash-command suggestions UI (new command registry + dropdown styling) and introduces command history persistence in UI settings, with ArrowUp/ArrowDown navigation in the chat textarea. Changes flow through the existing `OpenClawApp` state → `renderApp` → `renderChat` props pipeline: `UiSettings.chatCommandHistory` is loaded from localStorage, exposed on `AppViewState`, and then used by `ui/src/ui/views/chat.ts` to render suggestions and implement history navigation while composing. <h3>Confidence Score: 3/5</h3> - Generally safe to merge, with a few UX/accessibility pitfalls worth fixing before shipping broadly. - Changes are localized to the UI chat view and settings persistence, and the logic is straightforward. Main concerns are user-facing behavior issues (suggestions disappearing when arguments are typed, history navigation clobbering drafts / stealing caret movement) and some minor robustness/a11y semantics gaps. I couldn’t run tests in this environment (no node/pnpm), so confidence is moderate. - ui/src/ui/views/chat.ts (history navigation + suggestion behavior); ui/src/ui/app-chat.ts (history write timing); ui/src/ui/storage.ts (settings validation) <!-- greptile_other_comments_section --> <sub>(2/5) Greptile learns from your feedback when you react with thumbs up/down!</sub> **Context used:** - Context from `dashboard` - CLAUDE.md ([source](https://app.greptile.com/review/custom-context?memory=fd949e91-5c3a-4ab5-90a1-cbe184fd6ce8)) - Context from `dashboard` - AGENTS.md ([source](https://app.greptile.com/review/custom-context?memory=0d0c8278-ef8e-4d6c-ab21-f5527e322f13)) <!-- /greptile_comment -->

Most Similar PRs