primevue 3.31.0 → 3.32.1
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/accordion/Accordion.d.ts +7 -7
- package/accordion/Accordion.vue +1 -1
- package/accordion/accordion.cjs.js +3 -3
- package/accordion/accordion.cjs.min.js +1 -1
- package/accordion/accordion.esm.js +3 -3
- package/accordion/accordion.esm.min.js +1 -1
- package/accordion/accordion.js +3 -3
- package/accordion/accordion.min.js +1 -1
- package/accordiontab/AccordionTab.d.ts +22 -15
- package/autocomplete/AutoComplete.d.ts +50 -29
- package/autocomplete/AutoComplete.vue +4 -4
- package/autocomplete/BaseAutoComplete.vue +4 -0
- package/autocomplete/autocomplete.cjs.js +10 -5
- package/autocomplete/autocomplete.cjs.min.js +1 -1
- package/autocomplete/autocomplete.esm.js +10 -5
- package/autocomplete/autocomplete.esm.min.js +1 -1
- package/autocomplete/autocomplete.js +10 -5
- package/autocomplete/autocomplete.min.js +1 -1
- package/avatar/Avatar.d.ts +9 -9
- package/avatar/Avatar.vue +2 -2
- package/avatar/avatar.cjs.js +2 -2
- package/avatar/avatar.cjs.min.js +1 -1
- package/avatar/avatar.esm.js +2 -2
- package/avatar/avatar.esm.min.js +1 -1
- package/avatar/avatar.js +2 -2
- package/avatar/avatar.min.js +1 -1
- package/avatargroup/AvatarGroup.d.ts +5 -5
- package/badge/Badge.d.ts +5 -5
- package/badgedirective/BadgeDirective.d.ts +47 -5
- package/badgedirective/badgedirective.cjs.js +11 -1
- package/badgedirective/badgedirective.cjs.min.js +1 -1
- package/badgedirective/badgedirective.esm.js +11 -1
- package/badgedirective/badgedirective.esm.min.js +1 -1
- package/badgedirective/badgedirective.js +11 -1
- package/badgedirective/badgedirective.min.js +1 -1
- package/basecomponent/BaseComponent.vue +111 -30
- package/basecomponent/basecomponent.cjs.js +133 -51
- package/basecomponent/basecomponent.cjs.min.js +1 -1
- package/basecomponent/basecomponent.esm.js +133 -51
- package/basecomponent/basecomponent.esm.min.js +1 -1
- package/basecomponent/basecomponent.js +133 -51
- package/basecomponent/basecomponent.min.js +1 -1
- package/basedirective/basedirective.cjs.js +56 -10
- package/basedirective/basedirective.cjs.min.js +1 -1
- package/basedirective/basedirective.esm.js +56 -10
- package/basedirective/basedirective.esm.min.js +1 -1
- package/basedirective/basedirective.js +56 -10
- package/basedirective/basedirective.min.js +1 -1
- package/baseicon/BaseIcon.vue +44 -32
- package/baseicon/baseicon.cjs.js +19 -30
- package/baseicon/baseicon.cjs.min.js +1 -1
- package/baseicon/baseicon.esm.js +19 -30
- package/baseicon/baseicon.esm.min.js +1 -1
- package/baseicon/baseicon.js +20 -32
- package/baseicon/baseicon.min.js +1 -1
- package/blockui/BaseBlockUI.vue +0 -8
- package/blockui/BlockUI.d.ts +9 -5
- package/blockui/BlockUI.vue +35 -10
- package/blockui/blockui.cjs.js +34 -12
- package/blockui/blockui.cjs.min.js +1 -1
- package/blockui/blockui.esm.js +34 -12
- package/blockui/blockui.esm.min.js +1 -1
- package/blockui/blockui.js +34 -12
- package/blockui/blockui.min.js +1 -1
- package/breadcrumb/Breadcrumb.d.ts +12 -12
- package/button/Button.d.ts +10 -9
- package/button/Button.vue +6 -2
- package/button/button.cjs.js +7 -2
- package/button/button.cjs.min.js +1 -1
- package/button/button.esm.js +7 -2
- package/button/button.esm.min.js +1 -1
- package/button/button.js +7 -2
- package/button/button.min.js +1 -1
- package/calendar/Calendar.d.ts +131 -55
- package/calendar/Calendar.vue +54 -11
- package/calendar/calendar.cjs.js +79 -41
- package/calendar/calendar.cjs.min.js +1 -1
- package/calendar/calendar.esm.js +79 -41
- package/calendar/calendar.esm.min.js +1 -1
- package/calendar/calendar.js +79 -41
- package/calendar/calendar.min.js +1 -1
- package/card/Card.d.ts +11 -11
- package/carousel/Carousel.d.ts +34 -22
- package/carousel/Carousel.vue +12 -3
- package/carousel/carousel.cjs.js +15 -5
- package/carousel/carousel.cjs.min.js +1 -1
- package/carousel/carousel.esm.js +15 -5
- package/carousel/carousel.esm.min.js +1 -1
- package/carousel/carousel.js +15 -5
- package/carousel/carousel.min.js +1 -1
- package/cascadeselect/CascadeSelect.d.ts +27 -21
- package/cascadeselect/CascadeSelect.vue +1 -1
- package/cascadeselect/cascadeselect.cjs.js +3 -3
- package/cascadeselect/cascadeselect.cjs.min.js +1 -1
- package/cascadeselect/cascadeselect.esm.js +3 -3
- package/cascadeselect/cascadeselect.esm.min.js +1 -1
- package/cascadeselect/cascadeselect.js +3 -3
- package/cascadeselect/cascadeselect.min.js +1 -1
- package/chart/Chart.d.ts +7 -7
- package/checkbox/Checkbox.d.ts +10 -10
- package/chip/Chip.d.ts +13 -11
- package/chips/Chips.d.ts +23 -14
- package/chips/Chips.vue +1 -1
- package/chips/chips.cjs.js +1 -0
- package/chips/chips.cjs.min.js +1 -1
- package/chips/chips.esm.js +1 -0
- package/chips/chips.esm.min.js +1 -1
- package/chips/chips.js +1 -0
- package/chips/chips.min.js +1 -1
- package/colorpicker/ColorPicker.d.ts +20 -13
- package/colorpicker/ColorPicker.vue +2 -41
- package/colorpicker/colorpicker.cjs.js +11 -50
- package/colorpicker/colorpicker.cjs.min.js +1 -1
- package/colorpicker/colorpicker.esm.js +11 -50
- package/colorpicker/colorpicker.esm.min.js +1 -1
- package/colorpicker/colorpicker.js +11 -50
- package/colorpicker/colorpicker.min.js +1 -1
- package/column/Column.d.ts +71 -68
- package/columngroup/ColumnGroup.d.ts +5 -5
- package/config/PrimeVue.d.ts +10 -2
- package/config/config.cjs.js +4 -1
- package/config/config.cjs.min.js +1 -1
- package/config/config.esm.js +4 -1
- package/config/config.esm.min.js +1 -1
- package/config/config.js +4 -1
- package/config/config.min.js +1 -1
- package/confirmdialog/ConfirmDialog.d.ts +17 -16
- package/confirmpopup/ConfirmPopup.d.ts +19 -12
- package/confirmpopup/ConfirmPopup.vue +1 -1
- package/confirmpopup/confirmpopup.cjs.js +3 -3
- package/confirmpopup/confirmpopup.cjs.min.js +1 -1
- package/confirmpopup/confirmpopup.esm.js +4 -4
- package/confirmpopup/confirmpopup.esm.min.js +1 -1
- package/confirmpopup/confirmpopup.js +3 -3
- package/confirmpopup/confirmpopup.min.js +1 -1
- package/contextmenu/ContextMenu.d.ts +22 -15
- package/contextmenu/ContextMenu.vue +1 -1
- package/contextmenu/ContextMenuSub.vue +1 -1
- package/contextmenu/contextmenu.cjs.js +6 -6
- package/contextmenu/contextmenu.cjs.min.js +1 -1
- package/contextmenu/contextmenu.esm.js +7 -7
- package/contextmenu/contextmenu.esm.min.js +1 -1
- package/contextmenu/contextmenu.js +6 -6
- package/contextmenu/contextmenu.min.js +1 -1
- package/core/core.js +2082 -1386
- package/core/core.min.js +19 -17
- package/datatable/BaseDataTable.vue +1 -1
- package/datatable/BodyCell.vue +1 -0
- package/datatable/ColumnFilter.vue +1 -1
- package/datatable/DataTable.d.ts +41 -33
- package/datatable/DataTable.vue +47 -15
- package/datatable/TableBody.vue +1 -1
- package/datatable/datatable.cjs.js +125 -77
- package/datatable/datatable.cjs.min.js +1 -1
- package/datatable/datatable.esm.js +125 -77
- package/datatable/datatable.esm.min.js +1 -1
- package/datatable/datatable.js +125 -77
- package/datatable/datatable.min.js +1 -1
- package/dataview/DataView.d.ts +12 -12
- package/dataview/DataView.vue +2 -1
- package/dataview/dataview.cjs.js +4 -3
- package/dataview/dataview.cjs.min.js +1 -1
- package/dataview/dataview.esm.js +4 -3
- package/dataview/dataview.esm.min.js +1 -1
- package/dataview/dataview.js +4 -3
- package/dataview/dataview.min.js +1 -1
- package/dataviewlayoutoptions/DataViewLayoutOptions.d.ts +9 -9
- package/deferredcontent/DeferredContent.d.ts +5 -5
- package/dialog/BaseDialog.vue +3 -7
- package/dialog/Dialog.d.ts +23 -17
- package/dialog/Dialog.vue +10 -6
- package/dialog/dialog.cjs.js +17 -11
- package/dialog/dialog.cjs.min.js +1 -1
- package/dialog/dialog.esm.js +17 -11
- package/dialog/dialog.esm.min.js +1 -1
- package/dialog/dialog.js +17 -11
- package/dialog/dialog.min.js +1 -1
- package/divider/BaseDivider.vue +9 -24
- package/divider/Divider.d.ts +6 -6
- package/divider/Divider.vue +1 -1
- package/divider/divider.cjs.js +15 -2
- package/divider/divider.cjs.min.js +1 -1
- package/divider/divider.esm.js +15 -2
- package/divider/divider.esm.min.js +1 -1
- package/divider/divider.js +15 -2
- package/divider/divider.min.js +1 -1
- package/dock/BaseDock.vue +1 -1
- package/dock/Dock.d.ts +11 -11
- package/dock/Dock.vue +19 -2
- package/dock/dock.cjs.js +10 -4
- package/dock/dock.cjs.min.js +1 -1
- package/dock/dock.esm.js +10 -4
- package/dock/dock.esm.min.js +1 -1
- package/dock/dock.js +10 -4
- package/dock/dock.min.js +1 -1
- package/dropdown/BaseDropdown.vue +5 -5
- package/dropdown/Dropdown.d.ts +55 -38
- package/dropdown/Dropdown.vue +11 -2
- package/dropdown/dropdown.cjs.js +17 -9
- package/dropdown/dropdown.cjs.min.js +1 -1
- package/dropdown/dropdown.esm.js +17 -9
- package/dropdown/dropdown.esm.min.js +1 -1
- package/dropdown/dropdown.js +17 -9
- package/dropdown/dropdown.min.js +1 -1
- package/editor/BaseEditor.vue +0 -14
- package/editor/Editor.d.ts +21 -21
- package/editor/Editor.vue +20 -20
- package/editor/editor.cjs.js +20 -34
- package/editor/editor.cjs.min.js +1 -1
- package/editor/editor.esm.js +20 -34
- package/editor/editor.esm.min.js +1 -1
- package/editor/editor.js +20 -34
- package/editor/editor.min.js +1 -1
- package/fieldset/Fieldset.d.ts +19 -13
- package/fieldset/Fieldset.vue +1 -1
- package/fieldset/fieldset.cjs.js +3 -3
- package/fieldset/fieldset.cjs.min.js +1 -1
- package/fieldset/fieldset.esm.js +3 -3
- package/fieldset/fieldset.esm.min.js +1 -1
- package/fieldset/fieldset.js +3 -3
- package/fieldset/fieldset.min.js +1 -1
- package/fileupload/FileUpload.d.ts +36 -31
- package/fileupload/FileUpload.vue +8 -4
- package/fileupload/fileupload.cjs.js +14 -4
- package/fileupload/fileupload.cjs.min.js +1 -1
- package/fileupload/fileupload.esm.js +14 -4
- package/fileupload/fileupload.esm.min.js +1 -1
- package/fileupload/fileupload.js +15 -6
- package/fileupload/fileupload.min.js +1 -1
- package/focustrap/FocusTrap.d.ts +7 -6
- package/galleria/Galleria.d.ts +55 -36
- package/galleria/Galleria.vue +1 -1
- package/galleria/GalleriaItem.vue +11 -4
- package/galleria/GalleriaThumbnails.vue +6 -1
- package/galleria/galleria.cjs.js +30 -12
- package/galleria/galleria.cjs.min.js +1 -1
- package/galleria/galleria.esm.js +30 -12
- package/galleria/galleria.esm.min.js +1 -1
- package/galleria/galleria.js +30 -12
- package/galleria/galleria.min.js +1 -1
- package/image/Image.d.ts +34 -25
- package/image/Image.vue +10 -8
- package/image/image.cjs.js +22 -8
- package/image/image.cjs.min.js +1 -1
- package/image/image.esm.js +23 -9
- package/image/image.esm.min.js +1 -1
- package/image/image.js +22 -8
- package/image/image.min.js +1 -1
- package/inlinemessage/InlineMessage.d.ts +7 -7
- package/inplace/Inplace.d.ts +10 -10
- package/inputmask/InputMask.d.ts +34 -6
- package/inputmask/InputMask.vue +9 -1
- package/inputmask/inputmask.cjs.js +9 -1
- package/inputmask/inputmask.cjs.min.js +1 -1
- package/inputmask/inputmask.esm.js +9 -1
- package/inputmask/inputmask.esm.min.js +1 -1
- package/inputmask/inputmask.js +9 -1
- package/inputmask/inputmask.min.js +1 -1
- package/inputnumber/InputNumber.d.ts +12 -12
- package/inputswitch/InputSwitch.d.ts +9 -9
- package/inputtext/InputText.d.ts +5 -5
- package/knob/Knob.d.ts +9 -9
- package/listbox/Listbox.d.ts +22 -22
- package/megamenu/MegaMenu.d.ts +21 -20
- package/megamenu/MegaMenuSub.vue +1 -0
- package/megamenu/megamenu.cjs.js +2 -1
- package/megamenu/megamenu.cjs.min.js +1 -1
- package/megamenu/megamenu.esm.js +2 -1
- package/megamenu/megamenu.esm.min.js +1 -1
- package/megamenu/megamenu.js +2 -1
- package/megamenu/megamenu.min.js +1 -1
- package/menu/Menu.d.ts +22 -16
- package/menu/Menu.vue +1 -1
- package/menu/menu.cjs.js +3 -3
- package/menu/menu.cjs.min.js +1 -1
- package/menu/menu.esm.js +3 -3
- package/menu/menu.esm.min.js +1 -1
- package/menu/menu.js +3 -3
- package/menu/menu.min.js +1 -1
- package/menubar/Menubar.d.ts +24 -19
- package/menubar/MenubarSub.vue +3 -1
- package/menubar/menubar.cjs.js +4 -2
- package/menubar/menubar.cjs.min.js +1 -1
- package/menubar/menubar.esm.js +4 -2
- package/menubar/menubar.esm.min.js +1 -1
- package/menubar/menubar.js +4 -2
- package/menubar/menubar.min.js +1 -1
- package/message/BaseMessage.vue +5 -0
- package/message/Message.d.ts +22 -14
- package/message/Message.vue +1 -1
- package/message/message.cjs.js +4 -4
- package/message/message.cjs.min.js +1 -1
- package/message/message.esm.js +5 -5
- package/message/message.esm.min.js +1 -1
- package/message/message.js +4 -4
- package/message/message.min.js +1 -1
- package/multiselect/MultiSelect.d.ts +63 -47
- package/multiselect/MultiSelect.vue +2 -2
- package/multiselect/multiselect.cjs.js +4 -3
- package/multiselect/multiselect.cjs.min.js +1 -1
- package/multiselect/multiselect.esm.js +4 -3
- package/multiselect/multiselect.esm.min.js +1 -1
- package/multiselect/multiselect.js +4 -3
- package/multiselect/multiselect.min.js +1 -1
- package/orderlist/OrderList.d.ts +26 -20
- package/orderlist/OrderList.vue +2 -1
- package/orderlist/orderlist.cjs.js +3 -1
- package/orderlist/orderlist.cjs.min.js +1 -1
- package/orderlist/orderlist.esm.js +3 -1
- package/orderlist/orderlist.esm.min.js +1 -1
- package/orderlist/orderlist.js +3 -1
- package/orderlist/orderlist.min.js +1 -1
- package/organizationchart/OrganizationChart.d.ts +17 -17
- package/overlaypanel/OverlayPanel.d.ts +15 -9
- package/overlaypanel/OverlayPanel.vue +2 -1
- package/overlaypanel/overlaypanel.cjs.js +5 -3
- package/overlaypanel/overlaypanel.cjs.min.js +1 -1
- package/overlaypanel/overlaypanel.esm.js +6 -4
- package/overlaypanel/overlaypanel.esm.min.js +1 -1
- package/overlaypanel/overlaypanel.js +5 -3
- package/overlaypanel/overlaypanel.min.js +1 -1
- package/package.json +15 -15
- package/paginator/Paginator.d.ts +22 -22
- package/paginator/Paginator.vue +2 -1
- package/paginator/paginator.cjs.js +2 -0
- package/paginator/paginator.cjs.min.js +1 -1
- package/paginator/paginator.esm.js +3 -1
- package/paginator/paginator.esm.min.js +1 -1
- package/paginator/paginator.js +2 -0
- package/paginator/paginator.min.js +1 -1
- package/panel/Panel.d.ts +22 -15
- package/panel/Panel.vue +1 -1
- package/panel/panel.cjs.js +3 -3
- package/panel/panel.cjs.min.js +1 -1
- package/panel/panel.esm.js +3 -3
- package/panel/panel.esm.min.js +1 -1
- package/panel/panel.js +3 -3
- package/panel/panel.min.js +1 -1
- package/panelmenu/PanelMenu.d.ts +30 -23
- package/panelmenu/PanelMenu.vue +1 -1
- package/panelmenu/PanelMenuSub.vue +1 -1
- package/panelmenu/panelmenu.cjs.js +6 -6
- package/panelmenu/panelmenu.cjs.min.js +1 -1
- package/panelmenu/panelmenu.esm.js +6 -6
- package/panelmenu/panelmenu.esm.min.js +1 -1
- package/panelmenu/panelmenu.js +6 -6
- package/panelmenu/panelmenu.min.js +1 -1
- package/passthrough/index.cjs.js +30 -0
- package/passthrough/index.cjs.min.js +1 -0
- package/passthrough/index.d.ts +6 -0
- package/passthrough/index.esm.js +26 -0
- package/passthrough/index.esm.min.js +1 -0
- package/passthrough/index.js +36 -0
- package/passthrough/index.min.js +1 -0
- package/passthrough/package.json +6 -0
- package/{tailwind/tailwind.cjs.js → passthrough/tailwind/index.cjs.js} +1282 -834
- package/passthrough/tailwind/index.cjs.min.js +1 -0
- package/passthrough/tailwind/index.d.ts +4 -0
- package/{tailwind/tailwind.esm.js → passthrough/tailwind/index.esm.js} +1279 -834
- package/passthrough/tailwind/index.esm.min.js +1 -0
- package/{tailwind/tailwind.js → passthrough/tailwind/index.js} +1287 -836
- package/passthrough/tailwind/index.min.js +1 -0
- package/passthrough/tailwind/package.json +6 -0
- package/password/Password.d.ts +31 -18
- package/password/Password.vue +3 -1
- package/password/password.cjs.js +6 -4
- package/password/password.cjs.min.js +1 -1
- package/password/password.esm.js +6 -4
- package/password/password.esm.min.js +1 -1
- package/password/password.js +6 -4
- package/password/password.min.js +1 -1
- package/picklist/PickList.d.ts +44 -38
- package/picklist/PickList.vue +12 -9
- package/picklist/picklist.cjs.js +29 -9
- package/picklist/picklist.cjs.min.js +1 -1
- package/picklist/picklist.esm.js +29 -9
- package/picklist/picklist.esm.min.js +1 -1
- package/picklist/picklist.js +29 -9
- package/picklist/picklist.min.js +1 -1
- package/progressbar/ProgressBar.d.ts +7 -7
- package/progressspinner/ProgressSpinner.d.ts +7 -7
- package/radiobutton/RadioButton.d.ts +11 -11
- package/rating/Rating.d.ts +15 -14
- package/rating/Rating.vue +3 -3
- package/rating/rating.cjs.js +3 -3
- package/rating/rating.cjs.min.js +1 -1
- package/rating/rating.esm.js +3 -3
- package/rating/rating.esm.min.js +1 -1
- package/rating/rating.js +3 -3
- package/rating/rating.min.js +1 -1
- package/resources/themes/arya-blue/theme.css +11 -0
- package/resources/themes/arya-green/theme.css +11 -0
- package/resources/themes/arya-orange/theme.css +11 -0
- package/resources/themes/arya-purple/theme.css +11 -0
- package/resources/themes/bootstrap4-dark-blue/theme.css +15 -0
- package/resources/themes/bootstrap4-dark-purple/theme.css +15 -0
- package/resources/themes/bootstrap4-light-blue/theme.css +15 -0
- package/resources/themes/bootstrap4-light-purple/theme.css +15 -0
- package/resources/themes/fluent-light/theme.css +11 -0
- package/resources/themes/lara-dark-blue/theme.css +11 -0
- package/resources/themes/lara-dark-indigo/theme.css +11 -0
- package/resources/themes/lara-dark-purple/theme.css +11 -0
- package/resources/themes/lara-dark-teal/theme.css +11 -0
- package/resources/themes/lara-light-blue/theme.css +11 -0
- package/resources/themes/lara-light-indigo/theme.css +11 -0
- package/resources/themes/lara-light-purple/theme.css +11 -0
- package/resources/themes/lara-light-teal/theme.css +11 -0
- package/resources/themes/luna-amber/theme.css +11 -0
- package/resources/themes/luna-blue/theme.css +11 -0
- package/resources/themes/luna-green/theme.css +11 -0
- package/resources/themes/luna-pink/theme.css +11 -0
- package/resources/themes/md-dark-deeppurple/theme.css +11 -0
- package/resources/themes/md-dark-indigo/theme.css +11 -0
- package/resources/themes/md-light-deeppurple/theme.css +11 -0
- package/resources/themes/md-light-indigo/theme.css +11 -0
- package/resources/themes/mdc-dark-deeppurple/theme.css +11 -0
- package/resources/themes/mdc-dark-indigo/theme.css +11 -0
- package/resources/themes/mdc-light-deeppurple/theme.css +11 -0
- package/resources/themes/mdc-light-indigo/theme.css +11 -0
- package/resources/themes/mira/theme.css +11 -0
- package/resources/themes/nano/theme.css +11 -0
- package/resources/themes/nova/theme.css +11 -0
- package/resources/themes/nova-accent/theme.css +11 -0
- package/resources/themes/nova-alt/theme.css +11 -0
- package/resources/themes/nova-vue/theme.css +11 -0
- package/resources/themes/rhea/theme.css +11 -0
- package/resources/themes/saga-blue/theme.css +11 -0
- package/resources/themes/saga-green/theme.css +11 -0
- package/resources/themes/saga-orange/theme.css +11 -0
- package/resources/themes/saga-purple/theme.css +11 -0
- package/resources/themes/soho-dark/theme.css +11 -0
- package/resources/themes/soho-light/theme.css +11 -0
- package/resources/themes/tailwind-light/theme.css +11 -0
- package/resources/themes/vela-blue/theme.css +11 -0
- package/resources/themes/vela-green/theme.css +11 -0
- package/resources/themes/vela-orange/theme.css +11 -0
- package/resources/themes/vela-purple/theme.css +11 -0
- package/resources/themes/viva-dark/theme.css +11 -0
- package/resources/themes/viva-light/theme.css +11 -0
- package/ripple/Ripple.d.ts +5 -4
- package/row/Row.d.ts +2 -2
- package/scrollpanel/ScrollPanel.d.ts +9 -9
- package/scrolltop/ScrollTop.d.ts +13 -7
- package/scrolltop/ScrollTop.vue +1 -1
- package/scrolltop/scrolltop.cjs.js +3 -3
- package/scrolltop/scrolltop.cjs.min.js +1 -1
- package/scrolltop/scrolltop.esm.js +4 -4
- package/scrolltop/scrolltop.esm.min.js +1 -1
- package/scrolltop/scrolltop.js +3 -3
- package/scrolltop/scrolltop.min.js +1 -1
- package/selectbutton/SelectButton.d.ts +11 -7
- package/selectbutton/SelectButton.vue +2 -1
- package/selectbutton/selectbutton.cjs.js +2 -1
- package/selectbutton/selectbutton.cjs.min.js +1 -1
- package/selectbutton/selectbutton.esm.js +2 -1
- package/selectbutton/selectbutton.esm.min.js +1 -1
- package/selectbutton/selectbutton.js +2 -1
- package/selectbutton/selectbutton.min.js +1 -1
- package/sidebar/Sidebar.d.ts +18 -12
- package/sidebar/Sidebar.vue +2 -2
- package/sidebar/sidebar.cjs.js +4 -4
- package/sidebar/sidebar.cjs.min.js +1 -1
- package/sidebar/sidebar.esm.js +4 -4
- package/sidebar/sidebar.esm.min.js +1 -1
- package/sidebar/sidebar.js +4 -4
- package/sidebar/sidebar.min.js +1 -1
- package/skeleton/Skeleton.d.ts +5 -5
- package/slider/Slider.d.ts +9 -9
- package/speeddial/BaseSpeedDial.vue +12 -36
- package/speeddial/SpeedDial.d.ts +23 -16
- package/speeddial/SpeedDial.vue +6 -5
- package/speeddial/speeddial.cjs.js +45 -24
- package/speeddial/speeddial.cjs.min.js +1 -1
- package/speeddial/speeddial.esm.js +45 -24
- package/speeddial/speeddial.esm.min.js +1 -1
- package/speeddial/speeddial.js +45 -24
- package/speeddial/speeddial.min.js +1 -1
- package/splitbutton/SplitButton.d.ts +12 -10
- package/splitbutton/SplitButton.vue +22 -3
- package/splitbutton/splitbutton.cjs.js +17 -5
- package/splitbutton/splitbutton.cjs.min.js +1 -1
- package/splitbutton/splitbutton.esm.js +17 -5
- package/splitbutton/splitbutton.esm.min.js +1 -1
- package/splitbutton/splitbutton.js +17 -5
- package/splitbutton/splitbutton.min.js +1 -1
- package/splitter/Splitter.d.ts +18 -7
- package/splitter/Splitter.vue +8 -1
- package/splitter/splitter.cjs.js +9 -1
- package/splitter/splitter.cjs.min.js +1 -1
- package/splitter/splitter.esm.js +9 -1
- package/splitter/splitter.esm.min.js +1 -1
- package/splitter/splitter.js +9 -1
- package/splitter/splitter.min.js +1 -1
- package/splitterpanel/SplitterPanel.d.ts +5 -5
- package/splitterpanel/SplitterPanel.vue +1 -1
- package/splitterpanel/splitterpanel.cjs.js +1 -1
- package/splitterpanel/splitterpanel.cjs.min.js +1 -1
- package/splitterpanel/splitterpanel.esm.js +1 -1
- package/splitterpanel/splitterpanel.esm.min.js +1 -1
- package/splitterpanel/splitterpanel.js +1 -1
- package/splitterpanel/splitterpanel.min.js +1 -1
- package/steps/Steps.d.ts +10 -10
- package/styleclass/StyleClass.d.ts +4 -3
- package/tabmenu/TabMenu.d.ts +11 -11
- package/tabpanel/TabPanel.d.ts +12 -12
- package/tabview/TabView.d.ts +18 -18
- package/tag/Tag.d.ts +7 -7
- package/terminal/Terminal.d.ts +13 -13
- package/textarea/Textarea.d.ts +5 -5
- package/tieredmenu/TieredMenu.d.ts +22 -15
- package/tieredmenu/TieredMenu.vue +1 -1
- package/tieredmenu/tieredmenu.cjs.js +3 -3
- package/tieredmenu/tieredmenu.cjs.min.js +1 -1
- package/tieredmenu/tieredmenu.esm.js +3 -3
- package/tieredmenu/tieredmenu.esm.min.js +1 -1
- package/tieredmenu/tieredmenu.js +3 -3
- package/tieredmenu/tieredmenu.min.js +1 -1
- package/timeline/Timeline.d.ts +11 -11
- package/toast/BaseToast.vue +4 -0
- package/toast/Toast.d.ts +25 -19
- package/toast/Toast.vue +3 -2
- package/toast/toast.cjs.js +4 -2
- package/toast/toast.cjs.min.js +1 -1
- package/toast/toast.esm.js +5 -3
- package/toast/toast.esm.min.js +1 -1
- package/toast/toast.js +4 -2
- package/toast/toast.min.js +1 -1
- package/togglebutton/ToggleButton.d.ts +34 -11
- package/togglebutton/ToggleButton.vue +12 -3
- package/togglebutton/togglebutton.cjs.js +12 -3
- package/togglebutton/togglebutton.cjs.min.js +1 -1
- package/togglebutton/togglebutton.esm.js +12 -3
- package/togglebutton/togglebutton.esm.min.js +1 -1
- package/togglebutton/togglebutton.js +12 -3
- package/togglebutton/togglebutton.min.js +1 -1
- package/toolbar/Toolbar.d.ts +8 -8
- package/toolbar/Toolbar.vue +3 -3
- package/toolbar/toolbar.cjs.js +3 -6
- package/toolbar/toolbar.cjs.min.js +1 -1
- package/toolbar/toolbar.esm.js +3 -6
- package/toolbar/toolbar.esm.min.js +1 -1
- package/toolbar/toolbar.js +3 -6
- package/toolbar/toolbar.min.js +1 -1
- package/tooltip/Tooltip.d.ts +37 -7
- package/tooltip/tooltip.cjs.js +17 -4
- package/tooltip/tooltip.cjs.min.js +1 -1
- package/tooltip/tooltip.esm.js +17 -4
- package/tooltip/tooltip.esm.min.js +1 -1
- package/tooltip/tooltip.js +413 -400
- package/tooltip/tooltip.min.js +1 -1
- package/tree/Tree.d.ts +26 -22
- package/tree/Tree.vue +1 -0
- package/tree/tree.cjs.js +3 -2
- package/tree/tree.cjs.min.js +1 -1
- package/tree/tree.esm.js +3 -2
- package/tree/tree.esm.min.js +1 -1
- package/tree/tree.js +3 -2
- package/tree/tree.min.js +1 -1
- package/treeselect/TreeSelect.d.ts +26 -19
- package/treeselect/TreeSelect.vue +2 -2
- package/treeselect/treeselect.cjs.js +4 -4
- package/treeselect/treeselect.cjs.min.js +1 -1
- package/treeselect/treeselect.esm.js +4 -4
- package/treeselect/treeselect.esm.min.js +1 -1
- package/treeselect/treeselect.js +4 -4
- package/treeselect/treeselect.min.js +1 -1
- package/treetable/TreeTable.d.ts +24 -23
- package/treetable/TreeTable.vue +6 -3
- package/treetable/treetable.cjs.js +7 -6
- package/treetable/treetable.cjs.min.js +1 -1
- package/treetable/treetable.esm.js +7 -6
- package/treetable/treetable.esm.min.js +1 -1
- package/treetable/treetable.js +7 -6
- package/treetable/treetable.min.js +1 -1
- package/tristatecheckbox/TriStateCheckbox.d.ts +16 -13
- package/ts-helpers.d.ts +2 -0
- package/usestyle/UseStyle.d.ts +2 -1
- package/usestyle/usestyle.cjs.js +20 -7
- package/usestyle/usestyle.cjs.min.js +1 -1
- package/usestyle/usestyle.esm.js +20 -7
- package/usestyle/usestyle.esm.min.js +1 -1
- package/usestyle/usestyle.js +20 -7
- package/usestyle/usestyle.min.js +1 -1
- package/utils/Utils.d.ts +4 -0
- package/utils/utils.cjs.js +48 -8
- package/utils/utils.cjs.min.js +1 -1
- package/utils/utils.esm.js +48 -8
- package/utils/utils.esm.min.js +1 -1
- package/utils/utils.js +48 -8
- package/utils/utils.min.js +1 -1
- package/vetur-attributes.json +129 -125
- package/vetur-tags.json +1 -0
- package/virtualscroller/BaseVirtualScroller.vue +1 -1
- package/virtualscroller/VirtualScroller.d.ts +15 -13
- package/virtualscroller/virtualscroller.cjs.js +2 -1
- package/virtualscroller/virtualscroller.cjs.min.js +1 -1
- package/virtualscroller/virtualscroller.esm.js +2 -1
- package/virtualscroller/virtualscroller.esm.min.js +1 -1
- package/virtualscroller/virtualscroller.js +2 -1
- package/virtualscroller/virtualscroller.min.js +1 -1
- package/web-types.json +160 -127
- package/tailwind/Tailwind.d.ts +0 -5
- package/tailwind/package.json +0 -6
- package/tailwind/tailwind.cjs.min.js +0 -1
- package/tailwind/tailwind.esm.min.js +0 -1
- package/tailwind/tailwind.min.js +0 -1
package/dataview/DataView.d.ts
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
import { VNode } from 'vue';
|
|
11
11
|
import { ComponentHooks } from '../basecomponent';
|
|
12
12
|
import { PaginatorPassThroughOptionType } from '../paginator';
|
|
13
|
-
import { ClassComponent, GlobalComponentConstructor } from '../ts-helpers';
|
|
13
|
+
import { ClassComponent, GlobalComponentConstructor, PTOptions } from '../ts-helpers';
|
|
14
14
|
|
|
15
15
|
export declare type DataViewPassThroughOptionType = DataViewPassThroughAttributes | ((options: DataViewPassThroughMethodOptions) => DataViewPassThroughAttributes | string) | string | null | undefined;
|
|
16
16
|
|
|
@@ -51,40 +51,40 @@ export interface DataViewPageEvent {
|
|
|
51
51
|
*/
|
|
52
52
|
export interface DataViewPassThroughOptions {
|
|
53
53
|
/**
|
|
54
|
-
*
|
|
54
|
+
* Used to pass attributes to the root's DOM element.
|
|
55
55
|
*/
|
|
56
56
|
root?: DataViewPassThroughOptionType;
|
|
57
57
|
/**
|
|
58
|
-
*
|
|
58
|
+
* Used to pass attributes to the header's DOM element.
|
|
59
59
|
*/
|
|
60
60
|
header?: DataViewPassThroughOptionType;
|
|
61
61
|
/**
|
|
62
|
-
*
|
|
62
|
+
* Used to pass attributes to the Paginator component.
|
|
63
63
|
* @see {@link PaginatorPassThroughOptionType}
|
|
64
64
|
*/
|
|
65
65
|
paginator?: PaginatorPassThroughOptionType;
|
|
66
66
|
/**
|
|
67
|
-
*
|
|
67
|
+
* Used to pass attributes to the content's DOM element.
|
|
68
68
|
*/
|
|
69
69
|
content?: DataViewPassThroughOptionType;
|
|
70
70
|
/**
|
|
71
|
-
*
|
|
71
|
+
* Used to pass attributes to the grid's DOM element.
|
|
72
72
|
*/
|
|
73
73
|
grid?: DataViewPassThroughOptionType;
|
|
74
74
|
/**
|
|
75
|
-
*
|
|
75
|
+
* Used to pass attributes to the column's DOM element.
|
|
76
76
|
*/
|
|
77
77
|
column?: DataViewPassThroughOptionType;
|
|
78
78
|
/**
|
|
79
|
-
*
|
|
79
|
+
* Used to pass attributes to the empty message's DOM element.
|
|
80
80
|
*/
|
|
81
81
|
emptyMessage?: DataViewPassThroughOptionType;
|
|
82
82
|
/**
|
|
83
|
-
*
|
|
83
|
+
* Used to pass attributes to the footer's DOM element.
|
|
84
84
|
*/
|
|
85
85
|
footer?: DataViewPassThroughOptionType;
|
|
86
86
|
/**
|
|
87
|
-
*
|
|
87
|
+
* Used to manage all lifecycle hooks
|
|
88
88
|
* @see {@link BaseComponent.ComponentHooks}
|
|
89
89
|
*/
|
|
90
90
|
hooks?: ComponentHooks;
|
|
@@ -209,10 +209,10 @@ export interface DataViewProps {
|
|
|
209
209
|
*/
|
|
210
210
|
dataKey: string | undefined;
|
|
211
211
|
/**
|
|
212
|
-
*
|
|
212
|
+
* Used to pass attributes to DOM elements inside the component.
|
|
213
213
|
* @type {DataViewPassThroughOptions}
|
|
214
214
|
*/
|
|
215
|
-
pt?: DataViewPassThroughOptions
|
|
215
|
+
pt?: PTOptions<DataViewPassThroughOptions>;
|
|
216
216
|
/**
|
|
217
217
|
* When enabled, it removes component related styles in the core.
|
|
218
218
|
* @defaultValue false
|
package/dataview/DataView.vue
CHANGED
|
@@ -110,6 +110,7 @@ export default {
|
|
|
110
110
|
sort() {
|
|
111
111
|
if (this.value) {
|
|
112
112
|
const value = [...this.value];
|
|
113
|
+
const comparer = new Intl.Collator(undefined, { numeric: true }).compare;
|
|
113
114
|
|
|
114
115
|
value.sort((data1, data2) => {
|
|
115
116
|
let value1 = ObjectUtils.resolveFieldData(data1, this.sortField);
|
|
@@ -119,7 +120,7 @@ export default {
|
|
|
119
120
|
if (value1 == null && value2 != null) result = -1;
|
|
120
121
|
else if (value1 != null && value2 == null) result = 1;
|
|
121
122
|
else if (value1 == null && value2 == null) result = 0;
|
|
122
|
-
else if (typeof value1 === 'string' && typeof value2 === 'string') result = value1
|
|
123
|
+
else if (typeof value1 === 'string' && typeof value2 === 'string') result = comparer(value1, value2);
|
|
123
124
|
else result = value1 < value2 ? -1 : value1 > value2 ? 1 : 0;
|
|
124
125
|
|
|
125
126
|
return this.sortOrder * result;
|
package/dataview/dataview.cjs.js
CHANGED
|
@@ -153,13 +153,14 @@ var script = {
|
|
|
153
153
|
var _this = this;
|
|
154
154
|
if (this.value) {
|
|
155
155
|
var value = _toConsumableArray(this.value);
|
|
156
|
+
var comparer = new Intl.Collator(undefined, {
|
|
157
|
+
numeric: true
|
|
158
|
+
}).compare;
|
|
156
159
|
value.sort(function (data1, data2) {
|
|
157
160
|
var value1 = utils.ObjectUtils.resolveFieldData(data1, _this.sortField);
|
|
158
161
|
var value2 = utils.ObjectUtils.resolveFieldData(data2, _this.sortField);
|
|
159
162
|
var result = null;
|
|
160
|
-
if (value1 == null && value2 != null) result = -1;else if (value1 != null && value2 == null) result = 1;else if (value1 == null && value2 == null) result = 0;else if (typeof value1 === 'string' && typeof value2 === 'string') result = value1
|
|
161
|
-
numeric: true
|
|
162
|
-
});else result = value1 < value2 ? -1 : value1 > value2 ? 1 : 0;
|
|
163
|
+
if (value1 == null && value2 != null) result = -1;else if (value1 != null && value2 == null) result = 1;else if (value1 == null && value2 == null) result = 0;else if (typeof value1 === 'string' && typeof value2 === 'string') result = comparer(value1, value2);else result = value1 < value2 ? -1 : value1 > value2 ? 1 : 0;
|
|
163
164
|
return _this.sortOrder * result;
|
|
164
165
|
});
|
|
165
166
|
return value;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var t=require("primevue/paginator"),e=require("primevue/utils"),r=require("primevue/basecomponent"),o=require("vue");function a(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var n=a(t);function i(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function s(t,e){if(t){if("string"==typeof t)return u(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?u(t,e):void 0}}function l(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}function p(t){if(Array.isArray(t))return u(t)}function u(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,o=new Array(e);r<e;r++)o[r]=t[r];return o}var d={name:"DataView",extends:{name:"BaseDataView",extends:a(r).default,props:{value:{type:Array,default:null},layout:{type:String,default:"list"},rows:{type:Number,default:0},first:{type:Number,default:0},totalRecords:{type:Number,default:0},paginator:{type:Boolean,default:!1},paginatorPosition:{type:String,default:"bottom"},alwaysShowPaginator:{type:Boolean,default:!0},paginatorTemplate:{type:String,default:"FirstPageLink PrevPageLink PageLinks NextPageLink LastPageLink RowsPerPageDropdown"},pageLinkSize:{type:Number,default:5},rowsPerPageOptions:{type:Array,default:null},currentPageReportTemplate:{type:String,default:"({currentPage} of {totalPages})"},sortField:{type:[String,Function],default:null},sortOrder:{type:Number,default:null},lazy:{type:Boolean,default:!1},dataKey:{type:String,default:null}},css:{classes:{root:function(t){var e=t.props;return["p-dataview p-component",{"p-dataview-list":"list"===e.layout,"p-dataview-grid":"grid"===e.layout}]},header:"p-dataview-header",paginator:function(t){var e=t.instance;return e.paginatorTop?"p-paginator-top":e.paginatorBottom?"p-paginator-bottom":""},content:"p-dataview-content",grid:"p-grid p-nogutter grid grid-nogutter",column:"p-col col",emptyMessage:"p-dataview-emptymessage",footer:"p-dataview-footer"}},provide:function(){return{$parentInstance:this}}},emits:["update:first","update:rows","page"],data:function(){return{d_first:this.first,d_rows:this.rows}},watch:{first:function(t){this.d_first=t},rows:function(t){this.d_rows=t},sortField:function(){this.resetPage()},sortOrder:function(){this.resetPage()}},methods:{getKey:function(t,r){return this.dataKey?e.ObjectUtils.resolveFieldData(t,this.dataKey):r},onPage:function(t){this.d_first=t.first,this.d_rows=t.rows,this.$emit("update:first",this.d_first),this.$emit("update:rows",this.d_rows),this.$emit("page",t)},sort:function(){var t,r=this;if(this.value){var o=p(t=this.value)||l(t)||s(t)||i();return o.sort((function(t,o){var
|
|
1
|
+
"use strict";var t=require("primevue/paginator"),e=require("primevue/utils"),r=require("primevue/basecomponent"),o=require("vue");function a(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var n=a(t);function i(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function s(t,e){if(t){if("string"==typeof t)return u(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?u(t,e):void 0}}function l(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}function p(t){if(Array.isArray(t))return u(t)}function u(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,o=new Array(e);r<e;r++)o[r]=t[r];return o}var d={name:"DataView",extends:{name:"BaseDataView",extends:a(r).default,props:{value:{type:Array,default:null},layout:{type:String,default:"list"},rows:{type:Number,default:0},first:{type:Number,default:0},totalRecords:{type:Number,default:0},paginator:{type:Boolean,default:!1},paginatorPosition:{type:String,default:"bottom"},alwaysShowPaginator:{type:Boolean,default:!0},paginatorTemplate:{type:String,default:"FirstPageLink PrevPageLink PageLinks NextPageLink LastPageLink RowsPerPageDropdown"},pageLinkSize:{type:Number,default:5},rowsPerPageOptions:{type:Array,default:null},currentPageReportTemplate:{type:String,default:"({currentPage} of {totalPages})"},sortField:{type:[String,Function],default:null},sortOrder:{type:Number,default:null},lazy:{type:Boolean,default:!1},dataKey:{type:String,default:null}},css:{classes:{root:function(t){var e=t.props;return["p-dataview p-component",{"p-dataview-list":"list"===e.layout,"p-dataview-grid":"grid"===e.layout}]},header:"p-dataview-header",paginator:function(t){var e=t.instance;return e.paginatorTop?"p-paginator-top":e.paginatorBottom?"p-paginator-bottom":""},content:"p-dataview-content",grid:"p-grid p-nogutter grid grid-nogutter",column:"p-col col",emptyMessage:"p-dataview-emptymessage",footer:"p-dataview-footer"}},provide:function(){return{$parentInstance:this}}},emits:["update:first","update:rows","page"],data:function(){return{d_first:this.first,d_rows:this.rows}},watch:{first:function(t){this.d_first=t},rows:function(t){this.d_rows=t},sortField:function(){this.resetPage()},sortOrder:function(){this.resetPage()}},methods:{getKey:function(t,r){return this.dataKey?e.ObjectUtils.resolveFieldData(t,this.dataKey):r},onPage:function(t){this.d_first=t.first,this.d_rows=t.rows,this.$emit("update:first",this.d_first),this.$emit("update:rows",this.d_rows),this.$emit("page",t)},sort:function(){var t,r=this;if(this.value){var o=p(t=this.value)||l(t)||s(t)||i(),a=new Intl.Collator(void 0,{numeric:!0}).compare;return o.sort((function(t,o){var n=e.ObjectUtils.resolveFieldData(t,r.sortField),i=e.ObjectUtils.resolveFieldData(o,r.sortField),s=null;return s=null==n&&null!=i?-1:null!=n&&null==i?1:null==n&&null==i?0:"string"==typeof n&&"string"==typeof i?a(n,i):n<i?-1:n>i?1:0,r.sortOrder*s})),o}return null},resetPage:function(){this.d_first=0,this.$emit("update:first",this.d_first)}},computed:{getTotalRecords:function(){return this.totalRecords?this.totalRecords:this.value?this.value.length:0},empty:function(){return!this.value||0===this.value.length},paginatorTop:function(){return this.paginator&&("bottom"!==this.paginatorPosition||"both"===this.paginatorPosition)},paginatorBottom:function(){return this.paginator&&("top"!==this.paginatorPosition||"both"===this.paginatorPosition)},items:function(){if(this.value&&this.value.length){var t=this.value;if(t&&t.length&&this.sortField&&(t=this.sort()),this.paginator){var e=this.lazy?0:this.d_first;return t.slice(e,e+this.d_rows)}return t}return null}},components:{DVPaginator:n.default}};d.render=function(t,e,r,a,n,i){var s=o.resolveComponent("DVPaginator");return o.openBlock(),o.createElementBlock("div",o.mergeProps({class:t.cx("root")},t.ptm("root"),{"data-pc-name":"dataview"}),[t.$slots.header?(o.openBlock(),o.createElementBlock("div",o.mergeProps({key:0,class:t.cx("header")},t.ptm("header")),[o.renderSlot(t.$slots,"header")],16)):o.createCommentVNode("",!0),i.paginatorTop?(o.openBlock(),o.createBlock(s,{key:1,rows:n.d_rows,first:n.d_first,totalRecords:i.getTotalRecords,pageLinkSize:t.pageLinkSize,template:t.paginatorTemplate,rowsPerPageOptions:t.rowsPerPageOptions,currentPageReportTemplate:t.currentPageReportTemplate,class:o.normalizeClass(t.cx("paginator")),alwaysShow:t.alwaysShowPaginator,onPage:e[0]||(e[0]=function(t){return i.onPage(t)}),unstyled:t.unstyled,pt:t.ptm("paginator")},o.createSlots({_:2},[t.$slots.paginatorstart?{name:"start",fn:o.withCtx((function(){return[o.renderSlot(t.$slots,"paginatorstart")]})),key:"0"}:void 0,t.$slots.paginatorend?{name:"end",fn:o.withCtx((function(){return[o.renderSlot(t.$slots,"paginatorend")]})),key:"1"}:void 0]),1032,["rows","first","totalRecords","pageLinkSize","template","rowsPerPageOptions","currentPageReportTemplate","class","alwaysShow","unstyled","pt"])):o.createCommentVNode("",!0),o.createElementVNode("div",o.mergeProps({class:t.cx("content")},t.ptm("content")),[o.createElementVNode("div",o.mergeProps({class:t.cx("grid")},t.ptm("grid")),[(o.openBlock(!0),o.createElementBlock(o.Fragment,null,o.renderList(i.items,(function(e,r){return o.openBlock(),o.createElementBlock(o.Fragment,{key:i.getKey(e,r)},[t.$slots.list&&"list"===t.layout?o.renderSlot(t.$slots,"list",{key:0,data:e,index:r}):o.createCommentVNode("",!0),t.$slots.grid&&"grid"===t.layout?o.renderSlot(t.$slots,"grid",{key:1,data:e,index:r}):o.createCommentVNode("",!0)],64)})),128)),i.empty?(o.openBlock(),o.createElementBlock("div",o.mergeProps({key:0,class:t.cx("column")},t.ptm("column")),[o.createElementVNode("div",o.mergeProps({class:t.cx("emptyMessage")},t.ptm("emptyMessage")),[o.renderSlot(t.$slots,"empty")],16)],16)):o.createCommentVNode("",!0)],16)],16),i.paginatorBottom?(o.openBlock(),o.createBlock(s,{key:2,rows:n.d_rows,first:n.d_first,totalRecords:i.getTotalRecords,pageLinkSize:t.pageLinkSize,template:t.paginatorTemplate,rowsPerPageOptions:t.rowsPerPageOptions,currentPageReportTemplate:t.currentPageReportTemplate,class:o.normalizeClass(t.cx("paginator")),alwaysShow:t.alwaysShowPaginator,onPage:e[1]||(e[1]=function(t){return i.onPage(t)}),unstyled:t.unstyled,pt:t.ptm("paginator")},o.createSlots({_:2},[t.$slots.paginatorstart?{name:"start",fn:o.withCtx((function(){return[o.renderSlot(t.$slots,"paginatorstart")]})),key:"0"}:void 0,t.$slots.paginatorend?{name:"end",fn:o.withCtx((function(){return[o.renderSlot(t.$slots,"paginatorend")]})),key:"1"}:void 0]),1032,["rows","first","totalRecords","pageLinkSize","template","rowsPerPageOptions","currentPageReportTemplate","class","alwaysShow","unstyled","pt"])):o.createCommentVNode("",!0),t.$slots.footer?(o.openBlock(),o.createElementBlock("div",o.mergeProps({key:3,class:t.cx("footer")},t.ptm("footer")),[o.renderSlot(t.$slots,"footer")],16)):o.createCommentVNode("",!0)],16)},module.exports=d;
|
package/dataview/dataview.esm.js
CHANGED
|
@@ -146,13 +146,14 @@ var script = {
|
|
|
146
146
|
var _this = this;
|
|
147
147
|
if (this.value) {
|
|
148
148
|
var value = _toConsumableArray(this.value);
|
|
149
|
+
var comparer = new Intl.Collator(undefined, {
|
|
150
|
+
numeric: true
|
|
151
|
+
}).compare;
|
|
149
152
|
value.sort(function (data1, data2) {
|
|
150
153
|
var value1 = ObjectUtils.resolveFieldData(data1, _this.sortField);
|
|
151
154
|
var value2 = ObjectUtils.resolveFieldData(data2, _this.sortField);
|
|
152
155
|
var result = null;
|
|
153
|
-
if (value1 == null && value2 != null) result = -1;else if (value1 != null && value2 == null) result = 1;else if (value1 == null && value2 == null) result = 0;else if (typeof value1 === 'string' && typeof value2 === 'string') result = value1
|
|
154
|
-
numeric: true
|
|
155
|
-
});else result = value1 < value2 ? -1 : value1 > value2 ? 1 : 0;
|
|
156
|
+
if (value1 == null && value2 != null) result = -1;else if (value1 != null && value2 == null) result = 1;else if (value1 == null && value2 == null) result = 0;else if (typeof value1 === 'string' && typeof value2 === 'string') result = comparer(value1, value2);else result = value1 < value2 ? -1 : value1 > value2 ? 1 : 0;
|
|
156
157
|
return _this.sortOrder * result;
|
|
157
158
|
});
|
|
158
159
|
return value;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import t from"primevue/paginator";import{ObjectUtils as e}from"primevue/utils";import r from"primevue/basecomponent";import{resolveComponent as a,openBlock as o,createElementBlock as n,mergeProps as i,renderSlot as s,createCommentVNode as l,createBlock as p,normalizeClass as u,createSlots as d,withCtx as g,createElementVNode as c,Fragment as f,renderList as m}from"vue";function y(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function h(t,e){if(t){if("string"==typeof t)return P(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?P(t,e):void 0}}function w(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}function v(t){if(Array.isArray(t))return P(t)}function P(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,a=new Array(e);r<e;r++)a[r]=t[r];return a}var S={name:"DataView",extends:{name:"BaseDataView",extends:r,props:{value:{type:Array,default:null},layout:{type:String,default:"list"},rows:{type:Number,default:0},first:{type:Number,default:0},totalRecords:{type:Number,default:0},paginator:{type:Boolean,default:!1},paginatorPosition:{type:String,default:"bottom"},alwaysShowPaginator:{type:Boolean,default:!0},paginatorTemplate:{type:String,default:"FirstPageLink PrevPageLink PageLinks NextPageLink LastPageLink RowsPerPageDropdown"},pageLinkSize:{type:Number,default:5},rowsPerPageOptions:{type:Array,default:null},currentPageReportTemplate:{type:String,default:"({currentPage} of {totalPages})"},sortField:{type:[String,Function],default:null},sortOrder:{type:Number,default:null},lazy:{type:Boolean,default:!1},dataKey:{type:String,default:null}},css:{classes:{root:function(t){var e=t.props;return["p-dataview p-component",{"p-dataview-list":"list"===e.layout,"p-dataview-grid":"grid"===e.layout}]},header:"p-dataview-header",paginator:function(t){var e=t.instance;return e.paginatorTop?"p-paginator-top":e.paginatorBottom?"p-paginator-bottom":""},content:"p-dataview-content",grid:"p-grid p-nogutter grid grid-nogutter",column:"p-col col",emptyMessage:"p-dataview-emptymessage",footer:"p-dataview-footer"}},provide:function(){return{$parentInstance:this}}},emits:["update:first","update:rows","page"],data:function(){return{d_first:this.first,d_rows:this.rows}},watch:{first:function(t){this.d_first=t},rows:function(t){this.d_rows=t},sortField:function(){this.resetPage()},sortOrder:function(){this.resetPage()}},methods:{getKey:function(t,r){return this.dataKey?e.resolveFieldData(t,this.dataKey):r},onPage:function(t){this.d_first=t.first,this.d_rows=t.rows,this.$emit("update:first",this.d_first),this.$emit("update:rows",this.d_rows),this.$emit("page",t)},sort:function(){var t,r=this;if(this.value){var a=v(t=this.value)||w(t)||h(t)||y();return a.sort((function(t,a){var
|
|
1
|
+
import t from"primevue/paginator";import{ObjectUtils as e}from"primevue/utils";import r from"primevue/basecomponent";import{resolveComponent as a,openBlock as o,createElementBlock as n,mergeProps as i,renderSlot as s,createCommentVNode as l,createBlock as p,normalizeClass as u,createSlots as d,withCtx as g,createElementVNode as c,Fragment as f,renderList as m}from"vue";function y(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function h(t,e){if(t){if("string"==typeof t)return P(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?P(t,e):void 0}}function w(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}function v(t){if(Array.isArray(t))return P(t)}function P(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,a=new Array(e);r<e;r++)a[r]=t[r];return a}var S={name:"DataView",extends:{name:"BaseDataView",extends:r,props:{value:{type:Array,default:null},layout:{type:String,default:"list"},rows:{type:Number,default:0},first:{type:Number,default:0},totalRecords:{type:Number,default:0},paginator:{type:Boolean,default:!1},paginatorPosition:{type:String,default:"bottom"},alwaysShowPaginator:{type:Boolean,default:!0},paginatorTemplate:{type:String,default:"FirstPageLink PrevPageLink PageLinks NextPageLink LastPageLink RowsPerPageDropdown"},pageLinkSize:{type:Number,default:5},rowsPerPageOptions:{type:Array,default:null},currentPageReportTemplate:{type:String,default:"({currentPage} of {totalPages})"},sortField:{type:[String,Function],default:null},sortOrder:{type:Number,default:null},lazy:{type:Boolean,default:!1},dataKey:{type:String,default:null}},css:{classes:{root:function(t){var e=t.props;return["p-dataview p-component",{"p-dataview-list":"list"===e.layout,"p-dataview-grid":"grid"===e.layout}]},header:"p-dataview-header",paginator:function(t){var e=t.instance;return e.paginatorTop?"p-paginator-top":e.paginatorBottom?"p-paginator-bottom":""},content:"p-dataview-content",grid:"p-grid p-nogutter grid grid-nogutter",column:"p-col col",emptyMessage:"p-dataview-emptymessage",footer:"p-dataview-footer"}},provide:function(){return{$parentInstance:this}}},emits:["update:first","update:rows","page"],data:function(){return{d_first:this.first,d_rows:this.rows}},watch:{first:function(t){this.d_first=t},rows:function(t){this.d_rows=t},sortField:function(){this.resetPage()},sortOrder:function(){this.resetPage()}},methods:{getKey:function(t,r){return this.dataKey?e.resolveFieldData(t,this.dataKey):r},onPage:function(t){this.d_first=t.first,this.d_rows=t.rows,this.$emit("update:first",this.d_first),this.$emit("update:rows",this.d_rows),this.$emit("page",t)},sort:function(){var t,r=this;if(this.value){var a=v(t=this.value)||w(t)||h(t)||y(),o=new Intl.Collator(void 0,{numeric:!0}).compare;return a.sort((function(t,a){var n=e.resolveFieldData(t,r.sortField),i=e.resolveFieldData(a,r.sortField),s=null;return s=null==n&&null!=i?-1:null!=n&&null==i?1:null==n&&null==i?0:"string"==typeof n&&"string"==typeof i?o(n,i):n<i?-1:n>i?1:0,r.sortOrder*s})),a}return null},resetPage:function(){this.d_first=0,this.$emit("update:first",this.d_first)}},computed:{getTotalRecords:function(){return this.totalRecords?this.totalRecords:this.value?this.value.length:0},empty:function(){return!this.value||0===this.value.length},paginatorTop:function(){return this.paginator&&("bottom"!==this.paginatorPosition||"both"===this.paginatorPosition)},paginatorBottom:function(){return this.paginator&&("top"!==this.paginatorPosition||"both"===this.paginatorPosition)},items:function(){if(this.value&&this.value.length){var t=this.value;if(t&&t.length&&this.sortField&&(t=this.sort()),this.paginator){var e=this.lazy?0:this.d_first;return t.slice(e,e+this.d_rows)}return t}return null}},components:{DVPaginator:t}};S.render=function(t,e,r,y,h,w){var v=a("DVPaginator");return o(),n("div",i({class:t.cx("root")},t.ptm("root"),{"data-pc-name":"dataview"}),[t.$slots.header?(o(),n("div",i({key:0,class:t.cx("header")},t.ptm("header")),[s(t.$slots,"header")],16)):l("",!0),w.paginatorTop?(o(),p(v,{key:1,rows:h.d_rows,first:h.d_first,totalRecords:w.getTotalRecords,pageLinkSize:t.pageLinkSize,template:t.paginatorTemplate,rowsPerPageOptions:t.rowsPerPageOptions,currentPageReportTemplate:t.currentPageReportTemplate,class:u(t.cx("paginator")),alwaysShow:t.alwaysShowPaginator,onPage:e[0]||(e[0]=function(t){return w.onPage(t)}),unstyled:t.unstyled,pt:t.ptm("paginator")},d({_:2},[t.$slots.paginatorstart?{name:"start",fn:g((function(){return[s(t.$slots,"paginatorstart")]})),key:"0"}:void 0,t.$slots.paginatorend?{name:"end",fn:g((function(){return[s(t.$slots,"paginatorend")]})),key:"1"}:void 0]),1032,["rows","first","totalRecords","pageLinkSize","template","rowsPerPageOptions","currentPageReportTemplate","class","alwaysShow","unstyled","pt"])):l("",!0),c("div",i({class:t.cx("content")},t.ptm("content")),[c("div",i({class:t.cx("grid")},t.ptm("grid")),[(o(!0),n(f,null,m(w.items,(function(e,r){return o(),n(f,{key:w.getKey(e,r)},[t.$slots.list&&"list"===t.layout?s(t.$slots,"list",{key:0,data:e,index:r}):l("",!0),t.$slots.grid&&"grid"===t.layout?s(t.$slots,"grid",{key:1,data:e,index:r}):l("",!0)],64)})),128)),w.empty?(o(),n("div",i({key:0,class:t.cx("column")},t.ptm("column")),[c("div",i({class:t.cx("emptyMessage")},t.ptm("emptyMessage")),[s(t.$slots,"empty")],16)],16)):l("",!0)],16)],16),w.paginatorBottom?(o(),p(v,{key:2,rows:h.d_rows,first:h.d_first,totalRecords:w.getTotalRecords,pageLinkSize:t.pageLinkSize,template:t.paginatorTemplate,rowsPerPageOptions:t.rowsPerPageOptions,currentPageReportTemplate:t.currentPageReportTemplate,class:u(t.cx("paginator")),alwaysShow:t.alwaysShowPaginator,onPage:e[1]||(e[1]=function(t){return w.onPage(t)}),unstyled:t.unstyled,pt:t.ptm("paginator")},d({_:2},[t.$slots.paginatorstart?{name:"start",fn:g((function(){return[s(t.$slots,"paginatorstart")]})),key:"0"}:void 0,t.$slots.paginatorend?{name:"end",fn:g((function(){return[s(t.$slots,"paginatorend")]})),key:"1"}:void 0]),1032,["rows","first","totalRecords","pageLinkSize","template","rowsPerPageOptions","currentPageReportTemplate","class","alwaysShow","unstyled","pt"])):l("",!0),t.$slots.footer?(o(),n("div",i({key:3,class:t.cx("footer")},t.ptm("footer")),[s(t.$slots,"footer")],16)):l("",!0)],16)};export{S as default};
|
package/dataview/dataview.js
CHANGED
|
@@ -150,13 +150,14 @@ this.primevue.dataview = (function (Paginator, utils, BaseComponent, vue) {
|
|
|
150
150
|
var _this = this;
|
|
151
151
|
if (this.value) {
|
|
152
152
|
var value = _toConsumableArray(this.value);
|
|
153
|
+
var comparer = new Intl.Collator(undefined, {
|
|
154
|
+
numeric: true
|
|
155
|
+
}).compare;
|
|
153
156
|
value.sort(function (data1, data2) {
|
|
154
157
|
var value1 = utils.ObjectUtils.resolveFieldData(data1, _this.sortField);
|
|
155
158
|
var value2 = utils.ObjectUtils.resolveFieldData(data2, _this.sortField);
|
|
156
159
|
var result = null;
|
|
157
|
-
if (value1 == null && value2 != null) result = -1;else if (value1 != null && value2 == null) result = 1;else if (value1 == null && value2 == null) result = 0;else if (typeof value1 === 'string' && typeof value2 === 'string') result = value1
|
|
158
|
-
numeric: true
|
|
159
|
-
});else result = value1 < value2 ? -1 : value1 > value2 ? 1 : 0;
|
|
160
|
+
if (value1 == null && value2 != null) result = -1;else if (value1 != null && value2 == null) result = 1;else if (value1 == null && value2 == null) result = 0;else if (typeof value1 === 'string' && typeof value2 === 'string') result = comparer(value1, value2);else result = value1 < value2 ? -1 : value1 > value2 ? 1 : 0;
|
|
160
161
|
return _this.sortOrder * result;
|
|
161
162
|
});
|
|
162
163
|
return value;
|
package/dataview/dataview.min.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
this.primevue=this.primevue||{},this.primevue.dataview=function(t,e,r,o){"use strict";function a(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var n=a(t);function i(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function s(t,e){if(t){if("string"==typeof t)return u(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?u(t,e):void 0}}function l(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}function p(t){if(Array.isArray(t))return u(t)}function u(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,o=new Array(e);r<e;r++)o[r]=t[r];return o}var d={name:"DataView",extends:{name:"BaseDataView",extends:a(r).default,props:{value:{type:Array,default:null},layout:{type:String,default:"list"},rows:{type:Number,default:0},first:{type:Number,default:0},totalRecords:{type:Number,default:0},paginator:{type:Boolean,default:!1},paginatorPosition:{type:String,default:"bottom"},alwaysShowPaginator:{type:Boolean,default:!0},paginatorTemplate:{type:String,default:"FirstPageLink PrevPageLink PageLinks NextPageLink LastPageLink RowsPerPageDropdown"},pageLinkSize:{type:Number,default:5},rowsPerPageOptions:{type:Array,default:null},currentPageReportTemplate:{type:String,default:"({currentPage} of {totalPages})"},sortField:{type:[String,Function],default:null},sortOrder:{type:Number,default:null},lazy:{type:Boolean,default:!1},dataKey:{type:String,default:null}},css:{classes:{root:function(t){var e=t.props;return["p-dataview p-component",{"p-dataview-list":"list"===e.layout,"p-dataview-grid":"grid"===e.layout}]},header:"p-dataview-header",paginator:function(t){var e=t.instance;return e.paginatorTop?"p-paginator-top":e.paginatorBottom?"p-paginator-bottom":""},content:"p-dataview-content",grid:"p-grid p-nogutter grid grid-nogutter",column:"p-col col",emptyMessage:"p-dataview-emptymessage",footer:"p-dataview-footer"}},provide:function(){return{$parentInstance:this}}},emits:["update:first","update:rows","page"],data:function(){return{d_first:this.first,d_rows:this.rows}},watch:{first:function(t){this.d_first=t},rows:function(t){this.d_rows=t},sortField:function(){this.resetPage()},sortOrder:function(){this.resetPage()}},methods:{getKey:function(t,r){return this.dataKey?e.ObjectUtils.resolveFieldData(t,this.dataKey):r},onPage:function(t){this.d_first=t.first,this.d_rows=t.rows,this.$emit("update:first",this.d_first),this.$emit("update:rows",this.d_rows),this.$emit("page",t)},sort:function(){var t,r=this;if(this.value){var o=p(t=this.value)||l(t)||s(t)||i();return o.sort((function(t,o){var
|
|
1
|
+
this.primevue=this.primevue||{},this.primevue.dataview=function(t,e,r,o){"use strict";function a(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var n=a(t);function i(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function s(t,e){if(t){if("string"==typeof t)return u(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?u(t,e):void 0}}function l(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}function p(t){if(Array.isArray(t))return u(t)}function u(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,o=new Array(e);r<e;r++)o[r]=t[r];return o}var d={name:"DataView",extends:{name:"BaseDataView",extends:a(r).default,props:{value:{type:Array,default:null},layout:{type:String,default:"list"},rows:{type:Number,default:0},first:{type:Number,default:0},totalRecords:{type:Number,default:0},paginator:{type:Boolean,default:!1},paginatorPosition:{type:String,default:"bottom"},alwaysShowPaginator:{type:Boolean,default:!0},paginatorTemplate:{type:String,default:"FirstPageLink PrevPageLink PageLinks NextPageLink LastPageLink RowsPerPageDropdown"},pageLinkSize:{type:Number,default:5},rowsPerPageOptions:{type:Array,default:null},currentPageReportTemplate:{type:String,default:"({currentPage} of {totalPages})"},sortField:{type:[String,Function],default:null},sortOrder:{type:Number,default:null},lazy:{type:Boolean,default:!1},dataKey:{type:String,default:null}},css:{classes:{root:function(t){var e=t.props;return["p-dataview p-component",{"p-dataview-list":"list"===e.layout,"p-dataview-grid":"grid"===e.layout}]},header:"p-dataview-header",paginator:function(t){var e=t.instance;return e.paginatorTop?"p-paginator-top":e.paginatorBottom?"p-paginator-bottom":""},content:"p-dataview-content",grid:"p-grid p-nogutter grid grid-nogutter",column:"p-col col",emptyMessage:"p-dataview-emptymessage",footer:"p-dataview-footer"}},provide:function(){return{$parentInstance:this}}},emits:["update:first","update:rows","page"],data:function(){return{d_first:this.first,d_rows:this.rows}},watch:{first:function(t){this.d_first=t},rows:function(t){this.d_rows=t},sortField:function(){this.resetPage()},sortOrder:function(){this.resetPage()}},methods:{getKey:function(t,r){return this.dataKey?e.ObjectUtils.resolveFieldData(t,this.dataKey):r},onPage:function(t){this.d_first=t.first,this.d_rows=t.rows,this.$emit("update:first",this.d_first),this.$emit("update:rows",this.d_rows),this.$emit("page",t)},sort:function(){var t,r=this;if(this.value){var o=p(t=this.value)||l(t)||s(t)||i(),a=new Intl.Collator(void 0,{numeric:!0}).compare;return o.sort((function(t,o){var n=e.ObjectUtils.resolveFieldData(t,r.sortField),i=e.ObjectUtils.resolveFieldData(o,r.sortField),s=null;return s=null==n&&null!=i?-1:null!=n&&null==i?1:null==n&&null==i?0:"string"==typeof n&&"string"==typeof i?a(n,i):n<i?-1:n>i?1:0,r.sortOrder*s})),o}return null},resetPage:function(){this.d_first=0,this.$emit("update:first",this.d_first)}},computed:{getTotalRecords:function(){return this.totalRecords?this.totalRecords:this.value?this.value.length:0},empty:function(){return!this.value||0===this.value.length},paginatorTop:function(){return this.paginator&&("bottom"!==this.paginatorPosition||"both"===this.paginatorPosition)},paginatorBottom:function(){return this.paginator&&("top"!==this.paginatorPosition||"both"===this.paginatorPosition)},items:function(){if(this.value&&this.value.length){var t=this.value;if(t&&t.length&&this.sortField&&(t=this.sort()),this.paginator){var e=this.lazy?0:this.d_first;return t.slice(e,e+this.d_rows)}return t}return null}},components:{DVPaginator:n.default}};return d.render=function(t,e,r,a,n,i){var s=o.resolveComponent("DVPaginator");return o.openBlock(),o.createElementBlock("div",o.mergeProps({class:t.cx("root")},t.ptm("root"),{"data-pc-name":"dataview"}),[t.$slots.header?(o.openBlock(),o.createElementBlock("div",o.mergeProps({key:0,class:t.cx("header")},t.ptm("header")),[o.renderSlot(t.$slots,"header")],16)):o.createCommentVNode("",!0),i.paginatorTop?(o.openBlock(),o.createBlock(s,{key:1,rows:n.d_rows,first:n.d_first,totalRecords:i.getTotalRecords,pageLinkSize:t.pageLinkSize,template:t.paginatorTemplate,rowsPerPageOptions:t.rowsPerPageOptions,currentPageReportTemplate:t.currentPageReportTemplate,class:o.normalizeClass(t.cx("paginator")),alwaysShow:t.alwaysShowPaginator,onPage:e[0]||(e[0]=function(t){return i.onPage(t)}),unstyled:t.unstyled,pt:t.ptm("paginator")},o.createSlots({_:2},[t.$slots.paginatorstart?{name:"start",fn:o.withCtx((function(){return[o.renderSlot(t.$slots,"paginatorstart")]})),key:"0"}:void 0,t.$slots.paginatorend?{name:"end",fn:o.withCtx((function(){return[o.renderSlot(t.$slots,"paginatorend")]})),key:"1"}:void 0]),1032,["rows","first","totalRecords","pageLinkSize","template","rowsPerPageOptions","currentPageReportTemplate","class","alwaysShow","unstyled","pt"])):o.createCommentVNode("",!0),o.createElementVNode("div",o.mergeProps({class:t.cx("content")},t.ptm("content")),[o.createElementVNode("div",o.mergeProps({class:t.cx("grid")},t.ptm("grid")),[(o.openBlock(!0),o.createElementBlock(o.Fragment,null,o.renderList(i.items,(function(e,r){return o.openBlock(),o.createElementBlock(o.Fragment,{key:i.getKey(e,r)},[t.$slots.list&&"list"===t.layout?o.renderSlot(t.$slots,"list",{key:0,data:e,index:r}):o.createCommentVNode("",!0),t.$slots.grid&&"grid"===t.layout?o.renderSlot(t.$slots,"grid",{key:1,data:e,index:r}):o.createCommentVNode("",!0)],64)})),128)),i.empty?(o.openBlock(),o.createElementBlock("div",o.mergeProps({key:0,class:t.cx("column")},t.ptm("column")),[o.createElementVNode("div",o.mergeProps({class:t.cx("emptyMessage")},t.ptm("emptyMessage")),[o.renderSlot(t.$slots,"empty")],16)],16)):o.createCommentVNode("",!0)],16)],16),i.paginatorBottom?(o.openBlock(),o.createBlock(s,{key:2,rows:n.d_rows,first:n.d_first,totalRecords:i.getTotalRecords,pageLinkSize:t.pageLinkSize,template:t.paginatorTemplate,rowsPerPageOptions:t.rowsPerPageOptions,currentPageReportTemplate:t.currentPageReportTemplate,class:o.normalizeClass(t.cx("paginator")),alwaysShow:t.alwaysShowPaginator,onPage:e[1]||(e[1]=function(t){return i.onPage(t)}),unstyled:t.unstyled,pt:t.ptm("paginator")},o.createSlots({_:2},[t.$slots.paginatorstart?{name:"start",fn:o.withCtx((function(){return[o.renderSlot(t.$slots,"paginatorstart")]})),key:"0"}:void 0,t.$slots.paginatorend?{name:"end",fn:o.withCtx((function(){return[o.renderSlot(t.$slots,"paginatorend")]})),key:"1"}:void 0]),1032,["rows","first","totalRecords","pageLinkSize","template","rowsPerPageOptions","currentPageReportTemplate","class","alwaysShow","unstyled","pt"])):o.createCommentVNode("",!0),t.$slots.footer?(o.openBlock(),o.createElementBlock("div",o.mergeProps({key:3,class:t.cx("footer")},t.ptm("footer")),[o.renderSlot(t.$slots,"footer")],16)):o.createCommentVNode("",!0)],16)},d}(primevue.paginator,primevue.utils,primevue.basecomponent,Vue);
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
*/
|
|
10
10
|
import { VNode } from 'vue';
|
|
11
11
|
import { ComponentHooks } from '../basecomponent';
|
|
12
|
-
import { ClassComponent, GlobalComponentConstructor } from '../ts-helpers';
|
|
12
|
+
import { ClassComponent, GlobalComponentConstructor, PTOptions } from '../ts-helpers';
|
|
13
13
|
|
|
14
14
|
export declare type DataViewLayoutOptionsPassThroughOptionType =
|
|
15
15
|
| DataViewLayoutOptionsPassThroughAttributes
|
|
@@ -33,27 +33,27 @@ export interface DataViewLayoutOptionsPassThroughMethodOptions {
|
|
|
33
33
|
*/
|
|
34
34
|
export interface DataViewLayoutOptionsPassThroughOptions {
|
|
35
35
|
/**
|
|
36
|
-
*
|
|
36
|
+
* Used to pass attributes to the root's DOM element.
|
|
37
37
|
*/
|
|
38
38
|
root?: DataViewLayoutOptionsPassThroughOptionType;
|
|
39
39
|
/**
|
|
40
|
-
*
|
|
40
|
+
* Used to pass attributes to the list button's DOM element.
|
|
41
41
|
*/
|
|
42
42
|
listButton?: DataViewLayoutOptionsPassThroughOptionType;
|
|
43
43
|
/**
|
|
44
|
-
*
|
|
44
|
+
* Used to pass attributes to the list icon's DOM element.
|
|
45
45
|
*/
|
|
46
46
|
listIcon?: DataViewLayoutOptionsPassThroughOptionType;
|
|
47
47
|
/**
|
|
48
|
-
*
|
|
48
|
+
* Used to pass attributes to the grid button's DOM element.
|
|
49
49
|
*/
|
|
50
50
|
gridButton?: DataViewLayoutOptionsPassThroughOptionType;
|
|
51
51
|
/**
|
|
52
|
-
*
|
|
52
|
+
* Used to pass attributes to the grid icon's DOM element.
|
|
53
53
|
*/
|
|
54
54
|
gridIcon?: DataViewLayoutOptionsPassThroughOptionType;
|
|
55
55
|
/**
|
|
56
|
-
*
|
|
56
|
+
* Used to manage all lifecycle hooks
|
|
57
57
|
* @see {@link BaseComponent.ComponentHooks}
|
|
58
58
|
*/
|
|
59
59
|
hooks?: ComponentHooks;
|
|
@@ -91,10 +91,10 @@ export interface DataViewLayoutOptionsProps {
|
|
|
91
91
|
*/
|
|
92
92
|
modelValue?: string | undefined;
|
|
93
93
|
/**
|
|
94
|
-
*
|
|
94
|
+
* Used to pass attributes to DOM elements inside the component.
|
|
95
95
|
* @type {DataViewLayoutOptionsPassThroughOptions}
|
|
96
96
|
*/
|
|
97
|
-
pt?: DataViewLayoutOptionsPassThroughOptions
|
|
97
|
+
pt?: PTOptions<DataViewLayoutOptionsPassThroughOptions>;
|
|
98
98
|
/**
|
|
99
99
|
* When enabled, it removes component related styles in the core.
|
|
100
100
|
* @defaultValue false
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
*/
|
|
10
10
|
import { VNode } from 'vue';
|
|
11
11
|
import { ComponentHooks } from '../basecomponent';
|
|
12
|
-
import { ClassComponent, GlobalComponentConstructor } from '../ts-helpers';
|
|
12
|
+
import { ClassComponent, GlobalComponentConstructor, PTOptions } from '../ts-helpers';
|
|
13
13
|
|
|
14
14
|
export declare type DeferredContentPassThroughOptionType = DeferredContentPassThroughAttributes | ((options: DeferredContentPassThroughMethodOptions) => DeferredContentPassThroughAttributes | string) | string | null | undefined;
|
|
15
15
|
|
|
@@ -28,11 +28,11 @@ export interface DeferredContentPassThroughMethodOptions {
|
|
|
28
28
|
*/
|
|
29
29
|
export interface DeferredContentPassThroughOptions {
|
|
30
30
|
/**
|
|
31
|
-
*
|
|
31
|
+
* Used to pass attributes to the root's DOM element.
|
|
32
32
|
*/
|
|
33
33
|
root?: DeferredContentPassThroughOptionType;
|
|
34
34
|
/**
|
|
35
|
-
*
|
|
35
|
+
* Used to manage all lifecycle hooks
|
|
36
36
|
* @see {@link BaseComponent.ComponentHooks}
|
|
37
37
|
*/
|
|
38
38
|
hooks?: ComponentHooks;
|
|
@@ -61,10 +61,10 @@ export interface DeferredContentState {
|
|
|
61
61
|
*/
|
|
62
62
|
export interface DeferredContentProps {
|
|
63
63
|
/**
|
|
64
|
-
*
|
|
64
|
+
* Used to pass attributes to DOM elements inside the component.
|
|
65
65
|
* @type {DeferredContentPassThroughOptions}
|
|
66
66
|
*/
|
|
67
|
-
pt?: DeferredContentPassThroughOptions
|
|
67
|
+
pt?: PTOptions<DeferredContentPassThroughOptions>;
|
|
68
68
|
/**
|
|
69
69
|
* When enabled, it removes component related styles in the core.
|
|
70
70
|
* @defaultValue false
|
package/dialog/BaseDialog.vue
CHANGED
|
@@ -3,16 +3,11 @@ import BaseComponent from 'primevue/basecomponent';
|
|
|
3
3
|
import { useStyle } from 'primevue/usestyle';
|
|
4
4
|
|
|
5
5
|
const styles = `
|
|
6
|
-
.p-dialog-mask {
|
|
7
|
-
pointer-events: none;
|
|
8
|
-
}
|
|
9
|
-
|
|
10
6
|
.p-dialog-mask.p-component-overlay {
|
|
11
7
|
pointer-events: auto;
|
|
12
8
|
}
|
|
13
9
|
|
|
14
10
|
.p-dialog {
|
|
15
|
-
pointer-events: auto;
|
|
16
11
|
max-height: 90%;
|
|
17
12
|
transform: scale(1);
|
|
18
13
|
}
|
|
@@ -152,11 +147,12 @@ const inlineStyles = {
|
|
|
152
147
|
display: 'flex',
|
|
153
148
|
justifyContent: position === 'left' || position === 'topleft' || position === 'bottomleft' ? 'flex-start' : position === 'right' || position === 'topright' || position === 'bottomright' ? 'flex-end' : 'center',
|
|
154
149
|
alignItems: position === 'top' || position === 'topleft' || position === 'topright' ? 'flex-start' : position === 'bottom' || position === 'bottomleft' || position === 'bottomright' ? 'flex-end' : 'center',
|
|
155
|
-
pointerEvents:
|
|
150
|
+
pointerEvents: modal ? 'auto' : 'none'
|
|
156
151
|
}),
|
|
157
152
|
root: {
|
|
158
153
|
display: 'flex',
|
|
159
|
-
flexDirection: 'column'
|
|
154
|
+
flexDirection: 'column',
|
|
155
|
+
pointerEvents: 'auto'
|
|
160
156
|
}
|
|
161
157
|
};
|
|
162
158
|
|
package/dialog/Dialog.d.ts
CHANGED
|
@@ -7,12 +7,14 @@
|
|
|
7
7
|
* @module dialog
|
|
8
8
|
*
|
|
9
9
|
*/
|
|
10
|
-
import { HTMLAttributes, VNode } from 'vue';
|
|
10
|
+
import { HTMLAttributes, TransitionProps, VNode } from 'vue';
|
|
11
11
|
import { ComponentHooks } from '../basecomponent';
|
|
12
|
-
import { ClassComponent, GlobalComponentConstructor } from '../ts-helpers';
|
|
12
|
+
import { ClassComponent, GlobalComponentConstructor, PTOptions } from '../ts-helpers';
|
|
13
13
|
|
|
14
14
|
export declare type DialogPassThroughOptionType = DialogPassThroughAttributes | ((options: DialogPassThroughMethodOptions) => DialogPassThroughAttributes | string) | string | null | undefined;
|
|
15
15
|
|
|
16
|
+
export declare type DialogPassThroughTransitionType = TransitionProps | ((options: DialogPassThroughMethodOptions) => TransitionProps) | undefined;
|
|
17
|
+
|
|
16
18
|
/**
|
|
17
19
|
* Custom passthrough(pt) option method.
|
|
18
20
|
*/
|
|
@@ -28,54 +30,58 @@ export interface DialogPassThroughMethodOptions {
|
|
|
28
30
|
*/
|
|
29
31
|
export interface DialogPassThroughOptions {
|
|
30
32
|
/**
|
|
31
|
-
*
|
|
33
|
+
* Used to pass attributes to the root's DOM element.
|
|
32
34
|
*/
|
|
33
35
|
root?: DialogPassThroughOptionType;
|
|
34
36
|
/**
|
|
35
|
-
*
|
|
37
|
+
* Used to pass attributes to the header's DOM element.
|
|
36
38
|
*/
|
|
37
39
|
header?: DialogPassThroughOptionType;
|
|
38
40
|
/**
|
|
39
|
-
*
|
|
41
|
+
* Used to pass attributes to the header title's DOM element.
|
|
40
42
|
*/
|
|
41
43
|
headerTitle?: DialogPassThroughOptionType;
|
|
42
44
|
/**
|
|
43
|
-
*
|
|
45
|
+
* Used to pass attributes to the header icons' DOM element.
|
|
44
46
|
*/
|
|
45
47
|
headerIcons?: DialogPassThroughOptionType;
|
|
46
48
|
/**
|
|
47
|
-
*
|
|
49
|
+
* Used to pass attributes to the maximizable button's DOM element.
|
|
48
50
|
*/
|
|
49
51
|
maximizableButton?: DialogPassThroughOptionType;
|
|
50
52
|
/**
|
|
51
|
-
*
|
|
53
|
+
* Used to pass attributes to the maximizable icon's DOM element.
|
|
52
54
|
*/
|
|
53
55
|
maximizableIcon?: DialogPassThroughOptionType;
|
|
54
56
|
/**
|
|
55
|
-
*
|
|
57
|
+
* Used to pass attributes to the close button's component.
|
|
56
58
|
*/
|
|
57
59
|
closeButton?: DialogPassThroughOptionType;
|
|
58
60
|
/**
|
|
59
|
-
*
|
|
61
|
+
* Used to pass attributes to the close button icon's component.
|
|
60
62
|
*/
|
|
61
63
|
closeButtonIcon?: DialogPassThroughOptionType;
|
|
62
64
|
/**
|
|
63
|
-
*
|
|
65
|
+
* Used to pass attributes to the content's DOM element.
|
|
64
66
|
*/
|
|
65
67
|
content?: DialogPassThroughOptionType;
|
|
66
68
|
/**
|
|
67
|
-
*
|
|
69
|
+
* Used to pass attributes to the footer's DOM element.
|
|
68
70
|
*/
|
|
69
71
|
footer?: DialogPassThroughOptionType;
|
|
70
72
|
/**
|
|
71
|
-
*
|
|
73
|
+
* Used to pass attributes to the mask's DOM element.
|
|
72
74
|
*/
|
|
73
75
|
mask?: DialogPassThroughOptionType;
|
|
74
76
|
/**
|
|
75
|
-
*
|
|
77
|
+
* Used to manage all lifecycle hooks
|
|
76
78
|
* @see {@link BaseComponent.ComponentHooks}
|
|
77
79
|
*/
|
|
78
80
|
hooks?: ComponentHooks;
|
|
81
|
+
/**
|
|
82
|
+
* Used to control Vue Transition API.
|
|
83
|
+
*/
|
|
84
|
+
transition?: DialogPassThroughTransitionType;
|
|
79
85
|
}
|
|
80
86
|
|
|
81
87
|
/**
|
|
@@ -154,7 +160,7 @@ export interface DialogProps {
|
|
|
154
160
|
*/
|
|
155
161
|
contentClass?: any;
|
|
156
162
|
/**
|
|
157
|
-
*
|
|
163
|
+
* Used to pass all properties of the HTMLDivElement to the overlay panel inside the component.
|
|
158
164
|
*/
|
|
159
165
|
contentProps?: HTMLAttributes | undefined;
|
|
160
166
|
/**
|
|
@@ -251,10 +257,10 @@ export interface DialogProps {
|
|
|
251
257
|
*/
|
|
252
258
|
minimizeIcon?: string | undefined;
|
|
253
259
|
/**
|
|
254
|
-
*
|
|
260
|
+
* Used to pass attributes to DOM elements inside the component.
|
|
255
261
|
* @type {DialogPassThroughOptions}
|
|
256
262
|
*/
|
|
257
|
-
pt?: DialogPassThroughOptions
|
|
263
|
+
pt?: PTOptions<DialogPassThroughOptions>;
|
|
258
264
|
/**
|
|
259
265
|
* When enabled, it removes component related styles in the core.
|
|
260
266
|
* @defaultValue false
|
package/dialog/Dialog.vue
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<Portal :appendTo="appendTo">
|
|
3
3
|
<div v-if="containerVisible" :ref="maskRef" :class="cx('mask')" :style="sx('mask', true, { position, modal })" @click="onMaskClick" v-bind="ptm('mask')">
|
|
4
|
-
<transition name="p-dialog" @before-enter="onBeforeEnter" @enter="onEnter" @before-leave="onBeforeLeave" @leave="onLeave" @after-leave="onAfterLeave" appear>
|
|
4
|
+
<transition name="p-dialog" @before-enter="onBeforeEnter" @enter="onEnter" @before-leave="onBeforeLeave" @leave="onLeave" @after-leave="onAfterLeave" appear v-bind="ptm('transition')">
|
|
5
5
|
<div v-if="visible" :ref="containerRef" v-focustrap="{ disabled: !modal }" :class="cx('root')" :style="sx('root')" role="dialog" :aria-labelledby="ariaLabelledById" :aria-modal="modal" v-bind="{ ...$attrs, ...ptm('root') }">
|
|
6
6
|
<div v-if="showHeader" :ref="headerContainerRef" :class="cx('header')" @mousedown="initDrag" v-bind="ptm('header')">
|
|
7
7
|
<slot name="header">
|
|
@@ -163,7 +163,7 @@ export default {
|
|
|
163
163
|
},
|
|
164
164
|
focus() {
|
|
165
165
|
const findFocusableElement = (container) => {
|
|
166
|
-
return container.querySelector('[autofocus]');
|
|
166
|
+
return container && container.querySelector('[autofocus]');
|
|
167
167
|
};
|
|
168
168
|
|
|
169
169
|
let focusTarget = this.$slots.footer && findFocusableElement(this.footerContainer);
|
|
@@ -259,6 +259,7 @@ export default {
|
|
|
259
259
|
if (!this.styleElement && !this.isUnstyled) {
|
|
260
260
|
this.styleElement = document.createElement('style');
|
|
261
261
|
this.styleElement.type = 'text/css';
|
|
262
|
+
DomHandler.setAttribute(this.styleElement, 'nonce', this.$primevue?.config?.csp?.nonce);
|
|
262
263
|
document.head.appendChild(this.styleElement);
|
|
263
264
|
|
|
264
265
|
let innerHTML = '';
|
|
@@ -322,24 +323,27 @@ export default {
|
|
|
322
323
|
let leftPos = offset.left + deltaX;
|
|
323
324
|
let topPos = offset.top + deltaY;
|
|
324
325
|
let viewport = DomHandler.getViewport();
|
|
326
|
+
let getComputedStyle = getComputedStyle(this.container);
|
|
327
|
+
let marginLeft = parseFloat(getComputedStyle.marginLeft);
|
|
328
|
+
let marginTop = parseFloat(getComputedStyle.marginTop);
|
|
325
329
|
|
|
326
330
|
this.container.style.position = 'fixed';
|
|
327
331
|
|
|
328
332
|
if (this.keepInViewport) {
|
|
329
333
|
if (leftPos >= this.minX && leftPos + width < viewport.width) {
|
|
330
334
|
this.lastPageX = event.pageX;
|
|
331
|
-
this.container.style.left = leftPos + 'px';
|
|
335
|
+
this.container.style.left = leftPos - marginLeft + 'px';
|
|
332
336
|
}
|
|
333
337
|
|
|
334
338
|
if (topPos >= this.minY && topPos + height < viewport.height) {
|
|
335
339
|
this.lastPageY = event.pageY;
|
|
336
|
-
this.container.style.top = topPos + 'px';
|
|
340
|
+
this.container.style.top = topPos - marginTop + 'px';
|
|
337
341
|
}
|
|
338
342
|
} else {
|
|
339
343
|
this.lastPageX = event.pageX;
|
|
340
|
-
this.container.style.left = leftPos + 'px';
|
|
344
|
+
this.container.style.left = leftPos - marginLeft + 'px';
|
|
341
345
|
this.lastPageY = event.pageY;
|
|
342
|
-
this.container.style.top = topPos + 'px';
|
|
346
|
+
this.container.style.top = topPos - marginTop + 'px';
|
|
343
347
|
}
|
|
344
348
|
}
|
|
345
349
|
};
|