Skip to content

Commit 3dc0b65

Browse files
docs(user-head): 更新头像组件文档,优化描述信息,移除冗余字段 (#3447)
* docs(user-head): 更新头像组件文档,优化描述信息,移除冗余字段 * docs(user-head): 更新头像组件文档,修正类型描述为图标组件 * docs(user-head): 修正modelValue类型描述为支持组件和字符串
1 parent 6145875 commit 3dc0b65

File tree

2 files changed

+7
-20
lines changed

2 files changed

+7
-20
lines changed

examples/sites/demos/apis/user-head.js

Lines changed: 5 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -79,11 +79,11 @@ export default {
7979
},
8080
{
8181
name: 'modelValue',
82-
type: 'string',
82+
type: Component | 'string',
8383
defaultValue: '',
8484
desc: {
85-
'zh-CN': '设置头像值。',
86-
'en-US': 'Set the profile picture.'
85+
'zh-CN': 'type=icon 时为图标组件,type=label时为字体串,type=image时为资源路径',
86+
'en-US': 'If type is set to icon, it should be an icon component . If type is set to label, it indicates the font string. If type is set to image, it indicates the resource path'
8787
},
8888
mode: ['pc'],
8989
pcDemo: 'basic-usage'
@@ -124,26 +124,13 @@ export default {
124124
pcDemo: 'image-user-head',
125125
mfDemo: ''
126126
},
127-
{
128-
name: 'v-model',
129-
type: 'string',
130-
defaultValue: '',
131-
desc: {
132-
'zh-CN': 'type=icon 时为图标类名,type=label 时为字体串,type=image 时为资源路径',
133-
'en-US':
134-
'If type is set to icon, it indicates the icon class name. If type is set to label, it indicates the font string. If type is set to image, it indicates the resource path'
135-
},
136-
mode: ['pc', 'mobile-first'],
137-
pcDemo: 'icon-user-head',
138-
mfDemo: ''
139-
},
140127
{
141128
name: 'value',
142129
type: 'string',
143130
defaultValue: '',
144131
desc: {
145-
'zh-CN': 'type=icon 时为图标类名,type=label时为字体串,type=image时为资源路径',
146-
'en-US': ''
132+
'zh-CN': 'type=icon 时为图标组件,type=label时为字体串,type=image时为资源路径',
133+
'en-US': 'If type is set to icon, it should be an icon component . If type is set to label, it indicates the font string. If type is set to image, it indicates the resource path'
147134
},
148135
mode: ['mobile-first'],
149136
mfDemo: ''

packages/vue/src/user-head/src/index.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ export const userHeadProps = {
5959

6060
/**
6161
* @property {String} - 头像资源
62-
* type=icon 时为图标类名,type=label时为字体串,type=image时为资源路径
62+
* type=icon 时为图标组件,type=label时为字体串,type=image时为资源路径
6363
*/
6464
value: {
6565
type: [Object, String],
@@ -68,7 +68,7 @@ export const userHeadProps = {
6868

6969
/**
7070
* @property {String} - 头像资源
71-
* type=icon 时为图标类名,type=label时为字体串,type=image时为资源路径
71+
* type=icon 时为图标组件,type=label时为字体串,type=image时为资源路径
7272
*/
7373
modelValue: {
7474
type: [Object, String],

0 commit comments

Comments
 (0)