${this.renderContextBar()}
- ${state.workspacePanelCollapsed ? this.renderExpandWorkspacePanelButton() : null}
@@ -1246,6 +1256,7 @@ export class PiWebApp extends LitElement {
${state.authDialog !== undefined ? html`
{ void this.auth.chooseLoginMethod(authType); }} .onSelectProvider=${(providerId: string, authType: "oauth" | "api_key") => { void this.auth.selectLoginProvider(providerId, authType); }} .onApiKeyInput=${(value: string) => { this.auth.updateApiKey(value); }} .onSaveApiKey=${() => { void this.auth.saveApiKey(); }} .onLogoutProvider=${(providerId: string) => { void this.auth.logoutProvider(providerId); }} .onOAuthInput=${(value: string) => { this.auth.updateOAuthInput(value); }} .onOAuthRespond=${(value?: string) => { void this.auth.respondOAuth(value); }} .onOAuthCancel=${() => { void this.auth.cancelOAuth(); }} .onCancel=${() => { this.auth.closeDialog(); }}>` : null}
` : html`
${this.sessionEmptyMessage()}
`}
+ ${this.renderWorkspacePanelEdgeControl()}
${this.renderWorkspacePanel()}
${state.actionPaletteOpen ? html`
{ this.setState({ actionPaletteOpen: false }); this.runAction(action); }} .onCancel=${() => { this.setState({ actionPaletteOpen: false }); }}>` : null}
${state.projectDialogOpen ? html`
this.projects.addProject(path, create)} .onCancel=${() => { this.setState({ projectDialogOpen: false }); }}>` : null}
diff --git a/src/client/src/components/WorkspacePanel.ts b/src/client/src/components/WorkspacePanel.ts
index 0cbdfd8..826b293 100644
--- a/src/client/src/components/WorkspacePanel.ts
+++ b/src/client/src/components/WorkspacePanel.ts
@@ -20,7 +20,6 @@ export class WorkspacePanel extends LitElement {
@property({ attribute: false }) workspaceLabelItems: WorkspaceLabelItem[] = [];
@property({ type: Boolean }) hideToolTabs = false;
@property({ attribute: false }) onSelectTool: (tool: QualifiedContributionId) => void = () => undefined;
- @property({ attribute: false }) onToggleCollapse: () => void = () => undefined;
@query(".workspace-header-strip") private workspaceHeaderStrip?: HTMLElement | null;
@state() private workspaceHeaderCanScrollLeft = false;
@state() private workspaceHeaderCanScrollRight = false;
@@ -70,7 +69,6 @@ export class WorkspacePanel extends LitElement {
${visiblePanels.map((panel) => html`
`)}
-
`}
${renderWorkspaceLabel(workspace.label, this.workspaceLabelItems, workspace.path)}
@@ -94,10 +92,6 @@ export class WorkspacePanel extends LitElement {
return html`${panel.title}
${badge}`;
}
- private renderCollapseIcon(): TemplateResult {
- return html`
`;
- }
-
private renderEmptyState(state: WorkspacePanelEmptyState): TemplateResult {
return html`
diff --git a/src/client/src/components/shared.ts b/src/client/src/components/shared.ts
index 7b282cb..d752c74 100644
--- a/src/client/src/components/shared.ts
+++ b/src/client/src/components/shared.ts
@@ -51,15 +51,13 @@ export interface CompletionItem {
export const appStyles = css`
:host { display: block; height: 100dvh; box-sizing: border-box; padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left); color: var(--pi-text); background: var(--pi-bg); font: 14px system-ui, sans-serif; }
- .shell { display: grid; grid-template-columns: 340px minmax(420px, 1fr) minmax(360px, 42vw); height: 100%; min-height: 0; }
- .shell.workspace-panel-collapsed { grid-template-columns: 340px minmax(420px, 1fr); }
- .shell.workspace-panel-collapsed > workspace-panel { display: none; }
- aside { display: flex; flex-direction: column; min-height: 0; border-right: 1px solid var(--pi-border); overflow: hidden; }
+ .shell { display: grid; grid-template-columns: 340px minmax(420px, 1fr) 1px minmax(360px, 42vw); height: 100%; min-height: 0; }
+ aside { grid-column: 1; display: flex; flex-direction: column; min-height: 0; border-right: 1px solid var(--pi-border); overflow: hidden; }
header { flex: 0 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 12px; border-bottom: 1px solid var(--pi-border); }
.header-actions { display: flex; align-items: center; gap: 8px; }
project-list, workspace-list { flex: 0 0 auto; max-height: 26%; overflow: auto; border-bottom: 1px solid var(--pi-border-muted); }
session-list { flex: 1 1 auto; min-height: 0; overflow: auto; }
- main { display: flex; flex-direction: column; min-width: 0; min-height: 0; }
+ main { grid-column: 2; display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.context-bar { position: relative; flex: 0 0 auto; min-width: 0; display: none; align-items: center; gap: 0; padding: 6px 0; border-bottom: 1px solid var(--pi-border-muted); background: var(--pi-bg); }
.context-bar::before, .context-bar::after { content: ""; position: absolute; top: 0; bottom: 0; z-index: 2; width: 20px; opacity: 0; pointer-events: none; transition: opacity .15s ease; }
.context-bar::before { left: 0; background: linear-gradient(90deg, color-mix(in srgb, var(--pi-shadow-strong) 55%, transparent) 0%, transparent 100%); }
@@ -95,28 +93,30 @@ export const appStyles = css`
.mobile-navigation-tab, .mobile-navigation-panel { display: none; }
.mobile-tabs button.selected { border-color: var(--pi-accent); background: var(--pi-selection-bg); }
.tab-badge { display: inline-block; min-width: 14px; margin-left: 4px; border: 1px solid var(--pi-success-border); border-radius: 999px; background: var(--pi-success-surface); color: var(--pi-success); padding: 0 5px; font-size: 11px; line-height: 16px; text-align: center; }
- .expand-panel-strip { flex: 0 0 auto; display: flex; align-items: center; justify-content: flex-end; padding: 4px 8px; border-bottom: 1px solid var(--pi-border-muted); }
- .expand-workspace-panel-button { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; padding: 0; border-radius: 6px; }
- .expand-workspace-panel-button .expand-icon { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; pointer-events: none; }
- workspace-panel { min-width: 0; min-height: 0; border-left: 1px solid var(--pi-border); overflow: hidden; }
+ .workspace-panel-edge { grid-column: 3; min-width: 0; min-height: 0; display: flex; align-items: center; justify-content: center; overflow: visible; background: var(--pi-border-muted); z-index: 2; }
+ .workspace-panel-edge-button { position: relative; z-index: 1; display: grid; place-items: center; width: 18px; height: 48px; padding: 0; border: 1px solid var(--pi-border-muted); border-radius: 999px; background: var(--pi-bg); color: var(--pi-muted); opacity: .75; cursor: pointer; }
+ .workspace-panel-edge-button:hover, .workspace-panel-edge-button:focus-visible { color: var(--pi-text); background: var(--pi-surface-hover); opacity: 1; }
+ .workspace-panel-edge-icon { width: 12px; height: 12px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; pointer-events: none; }
+ workspace-panel { grid-column: 4; min-width: 0; min-height: 0; overflow: hidden; }
+ @media (min-width: 1181px) {
+ .shell.workspace-panel-collapsed { grid-template-columns: 340px minmax(420px, 1fr) 1px; }
+ .shell.workspace-panel-collapsed > workspace-panel { display: none; }
+ }
@media (max-width: 1180px) {
.shell { grid-template-columns: 340px minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr); }
- .shell.workspace-panel-collapsed { grid-template-columns: 340px minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr); }
aside { grid-row: 1 / 3; }
main { grid-column: 2; grid-row: 1 / 3; }
.mobile-tabs-frame { display: flex; }
.shell.workspace-view main { grid-row: 1; min-height: auto; }
.shell.workspace-view > workspace-panel { grid-column: 2; grid-row: 2; display: flex; border-left: 0; }
.shell:not(.workspace-view) > workspace-panel { display: none; }
- .shell.workspace-panel-collapsed > workspace-panel { display: none; }
- .expand-panel-strip { display: none; }
+ .workspace-panel-edge { display: none; }
main.workspace-view chat-view, main.workspace-view prompt-editor, main.workspace-view status-bar,
main.workspace-view .empty { display: none; }
main.workspace-view { overflow: hidden; }
}
@media (max-width: 760px) {
.shell { grid-template-columns: minmax(0, 1fr); }
- .shell.workspace-panel-collapsed { grid-template-columns: minmax(0, 1fr); }
aside { display: none; }
main, .shell.workspace-view > workspace-panel { grid-column: 1; }
.context-bar { display: flex; }
@@ -151,8 +151,6 @@ export const workspacePanelStyles = css`
.workspace-header-strip { display: flex; justify-content: space-between; align-items: center; gap: 8px; min-width: 0; padding: 8px; overflow-x: auto; overflow-y: hidden; overscroll-behavior-x: contain; scrollbar-width: thin; }
.tabs { flex: 0 0 auto; display: flex; gap: 6px; align-items: center; }
.tabs button { flex: 0 0 auto; white-space: nowrap; }
- .collapse-button { display: inline-flex; align-items: center; justify-content: center; width: auto; height: auto; padding: 5px 7px; }
- .collapse-icon { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; pointer-events: none; }
button { display: inline-flex; align-items: center; gap: 5px; border: 1px solid var(--pi-border); border-radius: 7px; background: var(--pi-surface); color: var(--pi-text); padding: 5px 7px; cursor: pointer; }
button.selected { border-color: var(--pi-accent); background: var(--pi-selection-bg); }
.tab-badge { display: inline-block; min-width: 14px; border: 1px solid var(--pi-success-border); border-radius: 999px; background: var(--pi-success-surface); color: var(--pi-success); padding: 0 5px; font-size: 11px; line-height: 16px; text-align: center; }