The open source coding agent.
TypeScript
tui: dock auto-accept after thinking and move Add file to bottom-left
David Hill69cb49f7cc65
diff --git a/packages/app/src/components/prompt-input.tsx b/packages/app/src/components/prompt-input.tsxindex 532edd3bcdc..62b16cd7fa7 100644--- a/packages/app/src/components/prompt-input.tsx+++ b/packages/app/src/components/prompt-input.tsx@@ -1214,7 +1214,7 @@ export const PromptInput: Component<PromptInputProps> = (props) => {onKeyDown={handleKeyDown}classList={{"select-text": true,- "w-full pl-3 pr-2 pt-2 pb-11 text-14-regular text-text-strong focus:outline-none whitespace-pre-wrap": true,+ "w-full pl-3 pr-2 pt-2 pb-[52px] text-14-regular text-text-strong focus:outline-none whitespace-pre-wrap": true,"[&_[data-type=file]]:text-syntax-property": true,"[&_[data-type=agent]]:text-syntax-type": true,"font-mono!": store.mode === "shell",@@ -1222,7 +1222,7 @@ export const PromptInput: Component<PromptInputProps> = (props) => {/><Show when={!prompt.dirty()}><div- class="absolute top-0 inset-x-0 pl-3 pr-2 pt-2 pb-11 text-14-regular text-text-weak pointer-events-none whitespace-nowrap truncate"+ class="absolute top-0 inset-x-0 pl-3 pr-2 pt-2 pb-[52px] text-14-regular text-text-weak pointer-events-none whitespace-nowrap truncate"classList={{ "font-mono!": store.mode === "shell" }}>{placeholder()}@@ -1250,30 +1250,6 @@ export const PromptInput: Component<PromptInputProps> = (props) => {"pointer-events": buttonsSpring() > 0.5 ? "auto" : "none",}}>- <TooltipKeybind- placement="top"- title={language.t("prompt.action.attachFile")}- keybind={command.keybind("file.attach")}- >- <Button- data-action="prompt-attach"- type="button"- variant="ghost"- class="size-8 p-0"- style={{- opacity: buttonsSpring(),- transform: `scale(${0.95 + buttonsSpring() * 0.05})`,- filter: `blur(${(1 - buttonsSpring()) * 2}px)`,- }}- onClick={pick}- disabled={store.mode !== "normal"}- tabIndex={store.mode === "normal" ? undefined : -1}- aria-label={language.t("prompt.action.attachFile")}- >- <Icon name="plus" class="size-4.5" />- </Button>- </TooltipKeybind>-<Tooltipplacement="top"inactive={!prompt.dirty() && !working()}@@ -1314,42 +1290,35 @@ export const PromptInput: Component<PromptInputProps> = (props) => {</div><div class="pointer-events-none absolute bottom-2 left-2">- <div class="pointer-events-auto">+ <div+ aria-hidden={store.mode !== "normal"}+ class="pointer-events-auto"+ style={{+ "pointer-events": buttonsSpring() > 0.5 ? "auto" : "none",+ }}+ ><TooltipKeybindplacement="top"gutter={8}- title={language.t(- accepting() ? "command.permissions.autoaccept.disable" : "command.permissions.autoaccept.enable",- )}- keybind={command.keybind("permissions.autoaccept")}+ title={language.t("prompt.action.attachFile")}+ keybind={command.keybind("file.attach")}><Button- data-action="prompt-permissions"+ data-action="prompt-attach"+ type="button"variant="ghost"- onClick={() => {- if (!params.id) {- permission.toggleAutoAcceptDirectory(sdk.directory)- return- }- permission.toggleAutoAccept(params.id, sdk.directory)- }}- classList={{- "size-6 flex items-center justify-center": true,- "text-text-base": !accepting(),- "hover:bg-surface-success-base": accepting(),+ class="size-8 p-0"+ style={{+ opacity: buttonsSpring(),+ transform: `scale(${0.95 + buttonsSpring() * 0.05})`,+ filter: `blur(${(1 - buttonsSpring()) * 2}px)`,}}- aria-label={- accepting()- ? language.t("command.permissions.autoaccept.disable")- : language.t("command.permissions.autoaccept.enable")- }- aria-pressed={accepting()}+ onClick={pick}+ disabled={store.mode !== "normal"}+ tabIndex={store.mode === "normal" ? undefined : -1}+ aria-label={language.t("prompt.action.attachFile")}>- <Icon- name="chevron-double-right"- size="small"- classList={{ "text-icon-success-base": accepting() }}- />+ <Icon name="plus" class="size-4.5" /></Button></TooltipKeybind></div>@@ -1494,6 +1463,51 @@ export const PromptInput: Component<PromptInputProps> = (props) => {variant="ghost"/></TooltipKeybind>++ <TooltipKeybind+ placement="top"+ gutter={4}+ title={language.t(+ accepting() ? "command.permissions.autoaccept.disable" : "command.permissions.autoaccept.enable",+ )}+ keybind={command.keybind("permissions.autoaccept")}+ >+ <Button+ data-action="prompt-permissions"+ type="button"+ variant="ghost"+ class="size-7 p-0 flex items-center justify-center"+ style={{+ opacity: buttonsSpring(),+ transform: `scale(${0.95 + buttonsSpring() * 0.05})`,+ filter: `blur(${(1 - buttonsSpring()) * 2}px)`,+ "pointer-events": buttonsSpring() > 0.5 ? "auto" : "none",+ }}+ onClick={() => {+ if (!params.id) {+ permission.toggleAutoAcceptDirectory(sdk.directory)+ return+ }+ permission.toggleAutoAccept(params.id, sdk.directory)+ }}+ classList={{+ "text-text-base": !accepting(),+ "hover:bg-surface-success-base": accepting(),+ }}+ aria-label={+ accepting()+ ? language.t("command.permissions.autoaccept.disable")+ : language.t("command.permissions.autoaccept.enable")+ }+ aria-pressed={accepting()}+ >+ <Icon+ name="chevron-double-right"+ size="small"+ classList={{ "text-icon-success-base": accepting() }}+ />+ </Button>+ </TooltipKeybind></div></div><div class="shrink-0">