Skip to content

Commit

Permalink
refactor: layout (#69)
Browse files Browse the repository at this point in the history
* fix: login style

* feat: home
  • Loading branch information
callqh authored May 22, 2024
1 parent c68b689 commit 923d634
Show file tree
Hide file tree
Showing 17 changed files with 4,743 additions and 4,703 deletions.
16 changes: 2 additions & 14 deletions farm.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,22 +4,10 @@ import less from '@farmfe/js-plugin-less';
import postcss from '@farmfe/js-plugin-postcss';
import { theme } from 'antd';
import Pages from 'vite-plugin-pages';
import { adminInfo } from './global.config';
import { adminInfo, theme as themeConfig } from './global.config';

const { getDesignToken } = theme;

const config = {
token: {
colorPrimary: '#9d4edc',
colorInfo: '#9d4edc',
},
cssVar: {
prefix: 'farm',
},
};

const globalToken = getDesignToken(config);
console.log('🤖 == globalToken:', globalToken);
const globalToken = getDesignToken(themeConfig);

export default defineConfig({
compilation: {
Expand Down
20 changes: 19 additions & 1 deletion global.config.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,21 @@
export const adminInfo = {
/**
* 系统信息
*/
const adminInfo = {
title: 'Farm React Admin',
};

/**
* 主题配置
*/
const theme = {
token: {
colorPrimary: '#9d4edc',
colorInfo: '#9d4edc',
},
cssVar: {
prefix: 'farm',
},
};

export { adminInfo, theme };
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
},
"dependencies": {
"@ant-design/icons": "^5.3.7",
"@ant-design/plots": "^2.2.2",
"antd": "^5.17.3",
"classnames": "^2.5.1",
"dayjs": "^1.11.11",
Expand Down
Loading

0 comments on commit 923d634

Please sign in to comment.