Skip to content

Commit 9d1a5c2

Browse files
committed
fix: Hide tab container from UI, fix theme-aware border colors
- Remove "New Tab Container" from Add menu since multi-tab support is not yet implemented. The schema and rendering code remain for backward compatibility but the feature is not user-creatable until add/remove/rename tab support is built. - Replace all var(--mantine-color-dark-4) borders with var(--mantine-color-default-border) for light theme support. - Replace var(--mantine-color-dark-6) backgrounds in drag overlay with var(--mantine-color-body) for theme awareness.
1 parent 04519f7 commit 9d1a5c2

5 files changed

Lines changed: 15 additions & 18 deletions

File tree

packages/app/src/DBDashboardPage.tsx

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,6 @@ import { notifications } from '@mantine/notifications';
6161
import {
6262
IconArrowsMaximize,
6363
IconBell,
64-
IconBoxMultiple,
6564
IconChartBar,
6665
IconCopy,
6766
IconDeviceFloppy,
@@ -2111,13 +2110,7 @@ function DBDashboardPage({ presetConfig }: { presetConfig?: Dashboard }) {
21112110
>
21122111
New Section
21132112
</Menu.Item>
2114-
<Menu.Item
2115-
data-testid="add-new-tab-menu-item"
2116-
leftSection={<IconBoxMultiple size={16} />}
2117-
onClick={() => handleAddContainer('tab')}
2118-
>
2119-
New Tab Container
2120-
</Menu.Item>
2113+
{/* Tab container hidden until multi-tab support is implemented */}
21212114
<Menu.Item
21222115
data-testid="add-new-group-menu-item"
21232116
leftSection={<IconSquaresDiagonal size={16} />}

packages/app/src/components/DashboardDndContext.tsx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -129,8 +129,8 @@ export function DashboardDndProvider({
129129
<Box
130130
p="xs"
131131
style={{
132-
background: 'var(--mantine-color-dark-6)',
133-
border: '1px solid var(--mantine-color-dark-4)',
132+
background: 'var(--mantine-color-body)',
133+
border: '1px solid var(--mantine-color-default-border)',
134134
borderRadius: 4,
135135
opacity: 0.85,
136136
maxWidth: 280,
@@ -146,8 +146,8 @@ export function DashboardDndProvider({
146146
px="sm"
147147
py={4}
148148
style={{
149-
background: 'var(--mantine-color-dark-6)',
150-
border: '1px solid var(--mantine-color-dark-4)',
149+
background: 'var(--mantine-color-body)',
150+
border: '1px solid var(--mantine-color-default-border)',
151151
borderRadius: 4,
152152
opacity: 0.85,
153153
}}
@@ -223,7 +223,7 @@ export function SectionDropZone({
223223
border: isOver
224224
? '2px dashed var(--mantine-color-blue-5)'
225225
: isEmpty
226-
? '2px dashed var(--mantine-color-dark-4)'
226+
? '2px dashed var(--mantine-color-default-border)'
227227
: undefined,
228228
background: isOver ? 'rgba(51, 154, 240, 0.05)' : undefined,
229229
transition: 'border-color 150ms, background 150ms',

packages/app/src/components/GroupContainer.tsx

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ export default function GroupContainer({
4747
onMouseEnter={() => setHovered(true)}
4848
onMouseLeave={() => setHovered(false)}
4949
style={{
50-
border: '1px solid var(--mantine-color-dark-4)',
50+
border: '1px solid var(--mantine-color-default-border)',
5151
borderRadius: 4,
5252
marginTop: 8,
5353
}}
@@ -57,7 +57,9 @@ export default function GroupContainer({
5757
gap="xs"
5858
px="sm"
5959
py={4}
60-
style={{ borderBottom: '1px solid var(--mantine-color-dark-4)' }}
60+
style={{
61+
borderBottom: '1px solid var(--mantine-color-default-border)',
62+
}}
6163
>
6264
{dragHandleProps && (
6365
<div

packages/app/src/components/SectionHeader.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ export default function SectionHeader({
6262
onMouseEnter={() => setHovered(true)}
6363
onMouseLeave={() => setHovered(false)}
6464
style={{
65-
borderBottom: '1px solid var(--mantine-color-dark-4)',
65+
borderBottom: '1px solid var(--mantine-color-default-border)',
6666
userSelect: 'none',
6767
}}
6868
data-testid={`section-header-${section.id}`}

packages/app/src/components/TabContainer.tsx

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ export default function TabContainer({
5454
onMouseEnter={() => setHovered(true)}
5555
onMouseLeave={() => setHovered(false)}
5656
style={{
57-
border: '1px solid var(--mantine-color-dark-4)',
57+
border: '1px solid var(--mantine-color-default-border)',
5858
borderRadius: 4,
5959
marginTop: 8,
6060
}}
@@ -64,7 +64,9 @@ export default function TabContainer({
6464
gap="xs"
6565
px="sm"
6666
py={4}
67-
style={{ borderBottom: '1px solid var(--mantine-color-dark-4)' }}
67+
style={{
68+
borderBottom: '1px solid var(--mantine-color-default-border)',
69+
}}
6870
>
6971
{editing ? (
7072
<form

0 commit comments

Comments
 (0)