Skip to content

Commit 2eb6040

Browse files
committed
contentbox optional border color
1 parent 7a1a1ce commit 2eb6040

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

src/app/components/ContentBox.tsx

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ export interface ContentBoxProps {
55
title: string;
66
subtitle?: React.ReactNode;
77
width?: Record<string, string>;
8-
outlineColor: string;
8+
outlineColor?: string;
99
padding?: Partial<SxProps>;
1010
margin?: string | number;
1111
sx?: SxProps;
@@ -22,7 +22,10 @@ export const ContentBox = (
2222
backgroundColor: 'background.default',
2323
color: 'text.primary',
2424
borderRadius: '6px',
25-
border: `2px solid ${props.outlineColor}`,
25+
border:
26+
props.outlineColor != null
27+
? `2px solid ${props.outlineColor}`
28+
: 'none',
2629
p: props.padding ?? 5,
2730
m: props.margin ?? 0,
2831
fontSize: '18px',

src/app/screens/Feed/FeedView.tsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -432,10 +432,11 @@ export default async function FeedView({
432432
for debugging and managing feed data
433433
</>
434434
}
435-
outlineColor='background.paper'
436435
sx={{ mt: 4, backgroundColor: 'background.paper' }}
437436
>
438-
<RevalidateCacheButton feedId={feed.id ?? ''} />
437+
{feed?.id != null && feed?.id !== '' && (
438+
<RevalidateCacheButton feedId={feed.id} />
439+
)}
439440
</ContentBox>
440441
)}
441442
</Container>

0 commit comments

Comments
 (0)