fix(web): address review — placeholder key family, menu-open gate, plan precedence, note wording

This commit is contained in:
_Kerman
2026-08-07 14:20:14 +08:00
parent f79db87d8d
commit 4ede2798fe
6 changed files with 38 additions and 8 deletions
@@ -22,7 +22,7 @@ export const zh = {
'input.commands': '命令',
'input.stop': '停止生成',
'input.send': '发送消息',
'input.steerQueueShortcut': 'Cmd/Ctrl+Enter 插话发送全部排队消息',
'placeholder.steerQueue': 'Cmd/Ctrl+Enter 插话发送全部排队消息',
'input.accessMode': '访问模式,当前:{name}',
'context.aria': '上下文已用 {percent}',
'context.used': '上下文已用',
@@ -163,7 +163,7 @@ export const en = {
'input.commands': 'Commands',
'input.stop': 'Stop generating',
'input.send': 'Send message',
'input.steerQueueShortcut': 'Cmd/Ctrl+Enter steers all queued messages',
'placeholder.steerQueue': 'Cmd/Ctrl+Enter steers all queued messages',
'input.accessMode': 'Access mode, current: {name}',
'context.aria': '{percent} of context used',
'context.used': 'of context used',
@@ -89,7 +89,7 @@ export function InputBar({
const disabled = removed || inert || !live
const locked = disabled
const machineBusy = input?.phase === 'adjudicating' || input?.phase === 'submitting'
const canSteerQueue = !locked && !machineBusy && empty && running && subagent === null
const canSteerQueue = !locked && !machineBusy && !commandMenuOpen && empty && running && subagent === null
&& input.queue.some(row => row.placement === 'queued')
// Scroll the draft scrollport the minimum that brings `caret` into view — the
@@ -486,8 +486,11 @@ export function InputBar({
data-phase={input?.phase ?? 'inert'}
placeholder={placeholder ?? (disabled
? t('placeholder.unavailable')
// The steer hint deliberately outranks the plan placeholder:
// while it shows, the whole-queue gesture is genuinely available
// (the gate never consults plan mode), so the actionable hint wins.
: canSteerQueue
? t('input.steerQueueShortcut')
? t('placeholder.steerQueue')
: planActive ? t('placeholder.plan') : t('placeholder.default'))}
rows={2}
onChange={onChange}