-
-
Notifications
You must be signed in to change notification settings - Fork 16.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug Report] Dialog closed without transition if update value in close event #1216
Comments
https://element-plus.org/#/zh-CN/component/dialog Dunno what happened but doc site is working fine. I'll verify it locally. |
Confirmed locally, will fix. |
I double checked the code. <span>需要注意的是内容是默认不居中的{{counter}}</span> The transition closes immediately. |
I found it works correctly in element-plus@1.0.1-beta.18 and previous versions. |
Same version of |
I double checked the code, before v1.0.1-beta.18, we emit |
I changed |
I see. Thanks for your help. |
Confirmed as a |
The fix is rather simple, we can switch |
bug reportwhen swith page , auto select checkbox not workfull code<template>
<el-dialog title="角色人员关联" v-model="showtb" width="55%" destroy-on-close>
<el-table ref="tb1" border style="width: 100%" :data="tb1Data">
<el-table-column type="selection" width="80" />
<el-table-column prop="id" label="id" width="100" />
</el-table>
<el-button @click="test1" type="primary" size="small"> test1 </el-button>
<el-button @click="test2" type="primary" size="small"> test2 </el-button>
</el-dialog>
</template>
<script setup lang="ts">
import { ref } from "vue";
const arr = [{ id: 1 }, { id: 2 }];
const showtb = ref(true);
const tb1 = ref(null);
const tb1Data = ref([]);
tb1Data.value = [...arr];
let num = 3;
function test1() {
// mock switch page
const a = { id: num };
num++;
{
// good-mode
tb1Data.value.push(a);
}
{
// bad-mode
arr.push(a);
tb1Data.value = [...arr];
}
test2();
}
function test2() {
tb1.value.toggleRowSelection(tb1Data.value[1], true);
}
</script> with this code
checkbox will select with this code
checkbox won't select |
@JeremyWuuuuu 解决办法为: 不知道这算不算个bug |
New version of vue has been released. If still has problem, please reopen this issue. |
Element Plus version
1.0.1-beta.22
OS/Browsers version
Google Chrome 87.0.4280.141
Vue version
3.0.5
Reproduction Link
https://codepen.io/xyorz/pen/ExgRvZO
Steps to reproduce
1.open dialog.
2.close dialog.
It works in vue@3.0.3 but not as well as vue@3.0.4 and later.
I'm not quite sure this bug is caused by element-plus or vue.
What is Expected?
Dialog closed with transition.
What is actually happening?
Dialog closed without transition.
The text was updated successfully, but these errors were encountered: