From 35eaaf643150bc0404338d5ac38cd424f27634ba Mon Sep 17 00:00:00 2001 From: Federico Ercoles Date: Wed, 21 Feb 2024 15:47:58 +0100 Subject: [PATCH] Change style of sticky columns padding when using dividers --- .../src/Table/Table.css.ts | 20 ++++++++++++++++--- .../bento-design-system/src/Table/Table.tsx | 12 ++++++++--- 2 files changed, 26 insertions(+), 6 deletions(-) diff --git a/packages/bento-design-system/src/Table/Table.css.ts b/packages/bento-design-system/src/Table/Table.css.ts index 1a5288cb1..494c5cdfb 100644 --- a/packages/bento-design-system/src/Table/Table.css.ts +++ b/packages/bento-design-system/src/Table/Table.css.ts @@ -9,9 +9,23 @@ export const table = style({ isolation: "isolate", }); -export const lastLeftStickyColumn = bentoSprinkles({ - background: "backgroundPrimary", - paddingRight: 8, +export const lastLeftStickyColumn = strictRecipe({ + variants: { + withDividers: { + true: style([ + { + paddingRight: 2, + }, + bentoSprinkles({ + background: "outlineDecorative", + }), + ]), + false: bentoSprinkles({ + background: "backgroundPrimary", + paddingRight: 8, + }), + }, + }, }); export const columnHeader = strictRecipe({ diff --git a/packages/bento-design-system/src/Table/Table.tsx b/packages/bento-design-system/src/Table/Table.tsx index feb29297f..ace3d2676 100644 --- a/packages/bento-design-system/src/Table/Table.tsx +++ b/packages/bento-design-system/src/Table/Table.tsx @@ -585,7 +585,10 @@ function ColumnHeader>({ return ( >({ return ( +