Browse Source

style: Table 选择颜色修改

pull/137/head
cp3hnu 1 year ago
parent
commit
66c4774939
6 changed files with 20 additions and 19 deletions
  1. +2
    -9
      react-ui/src/app.tsx
  2. +1
    -1
      react-ui/src/components/RobotFrame/index.less
  3. +5
    -3
      react-ui/src/components/SubAreaTitle/index.tsx
  4. +6
    -0
      react-ui/src/overrides.less
  5. +1
    -1
      react-ui/src/pages/Experiment/Comparison/index.less
  6. +5
    -5
      react-ui/src/pages/Workspace/components/ExperimentChart/index.tsx

+ 2
- 9
react-ui/src/app.tsx View File

@@ -118,18 +118,10 @@ export const layout: RuntimeConfig['layout'] = ({ initialState }) => {
width: '331px',
},
],
// links: isDev
// ? [
// <Link key="openapi" to="/umi/plugin/openapi" target="_blank">
// <LinkOutlined />
// <span>OpenAPI 文档</span>
// </Link>,
// ]
// : [],
// 自定义 403 页面
// unAccessible: <div>unAccessible</div>,
// 增加一个 loading 的状态
childrenRender: (children) => {
// 增加一个 loading 的状态
// if (initialState?.loading) return <PageLoading />;
return (
<div className="kf-page-container">
@@ -236,6 +228,7 @@ export const antd: RuntimeAntdConfig = (memo) => {
memo.theme.components.Table = {
headerBg: 'rgba(242, 244, 247, 0.36)',
headerBorderRadius: 4,
rowSelectedBg: 'rgba(22, 100, 255, 0.05)',
};
memo.theme.components.Tabs = {
titleFontSize: 16,


+ 1
- 1
react-ui/src/components/RobotFrame/index.less View File

@@ -23,7 +23,7 @@
width: 100%;
height: 60px;
padding: 0 15px;
border-bottom: 1px solid #e8e8e8;
border-bottom: 1px solid @border-color-base;
}

&__iframe {


+ 5
- 3
react-ui/src/components/SubAreaTitle/index.tsx View File

@@ -9,7 +9,7 @@ import './index.less';

type SubAreaTitleProps = {
title: string;
image: string;
image?: string;
style?: React.CSSProperties;
className?: string;
};
@@ -17,8 +17,10 @@ type SubAreaTitleProps = {
function SubAreaTitle({ title, image, style, className }: SubAreaTitleProps) {
return (
<div className={classNames('kf-subarea-title', className)} style={style}>
<img src={image} width={14} draggable={false} alt="" />
<span style={{ marginLeft: '8px' }}>{title}</span>
{image && (
<img src={image} width={18} draggable={false} alt="" style={{ marginRight: '8px' }} />
)}
<span>{title}</span>
</div>
);
}


+ 6
- 0
react-ui/src/overrides.less View File

@@ -79,6 +79,12 @@
background-color: #fff;
}

.ant-table-row-selected {
.ant-table-cell {
color: @primary-color;
}
}

.ant-pro-page-container {
overflow-y: auto;
}


+ 1
- 1
react-ui/src/pages/Experiment/Comparison/index.less View File

@@ -25,7 +25,7 @@
.ant-table-thead {
.ant-table-cell {
background-color: rgb(247, 247, 247);
border-color: #e8e8e8 !important;
border-color: @border-color-base !important;
}
}
.ant-table-tbody {


+ 5
- 5
react-ui/src/pages/Workspace/components/ExperimentChart/index.tsx View File

@@ -153,11 +153,11 @@ function ExperimentChart({ chartData, style }: ExperimentChartProps) {
show: false,
},
data: [
{ value: chartData.Failed > 0 ? chartData.Failed : null, name: '失败' },
{ value: chartData.Succeeded > 0 ? chartData.Succeeded : null, name: '成功' },
{ value: chartData.Terminated > 0 ? chartData.Terminated : null, name: '中止' },
{ value: chartData.Pending > 0 ? chartData.Pending : null, name: '等待' },
{ value: chartData.Running > 0 ? chartData.Running : null, name: '运行中' },
{ value: chartData.Failed > 0 ? chartData.Failed : undefined, name: '失败' },
{ value: chartData.Succeeded > 0 ? chartData.Succeeded : undefined, name: '成功' },
{ value: chartData.Terminated > 0 ? chartData.Terminated : undefined, name: '中止' },
{ value: chartData.Pending > 0 ? chartData.Pending : undefined, name: '等待' },
{ value: chartData.Running > 0 ? chartData.Running : undefined, name: '运行中' },
],
},
{


Loading…
Cancel
Save