diff --git a/chat2db-client/src/blocks/Setting/BaseSetting/index.tsx b/chat2db-client/src/blocks/Setting/BaseSetting/index.tsx index ad698722..3829f597 100644 --- a/chat2db-client/src/blocks/Setting/BaseSetting/index.tsx +++ b/chat2db-client/src/blocks/Setting/BaseSetting/index.tsx @@ -46,18 +46,38 @@ const colorList = [ { code: 'polar-green', name: i18n('setting.label.green'), - color: '#1d3712', + color: '#039e74', }, { code: 'golden-purple', name: i18n('setting.label.violet'), - color: '#301c4d', + color: '#9373ee', + }, + { + code: 'blue2', + name: i18n('setting.label.violet'), + color: '#00c3ee', + }, + { + code: 'gold', + name: i18n('setting.label.violet'), + color: '#9a7d56', + }, + { + code: 'silver', + name: i18n('setting.label.violet'), + color: '#8e8374', + }, + { + code: 'red', + name: i18n('setting.label.violet'), + color: '#fd6874', + }, + { + code: 'orange', + name: i18n('setting.label.violet'), + color: '#fa8c16', }, - // { - // code: 'sunset-orange', - // name: '日暮', - // color: "#593815" - // }, ]; // baseBody 基础设置 @@ -128,7 +148,7 @@ export default function BaseSetting() { > {currentPrimaryColor == item.code && } -
{item.name}
+ {/*
{item.name}
*/} ); })} diff --git a/chat2db-client/src/blocks/Setting/index.less b/chat2db-client/src/blocks/Setting/index.less index 338904b8..fa127008 100644 --- a/chat2db-client/src/blocks/Setting/index.less +++ b/chat2db-client/src/blocks/Setting/index.less @@ -7,7 +7,6 @@ .settingIcon { color: var(--custom-color-icon); &:hover { - background-color: var(--color-primary-bg-hover); color: var(--color-primary); } } @@ -71,6 +70,7 @@ } .activeMenu { + color: var(--color-primary); background-color: var(--color-hover-bg); } } diff --git a/chat2db-client/src/components/SearchResult/TableBox/index.less b/chat2db-client/src/components/SearchResult/TableBox/index.less index b26a3cd5..f403fab4 100644 --- a/chat2db-client/src/components/SearchResult/TableBox/index.less +++ b/chat2db-client/src/components/SearchResult/TableBox/index.less @@ -40,7 +40,7 @@ display: flex; justify-content: space-between; align-items: center; - border-top: 1px solid var(--color-border-secondary); + border-bottom: 1px solid var(--color-border-secondary); background-color: var(--color-bg-elevated); padding: 0 16px; height: 30px; diff --git a/chat2db-client/src/components/SearchResult/index.less b/chat2db-client/src/components/SearchResult/index.less index 2f05d03f..3a6bc3fd 100644 --- a/chat2db-client/src/components/SearchResult/index.less +++ b/chat2db-client/src/components/SearchResult/index.less @@ -30,11 +30,11 @@ } .successIcon { - color: rgb(71, 157, 255); + color: var(--color-primary); } .failIcon { - color: red; + color: var(--color-primary); } } diff --git a/chat2db-client/src/constants/theme.ts b/chat2db-client/src/constants/theme.ts index 31a3382b..b553afec 100644 --- a/chat2db-client/src/constants/theme.ts +++ b/chat2db-client/src/constants/theme.ts @@ -8,6 +8,11 @@ export enum PrimaryColorType { Polar_Green = 'polar-green', Golden_Purple = 'golden-purple', Polar_Blue = 'polar-blue', + Silver = 'silver', + Red = 'red', + Orange = 'orange', + Blue2 = 'blue2', + Gold = 'gold', } export enum LangType { diff --git a/chat2db-client/src/pages/main/index.less b/chat2db-client/src/pages/main/index.less index a5a342c7..5805a311 100644 --- a/chat2db-client/src/pages/main/index.less +++ b/chat2db-client/src/pages/main/index.less @@ -73,7 +73,7 @@ .icon { color: var(--color-primary); } - background-color: var(--color-primary-bg-hover); + background-color: var(--color-hover-bg); } } @@ -81,7 +81,7 @@ .icon { color: var(--color-primary); } - background-color: var(--color-primary-bg-hover); + background-color: var(--color-hover-bg); } } @@ -99,7 +99,7 @@ cursor: pointer; color: var(--custom-color-icon); &:hover { - background-color: var(--color-primary-bg-hover); + background-color: var(--color-hover-bg); color: var(--color-primary); } } diff --git a/chat2db-client/src/pages/main/workspace/components/Tree/TreeNodeRightClick/index.tsx b/chat2db-client/src/pages/main/workspace/components/Tree/TreeNodeRightClick/index.tsx index 92436521..af94505e 100644 --- a/chat2db-client/src/pages/main/workspace/components/Tree/TreeNodeRightClick/index.tsx +++ b/chat2db-client/src/pages/main/workspace/components/Tree/TreeNodeRightClick/index.tsx @@ -163,10 +163,8 @@ function TreeNodeRightClick(props: IProps) { ...data, ...data.extraParams }).then(res => { - setTimeout(() => { - data.children = res; - setIsLoading(false); - }, 200); + data.children = res; + setIsLoading(false); }) } diff --git a/chat2db-client/src/pages/main/workspace/components/Tree/index.tsx b/chat2db-client/src/pages/main/workspace/components/Tree/index.tsx index de2272ef..f322261d 100644 --- a/chat2db-client/src/pages/main/workspace/components/Tree/index.tsx +++ b/chat2db-client/src/pages/main/workspace/components/Tree/index.tsx @@ -84,11 +84,9 @@ const TreeNode = dvaModel((props: TreeNodeIProps) => { ...(data.extraParams || {}), }).then(res => { if (res.length) { - setTimeout(() => { - data.children = res; - setShowChildren(true); - setIsLoading(false); - }, 200); + data.children = res; + setShowChildren(true); + setIsLoading(false); } else { // 处理树可能出现不连续的情况 diff --git a/chat2db-client/src/pages/main/workspace/components/WorkspaceHeader/index.less b/chat2db-client/src/pages/main/workspace/components/WorkspaceHeader/index.less index 8cc26b44..be623232 100644 --- a/chat2db-client/src/pages/main/workspace/components/WorkspaceHeader/index.less +++ b/chat2db-client/src/pages/main/workspace/components/WorkspaceHeader/index.less @@ -23,7 +23,9 @@ font-weight: normal; cursor: pointer; color: var(--color-text-secondary); - + &:hover{ + color: var(--color-primary); + } i{ font-size: 14px; } diff --git a/chat2db-client/src/styles/global.less b/chat2db-client/src/styles/global.less index 09511845..be6bd00d 100644 --- a/chat2db-client/src/styles/global.less +++ b/chat2db-client/src/styles/global.less @@ -132,3 +132,10 @@ ol, li { list-style: none; } + + +// 覆盖antd 的一些样式 + +button{ + box-shadow: none !important; +} \ No newline at end of file diff --git a/chat2db-client/src/theme/dark.ts b/chat2db-client/src/theme/dark.ts index e3530aba..f0083f60 100644 --- a/chat2db-client/src/theme/dark.ts +++ b/chat2db-client/src/theme/dark.ts @@ -12,11 +12,26 @@ const antdPrimaryColor: IAntdPrimaryColor = { colorPrimary: '#3c8618', }, [PrimaryColorType.Golden_Purple]: { - colorPrimary: '#51258f', + colorPrimary: '#7688c9', }, [PrimaryColorType.Polar_Blue]: { colorPrimary: '#1677ff', }, + [PrimaryColorType.Silver]: { + colorPrimary: '#c3b7a4', + }, + [PrimaryColorType.Red]: { + colorPrimary: '#fd6874', + }, + [PrimaryColorType.Orange]: { + colorPrimary: '#ffa940', + }, + [PrimaryColorType.Blue2]: { + colorPrimary: '#009cc7', + }, + [PrimaryColorType.Gold]: { + colorPrimary: '#b59a6d', + }, }; const antDarkTheme = { diff --git a/chat2db-client/src/theme/light.ts b/chat2db-client/src/theme/light.ts index 74e87558..0d112f06 100644 --- a/chat2db-client/src/theme/light.ts +++ b/chat2db-client/src/theme/light.ts @@ -9,13 +9,28 @@ type IAntdPrimaryColor = { // 主题色 const antdPrimaryColor: IAntdPrimaryColor = { [PrimaryColorType.Polar_Green]: { - colorPrimary: '#3c8618', + colorPrimary: '#039e74', }, [PrimaryColorType.Golden_Purple]: { - colorPrimary: '#51258f', + colorPrimary: '#9373ee', }, [PrimaryColorType.Polar_Blue]: { - colorPrimary: '#597EF7', + colorPrimary: '#587df1', + }, + [PrimaryColorType.Silver]: { + colorPrimary: '#8e8374', + }, + [PrimaryColorType.Red]: { + colorPrimary: '#fd6874', + }, + [PrimaryColorType.Orange]: { + colorPrimary: '#fa8c16', + }, + [PrimaryColorType.Blue2]: { + colorPrimary: '#00c3ee', + }, + [PrimaryColorType.Gold]: { + colorPrimary: '#9a7d56', }, };