import type { CSSProperties } from 'react';
import type { WorkspaceKind } from '../workspaces/workspace';
import { SplitDownIcon, SplitRightIcon } from '../icons';
import { WorkspaceMenu } from './WorkspaceMenu';
type AppTitleBarProps = {
sidebarOpen: boolean;
onToggleSidebar: () => void;
workspaceKind: WorkspaceKind;
onWorkspaceKindChange: (kind: WorkspaceKind) => void;
onSplitRight: () => void;
onSplitDown: () => void;
};
function SidebarToggleIcon({ className }: { className?: string }) {
return (
);
}
/** Window Controls Overlay title bar row (macOS): sits in the OS-defined title bar rectangle. */
const macTitleBarStyle: CSSProperties & { WebkitAppRegion?: 'drag' } = {
WebkitAppRegion: 'drag',
position: 'fixed',
zIndex: 50,
left: 'env(titlebar-area-x, 0px)',
top: 'env(titlebar-area-y, 0px)',
width: 'env(titlebar-area-width, 100%)',
height: 'env(titlebar-area-height, 40px)',
boxSizing: 'border-box',
};
export function AppTitleBar({
sidebarOpen,
onToggleSidebar,
workspaceKind,
onWorkspaceKindChange,
onSplitRight,
onSplitDown,
}: AppTitleBarProps) {
const noDrag = { WebkitAppRegion: 'no-drag' as const };
return (
);
}