diff --git a/package.json b/package.json
index db3e44d982be78869d20204d48e8568ee6bab642..5b7674adeafb1458d49b8f03c5069cac63b894e7 100755
--- a/package.json
+++ b/package.json
@@ -91,7 +91,6 @@
},
"lint-staged": {
"**/*.{js,jsx}": "lint-staged:js",
- "**/*.less": "stylelint --syntax less",
- "src/**/demo/*.md": "lint-staged:demo"
+ "**/*.less": "stylelint --syntax less"
}
}
diff --git a/src/components/Charts/Icon/index.js b/src/components/Charts/Icon/index.js
index d03a3e383f0c06a591339626453c9c7c2732cae1..668b88280f44e322f7c8bf2bc44babc257159db0 100644
--- a/src/components/Charts/Icon/index.js
+++ b/src/components/Charts/Icon/index.js
@@ -1,24 +1,24 @@
import React from 'react';
import { Icon } from 'antd';
+import classNames from 'classnames';
+import styles from './index.less';
-const IconUp = ({ color }) => (
+const IconUp = ({ color, className, ...rest }) => (
);
-const IconDown = ({ color }) => (
+const IconDown = ({ color, className, ...rest }) => (
);
diff --git a/src/components/Charts/Icon/index.less b/src/components/Charts/Icon/index.less
new file mode 100644
index 0000000000000000000000000000000000000000..4009f23941b86e592070221fe935cc26746bd8f2
--- /dev/null
+++ b/src/components/Charts/Icon/index.less
@@ -0,0 +1,15 @@
+@import "~antd/lib/style/themes/default.less";
+
+.normal {
+ color: @text-color-secondary;
+ font-size: 12px;
+ transform: scale(83%);
+}
+
+.up {
+ color: @green-6;
+}
+
+.down {
+ color: @red-6;
+}
diff --git a/src/components/Charts/NumberInfo/index.js b/src/components/Charts/NumberInfo/index.js
index 507d9d5e77a5c8495296971a42c5efc69c60deca..2f467ee3cfb1a7909a4e57db2be7c147ebc77680 100644
--- a/src/components/Charts/NumberInfo/index.js
+++ b/src/components/Charts/NumberInfo/index.js
@@ -22,8 +22,8 @@ export default ({ theme, title, subTitle, total, subTotal, status, suffix, ...re
{
(status || subTotal) && (
- {status && }
{subTotal}
+ {status && }
)
}
diff --git a/src/components/Charts/NumberInfo/index.less b/src/components/Charts/NumberInfo/index.less
index 0ee56f91c00a61dabce0575bfc59aec3d11f92e5..8f221d9c93cb425169de29143e31c4b044e070f6 100644
--- a/src/components/Charts/NumberInfo/index.less
+++ b/src/components/Charts/NumberInfo/index.less
@@ -9,12 +9,15 @@
margin-left: 4px;
}
h4 {
- color: @heading-color;
+ color: @text-color;
+ font-size: @font-size-lg;
margin-bottom: 16px;
+ transition: all .3s;
}
h6 {
color: @text-color-secondary;
font-size: @font-size-base;
+ font-weight: normal;
height: 22px;
line-height: 22px;
.textOverflow();
@@ -33,12 +36,13 @@
}
.subTotal {
color: @text-color-secondary;
- font-size: @font-size-base;
+ font-size: @font-size-lg;
vertical-align: top;
+ margin-right: 0;
i {
font-size: 12px;
transform: scale(0.82);
- margin-right: 4px;
+ margin-left: 4px;
}
}
}
diff --git a/src/components/Charts/Pie/index.less b/src/components/Charts/Pie/index.less
index a9182749b18d988651ba14d47196b6a765b37707..f0051a9758be6cae5dbd053ecb832c9ed284daa7 100644
--- a/src/components/Charts/Pie/index.less
+++ b/src/components/Charts/Pie/index.less
@@ -45,7 +45,7 @@
right: 0;
}
.title {
- margin-bottom: 16px;
+ margin-bottom: 8px;
}
.total {
opacity: 0;
diff --git a/src/components/Charts/Trend/index.js b/src/components/Charts/Trend/index.js
index a0de08343a5476c89a3458db62b37eaec29848f2..09be71e4b0cdbab14090a61a3ef074ddb46de27f 100644
--- a/src/components/Charts/Trend/index.js
+++ b/src/components/Charts/Trend/index.js
@@ -1,74 +1,23 @@
import React from 'react';
-import PropTypes from 'prop-types';
-import classNames from 'classnames';
-import { Icon, Tooltip } from 'antd';
+import { Icon } from 'antd';
import styles from './index.less';
-const Item = ({ title, flag, children, ...rest }, { mini }) => {
- const map = {
- xs: 0,
- sm: 0,
- md: 0,
- lg: 0,
- xlg: 0,
- xl: 0,
- xxl: 0,
- };
-
- if (mini && mini.forEach) {
- mini.forEach((size) => {
- map[size] = 1;
- });
- }
-
- const clsObj = {};
- Object.keys(map).forEach((k) => {
- clsObj[styles[k]] = map[k];
- });
-
- const clsString = classNames(styles.trendItem, {
- [styles.mini]: (typeof mini === 'boolean' && mini),
- ...clsObj,
- });
-
- const miniContent = (
-
- {title}
- { flag && }
-
- );
-
+const Item = ({ title, flag, children, ...rest }) => {
return (
-
+
{title}
{children}
{flag && }
-
- {miniContent}
-
);
};
-Item.contextTypes = {
- mini: PropTypes.oneOfType([
- PropTypes.array,
- PropTypes.bool,
- ]),
-};
-
class Trend extends React.Component {
- getChildContext() {
- return {
- mini: this.props.mini,
- };
- }
-
render() {
- const { colorType, children, mini, ...rest } = this.props;
+ const { colorType, children, ...rest } = this.props;
return (
-
您的账户已被冻结
+
您的账户已被冻结
立即解冻
-
您的账户还不具备申请资格
+
您的账户还不具备申请资格
立即升级
diff --git a/src/index.less b/src/index.less
index 53c89c90da8b23be114f36df1051575ee8727016..5da336e8c149c062b986f0a3aef8b9c0f4a02f0e 100644
--- a/src/index.less
+++ b/src/index.less
@@ -9,9 +9,3 @@ body {
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
-
-:global {
- .ant-tabs-tab-active {
- font-weight: 500;
- }
-}
diff --git a/src/routes/Dashboard/Analysis.js b/src/routes/Dashboard/Analysis.js
index 75f85791dfad020b5333cefec339005794ffcbee..68c391d0a689eb477a8fea6be1b3755237674316 100644
--- a/src/routes/Dashboard/Analysis.js
+++ b/src/routes/Dashboard/Analysis.js
@@ -153,6 +153,7 @@ export default class Analysis extends Component {
dataIndex: 'count',
key: 'count',
sorter: (a, b) => a.count - b.count,
+ className: styles.alignRight,
},
{
title: '周涨幅',
@@ -160,8 +161,16 @@ export default class Analysis extends Component {
key: 'range',
sorter: (a, b) => a.range - b.range,
render: (text, record) => (
-
{text}% {record.status === 1 ? : }
+
+ {text}%
+ {
+ record.status === 1
+ ?
+ :
+ }
+
),
+ className: styles.alignRight,
},
];
@@ -173,7 +182,7 @@ export default class Analysis extends Component {
{data.cvr * 100}%}
theme={(currentKey !== data.name) && 'light'}
/>
@@ -212,7 +221,7 @@ export default class Analysis extends Component {
footer={}
contentHeight={46}
>
-
+
12%
11%
@@ -256,7 +265,7 @@ export default class Analysis extends Component {
action={}
total="78%"
footer={
-
+
12.3%
11%
@@ -347,7 +356,14 @@ export default class Analysis extends Component {
搜索用户数 }
+ subTitle={
+
+ 搜索用户数
+
+
+
+
+ }
total={numeral(12321).format('0,0')}
status="up"
subTotal={17.1}
@@ -374,7 +390,7 @@ export default class Analysis extends Component {
record.index}
- size="middle"
+ size="small"
columns={columns}
dataSource={searchData}
pagination={{
@@ -405,7 +421,7 @@ export default class Analysis extends Component {
)}
style={{ marginTop: 24 }}
>
-
+
-
+
-
您的账户已被冻结
+
您的账户已被冻结
立即解冻
-
您的账户还不具备申请资格
+
您的账户还不具备申请资格
立即升级