Skip to content

Commit 96a7281

Browse files
authored
Standardize top bar heights in the app (#1725)
Fixes OPS-3181. ## Additional Notes <img width="1496" height="374" alt="Screenshot 2025-12-03 at 6 57 47 PM" src="https://github.com/user-attachments/assets/2d9b2fb1-1c08-418c-81de-3ae88651186b" />
1 parent e86621d commit 96a7281

5 files changed

Lines changed: 12 additions & 4 deletions

File tree

packages/ui-components/src/components/assistant-ui/assistant-top-bar.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ import { BlockIcon } from '../../components/block-icon/block-icon';
1010
import { TooltipWrapper } from '../../components/tooltip-wrapper';
1111
import { useTypingAnimation } from '../../hooks/use-typing-animation';
1212
import { cn } from '../../lib/cn';
13+
import { TOP_BAR_HEIGHT } from '../../lib/constants';
1314
import { Button } from '../../ui/button';
1415
import { Popover, PopoverContent, PopoverTrigger } from '../../ui/popover';
1516

@@ -64,8 +65,9 @@ const AssistantTopBar = ({
6465
return (
6566
<div
6667
className={cn(
67-
'flex flex-col px-4 py-2 gap-1 flex-shrink-0 text-md dark:text-primary font-bold border-b border-gray-200',
68+
'flex flex-col px-4 py-2 gap-1 flex-shrink-0 text-md dark:text-primary font-bold border-b border-gray-200 justify-center',
6869
)}
70+
style={{ minHeight: `${TOP_BAR_HEIGHT}px` }}
6971
>
7072
<div className="flex justify-between items-center gap-2">
7173
<div className="flex items-center gap-2 flex-1 min-w-0">

packages/ui-components/src/components/page-primitives/page-header.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import { cn } from '../../lib/cn';
2+
import { TOP_BAR_HEIGHT } from '../../lib/constants';
23

34
const PageHeader = ({
45
title,
@@ -11,9 +12,10 @@ const PageHeader = ({
1112
}) => (
1213
<div
1314
className={cn(
14-
'flex items-center justify-between border-b w-full bg-background h-[61px] flex-shrink-0',
15+
'flex items-center justify-between border-b w-full bg-background flex-shrink-0',
1516
className,
1617
)}
18+
style={{ height: `${TOP_BAR_HEIGHT}px` }}
1719
>
1820
<h1 className="text-2xl pl-7">{title}</h1>
1921
{children}

packages/ui-components/src/components/sidebar/side-menu-header.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import { Link } from 'react-router-dom';
22
import { cn } from '../../lib/cn';
3+
import { TOP_BAR_HEIGHT } from '../../lib/constants';
34
import { Tooltip, TooltipTrigger } from '../../ui/tooltip';
45

56
const SideMenuHeader = ({
@@ -13,9 +14,10 @@ const SideMenuHeader = ({
1314
}) => (
1415
<div
1516
className={cn(
16-
'w-full flex items-center px-6 py-[18px] h-[60px] flex-shrink-0',
17+
'w-full flex items-center px-6 py-[18px] flex-shrink-0 border-b',
1718
className,
1819
)}
20+
style={{ height: `${TOP_BAR_HEIGHT}px` }}
1921
>
2022
<Link to="/">
2123
<Tooltip>

packages/ui-components/src/components/sidebar/side-menu-navigation.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ const SideMenuNavigation = ({
1010
links,
1111
isMinimized,
1212
}: SideMenuNavigationProps) => (
13-
<nav className="flex flex-col w-full gap-1 py-3 px-3 border-t">
13+
<nav className="flex flex-col w-full gap-1 py-3 px-3">
1414
{links.map((link, index) => (
1515
<MenuNavigationItem
1616
to={link.to}

packages/ui-components/src/lib/constants.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,3 +37,5 @@ export const PRIMITIVE_STEP_METADATA = {
3737
export const COPY_PASTE_TOAST_DURATION = 2000;
3838

3939
export const AI_CHAT_SCROLL_DELAY = 200;
40+
41+
export const TOP_BAR_HEIGHT = 60;

0 commit comments

Comments
 (0)