@os1-platform/dispatch-mobile 1.3.11 → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +198 -30
- package/android/.gradle/7.0.2/fileHashes/fileHashes.lock +0 -0
- package/android/.gradle/7.2/dependencies-accessors/dependencies-accessors.lock +0 -0
- package/android/.gradle/7.2/executionHistory/executionHistory.bin +0 -0
- package/android/.gradle/7.2/executionHistory/executionHistory.lock +0 -0
- package/android/.gradle/7.2/fileChanges/last-build.bin +0 -0
- package/android/.gradle/7.2/fileHashes/fileHashes.bin +0 -0
- package/android/.gradle/7.2/fileHashes/fileHashes.lock +0 -0
- package/android/.gradle/7.2/fileHashes/resourceHashesCache.bin +0 -0
- package/android/.gradle/7.2/gc.properties +0 -0
- package/android/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
- package/android/.gradle/buildOutputCleanup/cache.properties +2 -2
- package/android/.gradle/buildOutputCleanup/outputFiles.bin +0 -0
- package/android/.gradle/checksums/checksums.lock +0 -0
- package/android/.gradle/checksums/md5-checksums.bin +0 -0
- package/android/.gradle/checksums/sha1-checksums.bin +0 -0
- package/android/.idea/compiler.xml +6 -0
- package/android/.idea/gradle.xml +6 -1
- package/android/.idea/jarRepositories.xml +35 -0
- package/android/.idea/kotlinc.xml +6 -0
- package/android/.idea/misc.xml +6 -1
- package/android/local.properties +1 -1
- package/android/src/main/java/com/dispatchsdk/DispatchSdkPackage.kt +3 -1
- package/android/src/main/java/com/dispatchsdk/sharedPref/SharedPreferenceModule.kt +166 -0
- package/lib/commonjs/@types/assets/index.d.js +2 -0
- package/lib/commonjs/@types/assets/index.d.js.map +1 -0
- package/lib/commonjs/components/dispatch/DispatchExecNavigator.js +4 -4
- package/lib/commonjs/components/dispatch/DispatchExecNavigator.js.map +1 -1
- package/lib/commonjs/components/executiontasks/ExecutionTasksIndex.js +0 -28
- package/lib/commonjs/components/executiontasks/ExecutionTasksIndex.js.map +1 -1
- package/lib/commonjs/components/executiontasks/cancellation/CancelET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/captureInput/CaptureText.js +35 -35
- package/lib/commonjs/components/executiontasks/captureInput/CaptureText.js.map +1 -1
- package/lib/commonjs/components/executiontasks/captureInput/utils.js +13 -0
- package/lib/commonjs/components/executiontasks/captureInput/utils.js.map +1 -0
- package/lib/commonjs/components/executiontasks/deliver/DeliverET.js +2 -2
- package/lib/commonjs/components/executiontasks/deliver/DeliverET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/deliver/DeliverETInput.js.map +1 -1
- package/lib/commonjs/components/executiontasks/deliver/SLDeliverET.js +187 -112
- package/lib/commonjs/components/executiontasks/deliver/SLDeliverET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/display/DisplayModalET.js +16 -16
- package/lib/commonjs/components/executiontasks/display/DisplayModalET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/doodle/SignatureET.js +37 -34
- package/lib/commonjs/components/executiontasks/doodle/SignatureET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/dropCash/DropCashET.js +2 -2
- package/lib/commonjs/components/executiontasks/dropCash/DropCashET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/dropCash/SLDropCash.js +52 -52
- package/lib/commonjs/components/executiontasks/dropCash/SLDropCash.js.map +1 -1
- package/lib/commonjs/components/executiontasks/forms/FormGenerator.js +71 -66
- package/lib/commonjs/components/executiontasks/forms/FormGenerator.js.map +1 -1
- package/lib/commonjs/components/executiontasks/forms/widgets/DateTimeWidget.js.map +1 -1
- package/lib/commonjs/components/executiontasks/forms/widgets/DropdownWidget.js.map +1 -1
- package/lib/commonjs/components/executiontasks/forms/widgets/QRBarcodeScannerWidget.js +1 -1
- package/lib/commonjs/components/executiontasks/forms/widgets/QRBarcodeScannerWidget.js.map +1 -1
- package/lib/commonjs/components/executiontasks/forms/widgets/TimeRangeSelector.js.map +1 -1
- package/lib/commonjs/components/executiontasks/httpRequest/HttpEtUtils.js +2 -2
- package/lib/commonjs/components/executiontasks/httpRequest/HttpEtUtils.js.map +1 -1
- package/lib/commonjs/components/executiontasks/httpRequest/HttpRequestET.js +3 -3
- package/lib/commonjs/components/executiontasks/httpRequest/HttpRequestET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/imageCapture/CaptureSchema.js.map +1 -1
- package/lib/commonjs/components/executiontasks/imageCapture/CaptureUtils.js +6 -3
- package/lib/commonjs/components/executiontasks/imageCapture/CaptureUtils.js.map +1 -1
- package/lib/commonjs/components/executiontasks/imageCapture/ImageCapture.js +34 -34
- package/lib/commonjs/components/executiontasks/imageCapture/ImageCapture.js.map +1 -1
- package/lib/commonjs/components/executiontasks/payments/PaymentUtils.js.map +1 -1
- package/lib/commonjs/components/executiontasks/payments/completePayment/CompletePaymentET.js +54 -54
- package/lib/commonjs/components/executiontasks/payments/completePayment/CompletePaymentET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/payments/init/InitPaymentET.js +33 -33
- package/lib/commonjs/components/executiontasks/payments/init/InitPaymentET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/payments/processPayment/ProcessPaymentET.js +33 -33
- package/lib/commonjs/components/executiontasks/payments/processPayment/ProcessPaymentET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/pickup/PickupET.js +2 -2
- package/lib/commonjs/components/executiontasks/pickup/PickupET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/pickup/SLPickupET.js +112 -47
- package/lib/commonjs/components/executiontasks/pickup/SLPickupET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scan/ScanET.js +326 -428
- package/lib/commonjs/components/executiontasks/scan/ScanET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scan/ScanSchema.js +13 -0
- package/lib/commonjs/components/executiontasks/scan/ScanSchema.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scan/interfaces.js +15 -1
- package/lib/commonjs/components/executiontasks/scan/interfaces.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scan/modalConstant.js +104 -0
- package/lib/commonjs/components/executiontasks/scan/modalConstant.js.map +1 -0
- package/lib/commonjs/components/executiontasks/scan/sub_components/CScanner.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scan/sub_components/DropDownUtils.js +72 -37
- package/lib/commonjs/components/executiontasks/scan/sub_components/DropDownUtils.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scan/sub_components/ERDropDown.js +9 -7
- package/lib/commonjs/components/executiontasks/scan/sub_components/ERDropDown.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scan/sub_components/SummaryPage.js +1099 -0
- package/lib/commonjs/components/executiontasks/scan/sub_components/SummaryPage.js.map +1 -0
- package/lib/commonjs/components/executiontasks/scan/utils.js +548 -159
- package/lib/commonjs/components/executiontasks/scan/utils.js.map +1 -1
- package/lib/commonjs/components/executiontasks/validateOTP/ValidateOTPET.js +52 -53
- package/lib/commonjs/components/executiontasks/validateOTP/ValidateOTPET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/validateOTP/sub-components/OTPInput.js +4 -0
- package/lib/commonjs/components/executiontasks/validateOTP/sub-components/OTPInput.js.map +1 -1
- package/lib/commonjs/components/executiontasks/validateOTP/utils.js.map +1 -1
- package/lib/commonjs/components/executiontasks/verifyLocation/GeofenceUtils.js.map +1 -1
- package/lib/commonjs/components/executiontasks/verifyLocation/VerifyLocationET.js +1 -1
- package/lib/commonjs/components/executiontasks/verifyLocation/VerifyLocationET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/verifyOtp/VerifyOtpET.js +1 -1
- package/lib/commonjs/components/executiontasks/verifyOtp/VerifyOtpET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/verifyOtp/VerifyOtpSchema.js.map +1 -1
- package/lib/commonjs/components/utils/index.js +14 -0
- package/lib/commonjs/components/utils/index.js.map +1 -0
- package/lib/commonjs/components/widgets/AlertDisplay.js.map +1 -1
- package/lib/commonjs/components/widgets/CancelOrderDialog.js.map +1 -1
- package/lib/commonjs/components/widgets/Card.js +88 -0
- package/lib/commonjs/components/widgets/Card.js.map +1 -0
- package/lib/commonjs/components/widgets/GoBackModal.js +48 -0
- package/lib/commonjs/components/widgets/GoBackModal.js.map +1 -0
- package/lib/commonjs/components/widgets/IconButton.js.map +1 -1
- package/lib/commonjs/components/widgets/ModalWidget.js +99 -0
- package/lib/commonjs/components/widgets/ModalWidget.js.map +1 -0
- package/lib/commonjs/components/widgets/ProgressDialog.js.map +1 -1
- package/lib/commonjs/components/widgets/SearchBar.js +74 -0
- package/lib/commonjs/components/widgets/SearchBar.js.map +1 -0
- package/lib/commonjs/components/widgets/SnackBarCustom.js +12 -4
- package/lib/commonjs/components/widgets/SnackBarCustom.js.map +1 -1
- package/lib/commonjs/components/widgets/SplitTextInput.js.map +1 -1
- package/lib/commonjs/components/widgets/TabsComponent.js +64 -0
- package/lib/commonjs/components/widgets/TabsComponent.js.map +1 -0
- package/lib/commonjs/constants/apiConstants.js +3 -1
- package/lib/commonjs/constants/apiConstants.js.map +1 -1
- package/lib/commonjs/constants/constants.js +2 -2
- package/lib/commonjs/constants/constants.js.map +1 -1
- package/lib/commonjs/events/EventDispatcher.js +1 -5
- package/lib/commonjs/events/EventDispatcher.js.map +1 -1
- package/lib/commonjs/events/constants.js +3 -1
- package/lib/commonjs/events/constants.js.map +1 -1
- package/lib/commonjs/events/interface.js.map +1 -1
- package/lib/commonjs/index.js +32 -13
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/manager/dispatch/DispatchStateContainer.js +315 -609
- package/lib/commonjs/manager/dispatch/DispatchStateContainer.js.map +1 -1
- package/lib/commonjs/manager/dispatchCodes/EventCodeContainer.js.map +1 -1
- package/lib/commonjs/manager/dispatchCodes/EventCodeRepo.js.map +1 -1
- package/lib/commonjs/manager/dispatchCodes/ReasonCodeContainer.js.map +1 -1
- package/lib/commonjs/manager/dispatchCodes/ReasonCodeRepo.js.map +1 -1
- package/lib/commonjs/manager/jobRemoval/JobRemovalManager.js +21 -25
- package/lib/commonjs/manager/jobRemoval/JobRemovalManager.js.map +1 -1
- package/lib/commonjs/manager/location/LocationManager.js.map +1 -1
- package/lib/commonjs/manager/sdk/DispatchSDKManager.js +15 -1
- package/lib/commonjs/manager/sdk/DispatchSDKManager.js.map +1 -1
- package/lib/commonjs/manager/sdk/DispatchSdkCache.js +2 -2
- package/lib/commonjs/manager/sdk/DispatchSdkCache.js.map +1 -1
- package/lib/commonjs/manager/sdk/callbacksHandler.js +26 -0
- package/lib/commonjs/manager/sdk/callbacksHandler.js.map +1 -0
- package/lib/commonjs/manager/syncmanager/AppSyncManager.js +15 -1
- package/lib/commonjs/manager/syncmanager/AppSyncManager.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/DBConfig.js +36 -3
- package/lib/commonjs/manager/syncmanager/DBConfig.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/constants.js +17 -0
- package/lib/commonjs/manager/syncmanager/constants.js.map +1 -0
- package/lib/commonjs/manager/syncmanager/database.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/document/DocumentHttpClient.js +11 -17
- package/lib/commonjs/manager/syncmanager/document/DocumentHttpClient.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/document/DocumentManager.js +5 -6
- package/lib/commonjs/manager/syncmanager/document/DocumentManager.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/document/DocumentSyncManager.js +16 -6
- package/lib/commonjs/manager/syncmanager/document/DocumentSyncManager.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/events/ETEventsManager.js +377 -26
- package/lib/commonjs/manager/syncmanager/events/ETEventsManager.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/events/EventsSyncManager.js +183 -65
- package/lib/commonjs/manager/syncmanager/events/EventsSyncManager.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/events/SyncHttpClient.js +150 -37
- package/lib/commonjs/manager/syncmanager/events/SyncHttpClient.js.map +1 -1
- package/lib/commonjs/models/DispatchModels.js.map +1 -1
- package/lib/commonjs/models/execTasks/ETBaseModels.js +4 -0
- package/lib/commonjs/models/execTasks/ETBaseModels.js.map +1 -1
- package/lib/commonjs/models/sdk.js.map +1 -1
- package/lib/commonjs/native/signature/SignatureCapture.js.map +1 -1
- package/lib/commonjs/network/GraphQLClient.js.map +1 -1
- package/lib/commonjs/network/NetworkClient.js.map +1 -1
- package/lib/commonjs/network/NetworkUtils.js.map +1 -1
- package/lib/commonjs/network/client.js.map +1 -1
- package/lib/commonjs/resources/Login.js.map +1 -1
- package/lib/commonjs/resources/network.js.map +1 -1
- package/lib/commonjs/styles/SdkColors.js +4 -2
- package/lib/commonjs/styles/SdkColors.js.map +1 -1
- package/lib/commonjs/styles/executionTasks/CommonStyles.js +19 -10
- package/lib/commonjs/styles/executionTasks/CommonStyles.js.map +1 -1
- package/lib/commonjs/ui/screens/CancellationScreen.js +38 -7
- package/lib/commonjs/ui/screens/CancellationScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/CaptureInputScreen.js +11 -3
- package/lib/commonjs/ui/screens/CaptureInputScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/CompleteObjectiveScreen.js +11 -4
- package/lib/commonjs/ui/screens/CompleteObjectiveScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/DeliverScreen.js +26 -4
- package/lib/commonjs/ui/screens/DeliverScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/DisplayScreen.js +11 -2
- package/lib/commonjs/ui/screens/DisplayScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/DoodleScreen.js +13 -6
- package/lib/commonjs/ui/screens/DoodleScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/DropCashScreen.js +39 -15
- package/lib/commonjs/ui/screens/DropCashScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/ETScreensIndex.js +0 -7
- package/lib/commonjs/ui/screens/ETScreensIndex.js.map +1 -1
- package/lib/commonjs/ui/screens/FormsScreen.js +95 -28
- package/lib/commonjs/ui/screens/FormsScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/GeofenceScreen.js +10 -2
- package/lib/commonjs/ui/screens/GeofenceScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/HttpRequestScreen.js +10 -2
- package/lib/commonjs/ui/screens/HttpRequestScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/ImageCaptureScreen.js +26 -18
- package/lib/commonjs/ui/screens/ImageCaptureScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/PaymentScreen.js +22 -11
- package/lib/commonjs/ui/screens/PaymentScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/PickupScreen.js +34 -8
- package/lib/commonjs/ui/screens/PickupScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/ScanScreen.js +72 -219
- package/lib/commonjs/ui/screens/ScanScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/StartWorkFlowScreen.js +51 -16
- package/lib/commonjs/ui/screens/StartWorkFlowScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/ValidateOTPScreen.js +13 -7
- package/lib/commonjs/ui/screens/ValidateOTPScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/WithBaseDispatchScreen.js.map +1 -1
- package/lib/commonjs/ui/uiConfig/RouteParams.js +20 -5
- package/lib/commonjs/ui/uiConfig/RouteParams.js.map +1 -1
- package/lib/commonjs/utils/ApiUtils.js +16 -2
- package/lib/commonjs/utils/ApiUtils.js.map +1 -1
- package/lib/commonjs/utils/ExecTaskUtils.js +33 -25
- package/lib/commonjs/utils/ExecTaskUtils.js.map +1 -1
- package/lib/commonjs/utils/Logger.js.map +1 -1
- package/lib/commonjs/utils/NetworkUtil.js.map +1 -1
- package/lib/commonjs/utils/SdkUtils.js.map +1 -1
- package/lib/commonjs/utils/SyncManagerUtils.js +37 -4
- package/lib/commonjs/utils/SyncManagerUtils.js.map +1 -1
- package/lib/commonjs/utils/fcm/FCM.js +64 -35
- package/lib/commonjs/utils/fcm/FCM.js.map +1 -1
- package/lib/commonjs/utils/fcm/FcmUtils.js +82 -46
- package/lib/commonjs/utils/fcm/FcmUtils.js.map +1 -1
- package/lib/commonjs/utils/helper.js.map +1 -1
- package/lib/commonjs/utils/hooks/useModal.js +53 -0
- package/lib/commonjs/utils/hooks/useModal.js.map +1 -0
- package/lib/commonjs/utils/loginHelper.js.map +1 -1
- package/lib/commonjs/utils/storage.js +37 -2
- package/lib/commonjs/utils/storage.js.map +1 -1
- package/lib/commonjs/utils/utils.js.map +1 -1
- package/lib/module/@types/assets/index.d.js +2 -0
- package/lib/module/@types/assets/index.d.js.map +1 -0
- package/lib/module/components/dispatch/DispatchExecNavigator.js +4 -4
- package/lib/module/components/dispatch/DispatchExecNavigator.js.map +1 -1
- package/lib/module/components/executiontasks/ExecutionTasksIndex.js +1 -5
- package/lib/module/components/executiontasks/ExecutionTasksIndex.js.map +1 -1
- package/lib/module/components/executiontasks/cancellation/CancelET.js.map +1 -1
- package/lib/module/components/executiontasks/captureInput/CaptureText.js +38 -37
- package/lib/module/components/executiontasks/captureInput/CaptureText.js.map +1 -1
- package/lib/module/components/executiontasks/captureInput/utils.js +7 -0
- package/lib/module/components/executiontasks/captureInput/utils.js.map +1 -0
- package/lib/module/components/executiontasks/deliver/DeliverET.js +2 -2
- package/lib/module/components/executiontasks/deliver/DeliverET.js.map +1 -1
- package/lib/module/components/executiontasks/deliver/DeliverETInput.js.map +1 -1
- package/lib/module/components/executiontasks/deliver/SLDeliverET.js +189 -114
- package/lib/module/components/executiontasks/deliver/SLDeliverET.js.map +1 -1
- package/lib/module/components/executiontasks/display/DisplayModalET.js +16 -16
- package/lib/module/components/executiontasks/display/DisplayModalET.js.map +1 -1
- package/lib/module/components/executiontasks/doodle/SignatureET.js +39 -36
- package/lib/module/components/executiontasks/doodle/SignatureET.js.map +1 -1
- package/lib/module/components/executiontasks/dropCash/DropCashET.js +2 -2
- package/lib/module/components/executiontasks/dropCash/DropCashET.js.map +1 -1
- package/lib/module/components/executiontasks/dropCash/SLDropCash.js +53 -52
- package/lib/module/components/executiontasks/dropCash/SLDropCash.js.map +1 -1
- package/lib/module/components/executiontasks/forms/FormGenerator.js +73 -68
- package/lib/module/components/executiontasks/forms/FormGenerator.js.map +1 -1
- package/lib/module/components/executiontasks/forms/widgets/DateTimeWidget.js.map +1 -1
- package/lib/module/components/executiontasks/forms/widgets/DropdownWidget.js.map +1 -1
- package/lib/module/components/executiontasks/forms/widgets/QRBarcodeScannerWidget.js +1 -1
- package/lib/module/components/executiontasks/forms/widgets/QRBarcodeScannerWidget.js.map +1 -1
- package/lib/module/components/executiontasks/forms/widgets/TimeRangeSelector.js.map +1 -1
- package/lib/module/components/executiontasks/httpRequest/HttpEtUtils.js +3 -3
- package/lib/module/components/executiontasks/httpRequest/HttpEtUtils.js.map +1 -1
- package/lib/module/components/executiontasks/httpRequest/HttpRequestET.js +3 -3
- package/lib/module/components/executiontasks/httpRequest/HttpRequestET.js.map +1 -1
- package/lib/module/components/executiontasks/imageCapture/CaptureSchema.js.map +1 -1
- package/lib/module/components/executiontasks/imageCapture/CaptureUtils.js +6 -3
- package/lib/module/components/executiontasks/imageCapture/CaptureUtils.js.map +1 -1
- package/lib/module/components/executiontasks/imageCapture/ImageCapture.js +36 -36
- package/lib/module/components/executiontasks/imageCapture/ImageCapture.js.map +1 -1
- package/lib/module/components/executiontasks/payments/PaymentUtils.js.map +1 -1
- package/lib/module/components/executiontasks/payments/completePayment/CompletePaymentET.js +55 -54
- package/lib/module/components/executiontasks/payments/completePayment/CompletePaymentET.js.map +1 -1
- package/lib/module/components/executiontasks/payments/init/InitPaymentET.js +35 -34
- package/lib/module/components/executiontasks/payments/init/InitPaymentET.js.map +1 -1
- package/lib/module/components/executiontasks/payments/processPayment/ProcessPaymentET.js +35 -35
- package/lib/module/components/executiontasks/payments/processPayment/ProcessPaymentET.js.map +1 -1
- package/lib/module/components/executiontasks/pickup/PickupET.js +2 -2
- package/lib/module/components/executiontasks/pickup/PickupET.js.map +1 -1
- package/lib/module/components/executiontasks/pickup/SLPickupET.js +114 -49
- package/lib/module/components/executiontasks/pickup/SLPickupET.js.map +1 -1
- package/lib/module/components/executiontasks/scan/ScanET.js +332 -433
- package/lib/module/components/executiontasks/scan/ScanET.js.map +1 -1
- package/lib/module/components/executiontasks/scan/ScanSchema.js +16 -1
- package/lib/module/components/executiontasks/scan/ScanSchema.js.map +1 -1
- package/lib/module/components/executiontasks/scan/interfaces.js +12 -0
- package/lib/module/components/executiontasks/scan/interfaces.js.map +1 -1
- package/lib/module/components/executiontasks/scan/modalConstant.js +94 -0
- package/lib/module/components/executiontasks/scan/modalConstant.js.map +1 -0
- package/lib/module/components/executiontasks/scan/sub_components/CScanner.js.map +1 -1
- package/lib/module/components/executiontasks/scan/sub_components/DropDownUtils.js +72 -37
- package/lib/module/components/executiontasks/scan/sub_components/DropDownUtils.js.map +1 -1
- package/lib/module/components/executiontasks/scan/sub_components/ERDropDown.js +9 -7
- package/lib/module/components/executiontasks/scan/sub_components/ERDropDown.js.map +1 -1
- package/lib/module/components/executiontasks/scan/sub_components/SummaryPage.js +1092 -0
- package/lib/module/components/executiontasks/scan/sub_components/SummaryPage.js.map +1 -0
- package/lib/module/components/executiontasks/scan/utils.js +528 -160
- package/lib/module/components/executiontasks/scan/utils.js.map +1 -1
- package/lib/module/components/executiontasks/validateOTP/ValidateOTPET.js +54 -55
- package/lib/module/components/executiontasks/validateOTP/ValidateOTPET.js.map +1 -1
- package/lib/module/components/executiontasks/validateOTP/sub-components/OTPInput.js +4 -0
- package/lib/module/components/executiontasks/validateOTP/sub-components/OTPInput.js.map +1 -1
- package/lib/module/components/executiontasks/validateOTP/utils.js.map +1 -1
- package/lib/module/components/executiontasks/verifyLocation/GeofenceUtils.js.map +1 -1
- package/lib/module/components/executiontasks/verifyLocation/VerifyLocationET.js +1 -1
- package/lib/module/components/executiontasks/verifyLocation/VerifyLocationET.js.map +1 -1
- package/lib/module/components/executiontasks/verifyOtp/VerifyOtpET.js +2 -2
- package/lib/module/components/executiontasks/verifyOtp/VerifyOtpET.js.map +1 -1
- package/lib/module/components/executiontasks/verifyOtp/VerifyOtpSchema.js.map +1 -1
- package/lib/module/components/utils/index.js +8 -0
- package/lib/module/components/utils/index.js.map +1 -0
- package/lib/module/components/widgets/AlertDisplay.js.map +1 -1
- package/lib/module/components/widgets/CancelOrderDialog.js.map +1 -1
- package/lib/module/components/widgets/Card.js +80 -0
- package/lib/module/components/widgets/Card.js.map +1 -0
- package/lib/module/components/widgets/GoBackModal.js +40 -0
- package/lib/module/components/widgets/GoBackModal.js.map +1 -0
- package/lib/module/components/widgets/IconButton.js.map +1 -1
- package/lib/module/components/widgets/ModalWidget.js +92 -0
- package/lib/module/components/widgets/ModalWidget.js.map +1 -0
- package/lib/module/components/widgets/ProgressDialog.js.map +1 -1
- package/lib/module/components/widgets/SearchBar.js +66 -0
- package/lib/module/components/widgets/SearchBar.js.map +1 -0
- package/lib/module/components/widgets/SnackBarCustom.js +12 -4
- package/lib/module/components/widgets/SnackBarCustom.js.map +1 -1
- package/lib/module/components/widgets/SplitTextInput.js.map +1 -1
- package/lib/module/components/widgets/TabsComponent.js +55 -0
- package/lib/module/components/widgets/TabsComponent.js.map +1 -0
- package/lib/module/constants/apiConstants.js +3 -1
- package/lib/module/constants/apiConstants.js.map +1 -1
- package/lib/module/constants/constants.js +2 -2
- package/lib/module/constants/constants.js.map +1 -1
- package/lib/module/events/EventDispatcher.js +0 -3
- package/lib/module/events/EventDispatcher.js.map +1 -1
- package/lib/module/events/constants.js +3 -1
- package/lib/module/events/constants.js.map +1 -1
- package/lib/module/events/interface.js.map +1 -1
- package/lib/module/index.js +6 -3
- package/lib/module/index.js.map +1 -1
- package/lib/module/manager/dispatch/DispatchStateContainer.js +319 -610
- package/lib/module/manager/dispatch/DispatchStateContainer.js.map +1 -1
- package/lib/module/manager/dispatchCodes/EventCodeContainer.js.map +1 -1
- package/lib/module/manager/dispatchCodes/EventCodeRepo.js.map +1 -1
- package/lib/module/manager/dispatchCodes/ReasonCodeContainer.js.map +1 -1
- package/lib/module/manager/dispatchCodes/ReasonCodeRepo.js.map +1 -1
- package/lib/module/manager/jobRemoval/JobRemovalManager.js +21 -19
- package/lib/module/manager/jobRemoval/JobRemovalManager.js.map +1 -1
- package/lib/module/manager/location/LocationManager.js.map +1 -1
- package/lib/module/manager/sdk/DispatchSDKManager.js +15 -1
- package/lib/module/manager/sdk/DispatchSDKManager.js.map +1 -1
- package/lib/module/manager/sdk/DispatchSdkCache.js +2 -2
- package/lib/module/manager/sdk/DispatchSdkCache.js.map +1 -1
- package/lib/module/manager/sdk/callbacksHandler.js +19 -0
- package/lib/module/manager/sdk/callbacksHandler.js.map +1 -0
- package/lib/module/manager/syncmanager/AppSyncManager.js +15 -1
- package/lib/module/manager/syncmanager/AppSyncManager.js.map +1 -1
- package/lib/module/manager/syncmanager/DBConfig.js +32 -2
- package/lib/module/manager/syncmanager/DBConfig.js.map +1 -1
- package/lib/module/manager/syncmanager/constants.js +6 -0
- package/lib/module/manager/syncmanager/constants.js.map +1 -0
- package/lib/module/manager/syncmanager/database.js.map +1 -1
- package/lib/module/manager/syncmanager/document/DocumentHttpClient.js +11 -17
- package/lib/module/manager/syncmanager/document/DocumentHttpClient.js.map +1 -1
- package/lib/module/manager/syncmanager/document/DocumentManager.js +5 -6
- package/lib/module/manager/syncmanager/document/DocumentManager.js.map +1 -1
- package/lib/module/manager/syncmanager/document/DocumentSyncManager.js +16 -6
- package/lib/module/manager/syncmanager/document/DocumentSyncManager.js.map +1 -1
- package/lib/module/manager/syncmanager/events/ETEventsManager.js +377 -25
- package/lib/module/manager/syncmanager/events/ETEventsManager.js.map +1 -1
- package/lib/module/manager/syncmanager/events/EventsSyncManager.js +183 -65
- package/lib/module/manager/syncmanager/events/EventsSyncManager.js.map +1 -1
- package/lib/module/manager/syncmanager/events/SyncHttpClient.js +147 -34
- package/lib/module/manager/syncmanager/events/SyncHttpClient.js.map +1 -1
- package/lib/module/models/DispatchModels.js.map +1 -1
- package/lib/module/models/execTasks/ETBaseModels.js +1 -1
- package/lib/module/models/execTasks/ETBaseModels.js.map +1 -1
- package/lib/module/models/sdk.js.map +1 -1
- package/lib/module/native/signature/SignatureCapture.js.map +1 -1
- package/lib/module/network/GraphQLClient.js.map +1 -1
- package/lib/module/network/NetworkClient.js.map +1 -1
- package/lib/module/network/NetworkUtils.js.map +1 -1
- package/lib/module/network/client.js.map +1 -1
- package/lib/module/resources/Login.js.map +1 -1
- package/lib/module/resources/network.js.map +1 -1
- package/lib/module/styles/SdkColors.js +4 -2
- package/lib/module/styles/SdkColors.js.map +1 -1
- package/lib/module/styles/executionTasks/CommonStyles.js +19 -10
- package/lib/module/styles/executionTasks/CommonStyles.js.map +1 -1
- package/lib/module/ui/screens/CancellationScreen.js +39 -8
- package/lib/module/ui/screens/CancellationScreen.js.map +1 -1
- package/lib/module/ui/screens/CaptureInputScreen.js +12 -4
- package/lib/module/ui/screens/CaptureInputScreen.js.map +1 -1
- package/lib/module/ui/screens/CompleteObjectiveScreen.js +12 -5
- package/lib/module/ui/screens/CompleteObjectiveScreen.js.map +1 -1
- package/lib/module/ui/screens/DeliverScreen.js +27 -5
- package/lib/module/ui/screens/DeliverScreen.js.map +1 -1
- package/lib/module/ui/screens/DisplayScreen.js +12 -3
- package/lib/module/ui/screens/DisplayScreen.js.map +1 -1
- package/lib/module/ui/screens/DoodleScreen.js +14 -7
- package/lib/module/ui/screens/DoodleScreen.js.map +1 -1
- package/lib/module/ui/screens/DropCashScreen.js +42 -16
- package/lib/module/ui/screens/DropCashScreen.js.map +1 -1
- package/lib/module/ui/screens/ETScreensIndex.js +1 -2
- package/lib/module/ui/screens/ETScreensIndex.js.map +1 -1
- package/lib/module/ui/screens/FormsScreen.js +96 -29
- package/lib/module/ui/screens/FormsScreen.js.map +1 -1
- package/lib/module/ui/screens/GeofenceScreen.js +11 -3
- package/lib/module/ui/screens/GeofenceScreen.js.map +1 -1
- package/lib/module/ui/screens/HttpRequestScreen.js +11 -3
- package/lib/module/ui/screens/HttpRequestScreen.js.map +1 -1
- package/lib/module/ui/screens/ImageCaptureScreen.js +27 -19
- package/lib/module/ui/screens/ImageCaptureScreen.js.map +1 -1
- package/lib/module/ui/screens/PaymentScreen.js +23 -12
- package/lib/module/ui/screens/PaymentScreen.js.map +1 -1
- package/lib/module/ui/screens/PickupScreen.js +36 -10
- package/lib/module/ui/screens/PickupScreen.js.map +1 -1
- package/lib/module/ui/screens/ScanScreen.js +74 -222
- package/lib/module/ui/screens/ScanScreen.js.map +1 -1
- package/lib/module/ui/screens/StartWorkFlowScreen.js +51 -16
- package/lib/module/ui/screens/StartWorkFlowScreen.js.map +1 -1
- package/lib/module/ui/screens/ValidateOTPScreen.js +14 -8
- package/lib/module/ui/screens/ValidateOTPScreen.js.map +1 -1
- package/lib/module/ui/screens/WithBaseDispatchScreen.js.map +1 -1
- package/lib/module/ui/uiConfig/RouteParams.js +19 -5
- package/lib/module/ui/uiConfig/RouteParams.js.map +1 -1
- package/lib/module/utils/ApiUtils.js +17 -2
- package/lib/module/utils/ApiUtils.js.map +1 -1
- package/lib/module/utils/ExecTaskUtils.js +33 -25
- package/lib/module/utils/ExecTaskUtils.js.map +1 -1
- package/lib/module/utils/Logger.js.map +1 -1
- package/lib/module/utils/NetworkUtil.js.map +1 -1
- package/lib/module/utils/SdkUtils.js.map +1 -1
- package/lib/module/utils/SyncManagerUtils.js +37 -4
- package/lib/module/utils/SyncManagerUtils.js.map +1 -1
- package/lib/module/utils/fcm/FCM.js +64 -35
- package/lib/module/utils/fcm/FCM.js.map +1 -1
- package/lib/module/utils/fcm/FcmUtils.js +82 -46
- package/lib/module/utils/fcm/FcmUtils.js.map +1 -1
- package/lib/module/utils/helper.js.map +1 -1
- package/lib/module/utils/hooks/useModal.js +43 -0
- package/lib/module/utils/hooks/useModal.js.map +1 -0
- package/lib/module/utils/loginHelper.js.map +1 -1
- package/lib/module/utils/storage.js +37 -2
- package/lib/module/utils/storage.js.map +1 -1
- package/lib/module/utils/utils.js.map +1 -1
- package/lib/typescript/components/dispatch/DispatchExecNavigator.d.ts +2 -2
- package/lib/typescript/components/executiontasks/ExecutionTasksIndex.d.ts +3 -8
- package/lib/typescript/components/executiontasks/cancellation/CancelET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/captureInput/CaptureText.d.ts +2 -2
- package/lib/typescript/components/executiontasks/captureInput/utils.d.ts +1 -0
- package/lib/typescript/components/executiontasks/deliver/DeliverET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/deliver/DeliverETInput.d.ts +1 -0
- package/lib/typescript/components/executiontasks/deliver/SLDeliverET.d.ts +3 -3
- package/lib/typescript/components/executiontasks/display/DisplayModalET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/doodle/SignatureET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/dropCash/DropCashET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/dropCash/SLDropCash.d.ts +2 -2
- package/lib/typescript/components/executiontasks/forms/FormGenerator.d.ts +2 -2
- package/lib/typescript/components/executiontasks/forms/widgets/DateTimeWidget.d.ts +2 -2
- package/lib/typescript/components/executiontasks/forms/widgets/DropdownWidget.d.ts +2 -2
- package/lib/typescript/components/executiontasks/forms/widgets/QRBarcodeScannerWidget.d.ts +2 -2
- package/lib/typescript/components/executiontasks/forms/widgets/TimeRangeSelector.d.ts +2 -2
- package/lib/typescript/components/executiontasks/httpRequest/HttpEtUtils.d.ts +1 -1
- package/lib/typescript/components/executiontasks/httpRequest/HttpRequestET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/imageCapture/CaptureSchema.d.ts +1 -0
- package/lib/typescript/components/executiontasks/imageCapture/ImageCapture.d.ts +2 -2
- package/lib/typescript/components/executiontasks/payments/completePayment/CompletePaymentET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/payments/init/InitPaymentET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/payments/processPayment/ProcessPaymentET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/pickup/PickupET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/pickup/SLPickupET.d.ts +3 -3
- package/lib/typescript/components/executiontasks/scan/ScanET.d.ts +3 -3
- package/lib/typescript/components/executiontasks/scan/ScanSchema.d.ts +25 -9
- package/lib/typescript/components/executiontasks/scan/interfaces.d.ts +54 -1
- package/lib/typescript/components/executiontasks/scan/modalConstant.d.ts +37 -0
- package/lib/typescript/components/executiontasks/scan/sub_components/CScanner.d.ts +1 -1
- package/lib/typescript/components/executiontasks/scan/sub_components/DropDownUtils.d.ts +1 -1
- package/lib/typescript/components/executiontasks/scan/sub_components/ERDropDown.d.ts +1 -1
- package/lib/typescript/components/executiontasks/scan/sub_components/SummaryPage.d.ts +21 -0
- package/lib/typescript/components/executiontasks/scan/utils.d.ts +29 -13
- package/lib/typescript/components/executiontasks/validateOTP/ValidateOTPET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/validateOTP/sub-components/OTPInput.d.ts +2 -2
- package/lib/typescript/components/executiontasks/verifyLocation/VerifyLocationET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/verifyOtp/VerifyOtpET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/verifyOtp/VerifyOtpSchema.d.ts +3 -3
- package/lib/typescript/components/utils/index.d.ts +2 -0
- package/lib/typescript/components/widgets/CancelOrderDialog.d.ts +2 -2
- package/lib/typescript/components/widgets/Card.d.ts +17 -0
- package/lib/typescript/components/widgets/GoBackModal.d.ts +9 -0
- package/lib/typescript/components/widgets/IconButton.d.ts +2 -2
- package/lib/typescript/components/widgets/ModalWidget.d.ts +30 -0
- package/lib/typescript/components/widgets/ProgressDialog.d.ts +2 -2
- package/lib/typescript/components/widgets/SearchBar.d.ts +10 -0
- package/lib/typescript/components/widgets/SnackBarCustom.d.ts +3 -2
- package/lib/typescript/components/widgets/SplitTextInput.d.ts +2 -2
- package/lib/typescript/components/widgets/TabsComponent.d.ts +15 -0
- package/lib/typescript/constants/apiConstants.d.ts +1 -0
- package/lib/typescript/constants/constants.d.ts +2 -2
- package/lib/typescript/events/EventDispatcher.d.ts +0 -2
- package/lib/typescript/events/constants.d.ts +2 -0
- package/lib/typescript/events/interface.d.ts +1 -1
- package/lib/typescript/index.d.ts +8 -6
- package/lib/typescript/manager/dispatch/DispatchStateContainer.d.ts +27 -19
- package/lib/typescript/manager/jobRemoval/JobRemovalManager.d.ts +0 -6
- package/lib/typescript/manager/sdk/DispatchSdkCache.d.ts +0 -1
- package/lib/typescript/manager/sdk/callbacksHandler.d.ts +13 -0
- package/lib/typescript/manager/syncmanager/AppSyncManager.d.ts +2 -1
- package/lib/typescript/manager/syncmanager/DBConfig.d.ts +63 -7
- package/lib/typescript/manager/syncmanager/constants.d.ts +5 -0
- package/lib/typescript/manager/syncmanager/document/DocumentManager.d.ts +1 -1
- package/lib/typescript/manager/syncmanager/document/DocumentSyncManager.d.ts +1 -1
- package/lib/typescript/manager/syncmanager/events/ETEventsManager.d.ts +11 -2
- package/lib/typescript/manager/syncmanager/events/EventsSyncManager.d.ts +3 -5
- package/lib/typescript/manager/syncmanager/events/SyncHttpClient.d.ts +4 -3
- package/lib/typescript/models/DispatchModels.d.ts +40 -41
- package/lib/typescript/models/execTasks/ETBaseModels.d.ts +21 -16
- package/lib/typescript/models/sdk.d.ts +7 -0
- package/lib/typescript/native/signature/SignatureCapture.d.ts +1 -1
- package/lib/typescript/styles/SdkColors.d.ts +1 -0
- package/lib/typescript/styles/executionTasks/CommonStyles.d.ts +16 -7
- package/lib/typescript/ui/screens/CancellationScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/CaptureInputScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/CompleteObjectiveScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/DeliverScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/DisplayScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/DoodleScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/DropCashScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/ETScreensIndex.d.ts +1 -2
- package/lib/typescript/ui/screens/FormsScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/GeofenceScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/HttpRequestScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/ImageCaptureScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/PaymentScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/PickupScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/ScanScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/StartWorkFlowScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/ValidateOTPScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/WithBaseDispatchScreen.d.ts +2 -2
- package/lib/typescript/ui/uiConfig/RouteParams.d.ts +10 -4
- package/lib/typescript/utils/ExecTaskUtils.d.ts +5 -4
- package/lib/typescript/utils/SyncManagerUtils.d.ts +4 -5
- package/lib/typescript/utils/hooks/useModal.d.ts +6 -0
- package/lib/typescript/utils/storage.d.ts +15 -0
- package/package.json +5 -4
- package/tsconfig.json +0 -1
- package/android/.gradle/6.8/fileHashes/fileHashes.lock +0 -0
- package/android/.idea/workspace.xml +0 -131
- package/lib/commonjs/components/executiontasks/doodle/DoodleUtils.js +0 -26
- package/lib/commonjs/components/executiontasks/doodle/DoodleUtils.js.map +0 -1
- package/lib/commonjs/components/executiontasks/scan/sub_components/ScanList.js +0 -134
- package/lib/commonjs/components/executiontasks/scan/sub_components/ScanList.js.map +0 -1
- package/lib/commonjs/components/executiontasks/scanner/CScanner.js +0 -105
- package/lib/commonjs/components/executiontasks/scanner/CScanner.js.map +0 -1
- package/lib/commonjs/components/executiontasks/scanner/ScannerSchema.js +0 -27
- package/lib/commonjs/components/executiontasks/scanner/ScannerSchema.js.map +0 -1
- package/lib/commonjs/components/executiontasks/scanner/ScannerUtils.js +0 -164
- package/lib/commonjs/components/executiontasks/scanner/ScannerUtils.js.map +0 -1
- package/lib/commonjs/components/executiontasks/scanner/returns/DropDownSelector.js +0 -15
- package/lib/commonjs/components/executiontasks/scanner/returns/DropDownSelector.js.map +0 -1
- package/lib/commonjs/components/executiontasks/scanner/returns/DropDownUtils.js +0 -40
- package/lib/commonjs/components/executiontasks/scanner/returns/DropDownUtils.js.map +0 -1
- package/lib/commonjs/components/executiontasks/scanner/returns/RTReasonSelection.js +0 -93
- package/lib/commonjs/components/executiontasks/scanner/returns/RTReasonSelection.js.map +0 -1
- package/lib/commonjs/components/executiontasks/scanner/returns/RTScan.js +0 -278
- package/lib/commonjs/components/executiontasks/scanner/returns/RTScan.js.map +0 -1
- package/lib/commonjs/components/executiontasks/scanner/returns/ReasonDropDown.js +0 -83
- package/lib/commonjs/components/executiontasks/scanner/returns/ReasonDropDown.js.map +0 -1
- package/lib/commonjs/components/executiontasks/scanner/returns/ScanList.js +0 -248
- package/lib/commonjs/components/executiontasks/scanner/returns/ScanList.js.map +0 -1
- package/lib/commonjs/ui/screens/RTScanScreen.js +0 -99
- package/lib/commonjs/ui/screens/RTScanScreen.js.map +0 -1
- package/lib/module/components/executiontasks/doodle/DoodleUtils.js +0 -19
- package/lib/module/components/executiontasks/doodle/DoodleUtils.js.map +0 -1
- package/lib/module/components/executiontasks/scan/sub_components/ScanList.js +0 -124
- package/lib/module/components/executiontasks/scan/sub_components/ScanList.js.map +0 -1
- package/lib/module/components/executiontasks/scanner/CScanner.js +0 -96
- package/lib/module/components/executiontasks/scanner/CScanner.js.map +0 -1
- package/lib/module/components/executiontasks/scanner/ScannerSchema.js +0 -24
- package/lib/module/components/executiontasks/scanner/ScannerSchema.js.map +0 -1
- package/lib/module/components/executiontasks/scanner/ScannerUtils.js +0 -146
- package/lib/module/components/executiontasks/scanner/ScannerUtils.js.map +0 -1
- package/lib/module/components/executiontasks/scanner/returns/DropDownSelector.js +0 -7
- package/lib/module/components/executiontasks/scanner/returns/DropDownSelector.js.map +0 -1
- package/lib/module/components/executiontasks/scanner/returns/DropDownUtils.js +0 -33
- package/lib/module/components/executiontasks/scanner/returns/DropDownUtils.js.map +0 -1
- package/lib/module/components/executiontasks/scanner/returns/RTReasonSelection.js +0 -83
- package/lib/module/components/executiontasks/scanner/returns/RTReasonSelection.js.map +0 -1
- package/lib/module/components/executiontasks/scanner/returns/RTScan.js +0 -269
- package/lib/module/components/executiontasks/scanner/returns/RTScan.js.map +0 -1
- package/lib/module/components/executiontasks/scanner/returns/ReasonDropDown.js +0 -73
- package/lib/module/components/executiontasks/scanner/returns/ReasonDropDown.js.map +0 -1
- package/lib/module/components/executiontasks/scanner/returns/ScanList.js +0 -238
- package/lib/module/components/executiontasks/scanner/returns/ScanList.js.map +0 -1
- package/lib/module/ui/screens/RTScanScreen.js +0 -89
- package/lib/module/ui/screens/RTScanScreen.js.map +0 -1
- package/lib/typescript/components/executiontasks/doodle/DoodleUtils.d.ts +0 -3
- package/lib/typescript/components/executiontasks/scan/sub_components/ScanList.d.ts +0 -8
- package/lib/typescript/components/executiontasks/scanner/CScanner.d.ts +0 -7
- package/lib/typescript/components/executiontasks/scanner/ScannerSchema.d.ts +0 -75
- package/lib/typescript/components/executiontasks/scanner/ScannerUtils.d.ts +0 -15
- package/lib/typescript/components/executiontasks/scanner/returns/DropDownSelector.d.ts +0 -3
- package/lib/typescript/components/executiontasks/scanner/returns/DropDownUtils.d.ts +0 -2
- package/lib/typescript/components/executiontasks/scanner/returns/RTReasonSelection.d.ts +0 -7
- package/lib/typescript/components/executiontasks/scanner/returns/RTScan.d.ts +0 -4
- package/lib/typescript/components/executiontasks/scanner/returns/ReasonDropDown.d.ts +0 -14
- package/lib/typescript/components/executiontasks/scanner/returns/ScanList.d.ts +0 -17
- package/lib/typescript/ui/screens/RTScanScreen.d.ts +0 -3
- /package/android/.gradle/{6.8 → 7.0.2}/fileChanges/last-build.bin +0 -0
- /package/android/.gradle/{6.8 → 7.0.2}/gc.properties +0 -0
- /package/android/.gradle/{configuration-cache → 7.2/dependencies-accessors}/gc.properties +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_react","_interopRequireDefault","require","_reactNative","_CommonStyles","obj","__esModule","default","ProgressDialog","props","createElement","Modal","animationType","transparent","visible","onRequestClose","View","style","styles","wrapper","content","ActivityIndicator","size","color","Text","label","StyleSheet","create","textAlign","fontStyle","fontSize","fontFamily","Fonts","IBMPlexSans_600SemiBold","backgroundColor","padding","borderRadius","width","alignItems","flex","justifyContent","_default","exports"],"sources":["ProgressDialog.tsx"],"sourcesContent":["import React from 'react';\nimport { ActivityIndicator, Modal, StyleSheet, Text, View } from 'react-native';\nimport { Fonts } from '../../styles/executionTasks/CommonStyles';\n\nconst ProgressDialog = (props: ProgressDialogProps) => {\n return (\n <Modal\n animationType=\"none\"\n transparent={true}\n visible={props.visible}\n onRequestClose={() => {}}\n >\n <View style={styles.wrapper}>\n <View style={styles.content}>\n <ActivityIndicator size=\"large\" color=\"rgba(107, 142, 255, 1)\" />\n <Text style={[styles.label]}>{props.label}</Text>\n </View>\n </View>\n </Modal>\n );\n};\n\nconst styles = StyleSheet.create({\n label: {\n color: 'black',\n textAlign: 'center',\n fontStyle: 'normal',\n fontSize: 15,\n fontFamily: Fonts.IBMPlexSans_600SemiBold,\n },\n content: {\n backgroundColor: 'white',\n padding: 10,\n borderRadius: 5,\n width: '80%',\n alignItems: 'center',\n },\n wrapper: {\n flex: 1,\n alignItems: 'center',\n justifyContent: 'center',\n backgroundColor: 'rgba(0,0,0,0.7)',\n },\n});\n\nexport default ProgressDialog;\n\nexport interface ProgressDialogProps {\n visible: boolean;\n label: string;\n}\n"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,aAAA,GAAAF,OAAA;AAAiE,SAAAD,uBAAAI,GAAA,WAAAA,GAAA,IAAAA,GAAA,CAAAC,UAAA,GAAAD,GAAA,KAAAE,OAAA,EAAAF,GAAA;AAEjE,MAAMG,cAAc,GAAIC,KAA0B,IAAK;EACrD,oBACET,MAAA,CAAAO,OAAA,CAAAG,aAAA,CAACP,YAAA,CAAAQ,KAAK;IACJC,aAAa,EAAC,MAAM;IACpBC,WAAW,EAAE,IAAK;IAClBC,OAAO,EAAEL,KAAK,CAACK,OAAQ;IACvBC,cAAc,EAAEA,CAAA,KAAM,CAAC;EAAE,gBAEzBf,MAAA,CAAAO,OAAA,CAAAG,aAAA,CAACP,YAAA,CAAAa,IAAI;IAACC,KAAK,EAAEC,MAAM,CAACC;EAAQ,gBAC1BnB,MAAA,CAAAO,OAAA,CAAAG,aAAA,CAACP,YAAA,CAAAa,IAAI;IAACC,KAAK,EAAEC,MAAM,CAACE;EAAQ,gBAC1BpB,MAAA,CAAAO,OAAA,CAAAG,aAAA,CAACP,YAAA,CAAAkB,iBAAiB;IAACC,IAAI,EAAC,OAAO;IAACC,KAAK,EAAC;EAAwB,
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireDefault","require","_reactNative","_CommonStyles","obj","__esModule","default","ProgressDialog","props","createElement","Modal","animationType","transparent","visible","onRequestClose","View","style","styles","wrapper","content","ActivityIndicator","size","color","Text","label","StyleSheet","create","textAlign","fontStyle","fontSize","fontFamily","Fonts","IBMPlexSans_600SemiBold","backgroundColor","padding","borderRadius","width","alignItems","flex","justifyContent","_default","exports"],"sources":["ProgressDialog.tsx"],"sourcesContent":["import React from 'react';\nimport { ActivityIndicator, Modal, StyleSheet, Text, View } from 'react-native';\nimport { Fonts } from '../../styles/executionTasks/CommonStyles';\n\nconst ProgressDialog = (props: ProgressDialogProps) => {\n return (\n <Modal\n animationType=\"none\"\n transparent={true}\n visible={props.visible}\n onRequestClose={() => {}}\n >\n <View style={styles.wrapper}>\n <View style={styles.content}>\n <ActivityIndicator size=\"large\" color=\"rgba(107, 142, 255, 1)\" />\n <Text style={[styles.label]}>{props.label}</Text>\n </View>\n </View>\n </Modal>\n );\n};\n\nconst styles = StyleSheet.create({\n label: {\n color: 'black',\n textAlign: 'center',\n fontStyle: 'normal',\n fontSize: 15,\n fontFamily: Fonts.IBMPlexSans_600SemiBold,\n },\n content: {\n backgroundColor: 'white',\n padding: 10,\n borderRadius: 5,\n width: '80%',\n alignItems: 'center',\n },\n wrapper: {\n flex: 1,\n alignItems: 'center',\n justifyContent: 'center',\n backgroundColor: 'rgba(0,0,0,0.7)',\n },\n});\n\nexport default ProgressDialog;\n\nexport interface ProgressDialogProps {\n visible: boolean;\n label: string;\n}\n"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,aAAA,GAAAF,OAAA;AAAiE,SAAAD,uBAAAI,GAAA,WAAAA,GAAA,IAAAA,GAAA,CAAAC,UAAA,GAAAD,GAAA,KAAAE,OAAA,EAAAF,GAAA;AAEjE,MAAMG,cAAc,GAAIC,KAA0B,IAAK;EACrD,oBACET,MAAA,CAAAO,OAAA,CAAAG,aAAA,CAACP,YAAA,CAAAQ,KAAK;IACJC,aAAa,EAAC,MAAM;IACpBC,WAAW,EAAE,IAAK;IAClBC,OAAO,EAAEL,KAAK,CAACK,OAAQ;IACvBC,cAAc,EAAEA,CAAA,KAAM,CAAC;EAAE,gBAEzBf,MAAA,CAAAO,OAAA,CAAAG,aAAA,CAACP,YAAA,CAAAa,IAAI;IAACC,KAAK,EAAEC,MAAM,CAACC;EAAQ,gBAC1BnB,MAAA,CAAAO,OAAA,CAAAG,aAAA,CAACP,YAAA,CAAAa,IAAI;IAACC,KAAK,EAAEC,MAAM,CAACE;EAAQ,gBAC1BpB,MAAA,CAAAO,OAAA,CAAAG,aAAA,CAACP,YAAA,CAAAkB,iBAAiB;IAACC,IAAI,EAAC,OAAO;IAACC,KAAK,EAAC;EAAwB,CAAE,CAAC,eACjEvB,MAAA,CAAAO,OAAA,CAAAG,aAAA,CAACP,YAAA,CAAAqB,IAAI;IAACP,KAAK,EAAE,CAACC,MAAM,CAACO,KAAK;EAAE,GAAEhB,KAAK,CAACgB,KAAY,CAC5C,CACF,CACD,CAAC;AAEZ,CAAC;AAED,MAAMP,MAAM,GAAGQ,uBAAU,CAACC,MAAM,CAAC;EAC/BF,KAAK,EAAE;IACLF,KAAK,EAAE,OAAO;IACdK,SAAS,EAAE,QAAQ;IACnBC,SAAS,EAAE,QAAQ;IACnBC,QAAQ,EAAE,EAAE;IACZC,UAAU,EAAEC,mBAAK,CAACC;EACpB,CAAC;EACDb,OAAO,EAAE;IACPc,eAAe,EAAE,OAAO;IACxBC,OAAO,EAAE,EAAE;IACXC,YAAY,EAAE,CAAC;IACfC,KAAK,EAAE,KAAK;IACZC,UAAU,EAAE;EACd,CAAC;EACDnB,OAAO,EAAE;IACPoB,IAAI,EAAE,CAAC;IACPD,UAAU,EAAE,QAAQ;IACpBE,cAAc,EAAE,QAAQ;IACxBN,eAAe,EAAE;EACnB;AACF,CAAC,CAAC;AAAC,IAAAO,QAAA,GAEYjC,cAAc;AAAAkC,OAAA,CAAAnC,OAAA,GAAAkC,QAAA"}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
var _react = _interopRequireDefault(require("react"));
|
|
8
|
+
var _reactNative = require("react-native");
|
|
9
|
+
var _vectorIcons = require("@expo/vector-icons");
|
|
10
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
11
|
+
const SearchBar = props => {
|
|
12
|
+
const {
|
|
13
|
+
searchText,
|
|
14
|
+
setSearchText
|
|
15
|
+
} = props;
|
|
16
|
+
const handleSearch = text => {
|
|
17
|
+
props.onChangeSearch(text);
|
|
18
|
+
};
|
|
19
|
+
const handleClear = () => {
|
|
20
|
+
props.onClear();
|
|
21
|
+
setSearchText('');
|
|
22
|
+
};
|
|
23
|
+
return /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
24
|
+
style: styles.container
|
|
25
|
+
}, /*#__PURE__*/_react.default.createElement(_reactNative.TouchableOpacity, {
|
|
26
|
+
style: styles.iconContainer
|
|
27
|
+
}, /*#__PURE__*/_react.default.createElement(_vectorIcons.EvilIcons, {
|
|
28
|
+
name: "search",
|
|
29
|
+
size: 24,
|
|
30
|
+
color: "#525B7A"
|
|
31
|
+
})), /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
32
|
+
style: styles.inputContainer
|
|
33
|
+
}, /*#__PURE__*/_react.default.createElement(_reactNative.TextInput, {
|
|
34
|
+
style: styles.input,
|
|
35
|
+
placeholder: props.placeholder,
|
|
36
|
+
onChangeText: text => {
|
|
37
|
+
handleSearch(text);
|
|
38
|
+
setSearchText(text);
|
|
39
|
+
},
|
|
40
|
+
value: searchText
|
|
41
|
+
})), searchText ? /*#__PURE__*/_react.default.createElement(_reactNative.TouchableOpacity, {
|
|
42
|
+
style: styles.iconContainer,
|
|
43
|
+
onPress: handleClear
|
|
44
|
+
}, /*#__PURE__*/_react.default.createElement(_vectorIcons.MaterialIcons, {
|
|
45
|
+
name: "clear",
|
|
46
|
+
size: 24,
|
|
47
|
+
color: "#525B7A"
|
|
48
|
+
})) : null);
|
|
49
|
+
};
|
|
50
|
+
const styles = _reactNative.StyleSheet.create({
|
|
51
|
+
container: {
|
|
52
|
+
flexDirection: 'row',
|
|
53
|
+
alignItems: 'center',
|
|
54
|
+
backgroundColor: '#ffffff',
|
|
55
|
+
borderRadius: 6,
|
|
56
|
+
paddingHorizontal: 12,
|
|
57
|
+
borderWidth: 1,
|
|
58
|
+
borderColor: '#DDDDDD',
|
|
59
|
+
marginHorizontal: 16
|
|
60
|
+
},
|
|
61
|
+
inputContainer: {
|
|
62
|
+
flex: 1
|
|
63
|
+
},
|
|
64
|
+
input: {
|
|
65
|
+
height: 40
|
|
66
|
+
},
|
|
67
|
+
iconContainer: {
|
|
68
|
+
paddingLeft: 4,
|
|
69
|
+
paddingRight: 8
|
|
70
|
+
}
|
|
71
|
+
});
|
|
72
|
+
var _default = SearchBar;
|
|
73
|
+
exports.default = _default;
|
|
74
|
+
//# sourceMappingURL=SearchBar.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireDefault","require","_reactNative","_vectorIcons","obj","__esModule","default","SearchBar","props","searchText","setSearchText","handleSearch","text","onChangeSearch","handleClear","onClear","createElement","View","style","styles","container","TouchableOpacity","iconContainer","EvilIcons","name","size","color","inputContainer","TextInput","input","placeholder","onChangeText","value","onPress","MaterialIcons","StyleSheet","create","flexDirection","alignItems","backgroundColor","borderRadius","paddingHorizontal","borderWidth","borderColor","marginHorizontal","flex","height","paddingLeft","paddingRight","_default","exports"],"sources":["SearchBar.tsx"],"sourcesContent":["import React, { useState } from 'react';\nimport { View, TextInput, TouchableOpacity, StyleSheet } from 'react-native';\nimport { EvilIcons, MaterialIcons } from '@expo/vector-icons';\n\ninterface SearchBarProps {\n searchText: string;\n setSearchText: (searchText: string) => void;\n onChangeSearch: (searchText: string) => any;\n placeholder: string;\n onClear: () => any;\n}\n\nconst SearchBar = (props: SearchBarProps) => {\n const { searchText, setSearchText } = props;\n const handleSearch = (text: string) => {\n props.onChangeSearch(text);\n };\n const handleClear = () => {\n props.onClear();\n setSearchText('');\n };\n\n return (\n <View style={styles.container}>\n <TouchableOpacity style={styles.iconContainer}>\n <EvilIcons name=\"search\" size={24} color=\"#525B7A\" />\n </TouchableOpacity>\n <View style={styles.inputContainer}>\n <TextInput\n style={styles.input}\n placeholder={props.placeholder}\n onChangeText={(text) => {\n handleSearch(text);\n setSearchText(text);\n }}\n value={searchText}\n />\n </View>\n {searchText ? (\n <TouchableOpacity style={styles.iconContainer} onPress={handleClear}>\n <MaterialIcons name=\"clear\" size={24} color=\"#525B7A\" />\n </TouchableOpacity>\n ) : null}\n </View>\n );\n};\n\nconst styles = StyleSheet.create({\n container: {\n flexDirection: 'row',\n alignItems: 'center',\n backgroundColor: '#ffffff',\n borderRadius: 6,\n paddingHorizontal: 12,\n borderWidth: 1,\n borderColor: '#DDDDDD',\n marginHorizontal: 16,\n },\n inputContainer: {\n flex: 1,\n },\n input: {\n height: 40,\n },\n icon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Y;IAC/BC,YAAY,EAAGnB,IAAI,IAAK;MACtBD,YAAY,CAACC,IAAI,CAAC;MAClBF,aAAa,CAACE,IAAI,CAAC;IACrB,CAAE;IACFoB,KAAK,EAAEvB;EAAW,CACnB,CACG,CAAC,EACNA,UAAU,gBACTV,MAAA,CAAAO,OAAA,CAAAU,aAAA,CAACd,YAAA,CAAAmB,gBAAgB;IAACH,KAAK,EAAEC,MAAM,CAACG,aAAc;IAACW,OAAO,EAAEnB;EAAY,gBAClEf,MAAA,CAAAO,OAAA,CAAAU,aAAA,CAACb,YAAA,CAAA+B,aAAa;IAACV,IAAI,EAAC,OAAO;IAACC,IAAI,EAAE,EAAG;IAACC,KAAK,EAAC;EAAS,CAAE,CACvC,CAAC,GACjB,IACA,CAAC;AAEX,CAAC;AAED,MAAMP,MAAM,GAAGgB,uBAAU,CAACC,MAAM,CAAC;EAC/BhB,SAAS,EAAE;IACTiB,aAAa,EAAE,KAAK;IACpBC,UAAU,EAAE,QAAQ;IACpBC,eAAe,EAAE,SAAS;IAC1BC,YAAY,EAAE,CAAC;IACfC,iBAAiB,EAAE,EAAE;IACrBC,WAAW,EAAE,CAAC;IACdC,WAAW,EAAE,SAAS;IACtBC,gBAAgB,EAAE;EACpB,CAAC;EACDjB,cAAc,EAAE;IACdkB,IAAI,EAAE;EACR,CAAC;EACDhB,KAAK,EAAE;IACLiB,MAAM,EAAE;EACV,CAAC;EACDxB,aAAa,EAAE;IACbyB,WAAW,EAAE,CAAC;IACdC,YAAY,EAAE;EAChB;AACF,CAAC,CAAC;AAAC,IAAAC,QAAA,GAEY1C,SAAS;AAAA2C,OAAA,CAAA5C,OAAA,GAAA2C,QAAA"}
|
|
@@ -10,10 +10,11 @@ var _reactNativePaper = require("react-native-paper");
|
|
|
10
10
|
var _vectorIcons = require("@expo/vector-icons");
|
|
11
11
|
var _CommonStyles = require("../../styles/executionTasks/CommonStyles");
|
|
12
12
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
13
|
-
const DURATION_MEDIUM =
|
|
13
|
+
const DURATION_MEDIUM = 3000;
|
|
14
14
|
let SnackBarType = /*#__PURE__*/function (SnackBarType) {
|
|
15
15
|
SnackBarType[SnackBarType["SUCCESS"] = 0] = "SUCCESS";
|
|
16
16
|
SnackBarType[SnackBarType["FAILURE"] = 1] = "FAILURE";
|
|
17
|
+
SnackBarType[SnackBarType["WARNING"] = 2] = "WARNING";
|
|
17
18
|
return SnackBarType;
|
|
18
19
|
}({});
|
|
19
20
|
exports.SnackBarType = SnackBarType;
|
|
@@ -102,7 +103,7 @@ const SnackbarCustom = _ref => {
|
|
|
102
103
|
backgroundColor: colors.onSurface
|
|
103
104
|
}]
|
|
104
105
|
}, /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
105
|
-
style: type && type === SnackBarType.FAILURE ? styles.fail : styles.main
|
|
106
|
+
style: type && type === SnackBarType.FAILURE ? styles.fail : type && type === SnackBarType.WARNING ? styles.warn : styles.main
|
|
106
107
|
}, type && type === SnackBarType.FAILURE ? /*#__PURE__*/_react.default.createElement(_vectorIcons.AntDesign, {
|
|
107
108
|
name: "exclamationcircleo",
|
|
108
109
|
size: 20,
|
|
@@ -141,14 +142,21 @@ const styles = _reactNative.StyleSheet.create({
|
|
|
141
142
|
padding: 16,
|
|
142
143
|
flexDirection: 'row',
|
|
143
144
|
alignItems: 'center',
|
|
144
|
-
backgroundColor: '#
|
|
145
|
+
backgroundColor: '#059669',
|
|
145
146
|
flex: 1
|
|
146
147
|
},
|
|
147
148
|
fail: {
|
|
148
149
|
padding: 16,
|
|
149
150
|
flexDirection: 'row',
|
|
150
151
|
alignItems: 'center',
|
|
151
|
-
backgroundColor: '#
|
|
152
|
+
backgroundColor: '#DC2626',
|
|
153
|
+
flex: 1
|
|
154
|
+
},
|
|
155
|
+
warn: {
|
|
156
|
+
padding: 16,
|
|
157
|
+
flexDirection: 'row',
|
|
158
|
+
alignItems: 'center',
|
|
159
|
+
backgroundColor: '#D97706',
|
|
152
160
|
flex: 1
|
|
153
161
|
},
|
|
154
162
|
messageStyle: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_react","_interopRequireDefault","require","_reactNative","_reactNativePaper","_vectorIcons","_CommonStyles","obj","__esModule","default","DURATION_MEDIUM","SnackBarType","exports","SnackbarCustom","_ref","visible","duration","onDismiss","message","theme","type","customBottom","current","opacity","React","useRef","Animated","Value","hidden","setHidden","useState","hideTimeout","undefined","scale","animation","useEffect","clearTimeout","useLayoutEffect","timing","toValue","useNativeDriver","start","_ref2","finished","isInfinity","Number","POSITIVE_INFINITY","NEGATIVE_INFINITY","setTimeout","_ref3","colors","roundness","createElement","SafeAreaView","pointerEvents","style","styles","wrapper","bottom","Surface","accessibilityLiveRegion","container","borderRadius","transform","interpolate","inputRange","outputRange","backgroundColor","onSurface","View","FAILURE","fail","main","AntDesign","name","size","color","Text","messageStyle","onPress","StyleSheet","create","position","width","zIndex","elevation","flexDirection","justifyContent","alignItems","margin","padding","flex","marginStart","marginEnd","fontWeight","fontFamily","Fonts","IBMPlexSans_600SemiBold","_default","withTheme"],"sources":["SnackBarCustom.tsx"],"sourcesContent":["import React from 'react';\nimport {\n Animated,\n SafeAreaView,\n StyleProp,\n StyleSheet,\n Text,\n View,\n ViewStyle,\n} from 'react-native';\nimport { Surface, withTheme } from 'react-native-paper';\nimport { AntDesign } from '@expo/vector-icons';\nimport { Fonts } from '../../styles/executionTasks/CommonStyles';\n\nexport interface SnackbarProps {\n visible: boolean;\n duration?: number;\n /**\n * Callback called when Snackbar is dismissed. The `visible` prop needs to be updated when this is called.\n */\n onDismiss: () => void;\n /**\n * Text content of the Snackbar.\n */\n message: string;\n type?: SnackBarType;\n theme: ReactNativePaper.Theme;\n customBottom?: number;\n}\nconst DURATION_MEDIUM = 1000;\n\nexport enum SnackBarType {\n SUCCESS,\n FAILURE,\n}\n\nconst SnackbarCustom = ({\n visible,\n duration = DURATION_MEDIUM,\n onDismiss,\n message,\n theme,\n type,\n customBottom = 110,\n}: SnackbarProps) => {\n const { current: opacity } = React.useRef<Animated.Value>(\n new Animated.Value(0.0)\n );\n const [hidden, setHidden] = React.useState<boolean>(!visible);\n\n const hideTimeout = React.useRef<NodeJS.Timeout | undefined>(undefined);\n const { scale } = theme.animation;\n\n React.useEffect(() => {\n return () => {\n if (hideTimeout.current) clearTimeout(hideTimeout.current);\n };\n }, []);\n\n React.useLayoutEffect(() => {\n if (visible) {\n // show\n if (hideTimeout.current) clearTimeout(hideTimeout.current);\n setHidden(false);\n Animated.timing(opacity, {\n toValue: 1,\n duration: 200 * scale,\n useNativeDriver: true,\n }).start(({ finished }) => {\n if (finished) {\n const isInfinity =\n duration === Number.POSITIVE_INFINITY ||\n duration === Number.NEGATIVE_INFINITY;\n\n if (finished && !isInfinity) {\n hideTimeout.current = setTimeout(\n onDismiss,\n duration\n ) as unknown as NodeJS.Timeout;\n }\n }\n });\n } else {\n // hide\n if (hideTimeout.current) clearTimeout(hideTimeout.current);\n\n Animated.timing(opacity, {\n toValue: 0,\n duration: 100 * scale,\n useNativeDriver: true,\n }).start(({ finished }) => {\n if (finished) setHidden(true);\n });\n }\n }, [visible, duration, opacity, scale, onDismiss]);\n\n const { colors, roundness } = theme;\n\n if (hidden) return null;\n\n if (!message) return null;\n\n return (\n <SafeAreaView\n pointerEvents=\"box-none\"\n style={[styles.wrapper, { bottom: customBottom }]}\n >\n <Surface\n pointerEvents=\"box-none\"\n accessibilityLiveRegion=\"polite\"\n style={\n [\n styles.container,\n {\n borderRadius: roundness,\n opacity: opacity,\n transform: [\n {\n scale: visible\n ? opacity.interpolate({\n inputRange: [0, 1],\n outputRange: [0.9, 1],\n })\n : 1,\n },\n ],\n },\n { backgroundColor: colors.onSurface },\n ] as StyleProp<ViewStyle>\n }\n >\n <View\n style={\n type && type === SnackBarType.FAILURE ? styles.fail : styles.main\n }\n >\n {type && type === SnackBarType.FAILURE ? (\n <AntDesign name=\"exclamationcircleo\" size={20} color=\"white\" />\n ) : (\n <AntDesign name=\"checkcircleo\" size={20} color=\"white\" />\n )}\n <Text style={styles.messageStyle}>{message}</Text>\n <AntDesign\n name=\"close\"\n size={16}\n color=\"white\"\n onPress={() => {\n setHidden(true);\n }}\n />\n </View>\n </Surface>\n </SafeAreaView>\n );\n};\n\nconst styles = StyleSheet.create({\n wrapper: {\n position: 'absolute',\n bottom: 110,\n width: '100%',\n zIndex: 1000,\n },\n container: {\n elevation: 6,\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'center',\n margin: 8,\n borderRadius: 4,\n },\n main: {\n padding: 16,\n flexDirection: 'row',\n alignItems: 'center',\n backgroundColor: '#10B981',\n flex: 1,\n },\n fail: {\n padding: 16,\n flexDirection: 'row',\n alignItems: 'center',\n backgroundColor: '#FA3A2E',\n flex: 1,\n },\n messageStyle: {\n flex: 1,\n marginStart: 20,\n marginEnd: 20,\n color: '#ffffff',\n fontWeight: '600',\n fontFamily: Fonts.IBMPlexSans_600SemiBold,\n },\n});\n\nexport default withTheme(SnackbarCustom);\n"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AASA,IAAAE,iBAAA,GAAAF,OAAA;AACA,IAAAG,YAAA,GAAAH,OAAA;AACA,IAAAI,aAAA,GAAAJ,OAAA;AAAiE,SAAAD,uBAAAM,GAAA,WAAAA,GAAA,IAAAA,GAAA,CAAAC,UAAA,GAAAD,GAAA,KAAAE,OAAA,EAAAF,GAAA;AAiBjE,MAAMG,eAAe,GAAG,IAAI;AAAC,IAEjBC,YAAY,0BAAZA,YAAY;EAAZA,YAAY,CAAZA,YAAY;EAAZA,YAAY,CAAZA,YAAY;EAAA,OAAZA,YAAY;AAAA;AAAAC,OAAA,CAAAD,YAAA,GAAAA,YAAA;AAKxB,MAAME,cAAc,GAAGC,IAAA,IAQF;EAAA,IARG;IACtBC,OAAO;IACPC,QAAQ,GAAGN,eAAe;IAC1BO,SAAS;I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M;IACbC,MAAM,EAAE;EACV,CAAC;EACDvB,SAAS,EAAE;IACTwB,SAAS,EAAE,CAAC;IACZC,aAAa,EAAE,KAAK;IACpBC,cAAc,EAAE,eAAe;IAC/BC,UAAU,EAAE,QAAQ;IACpBC,MAAM,EAAE,CAAC;IACT3B,YAAY,EAAE;EAChB,CAAC;EACDU,IAAI,EAAE;IACJkB,OAAO,EAAE,EAAE;IACXJ,aAAa,EAAE,KAAK;IACpBE,UAAU,EAAE,QAAQ;IACpBrB,eAAe,EAAE,SAAS;IAC1BwB,IAAI,EAAE;EACR,CAAC;EACDpB,IAAI,EAAE;IACJmB,OAAO,EAAE,EAAE;IACXJ,aAAa,EAAE,KAAK;IACpBE,UAAU,EAAE,QAAQ;IACpBrB,eAAe,EAAE,SAAS;IAC1BwB,IAAI,EAAE;EACR,CAAC;EACDb,YAAY,EAAE;IACZa,IAAI,EAAE,CAAC;IACPC,WAAW,EAAE,EAAE;IACfC,SAAS,EAAE,EAAE;IACbjB,KAAK,EAAE,SAAS;IAChBkB,UAAU,EAAE,KAAK;IACjBC,UAAU,EAAEC,mBAAK,CAACC;EACpB;AACF,CAAC,CAAC;AAAC,IAAAC,QAAA,GAEY,IAAAC,2BAAS,EAACtF,cAAc,CAAC;AAAAD,OAAA,CAAAH,OAAA,GAAAyF,QAAA"}
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireDefault","require","_reactNative","_reactNativePaper","_vectorIcons","_CommonStyles","obj","__esModule","default","DURATION_MEDIUM","SnackBarType","exports","SnackbarCustom","_ref","visible","duration","onDismiss","message","theme","type","customBottom","current","opacity","React","useRef","Animated","Value","hidden","setHidden","useState","hideTimeout","undefined","scale","animation","useEffect","clearTimeout","useLayoutEffect","timing","toValue","useNativeDriver","start","_ref2","finished","isInfinity","Number","POSITIVE_INFINITY","NEGATIVE_INFINITY","setTimeout","_ref3","colors","roundness","createElement","SafeAreaView","pointerEvents","style","styles","wrapper","bottom","Surface","accessibilityLiveRegion","container","borderRadius","transform","interpolate","inputRange","outputRange","backgroundColor","onSurface","View","FAILURE","fail","WARNING","warn","main","AntDesign","name","size","color","Text","messageStyle","onPress","StyleSheet","create","position","width","zIndex","elevation","flexDirection","justifyContent","alignItems","margin","padding","flex","marginStart","marginEnd","fontWeight","fontFamily","Fonts","IBMPlexSans_600SemiBold","_default","withTheme"],"sources":["SnackBarCustom.tsx"],"sourcesContent":["import React from 'react';\nimport {\n Animated,\n SafeAreaView,\n StyleProp,\n StyleSheet,\n Text,\n View,\n ViewStyle,\n} from 'react-native';\nimport { Surface, withTheme } from 'react-native-paper';\nimport { AntDesign } from '@expo/vector-icons';\nimport { Fonts } from '../../styles/executionTasks/CommonStyles';\n\nexport interface SnackbarProps {\n visible: boolean;\n duration?: number;\n /**\n * Callback called when Snackbar is dismissed. The `visible` prop needs to be updated when this is called.\n */\n onDismiss: () => void;\n /**\n * Text content of the Snackbar.\n */\n message: string;\n type?: SnackBarType;\n theme: ReactNativePaper.Theme;\n customBottom?: number;\n}\nconst DURATION_MEDIUM = 3000;\n\nexport enum SnackBarType {\n SUCCESS,\n FAILURE,\n WARNING,\n}\n\nconst SnackbarCustom = ({\n visible,\n duration = DURATION_MEDIUM,\n onDismiss,\n message,\n theme,\n type,\n customBottom = 110,\n}: SnackbarProps) => {\n const { current: opacity } = React.useRef<Animated.Value>(\n new Animated.Value(0.0)\n );\n const [hidden, setHidden] = React.useState<boolean>(!visible);\n\n const hideTimeout = React.useRef<NodeJS.Timeout | undefined>(undefined);\n const { scale } = theme.animation;\n\n React.useEffect(() => {\n return () => {\n if (hideTimeout.current) clearTimeout(hideTimeout.current);\n };\n }, []);\n\n React.useLayoutEffect(() => {\n if (visible) {\n // show\n if (hideTimeout.current) clearTimeout(hideTimeout.current);\n setHidden(false);\n Animated.timing(opacity, {\n toValue: 1,\n duration: 200 * scale,\n useNativeDriver: true,\n }).start(({ finished }) => {\n if (finished) {\n const isInfinity =\n duration === Number.POSITIVE_INFINITY ||\n duration === Number.NEGATIVE_INFINITY;\n\n if (finished && !isInfinity) {\n hideTimeout.current = setTimeout(\n onDismiss,\n duration\n ) as unknown as NodeJS.Timeout;\n }\n }\n });\n } else {\n // hide\n if (hideTimeout.current) clearTimeout(hideTimeout.current);\n\n Animated.timing(opacity, {\n toValue: 0,\n duration: 100 * scale,\n useNativeDriver: true,\n }).start(({ finished }) => {\n if (finished) setHidden(true);\n });\n }\n }, [visible, duration, opacity, scale, onDismiss]);\n\n const { colors, roundness } = theme;\n\n if (hidden) return null;\n\n if (!message) return null;\n\n return (\n <SafeAreaView\n pointerEvents=\"box-none\"\n style={[styles.wrapper, { bottom: customBottom }]}\n >\n <Surface\n pointerEvents=\"box-none\"\n accessibilityLiveRegion=\"polite\"\n style={\n [\n styles.container,\n {\n borderRadius: roundness,\n opacity: opacity,\n transform: [\n {\n scale: visible\n ? opacity.interpolate({\n inputRange: [0, 1],\n outputRange: [0.9, 1],\n })\n : 1,\n },\n ],\n },\n { backgroundColor: colors.onSurface },\n ] as StyleProp<ViewStyle>\n }\n >\n <View\n style={\n type && type === SnackBarType.FAILURE\n ? styles.fail\n : type && type === SnackBarType.WARNING\n ? styles.warn\n : styles.main\n }\n >\n {type && type === SnackBarType.FAILURE ? (\n <AntDesign name=\"exclamationcircleo\" size={20} color=\"white\" />\n ) : (\n <AntDesign name=\"checkcircleo\" size={20} color=\"white\" />\n )}\n <Text style={styles.messageStyle}>{message}</Text>\n <AntDesign\n name=\"close\"\n size={16}\n color=\"white\"\n onPress={() => {\n setHidden(true);\n }}\n />\n </View>\n </Surface>\n </SafeAreaView>\n );\n};\n\nconst styles = StyleSheet.create({\n wrapper: {\n position: 'absolute',\n bottom: 110,\n width: '100%',\n zIndex: 1000,\n },\n container: {\n elevation: 6,\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'center',\n margin: 8,\n borderRadius: 4,\n },\n main: {\n padding: 16,\n flexDirection: 'row',\n alignItems: 'center',\n backgroundColor: '#059669',\n flex: 1,\n },\n fail: {\n padding: 16,\n flexDirection: 'row',\n alignItems: 'center',\n backgroundColor: '#DC2626',\n flex: 1,\n },\n warn: {\n padding: 16,\n flexDirection: 'row',\n alignItems: 'center',\n backgroundColor: '#D97706',\n flex: 1,\n },\n messageStyle: {\n flex: 1,\n marginStart: 20,\n marginEnd: 20,\n color: '#ffffff',\n fontWeight: '600',\n fontFamily: Fonts.IBMPlexSans_600SemiBold,\n },\n});\n\nexport default withTheme(SnackbarCustom);\n"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AASA,IAAAE,iBAAA,GAAAF,OAAA;AACA,IAAAG,YAAA,GAAAH,OAAA;AACA,IAAAI,aAAA,GAAAJ,OAAA;AAAiE,SAAAD,uBAAAM,GAAA,WAAAA,GAAA,IAAAA,GAAA,CAAAC,UAAA,GAAAD,GAAA,KAAAE,OAAA,EAAAF,GAAA;AAiBjE,MAAMG,eAAe,GAAG,IAAI;AAAC,IAEjBC,YAAY,0BAAZA,YAAY;EAAZA,YAAY,CAAZA,YAAY;EAAZA,YAAY,CAAZA,YAAY;EAAZA,YAAY,CAAZA,YAAY;EAAA,OAAZA,YAAY;AAAA;AAAAC,OAAA,CAAAD,YAAA,GAAAA,YAAA;AAMxB,MAAME,cAAc,GAAGC,IAAA,IAQF;EAAA,IARG;IACtBC,OAAO;IACPC,QAAQ,GAAGN,eAAe;IAC1BO,SAAS;IACTC,OAAO;IACPC,KAAK;IACLC,IAAI;IACJC,YAAY,GAAG;EACF,CAAC,GAAAP,IAAA;EACd,MAAM;IAAEQ,OAAO,EAAEC;EAAQ,CAAC,GAAGC,cAAK,CAACC,MAAM,CACvC,IAAIC,qBAAQ,CAACC,KAAK,CAAC,GAAG,CACxB,CAAC;EACD,MAAM,CAACC,MAAM,EAAEC,SAAS,CAAC,GAAGL,cAAK,CAACM,QAAQ,CAAU,CAACf,OAAO,CAAC;EAE7D,MAAMgB,WAAW,GAAGP,cAAK,CAACC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EAAE,EAAE;IACXJ,aAAa,EAAE,KAAK;IACpBE,UAAU,EAAE,QAAQ;IACpBvB,eAAe,EAAE,SAAS;IAC1B0B,IAAI,EAAE;EACR,CAAC;EACDtB,IAAI,EAAE;IACJqB,OAAO,EAAE,EAAE;IACXJ,aAAa,EAAE,KAAK;IACpBE,UAAU,EAAE,QAAQ;IACpBvB,eAAe,EAAE,SAAS;IAC1B0B,IAAI,EAAE;EACR,CAAC;EACDpB,IAAI,EAAE;IACJmB,OAAO,EAAE,EAAE;IACXJ,aAAa,EAAE,KAAK;IACpBE,UAAU,EAAE,QAAQ;IACpBvB,eAAe,EAAE,SAAS;IAC1B0B,IAAI,EAAE;EACR,CAAC;EACDb,YAAY,EAAE;IACZa,IAAI,EAAE,CAAC;IACPC,WAAW,EAAE,EAAE;IACfC,SAAS,EAAE,EAAE;IACbjB,KAAK,EAAE,SAAS;IAChBkB,UAAU,EAAE,KAAK;IACjBC,UAAU,EAAEC,mBAAK,CAACC;EACpB;AACF,CAAC,CAAC;AAAC,IAAAC,QAAA,GAEY,IAAAC,2BAAS,EAACxF,cAAc,CAAC;AAAAD,OAAA,CAAAH,OAAA,GAAA2F,QAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_reactNative","require","_react","_interopRequireWildcard","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","obj","__esModule","default","cache","has","get","newObj","hasPropertyDescriptor","Object","defineProperty","getOwnPropertyDescriptor","key","prototype","hasOwnProperty","call","desc","set","SplitTextInput","_ref","styles","value","onChange","maxLength","keyboardType","hasError","inputRef","useRef","boxArray","Array","fill","isInputBoxFocused","setIsInputBoxFocused","useState","handleOnPress","current","focus","handleOnBlur","boxDigit","_","index","digit","isCurrentValue","length","isLastValue","isCodeComplete","isValueFocused","splitBoxesStyle","Boolean","widgetStyles","errorSplitBoxes","focusedSplitBoxes","splitBoxes","createElement","View","style","Text","Fragment","Pressable","onPress","splitContainer","map","TextInput","textInputHidden","onChangeText","ref","onBlur","_default","exports","StyleSheet","create","width","flexDirection","justifyContent","borderColor","borderWidth","borderRadius","padding","minWidth","height","position","opacity"],"sources":["SplitTextInput.tsx"],"sourcesContent":["import {\n View,\n Text,\n Pressable,\n StyleSheet,\n TextInput,\n KeyboardTypeOptions,\n} from 'react-native';\nimport React, { useRef, useState } from 'react';\n\nexport interface SplitTextInputProps {\n styles: any;\n value: string;\n onChange: (text: string) => void;\n maxLength: number;\n keyboardType: KeyboardTypeOptions;\n hasError: boolean;\n}\n\nconst SplitTextInput = ({\n styles,\n value,\n onChange,\n maxLength,\n keyboardType,\n hasError,\n}: SplitTextInputProps) => {\n const inputRef: any = useRef();\n const boxArray = new Array(maxLength).fill(0);\n const [isInputBoxFocused, setIsInputBoxFocused] = useState(false);\n\n const handleOnPress = () => {\n setIsInputBoxFocused(true);\n inputRef.current.focus();\n };\n\n const handleOnBlur = () => {\n setIsInputBoxFocused(false);\n };\n\n const boxDigit = (_: number, index: number) => {\n const digit = value[index] || '';\n\n const isCurrentValue = index === value.length;\n const isLastValue = index === maxLength - 1;\n const isCodeComplete = value.length === maxLength;\n\n const isValueFocused = isCurrentValue || (isLastValue && isCodeComplete);\n\n const splitBoxesStyle = Boolean(hasError)\n ? widgetStyles.errorSplitBoxes\n : (isInputBoxFocused && isValueFocused) || value[index]\n ? widgetStyles.focusedSplitBoxes\n : widgetStyles.splitBoxes;\n\n return (\n <View style={splitBoxesStyle} key={index}>\n <Text style={styles}>{digit}</Text>\n </View>\n );\n };\n\n return (\n <>\n <Pressable onPress={handleOnPress} style={widgetStyles.splitContainer}>\n {boxArray.map(boxDigit)}\n </Pressable>\n <TextInput\n style={widgetStyles.textInputHidden}\n value={value}\n onChangeText={onChange}\n maxLength={maxLength}\n ref={inputRef}\n onBlur={handleOnBlur}\n keyboardType={keyboardType}\n />\n </>\n );\n};\n\nexport default SplitTextInput;\n\nconst widgetStyles = StyleSheet.create({\n splitContainer: {\n width: '100%',\n flexDirection: 'row',\n justifyContent: 'space-evenly',\n },\n splitBoxes: {\n borderColor: '#dddddd',\n borderWidth: 2,\n borderRadius: 5,\n padding: 12,\n minWidth: 50,\n },\n focusedSplitBoxes: {\n borderColor: '#666666',\n borderWidth: 2,\n borderRadius: 5,\n padding: 12,\n minWidth: 50,\n },\n errorSplitBoxes: {\n borderColor: '#DC2626',\n borderWidth: 2,\n borderRadius: 5,\n padding: 12,\n minWidth: 50,\n },\n textInputHidden: {\n height: 30,\n width: 300,\n position: 'absolute',\n opacity: 0,\n },\n});\n"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AAQA,IAAAC,MAAA,GAAAC,uBAAA,CAAAF,OAAA;AAAgD,SAAAG,yBAAAC,WAAA,eAAAC,OAAA,kCAAAC,iBAAA,OAAAD,OAAA,QAAAE,gBAAA,OAAAF,OAAA,YAAAF,wBAAA,YAAAA,CAAAC,WAAA,WAAAA,WAAA,GAAAG,gBAAA,GAAAD,iBAAA,KAAAF,WAAA;AAAA,SAAAF,wBAAAM,GAAA,EAAAJ,WAAA,SAAAA,WAAA,IAAAI,GAAA,IAAAA,GAAA,CAAAC,UAAA,WAAAD,GAAA,QAAAA,GAAA,oBAAAA,GAAA,wBAAAA,GAAA,4BAAAE,OAAA,EAAAF,GAAA,UAAAG,KAAA,GAAAR,wBAAA,CAAAC,WAAA,OAAAO,KAAA,IAAAA,KAAA,CAAAC,GAAA,CAAAJ,GAAA,YAAAG,KAAA,CAAAE,GAAA,CAAAL,GAAA,SAAAM,MAAA,WAAAC,qBAAA,GAAAC,MAAA,CAAAC,cAAA,IAAAD,MAAA,CAAAE,wBAAA,WAAAC,GAAA,IAAAX,GAAA,QAAAW,GAAA,kBAAAH,MAAA,CAAAI,SAAA,CAAAC,cAAA,CAAAC,IAAA,CAAAd,GAAA,EAAAW,GAAA,SAAAI,IAAA,GAAAR,qBAAA,GAAAC,MAAA,CAAAE,wBAAA,CAAAV,GAAA,EAAAW,GAAA,cAAAI,IAAA,KAAAA,IAAA,CAAAV,GAAA,IAAAU,IAAA,CAAAC,GAAA,KAAAR,MAAA,CAAAC,cAAA,CAAAH,MAAA,EAAAK,GAAA,EAAAI,IAAA,YAAAT,MAAA,CAAAK,GAAA,IAAAX,GAAA,CAAAW,GAAA,SAAAL,MAAA,CAAAJ,OAAA,GAAAF,GAAA,MAAAG,KAAA,IAAAA,KAAA,CAAAa,GAAA,CAAAhB,GAAA,EAAAM,MAAA,YAAAA,MAAA;AAWhD,MAAMW,cAAc,GAAGC,IAAA,IAOI;EAAA,IAPH;IACtBC,MAAM;IACNC,KAAK;IACLC,QAAQ;IACRC,SAAS;IACTC,YAAY;IACZC;EACmB,CAAC,GAAAN,IAAA;EACpB,MAAMO,QAAa,GAAG,IAAAC,aAAM,
|
|
1
|
+
{"version":3,"names":["_reactNative","require","_react","_interopRequireWildcard","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","obj","__esModule","default","cache","has","get","newObj","hasPropertyDescriptor","Object","defineProperty","getOwnPropertyDescriptor","key","prototype","hasOwnProperty","call","desc","set","SplitTextInput","_ref","styles","value","onChange","maxLength","keyboardType","hasError","inputRef","useRef","boxArray","Array","fill","isInputBoxFocused","setIsInputBoxFocused","useState","handleOnPress","current","focus","handleOnBlur","boxDigit","_","index","digit","isCurrentValue","length","isLastValue","isCodeComplete","isValueFocused","splitBoxesStyle","Boolean","widgetStyles","errorSplitBoxes","focusedSplitBoxes","splitBoxes","createElement","View","style","Text","Fragment","Pressable","onPress","splitContainer","map","TextInput","textInputHidden","onChangeText","ref","onBlur","_default","exports","StyleSheet","create","width","flexDirection","justifyContent","borderColor","borderWidth","borderRadius","padding","minWidth","height","position","opacity"],"sources":["SplitTextInput.tsx"],"sourcesContent":["import {\n View,\n Text,\n Pressable,\n StyleSheet,\n TextInput,\n KeyboardTypeOptions,\n} from 'react-native';\nimport React, { useRef, useState } from 'react';\n\nexport interface SplitTextInputProps {\n styles: any;\n value: string;\n onChange: (text: string) => void;\n maxLength: number;\n keyboardType: KeyboardTypeOptions;\n hasError: boolean;\n}\n\nconst SplitTextInput = ({\n styles,\n value,\n onChange,\n maxLength,\n keyboardType,\n hasError,\n}: SplitTextInputProps) => {\n const inputRef: any = useRef();\n const boxArray = new Array(maxLength).fill(0);\n const [isInputBoxFocused, setIsInputBoxFocused] = useState(false);\n\n const handleOnPress = () => {\n setIsInputBoxFocused(true);\n inputRef.current.focus();\n };\n\n const handleOnBlur = () => {\n setIsInputBoxFocused(false);\n };\n\n const boxDigit = (_: number, index: number) => {\n const digit = value[index] || '';\n\n const isCurrentValue = index === value.length;\n const isLastValue = index === maxLength - 1;\n const isCodeComplete = value.length === maxLength;\n\n const isValueFocused = isCurrentValue || (isLastValue && isCodeComplete);\n\n const splitBoxesStyle = Boolean(hasError)\n ? widgetStyles.errorSplitBoxes\n : (isInputBoxFocused && isValueFocused) || value[index]\n ? widgetStyles.focusedSplitBoxes\n : widgetStyles.splitBoxes;\n\n return (\n <View style={splitBoxesStyle} key={index}>\n <Text style={styles}>{digit}</Text>\n </View>\n );\n };\n\n return (\n <>\n <Pressable onPress={handleOnPress} style={widgetStyles.splitContainer}>\n {boxArray.map(boxDigit)}\n </Pressable>\n <TextInput\n style={widgetStyles.textInputHidden}\n value={value}\n onChangeText={onChange}\n maxLength={maxLength}\n ref={inputRef}\n onBlur={handleOnBlur}\n keyboardType={keyboardType}\n />\n </>\n );\n};\n\nexport default SplitTextInput;\n\nconst widgetStyles = StyleSheet.create({\n splitContainer: {\n width: '100%',\n flexDirection: 'row',\n justifyContent: 'space-evenly',\n },\n splitBoxes: {\n borderColor: '#dddddd',\n borderWidth: 2,\n borderRadius: 5,\n padding: 12,\n minWidth: 50,\n },\n focusedSplitBoxes: {\n borderColor: '#666666',\n borderWidth: 2,\n borderRadius: 5,\n padding: 12,\n minWidth: 50,\n },\n errorSplitBoxes: {\n borderColor: '#DC2626',\n borderWidth: 2,\n borderRadius: 5,\n padding: 12,\n minWidth: 50,\n },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IACtBC,WAAW,EAAE,CAAC;IACdC,YAAY,EAAE,CAAC;IACfC,OAAO,EAAE,EAAE;IACXC,QAAQ,EAAE;EACZ,CAAC;EACD5B,eAAe,EAAE;IACfwB,WAAW,EAAE,SAAS;IACtBC,WAAW,EAAE,CAAC;IACdC,YAAY,EAAE,CAAC;IACfC,OAAO,EAAE,EAAE;IACXC,QAAQ,EAAE;EACZ,CAAC;EACDf,eAAe,EAAE;IACfgB,MAAM,EAAE,EAAE;IACVR,KAAK,EAAE,GAAG;IACVS,QAAQ,EAAE,UAAU;IACpBC,OAAO,EAAE;EACX;AACF,CAAC,CAAC"}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
8
|
+
var _reactNative = require("react-native");
|
|
9
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
10
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
11
|
+
const TabsComponent = props => {
|
|
12
|
+
const [activeTab, setActiveTab] = (0, _react.useState)(props.initialTab.title);
|
|
13
|
+
const handleTabPress = tabName => {
|
|
14
|
+
setActiveTab(tabName);
|
|
15
|
+
props.onTabChange(tabName);
|
|
16
|
+
};
|
|
17
|
+
return /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
18
|
+
style: styles.container
|
|
19
|
+
}, /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
20
|
+
style: {
|
|
21
|
+
flexDirection: 'row'
|
|
22
|
+
}
|
|
23
|
+
}, /*#__PURE__*/_react.default.createElement(_reactNative.ScrollView, {
|
|
24
|
+
horizontal: true,
|
|
25
|
+
showsHorizontalScrollIndicator: false,
|
|
26
|
+
contentContainerStyle: styles.tabsContainer
|
|
27
|
+
}, props.tabs.map(tab => {
|
|
28
|
+
return /*#__PURE__*/_react.default.createElement(_reactNative.TouchableOpacity, {
|
|
29
|
+
key: tab.title,
|
|
30
|
+
style: [styles.tabItem, activeTab === tab.title && styles.activeTab, tab.titleStyle ? tab.titleStyle : {}],
|
|
31
|
+
onPress: () => handleTabPress(tab.title)
|
|
32
|
+
}, props.renderTabItem(tab));
|
|
33
|
+
}))), /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
34
|
+
style: styles.contentContainer
|
|
35
|
+
}, props.renderBody(activeTab)));
|
|
36
|
+
};
|
|
37
|
+
const styles = _reactNative.StyleSheet.create({
|
|
38
|
+
container: {
|
|
39
|
+
flex: 1
|
|
40
|
+
},
|
|
41
|
+
tabsContainer: {
|
|
42
|
+
flexDirection: 'row',
|
|
43
|
+
justifyContent: 'space-around',
|
|
44
|
+
backgroundColor: '#f0f0f0',
|
|
45
|
+
flexGrow: 1,
|
|
46
|
+
paddingHorizontal: 20
|
|
47
|
+
},
|
|
48
|
+
tabItem: {
|
|
49
|
+
// width: 200,
|
|
50
|
+
alignItems: 'center',
|
|
51
|
+
paddingVertical: 10,
|
|
52
|
+
marginHorizontal: 10
|
|
53
|
+
},
|
|
54
|
+
activeTab: {
|
|
55
|
+
borderBottomWidth: 2,
|
|
56
|
+
borderBottomColor: 'blue'
|
|
57
|
+
},
|
|
58
|
+
contentContainer: {
|
|
59
|
+
flex: 1
|
|
60
|
+
}
|
|
61
|
+
});
|
|
62
|
+
var _default = TabsComponent;
|
|
63
|
+
exports.default = _default;
|
|
64
|
+
//# sourceMappingURL=TabsComponent.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","obj","__esModule","default","cache","has","get","newObj","hasPropertyDescriptor","Object","defineProperty","getOwnPropertyDescriptor","key","prototype","hasOwnProperty","call","desc","set","TabsComponent","props","activeTab","setActiveTab","useState","initialTab","title","handleTabPress","tabName","onTabChange","createElement","View","style","styles","container","flexDirection","ScrollView","horizontal","showsHorizontalScrollIndicator","contentContainerStyle","tabsContainer","tabs","map","tab","TouchableOpacity","tabItem","titleStyle","onPress","renderTabItem","contentContainer","renderBody","StyleSheet","create","flex","justifyContent","backgroundColor","flexGrow","paddingHorizontal","alignItems","paddingVertical","marginHorizontal","borderBottomWidth","borderBottomColor","_default","exports"],"sources":["TabsComponent.tsx"],"sourcesContent":["import React, { useState } from 'react';\nimport { View, TouchableOpacity, StyleSheet, ScrollView } from 'react-native';\n\nexport interface Tab {\n title: string;\n count: number;\n titleStyle?: any;\n}\n\ninterface TabsComponentProps {\n tabs: Array<Tab>;\n initialTab: Tab;\n onTabChange: (currentTab: string) => void;\n renderTabItem: (tab: Tab) => JSX.Element;\n renderBody: (currentTab: string) => JSX.Element | null;\n}\n\nconst TabsComponent = (props: TabsComponentProps) => {\n const [activeTab, setActiveTab] = useState(props.initialTab.title);\n\n const handleTabPress = (tabName: string) => {\n setActiveTab(tabName);\n props.onTabChange(tabName);\n };\n\n return (\n <View style={styles.container}>\n <View style={{ flexDirection: 'row' }}>\n <ScrollView\n horizontal\n showsHorizontalScrollIndicator={false}\n contentContainerStyle={styles.tabsContainer}\n >\n {props.tabs.map((tab: Tab) => {\n return (\n <TouchableOpacity\n key={tab.title}\n style={[\n styles.tabItem,\n activeTab === tab.title && styles.activeTab,\n tab.titleStyle ? tab.titleStyle : {},\n ]}\n onPress={() => handleTabPress(tab.title)}\n >\n {props.renderTabItem(tab)}\n </TouchableOpacity>\n );\n })}\n </ScrollView>\n </View>\n\n {/* Render content based on the active tab */}\n <View style={styles.contentContainer}>{props.renderBody(activeTab)}</View>\n </View>\n );\n};\n\nconst styles = StyleSheet.create({\n container: {\n flex: 1,\n },\n tabsContainer: {\n flexDirection: 'row',\n justifyContent: 'space-around',\n backgroundColor: '#f0f0f0',\n flexGrow: 1,\n paddingHorizontal: 20,\n },\n tabItem: {\n // width: 200,\n alignItems: 'center',\n paddingVertical: 10,\n marginHorizontal: 10,\n },\n activeTab: {\n borderBottomWidth: 2,\n borderBottomColor: 'blue',\n },\n contentContainer: {\n flex: 1,\n },\n});\n\nexport default TabsComponent;\n"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAA8E,SAAAE,yBAAAC,WAAA,eAAAC,OAAA,kCAAAC,iBAAA,OAAAD,OAAA,QAAAE,gBAAA,OAAAF,OAAA,YAAAF,wBAAA,YAAAA,CAAAC,WAAA,WAAAA,WAAA,GAAAG,gBAAA,GAAAD,iBAAA,KAAAF,WAAA;AAAA,SAAAJ,wBAAAQ,GAAA,EAAAJ,WAAA,SAAAA,WAAA,IAAAI,GAAA,IAAAA,GAAA,CAAAC,UAAA,WAAAD,GAAA,QAAAA,GAAA,oBAAAA,GAAA,wBAAAA,GAAA,4BAAAE,OAAA,EAAAF,GAAA,UAAAG,KAAA,GAAAR,wBAAA,CAAAC,WAAA,OAAAO,KAAA,IAAAA,KAAA,CAAAC,GAAA,CAAAJ,GAAA,YAAAG,KAAA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AE;EACR;AACF,CAAC,CAAC;AAAC,IAAAU,QAAA,GAEY3C,aAAa;AAAA4C,OAAA,CAAA3D,OAAA,GAAA0D,QAAA"}
|
|
@@ -5,7 +5,9 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.ENDPOINTS = exports.API_CONFIG = void 0;
|
|
7
7
|
const ENDPOINTS = {
|
|
8
|
-
JOB_REMOVAL: dispatchId => `/dispatches/${dispatchId}/multiple-jobs
|
|
8
|
+
JOB_REMOVAL: dispatchId => `/dispatches/${dispatchId}/multiple-jobs`,
|
|
9
|
+
// NEW CODE
|
|
10
|
+
BULK_JOB_UPDATE: dispatchId => `/api/v2/produce/${dispatchId}/job-bulk-update`
|
|
9
11
|
};
|
|
10
12
|
exports.ENDPOINTS = ENDPOINTS;
|
|
11
13
|
const API_CONFIG = {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["ENDPOINTS","JOB_REMOVAL","dispatchId","exports","API_CONFIG","timeout"],"sources":["apiConstants.ts"],"sourcesContent":["export const ENDPOINTS = {\n JOB_REMOVAL: (dispatchId: string) =>\n `/dispatches/${dispatchId}/multiple-jobs`,\n};\n\nexport const API_CONFIG = {\n timeout: 15000, // timeout in millis i.e 15s\n};\n"],"mappings":";;;;;;AAAO,MAAMA,SAAS,GAAG;EACvBC,WAAW,EAAGC,UAAkB,IAC7B,eAAcA,UAAW;
|
|
1
|
+
{"version":3,"names":["ENDPOINTS","JOB_REMOVAL","dispatchId","BULK_JOB_UPDATE","exports","API_CONFIG","timeout"],"sources":["apiConstants.ts"],"sourcesContent":["export const ENDPOINTS = {\n JOB_REMOVAL: (dispatchId: string) =>\n `/dispatches/${dispatchId}/multiple-jobs`,\n // NEW CODE\n BULK_JOB_UPDATE: (dispatchId: string) =>\n `/api/v2/produce/${dispatchId}/job-bulk-update`,\n};\n\nexport const API_CONFIG = {\n timeout: 15000, // timeout in millis i.e 15s\n};\n"],"mappings":";;;;;;AAAO,MAAMA,SAAS,GAAG;EACvBC,WAAW,EAAGC,UAAkB,IAC7B,eAAcA,UAAW,gBAAe;EAC3C;EACAC,eAAe,EAAGD,UAAkB,IACjC,mBAAkBA,UAAW;AAClC,CAAC;AAACE,OAAA,CAAAJ,SAAA,GAAAA,SAAA;AAEK,MAAMK,UAAU,GAAG;EACxBC,OAAO,EAAE,KAAK,CAAE;AAClB,CAAC;AAACF,OAAA,CAAAC,UAAA,GAAAA,UAAA"}
|
|
@@ -14,11 +14,11 @@ const DEFAULT_INTERVAL = 10000;
|
|
|
14
14
|
exports.DEFAULT_INTERVAL = DEFAULT_INTERVAL;
|
|
15
15
|
const DEFAULT_PICKUP_TITLE = 'Pickup Order';
|
|
16
16
|
exports.DEFAULT_PICKUP_TITLE = DEFAULT_PICKUP_TITLE;
|
|
17
|
-
const DEFAULT_PICKUP_MESSAGE = 'Confirm Pickup of $
|
|
17
|
+
const DEFAULT_PICKUP_MESSAGE = 'Confirm Pickup of $ orders';
|
|
18
18
|
exports.DEFAULT_PICKUP_MESSAGE = DEFAULT_PICKUP_MESSAGE;
|
|
19
19
|
const DEFAULT_DELIVER_TITLE = 'Drop Order';
|
|
20
20
|
exports.DEFAULT_DELIVER_TITLE = DEFAULT_DELIVER_TITLE;
|
|
21
|
-
const DEFAULT_DELIVER_MESSAGE = 'Confirm Drop of $
|
|
21
|
+
const DEFAULT_DELIVER_MESSAGE = 'Confirm Drop of $ orders';
|
|
22
22
|
exports.DEFAULT_DELIVER_MESSAGE = DEFAULT_DELIVER_MESSAGE;
|
|
23
23
|
const DEFAULT_SIGN_ET_MESSAGE = 'Please capture a clear signature from the customer';
|
|
24
24
|
exports.DEFAULT_SIGN_ET_MESSAGE = DEFAULT_SIGN_ET_MESSAGE;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["LOCAL_STORAGE_KEY_PREFIX","exports","DEFAULT_NOTIFICATION_TITLE","DEFAULT_NOTIFICATION_DESCRIPTION","DEFAULT_INTERVAL","DEFAULT_PICKUP_TITLE","DEFAULT_PICKUP_MESSAGE","DEFAULT_DELIVER_TITLE","DEFAULT_DELIVER_MESSAGE","DEFAULT_SIGN_ET_MESSAGE","REASON_NOT_USED","GO_BACK_EVENT_CODE"],"sources":["constants.ts"],"sourcesContent":["export const LOCAL_STORAGE_KEY_PREFIX = '@dispatch-sdk:';\nexport const DEFAULT_NOTIFICATION_TITLE = 'Dispatch Sync Manager';\nexport const DEFAULT_NOTIFICATION_DESCRIPTION = 'Syncing Events & Files';\nexport const DEFAULT_INTERVAL = 10000;\nexport const DEFAULT_PICKUP_TITLE = 'Pickup Order';\nexport const DEFAULT_PICKUP_MESSAGE = 'Confirm Pickup of $
|
|
1
|
+
{"version":3,"names":["LOCAL_STORAGE_KEY_PREFIX","exports","DEFAULT_NOTIFICATION_TITLE","DEFAULT_NOTIFICATION_DESCRIPTION","DEFAULT_INTERVAL","DEFAULT_PICKUP_TITLE","DEFAULT_PICKUP_MESSAGE","DEFAULT_DELIVER_TITLE","DEFAULT_DELIVER_MESSAGE","DEFAULT_SIGN_ET_MESSAGE","REASON_NOT_USED","GO_BACK_EVENT_CODE"],"sources":["constants.ts"],"sourcesContent":["export const LOCAL_STORAGE_KEY_PREFIX = '@dispatch-sdk:';\nexport const DEFAULT_NOTIFICATION_TITLE = 'Dispatch Sync Manager';\nexport const DEFAULT_NOTIFICATION_DESCRIPTION = 'Syncing Events & Files';\nexport const DEFAULT_INTERVAL = 10000;\nexport const DEFAULT_PICKUP_TITLE = 'Pickup Order';\nexport const DEFAULT_PICKUP_MESSAGE = 'Confirm Pickup of $ orders';\nexport const DEFAULT_DELIVER_TITLE = 'Drop Order';\nexport const DEFAULT_DELIVER_MESSAGE = 'Confirm Drop of $ orders';\nexport const DEFAULT_SIGN_ET_MESSAGE =\n 'Please capture a clear signature from the customer';\nexport const REASON_NOT_USED = 'NOT_TO_BE_USED';\nexport const GO_BACK_EVENT_CODE = 'E-099';\n"],"mappings":";;;;;;AAAO,MAAMA,wBAAwB,GAAG,gBAAgB;AAACC,OAAA,CAAAD,wBAAA,GAAAA,wBAAA;AAClD,MAAME,0BAA0B,GAAG,uBAAuB;AAACD,OAAA,CAAAC,0BAAA,GAAAA,0BAAA;AAC3D,MAAMC,gCAAgC,GAAG,wBAAwB;AAACF,OAAA,CAAAE,gCAAA,GAAAA,gCAAA;AAClE,MAAMC,gBAAgB,GAAG,KAAK;AAACH,OAAA,CAAAG,gBAAA,GAAAA,gBAAA;AAC/B,MAAMC,oBAAoB,GAAG,cAAc;AAACJ,OAAA,CAAAI,oBAAA,GAAAA,oBAAA;AAC5C,MAAMC,sBAAsB,GAAG,4BAA4B;AAACL,OAAA,CAAAK,sBAAA,GAAAA,sBAAA;AAC5D,MAAMC,qBAAqB,GAAG,YAAY;AAACN,OAAA,CAAAM,qBAAA,GAAAA,qBAAA;AAC3C,MAAMC,uBAAuB,GAAG,0BAA0B;AAACP,OAAA,CAAAO,uBAAA,GAAAA,uBAAA;AAC3D,MAAMC,uBAAuB,GAClC,oDAAoD;AAACR,OAAA,CAAAQ,uBAAA,GAAAA,uBAAA;AAChD,MAAMC,eAAe,GAAG,gBAAgB;AAACT,OAAA,CAAAS,eAAA,GAAAA,eAAA;AACzC,MAAMC,kBAAkB,GAAG,OAAO;AAACV,OAAA,CAAAU,kBAAA,GAAAA,kBAAA"}
|
|
@@ -3,17 +3,13 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.
|
|
6
|
+
exports.default = void 0;
|
|
7
7
|
var _reactNative = require("react-native");
|
|
8
8
|
var _constants = require("./constants");
|
|
9
9
|
const eventEmitter = new _reactNative.NativeEventEmitter();
|
|
10
10
|
const events = (type, customEtName) => {
|
|
11
11
|
return `${_constants.BaseEvents[type]}:${customEtName}`;
|
|
12
12
|
};
|
|
13
|
-
const dispatchStartEvent = (customEtName, data) => {
|
|
14
|
-
dispatchEvent('START', customEtName, data);
|
|
15
|
-
};
|
|
16
|
-
exports.dispatchStartEvent = dispatchStartEvent;
|
|
17
13
|
const dispatchEvent = (type, customEtName, data) => {
|
|
18
14
|
/* Logger.getInstance().logEvent(
|
|
19
15
|
'eventOutputData: ',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_reactNative","require","_constants","eventEmitter","NativeEventEmitter","events","type","customEtName","BaseEvents","
|
|
1
|
+
{"version":3,"names":["_reactNative","require","_constants","eventEmitter","NativeEventEmitter","events","type","customEtName","BaseEvents","dispatchEvent","data","emit","_default","exports","default"],"sources":["EventDispatcher.ts"],"sourcesContent":["import { NativeEventEmitter } from 'react-native';\nimport { BaseEvents } from './constants';\nimport type { eventType } from './interface';\nimport Logger, { LOG_TYPE } from '../utils/Logger';\n\nconst eventEmitter = new NativeEventEmitter();\n\nconst events = (type: eventType, customEtName: string) => {\n return `${BaseEvents[type]}:${customEtName}`;\n};\n\nconst dispatchEvent = (type: eventType, customEtName: string, data: any) => {\n /* Logger.getInstance().logEvent(\n 'eventOutputData: ',\n JSON.stringify({ type, customEtName, data }),\n LOG_TYPE.SDK_INFO\n ); */\n eventEmitter.emit(events(type, customEtName), data);\n};\n\nexport default dispatchEvent;\n"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AACA,IAAAC,UAAA,GAAAD,OAAA;AAIA,MAAME,YAAY,GAAG,IAAIC,+BAAkB,CAAC,CAAC;AAE7C,MAAMC,MAAM,GAAGA,CAACC,IAAe,EAAEC,YAAoB,KAAK;EACxD,OAAQ,GAAEC,qBAAU,CAACF,IAAI,CAAE,IAAGC,YAAa,EAAC;AAC9C,CAAC;AAED,MAAME,aAAa,GAAGA,CAACH,IAAe,EAAEC,YAAoB,EAAEG,IAAS,KAAK;EAC1E;AACF;AACA;AACA;AACA;EACEP,YAAY,CAACQ,IAAI,CAACN,MAAM,CAACC,IAAI,EAAEC,YAAY,CAAC,EAAEG,IAAI,CAAC;AACrD,CAAC;AAAC,IAAAE,QAAA,GAEaH,aAAa;AAAAI,OAAA,CAAAC,OAAA,GAAAF,QAAA"}
|
|
@@ -7,7 +7,9 @@ exports.BaseEvents = void 0;
|
|
|
7
7
|
const BaseEvents = {
|
|
8
8
|
START: `onTaskStart`,
|
|
9
9
|
END: `onTaskEnd`,
|
|
10
|
-
BACK: `onTaskBack
|
|
10
|
+
BACK: `onTaskBack`,
|
|
11
|
+
ON_SCAN: `onScan`,
|
|
12
|
+
ON_SCAN_REMOVE: `onScanRemove`
|
|
11
13
|
};
|
|
12
14
|
exports.BaseEvents = BaseEvents;
|
|
13
15
|
//# sourceMappingURL=constants.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["BaseEvents","START","END","BACK","exports"],"sources":["constants.ts"],"sourcesContent":["export const BaseEvents = {\n START: `onTaskStart`,\n END: `onTaskEnd`,\n BACK: `onTaskBack`,\n};\n"],"mappings":";;;;;;AAAO,MAAMA,UAAU,GAAG;EACxBC,KAAK,EAAG,aAAY;EACpBC,GAAG,EAAG,WAAU;EAChBC,IAAI,EAAG;
|
|
1
|
+
{"version":3,"names":["BaseEvents","START","END","BACK","ON_SCAN","ON_SCAN_REMOVE","exports"],"sources":["constants.ts"],"sourcesContent":["export const BaseEvents = {\n START: `onTaskStart`,\n END: `onTaskEnd`,\n BACK: `onTaskBack`,\n ON_SCAN: `onScan`,\n ON_SCAN_REMOVE: `onScanRemove`,\n};\n"],"mappings":";;;;;;AAAO,MAAMA,UAAU,GAAG;EACxBC,KAAK,EAAG,aAAY;EACpBC,GAAG,EAAG,WAAU;EAChBC,IAAI,EAAG,YAAW;EAClBC,OAAO,EAAG,QAAO;EACjBC,cAAc,EAAG;AACnB,CAAC;AAACC,OAAA,CAAAN,UAAA,GAAAA,UAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":[],"sources":["interface.ts"],"sourcesContent":["export type eventType = 'START' | 'END' | 'BACK';\n"],"mappings":""}
|
|
1
|
+
{"version":3,"names":[],"sources":["interface.ts"],"sourcesContent":["export type eventType = 'START' | 'END' | 'BACK' | 'ON_SCAN' | 'ON_SCAN_REMOVE';\n"],"mappings":""}
|
package/lib/commonjs/index.js
CHANGED
|
@@ -9,6 +9,12 @@ Object.defineProperty(exports, "AppSyncManager", {
|
|
|
9
9
|
return _AppSyncManager.default;
|
|
10
10
|
}
|
|
11
11
|
});
|
|
12
|
+
Object.defineProperty(exports, "BaseEvents", {
|
|
13
|
+
enumerable: true,
|
|
14
|
+
get: function () {
|
|
15
|
+
return _constants.BaseEvents;
|
|
16
|
+
}
|
|
17
|
+
});
|
|
12
18
|
Object.defineProperty(exports, "CancelOrderDialog", {
|
|
13
19
|
enumerable: true,
|
|
14
20
|
get: function () {
|
|
@@ -21,6 +27,12 @@ Object.defineProperty(exports, "DispatchExecNavigator", {
|
|
|
21
27
|
return _DispatchExecNavigator.default;
|
|
22
28
|
}
|
|
23
29
|
});
|
|
30
|
+
Object.defineProperty(exports, "DispatchExecutor", {
|
|
31
|
+
enumerable: true,
|
|
32
|
+
get: function () {
|
|
33
|
+
return _platformCoreosExecutionEngineSdk.DispatchExecutor;
|
|
34
|
+
}
|
|
35
|
+
});
|
|
24
36
|
Object.defineProperty(exports, "DispatchSDKManager", {
|
|
25
37
|
enumerable: true,
|
|
26
38
|
get: function () {
|
|
@@ -33,6 +45,12 @@ Object.defineProperty(exports, "DispatchStateContainer", {
|
|
|
33
45
|
return _DispatchStateContainer.default;
|
|
34
46
|
}
|
|
35
47
|
});
|
|
48
|
+
Object.defineProperty(exports, "DispatchSyncType", {
|
|
49
|
+
enumerable: true,
|
|
50
|
+
get: function () {
|
|
51
|
+
return _DBConfig.DispatchSyncType;
|
|
52
|
+
}
|
|
53
|
+
});
|
|
36
54
|
Object.defineProperty(exports, "EventListener", {
|
|
37
55
|
enumerable: true,
|
|
38
56
|
get: function () {
|
|
@@ -46,6 +64,18 @@ Object.defineProperty(exports, "FCM", {
|
|
|
46
64
|
return _FCM.default;
|
|
47
65
|
}
|
|
48
66
|
});
|
|
67
|
+
Object.defineProperty(exports, "IDispatch", {
|
|
68
|
+
enumerable: true,
|
|
69
|
+
get: function () {
|
|
70
|
+
return _platformCoreosExecutionEngineSdk.IDispatch;
|
|
71
|
+
}
|
|
72
|
+
});
|
|
73
|
+
Object.defineProperty(exports, "IDispatchExecutor", {
|
|
74
|
+
enumerable: true,
|
|
75
|
+
get: function () {
|
|
76
|
+
return _platformCoreosExecutionEngineSdk.IDispatchExecutor;
|
|
77
|
+
}
|
|
78
|
+
});
|
|
49
79
|
Object.defineProperty(exports, "LOG_TYPE", {
|
|
50
80
|
enumerable: true,
|
|
51
81
|
get: function () {
|
|
@@ -65,12 +95,6 @@ Object.defineProperty(exports, "NativeSyncManager", {
|
|
|
65
95
|
return _NativeSyncManager.default;
|
|
66
96
|
}
|
|
67
97
|
});
|
|
68
|
-
Object.defineProperty(exports, "ObjectiveNotFoundError", {
|
|
69
|
-
enumerable: true,
|
|
70
|
-
get: function () {
|
|
71
|
-
return _mobileExecutionLib.ObjectiveNotFoundError;
|
|
72
|
-
}
|
|
73
|
-
});
|
|
74
98
|
Object.defineProperty(exports, "SdkSyncType", {
|
|
75
99
|
enumerable: true,
|
|
76
100
|
get: function () {
|
|
@@ -101,12 +125,6 @@ Object.defineProperty(exports, "getFCMToken", {
|
|
|
101
125
|
return _FcmUtils.getFCMToken;
|
|
102
126
|
}
|
|
103
127
|
});
|
|
104
|
-
Object.defineProperty(exports, "objectiveExecutionStatus", {
|
|
105
|
-
enumerable: true,
|
|
106
|
-
get: function () {
|
|
107
|
-
return _mobileExecutionLib.objectiveExecutionStatus;
|
|
108
|
-
}
|
|
109
|
-
});
|
|
110
128
|
Object.defineProperty(exports, "registerBackgroundHandler", {
|
|
111
129
|
enumerable: true,
|
|
112
130
|
get: function () {
|
|
@@ -137,13 +155,14 @@ var _FcmUtils = _interopRequireWildcard(require("./utils/fcm/FcmUtils"));
|
|
|
137
155
|
var _FCM = _interopRequireDefault(require("./utils/fcm/FCM"));
|
|
138
156
|
var _DispatchExecNavigator = _interopRequireDefault(require("./components/dispatch/DispatchExecNavigator"));
|
|
139
157
|
var _DispatchStateContainer = _interopRequireDefault(require("./manager/dispatch/DispatchStateContainer"));
|
|
140
|
-
var _mobileExecutionLib = require("@os1-platform/mobile-execution-lib");
|
|
141
158
|
var _DispatchSDKManager = require("./manager/sdk/DispatchSDKManager");
|
|
142
159
|
var _Logger = _interopRequireWildcard(require("./utils/Logger"));
|
|
143
160
|
var _SdkUtils = _interopRequireDefault(require("./utils/SdkUtils"));
|
|
144
161
|
var _AppSyncManager = _interopRequireDefault(require("./manager/syncmanager/AppSyncManager"));
|
|
145
162
|
var _DispatchModels = require("./models/DispatchModels");
|
|
146
163
|
var _events = _interopRequireDefault(require("./events"));
|
|
164
|
+
var _constants = require("./events/constants");
|
|
165
|
+
var _platformCoreosExecutionEngineSdk = require("@os1-platform/platform-coreos-execution-engine-sdk");
|
|
147
166
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
148
167
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
149
168
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_storage","_interopRequireDefault","require","ExecutionTask","_interopRequireWildcard","exports","MtsSdk","_NativeSyncManager","_DBConfig","_CancelOrderDialog","_FcmUtils","_FCM","_DispatchExecNavigator","_DispatchStateContainer","
|
|
1
|
+
{"version":3,"names":["_storage","_interopRequireDefault","require","ExecutionTask","_interopRequireWildcard","exports","MtsSdk","_NativeSyncManager","_DBConfig","_CancelOrderDialog","_FcmUtils","_FCM","_DispatchExecNavigator","_DispatchStateContainer","_DispatchSDKManager","_Logger","_SdkUtils","_AppSyncManager","_DispatchModels","_events","_constants","_platformCoreosExecutionEngineSdk","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","obj","__esModule","default","cache","has","get","newObj","hasPropertyDescriptor","Object","defineProperty","getOwnPropertyDescriptor","key","prototype","hasOwnProperty","call","desc","set"],"sources":["index.tsx"],"sourcesContent":["import Storage from './utils/storage';\nimport type * as ETaskSchema from './components/executiontasks/ExecutionTasksIndex';\nimport * as ExecutionTask from './components/executiontasks/ExecutionTasksIndex';\nimport type {\n MTSInitRequest,\n MTSStartRequest,\n} from '@foxtrotplatform/platform-coreos-mts-sdk';\nimport * as MtsSdk from '@foxtrotplatform/platform-coreos-mts-sdk';\nimport NativeSyncManager from './manager/syncmanager/NativeSyncManager';\nimport type { DocumentRow, EventRow } from './manager/syncmanager/DBConfig';\nimport { SyncMethod, DispatchSyncType } from './manager/syncmanager/DBConfig';\nimport CancelOrderDialog from './components/widgets/CancelOrderDialog';\nimport useFCMMessage, {\n getFCMToken,\n registerBackgroundHandler,\n requestFirebasePermissions,\n} from './utils/fcm/FcmUtils';\nimport FCM from './utils/fcm/FCM';\nimport DispatchExecNavigator from './components/dispatch/DispatchExecNavigator';\nimport DispatchStateContainer from './manager/dispatch/DispatchStateContainer';\nimport { DispatchSDKManager } from './manager/sdk/DispatchSDKManager';\nimport Logger, { LOG_TYPE } from './utils/Logger';\nimport type {\n ETSummary,\n CompleteSummary,\n ObjectiveSummary,\n} from './models/execTasks/ETBaseModels';\nimport SdkUtils from './utils/SdkUtils';\nimport AppSyncManager from './manager/syncmanager/AppSyncManager';\nimport type {\n JobObjectiveType,\n endEvent,\n startEvent,\n onScanRemoveEvent,\n onScanEvent,\n} from './models/DispatchModels';\nimport { SdkSyncType } from './models/DispatchModels';\nimport EventListener from './events';\nimport { BaseEvents } from './events/constants';\nimport {\n DispatchExecutor,\n IDispatch,\n IDispatchExecutor,\n} from '@os1-platform/platform-coreos-execution-engine-sdk';\n\nexport { DispatchExecutor, IDispatch, IDispatchExecutor };\nexport { Storage, DispatchExecNavigator };\nexport { ETSummary, CompleteSummary, ObjectiveSummary, DispatchSyncType };\nexport { BaseEvents, endEvent, startEvent, onScanRemoveEvent, onScanEvent };\nexport {\n NativeSyncManager,\n AppSyncManager,\n SdkSyncType,\n EventRow,\n DocumentRow,\n useFCMMessage,\n getFCMToken,\n requestFirebasePermissions,\n FCM,\n registerBackgroundHandler,\n DispatchStateContainer,\n SdkUtils,\n Logger,\n LOG_TYPE,\n EventListener,\n};\n\nexport { SyncMethod, JobObjectiveType };\nexport type { ETaskSchema };\nexport { ExecutionTask, CancelOrderDialog };\nexport { DispatchSDKManager };\n\nexport type { MTSStartRequest, MTSInitRequest };\nexport { MtsSdk };\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,QAAA,GAAAC,sBAAA,CAAAC,OAAA;AAEA,IAAAC,aAAA,GAAAC,uBAAA,CAAAF,OAAA;AAAiFG,OAAA,CAAAF,aAAA,GAAAA,aAAA;AAKjF,IAAAG,MAAA,GAAAF,uBAAA,CAAAF,OAAA;AAAmEG,OAAA,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