Skip to content

Commit 4402995

Browse files
committed
🤖 fix: align TitleBar background with WorkspaceHeader
Changed TitleBar from bg-dark to bg-separator to match WorkspaceHeader and create visual continuity across the top of the app.
1 parent 3556809 commit 4402995

File tree

6 files changed

+18
-9
lines changed

6 files changed

+18
-9
lines changed

src/browser/App.stories.tsx

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,10 @@ function setupMockAPI(options: {
3838
providers: {
3939
setProviderConfig: () => Promise.resolve({ success: true, data: undefined }),
4040
setModels: () => Promise.resolve({ success: true, data: undefined }),
41-
getConfig: () => Promise.resolve({} as Record<string, { apiKeySet: boolean; baseUrl?: string; models?: string[] }>),
41+
getConfig: () =>
42+
Promise.resolve(
43+
{} as Record<string, { apiKeySet: boolean; baseUrl?: string; models?: string[] }>
44+
),
4245
list: () => Promise.resolve([]),
4346
},
4447
workspace: {
@@ -558,7 +561,10 @@ export const ActiveWorkspaceWithChat: Story = {
558561
providers: {
559562
setProviderConfig: () => Promise.resolve({ success: true, data: undefined }),
560563
setModels: () => Promise.resolve({ success: true, data: undefined }),
561-
getConfig: () => Promise.resolve({} as Record<string, { apiKeySet: boolean; baseUrl?: string; models?: string[] }>),
564+
getConfig: () =>
565+
Promise.resolve(
566+
{} as Record<string, { apiKeySet: boolean; baseUrl?: string; models?: string[] }>
567+
),
562568
list: () => Promise.resolve(["anthropic", "openai", "xai"]),
563569
},
564570
workspace: {

src/browser/api.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -233,8 +233,7 @@ const webApi: IPCApi = {
233233
providers: {
234234
setProviderConfig: (provider, keyPath, value) =>
235235
invokeIPC(IPC_CHANNELS.PROVIDERS_SET_CONFIG, provider, keyPath, value),
236-
setModels: (provider, models) =>
237-
invokeIPC(IPC_CHANNELS.PROVIDERS_SET_MODELS, provider, models),
236+
setModels: (provider, models) => invokeIPC(IPC_CHANNELS.PROVIDERS_SET_MODELS, provider, models),
238237
getConfig: () => invokeIPC(IPC_CHANNELS.PROVIDERS_GET_CONFIG),
239238
list: () => invokeIPC(IPC_CHANNELS.PROVIDERS_LIST),
240239
},

src/browser/components/TitleBar.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ export function TitleBar() {
220220
const showUpdateIndicator = true;
221221

222222
return (
223-
<div className="bg-dark border-border-light font-primary text-muted flex shrink-0 items-center justify-between border-b px-4 py-1 text-[11px] select-none">
223+
<div className="bg-separator border-border-light font-primary text-muted flex h-8 shrink-0 items-center justify-between border-b px-4 text-[11px] select-none">
224224
<div className="mr-4 flex min-w-0 items-center gap-2">
225225
{showUpdateIndicator && (
226226
<TooltipWrapper>

src/browser/components/WorkspaceHeader.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ export const WorkspaceHeader: React.FC<WorkspaceHeaderProps> = ({
2828
}, [workspaceId]);
2929

3030
return (
31-
<div className="bg-separator border-border-light flex items-center justify-between border-b px-[15px] py-1 [@media(max-width:768px)]:flex-wrap [@media(max-width:768px)]:gap-2 [@media(max-width:768px)]:py-2 [@media(max-width:768px)]:pl-[60px]">
31+
<div className="bg-separator border-border-light flex h-8 items-center justify-between border-b px-[15px] [@media(max-width:768px)]:h-auto [@media(max-width:768px)]:flex-wrap [@media(max-width:768px)]:gap-2 [@media(max-width:768px)]:py-2 [@media(max-width:768px)]:pl-[60px]">
3232
<div className="text-foreground flex min-w-0 items-center gap-2 overflow-hidden font-semibold">
3333
<WorkspaceStatusDot workspaceId={workspaceId} />
3434
<GitStatusIndicator

src/common/types/ipc.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -248,7 +248,9 @@ export interface IPCApi {
248248
value: string
249249
): Promise<Result<void, string>>;
250250
setModels(provider: string, models: string[]): Promise<Result<void, string>>;
251-
getConfig(): Promise<Record<string, { apiKeySet: boolean; baseUrl?: string; models?: string[] }>>;
251+
getConfig(): Promise<
252+
Record<string, { apiKeySet: boolean; baseUrl?: string; models?: string[] }>
253+
>;
252254
list(): Promise<string[]>;
253255
};
254256
fs?: {

src/node/services/ipcMain.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1539,8 +1539,10 @@ export class IpcMain {
15391539
try {
15401540
const config = this.config.loadProvidersConfig() ?? {};
15411541
// Return a sanitized version (only whether API key is set, not the value)
1542-
const sanitized: Record<string, { apiKeySet: boolean; baseUrl?: string; models?: string[] }> =
1543-
{};
1542+
const sanitized: Record<
1543+
string,
1544+
{ apiKeySet: boolean; baseUrl?: string; models?: string[] }
1545+
> = {};
15441546
for (const [provider, providerConfig] of Object.entries(config)) {
15451547
const baseUrl = providerConfig.baseUrl ?? providerConfig.baseURL;
15461548
const models = providerConfig.models;

0 commit comments

Comments
 (0)