primereact 9.4.0 → 9.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/accordion/accordion.cjs.js +2 -1
- package/accordion/accordion.cjs.min.js +1 -1
- package/accordion/accordion.esm.js +3 -2
- package/accordion/accordion.esm.min.js +1 -1
- package/accordion/accordion.js +2 -1
- package/accordion/accordion.min.js +1 -1
- package/api/api.cjs.js +215 -3
- package/api/api.cjs.min.js +1 -1
- package/api/api.d.ts +882 -8
- package/api/api.esm.js +210 -4
- package/api/api.esm.min.js +1 -1
- package/api/api.js +216 -5
- package/api/api.min.js +1 -1
- package/autocomplete/autocomplete.cjs.js +148 -89
- package/autocomplete/autocomplete.cjs.min.js +1 -1
- package/autocomplete/autocomplete.d.ts +138 -2
- package/autocomplete/autocomplete.esm.js +150 -91
- package/autocomplete/autocomplete.esm.min.js +1 -1
- package/autocomplete/autocomplete.js +149 -91
- package/autocomplete/autocomplete.min.css +1 -1
- package/autocomplete/autocomplete.min.js +1 -1
- package/avatar/avatar.cjs.js +3 -1
- package/avatar/avatar.cjs.min.js +1 -1
- package/avatar/avatar.d.ts +1 -1
- package/avatar/avatar.esm.js +3 -1
- package/avatar/avatar.esm.min.js +1 -1
- package/avatar/avatar.js +4 -3
- package/avatar/avatar.min.js +1 -1
- package/avatargroup/avatargroup.cjs.js +3 -1
- package/avatargroup/avatargroup.cjs.min.js +1 -1
- package/avatargroup/avatargroup.esm.js +3 -1
- package/avatargroup/avatargroup.esm.min.js +1 -1
- package/avatargroup/avatargroup.js +4 -3
- package/avatargroup/avatargroup.min.js +1 -1
- package/badge/badge.cjs.js +3 -1
- package/badge/badge.cjs.min.js +1 -1
- package/badge/badge.esm.js +3 -1
- package/badge/badge.esm.min.js +1 -1
- package/badge/badge.js +4 -3
- package/badge/badge.min.js +1 -1
- package/blockui/blockui.cjs.js +4 -3
- package/blockui/blockui.cjs.min.js +1 -1
- package/blockui/blockui.esm.js +4 -3
- package/blockui/blockui.esm.min.js +1 -1
- package/blockui/blockui.js +5 -4
- package/blockui/blockui.min.js +1 -1
- package/breadcrumb/breadcrumb.cjs.js +97 -52
- package/breadcrumb/breadcrumb.cjs.min.js +1 -1
- package/breadcrumb/breadcrumb.d.ts +53 -1
- package/breadcrumb/breadcrumb.esm.js +97 -52
- package/breadcrumb/breadcrumb.esm.min.js +1 -1
- package/breadcrumb/breadcrumb.js +96 -53
- package/breadcrumb/breadcrumb.min.css +1 -1
- package/breadcrumb/breadcrumb.min.js +1 -1
- package/button/button.cjs.js +6 -2
- package/button/button.cjs.min.js +1 -1
- package/button/button.d.ts +6 -0
- package/button/button.esm.js +6 -2
- package/button/button.esm.min.js +1 -1
- package/button/button.js +7 -4
- package/button/button.min.js +1 -1
- package/calendar/calendar.cjs.js +322 -223
- package/calendar/calendar.cjs.min.js +1 -1
- package/calendar/calendar.d.ts +272 -3
- package/calendar/calendar.esm.js +324 -225
- package/calendar/calendar.esm.min.js +1 -1
- package/calendar/calendar.js +323 -225
- package/calendar/calendar.min.js +1 -1
- package/card/card.cjs.js +3 -1
- package/card/card.cjs.min.js +1 -1
- package/card/card.d.ts +5 -11
- package/card/card.esm.js +3 -1
- package/card/card.esm.min.js +1 -1
- package/card/card.js +4 -3
- package/card/card.min.js +1 -1
- package/carousel/carousel.cjs.js +154 -92
- package/carousel/carousel.cjs.min.js +1 -1
- package/carousel/carousel.d.ts +121 -1
- package/carousel/carousel.esm.js +156 -94
- package/carousel/carousel.esm.min.js +1 -1
- package/carousel/carousel.js +155 -94
- package/carousel/carousel.min.js +1 -1
- package/cascadeselect/cascadeselect.cjs.js +181 -108
- package/cascadeselect/cascadeselect.cjs.min.js +1 -1
- package/cascadeselect/cascadeselect.d.ts +100 -1
- package/cascadeselect/cascadeselect.esm.js +183 -110
- package/cascadeselect/cascadeselect.esm.min.js +1 -1
- package/cascadeselect/cascadeselect.js +180 -108
- package/cascadeselect/cascadeselect.min.js +1 -1
- package/chart/chart.cjs.js +31 -44
- package/chart/chart.cjs.min.js +1 -1
- package/chart/chart.d.ts +30 -0
- package/chart/chart.esm.js +18 -31
- package/chart/chart.esm.min.js +1 -1
- package/chart/chart.js +141 -156
- package/chart/chart.min.js +1 -1
- package/checkbox/checkbox.cjs.js +113 -48
- package/checkbox/checkbox.cjs.min.js +1 -1
- package/checkbox/checkbox.d.ts +65 -1
- package/checkbox/checkbox.esm.js +115 -50
- package/checkbox/checkbox.esm.min.js +1 -1
- package/checkbox/checkbox.js +113 -50
- package/checkbox/checkbox.min.js +1 -1
- package/chip/chip.cjs.js +3 -1
- package/chip/chip.cjs.min.js +1 -1
- package/chip/chip.d.ts +1 -1
- package/chip/chip.esm.js +3 -1
- package/chip/chip.esm.min.js +1 -1
- package/chip/chip.js +4 -3
- package/chip/chip.min.js +1 -1
- package/chips/chips.cjs.js +84 -55
- package/chips/chips.cjs.min.js +1 -1
- package/chips/chips.d.ts +78 -6
- package/chips/chips.esm.js +85 -56
- package/chips/chips.esm.min.js +1 -1
- package/chips/chips.js +83 -57
- package/chips/chips.min.js +1 -1
- package/colorpicker/colorpicker.cjs.js +123 -49
- package/colorpicker/colorpicker.cjs.min.js +1 -1
- package/colorpicker/colorpicker.d.ts +81 -0
- package/colorpicker/colorpicker.esm.js +125 -51
- package/colorpicker/colorpicker.esm.min.js +1 -1
- package/colorpicker/colorpicker.js +124 -51
- package/colorpicker/colorpicker.min.js +1 -1
- package/column/column.cjs.js +2 -0
- package/column/column.d.ts +298 -1
- package/column/column.esm.js +2 -0
- package/column/column.js +2 -0
- package/columngroup/columngroup.d.ts +28 -0
- package/componentbase/componentbase.cjs.js +29 -5
- package/componentbase/componentbase.cjs.min.js +1 -1
- package/componentbase/componentbase.esm.js +25 -5
- package/componentbase/componentbase.esm.min.js +1 -1
- package/componentbase/componentbase.js +30 -7
- package/componentbase/componentbase.min.js +1 -1
- package/confirmdialog/confirmdialog.cjs.js +4 -3
- package/confirmdialog/confirmdialog.cjs.min.js +1 -1
- package/confirmdialog/confirmdialog.esm.js +5 -4
- package/confirmdialog/confirmdialog.esm.min.js +1 -1
- package/confirmdialog/confirmdialog.js +4 -3
- package/confirmdialog/confirmdialog.min.js +1 -1
- package/confirmpopup/confirmpopup.cjs.js +5 -4
- package/confirmpopup/confirmpopup.cjs.min.js +1 -1
- package/confirmpopup/confirmpopup.esm.js +6 -5
- package/confirmpopup/confirmpopup.esm.min.js +1 -1
- package/confirmpopup/confirmpopup.js +5 -4
- package/confirmpopup/confirmpopup.min.js +1 -1
- package/contextmenu/contextmenu.cjs.js +121 -69
- package/contextmenu/contextmenu.cjs.min.js +1 -1
- package/contextmenu/contextmenu.d.ts +92 -1
- package/contextmenu/contextmenu.esm.js +123 -71
- package/contextmenu/contextmenu.esm.min.js +1 -1
- package/contextmenu/contextmenu.js +122 -71
- package/contextmenu/contextmenu.min.js +1 -1
- package/core/core.js +14005 -2381
- package/core/core.min.js +47 -47
- package/csstransition/csstransition.cjs.js +3 -2
- package/csstransition/csstransition.cjs.min.js +1 -1
- package/csstransition/csstransition.esm.js +3 -2
- package/csstransition/csstransition.esm.min.js +1 -1
- package/csstransition/csstransition.js +4 -3
- package/csstransition/csstransition.min.js +1 -1
- package/datascroller/datascroller.cjs.js +34 -43
- package/datascroller/datascroller.cjs.min.js +1 -1
- package/datascroller/datascroller.d.ts +51 -1
- package/datascroller/datascroller.esm.js +36 -45
- package/datascroller/datascroller.esm.min.js +1 -1
- package/datascroller/datascroller.js +35 -45
- package/datascroller/datascroller.min.js +1 -1
- package/datatable/datatable.cjs.js +1089 -649
- package/datatable/datatable.cjs.min.js +1 -1
- package/datatable/datatable.d.ts +191 -3
- package/datatable/datatable.esm.js +1091 -651
- package/datatable/datatable.esm.min.js +1 -1
- package/datatable/datatable.js +1090 -651
- package/datatable/datatable.min.js +1 -1
- package/dataview/dataview.cjs.js +125 -109
- package/dataview/dataview.cjs.min.js +1 -1
- package/dataview/dataview.d.ts +105 -2
- package/dataview/dataview.esm.js +127 -111
- package/dataview/dataview.esm.min.js +1 -1
- package/dataview/dataview.js +123 -108
- package/dataview/dataview.min.js +1 -1
- package/deferredcontent/deferredcontent.cjs.js +3 -1
- package/deferredcontent/deferredcontent.cjs.min.js +1 -1
- package/deferredcontent/deferredcontent.esm.js +3 -1
- package/deferredcontent/deferredcontent.esm.min.js +1 -1
- package/deferredcontent/deferredcontent.js +4 -3
- package/deferredcontent/deferredcontent.min.js +1 -1
- package/dialog/dialog.cjs.js +6 -5
- package/dialog/dialog.cjs.min.js +1 -1
- package/dialog/dialog.esm.js +7 -6
- package/dialog/dialog.esm.min.js +1 -1
- package/dialog/dialog.js +6 -5
- package/dialog/dialog.min.js +1 -1
- package/divider/divider.cjs.js +3 -1
- package/divider/divider.cjs.min.js +1 -1
- package/divider/divider.esm.js +3 -1
- package/divider/divider.esm.min.js +1 -1
- package/divider/divider.js +4 -3
- package/divider/divider.min.js +1 -1
- package/dock/dock.cjs.js +85 -46
- package/dock/dock.cjs.min.js +1 -1
- package/dock/dock.d.ts +66 -0
- package/dock/dock.esm.js +86 -47
- package/dock/dock.esm.min.js +1 -1
- package/dock/dock.js +85 -48
- package/dock/dock.min.js +1 -1
- package/dropdown/dropdown.cjs.js +170 -120
- package/dropdown/dropdown.cjs.min.js +1 -1
- package/dropdown/dropdown.d.ts +154 -2
- package/dropdown/dropdown.esm.js +172 -122
- package/dropdown/dropdown.esm.min.js +1 -1
- package/dropdown/dropdown.js +170 -121
- package/dropdown/dropdown.min.js +1 -1
- package/editor/editor.cjs.js +95 -116
- package/editor/editor.cjs.min.js +1 -1
- package/editor/editor.d.ts +50 -0
- package/editor/editor.esm.js +96 -117
- package/editor/editor.esm.min.js +1 -1
- package/editor/editor.js +95 -118
- package/editor/editor.min.js +1 -1
- package/fieldset/fieldset.cjs.js +3 -1
- package/fieldset/fieldset.cjs.min.js +1 -1
- package/fieldset/fieldset.esm.js +3 -1
- package/fieldset/fieldset.esm.min.js +1 -1
- package/fieldset/fieldset.js +4 -3
- package/fieldset/fieldset.min.js +1 -1
- package/fileupload/fileupload.cjs.js +234 -191
- package/fileupload/fileupload.cjs.min.js +1 -1
- package/fileupload/fileupload.d.ts +160 -1
- package/fileupload/fileupload.esm.js +235 -192
- package/fileupload/fileupload.esm.min.js +1 -1
- package/fileupload/fileupload.js +231 -188
- package/fileupload/fileupload.min.js +1 -1
- package/galleria/galleria.cjs.js +139 -124
- package/galleria/galleria.cjs.min.js +1 -1
- package/galleria/galleria.d.ts +156 -2
- package/galleria/galleria.esm.js +141 -126
- package/galleria/galleria.esm.min.js +1 -1
- package/galleria/galleria.js +138 -124
- package/galleria/galleria.min.js +1 -1
- package/hooks/hooks.cjs.js +10 -3
- package/hooks/hooks.cjs.min.js +1 -1
- package/hooks/hooks.esm.js +7 -3
- package/hooks/hooks.esm.min.js +1 -1
- package/hooks/hooks.js +11 -5
- package/hooks/hooks.min.js +1 -1
- package/icons/arrowdown/index.cjs.js +415 -2
- package/icons/arrowdown/index.cjs.min.js +1 -1
- package/icons/arrowdown/index.esm.js +415 -2
- package/icons/arrowdown/index.esm.min.js +1 -1
- package/icons/arrowdown/index.js +415 -2
- package/icons/arrowdown/index.min.js +1 -1
- package/icons/arrowup/index.cjs.js +415 -2
- package/icons/arrowup/index.cjs.min.js +1 -1
- package/icons/arrowup/index.esm.js +415 -2
- package/icons/arrowup/index.esm.min.js +1 -1
- package/icons/arrowup/index.js +415 -2
- package/icons/arrowup/index.min.js +1 -1
- package/icons/ban/index.cjs.js +415 -2
- package/icons/ban/index.cjs.min.js +1 -1
- package/icons/ban/index.esm.js +415 -2
- package/icons/ban/index.esm.min.js +1 -1
- package/icons/ban/index.js +415 -2
- package/icons/ban/index.min.js +1 -1
- package/icons/download/index.cjs.js +415 -2
- package/icons/download/index.cjs.min.js +1 -1
- package/icons/download/index.esm.js +415 -2
- package/icons/download/index.esm.min.js +1 -1
- package/icons/download/index.js +415 -2
- package/icons/download/index.min.js +1 -1
- package/icons/exclamationtriangle/index.cjs.js +415 -2
- package/icons/exclamationtriangle/index.cjs.min.js +1 -1
- package/icons/exclamationtriangle/index.esm.js +415 -2
- package/icons/exclamationtriangle/index.esm.min.js +1 -1
- package/icons/exclamationtriangle/index.js +415 -2
- package/icons/exclamationtriangle/index.min.js +1 -1
- package/icons/eyeslash/index.cjs.js +415 -2
- package/icons/eyeslash/index.cjs.min.js +1 -1
- package/icons/eyeslash/index.esm.js +415 -2
- package/icons/eyeslash/index.esm.min.js +1 -1
- package/icons/eyeslash/index.js +415 -2
- package/icons/eyeslash/index.min.js +1 -1
- package/icons/filter/index.cjs.js +415 -2
- package/icons/filter/index.cjs.min.js +1 -1
- package/icons/filter/index.esm.js +415 -2
- package/icons/filter/index.esm.min.js +1 -1
- package/icons/filter/index.js +415 -2
- package/icons/filter/index.min.js +1 -1
- package/icons/filterslash/index.cjs.js +415 -2
- package/icons/filterslash/index.cjs.min.js +1 -1
- package/icons/filterslash/index.esm.js +415 -2
- package/icons/filterslash/index.esm.min.js +1 -1
- package/icons/filterslash/index.js +415 -2
- package/icons/filterslash/index.min.js +1 -1
- package/icons/infocircle/index.cjs.js +415 -2
- package/icons/infocircle/index.cjs.min.js +1 -1
- package/icons/infocircle/index.esm.js +415 -2
- package/icons/infocircle/index.esm.min.js +1 -1
- package/icons/infocircle/index.js +415 -2
- package/icons/infocircle/index.min.js +1 -1
- package/icons/pencil/index.cjs.js +415 -2
- package/icons/pencil/index.cjs.min.js +1 -1
- package/icons/pencil/index.esm.js +415 -2
- package/icons/pencil/index.esm.min.js +1 -1
- package/icons/pencil/index.js +415 -2
- package/icons/pencil/index.min.js +1 -1
- package/icons/plus/index.cjs.js +415 -2
- package/icons/plus/index.cjs.min.js +1 -1
- package/icons/plus/index.esm.js +415 -2
- package/icons/plus/index.esm.min.js +1 -1
- package/icons/plus/index.js +415 -2
- package/icons/plus/index.min.js +1 -1
- package/icons/refresh/index.cjs.js +415 -2
- package/icons/refresh/index.cjs.min.js +1 -1
- package/icons/refresh/index.esm.js +415 -2
- package/icons/refresh/index.esm.min.js +1 -1
- package/icons/refresh/index.js +415 -2
- package/icons/refresh/index.min.js +1 -1
- package/icons/search/index.cjs.js +415 -2
- package/icons/search/index.cjs.min.js +1 -1
- package/icons/search/index.esm.js +415 -2
- package/icons/search/index.esm.min.js +1 -1
- package/icons/search/index.js +415 -2
- package/icons/search/index.min.js +1 -1
- package/icons/searchminus/index.cjs.js +415 -2
- package/icons/searchminus/index.cjs.min.js +1 -1
- package/icons/searchminus/index.esm.js +415 -2
- package/icons/searchminus/index.esm.min.js +1 -1
- package/icons/searchminus/index.js +415 -2
- package/icons/searchminus/index.min.js +1 -1
- package/icons/searchplus/index.cjs.js +415 -2
- package/icons/searchplus/index.cjs.min.js +1 -1
- package/icons/searchplus/index.esm.js +415 -2
- package/icons/searchplus/index.esm.min.js +1 -1
- package/icons/searchplus/index.js +415 -2
- package/icons/searchplus/index.min.js +1 -1
- package/icons/sortalt/index.cjs.js +415 -2
- package/icons/sortalt/index.cjs.min.js +1 -1
- package/icons/sortalt/index.esm.js +415 -2
- package/icons/sortalt/index.esm.min.js +1 -1
- package/icons/sortalt/index.js +415 -2
- package/icons/sortalt/index.min.js +1 -1
- package/icons/sortamountdown/index.cjs.js +415 -2
- package/icons/sortamountdown/index.cjs.min.js +1 -1
- package/icons/sortamountdown/index.esm.js +415 -2
- package/icons/sortamountdown/index.esm.min.js +1 -1
- package/icons/sortamountdown/index.js +415 -2
- package/icons/sortamountdown/index.min.js +1 -1
- package/icons/sortamountupalt/index.cjs.js +415 -2
- package/icons/sortamountupalt/index.cjs.min.js +1 -1
- package/icons/sortamountupalt/index.esm.js +415 -2
- package/icons/sortamountupalt/index.esm.min.js +1 -1
- package/icons/sortamountupalt/index.js +415 -2
- package/icons/sortamountupalt/index.min.js +1 -1
- package/icons/spinner/index.cjs.js +415 -2
- package/icons/spinner/index.cjs.min.js +1 -1
- package/icons/spinner/index.esm.js +415 -2
- package/icons/spinner/index.esm.min.js +1 -1
- package/icons/spinner/index.js +415 -2
- package/icons/spinner/index.min.js +1 -1
- package/icons/star/index.cjs.js +415 -2
- package/icons/star/index.cjs.min.js +1 -1
- package/icons/star/index.esm.js +415 -2
- package/icons/star/index.esm.min.js +1 -1
- package/icons/star/index.js +415 -2
- package/icons/star/index.min.js +1 -1
- package/icons/starfill/index.cjs.js +415 -2
- package/icons/starfill/index.cjs.min.js +1 -1
- package/icons/starfill/index.esm.js +415 -2
- package/icons/starfill/index.esm.min.js +1 -1
- package/icons/starfill/index.js +415 -2
- package/icons/starfill/index.min.js +1 -1
- package/icons/thlarge/index.cjs.js +415 -2
- package/icons/thlarge/index.cjs.min.js +1 -1
- package/icons/thlarge/index.esm.js +415 -2
- package/icons/thlarge/index.esm.min.js +1 -1
- package/icons/thlarge/index.js +415 -2
- package/icons/thlarge/index.min.js +1 -1
- package/icons/timescircle/index.cjs.js +415 -2
- package/icons/timescircle/index.cjs.min.js +1 -1
- package/icons/timescircle/index.esm.js +415 -2
- package/icons/timescircle/index.esm.min.js +1 -1
- package/icons/timescircle/index.js +415 -2
- package/icons/timescircle/index.min.js +1 -1
- package/icons/trash/index.cjs.js +415 -2
- package/icons/trash/index.cjs.min.js +1 -1
- package/icons/trash/index.esm.js +415 -2
- package/icons/trash/index.esm.min.js +1 -1
- package/icons/trash/index.js +415 -2
- package/icons/trash/index.min.js +1 -1
- package/icons/undo/index.cjs.js +415 -2
- package/icons/undo/index.cjs.min.js +1 -1
- package/icons/undo/index.esm.js +415 -2
- package/icons/undo/index.esm.min.js +1 -1
- package/icons/undo/index.js +415 -2
- package/icons/undo/index.min.js +1 -1
- package/icons/upload/index.cjs.js +415 -2
- package/icons/upload/index.cjs.min.js +1 -1
- package/icons/upload/index.esm.js +415 -2
- package/icons/upload/index.esm.min.js +1 -1
- package/icons/upload/index.js +415 -2
- package/icons/upload/index.min.js +1 -1
- package/icons/windowmaximize/index.cjs.js +415 -2
- package/icons/windowmaximize/index.cjs.min.js +1 -1
- package/icons/windowmaximize/index.esm.js +415 -2
- package/icons/windowmaximize/index.esm.min.js +1 -1
- package/icons/windowmaximize/index.js +415 -2
- package/icons/windowmaximize/index.min.js +1 -1
- package/icons/windowminimize/index.cjs.js +415 -2
- package/icons/windowminimize/index.cjs.min.js +1 -1
- package/icons/windowminimize/index.esm.js +415 -2
- package/icons/windowminimize/index.esm.min.js +1 -1
- package/icons/windowminimize/index.js +415 -2
- package/icons/windowminimize/index.min.js +1 -1
- package/image/image.cjs.js +480 -80
- package/image/image.cjs.min.js +1 -1
- package/image/image.d.ts +130 -3
- package/image/image.esm.js +483 -83
- package/image/image.esm.min.js +1 -1
- package/image/image.js +481 -82
- package/image/image.min.css +1 -1
- package/image/image.min.js +1 -1
- package/inplace/inplace.cjs.js +2 -1
- package/inplace/inplace.cjs.min.js +1 -1
- package/inplace/inplace.esm.js +3 -2
- package/inplace/inplace.esm.min.js +1 -1
- package/inplace/inplace.js +2 -1
- package/inplace/inplace.min.js +1 -1
- package/inputmask/inputmask.cjs.js +26 -26
- package/inputmask/inputmask.cjs.min.js +1 -1
- package/inputmask/inputmask.d.ts +7 -2
- package/inputmask/inputmask.esm.js +27 -27
- package/inputmask/inputmask.esm.min.js +1 -1
- package/inputmask/inputmask.js +26 -28
- package/inputmask/inputmask.min.js +1 -1
- package/inputnumber/inputnumber.cjs.js +68 -48
- package/inputnumber/inputnumber.cjs.min.js +1 -1
- package/inputnumber/inputnumber.d.ts +62 -1
- package/inputnumber/inputnumber.esm.js +66 -49
- package/inputnumber/inputnumber.esm.min.js +1 -1
- package/inputnumber/inputnumber.js +68 -50
- package/inputnumber/inputnumber.min.js +1 -1
- package/inputswitch/inputswitch.cjs.js +84 -25
- package/inputswitch/inputswitch.cjs.min.js +1 -1
- package/inputswitch/inputswitch.d.ts +61 -0
- package/inputswitch/inputswitch.esm.js +85 -26
- package/inputswitch/inputswitch.esm.min.js +1 -1
- package/inputswitch/inputswitch.js +83 -27
- package/inputswitch/inputswitch.min.js +1 -1
- package/inputtext/inputtext.cjs.js +25 -15
- package/inputtext/inputtext.cjs.min.js +1 -1
- package/inputtext/inputtext.d.ts +32 -0
- package/inputtext/inputtext.esm.js +26 -16
- package/inputtext/inputtext.esm.min.js +1 -1
- package/inputtext/inputtext.js +25 -17
- package/inputtext/inputtext.min.js +1 -1
- package/inputtextarea/inputtextarea.cjs.js +25 -15
- package/inputtextarea/inputtextarea.cjs.min.js +1 -1
- package/inputtextarea/inputtextarea.d.ts +33 -1
- package/inputtextarea/inputtextarea.esm.js +26 -16
- package/inputtextarea/inputtextarea.esm.min.js +1 -1
- package/inputtextarea/inputtextarea.js +25 -17
- package/inputtextarea/inputtextarea.min.js +1 -1
- package/keyfilter/keyfilter.cjs.js +25 -9
- package/keyfilter/keyfilter.cjs.min.js +1 -1
- package/keyfilter/keyfilter.esm.js +25 -9
- package/keyfilter/keyfilter.esm.min.js +1 -1
- package/keyfilter/keyfilter.js +25 -11
- package/keyfilter/keyfilter.min.js +1 -1
- package/knob/knob.cjs.js +44 -43
- package/knob/knob.cjs.min.js +1 -1
- package/knob/knob.d.ts +42 -0
- package/knob/knob.esm.js +45 -44
- package/knob/knob.esm.min.js +1 -1
- package/knob/knob.js +44 -45
- package/knob/knob.min.js +1 -1
- package/listbox/listbox.cjs.js +86 -56
- package/listbox/listbox.cjs.min.js +1 -1
- package/listbox/listbox.d.ts +103 -3
- package/listbox/listbox.esm.js +88 -58
- package/listbox/listbox.esm.min.js +1 -1
- package/listbox/listbox.js +86 -57
- package/listbox/listbox.min.js +1 -1
- package/megamenu/megamenu.cjs.js +151 -99
- package/megamenu/megamenu.cjs.min.js +1 -1
- package/megamenu/megamenu.d.ts +142 -2
- package/megamenu/megamenu.esm.js +152 -100
- package/megamenu/megamenu.esm.min.js +1 -1
- package/megamenu/megamenu.js +149 -98
- package/megamenu/megamenu.min.js +1 -1
- package/mention/mention.cjs.js +87 -61
- package/mention/mention.cjs.min.js +1 -1
- package/mention/mention.d.ts +80 -1
- package/mention/mention.esm.js +89 -63
- package/mention/mention.esm.min.js +1 -1
- package/mention/mention.js +88 -63
- package/mention/mention.min.js +1 -1
- package/menu/menu.cjs.js +99 -59
- package/menu/menu.cjs.min.js +1 -1
- package/menu/menu.d.ts +71 -0
- package/menu/menu.esm.js +101 -61
- package/menu/menu.esm.min.js +1 -1
- package/menu/menu.js +100 -61
- package/menu/menu.min.js +1 -1
- package/menubar/menubar.cjs.js +122 -114
- package/menubar/menubar.cjs.min.js +1 -1
- package/menubar/menubar.d.ts +94 -1
- package/menubar/menubar.esm.js +124 -116
- package/menubar/menubar.esm.min.js +1 -1
- package/menubar/menubar.js +122 -115
- package/menubar/menubar.min.js +1 -1
- package/message/message.cjs.js +69 -47
- package/message/message.cjs.min.js +1 -1
- package/message/message.d.ts +35 -2
- package/message/message.esm.js +70 -48
- package/message/message.esm.min.js +1 -1
- package/message/message.js +69 -49
- package/message/message.min.js +1 -1
- package/messages/messages.cjs.js +65 -63
- package/messages/messages.cjs.min.js +1 -1
- package/messages/messages.d.ts +51 -2
- package/messages/messages.esm.js +66 -64
- package/messages/messages.esm.min.js +1 -1
- package/messages/messages.js +65 -64
- package/messages/messages.min.js +1 -1
- package/multiselect/multiselect.cjs.js +249 -193
- package/multiselect/multiselect.cjs.min.js +1 -1
- package/multiselect/multiselect.d.ts +185 -3
- package/multiselect/multiselect.esm.js +252 -196
- package/multiselect/multiselect.esm.min.js +1 -1
- package/multiselect/multiselect.js +249 -194
- package/multiselect/multiselect.min.js +1 -1
- package/multistatecheckbox/multistatecheckbox.cjs.js +47 -33
- package/multistatecheckbox/multistatecheckbox.cjs.min.js +1 -1
- package/multistatecheckbox/multistatecheckbox.d.ts +61 -2
- package/multistatecheckbox/multistatecheckbox.esm.js +49 -35
- package/multistatecheckbox/multistatecheckbox.esm.min.js +1 -1
- package/multistatecheckbox/multistatecheckbox.js +48 -35
- package/multistatecheckbox/multistatecheckbox.min.js +1 -1
- package/orderlist/orderlist.cjs.js +188 -110
- package/orderlist/orderlist.cjs.min.js +1 -1
- package/orderlist/orderlist.d.ts +118 -2
- package/orderlist/orderlist.esm.js +190 -112
- package/orderlist/orderlist.esm.min.js +1 -1
- package/orderlist/orderlist.js +186 -109
- package/orderlist/orderlist.min.js +1 -1
- package/organizationchart/organizationchart.cjs.js +139 -73
- package/organizationchart/organizationchart.cjs.min.js +1 -1
- package/organizationchart/organizationchart.d.ts +89 -2
- package/organizationchart/organizationchart.esm.js +140 -74
- package/organizationchart/organizationchart.esm.min.js +1 -1
- package/organizationchart/organizationchart.js +139 -75
- package/organizationchart/organizationchart.min.js +1 -1
- package/overlaypanel/overlaypanel.cjs.js +7 -6
- package/overlaypanel/overlaypanel.cjs.min.js +1 -1
- package/overlaypanel/overlaypanel.d.ts +5 -0
- package/overlaypanel/overlaypanel.esm.js +8 -7
- package/overlaypanel/overlaypanel.esm.min.js +1 -1
- package/overlaypanel/overlaypanel.js +8 -7
- package/overlaypanel/overlaypanel.min.js +1 -1
- package/package.json +1 -1
- package/paginator/paginator.cjs.js +172 -166
- package/paginator/paginator.cjs.min.js +1 -1
- package/paginator/paginator.d.ts +111 -5
- package/paginator/paginator.esm.js +174 -168
- package/paginator/paginator.esm.min.js +1 -1
- package/paginator/paginator.js +172 -167
- package/paginator/paginator.min.js +1 -1
- package/panel/panel.cjs.js +3 -1
- package/panel/panel.cjs.min.js +1 -1
- package/panel/panel.esm.js +3 -1
- package/panel/panel.esm.min.js +1 -1
- package/panel/panel.js +4 -3
- package/panel/panel.min.js +1 -1
- package/panelmenu/panelmenu.cjs.js +148 -84
- package/panelmenu/panelmenu.cjs.min.js +1 -1
- package/panelmenu/panelmenu.d.ts +124 -2
- package/panelmenu/panelmenu.esm.js +148 -84
- package/panelmenu/panelmenu.esm.min.js +1 -1
- package/panelmenu/panelmenu.js +146 -84
- package/panelmenu/panelmenu.min.js +1 -1
- package/password/password.cjs.js +89 -46
- package/password/password.cjs.min.js +1 -1
- package/password/password.d.ts +98 -2
- package/password/password.esm.js +91 -48
- package/password/password.esm.min.js +1 -1
- package/password/password.js +88 -46
- package/password/password.min.js +1 -1
- package/picklist/picklist.cjs.js +146 -82
- package/picklist/picklist.cjs.min.js +1 -1
- package/picklist/picklist.d.ts +133 -1
- package/picklist/picklist.esm.js +148 -84
- package/picklist/picklist.esm.min.js +1 -1
- package/picklist/picklist.js +143 -80
- package/picklist/picklist.min.js +1 -1
- package/portal/portal.cjs.js +3 -2
- package/portal/portal.cjs.min.js +1 -1
- package/portal/portal.esm.js +3 -2
- package/portal/portal.esm.min.js +1 -1
- package/portal/portal.js +4 -3
- package/portal/portal.min.js +1 -1
- package/primereact.all.cjs.js +6656 -4389
- package/primereact.all.cjs.min.js +1 -1
- package/primereact.all.esm.js +6655 -4390
- package/primereact.all.esm.min.js +1 -1
- package/primereact.all.js +6656 -4389
- package/primereact.all.min.js +1 -1
- package/progressbar/progressbar.cjs.js +3 -1
- package/progressbar/progressbar.cjs.min.js +1 -1
- package/progressbar/progressbar.esm.js +3 -1
- package/progressbar/progressbar.esm.min.js +1 -1
- package/progressbar/progressbar.js +4 -3
- package/progressbar/progressbar.min.js +1 -1
- package/progressspinner/progressspinner.cjs.js +3 -1
- package/progressspinner/progressspinner.cjs.min.js +1 -1
- package/progressspinner/progressspinner.esm.js +3 -1
- package/progressspinner/progressspinner.esm.min.js +1 -1
- package/progressspinner/progressspinner.js +4 -3
- package/progressspinner/progressspinner.min.js +1 -1
- package/radiobutton/radiobutton.cjs.js +90 -30
- package/radiobutton/radiobutton.cjs.min.js +1 -1
- package/radiobutton/radiobutton.d.ts +66 -1
- package/radiobutton/radiobutton.esm.js +91 -31
- package/radiobutton/radiobutton.esm.min.js +1 -1
- package/radiobutton/radiobutton.js +89 -32
- package/radiobutton/radiobutton.min.js +1 -1
- package/rating/rating.cjs.js +47 -36
- package/rating/rating.cjs.min.js +1 -1
- package/rating/rating.d.ts +64 -1
- package/rating/rating.esm.js +48 -37
- package/rating/rating.esm.min.js +1 -1
- package/rating/rating.js +47 -38
- package/rating/rating.min.js +1 -1
- package/resources/primereact.css +475 -465
- package/resources/primereact.min.css +1 -1
- package/resources/themes/arya-blue/theme.css +33 -8
- package/resources/themes/arya-green/theme.css +33 -8
- package/resources/themes/arya-orange/theme.css +33 -8
- package/resources/themes/arya-purple/theme.css +33 -8
- package/resources/themes/bootstrap4-dark-blue/theme.css +33 -8
- package/resources/themes/bootstrap4-dark-purple/theme.css +33 -8
- package/resources/themes/bootstrap4-light-blue/theme.css +33 -8
- package/resources/themes/bootstrap4-light-purple/theme.css +33 -8
- package/resources/themes/fluent-light/theme.css +33 -8
- package/resources/themes/lara-dark-blue/theme.css +33 -8
- package/resources/themes/lara-dark-indigo/theme.css +33 -8
- package/resources/themes/lara-dark-purple/theme.css +33 -8
- package/resources/themes/lara-dark-teal/theme.css +33 -8
- package/resources/themes/lara-light-blue/theme.css +33 -8
- package/resources/themes/lara-light-indigo/theme.css +33 -8
- package/resources/themes/lara-light-purple/theme.css +33 -8
- package/resources/themes/lara-light-teal/theme.css +33 -8
- package/resources/themes/luna-amber/theme.css +33 -8
- package/resources/themes/luna-blue/theme.css +33 -8
- package/resources/themes/luna-green/theme.css +33 -8
- package/resources/themes/luna-pink/theme.css +33 -8
- package/resources/themes/md-dark-deeppurple/theme.css +33 -8
- package/resources/themes/md-dark-indigo/theme.css +33 -8
- package/resources/themes/md-light-deeppurple/theme.css +33 -8
- package/resources/themes/md-light-indigo/theme.css +33 -8
- package/resources/themes/mdc-dark-deeppurple/theme.css +33 -8
- package/resources/themes/mdc-dark-indigo/theme.css +33 -8
- package/resources/themes/mdc-light-deeppurple/theme.css +33 -8
- package/resources/themes/mdc-light-indigo/theme.css +33 -8
- package/resources/themes/mira/theme.css +33 -8
- package/resources/themes/nano/theme.css +33 -8
- package/resources/themes/nova/theme.css +33 -8
- package/resources/themes/nova-accent/theme.css +33 -8
- package/resources/themes/nova-alt/theme.css +33 -8
- package/resources/themes/rhea/theme.css +33 -8
- package/resources/themes/saga-blue/theme.css +33 -8
- package/resources/themes/saga-green/theme.css +33 -8
- package/resources/themes/saga-orange/theme.css +33 -8
- package/resources/themes/saga-purple/theme.css +33 -8
- package/resources/themes/soho-dark/theme.css +33 -8
- package/resources/themes/soho-light/theme.css +33 -8
- package/resources/themes/tailwind-light/theme.css +45 -20
- package/resources/themes/vela-blue/theme.css +33 -8
- package/resources/themes/vela-green/theme.css +33 -8
- package/resources/themes/vela-orange/theme.css +33 -8
- package/resources/themes/vela-purple/theme.css +33 -8
- package/resources/themes/viva-dark/theme.css +33 -8
- package/resources/themes/viva-light/theme.css +33 -8
- package/ripple/ripple.cjs.js +3 -2
- package/ripple/ripple.cjs.min.js +1 -1
- package/ripple/ripple.esm.js +3 -2
- package/ripple/ripple.esm.min.js +1 -1
- package/ripple/ripple.js +4 -3
- package/ripple/ripple.min.js +1 -1
- package/row/row.cjs.js +28 -41
- package/row/row.cjs.min.js +1 -1
- package/row/row.d.ts +28 -0
- package/row/row.esm.js +15 -28
- package/row/row.esm.min.js +1 -1
- package/row/row.js +49 -64
- package/row/row.min.js +1 -1
- package/scrollpanel/scrollpanel.cjs.js +3 -1
- package/scrollpanel/scrollpanel.cjs.min.js +1 -1
- package/scrollpanel/scrollpanel.esm.js +3 -1
- package/scrollpanel/scrollpanel.esm.min.js +1 -1
- package/scrollpanel/scrollpanel.js +4 -3
- package/scrollpanel/scrollpanel.min.js +1 -1
- package/scrolltop/scrolltop.cjs.js +9 -7
- package/scrolltop/scrolltop.cjs.min.js +1 -1
- package/scrolltop/scrolltop.esm.js +11 -9
- package/scrolltop/scrolltop.esm.min.js +1 -1
- package/scrolltop/scrolltop.js +10 -8
- package/scrolltop/scrolltop.min.js +1 -1
- package/selectbutton/selectbutton.cjs.js +37 -25
- package/selectbutton/selectbutton.cjs.min.js +1 -1
- package/selectbutton/selectbutton.d.ts +52 -1
- package/selectbutton/selectbutton.esm.js +38 -26
- package/selectbutton/selectbutton.esm.min.js +1 -1
- package/selectbutton/selectbutton.js +37 -27
- package/selectbutton/selectbutton.min.js +1 -1
- package/sidebar/sidebar.cjs.js +7 -6
- package/sidebar/sidebar.cjs.min.js +1 -1
- package/sidebar/sidebar.esm.js +8 -7
- package/sidebar/sidebar.esm.min.js +1 -1
- package/sidebar/sidebar.js +8 -7
- package/sidebar/sidebar.min.js +1 -1
- package/skeleton/skeleton.cjs.js +4 -3
- package/skeleton/skeleton.cjs.min.js +1 -1
- package/skeleton/skeleton.esm.js +4 -3
- package/skeleton/skeleton.esm.min.js +1 -1
- package/skeleton/skeleton.js +5 -5
- package/skeleton/skeleton.min.js +1 -1
- package/slidemenu/slidemenu.cjs.js +125 -114
- package/slidemenu/slidemenu.cjs.min.js +1 -1
- package/slidemenu/slidemenu.d.ts +103 -1
- package/slidemenu/slidemenu.esm.js +127 -116
- package/slidemenu/slidemenu.esm.min.js +1 -1
- package/slidemenu/slidemenu.js +125 -115
- package/slidemenu/slidemenu.min.js +1 -1
- package/slider/slider.cjs.js +71 -39
- package/slider/slider.cjs.min.js +1 -1
- package/slider/slider.d.ts +34 -1
- package/slider/slider.esm.js +72 -40
- package/slider/slider.esm.min.js +1 -1
- package/slider/slider.js +71 -41
- package/slider/slider.min.js +1 -1
- package/speeddial/speeddial.cjs.js +3 -1
- package/speeddial/speeddial.cjs.min.js +1 -1
- package/speeddial/speeddial.esm.js +3 -1
- package/speeddial/speeddial.esm.min.js +1 -1
- package/speeddial/speeddial.js +4 -3
- package/speeddial/speeddial.min.js +1 -1
- package/splitbutton/splitbutton.cjs.js +74 -63
- package/splitbutton/splitbutton.cjs.min.js +1 -1
- package/splitbutton/splitbutton.d.ts +39 -11
- package/splitbutton/splitbutton.esm.js +76 -65
- package/splitbutton/splitbutton.esm.min.js +1 -1
- package/splitbutton/splitbutton.js +74 -63
- package/splitbutton/splitbutton.min.js +1 -1
- package/splitter/splitter.cjs.js +3 -1
- package/splitter/splitter.cjs.min.js +1 -1
- package/splitter/splitter.d.ts +10 -0
- package/splitter/splitter.esm.js +3 -1
- package/splitter/splitter.esm.min.js +1 -1
- package/splitter/splitter.js +4 -3
- package/splitter/splitter.min.js +1 -1
- package/steps/steps.cjs.js +81 -46
- package/steps/steps.cjs.min.js +1 -1
- package/steps/steps.d.ts +50 -0
- package/steps/steps.esm.js +82 -47
- package/steps/steps.esm.min.js +1 -1
- package/steps/steps.js +81 -48
- package/steps/steps.min.js +1 -1
- package/styleclass/styleclass.cjs.js +3 -1
- package/styleclass/styleclass.cjs.min.js +1 -1
- package/styleclass/styleclass.esm.js +3 -1
- package/styleclass/styleclass.esm.min.js +1 -1
- package/styleclass/styleclass.js +4 -3
- package/styleclass/styleclass.min.js +1 -1
- package/tabmenu/tabmenu.cjs.js +86 -48
- package/tabmenu/tabmenu.cjs.min.js +1 -1
- package/tabmenu/tabmenu.d.ts +62 -0
- package/tabmenu/tabmenu.esm.js +87 -49
- package/tabmenu/tabmenu.esm.min.js +1 -1
- package/tabmenu/tabmenu.js +86 -50
- package/tabmenu/tabmenu.min.js +1 -1
- package/tabview/tabview.cjs.js +8 -5
- package/tabview/tabview.cjs.min.js +1 -1
- package/tabview/tabview.esm.js +9 -6
- package/tabview/tabview.esm.min.js +1 -1
- package/tabview/tabview.js +7 -4
- package/tabview/tabview.min.js +1 -1
- package/tag/tag.cjs.js +3 -1
- package/tag/tag.cjs.min.js +1 -1
- package/tag/tag.esm.js +3 -1
- package/tag/tag.esm.min.js +1 -1
- package/tag/tag.js +4 -3
- package/tag/tag.min.js +1 -1
- package/terminal/terminal.cjs.js +3 -1
- package/terminal/terminal.cjs.min.js +1 -1
- package/terminal/terminal.esm.js +3 -1
- package/terminal/terminal.esm.min.js +1 -1
- package/terminal/terminal.js +4 -3
- package/terminal/terminal.min.js +1 -1
- package/tieredmenu/tieredmenu.cjs.js +110 -64
- package/tieredmenu/tieredmenu.cjs.min.js +1 -1
- package/tieredmenu/tieredmenu.d.ts +83 -2
- package/tieredmenu/tieredmenu.esm.js +112 -66
- package/tieredmenu/tieredmenu.esm.min.js +1 -1
- package/tieredmenu/tieredmenu.js +111 -66
- package/tieredmenu/tieredmenu.min.js +1 -1
- package/timeline/timeline.cjs.js +51 -43
- package/timeline/timeline.cjs.min.js +1 -1
- package/timeline/timeline.d.ts +51 -1
- package/timeline/timeline.esm.js +52 -44
- package/timeline/timeline.esm.min.js +1 -1
- package/timeline/timeline.js +51 -45
- package/timeline/timeline.min.js +1 -1
- package/toast/toast.cjs.js +118 -75
- package/toast/toast.cjs.min.js +1 -1
- package/toast/toast.d.ts +122 -4
- package/toast/toast.esm.js +120 -77
- package/toast/toast.esm.min.js +1 -1
- package/toast/toast.js +116 -74
- package/toast/toast.min.js +1 -1
- package/togglebutton/togglebutton.cjs.js +74 -21
- package/togglebutton/togglebutton.cjs.min.js +1 -1
- package/togglebutton/togglebutton.d.ts +40 -2
- package/togglebutton/togglebutton.esm.js +75 -22
- package/togglebutton/togglebutton.esm.min.js +1 -1
- package/togglebutton/togglebutton.js +73 -23
- package/togglebutton/togglebutton.min.js +1 -1
- package/toolbar/toolbar.cjs.js +3 -1
- package/toolbar/toolbar.cjs.min.js +1 -1
- package/toolbar/toolbar.d.ts +5 -11
- package/toolbar/toolbar.esm.js +3 -1
- package/toolbar/toolbar.esm.min.js +1 -1
- package/toolbar/toolbar.js +4 -3
- package/toolbar/toolbar.min.js +1 -1
- package/tooltip/tooltip.cjs.js +3 -2
- package/tooltip/tooltip.cjs.min.js +1 -1
- package/tooltip/tooltip.d.ts +7 -7
- package/tooltip/tooltip.esm.js +4 -3
- package/tooltip/tooltip.esm.min.js +1 -1
- package/tooltip/tooltip.js +3 -2
- package/tooltip/tooltip.min.js +1 -1
- package/tree/tree.cjs.js +118 -88
- package/tree/tree.cjs.min.js +1 -1
- package/tree/tree.d.ts +139 -1
- package/tree/tree.esm.js +120 -90
- package/tree/tree.esm.min.js +1 -1
- package/tree/tree.js +116 -87
- package/tree/tree.min.js +1 -1
- package/treeselect/treeselect.cjs.js +135 -102
- package/treeselect/treeselect.cjs.min.js +1 -1
- package/treeselect/treeselect.d.ts +143 -2
- package/treeselect/treeselect.esm.js +137 -104
- package/treeselect/treeselect.esm.min.js +1 -1
- package/treeselect/treeselect.js +136 -104
- package/treeselect/treeselect.min.js +1 -1
- package/treetable/treetable.cjs.js +385 -198
- package/treetable/treetable.cjs.min.js +1 -1
- package/treetable/treetable.d.ts +305 -2
- package/treetable/treetable.esm.js +387 -200
- package/treetable/treetable.esm.min.js +1 -1
- package/treetable/treetable.js +383 -197
- package/treetable/treetable.min.js +1 -1
- package/tristatecheckbox/tristatecheckbox.cjs.js +97 -40
- package/tristatecheckbox/tristatecheckbox.cjs.min.js +1 -1
- package/tristatecheckbox/tristatecheckbox.d.ts +64 -1
- package/tristatecheckbox/tristatecheckbox.esm.js +99 -42
- package/tristatecheckbox/tristatecheckbox.esm.min.js +1 -1
- package/tristatecheckbox/tristatecheckbox.js +97 -42
- package/tristatecheckbox/tristatecheckbox.min.js +1 -1
- package/utils/utils.cjs.js +31 -5
- package/utils/utils.cjs.min.js +1 -1
- package/utils/utils.d.ts +1 -1
- package/utils/utils.esm.js +28 -5
- package/utils/utils.esm.min.js +1 -1
- package/utils/utils.js +32 -7
- package/utils/utils.min.js +1 -1
- package/virtualscroller/virtualscroller.cjs.js +43 -29
- package/virtualscroller/virtualscroller.cjs.min.js +1 -1
- package/virtualscroller/virtualscroller.d.ts +78 -1
- package/virtualscroller/virtualscroller.esm.js +44 -30
- package/virtualscroller/virtualscroller.esm.min.js +1 -1
- package/virtualscroller/virtualscroller.js +43 -31
- package/virtualscroller/virtualscroller.min.js +1 -1
- package/web-types.json +1 -1
package/password/password.esm.js
CHANGED
|
@@ -1,27 +1,54 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import PrimeReact, { localeOption } from 'primereact/api';
|
|
2
|
+
import PrimeReact, { PrimeReactContext, localeOption } from 'primereact/api';
|
|
3
3
|
import { CSSTransition } from 'primereact/csstransition';
|
|
4
4
|
import { useOverlayListener, useUnmountEffect } from 'primereact/hooks';
|
|
5
|
+
import { EyeIcon } from 'primereact/icons/eye';
|
|
6
|
+
import { EyeSlashIcon } from 'primereact/icons/eyeslash';
|
|
5
7
|
import { InputText } from 'primereact/inputtext';
|
|
6
8
|
import { OverlayService } from 'primereact/overlayservice';
|
|
7
9
|
import { Portal } from 'primereact/portal';
|
|
8
|
-
import { ObjectUtils, DomHandler, ZIndexUtils, classNames, IconUtils } from 'primereact/utils';
|
|
9
|
-
import {
|
|
10
|
-
import { EyeSlashIcon } from 'primereact/icons/eyeslash';
|
|
10
|
+
import { ObjectUtils, DomHandler, ZIndexUtils, classNames, mergeProps, IconUtils } from 'primereact/utils';
|
|
11
|
+
import { ComponentBase } from 'primereact/componentbase';
|
|
11
12
|
|
|
12
|
-
function
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
13
|
+
function _typeof(obj) {
|
|
14
|
+
"@babel/helpers - typeof";
|
|
15
|
+
|
|
16
|
+
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) {
|
|
17
|
+
return typeof obj;
|
|
18
|
+
} : function (obj) {
|
|
19
|
+
return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
|
20
|
+
}, _typeof(obj);
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
function _toPrimitive(input, hint) {
|
|
24
|
+
if (_typeof(input) !== "object" || input === null) return input;
|
|
25
|
+
var prim = input[Symbol.toPrimitive];
|
|
26
|
+
if (prim !== undefined) {
|
|
27
|
+
var res = prim.call(input, hint || "default");
|
|
28
|
+
if (_typeof(res) !== "object") return res;
|
|
29
|
+
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
30
|
+
}
|
|
31
|
+
return (hint === "string" ? String : Number)(input);
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
function _toPropertyKey(arg) {
|
|
35
|
+
var key = _toPrimitive(arg, "string");
|
|
36
|
+
return _typeof(key) === "symbol" ? key : String(key);
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
function _defineProperty(obj, key, value) {
|
|
40
|
+
key = _toPropertyKey(key);
|
|
41
|
+
if (key in obj) {
|
|
42
|
+
Object.defineProperty(obj, key, {
|
|
43
|
+
value: value,
|
|
44
|
+
enumerable: true,
|
|
45
|
+
configurable: true,
|
|
46
|
+
writable: true
|
|
47
|
+
});
|
|
48
|
+
} else {
|
|
49
|
+
obj[key] = value;
|
|
50
|
+
}
|
|
51
|
+
return obj;
|
|
25
52
|
}
|
|
26
53
|
|
|
27
54
|
function _arrayWithHoles(arr) {
|
|
@@ -79,7 +106,7 @@ function _slicedToArray(arr, i) {
|
|
|
79
106
|
return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest();
|
|
80
107
|
}
|
|
81
108
|
|
|
82
|
-
var PasswordBase = {
|
|
109
|
+
var PasswordBase = ComponentBase.extend({
|
|
83
110
|
defaultProps: {
|
|
84
111
|
__TYPE: 'Password',
|
|
85
112
|
id: null,
|
|
@@ -113,17 +140,14 @@ var PasswordBase = {
|
|
|
113
140
|
onShow: null,
|
|
114
141
|
onHide: null,
|
|
115
142
|
children: undefined
|
|
116
|
-
},
|
|
117
|
-
getProps: function getProps(props) {
|
|
118
|
-
return ObjectUtils.getMergedProps(props, PasswordBase.defaultProps);
|
|
119
|
-
},
|
|
120
|
-
getOtherProps: function getOtherProps(props) {
|
|
121
|
-
return ObjectUtils.getDiffProps(props, PasswordBase.defaultProps);
|
|
122
143
|
}
|
|
123
|
-
};
|
|
144
|
+
});
|
|
124
145
|
|
|
146
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
147
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
125
148
|
var Password = /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(function (inProps, ref) {
|
|
126
|
-
var
|
|
149
|
+
var context = React.useContext(PrimeReactContext);
|
|
150
|
+
var props = PasswordBase.getProps(inProps, context);
|
|
127
151
|
var promptLabel = props.promptLabel || localeOption('passwordPrompt');
|
|
128
152
|
var weakLabel = props.weakLabel || localeOption('weak');
|
|
129
153
|
var mediumLabel = props.mediumLabel || localeOption('medium');
|
|
@@ -154,6 +178,17 @@ var Password = /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(function (
|
|
|
154
178
|
var mediumCheckRegExp = React.useRef(new RegExp(props.mediumRegex));
|
|
155
179
|
var strongCheckRegExp = React.useRef(new RegExp(props.strongRegex));
|
|
156
180
|
var type = unmaskedState ? 'text' : 'password';
|
|
181
|
+
var _PasswordBase$setMeta = PasswordBase.setMetaData({
|
|
182
|
+
props: props,
|
|
183
|
+
state: {
|
|
184
|
+
overlayVisible: overlayVisibleState,
|
|
185
|
+
meter: meterState,
|
|
186
|
+
infoText: infoTextState,
|
|
187
|
+
focused: focusedState,
|
|
188
|
+
unmasked: unmaskedState
|
|
189
|
+
}
|
|
190
|
+
}),
|
|
191
|
+
ptm = _PasswordBase$setMeta.ptm;
|
|
157
192
|
var _useOverlayListener = useOverlayListener({
|
|
158
193
|
target: elementRef,
|
|
159
194
|
overlay: overlayRef,
|
|
@@ -215,11 +250,11 @@ var Password = /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(function (
|
|
|
215
250
|
};
|
|
216
251
|
var alignOverlay = function alignOverlay() {
|
|
217
252
|
if (inputRef.current) {
|
|
218
|
-
DomHandler.alignOverlay(overlayRef.current, inputRef.current.parentElement, props.appendTo || PrimeReact.appendTo);
|
|
253
|
+
DomHandler.alignOverlay(overlayRef.current, inputRef.current.parentElement, props.appendTo || context && context.appendTo || PrimeReact.appendTo);
|
|
219
254
|
}
|
|
220
255
|
};
|
|
221
256
|
var onOverlayEnter = function onOverlayEnter() {
|
|
222
|
-
ZIndexUtils.set('overlay', overlayRef.current, PrimeReact.autoZIndex, PrimeReact.zIndex['overlay']);
|
|
257
|
+
ZIndexUtils.set('overlay', overlayRef.current, context && context.autoZIndex || PrimeReact.autoZIndex, context && context.zIndex['overlay'] || PrimeReact.zIndex['overlay']);
|
|
223
258
|
alignOverlay();
|
|
224
259
|
};
|
|
225
260
|
var onOverlayEntered = function onOverlayEntered() {
|
|
@@ -336,12 +371,14 @@ var Password = /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(function (
|
|
|
336
371
|
});
|
|
337
372
|
var createIcon = function createIcon() {
|
|
338
373
|
var icon;
|
|
374
|
+
var hideIconProps = mergeProps(ptm('hideIcon'));
|
|
375
|
+
var showIconProps = mergeProps(ptm('showIcon'));
|
|
339
376
|
if (unmaskedState) {
|
|
340
|
-
icon = props.hideIcon || /*#__PURE__*/React.createElement(EyeSlashIcon,
|
|
377
|
+
icon = props.hideIcon || /*#__PURE__*/React.createElement(EyeSlashIcon, hideIconProps);
|
|
341
378
|
} else {
|
|
342
|
-
icon = props.showIcon || /*#__PURE__*/React.createElement(EyeIcon,
|
|
379
|
+
icon = props.showIcon || /*#__PURE__*/React.createElement(EyeIcon, showIconProps);
|
|
343
380
|
}
|
|
344
|
-
var eyeIcon = IconUtils.getJSXIcon(icon,
|
|
381
|
+
var eyeIcon = IconUtils.getJSXIcon(icon, unmaskedState ? _objectSpread({}, hideIconProps) : _objectSpread({}, showIconProps), {
|
|
345
382
|
props: props
|
|
346
383
|
});
|
|
347
384
|
if (props.toggleMask) {
|
|
@@ -363,8 +400,8 @@ var Password = /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(function (
|
|
|
363
400
|
};
|
|
364
401
|
var createPanel = function createPanel() {
|
|
365
402
|
var panelClassName = classNames('p-password-panel p-component', props.panelClassName, {
|
|
366
|
-
'p-input-filled': PrimeReact.inputStyle === 'filled',
|
|
367
|
-
'p-ripple-disabled': PrimeReact.ripple === false
|
|
403
|
+
'p-input-filled': context && context.inputStyle === 'filled' || PrimeReact.inputStyle === 'filled',
|
|
404
|
+
'p-ripple-disabled': context && context.ripple === false || PrimeReact.ripple === false
|
|
368
405
|
});
|
|
369
406
|
var _ref2 = meterState || {
|
|
370
407
|
strength: '',
|
|
@@ -374,16 +411,25 @@ var Password = /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(function (
|
|
|
374
411
|
width = _ref2.width;
|
|
375
412
|
var header = ObjectUtils.getJSXElement(props.header, props);
|
|
376
413
|
var footer = ObjectUtils.getJSXElement(props.footer, props);
|
|
377
|
-
var
|
|
378
|
-
|
|
379
|
-
|
|
414
|
+
var panelProps = mergeProps({
|
|
415
|
+
ref: overlayRef,
|
|
416
|
+
className: panelClassName,
|
|
417
|
+
style: props.panelStyle,
|
|
418
|
+
onClick: onPanelClick
|
|
419
|
+
}, ptm('panel'));
|
|
420
|
+
var meterProps = mergeProps({
|
|
421
|
+
className: 'p-password-meter'
|
|
422
|
+
}, ptm('meter'));
|
|
423
|
+
var meterLabelProps = mergeProps({
|
|
380
424
|
className: "p-password-strength ".concat(strength),
|
|
381
425
|
style: {
|
|
382
426
|
width: width
|
|
383
427
|
}
|
|
384
|
-
}
|
|
428
|
+
}, ptm('meterLabel'));
|
|
429
|
+
var infoProps = mergeProps({
|
|
385
430
|
className: "p-password-info ".concat(strength)
|
|
386
|
-
},
|
|
431
|
+
}, ptm('info'));
|
|
432
|
+
var content = props.content ? ObjectUtils.getJSXElement(props.content, props) : /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", meterProps, /*#__PURE__*/React.createElement("div", meterLabelProps)), /*#__PURE__*/React.createElement("div", infoProps, infoTextState));
|
|
387
433
|
var panel = /*#__PURE__*/React.createElement(CSSTransition, {
|
|
388
434
|
nodeRef: overlayRef,
|
|
389
435
|
classNames: "p-connected-overlay",
|
|
@@ -398,12 +444,7 @@ var Password = /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(function (
|
|
|
398
444
|
onEntered: onOverlayEntered,
|
|
399
445
|
onExit: onOverlayExit,
|
|
400
446
|
onExited: onOverlayExited
|
|
401
|
-
}, /*#__PURE__*/React.createElement("div",
|
|
402
|
-
ref: overlayRef,
|
|
403
|
-
className: panelClassName,
|
|
404
|
-
style: props.panelStyle,
|
|
405
|
-
onClick: onPanelClick
|
|
406
|
-
}, header, content, footer));
|
|
447
|
+
}, /*#__PURE__*/React.createElement("div", panelProps, header, content, footer));
|
|
407
448
|
return /*#__PURE__*/React.createElement(Portal, {
|
|
408
449
|
element: panel,
|
|
409
450
|
appendTo: props.appendTo
|
|
@@ -418,15 +459,16 @@ var Password = /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(function (
|
|
|
418
459
|
var inputProps = PasswordBase.getOtherProps(props);
|
|
419
460
|
var icon = createIcon();
|
|
420
461
|
var panel = createPanel();
|
|
421
|
-
|
|
462
|
+
var rootProps = mergeProps({
|
|
422
463
|
ref: elementRef,
|
|
423
464
|
id: props.id,
|
|
424
465
|
className: className,
|
|
425
466
|
style: props.style
|
|
426
|
-
},
|
|
467
|
+
}, PasswordBase.getOtherProps(props), ptm('root'));
|
|
468
|
+
var inputTextProps = mergeProps(_objectSpread(_objectSpread({
|
|
427
469
|
ref: inputRef,
|
|
428
470
|
id: props.inputId
|
|
429
|
-
}, inputProps, {
|
|
471
|
+
}, inputProps), {}, {
|
|
430
472
|
type: type,
|
|
431
473
|
className: inputClassName,
|
|
432
474
|
style: props.inputStyle,
|
|
@@ -436,7 +478,8 @@ var Password = /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(function (
|
|
|
436
478
|
onInput: onInput,
|
|
437
479
|
tooltip: props.tooltip,
|
|
438
480
|
tooltipOptions: props.tooltipOptions
|
|
439
|
-
})
|
|
481
|
+
}), ptm('input'));
|
|
482
|
+
return /*#__PURE__*/React.createElement("div", rootProps, /*#__PURE__*/React.createElement(InputText, inputTextProps), icon, panel);
|
|
440
483
|
}));
|
|
441
484
|
Password.displayName = 'Password';
|
|
442
485
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import*as e from"react";import t,{localeOption as
|
|
1
|
+
import*as e from"react";import t,{PrimeReactContext as n,localeOption as r}from"primereact/api";import{CSSTransition as o}from"primereact/csstransition";import{useOverlayListener as l,useUnmountEffect as i}from"primereact/hooks";import{EyeIcon as u}from"primereact/icons/eye";import{EyeSlashIcon as a}from"primereact/icons/eyeslash";import{InputText as c}from"primereact/inputtext";import{OverlayService as p}from"primereact/overlayservice";import{Portal as s}from"primereact/portal";import{ObjectUtils as f,DomHandler as m,ZIndexUtils as d,classNames as y,mergeProps as g,IconUtils as b}from"primereact/utils";import{ComponentBase as v}from"primereact/componentbase";function w(e){return w="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},w(e)}function h(e,t){if("object"!==w(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!==w(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}function E(e){var t=h(e,"string");return"symbol"===w(t)?t:String(t)}function S(e,t,n){return(t=E(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function O(e){if(Array.isArray(e))return e}function x(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,l,i,u=[],a=!0,c=!1;try{if(l=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;a=!1}else for(;!(a=(r=l.call(n)).done)&&(u.push(r.value),u.length!==t);a=!0);}catch(e){c=!0,o=e}finally{try{if(!a&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return u}}function k(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function R(e,t){if(e){if("string"==typeof e)return k(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?k(e,t):void 0}}function I(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function N(e,t){return O(e)||x(e,t)||R(e,t)||I()}var j=v.extend({defaultProps:{__TYPE:"Password",id:null,inputId:null,inputRef:null,promptLabel:null,weakLabel:null,mediumLabel:null,strongLabel:null,mediumRegex:"^(((?=.*[a-z])(?=.*[A-Z]))|((?=.*[a-z])(?=.*[0-9]))|((?=.*[A-Z])(?=.*[0-9])))(?=.{6,})",strongRegex:"^(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.{8,})",feedback:!0,toggleMask:!1,appendTo:null,header:null,content:null,footer:null,showIcon:null,hideIcon:null,icon:null,tooltip:null,tooltipOptions:null,style:null,className:null,inputStyle:null,inputClassName:null,panelStyle:null,panelClassName:null,transitionOptions:null,onInput:null,onShow:null,onHide:null,children:void 0}});function P(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function C(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?P(Object(n),!0).forEach((function(t){S(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):P(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var T=e.memo(e.forwardRef((function(v,w){var h=e.useContext(n),E=j.getProps(v,h),S=E.promptLabel||r("passwordPrompt"),O=E.weakLabel||r("weak"),x=E.mediumLabel||r("medium"),k=E.strongLabel||r("strong"),R=N(e.useState(!1),2),I=R[0],P=R[1],T=N(e.useState(null),2),A=T[0],L=T[1],M=N(e.useState(S),2),z=M[0],D=M[1],J=N(e.useState(!1),2),X=J[0],Z=J[1],F=N(e.useState(!1),2),H=F[0],U=F[1],B=e.useRef(null),K=e.useRef(null),V=e.useRef(E.inputRef),_=e.useRef(new RegExp(E.mediumRegex)),Y=e.useRef(new RegExp(E.strongRegex)),$=H?"text":"password",q=j.setMetaData({props:E,state:{overlayVisible:I,meter:A,infoText:z,focused:X,unmasked:H}}).ptm,G=N(l({target:B,overlay:K,listener:function(e,t){t.valid&&ie()},when:I}),2),Q=G[0],W=G[1],ee=V.current&&V.current.value,te=e.useMemo((function(){return f.isNotEmpty(E.value)||f.isNotEmpty(E.defaultValue)||f.isNotEmpty(ee)}),[E.value,E.defaultValue,ee]),ne=function(){if(A){var e=null;switch(A.strength){case"weak":e=O;break;case"medium":e=x;break;case"strong":e=k}e&&z!==e&&D(e)}else z!==S&&D(S)},re=function(e){E.feedback&&p.emit("overlay-click",{originalEvent:e,target:B.current})},oe=function(){U((function(e){return!e}))},le=function(){ne(),P(!0)},ie=function(){P(!1)},ue=function(){d.set("overlay",K.current,h&&h.autoZIndex||t.autoZIndex,h&&h.zIndex.overlay||t.zIndex.overlay),V.current&&m.alignOverlay(K.current,V.current.parentElement,E.appendTo||h&&h.appendTo||t.appendTo)},ae=function(){Q(),E.onShow&&E.onShow()},ce=function(){W()},pe=function(){d.clear(K.current),E.onHide&&E.onHide()},se=function(e){return Y.current.test(e)?3:_.current.test(e)?2:e.length?1:0};e.useImperativeHandle(w,(function(){return{props:E,focus:function(){return m.focus(V.current)},getElement:function(){return B.current},getOverlay:function(){return K.current},getInput:function(){return V.current}}})),e.useEffect((function(){f.combinedRefs(V,E.inputRef)}),[V,E.inputRef]),e.useEffect((function(){_.current=new RegExp(E.mediumRegex)}),[E.mediumRegex]),e.useEffect((function(){Y.current=new RegExp(E.strongRegex)}),[E.strongRegex]),e.useEffect((function(){!te&&m.hasClass(B.current,"p-inputwrapper-filled")&&m.removeClass(B.current,"p-inputwrapper-filled")}),[te]),i((function(){d.clear(K.current)}));var fe,me,de,ye,ge,be,ve,we,he,Ee,Se,Oe=y("p-password p-component p-inputwrapper",{"p-inputwrapper-filled":te,"p-inputwrapper-focus":X,"p-input-icon-right":E.toggleMask},E.className),xe=y("p-password-input",E.inputClassName),ke=j.getOtherProps(E),Re=function(){var t=g(q("hideIcon")),n=g(q("showIcon")),r=b.getJSXIcon(H?E.hideIcon||e.createElement(a,t):E.showIcon||e.createElement(u,n),C({},H?t:n),{props:E});if(E.toggleMask){var o=e.createElement("i",{onClick:oe}," ",r," ");if(E.icon)o=f.getJSXElement(E.icon,{onClick:oe,className:Oe,element:o,props:E});return o}return null}(),Ie=(fe=y("p-password-panel p-component",E.panelClassName,{"p-input-filled":h&&"filled"===h.inputStyle||"filled"===t.inputStyle,"p-ripple-disabled":h&&!1===h.ripple||!1===t.ripple}),de=(me=A||{strength:"",width:"0%"}).strength,ye=me.width,ge=f.getJSXElement(E.header,E),be=f.getJSXElement(E.footer,E),ve=g({ref:K,className:fe,style:E.panelStyle,onClick:re},q("panel")),we=g({className:"p-password-meter"},q("meter")),he=g({className:"p-password-strength ".concat(de),style:{width:ye}},q("meterLabel")),Ee=g({className:"p-password-info ".concat(de)},q("info")),Se=E.content?f.getJSXElement(E.content,E):e.createElement(e.Fragment,null,e.createElement("div",we,e.createElement("div",he)),e.createElement("div",Ee,z)),e.createElement(s,{element:e.createElement(o,{nodeRef:K,classNames:"p-connected-overlay",in:I,timeout:{enter:120,exit:100},options:E.transitionOptions,unmountOnExit:!0,onEnter:ue,onEntered:ae,onExit:ce,onExited:pe},e.createElement("div",ve,ge,Se,be)),appendTo:E.appendTo})),Ne=g({ref:B,id:E.id,className:Oe,style:E.style},j.getOtherProps(E),q("root")),je=g(C(C({ref:V,id:E.inputId},ke),{},{type:$,className:xe,style:E.inputStyle,onFocus:function(e){Z(!0),E.feedback&&le(),E.onFocus&&E.onFocus(e)},onBlur:function(e){Z(!1),E.feedback&&ie(),E.onBlur&&E.onBlur(e)},onKeyUp:function(e){var t=e.keyCode||e.which;if(E.feedback){var n=null,r=null;switch(se(e.target.value)){case 1:n=O,r={strength:"weak",width:"33.33%"};break;case 2:n=x,r={strength:"medium",width:"66.66%"};break;case 3:n=k,r={strength:"strong",width:"100%"};break;default:n=S,r=null}L(r),D(n),t&&!I&&le()}E.onKeyUp&&E.onKeyUp(e)},onInput:function(e,t){E.onInput&&E.onInput(e,t),E.onChange||(f.isNotEmpty(e.target.value)?m.addClass(B.current,"p-inputwrapper-filled"):m.removeClass(B.current,"p-inputwrapper-filled"))},tooltip:E.tooltip,tooltipOptions:E.tooltipOptions}),q("input"));return e.createElement("div",Ne,e.createElement(c,je),Re,Ie)})));T.displayName="Password";export{T as Password};
|
package/password/password.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
this.primereact = this.primereact || {};
|
|
2
|
-
this.primereact.password = (function (exports, React, PrimeReact, csstransition, hooks, inputtext, overlayservice, portal, utils,
|
|
2
|
+
this.primereact.password = (function (exports, React, PrimeReact, csstransition, hooks, eye, eyeslash, inputtext, overlayservice, portal, utils, componentbase) {
|
|
3
3
|
'use strict';
|
|
4
4
|
|
|
5
5
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
@@ -25,19 +25,45 @@ this.primereact.password = (function (exports, React, PrimeReact, csstransition,
|
|
|
25
25
|
var React__namespace = /*#__PURE__*/_interopNamespace(React);
|
|
26
26
|
var PrimeReact__default = /*#__PURE__*/_interopDefaultLegacy(PrimeReact);
|
|
27
27
|
|
|
28
|
-
function
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
28
|
+
function _typeof(obj) {
|
|
29
|
+
"@babel/helpers - typeof";
|
|
30
|
+
|
|
31
|
+
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) {
|
|
32
|
+
return typeof obj;
|
|
33
|
+
} : function (obj) {
|
|
34
|
+
return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
|
35
|
+
}, _typeof(obj);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
function _toPrimitive(input, hint) {
|
|
39
|
+
if (_typeof(input) !== "object" || input === null) return input;
|
|
40
|
+
var prim = input[Symbol.toPrimitive];
|
|
41
|
+
if (prim !== undefined) {
|
|
42
|
+
var res = prim.call(input, hint || "default");
|
|
43
|
+
if (_typeof(res) !== "object") return res;
|
|
44
|
+
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
45
|
+
}
|
|
46
|
+
return (hint === "string" ? String : Number)(input);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
function _toPropertyKey(arg) {
|
|
50
|
+
var key = _toPrimitive(arg, "string");
|
|
51
|
+
return _typeof(key) === "symbol" ? key : String(key);
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
function _defineProperty(obj, key, value) {
|
|
55
|
+
key = _toPropertyKey(key);
|
|
56
|
+
if (key in obj) {
|
|
57
|
+
Object.defineProperty(obj, key, {
|
|
58
|
+
value: value,
|
|
59
|
+
enumerable: true,
|
|
60
|
+
configurable: true,
|
|
61
|
+
writable: true
|
|
62
|
+
});
|
|
63
|
+
} else {
|
|
64
|
+
obj[key] = value;
|
|
65
|
+
}
|
|
66
|
+
return obj;
|
|
41
67
|
}
|
|
42
68
|
|
|
43
69
|
function _arrayWithHoles(arr) {
|
|
@@ -95,7 +121,7 @@ this.primereact.password = (function (exports, React, PrimeReact, csstransition,
|
|
|
95
121
|
return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest();
|
|
96
122
|
}
|
|
97
123
|
|
|
98
|
-
var PasswordBase = {
|
|
124
|
+
var PasswordBase = componentbase.ComponentBase.extend({
|
|
99
125
|
defaultProps: {
|
|
100
126
|
__TYPE: 'Password',
|
|
101
127
|
id: null,
|
|
@@ -129,17 +155,14 @@ this.primereact.password = (function (exports, React, PrimeReact, csstransition,
|
|
|
129
155
|
onShow: null,
|
|
130
156
|
onHide: null,
|
|
131
157
|
children: undefined
|
|
132
|
-
},
|
|
133
|
-
getProps: function getProps(props) {
|
|
134
|
-
return utils.ObjectUtils.getMergedProps(props, PasswordBase.defaultProps);
|
|
135
|
-
},
|
|
136
|
-
getOtherProps: function getOtherProps(props) {
|
|
137
|
-
return utils.ObjectUtils.getDiffProps(props, PasswordBase.defaultProps);
|
|
138
158
|
}
|
|
139
|
-
};
|
|
159
|
+
});
|
|
140
160
|
|
|
161
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
162
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
141
163
|
var Password = /*#__PURE__*/React__namespace.memo( /*#__PURE__*/React__namespace.forwardRef(function (inProps, ref) {
|
|
142
|
-
var
|
|
164
|
+
var context = React__namespace.useContext(PrimeReact.PrimeReactContext);
|
|
165
|
+
var props = PasswordBase.getProps(inProps, context);
|
|
143
166
|
var promptLabel = props.promptLabel || PrimeReact.localeOption('passwordPrompt');
|
|
144
167
|
var weakLabel = props.weakLabel || PrimeReact.localeOption('weak');
|
|
145
168
|
var mediumLabel = props.mediumLabel || PrimeReact.localeOption('medium');
|
|
@@ -170,6 +193,17 @@ this.primereact.password = (function (exports, React, PrimeReact, csstransition,
|
|
|
170
193
|
var mediumCheckRegExp = React__namespace.useRef(new RegExp(props.mediumRegex));
|
|
171
194
|
var strongCheckRegExp = React__namespace.useRef(new RegExp(props.strongRegex));
|
|
172
195
|
var type = unmaskedState ? 'text' : 'password';
|
|
196
|
+
var _PasswordBase$setMeta = PasswordBase.setMetaData({
|
|
197
|
+
props: props,
|
|
198
|
+
state: {
|
|
199
|
+
overlayVisible: overlayVisibleState,
|
|
200
|
+
meter: meterState,
|
|
201
|
+
infoText: infoTextState,
|
|
202
|
+
focused: focusedState,
|
|
203
|
+
unmasked: unmaskedState
|
|
204
|
+
}
|
|
205
|
+
}),
|
|
206
|
+
ptm = _PasswordBase$setMeta.ptm;
|
|
173
207
|
var _useOverlayListener = hooks.useOverlayListener({
|
|
174
208
|
target: elementRef,
|
|
175
209
|
overlay: overlayRef,
|
|
@@ -231,11 +265,11 @@ this.primereact.password = (function (exports, React, PrimeReact, csstransition,
|
|
|
231
265
|
};
|
|
232
266
|
var alignOverlay = function alignOverlay() {
|
|
233
267
|
if (inputRef.current) {
|
|
234
|
-
utils.DomHandler.alignOverlay(overlayRef.current, inputRef.current.parentElement, props.appendTo || PrimeReact__default["default"].appendTo);
|
|
268
|
+
utils.DomHandler.alignOverlay(overlayRef.current, inputRef.current.parentElement, props.appendTo || context && context.appendTo || PrimeReact__default["default"].appendTo);
|
|
235
269
|
}
|
|
236
270
|
};
|
|
237
271
|
var onOverlayEnter = function onOverlayEnter() {
|
|
238
|
-
utils.ZIndexUtils.set('overlay', overlayRef.current, PrimeReact__default["default"].autoZIndex, PrimeReact__default["default"].zIndex['overlay']);
|
|
272
|
+
utils.ZIndexUtils.set('overlay', overlayRef.current, context && context.autoZIndex || PrimeReact__default["default"].autoZIndex, context && context.zIndex['overlay'] || PrimeReact__default["default"].zIndex['overlay']);
|
|
239
273
|
alignOverlay();
|
|
240
274
|
};
|
|
241
275
|
var onOverlayEntered = function onOverlayEntered() {
|
|
@@ -352,12 +386,14 @@ this.primereact.password = (function (exports, React, PrimeReact, csstransition,
|
|
|
352
386
|
});
|
|
353
387
|
var createIcon = function createIcon() {
|
|
354
388
|
var icon;
|
|
389
|
+
var hideIconProps = utils.mergeProps(ptm('hideIcon'));
|
|
390
|
+
var showIconProps = utils.mergeProps(ptm('showIcon'));
|
|
355
391
|
if (unmaskedState) {
|
|
356
|
-
icon = props.hideIcon || /*#__PURE__*/React__namespace.createElement(eyeslash.EyeSlashIcon,
|
|
392
|
+
icon = props.hideIcon || /*#__PURE__*/React__namespace.createElement(eyeslash.EyeSlashIcon, hideIconProps);
|
|
357
393
|
} else {
|
|
358
|
-
icon = props.showIcon || /*#__PURE__*/React__namespace.createElement(eye.EyeIcon,
|
|
394
|
+
icon = props.showIcon || /*#__PURE__*/React__namespace.createElement(eye.EyeIcon, showIconProps);
|
|
359
395
|
}
|
|
360
|
-
var eyeIcon = utils.IconUtils.getJSXIcon(icon,
|
|
396
|
+
var eyeIcon = utils.IconUtils.getJSXIcon(icon, unmaskedState ? _objectSpread({}, hideIconProps) : _objectSpread({}, showIconProps), {
|
|
361
397
|
props: props
|
|
362
398
|
});
|
|
363
399
|
if (props.toggleMask) {
|
|
@@ -379,8 +415,8 @@ this.primereact.password = (function (exports, React, PrimeReact, csstransition,
|
|
|
379
415
|
};
|
|
380
416
|
var createPanel = function createPanel() {
|
|
381
417
|
var panelClassName = utils.classNames('p-password-panel p-component', props.panelClassName, {
|
|
382
|
-
'p-input-filled': PrimeReact__default["default"].inputStyle === 'filled',
|
|
383
|
-
'p-ripple-disabled': PrimeReact__default["default"].ripple === false
|
|
418
|
+
'p-input-filled': context && context.inputStyle === 'filled' || PrimeReact__default["default"].inputStyle === 'filled',
|
|
419
|
+
'p-ripple-disabled': context && context.ripple === false || PrimeReact__default["default"].ripple === false
|
|
384
420
|
});
|
|
385
421
|
var _ref2 = meterState || {
|
|
386
422
|
strength: '',
|
|
@@ -390,16 +426,25 @@ this.primereact.password = (function (exports, React, PrimeReact, csstransition,
|
|
|
390
426
|
width = _ref2.width;
|
|
391
427
|
var header = utils.ObjectUtils.getJSXElement(props.header, props);
|
|
392
428
|
var footer = utils.ObjectUtils.getJSXElement(props.footer, props);
|
|
393
|
-
var
|
|
394
|
-
|
|
395
|
-
|
|
429
|
+
var panelProps = utils.mergeProps({
|
|
430
|
+
ref: overlayRef,
|
|
431
|
+
className: panelClassName,
|
|
432
|
+
style: props.panelStyle,
|
|
433
|
+
onClick: onPanelClick
|
|
434
|
+
}, ptm('panel'));
|
|
435
|
+
var meterProps = utils.mergeProps({
|
|
436
|
+
className: 'p-password-meter'
|
|
437
|
+
}, ptm('meter'));
|
|
438
|
+
var meterLabelProps = utils.mergeProps({
|
|
396
439
|
className: "p-password-strength ".concat(strength),
|
|
397
440
|
style: {
|
|
398
441
|
width: width
|
|
399
442
|
}
|
|
400
|
-
}
|
|
443
|
+
}, ptm('meterLabel'));
|
|
444
|
+
var infoProps = utils.mergeProps({
|
|
401
445
|
className: "p-password-info ".concat(strength)
|
|
402
|
-
},
|
|
446
|
+
}, ptm('info'));
|
|
447
|
+
var content = props.content ? utils.ObjectUtils.getJSXElement(props.content, props) : /*#__PURE__*/React__namespace.createElement(React__namespace.Fragment, null, /*#__PURE__*/React__namespace.createElement("div", meterProps, /*#__PURE__*/React__namespace.createElement("div", meterLabelProps)), /*#__PURE__*/React__namespace.createElement("div", infoProps, infoTextState));
|
|
403
448
|
var panel = /*#__PURE__*/React__namespace.createElement(csstransition.CSSTransition, {
|
|
404
449
|
nodeRef: overlayRef,
|
|
405
450
|
classNames: "p-connected-overlay",
|
|
@@ -414,12 +459,7 @@ this.primereact.password = (function (exports, React, PrimeReact, csstransition,
|
|
|
414
459
|
onEntered: onOverlayEntered,
|
|
415
460
|
onExit: onOverlayExit,
|
|
416
461
|
onExited: onOverlayExited
|
|
417
|
-
}, /*#__PURE__*/React__namespace.createElement("div",
|
|
418
|
-
ref: overlayRef,
|
|
419
|
-
className: panelClassName,
|
|
420
|
-
style: props.panelStyle,
|
|
421
|
-
onClick: onPanelClick
|
|
422
|
-
}, header, content, footer));
|
|
462
|
+
}, /*#__PURE__*/React__namespace.createElement("div", panelProps, header, content, footer));
|
|
423
463
|
return /*#__PURE__*/React__namespace.createElement(portal.Portal, {
|
|
424
464
|
element: panel,
|
|
425
465
|
appendTo: props.appendTo
|
|
@@ -434,15 +474,16 @@ this.primereact.password = (function (exports, React, PrimeReact, csstransition,
|
|
|
434
474
|
var inputProps = PasswordBase.getOtherProps(props);
|
|
435
475
|
var icon = createIcon();
|
|
436
476
|
var panel = createPanel();
|
|
437
|
-
|
|
477
|
+
var rootProps = utils.mergeProps({
|
|
438
478
|
ref: elementRef,
|
|
439
479
|
id: props.id,
|
|
440
480
|
className: className,
|
|
441
481
|
style: props.style
|
|
442
|
-
},
|
|
482
|
+
}, PasswordBase.getOtherProps(props), ptm('root'));
|
|
483
|
+
var inputTextProps = utils.mergeProps(_objectSpread(_objectSpread({
|
|
443
484
|
ref: inputRef,
|
|
444
485
|
id: props.inputId
|
|
445
|
-
}, inputProps, {
|
|
486
|
+
}, inputProps), {}, {
|
|
446
487
|
type: type,
|
|
447
488
|
className: inputClassName,
|
|
448
489
|
style: props.inputStyle,
|
|
@@ -452,7 +493,8 @@ this.primereact.password = (function (exports, React, PrimeReact, csstransition,
|
|
|
452
493
|
onInput: onInput,
|
|
453
494
|
tooltip: props.tooltip,
|
|
454
495
|
tooltipOptions: props.tooltipOptions
|
|
455
|
-
})
|
|
496
|
+
}), ptm('input'));
|
|
497
|
+
return /*#__PURE__*/React__namespace.createElement("div", rootProps, /*#__PURE__*/React__namespace.createElement(inputtext.InputText, inputTextProps), icon, panel);
|
|
456
498
|
}));
|
|
457
499
|
Password.displayName = 'Password';
|
|
458
500
|
|
|
@@ -462,4 +504,4 @@ this.primereact.password = (function (exports, React, PrimeReact, csstransition,
|
|
|
462
504
|
|
|
463
505
|
return exports;
|
|
464
506
|
|
|
465
|
-
})({}, React, primereact.api, primereact.csstransition, primereact.hooks, primereact.
|
|
507
|
+
})({}, React, primereact.api, primereact.csstransition, primereact.hooks, primereact.icons.eye, primereact.icons.eyeslash, primereact.inputtext, primereact.overlayservice, primereact.portal, primereact.utils, primereact.componentbase);
|
package/password/password.min.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
this.primereact=this.primereact||{},this.primereact.password=function(e,t,n,r,l,
|
|
1
|
+
this.primereact=this.primereact||{},this.primereact.password=function(e,t,n,r,o,l,a,i,u,c,s,p){"use strict";function f(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}function m(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}var d=m(t),y=f(n);function g(e){return g="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},g(e)}function b(e,t){if("object"!==g(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!==g(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}function v(e){var t=b(e,"string");return"symbol"===g(t)?t:String(t)}function w(e,t,n){return(t=v(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function h(e){if(Array.isArray(e))return e}function O(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,l,a,i=[],u=!0,c=!1;try{if(l=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;u=!1}else for(;!(u=(r=l.call(n)).done)&&(i.push(r.value),i.length!==t);u=!0);}catch(e){c=!0,o=e}finally{try{if(!u&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw o}}return i}}function E(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function S(e,t){if(e){if("string"==typeof e)return E(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?E(e,t):void 0}}function j(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function P(e,t){return h(e)||O(e,t)||S(e,t)||j()}var x=p.ComponentBase.extend({defaultProps:{__TYPE:"Password",id:null,inputId:null,inputRef:null,promptLabel:null,weakLabel:null,mediumLabel:null,strongLabel:null,mediumRegex:"^(((?=.*[a-z])(?=.*[A-Z]))|((?=.*[a-z])(?=.*[0-9]))|((?=.*[A-Z])(?=.*[0-9])))(?=.{6,})",strongRegex:"^(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.{8,})",feedback:!0,toggleMask:!1,appendTo:null,header:null,content:null,footer:null,showIcon:null,hideIcon:null,icon:null,tooltip:null,tooltipOptions:null,style:null,className:null,inputStyle:null,inputClassName:null,panelStyle:null,panelClassName:null,transitionOptions:null,onInput:null,onShow:null,onHide:null,children:void 0}});function I(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function k(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?I(Object(n),!0).forEach((function(t){w(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):I(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var R=d.memo(d.forwardRef((function(e,t){var p=d.useContext(n.PrimeReactContext),f=x.getProps(e,p),m=f.promptLabel||n.localeOption("passwordPrompt"),g=f.weakLabel||n.localeOption("weak"),b=f.mediumLabel||n.localeOption("medium"),v=f.strongLabel||n.localeOption("strong"),w=P(d.useState(!1),2),h=w[0],O=w[1],E=P(d.useState(null),2),S=E[0],j=E[1],I=P(d.useState(m),2),R=I[0],N=I[1],C=P(d.useState(!1),2),U=C[0],D=C[1],T=P(d.useState(!1),2),H=T[0],L=T[1],A=d.useRef(null),M=d.useRef(null),Z=d.useRef(f.inputRef),z=d.useRef(new RegExp(f.mediumRegex)),_=d.useRef(new RegExp(f.strongRegex)),J=H?"text":"password",X=x.setMetaData({props:f,state:{overlayVisible:h,meter:S,infoText:R,focused:U,unmasked:H}}).ptm,B=P(o.useOverlayListener({target:A,overlay:M,listener:function(e,t){t.valid&&W()},when:h}),2),F=B[0],K=B[1],V=Z.current&&Z.current.value,Y=d.useMemo((function(){return s.ObjectUtils.isNotEmpty(f.value)||s.ObjectUtils.isNotEmpty(f.defaultValue)||s.ObjectUtils.isNotEmpty(V)}),[f.value,f.defaultValue,V]),$=function(){if(S){var e=null;switch(S.strength){case"weak":e=g;break;case"medium":e=b;break;case"strong":e=v}e&&R!==e&&N(e)}else R!==m&&N(m)},q=function(e){f.feedback&&u.OverlayService.emit("overlay-click",{originalEvent:e,target:A.current})},G=function(){L((function(e){return!e}))},Q=function(){$(),O(!0)},W=function(){O(!1)},ee=function(){s.ZIndexUtils.set("overlay",M.current,p&&p.autoZIndex||y.default.autoZIndex,p&&p.zIndex.overlay||y.default.zIndex.overlay),Z.current&&s.DomHandler.alignOverlay(M.current,Z.current.parentElement,f.appendTo||p&&p.appendTo||y.default.appendTo)},te=function(){F(),f.onShow&&f.onShow()},ne=function(){K()},re=function(){s.ZIndexUtils.clear(M.current),f.onHide&&f.onHide()},oe=function(e){return _.current.test(e)?3:z.current.test(e)?2:e.length?1:0};d.useImperativeHandle(t,(function(){return{props:f,focus:function(){return s.DomHandler.focus(Z.current)},getElement:function(){return A.current},getOverlay:function(){return M.current},getInput:function(){return Z.current}}})),d.useEffect((function(){s.ObjectUtils.combinedRefs(Z,f.inputRef)}),[Z,f.inputRef]),d.useEffect((function(){z.current=new RegExp(f.mediumRegex)}),[f.mediumRegex]),d.useEffect((function(){_.current=new RegExp(f.strongRegex)}),[f.strongRegex]),d.useEffect((function(){!Y&&s.DomHandler.hasClass(A.current,"p-inputwrapper-filled")&&s.DomHandler.removeClass(A.current,"p-inputwrapper-filled")}),[Y]),o.useUnmountEffect((function(){s.ZIndexUtils.clear(M.current)}));var le,ae,ie,ue,ce,se,pe,fe,me,de,ye,ge=s.classNames("p-password p-component p-inputwrapper",{"p-inputwrapper-filled":Y,"p-inputwrapper-focus":U,"p-input-icon-right":f.toggleMask},f.className),be=s.classNames("p-password-input",f.inputClassName),ve=x.getOtherProps(f),we=function(){var e=s.mergeProps(X("hideIcon")),t=s.mergeProps(X("showIcon")),n=s.IconUtils.getJSXIcon(H?f.hideIcon||d.createElement(a.EyeSlashIcon,e):f.showIcon||d.createElement(l.EyeIcon,t),k({},H?e:t),{props:f});if(f.toggleMask){var r=d.createElement("i",{onClick:G}," ",n," ");if(f.icon)r=s.ObjectUtils.getJSXElement(f.icon,{onClick:G,className:ge,element:r,props:f});return r}return null}(),he=(le=s.classNames("p-password-panel p-component",f.panelClassName,{"p-input-filled":p&&"filled"===p.inputStyle||"filled"===y.default.inputStyle,"p-ripple-disabled":p&&!1===p.ripple||!1===y.default.ripple}),ie=(ae=S||{strength:"",width:"0%"}).strength,ue=ae.width,ce=s.ObjectUtils.getJSXElement(f.header,f),se=s.ObjectUtils.getJSXElement(f.footer,f),pe=s.mergeProps({ref:M,className:le,style:f.panelStyle,onClick:q},X("panel")),fe=s.mergeProps({className:"p-password-meter"},X("meter")),me=s.mergeProps({className:"p-password-strength ".concat(ie),style:{width:ue}},X("meterLabel")),de=s.mergeProps({className:"p-password-info ".concat(ie)},X("info")),ye=f.content?s.ObjectUtils.getJSXElement(f.content,f):d.createElement(d.Fragment,null,d.createElement("div",fe,d.createElement("div",me)),d.createElement("div",de,R)),d.createElement(c.Portal,{element:d.createElement(r.CSSTransition,{nodeRef:M,classNames:"p-connected-overlay",in:h,timeout:{enter:120,exit:100},options:f.transitionOptions,unmountOnExit:!0,onEnter:ee,onEntered:te,onExit:ne,onExited:re},d.createElement("div",pe,ce,ye,se)),appendTo:f.appendTo})),Oe=s.mergeProps({ref:A,id:f.id,className:ge,style:f.style},x.getOtherProps(f),X("root")),Ee=s.mergeProps(k(k({ref:Z,id:f.inputId},ve),{},{type:J,className:be,style:f.inputStyle,onFocus:function(e){D(!0),f.feedback&&Q(),f.onFocus&&f.onFocus(e)},onBlur:function(e){D(!1),f.feedback&&W(),f.onBlur&&f.onBlur(e)},onKeyUp:function(e){var t=e.keyCode||e.which;if(f.feedback){var n=null,r=null;switch(oe(e.target.value)){case 1:n=g,r={strength:"weak",width:"33.33%"};break;case 2:n=b,r={strength:"medium",width:"66.66%"};break;case 3:n=v,r={strength:"strong",width:"100%"};break;default:n=m,r=null}j(r),N(n),t&&!h&&Q()}f.onKeyUp&&f.onKeyUp(e)},onInput:function(e,t){f.onInput&&f.onInput(e,t),f.onChange||(s.ObjectUtils.isNotEmpty(e.target.value)?s.DomHandler.addClass(A.current,"p-inputwrapper-filled"):s.DomHandler.removeClass(A.current,"p-inputwrapper-filled"))},tooltip:f.tooltip,tooltipOptions:f.tooltipOptions}),X("input"));return d.createElement("div",Oe,d.createElement(i.InputText,Ee),we,he)})));return R.displayName="Password",e.Password=R,Object.defineProperty(e,"__esModule",{value:!0}),e}({},React,primereact.api,primereact.csstransition,primereact.hooks,primereact.icons.eye,primereact.icons.eyeslash,primereact.inputtext,primereact.overlayservice,primereact.portal,primereact.utils,primereact.componentbase);
|