From 46b0dfb92cc1211301adfb2f8f7a0ed35db6523c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tu=C4=9F=C3=A7e=20K=C3=BC=C3=A7=C3=BCko=C4=9Flu?= Date: Thu, 3 Aug 2023 16:51:15 +0300 Subject: [PATCH] BlockUI: data-pc-section added for mask --- components/lib/blockui/BlockUI.vue | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/components/lib/blockui/BlockUI.vue b/components/lib/blockui/BlockUI.vue index 905d202d4..ada2f307c 100755 --- a/components/lib/blockui/BlockUI.vue +++ b/components/lib/blockui/BlockUI.vue @@ -33,23 +33,24 @@ export default { block() { let styleClass = 'p-blockui p-component-overlay p-component-overlay-enter'; + this.mask = document.createElement('div'); + this.mask.setAttribute('data-pc-section', 'mask'); + DomHandler.addStyles(this.mask, { + position: 'absolute', + top: '0', + left: '0', + width: '100%', + height: '100%' + }); + if (this.fullScreen) { styleClass += ' p-blockui-document'; - this.mask = document.createElement('div'); !this.isUnstyled && this.mask.setAttribute('class', styleClass); document.body.appendChild(this.mask); DomHandler.addClass(document.body, 'p-overflow-hidden'); document.activeElement.blur(); } else { - this.mask = document.createElement('div'); !this.isUnstyled && this.mask.setAttribute('class', styleClass); - DomHandler.addStyles(this.mask, { - position: 'absolute', - top: '0', - left: '0', - width: '100%', - height: '100%' - }); this.$refs.container.appendChild(this.mask); }