Skip to content

Commit 2cc9b15

Browse files
fix(clerk-js): Add background color to <PricingTableMatrix /> component (#5417)
1 parent 2dcaf65 commit 2cc9b15

File tree

2 files changed

+10
-2
lines changed

2 files changed

+10
-2
lines changed

.changeset/sad-feet-fail.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@clerk/clerk-js': patch
3+
---
4+
5+
Add background color to `<PricingTableMatrix />` elements to ensure sticky elements cover the scrollable content.

packages/clerk-js/src/ui/components/PricingTable/PricingTableMatrix.tsx

+5-2
Original file line numberDiff line numberDiff line change
@@ -72,15 +72,16 @@ export function PricingTableMatrix({
7272
<InternalThemeProvider>
7373
<Box
7474
elementDescriptor={descriptors.pricingTableMatrixRoot}
75-
sx={{
75+
sx={t => ({
7676
position: 'relative',
7777
minWidth: '100%',
7878
display: 'grid',
7979
isolation: 'isolate',
80+
backgroundColor: t.colors.$colorBackground,
8081
[mqu.md]: {
8182
overflowX: 'auto',
8283
},
83-
}}
84+
})}
8485
>
8586
<Box
8687
elementDescriptor={descriptors.pricingTableMatrixTable}
@@ -92,9 +93,11 @@ export function PricingTableMatrix({
9293
sx={t => ({
9394
position: 'sticky',
9495
top: 0,
96+
backgroundColor: t.colors.$colorBackground,
9597
borderBottomWidth: t.borderWidths.$normal,
9698
borderBottomStyle: t.borderStyles.$solid,
9799
borderBottomColor: t.colors.$neutralAlpha100,
100+
zIndex: 1,
98101
})}
99102
>
100103
<Box

0 commit comments

Comments
 (0)