fix(components): [message] the value of exposeProxy may be null (#9378)

* fix(components): [message] the value of exposeProxy may be null

* feat: use exposed
This commit is contained in:
btea
2022-08-24 19:47:44 +08:00
committed by GitHub
parent 4da4e7eb73
commit ad940b5913
2 changed files with 2 additions and 2 deletions

View File

@@ -26,5 +26,5 @@ export const getInstance = (id: string) => {
export const getLastOffset = (id: string): number => {
const { prev } = getInstance(id)
if (!prev) return 0
return prev.vm.exposeProxy!.bottom
return prev.vm.exposed!.bottom.value
}

View File

@@ -117,7 +117,7 @@ const createMessage = (
// instead of calling the onClose function directly, setting this value so that we can have the full lifecycle
// for out component, so that all closing steps will not be skipped.
close: () => {
vm.exposeProxy!.visible = false
vm.exposed!.visible.value = false
},
}