primevue 3.8.2 → 3.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/accordion/Accordion.d.ts +74 -11
- package/accordion/accordion.esm.js +1 -1
- package/accordion/accordion.esm.min.js +1 -1
- package/accordion/accordion.js +1 -1
- package/accordiontab/AccordionTab.d.ts +37 -8
- package/accordiontab/accordiontab.esm.js +1 -1
- package/accordiontab/accordiontab.esm.min.js +1 -1
- package/accordiontab/accordiontab.js +1 -1
- package/api/Api.d.ts +292 -251
- package/api/api.cjs.js +66 -32
- package/api/api.cjs.min.js +1 -1
- package/api/api.esm.js +66 -32
- package/api/api.esm.min.js +1 -1
- package/api/api.js +67 -33
- package/api/api.min.js +1 -1
- package/autocomplete/AutoComplete.d.ts +280 -63
- package/autocomplete/AutoComplete.vue +16 -9
- package/autocomplete/autocomplete.cjs.js +23 -15
- package/autocomplete/autocomplete.cjs.min.js +1 -1
- package/autocomplete/autocomplete.esm.js +20 -12
- package/autocomplete/autocomplete.esm.min.js +1 -1
- package/autocomplete/autocomplete.js +24 -16
- package/autocomplete/autocomplete.min.js +1 -1
- package/avatar/Avatar.d.ts +57 -8
- package/avatar/avatar.esm.js +1 -1
- package/avatar/avatar.esm.min.js +1 -1
- package/avatar/avatar.js +1 -1
- package/avatargroup/AvatarGroup.d.ts +29 -3
- package/avatargroup/avatargroup.esm.js +1 -1
- package/avatargroup/avatargroup.esm.min.js +1 -1
- package/avatargroup/avatargroup.js +1 -1
- package/badge/Badge.d.ts +46 -5
- package/badge/badge.esm.js +1 -1
- package/badge/badge.esm.min.js +1 -1
- package/badge/badge.js +1 -1
- package/badgedirective/badgedirective.esm.js +1 -1
- package/badgedirective/badgedirective.esm.min.js +1 -1
- package/badgedirective/badgedirective.js +1 -1
- package/blockui/BlockUI.d.ts +52 -11
- package/blockui/blockui.esm.js +1 -1
- package/blockui/blockui.esm.min.js +1 -1
- package/blockui/blockui.js +1 -1
- package/breadcrumb/Breadcrumb.d.ts +49 -9
- package/breadcrumb/BreadcrumbItem.vue +5 -2
- package/breadcrumb/breadcrumb.cjs.js +5 -2
- package/breadcrumb/breadcrumb.cjs.min.js +1 -1
- package/breadcrumb/breadcrumb.esm.js +6 -3
- package/breadcrumb/breadcrumb.esm.min.js +1 -1
- package/breadcrumb/breadcrumb.js +6 -3
- package/breadcrumb/breadcrumb.min.js +1 -1
- package/button/Button.d.ts +68 -11
- package/button/button.cjs.js +1 -1
- package/button/button.esm.js +1 -1
- package/button/button.esm.min.js +1 -1
- package/button/button.js +2 -2
- package/calendar/Calendar.d.ts +320 -58
- package/calendar/Calendar.vue +406 -84
- package/calendar/calendar.cjs.js +521 -204
- package/calendar/calendar.cjs.min.js +1 -1
- package/calendar/calendar.esm.js +521 -203
- package/calendar/calendar.esm.min.js +1 -1
- package/calendar/calendar.js +523 -205
- package/calendar/calendar.min.js +1 -1
- package/card/Card.d.ts +43 -9
- package/card/card.esm.js +1 -1
- package/card/card.esm.min.js +1 -1
- package/card/card.js +1 -1
- package/carousel/Carousel.d.ts +121 -24
- package/carousel/Carousel.vue +2 -2
- package/carousel/carousel.cjs.js +7 -7
- package/carousel/carousel.cjs.min.js +1 -1
- package/carousel/carousel.esm.js +7 -7
- package/carousel/carousel.esm.min.js +1 -1
- package/carousel/carousel.js +8 -8
- package/carousel/carousel.min.js +1 -1
- package/cascadeselect/CascadeSelect.d.ts +172 -35
- package/cascadeselect/cascadeselect.cjs.js +2 -2
- package/cascadeselect/cascadeselect.esm.js +1 -1
- package/cascadeselect/cascadeselect.esm.min.js +1 -1
- package/cascadeselect/cascadeselect.js +3 -3
- package/chart/Chart.d.ts +104 -12
- package/chart/Chart.vue +18 -4
- package/chart/chart.cjs.js +20 -8
- package/chart/chart.cjs.min.js +1 -1
- package/chart/chart.esm.js +19 -5
- package/chart/chart.esm.min.js +1 -1
- package/chart/chart.js +19 -5
- package/chart/chart.min.js +1 -1
- package/checkbox/Checkbox.d.ts +66 -8
- package/checkbox/checkbox.esm.js +1 -1
- package/checkbox/checkbox.esm.min.js +1 -1
- package/checkbox/checkbox.js +1 -1
- package/chip/Chip.d.ts +50 -4
- package/chip/chip.esm.js +1 -1
- package/chip/chip.esm.min.js +1 -1
- package/chip/chip.js +1 -1
- package/chips/Chips.d.ts +88 -15
- package/chips/chips.esm.js +1 -1
- package/chips/chips.esm.min.js +1 -1
- package/chips/chips.js +1 -1
- package/colorpicker/ColorPicker.d.ts +105 -13
- package/colorpicker/ColorPicker.vue +6 -1
- package/colorpicker/colorpicker.cjs.js +7 -2
- package/colorpicker/colorpicker.cjs.min.js +1 -1
- package/colorpicker/colorpicker.esm.js +7 -2
- package/colorpicker/colorpicker.esm.min.js +1 -1
- package/colorpicker/colorpicker.js +8 -3
- package/colorpicker/colorpicker.min.js +1 -1
- package/column/Column.d.ts +448 -78
- package/column/column.esm.js +1 -1
- package/column/column.esm.min.js +1 -1
- package/column/column.js +1 -1
- package/columngroup/ColumnGroup.d.ts +30 -4
- package/columngroup/columngroup.esm.js +1 -1
- package/columngroup/columngroup.esm.min.js +1 -1
- package/columngroup/columngroup.js +1 -1
- package/config/config.cjs.js +1 -1
- package/config/config.esm.js +1 -2
- package/config/config.esm.min.js +1 -1
- package/config/config.js +2 -2
- package/confirmationeventbus/confirmationeventbus.esm.js +1 -1
- package/confirmationeventbus/confirmationeventbus.esm.min.js +1 -1
- package/confirmationeventbus/confirmationeventbus.js +1 -1
- package/confirmationoptions/ConfirmationOptions.d.ts +58 -0
- package/confirmationoptions/package.json +3 -0
- package/confirmationservice/ConfirmationService.d.ts +2 -1
- package/confirmationservice/confirmationservice.cjs.js +2 -2
- package/confirmationservice/confirmationservice.esm.js +1 -1
- package/confirmationservice/confirmationservice.esm.min.js +1 -1
- package/confirmationservice/confirmationservice.js +3 -3
- package/confirmdialog/ConfirmDialog.d.ts +57 -5
- package/confirmdialog/ConfirmDialog.vue +8 -2
- package/confirmdialog/confirmdialog.cjs.js +17 -10
- package/confirmdialog/confirmdialog.cjs.min.js +1 -1
- package/confirmdialog/confirmdialog.esm.js +12 -5
- package/confirmdialog/confirmdialog.esm.min.js +1 -1
- package/confirmdialog/confirmdialog.js +18 -11
- package/confirmdialog/confirmdialog.min.js +1 -1
- package/confirmpopup/ConfirmPopup.d.ts +41 -3
- package/confirmpopup/ConfirmPopup.vue +7 -4
- package/confirmpopup/confirmpopup.cjs.js +19 -11
- package/confirmpopup/confirmpopup.cjs.min.js +1 -1
- package/confirmpopup/confirmpopup.esm.js +15 -7
- package/confirmpopup/confirmpopup.esm.min.js +1 -1
- package/confirmpopup/confirmpopup.js +20 -12
- package/confirmpopup/confirmpopup.min.js +1 -1
- package/contextmenu/ContextMenu.d.ts +88 -16
- package/contextmenu/ContextMenuSub.vue +7 -4
- package/contextmenu/contextmenu.cjs.js +8 -5
- package/contextmenu/contextmenu.cjs.min.js +1 -1
- package/contextmenu/contextmenu.esm.js +8 -5
- package/contextmenu/contextmenu.esm.min.js +1 -1
- package/contextmenu/contextmenu.js +9 -6
- package/contextmenu/contextmenu.min.js +1 -1
- package/core/core.js +861 -383
- package/core/core.min.js +15 -13
- package/datatable/BodyCell.vue +27 -1
- package/datatable/ColumnFilter.vue +17 -6
- package/datatable/DataTable.d.ts +1056 -130
- package/datatable/DataTable.vue +150 -131
- package/datatable/HeaderCheckbox.vue +5 -2
- package/datatable/RowCheckbox.vue +1 -1
- package/datatable/RowRadioButton.vue +1 -1
- package/datatable/TableBody.vue +57 -14
- package/datatable/TableFooter.vue +15 -1
- package/datatable/TableHeader.vue +15 -1
- package/datatable/datatable.cjs.js +542 -381
- package/datatable/datatable.cjs.min.js +1 -1
- package/datatable/datatable.esm.js +533 -373
- package/datatable/datatable.esm.min.js +1 -1
- package/datatable/datatable.js +543 -383
- package/datatable/datatable.min.js +1 -1
- package/dataview/DataView.d.ts +198 -32
- package/dataview/DataView.vue +8 -8
- package/dataview/dataview.cjs.js +13 -13
- package/dataview/dataview.cjs.min.js +1 -1
- package/dataview/dataview.esm.js +13 -13
- package/dataview/dataview.esm.min.js +1 -1
- package/dataview/dataview.js +14 -14
- package/dataview/dataview.min.js +1 -1
- package/dataviewlayoutoptions/DataViewLayoutOptions.d.ts +34 -5
- package/dataviewlayoutoptions/dataviewlayoutoptions.esm.js +1 -1
- package/dataviewlayoutoptions/dataviewlayoutoptions.esm.min.js +1 -1
- package/dataviewlayoutoptions/dataviewlayoutoptions.js +1 -1
- package/deferredcontent/DeferredContent.d.ts +31 -6
- package/deferredcontent/deferredcontent.esm.js +1 -1
- package/deferredcontent/deferredcontent.esm.min.js +1 -1
- package/deferredcontent/deferredcontent.js +1 -1
- package/dialog/Dialog.d.ts +187 -34
- package/dialog/Dialog.vue +1 -1
- package/dialog/dialog.cjs.js +2 -3
- package/dialog/dialog.cjs.min.js +1 -1
- package/dialog/dialog.esm.js +2 -3
- package/dialog/dialog.esm.min.js +1 -1
- package/dialog/dialog.js +3 -4
- package/dialog/dialog.min.js +1 -1
- package/divider/Divider.d.ts +53 -8
- package/divider/divider.esm.js +1 -1
- package/divider/divider.esm.min.js +1 -1
- package/divider/divider.js +1 -1
- package/dock/Dock.d.ts +92 -15
- package/dock/DockSub.vue +3 -1
- package/dock/dock.cjs.js +4 -1
- package/dock/dock.cjs.min.js +1 -1
- package/dock/dock.esm.js +4 -2
- package/dock/dock.esm.min.js +1 -1
- package/dock/dock.js +5 -3
- package/dock/dock.min.js +1 -1
- package/dropdown/Dropdown.d.ts +340 -76
- package/dropdown/Dropdown.vue +1 -1
- package/dropdown/dropdown.cjs.js +4 -4
- package/dropdown/dropdown.cjs.min.js +1 -1
- package/dropdown/dropdown.esm.js +2 -2
- package/dropdown/dropdown.esm.min.js +1 -1
- package/dropdown/dropdown.js +5 -5
- package/dropdown/dropdown.min.js +1 -1
- package/editor/Editor.d.ts +78 -11
- package/editor/editor.cjs.js +1 -1
- package/editor/editor.esm.js +1 -1
- package/editor/editor.esm.min.js +1 -1
- package/editor/editor.js +2 -2
- package/fieldset/Fieldset.d.ts +63 -11
- package/fieldset/fieldset.cjs.js +1 -1
- package/fieldset/fieldset.esm.js +1 -1
- package/fieldset/fieldset.esm.min.js +1 -1
- package/fieldset/fieldset.js +2 -2
- package/fileupload/FileUpload.d.ts +255 -37
- package/fileupload/fileupload.cjs.js +4 -4
- package/fileupload/fileupload.esm.js +1 -1
- package/fileupload/fileupload.esm.min.js +1 -1
- package/fileupload/fileupload.js +5 -5
- package/fullcalendar/FullCalendar.d.ts +29 -3
- package/fullcalendar/fullcalendar.esm.js +1 -1
- package/fullcalendar/fullcalendar.esm.min.js +1 -1
- package/fullcalendar/fullcalendar.js +1 -1
- package/galleria/Galleria.d.ts +196 -46
- package/galleria/galleria.cjs.js +3 -3
- package/galleria/galleria.esm.js +1 -1
- package/galleria/galleria.esm.min.js +1 -1
- package/galleria/galleria.js +4 -4
- package/image/Image.d.ts +51 -6
- package/image/image.esm.js +1 -1
- package/image/image.esm.min.js +1 -1
- package/image/image.js +1 -1
- package/inlinemessage/InlineMessage.d.ts +34 -6
- package/inlinemessage/inlinemessage.esm.js +1 -1
- package/inlinemessage/inlinemessage.esm.min.js +1 -1
- package/inlinemessage/inlinemessage.js +1 -1
- package/inplace/Inplace.d.ts +57 -12
- package/inplace/inplace.cjs.js +1 -1
- package/inplace/inplace.esm.js +1 -1
- package/inplace/inplace.esm.min.js +1 -1
- package/inplace/inplace.js +2 -2
- package/inputmask/InputMask.d.ts +75 -15
- package/inputmask/inputmask.esm.js +1 -1
- package/inputmask/inputmask.esm.min.js +1 -1
- package/inputmask/inputmask.js +1 -1
- package/inputnumber/InputNumber.d.ts +180 -30
- package/inputnumber/InputNumber.vue +19 -3
- package/inputnumber/inputnumber.cjs.js +21 -5
- package/inputnumber/inputnumber.cjs.min.js +1 -1
- package/inputnumber/inputnumber.esm.js +20 -4
- package/inputnumber/inputnumber.esm.min.js +1 -1
- package/inputnumber/inputnumber.js +22 -6
- package/inputnumber/inputnumber.min.js +1 -1
- package/inputswitch/InputSwitch.d.ts +61 -9
- package/inputswitch/inputswitch.esm.js +1 -1
- package/inputswitch/inputswitch.esm.min.js +1 -1
- package/inputswitch/inputswitch.js +1 -1
- package/inputtext/InputText.d.ts +34 -5
- package/inputtext/InputText.vue +1 -1
- package/inputtext/inputtext.cjs.js +2 -2
- package/inputtext/inputtext.cjs.min.js +1 -1
- package/inputtext/inputtext.esm.js +4 -4
- package/inputtext/inputtext.esm.min.js +1 -1
- package/inputtext/inputtext.js +3 -3
- package/inputtext/inputtext.min.js +1 -1
- package/knob/Knob.d.ts +92 -18
- package/knob/knob.esm.js +1 -1
- package/knob/knob.esm.min.js +1 -1
- package/knob/knob.js +1 -1
- package/listbox/Listbox.d.ts +246 -56
- package/listbox/listbox.cjs.js +2 -2
- package/listbox/listbox.esm.js +1 -1
- package/listbox/listbox.esm.min.js +1 -1
- package/listbox/listbox.js +3 -3
- package/megamenu/MegaMenu.d.ts +60 -12
- package/megamenu/MegaMenu.vue +10 -7
- package/megamenu/megamenu.cjs.js +11 -8
- package/megamenu/megamenu.cjs.min.js +1 -1
- package/megamenu/megamenu.esm.js +11 -8
- package/megamenu/megamenu.esm.min.js +1 -1
- package/megamenu/megamenu.js +12 -9
- package/megamenu/megamenu.min.js +1 -1
- package/menu/Menu.d.ts +84 -15
- package/menu/Menu.vue +6 -3
- package/menu/Menuitem.vue +5 -2
- package/menu/menu.cjs.js +13 -7
- package/menu/menu.cjs.min.js +1 -1
- package/menu/menu.esm.js +12 -6
- package/menu/menu.esm.min.js +1 -1
- package/menu/menu.js +14 -8
- package/menu/menu.min.js +1 -1
- package/menubar/Menubar.d.ts +52 -11
- package/menubar/Menubar.vue +1 -0
- package/menubar/MenubarSub.vue +7 -4
- package/menubar/menubar.cjs.js +9 -6
- package/menubar/menubar.cjs.min.js +1 -1
- package/menubar/menubar.esm.js +9 -6
- package/menubar/menubar.esm.min.js +1 -1
- package/menubar/menubar.js +10 -7
- package/menubar/menubar.min.js +1 -1
- package/menuitem/MenuItem.d.ts +82 -0
- package/menuitem/package.json +3 -0
- package/message/Message.d.ts +57 -10
- package/message/Message.vue +6 -2
- package/message/message.cjs.js +7 -3
- package/message/message.cjs.min.js +1 -1
- package/message/message.esm.js +7 -3
- package/message/message.esm.min.js +1 -1
- package/message/message.js +8 -4
- package/message/message.min.js +1 -1
- package/multiselect/MultiSelect.d.ts +368 -83
- package/multiselect/multiselect.cjs.js +3 -3
- package/multiselect/multiselect.esm.js +1 -1
- package/multiselect/multiselect.esm.min.js +1 -1
- package/multiselect/multiselect.js +4 -4
- package/orderlist/OrderList.d.ts +122 -17
- package/orderlist/OrderList.vue +2 -0
- package/orderlist/orderlist.cjs.js +5 -3
- package/orderlist/orderlist.cjs.min.js +1 -1
- package/orderlist/orderlist.esm.js +4 -2
- package/orderlist/orderlist.esm.min.js +1 -1
- package/orderlist/orderlist.js +6 -4
- package/orderlist/orderlist.min.js +1 -1
- package/organizationchart/OrganizationChart.d.ts +137 -15
- package/organizationchart/OrganizationChart.vue +1 -0
- package/organizationchart/organizationchart.cjs.js +1 -1
- package/organizationchart/organizationchart.cjs.min.js +1 -1
- package/organizationchart/organizationchart.esm.js +2 -2
- package/organizationchart/organizationchart.esm.min.js +1 -1
- package/organizationchart/organizationchart.js +2 -2
- package/organizationchart/organizationchart.min.js +1 -1
- package/overlayeventbus/overlayeventbus.esm.js +1 -1
- package/overlayeventbus/overlayeventbus.esm.min.js +1 -1
- package/overlayeventbus/overlayeventbus.js +1 -1
- package/overlaypanel/OverlayPanel.d.ts +107 -12
- package/overlaypanel/overlaypanel.cjs.js +5 -5
- package/overlaypanel/overlaypanel.esm.js +1 -1
- package/overlaypanel/overlaypanel.esm.min.js +1 -1
- package/overlaypanel/overlaypanel.js +6 -6
- package/package.json +5 -1
- package/paginator/Paginator.d.ts +129 -27
- package/paginator/Paginator.vue +4 -4
- package/paginator/paginator.cjs.js +12 -12
- package/paginator/paginator.cjs.min.js +1 -1
- package/paginator/paginator.esm.js +5 -5
- package/paginator/paginator.esm.min.js +1 -1
- package/paginator/paginator.js +13 -13
- package/paginator/paginator.min.js +1 -1
- package/panel/Panel.d.ts +64 -8
- package/panel/Panel.vue +1 -1
- package/panel/panel.cjs.js +1 -1
- package/panel/panel.esm.js +1 -1
- package/panel/panel.esm.min.js +1 -1
- package/panel/panel.js +2 -2
- package/panelmenu/PanelMenu.d.ts +59 -11
- package/panelmenu/PanelMenu.vue +8 -5
- package/panelmenu/PanelMenuSub.vue +8 -5
- package/panelmenu/panelmenu.cjs.js +18 -12
- package/panelmenu/panelmenu.cjs.min.js +1 -1
- package/panelmenu/panelmenu.esm.js +19 -13
- package/panelmenu/panelmenu.esm.min.js +1 -1
- package/panelmenu/panelmenu.js +19 -13
- package/panelmenu/panelmenu.min.js +1 -1
- package/password/Password.d.ts +115 -24
- package/password/password.cjs.js +2 -2
- package/password/password.esm.js +1 -1
- package/password/password.esm.min.js +1 -1
- package/password/password.js +3 -3
- package/picklist/PickList.d.ts +199 -26
- package/picklist/PickList.vue +10 -4
- package/picklist/picklist.cjs.js +15 -9
- package/picklist/picklist.cjs.min.js +1 -1
- package/picklist/picklist.esm.js +14 -8
- package/picklist/picklist.esm.min.js +1 -1
- package/picklist/picklist.js +16 -10
- package/picklist/picklist.min.js +1 -1
- package/progressbar/ProgressBar.d.ts +43 -8
- package/progressbar/ProgressBar.vue +13 -12
- package/progressbar/progressbar.cjs.js +13 -12
- package/progressbar/progressbar.cjs.min.js +1 -1
- package/progressbar/progressbar.esm.js +15 -14
- package/progressbar/progressbar.esm.min.js +1 -1
- package/progressbar/progressbar.js +14 -13
- package/progressbar/progressbar.min.js +1 -1
- package/progressspinner/ProgressSpinner.d.ts +39 -6
- package/progressspinner/progressspinner.esm.js +1 -1
- package/progressspinner/progressspinner.esm.min.js +1 -1
- package/progressspinner/progressspinner.js +1 -1
- package/radiobutton/RadioButton.d.ts +52 -7
- package/radiobutton/radiobutton.esm.js +1 -1
- package/radiobutton/radiobutton.esm.min.js +1 -1
- package/radiobutton/radiobutton.js +1 -1
- package/rating/Rating.d.ts +67 -10
- package/rating/Rating.vue +1 -1
- package/rating/rating.cjs.js +1 -1
- package/rating/rating.cjs.min.js +1 -1
- package/rating/rating.esm.js +2 -2
- package/rating/rating.esm.min.js +1 -1
- package/rating/rating.js +2 -2
- package/rating/rating.min.js +1 -1
- package/resources/primevue.css +5 -0
- package/resources/primevue.min.css +1 -1
- package/resources/themes/arya-blue/theme.css +81 -33
- package/resources/themes/arya-green/theme.css +81 -33
- package/resources/themes/arya-orange/theme.css +81 -33
- package/resources/themes/arya-purple/theme.css +81 -33
- package/resources/themes/bootstrap4-dark-blue/theme.css +62 -21
- package/resources/themes/bootstrap4-dark-purple/theme.css +62 -21
- package/resources/themes/bootstrap4-light-blue/theme.css +62 -21
- package/resources/themes/bootstrap4-light-purple/theme.css +62 -21
- package/resources/themes/fluent-light/theme.css +81 -33
- package/resources/themes/lara-dark-blue/fonts/Inter-Bold.woff +0 -0
- package/resources/themes/lara-dark-blue/fonts/Inter-Bold.woff2 +0 -0
- package/resources/themes/lara-dark-blue/fonts/Inter-Light.woff +0 -0
- package/resources/themes/lara-dark-blue/fonts/Inter-Light.woff2 +0 -0
- package/resources/themes/lara-dark-blue/fonts/Inter-Medium.woff +0 -0
- package/resources/themes/lara-dark-blue/fonts/Inter-Medium.woff2 +0 -0
- package/resources/themes/lara-dark-blue/fonts/Inter-Regular.woff +0 -0
- package/resources/themes/lara-dark-blue/fonts/Inter-Regular.woff2 +0 -0
- package/resources/themes/lara-dark-blue/fonts/Inter-SemiBold.woff +0 -0
- package/resources/themes/lara-dark-blue/fonts/Inter-SemiBold.woff2 +0 -0
- package/resources/themes/lara-dark-blue/theme.css +5421 -0
- package/resources/themes/lara-dark-indigo/fonts/Inter-Bold.woff +0 -0
- package/resources/themes/lara-dark-indigo/fonts/Inter-Bold.woff2 +0 -0
- package/resources/themes/lara-dark-indigo/fonts/Inter-Light.woff +0 -0
- package/resources/themes/lara-dark-indigo/fonts/Inter-Light.woff2 +0 -0
- package/resources/themes/lara-dark-indigo/fonts/Inter-Medium.woff +0 -0
- package/resources/themes/lara-dark-indigo/fonts/Inter-Medium.woff2 +0 -0
- package/resources/themes/lara-dark-indigo/fonts/Inter-Regular.woff +0 -0
- package/resources/themes/lara-dark-indigo/fonts/Inter-Regular.woff2 +0 -0
- package/resources/themes/lara-dark-indigo/fonts/Inter-SemiBold.woff +0 -0
- package/resources/themes/lara-dark-indigo/fonts/Inter-SemiBold.woff2 +0 -0
- package/resources/themes/lara-dark-indigo/theme.css +5421 -0
- package/resources/themes/lara-dark-purple/fonts/Inter-Bold.woff +0 -0
- package/resources/themes/lara-dark-purple/fonts/Inter-Bold.woff2 +0 -0
- package/resources/themes/lara-dark-purple/fonts/Inter-Light.woff +0 -0
- package/resources/themes/lara-dark-purple/fonts/Inter-Light.woff2 +0 -0
- package/resources/themes/lara-dark-purple/fonts/Inter-Medium.woff +0 -0
- package/resources/themes/lara-dark-purple/fonts/Inter-Medium.woff2 +0 -0
- package/resources/themes/lara-dark-purple/fonts/Inter-Regular.woff +0 -0
- package/resources/themes/lara-dark-purple/fonts/Inter-Regular.woff2 +0 -0
- package/resources/themes/lara-dark-purple/fonts/Inter-SemiBold.woff +0 -0
- package/resources/themes/lara-dark-purple/fonts/Inter-SemiBold.woff2 +0 -0
- package/resources/themes/lara-dark-purple/theme.css +5421 -0
- package/resources/themes/lara-dark-teal/fonts/Inter-Bold.woff +0 -0
- package/resources/themes/lara-dark-teal/fonts/Inter-Bold.woff2 +0 -0
- package/resources/themes/lara-dark-teal/fonts/Inter-Light.woff +0 -0
- package/resources/themes/lara-dark-teal/fonts/Inter-Light.woff2 +0 -0
- package/resources/themes/lara-dark-teal/fonts/Inter-Medium.woff +0 -0
- package/resources/themes/lara-dark-teal/fonts/Inter-Medium.woff2 +0 -0
- package/resources/themes/lara-dark-teal/fonts/Inter-Regular.woff +0 -0
- package/resources/themes/lara-dark-teal/fonts/Inter-Regular.woff2 +0 -0
- package/resources/themes/lara-dark-teal/fonts/Inter-SemiBold.woff +0 -0
- package/resources/themes/lara-dark-teal/fonts/Inter-SemiBold.woff2 +0 -0
- package/resources/themes/lara-dark-teal/theme.css +5421 -0
- package/resources/themes/lara-light-blue/fonts/Inter-Bold.woff +0 -0
- package/resources/themes/lara-light-blue/fonts/Inter-Bold.woff2 +0 -0
- package/resources/themes/lara-light-blue/fonts/Inter-Light.woff +0 -0
- package/resources/themes/lara-light-blue/fonts/Inter-Light.woff2 +0 -0
- package/resources/themes/lara-light-blue/fonts/Inter-Medium.woff +0 -0
- package/resources/themes/lara-light-blue/fonts/Inter-Medium.woff2 +0 -0
- package/resources/themes/lara-light-blue/fonts/Inter-Regular.woff +0 -0
- package/resources/themes/lara-light-blue/fonts/Inter-Regular.woff2 +0 -0
- package/resources/themes/lara-light-blue/fonts/Inter-SemiBold.woff +0 -0
- package/resources/themes/lara-light-blue/fonts/Inter-SemiBold.woff2 +0 -0
- package/resources/themes/lara-light-blue/theme.css +5421 -0
- package/resources/themes/lara-light-indigo/fonts/Inter-Bold.woff +0 -0
- package/resources/themes/lara-light-indigo/fonts/Inter-Bold.woff2 +0 -0
- package/resources/themes/lara-light-indigo/fonts/Inter-Light.woff +0 -0
- package/resources/themes/lara-light-indigo/fonts/Inter-Light.woff2 +0 -0
- package/resources/themes/lara-light-indigo/fonts/Inter-Medium.woff +0 -0
- package/resources/themes/lara-light-indigo/fonts/Inter-Medium.woff2 +0 -0
- package/resources/themes/lara-light-indigo/fonts/Inter-Regular.woff +0 -0
- package/resources/themes/lara-light-indigo/fonts/Inter-Regular.woff2 +0 -0
- package/resources/themes/lara-light-indigo/fonts/Inter-SemiBold.woff +0 -0
- package/resources/themes/lara-light-indigo/fonts/Inter-SemiBold.woff2 +0 -0
- package/resources/themes/lara-light-indigo/theme.css +5421 -0
- package/resources/themes/lara-light-purple/fonts/Inter-Bold.woff +0 -0
- package/resources/themes/lara-light-purple/fonts/Inter-Bold.woff2 +0 -0
- package/resources/themes/lara-light-purple/fonts/Inter-Light.woff +0 -0
- package/resources/themes/lara-light-purple/fonts/Inter-Light.woff2 +0 -0
- package/resources/themes/lara-light-purple/fonts/Inter-Medium.woff +0 -0
- package/resources/themes/lara-light-purple/fonts/Inter-Medium.woff2 +0 -0
- package/resources/themes/lara-light-purple/fonts/Inter-Regular.woff +0 -0
- package/resources/themes/lara-light-purple/fonts/Inter-Regular.woff2 +0 -0
- package/resources/themes/lara-light-purple/fonts/Inter-SemiBold.woff +0 -0
- package/resources/themes/lara-light-purple/fonts/Inter-SemiBold.woff2 +0 -0
- package/resources/themes/lara-light-purple/theme.css +5421 -0
- package/resources/themes/lara-light-teal/fonts/Inter-Bold.woff +0 -0
- package/resources/themes/lara-light-teal/fonts/Inter-Bold.woff2 +0 -0
- package/resources/themes/lara-light-teal/fonts/Inter-Light.woff +0 -0
- package/resources/themes/lara-light-teal/fonts/Inter-Light.woff2 +0 -0
- package/resources/themes/lara-light-teal/fonts/Inter-Medium.woff +0 -0
- package/resources/themes/lara-light-teal/fonts/Inter-Medium.woff2 +0 -0
- package/resources/themes/lara-light-teal/fonts/Inter-Regular.woff +0 -0
- package/resources/themes/lara-light-teal/fonts/Inter-Regular.woff2 +0 -0
- package/resources/themes/lara-light-teal/fonts/Inter-SemiBold.woff +0 -0
- package/resources/themes/lara-light-teal/fonts/Inter-SemiBold.woff2 +0 -0
- package/resources/themes/lara-light-teal/theme.css +5421 -0
- package/resources/themes/luna-amber/theme.css +78 -37
- package/resources/themes/luna-blue/theme.css +78 -37
- package/resources/themes/luna-green/theme.css +78 -37
- package/resources/themes/luna-pink/theme.css +78 -37
- package/resources/themes/md-dark-deeppurple/theme.css +252 -48
- package/resources/themes/md-dark-indigo/theme.css +252 -48
- package/resources/themes/md-light-deeppurple/theme.css +252 -48
- package/resources/themes/md-light-indigo/theme.css +252 -48
- package/resources/themes/mdc-dark-deeppurple/theme.css +252 -48
- package/resources/themes/mdc-dark-indigo/theme.css +252 -48
- package/resources/themes/mdc-light-deeppurple/theme.css +252 -48
- package/resources/themes/mdc-light-indigo/theme.css +252 -48
- package/resources/themes/nova/theme.css +78 -37
- package/resources/themes/nova-accent/theme.css +78 -37
- package/resources/themes/nova-alt/theme.css +78 -37
- package/resources/themes/nova-vue/theme.css +78 -37
- package/resources/themes/rhea/theme.css +78 -37
- package/resources/themes/saga-blue/theme.css +65 -17
- package/resources/themes/saga-green/theme.css +65 -17
- package/resources/themes/saga-orange/theme.css +65 -17
- package/resources/themes/saga-purple/theme.css +65 -17
- package/resources/themes/tailwind-light/theme.css +92 -36
- package/resources/themes/vela-blue/theme.css +81 -33
- package/resources/themes/vela-green/theme.css +81 -33
- package/resources/themes/vela-orange/theme.css +81 -33
- package/resources/themes/vela-purple/theme.css +81 -33
- package/ripple/ripple.esm.js +1 -1
- package/ripple/ripple.esm.min.js +1 -1
- package/ripple/ripple.js +1 -1
- package/row/Row.d.ts +25 -3
- package/row/row.esm.js +1 -1
- package/row/row.esm.min.js +1 -1
- package/row/row.js +1 -1
- package/scrollpanel/ScrollPanel.d.ts +27 -5
- package/scrollpanel/scrollpanel.esm.js +1 -1
- package/scrollpanel/scrollpanel.esm.min.js +1 -1
- package/scrollpanel/scrollpanel.js +1 -1
- package/scrolltop/ScrollTop.d.ts +47 -7
- package/scrolltop/scrolltop.esm.js +1 -1
- package/scrolltop/scrolltop.esm.min.js +1 -1
- package/scrolltop/scrolltop.js +1 -1
- package/selectbutton/SelectButton.d.ts +108 -19
- package/selectbutton/SelectButton.vue +8 -2
- package/selectbutton/selectbutton.cjs.js +15 -10
- package/selectbutton/selectbutton.cjs.min.js +1 -1
- package/selectbutton/selectbutton.esm.js +15 -10
- package/selectbutton/selectbutton.esm.min.js +1 -1
- package/selectbutton/selectbutton.js +16 -11
- package/selectbutton/selectbutton.min.js +1 -1
- package/sidebar/Sidebar.d.ts +81 -16
- package/sidebar/sidebar.cjs.js +1 -1
- package/sidebar/sidebar.esm.js +1 -1
- package/sidebar/sidebar.esm.min.js +1 -1
- package/sidebar/sidebar.js +2 -2
- package/skeleton/Skeleton.d.ts +58 -9
- package/skeleton/skeleton.esm.js +1 -1
- package/skeleton/skeleton.esm.min.js +1 -1
- package/skeleton/skeleton.js +1 -1
- package/slider/Slider.d.ts +90 -14
- package/slider/slider.esm.js +1 -1
- package/slider/slider.esm.min.js +1 -1
- package/slider/slider.js +1 -1
- package/speeddial/SpeedDial.d.ts +166 -29
- package/speeddial/SpeedDial.vue +3 -1
- package/speeddial/speeddial.cjs.js +5 -2
- package/speeddial/speeddial.cjs.min.js +1 -1
- package/speeddial/speeddial.esm.js +4 -2
- package/speeddial/speeddial.esm.min.js +1 -1
- package/speeddial/speeddial.js +6 -4
- package/speeddial/speeddial.min.js +1 -1
- package/splitbutton/SplitButton.d.ts +76 -11
- package/splitbutton/SplitButton.vue +3 -1
- package/splitbutton/splitbutton.cjs.js +15 -13
- package/splitbutton/splitbutton.cjs.min.js +1 -1
- package/splitbutton/splitbutton.esm.js +15 -13
- package/splitbutton/splitbutton.esm.min.js +1 -1
- package/splitbutton/splitbutton.js +16 -14
- package/splitbutton/splitbutton.min.js +1 -1
- package/splitter/Splitter.d.ts +74 -7
- package/splitter/Splitter.vue +5 -5
- package/splitter/splitter.cjs.js +1 -1
- package/splitter/splitter.cjs.min.js +1 -1
- package/splitter/splitter.esm.js +2 -2
- package/splitter/splitter.esm.min.js +1 -1
- package/splitter/splitter.js +2 -2
- package/splitter/splitter.min.js +1 -1
- package/splitterpanel/SplitterPanel.d.ts +34 -7
- package/splitterpanel/splitterpanel.esm.js +1 -1
- package/splitterpanel/splitterpanel.esm.min.js +1 -1
- package/splitterpanel/splitterpanel.js +1 -1
- package/steps/Steps.d.ts +51 -11
- package/steps/Steps.vue +5 -2
- package/steps/steps.cjs.js +5 -2
- package/steps/steps.cjs.min.js +1 -1
- package/steps/steps.esm.js +6 -3
- package/steps/steps.esm.min.js +1 -1
- package/steps/steps.js +6 -3
- package/steps/steps.min.js +1 -1
- package/styleclass/styleclass.esm.js +1 -1
- package/styleclass/styleclass.esm.min.js +1 -1
- package/styleclass/styleclass.js +1 -1
- package/tabmenu/TabMenu.d.ts +63 -10
- package/tabmenu/TabMenu.vue +6 -3
- package/tabmenu/tabmenu.cjs.js +7 -4
- package/tabmenu/tabmenu.cjs.min.js +1 -1
- package/tabmenu/tabmenu.esm.js +7 -4
- package/tabmenu/tabmenu.esm.min.js +1 -1
- package/tabmenu/tabmenu.js +8 -5
- package/tabmenu/tabmenu.min.js +1 -1
- package/tabpanel/TabPanel.d.ts +38 -7
- package/tabpanel/tabpanel.esm.js +1 -1
- package/tabpanel/tabpanel.esm.min.js +1 -1
- package/tabpanel/tabpanel.js +1 -1
- package/tabview/TabView.d.ts +73 -11
- package/tabview/tabview.cjs.js +1 -1
- package/tabview/tabview.esm.js +1 -1
- package/tabview/tabview.esm.min.js +1 -1
- package/tabview/tabview.js +2 -2
- package/tag/Tag.d.ts +44 -8
- package/tag/Tag.vue +1 -1
- package/tag/tag.cjs.js +6 -6
- package/tag/tag.cjs.min.js +1 -1
- package/tag/tag.esm.js +8 -8
- package/tag/tag.esm.min.js +1 -1
- package/tag/tag.js +7 -7
- package/tag/tag.min.js +1 -1
- package/terminal/Terminal.d.ts +36 -5
- package/terminal/terminal.cjs.js +3 -3
- package/terminal/terminal.esm.js +1 -1
- package/terminal/terminal.esm.min.js +1 -1
- package/terminal/terminal.js +4 -4
- package/terminalservice/TerminalService.d.ts +9 -6
- package/terminalservice/terminalservice.esm.js +1 -1
- package/terminalservice/terminalservice.esm.min.js +1 -1
- package/terminalservice/terminalservice.js +1 -1
- package/textarea/Textarea.d.ts +38 -6
- package/textarea/textarea.esm.js +1 -1
- package/textarea/textarea.esm.min.js +1 -1
- package/textarea/textarea.js +1 -1
- package/tieredmenu/TieredMenu.d.ts +89 -15
- package/tieredmenu/TieredMenuSub.vue +7 -4
- package/tieredmenu/tieredmenu.cjs.js +9 -6
- package/tieredmenu/tieredmenu.cjs.min.js +1 -1
- package/tieredmenu/tieredmenu.esm.js +8 -5
- package/tieredmenu/tieredmenu.esm.min.js +1 -1
- package/tieredmenu/tieredmenu.js +10 -7
- package/tieredmenu/tieredmenu.min.js +1 -1
- package/timeline/Timeline.d.ts +94 -15
- package/timeline/timeline.esm.js +1 -1
- package/timeline/timeline.esm.min.js +1 -1
- package/timeline/timeline.js +1 -1
- package/toast/Toast.d.ts +118 -12
- package/toast/toast.cjs.js +7 -7
- package/toast/toast.esm.js +1 -1
- package/toast/toast.esm.min.js +1 -1
- package/toast/toast.js +8 -8
- package/toasteventbus/toasteventbus.esm.js +1 -1
- package/toasteventbus/toasteventbus.esm.min.js +1 -1
- package/toasteventbus/toasteventbus.js +1 -1
- package/toastservice/ToastService.d.ts +17 -5
- package/toastservice/toastservice.cjs.js +3 -3
- package/toastservice/toastservice.esm.js +1 -1
- package/toastservice/toastservice.esm.min.js +1 -1
- package/toastservice/toastservice.js +4 -4
- package/togglebutton/ToggleButton.d.ts +64 -11
- package/togglebutton/togglebutton.cjs.js +1 -1
- package/togglebutton/togglebutton.esm.js +1 -1
- package/togglebutton/togglebutton.esm.min.js +1 -1
- package/togglebutton/togglebutton.js +2 -2
- package/toolbar/Toolbar.d.ts +31 -6
- package/toolbar/Toolbar.vue +2 -2
- package/toolbar/toolbar.cjs.js +2 -2
- package/toolbar/toolbar.cjs.min.js +1 -1
- package/toolbar/toolbar.esm.js +3 -3
- package/toolbar/toolbar.esm.min.js +1 -1
- package/toolbar/toolbar.js +3 -3
- package/toolbar/toolbar.min.js +1 -1
- package/tooltip/tooltip.esm.js +1 -1
- package/tooltip/tooltip.esm.min.js +1 -1
- package/tooltip/tooltip.js +1 -1
- package/tree/Tree.d.ts +189 -26
- package/tree/Tree.vue +1 -0
- package/tree/TreeNode.vue +4 -1
- package/tree/tree.cjs.js +6 -3
- package/tree/tree.cjs.min.js +1 -1
- package/tree/tree.esm.js +6 -3
- package/tree/tree.esm.min.js +1 -1
- package/tree/tree.js +7 -4
- package/tree/tree.min.js +1 -1
- package/treeselect/TreeSelect.d.ts +201 -44
- package/treeselect/TreeSelect.vue +9 -0
- package/treeselect/treeselect.cjs.js +12 -3
- package/treeselect/treeselect.cjs.min.js +1 -1
- package/treeselect/treeselect.esm.js +10 -1
- package/treeselect/treeselect.esm.min.js +1 -1
- package/treeselect/treeselect.js +13 -4
- package/treeselect/treeselect.min.js +1 -1
- package/treetable/BodyCell.vue +3 -3
- package/treetable/TreeTable.d.ts +459 -63
- package/treetable/TreeTable.vue +9 -9
- package/treetable/treetable.cjs.js +17 -17
- package/treetable/treetable.cjs.min.js +1 -1
- package/treetable/treetable.esm.js +16 -16
- package/treetable/treetable.esm.min.js +1 -1
- package/treetable/treetable.js +18 -18
- package/treetable/treetable.min.js +1 -1
- package/tristatecheckbox/TriStateCheckbox.d.ts +40 -6
- package/tristatecheckbox/tristatecheckbox.esm.js +1 -1
- package/tristatecheckbox/tristatecheckbox.esm.min.js +1 -1
- package/tristatecheckbox/tristatecheckbox.js +1 -1
- package/ts-helpers.d.ts +28 -0
- package/useconfirm/UseConfirm.d.ts +5 -19
- package/useconfirm/useconfirm.js +1 -1
- package/usetoast/UseToast.d.ts +3 -5
- package/usetoast/usetoast.js +1 -1
- package/utils/Utils.d.ts +3 -0
- package/utils/utils.cjs.js +41 -4
- package/utils/utils.cjs.min.js +1 -1
- package/utils/utils.esm.js +41 -4
- package/utils/utils.esm.min.js +1 -1
- package/utils/utils.js +42 -5
- package/utils/utils.min.js +1 -1
- package/vetur-attributes.json +66 -30
- package/vetur-tags.json +16 -7
- package/virtualscroller/VirtualScroller.d.ts +294 -53
- package/virtualscroller/VirtualScroller.vue +296 -255
- package/virtualscroller/virtualscroller.cjs.js +325 -266
- package/virtualscroller/virtualscroller.cjs.min.js +1 -1
- package/virtualscroller/virtualscroller.esm.js +326 -267
- package/virtualscroller/virtualscroller.esm.min.js +1 -1
- package/virtualscroller/virtualscroller.js +326 -267
- package/virtualscroller/virtualscroller.min.js +1 -1
- package/web-types.json +296 -47
|
@@ -8,7 +8,7 @@ this.primevue.selectbutton = (function (utils, Ripple, vue) {
|
|
|
8
8
|
|
|
9
9
|
var script = {
|
|
10
10
|
name: 'SelectButton',
|
|
11
|
-
emits: ['update:modelValue', 'focus', 'blur'],
|
|
11
|
+
emits: ['update:modelValue', 'focus', 'blur', 'change'],
|
|
12
12
|
props: {
|
|
13
13
|
modelValue: null,
|
|
14
14
|
options: Array,
|
|
@@ -53,6 +53,7 @@ this.primevue.selectbutton = (function (utils, Ripple, vue) {
|
|
|
53
53
|
}
|
|
54
54
|
|
|
55
55
|
this.$emit('update:modelValue', newValue);
|
|
56
|
+
this.$emit('change', {event: event, value: newValue});
|
|
56
57
|
},
|
|
57
58
|
isSelected(option) {
|
|
58
59
|
let selected = false;
|
|
@@ -88,25 +89,29 @@ this.primevue.selectbutton = (function (utils, Ripple, vue) {
|
|
|
88
89
|
}
|
|
89
90
|
},
|
|
90
91
|
computed: {
|
|
92
|
+
containerClass() {
|
|
93
|
+
return ['p-selectbutton p-buttonset p-component', {
|
|
94
|
+
'p-disabled': this.disabled
|
|
95
|
+
}];
|
|
96
|
+
},
|
|
91
97
|
equalityKey() {
|
|
92
98
|
return this.optionValue ? null : this.dataKey;
|
|
93
99
|
}
|
|
94
100
|
},
|
|
95
101
|
directives: {
|
|
96
|
-
'ripple': Ripple__default[
|
|
102
|
+
'ripple': Ripple__default["default"]
|
|
97
103
|
}
|
|
98
104
|
};
|
|
99
105
|
|
|
100
|
-
const _hoisted_1 = {
|
|
101
|
-
class: "p-selectbutton p-buttonset p-component",
|
|
102
|
-
role: "group"
|
|
103
|
-
};
|
|
104
|
-
const _hoisted_2 = { class: "p-button-label" };
|
|
106
|
+
const _hoisted_1 = { class: "p-button-label" };
|
|
105
107
|
|
|
106
108
|
function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
107
109
|
const _directive_ripple = vue.resolveDirective("ripple");
|
|
108
110
|
|
|
109
|
-
return (vue.openBlock(), vue.createBlock("div",
|
|
111
|
+
return (vue.openBlock(), vue.createBlock("div", {
|
|
112
|
+
class: $options.containerClass,
|
|
113
|
+
role: "group"
|
|
114
|
+
}, [
|
|
110
115
|
(vue.openBlock(true), vue.createBlock(vue.Fragment, null, vue.renderList($props.options, (option, i) => {
|
|
111
116
|
return vue.withDirectives((vue.openBlock(), vue.createBlock("div", {
|
|
112
117
|
key: $options.getOptionRenderKey(option),
|
|
@@ -128,17 +133,17 @@ this.primevue.selectbutton = (function (utils, Ripple, vue) {
|
|
|
128
133
|
option: option,
|
|
129
134
|
index: i
|
|
130
135
|
}, () => [
|
|
131
|
-
vue.createVNode("span",
|
|
136
|
+
vue.createVNode("span", _hoisted_1, vue.toDisplayString($options.getOptionLabel(option)), 1)
|
|
132
137
|
])
|
|
133
138
|
], 42, ["aria-label", "aria-pressed", "onClick", "onKeydown", "tabindex", "aria-labelledby"])), [
|
|
134
139
|
[_directive_ripple]
|
|
135
140
|
])
|
|
136
141
|
}), 128))
|
|
137
|
-
]))
|
|
142
|
+
], 2))
|
|
138
143
|
}
|
|
139
144
|
|
|
140
145
|
script.render = render;
|
|
141
146
|
|
|
142
147
|
return script;
|
|
143
148
|
|
|
144
|
-
}(primevue.utils, primevue.ripple, Vue)
|
|
149
|
+
})(primevue.utils, primevue.ripple, Vue);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
this.primevue=this.primevue||{},this.primevue.selectbutton=function(e,t,i){"use strict";function l(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var o={name:"SelectButton",emits:["update:modelValue","focus","blur"],props:{modelValue:null,options:Array,optionLabel:null,optionValue:null,optionDisabled:null,multiple:Boolean,disabled:Boolean,dataKey:null,ariaLabelledBy:null},methods:{getOptionLabel(t){return this.optionLabel?e.ObjectUtils.resolveFieldData(t,this.optionLabel):t},getOptionValue(t){return this.optionValue?e.ObjectUtils.resolveFieldData(t,this.optionValue):t},getOptionRenderKey(t){return this.dataKey?e.ObjectUtils.resolveFieldData(t,this.dataKey):this.getOptionLabel(t)},isOptionDisabled(t){return!!this.optionDisabled&&e.ObjectUtils.resolveFieldData(t,this.optionDisabled)},onOptionSelect(t,i){if(this.disabled||this.isOptionDisabled(i))return;let l,o=this.isSelected(i),s=this.getOptionValue(i);l=this.multiple?o?this.modelValue.filter((t=>!e.ObjectUtils.equals(t,s,this.equalityKey))):this.modelValue?[...this.modelValue,s]:[s]:s,this.$emit("update:modelValue",l)},isSelected(t){let i=!1,l=this.getOptionValue(t);if(this.multiple){if(this.modelValue)for(let t of this.modelValue)if(e.ObjectUtils.equals(t,l,this.equalityKey)){i=!0;break}}else i=e.ObjectUtils.equals(this.modelValue,l,this.equalityKey);return i},onFocus(e){this.$emit("focus",e)},onBlur(e){this.$emit("blur",e)},getButtonClass(e){return["p-button p-component",{"p-highlight":this.isSelected(e),"p-disabled":this.isOptionDisabled(e)}]}},computed:{equalityKey(){return this.optionValue?null:this.dataKey}},directives:{ripple:l(t).default}};const s={class:"p-
|
|
1
|
+
this.primevue=this.primevue||{},this.primevue.selectbutton=function(e,t,i){"use strict";function l(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var o={name:"SelectButton",emits:["update:modelValue","focus","blur","change"],props:{modelValue:null,options:Array,optionLabel:null,optionValue:null,optionDisabled:null,multiple:Boolean,disabled:Boolean,dataKey:null,ariaLabelledBy:null},methods:{getOptionLabel(t){return this.optionLabel?e.ObjectUtils.resolveFieldData(t,this.optionLabel):t},getOptionValue(t){return this.optionValue?e.ObjectUtils.resolveFieldData(t,this.optionValue):t},getOptionRenderKey(t){return this.dataKey?e.ObjectUtils.resolveFieldData(t,this.dataKey):this.getOptionLabel(t)},isOptionDisabled(t){return!!this.optionDisabled&&e.ObjectUtils.resolveFieldData(t,this.optionDisabled)},onOptionSelect(t,i){if(this.disabled||this.isOptionDisabled(i))return;let l,o=this.isSelected(i),s=this.getOptionValue(i);l=this.multiple?o?this.modelValue.filter((t=>!e.ObjectUtils.equals(t,s,this.equalityKey))):this.modelValue?[...this.modelValue,s]:[s]:s,this.$emit("update:modelValue",l),this.$emit("change",{event:t,value:l})},isSelected(t){let i=!1,l=this.getOptionValue(t);if(this.multiple){if(this.modelValue)for(let t of this.modelValue)if(e.ObjectUtils.equals(t,l,this.equalityKey)){i=!0;break}}else i=e.ObjectUtils.equals(this.modelValue,l,this.equalityKey);return i},onFocus(e){this.$emit("focus",e)},onBlur(e){this.$emit("blur",e)},getButtonClass(e){return["p-button p-component",{"p-highlight":this.isSelected(e),"p-disabled":this.isOptionDisabled(e)}]}},computed:{containerClass(){return["p-selectbutton p-buttonset p-component",{"p-disabled":this.disabled}]},equalityKey(){return this.optionValue?null:this.dataKey}},directives:{ripple:l(t).default}};const s={class:"p-button-label"};return o.render=function(e,t,l,o,n,a){const r=i.resolveDirective("ripple");return i.openBlock(),i.createBlock("div",{class:a.containerClass,role:"group"},[(i.openBlock(!0),i.createBlock(i.Fragment,null,i.renderList(l.options,((o,n)=>i.withDirectives((i.openBlock(),i.createBlock("div",{key:a.getOptionRenderKey(o),"aria-label":a.getOptionLabel(o),role:"button","aria-pressed":a.isSelected(o),onClick:e=>a.onOptionSelect(e,o,n),onKeydown:[i.withKeys(i.withModifiers((e=>a.onOptionSelect(e,o,n)),["prevent"]),["enter"]),i.withKeys(i.withModifiers((e=>a.onOptionSelect(e,o)),["prevent"]),["space"])],tabindex:a.isOptionDisabled(o)?null:"0",onFocus:t[1]||(t[1]=e=>a.onFocus(e)),onBlur:t[2]||(t[2]=e=>a.onBlur(e)),"aria-labelledby":l.ariaLabelledBy,class:a.getButtonClass(o)},[i.renderSlot(e.$slots,"option",{option:o,index:n},(()=>[i.createVNode("span",s,i.toDisplayString(a.getOptionLabel(o)),1)]))],42,["aria-label","aria-pressed","onClick","onKeydown","tabindex","aria-labelledby"])),[[r]]))),128))],2)},o}(primevue.utils,primevue.ripple,Vue);
|
package/sidebar/Sidebar.d.ts
CHANGED
|
@@ -1,24 +1,89 @@
|
|
|
1
1
|
import { VNode } from 'vue';
|
|
2
|
+
import { ClassComponent, GlobalComponentConstructor } from '../ts-helpers';
|
|
2
3
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
4
|
+
type SidebarPositionType = 'left' | 'right' | 'top' | 'bottom' | 'full' | undefined;
|
|
5
|
+
|
|
6
|
+
export interface SidebarProps {
|
|
7
|
+
/**
|
|
8
|
+
* Specifies the visibility of the dialog.
|
|
9
|
+
*/
|
|
10
|
+
visible?: boolean | undefined;
|
|
11
|
+
/**
|
|
12
|
+
* Specifies the position of the sidebar.
|
|
13
|
+
* @see SidebarPositionType
|
|
14
|
+
* Default value is 'left'.
|
|
15
|
+
*/
|
|
16
|
+
position?: SidebarPositionType;
|
|
17
|
+
/**
|
|
18
|
+
* Base zIndex value to use in layering.
|
|
19
|
+
* Default value is 0.
|
|
20
|
+
*/
|
|
21
|
+
baseZIndex?: number | undefined;
|
|
22
|
+
/**
|
|
23
|
+
* Whether to automatically manage layering.
|
|
24
|
+
* Default value is true.
|
|
25
|
+
*/
|
|
26
|
+
autoZIndex?: boolean | undefined;
|
|
27
|
+
/**
|
|
28
|
+
* Whether clicking outside closes the panel.
|
|
29
|
+
* Default value is true.
|
|
30
|
+
*/
|
|
31
|
+
dismissable?: boolean | undefined;
|
|
32
|
+
/**
|
|
33
|
+
* Whether to display a close icon inside the panel.
|
|
34
|
+
* Default value is true.
|
|
35
|
+
*/
|
|
36
|
+
showCloseIcon?: boolean | undefined;
|
|
37
|
+
/**
|
|
38
|
+
* Whether to a modal layer behind the sidebar.
|
|
39
|
+
* Default value is true.
|
|
40
|
+
*/
|
|
41
|
+
modal?: boolean | undefined;
|
|
42
|
+
/**
|
|
43
|
+
* Aria label of the close icon.
|
|
44
|
+
* Default value is 'close'.
|
|
45
|
+
*/
|
|
46
|
+
ariaCloseLabel?: string | undefined;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export interface SidebarSlots {
|
|
50
|
+
/**
|
|
51
|
+
* Custom content template.
|
|
52
|
+
*/
|
|
53
|
+
default: () => VNode[];
|
|
12
54
|
}
|
|
13
55
|
|
|
14
|
-
declare
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
56
|
+
export declare type SidebarEmits = {
|
|
57
|
+
/**
|
|
58
|
+
* Emitted when the value changes.
|
|
59
|
+
* @param {boolean} value - New value.
|
|
60
|
+
*/
|
|
61
|
+
'update:modelValue': (value: boolean) => void;
|
|
62
|
+
/**
|
|
63
|
+
* Callback to invoke when sidebar gets shown.
|
|
64
|
+
*/
|
|
65
|
+
'show': () => void;
|
|
66
|
+
/**
|
|
67
|
+
* Callback to invoke when sidebar gets hidden.
|
|
68
|
+
*/
|
|
69
|
+
'hide': () => void;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
declare class Sidebar extends ClassComponent<SidebarProps, SidebarSlots, SidebarEmits> { }
|
|
73
|
+
|
|
74
|
+
declare module '@vue/runtime-core' {
|
|
75
|
+
interface GlobalComponents {
|
|
76
|
+
Sidebar: GlobalComponentConstructor<Sidebar>
|
|
21
77
|
}
|
|
22
78
|
}
|
|
23
79
|
|
|
80
|
+
/**
|
|
81
|
+
*
|
|
82
|
+
* Sidebar is a panel component displayed as an overlay at the edges of the screen.
|
|
83
|
+
*
|
|
84
|
+
* Demos:
|
|
85
|
+
*
|
|
86
|
+
* - [Sidebar](https://www.primefaces.org/primevue/showcase/#/sidebar)
|
|
87
|
+
*
|
|
88
|
+
*/
|
|
24
89
|
export default Sidebar;
|
package/sidebar/sidebar.cjs.js
CHANGED
package/sidebar/sidebar.esm.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{ZIndexUtils as e,DomHandler as t}from"primevue/utils";import i from"primevue/ripple";import{resolveDirective as n,openBlock as s,createBlock as a,Teleport as r,createVNode as o,Transition as d,withCtx as l,mergeProps as p,withDirectives as b,createCommentVNode as m,renderSlot as c}from"vue";var h={name:"Sidebar",emits:["update:visible","show","hide"],inheritAttrs:!1,props:{visible:{type:Boolean,default:!1},position:{type:String,default:"left"},baseZIndex:{type:Number,default:0},autoZIndex:{type:Boolean,default:!0},dismissable:{type:Boolean,default:!0},showCloseIcon:{type:Boolean,default:!0},modal:{type:Boolean,default:!0},ariaCloseLabel:{type:String,default:"close"}},mask:null,maskClickListener:null,container:null,beforeUnmount(){this.destroyModal(),this.container&&this.autoZIndex&&e.clear(this.container),this.container=null},methods:{hide(){this.$emit("update:visible",!1)},onEnter(t){this.$emit("show"),this.autoZIndex&&e.set("modal",t,this.baseZIndex||this.$primevue.config.zIndex.modal),this.focus(),this.modal&&!this.fullScreen&&this.enableModality()},onLeave(){this.$emit("hide"),this.modal&&!this.fullScreen&&this.disableModality()},onAfterLeave(t){this.autoZIndex&&e.clear(t)},focus(){let e=t.findSingle(this.container,"input,button");e&&e.focus()},enableModality(){this.mask||(this.mask=document.createElement("div"),this.mask.setAttribute("class","p-sidebar-mask p-component-overlay p-component-overlay-enter"),this.mask.style.zIndex=String(parseInt(this.container.style.zIndex,10)-1),this.dismissable&&this.bindMaskClickListener(),document.body.appendChild(this.mask),t.addClass(document.body,"p-overflow-hidden"))},disableModality(){this.mask&&(t.addClass(this.mask,"p-component-overlay-leave"),this.mask.addEventListener("animationend",(()=>{this.destroyModal()})))},bindMaskClickListener(){this.maskClickListener||(this.maskClickListener=()=>{this.hide()},this.mask.addEventListener("click",this.maskClickListener))},unbindMaskClickListener(){this.maskClickListener&&(this.mask.removeEventListener("click",this.maskClickListener),this.maskClickListener=null)},destroyModal(){this.mask&&(this.unbindMaskClickListener(),document.body.removeChild(this.mask),t.removeClass(document.body,"p-overflow-hidden"),this.mask=null)},containerRef(e){this.container=e}},computed:{containerClass(){return["p-sidebar p-component p-sidebar-"+this.position,{"p-sidebar-active":this.visible,"p-input-filled":"filled"===this.$primevue.config.inputStyle,"p-ripple-disabled":!1===this.$primevue.config.ripple}]},fullScreen(){return"full"===this.position}},directives:{ripple:i}};const f={class:"p-sidebar-header"},u=o("span",{class:"p-sidebar-close-icon pi pi-times"},null,-1),k={class:"p-sidebar-content"};!function(e,t){void 0===t&&(t={});var i=t.insertAt;if(e&&"undefined"!=typeof document){var n=document.head||document.getElementsByTagName("head")[0],s=document.createElement("style");s.type="text/css","top"===i&&n.firstChild?n.insertBefore(s,n.firstChild):n.appendChild(s),s.styleSheet?s.styleSheet.cssText=e:s.appendChild(document.createTextNode(e))}}("\n.p-sidebar {\n position: fixed;\n -webkit-transition: -webkit-transform .3s;\n transition: -webkit-transform .3s;\n transition: transform .3s;\n transition: transform .3s, -webkit-transform .3s;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n.p-sidebar-content {\n position: relative;\n overflow-y: auto;\n}\n.p-sidebar-header {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: end;\n -ms-flex-pack: end;\n justify-content: flex-end;\n}\n.p-sidebar-icon {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n}\n.p-sidebar-left {\n top: 0;\n left: 0;\n width: 20rem;\n height: 100%;\n}\n.p-sidebar-right {\n top: 0;\n right: 0;\n width: 20rem;\n height: 100%;\n}\n.p-sidebar-top {\n top: 0;\n left: 0;\n width: 100%;\n height: 10rem;\n}\n.p-sidebar-bottom {\n bottom: 0;\n left: 0;\n width: 100%;\n height: 10rem;\n}\n.p-sidebar-full {\n width: 100%;\n height: 100%;\n top: 0;\n left: 0;\n -webkit-transition: none;\n transition: none;\n}\n.p-sidebar-left.p-sidebar-enter-from,\n.p-sidebar-left.p-sidebar-leave-to {\n -webkit-transform: translateX(-100%);\n transform: translateX(-100%);\n}\n.p-sidebar-right.p-sidebar-enter-from,\n.p-sidebar-right.p-sidebar-leave-to {\n -webkit-transform: translateX(100%);\n transform: translateX(100%);\n}\n.p-sidebar-top.p-sidebar-enter-from,\n.p-sidebar-top.p-sidebar-leave-to {\n -webkit-transform: translateY(-100%);\n transform: translateY(-100%);\n}\n.p-sidebar-bottom.p-sidebar-enter-from,\n.p-sidebar-bottom.p-sidebar-leave-to {\n -webkit-transform: translateY(100%);\n transform: translateY(100%);\n}\n.p-sidebar-full.p-sidebar-enter-from,\n.p-sidebar-full.p-sidebar-leave-to {\n opacity: 0;\n}\n.p-sidebar-full.p-sidebar-enter-active,\n.p-sidebar-full.p-sidebar-leave-active {\n -webkit-transition: opacity 400ms cubic-bezier(0.25, 0.8, 0.25, 1);\n transition: opacity 400ms cubic-bezier(0.25, 0.8, 0.25, 1);\n}\n.p-sidebar-left.p-sidebar-sm,\n.p-sidebar-right.p-sidebar-sm {\n width: 20rem;\n}\n.p-sidebar-left.p-sidebar-md,\n.p-sidebar-right.p-sidebar-md {\n width: 40rem;\n}\n.p-sidebar-left.p-sidebar-lg,\n.p-sidebar-right.p-sidebar-lg {\n width: 60rem;\n}\n.p-sidebar-top.p-sidebar-sm,\n.p-sidebar-bottom.p-sidebar-sm {\n height: 10rem;\n}\n.p-sidebar-top.p-sidebar-md,\n.p-sidebar-bottom.p-sidebar-md {\n height: 20rem;\n}\n.p-sidebar-top.p-sidebar-lg,\n.p-sidebar-bottom.p-sidebar-lg {\n height: 30rem;\n}\n@media screen and (max-width: 64em) {\n.p-sidebar-left.p-sidebar-lg,\n .p-sidebar-left.p-sidebar-md,\n .p-sidebar-right.p-sidebar-lg,\n .p-sidebar-right.p-sidebar-md {\n width: 20rem;\n}\n}\n"),h.render=function(e,t,i,h,v,y){const x=n("ripple");return s(),a(r,{to:"body"},[o(d,{name:"p-sidebar",onEnter:y.onEnter,onLeave:y.onLeave,onAfterLeave:y.onAfterLeave,appear:""},{default:l((()=>[i.visible?(s(),a("div",p({key:0,class:y.containerClass,ref:y.containerRef,role:"complementary","aria-modal":i.modal},e.$attrs),[o("div",f,[i.showCloseIcon?b((s(),a("button",{key:0,class:"p-sidebar-close p-sidebar-icon p-link",onClick:t[1]||(t[1]=(...e)=>y.hide&&y.hide(...e)),"aria-label":i.ariaCloseLabel,type:"button"},[u],8,["aria-label"])),[[x]]):m("",!0)]),o("div",k,[c(e.$slots,"default")])],16,["aria-modal"])):m("",!0)])),_:3},8,["onEnter","onLeave","onAfterLeave"])])};export default
|
|
1
|
+
import{ZIndexUtils as e,DomHandler as t}from"primevue/utils";import i from"primevue/ripple";import{resolveDirective as n,openBlock as s,createBlock as a,Teleport as r,createVNode as o,Transition as d,withCtx as l,mergeProps as p,withDirectives as b,createCommentVNode as m,renderSlot as c}from"vue";var h={name:"Sidebar",emits:["update:visible","show","hide"],inheritAttrs:!1,props:{visible:{type:Boolean,default:!1},position:{type:String,default:"left"},baseZIndex:{type:Number,default:0},autoZIndex:{type:Boolean,default:!0},dismissable:{type:Boolean,default:!0},showCloseIcon:{type:Boolean,default:!0},modal:{type:Boolean,default:!0},ariaCloseLabel:{type:String,default:"close"}},mask:null,maskClickListener:null,container:null,beforeUnmount(){this.destroyModal(),this.container&&this.autoZIndex&&e.clear(this.container),this.container=null},methods:{hide(){this.$emit("update:visible",!1)},onEnter(t){this.$emit("show"),this.autoZIndex&&e.set("modal",t,this.baseZIndex||this.$primevue.config.zIndex.modal),this.focus(),this.modal&&!this.fullScreen&&this.enableModality()},onLeave(){this.$emit("hide"),this.modal&&!this.fullScreen&&this.disableModality()},onAfterLeave(t){this.autoZIndex&&e.clear(t)},focus(){let e=t.findSingle(this.container,"input,button");e&&e.focus()},enableModality(){this.mask||(this.mask=document.createElement("div"),this.mask.setAttribute("class","p-sidebar-mask p-component-overlay p-component-overlay-enter"),this.mask.style.zIndex=String(parseInt(this.container.style.zIndex,10)-1),this.dismissable&&this.bindMaskClickListener(),document.body.appendChild(this.mask),t.addClass(document.body,"p-overflow-hidden"))},disableModality(){this.mask&&(t.addClass(this.mask,"p-component-overlay-leave"),this.mask.addEventListener("animationend",(()=>{this.destroyModal()})))},bindMaskClickListener(){this.maskClickListener||(this.maskClickListener=()=>{this.hide()},this.mask.addEventListener("click",this.maskClickListener))},unbindMaskClickListener(){this.maskClickListener&&(this.mask.removeEventListener("click",this.maskClickListener),this.maskClickListener=null)},destroyModal(){this.mask&&(this.unbindMaskClickListener(),document.body.removeChild(this.mask),t.removeClass(document.body,"p-overflow-hidden"),this.mask=null)},containerRef(e){this.container=e}},computed:{containerClass(){return["p-sidebar p-component p-sidebar-"+this.position,{"p-sidebar-active":this.visible,"p-input-filled":"filled"===this.$primevue.config.inputStyle,"p-ripple-disabled":!1===this.$primevue.config.ripple}]},fullScreen(){return"full"===this.position}},directives:{ripple:i}};const f={class:"p-sidebar-header"},u=o("span",{class:"p-sidebar-close-icon pi pi-times"},null,-1),k={class:"p-sidebar-content"};!function(e,t){void 0===t&&(t={});var i=t.insertAt;if(e&&"undefined"!=typeof document){var n=document.head||document.getElementsByTagName("head")[0],s=document.createElement("style");s.type="text/css","top"===i&&n.firstChild?n.insertBefore(s,n.firstChild):n.appendChild(s),s.styleSheet?s.styleSheet.cssText=e:s.appendChild(document.createTextNode(e))}}("\n.p-sidebar {\n position: fixed;\n -webkit-transition: -webkit-transform .3s;\n transition: -webkit-transform .3s;\n transition: transform .3s;\n transition: transform .3s, -webkit-transform .3s;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n.p-sidebar-content {\n position: relative;\n overflow-y: auto;\n}\n.p-sidebar-header {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: end;\n -ms-flex-pack: end;\n justify-content: flex-end;\n}\n.p-sidebar-icon {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n}\n.p-sidebar-left {\n top: 0;\n left: 0;\n width: 20rem;\n height: 100%;\n}\n.p-sidebar-right {\n top: 0;\n right: 0;\n width: 20rem;\n height: 100%;\n}\n.p-sidebar-top {\n top: 0;\n left: 0;\n width: 100%;\n height: 10rem;\n}\n.p-sidebar-bottom {\n bottom: 0;\n left: 0;\n width: 100%;\n height: 10rem;\n}\n.p-sidebar-full {\n width: 100%;\n height: 100%;\n top: 0;\n left: 0;\n -webkit-transition: none;\n transition: none;\n}\n.p-sidebar-left.p-sidebar-enter-from,\n.p-sidebar-left.p-sidebar-leave-to {\n -webkit-transform: translateX(-100%);\n transform: translateX(-100%);\n}\n.p-sidebar-right.p-sidebar-enter-from,\n.p-sidebar-right.p-sidebar-leave-to {\n -webkit-transform: translateX(100%);\n transform: translateX(100%);\n}\n.p-sidebar-top.p-sidebar-enter-from,\n.p-sidebar-top.p-sidebar-leave-to {\n -webkit-transform: translateY(-100%);\n transform: translateY(-100%);\n}\n.p-sidebar-bottom.p-sidebar-enter-from,\n.p-sidebar-bottom.p-sidebar-leave-to {\n -webkit-transform: translateY(100%);\n transform: translateY(100%);\n}\n.p-sidebar-full.p-sidebar-enter-from,\n.p-sidebar-full.p-sidebar-leave-to {\n opacity: 0;\n}\n.p-sidebar-full.p-sidebar-enter-active,\n.p-sidebar-full.p-sidebar-leave-active {\n -webkit-transition: opacity 400ms cubic-bezier(0.25, 0.8, 0.25, 1);\n transition: opacity 400ms cubic-bezier(0.25, 0.8, 0.25, 1);\n}\n.p-sidebar-left.p-sidebar-sm,\n.p-sidebar-right.p-sidebar-sm {\n width: 20rem;\n}\n.p-sidebar-left.p-sidebar-md,\n.p-sidebar-right.p-sidebar-md {\n width: 40rem;\n}\n.p-sidebar-left.p-sidebar-lg,\n.p-sidebar-right.p-sidebar-lg {\n width: 60rem;\n}\n.p-sidebar-top.p-sidebar-sm,\n.p-sidebar-bottom.p-sidebar-sm {\n height: 10rem;\n}\n.p-sidebar-top.p-sidebar-md,\n.p-sidebar-bottom.p-sidebar-md {\n height: 20rem;\n}\n.p-sidebar-top.p-sidebar-lg,\n.p-sidebar-bottom.p-sidebar-lg {\n height: 30rem;\n}\n@media screen and (max-width: 64em) {\n.p-sidebar-left.p-sidebar-lg,\n .p-sidebar-left.p-sidebar-md,\n .p-sidebar-right.p-sidebar-lg,\n .p-sidebar-right.p-sidebar-md {\n width: 20rem;\n}\n}\n"),h.render=function(e,t,i,h,v,y){const x=n("ripple");return s(),a(r,{to:"body"},[o(d,{name:"p-sidebar",onEnter:y.onEnter,onLeave:y.onLeave,onAfterLeave:y.onAfterLeave,appear:""},{default:l((()=>[i.visible?(s(),a("div",p({key:0,class:y.containerClass,ref:y.containerRef,role:"complementary","aria-modal":i.modal},e.$attrs),[o("div",f,[i.showCloseIcon?b((s(),a("button",{key:0,class:"p-sidebar-close p-sidebar-icon p-link",onClick:t[1]||(t[1]=(...e)=>y.hide&&y.hide(...e)),"aria-label":i.ariaCloseLabel,type:"button"},[u],8,["aria-label"])),[[x]]):m("",!0)]),o("div",k,[c(e.$slots,"default")])],16,["aria-modal"])):m("",!0)])),_:3},8,["onEnter","onLeave","onAfterLeave"])])};export{h as default};
|
package/sidebar/sidebar.js
CHANGED
|
@@ -147,7 +147,7 @@ this.primevue.sidebar = (function (utils, Ripple, vue) {
|
|
|
147
147
|
}
|
|
148
148
|
},
|
|
149
149
|
directives: {
|
|
150
|
-
'ripple': Ripple__default[
|
|
150
|
+
'ripple': Ripple__default["default"]
|
|
151
151
|
}
|
|
152
152
|
};
|
|
153
153
|
|
|
@@ -235,4 +235,4 @@ this.primevue.sidebar = (function (utils, Ripple, vue) {
|
|
|
235
235
|
|
|
236
236
|
return script;
|
|
237
237
|
|
|
238
|
-
}(primevue.utils, primevue.ripple, Vue)
|
|
238
|
+
})(primevue.utils, primevue.ripple, Vue);
|
package/skeleton/Skeleton.d.ts
CHANGED
|
@@ -1,14 +1,63 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
1
|
+
import { ClassComponent, GlobalComponentConstructor } from '../ts-helpers';
|
|
2
|
+
|
|
3
|
+
type SkeletonShapeType = 'rectangle' | 'circle' | undefined;
|
|
4
|
+
|
|
5
|
+
type SkeletonAnimationType = 'wave' | 'none' | undefined;
|
|
6
|
+
|
|
7
|
+
export interface SkeletonProps {
|
|
8
|
+
/**
|
|
9
|
+
* Shape of the element.
|
|
10
|
+
* @see SkeletonShapeType
|
|
11
|
+
* Default value is 'rectangle'.
|
|
12
|
+
*/
|
|
13
|
+
shape?: SkeletonShapeType;
|
|
14
|
+
/**
|
|
15
|
+
* Size of the Circle or Square.
|
|
16
|
+
*/
|
|
17
|
+
size?: string | undefined;
|
|
18
|
+
/**
|
|
19
|
+
* Width of the element.
|
|
20
|
+
* Default value is '100%'.
|
|
21
|
+
*/
|
|
22
|
+
width?: string | undefined;
|
|
23
|
+
/**
|
|
24
|
+
* Height of the element.
|
|
25
|
+
* Default value is '1rem'.
|
|
26
|
+
*/
|
|
27
|
+
height?: string | undefined;
|
|
28
|
+
/**
|
|
29
|
+
* Border radius of the element, defaults to value from theme.
|
|
30
|
+
*/
|
|
31
|
+
borderRadius?: string | undefined;
|
|
32
|
+
/**
|
|
33
|
+
* Type of the animation.
|
|
34
|
+
* @see SkeletonAnimationType
|
|
35
|
+
* Default value is 'wave'.
|
|
36
|
+
*/
|
|
37
|
+
animation?: SkeletonAnimationType;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
export interface SkeletonSlots {
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
export declare type SkeletonEmits = {
|
|
8
44
|
}
|
|
9
45
|
|
|
10
|
-
declare class Skeleton {
|
|
11
|
-
|
|
46
|
+
declare class Skeleton extends ClassComponent<SkeletonProps, SkeletonSlots, SkeletonEmits> { }
|
|
47
|
+
|
|
48
|
+
declare module '@vue/runtime-core' {
|
|
49
|
+
interface GlobalComponents {
|
|
50
|
+
Skeleton: GlobalComponentConstructor<Skeleton>
|
|
51
|
+
}
|
|
12
52
|
}
|
|
13
53
|
|
|
54
|
+
/**
|
|
55
|
+
*
|
|
56
|
+
* Skeleton is a placeholder to display instead of the actual content.
|
|
57
|
+
*
|
|
58
|
+
* Demos:
|
|
59
|
+
*
|
|
60
|
+
* - [Skeleton](https://www.primefaces.org/primevue/showcase/#/skeleton)
|
|
61
|
+
*
|
|
62
|
+
*/
|
|
14
63
|
export default Skeleton;
|
package/skeleton/skeleton.esm.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{openBlock as n,createBlock as e}from"vue";var t={name:"Skeleton",props:{shape:{type:String,default:"rectangle"},size:{type:String,default:null},width:{type:String,default:"100%"},height:{type:String,default:"1rem"},borderRadius:{type:String,default:null},animation:{type:String,default:"wave"}},computed:{containerClass(){return["p-skeleton p-component",{"p-skeleton-circle":"circle"===this.shape,"p-skeleton-none":"none"===this.animation}]},containerStyle(){return this.size?{width:this.size,height:this.size,borderRadius:this.borderRadius}:{width:this.width,height:this.height,borderRadius:this.borderRadius}}}};!function(n,e){void 0===e&&(e={});var t=e.insertAt;if(n&&"undefined"!=typeof document){var i=document.head||document.getElementsByTagName("head")[0],a=document.createElement("style");a.type="text/css","top"===t&&i.firstChild?i.insertBefore(a,i.firstChild):i.appendChild(a),a.styleSheet?a.styleSheet.cssText=n:a.appendChild(document.createTextNode(n))}}('\n.p-skeleton {\n position: relative;\n overflow: hidden;\n}\n.p-skeleton::after {\n content: "";\n -webkit-animation: p-skeleton-animation 1.2s infinite;\n animation: p-skeleton-animation 1.2s infinite;\n height: 100%;\n left: 0;\n position: absolute;\n right: 0;\n top: 0;\n -webkit-transform: translateX(-100%);\n transform: translateX(-100%);\n z-index: 1;\n}\n.p-skeleton.p-skeleton-circle {\n border-radius: 50%;\n}\n.p-skeleton-none::after {\n -webkit-animation: none;\n animation: none;\n}\n@-webkit-keyframes p-skeleton-animation {\nfrom {\n -webkit-transform: translateX(-100%);\n transform: translateX(-100%);\n}\nto {\n -webkit-transform: translateX(100%);\n transform: translateX(100%);\n}\n}\n@keyframes p-skeleton-animation {\nfrom {\n -webkit-transform: translateX(-100%);\n transform: translateX(-100%);\n}\nto {\n -webkit-transform: translateX(100%);\n transform: translateX(100%);\n}\n}\n'),t.render=function(t,i,a,r,o
|
|
1
|
+
import{openBlock as n,createBlock as e}from"vue";var t={name:"Skeleton",props:{shape:{type:String,default:"rectangle"},size:{type:String,default:null},width:{type:String,default:"100%"},height:{type:String,default:"1rem"},borderRadius:{type:String,default:null},animation:{type:String,default:"wave"}},computed:{containerClass(){return["p-skeleton p-component",{"p-skeleton-circle":"circle"===this.shape,"p-skeleton-none":"none"===this.animation}]},containerStyle(){return this.size?{width:this.size,height:this.size,borderRadius:this.borderRadius}:{width:this.width,height:this.height,borderRadius:this.borderRadius}}}};!function(n,e){void 0===e&&(e={});var t=e.insertAt;if(n&&"undefined"!=typeof document){var i=document.head||document.getElementsByTagName("head")[0],a=document.createElement("style");a.type="text/css","top"===t&&i.firstChild?i.insertBefore(a,i.firstChild):i.appendChild(a),a.styleSheet?a.styleSheet.cssText=n:a.appendChild(document.createTextNode(n))}}('\n.p-skeleton {\n position: relative;\n overflow: hidden;\n}\n.p-skeleton::after {\n content: "";\n -webkit-animation: p-skeleton-animation 1.2s infinite;\n animation: p-skeleton-animation 1.2s infinite;\n height: 100%;\n left: 0;\n position: absolute;\n right: 0;\n top: 0;\n -webkit-transform: translateX(-100%);\n transform: translateX(-100%);\n z-index: 1;\n}\n.p-skeleton.p-skeleton-circle {\n border-radius: 50%;\n}\n.p-skeleton-none::after {\n -webkit-animation: none;\n animation: none;\n}\n@-webkit-keyframes p-skeleton-animation {\nfrom {\n -webkit-transform: translateX(-100%);\n transform: translateX(-100%);\n}\nto {\n -webkit-transform: translateX(100%);\n transform: translateX(100%);\n}\n}\n@keyframes p-skeleton-animation {\nfrom {\n -webkit-transform: translateX(-100%);\n transform: translateX(-100%);\n}\nto {\n -webkit-transform: translateX(100%);\n transform: translateX(100%);\n}\n}\n'),t.render=function(t,i,a,r,s,o){return n(),e("div",{style:o.containerStyle,class:o.containerClass},null,6)};export{t as default};
|
package/skeleton/skeleton.js
CHANGED
package/slider/Slider.d.ts
CHANGED
|
@@ -1,19 +1,95 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
1
|
+
import { ClassComponent, GlobalComponentConstructor } from '../ts-helpers';
|
|
2
|
+
|
|
3
|
+
type SliderOrientationType = 'horizontal' | 'vertical' | undefined;
|
|
4
|
+
|
|
5
|
+
export interface SliderSlideEndEvent {
|
|
6
|
+
/**
|
|
7
|
+
* Original event
|
|
8
|
+
*/
|
|
9
|
+
originalEvent: Event;
|
|
10
|
+
/**
|
|
11
|
+
* New value.
|
|
12
|
+
*/
|
|
13
|
+
value: number;
|
|
10
14
|
}
|
|
11
15
|
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
16
|
+
export interface SliderProps {
|
|
17
|
+
/**
|
|
18
|
+
* Value of the component.
|
|
19
|
+
* Default value is 0.
|
|
20
|
+
*/
|
|
21
|
+
modelValue?: number | number[] | undefined;
|
|
22
|
+
/**
|
|
23
|
+
* Mininum boundary value.
|
|
24
|
+
* Default value is 0.
|
|
25
|
+
*/
|
|
26
|
+
min?: number | undefined;
|
|
27
|
+
/**
|
|
28
|
+
* Maximum boundary value.
|
|
29
|
+
* Default value is 100.
|
|
30
|
+
*/
|
|
31
|
+
max?: number | undefined;
|
|
32
|
+
/**
|
|
33
|
+
* Orientation of the slider.
|
|
34
|
+
* @see SliderOrientationType
|
|
35
|
+
* Default value is 'horizontal'.
|
|
36
|
+
*/
|
|
37
|
+
orientation?: SliderOrientationType;
|
|
38
|
+
/**
|
|
39
|
+
* Step factor to increment/decrement the value.
|
|
40
|
+
* Default value is 1.
|
|
41
|
+
*/
|
|
42
|
+
step?: number | undefined;
|
|
43
|
+
/**
|
|
44
|
+
* When speficed, allows two boundary values to be picked.
|
|
45
|
+
*/
|
|
46
|
+
range?: boolean | undefined;
|
|
47
|
+
/**
|
|
48
|
+
* When present, it specifies that the component should be disabled.
|
|
49
|
+
*/
|
|
50
|
+
disabled?: boolean | undefined;
|
|
51
|
+
/**
|
|
52
|
+
* Establishes relationships between the component and label(s) where its value should be one or more element IDs.
|
|
53
|
+
*/
|
|
54
|
+
ariaLabelledBy?: string | undefined;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
export interface SliderSlots {
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
export declare type SliderEmits = {
|
|
61
|
+
/**
|
|
62
|
+
* Emitted when the value changes.
|
|
63
|
+
* @param {number | number[]} value - New value.
|
|
64
|
+
*/
|
|
65
|
+
'update:modelValue': (value: number | number[]) => void;
|
|
66
|
+
/**
|
|
67
|
+
* Callback to invoke on value change.
|
|
68
|
+
* @param {number} value - New value
|
|
69
|
+
*/
|
|
70
|
+
'change': (value: number) => void;
|
|
71
|
+
/**
|
|
72
|
+
* Callback to invoke when slide ends.
|
|
73
|
+
* @param {SliderSlideEndEvent} event - Custom slide end event.
|
|
74
|
+
*/
|
|
75
|
+
'slideend': (event: SliderSlideEndEvent) => void;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
declare class Slider extends ClassComponent<SliderProps, SliderSlots, SliderEmits> { }
|
|
79
|
+
|
|
80
|
+
declare module '@vue/runtime-core' {
|
|
81
|
+
interface GlobalComponents {
|
|
82
|
+
Slider: GlobalComponentConstructor<Slider>
|
|
83
|
+
}
|
|
17
84
|
}
|
|
18
85
|
|
|
86
|
+
/**
|
|
87
|
+
*
|
|
88
|
+
* Slider is an input component to provide a numerical input.
|
|
89
|
+
*
|
|
90
|
+
* Demos:
|
|
91
|
+
*
|
|
92
|
+
* - [Slider](https://www.primefaces.org/primevue/showcase/#/slider)
|
|
93
|
+
*
|
|
94
|
+
*/
|
|
19
95
|
export default Slider;
|
package/slider/slider.esm.js
CHANGED
package/slider/slider.esm.min.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{DomHandler as e}from"primevue/utils";import{openBlock as t,createBlock as i,createVNode as a,createCommentVNode as n}from"vue";var l={name:"Slider",emits:["update:modelValue","change","slideend"],props:{modelValue:[Number,Array],min:{type:Number,default:0},max:{type:Number,default:100},orientation:{type:String,default:"horizontal"},step:{type:Number,default:null},range:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},ariaLabelledBy:{type:String,default:null}},dragging:!1,handleIndex:null,initX:null,initY:null,barWidth:null,barHeight:null,dragListener:null,dragEndListener:null,beforeUnmount(){this.unbindDragListeners()},methods:{updateDomData(){let t=this.$el.getBoundingClientRect();this.initX=t.left+e.getWindowScrollLeft(),this.initY=t.top+e.getWindowScrollTop(),this.barWidth=this.$el.offsetWidth,this.barHeight=this.$el.offsetHeight},setValue(e){let t,i=e.touches?e.touches[0].pageX:e.pageX,a=e.touches?e.touches[0].pageY:e.pageY;t="horizontal"===this.orientation?100*(i-this.initX)/this.barWidth:100*(this.initY+this.barHeight-a)/this.barHeight;let n=(this.max-this.min)*(t/100)+this.min;if(this.step){const e=this.range?this.modelValue[this.handleIndex]:this.modelValue,t=n-e;t<0?n=e+Math.ceil(n/this.step-e/this.step)*this.step:t>0&&(n=e+Math.floor(n/this.step-e/this.step)*this.step)}else n=Math.floor(n);this.updateModel(e,n)},updateModel(e,t){let i,a=parseFloat(t.toFixed(10));if(this.range)if(i=this.modelValue?[...this.modelValue]:[],0==this.handleIndex){let e=this.modelValue?this.modelValue[1]:this.max;a<this.min?a=this.min:a>=e&&(a=e),i[0]=a,i[1]=i[1]||this.max}else{let e=this.modelValue?this.modelValue[0]:this.min;a>this.max?a=this.max:a<=e&&(a=e),i[0]=i[0]||this.min,i[1]=a}else a<this.min?a=this.min:a>this.max&&(a=this.max),i=a;this.$emit("update:modelValue",i),this.$emit("change",i)},onDragStart(t,i){this.disabled||(e.addClass(this.$el,"p-slider-sliding"),this.dragging=!0,this.updateDomData(),this.handleIndex=i,t.preventDefault())},onDrag(e){this.dragging&&(this.setValue(e),e.preventDefault())},onDragEnd(t){this.dragging&&(this.dragging=!1,e.removeClass(this.$el,"p-slider-sliding"),this.$emit("slideend",{originalEvent:t,value:this.modelValue}))},onBarClick(t){this.disabled||e.hasClass(t.target,"p-slider-handle")||(this.updateDomData(),this.setValue(t))},onMouseDown(e,t){this.bindDragListeners(),this.onDragStart(e,t)},onKeyDown(e,t){switch(this.handleIndex=t,e.which){case 40:this.vertical&&(this.decrementValue(e,t),e.preventDefault());break;case 38:this.vertical&&(this.incrementValue(e,t),e.preventDefault());break;case 37:this.horizontal&&(this.decrementValue(e,t),e.preventDefault());break;case 39:this.horizontal&&(this.incrementValue(e,t),e.preventDefault())}},decrementValue(e,t){let i;i=this.range?this.step?this.modelValue[t]-this.step:this.modelValue[t]-1:this.step?this.modelValue-this.step:this.modelValue-1,this.updateModel(e,i),e.preventDefault()},incrementValue(e,t){let i;i=this.range?this.step?this.modelValue[t]+this.step:this.modelValue[t]+1:this.step?this.modelValue+this.step:this.modelValue+1,this.updateModel(e,i),e.preventDefault()},bindDragListeners(){this.dragListener||(this.dragListener=this.onDrag.bind(this),document.addEventListener("mousemove",this.dragListener)),this.dragEndListener||(this.dragEndListener=this.onDragEnd.bind(this),document.addEventListener("mouseup",this.dragEndListener))},unbindDragListeners(){this.dragListener&&(document.removeEventListener("mousemove",this.dragListener),this.dragListener=null),this.dragEndListener&&(document.removeEventListener("mouseup",this.dragEndListener),this.dragEndListener=null)}},computed:{containerClass(){return["p-slider p-component",{"p-disabled":this.disabled,"p-slider-horizontal":"horizontal"===this.orientation,"p-slider-vertical":"vertical"===this.orientation}]},horizontal(){return"horizontal"===this.orientation},vertical(){return"vertical"===this.orientation},rangeStyle(){return this.range?this.horizontal?{left:this.rangeStartPosition+"%",width:this.rangeEndPosition-this.rangeStartPosition+"%"}:{bottom:this.rangeStartPosition+"%",height:this.rangeEndPosition-this.rangeStartHandlePosition+"%"}:this.horizontal?{width:this.handlePosition+"%"}:{height:this.handlePosition+"%"}},handleStyle(){return this.horizontal?{left:this.handlePosition+"%"}:{bottom:this.handlePosition+"%"}},handlePosition(){return this.modelValue<this.min?0:this.modelValue>this.max?100:100*(this.modelValue-this.min)/(this.max-this.min)},rangeStartPosition(){return this.modelValue&&this.modelValue[0]?100*(this.modelValue[0]<this.min?0:this.modelValue[0]-this.min)/(this.max-this.min):0},rangeEndPosition(){return this.modelValue&&this.modelValue[1]?100*(this.modelValue[1]>this.max?100:this.modelValue[1]-this.min)/(this.max-this.min):100},rangeStartHandleStyle(){return this.horizontal?{left:this.rangeStartPosition+"%"}:{bottom:this.rangeStartPosition+"%"}},rangeEndHandleStyle(){return this.horizontal?{left:this.rangeEndPosition+"%"}:{bottom:this.rangeEndPosition+"%"}}}};!function(e,t){void 0===t&&(t={});var i=t.insertAt;if(e&&"undefined"!=typeof document){var a=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css","top"===i&&a.firstChild?a.insertBefore(n,a.firstChild):a.appendChild(n),n.styleSheet?n.styleSheet.cssText=e:n.appendChild(document.createTextNode(e))}}("\n.p-slider {\n\tposition: relative;\n}\n.p-slider .p-slider-handle {\n\tposition: absolute;\n\tcursor: -webkit-grab;\n\tcursor: grab;\n -ms-touch-action: none;\n touch-action: none;\n display: block;\n}\n.p-slider-range {\n\tposition: absolute;\n display: block;\n}\n.p-slider-horizontal .p-slider-range {\n top: 0;\n left: 0;\n\theight: 100%;\n}\n.p-slider-horizontal .p-slider-handle {\n top: 50%;\n}\n.p-slider-vertical {\n\theight: 100px;\n}\n.p-slider-vertical .p-slider-handle {\n left: 50%;\n}\n.p-slider-vertical .p-slider-range {\n bottom: 0;\n left: 0;\n width: 100%;\n}\n"),l.render=function(e,l,s,o,r,h){return t(),i("div",{class:h.containerClass,onClick:l[16]||(l[16]=(...e)=>h.onBarClick&&h.onBarClick(...e))},[a("span",{class:"p-slider-range",style:h.rangeStyle},null,4),s.range?n("",!0):(t(),i("span",{key:0,class:"p-slider-handle",style:h.handleStyle,onTouchstart:l[1]||(l[1]=e=>h.onDragStart(e)),onTouchmove:l[2]||(l[2]=e=>h.onDrag(e)),onTouchend:l[3]||(l[3]=e=>h.onDragEnd(e)),onMousedown:l[4]||(l[4]=e=>h.onMouseDown(e)),onKeydown:l[5]||(l[5]=e=>h.onKeyDown(e)),tabindex:"0",role:"slider","aria-valuemin":s.min,"aria-valuenow":s.modelValue,"aria-valuemax":s.max,"aria-labelledby":s.ariaLabelledBy},null,44,["aria-valuemin","aria-valuenow","aria-valuemax","aria-labelledby"])),s.range?(t(),i("span",{key:1,class:"p-slider-handle",style:h.rangeStartHandleStyle,onTouchstart:l[6]||(l[6]=e=>h.onDragStart(e,0)),onTouchmove:l[7]||(l[7]=e=>h.onDrag(e)),onTouchend:l[8]||(l[8]=e=>h.onDragEnd(e)),onMousedown:l[9]||(l[9]=e=>h.onMouseDown(e,0)),onKeydown:l[10]||(l[10]=e=>h.onKeyDown(e)),tabindex:"0",role:"slider","aria-valuemin":s.min,"aria-valuenow":s.modelValue?s.modelValue[0]:null,"aria-valuemax":s.max,"aria-labelledby":s.ariaLabelledBy},null,44,["aria-valuemin","aria-valuenow","aria-valuemax","aria-labelledby"])):n("",!0),s.range?(t(),i("span",{key:2,class:"p-slider-handle",style:h.rangeEndHandleStyle,onTouchstart:l[11]||(l[11]=e=>h.onDragStart(e,1)),onTouchmove:l[12]||(l[12]=e=>h.onDrag(e)),onTouchend:l[13]||(l[13]=e=>h.onDragEnd(e)),onMousedown:l[14]||(l[14]=e=>h.onMouseDown(e,1)),onKeydown:l[15]||(l[15]=e=>h.onKeyDown(e,1)),tabindex:"0",role:"slider","aria-valuemin":s.min,"aria-valuenow":s.modelValue?s.modelValue[1]:null,"aria-valuemax":s.max,"aria-labelledby":s.ariaLabelledBy},null,44,["aria-valuemin","aria-valuenow","aria-valuemax","aria-labelledby"])):n("",!0)],2)};export default
|
|
1
|
+
import{DomHandler as e}from"primevue/utils";import{openBlock as t,createBlock as i,createVNode as a,createCommentVNode as n}from"vue";var l={name:"Slider",emits:["update:modelValue","change","slideend"],props:{modelValue:[Number,Array],min:{type:Number,default:0},max:{type:Number,default:100},orientation:{type:String,default:"horizontal"},step:{type:Number,default:null},range:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},ariaLabelledBy:{type:String,default:null}},dragging:!1,handleIndex:null,initX:null,initY:null,barWidth:null,barHeight:null,dragListener:null,dragEndListener:null,beforeUnmount(){this.unbindDragListeners()},methods:{updateDomData(){let t=this.$el.getBoundingClientRect();this.initX=t.left+e.getWindowScrollLeft(),this.initY=t.top+e.getWindowScrollTop(),this.barWidth=this.$el.offsetWidth,this.barHeight=this.$el.offsetHeight},setValue(e){let t,i=e.touches?e.touches[0].pageX:e.pageX,a=e.touches?e.touches[0].pageY:e.pageY;t="horizontal"===this.orientation?100*(i-this.initX)/this.barWidth:100*(this.initY+this.barHeight-a)/this.barHeight;let n=(this.max-this.min)*(t/100)+this.min;if(this.step){const e=this.range?this.modelValue[this.handleIndex]:this.modelValue,t=n-e;t<0?n=e+Math.ceil(n/this.step-e/this.step)*this.step:t>0&&(n=e+Math.floor(n/this.step-e/this.step)*this.step)}else n=Math.floor(n);this.updateModel(e,n)},updateModel(e,t){let i,a=parseFloat(t.toFixed(10));if(this.range)if(i=this.modelValue?[...this.modelValue]:[],0==this.handleIndex){let e=this.modelValue?this.modelValue[1]:this.max;a<this.min?a=this.min:a>=e&&(a=e),i[0]=a,i[1]=i[1]||this.max}else{let e=this.modelValue?this.modelValue[0]:this.min;a>this.max?a=this.max:a<=e&&(a=e),i[0]=i[0]||this.min,i[1]=a}else a<this.min?a=this.min:a>this.max&&(a=this.max),i=a;this.$emit("update:modelValue",i),this.$emit("change",i)},onDragStart(t,i){this.disabled||(e.addClass(this.$el,"p-slider-sliding"),this.dragging=!0,this.updateDomData(),this.handleIndex=i,t.preventDefault())},onDrag(e){this.dragging&&(this.setValue(e),e.preventDefault())},onDragEnd(t){this.dragging&&(this.dragging=!1,e.removeClass(this.$el,"p-slider-sliding"),this.$emit("slideend",{originalEvent:t,value:this.modelValue}))},onBarClick(t){this.disabled||e.hasClass(t.target,"p-slider-handle")||(this.updateDomData(),this.setValue(t))},onMouseDown(e,t){this.bindDragListeners(),this.onDragStart(e,t)},onKeyDown(e,t){switch(this.handleIndex=t,e.which){case 40:this.vertical&&(this.decrementValue(e,t),e.preventDefault());break;case 38:this.vertical&&(this.incrementValue(e,t),e.preventDefault());break;case 37:this.horizontal&&(this.decrementValue(e,t),e.preventDefault());break;case 39:this.horizontal&&(this.incrementValue(e,t),e.preventDefault())}},decrementValue(e,t){let i;i=this.range?this.step?this.modelValue[t]-this.step:this.modelValue[t]-1:this.step?this.modelValue-this.step:this.modelValue-1,this.updateModel(e,i),e.preventDefault()},incrementValue(e,t){let i;i=this.range?this.step?this.modelValue[t]+this.step:this.modelValue[t]+1:this.step?this.modelValue+this.step:this.modelValue+1,this.updateModel(e,i),e.preventDefault()},bindDragListeners(){this.dragListener||(this.dragListener=this.onDrag.bind(this),document.addEventListener("mousemove",this.dragListener)),this.dragEndListener||(this.dragEndListener=this.onDragEnd.bind(this),document.addEventListener("mouseup",this.dragEndListener))},unbindDragListeners(){this.dragListener&&(document.removeEventListener("mousemove",this.dragListener),this.dragListener=null),this.dragEndListener&&(document.removeEventListener("mouseup",this.dragEndListener),this.dragEndListener=null)}},computed:{containerClass(){return["p-slider p-component",{"p-disabled":this.disabled,"p-slider-horizontal":"horizontal"===this.orientation,"p-slider-vertical":"vertical"===this.orientation}]},horizontal(){return"horizontal"===this.orientation},vertical(){return"vertical"===this.orientation},rangeStyle(){return this.range?this.horizontal?{left:this.rangeStartPosition+"%",width:this.rangeEndPosition-this.rangeStartPosition+"%"}:{bottom:this.rangeStartPosition+"%",height:this.rangeEndPosition-this.rangeStartHandlePosition+"%"}:this.horizontal?{width:this.handlePosition+"%"}:{height:this.handlePosition+"%"}},handleStyle(){return this.horizontal?{left:this.handlePosition+"%"}:{bottom:this.handlePosition+"%"}},handlePosition(){return this.modelValue<this.min?0:this.modelValue>this.max?100:100*(this.modelValue-this.min)/(this.max-this.min)},rangeStartPosition(){return this.modelValue&&this.modelValue[0]?100*(this.modelValue[0]<this.min?0:this.modelValue[0]-this.min)/(this.max-this.min):0},rangeEndPosition(){return this.modelValue&&this.modelValue[1]?100*(this.modelValue[1]>this.max?100:this.modelValue[1]-this.min)/(this.max-this.min):100},rangeStartHandleStyle(){return this.horizontal?{left:this.rangeStartPosition+"%"}:{bottom:this.rangeStartPosition+"%"}},rangeEndHandleStyle(){return this.horizontal?{left:this.rangeEndPosition+"%"}:{bottom:this.rangeEndPosition+"%"}}}};!function(e,t){void 0===t&&(t={});var i=t.insertAt;if(e&&"undefined"!=typeof document){var a=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css","top"===i&&a.firstChild?a.insertBefore(n,a.firstChild):a.appendChild(n),n.styleSheet?n.styleSheet.cssText=e:n.appendChild(document.createTextNode(e))}}("\n.p-slider {\n\tposition: relative;\n}\n.p-slider .p-slider-handle {\n\tposition: absolute;\n\tcursor: -webkit-grab;\n\tcursor: grab;\n -ms-touch-action: none;\n touch-action: none;\n display: block;\n}\n.p-slider-range {\n\tposition: absolute;\n display: block;\n}\n.p-slider-horizontal .p-slider-range {\n top: 0;\n left: 0;\n\theight: 100%;\n}\n.p-slider-horizontal .p-slider-handle {\n top: 50%;\n}\n.p-slider-vertical {\n\theight: 100px;\n}\n.p-slider-vertical .p-slider-handle {\n left: 50%;\n}\n.p-slider-vertical .p-slider-range {\n bottom: 0;\n left: 0;\n width: 100%;\n}\n"),l.render=function(e,l,s,o,r,h){return t(),i("div",{class:h.containerClass,onClick:l[16]||(l[16]=(...e)=>h.onBarClick&&h.onBarClick(...e))},[a("span",{class:"p-slider-range",style:h.rangeStyle},null,4),s.range?n("",!0):(t(),i("span",{key:0,class:"p-slider-handle",style:h.handleStyle,onTouchstart:l[1]||(l[1]=e=>h.onDragStart(e)),onTouchmove:l[2]||(l[2]=e=>h.onDrag(e)),onTouchend:l[3]||(l[3]=e=>h.onDragEnd(e)),onMousedown:l[4]||(l[4]=e=>h.onMouseDown(e)),onKeydown:l[5]||(l[5]=e=>h.onKeyDown(e)),tabindex:"0",role:"slider","aria-valuemin":s.min,"aria-valuenow":s.modelValue,"aria-valuemax":s.max,"aria-labelledby":s.ariaLabelledBy},null,44,["aria-valuemin","aria-valuenow","aria-valuemax","aria-labelledby"])),s.range?(t(),i("span",{key:1,class:"p-slider-handle",style:h.rangeStartHandleStyle,onTouchstart:l[6]||(l[6]=e=>h.onDragStart(e,0)),onTouchmove:l[7]||(l[7]=e=>h.onDrag(e)),onTouchend:l[8]||(l[8]=e=>h.onDragEnd(e)),onMousedown:l[9]||(l[9]=e=>h.onMouseDown(e,0)),onKeydown:l[10]||(l[10]=e=>h.onKeyDown(e)),tabindex:"0",role:"slider","aria-valuemin":s.min,"aria-valuenow":s.modelValue?s.modelValue[0]:null,"aria-valuemax":s.max,"aria-labelledby":s.ariaLabelledBy},null,44,["aria-valuemin","aria-valuenow","aria-valuemax","aria-labelledby"])):n("",!0),s.range?(t(),i("span",{key:2,class:"p-slider-handle",style:h.rangeEndHandleStyle,onTouchstart:l[11]||(l[11]=e=>h.onDragStart(e,1)),onTouchmove:l[12]||(l[12]=e=>h.onDrag(e)),onTouchend:l[13]||(l[13]=e=>h.onDragEnd(e)),onMousedown:l[14]||(l[14]=e=>h.onMouseDown(e,1)),onKeydown:l[15]||(l[15]=e=>h.onKeyDown(e,1)),tabindex:"0",role:"slider","aria-valuemin":s.min,"aria-valuenow":s.modelValue?s.modelValue[1]:null,"aria-valuemax":s.max,"aria-labelledby":s.ariaLabelledBy},null,44,["aria-valuemin","aria-valuenow","aria-valuemax","aria-labelledby"])):n("",!0)],2)};export{l as default};
|
package/slider/slider.js
CHANGED