From d0fbee324fe1e7e9e09db7011022a00107f13e33 Mon Sep 17 00:00:00 2001 From: Alex Andreev Date: Thu, 19 Jan 2023 12:12:09 +0300 Subject: [PATCH] Add flat TableHead param Signed-off-by: Alex Andreev --- src/renderer/components/table/table-head.scss | 5 +++++ src/renderer/components/table/table-head.tsx | 4 +++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/src/renderer/components/table/table-head.scss b/src/renderer/components/table/table-head.scss index ff9c6afec7..6df8517389 100644 --- a/src/renderer/components/table/table-head.scss +++ b/src/renderer/components/table/table-head.scss @@ -36,4 +36,9 @@ } } } + + &.flat { + background-color: transparent; + font-weight: 600; + } } diff --git a/src/renderer/components/table/table-head.tsx b/src/renderer/components/table/table-head.tsx index d697d38365..6424d43041 100644 --- a/src/renderer/components/table/table-head.tsx +++ b/src/renderer/components/table/table-head.tsx @@ -15,6 +15,7 @@ export interface TableHeadProps extends React.DOMAttributes { showTopLine?: boolean; // show border line at the top sticky?: boolean; // keep header on top when scrolling nowrap?: boolean; // white-space: nowrap, align inner in one line + flat?: boolean; // no header background } export class TableHead extends React.Component { @@ -23,10 +24,11 @@ export class TableHead extends React.Component { }; render() { - const { className, sticky, nowrap, showTopLine, children, ...headProps } = this.props; + const { className, sticky, nowrap, showTopLine, flat, children, ...headProps } = this.props; const classNames = cssNames("TableHead", className, { sticky, nowrap, topLine: showTopLine, + flat, }); return (