From 2b195ff8492c76d1379a3009cd6f631516ba6caa Mon Sep 17 00:00:00 2001 From: KumJungMin Date: Wed, 16 Oct 2024 21:45:16 +0900 Subject: [PATCH] fix: set this.target to document.activeElement when this.target is empty --- packages/primevue/src/confirmpopup/ConfirmPopup.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/primevue/src/confirmpopup/ConfirmPopup.vue b/packages/primevue/src/confirmpopup/ConfirmPopup.vue index d96a99742..20afdae90 100644 --- a/packages/primevue/src/confirmpopup/ConfirmPopup.vue +++ b/packages/primevue/src/confirmpopup/ConfirmPopup.vue @@ -176,7 +176,7 @@ export default { this.autoFocusAccept = this.confirmation.defaultFocus === undefined || this.confirmation.defaultFocus === 'accept' ? true : false; this.autoFocusReject = this.confirmation.defaultFocus === 'reject' ? true : false; - this.target = document.activeElement; + this.target = this.target || document.activeElement; this.bindOutsideClickListener(); this.bindScrollListener();