From 77333e4f1032ba76dec071b12efced8920ffa194 Mon Sep 17 00:00:00 2001 From: afc163 Date: Tue, 28 Aug 2018 16:52:36 +0800 Subject: [PATCH] defaultSetting primary color works on theme --- config/config.js | 5 +++-- src/defaultSetting.js | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/config/config.js b/config/config.js index 8008ef4c..2604cc2b 100644 --- a/config/config.js +++ b/config/config.js @@ -1,6 +1,7 @@ // https://umijs.org/config/ const pageRoutes = require('./router.config'); const webpackplugin = require('./plugin.config'); +const defaultSetting = require('../src/defaultSetting'); export default { // add for transfer to umi @@ -30,9 +31,9 @@ export default { ], // 路由配置 routes: pageRoutes, - + // theme for antd theme: { - 'card-actions-background': '#f5f8fa', + 'primary-color': defaultSetting.primaryColor, }, externals: { '@antv/data-set': 'DataSet', diff --git a/src/defaultSetting.js b/src/defaultSetting.js index 8d7aefd6..8873d6a3 100644 --- a/src/defaultSetting.js +++ b/src/defaultSetting.js @@ -1,4 +1,4 @@ -export default { +module.exports = { collapse: false, silderTheme: 'dark', primaryColor: '#1890FF', -- GitLab