Skip to content

Commit 956ba95

Browse files
committed
fix(terminal): restore lost refinements — button stretch, Terminal icon, (recommended), i18n alignment
- TerminalSettings.tsx: flex flex-col wrapper for auto-stretch, Terminal icon - TerminalSettings.profile.spec.tsx: add 4 tests for icon and i18n keys - en/settings.json: followVscode (recommended), refined description - zh-CN/settings.json: label, followVscode, description aligned with en - de/it/settings.json: label changed from override to Shell - All 16 locales: (recommended) suffix on followVscode
1 parent 39b087b commit 956ba95

20 files changed

Lines changed: 50 additions & 25 deletions

‎webview-ui/src/components/settings/TerminalSettings.tsx‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import { VSCodeCheckbox, VSCodeLink } from "@vscode/webview-ui-toolkit/react"
55
import { Trans } from "react-i18next"
66
import { buildDocLink } from "@src/utils/docLinks"
77
import { useEvent, useMount } from "react-use"
8+
import { Terminal } from "lucide-react"
89

910
import { type ExtensionMessage, type TerminalOutputPreviewSize } from "@roo-code/types"
1011

@@ -226,15 +227,16 @@ export const TerminalSettings = ({
226227
</Select>
227228

228229
{!terminalProfile && (
229-
<div className="mt-2">
230+
<div className="mt-2 flex flex-col">
230231
<Button
231232
variant="secondary"
232-
size="sm"
233+
className="py-1"
233234
onClick={() => {
234235
onTerminalProfilePickerOpened?.()
235236
vscode.postMessage({ type: "openTerminalProfilePicker" })
236237
}}
237238
data-testid="terminal-profile-configure-button">
239+
<Terminal />
238240
{t("settings:terminal.profile.configureButton")}
239241
</Button>
240242
</div>

‎webview-ui/src/components/settings/__tests__/TerminalSettings.profile.spec.tsx‎

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -212,4 +212,27 @@ describe("TerminalSettings unified profile dropdown", () => {
212212
// Compare DOM positions — checkbox should be before profile dropdown
213213
expect(checkbox.compareDocumentPosition(profileDropdown) & Node.DOCUMENT_POSITION_FOLLOWING).toBeTruthy()
214214
})
215+
216+
it("renders the Terminal icon inside the Configure button", () => {
217+
setup()
218+
const btn = screen.getByTestId("terminal-profile-configure-button")
219+
const svg = btn.querySelector("svg")
220+
expect(svg).toBeInTheDocument()
221+
})
222+
223+
it("shows the correct i18n key for the profile label", () => {
224+
setup()
225+
expect(screen.getByText("settings:terminal.profile.label")).toBeInTheDocument()
226+
})
227+
228+
it("shows the correct i18n key for the followVscode dropdown option", () => {
229+
setup()
230+
expect(screen.getByText("settings:terminal.profile.followVscode")).toBeInTheDocument()
231+
})
232+
233+
it("shows the correct i18n key for the configure button text", () => {
234+
setup()
235+
const btn = screen.getByTestId("terminal-profile-configure-button")
236+
expect(btn.textContent).toContain("settings:terminal.profile.configureButton")
237+
})
215238
})

‎webview-ui/src/i18n/locales/ca/settings.json‎

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎webview-ui/src/i18n/locales/de/settings.json‎

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎webview-ui/src/i18n/locales/en/settings.json‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -820,10 +820,10 @@
820820
},
821821
"profile": {
822822
"label": "Shell for Zoo Code",
823-
"followVscode": "Following VS Code profile",
823+
"followVscode": "Follow VS Code profile (recommended)",
824824
"configureButton": "Choose default profile in VS Code",
825825
"noProfiles": "(no path-based profiles found in terminal.integrated.profiles)",
826-
"description": "By default Zoo Code uses whatever shell VS Code is configured to use. Select a specific profile to override. Source-only profiles cannot be listed here. <0>Learn more</0>"
826+
"description": "Zoo Code uses the shell configured in VS Code by default. Select a specific terminal profile to override this. Only path-based profiles from terminal.integrated.profiles are listed here. <0>Learn more</0>"
827827
}
828828
},
829829
"advancedSettings": {

‎webview-ui/src/i18n/locales/es/settings.json‎

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎webview-ui/src/i18n/locales/fr/settings.json‎

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎webview-ui/src/i18n/locales/hi/settings.json‎

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎webview-ui/src/i18n/locales/id/settings.json‎

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎webview-ui/src/i18n/locales/it/settings.json‎

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)