diff --git a/examples/docs/en-US/dialog.md b/examples/docs/en-US/dialog.md index ae5755149..0b283a788 100644 --- a/examples/docs/en-US/dialog.md +++ b/examples/docs/en-US/dialog.md @@ -160,7 +160,7 @@ The content of Dialog can be anything, even a table or a form. This example show | Attribute | Description | Type | Accepted Values | Default | |---------- |-------------- |---------- |-------------------------------- |-------- | -| title | title of Dialog | string | — | — | +| title | title of Dialog. Can also be passed with a named slot (see the following table) | string | — | — | | size | size of Dialog | string | tiny/small/large/full | small | | top | value for `top` of Dialog CSS, works when `size` is not `full` | string | — | 15% | | modal | whether a mask is displayed | boolean | — | true | @@ -175,6 +175,7 @@ The content of Dialog can be anything, even a table or a form. This example show | Name | Description | |------|--------| | — | content of Dialog | +| title | content of the Dialog title | | footer | content of the Dialog footer | ### Methods diff --git a/examples/docs/zh-CN/dialog.md b/examples/docs/zh-CN/dialog.md index 6833e3760..e4bd34d40 100644 --- a/examples/docs/zh-CN/dialog.md +++ b/examples/docs/zh-CN/dialog.md @@ -179,9 +179,9 @@ Dialog 组件的内容可以是任意的,甚至可以是表格或表单,下 ### Attributes | 参数 | 说明 | 类型 | 可选值 | 默认值 | |---------- |-------------- |---------- |-------------------------------- |-------- | -| title | Dialog 的标题 | string | — | — | +| title | Dialog 的标题,也可通过具名 slot (见下表)传入 | string | — | — | | size | Dialog 的大小 | string | tiny/small/large/full | small | -| top | Dialog CSS 中的 top 值(仅在 size 不为 full 时有效) | string | — | 15% | +| top | Dialog CSS 中的 top 值(仅在 size 不为 full 时有效) | string | — | 15% | | modal | 是否需要遮罩层 | boolean | — | true | | lock-scroll | 是否在 Dialog 出现时将 body 滚动锁定 | boolean | — | true | | custom-class | Dialog 的自定义类名 | string | — | — | @@ -193,6 +193,7 @@ Dialog 组件的内容可以是任意的,甚至可以是表格或表单,下 | name | 说明 | |------|--------| | — | Dialog 的内容 | +| title | Dialog 标题区的内容 | | footer | Dialog 按钮操作区的内容 | ### 方法 diff --git a/packages/dialog/src/component.vue b/packages/dialog/src/component.vue index 080bff6e1..7f7c8e30b 100644 --- a/packages/dialog/src/component.vue +++ b/packages/dialog/src/component.vue @@ -7,7 +7,9 @@ ref="dialog" :style="style">
- {{title}} + + {{title}} +