From df6ecfb4cc7fcacb2468b6f663fa14a48304e847 Mon Sep 17 00:00:00 2001 From: nikogu <644506165@qq.com> Date: Tue, 31 Oct 2017 13:10:26 +0800 Subject: [PATCH] update charts demo --- src/components/AvatarList/demo/simple.md | 8 ++++---- src/components/AvatarList/index.less | 6 +++++- src/components/AvatarList/index.md | 4 ++-- src/components/Charts/ChartCard/index.less | 3 ++- src/components/Charts/MiniProgress/index.js | 2 +- src/components/Charts/demo/chart-card.md | 2 +- src/components/Charts/demo/mini-progress.md | 2 +- src/components/Charts/demo/mix.md | 7 +++---- src/components/Charts/demo/tag-cloud.md | 2 +- 9 files changed, 20 insertions(+), 16 deletions(-) diff --git a/src/components/AvatarList/demo/simple.md b/src/components/AvatarList/demo/simple.md index a9341ff4..f531e162 100644 --- a/src/components/AvatarList/demo/simple.md +++ b/src/components/AvatarList/demo/simple.md @@ -9,10 +9,10 @@ title: 基础样例 import AvatarList from 'ant-design-pro/lib/AvatarList'; ReactDOM.render( - - - - + + + + , mountNode); ```` diff --git a/src/components/AvatarList/index.less b/src/components/AvatarList/index.less index 6330297e..601babd2 100644 --- a/src/components/AvatarList/index.less +++ b/src/components/AvatarList/index.less @@ -10,12 +10,16 @@ } .avatarItem { - border: 1px solid #fff; display: inline-block; font-size: @font-size-base; margin-left: -8px; width: @avatar-size-base; height: @avatar-size-base; + :global { + .ant-avatar { + border: 1px solid #fff; + } + } } .avatarItemLarge { diff --git a/src/components/AvatarList/index.md b/src/components/AvatarList/index.md index ad2b7bc4..275f701e 100644 --- a/src/components/AvatarList/index.md +++ b/src/components/AvatarList/index.md @@ -5,7 +5,7 @@ order: 1 cols: 1 --- -一组用户头像,常用在项目/团队成员列表。 +一组用户头像,常用在项目/团队成员列表。可通过设置 `size` 属性来指定头像大小。 ## API @@ -13,7 +13,7 @@ cols: 1 | 参数 | 说明 | 类型 | 默认值 | |----------|------------------------------------------|-------------|-------| -| size | 头像大小 | `large`、`small` | - | +| size | 头像大小 | `large`、`small` 、`mini`, `default` | `default` | ### AvatarList.Item diff --git a/src/components/Charts/ChartCard/index.less b/src/components/Charts/ChartCard/index.less index 5cda326e..d6bb659e 100644 --- a/src/components/Charts/ChartCard/index.less +++ b/src/components/Charts/ChartCard/index.less @@ -25,6 +25,7 @@ height: 38px; } .content { + margin-bottom: 12px; position: relative; width: 100%; } @@ -37,7 +38,7 @@ .footer { border-top: 1px solid @border-color-split; padding-top: 9px; - margin-top: 20px; + margin-top: 8px; & > * { position: relative; } diff --git a/src/components/Charts/MiniProgress/index.js b/src/components/Charts/MiniProgress/index.js index 2f0fafcd..08fe9b53 100644 --- a/src/components/Charts/MiniProgress/index.js +++ b/src/components/Charts/MiniProgress/index.js @@ -3,7 +3,7 @@ import { Tooltip } from 'antd'; import styles from './index.less'; -const MiniProgress = ({ target, color, strokeWidth, percent }) => ( +const MiniProgress = ({ target, color = 'rgb(19, 194, 194)', strokeWidth, percent }) => (
} + action={} total={yuan(126560)} footer={} contentHeight={46} diff --git a/src/components/Charts/demo/mini-progress.md b/src/components/Charts/demo/mini-progress.md index daca766a..6308a8fa 100644 --- a/src/components/Charts/demo/mini-progress.md +++ b/src/components/Charts/demo/mini-progress.md @@ -7,6 +7,6 @@ title: 迷你进度条 import { MiniProgress } from 'ant-design-pro/lib/Charts'; ReactDOM.render( - + , mountNode); ```` diff --git a/src/components/Charts/demo/mix.md b/src/components/Charts/demo/mix.md index 6273bfe1..c550112d 100644 --- a/src/components/Charts/demo/mix.md +++ b/src/components/Charts/demo/mix.md @@ -37,7 +37,6 @@ ReactDOM.render( /> @@ -46,7 +45,7 @@ ReactDOM.render( } + action={} total={numeral(8846).format('0,0')} footer={} contentHeight={46} @@ -60,7 +59,7 @@ ReactDOM.render( } + action={} total="78%" footer={
@@ -76,7 +75,7 @@ ReactDOM.render( } contentHeight={46} > - + diff --git a/src/components/Charts/demo/tag-cloud.md b/src/components/Charts/demo/tag-cloud.md index c86bdd84..c66f6fe6 100644 --- a/src/components/Charts/demo/tag-cloud.md +++ b/src/components/Charts/demo/tag-cloud.md @@ -11,7 +11,7 @@ import { TagCloud } from 'ant-design-pro/lib/Charts'; const tags = []; for (let i = 0; i < 50; i += 1) { tags.push({ - name: `test-${i}`, + name: `TagClout-Title-${i}`, value: Math.floor((Math.random() * 50)) + 20, }); } -- GitLab