fix(components): [el-popover] update popperInstance when props change (#5835)

Co-authored-by: xiaoming <xiaoming@mgtv.com>
This commit is contained in:
QuXiaoMing
2022-02-09 16:05:02 +08:00
committed by GitHub
parent 8c0ce81317
commit 1add6d2c70

View File

@@ -113,6 +113,15 @@ export default defineComponent({
immediate: true,
}
)
watch(
() =>
buildPopperOptions(props, {
arrowEl: unref(arrowRef),
arrowOffset: unref(arrowOffset),
}),
(option) => popperInstanceRef.value?.setOptions(option)
)
})
return {