Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 12 additions & 2 deletions apps/web/src/components/RightPanelTabs.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -1028,6 +1028,12 @@ function RightPanelTab(
);
}

const PANE_BODY_SURFACE_CLASS: Partial<Record<RightPanelSurface["kind"], string>> = {
"pull-request": "bg-(--code-surface)",
file: "bg-(--code-surface)",
terminal: "bg-(--terminal-background)",
};

export function RightPanelTabs(props: RightPanelTabsProps) {
const focusedSurface = props.surfaces.find((surface) => surface.id === props.activeSurfaceId);
const ownsDesktopTitleBar = isElectron && props.mode === "inline";
Expand Down Expand Up @@ -1455,7 +1461,12 @@ export function RightPanelTabs(props: RightPanelTabsProps) {
"@container/diff-toolbar flex h-[var(--workspace-topbar-height)] min-h-[var(--workspace-topbar-height)] shrink-0 items-center gap-1",
// A layout pane's row lines up with its chat's header and starts at
// the pane's edge, under its notch.
notched ? "relative z-10 ps-1.5 pe-2 md:ps-0" : "pl-2",
notched
? cn(
"relative z-10 ps-1.5 pe-2 md:ps-0",
(focusedSurface && PANE_BODY_SURFACE_CLASS[focusedSurface.kind]) ?? "bg-background",
)
: "pl-2",
!notched && (props.mode === "inline" && !props.layoutControls ? "pr-28" : "pr-3"),
ownsDesktopTitleBar && "drag-region",
ownsDesktopTitleBar && "wco:pr-(--workspace-native-controls-inset)",
Expand All @@ -1465,7 +1476,6 @@ export function RightPanelTabs(props: RightPanelTabsProps) {
)}
data-right-panel-tabbar
data-pane-header={notched ? "" : undefined}
data-floating-pane-header={notched ? "" : undefined}
>
<PanelTabsNotch notched={notched} addButton={addSurfaceMenu}>
{layoutTabId !== null
Expand Down
2 changes: 1 addition & 1 deletion apps/web/src/components/preview/PreviewView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -959,7 +959,7 @@ export function PreviewView({

return (
<div
className="flex min-h-0 flex-1 flex-col bg-background surface-grain"
className="flex min-h-0 flex-1 flex-col bg-background"
data-thread-key={scopedThreadKey(threadRef)}
>
{pickActive && runtimeTabId && annotationVoice ? (
Expand Down
Loading