Skip to content

Commit

Permalink
fix: dialog body class (Tencent#2645)
Browse files Browse the repository at this point in the history
  • Loading branch information
uyarn authored and methodchen committed Aug 25, 2023
1 parent c1d1537 commit c3e918b
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 13 deletions.
4 changes: 3 additions & 1 deletion src/dialog/dialog.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -440,7 +440,9 @@ export default mixins(ActionMixin, getConfigReceiverMixins<Vue, DialogConfig>('d
const closeClassName = this.isFullScreen
? [`${this.componentName}__close`, `${this.componentName}__close--fullscreen`]
: `${this.componentName}__close`;
const bodyClassName = this.theme === 'default' ? [`${this.componentName}__body`] : [`${this.componentName}__body__icon`];
const bodyClassName = this.theme === 'default'
? [`${this.componentName}__body`]
: [`${this.componentName}__body`, `${this.componentName}__body__icon`];

const footerContent = renderTNodeJSX(this, 'footer', defaultFooter);

Expand Down
24 changes: 12 additions & 12 deletions test/snap/__snapshots__/csr.test.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -35240,7 +35240,7 @@ exports[`csr snapshot test > csr test ./src/config-provider/_example/dialog.vue
</span>
</div>
<div
class="t-dialog__body__icon"
class="t-dialog__body t-dialog__body__icon"
>
Would you like to be my friends?
</div>
Expand Down Expand Up @@ -35335,7 +35335,7 @@ exports[`csr snapshot test > csr test ./src/config-provider/_example/dialog.vue
</span>
</div>
<div
class="t-dialog__body__icon"
class="t-dialog__body t-dialog__body__icon"
>
Would you like to be my friends?
</div>
Expand Down Expand Up @@ -35430,7 +35430,7 @@ exports[`csr snapshot test > csr test ./src/config-provider/_example/dialog.vue
</span>
</div>
<div
class="t-dialog__body__icon"
class="t-dialog__body t-dialog__body__icon"
>
Would you like to be my friends?
</div>
Expand Down Expand Up @@ -35525,7 +35525,7 @@ exports[`csr snapshot test > csr test ./src/config-provider/_example/dialog.vue
</span>
</div>
<div
class="t-dialog__body__icon"
class="t-dialog__body t-dialog__body__icon"
>
Would you like to be my friends?
</div>
Expand Down Expand Up @@ -44821,7 +44821,7 @@ exports[`csr snapshot test > csr test ./src/dialog/_example/icon.vue 1`] = `
</span>
</div>
<div
class="t-dialog__body__icon"
class="t-dialog__body t-dialog__body__icon"
>
信息已全部保存,是否确认下单?
</div>
Expand Down Expand Up @@ -44913,7 +44913,7 @@ exports[`csr snapshot test > csr test ./src/dialog/_example/icon.vue 1`] = `
</span>
</div>
<div
class="t-dialog__body__icon"
class="t-dialog__body t-dialog__body__icon"
>
系统重启后会短暂影响页面访问,确认重启吗?
</div>
Expand Down Expand Up @@ -45005,7 +45005,7 @@ exports[`csr snapshot test > csr test ./src/dialog/_example/icon.vue 1`] = `
</span>
</div>
<div
class="t-dialog__body__icon"
class="t-dialog__body t-dialog__body__icon"
>
请检查推送数据是否符合要求
</div>
Expand Down Expand Up @@ -45097,7 +45097,7 @@ exports[`csr snapshot test > csr test ./src/dialog/_example/icon.vue 1`] = `
</span>
</div>
<div
class="t-dialog__body__icon"
class="t-dialog__body t-dialog__body__icon"
>
是否前往查看订单列表
</div>
Expand Down Expand Up @@ -46305,7 +46305,7 @@ exports[`csr snapshot test > csr test ./src/dialog/_example/warning.vue 1`] = `
</span>
</div>
<div
class="t-dialog__body__icon"
class="t-dialog__body t-dialog__body__icon"
>
对话框内容
</div>
Expand Down Expand Up @@ -46390,7 +46390,7 @@ exports[`csr snapshot test > csr test ./src/dialog/_example/warning.vue 1`] = `
</span>
</div>
<div
class="t-dialog__body__icon"
class="t-dialog__body t-dialog__body__icon"
>
对话框内容
</div>
Expand Down Expand Up @@ -46475,7 +46475,7 @@ exports[`csr snapshot test > csr test ./src/dialog/_example/warning.vue 1`] = `
</span>
</div>
<div
class="t-dialog__body__icon"
class="t-dialog__body t-dialog__body__icon"
>
对话框内容
</div>
Expand Down Expand Up @@ -46560,7 +46560,7 @@ exports[`csr snapshot test > csr test ./src/dialog/_example/warning.vue 1`] = `
</span>
</div>
<div
class="t-dialog__body__icon"
class="t-dialog__body t-dialog__body__icon"
>
对话框内容
</div>
Expand Down

0 comments on commit c3e918b

Please sign in to comment.