|
|
@@ -13,7 +13,6 @@
|
|
|
:close-on-press-escape="closeOnPressEscape"
|
|
|
:show-close="showClose"
|
|
|
:before-close="handleBeforeClose"
|
|
|
- :z-index="effectiveZIndex"
|
|
|
v-bind="mergedDialogProps"
|
|
|
@open="handleOpen"
|
|
|
@close="handleClose"
|
|
|
@@ -165,13 +164,14 @@
|
|
|
mergedDialogProps() {
|
|
|
return {
|
|
|
...this.dialogProps,
|
|
|
- 'modal-append-to-body': true,
|
|
|
- 'append-to-body': true,
|
|
|
+ // 保留用户传入的值,不硬编码覆盖
|
|
|
+ 'modal-append-to-body': this.modalAppendToBody,
|
|
|
+ 'append-to-body': this.appendToBody,
|
|
|
}
|
|
|
},
|
|
|
effectiveZIndex() {
|
|
|
- // 使用动态计算的zIndex优先,否则使用传入的zIndex
|
|
|
- return this.zIndex
|
|
|
+ // 确保返回的zIndex值总是有效且足够大
|
|
|
+ return this.currentZIndex || this.zIndex || 2000
|
|
|
},
|
|
|
},
|
|
|
methods: {
|