From 05c5272c93f9cabdef392adfc0902be41caa4be3 Mon Sep 17 00:00:00 2001 From: Sammy Teillet Date: Wed, 19 Apr 2023 16:47:34 +0200 Subject: [PATCH] feature: make border transparent instead of 0px --- front/src/components/table/Table.tsx | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/front/src/components/table/Table.tsx b/front/src/components/table/Table.tsx index c504b21dc..eff7a45e3 100644 --- a/front/src/components/table/Table.tsx +++ b/front/src/components/table/Table.tsx @@ -21,25 +21,33 @@ const StyledTable = styled.table` min-width: 100%; border-radius: 4px; border-spacing: 0; + border-collapse: collapse; th { + border-collapse: collapse; color: ${(props) => props.theme.text40}; padding: 0; - border-top: 1px solid ${(props) => props.theme.tertiaryBackground}; - border-bottom: 1px solid ${(props) => props.theme.tertiaryBackground}; + border: 1px solid ${(props) => props.theme.tertiaryBackground}; text-align: left; - :not(:last-child) { - border-right: 1px solid ${(props) => props.theme.tertiaryBackground}; + :last-child { + border-right-color: transparent; + } + :first-child { + border-left-color: transparent; } } td { + border-collapse: collapse; color: ${(props) => props.theme.text80}; padding: 0; - border-bottom: 1px solid ${(props) => props.theme.tertiaryBackground}; + border: 1px solid ${(props) => props.theme.tertiaryBackground}; text-align: left; - :not(:last-child) { - border-right: 1px solid ${(props) => props.theme.tertiaryBackground}; + :last-child { + border-right-color: transparent; + } + :first-child { + border-left-color: transparent; } } `;