argous 1.2.246 → 1.3.2
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/dist/api/WebSocket.d.ts +22 -10
- package/dist/api/WebSocket.js +40 -28
- package/dist/api/index.js +154 -132
- package/dist/api/ws.d.ts +1 -1
- package/dist/api/ws.js +45 -4
- package/dist/components/Alert/Alert.d.ts +19 -5
- package/dist/components/Alert/Alert.js +23 -9
- package/dist/components/Alert/index.d.ts +1 -2
- package/dist/components/ArgousAction/ArgousAction.d.ts +26 -5
- package/dist/components/ArgousAction/ArgousAction.js +25 -11
- package/dist/components/ArgousAction/index.d.ts +1 -2
- package/dist/components/ArgousAvatar/ArgousAvatar.d.ts +3 -14
- package/dist/components/ArgousAvatar/ArgousAvatar.js +54 -66
- package/dist/components/ArgousAvatar/index.d.ts +1 -2
- package/dist/components/ArgousComplexPagination/ArgousComplexPagination.d.ts +3 -76
- package/dist/components/ArgousComplexPagination/ArgousComplexPagination.js +114 -82
- package/dist/components/ArgousComplexPagination/index.d.ts +1 -2
- package/dist/components/ArgousComplexTable/ArgousComplexTable.d.ts +3 -158
- package/dist/components/ArgousComplexTable/ArgousComplexTable.js +94 -80
- package/dist/components/ArgousComplexTable/index.d.ts +1 -2
- package/dist/components/ArgousComplexTableBody/ArgousComplexTableBody.d.ts +7 -177
- package/dist/components/ArgousComplexTableBody/ArgousComplexTableBody.js +126 -100
- package/dist/components/ArgousComplexTableBody/DragAndDrop.d.ts +37 -0
- package/dist/components/ArgousComplexTableBody/DragAndDrop.js +156 -0
- package/dist/components/ArgousComplexTableBody/index.d.ts +1 -2
- package/dist/components/ArgousComplexTableHead/ArgousComplexTableHead.d.ts +3 -73
- package/dist/components/ArgousComplexTableHead/ArgousComplexTableHead.js +72 -51
- package/dist/components/ArgousComplexTableHead/index.d.ts +1 -2
- package/dist/components/ArgousComplexTableToolbar/ArgousComplexTableToolBar.d.ts +3 -58
- package/dist/components/ArgousComplexTableToolbar/ArgousComplexTableToolBar.js +63 -41
- package/dist/components/ArgousComplexTableToolbar/index.d.ts +1 -2
- package/dist/components/ArgousInput/ArgousInput.d.ts +2 -8
- package/dist/components/ArgousInput/ArgousInput.js +27 -13
- package/dist/components/ArgousInput/index.d.ts +1 -2
- package/dist/components/ArgousPagination/ArgousPagination.d.ts +3 -5
- package/dist/components/ArgousPagination/ArgousPagination.js +18 -11
- package/dist/components/ArgousPagination/index.d.ts +1 -2
- package/dist/components/ArgousProgressBar/ArgousProgressBar.d.ts +31 -21
- package/dist/components/ArgousProgressBar/ArgousProgressBar.js +64 -74
- package/dist/components/ArgousProgressBar/index.d.ts +1 -2
- package/dist/components/ArgousSimpleTable/ArgousSimpleTable.d.ts +3 -5
- package/dist/components/ArgousSimpleTable/ArgousSimpleTable.js +43 -33
- package/dist/components/ArgousSimpleTable/index.d.ts +1 -2
- package/dist/components/AutoComplete/AutoComplete.d.ts +2 -8
- package/dist/components/AutoComplete/AutoComplete.js +34 -21
- package/dist/components/AutoComplete/index.d.ts +1 -2
- package/dist/components/AutoCompleteFavorites/AutoCompleteFavorites.d.ts +28 -101
- package/dist/components/AutoCompleteFavorites/AutoCompleteFavorites.js +241 -185
- package/dist/components/AutoCompleteFavorites/index.d.ts +1 -2
- package/dist/components/BarChart/BarChart.d.ts +29 -5
- package/dist/components/BarChart/BarChart.js +22 -8
- package/dist/components/BarChart/index.d.ts +1 -2
- package/dist/components/BarraFerramentas/BarraFerramentas.d.ts +54 -25
- package/dist/components/BarraFerramentas/BarraFerramentas.js +163 -131
- package/dist/components/BarraFerramentas/index.d.ts +1 -2
- package/dist/components/Button/Button.d.ts +54 -5
- package/dist/components/Button/Button.js +25 -11
- package/dist/components/Button/index.d.ts +1 -2
- package/dist/components/Cabecalho/Cabecalho.d.ts +2 -8
- package/dist/components/Cabecalho/Cabecalho.js +46 -32
- package/dist/components/Cabecalho/index.d.ts +1 -2
- package/dist/components/Calendar/Calendar.d.ts +2 -8
- package/dist/components/Calendar/Calendar.js +35 -48
- package/dist/components/Calendar/index.d.ts +1 -2
- package/dist/components/Cam/Cam.d.ts +24 -24
- package/dist/components/Cam/Cam.js +34 -20
- package/dist/components/Cam/index.d.ts +1 -2
- package/dist/components/Carousel/Carousel.d.ts +21 -71
- package/dist/components/Carousel/Carousel.js +125 -111
- package/dist/components/Carousel/index.d.ts +1 -2
- package/dist/components/CartaoUsuario/CartaoUsuario.d.ts +6 -9
- package/dist/components/CartaoUsuario/CartaoUsuario.js +54 -40
- package/dist/components/CartaoUsuario/index.d.ts +1 -2
- package/dist/components/Collapse/Collapse.d.ts +55 -56
- package/dist/components/Collapse/Collapse.js +133 -79
- package/dist/components/Collapse/index.d.ts +1 -3
- package/dist/components/Compartilhar/Compartilhar.d.ts +3 -7
- package/dist/components/Compartilhar/Compartilhar.js +92 -83
- package/dist/components/Compartilhar/index.d.ts +1 -2
- package/dist/components/ConfirmModal/BasicModal.d.ts +1 -1
- package/dist/components/ConfirmModal/BasicModal.js +8 -8
- package/dist/components/ConfirmModal/ModalProvider.d.ts +12 -1
- package/dist/components/ConfirmModal/ModalProvider.js +34 -20
- package/dist/components/ConfirmModal/WrapperModal.d.ts +2 -2
- package/dist/components/ConfirmModal/WrapperModal.js +5 -5
- package/dist/components/ConfirmModal/index.d.ts +6 -20
- package/dist/components/ConfirmModal/index.js +5 -1
- package/dist/components/ContactValidationInput/ContactValidationInput.d.ts +17 -62
- package/dist/components/ContactValidationInput/ContactValidationInput.js +133 -105
- package/dist/components/ContactValidationInput/SealModal.d.ts +1 -1
- package/dist/components/ContactValidationInput/SealModal.js +13 -20
- package/dist/components/ContactValidationInput/index.d.ts +1 -2
- package/dist/components/Document/Icons.d.ts +2 -2
- package/dist/components/Document/Icons.js +46 -25
- package/dist/components/Document/ModalVisualizacaoDocumentos.d.ts +1 -1
- package/dist/components/Document/ModalVisualizacaoDocumentos.js +44 -24
- package/dist/components/Document/Visualizacao.d.ts +1 -1
- package/dist/components/Document/Visualizacao.js +60 -42
- package/dist/components/Document/index.d.ts +3 -3
- package/dist/components/Document/index.js +5 -1
- package/dist/components/DropArea/DropArea.d.ts +8 -21
- package/dist/components/DropArea/DropArea.js +43 -24
- package/dist/components/DropArea/Html5FileSelector.js +8 -9
- package/dist/components/DropArea/index.d.ts +1 -2
- package/dist/components/Editor/Events.d.ts +2 -2
- package/dist/components/Editor/ScriptLoader2.d.ts +2 -2
- package/dist/components/Editor/ScriptLoader2.js +3 -3
- package/dist/components/Editor/Utils.d.ts +4 -4
- package/dist/components/Editor/Utils.js +3 -3
- package/dist/components/Editor/components/Editor.d.ts +2 -2
- package/dist/components/Editor/components/Editor.js +38 -24
- package/dist/components/Editor/components/EditorPropTypes.d.ts +2 -2
- package/dist/components/Editor/components/EditorPropTypes.js +22 -8
- package/dist/components/FilePreparer/FilePreparer.d.ts +16 -26
- package/dist/components/FilePreparer/FilePreparer.js +133 -108
- package/dist/components/FilePreparer/index.d.ts +1 -2
- package/dist/components/FileUploader/FileUploader.d.ts +21 -8
- package/dist/components/FileUploader/FileUploader.js +54 -39
- package/dist/components/FileUploader/index.d.ts +1 -2
- package/dist/components/FormVisualizer/FormVisualizer.d.ts +8 -92
- package/dist/components/FormVisualizer/FormVisualizer.js +119 -80
- package/dist/components/FormVisualizer/index.d.ts +1 -2
- package/dist/components/HalfGauge/HalfGauge.d.ts +23 -82
- package/dist/components/HalfGauge/HalfGauge.js +107 -151
- package/dist/components/HalfGauge/index.d.ts +1 -2
- package/dist/components/Highlight/Highlight.d.ts +20 -7
- package/dist/components/Highlight/Highlight.js +28 -13
- package/dist/components/Highlight/index.d.ts +1 -2
- package/dist/components/ImageResize/ImageResize.d.ts +8 -28
- package/dist/components/ImageResize/ImageResize.js +128 -130
- package/dist/components/ImageResize/index.d.ts +1 -2
- package/dist/components/ImageResizeButton/ImageResizeButton.d.ts +2 -25
- package/dist/components/ImageResizeButton/ImageResizeButton.js +28 -14
- package/dist/components/ImageResizeButton/index.d.ts +1 -2
- package/dist/components/Input/Input.d.ts +2 -8
- package/dist/components/Input/Input.js +27 -13
- package/dist/components/Input/index.d.ts +1 -2
- package/dist/components/InputTags/InputTags.d.ts +2 -8
- package/dist/components/InputTags/InputTags.js +38 -21
- package/dist/components/InputTags/index.d.ts +1 -2
- package/dist/components/ListSelect/ListSelect.d.ts +2 -8
- package/dist/components/ListSelect/ListSelect.js +28 -14
- package/dist/components/ListSelect/index.d.ts +1 -2
- package/dist/components/MaterialButton/MaterialButton.d.ts +30 -12
- package/dist/components/MaterialButton/MaterialButton.js +56 -125
- package/dist/components/MaterialButton/index.d.ts +1 -2
- package/dist/components/MenuBar/MenuBar.d.ts +2 -8
- package/dist/components/MenuBar/MenuBar.js +28 -14
- package/dist/components/MenuBar/index.d.ts +1 -2
- package/dist/components/MonthPicker/MonthPicker.d.ts +2 -8
- package/dist/components/MonthPicker/MonthPicker.js +53 -35
- package/dist/components/MonthPicker/index.d.ts +1 -2
- package/dist/components/MultipleSelect/MultipleSelect.d.ts +2 -8
- package/dist/components/MultipleSelect/MultipleSelect.js +37 -19
- package/dist/components/MultipleSelect/index.d.ts +1 -2
- package/dist/components/OtpInput/OtpInput.d.ts +1 -1
- package/dist/components/OtpInput/OtpInput.js +80 -63
- package/dist/components/OtpInput/index.d.ts +1 -2
- package/dist/components/OutputText/OutputText.d.ts +2 -8
- package/dist/components/OutputText/OutputText.js +25 -11
- package/dist/components/OutputText/index.d.ts +1 -2
- package/dist/components/Pagination/Pagination.d.ts +16 -5
- package/dist/components/Pagination/Pagination.js +22 -8
- package/dist/components/Pagination/index.d.ts +1 -2
- package/dist/components/PercentageDisplay/PercentageDisplay.d.ts +14 -51
- package/dist/components/PercentageDisplay/PercentageDisplay.js +25 -89
- package/dist/components/PercentageDisplay/index.d.ts +1 -2
- package/dist/components/Programa/PageCodeEasterEgg.d.ts +6 -5
- package/dist/components/Programa/PageCodeEasterEgg.js +49 -36
- package/dist/components/Programa/Programa.d.ts +72 -32
- package/dist/components/Programa/Programa.js +78 -28
- package/dist/components/Programa/Tab.d.ts +7 -0
- package/dist/components/Programa/Tab.js +2 -0
- package/dist/components/Programa/TabNavigationRail.d.ts +12 -0
- package/dist/components/Programa/TabNavigationRail.js +76 -0
- package/dist/components/Programa/index.d.ts +1 -2
- package/dist/components/ProgressBar/ProgressBar.d.ts +20 -5
- package/dist/components/ProgressBar/ProgressBar.js +25 -11
- package/dist/components/ProgressBar/index.d.ts +1 -2
- package/dist/components/Select/Select.d.ts +2 -8
- package/dist/components/Select/Select.js +28 -14
- package/dist/components/Select/index.d.ts +1 -2
- package/dist/components/SimpleTable/SimpleTable.d.ts +27 -10
- package/dist/components/SimpleTable/SimpleTable.js +47 -33
- package/dist/components/SimpleTable/index.d.ts +1 -2
- package/dist/components/Stepper/Stepper.d.ts +25 -68
- package/dist/components/Stepper/Stepper.js +200 -181
- package/dist/components/Stepper/index.d.ts +1 -2
- package/dist/components/TablePicker/TablePicker.d.ts +3 -8
- package/dist/components/TablePicker/TablePicker.js +76 -43
- package/dist/components/TablePicker/index.d.ts +1 -2
- package/dist/components/Tabs/Tabs.d.ts +25 -5
- package/dist/components/Tabs/Tabs.js +25 -11
- package/dist/components/Tabs/index.d.ts +1 -2
- package/dist/components/TextArea/TextArea.d.ts +2 -8
- package/dist/components/TextArea/TextArea.js +25 -11
- package/dist/components/TextArea/index.d.ts +1 -2
- package/dist/components/TextToHtml/Cursor.d.ts +1 -1
- package/dist/components/TextToHtml/Cursor.js +26 -12
- package/dist/components/TextToHtml/TextStyles.d.ts +1 -1
- package/dist/components/TextToHtml/TextStyles.js +57 -46
- package/dist/components/TextToHtml/TextToHtml.d.ts +32 -36
- package/dist/components/TextToHtml/TextToHtml.js +76 -56
- package/dist/components/TextToHtml/index.d.ts +1 -2
- package/dist/components/ThreadLog/ThreadLog.d.ts +36 -5
- package/dist/components/ThreadLog/ThreadLog.js +34 -20
- package/dist/components/ThreadLog/index.d.ts +1 -2
- package/dist/components/UserCard/UserCard.d.ts +6 -15
- package/dist/components/UserCard/UserCard.js +51 -37
- package/dist/components/UserCard/index.d.ts +1 -2
- package/dist/components/UtilAutoComplete/UtilAutoComplete.d.ts +32 -97
- package/dist/components/UtilAutoComplete/UtilAutoComplete.js +44 -30
- package/dist/components/UtilAutoComplete/index.d.ts +1 -2
- package/dist/components/UtilTextField/UtilTextField.d.ts +7 -23
- package/dist/components/UtilTextField/UtilTextField.js +36 -20
- package/dist/components/UtilTextField/index.d.ts +1 -2
- package/dist/components/Zoom/Zoom.d.ts +7 -15
- package/dist/components/Zoom/Zoom.js +32 -29
- package/dist/components/Zoom/index.d.ts +1 -2
- package/dist/components/index.d.ts +118 -180
- package/dist/components/index.js +5 -1
- package/dist/fieldsRedux/createField.d.ts +6 -6
- package/dist/fieldsRedux/createField.js +39 -25
- package/dist/fieldsRedux/fieldsRedux.d.ts +3 -58
- package/dist/fieldsRedux/fieldsRedux.js +63 -49
- package/dist/fieldsRedux/index.d.ts +17 -2
- package/dist/fieldsRedux/passFields.d.ts +2 -0
- package/dist/fieldsRedux/passFields.js +33 -19
- package/dist/reducers/index.d.ts +98 -2
- package/dist/reducers/index.js +1 -1
- package/dist/utils/api.d.ts +2 -2
- package/dist/utils/api.js +50 -33
- package/dist/utils/config.js +2 -3
- package/dist/utils/date.js +4 -4
- package/dist/utils/index.d.ts +3 -3
- package/dist/utils/index.js +108 -162
- package/dist/utils/store.js +2 -3
- package/dist/utils/xmlToJson.js +1 -1
- package/lib/api/WebSocket.js +11 -12
- package/lib/api/index.js +14 -14
- package/lib/api/ws.js +48 -4
- package/lib/components/ArgousAvatar/ArgousAvatar.d.ts +1 -1
- package/lib/components/ArgousAvatar/ArgousAvatar.js +20 -54
- package/lib/components/ArgousComplexPagination/ArgousComplexPagination.d.ts +1 -1
- package/lib/components/ArgousComplexPagination/ArgousComplexPagination.js +50 -25
- package/lib/components/ArgousComplexTable/ArgousComplexTable.d.ts +1 -1
- package/lib/components/ArgousComplexTable/ArgousComplexTable.js +15 -15
- package/lib/components/ArgousComplexTableBody/ArgousComplexTableBody.d.ts +1 -1
- package/lib/components/ArgousComplexTableBody/ArgousComplexTableBody.js +121 -106
- package/lib/components/ArgousComplexTableBody/DragAndDrop.js +85 -0
- package/lib/components/ArgousComplexTableHead/ArgousComplexTableHead.js +60 -51
- package/lib/components/ArgousComplexTableToolbar/ArgousComplexTableToolBar.js +21 -12
- package/lib/components/ArgousInput/ArgousInput.js +2 -2
- package/lib/components/ArgousPagination/ArgousPagination.js +12 -4
- package/lib/components/ArgousProgressBar/ArgousProgressBar.js +67 -78
- package/lib/components/ArgousSimpleTable/ArgousSimpleTable.js +12 -18
- package/lib/components/AutoComplete/AutoComplete.js +2 -3
- package/lib/components/AutoCompleteFavorites/AutoCompleteFavorites.d.ts +3 -4
- package/lib/components/AutoCompleteFavorites/AutoCompleteFavorites.js +174 -108
- package/lib/components/BarraFerramentas/BarraFerramentas.d.ts +30 -2
- package/lib/components/BarraFerramentas/BarraFerramentas.js +92 -37
- package/lib/components/Calendar/Calendar.js +7 -42
- package/lib/components/Carousel/Carousel.js +42 -27
- package/lib/components/CartaoUsuario/CartaoUsuario.js +6 -6
- package/lib/components/Collapse/Collapse.d.ts +3 -3
- package/lib/components/Collapse/Collapse.js +92 -57
- package/lib/components/Compartilhar/Compartilhar.js +47 -46
- package/lib/components/ConfirmModal/BasicModal.tsx +1 -1
- package/lib/components/ConfirmModal/WrapperModal.tsx +2 -2
- package/lib/components/ContactValidationInput/ContactValidationInput.d.ts +1 -1
- package/lib/components/ContactValidationInput/ContactValidationInput.js +248 -213
- package/lib/components/ContactValidationInput/SealModal.js +38 -32
- package/lib/components/Document/Icons.js +14 -6
- package/lib/components/Document/ModalVisualizacaoDocumentos.js +9 -2
- package/lib/components/Document/Visualizacao.js +31 -25
- package/lib/components/DropArea/DropArea.js +9 -3
- package/lib/components/Editor/ScriptLoader2.ts +3 -3
- package/lib/components/Editor/Utils.ts +3 -3
- package/lib/components/Editor/components/Editor.tsx +1 -1
- package/lib/components/Editor/tinymce/models/dom/model.min.js +1 -1
- package/lib/components/Editor/tinymce/plugins/accordion/plugin.min.js +1 -1
- package/lib/components/Editor/tinymce/plugins/autolink/plugin.min.js +1 -1
- package/lib/components/Editor/tinymce/plugins/autosave/plugin.min.js +1 -1
- package/lib/components/Editor/tinymce/plugins/charmap/plugin.min.js +1 -1
- package/lib/components/Editor/tinymce/plugins/codesample/plugin.min.js +1 -1
- package/lib/components/Editor/tinymce/plugins/directionality/plugin.min.js +1 -1
- package/lib/components/Editor/tinymce/plugins/fullscreen/plugin.min.js +1 -1
- package/lib/components/Editor/tinymce/plugins/help/plugin.min.js +1 -1
- package/lib/components/Editor/tinymce/plugins/image/plugin.min.js +1 -1
- package/lib/components/Editor/tinymce/plugins/link/plugin.min.js +1 -1
- package/lib/components/Editor/tinymce/plugins/lists/plugin.min.js +1 -1
- package/lib/components/Editor/tinymce/plugins/media/plugin.min.js +1 -1
- package/lib/components/Editor/tinymce/plugins/searchreplace/plugin.min.js +1 -1
- package/lib/components/Editor/tinymce/plugins/table/plugin.js +3 -3
- package/lib/components/Editor/tinymce/plugins/table/plugin.min.js +1 -1
- package/lib/components/Editor/tinymce/plugins/visualchars/plugin.min.js +1 -1
- package/lib/components/Editor/tinymce/themes/silver/theme.js +38 -38
- package/lib/components/Editor/tinymce/themes/silver/theme.min.js +1 -1
- package/lib/components/Editor/tinymce/tinymce.js +12 -12
- package/lib/components/Editor/tinymce/tinymce.min.js +1 -1
- package/lib/components/FilePreparer/FilePreparer.d.ts +1 -1
- package/lib/components/FilePreparer/FilePreparer.js +112 -108
- package/lib/components/FileUploader/FileUploader.js +8 -7
- package/lib/components/FormVisualizer/FormVisualizer.d.ts +5 -7
- package/lib/components/FormVisualizer/FormVisualizer.js +59 -46
- package/lib/components/HalfGauge/HalfGauge.js +87 -85
- package/lib/components/Highlight/Highlight.js +4 -4
- package/lib/components/ImageResize/ImageResize.d.ts +1 -1
- package/lib/components/ImageResize/ImageResize.js +123 -118
- package/lib/components/ImageResizeButton/ImageResizeButton.d.ts +1 -1
- package/lib/components/ImageResizeButton/ImageResizeButton.js +1 -1
- package/lib/components/Input/Input.js +2 -2
- package/lib/components/InputTags/InputTags.js +6 -7
- package/lib/components/MaterialButton/MaterialButton.d.ts +2 -4
- package/lib/components/MaterialButton/MaterialButton.js +50 -125
- package/lib/components/MonthPicker/MonthPicker.js +2 -2
- package/lib/components/OtpInput/OtpInput.tsx +77 -69
- package/lib/components/PercentageDisplay/PercentageDisplay.d.ts +1 -1
- package/lib/components/PercentageDisplay/PercentageDisplay.js +29 -54
- package/lib/components/Programa/PageCodeEasterEgg.js +41 -40
- package/lib/components/Programa/Programa.d.ts +18 -3
- package/lib/components/Programa/Programa.js +60 -7
- package/lib/components/Programa/Tab.ts +8 -0
- package/lib/components/Programa/TabNavigationRail.js +96 -0
- package/lib/components/Stepper/Stepper.d.ts +1 -1
- package/lib/components/Stepper/Stepper.js +222 -190
- package/lib/components/TablePicker/TablePicker.js +11 -6
- package/lib/components/TextToHtml/TextStyles.js +42 -42
- package/lib/components/TextToHtml/TextToHtml.js +102 -92
- package/lib/components/ThreadLog/ThreadLog.js +1 -1
- package/lib/components/UserCard/UserCard.js +6 -6
- package/lib/components/UtilAutoComplete/UtilAutoComplete.d.ts +3 -4
- package/lib/components/UtilAutoComplete/UtilAutoComplete.js +67 -9
- package/lib/components/UtilTextField/UtilTextField.d.ts +1 -1
- package/lib/components/UtilTextField/UtilTextField.js +18 -16
- package/lib/components/Zoom/Zoom.js +6 -3
- package/lib/utils/api.ts +1 -1
- package/lib/utils/index.ts +10 -96
- package/package.json +56 -56
- package/.gitlab-ci.yml +0 -21
- package/dist/components/Cam/cam.css +0 -8
- package/dist/components/ContactValidationInput/style.css +0 -10
- package/dist/components/Document/icons/ai.svg +0 -20
- package/dist/components/Document/icons/audio.svg +0 -16
- package/dist/components/Document/icons/avi.svg +0 -15
- package/dist/components/Document/icons/css.svg +0 -47
- package/dist/components/Document/icons/csv.svg +0 -37
- package/dist/components/Document/icons/dbf.svg +0 -30
- package/dist/components/Document/icons/doc.svg +0 -47
- package/dist/components/Document/icons/dwg.svg +0 -32
- package/dist/components/Document/icons/exe.svg +0 -20
- package/dist/components/Document/icons/file.svg +0 -11
- package/dist/components/Document/icons/fla.svg +0 -23
- package/dist/components/Document/icons/html.svg +0 -23
- package/dist/components/Document/icons/image.svg +0 -16
- package/dist/components/Document/icons/iso.svg +0 -40
- package/dist/components/Document/icons/jpg.svg +0 -33
- package/dist/components/Document/icons/js.svg +0 -40
- package/dist/components/Document/icons/json.svg +0 -45
- package/dist/components/Document/icons/mod.svg +0 -41
- package/dist/components/Document/icons/mp3.svg +0 -36
- package/dist/components/Document/icons/mp4.svg +0 -25
- package/dist/components/Document/icons/pdf.svg +0 -35
- package/dist/components/Document/icons/png.svg +0 -30
- package/dist/components/Document/icons/ppt.svg +0 -31
- package/dist/components/Document/icons/psd.svg +0 -50
- package/dist/components/Document/icons/rtf.svg +0 -35
- package/dist/components/Document/icons/search.svg +0 -20
- package/dist/components/Document/icons/svg.svg +0 -34
- package/dist/components/Document/icons/txt.svg +0 -29
- package/dist/components/Document/icons/video.svg +0 -17
- package/dist/components/Document/icons/xls.svg +0 -31
- package/dist/components/Document/icons/xml.svg +0 -25
- package/dist/components/Document/icons/zip.svg +0 -24
- package/dist/components/Document/icons/zip1.svg +0 -18
- package/dist/components/Editor/skins/content/dark/content.min.css +0 -1
- package/dist/components/Editor/skins/content/default/content.min.css +0 -1
- package/dist/components/Editor/skins/content/document/content.min.css +0 -1
- package/dist/components/Editor/skins/content/tinymce-5/content.min.css +0 -1
- package/dist/components/Editor/skins/content/tinymce-5-dark/content.min.css +0 -1
- package/dist/components/Editor/skins/content/writer/content.min.css +0 -1
- package/dist/components/Editor/skins/ui/oxide/content.inline.min.css +0 -1
- package/dist/components/Editor/skins/ui/oxide/content.min.css +0 -1
- package/dist/components/Editor/skins/ui/oxide/skin.min.css +0 -1
- package/dist/components/Editor/skins/ui/oxide/skin.shadowdom.min.css +0 -1
- package/dist/components/Editor/skins/ui/oxide-dark/content.inline.min.css +0 -1
- package/dist/components/Editor/skins/ui/oxide-dark/content.min.css +0 -1
- package/dist/components/Editor/skins/ui/oxide-dark/skin.min.css +0 -1
- package/dist/components/Editor/skins/ui/oxide-dark/skin.shadowdom.min.css +0 -1
- package/dist/components/Editor/skins/ui/tinymce-5/content.inline.min.css +0 -1
- package/dist/components/Editor/skins/ui/tinymce-5/content.min.css +0 -1
- package/dist/components/Editor/skins/ui/tinymce-5/skin.min.css +0 -1
- package/dist/components/Editor/skins/ui/tinymce-5/skin.shadowdom.min.css +0 -1
- package/dist/components/Editor/skins/ui/tinymce-5-dark/content.inline.min.css +0 -1
- package/dist/components/Editor/skins/ui/tinymce-5-dark/content.min.css +0 -1
- package/dist/components/Editor/skins/ui/tinymce-5-dark/skin.min.css +0 -1
- package/dist/components/Editor/skins/ui/tinymce-5-dark/skin.shadowdom.min.css +0 -1
- package/dist/components/Editor/tinymce/icons/default/icons.js +0 -194
- package/dist/components/Editor/tinymce/icons/default/icons.min.js +0 -1
- package/dist/components/Editor/tinymce/skins/content/dark/content.css +0 -66
- package/dist/components/Editor/tinymce/skins/content/dark/content.min.css +0 -2
- package/dist/components/Editor/tinymce/skins/content/default/content.css +0 -61
- package/dist/components/Editor/tinymce/skins/content/default/content.min.css +0 -2
- package/dist/components/Editor/tinymce/skins/content/document/content.css +0 -66
- package/dist/components/Editor/tinymce/skins/content/document/content.min.css +0 -2
- package/dist/components/Editor/tinymce/skins/content/tinymce-5/content.css +0 -61
- package/dist/components/Editor/tinymce/skins/content/tinymce-5/content.min.css +0 -2
- package/dist/components/Editor/tinymce/skins/content/tinymce-5-dark/content.css +0 -66
- package/dist/components/Editor/tinymce/skins/content/tinymce-5-dark/content.min.css +0 -2
- package/dist/components/Editor/tinymce/skins/content/writer/content.css +0 -62
- package/dist/components/Editor/tinymce/skins/content/writer/content.min.css +0 -2
- package/dist/components/Editor/tinymce/skins/ui/oxide/content.css +0 -785
- package/dist/components/Editor/tinymce/skins/ui/oxide/content.inline.css +0 -779
- package/dist/components/Editor/tinymce/skins/ui/oxide/content.inline.min.css +0 -2
- package/dist/components/Editor/tinymce/skins/ui/oxide/content.min.css +0 -2
- package/dist/components/Editor/tinymce/skins/ui/oxide/skin.css +0 -3763
- package/dist/components/Editor/tinymce/skins/ui/oxide/skin.min.css +0 -2
- package/dist/components/Editor/tinymce/skins/ui/oxide/skin.shadowdom.css +0 -30
- package/dist/components/Editor/tinymce/skins/ui/oxide/skin.shadowdom.min.css +0 -2
- package/dist/components/Editor/tinymce/skins/ui/oxide-dark/content.css +0 -766
- package/dist/components/Editor/tinymce/skins/ui/oxide-dark/content.inline.css +0 -779
- package/dist/components/Editor/tinymce/skins/ui/oxide-dark/content.inline.min.css +0 -2
- package/dist/components/Editor/tinymce/skins/ui/oxide-dark/content.min.css +0 -2
- package/dist/components/Editor/tinymce/skins/ui/oxide-dark/skin.css +0 -3766
- package/dist/components/Editor/tinymce/skins/ui/oxide-dark/skin.min.css +0 -2
- package/dist/components/Editor/tinymce/skins/ui/oxide-dark/skin.shadowdom.css +0 -30
- package/dist/components/Editor/tinymce/skins/ui/oxide-dark/skin.shadowdom.min.css +0 -2
- package/dist/components/Editor/tinymce/skins/ui/tinymce-5/content.css +0 -785
- package/dist/components/Editor/tinymce/skins/ui/tinymce-5/content.inline.css +0 -779
- package/dist/components/Editor/tinymce/skins/ui/tinymce-5/content.inline.min.css +0 -2
- package/dist/components/Editor/tinymce/skins/ui/tinymce-5/content.min.css +0 -2
- package/dist/components/Editor/tinymce/skins/ui/tinymce-5/skin.css +0 -3857
- package/dist/components/Editor/tinymce/skins/ui/tinymce-5/skin.min.css +0 -2
- package/dist/components/Editor/tinymce/skins/ui/tinymce-5/skin.shadowdom.css +0 -30
- package/dist/components/Editor/tinymce/skins/ui/tinymce-5/skin.shadowdom.min.css +0 -2
- package/dist/components/Editor/tinymce/skins/ui/tinymce-5-dark/content.css +0 -766
- package/dist/components/Editor/tinymce/skins/ui/tinymce-5-dark/content.inline.css +0 -779
- package/dist/components/Editor/tinymce/skins/ui/tinymce-5-dark/content.inline.min.css +0 -2
- package/dist/components/Editor/tinymce/skins/ui/tinymce-5-dark/content.min.css +0 -2
- package/dist/components/Editor/tinymce/skins/ui/tinymce-5-dark/skin.css +0 -3857
- package/dist/components/Editor/tinymce/skins/ui/tinymce-5-dark/skin.min.css +0 -2
- package/dist/components/Editor/tinymce/skins/ui/tinymce-5-dark/skin.shadowdom.css +0 -30
- package/dist/components/Editor/tinymce/skins/ui/tinymce-5-dark/skin.shadowdom.min.css +0 -2
- package/dist/components/Editor/tinymce/tinymce.d.ts +0 -3238
- package/dist/components/TextToHtml/icons/resize_area.svg +0 -2
- package/dist/components/TextToHtml/style.css +0 -40
- package/dist/components/Zoom/style.css +0 -25
- package/dist/types.d.ts +0 -164
|
@@ -4,17 +4,17 @@ import { OtpInput } from '../';
|
|
|
4
4
|
import { api, headers } from '../../api';
|
|
5
5
|
import { numbersOnly, useModal } from '../../utils';
|
|
6
6
|
import { setError } from '../../utils/api';
|
|
7
|
-
import { Button, CircularProgress, Grid, IconButton, InputAdornment, TextField, Typography, useTheme } from '@material
|
|
7
|
+
import { Button, CircularProgress, Grid, IconButton, InputAdornment, Stack, TextField, Typography, useTheme } from '@mui/material';
|
|
8
8
|
import React, { useCallback, useEffect, useRef, useState } from 'react';
|
|
9
9
|
import { IoMdCheckmark } from 'react-icons/io';
|
|
10
10
|
import { LiaExclamationTriangleSolid } from 'react-icons/lia';
|
|
11
11
|
import { PiSealCheck } from 'react-icons/pi';
|
|
12
|
-
import MaskedInput from 'react-
|
|
12
|
+
import MaskedInput from '@mona-health/react-input-mask';
|
|
13
13
|
|
|
14
14
|
|
|
15
15
|
const EMAIL_VALIDATION_REGEX = /^[\w-.]+@([\w-]+\.)+[\w-]{2,4}$/;
|
|
16
16
|
|
|
17
|
-
const cellphoneMaskedInput = (props) => <MaskedInput mask='(
|
|
17
|
+
const cellphoneMaskedInput = (props) => <MaskedInput mask='(99) 99999-9999' {...props} />;
|
|
18
18
|
export const SealIcon = PiSealCheck;
|
|
19
19
|
|
|
20
20
|
export const GREEN_COLOR = '#00995D';
|
|
@@ -25,39 +25,48 @@ const RED_COLOR = '#f44336';
|
|
|
25
25
|
const INPUT_ADORNMENT_ICON_SIZE = 18;
|
|
26
26
|
|
|
27
27
|
|
|
28
|
-
const loadingInitialState = {
|
|
29
|
-
input: false,
|
|
30
|
-
validation: false,
|
|
31
|
-
sendValidationLink: false
|
|
28
|
+
const loadingInitialState = {
|
|
29
|
+
input: false,
|
|
30
|
+
validation: false,
|
|
31
|
+
sendValidationLink: false
|
|
32
32
|
};
|
|
33
33
|
|
|
34
34
|
const messageInitialState = { color: '', text: '' };
|
|
35
35
|
|
|
36
|
-
const initialState = {
|
|
37
|
-
loading: loadingInitialState,
|
|
38
|
-
validated: false,
|
|
39
|
-
validating: false,
|
|
40
|
-
searched: false,
|
|
41
|
-
idContato: '',
|
|
42
|
-
cdContato: '',
|
|
43
|
-
code: '',
|
|
44
|
-
message: messageInitialState
|
|
36
|
+
const initialState = {
|
|
37
|
+
loading: loadingInitialState,
|
|
38
|
+
validated: false,
|
|
39
|
+
validating: false,
|
|
40
|
+
searched: false,
|
|
41
|
+
idContato: '',
|
|
42
|
+
cdContato: '',
|
|
43
|
+
code: '',
|
|
44
|
+
message: messageInitialState
|
|
45
45
|
};
|
|
46
46
|
|
|
47
47
|
|
|
48
|
-
const ContactValidationInput = ({
|
|
49
|
-
id,
|
|
50
|
-
type = ('cellphone' || 'email'),
|
|
51
|
-
textFieldProps = {},
|
|
52
|
-
style = {},
|
|
53
|
-
className = '',
|
|
54
|
-
disabled,
|
|
55
|
-
cpf = '',
|
|
56
|
-
userName = '',
|
|
57
|
-
value = '',
|
|
58
|
-
onChange = () => '',
|
|
59
|
-
getComponentData = () => ''
|
|
48
|
+
const ContactValidationInput = ({
|
|
49
|
+
id,
|
|
50
|
+
type = ('cellphone' || 'email'),
|
|
51
|
+
textFieldProps = {},
|
|
52
|
+
style = {},
|
|
53
|
+
className = '',
|
|
54
|
+
disabled,
|
|
55
|
+
cpf = '',
|
|
56
|
+
userName = '',
|
|
57
|
+
value = '',
|
|
58
|
+
onChange = () => '',
|
|
59
|
+
getComponentData = () => ''
|
|
60
60
|
}) => {
|
|
61
|
+
const {
|
|
62
|
+
FormHelperTextProps,
|
|
63
|
+
InputLabelProps,
|
|
64
|
+
InputProps,
|
|
65
|
+
inputProps,
|
|
66
|
+
SelectProps,
|
|
67
|
+
slotProps: textFieldSlotProps = {},
|
|
68
|
+
...resolvedTextFieldProps
|
|
69
|
+
} = textFieldProps;
|
|
61
70
|
|
|
62
71
|
const theme = useTheme();
|
|
63
72
|
const [state, setState] = useState({ ...initialState, inputValue: value });
|
|
@@ -66,9 +75,9 @@ const ContactValidationInput = ({
|
|
|
66
75
|
const sealModal = createModal(SealModal);
|
|
67
76
|
const onChangeRef = useRef(onChange);
|
|
68
77
|
|
|
69
|
-
const logicSetState = ({ type, field, value }) => setState((states) => ({
|
|
70
|
-
...states,
|
|
71
|
-
[type]: (type && field) ? { ...states[type], [field]: value } : value
|
|
78
|
+
const logicSetState = ({ type, field, value }) => setState((states) => ({
|
|
79
|
+
...states,
|
|
80
|
+
[type]: (type && field) ? { ...states[type], [field]: value } : value
|
|
72
81
|
}));
|
|
73
82
|
|
|
74
83
|
const cellphoneType = (type === 'cellphone');
|
|
@@ -88,24 +97,24 @@ const ContactValidationInput = ({
|
|
|
88
97
|
const containerStyle = { gap: 10 };
|
|
89
98
|
const endInputAdornmentStyle = { gap: 7 };
|
|
90
99
|
|
|
91
|
-
const messageStyle = {
|
|
92
|
-
color: (message.color || theme.palette.text.primary),
|
|
93
|
-
fontStyle: 'italic'
|
|
100
|
+
const messageStyle = {
|
|
101
|
+
color: (message.color || theme.palette.text.primary),
|
|
102
|
+
fontStyle: 'italic'
|
|
94
103
|
};
|
|
95
104
|
|
|
96
105
|
const validateCodeButtonsContainerStyle = { gap: 10 };
|
|
97
106
|
|
|
98
|
-
const validateCodeButtonStyle = {
|
|
99
|
-
width: 'calc(100% - 36px - 10px)'
|
|
107
|
+
const validateCodeButtonStyle = {
|
|
108
|
+
width: 'calc(100% - 36px - 10px)'
|
|
100
109
|
};
|
|
101
110
|
|
|
102
|
-
const sealButtonStyle = {
|
|
103
|
-
height: '100%',
|
|
104
|
-
color: GREEN_COLOR,
|
|
105
|
-
border: `2px solid ${GREEN_COLOR}`,
|
|
106
|
-
borderRadius: 4,
|
|
107
|
-
padding: 5,
|
|
108
|
-
fontSize: 22
|
|
111
|
+
const sealButtonStyle = {
|
|
112
|
+
height: '100%',
|
|
113
|
+
color: GREEN_COLOR,
|
|
114
|
+
border: `2px solid ${GREEN_COLOR}`,
|
|
115
|
+
borderRadius: 4,
|
|
116
|
+
padding: 5,
|
|
117
|
+
fontSize: 22
|
|
109
118
|
};
|
|
110
119
|
|
|
111
120
|
|
|
@@ -120,28 +129,28 @@ const ContactValidationInput = ({
|
|
|
120
129
|
|
|
121
130
|
logicSetState({ type: 'loading', field: 'input', value: true });
|
|
122
131
|
|
|
123
|
-
const parameters = {
|
|
124
|
-
method: 'S',
|
|
125
|
-
type: (cellphoneType) ? '1' : (emailType) ? '2' : '',
|
|
126
|
-
cdCpf: numbersOnly(cpf)
|
|
132
|
+
const parameters = {
|
|
133
|
+
method: 'S',
|
|
134
|
+
type: (cellphoneType) ? '1' : (emailType) ? '2' : '',
|
|
135
|
+
cdCpf: numbersOnly(cpf)
|
|
127
136
|
};
|
|
128
137
|
|
|
129
|
-
const fetchOptions = {
|
|
130
|
-
method: 'POST',
|
|
131
|
-
body: JSON.stringify(parameters),
|
|
132
|
-
headers: headers()
|
|
138
|
+
const fetchOptions = {
|
|
139
|
+
method: 'POST',
|
|
140
|
+
body: JSON.stringify(parameters),
|
|
141
|
+
headers: headers()
|
|
133
142
|
};
|
|
134
143
|
|
|
135
144
|
const { status, cdContato, isVerificado } = await fetch(`${api()}agscontactconfirmation.rslvr`, fetchOptions).then(async (response) => await response.json());
|
|
136
145
|
if (status) {
|
|
137
146
|
const newInputValue = (cdContato || '');
|
|
138
147
|
|
|
139
|
-
setState((states) => ({
|
|
140
|
-
...states,
|
|
141
|
-
cdContato,
|
|
142
|
-
inputValue: newInputValue,
|
|
143
|
-
searched: true,
|
|
144
|
-
validated: isVerificado
|
|
148
|
+
setState((states) => ({
|
|
149
|
+
...states,
|
|
150
|
+
cdContato,
|
|
151
|
+
inputValue: newInputValue,
|
|
152
|
+
searched: true,
|
|
153
|
+
validated: isVerificado
|
|
145
154
|
}));
|
|
146
155
|
|
|
147
156
|
let newEvent = new Event('search');
|
|
@@ -161,33 +170,33 @@ const ContactValidationInput = ({
|
|
|
161
170
|
|
|
162
171
|
logicSetState({ type: 'loading', field: 'input', value: true });
|
|
163
172
|
|
|
164
|
-
const parameters = {
|
|
165
|
-
method: 'C',
|
|
166
|
-
type: (cellphoneType) ? '1' : (emailType) ? '2' : '',
|
|
167
|
-
tpMetodo: (emailType) ? '3' : '',
|
|
168
|
-
cdCpf: numbersOnly(cpf),
|
|
169
|
-
dsNome: userName,
|
|
170
|
-
cdContato: formattedInputValue
|
|
173
|
+
const parameters = {
|
|
174
|
+
method: 'C',
|
|
175
|
+
type: (cellphoneType) ? '1' : (emailType) ? '2' : '',
|
|
176
|
+
tpMetodo: (emailType) ? '3' : '',
|
|
177
|
+
cdCpf: numbersOnly(cpf),
|
|
178
|
+
dsNome: userName,
|
|
179
|
+
cdContato: formattedInputValue
|
|
171
180
|
};
|
|
172
181
|
|
|
173
|
-
const fetchOptions = {
|
|
174
|
-
method: 'POST',
|
|
175
|
-
body: JSON.stringify(parameters),
|
|
176
|
-
headers: headers()
|
|
182
|
+
const fetchOptions = {
|
|
183
|
+
method: 'POST',
|
|
184
|
+
body: JSON.stringify(parameters),
|
|
185
|
+
headers: headers()
|
|
177
186
|
};
|
|
178
187
|
|
|
179
188
|
const { status, idContato, cdContato, dsErro } = await fetch(`${api()}agscontactconfirmation.rslvr`, fetchOptions).then(async (response) => await response.json());
|
|
180
189
|
if (status) {
|
|
181
|
-
setState((states) => ({
|
|
182
|
-
...states,
|
|
183
|
-
idContato,
|
|
184
|
-
cdContato,
|
|
185
|
-
validated: false,
|
|
186
|
-
validating: true,
|
|
187
|
-
message: {
|
|
188
|
-
color: ORANGE_COLOR,
|
|
189
|
-
text: (cellphoneType) ? 'Utilize o código recebido via sms' : (emailType) ? 'Utilize o código recebido via e-mail' : ''
|
|
190
|
-
}
|
|
190
|
+
setState((states) => ({
|
|
191
|
+
...states,
|
|
192
|
+
idContato,
|
|
193
|
+
cdContato,
|
|
194
|
+
validated: false,
|
|
195
|
+
validating: true,
|
|
196
|
+
message: {
|
|
197
|
+
color: ORANGE_COLOR,
|
|
198
|
+
text: (cellphoneType) ? 'Utilize o código recebido via sms' : (emailType) ? 'Utilize o código recebido via e-mail' : ''
|
|
199
|
+
}
|
|
191
200
|
}));
|
|
192
201
|
} else {
|
|
193
202
|
(dsErro) && setError(dsErro);
|
|
@@ -201,32 +210,32 @@ const ContactValidationInput = ({
|
|
|
201
210
|
|
|
202
211
|
logicSetState({ type: 'loading', field: 'sendValidationLink', value: true });
|
|
203
212
|
|
|
204
|
-
const parameters = {
|
|
205
|
-
method: 'C',
|
|
206
|
-
type: '2',
|
|
207
|
-
tpMetodo: '4',
|
|
208
|
-
cdCpf: numbersOnly(cpf),
|
|
209
|
-
dsNome: userName,
|
|
210
|
-
cdContato: formattedInputValue
|
|
213
|
+
const parameters = {
|
|
214
|
+
method: 'C',
|
|
215
|
+
type: '2',
|
|
216
|
+
tpMetodo: '4',
|
|
217
|
+
cdCpf: numbersOnly(cpf),
|
|
218
|
+
dsNome: userName,
|
|
219
|
+
cdContato: formattedInputValue
|
|
211
220
|
};
|
|
212
221
|
|
|
213
|
-
const fetchOptions = {
|
|
214
|
-
method: 'POST',
|
|
215
|
-
body: JSON.stringify(parameters),
|
|
216
|
-
headers: headers()
|
|
222
|
+
const fetchOptions = {
|
|
223
|
+
method: 'POST',
|
|
224
|
+
body: JSON.stringify(parameters),
|
|
225
|
+
headers: headers()
|
|
217
226
|
};
|
|
218
227
|
|
|
219
228
|
const { status, cdContato, dsErro } = await fetch(`${api()}agscontactconfirmation.rslvr`, fetchOptions).then(async (response) => await response.json());
|
|
220
229
|
if (status) {
|
|
221
|
-
setState((states) => ({
|
|
222
|
-
...states,
|
|
223
|
-
idContato: '',
|
|
224
|
-
cdContato,
|
|
225
|
-
code: '',
|
|
226
|
-
message: {
|
|
227
|
-
color: '',
|
|
228
|
-
text: `O link de validação foi enviado para o e-mail "${cdContato}"`
|
|
229
|
-
}
|
|
230
|
+
setState((states) => ({
|
|
231
|
+
...states,
|
|
232
|
+
idContato: '',
|
|
233
|
+
cdContato,
|
|
234
|
+
code: '',
|
|
235
|
+
message: {
|
|
236
|
+
color: '',
|
|
237
|
+
text: `O link de validação foi enviado para o e-mail "${cdContato}"`
|
|
238
|
+
}
|
|
230
239
|
}));
|
|
231
240
|
} else {
|
|
232
241
|
(dsErro) && setError(dsErro);
|
|
@@ -240,21 +249,21 @@ const ContactValidationInput = ({
|
|
|
240
249
|
|
|
241
250
|
logicSetState({ type: 'loading', field: (snChancela) ? 'input' : 'validation', value: true });
|
|
242
251
|
|
|
243
|
-
const parameters = {
|
|
244
|
-
method: 'V',
|
|
245
|
-
type: (cellphoneType) ? '1' : (emailType) ? '2' : '',
|
|
246
|
-
cdCpf: numbersOnly(cpf),
|
|
247
|
-
dsNome: userName,
|
|
248
|
-
cdCode: code,
|
|
249
|
-
cdContato: formattedInputValue,
|
|
250
|
-
idContato,
|
|
251
|
-
snChancela
|
|
252
|
+
const parameters = {
|
|
253
|
+
method: 'V',
|
|
254
|
+
type: (cellphoneType) ? '1' : (emailType) ? '2' : '',
|
|
255
|
+
cdCpf: numbersOnly(cpf),
|
|
256
|
+
dsNome: userName,
|
|
257
|
+
cdCode: code,
|
|
258
|
+
cdContato: formattedInputValue,
|
|
259
|
+
idContato,
|
|
260
|
+
snChancela
|
|
252
261
|
};
|
|
253
262
|
|
|
254
|
-
const fetchOptions = {
|
|
255
|
-
method: 'POST',
|
|
256
|
-
body: JSON.stringify(parameters),
|
|
257
|
-
headers: headers()
|
|
263
|
+
const fetchOptions = {
|
|
264
|
+
method: 'POST',
|
|
265
|
+
body: JSON.stringify(parameters),
|
|
266
|
+
headers: headers()
|
|
258
267
|
};
|
|
259
268
|
|
|
260
269
|
const { status, isVerificado } = await fetch(`${api()}agscontactconfirmation.rslvr`, fetchOptions).then(async (response) => await response.json());
|
|
@@ -271,16 +280,16 @@ const ContactValidationInput = ({
|
|
|
271
280
|
messageText = 'Código inválido. Por favor tente novamente.';
|
|
272
281
|
}
|
|
273
282
|
|
|
274
|
-
setState((states) => ({
|
|
275
|
-
...states,
|
|
276
|
-
validated: isVerificado,
|
|
277
|
-
validating: false,
|
|
278
|
-
idContato: '',
|
|
279
|
-
code: '',
|
|
280
|
-
message: {
|
|
281
|
-
color: (isVerificado) ? '' : RED_COLOR,
|
|
282
|
-
text: messageText
|
|
283
|
-
}
|
|
283
|
+
setState((states) => ({
|
|
284
|
+
...states,
|
|
285
|
+
validated: isVerificado,
|
|
286
|
+
validating: false,
|
|
287
|
+
idContato: '',
|
|
288
|
+
code: '',
|
|
289
|
+
message: {
|
|
290
|
+
color: (isVerificado) ? '' : RED_COLOR,
|
|
291
|
+
text: messageText
|
|
292
|
+
}
|
|
284
293
|
}));
|
|
285
294
|
}
|
|
286
295
|
|
|
@@ -296,108 +305,134 @@ const ContactValidationInput = ({
|
|
|
296
305
|
if ((formattedInputValue === cdContato) && validated) logicSetState({ type: 'validating', value: false });
|
|
297
306
|
else if (!(formattedInputValue === cdContato) && validated) logicSetState({ type: 'validating', value: true });
|
|
298
307
|
else if (!(formattedInputValue === cdContato) && validating) {
|
|
299
|
-
setState((states) => ({
|
|
300
|
-
...states,
|
|
301
|
-
idContato: '',
|
|
302
|
-
validated: false,
|
|
303
|
-
validating: false,
|
|
304
|
-
code: '',
|
|
305
|
-
message: messageInitialState
|
|
308
|
+
setState((states) => ({
|
|
309
|
+
...states,
|
|
310
|
+
idContato: '',
|
|
311
|
+
validated: false,
|
|
312
|
+
validating: false,
|
|
313
|
+
code: '',
|
|
314
|
+
message: messageInitialState
|
|
306
315
|
}));
|
|
307
316
|
}
|
|
308
317
|
}, [formattedInputValue, cdContato, validated, validating]);
|
|
309
|
-
useEffect(() =>
|
|
318
|
+
useEffect(() => {
|
|
319
|
+
checkConsistency();
|
|
320
|
+
}, [formattedInputValue, checkConsistency]);
|
|
310
321
|
|
|
311
322
|
useEffect(() => {
|
|
312
323
|
(typeof getComponentData === 'function') && getComponentData(state);
|
|
313
324
|
}, [state, getComponentData]);
|
|
314
325
|
|
|
315
326
|
|
|
316
|
-
return
|
|
317
|
-
<
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
327
|
+
return (
|
|
328
|
+
<Stack {...{ id, className }} style={{ ...style, ...containerStyle }}>
|
|
329
|
+
<TextField
|
|
330
|
+
{...resolvedTextFieldProps}
|
|
331
|
+
disabled={disabledRule}
|
|
332
|
+
value={inputValue}
|
|
333
|
+
onChange={handleOnChange}
|
|
334
|
+
slotProps={{
|
|
335
|
+
...textFieldSlotProps,
|
|
336
|
+
formHelperText: {
|
|
337
|
+
...FormHelperTextProps,
|
|
338
|
+
...textFieldSlotProps.formHelperText
|
|
339
|
+
},
|
|
340
|
+
htmlInput: {
|
|
341
|
+
...inputProps,
|
|
342
|
+
...textFieldSlotProps.htmlInput
|
|
343
|
+
},
|
|
344
|
+
input: {
|
|
345
|
+
...InputProps,
|
|
346
|
+
...textFieldSlotProps.input,
|
|
347
|
+
inputComponent: (cellphoneType) ? cellphoneMaskedInput : textFieldSlotProps.input?.inputComponent,
|
|
348
|
+
endAdornment: (
|
|
349
|
+
<InputAdornment position='end' style={endInputAdornmentStyle}>
|
|
350
|
+
{(validatedRule) && <IoMdCheckmark color={GREEN_COLOR} size={INPUT_ADORNMENT_ICON_SIZE} />}
|
|
351
|
+
{(noValidatedRule) && <LiaExclamationTriangleSolid color={ORANGE_COLOR} size={INPUT_ADORNMENT_ICON_SIZE} />}
|
|
352
|
+
{(loading.input) && <CircularProgress color='secondary' size={INPUT_ADORNMENT_ICON_SIZE} />}
|
|
353
|
+
{(noValidatedRule) && (
|
|
354
|
+
<Button
|
|
355
|
+
size='small'
|
|
356
|
+
variant='contained'
|
|
357
|
+
disableElevation
|
|
358
|
+
disabled={disabledRule || loading.validation || sendValidationCodeButtonDisabled}
|
|
359
|
+
onClick={sendValidationCode}
|
|
360
|
+
>
|
|
361
|
+
Validar
|
|
362
|
+
</Button>
|
|
363
|
+
)}
|
|
364
|
+
</InputAdornment>
|
|
365
|
+
)
|
|
366
|
+
},
|
|
367
|
+
inputLabel: {
|
|
368
|
+
...InputLabelProps,
|
|
369
|
+
...textFieldSlotProps.inputLabel
|
|
370
|
+
},
|
|
371
|
+
select: {
|
|
372
|
+
...SelectProps,
|
|
373
|
+
...textFieldSlotProps.select
|
|
374
|
+
}
|
|
375
|
+
}}
|
|
376
|
+
/>
|
|
377
|
+
{(message.text) && (
|
|
378
|
+
<div>
|
|
379
|
+
<Typography style={messageStyle}>
|
|
380
|
+
{message.text}
|
|
381
|
+
</Typography>
|
|
362
382
|
</div>
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
383
|
+
)}
|
|
384
|
+
{(codeWasSent) && (
|
|
385
|
+
<>
|
|
386
|
+
<div className='otp-input-container'>
|
|
387
|
+
<OtpInput
|
|
388
|
+
autoFocus
|
|
389
|
+
numInputs={5}
|
|
390
|
+
disabled={disabledRule || loading.validation}
|
|
391
|
+
value={code}
|
|
392
|
+
onChange={(newCode) => logicSetState({ type: 'code', value: newCode })}
|
|
393
|
+
/>
|
|
394
|
+
</div>
|
|
395
|
+
<Grid container style={validateCodeButtonsContainerStyle} sx={{
|
|
396
|
+
alignItems: 'center'
|
|
397
|
+
}}>
|
|
398
|
+
<IconButton
|
|
399
|
+
title='Chancelar'
|
|
400
|
+
tabIndex='1'
|
|
401
|
+
size='small'
|
|
402
|
+
disabled={disabledRule || loading.validation || loading.sendValidationLink}
|
|
403
|
+
onClick={toSeal}
|
|
404
|
+
style={sealButtonStyle}
|
|
405
|
+
>
|
|
406
|
+
<SealIcon />
|
|
407
|
+
</IconButton>
|
|
408
|
+
<Button
|
|
409
|
+
color='primary'
|
|
410
|
+
variant='contained'
|
|
411
|
+
disableElevation
|
|
412
|
+
disabled={disabledRule || loading.validation || loading.sendValidationLink || (code.length < 5)}
|
|
413
|
+
startIcon={(loading.validation) ? <CircularProgress color='secondary' size={20} /> : null}
|
|
414
|
+
onClick={validateCode}
|
|
415
|
+
style={validateCodeButtonStyle}
|
|
416
|
+
>
|
|
417
|
+
Validar código
|
|
418
|
+
</Button>
|
|
419
|
+
</Grid>
|
|
420
|
+
{(emailType) && (
|
|
421
|
+
<Button
|
|
422
|
+
variant='contained'
|
|
423
|
+
disableElevation
|
|
424
|
+
disabled={disabledRule || loading.validation || loading.sendValidationLink}
|
|
425
|
+
startIcon={(loading.sendValidationLink) ? <CircularProgress color='secondary' size={20} /> : null}
|
|
426
|
+
onClick={sendValidationLink}
|
|
427
|
+
>
|
|
428
|
+
Enviar link para validação no e-mail
|
|
429
|
+
</Button>
|
|
430
|
+
)}
|
|
431
|
+
</>
|
|
432
|
+
)}
|
|
433
|
+
</Stack>
|
|
434
|
+
);
|
|
400
435
|
};
|
|
401
436
|
|
|
402
437
|
|
|
403
|
-
export default ContactValidationInput;
|
|
438
|
+
export default ContactValidationInput;
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { GREEN_COLOR, SealIcon } from './ContactValidationInput';
|
|
2
|
-
import { Button, Dialog, Grid, Typography } from '@material
|
|
2
|
+
import { Button, Dialog, Grid, Stack, Typography } from '@mui/material';
|
|
3
3
|
import React from 'react';
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
const SealModal = ({ open, proceed }) => {
|
|
7
7
|
|
|
8
|
-
const containerStyle = {
|
|
9
|
-
padding: 20,
|
|
10
|
-
gap: 20
|
|
8
|
+
const containerStyle = {
|
|
9
|
+
padding: 20,
|
|
10
|
+
gap: 20
|
|
11
11
|
};
|
|
12
12
|
|
|
13
13
|
const buttonsContainerStyle = { gap: 20 };
|
|
@@ -16,34 +16,40 @@ const SealModal = ({ open, proceed }) => {
|
|
|
16
16
|
const onClose = () => proceed({ status: false });
|
|
17
17
|
|
|
18
18
|
|
|
19
|
-
return
|
|
20
|
-
<
|
|
21
|
-
<
|
|
22
|
-
<
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
19
|
+
return (
|
|
20
|
+
<Dialog {...{ open, onClose }}>
|
|
21
|
+
<Stack style={containerStyle}>
|
|
22
|
+
<Grid container style={headerContainerStyle} sx={{
|
|
23
|
+
alignItems: 'center'
|
|
24
|
+
}}>
|
|
25
|
+
<Typography variant='h6'>
|
|
26
|
+
Chancela
|
|
27
|
+
</Typography>
|
|
28
|
+
<SealIcon color={GREEN_COLOR} size={20} />
|
|
29
|
+
</Grid>
|
|
30
|
+
<div>
|
|
31
|
+
<Typography>
|
|
32
|
+
Ao confirmar você estará validando o contato com um selo especial
|
|
33
|
+
</Typography>
|
|
34
|
+
</div>
|
|
35
|
+
<Grid container style={buttonsContainerStyle} sx={{
|
|
36
|
+
justifyContent: 'flex-end'
|
|
37
|
+
}}>
|
|
38
|
+
<Button onClick={onClose}>
|
|
39
|
+
Voltar
|
|
40
|
+
</Button>
|
|
41
|
+
<Button
|
|
42
|
+
color='primary'
|
|
43
|
+
variant='contained'
|
|
44
|
+
onClick={(event) => proceed({ status: true })}
|
|
45
|
+
>
|
|
46
|
+
Confirmar
|
|
47
|
+
</Button>
|
|
48
|
+
</Grid>
|
|
49
|
+
</Stack>
|
|
50
|
+
</Dialog>
|
|
51
|
+
);
|
|
46
52
|
};
|
|
47
53
|
|
|
48
54
|
|
|
49
|
-
export default SealModal;
|
|
55
|
+
export default SealModal;
|