diff --git a/src/progress/README.md b/src/progress/README.md index cc5abb263..85a82fa82 100644 --- a/src/progress/README.md +++ b/src/progress/README.md @@ -61,12 +61,12 @@ Use `pivot-text` to custom text,use `color` to custom bar color | Attribute | Description | Type | Default | |------|------|------|------| -| inactive | Whether to be gray | *boolean* | `false` | -| percentage | Percentage | *number* | `0` | +| percentage | Percentage | *number \| string* | `0` | | stroke-width `v2.2.1` | Stroke width | *number \| string* | `4px` | -| show-pivot | Whether to show text | *boolean* | `true` | | color | Color | *string* | `#1989fa` | -| text-color | Text color | *string* | `#fff` | | track-color `v2.2.9` | Track color | *string* | `#e5e5e5` | -| pivot-text | Text | *string* | percentage | -| pivot-color | Text background color | *string* | inherit progress color | +| pivot-text | Pivot text | *string* | percentage | +| pivot-color | Pivot text background color | *string* | inherit progress color | +| text-color | Pivot text color | *string* | `#fff` | +| inactive | Whether to be gray | *boolean* | `false` | +| show-pivot | Whether to show text | *boolean* | `true` | diff --git a/src/progress/README.zh-CN.md b/src/progress/README.zh-CN.md index 08d8e23c1..132285dee 100644 --- a/src/progress/README.zh-CN.md +++ b/src/progress/README.zh-CN.md @@ -64,12 +64,12 @@ Vue.use(Progress); | 参数 | 说明 | 类型 | 默认值 | |------|------|------|------| -| inactive | 是否置灰 | *boolean* | `false` | -| percentage | 进度百分比 | *number* | `0` | +| percentage | 进度百分比 | *number \| string* | `0` | | stroke-width `v2.2.1` | 进度条粗细,默认单位为`px` | *number \| string* | `4px` | -| show-pivot | 是否显示进度文字 | *boolean* | `true` | | color | 进度条颜色 | *string* | `#1989fa` | -| text-color | 进度文字颜色 | *string* | `#fff` | | track-color `v2.2.9` | 轨道颜色 | *string* | `#e5e5e5` | -| pivot-text | 文字显示 | *string* | 百分比文字 | -| pivot-color | 文字背景色 | *string* | 与进度条颜色一致 | +| pivot-text | 进度文字内容 | *string* | 百分比 | +| pivot-color | 进度文字背景色 | *string* | 同进度条颜色 | +| text-color | 进度文字颜色 | *string* | `#fff` | +| inactive | 是否置灰 | *boolean* | `false` | +| show-pivot | 是否显示进度文字 | *boolean* | `true` | diff --git a/src/progress/index.js b/src/progress/index.js index 85f6a7d6d..256589036 100644 --- a/src/progress/index.js +++ b/src/progress/index.js @@ -12,7 +12,7 @@ export default createComponent({ trackColor: String, strokeWidth: [Number, String], percentage: { - type: Number, + type: [Number, String], required: true, validator: value => value >= 0 && value <= 100, },