claude-web/node_modules/primevue/blockui/index.mjs.map

1 line
13 KiB
Plaintext
Raw Normal View History

2026-02-23 02:23:38 +00:00
{"version":3,"file":"index.mjs","sources":["../../src/blockui/BaseBlockUI.vue","../../src/blockui/BlockUI.vue","../../src/blockui/BlockUI.vue?vue&type=template&id=15a749d8&lang.js"],"sourcesContent":["<script>\nimport BaseComponent from '@primevue/core/basecomponent';\nimport BlockUIStyle from 'primevue/blockui/style';\n\nexport default {\n name: 'BaseBlockUI',\n extends: BaseComponent,\n props: {\n blocked: {\n type: Boolean,\n default: false\n },\n fullScreen: {\n type: Boolean,\n default: false\n },\n baseZIndex: {\n type: Number,\n default: 0\n },\n autoZIndex: {\n type: Boolean,\n default: true\n }\n },\n style: BlockUIStyle,\n provide() {\n return {\n $pcBlockUI: this,\n $parentInstance: this\n };\n }\n};\n</script>\n","<template>\n <div ref=\"container\" :class=\"cx('root')\" :aria-busy=\"isBlocked\" v-bind=\"ptmi('root')\">\n <slot></slot>\n </div>\n</template>\n\n<script>\nimport { addClass, createElement, hasCSSAnimation } from '@primeuix/utils/dom';\nimport { ZIndex } from '@primeuix/utils/zindex';\nimport { blockBodyScroll, unblockBodyScroll } from 'primevue/utils';\nimport BaseBlockUI from './BaseBlockUI.vue';\n\nexport default {\n name: 'BlockUI',\n extends: BaseBlockUI,\n inheritAttrs: false,\n emits: ['block', 'unblock'],\n mask: null,\n data() {\n return {\n isBlocked: false\n };\n },\n watch: {\n blocked(newValue) {\n if (newValue === true) this.block();\n else this.unblock();\n }\n },\n mounted() {\n if (this.blocked) {\n this.block();\n }\n },\n methods: {\n block() {\n let styleClass = 'p-blockui-mask p-overlay-mask p-overlay-mask-enter-active';\n\n if (this.fullScreen) {\n styleClass += ' p-blockui-mask-document';\n\n this.mask = createElement('div', {\n style: {\n position: 'fixed',\n top: '0',\n left: '0',\n width: '100%',\n height: '100%'\n },\n class: !this.isUnstyled && styleClass,\n 'p-bind': this.ptm('mask')\n });\n\n document.body.appendChild(this.mask);\n blockBodyScroll();\n document.activeElement.blur();\n } else {\n this.mask = createElement('div', {\n style: {\n position: 'absolute',\n top: '0',\n left: '0',\n width: '100%',\n height: '100%'\n },\n class: !this.isUnstyled && styleClass,\n 'p-bind': this.ptm('mask')\n });\n this.$refs.container.appendChild(this.mask);\n }\n\n if (this.autoZIndex) {\n ZIndex.set('modal', this.mask, this.baseZIndex + this.$primevue.config.zIndex.modal);\n }\n\n this.isBlocked = true;\n this.$emit('block');\n },\n unblock() {\n if (this.mask) {\n !this.isUnstyled && addClass(this.mask, 'p-overlay-mask-leave-active');\n\n const handleAnimationEnd = () => {\n clearTimeout(fallbackTimer);\n this.mask.removeEventListener('animationend', handleAnimationEnd);\n this.mask.removeEventListener('webkitAnimationEnd', handleAnimationEnd);\n };\n\n const fallbackTimer = setTimeout(() => {\n this.removeMask();\n }, 300);\n\n if (hasCSSAnimation(this.mask) > 0) {\n this.mask.addEventListener('animationend', handleAnimati