Skip to content

Commit 9abb1d8

Browse files
committed
more styling changes
1 parent 61f8812 commit 9abb1d8

File tree

2 files changed

+13
-11
lines changed

2 files changed

+13
-11
lines changed

src/features/feeds/components/ExpandableTableWrapper.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,13 +36,13 @@ export const ExpandableTableWrapper = ({
3636
}: ExpandableTableWrapperProps) => {
3737
const [isExpanded, setIsExpanded] = useState(defaultExpanded)
3838

39-
// If expansion is not allowed, always show content without header
39+
// If expansion is not allowed, still wrap content but without the header
4040
if (!allowExpansion) {
41-
return <>{children}</>
41+
return <div className={tableStyles.tableContainer}>{children}</div>
4242
}
4343

4444
return (
45-
<div>
45+
<div className={tableStyles.expandableWrapper}>
4646
<div
4747
className={tableStyles.expandableHeader}
4848
onClick={() => setIsExpanded(!isExpanded)}

src/features/feeds/components/Tables.module.css

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -49,23 +49,25 @@
4949
margin-right: var(--space-1x);
5050
}
5151

52-
/* Expandable header */
52+
/* Expandable wrapper and header */
53+
.expandableWrapper {
54+
background-color: var(--gray-50);
55+
border-radius: var(--border-radius);
56+
padding: var(--space-3x);
57+
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
58+
}
59+
5360
.expandableHeader {
5461
display: flex;
5562
align-items: center;
5663
gap: var(--space-2x);
57-
padding: var(--space-3x);
5864
cursor: pointer;
59-
background-color: var(--gray-50);
60-
border-radius: var(--border-radius);
61-
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
6265
transition: all 0.2s ease;
6366
user-select: none;
6467
}
6568

66-
.expandableHeader:hover {
67-
background-color: var(--gray-100) !important;
68-
box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15) !important;
69+
.expandableWrapper:hover .expandableHeader {
70+
opacity: 0.9;
6971
}
7072

7173
.expandableHeader:focus-visible {

0 commit comments

Comments
 (0)