primevue 3.27.0 → 3.28.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/autocomplete/AutoComplete.d.ts +10 -1
- package/autocomplete/AutoComplete.vue +1 -1
- package/autocomplete/autocomplete.cjs.js +4 -1
- package/autocomplete/autocomplete.cjs.min.js +1 -1
- package/autocomplete/autocomplete.esm.js +4 -1
- package/autocomplete/autocomplete.esm.min.js +1 -1
- package/autocomplete/autocomplete.js +4 -1
- package/autocomplete/autocomplete.min.js +1 -1
- package/avatar/Avatar.d.ts +44 -0
- package/avatar/Avatar.vue +10 -8
- package/avatar/avatar.cjs.js +36 -34
- package/avatar/avatar.cjs.min.js +1 -1
- package/avatar/avatar.esm.js +33 -35
- package/avatar/avatar.esm.min.js +1 -1
- package/avatar/avatar.js +37 -36
- package/avatar/avatar.min.js +1 -1
- package/avatargroup/AvatarGroup.d.ts +27 -1
- package/avatargroup/AvatarGroup.vue +5 -2
- package/avatargroup/avatargroup.cjs.js +9 -5
- package/avatargroup/avatargroup.cjs.min.js +1 -1
- package/avatargroup/avatargroup.esm.js +6 -6
- package/avatargroup/avatargroup.esm.min.js +1 -1
- package/avatargroup/avatargroup.js +10 -7
- package/avatargroup/avatargroup.min.js +1 -1
- package/badge/Badge.d.ts +32 -0
- package/badge/Badge.vue +3 -1
- package/badge/badge.cjs.js +8 -4
- package/badge/badge.cjs.min.js +1 -1
- package/badge/badge.esm.js +5 -5
- package/badge/badge.esm.min.js +1 -1
- package/badge/badge.js +9 -6
- package/badge/badge.min.js +1 -1
- package/basecomponent/BaseComponent.vue +10 -3
- package/basecomponent/basecomponent.cjs.js +10 -3
- package/basecomponent/basecomponent.cjs.min.js +1 -1
- package/basecomponent/basecomponent.esm.js +10 -3
- package/basecomponent/basecomponent.esm.min.js +1 -1
- package/basecomponent/basecomponent.js +10 -3
- package/basecomponent/basecomponent.min.js +1 -1
- package/baseicon/BaseIcon.vue +2 -2
- package/baseicon/baseicon.cjs.js +2 -2
- package/baseicon/baseicon.cjs.min.js +1 -1
- package/baseicon/baseicon.esm.js +2 -2
- package/baseicon/baseicon.esm.min.js +1 -1
- package/baseicon/baseicon.js +2 -2
- package/baseicon/baseicon.min.js +1 -1
- package/blockui/BlockUI.d.ts +44 -0
- package/blockui/BlockUI.vue +3 -1
- package/blockui/blockui.cjs.js +9 -3
- package/blockui/blockui.cjs.min.js +1 -1
- package/blockui/blockui.esm.js +6 -4
- package/blockui/blockui.esm.min.js +1 -1
- package/blockui/blockui.js +10 -5
- package/blockui/blockui.min.js +1 -1
- package/breadcrumb/Breadcrumb.d.ts +60 -0
- package/breadcrumb/Breadcrumb.vue +8 -6
- package/breadcrumb/BreadcrumbItem.vue +14 -10
- package/breadcrumb/breadcrumb.cjs.js +53 -51
- package/breadcrumb/breadcrumb.cjs.min.js +1 -1
- package/breadcrumb/breadcrumb.esm.js +53 -52
- package/breadcrumb/breadcrumb.esm.min.js +1 -1
- package/breadcrumb/breadcrumb.js +54 -53
- package/breadcrumb/breadcrumb.min.js +1 -1
- package/button/Button.d.ts +48 -0
- package/button/Button.vue +10 -9
- package/button/button.cjs.js +43 -44
- package/button/button.cjs.min.js +1 -1
- package/button/button.esm.js +43 -45
- package/button/button.esm.min.js +1 -1
- package/button/button.js +44 -46
- package/button/button.min.js +1 -1
- package/chart/Chart.d.ts +36 -0
- package/chart/Chart.vue +5 -2
- package/chart/chart.cjs.js +10 -5
- package/chart/chart.cjs.min.js +1 -1
- package/chart/chart.esm.js +7 -6
- package/chart/chart.esm.min.js +1 -1
- package/chart/chart.js +11 -7
- package/chart/chart.min.js +1 -1
- package/chip/Chip.d.ts +60 -0
- package/chip/Chip.vue +10 -9
- package/chip/chip.cjs.js +35 -36
- package/chip/chip.cjs.min.js +1 -1
- package/chip/chip.esm.js +35 -37
- package/chip/chip.esm.min.js +1 -1
- package/chip/chip.js +36 -38
- package/chip/chip.min.js +1 -1
- package/config/PrimeVue.d.ts +8 -0
- package/config/config.cjs.js +3 -1
- package/config/config.cjs.min.js +1 -1
- package/config/config.esm.js +3 -2
- package/config/config.esm.min.js +1 -1
- package/config/config.js +3 -1
- package/config/config.min.js +1 -1
- package/confirmdialog/ConfirmDialog.d.ts +88 -0
- package/confirmdialog/ConfirmDialog.vue +9 -6
- package/confirmdialog/confirmdialog.cjs.js +22 -18
- package/confirmdialog/confirmdialog.cjs.min.js +1 -1
- package/confirmdialog/confirmdialog.esm.js +22 -19
- package/confirmdialog/confirmdialog.esm.min.js +1 -1
- package/confirmdialog/confirmdialog.js +23 -20
- package/confirmdialog/confirmdialog.min.js +1 -1
- package/confirmpopup/ConfirmPopup.d.ts +75 -0
- package/confirmpopup/ConfirmPopup.vue +11 -9
- package/confirmpopup/confirmpopup.cjs.js +27 -25
- package/confirmpopup/confirmpopup.cjs.min.js +1 -1
- package/confirmpopup/confirmpopup.esm.js +27 -26
- package/confirmpopup/confirmpopup.esm.min.js +1 -1
- package/confirmpopup/confirmpopup.js +28 -27
- package/confirmpopup/confirmpopup.min.js +1 -1
- package/contextmenu/ContextMenu.d.ts +135 -0
- package/contextmenu/ContextMenu.vue +4 -1
- package/contextmenu/ContextMenuSub.vue +46 -10
- package/contextmenu/contextmenu.cjs.js +57 -46
- package/contextmenu/contextmenu.cjs.min.js +1 -1
- package/contextmenu/contextmenu.esm.js +57 -47
- package/contextmenu/contextmenu.esm.min.js +1 -1
- package/contextmenu/contextmenu.js +58 -48
- package/contextmenu/contextmenu.min.js +1 -1
- package/core/core.js +278 -246
- package/core/core.min.js +11 -11
- package/dialog/Dialog.d.ts +87 -0
- package/dialog/Dialog.vue +23 -10
- package/dialog/dialog.cjs.js +31 -30
- package/dialog/dialog.cjs.min.js +1 -1
- package/dialog/dialog.esm.js +31 -31
- package/dialog/dialog.esm.min.js +1 -1
- package/dialog/dialog.js +32 -32
- package/dialog/dialog.min.js +1 -1
- package/dock/Dock.d.ts +94 -0
- package/dock/Dock.vue +4 -2
- package/dock/DockSub.vue +30 -6
- package/dock/dock.cjs.js +52 -39
- package/dock/dock.cjs.min.js +1 -1
- package/dock/dock.esm.js +52 -40
- package/dock/dock.esm.min.js +1 -1
- package/dock/dock.js +53 -41
- package/dock/dock.min.js +1 -1
- package/dropdown/Dropdown.vue +1 -1
- package/dropdown/dropdown.cjs.js +1 -1
- package/dropdown/dropdown.cjs.min.js +1 -1
- package/dropdown/dropdown.esm.js +1 -1
- package/dropdown/dropdown.esm.min.js +1 -1
- package/dropdown/dropdown.js +1 -1
- package/dropdown/dropdown.min.js +1 -1
- package/dynamicdialog/DynamicDialog.vue +3 -1
- package/dynamicdialog/dynamicdialog.cjs.js +5 -1
- package/dynamicdialog/dynamicdialog.cjs.min.js +1 -1
- package/dynamicdialog/dynamicdialog.esm.js +4 -1
- package/dynamicdialog/dynamicdialog.esm.min.js +1 -1
- package/dynamicdialog/dynamicdialog.js +6 -3
- package/dynamicdialog/dynamicdialog.min.js +1 -1
- package/fileupload/FileContent.vue +11 -9
- package/fileupload/FileUpload.d.ts +154 -0
- package/fileupload/FileUpload.vue +26 -24
- package/fileupload/fileupload.cjs.js +100 -97
- package/fileupload/fileupload.cjs.min.js +1 -1
- package/fileupload/fileupload.esm.js +100 -98
- package/fileupload/fileupload.esm.min.js +1 -1
- package/fileupload/fileupload.js +101 -99
- package/fileupload/fileupload.min.js +1 -1
- package/inlinemessage/InlineMessage.d.ts +52 -0
- package/inlinemessage/InlineMessage.vue +7 -3
- package/inlinemessage/inlinemessage.cjs.js +12 -11
- package/inlinemessage/inlinemessage.cjs.min.js +1 -1
- package/inlinemessage/inlinemessage.esm.js +12 -12
- package/inlinemessage/inlinemessage.esm.min.js +1 -1
- package/inlinemessage/inlinemessage.js +13 -13
- package/inlinemessage/inlinemessage.min.js +1 -1
- package/inplace/Inplace.d.ts +59 -0
- package/inplace/Inplace.vue +7 -5
- package/inplace/inplace.cjs.js +17 -16
- package/inplace/inplace.cjs.min.js +1 -1
- package/inplace/inplace.esm.js +17 -17
- package/inplace/inplace.esm.min.js +1 -1
- package/inplace/inplace.js +18 -18
- package/inplace/inplace.min.js +1 -1
- package/listbox/Listbox.d.ts +1 -1
- package/megamenu/MegaMenu.d.ts +149 -0
- package/megamenu/MegaMenu.vue +6 -3
- package/megamenu/MegaMenuSub.vue +43 -15
- package/megamenu/megamenu.cjs.js +83 -75
- package/megamenu/megamenu.cjs.min.js +1 -1
- package/megamenu/megamenu.esm.js +83 -76
- package/megamenu/megamenu.esm.min.js +1 -1
- package/megamenu/megamenu.js +84 -77
- package/megamenu/megamenu.min.js +1 -1
- package/menu/Menu.d.ts +113 -0
- package/menu/Menu.vue +11 -8
- package/menu/Menuitem.vue +20 -8
- package/menu/menu.cjs.js +73 -62
- package/menu/menu.cjs.min.js +1 -1
- package/menu/menu.esm.js +73 -63
- package/menu/menu.esm.min.js +1 -1
- package/menu/menu.js +74 -64
- package/menu/menu.min.js +1 -1
- package/menubar/Menubar.d.ts +146 -0
- package/menubar/Menubar.vue +8 -5
- package/menubar/MenubarSub.vue +38 -10
- package/menubar/menubar.cjs.js +70 -60
- package/menubar/menubar.cjs.min.js +1 -1
- package/menubar/menubar.esm.js +70 -61
- package/menubar/menubar.esm.min.js +1 -1
- package/menubar/menubar.js +71 -62
- package/menubar/menubar.min.js +1 -1
- package/message/Message.d.ts +64 -1
- package/message/Message.vue +9 -7
- package/message/message.cjs.js +22 -21
- package/message/message.cjs.min.js +1 -1
- package/message/message.esm.js +22 -22
- package/message/message.esm.min.js +1 -1
- package/message/message.js +23 -23
- package/message/message.min.js +1 -1
- package/multiselect/MultiSelect.d.ts +1 -1
- package/overlaypanel/OverlayPanel.d.ts +56 -0
- package/overlaypanel/OverlayPanel.vue +6 -4
- package/overlaypanel/overlaypanel.cjs.js +13 -10
- package/overlaypanel/overlaypanel.cjs.min.js +1 -1
- package/overlaypanel/overlaypanel.esm.js +13 -11
- package/overlaypanel/overlaypanel.esm.min.js +1 -1
- package/overlaypanel/overlaypanel.js +14 -12
- package/overlaypanel/overlaypanel.min.js +1 -1
- package/package.json +1 -1
- package/panel/Panel.d.ts +10 -1
- package/panel/Panel.vue +1 -1
- package/panel/panel.cjs.js +4 -1
- package/panel/panel.cjs.min.js +1 -1
- package/panel/panel.esm.js +4 -1
- package/panel/panel.esm.min.js +1 -1
- package/panel/panel.js +4 -1
- package/panel/panel.min.js +1 -1
- package/panelmenu/PanelMenu.d.ts +133 -0
- package/panelmenu/PanelMenu.vue +36 -13
- package/panelmenu/PanelMenuList.vue +3 -0
- package/panelmenu/PanelMenuSub.vue +33 -12
- package/panelmenu/panelmenu.cjs.js +115 -96
- package/panelmenu/panelmenu.cjs.min.js +1 -1
- package/panelmenu/panelmenu.esm.js +115 -97
- package/panelmenu/panelmenu.esm.min.js +1 -1
- package/panelmenu/panelmenu.js +116 -98
- package/panelmenu/panelmenu.min.js +1 -1
- package/password/Password.vue +2 -2
- package/password/password.cjs.js +2 -2
- package/password/password.cjs.min.js +1 -1
- package/password/password.esm.js +2 -2
- package/password/password.esm.min.js +1 -1
- package/password/password.js +2 -2
- package/password/password.min.js +1 -1
- package/progressbar/ProgressBar.d.ts +40 -0
- package/progressbar/ProgressBar.vue +8 -5
- package/progressbar/progressbar.cjs.js +25 -23
- package/progressbar/progressbar.cjs.min.js +1 -1
- package/progressbar/progressbar.esm.js +22 -24
- package/progressbar/progressbar.esm.min.js +1 -1
- package/progressbar/progressbar.js +26 -25
- package/progressbar/progressbar.min.js +1 -1
- package/progressspinner/ProgressSpinner.d.ts +40 -0
- package/progressspinner/ProgressSpinner.vue +6 -3
- package/progressspinner/progressspinner.cjs.js +18 -13
- package/progressspinner/progressspinner.cjs.min.js +1 -1
- package/progressspinner/progressspinner.esm.js +15 -14
- package/progressspinner/progressspinner.esm.min.js +1 -1
- package/progressspinner/progressspinner.js +19 -15
- package/progressspinner/progressspinner.min.js +1 -1
- package/resources/themes/arya-blue/theme.css +1 -1
- package/resources/themes/arya-green/theme.css +1 -1
- package/resources/themes/arya-orange/theme.css +1 -1
- package/resources/themes/arya-purple/theme.css +1 -1
- package/resources/themes/bootstrap4-dark-blue/theme.css +1 -1
- package/resources/themes/bootstrap4-dark-purple/theme.css +1 -1
- package/resources/themes/bootstrap4-light-blue/theme.css +1 -1
- package/resources/themes/bootstrap4-light-purple/theme.css +1 -1
- package/resources/themes/fluent-light/theme.css +1 -1
- package/resources/themes/lara-dark-blue/theme.css +1 -1
- package/resources/themes/lara-dark-indigo/theme.css +1 -1
- package/resources/themes/lara-dark-purple/theme.css +1 -1
- package/resources/themes/lara-dark-teal/theme.css +1 -1
- package/resources/themes/lara-light-blue/theme.css +1 -1
- package/resources/themes/lara-light-indigo/theme.css +1 -1
- package/resources/themes/lara-light-purple/theme.css +1 -1
- package/resources/themes/lara-light-teal/theme.css +1 -1
- package/resources/themes/luna-amber/theme.css +1 -1
- package/resources/themes/luna-blue/theme.css +1 -1
- package/resources/themes/luna-green/theme.css +1 -1
- package/resources/themes/luna-pink/theme.css +1 -1
- package/resources/themes/md-dark-deeppurple/theme.css +4 -1
- package/resources/themes/md-dark-indigo/theme.css +4 -1
- package/resources/themes/md-light-deeppurple/theme.css +4 -1
- package/resources/themes/md-light-indigo/theme.css +4 -1
- package/resources/themes/mdc-dark-deeppurple/theme.css +4 -1
- package/resources/themes/mdc-dark-indigo/theme.css +4 -1
- package/resources/themes/mdc-light-deeppurple/theme.css +4 -1
- package/resources/themes/mdc-light-indigo/theme.css +4 -1
- package/resources/themes/mira/theme.css +1 -1
- package/resources/themes/nano/theme.css +1 -1
- package/resources/themes/nova/theme.css +1 -1
- package/resources/themes/nova-accent/theme.css +1 -1
- package/resources/themes/nova-alt/theme.css +1 -1
- package/resources/themes/nova-vue/theme.css +1 -1
- package/resources/themes/rhea/theme.css +1 -1
- package/resources/themes/saga-blue/theme.css +1 -1
- package/resources/themes/saga-green/theme.css +1 -1
- package/resources/themes/saga-orange/theme.css +1 -1
- package/resources/themes/saga-purple/theme.css +1 -1
- package/resources/themes/soho-dark/theme.css +1 -1
- package/resources/themes/soho-light/theme.css +1 -1
- package/resources/themes/tailwind-light/theme.css +1 -1
- package/resources/themes/vela-blue/theme.css +1 -1
- package/resources/themes/vela-green/theme.css +1 -1
- package/resources/themes/vela-orange/theme.css +1 -1
- package/resources/themes/vela-purple/theme.css +1 -1
- package/resources/themes/viva-dark/theme.css +1 -1
- package/resources/themes/viva-light/theme.css +1 -1
- package/scrolltop/ScrollTop.d.ts +48 -0
- package/scrolltop/ScrollTop.vue +5 -2
- package/scrolltop/scrolltop.cjs.js +10 -7
- package/scrolltop/scrolltop.cjs.min.js +1 -1
- package/scrolltop/scrolltop.esm.js +10 -8
- package/scrolltop/scrolltop.esm.min.js +1 -1
- package/scrolltop/scrolltop.js +11 -9
- package/scrolltop/scrolltop.min.js +1 -1
- package/sidebar/Sidebar.d.ts +68 -0
- package/sidebar/Sidebar.vue +9 -7
- package/sidebar/sidebar.cjs.js +26 -24
- package/sidebar/sidebar.cjs.min.js +1 -1
- package/sidebar/sidebar.esm.js +26 -25
- package/sidebar/sidebar.esm.min.js +1 -1
- package/sidebar/sidebar.js +27 -26
- package/sidebar/sidebar.min.js +1 -1
- package/skeleton/Skeleton.d.ts +32 -0
- package/skeleton/Skeleton.vue +4 -1
- package/skeleton/skeleton.cjs.js +10 -4
- package/skeleton/skeleton.cjs.min.js +1 -1
- package/skeleton/skeleton.esm.js +7 -5
- package/skeleton/skeleton.esm.min.js +1 -1
- package/skeleton/skeleton.js +11 -6
- package/skeleton/skeleton.min.js +1 -1
- package/speeddial/SpeedDial.d.ts +101 -0
- package/speeddial/SpeedDial.vue +31 -8
- package/speeddial/speeddial.cjs.js +47 -33
- package/speeddial/speeddial.cjs.min.js +1 -1
- package/speeddial/speeddial.esm.js +47 -34
- package/speeddial/speeddial.esm.min.js +1 -1
- package/speeddial/speeddial.js +48 -35
- package/speeddial/speeddial.min.js +1 -1
- package/splitbutton/SplitButton.d.ts +64 -0
- package/splitbutton/SplitButton.vue +8 -5
- package/splitbutton/splitbutton.cjs.js +23 -18
- package/splitbutton/splitbutton.cjs.min.js +1 -1
- package/splitbutton/splitbutton.esm.js +23 -19
- package/splitbutton/splitbutton.esm.min.js +1 -1
- package/splitbutton/splitbutton.js +24 -20
- package/splitbutton/splitbutton.min.js +1 -1
- package/steps/Steps.d.ts +52 -0
- package/steps/Steps.vue +11 -8
- package/steps/steps.cjs.js +34 -33
- package/steps/steps.cjs.min.js +1 -1
- package/steps/steps.esm.js +31 -34
- package/steps/steps.esm.min.js +1 -1
- package/steps/steps.js +35 -35
- package/steps/steps.min.js +1 -1
- package/tabmenu/TabMenu.d.ts +79 -0
- package/tabmenu/TabMenu.vue +20 -10
- package/tabmenu/tabmenu.cjs.js +47 -41
- package/tabmenu/tabmenu.cjs.min.js +1 -1
- package/tabmenu/tabmenu.esm.js +47 -42
- package/tabmenu/tabmenu.esm.min.js +1 -1
- package/tabmenu/tabmenu.js +48 -43
- package/tabmenu/tabmenu.min.js +1 -1
- package/tag/Tag.d.ts +40 -0
- package/tag/Tag.vue +7 -4
- package/tag/tag.cjs.js +14 -12
- package/tag/tag.cjs.min.js +1 -1
- package/tag/tag.esm.js +11 -13
- package/tag/tag.esm.min.js +1 -1
- package/tag/tag.js +15 -14
- package/tag/tag.min.js +1 -1
- package/terminal/Terminal.d.ts +79 -0
- package/terminal/Terminal.vue +12 -10
- package/terminal/terminal.cjs.js +23 -28
- package/terminal/terminal.cjs.min.js +1 -1
- package/terminal/terminal.esm.js +23 -29
- package/terminal/terminal.esm.min.js +1 -1
- package/terminal/terminal.js +24 -30
- package/terminal/terminal.min.js +1 -1
- package/tieredmenu/TieredMenu.d.ts +130 -0
- package/tieredmenu/TieredMenu.vue +4 -1
- package/tieredmenu/TieredMenuSub.vue +39 -11
- package/tieredmenu/tieredmenu.cjs.js +53 -41
- package/tieredmenu/tieredmenu.cjs.min.js +1 -1
- package/tieredmenu/tieredmenu.esm.js +53 -42
- package/tieredmenu/tieredmenu.esm.min.js +1 -1
- package/tieredmenu/tieredmenu.js +54 -43
- package/tieredmenu/tieredmenu.min.js +1 -1
- package/toast/Toast.d.ts +79 -0
- package/toast/Toast.vue +4 -1
- package/toast/ToastMessage.vue +12 -10
- package/toast/toast.cjs.js +31 -31
- package/toast/toast.cjs.min.js +1 -1
- package/toast/toast.esm.js +31 -32
- package/toast/toast.esm.min.js +1 -1
- package/toast/toast.js +32 -33
- package/toast/toast.min.js +1 -1
- package/treeselect/TreeSelect.d.ts +1 -2
- package/vetur-attributes.json +160 -0
- package/vetur-tags.json +79 -34
- package/web-types.json +404 -2
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
+
var BaseComponent = require('primevue/basecomponent');
|
|
3
4
|
var Button = require('primevue/button');
|
|
4
5
|
var ConfirmationEventBus = require('primevue/confirmationeventbus');
|
|
5
6
|
var FocusTrap = require('primevue/focustrap');
|
|
@@ -10,6 +11,7 @@ var vue = require('vue');
|
|
|
10
11
|
|
|
11
12
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
12
13
|
|
|
14
|
+
var BaseComponent__default = /*#__PURE__*/_interopDefaultLegacy(BaseComponent);
|
|
13
15
|
var Button__default = /*#__PURE__*/_interopDefaultLegacy(Button);
|
|
14
16
|
var ConfirmationEventBus__default = /*#__PURE__*/_interopDefaultLegacy(ConfirmationEventBus);
|
|
15
17
|
var FocusTrap__default = /*#__PURE__*/_interopDefaultLegacy(FocusTrap);
|
|
@@ -18,6 +20,7 @@ var Portal__default = /*#__PURE__*/_interopDefaultLegacy(Portal);
|
|
|
18
20
|
|
|
19
21
|
var script = {
|
|
20
22
|
name: 'ConfirmPopup',
|
|
23
|
+
extends: BaseComponent__default["default"],
|
|
21
24
|
inheritAttrs: false,
|
|
22
25
|
props: {
|
|
23
26
|
group: String
|
|
@@ -288,12 +291,6 @@ var script = {
|
|
|
288
291
|
};
|
|
289
292
|
|
|
290
293
|
const _hoisted_1 = ["aria-modal"];
|
|
291
|
-
const _hoisted_2 = {
|
|
292
|
-
key: 0,
|
|
293
|
-
class: "p-confirm-popup-content"
|
|
294
|
-
};
|
|
295
|
-
const _hoisted_3 = { class: "p-confirm-popup-message" };
|
|
296
|
-
const _hoisted_4 = { class: "p-confirm-popup-footer" };
|
|
297
294
|
|
|
298
295
|
function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
299
296
|
const _component_CPButton = vue.resolveComponent("CPButton");
|
|
@@ -319,9 +316,12 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
319
316
|
"aria-modal": $data.visible,
|
|
320
317
|
onClick: _cache[2] || (_cache[2] = (...args) => ($options.onOverlayClick && $options.onOverlayClick(...args))),
|
|
321
318
|
onKeydown: _cache[3] || (_cache[3] = (...args) => ($options.onOverlayKeydown && $options.onOverlayKeydown(...args)))
|
|
322
|
-
}, _ctx.$attrs), [
|
|
319
|
+
}, { ..._ctx.$attrs, ..._ctx.ptm('root') }), [
|
|
323
320
|
(!_ctx.$slots.message)
|
|
324
|
-
? (vue.openBlock(), vue.createElementBlock("div",
|
|
321
|
+
? (vue.openBlock(), vue.createElementBlock("div", vue.mergeProps({
|
|
322
|
+
key: 0,
|
|
323
|
+
class: "p-confirm-popup-content"
|
|
324
|
+
}, _ctx.ptm('content')), [
|
|
325
325
|
vue.renderSlot(_ctx.$slots, "icon", { class: "p-confirm-popup-icon" }, () => [
|
|
326
326
|
(_ctx.$slots.icon)
|
|
327
327
|
? (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(_ctx.$slots.icon), {
|
|
@@ -329,52 +329,54 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
329
329
|
class: "p-confirm-popup-icon"
|
|
330
330
|
}))
|
|
331
331
|
: ($data.confirmation.icon)
|
|
332
|
-
? (vue.openBlock(), vue.createElementBlock("span", {
|
|
332
|
+
? (vue.openBlock(), vue.createElementBlock("span", vue.mergeProps({
|
|
333
333
|
key: 1,
|
|
334
|
-
class:
|
|
335
|
-
}, null,
|
|
334
|
+
class: $options.iconClass
|
|
335
|
+
}, _ctx.ptm('icon')), null, 16))
|
|
336
336
|
: vue.createCommentVNode("", true)
|
|
337
337
|
]),
|
|
338
|
-
vue.createElementVNode("span",
|
|
339
|
-
]))
|
|
338
|
+
vue.createElementVNode("span", vue.mergeProps({ class: "p-confirm-popup-message" }, _ctx.ptm('message')), vue.toDisplayString($data.confirmation.message), 17)
|
|
339
|
+
], 16))
|
|
340
340
|
: (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(_ctx.$slots.message), {
|
|
341
341
|
key: 1,
|
|
342
342
|
message: $data.confirmation
|
|
343
343
|
}, null, 8, ["message"])),
|
|
344
|
-
vue.createElementVNode("div",
|
|
344
|
+
vue.createElementVNode("div", vue.mergeProps({ class: "p-confirm-popup-footer" }, _ctx.ptm('footer')), [
|
|
345
345
|
vue.createVNode(_component_CPButton, {
|
|
346
346
|
label: $options.rejectLabel,
|
|
347
347
|
class: vue.normalizeClass($options.rejectClass),
|
|
348
348
|
onClick: _cache[0] || (_cache[0] = $event => ($options.reject())),
|
|
349
349
|
onKeydown: $options.onRejectKeydown,
|
|
350
|
-
autofocus: $data.autoFocusReject
|
|
350
|
+
autofocus: $data.autoFocusReject,
|
|
351
|
+
pt: _ctx.ptm('rejectButton')
|
|
351
352
|
}, {
|
|
352
353
|
icon: vue.withCtx((iconProps) => [
|
|
353
354
|
vue.renderSlot(_ctx.$slots, "rejecticon", {}, () => [
|
|
354
|
-
vue.createElementVNode("span", {
|
|
355
|
-
class:
|
|
356
|
-
}, null,
|
|
355
|
+
vue.createElementVNode("span", vue.mergeProps({
|
|
356
|
+
class: [$options.rejectIcon, iconProps.class]
|
|
357
|
+
}, _ctx.ptm('rejectButton')['icon']), null, 16)
|
|
357
358
|
])
|
|
358
359
|
]),
|
|
359
360
|
_: 3
|
|
360
|
-
}, 8, ["label", "class", "onKeydown", "autofocus"]),
|
|
361
|
+
}, 8, ["label", "class", "onKeydown", "autofocus", "pt"]),
|
|
361
362
|
vue.createVNode(_component_CPButton, {
|
|
362
363
|
label: $options.acceptLabel,
|
|
363
364
|
class: vue.normalizeClass($options.acceptClass),
|
|
364
365
|
onClick: _cache[1] || (_cache[1] = $event => ($options.accept())),
|
|
365
366
|
onKeydown: $options.onAcceptKeydown,
|
|
366
|
-
autofocus: $data.autoFocusAccept
|
|
367
|
+
autofocus: $data.autoFocusAccept,
|
|
368
|
+
pt: _ctx.ptm('acceptButton')
|
|
367
369
|
}, {
|
|
368
370
|
icon: vue.withCtx((iconProps) => [
|
|
369
371
|
vue.renderSlot(_ctx.$slots, "accepticon", {}, () => [
|
|
370
|
-
vue.createElementVNode("span", {
|
|
371
|
-
class:
|
|
372
|
-
}, null,
|
|
372
|
+
vue.createElementVNode("span", vue.mergeProps({
|
|
373
|
+
class: [$options.acceptIcon, iconProps.class]
|
|
374
|
+
}, _ctx.ptm('acceptButton')['icon']), null, 16)
|
|
373
375
|
])
|
|
374
376
|
]),
|
|
375
377
|
_: 3
|
|
376
|
-
}, 8, ["label", "class", "onKeydown", "autofocus"])
|
|
377
|
-
])
|
|
378
|
+
}, 8, ["label", "class", "onKeydown", "autofocus", "pt"])
|
|
379
|
+
], 16)
|
|
378
380
|
], 16, _hoisted_1)), [
|
|
379
381
|
[_directive_focustrap]
|
|
380
382
|
])
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e=require("primevue/
|
|
1
|
+
"use strict";var e=require("primevue/basecomponent"),t=require("primevue/button"),n=require("primevue/confirmationeventbus"),i=require("primevue/focustrap"),o=require("primevue/overlayeventbus"),r=require("primevue/portal"),s=require("primevue/utils"),c=require("vue");function l(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var a=l(e),p=l(t),u=l(n),m=l(i),f=l(o),d=l(r),h={name:"ConfirmPopup",extends:a.default,inheritAttrs:!1,props:{group:String},data:()=>({visible:!1,confirmation:null,autoFocusAccept:null,autoFocusReject:null}),target:null,outsideClickListener:null,scrollHandler:null,resizeListener:null,container:null,confirmListener:null,closeListener:null,mounted(){this.confirmListener=e=>{e&&e.group===this.group&&(this.confirmation=e,this.target=e.target,this.confirmation.onShow&&this.confirmation.onShow(),this.visible=!0)},this.closeListener=()=>{this.visible=!1,this.confirmation=null},u.default.on("confirm",this.confirmListener),u.default.on("close",this.closeListener)},beforeUnmount(){u.default.off("confirm",this.confirmListener),u.default.off("close",this.closeListener),this.unbindOutsideClickListener(),this.scrollHandler&&(this.scrollHandler.destroy(),this.scrollHandler=null),this.unbindResizeListener(),this.container&&(s.ZIndexUtils.clear(this.container),this.container=null),this.target=null,this.confirmation=null},methods:{accept(){this.confirmation.accept&&this.confirmation.accept(),this.visible=!1},reject(){this.confirmation.reject&&this.confirmation.reject(),this.visible=!1},onHide(){this.confirmation.onHide&&this.confirmation.onHide(),this.visible=!1},onAcceptKeydown(e){"Space"!==e.code&&"Enter"!==e.code||(this.accept(),s.DomHandler.focus(this.target),e.preventDefault())},onRejectKeydown(e){"Space"!==e.code&&"Enter"!==e.code||(this.reject(),s.DomHandler.focus(this.target),e.preventDefault())},onEnter(e){this.autoFocusAccept=void 0===this.confirmation.defaultFocus||"accept"===this.confirmation.defaultFocus,this.autoFocusReject="reject"===this.confirmation.defaultFocus,this.bindOutsideClickListener(),this.bindScrollListener(),this.bindResizeListener(),s.ZIndexUtils.set("overlay",e,this.$primevue.config.zIndex.overlay)},onAfterEnter(){this.focus()},onLeave(){this.autoFocusAccept=null,this.autoFocusReject=null,this.unbindOutsideClickListener(),this.unbindScrollListener(),this.unbindResizeListener()},onAfterLeave(e){s.ZIndexUtils.clear(e)},alignOverlay(){s.DomHandler.absolutePosition(this.container,this.target);const e=s.DomHandler.getOffset(this.container),t=s.DomHandler.getOffset(this.target);let n=0;e.left<t.left&&(n=t.left-e.left),this.container.style.setProperty("--overlayArrowLeft",`${n}px`),e.top<t.top&&s.DomHandler.addClass(this.container,"p-confirm-popup-flipped")},bindOutsideClickListener(){this.outsideClickListener||(this.outsideClickListener=e=>{this.visible&&this.container&&!this.container.contains(e.target)&&!this.isTargetClicked(e)?(this.confirmation.onHide&&this.confirmation.onHide(),this.visible=!1):this.alignOverlay()},document.addEventListener("click",this.outsideClickListener))},unbindOutsideClickListener(){this.outsideClickListener&&(document.removeEventListener("click",this.outsideClickListener),this.outsideClickListener=null)},bindScrollListener(){this.scrollHandler||(this.scrollHandler=new s.ConnectedOverlayScrollHandler(this.target,(()=>{this.visible&&(this.visible=!1)}))),this.scrollHandler.bindScrollListener()},unbindScrollListener(){this.scrollHandler&&this.scrollHandler.unbindScrollListener()},bindResizeListener(){this.resizeListener||(this.resizeListener=()=>{this.visible&&!s.DomHandler.isTouchDevice()&&(this.visible=!1)},window.addEventListener("resize",this.resizeListener))},unbindResizeListener(){this.resizeListener&&(window.removeEventListener("resize",this.resizeListener),this.resizeListener=null)},focus(){let e=this.container.querySelector("[autofocus]");e&&e.focus({preventScroll:!0})},isTargetClicked(e){return this.target&&(this.target===e.target||this.target.contains(e.target))},containerRef(e){this.container=e},onOverlayClick(e){f.default.emit("overlay-click",{originalEvent:e,target:this.target})},onOverlayKeydown(e){"Escape"===e.code&&(u.default.emit("close",this.closeListener),s.DomHandler.focus(this.target))}},computed:{containerClass(){return["p-confirm-popup p-component",{"p-input-filled":"filled"===this.$primevue.config.inputStyle,"p-ripple-disabled":!1===this.$primevue.config.ripple}]},message(){return this.confirmation?this.confirmation.message:null},iconClass(){return["p-confirm-popup-icon",this.confirmation?this.confirmation.icon:null]},acceptLabel(){return this.confirmation?this.confirmation.acceptLabel||this.$primevue.config.locale.accept:null},rejectLabel(){return this.confirmation?this.confirmation.rejectLabel||this.$primevue.config.locale.reject:null},acceptIcon(){return this.confirmation?this.confirmation.acceptIcon:null},rejectIcon(){return this.confirmation?this.confirmation.rejectIcon:null},acceptClass(){return["p-confirm-popup-accept p-button-sm",this.confirmation?this.confirmation.acceptClass:null]},rejectClass(){return["p-confirm-popup-reject p-button-sm",this.confirmation?this.confirmation.rejectClass||"p-button-text":null]}},components:{CPButton:p.default,Portal:d.default},directives:{focustrap:m.default}};const v=["aria-modal"];!function(e,t){void 0===t&&(t={});var n=t.insertAt;if(e&&"undefined"!=typeof document){var i=document.head||document.getElementsByTagName("head")[0],o=document.createElement("style");o.type="text/css","top"===n&&i.firstChild?i.insertBefore(o,i.firstChild):i.appendChild(o),o.styleSheet?o.styleSheet.cssText=e:o.appendChild(document.createTextNode(e))}}("\n.p-confirm-popup {\n position: absolute;\n margin-top: 10px;\n top: 0;\n left: 0;\n}\n.p-confirm-popup-flipped {\n margin-top: 0;\n margin-bottom: 10px;\n}\n\n/* Animation */\n.p-confirm-popup-enter-from {\n opacity: 0;\n transform: scaleY(0.8);\n}\n.p-confirm-popup-leave-to {\n opacity: 0;\n}\n.p-confirm-popup-enter-active {\n transition: transform 0.12s cubic-bezier(0, 0, 0.2, 1), opacity 0.12s cubic-bezier(0, 0, 0.2, 1);\n}\n.p-confirm-popup-leave-active {\n transition: opacity 0.1s linear;\n}\n.p-confirm-popup:after,\n.p-confirm-popup:before {\n bottom: 100%;\n left: calc(var(--overlayArrowLeft, 0) + 1.25rem);\n content: ' ';\n height: 0;\n width: 0;\n position: absolute;\n pointer-events: none;\n}\n.p-confirm-popup:after {\n border-width: 8px;\n margin-left: -8px;\n}\n.p-confirm-popup:before {\n border-width: 10px;\n margin-left: -10px;\n}\n.p-confirm-popup-flipped:after,\n.p-confirm-popup-flipped:before {\n bottom: auto;\n top: 100%;\n}\n.p-confirm-popup.p-confirm-popup-flipped:after {\n border-bottom-color: transparent;\n}\n.p-confirm-popup.p-confirm-popup-flipped:before {\n border-bottom-color: transparent;\n}\n.p-confirm-popup .p-confirm-popup-content {\n display: flex;\n align-items: center;\n}\n"),h.render=function(e,t,n,i,o,r){const s=c.resolveComponent("CPButton"),l=c.resolveComponent("Portal"),a=c.resolveDirective("focustrap");return c.openBlock(),c.createBlock(l,null,{default:c.withCtx((()=>[c.createVNode(c.Transition,{name:"p-confirm-popup",onEnter:r.onEnter,onAfterEnter:r.onAfterEnter,onLeave:r.onLeave,onAfterLeave:r.onAfterLeave},{default:c.withCtx((()=>[o.visible?c.withDirectives((c.openBlock(),c.createElementBlock("div",c.mergeProps({key:0,ref:r.containerRef,role:"alertdialog",class:r.containerClass,"aria-modal":o.visible,onClick:t[2]||(t[2]=(...e)=>r.onOverlayClick&&r.onOverlayClick(...e)),onKeydown:t[3]||(t[3]=(...e)=>r.onOverlayKeydown&&r.onOverlayKeydown(...e))},{...e.$attrs,...e.ptm("root")}),[e.$slots.message?(c.openBlock(),c.createBlock(c.resolveDynamicComponent(e.$slots.message),{key:1,message:o.confirmation},null,8,["message"])):(c.openBlock(),c.createElementBlock("div",c.mergeProps({key:0,class:"p-confirm-popup-content"},e.ptm("content")),[c.renderSlot(e.$slots,"icon",{class:"p-confirm-popup-icon"},(()=>[e.$slots.icon?(c.openBlock(),c.createBlock(c.resolveDynamicComponent(e.$slots.icon),{key:0,class:"p-confirm-popup-icon"})):o.confirmation.icon?(c.openBlock(),c.createElementBlock("span",c.mergeProps({key:1,class:r.iconClass},e.ptm("icon")),null,16)):c.createCommentVNode("",!0)])),c.createElementVNode("span",c.mergeProps({class:"p-confirm-popup-message"},e.ptm("message")),c.toDisplayString(o.confirmation.message),17)],16)),c.createElementVNode("div",c.mergeProps({class:"p-confirm-popup-footer"},e.ptm("footer")),[c.createVNode(s,{label:r.rejectLabel,class:c.normalizeClass(r.rejectClass),onClick:t[0]||(t[0]=e=>r.reject()),onKeydown:r.onRejectKeydown,autofocus:o.autoFocusReject,pt:e.ptm("rejectButton")},{icon:c.withCtx((t=>[c.renderSlot(e.$slots,"rejecticon",{},(()=>[c.createElementVNode("span",c.mergeProps({class:[r.rejectIcon,t.class]},e.ptm("rejectButton").icon),null,16)]))])),_:3},8,["label","class","onKeydown","autofocus","pt"]),c.createVNode(s,{label:r.acceptLabel,class:c.normalizeClass(r.acceptClass),onClick:t[1]||(t[1]=e=>r.accept()),onKeydown:r.onAcceptKeydown,autofocus:o.autoFocusAccept,pt:e.ptm("acceptButton")},{icon:c.withCtx((t=>[c.renderSlot(e.$slots,"accepticon",{},(()=>[c.createElementVNode("span",c.mergeProps({class:[r.acceptIcon,t.class]},e.ptm("acceptButton").icon),null,16)]))])),_:3},8,["label","class","onKeydown","autofocus","pt"])],16)],16,v)),[[a]]):c.createCommentVNode("",!0)])),_:3},8,["onEnter","onAfterEnter","onLeave","onAfterLeave"])])),_:3})},module.exports=h;
|
|
@@ -1,13 +1,15 @@
|
|
|
1
|
+
import BaseComponent from 'primevue/basecomponent';
|
|
1
2
|
import Button from 'primevue/button';
|
|
2
3
|
import ConfirmationEventBus from 'primevue/confirmationeventbus';
|
|
3
4
|
import FocusTrap from 'primevue/focustrap';
|
|
4
5
|
import OverlayEventBus from 'primevue/overlayeventbus';
|
|
5
6
|
import Portal from 'primevue/portal';
|
|
6
7
|
import { ZIndexUtils, DomHandler, ConnectedOverlayScrollHandler } from 'primevue/utils';
|
|
7
|
-
import { resolveComponent, resolveDirective, openBlock, createBlock, withCtx, createVNode, Transition, withDirectives, createElementBlock, mergeProps, renderSlot, resolveDynamicComponent,
|
|
8
|
+
import { resolveComponent, resolveDirective, openBlock, createBlock, withCtx, createVNode, Transition, withDirectives, createElementBlock, mergeProps, renderSlot, resolveDynamicComponent, createCommentVNode, createElementVNode, toDisplayString, normalizeClass } from 'vue';
|
|
8
9
|
|
|
9
10
|
var script = {
|
|
10
11
|
name: 'ConfirmPopup',
|
|
12
|
+
extends: BaseComponent,
|
|
11
13
|
inheritAttrs: false,
|
|
12
14
|
props: {
|
|
13
15
|
group: String
|
|
@@ -278,12 +280,6 @@ var script = {
|
|
|
278
280
|
};
|
|
279
281
|
|
|
280
282
|
const _hoisted_1 = ["aria-modal"];
|
|
281
|
-
const _hoisted_2 = {
|
|
282
|
-
key: 0,
|
|
283
|
-
class: "p-confirm-popup-content"
|
|
284
|
-
};
|
|
285
|
-
const _hoisted_3 = { class: "p-confirm-popup-message" };
|
|
286
|
-
const _hoisted_4 = { class: "p-confirm-popup-footer" };
|
|
287
283
|
|
|
288
284
|
function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
289
285
|
const _component_CPButton = resolveComponent("CPButton");
|
|
@@ -309,9 +305,12 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
309
305
|
"aria-modal": $data.visible,
|
|
310
306
|
onClick: _cache[2] || (_cache[2] = (...args) => ($options.onOverlayClick && $options.onOverlayClick(...args))),
|
|
311
307
|
onKeydown: _cache[3] || (_cache[3] = (...args) => ($options.onOverlayKeydown && $options.onOverlayKeydown(...args)))
|
|
312
|
-
}, _ctx.$attrs), [
|
|
308
|
+
}, { ..._ctx.$attrs, ..._ctx.ptm('root') }), [
|
|
313
309
|
(!_ctx.$slots.message)
|
|
314
|
-
? (openBlock(), createElementBlock("div",
|
|
310
|
+
? (openBlock(), createElementBlock("div", mergeProps({
|
|
311
|
+
key: 0,
|
|
312
|
+
class: "p-confirm-popup-content"
|
|
313
|
+
}, _ctx.ptm('content')), [
|
|
315
314
|
renderSlot(_ctx.$slots, "icon", { class: "p-confirm-popup-icon" }, () => [
|
|
316
315
|
(_ctx.$slots.icon)
|
|
317
316
|
? (openBlock(), createBlock(resolveDynamicComponent(_ctx.$slots.icon), {
|
|
@@ -319,52 +318,54 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
319
318
|
class: "p-confirm-popup-icon"
|
|
320
319
|
}))
|
|
321
320
|
: ($data.confirmation.icon)
|
|
322
|
-
? (openBlock(), createElementBlock("span", {
|
|
321
|
+
? (openBlock(), createElementBlock("span", mergeProps({
|
|
323
322
|
key: 1,
|
|
324
|
-
class:
|
|
325
|
-
}, null,
|
|
323
|
+
class: $options.iconClass
|
|
324
|
+
}, _ctx.ptm('icon')), null, 16))
|
|
326
325
|
: createCommentVNode("", true)
|
|
327
326
|
]),
|
|
328
|
-
createElementVNode("span",
|
|
329
|
-
]))
|
|
327
|
+
createElementVNode("span", mergeProps({ class: "p-confirm-popup-message" }, _ctx.ptm('message')), toDisplayString($data.confirmation.message), 17)
|
|
328
|
+
], 16))
|
|
330
329
|
: (openBlock(), createBlock(resolveDynamicComponent(_ctx.$slots.message), {
|
|
331
330
|
key: 1,
|
|
332
331
|
message: $data.confirmation
|
|
333
332
|
}, null, 8, ["message"])),
|
|
334
|
-
createElementVNode("div",
|
|
333
|
+
createElementVNode("div", mergeProps({ class: "p-confirm-popup-footer" }, _ctx.ptm('footer')), [
|
|
335
334
|
createVNode(_component_CPButton, {
|
|
336
335
|
label: $options.rejectLabel,
|
|
337
336
|
class: normalizeClass($options.rejectClass),
|
|
338
337
|
onClick: _cache[0] || (_cache[0] = $event => ($options.reject())),
|
|
339
338
|
onKeydown: $options.onRejectKeydown,
|
|
340
|
-
autofocus: $data.autoFocusReject
|
|
339
|
+
autofocus: $data.autoFocusReject,
|
|
340
|
+
pt: _ctx.ptm('rejectButton')
|
|
341
341
|
}, {
|
|
342
342
|
icon: withCtx((iconProps) => [
|
|
343
343
|
renderSlot(_ctx.$slots, "rejecticon", {}, () => [
|
|
344
|
-
createElementVNode("span", {
|
|
345
|
-
class:
|
|
346
|
-
}, null,
|
|
344
|
+
createElementVNode("span", mergeProps({
|
|
345
|
+
class: [$options.rejectIcon, iconProps.class]
|
|
346
|
+
}, _ctx.ptm('rejectButton')['icon']), null, 16)
|
|
347
347
|
])
|
|
348
348
|
]),
|
|
349
349
|
_: 3
|
|
350
|
-
}, 8, ["label", "class", "onKeydown", "autofocus"]),
|
|
350
|
+
}, 8, ["label", "class", "onKeydown", "autofocus", "pt"]),
|
|
351
351
|
createVNode(_component_CPButton, {
|
|
352
352
|
label: $options.acceptLabel,
|
|
353
353
|
class: normalizeClass($options.acceptClass),
|
|
354
354
|
onClick: _cache[1] || (_cache[1] = $event => ($options.accept())),
|
|
355
355
|
onKeydown: $options.onAcceptKeydown,
|
|
356
|
-
autofocus: $data.autoFocusAccept
|
|
356
|
+
autofocus: $data.autoFocusAccept,
|
|
357
|
+
pt: _ctx.ptm('acceptButton')
|
|
357
358
|
}, {
|
|
358
359
|
icon: withCtx((iconProps) => [
|
|
359
360
|
renderSlot(_ctx.$slots, "accepticon", {}, () => [
|
|
360
|
-
createElementVNode("span", {
|
|
361
|
-
class:
|
|
362
|
-
}, null,
|
|
361
|
+
createElementVNode("span", mergeProps({
|
|
362
|
+
class: [$options.acceptIcon, iconProps.class]
|
|
363
|
+
}, _ctx.ptm('acceptButton')['icon']), null, 16)
|
|
363
364
|
])
|
|
364
365
|
]),
|
|
365
366
|
_: 3
|
|
366
|
-
}, 8, ["label", "class", "onKeydown", "autofocus"])
|
|
367
|
-
])
|
|
367
|
+
}, 8, ["label", "class", "onKeydown", "autofocus", "pt"])
|
|
368
|
+
], 16)
|
|
368
369
|
], 16, _hoisted_1)), [
|
|
369
370
|
[_directive_focustrap]
|
|
370
371
|
])
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import e from"primevue/
|
|
1
|
+
import e from"primevue/basecomponent";import t from"primevue/button";import n from"primevue/confirmationeventbus";import i from"primevue/focustrap";import o from"primevue/overlayeventbus";import s from"primevue/portal";import{ZIndexUtils as r,DomHandler as c,ConnectedOverlayScrollHandler as l}from"primevue/utils";import{resolveComponent as a,resolveDirective as p,openBlock as u,createBlock as f,withCtx as m,createVNode as h,Transition as d,withDirectives as v,createElementBlock as b,mergeProps as L,renderSlot as g,resolveDynamicComponent as y,createCommentVNode as C,createElementVNode as k,toDisplayString as j,normalizeClass as w}from"vue";var A={name:"ConfirmPopup",extends:e,inheritAttrs:!1,props:{group:String},data:()=>({visible:!1,confirmation:null,autoFocusAccept:null,autoFocusReject:null}),target:null,outsideClickListener:null,scrollHandler:null,resizeListener:null,container:null,confirmListener:null,closeListener:null,mounted(){this.confirmListener=e=>{e&&e.group===this.group&&(this.confirmation=e,this.target=e.target,this.confirmation.onShow&&this.confirmation.onShow(),this.visible=!0)},this.closeListener=()=>{this.visible=!1,this.confirmation=null},n.on("confirm",this.confirmListener),n.on("close",this.closeListener)},beforeUnmount(){n.off("confirm",this.confirmListener),n.off("close",this.closeListener),this.unbindOutsideClickListener(),this.scrollHandler&&(this.scrollHandler.destroy(),this.scrollHandler=null),this.unbindResizeListener(),this.container&&(r.clear(this.container),this.container=null),this.target=null,this.confirmation=null},methods:{accept(){this.confirmation.accept&&this.confirmation.accept(),this.visible=!1},reject(){this.confirmation.reject&&this.confirmation.reject(),this.visible=!1},onHide(){this.confirmation.onHide&&this.confirmation.onHide(),this.visible=!1},onAcceptKeydown(e){"Space"!==e.code&&"Enter"!==e.code||(this.accept(),c.focus(this.target),e.preventDefault())},onRejectKeydown(e){"Space"!==e.code&&"Enter"!==e.code||(this.reject(),c.focus(this.target),e.preventDefault())},onEnter(e){this.autoFocusAccept=void 0===this.confirmation.defaultFocus||"accept"===this.confirmation.defaultFocus,this.autoFocusReject="reject"===this.confirmation.defaultFocus,this.bindOutsideClickListener(),this.bindScrollListener(),this.bindResizeListener(),r.set("overlay",e,this.$primevue.config.zIndex.overlay)},onAfterEnter(){this.focus()},onLeave(){this.autoFocusAccept=null,this.autoFocusReject=null,this.unbindOutsideClickListener(),this.unbindScrollListener(),this.unbindResizeListener()},onAfterLeave(e){r.clear(e)},alignOverlay(){c.absolutePosition(this.container,this.target);const e=c.getOffset(this.container),t=c.getOffset(this.target);let n=0;e.left<t.left&&(n=t.left-e.left),this.container.style.setProperty("--overlayArrowLeft",`${n}px`),e.top<t.top&&c.addClass(this.container,"p-confirm-popup-flipped")},bindOutsideClickListener(){this.outsideClickListener||(this.outsideClickListener=e=>{this.visible&&this.container&&!this.container.contains(e.target)&&!this.isTargetClicked(e)?(this.confirmation.onHide&&this.confirmation.onHide(),this.visible=!1):this.alignOverlay()},document.addEventListener("click",this.outsideClickListener))},unbindOutsideClickListener(){this.outsideClickListener&&(document.removeEventListener("click",this.outsideClickListener),this.outsideClickListener=null)},bindScrollListener(){this.scrollHandler||(this.scrollHandler=new l(this.target,(()=>{this.visible&&(this.visible=!1)}))),this.scrollHandler.bindScrollListener()},unbindScrollListener(){this.scrollHandler&&this.scrollHandler.unbindScrollListener()},bindResizeListener(){this.resizeListener||(this.resizeListener=()=>{this.visible&&!c.isTouchDevice()&&(this.visible=!1)},window.addEventListener("resize",this.resizeListener))},unbindResizeListener(){this.resizeListener&&(window.removeEventListener("resize",this.resizeListener),this.resizeListener=null)},focus(){let e=this.container.querySelector("[autofocus]");e&&e.focus({preventScroll:!0})},isTargetClicked(e){return this.target&&(this.target===e.target||this.target.contains(e.target))},containerRef(e){this.container=e},onOverlayClick(e){o.emit("overlay-click",{originalEvent:e,target:this.target})},onOverlayKeydown(e){"Escape"===e.code&&(n.emit("close",this.closeListener),c.focus(this.target))}},computed:{containerClass(){return["p-confirm-popup p-component",{"p-input-filled":"filled"===this.$primevue.config.inputStyle,"p-ripple-disabled":!1===this.$primevue.config.ripple}]},message(){return this.confirmation?this.confirmation.message:null},iconClass(){return["p-confirm-popup-icon",this.confirmation?this.confirmation.icon:null]},acceptLabel(){return this.confirmation?this.confirmation.acceptLabel||this.$primevue.config.locale.accept:null},rejectLabel(){return this.confirmation?this.confirmation.rejectLabel||this.$primevue.config.locale.reject:null},acceptIcon(){return this.confirmation?this.confirmation.acceptIcon:null},rejectIcon(){return this.confirmation?this.confirmation.rejectIcon:null},acceptClass(){return["p-confirm-popup-accept p-button-sm",this.confirmation?this.confirmation.acceptClass:null]},rejectClass(){return["p-confirm-popup-reject p-button-sm",this.confirmation?this.confirmation.rejectClass||"p-button-text":null]}},components:{CPButton:t,Portal:s},directives:{focustrap:i}};const E=["aria-modal"];!function(e,t){void 0===t&&(t={});var n=t.insertAt;if(e&&"undefined"!=typeof document){var i=document.head||document.getElementsByTagName("head")[0],o=document.createElement("style");o.type="text/css","top"===n&&i.firstChild?i.insertBefore(o,i.firstChild):i.appendChild(o),o.styleSheet?o.styleSheet.cssText=e:o.appendChild(document.createTextNode(e))}}("\n.p-confirm-popup {\n position: absolute;\n margin-top: 10px;\n top: 0;\n left: 0;\n}\n.p-confirm-popup-flipped {\n margin-top: 0;\n margin-bottom: 10px;\n}\n\n/* Animation */\n.p-confirm-popup-enter-from {\n opacity: 0;\n transform: scaleY(0.8);\n}\n.p-confirm-popup-leave-to {\n opacity: 0;\n}\n.p-confirm-popup-enter-active {\n transition: transform 0.12s cubic-bezier(0, 0, 0.2, 1), opacity 0.12s cubic-bezier(0, 0, 0.2, 1);\n}\n.p-confirm-popup-leave-active {\n transition: opacity 0.1s linear;\n}\n.p-confirm-popup:after,\n.p-confirm-popup:before {\n bottom: 100%;\n left: calc(var(--overlayArrowLeft, 0) + 1.25rem);\n content: ' ';\n height: 0;\n width: 0;\n position: absolute;\n pointer-events: none;\n}\n.p-confirm-popup:after {\n border-width: 8px;\n margin-left: -8px;\n}\n.p-confirm-popup:before {\n border-width: 10px;\n margin-left: -10px;\n}\n.p-confirm-popup-flipped:after,\n.p-confirm-popup-flipped:before {\n bottom: auto;\n top: 100%;\n}\n.p-confirm-popup.p-confirm-popup-flipped:after {\n border-bottom-color: transparent;\n}\n.p-confirm-popup.p-confirm-popup-flipped:before {\n border-bottom-color: transparent;\n}\n.p-confirm-popup .p-confirm-popup-content {\n display: flex;\n align-items: center;\n}\n"),A.render=function(e,t,n,i,o,s){const r=a("CPButton"),c=a("Portal"),l=p("focustrap");return u(),f(c,null,{default:m((()=>[h(d,{name:"p-confirm-popup",onEnter:s.onEnter,onAfterEnter:s.onAfterEnter,onLeave:s.onLeave,onAfterLeave:s.onAfterLeave},{default:m((()=>[o.visible?v((u(),b("div",L({key:0,ref:s.containerRef,role:"alertdialog",class:s.containerClass,"aria-modal":o.visible,onClick:t[2]||(t[2]=(...e)=>s.onOverlayClick&&s.onOverlayClick(...e)),onKeydown:t[3]||(t[3]=(...e)=>s.onOverlayKeydown&&s.onOverlayKeydown(...e))},{...e.$attrs,...e.ptm("root")}),[e.$slots.message?(u(),f(y(e.$slots.message),{key:1,message:o.confirmation},null,8,["message"])):(u(),b("div",L({key:0,class:"p-confirm-popup-content"},e.ptm("content")),[g(e.$slots,"icon",{class:"p-confirm-popup-icon"},(()=>[e.$slots.icon?(u(),f(y(e.$slots.icon),{key:0,class:"p-confirm-popup-icon"})):o.confirmation.icon?(u(),b("span",L({key:1,class:s.iconClass},e.ptm("icon")),null,16)):C("",!0)])),k("span",L({class:"p-confirm-popup-message"},e.ptm("message")),j(o.confirmation.message),17)],16)),k("div",L({class:"p-confirm-popup-footer"},e.ptm("footer")),[h(r,{label:s.rejectLabel,class:w(s.rejectClass),onClick:t[0]||(t[0]=e=>s.reject()),onKeydown:s.onRejectKeydown,autofocus:o.autoFocusReject,pt:e.ptm("rejectButton")},{icon:m((t=>[g(e.$slots,"rejecticon",{},(()=>[k("span",L({class:[s.rejectIcon,t.class]},e.ptm("rejectButton").icon),null,16)]))])),_:3},8,["label","class","onKeydown","autofocus","pt"]),h(r,{label:s.acceptLabel,class:w(s.acceptClass),onClick:t[1]||(t[1]=e=>s.accept()),onKeydown:s.onAcceptKeydown,autofocus:o.autoFocusAccept,pt:e.ptm("acceptButton")},{icon:m((t=>[g(e.$slots,"accepticon",{},(()=>[k("span",L({class:[s.acceptIcon,t.class]},e.ptm("acceptButton").icon),null,16)]))])),_:3},8,["label","class","onKeydown","autofocus","pt"])],16)],16,E)),[[l]]):C("",!0)])),_:3},8,["onEnter","onAfterEnter","onLeave","onAfterLeave"])])),_:3})};export{A as default};
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
this.primevue = this.primevue || {};
|
|
2
|
-
this.primevue.confirmpopup = (function (Button, ConfirmationEventBus, FocusTrap, OverlayEventBus, Portal, utils, vue) {
|
|
2
|
+
this.primevue.confirmpopup = (function (BaseComponent, Button, ConfirmationEventBus, FocusTrap, OverlayEventBus, Portal, utils, vue) {
|
|
3
3
|
'use strict';
|
|
4
4
|
|
|
5
5
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
6
6
|
|
|
7
|
+
var BaseComponent__default = /*#__PURE__*/_interopDefaultLegacy(BaseComponent);
|
|
7
8
|
var Button__default = /*#__PURE__*/_interopDefaultLegacy(Button);
|
|
8
9
|
var ConfirmationEventBus__default = /*#__PURE__*/_interopDefaultLegacy(ConfirmationEventBus);
|
|
9
10
|
var FocusTrap__default = /*#__PURE__*/_interopDefaultLegacy(FocusTrap);
|
|
@@ -12,6 +13,7 @@ this.primevue.confirmpopup = (function (Button, ConfirmationEventBus, FocusTrap,
|
|
|
12
13
|
|
|
13
14
|
var script = {
|
|
14
15
|
name: 'ConfirmPopup',
|
|
16
|
+
extends: BaseComponent__default["default"],
|
|
15
17
|
inheritAttrs: false,
|
|
16
18
|
props: {
|
|
17
19
|
group: String
|
|
@@ -282,12 +284,6 @@ this.primevue.confirmpopup = (function (Button, ConfirmationEventBus, FocusTrap,
|
|
|
282
284
|
};
|
|
283
285
|
|
|
284
286
|
const _hoisted_1 = ["aria-modal"];
|
|
285
|
-
const _hoisted_2 = {
|
|
286
|
-
key: 0,
|
|
287
|
-
class: "p-confirm-popup-content"
|
|
288
|
-
};
|
|
289
|
-
const _hoisted_3 = { class: "p-confirm-popup-message" };
|
|
290
|
-
const _hoisted_4 = { class: "p-confirm-popup-footer" };
|
|
291
287
|
|
|
292
288
|
function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
293
289
|
const _component_CPButton = vue.resolveComponent("CPButton");
|
|
@@ -313,9 +309,12 @@ this.primevue.confirmpopup = (function (Button, ConfirmationEventBus, FocusTrap,
|
|
|
313
309
|
"aria-modal": $data.visible,
|
|
314
310
|
onClick: _cache[2] || (_cache[2] = (...args) => ($options.onOverlayClick && $options.onOverlayClick(...args))),
|
|
315
311
|
onKeydown: _cache[3] || (_cache[3] = (...args) => ($options.onOverlayKeydown && $options.onOverlayKeydown(...args)))
|
|
316
|
-
}, _ctx.$attrs), [
|
|
312
|
+
}, { ..._ctx.$attrs, ..._ctx.ptm('root') }), [
|
|
317
313
|
(!_ctx.$slots.message)
|
|
318
|
-
? (vue.openBlock(), vue.createElementBlock("div",
|
|
314
|
+
? (vue.openBlock(), vue.createElementBlock("div", vue.mergeProps({
|
|
315
|
+
key: 0,
|
|
316
|
+
class: "p-confirm-popup-content"
|
|
317
|
+
}, _ctx.ptm('content')), [
|
|
319
318
|
vue.renderSlot(_ctx.$slots, "icon", { class: "p-confirm-popup-icon" }, () => [
|
|
320
319
|
(_ctx.$slots.icon)
|
|
321
320
|
? (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(_ctx.$slots.icon), {
|
|
@@ -323,52 +322,54 @@ this.primevue.confirmpopup = (function (Button, ConfirmationEventBus, FocusTrap,
|
|
|
323
322
|
class: "p-confirm-popup-icon"
|
|
324
323
|
}))
|
|
325
324
|
: ($data.confirmation.icon)
|
|
326
|
-
? (vue.openBlock(), vue.createElementBlock("span", {
|
|
325
|
+
? (vue.openBlock(), vue.createElementBlock("span", vue.mergeProps({
|
|
327
326
|
key: 1,
|
|
328
|
-
class:
|
|
329
|
-
}, null,
|
|
327
|
+
class: $options.iconClass
|
|
328
|
+
}, _ctx.ptm('icon')), null, 16))
|
|
330
329
|
: vue.createCommentVNode("", true)
|
|
331
330
|
]),
|
|
332
|
-
vue.createElementVNode("span",
|
|
333
|
-
]))
|
|
331
|
+
vue.createElementVNode("span", vue.mergeProps({ class: "p-confirm-popup-message" }, _ctx.ptm('message')), vue.toDisplayString($data.confirmation.message), 17)
|
|
332
|
+
], 16))
|
|
334
333
|
: (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(_ctx.$slots.message), {
|
|
335
334
|
key: 1,
|
|
336
335
|
message: $data.confirmation
|
|
337
336
|
}, null, 8, ["message"])),
|
|
338
|
-
vue.createElementVNode("div",
|
|
337
|
+
vue.createElementVNode("div", vue.mergeProps({ class: "p-confirm-popup-footer" }, _ctx.ptm('footer')), [
|
|
339
338
|
vue.createVNode(_component_CPButton, {
|
|
340
339
|
label: $options.rejectLabel,
|
|
341
340
|
class: vue.normalizeClass($options.rejectClass),
|
|
342
341
|
onClick: _cache[0] || (_cache[0] = $event => ($options.reject())),
|
|
343
342
|
onKeydown: $options.onRejectKeydown,
|
|
344
|
-
autofocus: $data.autoFocusReject
|
|
343
|
+
autofocus: $data.autoFocusReject,
|
|
344
|
+
pt: _ctx.ptm('rejectButton')
|
|
345
345
|
}, {
|
|
346
346
|
icon: vue.withCtx((iconProps) => [
|
|
347
347
|
vue.renderSlot(_ctx.$slots, "rejecticon", {}, () => [
|
|
348
|
-
vue.createElementVNode("span", {
|
|
349
|
-
class:
|
|
350
|
-
}, null,
|
|
348
|
+
vue.createElementVNode("span", vue.mergeProps({
|
|
349
|
+
class: [$options.rejectIcon, iconProps.class]
|
|
350
|
+
}, _ctx.ptm('rejectButton')['icon']), null, 16)
|
|
351
351
|
])
|
|
352
352
|
]),
|
|
353
353
|
_: 3
|
|
354
|
-
}, 8, ["label", "class", "onKeydown", "autofocus"]),
|
|
354
|
+
}, 8, ["label", "class", "onKeydown", "autofocus", "pt"]),
|
|
355
355
|
vue.createVNode(_component_CPButton, {
|
|
356
356
|
label: $options.acceptLabel,
|
|
357
357
|
class: vue.normalizeClass($options.acceptClass),
|
|
358
358
|
onClick: _cache[1] || (_cache[1] = $event => ($options.accept())),
|
|
359
359
|
onKeydown: $options.onAcceptKeydown,
|
|
360
|
-
autofocus: $data.autoFocusAccept
|
|
360
|
+
autofocus: $data.autoFocusAccept,
|
|
361
|
+
pt: _ctx.ptm('acceptButton')
|
|
361
362
|
}, {
|
|
362
363
|
icon: vue.withCtx((iconProps) => [
|
|
363
364
|
vue.renderSlot(_ctx.$slots, "accepticon", {}, () => [
|
|
364
|
-
vue.createElementVNode("span", {
|
|
365
|
-
class:
|
|
366
|
-
}, null,
|
|
365
|
+
vue.createElementVNode("span", vue.mergeProps({
|
|
366
|
+
class: [$options.acceptIcon, iconProps.class]
|
|
367
|
+
}, _ctx.ptm('acceptButton')['icon']), null, 16)
|
|
367
368
|
])
|
|
368
369
|
]),
|
|
369
370
|
_: 3
|
|
370
|
-
}, 8, ["label", "class", "onKeydown", "autofocus"])
|
|
371
|
-
])
|
|
371
|
+
}, 8, ["label", "class", "onKeydown", "autofocus", "pt"])
|
|
372
|
+
], 16)
|
|
372
373
|
], 16, _hoisted_1)), [
|
|
373
374
|
[_directive_focustrap]
|
|
374
375
|
])
|
|
@@ -415,4 +416,4 @@ this.primevue.confirmpopup = (function (Button, ConfirmationEventBus, FocusTrap,
|
|
|
415
416
|
|
|
416
417
|
return script;
|
|
417
418
|
|
|
418
|
-
})(primevue.button, primevue.confirmationeventbus, primevue.focustrap, primevue.overlayeventbus, primevue.portal, primevue.utils, Vue);
|
|
419
|
+
})(primevue.basecomponent, primevue.button, primevue.confirmationeventbus, primevue.focustrap, primevue.overlayeventbus, primevue.portal, primevue.utils, Vue);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
this.primevue=this.primevue||{},this.primevue.confirmpopup=function(e,t,n,i,o,r,s){"use strict";function
|
|
1
|
+
this.primevue=this.primevue||{},this.primevue.confirmpopup=function(e,t,n,i,o,r,s,c){"use strict";function l(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var a=l(e),p=l(t),u=l(n),m=l(i),f=l(o),d=l(r),h={name:"ConfirmPopup",extends:a.default,inheritAttrs:!1,props:{group:String},data:()=>({visible:!1,confirmation:null,autoFocusAccept:null,autoFocusReject:null}),target:null,outsideClickListener:null,scrollHandler:null,resizeListener:null,container:null,confirmListener:null,closeListener:null,mounted(){this.confirmListener=e=>{e&&e.group===this.group&&(this.confirmation=e,this.target=e.target,this.confirmation.onShow&&this.confirmation.onShow(),this.visible=!0)},this.closeListener=()=>{this.visible=!1,this.confirmation=null},u.default.on("confirm",this.confirmListener),u.default.on("close",this.closeListener)},beforeUnmount(){u.default.off("confirm",this.confirmListener),u.default.off("close",this.closeListener),this.unbindOutsideClickListener(),this.scrollHandler&&(this.scrollHandler.destroy(),this.scrollHandler=null),this.unbindResizeListener(),this.container&&(s.ZIndexUtils.clear(this.container),this.container=null),this.target=null,this.confirmation=null},methods:{accept(){this.confirmation.accept&&this.confirmation.accept(),this.visible=!1},reject(){this.confirmation.reject&&this.confirmation.reject(),this.visible=!1},onHide(){this.confirmation.onHide&&this.confirmation.onHide(),this.visible=!1},onAcceptKeydown(e){"Space"!==e.code&&"Enter"!==e.code||(this.accept(),s.DomHandler.focus(this.target),e.preventDefault())},onRejectKeydown(e){"Space"!==e.code&&"Enter"!==e.code||(this.reject(),s.DomHandler.focus(this.target),e.preventDefault())},onEnter(e){this.autoFocusAccept=void 0===this.confirmation.defaultFocus||"accept"===this.confirmation.defaultFocus,this.autoFocusReject="reject"===this.confirmation.defaultFocus,this.bindOutsideClickListener(),this.bindScrollListener(),this.bindResizeListener(),s.ZIndexUtils.set("overlay",e,this.$primevue.config.zIndex.overlay)},onAfterEnter(){this.focus()},onLeave(){this.autoFocusAccept=null,this.autoFocusReject=null,this.unbindOutsideClickListener(),this.unbindScrollListener(),this.unbindResizeListener()},onAfterLeave(e){s.ZIndexUtils.clear(e)},alignOverlay(){s.DomHandler.absolutePosition(this.container,this.target);const e=s.DomHandler.getOffset(this.container),t=s.DomHandler.getOffset(this.target);let n=0;e.left<t.left&&(n=t.left-e.left),this.container.style.setProperty("--overlayArrowLeft",`${n}px`),e.top<t.top&&s.DomHandler.addClass(this.container,"p-confirm-popup-flipped")},bindOutsideClickListener(){this.outsideClickListener||(this.outsideClickListener=e=>{this.visible&&this.container&&!this.container.contains(e.target)&&!this.isTargetClicked(e)?(this.confirmation.onHide&&this.confirmation.onHide(),this.visible=!1):this.alignOverlay()},document.addEventListener("click",this.outsideClickListener))},unbindOutsideClickListener(){this.outsideClickListener&&(document.removeEventListener("click",this.outsideClickListener),this.outsideClickListener=null)},bindScrollListener(){this.scrollHandler||(this.scrollHandler=new s.ConnectedOverlayScrollHandler(this.target,(()=>{this.visible&&(this.visible=!1)}))),this.scrollHandler.bindScrollListener()},unbindScrollListener(){this.scrollHandler&&this.scrollHandler.unbindScrollListener()},bindResizeListener(){this.resizeListener||(this.resizeListener=()=>{this.visible&&!s.DomHandler.isTouchDevice()&&(this.visible=!1)},window.addEventListener("resize",this.resizeListener))},unbindResizeListener(){this.resizeListener&&(window.removeEventListener("resize",this.resizeListener),this.resizeListener=null)},focus(){let e=this.container.querySelector("[autofocus]");e&&e.focus({preventScroll:!0})},isTargetClicked(e){return this.target&&(this.target===e.target||this.target.contains(e.target))},containerRef(e){this.container=e},onOverlayClick(e){f.default.emit("overlay-click",{originalEvent:e,target:this.target})},onOverlayKeydown(e){"Escape"===e.code&&(u.default.emit("close",this.closeListener),s.DomHandler.focus(this.target))}},computed:{containerClass(){return["p-confirm-popup p-component",{"p-input-filled":"filled"===this.$primevue.config.inputStyle,"p-ripple-disabled":!1===this.$primevue.config.ripple}]},message(){return this.confirmation?this.confirmation.message:null},iconClass(){return["p-confirm-popup-icon",this.confirmation?this.confirmation.icon:null]},acceptLabel(){return this.confirmation?this.confirmation.acceptLabel||this.$primevue.config.locale.accept:null},rejectLabel(){return this.confirmation?this.confirmation.rejectLabel||this.$primevue.config.locale.reject:null},acceptIcon(){return this.confirmation?this.confirmation.acceptIcon:null},rejectIcon(){return this.confirmation?this.confirmation.rejectIcon:null},acceptClass(){return["p-confirm-popup-accept p-button-sm",this.confirmation?this.confirmation.acceptClass:null]},rejectClass(){return["p-confirm-popup-reject p-button-sm",this.confirmation?this.confirmation.rejectClass||"p-button-text":null]}},components:{CPButton:p.default,Portal:d.default},directives:{focustrap:m.default}};const v=["aria-modal"];return function(e,t){void 0===t&&(t={});var n=t.insertAt;if(e&&"undefined"!=typeof document){var i=document.head||document.getElementsByTagName("head")[0],o=document.createElement("style");o.type="text/css","top"===n&&i.firstChild?i.insertBefore(o,i.firstChild):i.appendChild(o),o.styleSheet?o.styleSheet.cssText=e:o.appendChild(document.createTextNode(e))}}("\n.p-confirm-popup {\n position: absolute;\n margin-top: 10px;\n top: 0;\n left: 0;\n}\n.p-confirm-popup-flipped {\n margin-top: 0;\n margin-bottom: 10px;\n}\n\n/* Animation */\n.p-confirm-popup-enter-from {\n opacity: 0;\n transform: scaleY(0.8);\n}\n.p-confirm-popup-leave-to {\n opacity: 0;\n}\n.p-confirm-popup-enter-active {\n transition: transform 0.12s cubic-bezier(0, 0, 0.2, 1), opacity 0.12s cubic-bezier(0, 0, 0.2, 1);\n}\n.p-confirm-popup-leave-active {\n transition: opacity 0.1s linear;\n}\n.p-confirm-popup:after,\n.p-confirm-popup:before {\n bottom: 100%;\n left: calc(var(--overlayArrowLeft, 0) + 1.25rem);\n content: ' ';\n height: 0;\n width: 0;\n position: absolute;\n pointer-events: none;\n}\n.p-confirm-popup:after {\n border-width: 8px;\n margin-left: -8px;\n}\n.p-confirm-popup:before {\n border-width: 10px;\n margin-left: -10px;\n}\n.p-confirm-popup-flipped:after,\n.p-confirm-popup-flipped:before {\n bottom: auto;\n top: 100%;\n}\n.p-confirm-popup.p-confirm-popup-flipped:after {\n border-bottom-color: transparent;\n}\n.p-confirm-popup.p-confirm-popup-flipped:before {\n border-bottom-color: transparent;\n}\n.p-confirm-popup .p-confirm-popup-content {\n display: flex;\n align-items: center;\n}\n"),h.render=function(e,t,n,i,o,r){const s=c.resolveComponent("CPButton"),l=c.resolveComponent("Portal"),a=c.resolveDirective("focustrap");return c.openBlock(),c.createBlock(l,null,{default:c.withCtx((()=>[c.createVNode(c.Transition,{name:"p-confirm-popup",onEnter:r.onEnter,onAfterEnter:r.onAfterEnter,onLeave:r.onLeave,onAfterLeave:r.onAfterLeave},{default:c.withCtx((()=>[o.visible?c.withDirectives((c.openBlock(),c.createElementBlock("div",c.mergeProps({key:0,ref:r.containerRef,role:"alertdialog",class:r.containerClass,"aria-modal":o.visible,onClick:t[2]||(t[2]=(...e)=>r.onOverlayClick&&r.onOverlayClick(...e)),onKeydown:t[3]||(t[3]=(...e)=>r.onOverlayKeydown&&r.onOverlayKeydown(...e))},{...e.$attrs,...e.ptm("root")}),[e.$slots.message?(c.openBlock(),c.createBlock(c.resolveDynamicComponent(e.$slots.message),{key:1,message:o.confirmation},null,8,["message"])):(c.openBlock(),c.createElementBlock("div",c.mergeProps({key:0,class:"p-confirm-popup-content"},e.ptm("content")),[c.renderSlot(e.$slots,"icon",{class:"p-confirm-popup-icon"},(()=>[e.$slots.icon?(c.openBlock(),c.createBlock(c.resolveDynamicComponent(e.$slots.icon),{key:0,class:"p-confirm-popup-icon"})):o.confirmation.icon?(c.openBlock(),c.createElementBlock("span",c.mergeProps({key:1,class:r.iconClass},e.ptm("icon")),null,16)):c.createCommentVNode("",!0)])),c.createElementVNode("span",c.mergeProps({class:"p-confirm-popup-message"},e.ptm("message")),c.toDisplayString(o.confirmation.message),17)],16)),c.createElementVNode("div",c.mergeProps({class:"p-confirm-popup-footer"},e.ptm("footer")),[c.createVNode(s,{label:r.rejectLabel,class:c.normalizeClass(r.rejectClass),onClick:t[0]||(t[0]=e=>r.reject()),onKeydown:r.onRejectKeydown,autofocus:o.autoFocusReject,pt:e.ptm("rejectButton")},{icon:c.withCtx((t=>[c.renderSlot(e.$slots,"rejecticon",{},(()=>[c.createElementVNode("span",c.mergeProps({class:[r.rejectIcon,t.class]},e.ptm("rejectButton").icon),null,16)]))])),_:3},8,["label","class","onKeydown","autofocus","pt"]),c.createVNode(s,{label:r.acceptLabel,class:c.normalizeClass(r.acceptClass),onClick:t[1]||(t[1]=e=>r.accept()),onKeydown:r.onAcceptKeydown,autofocus:o.autoFocusAccept,pt:e.ptm("acceptButton")},{icon:c.withCtx((t=>[c.renderSlot(e.$slots,"accepticon",{},(()=>[c.createElementVNode("span",c.mergeProps({class:[r.acceptIcon,t.class]},e.ptm("acceptButton").icon),null,16)]))])),_:3},8,["label","class","onKeydown","autofocus","pt"])],16)],16,v)),[[a]]):c.createCommentVNode("",!0)])),_:3},8,["onEnter","onAfterEnter","onLeave","onAfterLeave"])])),_:3})},h}(primevue.basecomponent,primevue.button,primevue.confirmationeventbus,primevue.focustrap,primevue.overlayeventbus,primevue.portal,primevue.utils,Vue);
|