primevue 4.2.5 → 4.3.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/LICENSE.md +1 -1
- package/accordion/Accordion.vue +0 -8
- package/accordion/index.mjs +1 -9
- package/accordion/index.mjs.map +1 -1
- package/accordion/style/index.mjs +2 -5
- package/accordion/style/index.mjs.map +1 -1
- package/accordioncontent/index.mjs +1 -1
- package/accordionheader/AccordionHeader.vue +2 -2
- package/accordionheader/index.mjs +4 -4
- package/accordionheader/index.mjs.map +1 -1
- package/accordionpanel/index.mjs +1 -1
- package/animateonscroll/index.d.ts +1 -1
- package/animateonscroll/index.mjs +4 -4
- package/animateonscroll/index.mjs.map +1 -1
- package/animateonscroll/style/index.d.ts +1 -1
- package/autocomplete/AutoComplete.vue +90 -23
- package/autocomplete/index.d.ts +19 -2
- package/autocomplete/index.mjs +127 -55
- package/autocomplete/index.mjs.map +1 -1
- package/autocomplete/style/index.mjs +15 -19
- package/autocomplete/style/index.mjs.map +1 -1
- package/avatar/index.mjs +1 -1
- package/avatar/style/index.mjs +4 -7
- package/avatar/style/index.mjs.map +1 -1
- package/avatargroup/index.mjs +1 -1
- package/badge/index.mjs +1 -1
- package/badge/style/index.mjs +6 -9
- package/badge/style/index.mjs.map +1 -1
- package/badgedirective/index.mjs +6 -6
- package/badgedirective/index.mjs.map +1 -1
- package/blockui/BlockUI.vue +2 -1
- package/blockui/index.mjs +3 -2
- package/blockui/index.mjs.map +1 -1
- package/blockui/style/index.mjs +2 -5
- package/blockui/style/index.mjs.map +1 -1
- package/breadcrumb/index.mjs +1 -1
- package/breadcrumb/style/index.mjs +4 -7
- package/breadcrumb/style/index.mjs.map +1 -1
- package/button/Button.vue +1 -1
- package/button/index.d.ts +11 -1
- package/button/index.mjs +5 -4
- package/button/index.mjs.map +1 -1
- package/button/style/index.mjs +9 -12
- package/button/style/index.mjs.map +1 -1
- package/buttongroup/index.mjs +1 -1
- package/buttongroup/style/index.mjs +2 -5
- package/buttongroup/style/index.mjs.map +1 -1
- package/card/index.mjs +1 -1
- package/card/style/index.mjs +2 -5
- package/card/style/index.mjs.map +1 -1
- package/carousel/index.mjs +2 -2
- package/carousel/index.mjs.map +1 -1
- package/carousel/style/index.mjs +19 -22
- package/carousel/style/index.mjs.map +1 -1
- package/cascadeselect/CascadeSelect.vue +16 -17
- package/cascadeselect/CascadeSelectSub.vue +1 -1
- package/cascadeselect/index.d.ts +2 -2
- package/cascadeselect/index.mjs +26 -28
- package/cascadeselect/index.mjs.map +1 -1
- package/cascadeselect/style/index.mjs +17 -19
- package/cascadeselect/style/index.mjs.map +1 -1
- package/chart/index.mjs +4 -4
- package/checkbox/index.d.ts +2 -2
- package/checkbox/index.mjs +2 -2
- package/checkbox/index.mjs.map +1 -1
- package/checkbox/style/index.mjs +5 -8
- package/checkbox/style/index.mjs.map +1 -1
- package/checkboxgroup/index.mjs +1 -1
- package/checkboxgroup/style/index.mjs +2 -5
- package/checkboxgroup/style/index.mjs.map +1 -1
- package/chip/index.mjs +1 -1
- package/chip/style/index.mjs +2 -5
- package/chip/style/index.mjs.map +1 -1
- package/colorpicker/ColorPicker.vue +2 -2
- package/colorpicker/index.mjs +7 -7
- package/colorpicker/index.mjs.map +1 -1
- package/colorpicker/style/index.mjs +7 -10
- package/colorpicker/style/index.mjs.map +1 -1
- package/column/BaseColumn.vue +1 -1
- package/column/index.d.ts +2 -2
- package/column/index.mjs +1 -1
- package/column/index.mjs.map +1 -1
- package/columngroup/index.mjs.map +1 -1
- package/confirmdialog/index.d.ts +4 -0
- package/confirmdialog/index.mjs +1 -1
- package/confirmdialog/index.mjs.map +1 -1
- package/confirmdialog/style/index.mjs +2 -5
- package/confirmdialog/style/index.mjs.map +1 -1
- package/confirmpopup/ConfirmPopup.vue +2 -2
- package/confirmpopup/index.mjs +4 -4
- package/confirmpopup/index.mjs.map +1 -1
- package/confirmpopup/style/index.mjs +2 -5
- package/confirmpopup/style/index.mjs.map +1 -1
- package/contextmenu/ContextMenu.vue +6 -12
- package/contextmenu/index.mjs +9 -15
- package/contextmenu/index.mjs.map +1 -1
- package/contextmenu/style/index.mjs +7 -10
- package/contextmenu/style/index.mjs.map +1 -1
- package/datatable/BodyCell.vue +24 -14
- package/datatable/BodyRow.vue +0 -1
- package/datatable/ColumnFilter.vue +10 -16
- package/datatable/DataTable.vue +6 -6
- package/datatable/FilterHeaderCell.vue +189 -0
- package/datatable/FooterCell.vue +2 -2
- package/datatable/HeaderCell.vue +4 -4
- package/datatable/TableBody.vue +3 -10
- package/datatable/TableHeader.vue +23 -50
- package/datatable/index.d.ts +89 -39
- package/datatable/index.mjs +444 -234
- package/datatable/index.mjs.map +1 -1
- package/datatable/style/index.mjs +32 -36
- package/datatable/style/index.mjs.map +1 -1
- package/dataview/index.mjs +2 -2
- package/dataview/index.mjs.map +1 -1
- package/dataview/style/index.mjs +6 -9
- package/dataview/style/index.mjs.map +1 -1
- package/datepicker/BaseDatePicker.vue +0 -4
- package/datepicker/DatePicker.vue +46 -20
- package/datepicker/index.d.ts +2 -6
- package/datepicker/index.mjs +78 -52
- package/datepicker/index.mjs.map +1 -1
- package/datepicker/style/index.mjs +26 -28
- package/datepicker/style/index.mjs.map +1 -1
- package/deferredcontent/index.mjs +1 -1
- package/dialog/Dialog.vue +3 -11
- package/dialog/index.d.ts +1 -1
- package/dialog/index.mjs +7 -14
- package/dialog/index.mjs.map +1 -1
- package/dialog/style/index.mjs +10 -14
- package/dialog/style/index.mjs.map +1 -1
- package/divider/index.mjs +1 -1
- package/divider/style/index.mjs +6 -10
- package/divider/style/index.mjs.map +1 -1
- package/dock/DockSub.vue +5 -13
- package/dock/index.mjs +6 -14
- package/dock/index.mjs.map +1 -1
- package/dock/style/index.mjs +9 -12
- package/dock/style/index.mjs.map +1 -1
- package/drawer/Drawer.vue +7 -4
- package/drawer/index.d.ts +4 -0
- package/drawer/index.mjs +7 -5
- package/drawer/index.mjs.map +1 -1
- package/drawer/style/index.mjs +10 -13
- package/drawer/style/index.mjs.map +1 -1
- package/dynamicdialog/DynamicDialog.vue +5 -5
- package/dynamicdialog/index.mjs +8 -6
- package/dynamicdialog/index.mjs.map +1 -1
- package/editor/Editor.vue +9 -11
- package/editor/index.d.ts +0 -15
- package/editor/index.mjs +16 -16
- package/editor/index.mjs.map +1 -1
- package/editor/style/index.mjs +4 -7
- package/editor/style/index.mjs.map +1 -1
- package/fieldset/Fieldset.vue +4 -12
- package/fieldset/index.mjs +9 -17
- package/fieldset/index.mjs.map +1 -1
- package/fieldset/style/index.mjs +4 -7
- package/fieldset/style/index.mjs.map +1 -1
- package/fileupload/FileUpload.vue +9 -7
- package/fileupload/index.d.ts +3 -3
- package/fileupload/index.mjs +12 -10
- package/fileupload/index.mjs.map +1 -1
- package/fileupload/style/index.mjs +4 -7
- package/fileupload/style/index.mjs.map +1 -1
- package/floatlabel/index.mjs +1 -1
- package/floatlabel/style/index.mjs +4 -8
- package/floatlabel/style/index.mjs.map +1 -1
- package/fluid/index.mjs +1 -1
- package/focustrap/index.mjs +4 -4
- package/focustrap/index.mjs.map +1 -1
- package/galleria/Galleria.vue +2 -1
- package/galleria/GalleriaContent.vue +3 -11
- package/galleria/GalleriaThumbnails.vue +15 -8
- package/galleria/index.mjs +28 -30
- package/galleria/index.mjs.map +1 -1
- package/galleria/style/index.mjs +23 -26
- package/galleria/style/index.mjs.map +1 -1
- package/iconfield/index.mjs +1 -1
- package/iconfield/style/index.mjs +2 -5
- package/iconfield/style/index.mjs.map +1 -1
- package/iftalabel/index.mjs +1 -1
- package/iftalabel/style/index.mjs +2 -5
- package/iftalabel/style/index.mjs.map +1 -1
- package/image/Image.vue +2 -1
- package/image/index.d.ts +4 -0
- package/image/index.mjs +6 -5
- package/image/index.mjs.map +1 -1
- package/image/style/index.mjs +8 -11
- package/image/style/index.mjs.map +1 -1
- package/imagecompare/index.mjs +1 -1
- package/imagecompare/style/index.mjs +2 -5
- package/imagecompare/style/index.mjs.map +1 -1
- package/index.d.ts +3 -0
- package/index.mjs +1 -0
- package/index.mjs.map +1 -1
- package/inlinemessage/index.mjs +1 -1
- package/inlinemessage/style/index.mjs +7 -10
- package/inlinemessage/style/index.mjs.map +1 -1
- package/inplace/index.mjs +4 -4
- package/inplace/style/index.mjs +4 -7
- package/inplace/style/index.mjs.map +1 -1
- package/inputchips/InputChips.vue +2 -10
- package/inputchips/index.mjs +6 -14
- package/inputchips/index.mjs.map +1 -1
- package/inputchips/style/index.mjs +11 -14
- package/inputchips/style/index.mjs.map +1 -1
- package/inputgroup/index.mjs +1 -1
- package/inputgroup/style/index.mjs +2 -5
- package/inputgroup/style/index.mjs.map +1 -1
- package/inputgroupaddon/index.mjs +1 -1
- package/inputicon/index.mjs +1 -1
- package/inputmask/InputMask.vue +26 -17
- package/inputmask/index.d.ts +2 -2
- package/inputmask/index.mjs +28 -17
- package/inputmask/index.mjs.map +1 -1
- package/inputnumber/InputNumber.vue +17 -6
- package/inputnumber/index.d.ts +4 -4
- package/inputnumber/index.mjs +20 -12
- package/inputnumber/index.mjs.map +1 -1
- package/inputnumber/style/index.mjs +12 -14
- package/inputnumber/style/index.mjs.map +1 -1
- package/inputotp/index.d.ts +23 -8
- package/inputotp/index.mjs +1 -1
- package/inputotp/style/index.mjs +2 -5
- package/inputotp/style/index.mjs.map +1 -1
- package/inputtext/InputText.vue +1 -1
- package/inputtext/index.d.ts +1 -1
- package/inputtext/index.mjs +3 -2
- package/inputtext/index.mjs.map +1 -1
- package/inputtext/style/index.mjs +5 -8
- package/inputtext/style/index.mjs.map +1 -1
- package/keyfilter/index.mjs +8 -9
- package/keyfilter/index.mjs.map +1 -1
- package/knob/index.mjs +3 -3
- package/knob/index.mjs.map +1 -1
- package/knob/style/index.mjs +5 -8
- package/knob/style/index.mjs.map +1 -1
- package/listbox/Listbox.vue +7 -13
- package/listbox/index.mjs +10 -16
- package/listbox/index.mjs.map +1 -1
- package/listbox/style/index.mjs +11 -14
- package/listbox/style/index.mjs.map +1 -1
- package/megamenu/MegaMenu.vue +9 -15
- package/megamenu/index.mjs +12 -18
- package/megamenu/index.mjs.map +1 -1
- package/megamenu/style/index.mjs +15 -18
- package/megamenu/style/index.mjs.map +1 -1
- package/menu/Menu.vue +9 -17
- package/menu/index.d.ts +10 -0
- package/menu/index.mjs +10 -17
- package/menu/index.mjs.map +1 -1
- package/menu/style/index.mjs +6 -9
- package/menu/style/index.mjs.map +1 -1
- package/menubar/Menubar.vue +10 -16
- package/menubar/index.mjs +14 -20
- package/menubar/index.mjs.map +1 -1
- package/menubar/style/index.mjs +10 -13
- package/menubar/style/index.mjs.map +1 -1
- package/message/index.mjs +4 -4
- package/message/style/index.mjs +4 -7
- package/message/style/index.mjs.map +1 -1
- package/metergroup/index.mjs +1 -1
- package/metergroup/style/index.mjs +6 -9
- package/metergroup/style/index.mjs.map +1 -1
- package/multiselect/MultiSelect.vue +23 -18
- package/multiselect/index.d.ts +12 -6
- package/multiselect/index.mjs +32 -28
- package/multiselect/index.mjs.map +1 -1
- package/multiselect/style/index.mjs +17 -20
- package/multiselect/style/index.mjs.map +1 -1
- package/orderlist/OrderList.vue +1 -10
- package/orderlist/index.mjs +7 -15
- package/orderlist/index.mjs.map +1 -1
- package/orderlist/style/index.mjs +2 -5
- package/orderlist/style/index.mjs.map +1 -1
- package/organizationchart/index.mjs +4 -4
- package/organizationchart/style/index.mjs +9 -12
- package/organizationchart/style/index.mjs.map +1 -1
- package/overlaybadge/index.mjs +1 -1
- package/overlaybadge/style/index.mjs +2 -5
- package/overlaybadge/style/index.mjs.map +1 -1
- package/package.json +6 -5
- package/paginator/index.mjs +2 -2
- package/paginator/index.mjs.map +1 -1
- package/paginator/style/index.mjs +18 -21
- package/paginator/style/index.mjs.map +1 -1
- package/panel/Panel.vue +5 -13
- package/panel/index.mjs +7 -15
- package/panel/index.mjs.map +1 -1
- package/panel/style/index.mjs +4 -7
- package/panel/style/index.mjs.map +1 -1
- package/panelmenu/PanelMenu.vue +2 -12
- package/panelmenu/index.mjs +8 -18
- package/panelmenu/index.mjs.map +1 -1
- package/panelmenu/style/index.mjs +8 -11
- package/panelmenu/style/index.mjs.map +1 -1
- package/passthrough/index.mjs +3 -3
- package/password/Password.vue +3 -10
- package/password/index.d.ts +2 -2
- package/password/index.mjs +9 -16
- package/password/index.mjs.map +1 -1
- package/password/style/index.mjs +8 -11
- package/password/style/index.mjs.map +1 -1
- package/picklist/PickList.vue +2 -9
- package/picklist/index.mjs +8 -14
- package/picklist/index.mjs.map +1 -1
- package/picklist/style/index.mjs +2 -5
- package/picklist/style/index.mjs.map +1 -1
- package/popover/Popover.vue +2 -2
- package/popover/index.mjs +4 -4
- package/popover/index.mjs.map +1 -1
- package/popover/style/index.mjs +2 -5
- package/popover/style/index.mjs.map +1 -1
- package/portal/index.mjs +1 -1
- package/progressbar/index.mjs +1 -1
- package/progressbar/style/index.mjs +4 -7
- package/progressbar/style/index.mjs.map +1 -1
- package/progressspinner/index.mjs +1 -1
- package/progressspinner/style/index.mjs +2 -5
- package/progressspinner/style/index.mjs.map +1 -1
- package/radiobutton/index.d.ts +2 -2
- package/radiobutton/index.mjs +1 -1
- package/radiobutton/index.mjs.map +1 -1
- package/radiobutton/style/index.mjs +5 -8
- package/radiobutton/style/index.mjs.map +1 -1
- package/radiobuttongroup/index.mjs +1 -1
- package/radiobuttongroup/style/index.mjs +2 -5
- package/radiobuttongroup/style/index.mjs.map +1 -1
- package/rating/Rating.vue +6 -11
- package/rating/index.mjs +7 -12
- package/rating/index.mjs.map +1 -1
- package/rating/style/index.mjs +11 -14
- package/rating/style/index.mjs.map +1 -1
- package/ripple/index.mjs +16 -13
- package/ripple/index.mjs.map +1 -1
- package/ripple/style/index.mjs +2 -5
- package/ripple/style/index.mjs.map +1 -1
- package/row/index.mjs.map +1 -1
- package/scrollpanel/ScrollPanel.vue +1 -10
- package/scrollpanel/index.mjs +3 -11
- package/scrollpanel/index.mjs.map +1 -1
- package/scrollpanel/style/index.mjs +2 -5
- package/scrollpanel/style/index.mjs.map +1 -1
- package/scrolltop/index.mjs +1 -1
- package/scrolltop/style/index.mjs +4 -7
- package/scrolltop/style/index.mjs.map +1 -1
- package/select/Select.vue +55 -26
- package/select/index.d.ts +9 -5
- package/select/index.mjs +89 -63
- package/select/index.mjs.map +1 -1
- package/select/style/index.mjs +15 -18
- package/select/style/index.mjs.map +1 -1
- package/selectbutton/index.mjs +3 -3
- package/selectbutton/style/index.mjs +4 -7
- package/selectbutton/style/index.mjs.map +1 -1
- package/skeleton/index.mjs +1 -1
- package/skeleton/style/index.mjs +4 -7
- package/skeleton/style/index.mjs.map +1 -1
- package/slider/Slider.vue +1 -1
- package/slider/index.mjs +3 -3
- package/slider/index.mjs.map +1 -1
- package/slider/style/index.mjs +5 -8
- package/slider/style/index.mjs.map +1 -1
- package/speeddial/SpeedDial.vue +8 -15
- package/speeddial/index.d.ts +1 -1
- package/speeddial/index.mjs +13 -19
- package/speeddial/index.mjs.map +1 -1
- package/speeddial/style/index.mjs +15 -18
- package/speeddial/style/index.mjs.map +1 -1
- package/splitbutton/SplitButton.vue +2 -11
- package/splitbutton/index.d.ts +2 -2
- package/splitbutton/index.mjs +3 -11
- package/splitbutton/index.mjs.map +1 -1
- package/splitbutton/style/index.mjs +5 -8
- package/splitbutton/style/index.mjs.map +1 -1
- package/splitter/Splitter.vue +31 -14
- package/splitter/index.d.ts +1 -1
- package/splitter/index.mjs +28 -14
- package/splitter/index.mjs.map +1 -1
- package/splitter/style/index.mjs +6 -9
- package/splitter/style/index.mjs.map +1 -1
- package/splitterpanel/index.mjs +1 -1
- package/step/index.mjs +1 -1
- package/step/index.mjs.map +1 -1
- package/stepitem/index.mjs +1 -1
- package/stepitem/index.mjs.map +1 -1
- package/steplist/index.mjs +1 -1
- package/steppanel/index.mjs +1 -1
- package/steppanel/index.mjs.map +1 -1
- package/steppanels/index.mjs +1 -1
- package/stepper/Stepper.vue +0 -8
- package/stepper/index.mjs +1 -9
- package/stepper/index.mjs.map +1 -1
- package/stepper/style/index.mjs +4 -7
- package/stepper/style/index.mjs.map +1 -1
- package/steps/index.mjs +2 -2
- package/steps/style/index.mjs +8 -11
- package/steps/style/index.mjs.map +1 -1
- package/styleclass/index.mjs +1 -1
- package/tab/Tab.vue +3 -3
- package/tab/index.mjs +4 -4
- package/tab/index.mjs.map +1 -1
- package/tablist/TabList.vue +2 -2
- package/tablist/index.mjs +4 -4
- package/tablist/index.mjs.map +1 -1
- package/tabmenu/index.mjs +2 -2
- package/tabmenu/index.mjs.map +1 -1
- package/tabmenu/style/index.mjs +6 -9
- package/tabmenu/style/index.mjs.map +1 -1
- package/tabpanel/index.mjs +1 -1
- package/tabpanel/index.mjs.map +1 -1
- package/tabpanels/index.mjs +1 -1
- package/tabs/Tabs.vue +0 -8
- package/tabs/index.mjs +1 -9
- package/tabs/index.mjs.map +1 -1
- package/tabs/style/index.mjs +4 -7
- package/tabs/style/index.mjs.map +1 -1
- package/tabview/TabView.vue +3 -9
- package/tabview/index.mjs +7 -13
- package/tabview/index.mjs.map +1 -1
- package/tabview/style/index.mjs +11 -14
- package/tabview/style/index.mjs.map +1 -1
- package/tag/index.mjs +1 -1
- package/tag/style/index.mjs +4 -7
- package/tag/style/index.mjs.map +1 -1
- package/terminal/index.mjs +1 -1
- package/terminal/style/index.mjs +2 -5
- package/terminal/style/index.mjs.map +1 -1
- package/textarea/Textarea.vue +5 -2
- package/textarea/index.d.ts +4 -4
- package/textarea/index.mjs +7 -3
- package/textarea/index.mjs.map +1 -1
- package/textarea/style/index.mjs +5 -8
- package/textarea/style/index.mjs.map +1 -1
- package/tieredmenu/TieredMenu.vue +8 -13
- package/tieredmenu/index.mjs +11 -16
- package/tieredmenu/index.mjs.map +1 -1
- package/tieredmenu/style/index.mjs +11 -14
- package/tieredmenu/style/index.mjs.map +1 -1
- package/timeline/index.d.ts +4 -0
- package/timeline/index.mjs +1 -1
- package/timeline/style/index.mjs +4 -7
- package/timeline/style/index.mjs.map +1 -1
- package/toast/BaseToast.vue +12 -0
- package/toast/ToastMessage.vue +38 -4
- package/toast/index.d.ts +12 -0
- package/toast/index.mjs +79 -15
- package/toast/index.mjs.map +1 -1
- package/toast/style/index.mjs +12 -15
- package/toast/style/index.mjs.map +1 -1
- package/togglebutton/ToggleButton.vue +1 -0
- package/togglebutton/index.mjs +3 -2
- package/togglebutton/index.mjs.map +1 -1
- package/togglebutton/style/index.mjs +5 -8
- package/togglebutton/style/index.mjs.map +1 -1
- package/toggleswitch/index.mjs +1 -1
- package/toggleswitch/index.mjs.map +1 -1
- package/toggleswitch/style/index.mjs +5 -8
- package/toggleswitch/style/index.mjs.map +1 -1
- package/toolbar/index.mjs +1 -1
- package/toolbar/style/index.mjs +2 -5
- package/toolbar/style/index.mjs.map +1 -1
- package/tooltip/index.mjs +62 -14
- package/tooltip/index.mjs.map +1 -1
- package/tooltip/style/index.mjs +2 -5
- package/tooltip/style/index.mjs.map +1 -1
- package/tree/Tree.vue +2 -2
- package/tree/index.mjs +16 -16
- package/tree/index.mjs.map +1 -1
- package/tree/style/index.mjs +8 -11
- package/tree/style/index.mjs.map +1 -1
- package/treeselect/TreeSelect.vue +21 -26
- package/treeselect/index.d.ts +2 -2
- package/treeselect/index.mjs +56 -72
- package/treeselect/index.mjs.map +1 -1
- package/treeselect/style/index.mjs +10 -13
- package/treeselect/style/index.mjs.map +1 -1
- package/treetable/BodyCell.vue +8 -5
- package/treetable/FooterCell.vue +2 -2
- package/treetable/HeaderCell.vue +4 -4
- package/treetable/index.d.ts +29 -0
- package/treetable/index.mjs +42 -35
- package/treetable/index.mjs.map +1 -1
- package/treetable/style/index.mjs +22 -25
- package/treetable/style/index.mjs.map +1 -1
- package/umd/primevue.min.js +1 -1
- package/utils/index.d.ts +9 -0
- package/utils/index.mjs +16 -0
- package/utils/index.mjs.map +1 -0
- package/utils/package.json +5 -0
- package/virtualscroller/VirtualScroller.vue +16 -10
- package/virtualscroller/index.mjs +21 -15
- package/virtualscroller/index.mjs.map +1 -1
- package/virtualscroller/style/index.mjs +2 -5
- package/virtualscroller/style/index.mjs.map +1 -1
- package/web-types.json +1 -1
|
@@ -1,13 +1,9 @@
|
|
|
1
|
+
import { style } from '@primeuix/styles/floatlabel';
|
|
1
2
|
import BaseStyle from '@primevue/core/base/style';
|
|
2
3
|
|
|
3
|
-
var theme = function theme(_ref) {
|
|
4
|
-
var dt = _ref.dt;
|
|
5
|
-
return "\n.p-floatlabel {\n display: block;\n position: relative;\n}\n\n.p-floatlabel label {\n position: absolute;\n pointer-events: none;\n top: 50%;\n transform: translateY(-50%);\n transition-property: all;\n transition-timing-function: ease;\n line-height: 1;\n font-weight: ".concat(dt('floatlabel.font.weight'), ";\n inset-inline-start: ").concat(dt('floatlabel.position.x'), ";\n color: ").concat(dt('floatlabel.color'), ";\n transition-duration: ").concat(dt('floatlabel.transition.duration'), ";\n}\n\n.p-floatlabel:has(.p-textarea) label {\n top: ").concat(dt('floatlabel.position.y'), ";\n transform: translateY(0);\n}\n\n.p-floatlabel:has(.p-inputicon:first-child) label {\n inset-inline-start: calc((").concat(dt('form.field.padding.x'), " * 2) + ").concat(dt('icon.size'), ");\n}\n\n.p-floatlabel:has(.p-invalid) label {\n color: ").concat(dt('floatlabel.invalid.color'), ";\n}\n\n.p-floatlabel:has(input:focus) label,\n.p-floatlabel:has(input.p-filled) label,\n.p-floatlabel:has(input:-webkit-autofill) label,\n.p-floatlabel:has(textarea:focus) label,\n.p-floatlabel:has(textarea.p-filled) label,\n.p-floatlabel:has(.p-inputwrapper-focus) label,\n.p-floatlabel:has(.p-inputwrapper-filled) label {\n top: ").concat(dt('floatlabel.over.active.top'), ";\n transform: translateY(0);\n font-size: ").concat(dt('floatlabel.active.font.size'), ";\n font-weight: ").concat(dt('floatlabel.label.active.font.weight'), ";\n}\n\n.p-floatlabel:has(input.p-filled) label,\n.p-floatlabel:has(textarea.p-filled) label,\n.p-floatlabel:has(.p-inputwrapper-filled) label {\n color: ").concat(dt('floatlabel.active.color'), ";\n}\n\n.p-floatlabel:has(input:focus) label,\n.p-floatlabel:has(input:-webkit-autofill) label,\n.p-floatlabel:has(textarea:focus) label,\n.p-floatlabel:has(.p-inputwrapper-focus) label {\n color: ").concat(dt('floatlabel.focus.color'), ";\n}\n\n.p-floatlabel-in .p-inputtext,\n.p-floatlabel-in .p-textarea,\n.p-floatlabel-in .p-select-label,\n.p-floatlabel-in .p-multiselect-label,\n.p-floatlabel-in .p-autocomplete-input-multiple,\n.p-floatlabel-in .p-cascadeselect-label,\n.p-floatlabel-in .p-treeselect-label {\n padding-block-start: ").concat(dt('floatlabel.in.input.padding.top'), ";\n padding-block-end: ").concat(dt('floatlabel.in.input.padding.bottom'), ";\n}\n\n.p-floatlabel-in:has(input:focus) label,\n.p-floatlabel-in:has(input.p-filled) label,\n.p-floatlabel-in:has(input:-webkit-autofill) label,\n.p-floatlabel-in:has(textarea:focus) label,\n.p-floatlabel-in:has(textarea.p-filled) label,\n.p-floatlabel-in:has(.p-inputwrapper-focus) label,\n.p-floatlabel-in:has(.p-inputwrapper-filled) label {\n top: ").concat(dt('floatlabel.in.active.top'), ";\n}\n\n.p-floatlabel-on:has(input:focus) label,\n.p-floatlabel-on:has(input.p-filled) label,\n.p-floatlabel-on:has(input:-webkit-autofill) label,\n.p-floatlabel-on:has(textarea:focus) label,\n.p-floatlabel-on:has(textarea.p-filled) label,\n.p-floatlabel-on:has(.p-inputwrapper-focus) label,\n.p-floatlabel-on:has(.p-inputwrapper-filled) label {\n top: 0;\n transform: translateY(-50%);\n border-radius: ").concat(dt('floatlabel.on.border.radius'), ";\n background: ").concat(dt('floatlabel.on.active.background'), ";\n padding: ").concat(dt('floatlabel.on.active.padding'), ";\n}\n");
|
|
6
|
-
};
|
|
7
4
|
var classes = {
|
|
8
|
-
root: function root(
|
|
9
|
-
|
|
10
|
-
var props = _ref2.props;
|
|
5
|
+
root: function root(_ref) {
|
|
6
|
+
var props = _ref.props;
|
|
11
7
|
return ['p-floatlabel', {
|
|
12
8
|
'p-floatlabel-over': props.variant === 'over',
|
|
13
9
|
'p-floatlabel-on': props.variant === 'on',
|
|
@@ -17,7 +13,7 @@ var classes = {
|
|
|
17
13
|
};
|
|
18
14
|
var FloatLabelStyle = BaseStyle.extend({
|
|
19
15
|
name: 'floatlabel',
|
|
20
|
-
|
|
16
|
+
style: style,
|
|
21
17
|
classes: classes
|
|
22
18
|
});
|
|
23
19
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../src/floatlabel/style/FloatLabelStyle.js"],"sourcesContent":["import
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../../src/floatlabel/style/FloatLabelStyle.js"],"sourcesContent":["import { style } from '@primeuix/styles/floatlabel';\nimport BaseStyle from '@primevue/core/base/style';\n\nconst classes = {\n root: ({ props }) => [\n 'p-floatlabel',\n {\n 'p-floatlabel-over': props.variant === 'over',\n 'p-floatlabel-on': props.variant === 'on',\n 'p-floatlabel-in': props.variant === 'in'\n }\n ]\n};\n\nexport default BaseStyle.extend({\n name: 'floatlabel',\n style,\n classes\n});\n"],"names":["classes","root","_ref","props","variant","BaseStyle","extend","name","style"],"mappings":";;;AAGA,IAAMA,OAAO,GAAG;AACZC,EAAAA,IAAI,EAAE,SAANA,IAAIA,CAAAC,IAAA,EAAA;AAAA,IAAA,IAAKC,KAAK,GAAAD,IAAA,CAALC,KAAK;IAAA,OAAO,CACjB,cAAc,EACd;AACI,MAAA,mBAAmB,EAAEA,KAAK,CAACC,OAAO,KAAK,MAAM;AAC7C,MAAA,iBAAiB,EAAED,KAAK,CAACC,OAAO,KAAK,IAAI;AACzC,MAAA,iBAAiB,EAAED,KAAK,CAACC,OAAO,KAAK;AACzC,KAAC,CACJ;AAAA;AACL,CAAC;AAED,sBAAeC,SAAS,CAACC,MAAM,CAAC;AAC5BC,EAAAA,IAAI,EAAE,YAAY;AAClBC,EAAAA,KAAK,EAALA,KAAK;AACLR,EAAAA,OAAO,EAAPA;AACJ,CAAC,CAAC;;;;"}
|
package/fluid/index.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import BaseComponent from '@primevue/core/basecomponent';
|
|
2
2
|
import FluidStyle from 'primevue/fluid/style';
|
|
3
|
-
import {
|
|
3
|
+
import { createElementBlock, openBlock, mergeProps, renderSlot } from 'vue';
|
|
4
4
|
|
|
5
5
|
var script$1 = {
|
|
6
6
|
name: 'BaseFluid',
|
package/focustrap/index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { focus, getFirstFocusableElement,
|
|
1
|
+
import { getLastFocusableElement, focus, getFirstFocusableElement, createElement, isFocusableElement } from '@primeuix/utils/dom';
|
|
2
2
|
import { isNotEmpty } from '@primeuix/utils/object';
|
|
3
3
|
import BaseDirective from '@primevue/core/basedirective';
|
|
4
4
|
import FocusTrapStyle from 'primevue/focustrap/style';
|
|
@@ -9,10 +9,10 @@ var BaseFocusTrap = BaseDirective.extend({
|
|
|
9
9
|
|
|
10
10
|
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); }
|
|
11
11
|
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; }
|
|
12
|
-
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t),
|
|
13
|
-
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable:
|
|
12
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), true).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; }
|
|
13
|
+
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: true, configurable: true, writable: true }) : e[r] = t, e; }
|
|
14
14
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
15
|
-
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r
|
|
15
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
16
16
|
var FocusTrap = BaseFocusTrap.extend('focustrap', {
|
|
17
17
|
mounted: function mounted(el, binding) {
|
|
18
18
|
var _ref = binding.value || {},
|
package/focustrap/index.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../src/focustrap/BaseFocusTrap.js","../../src/focustrap/FocusTrap.js"],"sourcesContent":["import BaseDirective from '@primevue/core/basedirective';\nimport FocusTrapStyle from 'primevue/focustrap/style';\n\nconst BaseFocusTrap = BaseDirective.extend({\n style: FocusTrapStyle\n});\n\nexport default BaseFocusTrap;\n","import { createElement, focus, getFirstFocusableElement, getLastFocusableElement, isFocusableElement } from '@primeuix/utils/dom';\nimport { isNotEmpty } from '@primeuix/utils/object';\nimport BaseFocusTrap from './BaseFocusTrap';\n\nconst FocusTrap = BaseFocusTrap.extend('focustrap', {\n mounted(el, binding) {\n const { disabled } = binding.value || {};\n\n if (!disabled) {\n this.createHiddenFocusableElements(el, binding);\n this.bind(el, binding);\n this.autoElementFocus(el, binding);\n }\n\n el.setAttribute('data-pd-focustrap', true);\n\n this.$el = el;\n },\n updated(el, binding) {\n const { disabled } = binding.value || {};\n\n disabled && this.unbind(el);\n },\n unmounted(el) {\n this.unbind(el);\n },\n methods: {\n getComputedSelector(selector) {\n return `:not(.p-hidden-focusable):not([data-p-hidden-focusable=\"true\"])${selector ?? ''}`;\n },\n bind(el, binding) {\n const { onFocusIn, onFocusOut } = binding.value || {};\n\n el.$_pfocustrap_mutationobserver = new MutationObserver((mutationList) => {\n mutationList.forEach((mutation) => {\n if (mutation.type === 'childList' && !el.contains(document.activeElement)) {\n const findNextFocusableElement = (_el) => {\n const focusableElement = isFocusableElement(_el)\n ? isFocusableElement(_el, this.getComputedSelector(el.$_pfocustrap_focusableselector))\n ? _el\n : getFirstFocusableElement(el, this.getComputedSelector(el.$_pfocustrap_focusableselector))\n : getFirstFocusableElement(_el);\n\n return isNotEmpty(focusableElement) ? focusableElement : _el.nextSibling && findNextFocusableElement(_el.nextSibling);\n };\n\n focus(findNextFocusableElement(mutation.nextSibling));\n }\n });\n });\n\n el.$_pfocustrap_mutationobserver.disconnect();\n el.$_pfocustrap_mutationobserver.observe(el, {\n childList: true\n });\n\n el.$_pfocustrap_focusinlistener = (event) => onFocusIn && onFocusIn(event);\n el.$_pfocustrap_focusoutlistener = (event) => onFocusOut && onFocusOut(event);\n\n el.addEventListener('focusin', el.$_pfocustrap_focusinlistener);\n el.addEventListener('focusout', el.$_pfocustrap_focusoutlistener);\n },\n unbind(el) {\n el.$_pfocustrap_mutationobserver && el.$_pfocustrap_mutationobserver.disconnect();\n el.$_pfocustrap_focusinlistener && el.removeEventListener('focusin', el.$_pfocustrap_focusinlistener) && (el.$_pfocustrap_focusinlistener = null);\n el.$_pfocustrap_focusoutlistener && el.removeEventListener('focusout', el.$_pfocustrap_focusoutlistener) && (el.$_pfocustrap_focusoutlistener = null);\n },\n autoFocus(options) {\n this.autoElementFocus(this.$el, { value: { ...options, autoFocus: true } });\n },\n autoElementFocus(el, binding) {\n const { autoFocusSelector = '', firstFocusableSelector = '', autoFocus = false } = binding.value || {};\n let focusableElement = getFirstFocusableElement(el, `[autofocus]${this.getComputedSelector(autoFocusSelector)}`);\n\n autoFocus && !focusableElement && (focusableElement = getFirstFocusableElement(el, this.getComputedSelector(firstFocusableSelector)));\n focus(focusableElement);\n },\n onFirstHiddenElementFocus(event) {\n const { currentTarget, relatedTarget } = event;\n const focusableElement =\n relatedTarget === currentTarget.$_pfocustrap_lasthiddenfocusableelement || !this.$el?.contains(relatedTarget)\n ? getFirstFocusableElement(currentTarget.parentElement, this.getComputedSelector(currentTarget.$_pfocustrap_focusableselector))\n : currentTarget.$_pfocustrap_lasthiddenfocusableelement;\n\n focus(focusableElement);\n },\n onLastHiddenElementFocus(event) {\n const { currentTarget, relatedTarget } = event;\n const focusableElement =\n relatedTarget === currentTarget.$_pfocustrap_firsthiddenfocusableelement || !this.$el?.contains(relatedTarget)\n ? getLastFocusableElement(currentTarget.parentElement, this.getComputedSelector(currentTarget.$_pfocustrap_focusableselector))\n : currentTarget.$_pfocustrap_firsthiddenfocusableelement;\n\n focus(focusableElement);\n },\n createHiddenFocusableElements(el, binding) {\n const { tabIndex = 0, firstFocusableSelector = '', lastFocusableSelector = '' } = binding.value || {};\n\n const createFocusableElement = (onFocus) => {\n return createElement('span', {\n class: 'p-hidden-accessible p-hidden-focusable',\n tabIndex,\n role: 'presentation',\n 'aria-hidden': true,\n 'data-p-hidden-accessible': true,\n 'data-p-hidden-focusable': true,\n onFocus: onFocus?.bind(this)\n });\n };\n\n const firstFocusableElement = createFocusableElement(this.onFirstHiddenElementFocus);\n const lastFocusableElement = createFocusableElement(this.onLastHiddenElementFocus);\n\n firstFocusableElement.$_pfocustrap_lasthiddenfocusableelement = lastFocusableElement;\n firstFocusableElement.$_pfocustrap_focusableselector = firstFocusableSelector;\n firstFocusableElement.setAttribute('data-pc-section', 'firstfocusableelement');\n\n lastFocusableElement.$_pfocustrap_firsthiddenfocusableelement = firstFocusableElement;\n lastFocusableElement.$_pfocustrap_focusableselector = lastFocusableSelector;\n lastFocusableElement.setAttribute('data-pc-section', 'lastfocusableelement');\n\n el.prepend(firstFocusableElement);\n el.append(lastFocusableElement);\n }\n }\n});\n\nexport default FocusTrap;\n"],"names":["BaseFocusTrap","BaseDirective","extend","style","FocusTrapStyle","FocusTrap","mounted","el","binding","_ref","value","disabled","createHiddenFocusableElements","bind","autoElementFocus","setAttribute","$el","updated","_ref2","unbind","unmounted","methods","getComputedSelector","selector","concat","_this","_ref3","onFocusIn","onFocusOut","$_pfocustrap_mutationobserver","MutationObserver","mutationList","forEach","mutation","type","contains","document","activeElement","findNextFocusableElement","_el","focusableElement","isFocusableElement","$_pfocustrap_focusableselector","getFirstFocusableElement","isNotEmpty","nextSibling","focus","disconnect","observe","childList","$_pfocustrap_focusinlistener","event","$_pfocustrap_focusoutlistener","addEventListener","removeEventListener","autoFocus","options","_objectSpread","_ref4","_ref4$autoFocusSelect","autoFocusSelector","_ref4$firstFocusableS","firstFocusableSelector","_ref4$autoFocus","onFirstHiddenElementFocus","_this$$el","currentTarget","relatedTarget","$_pfocustrap_lasthiddenfocusableelement","parentElement","onLastHiddenElementFocus","_this$$el2","$_pfocustrap_firsthiddenfocusableelement","getLastFocusableElement","_this2","_ref5","_ref5$tabIndex","tabIndex","_ref5$firstFocusableS","_ref5$lastFocusableSe","lastFocusableSelector","createFocusableElement","onFocus","createElement","role","firstFocusableElement","lastFocusableElement","prepend","append"],"mappings":";;;;;AAGA,IAAMA,aAAa,GAAGC,aAAa,CAACC,MAAM,CAAC;AACvCC,EAAAA,KAAK,EAAEC;AACX,CAAC,CAAC;;;;;;;;ACDF,IAAMC,SAAS,GAAGL,aAAa,CAACE,MAAM,CAAC,WAAW,EAAE;AAChDI,EAAAA,OAAO,WAAPA,OAAOA,CAACC,EAAE,EAAEC,OAAO,EAAE;AACjB,IAAA,IAAAC,IAAA,GAAqBD,OAAO,CAACE,KAAK,IAAI,EAAE;MAAhCC,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,EAAO,wCAAwC;AAC/CN,UAAAA,QAAQ,EAARA,QAAQ;AACRO,UAAAA,IAAI,EAAE,cAAc;AACpB,UAAA,aAAa,EAAE,IAAI;AACnB,UAAA,0BAA0B,EAAE,IAAI;AAChC,UAAA,yBAAyB,EAAE,IAAI;UAC/BF,OAAO,EAAEA,OAAO,KAAPA,IAAAA,IAAAA,OAAO,uBAAPA,OAAO,CAAErE,IAAI,CAAC6D,MAAI;AAC/B,SAAC,CAAC;OACL;AAED,MAAA,IAAMW,qBAAqB,GAAGJ,sBAAsB,CAAC,IAAI,CAACjB,yBAAyB,CAAC;AACpF,MAAA,IAAMsB,oBAAoB,GAAGL,sBAAsB,CAAC,IAAI,CAACX,wBAAwB,CAAC;MAElFe,qBAAqB,CAACjB,uCAAuC,GAAGkB,oBAAoB;MACpFD,qBAAqB,CAAC3C,8BAA8B,GAAGoB,sBAAsB;AAC7EuB,MAAAA,qBAAqB,CAACtE,YAAY,CAAC,iBAAiB,EAAE,uBAAuB,CAAC;MAE9EuE,oBAAoB,CAACd,wCAAwC,GAAGa,qBAAqB;MACrFC,oBAAoB,CAAC5C,8BAA8B,GAAGsC,qBAAqB;AAC3EM,MAAAA,oBAAoB,CAACvE,YAAY,CAAC,iBAAiB,EAAE,sBAAsB,CAAC;AAE5ER,MAAAA,EAAE,CAACgF,OAAO,CAACF,qBAAqB,CAAC;AACjC9E,MAAAA,EAAE,CAACiF,MAAM,CAACF,oBAAoB,CAAC;AACnC;AACJ;AACJ,CAAC;;;;"}
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../src/focustrap/BaseFocusTrap.js","../../src/focustrap/FocusTrap.js"],"sourcesContent":["import BaseDirective from '@primevue/core/basedirective';\nimport FocusTrapStyle from 'primevue/focustrap/style';\n\nconst BaseFocusTrap = BaseDirective.extend({\n style: FocusTrapStyle\n});\n\nexport default BaseFocusTrap;\n","import { createElement, focus, getFirstFocusableElement, getLastFocusableElement, isFocusableElement } from '@primeuix/utils/dom';\nimport { isNotEmpty } from '@primeuix/utils/object';\nimport BaseFocusTrap from './BaseFocusTrap';\n\nconst FocusTrap = BaseFocusTrap.extend('focustrap', {\n mounted(el, binding) {\n const { disabled } = binding.value || {};\n\n if (!disabled) {\n this.createHiddenFocusableElements(el, binding);\n this.bind(el, binding);\n this.autoElementFocus(el, binding);\n }\n\n el.setAttribute('data-pd-focustrap', true);\n\n this.$el = el;\n },\n updated(el, binding) {\n const { disabled } = binding.value || {};\n\n disabled && this.unbind(el);\n },\n unmounted(el) {\n this.unbind(el);\n },\n methods: {\n getComputedSelector(selector) {\n return `:not(.p-hidden-focusable):not([data-p-hidden-focusable=\"true\"])${selector ?? ''}`;\n },\n bind(el, binding) {\n const { onFocusIn, onFocusOut } = binding.value || {};\n\n el.$_pfocustrap_mutationobserver = new MutationObserver((mutationList) => {\n mutationList.forEach((mutation) => {\n if (mutation.type === 'childList' && !el.contains(document.activeElement)) {\n const findNextFocusableElement = (_el) => {\n const focusableElement = isFocusableElement(_el)\n ? isFocusableElement(_el, this.getComputedSelector(el.$_pfocustrap_focusableselector))\n ? _el\n : getFirstFocusableElement(el, this.getComputedSelector(el.$_pfocustrap_focusableselector))\n : getFirstFocusableElement(_el);\n\n return isNotEmpty(focusableElement) ? focusableElement : _el.nextSibling && findNextFocusableElement(_el.nextSibling);\n };\n\n focus(findNextFocusableElement(mutation.nextSibling));\n }\n });\n });\n\n el.$_pfocustrap_mutationobserver.disconnect();\n el.$_pfocustrap_mutationobserver.observe(el, {\n childList: true\n });\n\n el.$_pfocustrap_focusinlistener = (event) => onFocusIn && onFocusIn(event);\n el.$_pfocustrap_focusoutlistener = (event) => onFocusOut && onFocusOut(event);\n\n el.addEventListener('focusin', el.$_pfocustrap_focusinlistener);\n el.addEventListener('focusout', el.$_pfocustrap_focusoutlistener);\n },\n unbind(el) {\n el.$_pfocustrap_mutationobserver && el.$_pfocustrap_mutationobserver.disconnect();\n el.$_pfocustrap_focusinlistener && el.removeEventListener('focusin', el.$_pfocustrap_focusinlistener) && (el.$_pfocustrap_focusinlistener = null);\n el.$_pfocustrap_focusoutlistener && el.removeEventListener('focusout', el.$_pfocustrap_focusoutlistener) && (el.$_pfocustrap_focusoutlistener = null);\n },\n autoFocus(options) {\n this.autoElementFocus(this.$el, { value: { ...options, autoFocus: true } });\n },\n autoElementFocus(el, binding) {\n const { autoFocusSelector = '', firstFocusableSelector = '', autoFocus = false } = binding.value || {};\n let focusableElement = getFirstFocusableElement(el, `[autofocus]${this.getComputedSelector(autoFocusSelector)}`);\n\n autoFocus && !focusableElement && (focusableElement = getFirstFocusableElement(el, this.getComputedSelector(firstFocusableSelector)));\n focus(focusableElement);\n },\n onFirstHiddenElementFocus(event) {\n const { currentTarget, relatedTarget } = event;\n const focusableElement =\n relatedTarget === currentTarget.$_pfocustrap_lasthiddenfocusableelement || !this.$el?.contains(relatedTarget)\n ? getFirstFocusableElement(currentTarget.parentElement, this.getComputedSelector(currentTarget.$_pfocustrap_focusableselector))\n : currentTarget.$_pfocustrap_lasthiddenfocusableelement;\n\n focus(focusableElement);\n },\n onLastHiddenElementFocus(event) {\n const { currentTarget, relatedTarget } = event;\n const focusableElement =\n relatedTarget === currentTarget.$_pfocustrap_firsthiddenfocusableelement || !this.$el?.contains(relatedTarget)\n ? getLastFocusableElement(currentTarget.parentElement, this.getComputedSelector(currentTarget.$_pfocustrap_focusableselector))\n : currentTarget.$_pfocustrap_firsthiddenfocusableelement;\n\n focus(focusableElement);\n },\n createHiddenFocusableElements(el, binding) {\n const { tabIndex = 0, firstFocusableSelector = '', lastFocusableSelector = '' } = binding.value || {};\n\n const createFocusableElement = (onFocus) => {\n return createElement('span', {\n class: 'p-hidden-accessible p-hidden-focusable',\n tabIndex,\n role: 'presentation',\n 'aria-hidden': true,\n 'data-p-hidden-accessible': true,\n 'data-p-hidden-focusable': true,\n onFocus: onFocus?.bind(this)\n });\n };\n\n const firstFocusableElement = createFocusableElement(this.onFirstHiddenElementFocus);\n const lastFocusableElement = createFocusableElement(this.onLastHiddenElementFocus);\n\n firstFocusableElement.$_pfocustrap_lasthiddenfocusableelement = lastFocusableElement;\n firstFocusableElement.$_pfocustrap_focusableselector = firstFocusableSelector;\n firstFocusableElement.setAttribute('data-pc-section', 'firstfocusableelement');\n\n lastFocusableElement.$_pfocustrap_firsthiddenfocusableelement = firstFocusableElement;\n lastFocusableElement.$_pfocustrap_focusableselector = lastFocusableSelector;\n lastFocusableElement.setAttribute('data-pc-section', 'lastfocusableelement');\n\n el.prepend(firstFocusableElement);\n el.append(lastFocusableElement);\n }\n }\n});\n\nexport default FocusTrap;\n"],"names":["BaseFocusTrap","BaseDirective","extend","style","FocusTrapStyle","FocusTrap","mounted","el","binding","_ref","value","disabled","createHiddenFocusableElements","bind","autoElementFocus","setAttribute","$el","updated","_ref2","unbind","unmounted","methods","getComputedSelector","selector","concat","_this","_ref3","onFocusIn","onFocusOut","$_pfocustrap_mutationobserver","MutationObserver","mutationList","forEach","mutation","type","contains","document","activeElement","findNextFocusableElement","_el","focusableElement","isFocusableElement","$_pfocustrap_focusableselector","getFirstFocusableElement","isNotEmpty","nextSibling","focus","disconnect","observe","childList","$_pfocustrap_focusinlistener","event","$_pfocustrap_focusoutlistener","addEventListener","removeEventListener","autoFocus","options","_objectSpread","_ref4","_ref4$autoFocusSelect","autoFocusSelector","_ref4$firstFocusableS","firstFocusableSelector","_ref4$autoFocus","onFirstHiddenElementFocus","_this$$el","currentTarget","relatedTarget","$_pfocustrap_lasthiddenfocusableelement","parentElement","onLastHiddenElementFocus","_this$$el2","$_pfocustrap_firsthiddenfocusableelement","getLastFocusableElement","_this2","_ref5","_ref5$tabIndex","tabIndex","_ref5$firstFocusableS","_ref5$lastFocusableSe","lastFocusableSelector","createFocusableElement","onFocus","createElement","role","firstFocusableElement","lastFocusableElement","prepend","append"],"mappings":";;;;;AAGA,IAAMA,aAAa,GAAGC,aAAa,CAACC,MAAM,CAAC;AACvCC,EAAAA,KAAK,EAAEC;AACX,CAAC,CAAC;;;;;;;;ACD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14
|
import { ZIndex } from '@primeuix/utils/zindex';
|
|
15
15
|
import FocusTrap from 'primevue/focustrap';
|
|
16
16
|
import Portal from 'primevue/portal';
|
|
17
|
+
import { blockBodyScroll, unblockBodyScroll } from 'primevue/utils';
|
|
17
18
|
import BaseGalleria from './BaseGalleria.vue';
|
|
18
19
|
import GalleriaContent from './GalleriaContent.vue';
|
|
19
20
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div
|
|
3
3
|
v-if="$attrs.value && $attrs.value.length > 0"
|
|
4
|
-
:id="id"
|
|
4
|
+
:id="$id"
|
|
5
5
|
role="region"
|
|
6
6
|
:class="[cx('root'), $attrs.containerClass]"
|
|
7
7
|
:style="$attrs.containerStyle"
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
</div>
|
|
18
18
|
<div :class="cx('content')" :aria-live="$attrs.autoPlay ? 'polite' : 'off'" v-bind="getPTOptions('content')">
|
|
19
19
|
<GalleriaItem
|
|
20
|
-
:id="id"
|
|
20
|
+
:id="$id"
|
|
21
21
|
v-model:activeIndex="activeIndex"
|
|
22
22
|
v-model:slideShowActive="slideShowActive"
|
|
23
23
|
:value="$attrs.value"
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
v-if="$attrs.showThumbnails"
|
|
38
38
|
v-model:activeIndex="activeIndex"
|
|
39
39
|
v-model:slideShowActive="slideShowActive"
|
|
40
|
-
:containerId="id"
|
|
40
|
+
:containerId="$id"
|
|
41
41
|
:value="$attrs.value"
|
|
42
42
|
:templates="$attrs.templates"
|
|
43
43
|
:numVisible="numVisible"
|
|
@@ -61,7 +61,6 @@
|
|
|
61
61
|
|
|
62
62
|
<script>
|
|
63
63
|
import BaseComponent from '@primevue/core/basecomponent';
|
|
64
|
-
import { UniqueComponentId } from '@primevue/core/utils';
|
|
65
64
|
import TimesIcon from '@primevue/icons/times';
|
|
66
65
|
import Ripple from 'primevue/ripple';
|
|
67
66
|
import GalleriaItem from './GalleriaItem.vue';
|
|
@@ -76,16 +75,12 @@ export default {
|
|
|
76
75
|
emits: ['activeitem-change', 'mask-hide'],
|
|
77
76
|
data() {
|
|
78
77
|
return {
|
|
79
|
-
id: this.$attrs.id || UniqueComponentId(),
|
|
80
78
|
activeIndex: this.$attrs.activeIndex,
|
|
81
79
|
numVisible: this.$attrs.numVisible,
|
|
82
80
|
slideShowActive: false
|
|
83
81
|
};
|
|
84
82
|
},
|
|
85
83
|
watch: {
|
|
86
|
-
'$attrs.id': function (newValue) {
|
|
87
|
-
this.id = newValue || UniqueComponentId();
|
|
88
|
-
},
|
|
89
84
|
'$attrs.value': function (newVal) {
|
|
90
85
|
if (newVal && newVal.length < this.numVisible) {
|
|
91
86
|
this.numVisible = newVal.length;
|
|
@@ -101,9 +96,6 @@ export default {
|
|
|
101
96
|
newVal ? this.startSlideShow() : this.stopSlideShow();
|
|
102
97
|
}
|
|
103
98
|
},
|
|
104
|
-
mounted() {
|
|
105
|
-
this.id = this.id || UniqueComponentId();
|
|
106
|
-
},
|
|
107
99
|
updated() {
|
|
108
100
|
this.$emit('activeitem-change', this.activeIndex);
|
|
109
101
|
},
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
v-if="showThumbnailNavigators"
|
|
6
6
|
v-ripple
|
|
7
7
|
:class="cx('thumbnailPrevButton')"
|
|
8
|
-
:disabled="isNavBackwardDisabled
|
|
8
|
+
:disabled="isNavBackwardDisabled"
|
|
9
9
|
type="button"
|
|
10
10
|
:aria-label="ariaPrevButtonLabel"
|
|
11
11
|
@click="navBackward($event)"
|
|
@@ -57,7 +57,7 @@
|
|
|
57
57
|
v-if="showThumbnailNavigators"
|
|
58
58
|
v-ripple
|
|
59
59
|
:class="cx('thumbnailNextButton')"
|
|
60
|
-
:disabled="isNavForwardDisabled
|
|
60
|
+
:disabled="isNavForwardDisabled"
|
|
61
61
|
type="button"
|
|
62
62
|
:aria-label="ariaNextButtonLabel"
|
|
63
63
|
@click="navForward($event)"
|
|
@@ -421,6 +421,12 @@ export default {
|
|
|
421
421
|
}
|
|
422
422
|
},
|
|
423
423
|
changePageOnTouch(e, diff) {
|
|
424
|
+
const touchThreshold = 10
|
|
425
|
+
|
|
426
|
+
if(Math.abs(diff) < touchThreshold) {
|
|
427
|
+
// only a click/tap
|
|
428
|
+
return;
|
|
429
|
+
}
|
|
424
430
|
if (diff < 0) {
|
|
425
431
|
// left
|
|
426
432
|
this.navForward(e);
|
|
@@ -507,12 +513,7 @@ export default {
|
|
|
507
513
|
this.documentResizeListener = null;
|
|
508
514
|
}
|
|
509
515
|
},
|
|
510
|
-
|
|
511
|
-
return (!this.circular && this.d_activeIndex === 0) || this.value.length <= this.d_numVisible;
|
|
512
|
-
},
|
|
513
|
-
isNavForwardDisabled() {
|
|
514
|
-
return (!this.circular && this.d_activeIndex === this.value.length - 1) || this.value.length <= this.d_numVisible;
|
|
515
|
-
},
|
|
516
|
+
|
|
516
517
|
firstItemAciveIndex() {
|
|
517
518
|
return this.totalShiftedItems * -1;
|
|
518
519
|
},
|
|
@@ -532,6 +533,12 @@ export default {
|
|
|
532
533
|
},
|
|
533
534
|
ariaNextButtonLabel() {
|
|
534
535
|
return this.$primevue.config.locale.aria ? this.$primevue.config.locale.aria.nextPageLabel : undefined;
|
|
536
|
+
},
|
|
537
|
+
isNavBackwardDisabled() {
|
|
538
|
+
return (!this.circular && this.d_activeIndex === 0) || this.value.length <= this.d_numVisible;
|
|
539
|
+
},
|
|
540
|
+
isNavForwardDisabled() {
|
|
541
|
+
return (!this.circular && this.d_activeIndex === this.value.length - 1) || this.value.length <= this.d_numVisible;
|
|
535
542
|
}
|
|
536
543
|
},
|
|
537
544
|
components: {
|
package/galleria/index.mjs
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { find,
|
|
1
|
+
import { find, findSingle, getAttribute, setAttribute, addClass, removeClass } from '@primeuix/utils/dom';
|
|
2
2
|
import { ZIndex } from '@primeuix/utils/zindex';
|
|
3
3
|
import FocusTrap from 'primevue/focustrap';
|
|
4
4
|
import Portal from 'primevue/portal';
|
|
5
|
+
import { unblockBodyScroll, blockBodyScroll } from 'primevue/utils';
|
|
5
6
|
import BaseComponent from '@primevue/core/basecomponent';
|
|
6
7
|
import GalleriaStyle from 'primevue/galleria/style';
|
|
7
|
-
import { UniqueComponentId } from '@primevue/core/utils';
|
|
8
8
|
import TimesIcon from '@primevue/icons/times';
|
|
9
9
|
import Ripple from 'primevue/ripple';
|
|
10
10
|
import ChevronLeftIcon from '@primevue/icons/chevronleft';
|
|
11
11
|
import ChevronRightIcon from '@primevue/icons/chevronright';
|
|
12
|
-
import { resolveDirective,
|
|
12
|
+
import { resolveDirective, createElementBlock, openBlock, mergeProps, createElementVNode, createCommentVNode, withDirectives, createBlock, resolveDynamicComponent, Fragment, renderList, resolveComponent, createVNode, withCtx, Transition } from 'vue';
|
|
13
13
|
import { localeComparator, sort } from '@primeuix/utils/object';
|
|
14
14
|
import ChevronDownIcon from '@primevue/icons/chevrondown';
|
|
15
15
|
import ChevronUpIcon from '@primevue/icons/chevronup';
|
|
@@ -756,6 +756,11 @@ var script$2 = {
|
|
|
756
756
|
}
|
|
757
757
|
},
|
|
758
758
|
changePageOnTouch: function changePageOnTouch(e, diff) {
|
|
759
|
+
var touchThreshold = 10;
|
|
760
|
+
if (Math.abs(diff) < touchThreshold) {
|
|
761
|
+
// only a click/tap
|
|
762
|
+
return;
|
|
763
|
+
}
|
|
759
764
|
if (diff < 0) {
|
|
760
765
|
// left
|
|
761
766
|
this.navForward(e);
|
|
@@ -823,12 +828,6 @@ var script$2 = {
|
|
|
823
828
|
this.documentResizeListener = null;
|
|
824
829
|
}
|
|
825
830
|
},
|
|
826
|
-
isNavBackwardDisabled: function isNavBackwardDisabled() {
|
|
827
|
-
return !this.circular && this.d_activeIndex === 0 || this.value.length <= this.d_numVisible;
|
|
828
|
-
},
|
|
829
|
-
isNavForwardDisabled: function isNavForwardDisabled() {
|
|
830
|
-
return !this.circular && this.d_activeIndex === this.value.length - 1 || this.value.length <= this.d_numVisible;
|
|
831
|
-
},
|
|
832
831
|
firstItemAciveIndex: function firstItemAciveIndex() {
|
|
833
832
|
return this.totalShiftedItems * -1;
|
|
834
833
|
},
|
|
@@ -848,6 +847,12 @@ var script$2 = {
|
|
|
848
847
|
},
|
|
849
848
|
ariaNextButtonLabel: function ariaNextButtonLabel() {
|
|
850
849
|
return this.$primevue.config.locale.aria ? this.$primevue.config.locale.aria.nextPageLabel : undefined;
|
|
850
|
+
},
|
|
851
|
+
isNavBackwardDisabled: function isNavBackwardDisabled() {
|
|
852
|
+
return !this.circular && this.d_activeIndex === 0 || this.value.length <= this.d_numVisible;
|
|
853
|
+
},
|
|
854
|
+
isNavForwardDisabled: function isNavForwardDisabled() {
|
|
855
|
+
return !this.circular && this.d_activeIndex === this.value.length - 1 || this.value.length <= this.d_numVisible;
|
|
851
856
|
}
|
|
852
857
|
},
|
|
853
858
|
components: {
|
|
@@ -863,10 +868,10 @@ var script$2 = {
|
|
|
863
868
|
|
|
864
869
|
function _typeof$2(o) { "@babel/helpers - typeof"; return _typeof$2 = "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$2(o); }
|
|
865
870
|
function ownKeys$2(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; }
|
|
866
|
-
function _objectSpread$2(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$2(Object(t),
|
|
867
|
-
function _defineProperty$2(e, r, t) { return (r = _toPropertyKey$2(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable:
|
|
871
|
+
function _objectSpread$2(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$2(Object(t), true).forEach(function (r) { _defineProperty$2(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$2(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
872
|
+
function _defineProperty$2(e, r, t) { return (r = _toPropertyKey$2(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: true, configurable: true, writable: true }) : e[r] = t, e; }
|
|
868
873
|
function _toPropertyKey$2(t) { var i = _toPrimitive$2(t, "string"); return "symbol" == _typeof$2(i) ? i : i + ""; }
|
|
869
|
-
function _toPrimitive$2(t, r) { if ("object" != _typeof$2(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r
|
|
874
|
+
function _toPrimitive$2(t, r) { if ("object" != _typeof$2(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r); if ("object" != _typeof$2(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
870
875
|
var _hoisted_1$2 = ["disabled", "aria-label"];
|
|
871
876
|
var _hoisted_2$1 = ["data-p-active", "aria-selected", "aria-controls", "onKeydown", "data-p-galleria-thumbnail-item-current", "data-p-galleria-thumbnail-item-active", "data-p-galleria-thumbnail-item-start", "data-p-galleria-thumbnail-item-end"];
|
|
872
877
|
var _hoisted_3$1 = ["tabindex", "aria-label", "aria-current", "onClick"];
|
|
@@ -880,7 +885,7 @@ function render$2(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
880
885
|
}, _ctx.ptm('thumbnailContent')), [$props.showThumbnailNavigators ? withDirectives((openBlock(), createElementBlock("button", mergeProps({
|
|
881
886
|
key: 0,
|
|
882
887
|
"class": _ctx.cx('thumbnailPrevButton'),
|
|
883
|
-
disabled: $options.isNavBackwardDisabled
|
|
888
|
+
disabled: $options.isNavBackwardDisabled,
|
|
884
889
|
type: "button",
|
|
885
890
|
"aria-label": $options.ariaPrevButtonLabel,
|
|
886
891
|
onClick: _cache[0] || (_cache[0] = function ($event) {
|
|
@@ -947,7 +952,7 @@ function render$2(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
947
952
|
}), 128))], 16)], 16), $props.showThumbnailNavigators ? withDirectives((openBlock(), createElementBlock("button", mergeProps({
|
|
948
953
|
key: 1,
|
|
949
954
|
"class": _ctx.cx('thumbnailNextButton'),
|
|
950
|
-
disabled: $options.isNavForwardDisabled
|
|
955
|
+
disabled: $options.isNavForwardDisabled,
|
|
951
956
|
type: "button",
|
|
952
957
|
"aria-label": $options.ariaNextButtonLabel,
|
|
953
958
|
onClick: _cache[5] || (_cache[5] = function ($event) {
|
|
@@ -964,10 +969,10 @@ script$2.render = render$2;
|
|
|
964
969
|
|
|
965
970
|
function _typeof$1(o) { "@babel/helpers - typeof"; return _typeof$1 = "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$1(o); }
|
|
966
971
|
function ownKeys$1(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; }
|
|
967
|
-
function _objectSpread$1(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$1(Object(t),
|
|
968
|
-
function _defineProperty$1(e, r, t) { return (r = _toPropertyKey$1(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable:
|
|
972
|
+
function _objectSpread$1(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$1(Object(t), true).forEach(function (r) { _defineProperty$1(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$1(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
973
|
+
function _defineProperty$1(e, r, t) { return (r = _toPropertyKey$1(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: true, configurable: true, writable: true }) : e[r] = t, e; }
|
|
969
974
|
function _toPropertyKey$1(t) { var i = _toPrimitive$1(t, "string"); return "symbol" == _typeof$1(i) ? i : i + ""; }
|
|
970
|
-
function _toPrimitive$1(t, r) { if ("object" != _typeof$1(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r
|
|
975
|
+
function _toPrimitive$1(t, r) { if ("object" != _typeof$1(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r); if ("object" != _typeof$1(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
971
976
|
var script$1 = {
|
|
972
977
|
name: 'GalleriaContent',
|
|
973
978
|
hostName: 'Galleria',
|
|
@@ -977,16 +982,12 @@ var script$1 = {
|
|
|
977
982
|
emits: ['activeitem-change', 'mask-hide'],
|
|
978
983
|
data: function data() {
|
|
979
984
|
return {
|
|
980
|
-
id: this.$attrs.id || UniqueComponentId(),
|
|
981
985
|
activeIndex: this.$attrs.activeIndex,
|
|
982
986
|
numVisible: this.$attrs.numVisible,
|
|
983
987
|
slideShowActive: false
|
|
984
988
|
};
|
|
985
989
|
},
|
|
986
990
|
watch: {
|
|
987
|
-
'$attrs.id': function $attrsId(newValue) {
|
|
988
|
-
this.id = newValue || UniqueComponentId();
|
|
989
|
-
},
|
|
990
991
|
'$attrs.value': function $attrsValue(newVal) {
|
|
991
992
|
if (newVal && newVal.length < this.numVisible) {
|
|
992
993
|
this.numVisible = newVal.length;
|
|
@@ -1002,9 +1003,6 @@ var script$1 = {
|
|
|
1002
1003
|
newVal ? this.startSlideShow() : this.stopSlideShow();
|
|
1003
1004
|
}
|
|
1004
1005
|
},
|
|
1005
|
-
mounted: function mounted() {
|
|
1006
|
-
this.id = this.id || UniqueComponentId();
|
|
1007
|
-
},
|
|
1008
1006
|
updated: function updated() {
|
|
1009
1007
|
this.$emit('activeitem-change', this.activeIndex);
|
|
1010
1008
|
},
|
|
@@ -1067,10 +1065,10 @@ var script$1 = {
|
|
|
1067
1065
|
|
|
1068
1066
|
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); }
|
|
1069
1067
|
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; }
|
|
1070
|
-
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t),
|
|
1071
|
-
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable:
|
|
1068
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), true).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; }
|
|
1069
|
+
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: true, configurable: true, writable: true }) : e[r] = t, e; }
|
|
1072
1070
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
1073
|
-
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r
|
|
1071
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
1074
1072
|
var _hoisted_1$1 = ["id", "aria-label", "aria-roledescription"];
|
|
1075
1073
|
var _hoisted_2 = ["aria-label"];
|
|
1076
1074
|
var _hoisted_3 = ["aria-live"];
|
|
@@ -1080,7 +1078,7 @@ function render$1(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
1080
1078
|
var _directive_ripple = resolveDirective("ripple");
|
|
1081
1079
|
return _ctx.$attrs.value && _ctx.$attrs.value.length > 0 ? (openBlock(), createElementBlock("div", mergeProps({
|
|
1082
1080
|
key: 0,
|
|
1083
|
-
id:
|
|
1081
|
+
id: _ctx.$id,
|
|
1084
1082
|
role: "region",
|
|
1085
1083
|
"class": [_ctx.cx('root'), _ctx.$attrs.containerClass],
|
|
1086
1084
|
style: _ctx.$attrs.containerStyle,
|
|
@@ -1104,7 +1102,7 @@ function render$1(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
1104
1102
|
"class": _ctx.cx('content'),
|
|
1105
1103
|
"aria-live": _ctx.$attrs.autoPlay ? 'polite' : 'off'
|
|
1106
1104
|
}, $options.getPTOptions('content')), [createVNode(_component_GalleriaItem, {
|
|
1107
|
-
id:
|
|
1105
|
+
id: _ctx.$id,
|
|
1108
1106
|
activeIndex: $data.activeIndex,
|
|
1109
1107
|
"onUpdate:activeIndex": _cache[1] || (_cache[1] = function ($event) {
|
|
1110
1108
|
return $data.activeIndex = $event;
|
|
@@ -1134,7 +1132,7 @@ function render$1(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
1134
1132
|
"onUpdate:slideShowActive": _cache[4] || (_cache[4] = function ($event) {
|
|
1135
1133
|
return $data.slideShowActive = $event;
|
|
1136
1134
|
}),
|
|
1137
|
-
containerId:
|
|
1135
|
+
containerId: _ctx.$id,
|
|
1138
1136
|
value: _ctx.$attrs.value,
|
|
1139
1137
|
templates: _ctx.$attrs.templates,
|
|
1140
1138
|
numVisible: $data.numVisible,
|