Порівняти коміти

...
3 змінених файлів з 84 додано та 44 видалено

No files matched your search

+27
Переглянути файл
@@ -0,0 +1,27 @@
import { expect, test } from "./fixtures";
test("keeps debug actions and views accessible when the Debug window is docked at the side", async ({
workbench: page,
}) => {
await page.setViewportSize({ width: 900, height: 760 });
await page.evaluate(async () => {
const debugModule = "/src/features/debugger/state.ts";
const layoutModule = "/src/workbench/toolwindows/store.ts";
const servicesModule = "/src/workbench/contributions.ts";
const { adoptSession } = await import(/* @vite-ignore */ debugModule);
const { moveToolWindow, setToolWindowSize } = await import(/* @vite-ignore */ layoutModule);
const { toolWindowService } = await import(/* @vite-ignore */ servicesModule);
adoptSession(91, { name: "Checkout service", adapter: "java-debug", status: "starting" });
moveToolWindow("debug", "right");
setToolWindowSize("right", 300);
toolWindowService().show("debug", true);
});
const pane = page.getByRole("region", { name: "Debug", exact: true });
const toolbar = pane.getByRole("toolbar", { name: "Debugger actions" });
const views = pane.getByRole("tablist", { name: "Debug views" });
await expect(toolbar.getByRole("button", { name: "More", exact: true })).toBeInViewport();
await expect(views.getByRole("tab", { name: "Console", exact: true })).toBeInViewport();
await views.getByRole("tab", { name: "Memory", exact: true }).click();
await expect(views.getByRole("tab", { name: "Memory", exact: true })).toHaveAttribute("aria-selected", "true");
});
+19 -7
Переглянути файл
@@ -19,20 +19,28 @@
}
.toolbar {
height: 32px;
min-height: 32px;
flex: none;
display: flex;
flex-wrap: wrap;
align-items: center;
gap: var(--space-0-5);
padding: 0 8px 0 4px;
gap: var(--space-0-5) var(--space-2);
padding: var(--space-0-5) var(--space-2) var(--space-0-5) var(--space-1);
border-bottom: 1px solid var(--border);
min-width: 0;
overflow: hidden;
}
.actions {
display: flex;
flex-wrap: wrap;
align-items: center;
gap: var(--space-0-5);
min-width: 0;
}
.tool {
width: 26px;
height: 26px;
width: var(--h-control);
height: var(--h-control);
flex: none;
}
@@ -46,17 +54,21 @@
.tabs {
display: flex;
flex-wrap: wrap;
align-items: center;
gap: var(--space-0-5);
flex: none;
min-width: 0;
}
.tab {
height: 24px;
max-inline-size: 100%;
padding: 0 8px;
border-radius: var(--radius-small);
color: var(--fg);
font-size: var(--fs-ui);
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.tab:hover {
+38 -37
Переглянути файл
@@ -16,6 +16,7 @@ import {
SplitHandle,
SplitPanel,
Tabs,
Toolbar,
showContextMenu,
type MenuItem,
type TabItem,
@@ -218,43 +219,43 @@ export function DebugToolWindow() {
return (
<div className={styles.root}>
<div className={styles.toolbar} role="toolbar" aria-label={tx("Debugger actions")}>
{/* IDEA's XDebugger.ToolWindow.TopToolbar3 (+ its "More" group), then the views. */}
<ToolButton action="debug.rerun" icon="rerun" />
<ToolButton action="debug.stop" icon="stop" tone="danger" />
<span className={styles.sep} aria-hidden />
<ToolButton action="debug.resume" icon="resume" />
<ToolButton action="debug.pause" icon="pause" />
<ToolButton action="debug.stepOver" icon="step-over" />
<ToolButton action="debug.stepInto" icon="step-into" />
<ToolButton action="debug.stepOut" icon="step-out" />
<span className={styles.sep} aria-hidden />
{rootOf(active).adapter === "dart" && (
<>
<ToolButton action="debug.hotReload" icon="hot-reload" />
<ToolButton action="debug.hotRestart" icon="refresh" />
{rootOf(active).vmServiceUri && <ToolButton action="debug.openDevTools" icon="external-link" />}
<span className={styles.sep} aria-hidden />
</>
)}
<IconButton
icon="view-breakpoints"
action="debug.viewBreakpoints"
size="small"
iconSize={16}
className={styles.tool}
/>
<IconButton
icon="mute-breakpoint"
title={muted ? "Unmute Breakpoints" : "Mute Breakpoints"}
pressed={muted}
size="small"
iconSize={16}
className={styles.tool}
onClick={() => setMuted(!muted)}
/>
<MoreActions />
<span className={styles.sep} aria-hidden />
<div className={styles.toolbar}>
<Toolbar className={styles.actions} aria-label="Debugger actions">
<ToolButton action="debug.rerun" icon="rerun" />
<ToolButton action="debug.stop" icon="stop" tone="danger" />
<span className={styles.sep} aria-hidden />
<ToolButton action="debug.resume" icon="resume" />
<ToolButton action="debug.pause" icon="pause" />
<ToolButton action="debug.stepOver" icon="step-over" />
<ToolButton action="debug.stepInto" icon="step-into" />
<ToolButton action="debug.stepOut" icon="step-out" />
<span className={styles.sep} aria-hidden />
{rootOf(active).adapter === "dart" && (
<>
<ToolButton action="debug.hotReload" icon="hot-reload" />
<ToolButton action="debug.hotRestart" icon="refresh" />
{rootOf(active).vmServiceUri && <ToolButton action="debug.openDevTools" icon="external-link" />}
<span className={styles.sep} aria-hidden />
</>
)}
<IconButton
icon="view-breakpoints"
action="debug.viewBreakpoints"
size="small"
iconSize={16}
className={styles.tool}
/>
<IconButton
icon="mute-breakpoint"
title={muted ? "Unmute Breakpoints" : "Mute Breakpoints"}
pressed={muted}
size="small"
iconSize={16}
className={styles.tool}
onClick={() => setMuted(!muted)}
/>
<MoreActions />
</Toolbar>
<div role="tablist" aria-label={tx("Debug views")} className={styles.tabs}>
{(
[