You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@devlake.apache.org by mi...@apache.org on 2023/12/18 04:19:28 UTC
(incubator-devlake) branch refactor-6307 created (now 3882564ba)
This is an automated email from the ASF dual-hosted git repository.
mintsweet pushed a change to branch refactor-6307
in repository https://gitbox.apache.org/repos/asf/incubator-devlake.git
at 3882564ba refactor(config-ui): use new ui tag component to replace old
This branch includes the following new commits:
new 3882564ba refactor(config-ui): use new ui tag component to replace old
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
(incubator-devlake) 01/01: refactor(config-ui): use new ui tag component to replace old
Posted by mi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
mintsweet pushed a commit to branch refactor-6307
in repository https://gitbox.apache.org/repos/asf/incubator-devlake.git
commit 3882564ba557fedc40960da251b67093298266a7
Author: mintsweet <0x...@gmail.com>
AuthorDate: Mon Dec 18 17:19:14 2023 +1300
refactor(config-ui): use new ui tag component to replace old
---
.../src/pages/blueprint/detail/components/sync-policy/index.tsx | 6 ++----
config-ui/src/pages/blueprint/home/index.tsx | 9 ++-------
config-ui/src/routes/api-keys/api-keys.tsx | 3 +--
config-ui/src/routes/error/components/offline/index.tsx | 3 +--
4 files changed, 6 insertions(+), 15 deletions(-)
diff --git a/config-ui/src/pages/blueprint/detail/components/sync-policy/index.tsx b/config-ui/src/pages/blueprint/detail/components/sync-policy/index.tsx
index 43ab6cae5..1e11d2797 100644
--- a/config-ui/src/pages/blueprint/detail/components/sync-policy/index.tsx
+++ b/config-ui/src/pages/blueprint/detail/components/sync-policy/index.tsx
@@ -19,8 +19,7 @@
import { useState, useEffect, useMemo } from 'react';
import dayjs from 'dayjs';
import type { RadioChangeEvent } from 'antd';
-import { Radio, Space, Checkbox, Input } from 'antd';
-import { Tag } from '@blueprintjs/core';
+import { Radio, Space, Checkbox, Input, Tag } from 'antd';
import { TimePrecision } from '@blueprintjs/datetime';
import { DateInput2 } from '@blueprintjs/datetime2';
@@ -111,8 +110,7 @@ export const SyncPolicy = ({
<Tag
key={i}
style={{ marginRight: 5, cursor: 'pointer' }}
- minimal={formatTime(opt.date) !== formatTime(timeAfter)}
- intent="primary"
+ color={formatTime(opt.date) === formatTime(timeAfter) ? 'blue' : 'default'}
onClick={() => onChangeTimeAfter(dayjs(opt.date).utc().format('YYYY-MM-DD[T]HH:mm:ssZ'))}
>
{opt.label}
diff --git a/config-ui/src/pages/blueprint/home/index.tsx b/config-ui/src/pages/blueprint/home/index.tsx
index 1fc195d35..83c0b4cf9 100644
--- a/config-ui/src/pages/blueprint/home/index.tsx
+++ b/config-ui/src/pages/blueprint/home/index.tsx
@@ -19,8 +19,7 @@
import { useState, useMemo } from 'react';
import { Link } from 'react-router-dom';
import { PlusOutlined, SettingOutlined } from '@ant-design/icons';
-import { Flex, Table, Modal, Radio, Button, Input } from 'antd';
-import { Tag, Intent } from '@blueprintjs/core';
+import { Flex, Table, Modal, Radio, Button, Input, Tag } from 'antd';
import dayjs from 'dayjs';
import API from '@/api';
@@ -184,11 +183,7 @@ export const BlueprintHomePage = () => {
dataIndex: 'enable',
key: 'enable',
align: 'center',
- render: (val) => (
- <Tag minimal intent={val ? Intent.SUCCESS : Intent.DANGER}>
- {val ? 'Enabled' : 'Disabled'}
- </Tag>
- ),
+ render: (val) => <Tag color={val ? 'blue' : 'red'}>{val ? 'Enabled' : 'Disabled'}</Tag>,
},
{
title: '',
diff --git a/config-ui/src/routes/api-keys/api-keys.tsx b/config-ui/src/routes/api-keys/api-keys.tsx
index 96b0eb39b..86e802d7b 100644
--- a/config-ui/src/routes/api-keys/api-keys.tsx
+++ b/config-ui/src/routes/api-keys/api-keys.tsx
@@ -18,8 +18,7 @@
import { useState, useMemo } from 'react';
import { PlusOutlined } from '@ant-design/icons';
-import { Table, Modal, Input, Select, Button } from 'antd';
-import { Tag } from '@blueprintjs/core';
+import { Table, Modal, Input, Select, Button, Tag } from 'antd';
import dayjs from 'dayjs';
import API from '@/api';
diff --git a/config-ui/src/routes/error/components/offline/index.tsx b/config-ui/src/routes/error/components/offline/index.tsx
index a5125beac..09d3e5e43 100644
--- a/config-ui/src/routes/error/components/offline/index.tsx
+++ b/config-ui/src/routes/error/components/offline/index.tsx
@@ -19,8 +19,7 @@
import { useState } from 'react';
import { useNavigate } from 'react-router-dom';
import { CheckCircleOutlined, CloseCircleOutlined, RedoOutlined, QuestionCircleOutlined } from '@ant-design/icons';
-import { Card, Flex, Button } from 'antd';
-import { Tag } from '@blueprintjs/core';
+import { Card, Flex, Button, Tag } from 'antd';
import API from '@/api';
import { DEVLAKE_ENDPOINT } from '@/config';