primereact 10.3.0 → 10.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/accordion/accordion.cjs.js +11 -8
- package/accordion/accordion.cjs.min.js +1 -1
- package/accordion/accordion.d.ts +36 -1
- package/accordion/accordion.esm.js +11 -8
- package/accordion/accordion.esm.min.js +1 -1
- package/accordion/accordion.js +9 -6
- package/accordion/accordion.min.js +1 -1
- package/api/api.cjs.js +39 -33
- package/api/api.cjs.min.js +1 -1
- package/api/api.d.ts +13 -2
- package/api/api.esm.js +39 -33
- package/api/api.esm.min.js +1 -1
- package/api/api.js +39 -33
- package/api/api.min.js +1 -1
- package/autocomplete/autocomplete.cjs.js +3 -2
- package/autocomplete/autocomplete.cjs.min.js +1 -1
- package/autocomplete/autocomplete.d.ts +6 -1
- package/autocomplete/autocomplete.esm.js +3 -2
- package/autocomplete/autocomplete.esm.min.js +1 -1
- package/autocomplete/autocomplete.js +3 -2
- package/autocomplete/autocomplete.min.js +1 -1
- package/blockui/blockui.cjs.js +8 -5
- package/blockui/blockui.cjs.min.js +1 -1
- package/blockui/blockui.esm.js +8 -5
- package/blockui/blockui.esm.min.js +1 -1
- package/blockui/blockui.js +8 -5
- package/blockui/blockui.min.js +1 -1
- package/calendar/calendar.cjs.js +80 -43
- package/calendar/calendar.cjs.min.js +1 -1
- package/calendar/calendar.d.ts +3 -5
- package/calendar/calendar.esm.js +80 -43
- package/calendar/calendar.esm.min.js +1 -1
- package/calendar/calendar.js +80 -43
- package/calendar/calendar.min.js +1 -1
- package/carousel/carousel.cjs.js +1 -1
- package/carousel/carousel.cjs.min.js +1 -1
- package/carousel/carousel.esm.js +1 -1
- package/carousel/carousel.esm.min.js +1 -1
- package/carousel/carousel.js +1 -1
- package/carousel/carousel.min.js +1 -1
- package/cascadeselect/cascadeselect.cjs.js +42 -20
- package/cascadeselect/cascadeselect.cjs.min.js +1 -1
- package/cascadeselect/cascadeselect.d.ts +27 -4
- package/cascadeselect/cascadeselect.esm.js +43 -21
- package/cascadeselect/cascadeselect.esm.min.js +1 -1
- package/cascadeselect/cascadeselect.js +43 -21
- package/cascadeselect/cascadeselect.min.js +1 -1
- package/checkbox/checkbox.cjs.js +25 -25
- package/checkbox/checkbox.cjs.min.js +1 -1
- package/checkbox/checkbox.esm.js +25 -25
- package/checkbox/checkbox.esm.min.js +1 -1
- package/checkbox/checkbox.js +26 -26
- package/checkbox/checkbox.min.js +1 -1
- package/chip/chip.cjs.js +5 -1
- package/chip/chip.cjs.min.js +1 -1
- package/chip/chip.d.ts +17 -2
- package/chip/chip.esm.js +5 -1
- package/chip/chip.esm.min.js +1 -1
- package/chip/chip.js +5 -1
- package/chip/chip.min.js +1 -1
- package/chips/chips.cjs.js +2 -1
- package/chips/chips.cjs.min.js +1 -1
- package/chips/chips.esm.js +2 -1
- package/chips/chips.esm.min.js +1 -1
- package/chips/chips.js +2 -1
- package/chips/chips.min.js +1 -1
- package/colorpicker/colorpicker.d.ts +1 -1
- package/componentbase/componentbase.cjs.js +49 -8
- package/componentbase/componentbase.cjs.min.js +1 -1
- package/componentbase/componentbase.esm.js +50 -9
- package/componentbase/componentbase.esm.min.js +1 -1
- package/componentbase/componentbase.js +49 -8
- package/componentbase/componentbase.min.js +1 -1
- package/confirmdialog/confirmdialog.cjs.js +21 -18
- package/confirmdialog/confirmdialog.cjs.min.js +1 -1
- package/confirmdialog/confirmdialog.d.ts +19 -3
- package/confirmdialog/confirmdialog.esm.js +21 -18
- package/confirmdialog/confirmdialog.esm.min.js +1 -1
- package/confirmdialog/confirmdialog.js +21 -18
- package/confirmdialog/confirmdialog.min.js +1 -1
- package/confirmpopup/confirmpopup.cjs.js +32 -120
- package/confirmpopup/confirmpopup.cjs.min.js +1 -1
- package/confirmpopup/confirmpopup.d.ts +12 -2
- package/confirmpopup/confirmpopup.esm.js +35 -123
- package/confirmpopup/confirmpopup.esm.min.js +1 -1
- package/confirmpopup/confirmpopup.js +32 -120
- package/confirmpopup/confirmpopup.min.js +1 -1
- package/contextmenu/contextmenu.cjs.js +1 -1
- package/contextmenu/contextmenu.cjs.min.js +1 -1
- package/contextmenu/contextmenu.d.ts +1 -1
- package/contextmenu/contextmenu.esm.js +1 -1
- package/contextmenu/contextmenu.esm.min.js +1 -1
- package/contextmenu/contextmenu.js +1 -1
- package/contextmenu/contextmenu.min.js +1 -1
- package/core/core.js +725 -458
- package/core/core.min.js +40 -40
- package/datatable/datatable.cjs.js +31 -24
- package/datatable/datatable.cjs.min.js +1 -1
- package/datatable/datatable.d.ts +4 -3
- package/datatable/datatable.esm.js +31 -24
- package/datatable/datatable.esm.min.js +1 -1
- package/datatable/datatable.js +31 -24
- package/datatable/datatable.min.js +1 -1
- package/dataview/dataview.d.ts +1 -1
- package/dialog/dialog.cjs.js +27 -118
- package/dialog/dialog.cjs.min.js +1 -1
- package/dialog/dialog.d.ts +2 -2
- package/dialog/dialog.esm.js +34 -125
- package/dialog/dialog.esm.min.js +1 -1
- package/dialog/dialog.js +28 -119
- package/dialog/dialog.min.js +1 -1
- package/dropdown/dropdown.cjs.js +5 -3
- package/dropdown/dropdown.cjs.min.js +1 -1
- package/dropdown/dropdown.d.ts +1 -1
- package/dropdown/dropdown.esm.js +5 -3
- package/dropdown/dropdown.esm.min.js +1 -1
- package/dropdown/dropdown.js +6 -4
- package/dropdown/dropdown.min.js +1 -1
- package/galleria/galleria.cjs.js +1 -1
- package/galleria/galleria.cjs.min.js +1 -1
- package/galleria/galleria.esm.js +1 -1
- package/galleria/galleria.esm.min.js +1 -1
- package/galleria/galleria.js +1 -1
- package/galleria/galleria.min.js +1 -1
- package/hooks/hooks.cjs.js +215 -76
- package/hooks/hooks.cjs.min.js +1 -1
- package/hooks/hooks.d.ts +8 -4
- package/hooks/hooks.esm.js +215 -78
- package/hooks/hooks.esm.min.js +1 -1
- package/hooks/hooks.js +215 -76
- package/hooks/hooks.min.js +1 -1
- package/icons/arrowdown/index.cjs.js +1 -1
- package/icons/arrowdown/index.cjs.min.js +1 -1
- package/icons/arrowdown/index.esm.js +1 -1
- package/icons/arrowdown/index.esm.min.js +1 -1
- package/icons/arrowdown/index.js +1 -1
- package/icons/arrowdown/index.min.js +1 -1
- package/icons/arrowup/index.cjs.js +1 -1
- package/icons/arrowup/index.cjs.min.js +1 -1
- package/icons/arrowup/index.esm.js +1 -1
- package/icons/arrowup/index.esm.min.js +1 -1
- package/icons/arrowup/index.js +1 -1
- package/icons/arrowup/index.min.js +1 -1
- package/icons/ban/index.cjs.js +1 -1
- package/icons/ban/index.cjs.min.js +1 -1
- package/icons/ban/index.esm.js +1 -1
- package/icons/ban/index.esm.min.js +1 -1
- package/icons/ban/index.js +1 -1
- package/icons/ban/index.min.js +1 -1
- package/icons/download/index.cjs.js +1 -1
- package/icons/download/index.cjs.min.js +1 -1
- package/icons/download/index.esm.js +1 -1
- package/icons/download/index.esm.min.js +1 -1
- package/icons/download/index.js +1 -1
- package/icons/download/index.min.js +1 -1
- package/icons/exclamationtriangle/index.cjs.js +1 -1
- package/icons/exclamationtriangle/index.cjs.min.js +1 -1
- package/icons/exclamationtriangle/index.esm.js +1 -1
- package/icons/exclamationtriangle/index.esm.min.js +1 -1
- package/icons/exclamationtriangle/index.js +1 -1
- package/icons/exclamationtriangle/index.min.js +1 -1
- package/icons/eyeslash/index.cjs.js +1 -1
- package/icons/eyeslash/index.cjs.min.js +1 -1
- package/icons/eyeslash/index.esm.js +1 -1
- package/icons/eyeslash/index.esm.min.js +1 -1
- package/icons/eyeslash/index.js +1 -1
- package/icons/eyeslash/index.min.js +1 -1
- package/icons/filter/index.cjs.js +1 -1
- package/icons/filter/index.cjs.min.js +1 -1
- package/icons/filter/index.esm.js +1 -1
- package/icons/filter/index.esm.min.js +1 -1
- package/icons/filter/index.js +1 -1
- package/icons/filter/index.min.js +1 -1
- package/icons/filterslash/index.cjs.js +1 -1
- package/icons/filterslash/index.cjs.min.js +1 -1
- package/icons/filterslash/index.esm.js +1 -1
- package/icons/filterslash/index.esm.min.js +1 -1
- package/icons/filterslash/index.js +1 -1
- package/icons/filterslash/index.min.js +1 -1
- package/icons/infocircle/index.cjs.js +1 -1
- package/icons/infocircle/index.cjs.min.js +1 -1
- package/icons/infocircle/index.esm.js +1 -1
- package/icons/infocircle/index.esm.min.js +1 -1
- package/icons/infocircle/index.js +1 -1
- package/icons/infocircle/index.min.js +1 -1
- package/icons/pencil/index.cjs.js +1 -1
- package/icons/pencil/index.cjs.min.js +1 -1
- package/icons/pencil/index.esm.js +1 -1
- package/icons/pencil/index.esm.min.js +1 -1
- package/icons/pencil/index.js +1 -1
- package/icons/pencil/index.min.js +1 -1
- package/icons/plus/index.cjs.js +1 -1
- package/icons/plus/index.cjs.min.js +1 -1
- package/icons/plus/index.esm.js +1 -1
- package/icons/plus/index.esm.min.js +1 -1
- package/icons/plus/index.js +1 -1
- package/icons/plus/index.min.js +1 -1
- package/icons/refresh/index.cjs.js +1 -1
- package/icons/refresh/index.cjs.min.js +1 -1
- package/icons/refresh/index.esm.js +1 -1
- package/icons/refresh/index.esm.min.js +1 -1
- package/icons/refresh/index.js +1 -1
- package/icons/refresh/index.min.js +1 -1
- package/icons/search/index.cjs.js +1 -1
- package/icons/search/index.cjs.min.js +1 -1
- package/icons/search/index.esm.js +1 -1
- package/icons/search/index.esm.min.js +1 -1
- package/icons/search/index.js +1 -1
- package/icons/search/index.min.js +1 -1
- package/icons/searchminus/index.cjs.js +1 -1
- package/icons/searchminus/index.cjs.min.js +1 -1
- package/icons/searchminus/index.esm.js +1 -1
- package/icons/searchminus/index.esm.min.js +1 -1
- package/icons/searchminus/index.js +1 -1
- package/icons/searchminus/index.min.js +1 -1
- package/icons/searchplus/index.cjs.js +1 -1
- package/icons/searchplus/index.cjs.min.js +1 -1
- package/icons/searchplus/index.esm.js +1 -1
- package/icons/searchplus/index.esm.min.js +1 -1
- package/icons/searchplus/index.js +1 -1
- package/icons/searchplus/index.min.js +1 -1
- package/icons/sortalt/index.cjs.js +1 -1
- package/icons/sortalt/index.cjs.min.js +1 -1
- package/icons/sortalt/index.esm.js +1 -1
- package/icons/sortalt/index.esm.min.js +1 -1
- package/icons/sortalt/index.js +1 -1
- package/icons/sortalt/index.min.js +1 -1
- package/icons/sortamountdown/index.cjs.js +1 -1
- package/icons/sortamountdown/index.cjs.min.js +1 -1
- package/icons/sortamountdown/index.esm.js +1 -1
- package/icons/sortamountdown/index.esm.min.js +1 -1
- package/icons/sortamountdown/index.js +1 -1
- package/icons/sortamountdown/index.min.js +1 -1
- package/icons/sortamountupalt/index.cjs.js +1 -1
- package/icons/sortamountupalt/index.cjs.min.js +1 -1
- package/icons/sortamountupalt/index.esm.js +1 -1
- package/icons/sortamountupalt/index.esm.min.js +1 -1
- package/icons/sortamountupalt/index.js +1 -1
- package/icons/sortamountupalt/index.min.js +1 -1
- package/icons/spinner/index.cjs.js +1 -1
- package/icons/spinner/index.cjs.min.js +1 -1
- package/icons/spinner/index.esm.js +1 -1
- package/icons/spinner/index.esm.min.js +1 -1
- package/icons/spinner/index.js +1 -1
- package/icons/spinner/index.min.js +1 -1
- package/icons/star/index.cjs.js +1 -1
- package/icons/star/index.cjs.min.js +1 -1
- package/icons/star/index.esm.js +1 -1
- package/icons/star/index.esm.min.js +1 -1
- package/icons/star/index.js +1 -1
- package/icons/star/index.min.js +1 -1
- package/icons/starfill/index.cjs.js +1 -1
- package/icons/starfill/index.cjs.min.js +1 -1
- package/icons/starfill/index.esm.js +1 -1
- package/icons/starfill/index.esm.min.js +1 -1
- package/icons/starfill/index.js +1 -1
- package/icons/starfill/index.min.js +1 -1
- package/icons/thlarge/index.cjs.js +1 -1
- package/icons/thlarge/index.cjs.min.js +1 -1
- package/icons/thlarge/index.esm.js +1 -1
- package/icons/thlarge/index.esm.min.js +1 -1
- package/icons/thlarge/index.js +1 -1
- package/icons/thlarge/index.min.js +1 -1
- package/icons/timescircle/index.cjs.js +1 -1
- package/icons/timescircle/index.cjs.min.js +1 -1
- package/icons/timescircle/index.esm.js +1 -1
- package/icons/timescircle/index.esm.min.js +1 -1
- package/icons/timescircle/index.js +1 -1
- package/icons/timescircle/index.min.js +1 -1
- package/icons/trash/index.cjs.js +1 -1
- package/icons/trash/index.cjs.min.js +1 -1
- package/icons/trash/index.esm.js +1 -1
- package/icons/trash/index.esm.min.js +1 -1
- package/icons/trash/index.js +1 -1
- package/icons/trash/index.min.js +1 -1
- package/icons/undo/index.cjs.js +1 -1
- package/icons/undo/index.cjs.min.js +1 -1
- package/icons/undo/index.esm.js +1 -1
- package/icons/undo/index.esm.min.js +1 -1
- package/icons/undo/index.js +1 -1
- package/icons/undo/index.min.js +1 -1
- package/icons/upload/index.cjs.js +1 -1
- package/icons/upload/index.cjs.min.js +1 -1
- package/icons/upload/index.esm.js +1 -1
- package/icons/upload/index.esm.min.js +1 -1
- package/icons/upload/index.js +1 -1
- package/icons/upload/index.min.js +1 -1
- package/icons/windowmaximize/index.cjs.js +1 -1
- package/icons/windowmaximize/index.cjs.min.js +1 -1
- package/icons/windowmaximize/index.esm.js +1 -1
- package/icons/windowmaximize/index.esm.min.js +1 -1
- package/icons/windowmaximize/index.js +1 -1
- package/icons/windowmaximize/index.min.js +1 -1
- package/icons/windowminimize/index.cjs.js +1 -1
- package/icons/windowminimize/index.cjs.min.js +1 -1
- package/icons/windowminimize/index.esm.js +1 -1
- package/icons/windowminimize/index.esm.min.js +1 -1
- package/icons/windowminimize/index.js +1 -1
- package/icons/windowminimize/index.min.js +1 -1
- package/image/image.cjs.js +20 -109
- package/image/image.cjs.min.js +1 -1
- package/image/image.esm.js +22 -111
- package/image/image.esm.min.js +1 -1
- package/image/image.js +21 -110
- package/image/image.min.js +1 -1
- package/inplace/inplace.cjs.js +7 -0
- package/inplace/inplace.cjs.min.js +1 -1
- package/inplace/inplace.esm.js +7 -0
- package/inplace/inplace.esm.min.js +1 -1
- package/inplace/inplace.js +8 -2
- package/inplace/inplace.min.js +1 -1
- package/inputnumber/inputnumber.cjs.js +63 -19
- package/inputnumber/inputnumber.cjs.min.js +1 -1
- package/inputnumber/inputnumber.d.ts +7 -0
- package/inputnumber/inputnumber.esm.js +63 -19
- package/inputnumber/inputnumber.esm.min.js +1 -1
- package/inputnumber/inputnumber.js +63 -19
- package/inputnumber/inputnumber.min.js +1 -1
- package/inputswitch/inputswitch.cjs.js +3 -3
- package/inputswitch/inputswitch.cjs.min.js +1 -1
- package/inputswitch/inputswitch.esm.js +3 -3
- package/inputswitch/inputswitch.esm.min.js +1 -1
- package/inputswitch/inputswitch.js +3 -3
- package/inputswitch/inputswitch.min.js +1 -1
- package/inputtext/inputtext.cjs.js +7 -6
- package/inputtext/inputtext.cjs.min.js +1 -1
- package/inputtext/inputtext.esm.js +7 -6
- package/inputtext/inputtext.esm.min.js +1 -1
- package/inputtext/inputtext.js +7 -6
- package/inputtext/inputtext.min.js +1 -1
- package/listbox/listbox.cjs.js +14 -1
- package/listbox/listbox.cjs.min.js +1 -1
- package/listbox/listbox.d.ts +8 -3
- package/listbox/listbox.esm.js +14 -1
- package/listbox/listbox.esm.min.js +1 -1
- package/listbox/listbox.js +14 -1
- package/listbox/listbox.min.js +1 -1
- package/megamenu/megamenu.cjs.js +67 -66
- package/megamenu/megamenu.cjs.min.js +1 -1
- package/megamenu/megamenu.esm.js +69 -68
- package/megamenu/megamenu.esm.min.js +1 -1
- package/megamenu/megamenu.js +67 -66
- package/megamenu/megamenu.min.js +1 -1
- package/mention/mention.cjs.js +0 -3
- package/mention/mention.cjs.min.js +1 -1
- package/mention/mention.esm.js +1 -4
- package/mention/mention.esm.min.js +1 -1
- package/mention/mention.js +0 -3
- package/mention/mention.min.js +1 -1
- package/menu/menu.cjs.js +7 -102
- package/menu/menu.cjs.min.js +1 -1
- package/menu/menu.d.ts +1 -1
- package/menu/menu.esm.js +10 -105
- package/menu/menu.esm.min.js +1 -1
- package/menu/menu.js +7 -102
- package/menu/menu.min.js +1 -1
- package/messages/messages.cjs.js +1 -1
- package/messages/messages.cjs.min.js +1 -1
- package/messages/messages.esm.js +1 -1
- package/messages/messages.esm.min.js +1 -1
- package/messages/messages.js +1 -1
- package/messages/messages.min.js +1 -1
- package/multiselect/multiselect.cjs.js +47 -30
- package/multiselect/multiselect.cjs.min.js +1 -1
- package/multiselect/multiselect.d.ts +5 -1
- package/multiselect/multiselect.esm.js +47 -30
- package/multiselect/multiselect.esm.min.js +1 -1
- package/multiselect/multiselect.js +47 -30
- package/multiselect/multiselect.min.js +1 -1
- package/orderlist/orderlist.cjs.js +1 -1
- package/orderlist/orderlist.cjs.min.js +1 -1
- package/orderlist/orderlist.d.ts +10 -0
- package/orderlist/orderlist.esm.js +1 -1
- package/orderlist/orderlist.esm.min.js +1 -1
- package/orderlist/orderlist.js +1 -1
- package/orderlist/orderlist.min.js +1 -1
- package/organizationchart/organizationchart.cjs.js +10 -0
- package/organizationchart/organizationchart.cjs.min.js +1 -1
- package/organizationchart/organizationchart.esm.js +10 -0
- package/organizationchart/organizationchart.esm.min.js +1 -1
- package/organizationchart/organizationchart.js +10 -0
- package/organizationchart/organizationchart.min.js +1 -1
- package/overlaypanel/overlaypanel.cjs.js +9 -104
- package/overlaypanel/overlaypanel.cjs.min.js +1 -1
- package/overlaypanel/overlaypanel.d.ts +1 -1
- package/overlaypanel/overlaypanel.esm.js +11 -106
- package/overlaypanel/overlaypanel.esm.min.js +1 -1
- package/overlaypanel/overlaypanel.js +10 -105
- package/overlaypanel/overlaypanel.min.js +1 -1
- package/package.json +1 -1
- package/paginator/paginator.d.ts +2 -2
- package/panelmenu/panelmenu.cjs.js +1 -1
- package/panelmenu/panelmenu.cjs.min.js +1 -1
- package/panelmenu/panelmenu.esm.js +1 -1
- package/panelmenu/panelmenu.esm.min.js +1 -1
- package/panelmenu/panelmenu.js +1 -1
- package/panelmenu/panelmenu.min.js +1 -1
- package/passthrough/tailwind/index.cjs.js +158 -155
- package/passthrough/tailwind/index.cjs.min.js +1 -1
- package/passthrough/tailwind/index.esm.js +158 -155
- package/passthrough/tailwind/index.esm.min.js +1 -1
- package/passthrough/tailwind/index.js +158 -155
- package/passthrough/tailwind/index.min.js +1 -1
- package/password/password.cjs.js +8 -3
- package/password/password.cjs.min.js +1 -1
- package/password/password.d.ts +1 -1
- package/password/password.esm.js +9 -4
- package/password/password.esm.min.js +1 -1
- package/password/password.js +8 -3
- package/password/password.min.js +1 -1
- package/picklist/picklist.cjs.js +709 -181
- package/picklist/picklist.cjs.min.js +1 -1
- package/picklist/picklist.d.ts +10 -0
- package/picklist/picklist.esm.js +708 -180
- package/picklist/picklist.esm.min.js +1 -1
- package/picklist/picklist.js +709 -181
- package/picklist/picklist.min.js +1 -1
- package/portal/portal.cjs.js +7 -1
- package/portal/portal.cjs.min.js +1 -1
- package/portal/portal.esm.js +7 -1
- package/portal/portal.esm.min.js +1 -1
- package/portal/portal.js +7 -1
- package/portal/portal.min.js +1 -1
- package/primereact.all.cjs.js +3391 -2429
- package/primereact.all.cjs.min.js +1 -1
- package/primereact.all.esm.js +3390 -2430
- package/primereact.all.esm.min.js +1 -1
- package/primereact.all.js +3391 -2429
- package/primereact.all.min.js +1 -1
- package/radiobutton/radiobutton.cjs.js +26 -26
- package/radiobutton/radiobutton.cjs.min.js +1 -1
- package/radiobutton/radiobutton.esm.js +26 -26
- package/radiobutton/radiobutton.esm.min.js +1 -1
- package/radiobutton/radiobutton.js +27 -27
- package/radiobutton/radiobutton.min.js +1 -1
- package/resources/themes/arya-blue/theme.css +18 -9
- package/resources/themes/arya-green/theme.css +18 -9
- package/resources/themes/arya-orange/theme.css +18 -9
- package/resources/themes/arya-purple/theme.css +18 -9
- package/resources/themes/bootstrap4-dark-blue/theme.css +18 -9
- package/resources/themes/bootstrap4-dark-purple/theme.css +18 -9
- package/resources/themes/bootstrap4-light-blue/theme.css +18 -9
- package/resources/themes/bootstrap4-light-purple/theme.css +18 -9
- package/resources/themes/fluent-light/theme.css +18 -9
- package/resources/themes/lara-dark-amber/theme.css +18 -9
- package/resources/themes/lara-dark-blue/theme.css +18 -9
- package/resources/themes/lara-dark-cyan/theme.css +18 -9
- package/resources/themes/lara-dark-green/theme.css +18 -9
- package/resources/themes/lara-dark-indigo/theme.css +18 -9
- package/resources/themes/lara-dark-pink/theme.css +18 -9
- package/resources/themes/lara-dark-purple/theme.css +18 -9
- package/resources/themes/lara-dark-teal/theme.css +18 -9
- package/resources/themes/lara-light-amber/theme.css +18 -9
- package/resources/themes/lara-light-blue/theme.css +18 -9
- package/resources/themes/lara-light-cyan/theme.css +18 -9
- package/resources/themes/lara-light-green/theme.css +18 -9
- package/resources/themes/lara-light-indigo/theme.css +18 -9
- package/resources/themes/lara-light-pink/theme.css +18 -9
- package/resources/themes/lara-light-purple/theme.css +18 -9
- package/resources/themes/lara-light-teal/theme.css +18 -9
- package/resources/themes/luna-amber/theme.css +18 -9
- package/resources/themes/luna-blue/theme.css +18 -9
- package/resources/themes/luna-green/theme.css +18 -9
- package/resources/themes/luna-pink/theme.css +18 -9
- package/resources/themes/md-dark-deeppurple/theme.css +18 -9
- package/resources/themes/md-dark-indigo/theme.css +18 -9
- package/resources/themes/md-light-deeppurple/theme.css +18 -9
- package/resources/themes/md-light-indigo/theme.css +18 -9
- package/resources/themes/mdc-dark-deeppurple/theme.css +18 -9
- package/resources/themes/mdc-dark-indigo/theme.css +18 -9
- package/resources/themes/mdc-light-deeppurple/theme.css +18 -9
- package/resources/themes/mdc-light-indigo/theme.css +18 -9
- package/resources/themes/mira/theme.css +18 -9
- package/resources/themes/nano/theme.css +18 -9
- package/resources/themes/nova/theme.css +18 -9
- package/resources/themes/nova-accent/theme.css +18 -9
- package/resources/themes/nova-alt/theme.css +18 -9
- package/resources/themes/rhea/theme.css +18 -9
- package/resources/themes/saga-blue/theme.css +18 -9
- package/resources/themes/saga-green/theme.css +18 -9
- package/resources/themes/saga-orange/theme.css +18 -9
- package/resources/themes/saga-purple/theme.css +18 -9
- package/resources/themes/soho-dark/theme.css +18 -9
- package/resources/themes/soho-light/theme.css +18 -9
- package/resources/themes/tailwind-light/theme.css +18 -9
- package/resources/themes/vela-blue/theme.css +18 -9
- package/resources/themes/vela-green/theme.css +18 -9
- package/resources/themes/vela-orange/theme.css +18 -9
- package/resources/themes/vela-purple/theme.css +18 -9
- package/resources/themes/viva-dark/theme.css +18 -9
- package/resources/themes/viva-light/theme.css +18 -9
- package/ripple/ripple.cjs.js +6 -3
- package/ripple/ripple.cjs.min.js +1 -1
- package/ripple/ripple.esm.js +6 -3
- package/ripple/ripple.esm.min.js +1 -1
- package/ripple/ripple.js +6 -3
- package/ripple/ripple.min.js +1 -1
- package/sidebar/sidebar.cjs.js +8 -105
- package/sidebar/sidebar.cjs.min.js +1 -1
- package/sidebar/sidebar.d.ts +3 -3
- package/sidebar/sidebar.esm.js +11 -108
- package/sidebar/sidebar.esm.min.js +1 -1
- package/sidebar/sidebar.js +9 -106
- package/sidebar/sidebar.min.js +1 -1
- package/slidemenu/slidemenu.cjs.js +7 -102
- package/slidemenu/slidemenu.cjs.min.js +1 -1
- package/slidemenu/slidemenu.d.ts +1 -1
- package/slidemenu/slidemenu.esm.js +10 -105
- package/slidemenu/slidemenu.esm.min.js +1 -1
- package/slidemenu/slidemenu.js +7 -102
- package/slidemenu/slidemenu.min.js +1 -1
- package/slider/slider.cjs.js +1 -1
- package/slider/slider.cjs.min.js +1 -1
- package/slider/slider.esm.js +1 -1
- package/slider/slider.esm.min.js +1 -1
- package/slider/slider.js +1 -1
- package/slider/slider.min.js +1 -1
- package/speeddial/speeddial.cjs.js +11 -3
- package/speeddial/speeddial.cjs.min.js +1 -1
- package/speeddial/speeddial.esm.js +12 -4
- package/speeddial/speeddial.esm.min.js +1 -1
- package/speeddial/speeddial.js +11 -3
- package/speeddial/speeddial.min.js +1 -1
- package/splitbutton/splitbutton.cjs.js +89 -81
- package/splitbutton/splitbutton.cjs.min.js +1 -1
- package/splitbutton/splitbutton.d.ts +1 -1
- package/splitbutton/splitbutton.esm.js +90 -82
- package/splitbutton/splitbutton.esm.min.js +1 -1
- package/splitbutton/splitbutton.js +89 -81
- package/splitbutton/splitbutton.min.js +1 -1
- package/tabmenu/tabmenu.cjs.js +9 -7
- package/tabmenu/tabmenu.cjs.min.js +1 -1
- package/tabmenu/tabmenu.esm.js +9 -7
- package/tabmenu/tabmenu.esm.min.js +1 -1
- package/tabmenu/tabmenu.js +9 -7
- package/tabmenu/tabmenu.min.js +1 -1
- package/tabview/tabview.cjs.js +22 -8
- package/tabview/tabview.cjs.min.js +1 -1
- package/tabview/tabview.d.ts +35 -0
- package/tabview/tabview.esm.js +22 -8
- package/tabview/tabview.esm.min.js +1 -1
- package/tabview/tabview.js +22 -8
- package/tabview/tabview.min.js +1 -1
- package/tieredmenu/tieredmenu.cjs.js +1 -1
- package/tieredmenu/tieredmenu.cjs.min.js +1 -1
- package/tieredmenu/tieredmenu.d.ts +1 -1
- package/tieredmenu/tieredmenu.esm.js +1 -1
- package/tieredmenu/tieredmenu.esm.min.js +1 -1
- package/tieredmenu/tieredmenu.js +1 -1
- package/tieredmenu/tieredmenu.min.js +1 -1
- package/toast/toast.d.ts +2 -2
- package/togglebutton/togglebutton.cjs.js +74 -4
- package/togglebutton/togglebutton.cjs.min.js +1 -1
- package/togglebutton/togglebutton.esm.js +74 -4
- package/togglebutton/togglebutton.esm.min.js +1 -1
- package/togglebutton/togglebutton.js +75 -5
- package/togglebutton/togglebutton.min.js +1 -1
- package/tooltip/tooltip.d.ts +27 -0
- package/tooltip/tooltipoptions.d.ts +1 -1
- package/tree/tree.cjs.js +244 -131
- package/tree/tree.cjs.min.js +1 -1
- package/tree/tree.d.ts +8 -0
- package/tree/tree.esm.js +245 -132
- package/tree/tree.esm.min.js +1 -1
- package/tree/tree.js +244 -131
- package/tree/tree.min.js +1 -1
- package/treeselect/treeselect.cjs.js +185 -49
- package/treeselect/treeselect.cjs.min.js +1 -1
- package/treeselect/treeselect.d.ts +26 -1
- package/treeselect/treeselect.esm.js +186 -50
- package/treeselect/treeselect.esm.min.js +1 -1
- package/treeselect/treeselect.js +186 -51
- package/treeselect/treeselect.min.js +1 -1
- package/treetable/treetable.cjs.js +67 -44
- package/treetable/treetable.cjs.min.js +1 -1
- package/treetable/treetable.d.ts +3 -3
- package/treetable/treetable.esm.js +67 -44
- package/treetable/treetable.esm.min.js +1 -1
- package/treetable/treetable.js +67 -44
- package/treetable/treetable.min.js +1 -1
- package/utils/utils.cjs.js +7 -4
- package/utils/utils.cjs.min.js +1 -1
- package/utils/utils.d.ts +1 -1
- package/utils/utils.esm.js +7 -4
- package/utils/utils.esm.min.js +1 -1
- package/utils/utils.js +7 -4
- package/utils/utils.min.js +1 -1
- package/web-types.json +136 -29
package/core/core.js
CHANGED
|
@@ -1221,10 +1221,13 @@ this.primereact.utils = (function (exports, React) {
|
|
|
1221
1221
|
}
|
|
1222
1222
|
}, {
|
|
1223
1223
|
key: "createInlineStyle",
|
|
1224
|
-
value: function createInlineStyle(nonce) {
|
|
1224
|
+
value: function createInlineStyle(nonce, styleContainer) {
|
|
1225
1225
|
var styleElement = document.createElement('style');
|
|
1226
1226
|
DomHandler.addNonce(styleElement, nonce);
|
|
1227
|
-
|
|
1227
|
+
if (!styleContainer) {
|
|
1228
|
+
styleContainer = document.head;
|
|
1229
|
+
}
|
|
1230
|
+
styleContainer.appendChild(styleElement);
|
|
1228
1231
|
return styleElement;
|
|
1229
1232
|
}
|
|
1230
1233
|
}, {
|
|
@@ -1232,7 +1235,7 @@ this.primereact.utils = (function (exports, React) {
|
|
|
1232
1235
|
value: function removeInlineStyle(styleElement) {
|
|
1233
1236
|
if (this.isExist(styleElement)) {
|
|
1234
1237
|
try {
|
|
1235
|
-
|
|
1238
|
+
styleElement.parentNode.removeChild(styleElement);
|
|
1236
1239
|
} catch (error) {
|
|
1237
1240
|
// style element may have already been removed in a fast refresh
|
|
1238
1241
|
}
|
|
@@ -1752,7 +1755,7 @@ this.primereact.utils = (function (exports, React) {
|
|
|
1752
1755
|
}, {
|
|
1753
1756
|
key: "isLetter",
|
|
1754
1757
|
value: function isLetter(_char2) {
|
|
1755
|
-
return
|
|
1758
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
1756
1759
|
}
|
|
1757
1760
|
|
|
1758
1761
|
/**
|
|
@@ -3333,59 +3336,63 @@ this.primereact.api = (function (exports, utils, React) {
|
|
|
3333
3336
|
_useState8 = _slicedToArray(_useState7, 2),
|
|
3334
3337
|
appendTo = _useState8[0],
|
|
3335
3338
|
setAppendTo = _useState8[1];
|
|
3336
|
-
var _useState9 = React.useState(propsValue.
|
|
3339
|
+
var _useState9 = React.useState(propsValue.styleContainer || null),
|
|
3337
3340
|
_useState10 = _slicedToArray(_useState9, 2),
|
|
3338
|
-
|
|
3339
|
-
|
|
3340
|
-
var _useState11 = React.useState(propsValue.
|
|
3341
|
+
styleContainer = _useState10[0],
|
|
3342
|
+
setStyleContainer = _useState10[1];
|
|
3343
|
+
var _useState11 = React.useState(propsValue.cssTransition || true),
|
|
3341
3344
|
_useState12 = _slicedToArray(_useState11, 2),
|
|
3342
|
-
|
|
3343
|
-
|
|
3344
|
-
var _useState13 = React.useState(propsValue.
|
|
3345
|
+
cssTransition = _useState12[0],
|
|
3346
|
+
setCssTransition = _useState12[1];
|
|
3347
|
+
var _useState13 = React.useState(propsValue.autoZIndex || true),
|
|
3345
3348
|
_useState14 = _slicedToArray(_useState13, 2),
|
|
3346
|
-
|
|
3347
|
-
|
|
3348
|
-
var _useState15 = React.useState(propsValue.
|
|
3349
|
+
autoZIndex = _useState14[0],
|
|
3350
|
+
setAutoZIndex = _useState14[1];
|
|
3351
|
+
var _useState15 = React.useState(propsValue.hideOverlaysOnDocumentScrolling || false),
|
|
3349
3352
|
_useState16 = _slicedToArray(_useState15, 2),
|
|
3350
|
-
|
|
3351
|
-
|
|
3352
|
-
var _useState17 = React.useState(propsValue.
|
|
3353
|
+
hideOverlaysOnDocumentScrolling = _useState16[0],
|
|
3354
|
+
setHideOverlaysOnDocumentScrolling = _useState16[1];
|
|
3355
|
+
var _useState17 = React.useState(propsValue.nonce || null),
|
|
3353
3356
|
_useState18 = _slicedToArray(_useState17, 2),
|
|
3354
|
-
|
|
3355
|
-
|
|
3356
|
-
var _useState19 = React.useState(propsValue.
|
|
3357
|
+
nonce = _useState18[0],
|
|
3358
|
+
setNonce = _useState18[1];
|
|
3359
|
+
var _useState19 = React.useState(propsValue.nullSortOrder || 1),
|
|
3360
|
+
_useState20 = _slicedToArray(_useState19, 2),
|
|
3361
|
+
nullSortOrder = _useState20[0],
|
|
3362
|
+
setNullSortOrder = _useState20[1];
|
|
3363
|
+
var _useState21 = React.useState(propsValue.zIndex || {
|
|
3357
3364
|
modal: 1100,
|
|
3358
3365
|
overlay: 1000,
|
|
3359
3366
|
menu: 1000,
|
|
3360
3367
|
tooltip: 1100,
|
|
3361
3368
|
toast: 1200
|
|
3362
3369
|
}),
|
|
3363
|
-
|
|
3364
|
-
zIndex =
|
|
3365
|
-
setZIndex =
|
|
3366
|
-
var
|
|
3370
|
+
_useState22 = _slicedToArray(_useState21, 2),
|
|
3371
|
+
zIndex = _useState22[0],
|
|
3372
|
+
setZIndex = _useState22[1];
|
|
3373
|
+
var _useState23 = React.useState(propsValue.ptOptions || {
|
|
3367
3374
|
mergeSections: true,
|
|
3368
3375
|
mergeProps: true
|
|
3369
3376
|
}),
|
|
3370
|
-
_useState22 = _slicedToArray(_useState21, 2),
|
|
3371
|
-
ptOptions = _useState22[0],
|
|
3372
|
-
setPtOptions = _useState22[1];
|
|
3373
|
-
var _useState23 = React.useState(propsValue.pt || undefined),
|
|
3374
3377
|
_useState24 = _slicedToArray(_useState23, 2),
|
|
3375
|
-
|
|
3376
|
-
|
|
3377
|
-
var _useState25 = React.useState(propsValue.
|
|
3378
|
+
ptOptions = _useState24[0],
|
|
3379
|
+
setPtOptions = _useState24[1];
|
|
3380
|
+
var _useState25 = React.useState(propsValue.pt || undefined),
|
|
3378
3381
|
_useState26 = _slicedToArray(_useState25, 2),
|
|
3379
|
-
|
|
3380
|
-
|
|
3381
|
-
var _useState27 = React.useState(propsValue.
|
|
3382
|
+
pt = _useState26[0],
|
|
3383
|
+
setPt = _useState26[1];
|
|
3384
|
+
var _useState27 = React.useState(propsValue.unstyled || false),
|
|
3385
|
+
_useState28 = _slicedToArray(_useState27, 2),
|
|
3386
|
+
unstyled = _useState28[0],
|
|
3387
|
+
setUnstyled = _useState28[1];
|
|
3388
|
+
var _useState29 = React.useState(propsValue.filterMatchModeOptions || {
|
|
3382
3389
|
text: [FilterMatchMode.STARTS_WITH, FilterMatchMode.CONTAINS, FilterMatchMode.NOT_CONTAINS, FilterMatchMode.ENDS_WITH, FilterMatchMode.EQUALS, FilterMatchMode.NOT_EQUALS],
|
|
3383
3390
|
numeric: [FilterMatchMode.EQUALS, FilterMatchMode.NOT_EQUALS, FilterMatchMode.LESS_THAN, FilterMatchMode.LESS_THAN_OR_EQUAL_TO, FilterMatchMode.GREATER_THAN, FilterMatchMode.GREATER_THAN_OR_EQUAL_TO],
|
|
3384
3391
|
date: [FilterMatchMode.DATE_IS, FilterMatchMode.DATE_IS_NOT, FilterMatchMode.DATE_BEFORE, FilterMatchMode.DATE_AFTER]
|
|
3385
3392
|
}),
|
|
3386
|
-
|
|
3387
|
-
filterMatchModeOptions =
|
|
3388
|
-
setFilterMatchModeOptions =
|
|
3393
|
+
_useState30 = _slicedToArray(_useState29, 2),
|
|
3394
|
+
filterMatchModeOptions = _useState30[0],
|
|
3395
|
+
setFilterMatchModeOptions = _useState30[1];
|
|
3389
3396
|
var changeTheme = function changeTheme(currentTheme, newTheme, linkElementId, callback) {
|
|
3390
3397
|
var _linkElement$parentNo;
|
|
3391
3398
|
var linkElement = document.getElementById(linkElementId);
|
|
@@ -3433,6 +3440,8 @@ this.primereact.api = (function (exports, utils, React) {
|
|
|
3433
3440
|
setLocale: setLocale,
|
|
3434
3441
|
appendTo: appendTo,
|
|
3435
3442
|
setAppendTo: setAppendTo,
|
|
3443
|
+
styleContainer: styleContainer,
|
|
3444
|
+
setStyleContainer: setStyleContainer,
|
|
3436
3445
|
cssTransition: cssTransition,
|
|
3437
3446
|
setCssTransition: setCssTransition,
|
|
3438
3447
|
autoZIndex: autoZIndex,
|
|
@@ -3492,6 +3501,37 @@ this.primereact.componentbase = (function (exports, PrimeReact, hooks, utils) {
|
|
|
3492
3501
|
|
|
3493
3502
|
var PrimeReact__default = /*#__PURE__*/_interopDefaultLegacy(PrimeReact);
|
|
3494
3503
|
|
|
3504
|
+
function _arrayLikeToArray(arr, len) {
|
|
3505
|
+
if (len == null || len > arr.length) len = arr.length;
|
|
3506
|
+
for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];
|
|
3507
|
+
return arr2;
|
|
3508
|
+
}
|
|
3509
|
+
|
|
3510
|
+
function _arrayWithoutHoles(arr) {
|
|
3511
|
+
if (Array.isArray(arr)) return _arrayLikeToArray(arr);
|
|
3512
|
+
}
|
|
3513
|
+
|
|
3514
|
+
function _iterableToArray(iter) {
|
|
3515
|
+
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
|
|
3516
|
+
}
|
|
3517
|
+
|
|
3518
|
+
function _unsupportedIterableToArray(o, minLen) {
|
|
3519
|
+
if (!o) return;
|
|
3520
|
+
if (typeof o === "string") return _arrayLikeToArray(o, minLen);
|
|
3521
|
+
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
3522
|
+
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
3523
|
+
if (n === "Map" || n === "Set") return Array.from(o);
|
|
3524
|
+
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);
|
|
3525
|
+
}
|
|
3526
|
+
|
|
3527
|
+
function _nonIterableSpread() {
|
|
3528
|
+
throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
3529
|
+
}
|
|
3530
|
+
|
|
3531
|
+
function _toConsumableArray(arr) {
|
|
3532
|
+
return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread();
|
|
3533
|
+
}
|
|
3534
|
+
|
|
3495
3535
|
function _typeof(o) {
|
|
3496
3536
|
"@babel/helpers - typeof";
|
|
3497
3537
|
|
|
@@ -3578,7 +3618,7 @@ this.primereact.componentbase = (function (exports, PrimeReact, hooks, utils) {
|
|
|
3578
3618
|
var checkboxStyles = "\n.p-checkbox {\n display: inline-flex;\n cursor: pointer;\n user-select: none;\n vertical-align: bottom;\n position: relative;\n}\n\n.p-checkbox.p-checkbox-disabled {\n cursor: auto;\n}\n\n.p-checkbox-box {\n display: flex;\n justify-content: center;\n align-items: center;\n}\n";
|
|
3579
3619
|
var inputTextStyles = "\n.p-inputtext {\n margin: 0;\n}\n\n.p-fluid .p-inputtext {\n width: 100%;\n}\n\n/* InputGroup */\n.p-inputgroup {\n display: flex;\n align-items: stretch;\n width: 100%;\n}\n\n.p-inputgroup-addon {\n display: flex;\n align-items: center;\n justify-content: center;\n}\n\n.p-inputgroup .p-float-label {\n display: flex;\n align-items: stretch;\n width: 100%;\n}\n\n.p-inputgroup .p-inputtext,\n.p-fluid .p-inputgroup .p-inputtext,\n.p-inputgroup .p-inputwrapper,\n.p-fluid .p-inputgroup .p-input {\n flex: 1 1 auto;\n width: 1%;\n}\n\n/* Floating Label */\n.p-float-label {\n display: block;\n position: relative;\n}\n\n.p-float-label label {\n position: absolute;\n pointer-events: none;\n top: 50%;\n margin-top: -0.5rem;\n transition-property: all;\n transition-timing-function: ease;\n line-height: 1;\n}\n\n.p-float-label textarea ~ label,\n.p-float-label .p-mention ~ label {\n top: 1rem;\n}\n\n.p-float-label input:focus ~ label,\n.p-float-label input:-webkit-autofill ~ label,\n.p-float-label input.p-filled ~ label,\n.p-float-label textarea:focus ~ label,\n.p-float-label textarea.p-filled ~ label,\n.p-float-label .p-inputwrapper-focus ~ label,\n.p-float-label .p-inputwrapper-filled ~ label,\n.p-float-label .p-tooltip-target-wrapper ~ label {\n top: -0.75rem;\n font-size: 12px;\n}\n\n.p-float-label .p-placeholder,\n.p-float-label input::placeholder,\n.p-float-label .p-inputtext::placeholder {\n opacity: 0;\n transition-property: all;\n transition-timing-function: ease;\n}\n\n.p-float-label .p-focus .p-placeholder,\n.p-float-label input:focus::placeholder,\n.p-float-label .p-inputtext:focus::placeholder {\n opacity: 1;\n transition-property: all;\n transition-timing-function: ease;\n}\n\n.p-input-icon-left,\n.p-input-icon-right {\n position: relative;\n display: inline-block;\n}\n\n.p-input-icon-left > i,\n.p-input-icon-right > i,\n.p-input-icon-left > svg,\n.p-input-icon-right > svg,\n.p-input-icon-left > .p-input-prefix,\n.p-input-icon-right > .p-input-suffix {\n position: absolute;\n top: 50%;\n margin-top: -0.5rem;\n}\n\n.p-fluid .p-input-icon-left,\n.p-fluid .p-input-icon-right {\n display: block;\n width: 100%;\n}\n";
|
|
3580
3620
|
var radioButtonStyles = "\n.p-radiobutton {\n display: inline-flex;\n cursor: pointer;\n user-select: none;\n vertical-align: bottom;\n}\n\n.p-radiobutton-box {\n display: flex;\n justify-content: center;\n align-items: center;\n}\n\n.p-radiobutton-icon {\n -webkit-backface-visibility: hidden;\n backface-visibility: hidden;\n transform: translateZ(0) scale(.1);\n border-radius: 50%;\n visibility: hidden;\n}\n\n.p-radiobutton-box.p-highlight .p-radiobutton-icon {\n transform: translateZ(0) scale(1.0, 1.0);\n visibility: visible;\n}\n\n";
|
|
3581
|
-
var iconStyles = "\n.p-icon {\n display: inline-block;\n}\n\n.p-icon-spin {\n -webkit-animation: p-icon-spin 2s infinite linear;\n animation: p-icon-spin 2s infinite linear;\n}\n\nsvg.p-icon {\n pointer-events: auto;\n}\n\nsvg.p-icon g {\n pointer-events: none;\n}\n\n@-webkit-keyframes p-icon-spin {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(359deg);\n transform: rotate(359deg);\n }\n}\n\n@keyframes p-icon-spin {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(359deg);\n transform: rotate(359deg);\n }\n}\n";
|
|
3621
|
+
var iconStyles = "\n.p-icon {\n display: inline-block;\n}\n\n.p-icon-spin {\n -webkit-animation: p-icon-spin 2s infinite linear;\n animation: p-icon-spin 2s infinite linear;\n}\n\nsvg.p-icon {\n pointer-events: auto;\n}\n\nsvg.p-icon g,\n.p-disabled svg.p-icon {\n pointer-events: none;\n}\n\n@-webkit-keyframes p-icon-spin {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(359deg);\n transform: rotate(359deg);\n }\n}\n\n@keyframes p-icon-spin {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(359deg);\n transform: rotate(359deg);\n }\n}\n";
|
|
3582
3622
|
var commonStyle = "\n@layer primereact {\n .p-component, .p-component * {\n box-sizing: border-box;\n }\n\n .p-hidden {\n display: none;\n }\n\n .p-hidden-space {\n visibility: hidden;\n }\n\n .p-reset {\n margin: 0;\n padding: 0;\n border: 0;\n outline: 0;\n text-decoration: none;\n font-size: 100%;\n list-style: none;\n }\n\n .p-disabled, .p-disabled * {\n cursor: default;\n pointer-events: none;\n user-select: none;\n }\n\n .p-component-overlay {\n position: fixed;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n }\n\n .p-unselectable-text {\n user-select: none;\n }\n\n .p-scrollbar-measure {\n width: 100px;\n height: 100px;\n overflow: scroll;\n position: absolute;\n top: -9999px;\n }\n\n @-webkit-keyframes p-fadein {\n 0% { opacity: 0; }\n 100% { opacity: 1; }\n }\n @keyframes p-fadein {\n 0% { opacity: 0; }\n 100% { opacity: 1; }\n }\n\n .p-link {\n text-align: left;\n background-color: transparent;\n margin: 0;\n padding: 0;\n border: none;\n cursor: pointer;\n user-select: none;\n }\n\n .p-link:disabled {\n cursor: default;\n }\n\n /* Non react overlay animations */\n .p-connected-overlay {\n opacity: 0;\n transform: scaleY(0.8);\n transition: transform .12s cubic-bezier(0, 0, 0.2, 1), opacity .12s cubic-bezier(0, 0, 0.2, 1);\n }\n\n .p-connected-overlay-visible {\n opacity: 1;\n transform: scaleY(1);\n }\n\n .p-connected-overlay-hidden {\n opacity: 0;\n transform: scaleY(1);\n transition: opacity .1s linear;\n }\n\n /* React based overlay animations */\n .p-connected-overlay-enter {\n opacity: 0;\n transform: scaleY(0.8);\n }\n\n .p-connected-overlay-enter-active {\n opacity: 1;\n transform: scaleY(1);\n transition: transform .12s cubic-bezier(0, 0, 0.2, 1), opacity .12s cubic-bezier(0, 0, 0.2, 1);\n }\n\n .p-connected-overlay-enter-done {\n transform: none;\n }\n\n .p-connected-overlay-exit {\n opacity: 1;\n }\n\n .p-connected-overlay-exit-active {\n opacity: 0;\n transition: opacity .1s linear;\n }\n\n /* Toggleable Content */\n .p-toggleable-content-enter {\n max-height: 0;\n }\n\n .p-toggleable-content-enter-active {\n overflow: hidden;\n max-height: 1000px;\n transition: max-height 1s ease-in-out;\n }\n\n .p-toggleable-content-enter-done {\n transform: none;\n }\n\n .p-toggleable-content-exit {\n max-height: 1000px;\n }\n\n .p-toggleable-content-exit-active {\n overflow: hidden;\n max-height: 0;\n transition: max-height 0.45s cubic-bezier(0, 1, 0, 1);\n }\n\n .p-sr-only {\n border: 0;\n clip: rect(1px, 1px, 1px, 1px);\n clip-path: inset(50%);\n height: 1px;\n margin: -1px;\n overflow: hidden;\n padding: 0;\n position: absolute;\n width: 1px;\n word-wrap: normal;\n }\n\n /* @todo Refactor */\n .p-menu .p-menuitem-link {\n cursor: pointer;\n display: flex;\n align-items: center;\n text-decoration: none;\n overflow: hidden;\n position: relative;\n }\n\n ".concat(buttonStyles, "\n ").concat(checkboxStyles, "\n ").concat(inputTextStyles, "\n ").concat(radioButtonStyles, "\n ").concat(iconStyles, "\n}\n");
|
|
3583
3623
|
var ComponentBase = {
|
|
3584
3624
|
cProps: undefined,
|
|
@@ -3616,12 +3656,13 @@ this.primereact.componentbase = (function (exports, PrimeReact, hooks, utils) {
|
|
|
3616
3656
|
if (obj.hasOwnProperty('pt') && obj.pt !== undefined) {
|
|
3617
3657
|
obj = obj.pt;
|
|
3618
3658
|
}
|
|
3659
|
+
var originalkey = key;
|
|
3660
|
+
var isNestedParam = /./g.test(originalkey) && !!params[originalkey.split('.')[0]];
|
|
3661
|
+
var fkey = isNestedParam ? utils.ObjectUtils.toFlatCase(originalkey.split('.')[1]) : utils.ObjectUtils.toFlatCase(originalkey);
|
|
3619
3662
|
var hostName = params.hostName && utils.ObjectUtils.toFlatCase(params.hostName);
|
|
3620
3663
|
var componentName = hostName || params.props && params.props.__TYPE && utils.ObjectUtils.toFlatCase(params.props.__TYPE) || '';
|
|
3621
|
-
var
|
|
3622
|
-
var isTransition = key === 'transition' || /./g.test(key) && !!(key.split('.')[1] === 'transition');
|
|
3664
|
+
var isTransition = fkey === 'transition';
|
|
3623
3665
|
var datasetPrefix = 'data-pc-';
|
|
3624
|
-
var fkey = isNestedParam ? utils.ObjectUtils.toFlatCase(key.split('.')[1]) : utils.ObjectUtils.toFlatCase(key);
|
|
3625
3666
|
var getHostInstance = function getHostInstance(params) {
|
|
3626
3667
|
return params !== null && params !== void 0 && params.props ? params.hostName ? params.props.__TYPE === params.hostName ? params.props : getHostInstance(params.parent) : params.parent : undefined;
|
|
3627
3668
|
};
|
|
@@ -3638,12 +3679,21 @@ this.primereact.componentbase = (function (exports, PrimeReact, hooks, utils) {
|
|
|
3638
3679
|
useMergeProps = _ref$mergeProps === void 0 ? false : _ref$mergeProps;
|
|
3639
3680
|
var getPTClassValue = function getPTClassValue() {
|
|
3640
3681
|
var value = getOptionValue.apply(void 0, arguments);
|
|
3641
|
-
|
|
3682
|
+
if (Array.isArray(value)) return {
|
|
3683
|
+
className: utils.classNames.apply(void 0, _toConsumableArray(value))
|
|
3684
|
+
};
|
|
3685
|
+
if (utils.ObjectUtils.isString(value)) return {
|
|
3642
3686
|
className: value
|
|
3643
|
-
}
|
|
3687
|
+
};
|
|
3688
|
+
if (value !== null && value !== void 0 && value.hasOwnProperty('className') && Array.isArray(value.className)) {
|
|
3689
|
+
return {
|
|
3690
|
+
className: utils.classNames.apply(void 0, _toConsumableArray(value.className))
|
|
3691
|
+
};
|
|
3692
|
+
}
|
|
3693
|
+
return value;
|
|
3644
3694
|
};
|
|
3645
|
-
var globalPT = searchInDefaultPT ? isNestedParam ? _useGlobalPT(getPTClassValue,
|
|
3646
|
-
var self = isNestedParam ? undefined : _usePT(_getPT(obj, componentName), getPTClassValue,
|
|
3695
|
+
var globalPT = searchInDefaultPT ? isNestedParam ? _useGlobalPT(getPTClassValue, originalkey, params) : _useDefaultPT(getPTClassValue, originalkey, params) : undefined;
|
|
3696
|
+
var self = isNestedParam ? undefined : _usePT(_getPT(obj, componentName), getPTClassValue, originalkey, params);
|
|
3647
3697
|
var datasetProps = !isTransition && _objectSpread(_objectSpread({}, fkey === 'root' && _defineProperty({}, "".concat(datasetPrefix, "name"), params.props && params.props.__parentMetadata ? utils.ObjectUtils.toFlatCase(params.props.__TYPE) : componentName)), {}, _defineProperty({}, "".concat(datasetPrefix, "section"), fkey));
|
|
3648
3698
|
return mergeSections || !mergeSections && self ? useMergeProps ? mergeProps(globalPT, self, Object.keys(datasetProps).length ? datasetProps : {}) : _objectSpread(_objectSpread(_objectSpread({}, globalPT), self), Object.keys(datasetProps).length ? datasetProps : {}) : _objectSpread(_objectSpread({}, self), Object.keys(datasetProps).length ? datasetProps : {});
|
|
3649
3699
|
};
|
|
@@ -4047,36 +4097,6 @@ this.primereact.hooks = (function (exports, React, utils, PrimeReact) {
|
|
|
4047
4097
|
};
|
|
4048
4098
|
};
|
|
4049
4099
|
|
|
4050
|
-
/* eslint-disable */
|
|
4051
|
-
var useTimeout = function useTimeout(fn) {
|
|
4052
|
-
var delay = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
|
|
4053
|
-
var when = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
|
|
4054
|
-
var timeout = React__namespace.useRef(null);
|
|
4055
|
-
var savedCallback = React__namespace.useRef(null);
|
|
4056
|
-
var clear = React__namespace.useCallback(function () {
|
|
4057
|
-
return clearTimeout(timeout.current);
|
|
4058
|
-
}, [timeout.current]);
|
|
4059
|
-
React__namespace.useEffect(function () {
|
|
4060
|
-
savedCallback.current = fn;
|
|
4061
|
-
});
|
|
4062
|
-
React__namespace.useEffect(function () {
|
|
4063
|
-
function callback() {
|
|
4064
|
-
savedCallback.current();
|
|
4065
|
-
}
|
|
4066
|
-
if (when) {
|
|
4067
|
-
timeout.current = setTimeout(callback, delay);
|
|
4068
|
-
return clear;
|
|
4069
|
-
} else {
|
|
4070
|
-
clear();
|
|
4071
|
-
}
|
|
4072
|
-
}, [delay, when]);
|
|
4073
|
-
useUnmountEffect(function () {
|
|
4074
|
-
clear();
|
|
4075
|
-
});
|
|
4076
|
-
return [clear];
|
|
4077
|
-
};
|
|
4078
|
-
/* eslint-enable */
|
|
4079
|
-
|
|
4080
4100
|
var useDebounce = function useDebounce(initialValue, delay) {
|
|
4081
4101
|
var _React$useState = React__namespace.useState(initialValue),
|
|
4082
4102
|
_React$useState2 = _slicedToArray(_React$useState, 2),
|
|
@@ -4086,12 +4106,64 @@ this.primereact.hooks = (function (exports, React, utils, PrimeReact) {
|
|
|
4086
4106
|
_React$useState4 = _slicedToArray(_React$useState3, 2),
|
|
4087
4107
|
debouncedValue = _React$useState4[0],
|
|
4088
4108
|
setDebouncedValue = _React$useState4[1];
|
|
4089
|
-
|
|
4090
|
-
|
|
4091
|
-
|
|
4109
|
+
var mountedRef = React__namespace.useRef(false);
|
|
4110
|
+
var timeoutRef = React__namespace.useRef(null);
|
|
4111
|
+
var cancelTimer = function cancelTimer() {
|
|
4112
|
+
return window.clearTimeout(timeoutRef.current);
|
|
4113
|
+
};
|
|
4114
|
+
useMountEffect(function () {
|
|
4115
|
+
mountedRef.current = true;
|
|
4116
|
+
});
|
|
4117
|
+
useUnmountEffect(function () {
|
|
4118
|
+
cancelTimer();
|
|
4119
|
+
});
|
|
4120
|
+
React__namespace.useEffect(function () {
|
|
4121
|
+
if (!mountedRef.current) {
|
|
4122
|
+
return;
|
|
4123
|
+
}
|
|
4124
|
+
cancelTimer();
|
|
4125
|
+
timeoutRef.current = window.setTimeout(function () {
|
|
4126
|
+
setDebouncedValue(inputValue);
|
|
4127
|
+
}, delay);
|
|
4128
|
+
}, [inputValue, delay]);
|
|
4092
4129
|
return [inputValue, debouncedValue, setInputValue];
|
|
4093
4130
|
};
|
|
4094
4131
|
|
|
4132
|
+
var groupToDisplayedElements = {};
|
|
4133
|
+
var useDisplayOrder = function useDisplayOrder(group) {
|
|
4134
|
+
var isVisible = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
|
|
4135
|
+
var _React$useState = React__namespace.useState(function () {
|
|
4136
|
+
return utils.UniqueComponentId();
|
|
4137
|
+
}),
|
|
4138
|
+
_React$useState2 = _slicedToArray(_React$useState, 1),
|
|
4139
|
+
uid = _React$useState2[0];
|
|
4140
|
+
var _React$useState3 = React__namespace.useState(),
|
|
4141
|
+
_React$useState4 = _slicedToArray(_React$useState3, 2),
|
|
4142
|
+
displayOrder = _React$useState4[0],
|
|
4143
|
+
setDisplayOrder = _React$useState4[1];
|
|
4144
|
+
React__namespace.useEffect(function () {
|
|
4145
|
+
if (isVisible) {
|
|
4146
|
+
if (!(group in groupToDisplayedElements)) {
|
|
4147
|
+
groupToDisplayedElements[group] = [];
|
|
4148
|
+
}
|
|
4149
|
+
var newDisplayOrder = groupToDisplayedElements[group].length;
|
|
4150
|
+
groupToDisplayedElements[group].push(uid);
|
|
4151
|
+
setDisplayOrder(newDisplayOrder);
|
|
4152
|
+
return function () {
|
|
4153
|
+
delete groupToDisplayedElements[group][newDisplayOrder];
|
|
4154
|
+
var lastOrder = groupToDisplayedElements[group].findLastIndex(function (el) {
|
|
4155
|
+
return el !== undefined;
|
|
4156
|
+
});
|
|
4157
|
+
|
|
4158
|
+
// Reduce array length, by removing undefined elements at the end of array:
|
|
4159
|
+
groupToDisplayedElements[group].splice(lastOrder + 1);
|
|
4160
|
+
setDisplayOrder(undefined);
|
|
4161
|
+
};
|
|
4162
|
+
}
|
|
4163
|
+
}, [group, uid, isVisible]);
|
|
4164
|
+
return displayOrder;
|
|
4165
|
+
};
|
|
4166
|
+
|
|
4095
4167
|
var TYPE_MAP = {
|
|
4096
4168
|
ico: 'image/x-icon',
|
|
4097
4169
|
png: 'image/png',
|
|
@@ -4116,6 +4188,121 @@ this.primereact.hooks = (function (exports, React, utils, PrimeReact) {
|
|
|
4116
4188
|
}, [newIcon, rel]);
|
|
4117
4189
|
};
|
|
4118
4190
|
|
|
4191
|
+
function _arrayWithoutHoles(arr) {
|
|
4192
|
+
if (Array.isArray(arr)) return _arrayLikeToArray(arr);
|
|
4193
|
+
}
|
|
4194
|
+
|
|
4195
|
+
function _iterableToArray(iter) {
|
|
4196
|
+
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
|
|
4197
|
+
}
|
|
4198
|
+
|
|
4199
|
+
function _nonIterableSpread() {
|
|
4200
|
+
throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
4201
|
+
}
|
|
4202
|
+
|
|
4203
|
+
function _toConsumableArray(arr) {
|
|
4204
|
+
return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread();
|
|
4205
|
+
}
|
|
4206
|
+
|
|
4207
|
+
/**
|
|
4208
|
+
* Priorities of different components (bigger number handled first)
|
|
4209
|
+
*/
|
|
4210
|
+
var ESC_KEY_HANDLING_PRIORITIES = {
|
|
4211
|
+
SIDEBAR: 100,
|
|
4212
|
+
SLIDE_MENU: 200,
|
|
4213
|
+
DIALOG: 300,
|
|
4214
|
+
IMAGE: 400,
|
|
4215
|
+
MENU: 500,
|
|
4216
|
+
OVERLAY_PANEL: 600,
|
|
4217
|
+
PASSWORD: 700,
|
|
4218
|
+
CASCADE_SELECT: 800,
|
|
4219
|
+
SPLIT_BUTTON: 900,
|
|
4220
|
+
SPEED_DIAL: 1000
|
|
4221
|
+
};
|
|
4222
|
+
|
|
4223
|
+
/**
|
|
4224
|
+
* Object, that manages global escape key handling logic
|
|
4225
|
+
*/
|
|
4226
|
+
var globalEscKeyHandlingLogic = {
|
|
4227
|
+
/**
|
|
4228
|
+
* Mapping from ESC_KEY_HANDLING_PRIORITY to array of related listeners, grouped by priority
|
|
4229
|
+
* @example
|
|
4230
|
+
* Map<{
|
|
4231
|
+
* [ESC_KEY_HANDLING_PRIORITIES.SIDEBAR]: Map<{
|
|
4232
|
+
* 1: () => {...},
|
|
4233
|
+
* 2: () => {...}
|
|
4234
|
+
* }>,
|
|
4235
|
+
* [ESC_KEY_HANDLING_PRIORITIES.DIALOG]: Map<{
|
|
4236
|
+
* 1: () => {...},
|
|
4237
|
+
* 2: () => {...}
|
|
4238
|
+
* }>
|
|
4239
|
+
* }>;
|
|
4240
|
+
*/
|
|
4241
|
+
escKeyListeners: new Map(),
|
|
4242
|
+
/**
|
|
4243
|
+
* Keydown handler (attached to any keydown)
|
|
4244
|
+
*/
|
|
4245
|
+
onGlobalKeyDown: function onGlobalKeyDown(event) {
|
|
4246
|
+
// Do nothing if not an "esc" key is pressed:
|
|
4247
|
+
if (event.key !== 'Esc' && event.key !== 'Escape') return;
|
|
4248
|
+
var escKeyListeners = globalEscKeyHandlingLogic.escKeyListeners;
|
|
4249
|
+
var maxPrimaryPriority = Math.max.apply(Math, _toConsumableArray(escKeyListeners.keys()));
|
|
4250
|
+
var theMostImportantEscHandlersSet = escKeyListeners.get(maxPrimaryPriority);
|
|
4251
|
+
var maxSecondaryPriority = Math.max.apply(Math, _toConsumableArray(theMostImportantEscHandlersSet.keys()));
|
|
4252
|
+
var theMostImportantEscHandler = theMostImportantEscHandlersSet.get(maxSecondaryPriority);
|
|
4253
|
+
theMostImportantEscHandler(event);
|
|
4254
|
+
},
|
|
4255
|
+
/**
|
|
4256
|
+
* Attach global keydown listener if there are any "esc" key handlers assigned,
|
|
4257
|
+
* otherwise detach.
|
|
4258
|
+
*/
|
|
4259
|
+
refreshGlobalKeyDownListener: function refreshGlobalKeyDownListener() {
|
|
4260
|
+
var document = utils.DomHandler.getTargetElement('document');
|
|
4261
|
+
if (this.escKeyListeners.size > 0) {
|
|
4262
|
+
document.addEventListener('keydown', this.onGlobalKeyDown);
|
|
4263
|
+
} else {
|
|
4264
|
+
document.removeEventListener('keydown', this.onGlobalKeyDown);
|
|
4265
|
+
}
|
|
4266
|
+
},
|
|
4267
|
+
/**
|
|
4268
|
+
* Add "Esc" key handler
|
|
4269
|
+
*/
|
|
4270
|
+
addListener: function addListener(callback, _ref) {
|
|
4271
|
+
var _this = this;
|
|
4272
|
+
var _ref2 = _slicedToArray(_ref, 2),
|
|
4273
|
+
primaryPriority = _ref2[0],
|
|
4274
|
+
secondaryPriority = _ref2[1];
|
|
4275
|
+
var escKeyListeners = this.escKeyListeners;
|
|
4276
|
+
if (!escKeyListeners.has(primaryPriority)) {
|
|
4277
|
+
escKeyListeners.set(primaryPriority, new Map());
|
|
4278
|
+
}
|
|
4279
|
+
var primaryPriorityListeners = escKeyListeners.get(primaryPriority);
|
|
4280
|
+
|
|
4281
|
+
// To prevent unexpected override of callback:
|
|
4282
|
+
if (primaryPriorityListeners.has(secondaryPriority)) {
|
|
4283
|
+
throw new Error("Unexpected: global esc key listener with priority [".concat(primaryPriority, ", ").concat(secondaryPriority, "] already exists."));
|
|
4284
|
+
}
|
|
4285
|
+
primaryPriorityListeners.set(secondaryPriority, callback);
|
|
4286
|
+
this.refreshGlobalKeyDownListener();
|
|
4287
|
+
return function () {
|
|
4288
|
+
primaryPriorityListeners["delete"](secondaryPriority);
|
|
4289
|
+
if (primaryPriorityListeners.size === 0) {
|
|
4290
|
+
escKeyListeners["delete"](primaryPriority);
|
|
4291
|
+
}
|
|
4292
|
+
_this.refreshGlobalKeyDownListener();
|
|
4293
|
+
};
|
|
4294
|
+
}
|
|
4295
|
+
};
|
|
4296
|
+
var useGlobalOnEscapeKey = function useGlobalOnEscapeKey(_ref3) {
|
|
4297
|
+
var callback = _ref3.callback,
|
|
4298
|
+
when = _ref3.when,
|
|
4299
|
+
priority = _ref3.priority;
|
|
4300
|
+
React.useEffect(function () {
|
|
4301
|
+
if (!when) return;
|
|
4302
|
+
return globalEscKeyHandlingLogic.addListener(callback, priority);
|
|
4303
|
+
}, [when, callback, priority]);
|
|
4304
|
+
};
|
|
4305
|
+
|
|
4119
4306
|
var useIntersectionObserver = function useIntersectionObserver(ref) {
|
|
4120
4307
|
var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
4121
4308
|
var _React$useState = React__namespace.useState(false),
|
|
@@ -4774,19 +4961,6 @@ this.primereact.hooks = (function (exports, React, utils, PrimeReact) {
|
|
|
4774
4961
|
};
|
|
4775
4962
|
/* eslint-enable */
|
|
4776
4963
|
|
|
4777
|
-
/* eslint-disable */
|
|
4778
|
-
var useUpdateEffect = function useUpdateEffect(fn, deps) {
|
|
4779
|
-
var mounted = React__namespace.useRef(false);
|
|
4780
|
-
return React__namespace.useEffect(function () {
|
|
4781
|
-
if (!mounted.current) {
|
|
4782
|
-
mounted.current = true;
|
|
4783
|
-
return;
|
|
4784
|
-
}
|
|
4785
|
-
return fn && fn();
|
|
4786
|
-
}, deps);
|
|
4787
|
-
};
|
|
4788
|
-
/* eslint-enable */
|
|
4789
|
-
|
|
4790
4964
|
var _id = 0;
|
|
4791
4965
|
var useStyle = function useStyle(css) {
|
|
4792
4966
|
var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
@@ -4811,17 +4985,17 @@ this.primereact.hooks = (function (exports, React, utils, PrimeReact) {
|
|
|
4811
4985
|
isLoaded && css !== newCSS && (styleRef.current.textContent = newCSS);
|
|
4812
4986
|
};
|
|
4813
4987
|
var load = function load() {
|
|
4814
|
-
if (!document) return;
|
|
4815
|
-
|
|
4988
|
+
if (!document || isLoaded) return;
|
|
4989
|
+
var styleContainer = (context === null || context === void 0 ? void 0 : context.styleContainer) || document.head;
|
|
4990
|
+
styleRef.current = styleContainer.querySelector("style[data-primereact-style-id=\"".concat(name, "\"]")) || document.getElementById(id) || document.createElement('style');
|
|
4816
4991
|
if (!styleRef.current.isConnected) {
|
|
4817
4992
|
styleRef.current.type = 'text/css';
|
|
4818
4993
|
id && (styleRef.current.id = id);
|
|
4819
4994
|
media && (styleRef.current.media = media);
|
|
4820
4995
|
utils.DomHandler.addNonce(styleRef.current, context && context.nonce || PrimeReact__default["default"].nonce);
|
|
4821
|
-
|
|
4996
|
+
styleContainer.appendChild(styleRef.current);
|
|
4822
4997
|
name && styleRef.current.setAttribute('data-primereact-style-id', name);
|
|
4823
4998
|
}
|
|
4824
|
-
if (isLoaded) return;
|
|
4825
4999
|
styleRef.current.textContent = css;
|
|
4826
5000
|
setIsLoaded(true);
|
|
4827
5001
|
};
|
|
@@ -4835,7 +5009,7 @@ this.primereact.hooks = (function (exports, React, utils, PrimeReact) {
|
|
|
4835
5009
|
|
|
4836
5010
|
// return () => {if (!manual) unload()}; /* @todo */
|
|
4837
5011
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
4838
|
-
}, []);
|
|
5012
|
+
}, [manual]);
|
|
4839
5013
|
return {
|
|
4840
5014
|
id: id,
|
|
4841
5015
|
name: name,
|
|
@@ -4846,41 +5020,57 @@ this.primereact.hooks = (function (exports, React, utils, PrimeReact) {
|
|
|
4846
5020
|
};
|
|
4847
5021
|
};
|
|
4848
5022
|
|
|
4849
|
-
|
|
4850
|
-
|
|
4851
|
-
|
|
4852
|
-
|
|
4853
|
-
|
|
4854
|
-
|
|
4855
|
-
|
|
4856
|
-
|
|
4857
|
-
|
|
4858
|
-
type: 'keydown',
|
|
4859
|
-
listener: handleEsc
|
|
4860
|
-
}),
|
|
4861
|
-
_useEventListener2 = _slicedToArray(_useEventListener, 2),
|
|
4862
|
-
bindKeyDownListener = _useEventListener2[0],
|
|
4863
|
-
unbindKeyDownListener = _useEventListener2[1];
|
|
5023
|
+
/* eslint-disable */
|
|
5024
|
+
var useTimeout = function useTimeout(fn) {
|
|
5025
|
+
var delay = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
|
|
5026
|
+
var when = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
|
|
5027
|
+
var timeout = React__namespace.useRef(null);
|
|
5028
|
+
var savedCallback = React__namespace.useRef(null);
|
|
5029
|
+
var clear = React__namespace.useCallback(function () {
|
|
5030
|
+
return clearTimeout(timeout.current);
|
|
5031
|
+
}, [timeout.current]);
|
|
4864
5032
|
React__namespace.useEffect(function () {
|
|
4865
|
-
|
|
4866
|
-
|
|
5033
|
+
savedCallback.current = fn;
|
|
5034
|
+
});
|
|
5035
|
+
React__namespace.useEffect(function () {
|
|
5036
|
+
function callback() {
|
|
5037
|
+
savedCallback.current();
|
|
4867
5038
|
}
|
|
4868
|
-
if (
|
|
4869
|
-
|
|
5039
|
+
if (when) {
|
|
5040
|
+
timeout.current = setTimeout(callback, delay);
|
|
5041
|
+
return clear;
|
|
5042
|
+
} else {
|
|
5043
|
+
clear();
|
|
4870
5044
|
}
|
|
4871
|
-
|
|
4872
|
-
|
|
4873
|
-
|
|
4874
|
-
};
|
|
5045
|
+
}, [delay, when]);
|
|
5046
|
+
useUnmountEffect(function () {
|
|
5047
|
+
clear();
|
|
4875
5048
|
});
|
|
4876
|
-
return [
|
|
5049
|
+
return [clear];
|
|
5050
|
+
};
|
|
5051
|
+
/* eslint-enable */
|
|
5052
|
+
|
|
5053
|
+
/* eslint-disable */
|
|
5054
|
+
var useUpdateEffect = function useUpdateEffect(fn, deps) {
|
|
5055
|
+
var mounted = React__namespace.useRef(false);
|
|
5056
|
+
return React__namespace.useEffect(function () {
|
|
5057
|
+
if (!mounted.current) {
|
|
5058
|
+
mounted.current = true;
|
|
5059
|
+
return;
|
|
5060
|
+
}
|
|
5061
|
+
return fn && fn();
|
|
5062
|
+
}, deps);
|
|
4877
5063
|
};
|
|
5064
|
+
/* eslint-enable */
|
|
4878
5065
|
|
|
5066
|
+
exports.ESC_KEY_HANDLING_PRIORITIES = ESC_KEY_HANDLING_PRIORITIES;
|
|
4879
5067
|
exports.useClickOutside = useClickOutside;
|
|
4880
5068
|
exports.useCounter = useCounter;
|
|
4881
5069
|
exports.useDebounce = useDebounce;
|
|
5070
|
+
exports.useDisplayOrder = useDisplayOrder;
|
|
4882
5071
|
exports.useEventListener = useEventListener;
|
|
4883
5072
|
exports.useFavicon = useFavicon;
|
|
5073
|
+
exports.useGlobalOnEscapeKey = useGlobalOnEscapeKey;
|
|
4884
5074
|
exports.useIntersectionObserver = useIntersectionObserver;
|
|
4885
5075
|
exports.useInterval = useInterval;
|
|
4886
5076
|
exports.useLocalStorage = useLocalStorage;
|
|
@@ -4888,7 +5078,6 @@ this.primereact.hooks = (function (exports, React, utils, PrimeReact) {
|
|
|
4888
5078
|
exports.useMountEffect = useMountEffect;
|
|
4889
5079
|
exports.useMouse = useMouse;
|
|
4890
5080
|
exports.useMove = useMove;
|
|
4891
|
-
exports.useOnEscapeKey = useOnEscapeKey;
|
|
4892
5081
|
exports.useOverlayListener = useOverlayListener;
|
|
4893
5082
|
exports.useOverlayScrollListener = useOverlayScrollListener;
|
|
4894
5083
|
exports.usePrevious = usePrevious;
|
|
@@ -5076,11 +5265,13 @@ this.primereact.ripple = (function (exports, React, PrimeReact, hooks, utils, co
|
|
|
5076
5265
|
var targetRef = React__namespace.useRef(null);
|
|
5077
5266
|
var context = React__namespace.useContext(PrimeReact.PrimeReactContext);
|
|
5078
5267
|
var props = RippleBase.getProps(inProps, context);
|
|
5268
|
+
var isRippleActive = context && context.ripple || PrimeReact__default["default"].ripple;
|
|
5079
5269
|
var metaData = {
|
|
5080
5270
|
props: props
|
|
5081
5271
|
};
|
|
5082
5272
|
hooks.useStyle(RippleBase.css.styles, {
|
|
5083
|
-
name: 'ripple'
|
|
5273
|
+
name: 'ripple',
|
|
5274
|
+
manual: !isRippleActive
|
|
5084
5275
|
});
|
|
5085
5276
|
var _RippleBase$setMetaDa = RippleBase.setMetaData(_objectSpread({}, metaData)),
|
|
5086
5277
|
ptm = _RippleBase$setMetaDa.ptm,
|
|
@@ -5159,16 +5350,17 @@ this.primereact.ripple = (function (exports, React, PrimeReact, hooks, utils, co
|
|
|
5159
5350
|
unbindEvents();
|
|
5160
5351
|
}
|
|
5161
5352
|
});
|
|
5353
|
+
if (!isRippleActive) return null;
|
|
5162
5354
|
var rootProps = utils.mergeProps({
|
|
5163
5355
|
'aria-hidden': true,
|
|
5164
5356
|
className: utils.classNames(cx('root'))
|
|
5165
5357
|
}, RippleBase.getOtherProps(props), ptm('root'));
|
|
5166
|
-
return
|
|
5358
|
+
return /*#__PURE__*/React__namespace.createElement("span", _extends({
|
|
5167
5359
|
role: "presentation",
|
|
5168
5360
|
ref: inkRef
|
|
5169
5361
|
}, rootProps, {
|
|
5170
5362
|
onAnimationEnd: onAnimationEnd
|
|
5171
|
-
}))
|
|
5363
|
+
}));
|
|
5172
5364
|
}));
|
|
5173
5365
|
Ripple.displayName = 'Ripple';
|
|
5174
5366
|
|
|
@@ -5466,7 +5658,13 @@ this.primereact.portal = (function (exports, React, ReactDOM, PrimeReact, hooks,
|
|
|
5466
5658
|
});
|
|
5467
5659
|
var element = props.element || props.children;
|
|
5468
5660
|
if (element && mountedState) {
|
|
5469
|
-
var appendTo = props.appendTo || context && context.appendTo || PrimeReact__default["default"].appendTo
|
|
5661
|
+
var appendTo = props.appendTo || context && context.appendTo || PrimeReact__default["default"].appendTo;
|
|
5662
|
+
if (utils.ObjectUtils.isFunction(appendTo)) {
|
|
5663
|
+
appendTo = appendTo();
|
|
5664
|
+
}
|
|
5665
|
+
if (!appendTo) {
|
|
5666
|
+
appendTo = document.body;
|
|
5667
|
+
}
|
|
5470
5668
|
return appendTo === 'self' ? element : /*#__PURE__*/ReactDOM__default["default"].createPortal(element, appendTo);
|
|
5471
5669
|
}
|
|
5472
5670
|
return null;
|
|
@@ -6664,7 +6862,7 @@ this.primereact.icons.arrowdown = (function (exports, React, iconbase) {
|
|
|
6664
6862
|
}, {
|
|
6665
6863
|
key: "isLetter",
|
|
6666
6864
|
value: function isLetter(_char2) {
|
|
6667
|
-
return
|
|
6865
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
6668
6866
|
}
|
|
6669
6867
|
|
|
6670
6868
|
/**
|
|
@@ -7370,7 +7568,7 @@ this.primereact.icons.arrowup = (function (exports, React, iconbase) {
|
|
|
7370
7568
|
}, {
|
|
7371
7569
|
key: "isLetter",
|
|
7372
7570
|
value: function isLetter(_char2) {
|
|
7373
|
-
return
|
|
7571
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
7374
7572
|
}
|
|
7375
7573
|
|
|
7376
7574
|
/**
|
|
@@ -8076,7 +8274,7 @@ this.primereact.icons.ban = (function (exports, React, iconbase) {
|
|
|
8076
8274
|
}, {
|
|
8077
8275
|
key: "isLetter",
|
|
8078
8276
|
value: function isLetter(_char2) {
|
|
8079
|
-
return
|
|
8277
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
8080
8278
|
}
|
|
8081
8279
|
|
|
8082
8280
|
/**
|
|
@@ -9230,7 +9428,7 @@ this.primereact.icons.exclamationtriangle = (function (exports, React, iconbase)
|
|
|
9230
9428
|
}, {
|
|
9231
9429
|
key: "isLetter",
|
|
9232
9430
|
value: function isLetter(_char2) {
|
|
9233
|
-
return
|
|
9431
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
9234
9432
|
}
|
|
9235
9433
|
|
|
9236
9434
|
/**
|
|
@@ -10006,7 +10204,7 @@ this.primereact.icons.eyeslash = (function (exports, React, iconbase) {
|
|
|
10006
10204
|
}, {
|
|
10007
10205
|
key: "isLetter",
|
|
10008
10206
|
value: function isLetter(_char2) {
|
|
10009
|
-
return
|
|
10207
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
10010
10208
|
}
|
|
10011
10209
|
|
|
10012
10210
|
/**
|
|
@@ -10712,7 +10910,7 @@ this.primereact.icons.filter = (function (exports, React, iconbase) {
|
|
|
10712
10910
|
}, {
|
|
10713
10911
|
key: "isLetter",
|
|
10714
10912
|
value: function isLetter(_char2) {
|
|
10715
|
-
return
|
|
10913
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
10716
10914
|
}
|
|
10717
10915
|
|
|
10718
10916
|
/**
|
|
@@ -11416,7 +11614,7 @@ this.primereact.icons.filterslash = (function (exports, React, iconbase) {
|
|
|
11416
11614
|
}, {
|
|
11417
11615
|
key: "isLetter",
|
|
11418
11616
|
value: function isLetter(_char2) {
|
|
11419
|
-
return
|
|
11617
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
11420
11618
|
}
|
|
11421
11619
|
|
|
11422
11620
|
/**
|
|
@@ -12122,7 +12320,7 @@ this.primereact.icons.infocircle = (function (exports, React, iconbase) {
|
|
|
12122
12320
|
}, {
|
|
12123
12321
|
key: "isLetter",
|
|
12124
12322
|
value: function isLetter(_char2) {
|
|
12125
|
-
return
|
|
12323
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
12126
12324
|
}
|
|
12127
12325
|
|
|
12128
12326
|
/**
|
|
@@ -12892,7 +13090,7 @@ this.primereact.icons.pencil = (function (exports, React, iconbase) {
|
|
|
12892
13090
|
}, {
|
|
12893
13091
|
key: "isLetter",
|
|
12894
13092
|
value: function isLetter(_char2) {
|
|
12895
|
-
return
|
|
13093
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
12896
13094
|
}
|
|
12897
13095
|
|
|
12898
13096
|
/**
|
|
@@ -13596,7 +13794,7 @@ this.primereact.icons.plus = (function (exports, React, iconbase) {
|
|
|
13596
13794
|
}, {
|
|
13597
13795
|
key: "isLetter",
|
|
13598
13796
|
value: function isLetter(_char2) {
|
|
13599
|
-
return
|
|
13797
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
13600
13798
|
}
|
|
13601
13799
|
|
|
13602
13800
|
/**
|
|
@@ -14300,7 +14498,7 @@ this.primereact.icons.refresh = (function (exports, React, iconbase) {
|
|
|
14300
14498
|
}, {
|
|
14301
14499
|
key: "isLetter",
|
|
14302
14500
|
value: function isLetter(_char2) {
|
|
14303
|
-
return
|
|
14501
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
14304
14502
|
}
|
|
14305
14503
|
|
|
14306
14504
|
/**
|
|
@@ -15006,7 +15204,7 @@ this.primereact.icons.search = (function (exports, React, iconbase) {
|
|
|
15006
15204
|
}, {
|
|
15007
15205
|
key: "isLetter",
|
|
15008
15206
|
value: function isLetter(_char2) {
|
|
15009
|
-
return
|
|
15207
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
15010
15208
|
}
|
|
15011
15209
|
|
|
15012
15210
|
/**
|
|
@@ -15712,7 +15910,7 @@ this.primereact.icons.searchminus = (function (exports, React, iconbase) {
|
|
|
15712
15910
|
}, {
|
|
15713
15911
|
key: "isLetter",
|
|
15714
15912
|
value: function isLetter(_char2) {
|
|
15715
|
-
return
|
|
15913
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
15716
15914
|
}
|
|
15717
15915
|
|
|
15718
15916
|
/**
|
|
@@ -16418,7 +16616,7 @@ this.primereact.icons.searchplus = (function (exports, React, iconbase) {
|
|
|
16418
16616
|
}, {
|
|
16419
16617
|
key: "isLetter",
|
|
16420
16618
|
value: function isLetter(_char2) {
|
|
16421
|
-
return
|
|
16619
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
16422
16620
|
}
|
|
16423
16621
|
|
|
16424
16622
|
/**
|
|
@@ -17124,7 +17322,7 @@ this.primereact.icons.sortalt = (function (exports, React, iconbase) {
|
|
|
17124
17322
|
}, {
|
|
17125
17323
|
key: "isLetter",
|
|
17126
17324
|
value: function isLetter(_char2) {
|
|
17127
|
-
return
|
|
17325
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
17128
17326
|
}
|
|
17129
17327
|
|
|
17130
17328
|
/**
|
|
@@ -17837,7 +18035,7 @@ this.primereact.icons.sortamountdown = (function (exports, React, iconbase) {
|
|
|
17837
18035
|
}, {
|
|
17838
18036
|
key: "isLetter",
|
|
17839
18037
|
value: function isLetter(_char2) {
|
|
17840
|
-
return
|
|
18038
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
17841
18039
|
}
|
|
17842
18040
|
|
|
17843
18041
|
/**
|
|
@@ -18556,7 +18754,7 @@ this.primereact.icons.sortamountupalt = (function (exports, React, iconbase) {
|
|
|
18556
18754
|
}, {
|
|
18557
18755
|
key: "isLetter",
|
|
18558
18756
|
value: function isLetter(_char2) {
|
|
18559
|
-
return
|
|
18757
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
18560
18758
|
}
|
|
18561
18759
|
|
|
18562
18760
|
/**
|
|
@@ -19275,7 +19473,7 @@ this.primereact.icons.spinner = (function (exports, React, iconbase) {
|
|
|
19275
19473
|
}, {
|
|
19276
19474
|
key: "isLetter",
|
|
19277
19475
|
value: function isLetter(_char2) {
|
|
19278
|
-
return
|
|
19476
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
19279
19477
|
}
|
|
19280
19478
|
|
|
19281
19479
|
/**
|
|
@@ -19979,7 +20177,7 @@ this.primereact.icons.star = (function (exports, React, iconbase) {
|
|
|
19979
20177
|
}, {
|
|
19980
20178
|
key: "isLetter",
|
|
19981
20179
|
value: function isLetter(_char2) {
|
|
19982
|
-
return
|
|
20180
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
19983
20181
|
}
|
|
19984
20182
|
|
|
19985
20183
|
/**
|
|
@@ -20683,7 +20881,7 @@ this.primereact.icons.starfill = (function (exports, React, iconbase) {
|
|
|
20683
20881
|
}, {
|
|
20684
20882
|
key: "isLetter",
|
|
20685
20883
|
value: function isLetter(_char2) {
|
|
20686
|
-
return
|
|
20884
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
20687
20885
|
}
|
|
20688
20886
|
|
|
20689
20887
|
/**
|
|
@@ -21387,7 +21585,7 @@ this.primereact.icons.thlarge = (function (exports, React, iconbase) {
|
|
|
21387
21585
|
}, {
|
|
21388
21586
|
key: "isLetter",
|
|
21389
21587
|
value: function isLetter(_char2) {
|
|
21390
|
-
return
|
|
21588
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
21391
21589
|
}
|
|
21392
21590
|
|
|
21393
21591
|
/**
|
|
@@ -22157,7 +22355,7 @@ this.primereact.icons.timescircle = (function (exports, React, iconbase) {
|
|
|
22157
22355
|
}, {
|
|
22158
22356
|
key: "isLetter",
|
|
22159
22357
|
value: function isLetter(_char2) {
|
|
22160
|
-
return
|
|
22358
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
22161
22359
|
}
|
|
22162
22360
|
|
|
22163
22361
|
/**
|
|
@@ -22863,7 +23061,7 @@ this.primereact.icons.trash = (function (exports, React, iconbase) {
|
|
|
22863
23061
|
}, {
|
|
22864
23062
|
key: "isLetter",
|
|
22865
23063
|
value: function isLetter(_char2) {
|
|
22866
|
-
return
|
|
23064
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
22867
23065
|
}
|
|
22868
23066
|
|
|
22869
23067
|
/**
|
|
@@ -23569,7 +23767,7 @@ this.primereact.icons.undo = (function (exports, React, iconbase) {
|
|
|
23569
23767
|
}, {
|
|
23570
23768
|
key: "isLetter",
|
|
23571
23769
|
value: function isLetter(_char2) {
|
|
23572
|
-
return
|
|
23770
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
23573
23771
|
}
|
|
23574
23772
|
|
|
23575
23773
|
/**
|
|
@@ -24275,7 +24473,7 @@ this.primereact.icons.upload = (function (exports, React, iconbase) {
|
|
|
24275
24473
|
}, {
|
|
24276
24474
|
key: "isLetter",
|
|
24277
24475
|
value: function isLetter(_char2) {
|
|
24278
|
-
return
|
|
24476
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
24279
24477
|
}
|
|
24280
24478
|
|
|
24281
24479
|
/**
|
|
@@ -24981,7 +25179,7 @@ this.primereact.icons.windowmaximize = (function (exports, React, iconbase) {
|
|
|
24981
25179
|
}, {
|
|
24982
25180
|
key: "isLetter",
|
|
24983
25181
|
value: function isLetter(_char2) {
|
|
24984
|
-
return
|
|
25182
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
24985
25183
|
}
|
|
24986
25184
|
|
|
24987
25185
|
/**
|
|
@@ -25687,7 +25885,7 @@ this.primereact.icons.windowminimize = (function (exports, React, iconbase) {
|
|
|
25687
25885
|
}, {
|
|
25688
25886
|
key: "isLetter",
|
|
25689
25887
|
value: function isLetter(_char2) {
|
|
25690
|
-
return
|
|
25888
|
+
return /^[a-zA-Z\u00C0-\u017F]$/.test(_char2);
|
|
25691
25889
|
}
|
|
25692
25890
|
|
|
25693
25891
|
/**
|
|
@@ -27634,7 +27832,7 @@ this.primereact.overlayservice = (function (exports, utils) {
|
|
|
27634
27832
|
})({}, primereact.utils);
|
|
27635
27833
|
|
|
27636
27834
|
this.primereact = this.primereact || {};
|
|
27637
|
-
this.primereact.checkbox = (function (exports, React, api, hooks, check, tooltip, utils
|
|
27835
|
+
this.primereact.checkbox = (function (exports, React, api, componentbase, hooks, check, tooltip, utils) {
|
|
27638
27836
|
'use strict';
|
|
27639
27837
|
|
|
27640
27838
|
function _interopNamespace(e) {
|
|
@@ -27862,32 +28060,32 @@ this.primereact.checkbox = (function (exports, React, api, hooks, check, tooltip
|
|
|
27862
28060
|
var checkboxClicked = event.target instanceof HTMLDivElement || event.target instanceof HTMLSpanElement || event.target instanceof Object;
|
|
27863
28061
|
var isInputToggled = event.target === inputRef.current;
|
|
27864
28062
|
var isCheckboxToggled = checkboxClicked && event.target.checked !== _checked;
|
|
27865
|
-
|
|
27866
|
-
|
|
27867
|
-
|
|
27868
|
-
|
|
28063
|
+
var value = _checked ? props.falseValue : props.trueValue;
|
|
28064
|
+
var eventData = {
|
|
28065
|
+
originalEvent: event,
|
|
28066
|
+
value: props.value,
|
|
28067
|
+
checked: value,
|
|
28068
|
+
stopPropagation: function stopPropagation() {
|
|
28069
|
+
event.stopPropagation();
|
|
28070
|
+
},
|
|
28071
|
+
preventDefault: function preventDefault() {
|
|
28072
|
+
event.preventDefault();
|
|
28073
|
+
},
|
|
28074
|
+
target: {
|
|
28075
|
+
type: 'checkbox',
|
|
28076
|
+
name: props.name,
|
|
28077
|
+
id: props.id,
|
|
27869
28078
|
value: props.value,
|
|
27870
|
-
checked: value
|
|
27871
|
-
stopPropagation: function stopPropagation() {
|
|
27872
|
-
event.stopPropagation();
|
|
27873
|
-
},
|
|
27874
|
-
preventDefault: function preventDefault() {
|
|
27875
|
-
event.preventDefault();
|
|
27876
|
-
},
|
|
27877
|
-
target: {
|
|
27878
|
-
type: 'checkbox',
|
|
27879
|
-
name: props.name,
|
|
27880
|
-
id: props.id,
|
|
27881
|
-
value: props.value,
|
|
27882
|
-
checked: value
|
|
27883
|
-
}
|
|
27884
|
-
};
|
|
27885
|
-
props.onClick && props.onClick(eventData);
|
|
27886
|
-
|
|
27887
|
-
// do not continue if the user defined click wants to prevent
|
|
27888
|
-
if (event.defaultPrevented) {
|
|
27889
|
-
return;
|
|
28079
|
+
checked: value
|
|
27890
28080
|
}
|
|
28081
|
+
};
|
|
28082
|
+
props.onClick && props.onClick(eventData);
|
|
28083
|
+
|
|
28084
|
+
// do not continue if the user defined click wants to prevent
|
|
28085
|
+
if (event.defaultPrevented) {
|
|
28086
|
+
return;
|
|
28087
|
+
}
|
|
28088
|
+
if (isInputToggled || isCheckboxToggled) {
|
|
27891
28089
|
props.onChange && props.onChange(eventData);
|
|
27892
28090
|
}
|
|
27893
28091
|
utils.DomHandler.focus(inputRef.current);
|
|
@@ -28009,7 +28207,7 @@ this.primereact.checkbox = (function (exports, React, api, hooks, check, tooltip
|
|
|
28009
28207
|
|
|
28010
28208
|
return exports;
|
|
28011
28209
|
|
|
28012
|
-
})({}, React, primereact.api, primereact.hooks, primereact.icons.check, primereact.tooltip, primereact.utils
|
|
28210
|
+
})({}, React, primereact.api, primereact.componentbase, primereact.hooks, primereact.icons.check, primereact.tooltip, primereact.utils);
|
|
28013
28211
|
|
|
28014
28212
|
this.primereact = this.primereact || {};
|
|
28015
28213
|
this.primereact.button = (function (exports, React, api, componentbase, utils, spinner, ripple, tooltip) {
|
|
@@ -28420,15 +28618,16 @@ this.primereact.inputtext = (function (exports, React, api, componentbase, keyfi
|
|
|
28420
28618
|
defaultProps: {
|
|
28421
28619
|
__TYPE: 'InputText',
|
|
28422
28620
|
__parentMetadata: null,
|
|
28621
|
+
children: undefined,
|
|
28622
|
+
className: null,
|
|
28423
28623
|
keyfilter: null,
|
|
28424
|
-
validateOnly: false,
|
|
28425
|
-
tooltip: null,
|
|
28426
|
-
tooltipOptions: null,
|
|
28427
28624
|
onBeforeInput: null,
|
|
28428
28625
|
onInput: null,
|
|
28429
28626
|
onKeyDown: null,
|
|
28430
28627
|
onPaste: null,
|
|
28431
|
-
|
|
28628
|
+
tooltip: null,
|
|
28629
|
+
tooltipOptions: null,
|
|
28630
|
+
validateOnly: false
|
|
28432
28631
|
},
|
|
28433
28632
|
css: {
|
|
28434
28633
|
classes: classes
|
|
@@ -28492,9 +28691,9 @@ this.primereact.inputtext = (function (exports, React, api, componentbase, keyfi
|
|
|
28492
28691
|
}, [props.value, props.defaultValue]);
|
|
28493
28692
|
var hasTooltip = utils.ObjectUtils.isNotEmpty(props.tooltip);
|
|
28494
28693
|
var rootProps = utils.mergeProps({
|
|
28495
|
-
className: cx('root', {
|
|
28694
|
+
className: utils.classNames(props.className, cx('root', {
|
|
28496
28695
|
isFilled: isFilled
|
|
28497
|
-
}),
|
|
28696
|
+
})),
|
|
28498
28697
|
onBeforeInput: onBeforeInput,
|
|
28499
28698
|
onInput: onInput,
|
|
28500
28699
|
onKeyDown: onKeyDown,
|
|
@@ -28748,6 +28947,7 @@ this.primereact.inputnumber = (function (exports, React, PrimeReact, componentba
|
|
|
28748
28947
|
prefix: null,
|
|
28749
28948
|
readOnly: false,
|
|
28750
28949
|
required: false,
|
|
28950
|
+
roundingMode: undefined,
|
|
28751
28951
|
showButtons: false,
|
|
28752
28952
|
size: null,
|
|
28753
28953
|
step: 1,
|
|
@@ -28804,9 +29004,11 @@ this.primereact.inputnumber = (function (exports, React, PrimeReact, componentba
|
|
|
28804
29004
|
var _minusSign = React__namespace.useRef(null);
|
|
28805
29005
|
var _currency = React__namespace.useRef(null);
|
|
28806
29006
|
var _decimal = React__namespace.useRef(null);
|
|
29007
|
+
var _decimalSeparator = React__namespace.useRef(null);
|
|
28807
29008
|
var _suffix = React__namespace.useRef(null);
|
|
28808
29009
|
var _prefix = React__namespace.useRef(null);
|
|
28809
29010
|
var _index = React__namespace.useRef(null);
|
|
29011
|
+
var isFocusedByClick = React__namespace.useRef(false);
|
|
28810
29012
|
var _locale = props.locale || context && context.locale || PrimeReact__default["default"].locale;
|
|
28811
29013
|
var stacked = props.showButtons && props.buttonLayout === 'stacked';
|
|
28812
29014
|
var horizontal = props.showButtons && props.buttonLayout === 'horizontal';
|
|
@@ -28820,7 +29022,8 @@ this.primereact.inputnumber = (function (exports, React, PrimeReact, componentba
|
|
|
28820
29022
|
currencyDisplay: props.currencyDisplay,
|
|
28821
29023
|
useGrouping: props.useGrouping,
|
|
28822
29024
|
minimumFractionDigits: props.minFractionDigits,
|
|
28823
|
-
maximumFractionDigits: props.maxFractionDigits
|
|
29025
|
+
maximumFractionDigits: props.maxFractionDigits,
|
|
29026
|
+
roundingMode: props.roundingMode
|
|
28824
29027
|
};
|
|
28825
29028
|
};
|
|
28826
29029
|
var constructParser = function constructParser() {
|
|
@@ -28832,12 +29035,13 @@ this.primereact.inputnumber = (function (exports, React, PrimeReact, componentba
|
|
|
28832
29035
|
return [d, i];
|
|
28833
29036
|
}));
|
|
28834
29037
|
_numeral.current = new RegExp("[".concat(numerals.join(''), "]"), 'g');
|
|
28835
|
-
_group.current = getGroupingExpression();
|
|
28836
|
-
_minusSign.current = getMinusSignExpression();
|
|
28837
|
-
_currency.current = getCurrencyExpression();
|
|
28838
|
-
_decimal.current = getDecimalExpression();
|
|
28839
|
-
|
|
28840
|
-
|
|
29038
|
+
_group.current = getGroupingExpression(); // regular expression /[,]/g, /[.]/g
|
|
29039
|
+
_minusSign.current = getMinusSignExpression(); // regular expression /[-]/g
|
|
29040
|
+
_currency.current = getCurrencyExpression(); // regular expression for currency (e.g. /[$]/g, /[€]/g, /[]/g and more)
|
|
29041
|
+
_decimal.current = getDecimalExpression(); // regular expression /[,]/g, /[.]/g, /[]/g
|
|
29042
|
+
_decimalSeparator.current = getDecimalSeparator(); // current decimal separator '.', ','
|
|
29043
|
+
_suffix.current = getSuffixExpression(); // regular expression for suffix (e.g. /℃/g)
|
|
29044
|
+
_prefix.current = getPrefixExpression(); // regular expression for prefix (e.g. /\ days/g)
|
|
28841
29045
|
_index.current = function (d) {
|
|
28842
29046
|
return index.get(d);
|
|
28843
29047
|
};
|
|
@@ -28845,6 +29049,15 @@ this.primereact.inputnumber = (function (exports, React, PrimeReact, componentba
|
|
|
28845
29049
|
var escapeRegExp = function escapeRegExp(text) {
|
|
28846
29050
|
return text.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, '\\$&');
|
|
28847
29051
|
};
|
|
29052
|
+
|
|
29053
|
+
/**
|
|
29054
|
+
* get decimal separator in current locale
|
|
29055
|
+
*/
|
|
29056
|
+
var getDecimalSeparator = function getDecimalSeparator() {
|
|
29057
|
+
return new Intl.NumberFormat(_locale, {
|
|
29058
|
+
useGrouping: false
|
|
29059
|
+
}).format(1.1).trim().replace(_numeral.current, '');
|
|
29060
|
+
};
|
|
28848
29061
|
var getDecimalExpression = function getDecimalExpression() {
|
|
28849
29062
|
var formatter = new Intl.NumberFormat(_locale, _objectSpread(_objectSpread({}, getOptions()), {}, {
|
|
28850
29063
|
useGrouping: false
|
|
@@ -28871,7 +29084,8 @@ this.primereact.inputnumber = (function (exports, React, PrimeReact, componentba
|
|
|
28871
29084
|
currency: props.currency,
|
|
28872
29085
|
currencyDisplay: props.currencyDisplay,
|
|
28873
29086
|
minimumFractionDigits: 0,
|
|
28874
|
-
maximumFractionDigits: 0
|
|
29087
|
+
maximumFractionDigits: 0,
|
|
29088
|
+
roundingMode: props.roundingMode
|
|
28875
29089
|
});
|
|
28876
29090
|
return new RegExp("[".concat(formatter.format(1).replace(/\s/g, '').replace(_numeral.current, '').replace(_group.current, ''), "]"), 'g');
|
|
28877
29091
|
}
|
|
@@ -28899,7 +29113,8 @@ this.primereact.inputnumber = (function (exports, React, PrimeReact, componentba
|
|
|
28899
29113
|
currency: props.currency,
|
|
28900
29114
|
currencyDisplay: props.currencyDisplay,
|
|
28901
29115
|
minimumFractionDigits: 0,
|
|
28902
|
-
maximumFractionDigits: 0
|
|
29116
|
+
maximumFractionDigits: 0,
|
|
29117
|
+
roundingMode: props.roundingMode
|
|
28903
29118
|
});
|
|
28904
29119
|
suffixChar.current = formatter.format(1).split('1')[1];
|
|
28905
29120
|
}
|
|
@@ -29216,8 +29431,14 @@ this.primereact.inputnumber = (function (exports, React, PrimeReact, componentba
|
|
|
29216
29431
|
}
|
|
29217
29432
|
return false;
|
|
29218
29433
|
};
|
|
29434
|
+
var replaceDecimalSeparator = function replaceDecimalSeparator(val) {
|
|
29435
|
+
if (isFloat(val)) {
|
|
29436
|
+
return val.toString().replace(/\.(?=[^.]*$)/, _decimalSeparator.current);
|
|
29437
|
+
}
|
|
29438
|
+
return val;
|
|
29439
|
+
};
|
|
29219
29440
|
var isDecimalSign = function isDecimalSign(_char3) {
|
|
29220
|
-
if (_decimal.current.test(_char3)) {
|
|
29441
|
+
if (_decimal.current.test(_char3) || isFloat(_char3)) {
|
|
29221
29442
|
_decimal.current.lastIndex = 0;
|
|
29222
29443
|
return true;
|
|
29223
29444
|
}
|
|
@@ -29226,6 +29447,12 @@ this.primereact.inputnumber = (function (exports, React, PrimeReact, componentba
|
|
|
29226
29447
|
var isDecimalMode = function isDecimalMode() {
|
|
29227
29448
|
return props.mode === 'decimal';
|
|
29228
29449
|
};
|
|
29450
|
+
var isFloat = function isFloat(val) {
|
|
29451
|
+
var formatter = new Intl.NumberFormat(_locale, getOptions());
|
|
29452
|
+
var parseVal = parseValue(formatter.format(val));
|
|
29453
|
+
if (parseVal === null) return false;
|
|
29454
|
+
return parseVal % 1 !== 0;
|
|
29455
|
+
};
|
|
29229
29456
|
var getDecimalCharIndexes = function getDecimalCharIndexes(val) {
|
|
29230
29457
|
var decimalCharIndex = val.search(_decimal.current);
|
|
29231
29458
|
_decimal.current.lastIndex = 0;
|
|
@@ -29309,12 +29536,15 @@ this.primereact.inputnumber = (function (exports, React, PrimeReact, componentba
|
|
|
29309
29536
|
}
|
|
29310
29537
|
}
|
|
29311
29538
|
};
|
|
29539
|
+
var replaceSuffix = function replaceSuffix(value) {
|
|
29540
|
+
return value ? value.replace(_suffix.current, '').trim().replace(/\s/g, '').replace(_currency.current, '') : value;
|
|
29541
|
+
};
|
|
29312
29542
|
var insertText = function insertText(value, text, start, end) {
|
|
29313
29543
|
var textSplit = text === '.' ? text : text.split('.');
|
|
29314
29544
|
if (textSplit.length === 2) {
|
|
29315
29545
|
var decimalCharIndex = value.slice(start, end).search(_decimal.current);
|
|
29316
29546
|
_decimal.current.lastIndex = 0;
|
|
29317
|
-
return decimalCharIndex > 0 ? value.slice(0, start) + formatValue(text) + value.slice(end) : value || formatValue(text);
|
|
29547
|
+
return decimalCharIndex > 0 ? value.slice(0, start) + formatValue(text) + replaceSuffix(value).slice(end) : value || formatValue(text);
|
|
29318
29548
|
} else if (end - start === value.length) {
|
|
29319
29549
|
return formatValue(text);
|
|
29320
29550
|
} else if (start === 0) {
|
|
@@ -29323,7 +29553,10 @@ this.primereact.inputnumber = (function (exports, React, PrimeReact, componentba
|
|
|
29323
29553
|
} else if (end === value.length) {
|
|
29324
29554
|
return value.slice(0, start) + text;
|
|
29325
29555
|
} else {
|
|
29326
|
-
|
|
29556
|
+
var selectionValue = value.slice(start, end);
|
|
29557
|
+
// Fix: if the suffix starts with a space, the input will be cleared after pasting
|
|
29558
|
+
var space = /\s$/.test(selectionValue) ? ' ' : '';
|
|
29559
|
+
return value.slice(0, start) + text + space + value.slice(end);
|
|
29327
29560
|
}
|
|
29328
29561
|
};
|
|
29329
29562
|
var deleteRange = function deleteRange(value, start, end) {
|
|
@@ -29376,6 +29609,9 @@ this.primereact.inputnumber = (function (exports, React, PrimeReact, componentba
|
|
|
29376
29609
|
}
|
|
29377
29610
|
return index || 0;
|
|
29378
29611
|
};
|
|
29612
|
+
var onInputPointerDown = function onInputPointerDown() {
|
|
29613
|
+
isFocusedByClick.current = true;
|
|
29614
|
+
};
|
|
29379
29615
|
var onInputClick = function onInputClick() {
|
|
29380
29616
|
initCursor();
|
|
29381
29617
|
};
|
|
@@ -29525,7 +29761,8 @@ this.primereact.inputnumber = (function (exports, React, PrimeReact, componentba
|
|
|
29525
29761
|
if (val1 && val2) {
|
|
29526
29762
|
var decimalCharIndex = val2.search(_decimal.current);
|
|
29527
29763
|
_decimal.current.lastIndex = 0;
|
|
29528
|
-
|
|
29764
|
+
var newVal1 = replaceDecimalSeparator(val1).split(_decimal.current)[0].replace(_suffix.current, '').trim();
|
|
29765
|
+
return decimalCharIndex !== -1 ? newVal1 + val2.slice(decimalCharIndex) : val1;
|
|
29529
29766
|
}
|
|
29530
29767
|
return val1;
|
|
29531
29768
|
};
|
|
@@ -29533,7 +29770,7 @@ this.primereact.inputnumber = (function (exports, React, PrimeReact, componentba
|
|
|
29533
29770
|
if (value) {
|
|
29534
29771
|
var valueSplit = value.split(_decimal.current);
|
|
29535
29772
|
if (valueSplit.length === 2) {
|
|
29536
|
-
return valueSplit[1]
|
|
29773
|
+
return replaceSuffix(valueSplit[1]).length;
|
|
29537
29774
|
}
|
|
29538
29775
|
}
|
|
29539
29776
|
return 0;
|
|
@@ -29560,14 +29797,18 @@ this.primereact.inputnumber = (function (exports, React, PrimeReact, componentba
|
|
|
29560
29797
|
var onInputFocus = function onInputFocus(event) {
|
|
29561
29798
|
setFocusedState(true);
|
|
29562
29799
|
props.onFocus && props.onFocus(event);
|
|
29563
|
-
if ((props.suffix || props.currency || props.prefix) && inputRef.current) {
|
|
29564
|
-
// GitHub #1866
|
|
29565
|
-
var
|
|
29566
|
-
|
|
29800
|
+
if ((props.suffix || props.currency || props.prefix) && inputRef.current && !isFocusedByClick.current) {
|
|
29801
|
+
// GitHub #1866,#5537
|
|
29802
|
+
var inputValue = inputRef.current.value;
|
|
29803
|
+
var prefixLength = (prefixChar.current || '').length;
|
|
29804
|
+
var suffixLength = (suffixChar.current || '').length;
|
|
29805
|
+
var end = inputValue.length === 0 ? 0 : inputValue.length - suffixLength;
|
|
29806
|
+
inputRef.current.setSelectionRange(prefixLength, end);
|
|
29567
29807
|
}
|
|
29568
29808
|
};
|
|
29569
29809
|
var onInputBlur = function onInputBlur(event) {
|
|
29570
29810
|
setFocusedState(false);
|
|
29811
|
+
isFocusedByClick.current = false;
|
|
29571
29812
|
if (inputRef.current) {
|
|
29572
29813
|
var currentValue = inputRef.current.value;
|
|
29573
29814
|
if (isValueChanged(currentValue, props.value)) {
|
|
@@ -29584,7 +29825,8 @@ this.primereact.inputnumber = (function (exports, React, PrimeReact, componentba
|
|
|
29584
29825
|
}
|
|
29585
29826
|
};
|
|
29586
29827
|
var changeValue = function changeValue() {
|
|
29587
|
-
|
|
29828
|
+
var val = validateValueByLimit(props.value);
|
|
29829
|
+
updateInputValue(props.format ? val : replaceDecimalSeparator(val));
|
|
29588
29830
|
var newValue = validateValue(props.value);
|
|
29589
29831
|
if (props.value !== null && props.value !== newValue) {
|
|
29590
29832
|
updateModel(null, newValue);
|
|
@@ -29657,6 +29899,7 @@ this.primereact.inputnumber = (function (exports, React, PrimeReact, componentba
|
|
|
29657
29899
|
onKeyPress: onInputKeyUp,
|
|
29658
29900
|
onInput: onInput,
|
|
29659
29901
|
onClick: onInputClick,
|
|
29902
|
+
onPointerDown: onInputPointerDown,
|
|
29660
29903
|
onBlur: onInputBlur,
|
|
29661
29904
|
onFocus: onInputFocus,
|
|
29662
29905
|
onPaste: onPaste,
|
|
@@ -30191,7 +30434,7 @@ this.primereact.messages = (function (exports, React, reactTransitionGroup, api,
|
|
|
30191
30434
|
style: props.style
|
|
30192
30435
|
}, MessagesBase.getOtherProps(props), ptCallbacks.ptm('root'));
|
|
30193
30436
|
var transitionProps = utils.mergeProps({
|
|
30194
|
-
classNames: ptCallbacks.cx('transition'),
|
|
30437
|
+
classNames: ptCallbacks.cx('uimessage.transition'),
|
|
30195
30438
|
unmountOnExit: true,
|
|
30196
30439
|
timeout: {
|
|
30197
30440
|
enter: 300,
|
|
@@ -30446,7 +30689,7 @@ this.primereact.progressbar = (function (exports, React, api, componentbase, uti
|
|
|
30446
30689
|
})({}, React, primereact.api, primereact.componentbase, primereact.utils);
|
|
30447
30690
|
|
|
30448
30691
|
this.primereact = this.primereact || {};
|
|
30449
|
-
this.primereact.dropdown = (function (exports, React, PrimeReact, componentbase, hooks, chevrondown, times, overlayservice, tooltip, utils, csstransition, search, portal, virtualscroller, ripple
|
|
30692
|
+
this.primereact.dropdown = (function (exports, React, PrimeReact, componentbase, hooks, chevrondown, spinner, times, overlayservice, tooltip, utils, csstransition, search, portal, virtualscroller, ripple) {
|
|
30450
30693
|
'use strict';
|
|
30451
30694
|
|
|
30452
30695
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
@@ -31716,7 +31959,7 @@ this.primereact.dropdown = (function (exports, React, PrimeReact, componentbase,
|
|
|
31716
31959
|
onBlur: onInputBlur,
|
|
31717
31960
|
onKeyDown: onInputKeyDown,
|
|
31718
31961
|
disabled: props.disabled,
|
|
31719
|
-
tabIndex: props.tabIndex
|
|
31962
|
+
tabIndex: props.tabIndex || 0
|
|
31720
31963
|
}, ariaProps), ptm('input'));
|
|
31721
31964
|
return /*#__PURE__*/React__namespace.createElement("div", hiddenSelectedMessageProps, /*#__PURE__*/React__namespace.createElement("input", inputProps));
|
|
31722
31965
|
};
|
|
@@ -31737,6 +31980,7 @@ this.primereact.dropdown = (function (exports, React, PrimeReact, componentbase,
|
|
|
31737
31980
|
onInput: onEditableInputChange,
|
|
31738
31981
|
onFocus: onEditableInputFocus,
|
|
31739
31982
|
onBlur: onInputBlur,
|
|
31983
|
+
tabIndex: props.tabIndex || 0,
|
|
31740
31984
|
'aria-haspopup': 'listbox'
|
|
31741
31985
|
}, ariaProps), ptm('input'));
|
|
31742
31986
|
return /*#__PURE__*/React__namespace.createElement("input", inputProps);
|
|
@@ -31746,7 +31990,8 @@ this.primereact.dropdown = (function (exports, React, PrimeReact, componentbase,
|
|
|
31746
31990
|
ref: inputRef,
|
|
31747
31991
|
className: cx('input', {
|
|
31748
31992
|
label: label
|
|
31749
|
-
})
|
|
31993
|
+
}),
|
|
31994
|
+
tabIndex: '-1'
|
|
31750
31995
|
}, ptm('input'));
|
|
31751
31996
|
return /*#__PURE__*/React__namespace.createElement("span", _inputProps, content);
|
|
31752
31997
|
}
|
|
@@ -31876,10 +32121,10 @@ this.primereact.dropdown = (function (exports, React, PrimeReact, componentbase,
|
|
|
31876
32121
|
|
|
31877
32122
|
return exports;
|
|
31878
32123
|
|
|
31879
|
-
})({}, React, primereact.api, primereact.componentbase, primereact.hooks, primereact.icons.chevrondown, primereact.icons.times, primereact.overlayservice, primereact.tooltip, primereact.utils, primereact.csstransition, primereact.icons.search, primereact.portal, primereact.virtualscroller, primereact.ripple
|
|
32124
|
+
})({}, React, primereact.api, primereact.componentbase, primereact.hooks, primereact.icons.chevrondown, primereact.icons.spinner, primereact.icons.times, primereact.overlayservice, primereact.tooltip, primereact.utils, primereact.csstransition, primereact.icons.search, primereact.portal, primereact.virtualscroller, primereact.ripple);
|
|
31880
32125
|
|
|
31881
32126
|
this.primereact = this.primereact || {};
|
|
31882
|
-
this.primereact.dialog = (function (exports, React,
|
|
32127
|
+
this.primereact.dialog = (function (exports, React, PrimeReact, componentbase, csstransition, hooks, times, windowmaximize, windowminimize, portal, ripple, utils) {
|
|
31883
32128
|
'use strict';
|
|
31884
32129
|
|
|
31885
32130
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
@@ -32032,106 +32277,6 @@ this.primereact.dialog = (function (exports, React, utils, PrimeReact, component
|
|
|
32032
32277
|
return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest();
|
|
32033
32278
|
}
|
|
32034
32279
|
|
|
32035
|
-
var usePrevious = function usePrevious(newValue) {
|
|
32036
|
-
var ref = React__namespace.useRef(undefined);
|
|
32037
|
-
React__namespace.useEffect(function () {
|
|
32038
|
-
ref.current = newValue;
|
|
32039
|
-
});
|
|
32040
|
-
return ref.current;
|
|
32041
|
-
};
|
|
32042
|
-
|
|
32043
|
-
/* eslint-disable */
|
|
32044
|
-
var useUnmountEffect = function useUnmountEffect(fn) {
|
|
32045
|
-
return React__namespace.useEffect(function () {
|
|
32046
|
-
return fn;
|
|
32047
|
-
}, []);
|
|
32048
|
-
};
|
|
32049
|
-
/* eslint-enable */
|
|
32050
|
-
|
|
32051
|
-
/* eslint-disable */
|
|
32052
|
-
var useEventListener = function useEventListener(_ref) {
|
|
32053
|
-
var _ref$target = _ref.target,
|
|
32054
|
-
target = _ref$target === void 0 ? 'document' : _ref$target,
|
|
32055
|
-
type = _ref.type,
|
|
32056
|
-
listener = _ref.listener,
|
|
32057
|
-
options = _ref.options,
|
|
32058
|
-
_ref$when = _ref.when,
|
|
32059
|
-
when = _ref$when === void 0 ? true : _ref$when;
|
|
32060
|
-
var targetRef = React__namespace.useRef(null);
|
|
32061
|
-
var listenerRef = React__namespace.useRef(null);
|
|
32062
|
-
var prevListener = usePrevious(listener);
|
|
32063
|
-
var prevOptions = usePrevious(options);
|
|
32064
|
-
var bind = function bind() {
|
|
32065
|
-
var bindOptions = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
32066
|
-
if (utils.ObjectUtils.isNotEmpty(bindOptions.target)) {
|
|
32067
|
-
unbind();
|
|
32068
|
-
(bindOptions.when || when) && (targetRef.current = utils.DomHandler.getTargetElement(bindOptions.target));
|
|
32069
|
-
}
|
|
32070
|
-
if (!listenerRef.current && targetRef.current) {
|
|
32071
|
-
listenerRef.current = function (event) {
|
|
32072
|
-
return listener && listener(event);
|
|
32073
|
-
};
|
|
32074
|
-
targetRef.current.addEventListener(type, listenerRef.current, options);
|
|
32075
|
-
}
|
|
32076
|
-
};
|
|
32077
|
-
var unbind = function unbind() {
|
|
32078
|
-
if (listenerRef.current) {
|
|
32079
|
-
targetRef.current.removeEventListener(type, listenerRef.current, options);
|
|
32080
|
-
listenerRef.current = null;
|
|
32081
|
-
}
|
|
32082
|
-
};
|
|
32083
|
-
React__namespace.useEffect(function () {
|
|
32084
|
-
if (when) {
|
|
32085
|
-
targetRef.current = utils.DomHandler.getTargetElement(target);
|
|
32086
|
-
} else {
|
|
32087
|
-
unbind();
|
|
32088
|
-
targetRef.current = null;
|
|
32089
|
-
}
|
|
32090
|
-
}, [target, when]);
|
|
32091
|
-
React__namespace.useEffect(function () {
|
|
32092
|
-
// to properly compare functions we can implicitly converting the function to it's body's text as a String
|
|
32093
|
-
if (listenerRef.current && ('' + prevListener !== '' + listener || prevOptions !== options)) {
|
|
32094
|
-
unbind();
|
|
32095
|
-
when && bind();
|
|
32096
|
-
}
|
|
32097
|
-
}, [listener, options, when]);
|
|
32098
|
-
useUnmountEffect(function () {
|
|
32099
|
-
unbind();
|
|
32100
|
-
});
|
|
32101
|
-
return [bind, unbind];
|
|
32102
|
-
};
|
|
32103
|
-
/* eslint-enable */
|
|
32104
|
-
|
|
32105
|
-
var useOnEscapeKey = function useOnEscapeKey(ref, condition, callback) {
|
|
32106
|
-
var handleEsc = function handleEsc(event) {
|
|
32107
|
-
if (event.key === 'Esc' || event.key === 'Escape') {
|
|
32108
|
-
event.stopImmediatePropagation();
|
|
32109
|
-
callback(event);
|
|
32110
|
-
}
|
|
32111
|
-
return;
|
|
32112
|
-
};
|
|
32113
|
-
var _useEventListener = useEventListener({
|
|
32114
|
-
type: 'keydown',
|
|
32115
|
-
listener: handleEsc
|
|
32116
|
-
}),
|
|
32117
|
-
_useEventListener2 = _slicedToArray(_useEventListener, 2),
|
|
32118
|
-
bindKeyDownListener = _useEventListener2[0],
|
|
32119
|
-
unbindKeyDownListener = _useEventListener2[1];
|
|
32120
|
-
React__namespace.useEffect(function () {
|
|
32121
|
-
if (!condition) {
|
|
32122
|
-
return;
|
|
32123
|
-
}
|
|
32124
|
-
if (!ref.current) {
|
|
32125
|
-
return;
|
|
32126
|
-
}
|
|
32127
|
-
bindKeyDownListener();
|
|
32128
|
-
return function () {
|
|
32129
|
-
unbindKeyDownListener();
|
|
32130
|
-
};
|
|
32131
|
-
});
|
|
32132
|
-
return [ref, callback];
|
|
32133
|
-
};
|
|
32134
|
-
|
|
32135
32280
|
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; }
|
|
32136
32281
|
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), !0).forEach(function (r) { _defineProperty(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; }
|
|
32137
32282
|
var classes = {
|
|
@@ -32298,6 +32443,7 @@ this.primereact.dialog = (function (exports, React, utils, PrimeReact, component
|
|
|
32298
32443
|
var focusElementOnHide = React__namespace.useRef(null);
|
|
32299
32444
|
var maximized = props.onMaximize ? props.maximized : maximizedState;
|
|
32300
32445
|
var shouldBlockScroll = visibleState && (props.blockScroll || props.maximizable && maximized);
|
|
32446
|
+
var displayOrder = hooks.useDisplayOrder('dialog', visibleState);
|
|
32301
32447
|
var _DialogBase$setMetaDa = DialogBase.setMetaData(_objectSpread(_objectSpread({
|
|
32302
32448
|
props: props
|
|
32303
32449
|
}, props.__parentMetadata), {}, {
|
|
@@ -32314,15 +32460,14 @@ this.primereact.dialog = (function (exports, React, utils, PrimeReact, component
|
|
|
32314
32460
|
componentbase.useHandleStyle(DialogBase.css.styles, isUnstyled, {
|
|
32315
32461
|
name: 'dialog'
|
|
32316
32462
|
});
|
|
32317
|
-
|
|
32318
|
-
|
|
32319
|
-
|
|
32320
|
-
|
|
32321
|
-
|
|
32322
|
-
|
|
32323
|
-
|
|
32324
|
-
|
|
32325
|
-
params.splice(paramLength - 1, 1);
|
|
32463
|
+
hooks.useGlobalOnEscapeKey({
|
|
32464
|
+
callback: function callback(event) {
|
|
32465
|
+
if (props.closable && props.closeOnEscape) {
|
|
32466
|
+
onClose(event);
|
|
32467
|
+
}
|
|
32468
|
+
},
|
|
32469
|
+
when: visibleState,
|
|
32470
|
+
priority: [hooks.ESC_KEY_HANDLING_PRIORITIES.DIALOG, displayOrder]
|
|
32326
32471
|
});
|
|
32327
32472
|
var _useEventListener = hooks.useEventListener({
|
|
32328
32473
|
type: 'keydown',
|
|
@@ -32582,11 +32727,9 @@ this.primereact.dialog = (function (exports, React, utils, PrimeReact, component
|
|
|
32582
32727
|
};
|
|
32583
32728
|
var enableDocumentSettings = function enableDocumentSettings() {
|
|
32584
32729
|
bindGlobalListeners();
|
|
32585
|
-
updateGlobalDialogsRegistry(true);
|
|
32586
32730
|
};
|
|
32587
32731
|
var disableDocumentSettings = function disableDocumentSettings() {
|
|
32588
32732
|
unbindGlobalListeners();
|
|
32589
|
-
updateGlobalDialogsRegistry(false);
|
|
32590
32733
|
};
|
|
32591
32734
|
var updateScrollBlocker = function updateScrollBlocker() {
|
|
32592
32735
|
// Scroll should be unblocked if there is at least one dialog that blocks scrolling:
|
|
@@ -32600,7 +32743,7 @@ this.primereact.dialog = (function (exports, React, utils, PrimeReact, component
|
|
|
32600
32743
|
}
|
|
32601
32744
|
};
|
|
32602
32745
|
var updateGlobalDialogsRegistry = function updateGlobalDialogsRegistry(isMounted) {
|
|
32603
|
-
// Update current dialog info in global registry if it is mounted :
|
|
32746
|
+
// Update current dialog info in global registry if it is mounted and visible:
|
|
32604
32747
|
if (isMounted && visibleState) {
|
|
32605
32748
|
var newParam = {
|
|
32606
32749
|
id: idState,
|
|
@@ -32620,7 +32763,7 @@ this.primereact.dialog = (function (exports, React, utils, PrimeReact, component
|
|
|
32620
32763
|
document.primeDialogParams = document.primeDialogParams.toSpliced(currentDialogIndexInRegistry, 1, newParam);
|
|
32621
32764
|
}
|
|
32622
32765
|
}
|
|
32623
|
-
// Or remove it from global registry if unmounted:
|
|
32766
|
+
// Or remove it from global registry if unmounted or invisible:
|
|
32624
32767
|
else {
|
|
32625
32768
|
document.primeDialogParams = document.primeDialogParams && document.primeDialogParams.filter(function (param) {
|
|
32626
32769
|
return param.id !== idState;
|
|
@@ -32650,21 +32793,31 @@ this.primereact.dialog = (function (exports, React, utils, PrimeReact, component
|
|
|
32650
32793
|
unbindDocumentKeyDownListener();
|
|
32651
32794
|
};
|
|
32652
32795
|
var createStyle = function createStyle() {
|
|
32653
|
-
styleElement.current = utils.DomHandler.createInlineStyle(context && context.nonce || PrimeReact__default["default"].nonce);
|
|
32796
|
+
styleElement.current = utils.DomHandler.createInlineStyle(context && context.nonce || PrimeReact__default["default"].nonce, context && context.styleContainer);
|
|
32654
32797
|
var innerHTML = '';
|
|
32655
32798
|
for (var breakpoint in props.breakpoints) {
|
|
32656
|
-
innerHTML += "\n @media screen and (max-width: ".concat(breakpoint, ") {\n
|
|
32799
|
+
innerHTML += "\n @media screen and (max-width: ".concat(breakpoint, ") {\n [data-pc-name=\"dialog\"][").concat(attributeSelector.current, "] {\n width: ").concat(props.breakpoints[breakpoint], " !important;\n }\n }\n ");
|
|
32657
32800
|
}
|
|
32658
32801
|
styleElement.current.innerHTML = innerHTML;
|
|
32659
32802
|
};
|
|
32803
|
+
var destroyStyle = function destroyStyle() {
|
|
32804
|
+
styleElement.current = utils.DomHandler.removeInlineStyle(styleElement.current);
|
|
32805
|
+
};
|
|
32660
32806
|
hooks.useMountEffect(function () {
|
|
32807
|
+
updateGlobalDialogsRegistry(true);
|
|
32661
32808
|
if (props.visible) {
|
|
32662
32809
|
setMaskVisibleState(true);
|
|
32663
32810
|
}
|
|
32811
|
+
});
|
|
32812
|
+
React__namespace.useEffect(function () {
|
|
32664
32813
|
if (props.breakpoints) {
|
|
32665
32814
|
createStyle();
|
|
32666
32815
|
}
|
|
32667
|
-
|
|
32816
|
+
return function () {
|
|
32817
|
+
destroyStyle();
|
|
32818
|
+
};
|
|
32819
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
32820
|
+
}, [props.breakpoints]);
|
|
32668
32821
|
hooks.useUpdateEffect(function () {
|
|
32669
32822
|
if (props.visible && !maskVisibleState) {
|
|
32670
32823
|
setMaskVisibleState(true);
|
|
@@ -32686,9 +32839,10 @@ this.primereact.dialog = (function (exports, React, utils, PrimeReact, component
|
|
|
32686
32839
|
}, [maskVisibleState]);
|
|
32687
32840
|
hooks.useUpdateEffect(function () {
|
|
32688
32841
|
updateGlobalDialogsRegistry(true);
|
|
32689
|
-
}, [shouldBlockScroll]);
|
|
32842
|
+
}, [shouldBlockScroll, visibleState]);
|
|
32690
32843
|
hooks.useUnmountEffect(function () {
|
|
32691
32844
|
disableDocumentSettings();
|
|
32845
|
+
updateGlobalDialogsRegistry(false);
|
|
32692
32846
|
utils.DomHandler.removeInlineStyle(styleElement.current);
|
|
32693
32847
|
utils.ZIndexUtils.clear(maskRef.current);
|
|
32694
32848
|
});
|
|
@@ -32923,7 +33077,7 @@ this.primereact.dialog = (function (exports, React, utils, PrimeReact, component
|
|
|
32923
33077
|
|
|
32924
33078
|
return exports;
|
|
32925
33079
|
|
|
32926
|
-
})({}, React, primereact.
|
|
33080
|
+
})({}, React, primereact.api, primereact.componentbase, primereact.csstransition, primereact.hooks, primereact.icons.times, primereact.icons.windowmaximize, primereact.icons.windowminimize, primereact.portal, primereact.ripple, primereact.utils);
|
|
32927
33081
|
|
|
32928
33082
|
this.primereact = this.primereact || {};
|
|
32929
33083
|
this.primereact.paginator = (function (exports, React, api, componentbase, hooks, utils, angledoubleleft, ripple, inputnumber, angledoubleright, angleright, angleleft, dropdown) {
|
|
@@ -34079,7 +34233,7 @@ this.primereact.tree = (function (exports, React, api, componentbase, search, sp
|
|
|
34079
34233
|
});
|
|
34080
34234
|
}
|
|
34081
34235
|
};
|
|
34082
|
-
var styles = "\n@layer primereact {\n .p-tree-container {\n margin: 0;\n padding: 0;\n list-style-type: none;\n overflow: auto;\n }\n
|
|
34236
|
+
var styles = "\n@layer primereact {\n .p-tree-container {\n margin: 0;\n padding: 0;\n list-style-type: none;\n overflow: auto;\n }\n\n .p-treenode-children {\n margin: 0;\n padding: 0;\n list-style-type: none;\n }\n\n .p-treenode-selectable {\n cursor: pointer;\n user-select: none;\n }\n\n .p-tree-toggler {\n cursor: pointer;\n user-select: none;\n display: inline-flex;\n align-items: center;\n justify-content: center;\n flex-shrink: 0;\n overflow: hidden;\n position: relative;\n }\n\n .p-treenode-leaf > .p-treenode-content .p-tree-toggler {\n visibility: hidden;\n }\n\n .p-treenode-content {\n display: flex;\n align-items: center;\n }\n\n .p-tree-filter {\n width: 100%;\n }\n\n .p-tree-filter-container {\n position: relative;\n display: block;\n width: 100%;\n }\n\n .p-tree-filter-icon {\n position: absolute;\n top: 50%;\n margin-top: -.5rem;\n }\n\n .p-tree-loading {\n position: relative;\n min-height: 4rem;\n }\n\n .p-tree .p-tree-loading-overlay {\n position: absolute;\n z-index: 1;\n display: flex;\n align-items: center;\n justify-content: center;\n }\n}\n";
|
|
34083
34237
|
var TreeBase = componentbase.ComponentBase.extend({
|
|
34084
34238
|
defaultProps: {
|
|
34085
34239
|
__TYPE: 'Tree',
|
|
@@ -34094,6 +34248,8 @@ this.primereact.tree = (function (exports, React, api, componentbase, search, sp
|
|
|
34094
34248
|
contextMenuSelectionKey: null,
|
|
34095
34249
|
onContextMenuSelectionChange: null,
|
|
34096
34250
|
expandedKeys: null,
|
|
34251
|
+
ariaLabel: null,
|
|
34252
|
+
ariaLabelledBy: null,
|
|
34097
34253
|
style: null,
|
|
34098
34254
|
className: null,
|
|
34099
34255
|
contentStyle: null,
|
|
@@ -34117,6 +34273,7 @@ this.primereact.tree = (function (exports, React, api, componentbase, search, sp
|
|
|
34117
34273
|
filterPlaceholder: null,
|
|
34118
34274
|
filterLocale: undefined,
|
|
34119
34275
|
filterTemplate: null,
|
|
34276
|
+
level: 0,
|
|
34120
34277
|
nodeTemplate: null,
|
|
34121
34278
|
togglerTemplate: null,
|
|
34122
34279
|
onSelect: null,
|
|
@@ -34144,8 +34301,10 @@ this.primereact.tree = (function (exports, React, api, componentbase, search, sp
|
|
|
34144
34301
|
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), !0).forEach(function (r) { _defineProperty(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; }
|
|
34145
34302
|
var UITreeNode = /*#__PURE__*/React__namespace.memo(function (props) {
|
|
34146
34303
|
var contentRef = React__namespace.useRef(null);
|
|
34304
|
+
var elementRef = React__namespace.useRef(null);
|
|
34147
34305
|
var nodeTouched = React__namespace.useRef(false);
|
|
34148
34306
|
var isLeaf = props.isNodeLeaf(props.node);
|
|
34307
|
+
var label = props.node.label;
|
|
34149
34308
|
var expanded = (props.expandedKeys ? props.expandedKeys[props.node.key] !== undefined : false) || props.node.expanded;
|
|
34150
34309
|
var ptm = props.ptm,
|
|
34151
34310
|
cx = props.cx;
|
|
@@ -34161,11 +34320,13 @@ this.primereact.tree = (function (exports, React, api, componentbase, search, sp
|
|
|
34161
34320
|
});
|
|
34162
34321
|
};
|
|
34163
34322
|
var expand = function expand(event) {
|
|
34323
|
+
var navigateFocusToChild = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
|
|
34164
34324
|
var expandedKeys = props.expandedKeys ? _objectSpread$1({}, props.expandedKeys) : {};
|
|
34165
34325
|
expandedKeys[props.node.key] = true;
|
|
34166
34326
|
props.onToggle({
|
|
34167
34327
|
originalEvent: event,
|
|
34168
|
-
value: expandedKeys
|
|
34328
|
+
value: expandedKeys,
|
|
34329
|
+
navigateFocusToChild: navigateFocusToChild
|
|
34169
34330
|
});
|
|
34170
34331
|
invokeToggleEvents(event, true);
|
|
34171
34332
|
};
|
|
@@ -34182,7 +34343,7 @@ this.primereact.tree = (function (exports, React, api, componentbase, search, sp
|
|
|
34182
34343
|
if (props.disabled) {
|
|
34183
34344
|
return;
|
|
34184
34345
|
}
|
|
34185
|
-
expanded ? collapse(event) : expand(event);
|
|
34346
|
+
expanded ? collapse(event) : expand(event, false);
|
|
34186
34347
|
event.preventDefault();
|
|
34187
34348
|
event.stopPropagation();
|
|
34188
34349
|
};
|
|
@@ -34203,72 +34364,6 @@ this.primereact.tree = (function (exports, React, api, componentbase, search, sp
|
|
|
34203
34364
|
}
|
|
34204
34365
|
}
|
|
34205
34366
|
};
|
|
34206
|
-
var onNodeKeyDown = function onNodeKeyDown(event) {
|
|
34207
|
-
if (props.disabled) {
|
|
34208
|
-
return;
|
|
34209
|
-
}
|
|
34210
|
-
var nodeElement = event.target.parentElement;
|
|
34211
|
-
if (!utils.DomHandler.hasClass(nodeElement, 'p-treenode')) {
|
|
34212
|
-
return;
|
|
34213
|
-
}
|
|
34214
|
-
switch (event.which) {
|
|
34215
|
-
//down arrow
|
|
34216
|
-
case 40:
|
|
34217
|
-
var listElement = nodeElement.children[1];
|
|
34218
|
-
if (listElement) {
|
|
34219
|
-
focusNode(listElement.children[0]);
|
|
34220
|
-
} else {
|
|
34221
|
-
var nextNodeElement = nodeElement.nextElementSibling;
|
|
34222
|
-
while (nextNodeElement) {
|
|
34223
|
-
if (!utils.DomHandler.hasClass(nextNodeElement, 'p-treenode-droppoint')) {
|
|
34224
|
-
break;
|
|
34225
|
-
}
|
|
34226
|
-
nextNodeElement = nextNodeElement.nextElementSibling;
|
|
34227
|
-
}
|
|
34228
|
-
if (nextNodeElement) {
|
|
34229
|
-
focusNode(nextNodeElement);
|
|
34230
|
-
} else {
|
|
34231
|
-
var nextSiblingAncestor = findNextSiblingOfAncestor(nodeElement);
|
|
34232
|
-
nextSiblingAncestor && focusNode(nextSiblingAncestor);
|
|
34233
|
-
}
|
|
34234
|
-
}
|
|
34235
|
-
event.preventDefault();
|
|
34236
|
-
break;
|
|
34237
|
-
|
|
34238
|
-
//up arrow
|
|
34239
|
-
case 38:
|
|
34240
|
-
if (nodeElement.previousElementSibling) {
|
|
34241
|
-
focusNode(findLastVisibleDescendant(nodeElement.previousElementSibling));
|
|
34242
|
-
} else {
|
|
34243
|
-
var parentNodeElement = getParentNodeElement(nodeElement);
|
|
34244
|
-
parentNodeElement && focusNode(parentNodeElement);
|
|
34245
|
-
}
|
|
34246
|
-
event.preventDefault();
|
|
34247
|
-
break;
|
|
34248
|
-
|
|
34249
|
-
//right arrow
|
|
34250
|
-
case 39:
|
|
34251
|
-
if (!expanded) {
|
|
34252
|
-
expand(event);
|
|
34253
|
-
}
|
|
34254
|
-
event.preventDefault();
|
|
34255
|
-
break;
|
|
34256
|
-
|
|
34257
|
-
//left arrow
|
|
34258
|
-
case 37:
|
|
34259
|
-
if (expanded) {
|
|
34260
|
-
collapse(event);
|
|
34261
|
-
}
|
|
34262
|
-
event.preventDefault();
|
|
34263
|
-
break;
|
|
34264
|
-
|
|
34265
|
-
//enter
|
|
34266
|
-
case 13:
|
|
34267
|
-
onClick(event);
|
|
34268
|
-
event.preventDefault();
|
|
34269
|
-
break;
|
|
34270
|
-
}
|
|
34271
|
-
};
|
|
34272
34367
|
var findNextSiblingOfAncestor = function findNextSiblingOfAncestor(nodeElement) {
|
|
34273
34368
|
var parentNodeElement = getParentNodeElement(nodeElement);
|
|
34274
34369
|
return parentNodeElement ? parentNodeElement.nextElementSibling || findNextSiblingOfAncestor(parentNodeElement) : null;
|
|
@@ -34287,7 +34382,7 @@ this.primereact.tree = (function (exports, React, api, componentbase, search, sp
|
|
|
34287
34382
|
return utils.DomHandler.hasClass(parentNodeElement, 'p-treenode') ? parentNodeElement : null;
|
|
34288
34383
|
};
|
|
34289
34384
|
var focusNode = function focusNode(element) {
|
|
34290
|
-
element && element.
|
|
34385
|
+
element && element.focus();
|
|
34291
34386
|
};
|
|
34292
34387
|
var onClick = function onClick(event) {
|
|
34293
34388
|
if (props.onClick) {
|
|
@@ -34447,6 +34542,131 @@ this.primereact.tree = (function (exports, React, api, componentbase, search, sp
|
|
|
34447
34542
|
});
|
|
34448
34543
|
}
|
|
34449
34544
|
};
|
|
34545
|
+
var onKeyDown = function onKeyDown(event) {
|
|
34546
|
+
if (!isSameNode(event)) return;
|
|
34547
|
+
switch (event.code) {
|
|
34548
|
+
case 'Tab':
|
|
34549
|
+
onTabKey();
|
|
34550
|
+
break;
|
|
34551
|
+
case 'ArrowDown':
|
|
34552
|
+
onArrowDown(event);
|
|
34553
|
+
break;
|
|
34554
|
+
case 'ArrowUp':
|
|
34555
|
+
onArrowUp(event);
|
|
34556
|
+
break;
|
|
34557
|
+
case 'ArrowRight':
|
|
34558
|
+
onArrowRight(event);
|
|
34559
|
+
break;
|
|
34560
|
+
case 'ArrowLeft':
|
|
34561
|
+
onArrowLeft(event);
|
|
34562
|
+
break;
|
|
34563
|
+
case 'Enter':
|
|
34564
|
+
case 'NumpadEnter':
|
|
34565
|
+
case 'Space':
|
|
34566
|
+
onEnterKey(event);
|
|
34567
|
+
break;
|
|
34568
|
+
}
|
|
34569
|
+
};
|
|
34570
|
+
var onArrowDown = function onArrowDown(event) {
|
|
34571
|
+
var nodeElement = event.target.getAttribute('data-pc-section') === 'toggler' ? event.target.closest('[role="treeitem"]') : event.target;
|
|
34572
|
+
var listElement = nodeElement.children[1];
|
|
34573
|
+
if (listElement) {
|
|
34574
|
+
focusRowChange(nodeElement, listElement.children[0]);
|
|
34575
|
+
} else {
|
|
34576
|
+
if (nodeElement.nextElementSibling) {
|
|
34577
|
+
focusRowChange(nodeElement, nodeElement.nextElementSibling);
|
|
34578
|
+
} else {
|
|
34579
|
+
var nextSiblingAncestor = findNextSiblingOfAncestor(nodeElement);
|
|
34580
|
+
if (nextSiblingAncestor) {
|
|
34581
|
+
focusRowChange(nodeElement, nextSiblingAncestor);
|
|
34582
|
+
}
|
|
34583
|
+
}
|
|
34584
|
+
}
|
|
34585
|
+
event.preventDefault();
|
|
34586
|
+
};
|
|
34587
|
+
var onArrowUp = function onArrowUp(event) {
|
|
34588
|
+
var nodeElement = event.target;
|
|
34589
|
+
if (nodeElement.previousElementSibling) {
|
|
34590
|
+
focusRowChange(nodeElement, nodeElement.previousElementSibling, findLastVisibleDescendant(nodeElement.previousElementSibling));
|
|
34591
|
+
} else {
|
|
34592
|
+
var parentNodeElement = getParentNodeElement(nodeElement);
|
|
34593
|
+
if (parentNodeElement) {
|
|
34594
|
+
focusRowChange(nodeElement, parentNodeElement);
|
|
34595
|
+
}
|
|
34596
|
+
}
|
|
34597
|
+
event.preventDefault();
|
|
34598
|
+
};
|
|
34599
|
+
var onArrowRight = function onArrowRight(event) {
|
|
34600
|
+
if (isLeaf || expanded) return;
|
|
34601
|
+
event.currentTarget.tabIndex = -1;
|
|
34602
|
+
expand(event, true);
|
|
34603
|
+
};
|
|
34604
|
+
var onArrowLeft = function onArrowLeft(event) {
|
|
34605
|
+
var togglerElement = utils.DomHandler.findSingle(event.currentTarget, '[data-pc-section="toggler"]');
|
|
34606
|
+
if (props.level === 0 && !expanded) {
|
|
34607
|
+
return false;
|
|
34608
|
+
}
|
|
34609
|
+
if (expanded && !isLeaf) {
|
|
34610
|
+
togglerElement.click();
|
|
34611
|
+
return false;
|
|
34612
|
+
}
|
|
34613
|
+
var target = findBeforeClickableNode(event.currentTarget);
|
|
34614
|
+
if (target) {
|
|
34615
|
+
focusRowChange(event.currentTarget, target);
|
|
34616
|
+
}
|
|
34617
|
+
};
|
|
34618
|
+
var onEnterKey = function onEnterKey(event) {
|
|
34619
|
+
setTabIndexForSelectionMode(event, nodeTouched.current);
|
|
34620
|
+
onClick(event);
|
|
34621
|
+
event.preventDefault();
|
|
34622
|
+
};
|
|
34623
|
+
var onTabKey = function onTabKey() {
|
|
34624
|
+
setAllNodesTabIndexes();
|
|
34625
|
+
};
|
|
34626
|
+
var setAllNodesTabIndexes = function setAllNodesTabIndexes() {
|
|
34627
|
+
var nodes = utils.DomHandler.find(contentRef.current.closest('[data-pc-section="container"]'), '[role="treeitem"]');
|
|
34628
|
+
var hasSelectedNode = _toConsumableArray(nodes).some(function (node) {
|
|
34629
|
+
return node.getAttribute('aria-selected') === 'true' || node.getAttribute('aria-checked') === 'true';
|
|
34630
|
+
});
|
|
34631
|
+
_toConsumableArray(nodes).forEach(function (node) {
|
|
34632
|
+
node.tabIndex = -1;
|
|
34633
|
+
});
|
|
34634
|
+
if (hasSelectedNode) {
|
|
34635
|
+
var selectedNodes = _toConsumableArray(nodes).filter(function (node) {
|
|
34636
|
+
return node.getAttribute('aria-selected') === 'true' || node.getAttribute('aria-checked') === 'true';
|
|
34637
|
+
});
|
|
34638
|
+
selectedNodes[0].tabIndex = 0;
|
|
34639
|
+
return;
|
|
34640
|
+
}
|
|
34641
|
+
_toConsumableArray(nodes)[0].tabIndex = 0;
|
|
34642
|
+
};
|
|
34643
|
+
var setTabIndexForSelectionMode = function setTabIndexForSelectionMode(event, nodeTouched) {
|
|
34644
|
+
if (props.selectionMode !== null) {
|
|
34645
|
+
var elements = _toConsumableArray(utils.DomHandler.find(elementRef.current.parentElement, '[role="treeitem"]'));
|
|
34646
|
+
event.currentTarget.tabIndex = nodeTouched === false ? -1 : 0;
|
|
34647
|
+
if (elements.every(function (element) {
|
|
34648
|
+
return element.tabIndex === -1;
|
|
34649
|
+
})) {
|
|
34650
|
+
elements[0].tabIndex = 0;
|
|
34651
|
+
}
|
|
34652
|
+
}
|
|
34653
|
+
};
|
|
34654
|
+
var focusRowChange = function focusRowChange(firstFocusableRow, currentFocusedRow, lastVisibleDescendant) {
|
|
34655
|
+
firstFocusableRow.tabIndex = '-1';
|
|
34656
|
+
currentFocusedRow.tabIndex = '0';
|
|
34657
|
+
focusNode(lastVisibleDescendant || currentFocusedRow);
|
|
34658
|
+
};
|
|
34659
|
+
var findBeforeClickableNode = function findBeforeClickableNode(node) {
|
|
34660
|
+
var parentListElement = node.closest('ul').closest('li');
|
|
34661
|
+
if (parentListElement) {
|
|
34662
|
+
var prevNodeButton = utils.DomHandler.findSingle(parentListElement, 'button');
|
|
34663
|
+
if (prevNodeButton && prevNodeButton.style.visibility !== 'hidden') {
|
|
34664
|
+
return parentListElement;
|
|
34665
|
+
}
|
|
34666
|
+
return findBeforeClickableNode(node.previousElementSibling);
|
|
34667
|
+
}
|
|
34668
|
+
return null;
|
|
34669
|
+
};
|
|
34450
34670
|
var propagateUp = function propagateUp(event) {
|
|
34451
34671
|
var check = event.check;
|
|
34452
34672
|
var selectionKeys = event.selectionKeys;
|
|
@@ -34510,6 +34730,9 @@ this.primereact.tree = (function (exports, React, api, componentbase, search, sp
|
|
|
34510
34730
|
var isChecked = function isChecked() {
|
|
34511
34731
|
return (props.selectionKeys ? props.selectionKeys[props.node.key] && props.selectionKeys[props.node.key].checked : false) || false;
|
|
34512
34732
|
};
|
|
34733
|
+
var isSameNode = function isSameNode(event) {
|
|
34734
|
+
return event.currentTarget && (event.currentTarget.isSameNode(event.target) || event.currentTarget.isSameNode(event.target.closest('[role="treeitem"]')));
|
|
34735
|
+
};
|
|
34513
34736
|
var isPartialChecked = function isPartialChecked() {
|
|
34514
34737
|
return props.selectionKeys ? props.selectionKeys[props.node.key] && props.selectionKeys[props.node.key].partialChecked : false;
|
|
34515
34738
|
};
|
|
@@ -34612,7 +34835,7 @@ this.primereact.tree = (function (exports, React, api, componentbase, search, sp
|
|
|
34612
34835
|
var labelProps = utils.mergeProps({
|
|
34613
34836
|
className: cx('label')
|
|
34614
34837
|
}, getPTOptions('label'));
|
|
34615
|
-
var content = /*#__PURE__*/React__namespace.createElement("span", labelProps,
|
|
34838
|
+
var content = /*#__PURE__*/React__namespace.createElement("span", labelProps, label);
|
|
34616
34839
|
if (props.nodeTemplate) {
|
|
34617
34840
|
var defaultContentOptions = {
|
|
34618
34841
|
onTogglerClick: onTogglerClick,
|
|
@@ -34635,6 +34858,7 @@ this.primereact.tree = (function (exports, React, api, componentbase, search, sp
|
|
|
34635
34858
|
var icon = checked ? props.checkboxIcon || /*#__PURE__*/React__namespace.createElement(check.CheckIcon, checkboxIconProps) : partialChecked ? props.checkboxIcon || /*#__PURE__*/React__namespace.createElement(minus.MinusIcon, checkboxIconProps) : null;
|
|
34636
34859
|
var checkboxIcon = utils.IconUtils.getJSXIcon(icon, _objectSpread$1({}, checkboxIconProps), props);
|
|
34637
34860
|
var checkboxContainerProps = utils.mergeProps({
|
|
34861
|
+
'aria-hidden': true,
|
|
34638
34862
|
className: cx('checkboxContainer')
|
|
34639
34863
|
}, getPTOptions('checkboxContainer'));
|
|
34640
34864
|
var checkboxProps = utils.mergeProps({
|
|
@@ -34643,8 +34867,7 @@ this.primereact.tree = (function (exports, React, api, componentbase, search, sp
|
|
|
34643
34867
|
partialChecked: partialChecked,
|
|
34644
34868
|
nodeProps: props
|
|
34645
34869
|
}),
|
|
34646
|
-
role: 'checkbox'
|
|
34647
|
-
'aria-checked': checked
|
|
34870
|
+
role: 'checkbox'
|
|
34648
34871
|
}, getPTOptions('checkbox'));
|
|
34649
34872
|
return /*#__PURE__*/React__namespace.createElement("div", checkboxContainerProps, /*#__PURE__*/React__namespace.createElement("div", checkboxProps, checkboxIcon));
|
|
34650
34873
|
}
|
|
@@ -34661,7 +34884,6 @@ this.primereact.tree = (function (exports, React, api, componentbase, search, sp
|
|
|
34661
34884
|
return null;
|
|
34662
34885
|
};
|
|
34663
34886
|
var createToggler = function createToggler() {
|
|
34664
|
-
var label = expanded ? api.ariaLabel('collapseLabel') : api.ariaLabel('expandLabel');
|
|
34665
34887
|
var togglerIconProps = utils.mergeProps({
|
|
34666
34888
|
className: cx('togglerIcon'),
|
|
34667
34889
|
'aria-hidden': true
|
|
@@ -34675,8 +34897,8 @@ this.primereact.tree = (function (exports, React, api, componentbase, search, sp
|
|
|
34675
34897
|
type: 'button',
|
|
34676
34898
|
className: cx('toggler'),
|
|
34677
34899
|
tabIndex: -1,
|
|
34678
|
-
|
|
34679
|
-
|
|
34900
|
+
'aria-hidden': true,
|
|
34901
|
+
onClick: onTogglerClick
|
|
34680
34902
|
}, getPTOptions('toggler'));
|
|
34681
34903
|
var content = /*#__PURE__*/React__namespace.createElement("button", togglerProps, togglerIcon, /*#__PURE__*/React__namespace.createElement(ripple.Ripple, null));
|
|
34682
34904
|
if (props.togglerTemplate) {
|
|
@@ -34733,8 +34955,7 @@ this.primereact.tree = (function (exports, React, api, componentbase, search, sp
|
|
|
34733
34955
|
onDragEnter: onDragEnter,
|
|
34734
34956
|
onDragLeave: onDragLeave,
|
|
34735
34957
|
onDragStart: onDragStart,
|
|
34736
|
-
onDragEnd: onDragEnd
|
|
34737
|
-
onKeyDown: onNodeKeyDown
|
|
34958
|
+
onDragEnd: onDragEnd
|
|
34738
34959
|
}, getPTOptions('content'));
|
|
34739
34960
|
return /*#__PURE__*/React__namespace.createElement("div", contentProps, toggler, checkbox, icon, label);
|
|
34740
34961
|
};
|
|
@@ -34748,62 +34969,70 @@ this.primereact.tree = (function (exports, React, api, componentbase, search, sp
|
|
|
34748
34969
|
return /*#__PURE__*/React__namespace.createElement(UITreeNode, {
|
|
34749
34970
|
key: childNode.key || childNode.label,
|
|
34750
34971
|
node: childNode,
|
|
34751
|
-
|
|
34752
|
-
|
|
34972
|
+
checkboxIcon: props.checkboxIcon,
|
|
34973
|
+
collapseIcon: props.collapseIcon,
|
|
34974
|
+
contextMenuSelectionKey: props.contextMenuSelectionKey,
|
|
34975
|
+
cx: cx,
|
|
34976
|
+
disabled: props.disabled,
|
|
34977
|
+
dragdropScope: props.dragdropScope,
|
|
34978
|
+
expandIcon: props.expandIcon,
|
|
34979
|
+
expandedKeys: props.expandedKeys,
|
|
34753
34980
|
index: index,
|
|
34981
|
+
isNodeLeaf: props.isNodeLeaf,
|
|
34754
34982
|
last: index === props.node.children.length - 1,
|
|
34755
|
-
path: props.path + '-' + index,
|
|
34756
|
-
disabled: props.disabled,
|
|
34757
|
-
selectionMode: props.selectionMode,
|
|
34758
|
-
selectionKeys: props.selectionKeys,
|
|
34759
|
-
onSelectionChange: props.onSelectionChange,
|
|
34760
34983
|
metaKeySelection: props.metaKeySelection,
|
|
34761
|
-
|
|
34762
|
-
propagateSelectionUp: props.propagateSelectionUp,
|
|
34763
|
-
contextMenuSelectionKey: props.contextMenuSelectionKey,
|
|
34764
|
-
onContextMenuSelectionChange: props.onContextMenuSelectionChange,
|
|
34765
|
-
onContextMenu: props.onContextMenu,
|
|
34766
|
-
onExpand: props.onExpand,
|
|
34767
|
-
onCollapse: props.onCollapse,
|
|
34768
|
-
onSelect: props.onSelect,
|
|
34769
|
-
onUnselect: props.onUnselect,
|
|
34984
|
+
nodeTemplate: props.nodeTemplate,
|
|
34770
34985
|
onClick: props.onClick,
|
|
34986
|
+
onCollapse: props.onCollapse,
|
|
34987
|
+
onContextMenu: props.onContextMenu,
|
|
34988
|
+
onContextMenuSelectionChange: props.onContextMenuSelectionChange,
|
|
34771
34989
|
onDoubleClick: props.onDoubleClick,
|
|
34772
|
-
expandedKeys: props.expandedKeys,
|
|
34773
|
-
onToggle: props.onToggle,
|
|
34774
|
-
onPropagateUp: propagateUp,
|
|
34775
|
-
nodeTemplate: props.nodeTemplate,
|
|
34776
|
-
togglerTemplate: props.togglerTemplate,
|
|
34777
|
-
isNodeLeaf: props.isNodeLeaf,
|
|
34778
|
-
dragdropScope: props.dragdropScope,
|
|
34779
|
-
onDragStart: props.onDragStart,
|
|
34780
34990
|
onDragEnd: props.onDragEnd,
|
|
34991
|
+
onDragStart: props.onDragStart,
|
|
34781
34992
|
onDrop: props.onDrop,
|
|
34782
34993
|
onDropPoint: props.onDropPoint,
|
|
34994
|
+
onExpand: props.onExpand,
|
|
34995
|
+
onPropagateUp: propagateUp,
|
|
34996
|
+
onSelect: props.onSelect,
|
|
34997
|
+
onSelectionChange: props.onSelectionChange,
|
|
34998
|
+
onToggle: props.onToggle,
|
|
34999
|
+
onUnselect: props.onUnselect,
|
|
35000
|
+
originalOptions: props.originalOptions,
|
|
35001
|
+
parent: props.node,
|
|
35002
|
+
path: props.path + '-' + index,
|
|
35003
|
+
propagateSelectionDown: props.propagateSelectionDown,
|
|
35004
|
+
propagateSelectionUp: props.propagateSelectionUp,
|
|
34783
35005
|
ptm: ptm,
|
|
34784
|
-
|
|
35006
|
+
selectionKeys: props.selectionKeys,
|
|
35007
|
+
selectionMode: props.selectionMode,
|
|
35008
|
+
togglerTemplate: props.togglerTemplate
|
|
34785
35009
|
});
|
|
34786
35010
|
}));
|
|
34787
35011
|
}
|
|
34788
35012
|
return null;
|
|
34789
35013
|
};
|
|
34790
35014
|
var createNode = function createNode() {
|
|
34791
|
-
var tabIndex = props.disabled ?
|
|
35015
|
+
var tabIndex = props.disabled || props.index !== 0 ? -1 : 0;
|
|
34792
35016
|
var selected = isSelected();
|
|
34793
35017
|
var checked = isChecked();
|
|
34794
35018
|
var content = createContent();
|
|
34795
35019
|
var children = createChildren();
|
|
34796
|
-
var nodeProps = utils.mergeProps({
|
|
35020
|
+
var nodeProps = utils.mergeProps(_defineProperty(_defineProperty({
|
|
35021
|
+
ref: elementRef,
|
|
34797
35022
|
className: utils.classNames(props.node.className, cx('node', {
|
|
34798
35023
|
isLeaf: isLeaf
|
|
34799
35024
|
})),
|
|
34800
35025
|
style: props.node.style,
|
|
34801
35026
|
tabIndex: tabIndex,
|
|
34802
35027
|
role: 'treeitem',
|
|
34803
|
-
'aria-
|
|
35028
|
+
'aria-label': label,
|
|
35029
|
+
'aria-level': props.level,
|
|
34804
35030
|
'aria-expanded': expanded,
|
|
34805
|
-
'aria-
|
|
34806
|
-
|
|
35031
|
+
'aria-checked': checked,
|
|
35032
|
+
'aria-setsize': props.node.children ? props.node.children.length : 0,
|
|
35033
|
+
'aria-posinset': props.index + 1,
|
|
35034
|
+
onKeyDown: onKeyDown
|
|
35035
|
+
}, "aria-expanded", expanded), 'aria-selected', checked || selected), getPTOptions('node'));
|
|
34807
35036
|
return /*#__PURE__*/React__namespace.createElement("li", nodeProps, content, children);
|
|
34808
35037
|
};
|
|
34809
35038
|
var node = createNode();
|
|
@@ -34816,6 +35045,19 @@ this.primereact.tree = (function (exports, React, api, componentbase, search, sp
|
|
|
34816
35045
|
});
|
|
34817
35046
|
UITreeNode.displayName = 'UITreeNode';
|
|
34818
35047
|
|
|
35048
|
+
/* eslint-disable */
|
|
35049
|
+
var useUpdateEffect = function useUpdateEffect(fn, deps) {
|
|
35050
|
+
var mounted = React__namespace.useRef(false);
|
|
35051
|
+
return React__namespace.useEffect(function () {
|
|
35052
|
+
if (!mounted.current) {
|
|
35053
|
+
mounted.current = true;
|
|
35054
|
+
return;
|
|
35055
|
+
}
|
|
35056
|
+
return fn && fn();
|
|
35057
|
+
}, deps);
|
|
35058
|
+
};
|
|
35059
|
+
/* eslint-enable */
|
|
35060
|
+
|
|
34819
35061
|
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; }
|
|
34820
35062
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
34821
35063
|
function _createForOfIteratorHelper(o, allowArrayLike) { var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"]; if (!it) { if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = it.call(o); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it["return"] != null) it["return"](); } finally { if (didErr) throw err; } } }; }
|
|
@@ -34838,6 +35080,7 @@ this.primereact.tree = (function (exports, React, api, componentbase, search, sp
|
|
|
34838
35080
|
var filterChanged = React__namespace.useRef(false);
|
|
34839
35081
|
var filteredValue = props.onFilterValueChange ? props.filterValue : filterValueState;
|
|
34840
35082
|
var expandedKeys = props.onToggle ? props.expandedKeys : expandedKeysState;
|
|
35083
|
+
var childFocusEvent = React__namespace.useRef(null);
|
|
34841
35084
|
var _TreeBase$setMetaData = TreeBase.setMetaData({
|
|
34842
35085
|
props: props,
|
|
34843
35086
|
state: {
|
|
@@ -34863,12 +35106,33 @@ this.primereact.tree = (function (exports, React, api, componentbase, search, sp
|
|
|
34863
35106
|
return props.filter && filteredNodes.current ? filteredNodes.current : props.value;
|
|
34864
35107
|
};
|
|
34865
35108
|
var onToggle = function onToggle(event) {
|
|
35109
|
+
var originalEvent = event.originalEvent,
|
|
35110
|
+
value = event.value,
|
|
35111
|
+
navigateFocusToChild = event.navigateFocusToChild;
|
|
34866
35112
|
if (props.onToggle) {
|
|
34867
|
-
props.onToggle(
|
|
35113
|
+
props.onToggle({
|
|
35114
|
+
originalEvent: originalEvent,
|
|
35115
|
+
value: value
|
|
35116
|
+
});
|
|
34868
35117
|
} else {
|
|
35118
|
+
if (navigateFocusToChild) {
|
|
35119
|
+
childFocusEvent.current = originalEvent;
|
|
35120
|
+
}
|
|
34869
35121
|
setExpandedKeysState(event.value);
|
|
34870
35122
|
}
|
|
34871
35123
|
};
|
|
35124
|
+
useUpdateEffect(function () {
|
|
35125
|
+
if (childFocusEvent.current) {
|
|
35126
|
+
var event = childFocusEvent.current;
|
|
35127
|
+
var nodeElement = event.target.getAttribute('data-pc-section') === 'toggler' ? event.target.closest('[role="treeitem"]') : event.target;
|
|
35128
|
+
var listElement = nodeElement.children[1];
|
|
35129
|
+
var childElement = listElement.children[0];
|
|
35130
|
+
nodeElement.tabIndex = '-1';
|
|
35131
|
+
childElement.tabIndex = '0';
|
|
35132
|
+
childElement.focus();
|
|
35133
|
+
childFocusEvent.current = null;
|
|
35134
|
+
}
|
|
35135
|
+
}, [expandedKeys]);
|
|
34872
35136
|
var onDragStart = function onDragStart(event) {
|
|
34873
35137
|
dragState.current = {
|
|
34874
35138
|
path: event.path,
|
|
@@ -35141,41 +35405,42 @@ this.primereact.tree = (function (exports, React, api, componentbase, search, sp
|
|
|
35141
35405
|
hostName: "Tree",
|
|
35142
35406
|
key: node.key || node.label,
|
|
35143
35407
|
node: node,
|
|
35408
|
+
level: props.level + 1,
|
|
35144
35409
|
originalOptions: props.value,
|
|
35145
35410
|
index: index,
|
|
35146
35411
|
last: last,
|
|
35147
35412
|
path: String(index),
|
|
35148
35413
|
checkboxIcon: props.checkboxIcon,
|
|
35149
|
-
expandIcon: props.expandIcon,
|
|
35150
35414
|
collapseIcon: props.collapseIcon,
|
|
35151
|
-
disabled: props.disabled,
|
|
35152
|
-
selectionMode: props.selectionMode,
|
|
35153
|
-
selectionKeys: props.selectionKeys,
|
|
35154
|
-
onSelectionChange: props.onSelectionChange,
|
|
35155
|
-
metaKeySelection: props.metaKeySelection,
|
|
35156
35415
|
contextMenuSelectionKey: props.contextMenuSelectionKey,
|
|
35157
|
-
|
|
35158
|
-
|
|
35159
|
-
|
|
35160
|
-
|
|
35161
|
-
onExpand: props.onExpand,
|
|
35162
|
-
onCollapse: props.onCollapse,
|
|
35163
|
-
onSelect: props.onSelect,
|
|
35164
|
-
onUnselect: props.onUnselect,
|
|
35416
|
+
cx: cx,
|
|
35417
|
+
disabled: props.disabled,
|
|
35418
|
+
dragdropScope: props.dragdropScope,
|
|
35419
|
+
expandIcon: props.expandIcon,
|
|
35165
35420
|
expandedKeys: expandedKeys,
|
|
35166
|
-
onToggle: onToggle,
|
|
35167
|
-
nodeTemplate: props.nodeTemplate,
|
|
35168
|
-
togglerTemplate: props.togglerTemplate,
|
|
35169
35421
|
isNodeLeaf: isNodeLeaf,
|
|
35170
|
-
|
|
35171
|
-
|
|
35422
|
+
metaKeySelection: props.metaKeySelection,
|
|
35423
|
+
nodeTemplate: props.nodeTemplate,
|
|
35424
|
+
onClick: props.onNodeClick,
|
|
35425
|
+
onCollapse: props.onCollapse,
|
|
35426
|
+
onContextMenu: props.onContextMenu,
|
|
35427
|
+
onContextMenuSelectionChange: props.onContextMenuSelectionChange,
|
|
35428
|
+
onDoubleClick: props.onNodeDoubleClick,
|
|
35172
35429
|
onDragEnd: onDragEnd,
|
|
35430
|
+
onDragStart: onDragStart,
|
|
35173
35431
|
onDrop: onDrop,
|
|
35174
35432
|
onDropPoint: onDropPoint,
|
|
35175
|
-
|
|
35176
|
-
|
|
35433
|
+
onExpand: props.onExpand,
|
|
35434
|
+
onSelect: props.onSelect,
|
|
35435
|
+
onSelectionChange: props.onSelectionChange,
|
|
35436
|
+
onToggle: onToggle,
|
|
35437
|
+
onUnselect: props.onUnselect,
|
|
35438
|
+
propagateSelectionDown: props.propagateSelectionDown,
|
|
35439
|
+
propagateSelectionUp: props.propagateSelectionUp,
|
|
35177
35440
|
ptm: ptm,
|
|
35178
|
-
|
|
35441
|
+
selectionKeys: props.selectionKeys,
|
|
35442
|
+
selectionMode: props.selectionMode,
|
|
35443
|
+
togglerTemplate: props.togglerTemplate
|
|
35179
35444
|
});
|
|
35180
35445
|
};
|
|
35181
35446
|
var createRootChildren = function createRootChildren() {
|
|
@@ -35194,6 +35459,8 @@ this.primereact.tree = (function (exports, React, api, componentbase, search, sp
|
|
|
35194
35459
|
var containerProps = utils.mergeProps(_objectSpread({
|
|
35195
35460
|
className: utils.classNames(props.contentClassName, cx('container')),
|
|
35196
35461
|
role: 'tree',
|
|
35462
|
+
'aria-label': props.ariaLabel,
|
|
35463
|
+
'aria-labelledby': props.ariaLabelledBy,
|
|
35197
35464
|
style: props.contentStyle
|
|
35198
35465
|
}, ariaProps), ptm('container'));
|
|
35199
35466
|
return /*#__PURE__*/React__namespace.createElement("ul", containerProps, rootNodes);
|