primevue 3.32.2 → 3.34.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/accordion/Accordion.d.ts +21 -2
- package/accordion/accordion.cjs.js +3 -3
- package/accordion/accordion.esm.js +3 -3
- package/accordion/accordion.js +3 -3
- package/accordiontab/AccordionTab.d.ts +24 -2
- package/autocomplete/AutoComplete.d.ts +24 -2
- package/autocomplete/AutoComplete.vue +1 -1
- package/autocomplete/autocomplete.cjs.js +5 -5
- package/autocomplete/autocomplete.cjs.min.js +1 -1
- package/autocomplete/autocomplete.esm.js +5 -5
- package/autocomplete/autocomplete.esm.min.js +1 -1
- package/autocomplete/autocomplete.js +5 -5
- package/autocomplete/autocomplete.min.js +1 -1
- package/avatar/Avatar.d.ts +21 -2
- package/avatargroup/AvatarGroup.d.ts +8 -2
- package/badge/Badge.d.ts +18 -2
- package/badgedirective/BadgeDirective.d.ts +12 -2
- package/badgedirective/badgedirective.cjs.js +3 -3
- package/badgedirective/badgedirective.esm.js +3 -3
- package/badgedirective/badgedirective.js +3 -3
- package/basecomponent/BaseComponent.vue +20 -22
- package/basecomponent/basecomponent.cjs.js +41 -28
- package/basecomponent/basecomponent.cjs.min.js +1 -1
- package/basecomponent/basecomponent.esm.js +41 -28
- package/basecomponent/basecomponent.esm.min.js +1 -1
- package/basecomponent/basecomponent.js +41 -28
- package/basecomponent/basecomponent.min.js +1 -1
- package/basedirective/basedirective.cjs.js +42 -25
- package/basedirective/basedirective.cjs.min.js +1 -1
- package/basedirective/basedirective.esm.js +42 -25
- package/basedirective/basedirective.esm.min.js +1 -1
- package/basedirective/basedirective.js +42 -25
- package/basedirective/basedirective.min.js +1 -1
- package/blockui/BlockUI.d.ts +21 -2
- package/breadcrumb/Breadcrumb.d.ts +47 -2
- package/breadcrumb/Breadcrumb.vue +7 -2
- package/breadcrumb/BreadcrumbItem.vue +28 -3
- package/breadcrumb/breadcrumb.cjs.js +35 -8
- package/breadcrumb/breadcrumb.cjs.min.js +1 -1
- package/breadcrumb/breadcrumb.esm.js +36 -9
- package/breadcrumb/breadcrumb.esm.min.js +1 -1
- package/breadcrumb/breadcrumb.js +35 -8
- package/breadcrumb/breadcrumb.min.js +1 -1
- package/button/Button.d.ts +24 -2
- package/button/button.cjs.js +1 -1
- package/button/button.esm.js +1 -1
- package/button/button.js +1 -1
- package/calendar/Calendar.d.ts +26 -4
- package/calendar/Calendar.vue +63 -29
- package/calendar/calendar.cjs.js +137 -51
- package/calendar/calendar.cjs.min.js +1 -1
- package/calendar/calendar.esm.js +137 -51
- package/calendar/calendar.esm.min.js +1 -1
- package/calendar/calendar.js +137 -51
- package/calendar/calendar.min.js +1 -1
- package/card/Card.d.ts +8 -2
- package/carousel/Carousel.d.ts +24 -2
- package/carousel/Carousel.vue +22 -2
- package/carousel/carousel.cjs.js +9 -5
- package/carousel/carousel.cjs.min.js +1 -1
- package/carousel/carousel.esm.js +9 -5
- package/carousel/carousel.esm.min.js +1 -1
- package/carousel/carousel.js +9 -5
- package/carousel/carousel.min.js +1 -1
- package/cascadeselect/CascadeSelect.d.ts +21 -2
- package/cascadeselect/cascadeselect.cjs.js +3 -3
- package/cascadeselect/cascadeselect.esm.js +3 -3
- package/cascadeselect/cascadeselect.js +3 -3
- package/chart/Chart.d.ts +18 -2
- package/chart/chart.cjs.js +3 -3
- package/chart/chart.esm.js +3 -3
- package/chart/chart.js +3 -3
- package/checkbox/Checkbox.d.ts +24 -2
- package/checkbox/checkbox.cjs.js +3 -3
- package/checkbox/checkbox.esm.js +3 -3
- package/checkbox/checkbox.js +3 -3
- package/chip/Chip.d.ts +21 -2
- package/chips/Chips.d.ts +21 -2
- package/chips/chips.cjs.js +3 -3
- package/chips/chips.esm.js +3 -3
- package/chips/chips.js +3 -3
- package/colorpicker/ColorPicker.d.ts +21 -2
- package/column/Column.d.ts +24 -2
- package/columngroup/ColumnGroup.d.ts +24 -2
- package/config/PrimeVue.d.ts +93 -92
- package/config/config.cjs.js +4 -3
- package/config/config.cjs.min.js +1 -1
- package/config/config.esm.js +4 -3
- package/config/config.esm.min.js +1 -1
- package/config/config.js +4 -3
- package/config/config.min.js +1 -1
- package/confirmdialog/ConfirmDialog.d.ts +21 -2
- package/confirmpopup/ConfirmPopup.d.ts +21 -2
- package/confirmpopup/confirmpopup.cjs.js +3 -3
- package/confirmpopup/confirmpopup.esm.js +3 -3
- package/confirmpopup/confirmpopup.js +3 -3
- package/contextmenu/ContextMenu.d.ts +54 -2
- package/contextmenu/ContextMenu.vue +13 -7
- package/contextmenu/ContextMenuSub.vue +34 -2
- package/contextmenu/contextmenu.cjs.js +41 -14
- package/contextmenu/contextmenu.cjs.min.js +1 -1
- package/contextmenu/contextmenu.esm.js +42 -15
- package/contextmenu/contextmenu.esm.min.js +1 -1
- package/contextmenu/contextmenu.js +41 -14
- package/contextmenu/contextmenu.min.js +1 -1
- package/core/core.js +256 -147
- package/core/core.min.js +12 -12
- package/datatable/BodyCell.vue +14 -4
- package/datatable/DataTable.d.ts +41 -3
- package/datatable/DataTable.vue +6 -3
- package/datatable/TableBody.vue +7 -8
- package/datatable/datatable.cjs.js +63 -57
- package/datatable/datatable.cjs.min.js +1 -1
- package/datatable/datatable.esm.js +63 -57
- package/datatable/datatable.esm.min.js +1 -1
- package/datatable/datatable.js +63 -57
- package/datatable/datatable.min.js +1 -1
- package/dataview/DataView.d.ts +21 -2
- package/dataviewlayoutoptions/DataViewLayoutOptions.d.ts +21 -2
- package/deferredcontent/DeferredContent.d.ts +21 -2
- package/dialog/Dialog.d.ts +21 -2
- package/dialog/Dialog.vue +2 -2
- package/dialog/dialog.cjs.js +7 -5
- package/dialog/dialog.cjs.min.js +1 -1
- package/dialog/dialog.esm.js +8 -6
- package/dialog/dialog.esm.min.js +1 -1
- package/dialog/dialog.js +7 -5
- package/dialog/dialog.min.js +1 -1
- package/divider/Divider.d.ts +18 -2
- package/dock/Dock.d.ts +46 -2
- package/dock/Dock.vue +5 -0
- package/dock/DockSub.vue +20 -1
- package/dock/dock.cjs.js +21 -2
- package/dock/dock.cjs.min.js +1 -1
- package/dock/dock.esm.js +22 -3
- package/dock/dock.esm.min.js +1 -1
- package/dock/dock.js +21 -2
- package/dock/dock.min.js +1 -1
- package/dropdown/Dropdown.d.ts +24 -2
- package/dropdown/dropdown.cjs.js +6 -6
- package/dropdown/dropdown.esm.js +6 -6
- package/dropdown/dropdown.js +6 -6
- package/editor/Editor.d.ts +22 -2
- package/editor/editor.cjs.js +3 -3
- package/editor/editor.esm.js +3 -3
- package/editor/editor.js +3 -3
- package/fieldset/Fieldset.d.ts +21 -2
- package/fieldset/fieldset.cjs.js +4 -4
- package/fieldset/fieldset.esm.js +4 -4
- package/fieldset/fieldset.js +4 -4
- package/fileupload/FileContent.vue +8 -6
- package/fileupload/FileUpload.d.ts +21 -2
- package/fileupload/FileUpload.vue +9 -7
- package/fileupload/fileupload.cjs.js +17 -13
- package/fileupload/fileupload.cjs.min.js +1 -1
- package/fileupload/fileupload.esm.js +17 -13
- package/fileupload/fileupload.esm.min.js +1 -1
- package/fileupload/fileupload.js +17 -13
- package/fileupload/fileupload.min.js +1 -1
- package/focustrap/FocusTrap.d.ts +8 -2
- package/galleria/Galleria.d.ts +24 -2
- package/galleria/galleria.cjs.js +9 -9
- package/galleria/galleria.esm.js +9 -9
- package/galleria/galleria.js +9 -9
- package/image/Image.d.ts +21 -2
- package/image/image.cjs.js +3 -3
- package/image/image.esm.js +3 -3
- package/image/image.js +3 -3
- package/inlinemessage/InlineMessage.d.ts +21 -2
- package/inplace/Inplace.d.ts +21 -2
- package/inplace/inplace.cjs.js +3 -3
- package/inplace/inplace.esm.js +3 -3
- package/inplace/inplace.js +3 -3
- package/inputmask/InputMask.d.ts +21 -2
- package/inputmask/InputMask.vue +3 -1
- package/inputmask/inputmask.cjs.js +2 -1
- package/inputmask/inputmask.cjs.min.js +1 -1
- package/inputmask/inputmask.esm.js +2 -1
- package/inputmask/inputmask.esm.min.js +1 -1
- package/inputmask/inputmask.js +2 -1
- package/inputmask/inputmask.min.js +1 -1
- package/inputnumber/InputNumber.d.ts +21 -2
- package/inputnumber/inputnumber.cjs.js +6 -6
- package/inputnumber/inputnumber.esm.js +6 -6
- package/inputnumber/inputnumber.js +6 -6
- package/inputswitch/InputSwitch.d.ts +21 -2
- package/inputswitch/inputswitch.cjs.js +3 -3
- package/inputswitch/inputswitch.esm.js +3 -3
- package/inputswitch/inputswitch.js +3 -3
- package/inputtext/InputText.d.ts +21 -2
- package/knob/Knob.d.ts +21 -2
- package/listbox/Listbox.d.ts +24 -2
- package/listbox/listbox.cjs.js +3 -3
- package/listbox/listbox.esm.js +3 -3
- package/listbox/listbox.js +3 -3
- package/megamenu/MegaMenu.d.ts +58 -2
- package/megamenu/MegaMenu.vue +6 -30
- package/megamenu/MegaMenuSub.vue +34 -3
- package/megamenu/megamenu.cjs.js +36 -39
- package/megamenu/megamenu.cjs.min.js +1 -1
- package/megamenu/megamenu.esm.js +37 -40
- package/megamenu/megamenu.esm.min.js +1 -1
- package/megamenu/megamenu.js +36 -39
- package/megamenu/megamenu.min.js +1 -1
- package/menu/Menu.d.ts +60 -2
- package/menu/Menu.vue +6 -1
- package/menu/Menuitem.vue +26 -1
- package/menu/menu.cjs.js +29 -7
- package/menu/menu.cjs.min.js +1 -1
- package/menu/menu.esm.js +30 -8
- package/menu/menu.esm.min.js +1 -1
- package/menu/menu.js +29 -7
- package/menu/menu.min.js +1 -1
- package/menubar/Menubar.d.ts +62 -2
- package/menubar/Menubar.vue +6 -0
- package/menubar/MenubarSub.vue +32 -1
- package/menubar/menubar.cjs.js +34 -6
- package/menubar/menubar.cjs.min.js +1 -1
- package/menubar/menubar.esm.js +35 -7
- package/menubar/menubar.esm.min.js +1 -1
- package/menubar/menubar.js +34 -6
- package/menubar/menubar.min.js +1 -1
- package/menuitem/MenuItem.d.ts +1 -0
- package/message/Message.d.ts +21 -2
- package/message/message.cjs.js +3 -3
- package/message/message.esm.js +3 -3
- package/message/message.js +3 -3
- package/multiselect/MultiSelect.d.ts +24 -2
- package/multiselect/multiselect.cjs.js +6 -6
- package/multiselect/multiselect.esm.js +6 -6
- package/multiselect/multiselect.js +6 -6
- package/orderlist/OrderList.d.ts +24 -2
- package/orderlist/OrderList.vue +7 -5
- package/orderlist/orderlist.cjs.js +10 -8
- package/orderlist/orderlist.cjs.min.js +1 -1
- package/orderlist/orderlist.esm.js +10 -8
- package/orderlist/orderlist.esm.min.js +1 -1
- package/orderlist/orderlist.js +10 -8
- package/orderlist/orderlist.min.js +1 -1
- package/organizationchart/OrganizationChart.d.ts +24 -2
- package/organizationchart/organizationchart.cjs.js +4 -4
- package/organizationchart/organizationchart.esm.js +4 -4
- package/organizationchart/organizationchart.js +4 -4
- package/overlaypanel/OverlayPanel.d.ts +21 -2
- package/overlaypanel/overlaypanel.cjs.js +3 -3
- package/overlaypanel/overlaypanel.esm.js +3 -3
- package/overlaypanel/overlaypanel.js +3 -3
- package/package.json +1 -1
- package/paginator/FirstPageLink.vue +1 -1
- package/paginator/JumpToPageDropdown.vue +1 -0
- package/paginator/LastPageLink.vue +1 -1
- package/paginator/NextPageLink.vue +1 -1
- package/paginator/Paginator.d.ts +24 -2
- package/paginator/PrevPageLink.vue +1 -1
- package/paginator/RowsPerPageDropdown.vue +1 -0
- package/paginator/paginator.cjs.js +19 -9
- package/paginator/paginator.cjs.min.js +1 -1
- package/paginator/paginator.esm.js +19 -9
- package/paginator/paginator.esm.min.js +1 -1
- package/paginator/paginator.js +19 -9
- package/paginator/paginator.min.js +1 -1
- package/panel/Panel.d.ts +21 -2
- package/panel/panel.cjs.js +3 -3
- package/panel/panel.esm.js +3 -3
- package/panel/panel.js +3 -3
- package/panelmenu/PanelMenu.d.ts +58 -2
- package/panelmenu/PanelMenu.vue +6 -0
- package/panelmenu/PanelMenuList.vue +1 -0
- package/panelmenu/PanelMenuSub.vue +33 -1
- package/panelmenu/panelmenu.cjs.js +41 -12
- package/panelmenu/panelmenu.cjs.min.js +1 -1
- package/panelmenu/panelmenu.esm.js +42 -13
- package/panelmenu/panelmenu.esm.min.js +1 -1
- package/panelmenu/panelmenu.js +41 -12
- package/panelmenu/panelmenu.min.js +1 -1
- package/passthrough/index.cjs.js +15 -9
- package/passthrough/index.cjs.min.js +1 -1
- package/passthrough/index.d.ts +4 -4
- package/passthrough/index.esm.js +15 -9
- package/passthrough/index.esm.min.js +1 -1
- package/passthrough/index.js +15 -9
- package/passthrough/index.min.js +1 -1
- package/passthrough/tailwind/index.cjs.js +3 -3
- package/passthrough/tailwind/index.cjs.min.js +1 -1
- package/passthrough/tailwind/index.esm.js +3 -3
- package/passthrough/tailwind/index.esm.min.js +1 -1
- package/passthrough/tailwind/index.js +3 -3
- package/passthrough/tailwind/index.min.js +1 -1
- package/password/Password.d.ts +21 -2
- package/password/password.cjs.js +3 -3
- package/password/password.esm.js +3 -3
- package/password/password.js +3 -3
- package/picklist/PickList.d.ts +24 -2
- package/picklist/PickList.vue +8 -5
- package/picklist/picklist.cjs.js +10 -8
- package/picklist/picklist.cjs.min.js +1 -1
- package/picklist/picklist.esm.js +10 -8
- package/picklist/picklist.esm.min.js +1 -1
- package/picklist/picklist.js +10 -8
- package/picklist/picklist.min.js +1 -1
- package/progressbar/ProgressBar.d.ts +18 -2
- package/progressspinner/ProgressSpinner.d.ts +18 -2
- package/radiobutton/RadioButton.d.ts +21 -2
- package/radiobutton/radiobutton.cjs.js +3 -3
- package/radiobutton/radiobutton.esm.js +3 -3
- package/radiobutton/radiobutton.js +3 -3
- package/rating/Rating.d.ts +24 -2
- package/ripple/Ripple.d.ts +8 -2
- package/row/Row.d.ts +16 -0
- package/scrollpanel/ScrollPanel.d.ts +21 -2
- package/scrolltop/ScrollTop.d.ts +21 -2
- package/selectbutton/SelectButton.d.ts +24 -2
- package/sidebar/Sidebar.d.ts +21 -2
- package/sidebar/sidebar.cjs.js +3 -3
- package/sidebar/sidebar.esm.js +3 -3
- package/sidebar/sidebar.js +3 -3
- package/skeleton/Skeleton.d.ts +18 -2
- package/slider/Slider.d.ts +18 -2
- package/speeddial/SpeedDial.d.ts +24 -2
- package/speeddial/speeddial.cjs.js +4 -4
- package/speeddial/speeddial.esm.js +4 -4
- package/speeddial/speeddial.js +4 -4
- package/splitbutton/SplitButton.d.ts +35 -2
- package/splitbutton/SplitButton.vue +6 -2
- package/splitbutton/splitbutton.cjs.js +17 -9
- package/splitbutton/splitbutton.cjs.min.js +1 -1
- package/splitbutton/splitbutton.esm.js +18 -10
- package/splitbutton/splitbutton.esm.min.js +1 -1
- package/splitbutton/splitbutton.js +17 -9
- package/splitbutton/splitbutton.min.js +1 -1
- package/splitter/Splitter.d.ts +24 -2
- package/splitterpanel/SplitterPanel.d.ts +21 -2
- package/steps/Steps.d.ts +51 -2
- package/steps/Steps.vue +31 -1
- package/steps/steps.cjs.js +31 -3
- package/steps/steps.cjs.min.js +1 -1
- package/steps/steps.esm.js +31 -3
- package/steps/steps.esm.min.js +1 -1
- package/steps/steps.js +32 -4
- package/steps/steps.min.js +1 -1
- package/styleclass/StyleClass.d.ts +8 -2
- package/tabmenu/TabMenu.d.ts +50 -2
- package/tabmenu/TabMenu.vue +27 -1
- package/tabmenu/tabmenu.cjs.js +26 -3
- package/tabmenu/tabmenu.cjs.min.js +1 -1
- package/tabmenu/tabmenu.esm.js +26 -3
- package/tabmenu/tabmenu.esm.min.js +1 -1
- package/tabmenu/tabmenu.js +27 -4
- package/tabmenu/tabmenu.min.js +1 -1
- package/tabpanel/TabPanel.d.ts +24 -2
- package/tabview/TabView.d.ts +8 -2
- package/tabview/tabview.cjs.js +3 -3
- package/tabview/tabview.esm.js +3 -3
- package/tabview/tabview.js +3 -3
- package/tag/Tag.d.ts +18 -2
- package/terminal/Terminal.d.ts +21 -2
- package/textarea/Textarea.d.ts +21 -2
- package/tieredmenu/TieredMenu.d.ts +58 -2
- package/tieredmenu/TieredMenu.vue +6 -0
- package/tieredmenu/TieredMenuSub.vue +33 -1
- package/tieredmenu/tieredmenu.cjs.js +35 -7
- package/tieredmenu/tieredmenu.cjs.min.js +1 -1
- package/tieredmenu/tieredmenu.esm.js +36 -8
- package/tieredmenu/tieredmenu.esm.min.js +1 -1
- package/tieredmenu/tieredmenu.js +35 -7
- package/tieredmenu/tieredmenu.min.js +1 -1
- package/timeline/Timeline.d.ts +21 -2
- package/toast/Toast.d.ts +21 -2
- package/toast/toast.cjs.js +7 -7
- package/toast/toast.esm.js +7 -7
- package/toast/toast.js +7 -7
- package/togglebutton/ToggleButton.d.ts +24 -2
- package/togglebutton/ToggleButton.vue +4 -4
- package/togglebutton/togglebutton.cjs.js +7 -7
- package/togglebutton/togglebutton.cjs.min.js +1 -1
- package/togglebutton/togglebutton.esm.js +7 -7
- package/togglebutton/togglebutton.esm.min.js +1 -1
- package/togglebutton/togglebutton.js +7 -7
- package/togglebutton/togglebutton.min.js +1 -1
- package/toolbar/Toolbar.d.ts +18 -2
- package/tooltip/Tooltip.d.ts +12 -2
- package/tooltip/tooltip.cjs.js +2 -2
- package/tooltip/tooltip.esm.js +2 -2
- package/tooltip/tooltip.js +2 -2
- package/tree/Tree.d.ts +24 -2
- package/tree/Tree.vue +1 -1
- package/tree/tree.cjs.js +7 -7
- package/tree/tree.cjs.min.js +1 -1
- package/tree/tree.esm.js +7 -7
- package/tree/tree.esm.min.js +1 -1
- package/tree/tree.js +7 -7
- package/tree/tree.min.js +1 -1
- package/treeselect/TreeSelect.d.ts +21 -2
- package/treeselect/treeselect.cjs.js +6 -6
- package/treeselect/treeselect.esm.js +6 -6
- package/treeselect/treeselect.js +6 -6
- package/treetable/BodyCell.vue +1 -1
- package/treetable/TreeTable.d.ts +24 -2
- package/treetable/TreeTableRow.vue +1 -1
- package/treetable/treetable.cjs.js +22 -20
- package/treetable/treetable.cjs.min.js +1 -1
- package/treetable/treetable.esm.js +22 -20
- package/treetable/treetable.esm.min.js +1 -1
- package/treetable/treetable.js +22 -20
- package/treetable/treetable.min.js +1 -1
- package/tristatecheckbox/TriStateCheckbox.d.ts +24 -2
- package/tristatecheckbox/tristatecheckbox.cjs.js +3 -3
- package/tristatecheckbox/tristatecheckbox.esm.js +3 -3
- package/tristatecheckbox/tristatecheckbox.js +3 -3
- package/ts-helpers.d.ts +2 -2
- package/utils/utils.cjs.js +30 -20
- package/utils/utils.cjs.min.js +1 -1
- package/utils/utils.esm.js +30 -20
- package/utils/utils.esm.min.js +1 -1
- package/utils/utils.js +30 -20
- package/utils/utils.min.js +1 -1
- package/vetur-attributes.json +1 -1
- package/virtualscroller/BaseVirtualScroller.vue +3 -3
- package/virtualscroller/VirtualScroller.d.ts +21 -2
- package/virtualscroller/virtualscroller.cjs.js +6 -6
- package/virtualscroller/virtualscroller.cjs.min.js +1 -1
- package/virtualscroller/virtualscroller.esm.js +6 -6
- package/virtualscroller/virtualscroller.esm.min.js +1 -1
- package/virtualscroller/virtualscroller.js +6 -6
- package/virtualscroller/virtualscroller.min.js +1 -1
- package/web-types.json +13 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
import{loadBaseStyle as n}from"primevue/base";import{ObjectUtils as t}from"primevue/utils";import{mergeProps as e}from"vue";function o(n){return o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(n){return typeof n}:function(n){return n&&"function"==typeof Symbol&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},o(n)}function i(n,t){return
|
|
1
|
+
import{loadBaseStyle as n}from"primevue/base";import{ObjectUtils as t}from"primevue/utils";import{mergeProps as e}from"vue";function o(n){return o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(n){return typeof n}:function(n){return n&&"function"==typeof Symbol&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},o(n)}function i(n,t){return v(n)||a(n,t)||r(n,t)||l()}function l(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function r(n,t){if(n){if("string"==typeof n)return u(n,t);var e=Object.prototype.toString.call(n).slice(8,-1);return"Object"===e&&n.constructor&&(e=n.constructor.name),"Map"===e||"Set"===e?Array.from(n):"Arguments"===e||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e)?u(n,t):void 0}}function u(n,t){(null==t||t>n.length)&&(t=n.length);for(var e=0,o=new Array(t);e<t;e++)o[e]=n[e];return o}function a(n,t){var e=null==n?null:"undefined"!=typeof Symbol&&n[Symbol.iterator]||n["@@iterator"];if(null!=e){var o,i,l,r,u=[],a=!0,v=!1;try{if(l=(e=e.call(n)).next,0===t){if(Object(e)!==e)return;a=!1}else for(;!(a=(o=l.call(e)).done)&&(u.push(o.value),u.length!==t);a=!0);}catch(n){v=!0,i=n}finally{try{if(!a&&null!=e.return&&(r=e.return(),Object(r)!==r))return}finally{if(v)throw i}}return u}}function v(n){if(Array.isArray(n))return n}function d(n,t){var e=Object.keys(n);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(n);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(n,t).enumerable}))),e.push.apply(e,o)}return e}function c(n){for(var t=1;t<arguments.length;t++){var e=null!=arguments[t]?arguments[t]:{};t%2?d(Object(e),!0).forEach((function(t){s(n,t,e[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(e)):d(Object(e)).forEach((function(t){Object.defineProperty(n,t,Object.getOwnPropertyDescriptor(e,t))}))}return n}function s(n,t,e){return(t=f(t))in n?Object.defineProperty(n,t,{value:e,enumerable:!0,configurable:!0,writable:!0}):n[t]=e,n}function f(n){var t=g(n,"string");return"symbol"===o(t)?t:String(t)}function g(n,t){if("object"!==o(n)||null===n)return n;var e=n[Symbol.toPrimitive];if(void 0!==e){var i=e.call(n,t||"default");if("object"!==o(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(n)}var p={_getMeta:function(){return[t.isObject(arguments.length<=0?void 0:arguments[0])||arguments.length<=0?void 0:arguments[0],t.getItemValue(t.isObject(arguments.length<=0?void 0:arguments[0])?arguments.length<=0?void 0:arguments[0]:arguments.length<=1?void 0:arguments[1])]},_getOptionValue:function(n){var e=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o=t.toFlatCase(arguments.length>1&&void 0!==arguments[1]?arguments[1]:"").split("."),i=o.shift();return i?t.isObject(n)?p._getOptionValue(t.getItemValue(n[Object.keys(n).find((function(n){return t.toFlatCase(n)===i}))||""],e),o.join("."),e):void 0:t.getItemValue(n,e)},_getPTValue:function(){var n,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},u=function(){var n=p._getOptionValue.apply(p,arguments);return t.isString(n)||t.isArray(n)?{class:n}:n},a="data-pc-",v=(null===(n=o.binding)||void 0===n||null===(n=n.value)||void 0===n?void 0:n.ptOptions)||{},d=v.mergeSections,f=void 0===d||d,g=v.mergeProps,y=void 0!==g&&g,m=!(arguments.length>4&&void 0!==arguments[4])||arguments[4]?p._useDefaultPT(o,o.defaultPT,u,l,r):void 0,b=p._usePT(o,p._getPT(i,o.$name),u,l,c(c({},r),{},{global:m||{}})),h=c(c({},"root"===l&&s({},"".concat(a,"name"),t.toFlatCase(o.$name))),{},s({},"".concat(a,"section"),t.toFlatCase(l)));return f||!f&&b?y?e(m,b,h):c(c(c({},m),b),h):c(c({},b),h)},_getPT:function(n){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",o=arguments.length>2?arguments[2]:void 0,i=null==n?void 0:n._usept,l=function(n){var i,l=o?o(n):n,r=t.toFlatCase(e);return null!==(i=null==l?void 0:l[r])&&void 0!==i?i:l};return t.isNotEmpty(i)?{_usept:i,originalValue:l(n.originalValue),value:l(n.value)}:l(n)},_usePT:function(){var n=arguments.length>1?arguments[1]:void 0,o=arguments.length>2?arguments[2]:void 0,i=arguments.length>3?arguments[3]:void 0,l=arguments.length>4?arguments[4]:void 0,r=function(n){return o(n,i,l)};if(null!=n&&n.hasOwnProperty("_usept")){var u=n._usept||{},a=u.mergeSections,v=void 0===a||a,d=u.mergeProps,s=void 0!==d&&d,f=r(n.originalValue),g=r(n.value);if(void 0===f&&void 0===g)return;return t.isString(g)?g:t.isString(f)?f:v||!v&&g?s?e(f,g):c(c({},f),g):g}return r(n)},_useDefaultPT:function(){return p._usePT(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},arguments.length>2?arguments[2]:void 0,arguments.length>3?arguments[3]:void 0,arguments.length>4?arguments[4]:void 0)},_hook:function(n,e,o,i,l,r){var u,a,v,d="on".concat(t.toCapitalCase(e)),c=null==i||null===(u=i.instance)||void 0===u||null===(u=u.$primevue)||void 0===u?void 0:u.config,s=null==o?void 0:o.$instance,f=p._usePT(s,p._getPT(null==i||null===(a=i.value)||void 0===a?void 0:a.pt,n),p._getOptionValue,"hooks.".concat(d)),g=p._useDefaultPT(s,null==c||null===(v=c.pt)||void 0===v||null===(v=v.directives)||void 0===v?void 0:v[n],p._getOptionValue,"hooks.".concat(d)),y={el:o,binding:i,vnode:l,prevVnode:r};null==f||f(s,y),null==g||g(s,y)},_extend:function(e){var o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=function(n,i,l,r,u){var a,v,d;i._$instances=i._$instances||{};var s=null==l||null===(a=l.instance)||void 0===a||null===(a=a.$primevue)||void 0===a?void 0:a.config,f=i._$instances[e]||{},g=t.isEmpty(f)?c(c({},o),null==o?void 0:o.methods):{};i._$instances[e]=c(c({},f),{},{$name:e,$host:i,$binding:l,$el:f.$el||void 0,$css:c({classes:void 0,inlineStyles:void 0,loadStyle:function(){}},null==o?void 0:o.css),$config:s,defaultPT:p._getPT(null==s?void 0:s.pt,void 0,(function(n){var t;return null==n||null===(t=n.directives)||void 0===t?void 0:t[e]})),isUnstyled:void 0!==i.unstyled?i.unstyled:null==s?void 0:s.unstyled,ptm:function(){var n;return p._getPTValue(i.$instance,null===(n=i.$instance)||void 0===n||null===(n=n.$binding)||void 0===n||null===(n=n.value)||void 0===n?void 0:n.pt,arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",c({},arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}))},ptmo:function(){return p._getPTValue(i.$instance,arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},!1)},cx:function(){var n,t;return null!==(n=i.$instance)&&void 0!==n&&n.isUnstyled?void 0:p._getOptionValue(null===(t=i.$instance)||void 0===t||null===(t=t.$css)||void 0===t?void 0:t.classes,arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",c({},arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}))},sx:function(){var n;return!(arguments.length>1&&void 0!==arguments[1])||arguments[1]?p._getOptionValue(null===(n=i.$instance)||void 0===n||null===(n=n.$css)||void 0===n?void 0:n.inlineStyles,arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",c({},arguments.length>2&&void 0!==arguments[2]?arguments[2]:{})):void 0}},g),i.$instance=i._$instances[e],null===(v=(d=i.$instance)[n])||void 0===v||v.call(d,i,l,r,u),p._hook(e,n,i,l,r,u)};return{created:function(n,t,e,o){i("created",n,t,e,o)},beforeMount:function(t,e,o,l){var r,u,a,v,d,c=null==e||null===(r=e.instance)||void 0===r||null===(r=r.$primevue)||void 0===r?void 0:r.config;n(void 0,{nonce:null==c||null===(u=c.csp)||void 0===u?void 0:u.nonce}),(null===(a=t.$instance)||void 0===a||!a.isUnstyled)&&(null===(v=t.$instance)||void 0===v||null===(v=v.$css)||void 0===v||v.loadStyle(void 0,{nonce:null==c||null===(d=c.csp)||void 0===d?void 0:d.nonce})),i("beforeMount",t,e,o,l)},mounted:function(n,t,e,o){i("mounted",n,t,e,o)},beforeUpdate:function(n,t,e,o){i("beforeUpdate",n,t,e,o)},updated:function(n,t,e,o){i("updated",n,t,e,o)},beforeUnmount:function(n,t,e,o){i("beforeUnmount",n,t,e,o)},unmounted:function(n,t,e,o){i("unmounted",n,t,e,o)}}},extend:function(){var n=i(p._getMeta.apply(p,arguments),2),t=n[1];return c({extend:function(){var n=i(p._getMeta.apply(p,arguments),2),e=n[1];return p.extend(n[0],c(c(c({},t),null==t?void 0:t.methods),e))}},p._extend(n[0],t))}};export{p as default};
|
|
@@ -2,15 +2,15 @@ this.primevue = this.primevue || {};
|
|
|
2
2
|
this.primevue.basedirective = (function (base, utils, vue) {
|
|
3
3
|
'use strict';
|
|
4
4
|
|
|
5
|
-
function _typeof(
|
|
5
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
6
6
|
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
7
7
|
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
8
8
|
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
9
9
|
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
10
|
-
function _iterableToArrayLimit(
|
|
10
|
+
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t["return"] && (u = t["return"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
11
11
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
12
|
-
function ownKeys(
|
|
13
|
-
function _objectSpread(
|
|
12
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
13
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
14
14
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
15
15
|
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
16
16
|
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
@@ -28,6 +28,7 @@ this.primevue.basedirective = (function (base, utils, vue) {
|
|
|
28
28
|
}) || ''], params), fKeys.join('.'), params) : undefined : utils.ObjectUtils.getItemValue(options, params);
|
|
29
29
|
},
|
|
30
30
|
_getPTValue: function _getPTValue() {
|
|
31
|
+
var _instance$binding;
|
|
31
32
|
var instance = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
32
33
|
var obj = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
33
34
|
var key = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : '';
|
|
@@ -40,19 +41,27 @@ this.primevue.basedirective = (function (base, utils, vue) {
|
|
|
40
41
|
} : value;
|
|
41
42
|
};
|
|
42
43
|
var datasetPrefix = 'data-pc-';
|
|
43
|
-
var
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
44
|
+
var _ref = ((_instance$binding = instance.binding) === null || _instance$binding === void 0 || (_instance$binding = _instance$binding.value) === null || _instance$binding === void 0 ? void 0 : _instance$binding.ptOptions) || {},
|
|
45
|
+
_ref$mergeSections = _ref.mergeSections,
|
|
46
|
+
mergeSections = _ref$mergeSections === void 0 ? true : _ref$mergeSections,
|
|
47
|
+
_ref$mergeProps = _ref.mergeProps,
|
|
48
|
+
useMergeProps = _ref$mergeProps === void 0 ? false : _ref$mergeProps;
|
|
49
|
+
var global = searchInDefaultPT ? BaseDirective._useDefaultPT(instance, instance.defaultPT, getValue, key, params) : undefined;
|
|
50
|
+
var self = BaseDirective._usePT(instance, BaseDirective._getPT(obj, instance.$name), getValue, key, _objectSpread(_objectSpread({}, params), {}, {
|
|
51
|
+
global: global || {}
|
|
52
|
+
}));
|
|
53
|
+
var datasets = _objectSpread(_objectSpread({}, key === 'root' && _defineProperty({}, "".concat(datasetPrefix, "name"), utils.ObjectUtils.toFlatCase(instance.$name))), {}, _defineProperty({}, "".concat(datasetPrefix, "section"), utils.ObjectUtils.toFlatCase(key)));
|
|
54
|
+
return mergeSections || !mergeSections && self ? useMergeProps ? vue.mergeProps(global, self, datasets) : _objectSpread(_objectSpread(_objectSpread({}, global), self), datasets) : _objectSpread(_objectSpread({}, self), datasets);
|
|
47
55
|
},
|
|
48
56
|
_getPT: function _getPT(pt) {
|
|
49
57
|
var key = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';
|
|
50
58
|
var callback = arguments.length > 2 ? arguments[2] : undefined;
|
|
51
59
|
var _usept = pt === null || pt === void 0 ? void 0 : pt['_usept'];
|
|
52
60
|
var getValue = function getValue(value) {
|
|
53
|
-
var _computedValue$
|
|
61
|
+
var _computedValue$_key;
|
|
54
62
|
var computedValue = callback ? callback(value) : value;
|
|
55
|
-
|
|
63
|
+
var _key = utils.ObjectUtils.toFlatCase(key);
|
|
64
|
+
return (_computedValue$_key = computedValue === null || computedValue === void 0 ? void 0 : computedValue[_key]) !== null && _computedValue$_key !== void 0 ? _computedValue$_key : computedValue;
|
|
56
65
|
};
|
|
57
66
|
return utils.ObjectUtils.isNotEmpty(_usept) ? {
|
|
58
67
|
_usept: _usept,
|
|
@@ -60,42 +69,50 @@ this.primevue.basedirective = (function (base, utils, vue) {
|
|
|
60
69
|
value: getValue(pt.value)
|
|
61
70
|
} : getValue(pt);
|
|
62
71
|
},
|
|
63
|
-
_usePT: function _usePT(
|
|
72
|
+
_usePT: function _usePT() {
|
|
73
|
+
var pt = arguments.length > 1 ? arguments[1] : undefined;
|
|
74
|
+
var callback = arguments.length > 2 ? arguments[2] : undefined;
|
|
75
|
+
var key = arguments.length > 3 ? arguments[3] : undefined;
|
|
76
|
+
var params = arguments.length > 4 ? arguments[4] : undefined;
|
|
64
77
|
var fn = function fn(value) {
|
|
65
78
|
return callback(value, key, params);
|
|
66
79
|
};
|
|
67
80
|
if (pt !== null && pt !== void 0 && pt.hasOwnProperty('_usept')) {
|
|
68
|
-
var
|
|
69
|
-
|
|
70
|
-
|
|
81
|
+
var _ref3 = pt['_usept'] || {},
|
|
82
|
+
_ref3$mergeSections = _ref3.mergeSections,
|
|
83
|
+
mergeSections = _ref3$mergeSections === void 0 ? true : _ref3$mergeSections,
|
|
84
|
+
_ref3$mergeProps = _ref3.mergeProps,
|
|
85
|
+
useMergeProps = _ref3$mergeProps === void 0 ? false : _ref3$mergeProps;
|
|
71
86
|
var originalValue = fn(pt.originalValue);
|
|
72
87
|
var value = fn(pt.value);
|
|
73
88
|
if (originalValue === undefined && value === undefined) return undefined;else if (utils.ObjectUtils.isString(value)) return value;else if (utils.ObjectUtils.isString(originalValue)) return originalValue;
|
|
74
|
-
return
|
|
89
|
+
return mergeSections || !mergeSections && value ? useMergeProps ? vue.mergeProps(originalValue, value) : _objectSpread(_objectSpread({}, originalValue), value) : value;
|
|
75
90
|
}
|
|
76
91
|
return fn(pt);
|
|
77
92
|
},
|
|
78
93
|
_useDefaultPT: function _useDefaultPT() {
|
|
79
|
-
var
|
|
80
|
-
var
|
|
81
|
-
var
|
|
82
|
-
var
|
|
83
|
-
|
|
94
|
+
var instance = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
95
|
+
var defaultPT = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
96
|
+
var callback = arguments.length > 2 ? arguments[2] : undefined;
|
|
97
|
+
var key = arguments.length > 3 ? arguments[3] : undefined;
|
|
98
|
+
var params = arguments.length > 4 ? arguments[4] : undefined;
|
|
99
|
+
return BaseDirective._usePT(instance, defaultPT, callback, key, params);
|
|
84
100
|
},
|
|
85
101
|
_hook: function _hook(directiveName, hookName, el, binding, vnode, prevVnode) {
|
|
86
102
|
var _binding$instance, _binding$value, _config$pt;
|
|
87
103
|
var name = "on".concat(utils.ObjectUtils.toCapitalCase(hookName));
|
|
88
104
|
var config = binding === null || binding === void 0 || (_binding$instance = binding.instance) === null || _binding$instance === void 0 || (_binding$instance = _binding$instance.$primevue) === null || _binding$instance === void 0 ? void 0 : _binding$instance.config;
|
|
89
|
-
var
|
|
90
|
-
var
|
|
105
|
+
var instance = el === null || el === void 0 ? void 0 : el.$instance;
|
|
106
|
+
var selfHook = BaseDirective._usePT(instance, BaseDirective._getPT(binding === null || binding === void 0 || (_binding$value = binding.value) === null || _binding$value === void 0 ? void 0 : _binding$value.pt, directiveName), BaseDirective._getOptionValue, "hooks.".concat(name));
|
|
107
|
+
var defaultHook = BaseDirective._useDefaultPT(instance, config === null || config === void 0 || (_config$pt = config.pt) === null || _config$pt === void 0 || (_config$pt = _config$pt.directives) === null || _config$pt === void 0 ? void 0 : _config$pt[directiveName], BaseDirective._getOptionValue, "hooks.".concat(name));
|
|
91
108
|
var options = {
|
|
92
109
|
el: el,
|
|
93
110
|
binding: binding,
|
|
94
111
|
vnode: vnode,
|
|
95
112
|
prevVnode: prevVnode
|
|
96
113
|
};
|
|
97
|
-
selfHook === null || selfHook === void 0
|
|
98
|
-
defaultHook === null || defaultHook === void 0
|
|
114
|
+
selfHook === null || selfHook === void 0 || selfHook(instance, options);
|
|
115
|
+
defaultHook === null || defaultHook === void 0 || defaultHook(instance, options);
|
|
99
116
|
},
|
|
100
117
|
_extend: function _extend(name) {
|
|
101
118
|
var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
@@ -151,7 +168,7 @@ this.primevue.basedirective = (function (base, utils, vue) {
|
|
|
151
168
|
}
|
|
152
169
|
}, $options);
|
|
153
170
|
el.$instance = el._$instances[name]; // pass instance data to hooks
|
|
154
|
-
(_el$$instance$hook = (_el$$instance5 = el.$instance)[hook]) === null || _el$$instance$hook === void 0
|
|
171
|
+
(_el$$instance$hook = (_el$$instance5 = el.$instance)[hook]) === null || _el$$instance$hook === void 0 || _el$$instance$hook.call(_el$$instance5, el, binding, vnode, prevVnode); // handle hook in directive implementation
|
|
155
172
|
BaseDirective._hook(name, hook, el, binding, vnode, prevVnode); // handle hooks during directive uses (global and self-definition)
|
|
156
173
|
};
|
|
157
174
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
this.primevue=this.primevue||{},this.primevue.basedirective=function(t,e,n){"use strict";function i(t){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i(t)}function o(t,e){return a(t)||c(t,e)||r(t,e)||l()}function l(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function r(t,e){if(t){if("string"==typeof t)return u(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?u(t,e):void 0}}function u(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,i=new Array(e);n<e;n++)i[n]=t[n];return i}function c(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var i,o,l,r,u=[],c=!0,a=!1;try{if(l=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;c=!1}else for(;!(c=(i=l.call(n)).done)&&(u.push(i.value),u.length!==e);c=!0);}catch(t){a=!0,o=t}finally{try{if(!c&&null!=n.return&&(r=n.return(),Object(r)!==r))return}finally{if(a)throw o}}return u}}function a(t){if(Array.isArray(t))return t}function s(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,i)}return n}function v(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?s(Object(n),!0).forEach((function(e){d(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):s(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function d(t,e,n){return(e=f(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function f(t){var e=g(t,"string");return"symbol"===i(e)?e:String(e)}function g(t,e){if("object"!==i(t)||null===t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var o=n.call(t,e||"default");if("object"!==i(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}var p={_getMeta:function(){return[e.ObjectUtils.isObject(arguments.length<=0?void 0:arguments[0])||arguments.length<=0?void 0:arguments[0],e.ObjectUtils.getItemValue(e.ObjectUtils.isObject(arguments.length<=0?void 0:arguments[0])?arguments.length<=0?void 0:arguments[0]:arguments.length<=1?void 0:arguments[1])]},_getOptionValue:function(t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=e.ObjectUtils.toFlatCase(arguments.length>1&&void 0!==arguments[1]?arguments[1]:"").split("."),o=i.shift();return o?e.ObjectUtils.isObject(t)?p._getOptionValue(e.ObjectUtils.getItemValue(t[Object.keys(t).find((function(t){return e.ObjectUtils.toFlatCase(t)===o}))||""],n),i.join("."),n):void 0:e.ObjectUtils.getItemValue(t,n)},_getPTValue:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},
|
|
1
|
+
this.primevue=this.primevue||{},this.primevue.basedirective=function(t,e,n){"use strict";function i(t){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i(t)}function o(t,e){return a(t)||c(t,e)||r(t,e)||l()}function l(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function r(t,e){if(t){if("string"==typeof t)return u(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?u(t,e):void 0}}function u(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,i=new Array(e);n<e;n++)i[n]=t[n];return i}function c(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var i,o,l,r,u=[],c=!0,a=!1;try{if(l=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;c=!1}else for(;!(c=(i=l.call(n)).done)&&(u.push(i.value),u.length!==e);c=!0);}catch(t){a=!0,o=t}finally{try{if(!c&&null!=n.return&&(r=n.return(),Object(r)!==r))return}finally{if(a)throw o}}return u}}function a(t){if(Array.isArray(t))return t}function s(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,i)}return n}function v(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?s(Object(n),!0).forEach((function(e){d(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):s(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function d(t,e,n){return(e=f(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function f(t){var e=g(t,"string");return"symbol"===i(e)?e:String(e)}function g(t,e){if("object"!==i(t)||null===t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var o=n.call(t,e||"default");if("object"!==i(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}var p={_getMeta:function(){return[e.ObjectUtils.isObject(arguments.length<=0?void 0:arguments[0])||arguments.length<=0?void 0:arguments[0],e.ObjectUtils.getItemValue(e.ObjectUtils.isObject(arguments.length<=0?void 0:arguments[0])?arguments.length<=0?void 0:arguments[0]:arguments.length<=1?void 0:arguments[1])]},_getOptionValue:function(t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=e.ObjectUtils.toFlatCase(arguments.length>1&&void 0!==arguments[1]?arguments[1]:"").split("."),o=i.shift();return o?e.ObjectUtils.isObject(t)?p._getOptionValue(e.ObjectUtils.getItemValue(t[Object.keys(t).find((function(t){return e.ObjectUtils.toFlatCase(t)===o}))||""],n),i.join("."),n):void 0:e.ObjectUtils.getItemValue(t,n)},_getPTValue:function(){var t,i=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},u=function(){var t=p._getOptionValue.apply(p,arguments);return e.ObjectUtils.isString(t)||e.ObjectUtils.isArray(t)?{class:t}:t},c="data-pc-",a=(null===(t=i.binding)||void 0===t||null===(t=t.value)||void 0===t?void 0:t.ptOptions)||{},s=a.mergeSections,f=void 0===s||s,g=a.mergeProps,b=void 0!==g&&g,y=!(arguments.length>4&&void 0!==arguments[4])||arguments[4]?p._useDefaultPT(i,i.defaultPT,u,l,r):void 0,m=p._usePT(i,p._getPT(o,i.$name),u,l,v(v({},r),{},{global:y||{}})),h=v(v({},"root"===l&&d({},"".concat(c,"name"),e.ObjectUtils.toFlatCase(i.$name))),{},d({},"".concat(c,"section"),e.ObjectUtils.toFlatCase(l)));return f||!f&&m?b?n.mergeProps(y,m,h):v(v(v({},y),m),h):v(v({},m),h)},_getPT:function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",i=arguments.length>2?arguments[2]:void 0,o=null==t?void 0:t._usept,l=function(t){var o,l=i?i(t):t,r=e.ObjectUtils.toFlatCase(n);return null!==(o=null==l?void 0:l[r])&&void 0!==o?o:l};return e.ObjectUtils.isNotEmpty(o)?{_usept:o,originalValue:l(t.originalValue),value:l(t.value)}:l(t)},_usePT:function(){var t=arguments.length>1?arguments[1]:void 0,i=arguments.length>2?arguments[2]:void 0,o=arguments.length>3?arguments[3]:void 0,l=arguments.length>4?arguments[4]:void 0,r=function(t){return i(t,o,l)};if(null!=t&&t.hasOwnProperty("_usept")){var u=t._usept||{},c=u.mergeSections,a=void 0===c||c,s=u.mergeProps,d=void 0!==s&&s,f=r(t.originalValue),g=r(t.value);if(void 0===f&&void 0===g)return;return e.ObjectUtils.isString(g)?g:e.ObjectUtils.isString(f)?f:a||!a&&g?d?n.mergeProps(f,g):v(v({},f),g):g}return r(t)},_useDefaultPT:function(){return p._usePT(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},arguments.length>2?arguments[2]:void 0,arguments.length>3?arguments[3]:void 0,arguments.length>4?arguments[4]:void 0)},_hook:function(t,n,i,o,l,r){var u,c,a,s="on".concat(e.ObjectUtils.toCapitalCase(n)),v=null==o||null===(u=o.instance)||void 0===u||null===(u=u.$primevue)||void 0===u?void 0:u.config,d=null==i?void 0:i.$instance,f=p._usePT(d,p._getPT(null==o||null===(c=o.value)||void 0===c?void 0:c.pt,t),p._getOptionValue,"hooks.".concat(s)),g=p._useDefaultPT(d,null==v||null===(a=v.pt)||void 0===a||null===(a=a.directives)||void 0===a?void 0:a[t],p._getOptionValue,"hooks.".concat(s)),b={el:i,binding:o,vnode:l,prevVnode:r};null==f||f(d,b),null==g||g(d,b)},_extend:function(n){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},o=function(t,o,l,r,u){var c,a,s;o._$instances=o._$instances||{};var d=null==l||null===(c=l.instance)||void 0===c||null===(c=c.$primevue)||void 0===c?void 0:c.config,f=o._$instances[n]||{},g=e.ObjectUtils.isEmpty(f)?v(v({},i),null==i?void 0:i.methods):{};o._$instances[n]=v(v({},f),{},{$name:n,$host:o,$binding:l,$el:f.$el||void 0,$css:v({classes:void 0,inlineStyles:void 0,loadStyle:function(){}},null==i?void 0:i.css),$config:d,defaultPT:p._getPT(null==d?void 0:d.pt,void 0,(function(t){var e;return null==t||null===(e=t.directives)||void 0===e?void 0:e[n]})),isUnstyled:void 0!==o.unstyled?o.unstyled:null==d?void 0:d.unstyled,ptm:function(){var t;return p._getPTValue(o.$instance,null===(t=o.$instance)||void 0===t||null===(t=t.$binding)||void 0===t||null===(t=t.value)||void 0===t?void 0:t.pt,arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",v({},arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}))},ptmo:function(){return p._getPTValue(o.$instance,arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},!1)},cx:function(){var t,e;return null!==(t=o.$instance)&&void 0!==t&&t.isUnstyled?void 0:p._getOptionValue(null===(e=o.$instance)||void 0===e||null===(e=e.$css)||void 0===e?void 0:e.classes,arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",v({},arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}))},sx:function(){var t;return!(arguments.length>1&&void 0!==arguments[1])||arguments[1]?p._getOptionValue(null===(t=o.$instance)||void 0===t||null===(t=t.$css)||void 0===t?void 0:t.inlineStyles,arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",v({},arguments.length>2&&void 0!==arguments[2]?arguments[2]:{})):void 0}},g),o.$instance=o._$instances[n],null===(a=(s=o.$instance)[t])||void 0===a||a.call(s,o,l,r,u),p._hook(n,t,o,l,r,u)};return{created:function(t,e,n,i){o("created",t,e,n,i)},beforeMount:function(e,n,i,l){var r,u,c,a,s,v=null==n||null===(r=n.instance)||void 0===r||null===(r=r.$primevue)||void 0===r?void 0:r.config;t.loadBaseStyle(void 0,{nonce:null==v||null===(u=v.csp)||void 0===u?void 0:u.nonce}),(null===(c=e.$instance)||void 0===c||!c.isUnstyled)&&(null===(a=e.$instance)||void 0===a||null===(a=a.$css)||void 0===a||a.loadStyle(void 0,{nonce:null==v||null===(s=v.csp)||void 0===s?void 0:s.nonce})),o("beforeMount",e,n,i,l)},mounted:function(t,e,n,i){o("mounted",t,e,n,i)},beforeUpdate:function(t,e,n,i){o("beforeUpdate",t,e,n,i)},updated:function(t,e,n,i){o("updated",t,e,n,i)},beforeUnmount:function(t,e,n,i){o("beforeUnmount",t,e,n,i)},unmounted:function(t,e,n,i){o("unmounted",t,e,n,i)}}},extend:function(){var t=o(p._getMeta.apply(p,arguments),2),e=t[1];return v({extend:function(){var t=o(p._getMeta.apply(p,arguments),2),n=t[1];return p.extend(t[0],v(v(v({},e),null==e?void 0:e.methods),n))}},p._extend(t[0],e))}};return p}(primevue.base,primevue.utils,Vue);
|
package/blockui/BlockUI.d.ts
CHANGED
|
@@ -9,7 +9,8 @@
|
|
|
9
9
|
*/
|
|
10
10
|
import { VNode } from 'vue';
|
|
11
11
|
import { ComponentHooks } from '../basecomponent';
|
|
12
|
-
import {
|
|
12
|
+
import { PassThroughOptions } from '../passthrough';
|
|
13
|
+
import { ClassComponent, GlobalComponentConstructor, PassThrough } from '../ts-helpers';
|
|
13
14
|
|
|
14
15
|
export declare type BlockUIPassThroughOptionType = BlockUIPassThroughAttributes | ((options: BlockUIPassThroughMethodOptions) => BlockUIPassThroughAttributes | string) | string | null | undefined;
|
|
15
16
|
|
|
@@ -17,9 +18,22 @@ export declare type BlockUIPassThroughOptionType = BlockUIPassThroughAttributes
|
|
|
17
18
|
* Custom passthrough(pt) option method.
|
|
18
19
|
*/
|
|
19
20
|
export interface BlockUIPassThroughMethodOptions {
|
|
21
|
+
/**
|
|
22
|
+
* Defines instance.
|
|
23
|
+
*/
|
|
20
24
|
instance: any;
|
|
25
|
+
/**
|
|
26
|
+
* Defines valid properties.
|
|
27
|
+
*/
|
|
21
28
|
props: BlockUIProps;
|
|
29
|
+
/**
|
|
30
|
+
* Defines current inline state.
|
|
31
|
+
*/
|
|
22
32
|
state: BlockUIState;
|
|
33
|
+
/**
|
|
34
|
+
* Defines passthrough(pt) options in global config.
|
|
35
|
+
*/
|
|
36
|
+
global: object | undefined;
|
|
23
37
|
}
|
|
24
38
|
|
|
25
39
|
/**
|
|
@@ -88,7 +102,12 @@ export interface BlockUIProps {
|
|
|
88
102
|
* Used to pass attributes to DOM elements inside the component.
|
|
89
103
|
* @type {BlockUIPassThroughOptions}
|
|
90
104
|
*/
|
|
91
|
-
pt?:
|
|
105
|
+
pt?: PassThrough<BlockUIPassThroughOptions>;
|
|
106
|
+
/**
|
|
107
|
+
* Used to configure passthrough(pt) options of the component.
|
|
108
|
+
* @type {PassThroughOptions}
|
|
109
|
+
*/
|
|
110
|
+
ptOptions?: PassThroughOptions;
|
|
92
111
|
/**
|
|
93
112
|
* When enabled, it removes component related styles in the core.
|
|
94
113
|
* @defaultValue false
|
|
@@ -10,7 +10,8 @@
|
|
|
10
10
|
import { VNode } from 'vue';
|
|
11
11
|
import { ComponentHooks } from '../basecomponent';
|
|
12
12
|
import { MenuItem } from '../menuitem';
|
|
13
|
-
import {
|
|
13
|
+
import { PassThroughOptions } from '../passthrough';
|
|
14
|
+
import { ClassComponent, GlobalComponentConstructor, PassThrough } from '../ts-helpers';
|
|
14
15
|
|
|
15
16
|
export declare type BreadcrumbPassThroughOptionType = BreadcrumbPassThroughAttributes | ((options: BreadcrumbPassThroughMethodOptions) => BreadcrumbPassThroughAttributes | string) | string | null | undefined;
|
|
16
17
|
|
|
@@ -18,9 +19,22 @@ export declare type BreadcrumbPassThroughOptionType = BreadcrumbPassThroughAttri
|
|
|
18
19
|
* Custom passthrough(pt) option method.
|
|
19
20
|
*/
|
|
20
21
|
export interface BreadcrumbPassThroughMethodOptions {
|
|
22
|
+
/**
|
|
23
|
+
* Defines instance.
|
|
24
|
+
*/
|
|
21
25
|
instance: any;
|
|
26
|
+
/**
|
|
27
|
+
* Defines valid properties.
|
|
28
|
+
*/
|
|
22
29
|
props: BreadcrumbProps;
|
|
30
|
+
/**
|
|
31
|
+
* Defines current options.
|
|
32
|
+
*/
|
|
23
33
|
context: BreadcrumbContext;
|
|
34
|
+
/**
|
|
35
|
+
* Defines passthrough(pt) options in global config.
|
|
36
|
+
*/
|
|
37
|
+
global: object | undefined;
|
|
24
38
|
}
|
|
25
39
|
|
|
26
40
|
/**
|
|
@@ -88,6 +102,24 @@ export interface BreadcrumbContext {
|
|
|
88
102
|
index: number;
|
|
89
103
|
}
|
|
90
104
|
|
|
105
|
+
/**
|
|
106
|
+
* Defines valid router binding props in Breadcrumb component.
|
|
107
|
+
*/
|
|
108
|
+
export interface BreadcrumbRouterBindProps {
|
|
109
|
+
/**
|
|
110
|
+
* Action element binding
|
|
111
|
+
*/
|
|
112
|
+
action: object;
|
|
113
|
+
/**
|
|
114
|
+
* Icon element binding
|
|
115
|
+
*/
|
|
116
|
+
icon: object;
|
|
117
|
+
/**
|
|
118
|
+
* Label element binding
|
|
119
|
+
*/
|
|
120
|
+
label: object;
|
|
121
|
+
}
|
|
122
|
+
|
|
91
123
|
/**
|
|
92
124
|
* Defines valid properties in Breadcrumb component.
|
|
93
125
|
*/
|
|
@@ -117,7 +149,12 @@ export interface BreadcrumbProps {
|
|
|
117
149
|
* Used to pass attributes to DOM elements inside the component.
|
|
118
150
|
* @type {BreadcrumbPassThroughOptions}
|
|
119
151
|
*/
|
|
120
|
-
pt?:
|
|
152
|
+
pt?: PassThrough<BreadcrumbPassThroughOptions>;
|
|
153
|
+
/**
|
|
154
|
+
* Used to configure passthrough(pt) options of the component.
|
|
155
|
+
* @type {PassThroughOptions}
|
|
156
|
+
*/
|
|
157
|
+
ptOptions?: PassThroughOptions;
|
|
121
158
|
/**
|
|
122
159
|
* When enabled, it removes component related styles in the core.
|
|
123
160
|
* @defaultValue false
|
|
@@ -138,6 +175,14 @@ export interface BreadcrumbSlots {
|
|
|
138
175
|
* Menuitem instance
|
|
139
176
|
*/
|
|
140
177
|
item: MenuItem;
|
|
178
|
+
/**
|
|
179
|
+
* Label property of the menuitem
|
|
180
|
+
*/
|
|
181
|
+
label: string | ((...args: any) => string) | undefined;
|
|
182
|
+
/**
|
|
183
|
+
* Binding properties of the menuitem
|
|
184
|
+
*/
|
|
185
|
+
props: BreadcrumbRouterBindProps;
|
|
141
186
|
}): VNode[];
|
|
142
187
|
/**
|
|
143
188
|
* Custom separator template.
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<nav :class="cx('root')" v-bind="ptm('root')" data-pc-name="breadcrumb">
|
|
3
3
|
<ol :class="cx('menu')" v-bind="ptm('menu')">
|
|
4
|
-
<BreadcrumbItem v-if="home" :item="home" :class="cx('home')" :templates="$slots" :exact="exact" :pt="pt" v-bind="ptm('home')" />
|
|
4
|
+
<BreadcrumbItem v-if="home" :item="home" :class="cx('home')" :templates="$slots" :exact="exact" :pt="pt" :unstyled="unstyled" v-bind="ptm('home')" />
|
|
5
5
|
<template v-for="(item, i) of model" :key="item.label">
|
|
6
6
|
<li v-if="home || i !== 0" :class="cx('separator')" v-bind="ptm('separator')">
|
|
7
7
|
<slot name="separator">
|
|
8
8
|
<ChevronRightIcon aria-hidden="true" v-bind="ptm('separatorIcon')" />
|
|
9
9
|
</slot>
|
|
10
10
|
</li>
|
|
11
|
-
<BreadcrumbItem :item="item" :index="i" :templates="$slots" :exact="exact" :pt="pt" />
|
|
11
|
+
<BreadcrumbItem :item="item" :index="i" :templates="$slots" :exact="exact" :pt="pt" :unstyled="unstyled" />
|
|
12
12
|
</template>
|
|
13
13
|
</ol>
|
|
14
14
|
</nav>
|
|
@@ -22,6 +22,11 @@ import BreadcrumbItem from './BreadcrumbItem.vue';
|
|
|
22
22
|
export default {
|
|
23
23
|
name: 'Breadcrumb',
|
|
24
24
|
extends: BaseBreadcrumb,
|
|
25
|
+
beforeMount() {
|
|
26
|
+
if (!this.$slots.item) {
|
|
27
|
+
console.warn('In future versions, vue-router support will be removed. Item templating should be used.');
|
|
28
|
+
}
|
|
29
|
+
},
|
|
25
30
|
components: {
|
|
26
31
|
BreadcrumbItem: BreadcrumbItem,
|
|
27
32
|
ChevronRightIcon: ChevronRightIcon
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<li v-if="visible()" :class="[cx('menuitem'), item.class]" v-bind="ptm('menuitem', ptmOptions)">
|
|
3
|
-
<template v-if="!templates
|
|
3
|
+
<template v-if="!templates.item">
|
|
4
4
|
<router-link v-if="item.to" v-slot="{ navigate, href, isActive, isExactActive }" :to="item.to" custom>
|
|
5
5
|
<a :href="href" :class="cx('action', { isActive, isExactActive })" :aria-current="isCurrentUrl()" @click="onClick($event, navigate)" v-bind="ptm('action', ptmOptions)">
|
|
6
6
|
<component v-if="templates.itemicon" :is="templates.itemicon" :item="item" :class="cx('icon')" />
|
|
@@ -14,12 +14,13 @@
|
|
|
14
14
|
<span v-if="item.label" :class="cx('label')" v-bind="ptm('label', ptmOptions)">{{ label() }}</span>
|
|
15
15
|
</a>
|
|
16
16
|
</template>
|
|
17
|
-
<component v-else :is="templates.item" :item="item"></component>
|
|
17
|
+
<component v-else :is="templates.item" :item="item" :label="label()" :props="getMenuItemProps"></component>
|
|
18
18
|
</li>
|
|
19
19
|
</template>
|
|
20
20
|
|
|
21
21
|
<script>
|
|
22
22
|
import BaseComponent from 'primevue/basecomponent';
|
|
23
|
+
import { mergeProps } from 'vue';
|
|
23
24
|
|
|
24
25
|
export default {
|
|
25
26
|
name: 'BreadcrumbItem',
|
|
@@ -55,7 +56,7 @@ export default {
|
|
|
55
56
|
},
|
|
56
57
|
isCurrentUrl() {
|
|
57
58
|
const { to, url } = this.item;
|
|
58
|
-
|
|
59
|
+
const lastPath = typeof window !== 'undefined' ? window.location.pathname : '';
|
|
59
60
|
|
|
60
61
|
return to === lastPath || url === lastPath ? 'page' : undefined;
|
|
61
62
|
}
|
|
@@ -68,6 +69,30 @@ export default {
|
|
|
68
69
|
index: this.index
|
|
69
70
|
}
|
|
70
71
|
};
|
|
72
|
+
},
|
|
73
|
+
getMenuItemProps() {
|
|
74
|
+
return {
|
|
75
|
+
action: mergeProps(
|
|
76
|
+
{
|
|
77
|
+
class: this.cx('action'),
|
|
78
|
+
'aria-current': this.isCurrentUrl(),
|
|
79
|
+
onClick: ($event) => this.onClick($event)
|
|
80
|
+
},
|
|
81
|
+
this.ptm('action', this.ptmOptions)
|
|
82
|
+
),
|
|
83
|
+
icon: mergeProps(
|
|
84
|
+
{
|
|
85
|
+
class: [this.cx('icon'), this.item.icon]
|
|
86
|
+
},
|
|
87
|
+
this.ptm('icon', this.ptmOptions)
|
|
88
|
+
),
|
|
89
|
+
label: mergeProps(
|
|
90
|
+
{
|
|
91
|
+
class: this.cx('label')
|
|
92
|
+
},
|
|
93
|
+
this.ptm('label', this.ptmOptions)
|
|
94
|
+
)
|
|
95
|
+
};
|
|
71
96
|
}
|
|
72
97
|
}
|
|
73
98
|
};
|
|
@@ -102,7 +102,7 @@ var script$1 = {
|
|
|
102
102
|
var _this$item = this.item,
|
|
103
103
|
to = _this$item.to,
|
|
104
104
|
url = _this$item.url;
|
|
105
|
-
var lastPath =
|
|
105
|
+
var lastPath = typeof window !== 'undefined' ? window.location.pathname : '';
|
|
106
106
|
return to === lastPath || url === lastPath ? 'page' : undefined;
|
|
107
107
|
}
|
|
108
108
|
},
|
|
@@ -114,6 +114,24 @@ var script$1 = {
|
|
|
114
114
|
index: this.index
|
|
115
115
|
}
|
|
116
116
|
};
|
|
117
|
+
},
|
|
118
|
+
getMenuItemProps: function getMenuItemProps() {
|
|
119
|
+
var _this = this;
|
|
120
|
+
return {
|
|
121
|
+
action: vue.mergeProps({
|
|
122
|
+
"class": this.cx('action'),
|
|
123
|
+
'aria-current': this.isCurrentUrl(),
|
|
124
|
+
onClick: function onClick($event) {
|
|
125
|
+
return _this.onClick($event);
|
|
126
|
+
}
|
|
127
|
+
}, this.ptm('action', this.ptmOptions)),
|
|
128
|
+
icon: vue.mergeProps({
|
|
129
|
+
"class": [this.cx('icon'), this.item.icon]
|
|
130
|
+
}, this.ptm('icon', this.ptmOptions)),
|
|
131
|
+
label: vue.mergeProps({
|
|
132
|
+
"class": this.cx('label')
|
|
133
|
+
}, this.ptm('label', this.ptmOptions))
|
|
134
|
+
};
|
|
117
135
|
}
|
|
118
136
|
}
|
|
119
137
|
};
|
|
@@ -125,7 +143,7 @@ function render$1(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
125
143
|
return $options.visible() ? (vue.openBlock(), vue.createElementBlock("li", vue.mergeProps({
|
|
126
144
|
key: 0,
|
|
127
145
|
"class": [_ctx.cx('menuitem'), $props.item["class"]]
|
|
128
|
-
}, _ctx.ptm('menuitem', $options.ptmOptions)), [!$props.templates
|
|
146
|
+
}, _ctx.ptm('menuitem', $options.ptmOptions)), [!$props.templates.item ? (vue.openBlock(), vue.createElementBlock(vue.Fragment, {
|
|
129
147
|
key: 0
|
|
130
148
|
}, [$props.item.to ? (vue.openBlock(), vue.createBlock(_component_router_link, {
|
|
131
149
|
key: 0,
|
|
@@ -181,8 +199,10 @@ function render$1(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
181
199
|
"class": _ctx.cx('label')
|
|
182
200
|
}, _ctx.ptm('label', $options.ptmOptions)), vue.toDisplayString($options.label()), 17)) : vue.createCommentVNode("", true)], 16, _hoisted_2))], 64)) : (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent($props.templates.item), {
|
|
183
201
|
key: 1,
|
|
184
|
-
item: $props.item
|
|
185
|
-
|
|
202
|
+
item: $props.item,
|
|
203
|
+
label: $options.label(),
|
|
204
|
+
props: $options.getMenuItemProps
|
|
205
|
+
}, null, 8, ["item", "label", "props"]))], 16)) : vue.createCommentVNode("", true);
|
|
186
206
|
}
|
|
187
207
|
|
|
188
208
|
script$1.render = render$1;
|
|
@@ -190,6 +210,11 @@ script$1.render = render$1;
|
|
|
190
210
|
var script = {
|
|
191
211
|
name: 'Breadcrumb',
|
|
192
212
|
"extends": script$2,
|
|
213
|
+
beforeMount: function beforeMount() {
|
|
214
|
+
if (!this.$slots.item) {
|
|
215
|
+
console.warn('In future versions, vue-router support will be removed. Item templating should be used.');
|
|
216
|
+
}
|
|
217
|
+
},
|
|
193
218
|
components: {
|
|
194
219
|
BreadcrumbItem: script$1,
|
|
195
220
|
ChevronRightIcon: ChevronRightIcon__default["default"]
|
|
@@ -211,8 +236,9 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
211
236
|
"class": _ctx.cx('home'),
|
|
212
237
|
templates: _ctx.$slots,
|
|
213
238
|
exact: _ctx.exact,
|
|
214
|
-
pt: _ctx.pt
|
|
215
|
-
|
|
239
|
+
pt: _ctx.pt,
|
|
240
|
+
unstyled: _ctx.unstyled
|
|
241
|
+
}, _ctx.ptm('home')), null, 16, ["item", "class", "templates", "exact", "pt", "unstyled"])) : vue.createCommentVNode("", true), (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.model, function (item, i) {
|
|
216
242
|
return vue.openBlock(), vue.createElementBlock(vue.Fragment, {
|
|
217
243
|
key: item.label
|
|
218
244
|
}, [_ctx.home || i !== 0 ? (vue.openBlock(), vue.createElementBlock("li", vue.mergeProps({
|
|
@@ -227,8 +253,9 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
227
253
|
index: i,
|
|
228
254
|
templates: _ctx.$slots,
|
|
229
255
|
exact: _ctx.exact,
|
|
230
|
-
pt: _ctx.pt
|
|
231
|
-
|
|
256
|
+
pt: _ctx.pt,
|
|
257
|
+
unstyled: _ctx.unstyled
|
|
258
|
+
}, null, 8, ["item", "index", "templates", "exact", "pt", "unstyled"])], 64);
|
|
232
259
|
}), 128))], 16)], 16);
|
|
233
260
|
}
|
|
234
261
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e=require("primevue/icons/chevronright"),t=require("primevue/basecomponent"),n=require("primevue/usestyle"),o=require("vue");function
|
|
1
|
+
"use strict";var e=require("primevue/icons/chevronright"),t=require("primevue/basecomponent"),n=require("primevue/usestyle"),o=require("vue");function i(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var r=i(e),l=i(t),a=n.useStyle("\n.p-breadcrumb {\n overflow-x: auto;\n}\n\n.p-breadcrumb .p-breadcrumb-list {\n margin: 0;\n padding: 0;\n list-style-type: none;\n display: flex;\n align-items: center;\n flex-wrap: nowrap;\n}\n\n.p-breadcrumb .p-menuitem-text {\n line-height: 1;\n}\n\n.p-breadcrumb .p-menuitem-link {\n text-decoration: none;\n display: flex;\n align-items: center;\n}\n\n.p-breadcrumb .p-menuitem-separator {\n display: flex;\n align-items: center;\n}\n\n.p-breadcrumb::-webkit-scrollbar {\n display: none;\n}\n",{name:"breadcrumb",manual:!0}),m={name:"BaseBreadcrumb",extends:l.default,props:{model:{type:Array,default:null},home:{type:null,default:null},exact:{type:Boolean,default:!0}},css:{classes:{root:"p-breadcrumb p-component",menu:"p-breadcrumb-list",home:"p-breadcrumb-home",separator:"p-menuitem-separator",menuitem:function(e){return["p-menuitem",{"p-disabled":e.instance.disabled()}]},action:function(e){return["p-menuitem-link",{"router-link-active":e.isActive,"router-link-active-exact":e.props.exact&&e.isExactActive}]},icon:"p-menuitem-icon",label:"p-menuitem-text"},loadStyle:a.load},provide:function(){return{$parentInstance:this}}},c={name:"BreadcrumbItem",hostName:"Breadcrumb",extends:l.default,props:{item:null,templates:null,exact:null,index:null},methods:{onClick:function(e,t){this.item.command&&this.item.command({originalEvent:e,item:this.item}),this.item.to&&t&&t(e)},visible:function(){return"function"==typeof this.item.visible?this.item.visible():!1!==this.item.visible},disabled:function(){return"function"==typeof this.item.disabled?this.item.disabled():this.item.disabled},label:function(){return"function"==typeof this.item.label?this.item.label():this.item.label},isCurrentUrl:function(){var e=this.item,t="undefined"!=typeof window?window.location.pathname:"";return e.to===t||e.url===t?"page":void 0}},computed:{ptmOptions:function(){return{context:{item:this.item,index:this.index}}},getMenuItemProps:function(){var e=this;return{action:o.mergeProps({class:this.cx("action"),"aria-current":this.isCurrentUrl(),onClick:function(t){return e.onClick(t)}},this.ptm("action",this.ptmOptions)),icon:o.mergeProps({class:[this.cx("icon"),this.item.icon]},this.ptm("icon",this.ptmOptions)),label:o.mergeProps({class:this.cx("label")},this.ptm("label",this.ptmOptions))}}}},s=["href","aria-current","onClick"],p=["href","target","aria-current"];c.render=function(e,t,n,i,r,l){var a=o.resolveComponent("router-link");return l.visible()?(o.openBlock(),o.createElementBlock("li",o.mergeProps({key:0,class:[e.cx("menuitem"),n.item.class]},e.ptm("menuitem",l.ptmOptions)),[n.templates.item?(o.openBlock(),o.createBlock(o.resolveDynamicComponent(n.templates.item),{key:1,item:n.item,label:l.label(),props:l.getMenuItemProps},null,8,["item","label","props"])):(o.openBlock(),o.createElementBlock(o.Fragment,{key:0},[n.item.to?(o.openBlock(),o.createBlock(a,{key:0,to:n.item.to,custom:""},{default:o.withCtx((function(t){var i=t.navigate;return[o.createElementVNode("a",o.mergeProps({href:t.href,class:e.cx("action",{isActive:t.isActive,isExactActive:t.isExactActive}),"aria-current":l.isCurrentUrl(),onClick:function(e){return l.onClick(e,i)}},e.ptm("action",l.ptmOptions)),[n.templates.itemicon?(o.openBlock(),o.createBlock(o.resolveDynamicComponent(n.templates.itemicon),{key:0,item:n.item,class:o.normalizeClass(e.cx("icon"))},null,8,["item","class"])):n.item.icon?(o.openBlock(),o.createElementBlock("span",o.mergeProps({key:1,class:[e.cx("icon"),n.item.icon]},e.ptm("icon",l.ptmOptions)),null,16)):o.createCommentVNode("",!0),n.item.label?(o.openBlock(),o.createElementBlock("span",o.mergeProps({key:2,class:e.cx("label")},e.ptm("label",l.ptmOptions)),o.toDisplayString(l.label()),17)):o.createCommentVNode("",!0)],16,s)]})),_:1},8,["to"])):(o.openBlock(),o.createElementBlock("a",o.mergeProps({key:1,href:n.item.url||"#",class:e.cx("action"),target:n.item.target,"aria-current":l.isCurrentUrl(),onClick:t[0]||(t[0]=function(){return l.onClick&&l.onClick.apply(l,arguments)})},e.ptm("action",l.ptmOptions)),[n.templates&&n.templates.itemicon?(o.openBlock(),o.createBlock(o.resolveDynamicComponent(n.templates.itemicon),{key:0,item:n.item,class:o.normalizeClass(e.cx("icon",l.ptmOptions))},null,8,["item","class"])):n.item.icon?(o.openBlock(),o.createElementBlock("span",o.mergeProps({key:1,class:[e.cx("icon"),n.item.icon]},e.ptm("icon",l.ptmOptions)),null,16)):o.createCommentVNode("",!0),n.item.label?(o.openBlock(),o.createElementBlock("span",o.mergeProps({key:2,class:e.cx("label")},e.ptm("label",l.ptmOptions)),o.toDisplayString(l.label()),17)):o.createCommentVNode("",!0)],16,p))],64))],16)):o.createCommentVNode("",!0)};var u={name:"Breadcrumb",extends:m,beforeMount:function(){this.$slots.item||console.warn("In future versions, vue-router support will be removed. Item templating should be used.")},components:{BreadcrumbItem:c,ChevronRightIcon:r.default}};u.render=function(e,t,n,i,r,l){var a=o.resolveComponent("BreadcrumbItem"),m=o.resolveComponent("ChevronRightIcon");return o.openBlock(),o.createElementBlock("nav",o.mergeProps({class:e.cx("root")},e.ptm("root"),{"data-pc-name":"breadcrumb"}),[o.createElementVNode("ol",o.mergeProps({class:e.cx("menu")},e.ptm("menu")),[e.home?(o.openBlock(),o.createBlock(a,o.mergeProps({key:0,item:e.home,class:e.cx("home"),templates:e.$slots,exact:e.exact,pt:e.pt,unstyled:e.unstyled},e.ptm("home")),null,16,["item","class","templates","exact","pt","unstyled"])):o.createCommentVNode("",!0),(o.openBlock(!0),o.createElementBlock(o.Fragment,null,o.renderList(e.model,(function(t,n){return o.openBlock(),o.createElementBlock(o.Fragment,{key:t.label},[e.home||0!==n?(o.openBlock(),o.createElementBlock("li",o.mergeProps({key:0,class:e.cx("separator")},e.ptm("separator")),[o.renderSlot(e.$slots,"separator",{},(function(){return[o.createVNode(m,o.mergeProps({"aria-hidden":"true"},e.ptm("separatorIcon")),null,16)]}))],16)):o.createCommentVNode("",!0),o.createVNode(a,{item:t,index:n,templates:e.$slots,exact:e.exact,pt:e.pt,unstyled:e.unstyled},null,8,["item","index","templates","exact","pt","unstyled"])],64)})),128))],16)],16)},module.exports=u;
|