primereact 7.0.0-rc.1 → 7.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +35 -10
- package/accordion/accordion.cjs.js +40 -27
- package/accordion/accordion.cjs.min.js +1 -1
- package/accordion/accordion.d.ts +7 -3
- package/accordion/accordion.esm.js +27 -14
- package/accordion/accordion.esm.min.js +1 -1
- package/accordion/accordion.js +40 -28
- package/accordion/accordion.min.js +1 -1
- package/api/api.cjs.js +82 -46
- package/api/api.cjs.min.js +1 -1
- package/api/api.d.ts +95 -61
- package/api/api.esm.js +69 -33
- package/api/api.esm.min.js +1 -1
- package/api/api.js +83 -47
- package/api/api.min.js +1 -1
- package/autocomplete/autocomplete.cjs.js +79 -71
- package/autocomplete/autocomplete.cjs.min.js +1 -1
- package/autocomplete/autocomplete.d.ts +11 -4
- package/autocomplete/autocomplete.esm.js +16 -8
- package/autocomplete/autocomplete.esm.min.js +1 -1
- package/autocomplete/autocomplete.js +75 -72
- package/autocomplete/autocomplete.min.js +1 -1
- package/avatar/avatar.cjs.js +10 -9
- package/avatar/avatar.cjs.min.js +1 -1
- package/avatar/avatar.d.ts +2 -1
- package/avatar/avatar.esm.js +5 -4
- package/avatar/avatar.esm.min.js +1 -1
- package/avatar/avatar.js +11 -10
- package/avatar/avatar.min.js +1 -1
- package/avatargroup/avatargroup.cjs.js +3 -3
- package/avatargroup/avatargroup.cjs.min.js +1 -1
- package/avatargroup/avatargroup.esm.js +1 -1
- package/avatargroup/avatargroup.esm.min.js +1 -1
- package/avatargroup/avatargroup.js +4 -4
- package/avatargroup/avatargroup.min.js +1 -1
- package/badge/badge.cjs.js +3 -3
- package/badge/badge.cjs.min.js +1 -1
- package/badge/badge.esm.js +1 -1
- package/badge/badge.esm.min.js +1 -1
- package/badge/badge.js +4 -4
- package/badge/badge.min.js +1 -1
- package/blockui/blockui.cjs.js +27 -16
- package/blockui/blockui.cjs.min.js +1 -1
- package/blockui/blockui.esm.js +17 -7
- package/blockui/blockui.esm.min.js +1 -1
- package/blockui/blockui.js +26 -17
- package/blockui/blockui.min.js +1 -1
- package/breadcrumb/breadcrumb.cjs.js +16 -16
- package/breadcrumb/breadcrumb.cjs.min.js +1 -1
- package/breadcrumb/breadcrumb.esm.js +1 -1
- package/breadcrumb/breadcrumb.esm.min.js +1 -1
- package/breadcrumb/breadcrumb.js +17 -17
- package/breadcrumb/breadcrumb.min.js +1 -1
- package/button/button.cjs.js +42 -53
- package/button/button.cjs.min.js +1 -1
- package/button/button.d.ts +4 -11
- package/button/button.esm.js +31 -42
- package/button/button.esm.min.js +1 -1
- package/button/button.js +41 -54
- package/button/button.min.js +1 -1
- package/calendar/calendar.cjs.js +193 -154
- package/calendar/calendar.cjs.min.js +1 -1
- package/calendar/calendar.d.ts +7 -2
- package/calendar/calendar.esm.js +68 -29
- package/calendar/calendar.esm.min.js +1 -1
- package/calendar/calendar.js +189 -155
- package/calendar/calendar.min.css +1 -1
- package/calendar/calendar.min.js +1 -1
- package/captcha/captcha.cjs.js +1 -1
- package/captcha/captcha.cjs.min.js +1 -1
- package/captcha/captcha.esm.min.js +1 -1
- package/captcha/captcha.js +2 -2
- package/captcha/captcha.min.js +1 -1
- package/card/card.cjs.js +13 -13
- package/card/card.cjs.min.js +1 -1
- package/card/card.esm.js +1 -1
- package/card/card.esm.min.js +1 -1
- package/card/card.js +14 -14
- package/card/card.min.js +1 -1
- package/carousel/carousel.cjs.js +45 -45
- package/carousel/carousel.cjs.min.js +1 -1
- package/carousel/carousel.esm.js +10 -10
- package/carousel/carousel.esm.min.js +1 -1
- package/carousel/carousel.js +45 -46
- package/carousel/carousel.min.js +1 -1
- package/cascadeselect/cascadeselect.cjs.js +51 -47
- package/cascadeselect/cascadeselect.cjs.min.js +1 -1
- package/cascadeselect/cascadeselect.d.ts +2 -1
- package/cascadeselect/cascadeselect.esm.js +7 -3
- package/cascadeselect/cascadeselect.esm.min.js +1 -1
- package/cascadeselect/cascadeselect.js +48 -48
- package/cascadeselect/cascadeselect.min.js +1 -1
- package/chart/chart.cjs.js +6 -8
- package/chart/chart.cjs.min.js +1 -1
- package/chart/chart.esm.js +1 -1
- package/chart/chart.esm.min.js +1 -1
- package/chart/chart.js +5 -5
- package/chart/chart.min.js +1 -1
- package/checkbox/checkbox.cjs.js +20 -15
- package/checkbox/checkbox.cjs.min.js +1 -1
- package/checkbox/checkbox.d.ts +2 -1
- package/checkbox/checkbox.esm.js +13 -8
- package/checkbox/checkbox.esm.min.js +1 -1
- package/checkbox/checkbox.js +20 -16
- package/checkbox/checkbox.min.js +1 -1
- package/chip/chip.cjs.js +16 -14
- package/chip/chip.cjs.min.js +1 -1
- package/chip/chip.d.ts +3 -4
- package/chip/chip.esm.js +11 -9
- package/chip/chip.esm.min.js +1 -1
- package/chip/chip.js +17 -15
- package/chip/chip.min.js +1 -1
- package/chips/chips.cjs.js +46 -20
- package/chips/chips.cjs.min.js +1 -1
- package/chips/chips.d.ts +10 -0
- package/chips/chips.esm.js +37 -11
- package/chips/chips.esm.min.js +1 -1
- package/chips/chips.js +46 -21
- package/chips/chips.min.js +1 -1
- package/colorpicker/colorpicker.cjs.js +35 -31
- package/colorpicker/colorpicker.cjs.min.js +1 -1
- package/colorpicker/colorpicker.d.ts +20 -6
- package/colorpicker/colorpicker.esm.js +7 -3
- package/colorpicker/colorpicker.esm.min.js +1 -1
- package/colorpicker/colorpicker.js +32 -32
- package/colorpicker/colorpicker.min.js +1 -1
- package/column/column.cjs.min.js +1 -1
- package/column/column.d.ts +24 -2
- package/column/column.esm.min.js +1 -1
- package/column/column.js +1 -1
- package/column/column.min.js +1 -1
- package/columngroup/columngroup.cjs.min.js +1 -1
- package/columngroup/columngroup.esm.min.js +1 -1
- package/columngroup/columngroup.js +1 -1
- package/columngroup/columngroup.min.js +1 -1
- package/confirmdialog/confirmdialog.cjs.js +22 -20
- package/confirmdialog/confirmdialog.cjs.min.js +1 -1
- package/confirmdialog/confirmdialog.d.ts +4 -3
- package/confirmdialog/confirmdialog.esm.js +6 -4
- package/confirmdialog/confirmdialog.esm.min.js +1 -1
- package/confirmdialog/confirmdialog.js +22 -21
- package/confirmdialog/confirmdialog.min.js +1 -1
- package/confirmpopup/confirmpopup.cjs.js +46 -41
- package/confirmpopup/confirmpopup.cjs.min.js +1 -1
- package/confirmpopup/confirmpopup.d.ts +6 -4
- package/confirmpopup/confirmpopup.esm.js +12 -8
- package/confirmpopup/confirmpopup.esm.min.js +1 -1
- package/confirmpopup/confirmpopup.js +43 -41
- package/confirmpopup/confirmpopup.min.js +1 -1
- package/contextmenu/contextmenu.cjs.js +68 -63
- package/contextmenu/contextmenu.cjs.min.js +1 -1
- package/contextmenu/contextmenu.d.ts +2 -1
- package/contextmenu/contextmenu.esm.js +35 -31
- package/contextmenu/contextmenu.esm.min.js +1 -1
- package/contextmenu/contextmenu.js +65 -64
- package/contextmenu/contextmenu.min.js +1 -1
- package/core/core.js +11228 -846
- package/core/core.min.js +40 -1
- package/csstransition/csstransition.cjs.js +49 -19
- package/csstransition/csstransition.cjs.min.js +1 -1
- package/csstransition/csstransition.d.ts +8 -0
- package/csstransition/csstransition.esm.js +48 -19
- package/csstransition/csstransition.esm.min.js +1 -1
- package/csstransition/csstransition.js +49 -21
- package/csstransition/csstransition.min.js +1 -1
- package/csstransition/package.json +2 -1
- package/datascroller/datascroller.cjs.js +12 -11
- package/datascroller/datascroller.cjs.min.js +1 -1
- package/datascroller/datascroller.esm.js +4 -3
- package/datascroller/datascroller.esm.min.js +1 -1
- package/datascroller/datascroller.js +12 -12
- package/datascroller/datascroller.min.js +1 -1
- package/datatable/datatable.cjs.js +600 -519
- package/datatable/datatable.cjs.min.js +1 -1
- package/datatable/datatable.d.ts +30 -14
- package/datatable/datatable.esm.js +321 -240
- package/datatable/datatable.esm.min.js +1 -1
- package/datatable/datatable.js +597 -520
- package/datatable/datatable.min.js +1 -1
- package/dataview/dataview.cjs.js +32 -29
- package/dataview/dataview.cjs.min.js +1 -1
- package/dataview/dataview.esm.js +6 -3
- package/dataview/dataview.esm.min.js +1 -1
- package/dataview/dataview.js +31 -30
- package/dataview/dataview.min.js +1 -1
- package/deferredcontent/deferredcontent.cjs.js +1 -1
- package/deferredcontent/deferredcontent.cjs.min.js +1 -1
- package/deferredcontent/deferredcontent.esm.min.js +1 -1
- package/deferredcontent/deferredcontent.js +2 -2
- package/deferredcontent/deferredcontent.min.js +1 -1
- package/dialog/dialog.cjs.js +60 -59
- package/dialog/dialog.cjs.min.js +1 -1
- package/dialog/dialog.d.ts +3 -1
- package/dialog/dialog.esm.js +13 -13
- package/dialog/dialog.esm.min.js +1 -1
- package/dialog/dialog.js +57 -60
- package/dialog/dialog.min.js +1 -1
- package/divider/divider.cjs.js +4 -4
- package/divider/divider.cjs.min.js +1 -1
- package/divider/divider.esm.js +1 -1
- package/divider/divider.esm.min.js +1 -1
- package/divider/divider.js +5 -5
- package/divider/divider.min.js +1 -1
- package/dock/dock.cjs.js +51 -17
- package/dock/dock.cjs.min.js +1 -1
- package/dock/dock.d.ts +13 -0
- package/dock/dock.esm.js +39 -5
- package/dock/dock.esm.min.js +1 -1
- package/dock/dock.js +51 -18
- package/dock/dock.min.css +1 -1
- package/dock/dock.min.js +1 -1
- package/dropdown/dropdown.cjs.js +99 -77
- package/dropdown/dropdown.cjs.min.js +1 -1
- package/dropdown/dropdown.d.ts +2 -1
- package/dropdown/dropdown.esm.js +37 -15
- package/dropdown/dropdown.esm.min.js +1 -1
- package/dropdown/dropdown.js +95 -78
- package/dropdown/dropdown.min.js +1 -1
- package/editor/editor.cjs.js +44 -42
- package/editor/editor.cjs.min.js +1 -1
- package/editor/editor.d.ts +1 -0
- package/editor/editor.esm.js +8 -4
- package/editor/editor.esm.min.js +1 -1
- package/editor/editor.js +43 -39
- package/editor/editor.min.js +1 -1
- package/fieldset/fieldset.cjs.js +17 -15
- package/fieldset/fieldset.cjs.min.js +1 -1
- package/fieldset/fieldset.d.ts +2 -1
- package/fieldset/fieldset.esm.js +3 -1
- package/fieldset/fieldset.esm.min.js +1 -1
- package/fieldset/fieldset.js +16 -16
- package/fieldset/fieldset.min.js +1 -1
- package/fileupload/fileupload.cjs.js +63 -56
- package/fileupload/fileupload.cjs.min.js +1 -1
- package/fileupload/fileupload.d.ts +2 -1
- package/fileupload/fileupload.esm.js +24 -17
- package/fileupload/fileupload.esm.min.js +1 -1
- package/fileupload/fileupload.js +63 -57
- package/fileupload/fileupload.min.js +1 -1
- package/fullcalendar/fullcalendar.cjs.js +6 -8
- package/fullcalendar/fullcalendar.cjs.min.js +1 -1
- package/fullcalendar/fullcalendar.esm.js +1 -1
- package/fullcalendar/fullcalendar.esm.min.js +1 -1
- package/fullcalendar/fullcalendar.js +5 -5
- package/fullcalendar/fullcalendar.min.js +1 -1
- package/galleria/galleria.cjs.js +71 -67
- package/galleria/galleria.cjs.min.js +1 -1
- package/galleria/galleria.d.ts +2 -1
- package/galleria/galleria.esm.js +7 -4
- package/galleria/galleria.esm.min.js +1 -1
- package/galleria/galleria.js +68 -68
- package/galleria/galleria.min.js +1 -1
- package/gmap/gmap.cjs.js +1 -1
- package/gmap/gmap.cjs.min.js +1 -1
- package/gmap/gmap.esm.min.js +1 -1
- package/gmap/gmap.js +2 -2
- package/gmap/gmap.min.js +1 -1
- package/image/image.cjs.js +31 -27
- package/image/image.cjs.min.js +1 -1
- package/image/image.d.ts +5 -5
- package/image/image.esm.js +5 -2
- package/image/image.esm.min.js +1 -1
- package/image/image.js +29 -28
- package/image/image.min.js +1 -1
- package/inplace/inplace.cjs.js +8 -8
- package/inplace/inplace.cjs.min.js +1 -1
- package/inplace/inplace.esm.js +1 -1
- package/inplace/inplace.esm.min.js +1 -1
- package/inplace/inplace.js +9 -9
- package/inplace/inplace.min.js +1 -1
- package/inputmask/inputmask.cjs.js +11 -10
- package/inputmask/inputmask.cjs.min.js +1 -1
- package/inputmask/inputmask.d.ts +1 -1
- package/inputmask/inputmask.esm.js +4 -3
- package/inputmask/inputmask.esm.min.js +1 -1
- package/inputmask/inputmask.js +11 -11
- package/inputmask/inputmask.min.js +1 -1
- package/inputnumber/inputnumber.cjs.js +58 -34
- package/inputnumber/inputnumber.cjs.min.js +1 -1
- package/inputnumber/inputnumber.d.ts +4 -4
- package/inputnumber/inputnumber.esm.js +41 -17
- package/inputnumber/inputnumber.esm.min.js +1 -1
- package/inputnumber/inputnumber.js +57 -35
- package/inputnumber/inputnumber.min.js +1 -1
- package/inputswitch/inputswitch.cjs.js +15 -12
- package/inputswitch/inputswitch.cjs.min.js +1 -1
- package/inputswitch/inputswitch.esm.js +8 -5
- package/inputswitch/inputswitch.esm.min.js +1 -1
- package/inputswitch/inputswitch.js +15 -13
- package/inputswitch/inputswitch.min.js +1 -1
- package/inputtext/inputtext.cjs.js +12 -10
- package/inputtext/inputtext.cjs.min.js +1 -1
- package/inputtext/inputtext.d.ts +1 -1
- package/inputtext/inputtext.esm.js +3 -1
- package/inputtext/inputtext.esm.min.js +1 -1
- package/inputtext/inputtext.js +11 -11
- package/inputtext/inputtext.min.css +1 -1
- package/inputtext/inputtext.min.js +1 -1
- package/inputtextarea/inputtextarea.cjs.js +10 -9
- package/inputtextarea/inputtextarea.cjs.min.js +1 -1
- package/inputtextarea/inputtextarea.d.ts +1 -1
- package/inputtextarea/inputtextarea.esm.js +2 -1
- package/inputtextarea/inputtextarea.esm.min.js +1 -1
- package/inputtextarea/inputtextarea.js +10 -10
- package/inputtextarea/inputtextarea.min.js +1 -1
- package/keyfilter/keyfilter.cjs.js +5 -5
- package/keyfilter/keyfilter.cjs.min.js +1 -1
- package/keyfilter/keyfilter.esm.js +1 -1
- package/keyfilter/keyfilter.esm.min.js +1 -1
- package/keyfilter/keyfilter.js +6 -6
- package/keyfilter/keyfilter.min.js +1 -1
- package/knob/knob.cjs.js +7 -7
- package/knob/knob.cjs.min.js +1 -1
- package/knob/knob.esm.js +1 -1
- package/knob/knob.esm.min.js +1 -1
- package/knob/knob.js +8 -8
- package/knob/knob.min.js +1 -1
- package/listbox/listbox.cjs.js +38 -36
- package/listbox/listbox.cjs.min.js +1 -1
- package/listbox/listbox.esm.js +3 -1
- package/listbox/listbox.esm.min.js +1 -1
- package/listbox/listbox.js +37 -37
- package/listbox/listbox.min.js +1 -1
- package/megamenu/megamenu.cjs.js +36 -35
- package/megamenu/megamenu.cjs.min.js +1 -1
- package/megamenu/megamenu.esm.js +2 -1
- package/megamenu/megamenu.esm.min.js +1 -1
- package/megamenu/megamenu.js +36 -36
- package/megamenu/megamenu.min.js +1 -1
- package/mention/mention.cjs.js +53 -46
- package/mention/mention.cjs.min.js +1 -1
- package/mention/mention.d.ts +2 -1
- package/mention/mention.esm.js +9 -3
- package/mention/mention.esm.min.js +1 -1
- package/mention/mention.js +48 -47
- package/mention/mention.min.js +1 -1
- package/menu/menu.cjs.js +33 -28
- package/menu/menu.cjs.min.js +1 -1
- package/menu/menu.d.ts +4 -1
- package/menu/menu.esm.js +7 -3
- package/menu/menu.esm.min.js +1 -1
- package/menu/menu.js +30 -29
- package/menu/menu.min.js +1 -1
- package/menubar/menubar.cjs.js +38 -35
- package/menubar/menubar.cjs.min.js +1 -1
- package/menubar/menubar.esm.js +4 -2
- package/menubar/menubar.esm.min.js +1 -1
- package/menubar/menubar.js +37 -36
- package/menubar/menubar.min.css +1 -1
- package/menubar/menubar.min.js +1 -1
- package/message/message.cjs.js +9 -8
- package/message/message.cjs.min.js +1 -1
- package/message/message.d.ts +3 -1
- package/message/message.esm.js +3 -2
- package/message/message.esm.min.js +1 -1
- package/message/message.js +10 -9
- package/message/message.min.js +1 -1
- package/messages/messages.cjs.js +19 -17
- package/messages/messages.cjs.min.js +1 -1
- package/messages/messages.d.ts +2 -1
- package/messages/messages.esm.js +3 -1
- package/messages/messages.esm.min.js +1 -1
- package/messages/messages.js +18 -18
- package/messages/messages.min.js +1 -1
- package/multiselect/multiselect.cjs.js +128 -116
- package/multiselect/multiselect.cjs.min.js +1 -1
- package/multiselect/multiselect.d.ts +5 -2
- package/multiselect/multiselect.esm.js +44 -32
- package/multiselect/multiselect.esm.min.js +1 -1
- package/multiselect/multiselect.js +124 -117
- package/multiselect/multiselect.min.js +1 -1
- package/multistatecheckbox/multistatecheckbox.cjs.js +14 -13
- package/multistatecheckbox/multistatecheckbox.cjs.min.js +1 -1
- package/multistatecheckbox/multistatecheckbox.d.ts +2 -1
- package/multistatecheckbox/multistatecheckbox.esm.js +2 -1
- package/multistatecheckbox/multistatecheckbox.esm.min.js +1 -1
- package/multistatecheckbox/multistatecheckbox.js +14 -14
- package/multistatecheckbox/multistatecheckbox.min.js +1 -1
- package/orderlist/orderlist.cjs.js +35 -34
- package/orderlist/orderlist.cjs.min.js +1 -1
- package/orderlist/orderlist.esm.js +2 -1
- package/orderlist/orderlist.esm.min.js +1 -1
- package/orderlist/orderlist.js +35 -35
- package/orderlist/orderlist.min.js +1 -1
- package/organizationchart/organizationchart.cjs.js +26 -26
- package/organizationchart/organizationchart.cjs.min.js +1 -1
- package/organizationchart/organizationchart.esm.js +1 -1
- package/organizationchart/organizationchart.esm.min.js +1 -1
- package/organizationchart/organizationchart.js +27 -27
- package/organizationchart/organizationchart.min.css +1 -1
- package/organizationchart/organizationchart.min.js +1 -1
- package/overlaypanel/overlaypanel.cjs.js +33 -30
- package/overlaypanel/overlaypanel.cjs.min.js +1 -1
- package/overlaypanel/overlaypanel.d.ts +3 -2
- package/overlaypanel/overlaypanel.esm.js +11 -9
- package/overlaypanel/overlaypanel.esm.min.js +1 -1
- package/overlaypanel/overlaypanel.js +29 -31
- package/overlaypanel/overlaypanel.min.js +1 -1
- package/overlayservice/overlayservice.cjs.js +2 -2
- package/overlayservice/overlayservice.cjs.min.js +1 -1
- package/overlayservice/overlayservice.esm.js +1 -1
- package/overlayservice/overlayservice.esm.min.js +1 -1
- package/overlayservice/overlayservice.js +3 -3
- package/overlayservice/overlayservice.min.js +1 -1
- package/package.json +11 -4
- package/paginator/paginator.cjs.js +48 -47
- package/paginator/paginator.cjs.min.js +1 -1
- package/paginator/paginator.esm.js +2 -1
- package/paginator/paginator.esm.min.js +1 -1
- package/paginator/paginator.js +48 -48
- package/paginator/paginator.min.js +1 -1
- package/panel/panel.cjs.js +21 -18
- package/panel/panel.cjs.min.js +1 -1
- package/panel/panel.d.ts +5 -3
- package/panel/panel.esm.js +6 -3
- package/panel/panel.esm.min.js +1 -1
- package/panel/panel.js +20 -19
- package/panel/panel.min.js +1 -1
- package/panelmenu/panelmenu.cjs.js +40 -39
- package/panelmenu/panelmenu.cjs.min.js +1 -1
- package/panelmenu/panelmenu.d.ts +2 -1
- package/panelmenu/panelmenu.esm.js +2 -1
- package/panelmenu/panelmenu.esm.min.js +1 -1
- package/panelmenu/panelmenu.js +40 -40
- package/panelmenu/panelmenu.min.js +1 -1
- package/password/password.cjs.js +33 -29
- package/password/password.cjs.min.js +1 -1
- package/password/password.d.ts +3 -2
- package/password/password.esm.js +7 -3
- package/password/password.esm.min.js +1 -1
- package/password/password.js +30 -30
- package/password/password.min.js +1 -1
- package/picklist/picklist.cjs.js +58 -54
- package/picklist/picklist.cjs.min.js +1 -1
- package/picklist/picklist.esm.js +14 -10
- package/picklist/picklist.esm.min.js +1 -1
- package/picklist/picklist.js +58 -55
- package/picklist/picklist.min.js +1 -1
- package/portal/portal.cjs.js +4 -8
- package/portal/portal.cjs.min.js +1 -1
- package/portal/portal.esm.js +2 -6
- package/portal/portal.esm.min.js +1 -1
- package/portal/portal.js +5 -10
- package/portal/portal.min.js +1 -1
- package/primereact.all.cjs.js +3168 -2524
- package/primereact.all.cjs.min.js +1 -1
- package/primereact.all.esm.js +1939 -1294
- package/primereact.all.esm.min.js +1 -1
- package/primereact.all.js +3167 -2521
- package/primereact.all.min.js +1 -1
- package/progressbar/progressbar.cjs.js +9 -9
- package/progressbar/progressbar.cjs.min.js +1 -1
- package/progressbar/progressbar.esm.js +1 -1
- package/progressbar/progressbar.esm.min.js +1 -1
- package/progressbar/progressbar.js +10 -10
- package/progressbar/progressbar.min.js +1 -1
- package/progressspinner/progressspinner.cjs.js +5 -5
- package/progressspinner/progressspinner.cjs.min.js +1 -1
- package/progressspinner/progressspinner.esm.js +1 -1
- package/progressspinner/progressspinner.esm.min.js +1 -1
- package/progressspinner/progressspinner.js +6 -6
- package/progressspinner/progressspinner.min.js +1 -1
- package/radiobutton/radiobutton.cjs.js +10 -9
- package/radiobutton/radiobutton.cjs.min.js +1 -1
- package/radiobutton/radiobutton.esm.js +2 -1
- package/radiobutton/radiobutton.esm.min.js +1 -1
- package/radiobutton/radiobutton.js +10 -10
- package/radiobutton/radiobutton.min.js +1 -1
- package/rating/rating.cjs.js +10 -9
- package/rating/rating.cjs.min.js +1 -1
- package/rating/rating.esm.js +4 -3
- package/rating/rating.esm.min.js +1 -1
- package/rating/rating.js +10 -10
- package/rating/rating.min.js +1 -1
- package/resources/primereact.css +484 -431
- package/resources/primereact.min.css +1 -1
- package/resources/themes/arya-blue/theme.css +38 -18
- package/resources/themes/arya-green/theme.css +38 -18
- package/resources/themes/arya-orange/theme.css +38 -18
- package/resources/themes/arya-purple/theme.css +38 -18
- package/resources/themes/bootstrap4-dark-blue/theme.css +42 -22
- package/resources/themes/bootstrap4-dark-purple/theme.css +42 -22
- package/resources/themes/bootstrap4-light-blue/theme.css +42 -22
- package/resources/themes/bootstrap4-light-purple/theme.css +42 -22
- package/resources/themes/fluent-light/theme.css +38 -18
- package/resources/themes/lara-dark-blue/fonts/Inter-Bold.woff +0 -0
- package/resources/themes/lara-dark-blue/fonts/Inter-Bold.woff2 +0 -0
- package/resources/themes/lara-dark-blue/fonts/Inter-Light.woff +0 -0
- package/resources/themes/lara-dark-blue/fonts/Inter-Light.woff2 +0 -0
- package/resources/themes/lara-dark-blue/fonts/Inter-Medium.woff +0 -0
- package/resources/themes/lara-dark-blue/fonts/Inter-Medium.woff2 +0 -0
- package/resources/themes/lara-dark-blue/fonts/Inter-Regular.woff +0 -0
- package/resources/themes/lara-dark-blue/fonts/Inter-Regular.woff2 +0 -0
- package/resources/themes/lara-dark-blue/fonts/Inter-SemiBold.woff +0 -0
- package/resources/themes/lara-dark-blue/fonts/Inter-SemiBold.woff2 +0 -0
- package/resources/themes/lara-dark-blue/theme.css +5675 -0
- package/resources/themes/lara-dark-indigo/fonts/Inter-Bold.woff +0 -0
- package/resources/themes/lara-dark-indigo/fonts/Inter-Bold.woff2 +0 -0
- package/resources/themes/lara-dark-indigo/fonts/Inter-Light.woff +0 -0
- package/resources/themes/lara-dark-indigo/fonts/Inter-Light.woff2 +0 -0
- package/resources/themes/lara-dark-indigo/fonts/Inter-Medium.woff +0 -0
- package/resources/themes/lara-dark-indigo/fonts/Inter-Medium.woff2 +0 -0
- package/resources/themes/lara-dark-indigo/fonts/Inter-Regular.woff +0 -0
- package/resources/themes/lara-dark-indigo/fonts/Inter-Regular.woff2 +0 -0
- package/resources/themes/lara-dark-indigo/fonts/Inter-SemiBold.woff +0 -0
- package/resources/themes/lara-dark-indigo/fonts/Inter-SemiBold.woff2 +0 -0
- package/resources/themes/lara-dark-indigo/theme.css +5675 -0
- package/resources/themes/lara-dark-purple/fonts/Inter-Bold.woff +0 -0
- package/resources/themes/lara-dark-purple/fonts/Inter-Bold.woff2 +0 -0
- package/resources/themes/lara-dark-purple/fonts/Inter-Light.woff +0 -0
- package/resources/themes/lara-dark-purple/fonts/Inter-Light.woff2 +0 -0
- package/resources/themes/lara-dark-purple/fonts/Inter-Medium.woff +0 -0
- package/resources/themes/lara-dark-purple/fonts/Inter-Medium.woff2 +0 -0
- package/resources/themes/lara-dark-purple/fonts/Inter-Regular.woff +0 -0
- package/resources/themes/lara-dark-purple/fonts/Inter-Regular.woff2 +0 -0
- package/resources/themes/lara-dark-purple/fonts/Inter-SemiBold.woff +0 -0
- package/resources/themes/lara-dark-purple/fonts/Inter-SemiBold.woff2 +0 -0
- package/resources/themes/lara-dark-purple/theme.css +5675 -0
- package/resources/themes/lara-dark-teal/fonts/Inter-Bold.woff +0 -0
- package/resources/themes/lara-dark-teal/fonts/Inter-Bold.woff2 +0 -0
- package/resources/themes/lara-dark-teal/fonts/Inter-Light.woff +0 -0
- package/resources/themes/lara-dark-teal/fonts/Inter-Light.woff2 +0 -0
- package/resources/themes/lara-dark-teal/fonts/Inter-Medium.woff +0 -0
- package/resources/themes/lara-dark-teal/fonts/Inter-Medium.woff2 +0 -0
- package/resources/themes/lara-dark-teal/fonts/Inter-Regular.woff +0 -0
- package/resources/themes/lara-dark-teal/fonts/Inter-Regular.woff2 +0 -0
- package/resources/themes/lara-dark-teal/fonts/Inter-SemiBold.woff +0 -0
- package/resources/themes/lara-dark-teal/fonts/Inter-SemiBold.woff2 +0 -0
- package/resources/themes/lara-dark-teal/theme.css +5675 -0
- package/resources/themes/lara-light-blue/fonts/Inter-Bold.woff +0 -0
- package/resources/themes/lara-light-blue/fonts/Inter-Bold.woff2 +0 -0
- package/resources/themes/lara-light-blue/fonts/Inter-Light.woff +0 -0
- package/resources/themes/lara-light-blue/fonts/Inter-Light.woff2 +0 -0
- package/resources/themes/lara-light-blue/fonts/Inter-Medium.woff +0 -0
- package/resources/themes/lara-light-blue/fonts/Inter-Medium.woff2 +0 -0
- package/resources/themes/lara-light-blue/fonts/Inter-Regular.woff +0 -0
- package/resources/themes/lara-light-blue/fonts/Inter-Regular.woff2 +0 -0
- package/resources/themes/lara-light-blue/fonts/Inter-SemiBold.woff +0 -0
- package/resources/themes/lara-light-blue/fonts/Inter-SemiBold.woff2 +0 -0
- package/resources/themes/lara-light-blue/theme.css +5675 -0
- package/resources/themes/lara-light-indigo/fonts/Inter-Bold.woff +0 -0
- package/resources/themes/lara-light-indigo/fonts/Inter-Bold.woff2 +0 -0
- package/resources/themes/lara-light-indigo/fonts/Inter-Light.woff +0 -0
- package/resources/themes/lara-light-indigo/fonts/Inter-Light.woff2 +0 -0
- package/resources/themes/lara-light-indigo/fonts/Inter-Medium.woff +0 -0
- package/resources/themes/lara-light-indigo/fonts/Inter-Medium.woff2 +0 -0
- package/resources/themes/lara-light-indigo/fonts/Inter-Regular.woff +0 -0
- package/resources/themes/lara-light-indigo/fonts/Inter-Regular.woff2 +0 -0
- package/resources/themes/lara-light-indigo/fonts/Inter-SemiBold.woff +0 -0
- package/resources/themes/lara-light-indigo/fonts/Inter-SemiBold.woff2 +0 -0
- package/resources/themes/lara-light-indigo/theme.css +5675 -0
- package/resources/themes/lara-light-purple/fonts/Inter-Bold.woff +0 -0
- package/resources/themes/lara-light-purple/fonts/Inter-Bold.woff2 +0 -0
- package/resources/themes/lara-light-purple/fonts/Inter-Light.woff +0 -0
- package/resources/themes/lara-light-purple/fonts/Inter-Light.woff2 +0 -0
- package/resources/themes/lara-light-purple/fonts/Inter-Medium.woff +0 -0
- package/resources/themes/lara-light-purple/fonts/Inter-Medium.woff2 +0 -0
- package/resources/themes/lara-light-purple/fonts/Inter-Regular.woff +0 -0
- package/resources/themes/lara-light-purple/fonts/Inter-Regular.woff2 +0 -0
- package/resources/themes/lara-light-purple/fonts/Inter-SemiBold.woff +0 -0
- package/resources/themes/lara-light-purple/fonts/Inter-SemiBold.woff2 +0 -0
- package/resources/themes/lara-light-purple/theme.css +5675 -0
- package/resources/themes/lara-light-teal/fonts/Inter-Bold.woff +0 -0
- package/resources/themes/lara-light-teal/fonts/Inter-Bold.woff2 +0 -0
- package/resources/themes/lara-light-teal/fonts/Inter-Light.woff +0 -0
- package/resources/themes/lara-light-teal/fonts/Inter-Light.woff2 +0 -0
- package/resources/themes/lara-light-teal/fonts/Inter-Medium.woff +0 -0
- package/resources/themes/lara-light-teal/fonts/Inter-Medium.woff2 +0 -0
- package/resources/themes/lara-light-teal/fonts/Inter-Regular.woff +0 -0
- package/resources/themes/lara-light-teal/fonts/Inter-Regular.woff2 +0 -0
- package/resources/themes/lara-light-teal/fonts/Inter-SemiBold.woff +0 -0
- package/resources/themes/lara-light-teal/fonts/Inter-SemiBold.woff2 +0 -0
- package/resources/themes/lara-light-teal/theme.css +5675 -0
- package/resources/themes/luna-amber/theme.css +42 -22
- package/resources/themes/luna-blue/theme.css +42 -22
- package/resources/themes/luna-green/theme.css +42 -22
- package/resources/themes/luna-pink/theme.css +42 -22
- package/resources/themes/md-dark-deeppurple/theme.css +227 -47
- package/resources/themes/md-dark-indigo/theme.css +227 -47
- package/resources/themes/md-light-deeppurple/theme.css +227 -47
- package/resources/themes/md-light-indigo/theme.css +227 -47
- package/resources/themes/mdc-dark-deeppurple/theme.css +227 -47
- package/resources/themes/mdc-dark-indigo/theme.css +227 -47
- package/resources/themes/mdc-light-deeppurple/theme.css +227 -47
- package/resources/themes/mdc-light-indigo/theme.css +227 -47
- package/resources/themes/nova/theme.css +42 -22
- package/resources/themes/nova-accent/theme.css +42 -22
- package/resources/themes/nova-alt/theme.css +42 -22
- package/resources/themes/rhea/theme.css +42 -22
- package/resources/themes/saga-blue/theme.css +38 -18
- package/resources/themes/saga-green/theme.css +38 -18
- package/resources/themes/saga-orange/theme.css +38 -18
- package/resources/themes/saga-purple/theme.css +38 -18
- package/resources/themes/tailwind-light/theme.css +42 -22
- package/resources/themes/vela-blue/theme.css +38 -18
- package/resources/themes/vela-green/theme.css +38 -18
- package/resources/themes/vela-orange/theme.css +38 -18
- package/resources/themes/vela-purple/theme.css +38 -18
- package/ripple/ripple.cjs.js +11 -11
- package/ripple/ripple.cjs.min.js +1 -1
- package/ripple/ripple.esm.js +3 -3
- package/ripple/ripple.esm.min.js +1 -1
- package/ripple/ripple.js +12 -12
- package/ripple/ripple.min.js +1 -1
- package/row/row.cjs.js +1 -1
- package/row/row.cjs.min.js +1 -1
- package/row/row.esm.min.js +1 -1
- package/row/row.js +2 -2
- package/row/row.min.js +1 -1
- package/scrollpanel/scrollpanel.cjs.js +19 -19
- package/scrollpanel/scrollpanel.cjs.min.js +1 -1
- package/scrollpanel/scrollpanel.esm.js +1 -1
- package/scrollpanel/scrollpanel.esm.min.js +1 -1
- package/scrollpanel/scrollpanel.js +20 -20
- package/scrollpanel/scrollpanel.min.js +1 -1
- package/scrolltop/scrolltop.cjs.js +18 -13
- package/scrolltop/scrolltop.cjs.min.js +1 -1
- package/scrolltop/scrolltop.d.ts +4 -2
- package/scrolltop/scrolltop.esm.js +9 -5
- package/scrolltop/scrolltop.esm.min.js +1 -1
- package/scrolltop/scrolltop.js +16 -14
- package/scrolltop/scrolltop.min.js +1 -1
- package/selectbutton/selectbutton.cjs.js +17 -15
- package/selectbutton/selectbutton.cjs.min.js +1 -1
- package/selectbutton/selectbutton.esm.js +3 -1
- package/selectbutton/selectbutton.esm.min.js +1 -1
- package/selectbutton/selectbutton.js +16 -16
- package/selectbutton/selectbutton.min.js +1 -1
- package/selectitem/selectitem.d.ts +3 -1
- package/sidebar/sidebar.cjs.js +142 -116
- package/sidebar/sidebar.cjs.min.js +1 -1
- package/sidebar/sidebar.d.ts +4 -1
- package/sidebar/sidebar.esm.js +133 -108
- package/sidebar/sidebar.esm.min.js +1 -1
- package/sidebar/sidebar.js +139 -117
- package/sidebar/sidebar.min.css +1 -1
- package/sidebar/sidebar.min.js +1 -1
- package/skeleton/skeleton.cjs.js +3 -3
- package/skeleton/skeleton.cjs.min.js +1 -1
- package/skeleton/skeleton.esm.js +1 -1
- package/skeleton/skeleton.esm.min.js +1 -1
- package/skeleton/skeleton.js +4 -4
- package/skeleton/skeleton.min.js +1 -1
- package/slidemenu/slidemenu.cjs.js +37 -32
- package/slidemenu/slidemenu.cjs.min.js +1 -1
- package/slidemenu/slidemenu.d.ts +2 -1
- package/slidemenu/slidemenu.esm.js +7 -3
- package/slidemenu/slidemenu.esm.min.js +1 -1
- package/slidemenu/slidemenu.js +34 -33
- package/slidemenu/slidemenu.min.js +1 -1
- package/slider/slider.cjs.js +29 -19
- package/slider/slider.cjs.min.js +1 -1
- package/slider/slider.esm.js +21 -11
- package/slider/slider.esm.min.js +1 -1
- package/slider/slider.js +30 -20
- package/slider/slider.min.js +1 -1
- package/speeddial/speeddial.cjs.js +20 -19
- package/speeddial/speeddial.cjs.min.js +1 -1
- package/speeddial/speeddial.d.ts +3 -2
- package/speeddial/speeddial.esm.js +2 -1
- package/speeddial/speeddial.esm.min.js +1 -1
- package/speeddial/speeddial.js +20 -20
- package/speeddial/speeddial.min.js +1 -1
- package/splitbutton/splitbutton.cjs.js +43 -35
- package/splitbutton/splitbutton.cjs.min.js +1 -1
- package/splitbutton/splitbutton.d.ts +8 -6
- package/splitbutton/splitbutton.esm.js +13 -5
- package/splitbutton/splitbutton.esm.min.js +1 -1
- package/splitbutton/splitbutton.js +40 -36
- package/splitbutton/splitbutton.min.js +1 -1
- package/splitter/splitter.cjs.js +19 -19
- package/splitter/splitter.cjs.min.js +1 -1
- package/splitter/splitter.esm.js +2 -2
- package/splitter/splitter.esm.min.js +1 -1
- package/splitter/splitter.js +20 -20
- package/splitter/splitter.min.js +1 -1
- package/steps/steps.cjs.js +10 -10
- package/steps/steps.cjs.min.js +1 -1
- package/steps/steps.esm.js +1 -1
- package/steps/steps.esm.min.js +1 -1
- package/steps/steps.js +11 -11
- package/steps/steps.min.js +1 -1
- package/styleclass/styleclass.cjs.js +17 -17
- package/styleclass/styleclass.cjs.min.js +1 -1
- package/styleclass/styleclass.esm.js +1 -1
- package/styleclass/styleclass.esm.min.js +1 -1
- package/styleclass/styleclass.js +18 -18
- package/styleclass/styleclass.min.js +1 -1
- package/tabmenu/tabmenu.cjs.js +16 -15
- package/tabmenu/tabmenu.cjs.min.js +1 -1
- package/tabmenu/tabmenu.esm.js +2 -1
- package/tabmenu/tabmenu.esm.min.js +1 -1
- package/tabmenu/tabmenu.js +16 -16
- package/tabmenu/tabmenu.min.js +1 -1
- package/tabview/tabview.cjs.js +195 -57
- package/tabview/tabview.cjs.min.js +1 -1
- package/tabview/tabview.d.ts +12 -1
- package/tabview/tabview.esm.js +165 -27
- package/tabview/tabview.esm.min.js +1 -1
- package/tabview/tabview.js +195 -58
- package/tabview/tabview.min.css +1 -1
- package/tabview/tabview.min.js +1 -1
- package/tag/tag.cjs.js +9 -8
- package/tag/tag.cjs.min.js +1 -1
- package/tag/tag.d.ts +2 -1
- package/tag/tag.esm.js +5 -4
- package/tag/tag.esm.min.js +1 -1
- package/tag/tag.js +10 -9
- package/tag/tag.min.js +1 -1
- package/terminal/terminal.cjs.js +12 -12
- package/terminal/terminal.cjs.min.js +1 -1
- package/terminal/terminal.esm.js +1 -1
- package/terminal/terminal.esm.min.js +1 -1
- package/terminal/terminal.js +13 -13
- package/terminal/terminal.min.js +1 -1
- package/terminalservice/terminalservice.cjs.js +2 -2
- package/terminalservice/terminalservice.cjs.min.js +1 -1
- package/terminalservice/terminalservice.esm.js +1 -1
- package/terminalservice/terminalservice.esm.min.js +1 -1
- package/terminalservice/terminalservice.js +3 -3
- package/terminalservice/terminalservice.min.js +1 -1
- package/tieredmenu/tieredmenu.cjs.js +42 -36
- package/tieredmenu/tieredmenu.cjs.min.js +1 -1
- package/tieredmenu/tieredmenu.d.ts +2 -1
- package/tieredmenu/tieredmenu.esm.js +8 -3
- package/tieredmenu/tieredmenu.esm.min.js +1 -1
- package/tieredmenu/tieredmenu.js +38 -37
- package/tieredmenu/tieredmenu.min.js +1 -1
- package/timeline/timeline.cjs.js +12 -12
- package/timeline/timeline.cjs.min.js +1 -1
- package/timeline/timeline.esm.js +1 -1
- package/timeline/timeline.esm.min.js +1 -1
- package/timeline/timeline.js +13 -13
- package/timeline/timeline.min.js +1 -1
- package/toast/toast.cjs.js +46 -40
- package/toast/toast.cjs.min.js +1 -1
- package/toast/toast.d.ts +2 -1
- package/toast/toast.esm.js +20 -15
- package/toast/toast.esm.min.js +1 -1
- package/toast/toast.js +44 -41
- package/toast/toast.min.js +1 -1
- package/togglebutton/togglebutton.cjs.js +14 -9
- package/togglebutton/togglebutton.cjs.min.js +1 -1
- package/togglebutton/togglebutton.d.ts +3 -2
- package/togglebutton/togglebutton.esm.js +8 -3
- package/togglebutton/togglebutton.esm.min.js +1 -1
- package/togglebutton/togglebutton.js +13 -10
- package/togglebutton/togglebutton.min.js +1 -1
- package/toolbar/toolbar.cjs.js +7 -7
- package/toolbar/toolbar.cjs.min.js +1 -1
- package/toolbar/toolbar.esm.js +1 -1
- package/toolbar/toolbar.esm.min.js +1 -1
- package/toolbar/toolbar.js +8 -8
- package/toolbar/toolbar.min.js +1 -1
- package/tooltip/tooltip.cjs.js +65 -36
- package/tooltip/tooltip.cjs.min.js +1 -1
- package/tooltip/tooltip.d.ts +0 -1
- package/tooltip/tooltip.esm.js +36 -8
- package/tooltip/tooltip.esm.min.js +1 -1
- package/tooltip/tooltip.js +64 -37
- package/tooltip/tooltip.min.css +1 -1
- package/tooltip/tooltip.min.js +1 -1
- package/tooltip/tooltipoptions.d.ts +2 -0
- package/tree/tree.cjs.js +52 -51
- package/tree/tree.cjs.min.js +1 -1
- package/tree/tree.d.ts +14 -3
- package/tree/tree.esm.js +2 -1
- package/tree/tree.esm.min.js +1 -1
- package/tree/tree.js +52 -52
- package/tree/tree.min.js +1 -1
- package/treenode/treenode.d.ts +3 -1
- package/treeselect/treeselect.cjs.js +50 -46
- package/treeselect/treeselect.cjs.min.js +1 -1
- package/treeselect/treeselect.d.ts +11 -3
- package/treeselect/treeselect.esm.js +10 -6
- package/treeselect/treeselect.esm.min.js +1 -1
- package/treeselect/treeselect.js +47 -47
- package/treeselect/treeselect.min.js +1 -1
- package/treetable/treetable.cjs.js +1363 -312
- package/treetable/treetable.cjs.min.js +1 -1
- package/treetable/treetable.d.ts +10 -3
- package/treetable/treetable.esm.js +1267 -216
- package/treetable/treetable.esm.min.js +1 -1
- package/treetable/treetable.js +1362 -313
- package/treetable/treetable.min.js +1 -1
- package/tristatecheckbox/tristatecheckbox.cjs.js +11 -10
- package/tristatecheckbox/tristatecheckbox.cjs.min.js +1 -1
- package/tristatecheckbox/tristatecheckbox.esm.js +2 -1
- package/tristatecheckbox/tristatecheckbox.esm.min.js +1 -1
- package/tristatecheckbox/tristatecheckbox.js +11 -11
- package/tristatecheckbox/tristatecheckbox.min.js +1 -1
- package/utils/utils.cjs.js +154 -33
- package/utils/utils.cjs.min.js +1 -1
- package/utils/utils.d.ts +17 -0
- package/utils/utils.esm.js +153 -33
- package/utils/utils.esm.min.js +1 -1
- package/utils/utils.js +155 -34
- package/utils/utils.min.js +1 -1
- package/virtualscroller/virtualscroller.cjs.js +44 -34
- package/virtualscroller/virtualscroller.cjs.min.js +1 -1
- package/virtualscroller/virtualscroller.esm.js +29 -19
- package/virtualscroller/virtualscroller.esm.min.js +1 -1
- package/virtualscroller/virtualscroller.js +45 -35
- package/virtualscroller/virtualscroller.min.js +1 -1
- package/web-types.json +2 -2
- package/core/core.cjs.js +0 -2987
- package/core/core.cjs.min.js +0 -1
- package/core/core.esm.js +0 -2963
- package/core/core.esm.min.js +0 -1
- package/core/package.json +0 -5
- package/util.d.ts +0 -1
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
import React, { Component } from 'react';
|
|
2
2
|
import { Paginator } from 'primereact/paginator';
|
|
3
|
-
import { classNames, ObjectUtils,
|
|
3
|
+
import { classNames, ObjectUtils, DomHandler, ZIndexUtils, ConnectedOverlayScrollHandler, UniqueComponentId } from 'primereact/utils';
|
|
4
4
|
import PrimeReact, { localeOption, FilterOperator, FilterMatchMode as FilterMatchMode$1, FilterService } from 'primereact/api';
|
|
5
|
+
import { OverlayService } from 'primereact/overlayservice';
|
|
6
|
+
import { Ripple } from 'primereact/ripple';
|
|
7
|
+
import { CSSTransition } from 'primereact/csstransition';
|
|
8
|
+
import { Portal } from 'primereact/portal';
|
|
5
9
|
import { InputText } from 'primereact/inputtext';
|
|
6
10
|
import { Dropdown } from 'primereact/dropdown';
|
|
7
11
|
import { Button } from 'primereact/button';
|
|
@@ -612,6 +616,8 @@ var BodyCell = /*#__PURE__*/function (_Component) {
|
|
|
612
616
|
}
|
|
613
617
|
|
|
614
618
|
this.closeCell(event);
|
|
619
|
+
} else {
|
|
620
|
+
event.preventDefault();
|
|
615
621
|
}
|
|
616
622
|
}
|
|
617
623
|
}, {
|
|
@@ -848,13 +854,16 @@ var BodyCell = /*#__PURE__*/function (_Component) {
|
|
|
848
854
|
|
|
849
855
|
case 13:
|
|
850
856
|
// @deprecated
|
|
851
|
-
|
|
852
|
-
|
|
857
|
+
if (!DomHandler.isClickable(target)) {
|
|
858
|
+
this.onClick(event);
|
|
859
|
+
event.preventDefault();
|
|
860
|
+
}
|
|
861
|
+
|
|
853
862
|
break;
|
|
854
863
|
//space
|
|
855
864
|
|
|
856
865
|
case 32:
|
|
857
|
-
if (
|
|
866
|
+
if (!DomHandler.isClickable(target) && !target.readOnly) {
|
|
858
867
|
this.onClick(event);
|
|
859
868
|
event.preventDefault();
|
|
860
869
|
}
|
|
@@ -1041,28 +1050,9 @@ var BodyCell = /*#__PURE__*/function (_Component) {
|
|
|
1041
1050
|
props: this.props.tableProps
|
|
1042
1051
|
}));
|
|
1043
1052
|
|
|
1044
|
-
if (
|
|
1045
|
-
content = body ? ObjectUtils.getJSXElement(body, this.props.rowData, {
|
|
1046
|
-
column: this.props.column,
|
|
1047
|
-
field: this.field,
|
|
1048
|
-
rowIndex: this.props.rowIndex,
|
|
1049
|
-
frozenRow: this.props.frozenRow,
|
|
1050
|
-
props: this.props.tableProps
|
|
1051
|
-
}) : value;
|
|
1052
|
-
} else if (editor && this.state.editing) {
|
|
1053
|
-
content = ObjectUtils.getJSXElement(editor, {
|
|
1054
|
-
rowData: this.state.editingRowData,
|
|
1055
|
-
value: this.resolveFieldData(this.state.editingRowData),
|
|
1056
|
-
column: this.props.column,
|
|
1057
|
-
field: this.field,
|
|
1058
|
-
rowIndex: this.props.rowIndex,
|
|
1059
|
-
frozenRow: this.props.frozenRow,
|
|
1060
|
-
props: this.props.tableProps,
|
|
1061
|
-
editorCallback: this.editorCallback
|
|
1062
|
-
});
|
|
1063
|
-
} else if (selectionMode) {
|
|
1053
|
+
if (selectionMode) {
|
|
1064
1054
|
var showSelection = this.props.showSelectionElement ? this.props.showSelectionElement(this.props.rowData, {
|
|
1065
|
-
|
|
1055
|
+
rowIndex: this.props.rowIndex,
|
|
1066
1056
|
props: this.props.tableProps
|
|
1067
1057
|
}) : true;
|
|
1068
1058
|
content = showSelection && /*#__PURE__*/React.createElement(React.Fragment, null, selectionMode === 'single' && /*#__PURE__*/React.createElement(RowRadioButton, {
|
|
@@ -1079,7 +1069,7 @@ var BodyCell = /*#__PURE__*/function (_Component) {
|
|
|
1079
1069
|
}));
|
|
1080
1070
|
} else if (rowReorder) {
|
|
1081
1071
|
var showReorder = this.props.showRowReorderElement ? this.props.showRowReorderElement(this.props.rowData, {
|
|
1082
|
-
|
|
1072
|
+
rowIndex: this.props.rowIndex,
|
|
1083
1073
|
props: this.props.tableProps
|
|
1084
1074
|
}) : true;
|
|
1085
1075
|
content = showReorder && /*#__PURE__*/React.createElement("i", {
|
|
@@ -1109,8 +1099,9 @@ var BodyCell = /*#__PURE__*/function (_Component) {
|
|
|
1109
1099
|
content = ObjectUtils.getJSXElement(body, this.props.rowData, {
|
|
1110
1100
|
column: this.props.column,
|
|
1111
1101
|
field: this.field,
|
|
1112
|
-
|
|
1102
|
+
rowIndex: this.props.rowIndex,
|
|
1113
1103
|
frozenRow: this.props.frozenRow,
|
|
1104
|
+
props: this.props.tableProps,
|
|
1114
1105
|
expander: expanderProps
|
|
1115
1106
|
});
|
|
1116
1107
|
}
|
|
@@ -1164,11 +1155,31 @@ var BodyCell = /*#__PURE__*/function (_Component) {
|
|
|
1164
1155
|
content = ObjectUtils.getJSXElement(body, this.props.rowData, {
|
|
1165
1156
|
column: this.props.column,
|
|
1166
1157
|
field: this.field,
|
|
1167
|
-
|
|
1158
|
+
rowIndex: this.props.rowIndex,
|
|
1168
1159
|
frozenRow: this.props.frozenRow,
|
|
1160
|
+
props: this.props.tableProps,
|
|
1169
1161
|
rowEditor: rowEditorProps
|
|
1170
1162
|
});
|
|
1171
1163
|
}
|
|
1164
|
+
} else if (body && !this.state.editing) {
|
|
1165
|
+
content = body ? ObjectUtils.getJSXElement(body, this.props.rowData, {
|
|
1166
|
+
column: this.props.column,
|
|
1167
|
+
field: this.field,
|
|
1168
|
+
rowIndex: this.props.rowIndex,
|
|
1169
|
+
frozenRow: this.props.frozenRow,
|
|
1170
|
+
props: this.props.tableProps
|
|
1171
|
+
}) : value;
|
|
1172
|
+
} else if (editor && this.state.editing) {
|
|
1173
|
+
content = ObjectUtils.getJSXElement(editor, {
|
|
1174
|
+
rowData: this.state.editingRowData,
|
|
1175
|
+
value: this.resolveFieldData(this.state.editingRowData),
|
|
1176
|
+
column: this.props.column,
|
|
1177
|
+
field: this.field,
|
|
1178
|
+
rowIndex: this.props.rowIndex,
|
|
1179
|
+
frozenRow: this.props.frozenRow,
|
|
1180
|
+
props: this.props.tableProps,
|
|
1181
|
+
editorCallback: this.editorCallback
|
|
1182
|
+
});
|
|
1172
1183
|
} else {
|
|
1173
1184
|
content = value;
|
|
1174
1185
|
}
|
|
@@ -1437,13 +1448,16 @@ var BodyRow = /*#__PURE__*/function (_Component) {
|
|
|
1437
1448
|
|
|
1438
1449
|
case 13:
|
|
1439
1450
|
// @deprecated
|
|
1440
|
-
|
|
1441
|
-
|
|
1451
|
+
if (!DomHandler.isClickable(target)) {
|
|
1452
|
+
this.onClick(event);
|
|
1453
|
+
event.preventDefault();
|
|
1454
|
+
}
|
|
1455
|
+
|
|
1442
1456
|
break;
|
|
1443
1457
|
//space
|
|
1444
1458
|
|
|
1445
1459
|
case 32:
|
|
1446
|
-
if (
|
|
1460
|
+
if (!DomHandler.isClickable(target) && !target.readOnly) {
|
|
1447
1461
|
this.onClick(event);
|
|
1448
1462
|
event.preventDefault();
|
|
1449
1463
|
}
|
|
@@ -1809,7 +1823,7 @@ var TableBody = /*#__PURE__*/function (_Component) {
|
|
|
1809
1823
|
}, {
|
|
1810
1824
|
key: "equals",
|
|
1811
1825
|
value: function equals(data1, data2) {
|
|
1812
|
-
if (this.allowCellSelection()) return (data1.rowIndex === data2.rowIndex || data1.rowData === data2.rowData) && (data1.field === data2.field || data1.cellIndex === data2.cellIndex);else return this.compareSelectionBy === 'equals' ? data1 === data2 : ObjectUtils.equals(data1, data2, this.props.dataKey);
|
|
1826
|
+
if (this.allowCellSelection()) return (data1.rowIndex === data2.rowIndex || data1.rowData === data2.rowData) && (data1.field === data2.field || data1.cellIndex === data2.cellIndex);else return this.props.compareSelectionBy === 'equals' ? data1 === data2 : ObjectUtils.equals(data1, data2, this.props.dataKey);
|
|
1813
1827
|
}
|
|
1814
1828
|
}, {
|
|
1815
1829
|
key: "isSubheaderGrouping",
|
|
@@ -2039,6 +2053,12 @@ var TableBody = /*#__PURE__*/function (_Component) {
|
|
|
2039
2053
|
});
|
|
2040
2054
|
}
|
|
2041
2055
|
}
|
|
2056
|
+
}, {
|
|
2057
|
+
key: "updateVirtualScrollerPosition",
|
|
2058
|
+
value: function updateVirtualScrollerPosition() {
|
|
2059
|
+
var tableHeaderHeight = DomHandler.getOuterHeight(this.el.previousElementSibling);
|
|
2060
|
+
this.el.style.top = (this.el.style.top || 0) + tableHeaderHeight + 'px';
|
|
2061
|
+
}
|
|
2042
2062
|
}, {
|
|
2043
2063
|
key: "onSingleSelection",
|
|
2044
2064
|
value: function onSingleSelection(_ref) {
|
|
@@ -2072,7 +2092,8 @@ var TableBody = /*#__PURE__*/function (_Component) {
|
|
|
2072
2092
|
if (this.props.onSelectionChange && selection !== this.props.selection) {
|
|
2073
2093
|
this.props.onSelectionChange({
|
|
2074
2094
|
originalEvent: originalEvent,
|
|
2075
|
-
value: selection
|
|
2095
|
+
value: selection,
|
|
2096
|
+
type: type
|
|
2076
2097
|
});
|
|
2077
2098
|
}
|
|
2078
2099
|
}
|
|
@@ -2128,13 +2149,14 @@ var TableBody = /*#__PURE__*/function (_Component) {
|
|
|
2128
2149
|
if (this.props.onSelectionChange && selection !== this.props.selection) {
|
|
2129
2150
|
this.props.onSelectionChange({
|
|
2130
2151
|
originalEvent: originalEvent,
|
|
2131
|
-
value: selection
|
|
2152
|
+
value: selection,
|
|
2153
|
+
type: type
|
|
2132
2154
|
});
|
|
2133
2155
|
}
|
|
2134
2156
|
}
|
|
2135
2157
|
}, {
|
|
2136
2158
|
key: "onRangeSelection",
|
|
2137
|
-
value: function onRangeSelection(event) {
|
|
2159
|
+
value: function onRangeSelection(event, type) {
|
|
2138
2160
|
DomHandler.clearSelection();
|
|
2139
2161
|
this.rangeRowIndex = this.allowCellSelection() ? event.rowIndex : event.index;
|
|
2140
2162
|
var selectionInRange = this.selectRange(event);
|
|
@@ -2143,7 +2165,8 @@ var TableBody = /*#__PURE__*/function (_Component) {
|
|
|
2143
2165
|
if (this.props.onSelectionChange && selection !== this.props.selection) {
|
|
2144
2166
|
this.props.onSelectionChange({
|
|
2145
2167
|
originalEvent: event.originalEvent,
|
|
2146
|
-
value: selection
|
|
2168
|
+
value: selection,
|
|
2169
|
+
type: type
|
|
2147
2170
|
});
|
|
2148
2171
|
}
|
|
2149
2172
|
|
|
@@ -2303,7 +2326,7 @@ var TableBody = /*#__PURE__*/function (_Component) {
|
|
|
2303
2326
|
|
|
2304
2327
|
if (this.allowRowSelection()) {
|
|
2305
2328
|
if (this.allowRangeSelection(event)) {
|
|
2306
|
-
this.onRangeSelection(event);
|
|
2329
|
+
this.onRangeSelection(event, 'row');
|
|
2307
2330
|
} else {
|
|
2308
2331
|
var toggleable = this.isRadioSelectionModeInColumn() || this.isCheckboxSelectionModeInColumn() || this.allowMetaKeySelection(event);
|
|
2309
2332
|
this.anchorRowIndex = event.index;
|
|
@@ -2389,7 +2412,7 @@ var TableBody = /*#__PURE__*/function (_Component) {
|
|
|
2389
2412
|
var isSameRow = event.index === this.anchorRowIndex;
|
|
2390
2413
|
|
|
2391
2414
|
if (this.allowRowDrag(event) && !isSameRow) {
|
|
2392
|
-
this.onRangeSelection(event);
|
|
2415
|
+
this.onRangeSelection(event, 'row');
|
|
2393
2416
|
}
|
|
2394
2417
|
}
|
|
2395
2418
|
}, {
|
|
@@ -2592,7 +2615,7 @@ var TableBody = /*#__PURE__*/function (_Component) {
|
|
|
2592
2615
|
|
|
2593
2616
|
if (this.allowCellSelection()) {
|
|
2594
2617
|
if (this.allowRangeSelection(event)) {
|
|
2595
|
-
this.onRangeSelection(event);
|
|
2618
|
+
this.onRangeSelection(event, 'cell');
|
|
2596
2619
|
} else {
|
|
2597
2620
|
var toggleable = this.allowMetaKeySelection(event);
|
|
2598
2621
|
|
|
@@ -2641,7 +2664,7 @@ var TableBody = /*#__PURE__*/function (_Component) {
|
|
|
2641
2664
|
var isSameCell = event.rowIndex === this.anchorRowIndex && event.cellIndex === this.anchorCellIndex;
|
|
2642
2665
|
|
|
2643
2666
|
if (this.allowCellDrag(event) && !isSameCell) {
|
|
2644
|
-
this.onRangeSelection(event);
|
|
2667
|
+
this.onRangeSelection(event, 'cell');
|
|
2645
2668
|
}
|
|
2646
2669
|
}
|
|
2647
2670
|
}, {
|
|
@@ -2668,8 +2691,7 @@ var TableBody = /*#__PURE__*/function (_Component) {
|
|
|
2668
2691
|
}
|
|
2669
2692
|
|
|
2670
2693
|
if (!this.props.isVirtualScrollerDisabled && this.getVirtualScrollerOption('vertical')) {
|
|
2671
|
-
|
|
2672
|
-
this.el.style.top = parseFloat(style.top) + parseFloat(this.props.virtualScrollerOptions.itemSize) + 'px';
|
|
2694
|
+
this.updateVirtualScrollerPosition();
|
|
2673
2695
|
}
|
|
2674
2696
|
}
|
|
2675
2697
|
}, {
|
|
@@ -2684,8 +2706,7 @@ var TableBody = /*#__PURE__*/function (_Component) {
|
|
|
2684
2706
|
}
|
|
2685
2707
|
|
|
2686
2708
|
if (!this.props.isVirtualScrollerDisabled && this.getVirtualScrollerOption('vertical') && this.getVirtualScrollerOption('itemSize', prevProps.virtualScrollerOptions) !== this.getVirtualScrollerOption('itemSize')) {
|
|
2687
|
-
|
|
2688
|
-
this.el.style.top = parseFloat(style.top) + parseFloat(this.getVirtualScrollerOption('itemSize')) - parseFloat(this.getVirtualScrollerOption('itemSize', prevProps.virtualScrollerOptions)) + 'px';
|
|
2709
|
+
this.updateVirtualScrollerPosition();
|
|
2689
2710
|
}
|
|
2690
2711
|
}
|
|
2691
2712
|
}, {
|
|
@@ -2703,7 +2724,7 @@ var TableBody = /*#__PURE__*/function (_Component) {
|
|
|
2703
2724
|
var content = ObjectUtils.getJSXElement(this.props.emptyMessage, {
|
|
2704
2725
|
props: this.props,
|
|
2705
2726
|
frozen: this.props.frozenRow
|
|
2706
|
-
});
|
|
2727
|
+
}) || localeOption('emptyMessage');
|
|
2707
2728
|
return /*#__PURE__*/React.createElement("tr", {
|
|
2708
2729
|
className: "p-datatable-emptymessage",
|
|
2709
2730
|
role: "row"
|
|
@@ -3133,7 +3154,7 @@ var HeaderCheckbox = /*#__PURE__*/function (_Component) {
|
|
|
3133
3154
|
});
|
|
3134
3155
|
this.props.onChange({
|
|
3135
3156
|
originalEvent: event,
|
|
3136
|
-
checked: this.props.checked
|
|
3157
|
+
checked: !this.props.checked
|
|
3137
3158
|
});
|
|
3138
3159
|
}
|
|
3139
3160
|
}
|
|
@@ -3216,9 +3237,7 @@ var ColumnFilter = /*#__PURE__*/function (_Component) {
|
|
|
3216
3237
|
|
|
3217
3238
|
_this = _super.call(this, props);
|
|
3218
3239
|
_this.state = {
|
|
3219
|
-
overlayVisible: false
|
|
3220
|
-
defaultMatchMode: null,
|
|
3221
|
-
defaultOperator: null
|
|
3240
|
+
overlayVisible: false
|
|
3222
3241
|
};
|
|
3223
3242
|
_this.overlayRef = /*#__PURE__*/React.createRef();
|
|
3224
3243
|
_this.filterCallback = _this.filterCallback.bind(_assertThisInitialized(_this));
|
|
@@ -3253,6 +3272,11 @@ var ColumnFilter = /*#__PURE__*/function (_Component) {
|
|
|
3253
3272
|
get: function get() {
|
|
3254
3273
|
return this.props.filters[this.field];
|
|
3255
3274
|
}
|
|
3275
|
+
}, {
|
|
3276
|
+
key: "filterStoreModel",
|
|
3277
|
+
get: function get() {
|
|
3278
|
+
return this.props.filtersStore[this.field];
|
|
3279
|
+
}
|
|
3256
3280
|
}, {
|
|
3257
3281
|
key: "hasFilter",
|
|
3258
3282
|
value: function hasFilter() {
|
|
@@ -3276,7 +3300,7 @@ var ColumnFilter = /*#__PURE__*/function (_Component) {
|
|
|
3276
3300
|
}, {
|
|
3277
3301
|
key: "isRowMatchModeSelected",
|
|
3278
3302
|
value: function isRowMatchModeSelected(matchMode) {
|
|
3279
|
-
return this.filterModel.matchMode === matchMode;
|
|
3303
|
+
return this.filterModel && this.filterModel.matchMode === matchMode;
|
|
3280
3304
|
}
|
|
3281
3305
|
}, {
|
|
3282
3306
|
key: "showMenuButton",
|
|
@@ -3328,6 +3352,22 @@ var ColumnFilter = /*#__PURE__*/function (_Component) {
|
|
|
3328
3352
|
value: function getColumnProp(prop) {
|
|
3329
3353
|
return this.props.column.props[prop];
|
|
3330
3354
|
}
|
|
3355
|
+
}, {
|
|
3356
|
+
key: "getDefaultConstraint",
|
|
3357
|
+
value: function getDefaultConstraint() {
|
|
3358
|
+
if (this.props.filtersStore && this.filterStoreModel) {
|
|
3359
|
+
if (this.filterStoreModel.operator) {
|
|
3360
|
+
return {
|
|
3361
|
+
matchMode: this.filterStoreModel.constraints[0].matchMode,
|
|
3362
|
+
operator: this.filterStoreModel.operator
|
|
3363
|
+
};
|
|
3364
|
+
} else {
|
|
3365
|
+
return {
|
|
3366
|
+
matchMode: this.filterStoreModel.matchMode
|
|
3367
|
+
};
|
|
3368
|
+
}
|
|
3369
|
+
}
|
|
3370
|
+
}
|
|
3331
3371
|
}, {
|
|
3332
3372
|
key: "findDataType",
|
|
3333
3373
|
value: function findDataType() {
|
|
@@ -3356,19 +3396,20 @@ var ColumnFilter = /*#__PURE__*/function (_Component) {
|
|
|
3356
3396
|
value: function clearFilter() {
|
|
3357
3397
|
var field = this.field;
|
|
3358
3398
|
var filterClearCallback = this.getColumnProp('onFilterClear');
|
|
3399
|
+
var defaultConstraint = this.getDefaultConstraint();
|
|
3359
3400
|
|
|
3360
3401
|
var filters = _objectSpread$3({}, this.props.filters);
|
|
3361
3402
|
|
|
3362
3403
|
if (filters[field].operator) {
|
|
3363
3404
|
filters[field].constraints.splice(1);
|
|
3364
|
-
filters[field].operator =
|
|
3405
|
+
filters[field].operator = defaultConstraint.operator;
|
|
3365
3406
|
filters[field].constraints[0] = {
|
|
3366
3407
|
value: null,
|
|
3367
|
-
matchMode:
|
|
3408
|
+
matchMode: defaultConstraint.matchMode
|
|
3368
3409
|
};
|
|
3369
3410
|
} else {
|
|
3370
3411
|
filters[field].value = null;
|
|
3371
|
-
filters[field].matchMode =
|
|
3412
|
+
filters[field].matchMode = defaultConstraint.matchMode;
|
|
3372
3413
|
}
|
|
3373
3414
|
|
|
3374
3415
|
filterClearCallback && filterClearCallback();
|
|
@@ -3541,17 +3582,18 @@ var ColumnFilter = /*#__PURE__*/function (_Component) {
|
|
|
3541
3582
|
key: "addConstraint",
|
|
3542
3583
|
value: function addConstraint() {
|
|
3543
3584
|
var filterConstraintAddCallback = this.getColumnProp('onFilterConstraintAdd');
|
|
3585
|
+
var defaultConstraint = this.getDefaultConstraint();
|
|
3544
3586
|
|
|
3545
3587
|
var filters = _objectSpread$3({}, this.props.filters);
|
|
3546
3588
|
|
|
3547
3589
|
var newConstraint = {
|
|
3548
3590
|
value: null,
|
|
3549
|
-
matchMode:
|
|
3591
|
+
matchMode: defaultConstraint.matchMode
|
|
3550
3592
|
};
|
|
3551
3593
|
filters[this.field].constraints.push(newConstraint);
|
|
3552
3594
|
filterConstraintAddCallback && filterConstraintAddCallback({
|
|
3553
3595
|
field: this.field,
|
|
3554
|
-
|
|
3596
|
+
constraint: newConstraint
|
|
3555
3597
|
});
|
|
3556
3598
|
this.props.onFilterChange(filters);
|
|
3557
3599
|
|
|
@@ -3569,7 +3611,7 @@ var ColumnFilter = /*#__PURE__*/function (_Component) {
|
|
|
3569
3611
|
var removedConstraint = filters[this.field].constraints.splice(index, 1);
|
|
3570
3612
|
filterConstraintRemoveCallback && filterConstraintRemoveCallback({
|
|
3571
3613
|
field: this.field,
|
|
3572
|
-
|
|
3614
|
+
constraint: removedConstraint
|
|
3573
3615
|
});
|
|
3574
3616
|
this.props.onFilterChange(filters);
|
|
3575
3617
|
|
|
@@ -3615,7 +3657,7 @@ var ColumnFilter = /*#__PURE__*/function (_Component) {
|
|
|
3615
3657
|
value: function onOverlayEnter() {
|
|
3616
3658
|
var _this2 = this;
|
|
3617
3659
|
|
|
3618
|
-
ZIndexUtils.set('overlay', this.overlay);
|
|
3660
|
+
ZIndexUtils.set('overlay', this.overlay, PrimeReact.autoZIndex, PrimeReact.zIndex['overlay']);
|
|
3619
3661
|
DomHandler.alignOverlay(this.overlay, this.icon, PrimeReact.appendTo, false);
|
|
3620
3662
|
this.bindOutsideClickListener();
|
|
3621
3663
|
this.bindScrollListener();
|
|
@@ -3703,7 +3745,7 @@ var ColumnFilter = /*#__PURE__*/function (_Component) {
|
|
|
3703
3745
|
|
|
3704
3746
|
if (!this.resizeListener) {
|
|
3705
3747
|
this.resizeListener = function () {
|
|
3706
|
-
if (_this5.state.overlayVisible) {
|
|
3748
|
+
if (_this5.state.overlayVisible && !DomHandler.isTouchDevice()) {
|
|
3707
3749
|
_this5.hide();
|
|
3708
3750
|
}
|
|
3709
3751
|
};
|
|
@@ -3786,24 +3828,6 @@ var ColumnFilter = /*#__PURE__*/function (_Component) {
|
|
|
3786
3828
|
args && this.filterCallback(args[0], args[1]);
|
|
3787
3829
|
this.props.onFilterApply();
|
|
3788
3830
|
}
|
|
3789
|
-
}, {
|
|
3790
|
-
key: "componentDidMount",
|
|
3791
|
-
value: function componentDidMount() {
|
|
3792
|
-
if (this.props.filters && this.filterModel) {
|
|
3793
|
-
var filterModel = this.filterModel;
|
|
3794
|
-
|
|
3795
|
-
if (filterModel.operator) {
|
|
3796
|
-
this.setState({
|
|
3797
|
-
defaultMatchMode: filterModel.constraints[0].matchMode,
|
|
3798
|
-
defaultOperator: filterModel.operator
|
|
3799
|
-
});
|
|
3800
|
-
} else {
|
|
3801
|
-
this.setState({
|
|
3802
|
-
defaultMatchMode: this.filterModel.matchMode
|
|
3803
|
-
});
|
|
3804
|
-
}
|
|
3805
|
-
}
|
|
3806
|
-
}
|
|
3807
3831
|
}, {
|
|
3808
3832
|
key: "componentDidUpdate",
|
|
3809
3833
|
value: function componentDidUpdate(prevProps, prevState) {
|
|
@@ -3829,16 +3853,17 @@ var ColumnFilter = /*#__PURE__*/function (_Component) {
|
|
|
3829
3853
|
value: function renderFilterElement(model, index) {
|
|
3830
3854
|
var _this6 = this;
|
|
3831
3855
|
|
|
3856
|
+
var value = model ? model.value : null;
|
|
3832
3857
|
return this.getColumnProp('filterElement') ? ObjectUtils.getJSXElement(this.getColumnProp('filterElement'), {
|
|
3833
3858
|
field: this.field,
|
|
3834
3859
|
index: index,
|
|
3835
3860
|
filterModel: model,
|
|
3836
|
-
value:
|
|
3861
|
+
value: value,
|
|
3837
3862
|
filterApplyCallback: this.filterApplyCallback,
|
|
3838
3863
|
filterCallback: this.filterCallback
|
|
3839
3864
|
}) : /*#__PURE__*/React.createElement(InputText, {
|
|
3840
3865
|
type: this.getColumnProp('filterType'),
|
|
3841
|
-
value:
|
|
3866
|
+
value: value || '',
|
|
3842
3867
|
onChange: function onChange(e) {
|
|
3843
3868
|
return _this6.onInputChange(e, index);
|
|
3844
3869
|
},
|
|
@@ -4502,7 +4527,7 @@ var HeaderCell = /*#__PURE__*/function (_Component) {
|
|
|
4502
4527
|
}, {
|
|
4503
4528
|
key: "renderCheckbox",
|
|
4504
4529
|
value: function renderCheckbox() {
|
|
4505
|
-
if (this.getColumnProp('selectionMode') === 'multiple' && this.props.filterDisplay !== 'row') {
|
|
4530
|
+
if (this.props.showSelectAll && this.getColumnProp('selectionMode') === 'multiple' && this.props.filterDisplay !== 'row') {
|
|
4506
4531
|
var allRowsSelected = this.props.allRowsSelected(this.props.value);
|
|
4507
4532
|
return /*#__PURE__*/React.createElement(HeaderCheckbox, {
|
|
4508
4533
|
checked: allRowsSelected,
|
|
@@ -4724,6 +4749,7 @@ var TableHeader = /*#__PURE__*/function (_Component) {
|
|
|
4724
4749
|
onColumnResizeStart: _this3.props.onColumnResizeStart,
|
|
4725
4750
|
onColumnResizerClick: _this3.props.onColumnResizerClick,
|
|
4726
4751
|
onColumnResizerDoubleClick: _this3.props.onColumnResizerDoubleClick,
|
|
4752
|
+
showSelectAll: _this3.props.showSelectAll,
|
|
4727
4753
|
allRowsSelected: _this3.props.allRowsSelected,
|
|
4728
4754
|
onColumnCheckboxChange: _this3.onCheckboxChange,
|
|
4729
4755
|
reorderableColumns: _this3.props.reorderableColumns,
|
|
@@ -4731,6 +4757,36 @@ var TableHeader = /*#__PURE__*/function (_Component) {
|
|
|
4731
4757
|
});
|
|
4732
4758
|
});
|
|
4733
4759
|
}
|
|
4760
|
+
}, {
|
|
4761
|
+
key: "renderCheckbox",
|
|
4762
|
+
value: function renderCheckbox(selectionMode) {
|
|
4763
|
+
if (this.props.showSelectAll && selectionMode === 'multiple') {
|
|
4764
|
+
var allRowsSelected = this.props.allRowsSelected(this.props.value);
|
|
4765
|
+
return /*#__PURE__*/React.createElement(HeaderCheckbox, {
|
|
4766
|
+
checked: allRowsSelected,
|
|
4767
|
+
onChange: this.onCheckboxChange,
|
|
4768
|
+
disabled: this.props.empty
|
|
4769
|
+
});
|
|
4770
|
+
}
|
|
4771
|
+
|
|
4772
|
+
return null;
|
|
4773
|
+
}
|
|
4774
|
+
}, {
|
|
4775
|
+
key: "renderFilter",
|
|
4776
|
+
value: function renderFilter(column, filter) {
|
|
4777
|
+
if (filter) {
|
|
4778
|
+
return /*#__PURE__*/React.createElement(ColumnFilter, {
|
|
4779
|
+
display: "row",
|
|
4780
|
+
column: column,
|
|
4781
|
+
filters: this.props.filters,
|
|
4782
|
+
filtersStore: this.props.filtersStore,
|
|
4783
|
+
onFilterChange: this.props.onFilterChange,
|
|
4784
|
+
onFilterApply: this.props.onFilterApply
|
|
4785
|
+
});
|
|
4786
|
+
}
|
|
4787
|
+
|
|
4788
|
+
return null;
|
|
4789
|
+
}
|
|
4734
4790
|
}, {
|
|
4735
4791
|
key: "renderFilterCells",
|
|
4736
4792
|
value: function renderFilterCells() {
|
|
@@ -4758,24 +4814,15 @@ var TableHeader = /*#__PURE__*/function (_Component) {
|
|
|
4758
4814
|
});
|
|
4759
4815
|
var colKey = columnKey || field || i;
|
|
4760
4816
|
|
|
4761
|
-
var
|
|
4817
|
+
var checkbox = _this4.renderCheckbox(selectionMode);
|
|
4818
|
+
|
|
4819
|
+
var filterRow = _this4.renderFilter(col, filter);
|
|
4762
4820
|
|
|
4763
4821
|
return /*#__PURE__*/React.createElement("th", {
|
|
4764
4822
|
key: colKey,
|
|
4765
4823
|
style: colStyle,
|
|
4766
4824
|
className: colClassName
|
|
4767
|
-
},
|
|
4768
|
-
checked: allRowsSelected,
|
|
4769
|
-
onChange: _this4.onCheckboxChange,
|
|
4770
|
-
disabled: _this4.props.empty
|
|
4771
|
-
}), filter && /*#__PURE__*/React.createElement(ColumnFilter, {
|
|
4772
|
-
display: "row",
|
|
4773
|
-
column: col,
|
|
4774
|
-
filters: _this4.props.filters,
|
|
4775
|
-
filtersStore: _this4.props.filtersStore,
|
|
4776
|
-
onFilterChange: _this4.props.onFilterChange,
|
|
4777
|
-
onFilterApply: _this4.props.onFilterApply
|
|
4778
|
-
}));
|
|
4825
|
+
}, checkbox, filterRow);
|
|
4779
4826
|
}
|
|
4780
4827
|
|
|
4781
4828
|
return null;
|
|
@@ -4859,10 +4906,6 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
4859
4906
|
_this.state.filters = props.filters;
|
|
4860
4907
|
}
|
|
4861
4908
|
|
|
4862
|
-
if (_this.isStateful()) {
|
|
4863
|
-
_this.restoreState(_this.state);
|
|
4864
|
-
}
|
|
4865
|
-
|
|
4866
4909
|
_this.attributeSelector = UniqueComponentId(); // header
|
|
4867
4910
|
|
|
4868
4911
|
_this.onSortChange = _this.onSortChange.bind(_assertThisInitialized(_this));
|
|
@@ -4898,6 +4941,11 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
4898
4941
|
value: function isVirtualScrollerDisabled() {
|
|
4899
4942
|
return ObjectUtils.isEmpty(this.props.virtualScrollerOptions) || !this.props.scrollable;
|
|
4900
4943
|
}
|
|
4944
|
+
}, {
|
|
4945
|
+
key: "isEquals",
|
|
4946
|
+
value: function isEquals(data1, data2) {
|
|
4947
|
+
return this.props.compareSelectionBy === 'equals' ? data1 === data2 : ObjectUtils.equals(data1, data2, this.props.dataKey);
|
|
4948
|
+
}
|
|
4901
4949
|
}, {
|
|
4902
4950
|
key: "hasFilter",
|
|
4903
4951
|
value: function hasFilter() {
|
|
@@ -4943,17 +4991,7 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
4943
4991
|
value: function getColumns(ignoreReorderable) {
|
|
4944
4992
|
var _this2 = this;
|
|
4945
4993
|
|
|
4946
|
-
var
|
|
4947
|
-
return type.name === 'Column';
|
|
4948
|
-
};
|
|
4949
|
-
|
|
4950
|
-
var columns = React.Children.toArray(this.props.children).reduce(function (arr, child) {
|
|
4951
|
-
var type = child && child.type;
|
|
4952
|
-
type && (isValidType(type) ? arr.push(child) : type.toString() === 'Symbol(react.fragment)' && (arr = [].concat(_toConsumableArray(arr), _toConsumableArray(React.Children.toArray(child.props.children).filter(function (c) {
|
|
4953
|
-
return isValidType(c.type);
|
|
4954
|
-
})))));
|
|
4955
|
-
return arr;
|
|
4956
|
-
}, []);
|
|
4994
|
+
var columns = React.Children.toArray(this.props.children);
|
|
4957
4995
|
|
|
4958
4996
|
if (!columns) {
|
|
4959
4997
|
return null;
|
|
@@ -5115,7 +5153,7 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5115
5153
|
};
|
|
5116
5154
|
};
|
|
5117
5155
|
|
|
5118
|
-
this.props.onPage(getOnPageParams(restoredState.first, restoredState.rows));
|
|
5156
|
+
this.props.onPage(this.createEvent(getOnPageParams(restoredState.first, restoredState.rows)));
|
|
5119
5157
|
} else {
|
|
5120
5158
|
state.first = restoredState.first;
|
|
5121
5159
|
state.rows = restoredState.rows;
|
|
@@ -5124,10 +5162,10 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5124
5162
|
|
|
5125
5163
|
if (restoredState.sortField) {
|
|
5126
5164
|
if (this.props.onSort) {
|
|
5127
|
-
this.props.onSort({
|
|
5165
|
+
this.props.onSort(this.createEvent({
|
|
5128
5166
|
sortField: restoredState.sortField,
|
|
5129
5167
|
sortOrder: restoredState.sortOrder
|
|
5130
|
-
});
|
|
5168
|
+
}));
|
|
5131
5169
|
} else {
|
|
5132
5170
|
state.sortField = restoredState.sortField;
|
|
5133
5171
|
state.sortOrder = restoredState.sortOrder;
|
|
@@ -5136,9 +5174,9 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5136
5174
|
|
|
5137
5175
|
if (restoredState.multiSortMeta) {
|
|
5138
5176
|
if (this.props.onSort) {
|
|
5139
|
-
this.props.onSort({
|
|
5177
|
+
this.props.onSort(this.createEvent({
|
|
5140
5178
|
multiSortMeta: restoredState.multiSortMeta
|
|
5141
|
-
});
|
|
5179
|
+
}));
|
|
5142
5180
|
} else {
|
|
5143
5181
|
state.multiSortMeta = restoredState.multiSortMeta;
|
|
5144
5182
|
}
|
|
@@ -5148,9 +5186,9 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5148
5186
|
state.d_filters = this.cloneFilters(restoredState.filters);
|
|
5149
5187
|
|
|
5150
5188
|
if (this.props.onFilter) {
|
|
5151
|
-
this.props.onFilter({
|
|
5189
|
+
this.props.onFilter(this.createEvent({
|
|
5152
5190
|
filters: restoredState.filters
|
|
5153
|
-
});
|
|
5191
|
+
}));
|
|
5154
5192
|
} else {
|
|
5155
5193
|
state.filters = this.cloneFilters(restoredState.filters);
|
|
5156
5194
|
}
|
|
@@ -5251,9 +5289,25 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5251
5289
|
}, {
|
|
5252
5290
|
key: "allRowsSelected",
|
|
5253
5291
|
value: function allRowsSelected(processedData) {
|
|
5254
|
-
var
|
|
5255
|
-
|
|
5256
|
-
|
|
5292
|
+
var _this5 = this;
|
|
5293
|
+
|
|
5294
|
+
if (this.props.onSelectAllChange) {
|
|
5295
|
+
return this.props.selectAll;
|
|
5296
|
+
} else {
|
|
5297
|
+
var data = this.props.selectionPageOnly ? this.dataToRender(processedData) : processedData;
|
|
5298
|
+
var val = this.props.frozenValue ? [].concat(_toConsumableArray(this.props.frozenValue), _toConsumableArray(data)) : data;
|
|
5299
|
+
var selectableVal = this.props.showSelectionElement ? val.filter(function (data, index) {
|
|
5300
|
+
return _this5.props.showSelectionElement(data, {
|
|
5301
|
+
rowIndex: index,
|
|
5302
|
+
props: _this5.props
|
|
5303
|
+
});
|
|
5304
|
+
}) : val;
|
|
5305
|
+
return selectableVal && this.props.selection && selectableVal.every(function (sv) {
|
|
5306
|
+
return _this5.props.selection.some(function (s) {
|
|
5307
|
+
return _this5.isEquals(s, sv);
|
|
5308
|
+
});
|
|
5309
|
+
});
|
|
5310
|
+
}
|
|
5257
5311
|
}
|
|
5258
5312
|
}, {
|
|
5259
5313
|
key: "getSelectionModeInColumn",
|
|
@@ -5384,7 +5438,7 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5384
5438
|
}, {
|
|
5385
5439
|
key: "resizeTableCells",
|
|
5386
5440
|
value: function resizeTableCells(newColumnWidth, nextColumnWidth) {
|
|
5387
|
-
var
|
|
5441
|
+
var _this6 = this;
|
|
5388
5442
|
|
|
5389
5443
|
var widths = [];
|
|
5390
5444
|
var colIndex = DomHandler.index(this.resizeColumnElement);
|
|
@@ -5397,30 +5451,30 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5397
5451
|
var innerHTML = '';
|
|
5398
5452
|
widths.forEach(function (width, index) {
|
|
5399
5453
|
var colWidth = index === colIndex ? newColumnWidth : nextColumnWidth && index === colIndex + 1 ? nextColumnWidth : width;
|
|
5400
|
-
var style =
|
|
5401
|
-
innerHTML += "\n .p-datatable[".concat(
|
|
5454
|
+
var style = _this6.props.scrollable ? "flex: 0 0 ".concat(colWidth, "px !important") : "width: ".concat(colWidth, "px !important");
|
|
5455
|
+
innerHTML += "\n .p-datatable[".concat(_this6.attributeSelector, "] .p-datatable-thead > tr > th:nth-child(").concat(index + 1, "),\n .p-datatable[").concat(_this6.attributeSelector, "] .p-datatable-tbody > tr > td:nth-child(").concat(index + 1, "),\n .p-datatable[").concat(_this6.attributeSelector, "] .p-datatable-tfoot > tr > td:nth-child(").concat(index + 1, ") {\n ").concat(style, "\n }\n ");
|
|
5402
5456
|
});
|
|
5403
5457
|
this.styleElement.innerHTML = innerHTML;
|
|
5404
5458
|
}
|
|
5405
5459
|
}, {
|
|
5406
5460
|
key: "bindColumnResizeEvents",
|
|
5407
5461
|
value: function bindColumnResizeEvents() {
|
|
5408
|
-
var
|
|
5462
|
+
var _this7 = this;
|
|
5409
5463
|
|
|
5410
5464
|
if (!this.documentColumnResizeListener) {
|
|
5411
5465
|
this.documentColumnResizeListener = document.addEventListener('mousemove', function (event) {
|
|
5412
|
-
if (
|
|
5413
|
-
|
|
5466
|
+
if (_this7.columnResizing) {
|
|
5467
|
+
_this7.onColumnResize(event);
|
|
5414
5468
|
}
|
|
5415
5469
|
});
|
|
5416
5470
|
}
|
|
5417
5471
|
|
|
5418
5472
|
if (!this.documentColumnResizeEndListener) {
|
|
5419
5473
|
this.documentColumnResizeEndListener = document.addEventListener('mouseup', function () {
|
|
5420
|
-
if (
|
|
5421
|
-
|
|
5474
|
+
if (_this7.columnResizing) {
|
|
5475
|
+
_this7.columnResizing = false;
|
|
5422
5476
|
|
|
5423
|
-
|
|
5477
|
+
_this7.onColumnResizeEnd();
|
|
5424
5478
|
}
|
|
5425
5479
|
});
|
|
5426
5480
|
}
|
|
@@ -5452,31 +5506,48 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5452
5506
|
}, {
|
|
5453
5507
|
key: "onColumnHeaderCheckboxChange",
|
|
5454
5508
|
value: function onColumnHeaderCheckboxChange(e, processedData) {
|
|
5455
|
-
var
|
|
5456
|
-
checked = e.checked;
|
|
5457
|
-
var selection;
|
|
5509
|
+
var _this8 = this;
|
|
5458
5510
|
|
|
5459
|
-
if (
|
|
5460
|
-
|
|
5461
|
-
this.props.onAllRowsSelect && this.props.onAllRowsSelect({
|
|
5462
|
-
originalEvent: originalEvent,
|
|
5463
|
-
data: selection,
|
|
5464
|
-
type: 'all'
|
|
5465
|
-
});
|
|
5511
|
+
if (this.props.onSelectAllChange) {
|
|
5512
|
+
this.props.onSelectAllChange(e);
|
|
5466
5513
|
} else {
|
|
5467
|
-
|
|
5468
|
-
|
|
5469
|
-
|
|
5470
|
-
|
|
5471
|
-
|
|
5472
|
-
|
|
5473
|
-
|
|
5514
|
+
var originalEvent = e.originalEvent,
|
|
5515
|
+
checked = e.checked;
|
|
5516
|
+
var data = this.props.selectionPageOnly ? this.dataToRender(processedData) : processedData;
|
|
5517
|
+
var selection = this.props.selectionPageOnly && this.props.selection ? this.props.selection.filter(function (s) {
|
|
5518
|
+
return !data.some(function (d) {
|
|
5519
|
+
return _this8.isEquals(s, d);
|
|
5520
|
+
});
|
|
5521
|
+
}) : [];
|
|
5522
|
+
|
|
5523
|
+
if (checked) {
|
|
5524
|
+
selection = this.props.frozenValue ? [].concat(_toConsumableArray(selection), _toConsumableArray(this.props.frozenValue), _toConsumableArray(data)) : [].concat(_toConsumableArray(selection), _toConsumableArray(data));
|
|
5525
|
+
selection = this.props.showSelectionElement ? selection.filter(function (data, index) {
|
|
5526
|
+
return _this8.props.showSelectionElement(data, {
|
|
5527
|
+
rowIndex: index,
|
|
5528
|
+
props: _this8.props
|
|
5529
|
+
});
|
|
5530
|
+
}) : selection;
|
|
5531
|
+
this.props.onAllRowsSelect && this.props.onAllRowsSelect({
|
|
5532
|
+
originalEvent: originalEvent,
|
|
5533
|
+
data: selection,
|
|
5534
|
+
type: 'all'
|
|
5535
|
+
});
|
|
5536
|
+
} else {
|
|
5537
|
+
this.props.onAllRowsUnselect && this.props.onAllRowsUnselect({
|
|
5538
|
+
originalEvent: originalEvent,
|
|
5539
|
+
data: selection,
|
|
5540
|
+
type: 'all'
|
|
5541
|
+
});
|
|
5542
|
+
}
|
|
5474
5543
|
|
|
5475
|
-
|
|
5476
|
-
|
|
5477
|
-
|
|
5478
|
-
|
|
5479
|
-
|
|
5544
|
+
if (this.props.onSelectionChange) {
|
|
5545
|
+
this.props.onSelectionChange({
|
|
5546
|
+
originalEvent: originalEvent,
|
|
5547
|
+
value: selection,
|
|
5548
|
+
type: 'all'
|
|
5549
|
+
});
|
|
5550
|
+
}
|
|
5480
5551
|
}
|
|
5481
5552
|
}
|
|
5482
5553
|
}, {
|
|
@@ -5542,7 +5613,7 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5542
5613
|
}, {
|
|
5543
5614
|
key: "onColumnHeaderDrop",
|
|
5544
5615
|
value: function onColumnHeaderDrop(e) {
|
|
5545
|
-
var
|
|
5616
|
+
var _this9 = this;
|
|
5546
5617
|
|
|
5547
5618
|
var event = e.originalEvent,
|
|
5548
5619
|
column = e.column;
|
|
@@ -5565,7 +5636,7 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5565
5636
|
};
|
|
5566
5637
|
|
|
5567
5638
|
var dragColIndex = columns.findIndex(function (child) {
|
|
5568
|
-
return isSameColumn(child,
|
|
5639
|
+
return isSameColumn(child, _this9.draggedColumn);
|
|
5569
5640
|
});
|
|
5570
5641
|
var dropColIndex = columns.findIndex(function (child) {
|
|
5571
5642
|
return isSameColumn(child, column);
|
|
@@ -5609,15 +5680,13 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5609
5680
|
}, {
|
|
5610
5681
|
key: "createStyleElement",
|
|
5611
5682
|
value: function createStyleElement() {
|
|
5612
|
-
this.styleElement =
|
|
5613
|
-
document.head.appendChild(this.styleElement);
|
|
5683
|
+
this.styleElement = DomHandler.createInlineStyle();
|
|
5614
5684
|
}
|
|
5615
5685
|
}, {
|
|
5616
5686
|
key: "createResponsiveStyle",
|
|
5617
5687
|
value: function createResponsiveStyle() {
|
|
5618
5688
|
if (!this.responsiveStyleElement) {
|
|
5619
|
-
this.responsiveStyleElement =
|
|
5620
|
-
document.head.appendChild(this.responsiveStyleElement);
|
|
5689
|
+
this.responsiveStyleElement = DomHandler.createInlineStyle();
|
|
5621
5690
|
var innerHTML = "\n@media screen and (max-width: ".concat(this.props.breakpoint, ") {\n .p-datatable[").concat(this.attributeSelector, "] .p-datatable-thead > tr > th,\n .p-datatable[").concat(this.attributeSelector, "] .p-datatable-tfoot > tr > td {\n display: none !important;\n }\n\n .p-datatable[").concat(this.attributeSelector, "] .p-datatable-tbody > tr > td {\n display: flex;\n width: 100% !important;\n align-items: center;\n justify-content: space-between;\n }\n\n .p-datatable[").concat(this.attributeSelector, "] .p-datatable-tbody > tr > td:not(:last-child) {\n border: 0 none;\n }\n\n .p-datatable[").concat(this.attributeSelector, "].p-datatable-gridlines .p-datatable-tbody > tr > td:last-child {\n border-top: 0;\n border-right: 0;\n border-left: 0;\n }\n\n .p-datatable[").concat(this.attributeSelector, "] .p-datatable-tbody > tr > td > .p-column-title {\n display: block;\n }\n}\n");
|
|
5622
5691
|
this.responsiveStyleElement.innerHTML = innerHTML;
|
|
5623
5692
|
}
|
|
@@ -5625,24 +5694,18 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5625
5694
|
}, {
|
|
5626
5695
|
key: "destroyResponsiveStyle",
|
|
5627
5696
|
value: function destroyResponsiveStyle() {
|
|
5628
|
-
|
|
5629
|
-
document.head.removeChild(this.responsiveStyleElement);
|
|
5630
|
-
this.responsiveStyleElement = null;
|
|
5631
|
-
}
|
|
5697
|
+
this.responsiveStyleElement = DomHandler.removeInlineStyle(this.responsiveStyleElement);
|
|
5632
5698
|
}
|
|
5633
5699
|
}, {
|
|
5634
5700
|
key: "destroyStyleElement",
|
|
5635
5701
|
value: function destroyStyleElement() {
|
|
5636
|
-
|
|
5637
|
-
document.head.removeChild(this.styleElement);
|
|
5638
|
-
this.styleElement = null;
|
|
5639
|
-
}
|
|
5702
|
+
this.styleElement = DomHandler.removeInlineStyle(this.styleElement);
|
|
5640
5703
|
}
|
|
5641
5704
|
}, {
|
|
5642
5705
|
key: "onPageChange",
|
|
5643
5706
|
value: function onPageChange(e) {
|
|
5644
5707
|
this.clearEditingMetaData();
|
|
5645
|
-
if (this.props.onPage) this.props.onPage(e);else this.setState({
|
|
5708
|
+
if (this.props.onPage) this.props.onPage(this.createEvent(e));else this.setState({
|
|
5646
5709
|
first: e.first,
|
|
5647
5710
|
rows: e.rows
|
|
5648
5711
|
});
|
|
@@ -5706,7 +5769,7 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5706
5769
|
}
|
|
5707
5770
|
|
|
5708
5771
|
if (this.props.onSort) {
|
|
5709
|
-
this.props.onSort(eventMeta);
|
|
5772
|
+
this.props.onSort(this.createEvent(eventMeta));
|
|
5710
5773
|
} else {
|
|
5711
5774
|
eventMeta.first = 0;
|
|
5712
5775
|
this.setState(eventMeta);
|
|
@@ -5725,6 +5788,15 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5725
5788
|
value: function getCalculatedSortOrder(currentOrder) {
|
|
5726
5789
|
return this.props.removableSort ? this.props.defaultSortOrder === currentOrder ? currentOrder * -1 : 0 : currentOrder * -1;
|
|
5727
5790
|
}
|
|
5791
|
+
}, {
|
|
5792
|
+
key: "compareValuesOnSort",
|
|
5793
|
+
value: function compareValuesOnSort(value1, value2) {
|
|
5794
|
+
var result = null;
|
|
5795
|
+
if (value1 == null && value2 != null) result = -1;else if (value1 != null && value2 == null) result = 1;else if (value1 == null && value2 == null) result = 0;else if (typeof value1 === 'string' && typeof value2 === 'string') result = value1.localeCompare(value2, undefined, {
|
|
5796
|
+
numeric: true
|
|
5797
|
+
});else result = value1 < value2 ? -1 : value1 > value2 ? 1 : 0;
|
|
5798
|
+
return result;
|
|
5799
|
+
}
|
|
5728
5800
|
}, {
|
|
5729
5801
|
key: "addSortMeta",
|
|
5730
5802
|
value: function addSortMeta(meta, multiSortMeta) {
|
|
@@ -5749,6 +5821,8 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5749
5821
|
}, {
|
|
5750
5822
|
key: "sortSingle",
|
|
5751
5823
|
value: function sortSingle(data, field, order) {
|
|
5824
|
+
var _this10 = this;
|
|
5825
|
+
|
|
5752
5826
|
if (this.props.groupRowsBy && this.props.groupRowsBy === this.props.sortField) {
|
|
5753
5827
|
var multiSortMeta = [{
|
|
5754
5828
|
field: this.props.sortField,
|
|
@@ -5772,10 +5846,9 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5772
5846
|
value.sort(function (data1, data2) {
|
|
5773
5847
|
var value1 = ObjectUtils.resolveFieldData(data1, field);
|
|
5774
5848
|
var value2 = ObjectUtils.resolveFieldData(data2, field);
|
|
5775
|
-
|
|
5776
|
-
|
|
5777
|
-
|
|
5778
|
-
});else result = value1 < value2 ? -1 : value1 > value2 ? 1 : 0;
|
|
5849
|
+
|
|
5850
|
+
var result = _this10.compareValuesOnSort(value1, value2);
|
|
5851
|
+
|
|
5779
5852
|
return order * result;
|
|
5780
5853
|
});
|
|
5781
5854
|
}
|
|
@@ -5785,7 +5858,7 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5785
5858
|
}, {
|
|
5786
5859
|
key: "sortMultiple",
|
|
5787
5860
|
value: function sortMultiple(data) {
|
|
5788
|
-
var
|
|
5861
|
+
var _this11 = this;
|
|
5789
5862
|
|
|
5790
5863
|
var multiSortMeta = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];
|
|
5791
5864
|
|
|
@@ -5802,7 +5875,7 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5802
5875
|
|
|
5803
5876
|
if (this.columnSortable && this.columnSortFunction) {
|
|
5804
5877
|
var meta = multiSortMeta.find(function (meta) {
|
|
5805
|
-
return meta.field ===
|
|
5878
|
+
return meta.field === _this11.columnField;
|
|
5806
5879
|
});
|
|
5807
5880
|
var field = this.columnField;
|
|
5808
5881
|
var order = meta ? meta.order : this.defaultSortOrder;
|
|
@@ -5812,7 +5885,7 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5812
5885
|
});
|
|
5813
5886
|
} else {
|
|
5814
5887
|
value.sort(function (data1, data2) {
|
|
5815
|
-
return
|
|
5888
|
+
return _this11.multisortField(data1, data2, multiSortMeta, 0);
|
|
5816
5889
|
});
|
|
5817
5890
|
}
|
|
5818
5891
|
|
|
@@ -5823,22 +5896,12 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5823
5896
|
value: function multisortField(data1, data2, multiSortMeta, index) {
|
|
5824
5897
|
var value1 = ObjectUtils.resolveFieldData(data1, multiSortMeta[index].field);
|
|
5825
5898
|
var value2 = ObjectUtils.resolveFieldData(data2, multiSortMeta[index].field);
|
|
5826
|
-
var result = null;
|
|
5827
|
-
|
|
5828
|
-
if (typeof value1 === 'string' || value1 instanceof String) {
|
|
5829
|
-
if (value1.localeCompare && value1 !== value2) {
|
|
5830
|
-
return multiSortMeta[index].order * value1.localeCompare(value2, undefined, {
|
|
5831
|
-
numeric: true
|
|
5832
|
-
});
|
|
5833
|
-
}
|
|
5834
|
-
} else {
|
|
5835
|
-
result = value1 < value2 ? -1 : 1;
|
|
5836
|
-
}
|
|
5837
5899
|
|
|
5838
5900
|
if (value1 === value2) {
|
|
5839
5901
|
return multiSortMeta.length - 1 > index ? this.multisortField(data1, data2, multiSortMeta, index + 1) : 0;
|
|
5840
5902
|
}
|
|
5841
5903
|
|
|
5904
|
+
var result = this.compareValuesOnSort(value1, value2);
|
|
5842
5905
|
return multiSortMeta[index].order * result;
|
|
5843
5906
|
}
|
|
5844
5907
|
}, {
|
|
@@ -5852,25 +5915,25 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5852
5915
|
}, {
|
|
5853
5916
|
key: "onFilterApply",
|
|
5854
5917
|
value: function onFilterApply() {
|
|
5855
|
-
var
|
|
5918
|
+
var _this12 = this;
|
|
5856
5919
|
|
|
5857
5920
|
clearTimeout(this.filterTimeout);
|
|
5858
5921
|
this.filterTimeout = setTimeout(function () {
|
|
5859
|
-
var filters =
|
|
5922
|
+
var filters = _this12.cloneFilters(_this12.state.d_filters);
|
|
5860
5923
|
|
|
5861
|
-
if (
|
|
5862
|
-
|
|
5924
|
+
if (_this12.props.onFilter) {
|
|
5925
|
+
_this12.props.onFilter(_this12.createEvent({
|
|
5863
5926
|
filters: filters
|
|
5864
|
-
});
|
|
5927
|
+
}));
|
|
5865
5928
|
} else {
|
|
5866
|
-
|
|
5929
|
+
_this12.setState({
|
|
5867
5930
|
first: 0,
|
|
5868
5931
|
filters: filters
|
|
5869
5932
|
});
|
|
5870
5933
|
}
|
|
5871
5934
|
|
|
5872
|
-
if (
|
|
5873
|
-
|
|
5935
|
+
if (_this12.props.onValueChange) {
|
|
5936
|
+
_this12.props.onValueChange(_this12.processedData({
|
|
5874
5937
|
filters: filters
|
|
5875
5938
|
}));
|
|
5876
5939
|
}
|
|
@@ -5968,7 +6031,7 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5968
6031
|
}, {
|
|
5969
6032
|
key: "cloneFilters",
|
|
5970
6033
|
value: function cloneFilters(filters) {
|
|
5971
|
-
var
|
|
6034
|
+
var _this13 = this;
|
|
5972
6035
|
|
|
5973
6036
|
filters = filters || this.props.filters;
|
|
5974
6037
|
var cloned = {};
|
|
@@ -5989,34 +6052,31 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
5989
6052
|
} else {
|
|
5990
6053
|
var columns = this.getColumns();
|
|
5991
6054
|
cloned = columns.reduce(function (_filters, col) {
|
|
5992
|
-
|
|
5993
|
-
|
|
5994
|
-
|
|
5995
|
-
|
|
5996
|
-
|
|
5997
|
-
|
|
5998
|
-
|
|
5999
|
-
|
|
6000
|
-
};
|
|
6001
|
-
|
|
6002
|
-
if (filterFunction) {
|
|
6003
|
-
FilterService.register("custom_".concat(field), function () {
|
|
6004
|
-
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
6005
|
-
args[_key] = arguments[_key];
|
|
6006
|
-
}
|
|
6055
|
+
var field = col.props.filterField || col.props.field;
|
|
6056
|
+
var filterFunction = col.props.filterFunction;
|
|
6057
|
+
var dataType = col.props.dataType;
|
|
6058
|
+
var matchMode = col.props.filterMatchMode || (PrimeReact.filterMatchModeOptions[dataType] ? PrimeReact.filterMatchModeOptions[dataType][0] : FilterMatchMode$1.STARTS_WITH);
|
|
6059
|
+
var constraint = {
|
|
6060
|
+
value: null,
|
|
6061
|
+
matchMode: matchMode
|
|
6062
|
+
};
|
|
6007
6063
|
|
|
6008
|
-
|
|
6009
|
-
|
|
6010
|
-
|
|
6011
|
-
|
|
6012
|
-
|
|
6064
|
+
if (filterFunction) {
|
|
6065
|
+
FilterService.register("custom_".concat(field), function () {
|
|
6066
|
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
6067
|
+
args[_key] = arguments[_key];
|
|
6068
|
+
}
|
|
6013
6069
|
|
|
6014
|
-
|
|
6015
|
-
|
|
6016
|
-
|
|
6017
|
-
}
|
|
6070
|
+
return filterFunction.apply(void 0, args.concat([{
|
|
6071
|
+
column: col
|
|
6072
|
+
}]));
|
|
6073
|
+
});
|
|
6018
6074
|
}
|
|
6019
6075
|
|
|
6076
|
+
_filters[field] = _this13.props.filterDisplay === 'menu' ? {
|
|
6077
|
+
operator: FilterOperator.AND,
|
|
6078
|
+
constraints: [constraint]
|
|
6079
|
+
} : constraint;
|
|
6020
6080
|
return _filters;
|
|
6021
6081
|
}, {});
|
|
6022
6082
|
}
|
|
@@ -6092,7 +6152,7 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
6092
6152
|
}, {
|
|
6093
6153
|
key: "exportCSV",
|
|
6094
6154
|
value: function exportCSV(options) {
|
|
6095
|
-
var
|
|
6155
|
+
var _this14 = this;
|
|
6096
6156
|
|
|
6097
6157
|
var data;
|
|
6098
6158
|
var csv = "\uFEFF";
|
|
@@ -6115,7 +6175,7 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
6115
6175
|
csv += '"' + (header || field) + '"';
|
|
6116
6176
|
|
|
6117
6177
|
if (i < columns.length - 1) {
|
|
6118
|
-
csv +=
|
|
6178
|
+
csv += _this14.props.csvSeparator;
|
|
6119
6179
|
}
|
|
6120
6180
|
}
|
|
6121
6181
|
}); //body
|
|
@@ -6131,16 +6191,18 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
6131
6191
|
var cellData = ObjectUtils.resolveFieldData(record, field);
|
|
6132
6192
|
|
|
6133
6193
|
if (cellData != null) {
|
|
6134
|
-
cellData =
|
|
6194
|
+
cellData = _this14.props.exportFunction ? _this14.props.exportFunction({
|
|
6135
6195
|
data: cellData,
|
|
6136
|
-
field: field
|
|
6196
|
+
field: field,
|
|
6197
|
+
rowData: record,
|
|
6198
|
+
column: column
|
|
6137
6199
|
}) : String(cellData).replace(/"/g, '""');
|
|
6138
6200
|
} else cellData = '';
|
|
6139
6201
|
|
|
6140
6202
|
csv += '"' + cellData + '"';
|
|
6141
6203
|
|
|
6142
6204
|
if (i < columns.length - 1) {
|
|
6143
|
-
csv +=
|
|
6205
|
+
csv += _this14.props.csvSeparator;
|
|
6144
6206
|
}
|
|
6145
6207
|
}
|
|
6146
6208
|
});
|
|
@@ -6154,6 +6216,18 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
6154
6216
|
document.body.click();
|
|
6155
6217
|
}
|
|
6156
6218
|
}
|
|
6219
|
+
}, {
|
|
6220
|
+
key: "createEvent",
|
|
6221
|
+
value: function createEvent(event) {
|
|
6222
|
+
return _objectSpread({
|
|
6223
|
+
first: this.getFirst(),
|
|
6224
|
+
rows: this.getRows(),
|
|
6225
|
+
sortField: this.getSortField(),
|
|
6226
|
+
sortOrder: this.getSortOrder(),
|
|
6227
|
+
multiSortMeta: this.getMultiSortMeta(),
|
|
6228
|
+
filters: this.getFilters()
|
|
6229
|
+
}, event);
|
|
6230
|
+
}
|
|
6157
6231
|
}, {
|
|
6158
6232
|
key: "processedData",
|
|
6159
6233
|
value: function processedData(localState) {
|
|
@@ -6197,8 +6271,12 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
6197
6271
|
this.createResponsiveStyle();
|
|
6198
6272
|
}
|
|
6199
6273
|
|
|
6200
|
-
if (this.isStateful()
|
|
6201
|
-
this.
|
|
6274
|
+
if (this.isStateful()) {
|
|
6275
|
+
this.setState(this.restoreState(this.state));
|
|
6276
|
+
|
|
6277
|
+
if (this.props.resizableColumns) {
|
|
6278
|
+
this.restoreColumnWidths();
|
|
6279
|
+
}
|
|
6202
6280
|
}
|
|
6203
6281
|
}
|
|
6204
6282
|
}, {
|
|
@@ -6298,6 +6376,7 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
6298
6376
|
filtersStore: filtersStore,
|
|
6299
6377
|
onFilterChange: this.onFilterChange,
|
|
6300
6378
|
onFilterApply: this.onFilterApply,
|
|
6379
|
+
showSelectAll: this.props.showSelectAll,
|
|
6301
6380
|
allRowsSelected: this.allRowsSelected,
|
|
6302
6381
|
onColumnCheckboxChange: this.onColumnHeaderCheckboxChange,
|
|
6303
6382
|
onColumnMouseDown: this.onColumnHeaderMouseDown,
|
|
@@ -6465,7 +6544,7 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
6465
6544
|
}, {
|
|
6466
6545
|
key: "renderContent",
|
|
6467
6546
|
value: function renderContent(processedData, columns, selectionModeInColumn, empty) {
|
|
6468
|
-
var
|
|
6547
|
+
var _this15 = this;
|
|
6469
6548
|
|
|
6470
6549
|
if (!columns) return;
|
|
6471
6550
|
var isVirtualScrollerDisabled = this.isVirtualScrollerDisabled();
|
|
@@ -6478,29 +6557,27 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
6478
6557
|
}, /*#__PURE__*/React.createElement(VirtualScroller, _extends({}, virtualScrollerOptions, {
|
|
6479
6558
|
items: processedData,
|
|
6480
6559
|
columns: columns,
|
|
6481
|
-
|
|
6482
|
-
height: this.props.scrollHeight
|
|
6483
|
-
},
|
|
6560
|
+
scrollHeight: this.props.scrollHeight,
|
|
6484
6561
|
disabled: isVirtualScrollerDisabled,
|
|
6485
6562
|
loaderDisabled: true,
|
|
6486
6563
|
showSpacer: false,
|
|
6487
6564
|
contentTemplate: function contentTemplate(options) {
|
|
6488
6565
|
var ref = function ref(el) {
|
|
6489
|
-
|
|
6566
|
+
_this15.table = el;
|
|
6490
6567
|
options.spacerRef && options.spacerRef(el);
|
|
6491
6568
|
};
|
|
6492
6569
|
|
|
6493
|
-
var tableClassName = classNames('p-datatable-table',
|
|
6570
|
+
var tableClassName = classNames('p-datatable-table', _this15.props.tableClassName);
|
|
6494
6571
|
|
|
6495
|
-
var tableHeader =
|
|
6572
|
+
var tableHeader = _this15.renderTableHeader(options, empty);
|
|
6496
6573
|
|
|
6497
|
-
var tableBody =
|
|
6574
|
+
var tableBody = _this15.renderTableBody(options, selectionModeInColumn, empty, isVirtualScrollerDisabled);
|
|
6498
6575
|
|
|
6499
|
-
var tableFooter =
|
|
6576
|
+
var tableFooter = _this15.renderTableFooter(options);
|
|
6500
6577
|
|
|
6501
6578
|
return /*#__PURE__*/React.createElement("table", {
|
|
6502
6579
|
ref: ref,
|
|
6503
|
-
style:
|
|
6580
|
+
style: _this15.props.tableStyle,
|
|
6504
6581
|
className: tableClassName,
|
|
6505
6582
|
role: "table"
|
|
6506
6583
|
}, tableHeader, tableBody, tableFooter);
|
|
@@ -6562,12 +6639,12 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
6562
6639
|
}, {
|
|
6563
6640
|
key: "renderResizeHelper",
|
|
6564
6641
|
value: function renderResizeHelper() {
|
|
6565
|
-
var
|
|
6642
|
+
var _this16 = this;
|
|
6566
6643
|
|
|
6567
6644
|
if (this.props.resizableColumns) {
|
|
6568
6645
|
return /*#__PURE__*/React.createElement("div", {
|
|
6569
6646
|
ref: function ref(el) {
|
|
6570
|
-
return
|
|
6647
|
+
return _this16.resizeHelper = el;
|
|
6571
6648
|
},
|
|
6572
6649
|
className: "p-column-resizer-helper",
|
|
6573
6650
|
style: {
|
|
@@ -6581,7 +6658,7 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
6581
6658
|
}, {
|
|
6582
6659
|
key: "renderReorderIndicators",
|
|
6583
6660
|
value: function renderReorderIndicators() {
|
|
6584
|
-
var
|
|
6661
|
+
var _this17 = this;
|
|
6585
6662
|
|
|
6586
6663
|
if (this.props.reorderableColumns) {
|
|
6587
6664
|
var style = {
|
|
@@ -6590,13 +6667,13 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
6590
6667
|
};
|
|
6591
6668
|
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("span", {
|
|
6592
6669
|
ref: function ref(el) {
|
|
6593
|
-
return
|
|
6670
|
+
return _this17.reorderIndicatorUp = el;
|
|
6594
6671
|
},
|
|
6595
6672
|
className: "pi pi-arrow-down p-datatable-reorder-indicator-up",
|
|
6596
6673
|
style: style
|
|
6597
6674
|
}), /*#__PURE__*/React.createElement("span", {
|
|
6598
6675
|
ref: function ref(el) {
|
|
6599
|
-
return
|
|
6676
|
+
return _this17.reorderIndicatorDown = el;
|
|
6600
6677
|
},
|
|
6601
6678
|
className: "pi pi-arrow-up p-datatable-reorder-indicator-down",
|
|
6602
6679
|
style: style
|
|
@@ -6608,7 +6685,7 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
6608
6685
|
}, {
|
|
6609
6686
|
key: "render",
|
|
6610
6687
|
value: function render() {
|
|
6611
|
-
var
|
|
6688
|
+
var _this18 = this;
|
|
6612
6689
|
|
|
6613
6690
|
var processedData = this.processedData();
|
|
6614
6691
|
var columns = this.getColumns();
|
|
@@ -6644,7 +6721,7 @@ var DataTable = /*#__PURE__*/function (_Component) {
|
|
|
6644
6721
|
var reorderIndicators = this.renderReorderIndicators();
|
|
6645
6722
|
return /*#__PURE__*/React.createElement("div", {
|
|
6646
6723
|
ref: function ref(el) {
|
|
6647
|
-
return
|
|
6724
|
+
return _this18.el = el;
|
|
6648
6725
|
},
|
|
6649
6726
|
id: this.props.id,
|
|
6650
6727
|
className: className,
|
|
@@ -6699,7 +6776,7 @@ _defineProperty(DataTable, "defaultProps", {
|
|
|
6699
6776
|
sortMode: 'single',
|
|
6700
6777
|
defaultSortOrder: 1,
|
|
6701
6778
|
removableSort: false,
|
|
6702
|
-
emptyMessage:
|
|
6779
|
+
emptyMessage: null,
|
|
6703
6780
|
selectionMode: null,
|
|
6704
6781
|
dragSelection: false,
|
|
6705
6782
|
cellSelection: false,
|
|
@@ -6711,6 +6788,10 @@ _defineProperty(DataTable, "defaultProps", {
|
|
|
6711
6788
|
dataKey: null,
|
|
6712
6789
|
metaKeySelection: true,
|
|
6713
6790
|
selectOnEdit: true,
|
|
6791
|
+
selectionPageOnly: false,
|
|
6792
|
+
showSelectAll: true,
|
|
6793
|
+
selectAll: false,
|
|
6794
|
+
onSelectAllChange: null,
|
|
6714
6795
|
headerColumnGroup: null,
|
|
6715
6796
|
footerColumnGroup: null,
|
|
6716
6797
|
rowExpansionTemplate: null,
|