Skip to content

The easy-to-use open source Business Intelligence and Embedded Analytics tool that lets everyone work with data :bar_chart:

UXW-2546 Fix permissions table cell background color & borders (#67331)

Gabriel Moreno6d001780439c
diff --git a/frontend/src/metabase/admin/permissions/components/PermissionsTable/PermissionsTable.styled.tsx b/frontend/src/metabase/admin/permissions/components/PermissionsTable/PermissionsTable.styled.tsx
index 8ddf9ee2fb6..b9c56c534f1 100644
--- a/frontend/src/metabase/admin/permissions/components/PermissionsTable/PermissionsTable.styled.tsx
+++ b/frontend/src/metabase/admin/permissions/components/PermissionsTable/PermissionsTable.styled.tsx
@@ -6,23 +6,21 @@ import { forwardRef } from "react";
import Link from "metabase/common/components/Link";
import Label from "metabase/common/components/type/Label";
-import { alpha } from "metabase/lib/colors";
import { Icon, type IconProps } from "metabase/ui";
import { color } from "metabase/ui/utils/colors";
const getTableBorder = (theme: Theme) =>
- `1px solid ${alpha(theme.fn.themeColor("border"), 0.5)}`;
+ `1px solid color-mix(in srgb, ${theme.fn.themeColor("border")}, transparent 50%)`;
// background with 1px of border color at the bottom
// to work properly with sticky positioning
const getHeaderBackground = (theme: Theme) =>
- `linear-gradient(to top, ${alpha(
- theme.fn.themeColor("border"),
- 0.5,
- )}, ${alpha(
- theme.fn.themeColor("border"),
- 0.5,
- )} 1px, var(--mb-color-bg-white) 1px, var(--mb-color-bg-white) 100%)`;
+ `linear-gradient(
+ to top,
+ color-mix(in srgb, ${theme.fn.themeColor("border")} 50%, ${theme.fn.themeColor("bg-white")} 50%) 1px,
+ var(--mb-color-bg-white) 1px,
+ var(--mb-color-bg-white) 100%
+ )`;
export const PermissionsTableRoot = styled.table`
border-collapse: collapse;
@@ -37,6 +35,7 @@ export const PermissionsTableCell = styled.td`
box-sizing: border-box;
min-height: 40px;
overflow: hidden;
+ background: var(--mb-color-bg-white);
&:first-of-type {
max-width: 300px;
@@ -45,6 +44,7 @@ export const PermissionsTableCell = styled.td`
position: sticky;
padding-left: 0;
padding-right: 1.5rem;
+ background: var(--mb-color-bg-white);
&:after {
position: absolute;