@scandit/web-datacapture-core 8.3.1 → 8.4.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/electron/common.cjs +1 -1
- package/build/electron/constants.cjs +1 -1
- package/build/electron/main.cjs +1 -1
- package/build/electron/preload.cjs +1 -1
- package/build/js/{Camera-Cc__1Nc-.d.ts → Camera-HgH6fwnW.d.ts} +16 -2
- package/build/js/Camera.d.ts +1 -1
- package/build/js/Camera.js +1 -1
- package/build/js/CameraRelated.d.ts +1 -1
- package/build/js/CameraRelated.js +1 -1
- package/build/js/{DataCaptureContext-BcSpF9Dt.d.ts → DataCaptureContext-qacCkSOl.d.ts} +40 -21
- package/build/js/DataCaptureContext.d.ts +4 -4
- package/build/js/DataCaptureContext.js +1 -1
- package/build/js/DataCaptureContextRelated.d.ts +3 -3
- package/build/js/DataCaptureVersion.js +1 -1
- package/build/js/DataCaptureView.d.ts +3 -3
- package/build/js/DataCaptureView.js +1 -1
- package/build/js/DataCaptureViewPlusRelated-BOrDBPHq.d.ts +49 -0
- package/build/js/DataCaptureViewPlusRelated.d.ts +2 -24
- package/build/js/DataCaptureViewPlusRelated.js +1 -1
- package/build/js/Feedback.js +1 -1
- package/build/js/FrameData.d.ts +3 -3
- package/build/js/ImageFrameSource.d.ts +1 -1
- package/build/js/ImageFrameSource.js +1 -1
- package/build/js/NotificationPresenter/index.d.ts +3 -3
- package/build/js/NotificationPresenter/index.js +1 -1
- package/build/js/NotificationPresenter/private/ConcreteNotificationPresenter.d.ts +3 -3
- package/build/js/NotificationPresenter/private/presets.d.ts +3 -3
- package/build/js/ScanditIcon.js +1 -1
- package/build/js/ScanditIconBuilder.js +1 -1
- package/build/js/SingleImageUploader.d.ts +1 -1
- package/build/js/SingleImageUploader.js +1 -1
- package/build/js/Sound.js +1 -1
- package/build/js/ZoomGestureListener.d.ts +3 -0
- package/build/js/ZoomListener.d.ts +7 -0
- package/build/js/ZoomSwitchOrientation.d.ts +8 -0
- package/build/js/ZoomSwitchOrientation.js +1 -0
- package/build/js/chunks/{chunk-U2VELHGX.js → chunk-2UHUEJA4.js} +1 -1
- package/build/js/chunks/{chunk-6IM6NGGI.js → chunk-3MKSI2DV.js} +1 -1
- package/build/js/chunks/{chunk-TNIR74NN.js → chunk-4F2Q2P2O.js} +1 -1
- package/build/js/chunks/chunk-4KLHTKGW.js +1 -0
- package/build/js/chunks/chunk-4LGQ66HW.js +1 -0
- package/build/js/chunks/chunk-4QJAB4PO.js +1 -0
- package/build/js/chunks/chunk-4WA2PCJE.js +1 -0
- package/build/js/chunks/chunk-56OQ5EHO.js +1 -0
- package/build/js/chunks/{chunk-HILZP6OW.js → chunk-6AZW5IIG.js} +1 -1
- package/build/js/chunks/{chunk-YP53ND2Q.js → chunk-6EEMWSEO.js} +1 -1
- package/build/js/chunks/{chunk-Z6CZGU5N.js → chunk-76IGNICM.js} +1 -1
- package/build/js/chunks/{chunk-A3ZT7PJA.js → chunk-7HYFN4JO.js} +1 -1
- package/build/js/chunks/chunk-7LTHFX4E.js +1 -0
- package/build/js/chunks/{chunk-SX5ZLP2O.js → chunk-7OFC24NE.js} +1 -1
- package/build/js/chunks/chunk-7SA74NKD.js +0 -0
- package/build/js/chunks/{chunk-YRQQE3NR.js → chunk-AC4QOIY7.js} +1 -1
- package/build/js/chunks/{chunk-XDTXM6UX.js → chunk-ACCTMSWC.js} +1 -1
- package/build/js/chunks/{chunk-5VJXJTUX.js → chunk-AD77NFCP.js} +1 -1
- package/build/js/chunks/chunk-AE2LWVIB.js +1 -0
- package/build/js/chunks/chunk-CA6FHIF6.js +35 -0
- package/build/js/chunks/{chunk-MBF27IWL.js → chunk-CERFU73N.js} +1 -1
- package/build/js/chunks/{chunk-FK5L5YTR.js → chunk-CGK5V6XZ.js} +1 -1
- package/build/js/chunks/chunk-D222MT4V.js +1 -0
- package/build/js/chunks/{chunk-ARODHCN7.js → chunk-DGIQ3GF7.js} +1 -1
- package/build/js/chunks/chunk-FHUC75ND.js +1 -0
- package/build/js/chunks/chunk-GMOTHEWV.js +1 -0
- package/build/js/chunks/chunk-GVHXM75D.js +1 -0
- package/build/js/chunks/chunk-H3J4TP2K.js +1 -0
- package/build/js/chunks/{chunk-GZCWMFWA.js → chunk-JLTSTUKY.js} +1 -1
- package/build/js/chunks/chunk-LPFXHHWJ.js +1 -0
- package/build/js/chunks/chunk-MA3GV76P.js +1 -0
- package/build/js/chunks/chunk-NIKRAADM.js +1 -0
- package/build/js/chunks/{chunk-FMOB7R2T.js → chunk-O4HDBWKK.js} +1 -1
- package/build/js/chunks/{chunk-33ZWDLU7.js → chunk-O7EM4VIM.js} +1 -1
- package/build/js/chunks/chunk-OLUNDJBC.js +1 -0
- package/build/js/chunks/{chunk-PM5CNTBV.js → chunk-OX64CCOP.js} +1 -1
- package/build/js/chunks/chunk-P2R7FW6C.js +1 -0
- package/build/js/chunks/chunk-P3NPNIWR.js +1 -0
- package/build/js/chunks/{chunk-2SGKGZ6F.js → chunk-QFSNPY5Y.js} +1 -1
- package/build/js/chunks/{chunk-BSX3V75N.js → chunk-QUWP3ILW.js} +1 -1
- package/build/js/chunks/chunk-RZTXUIJ5.js +0 -0
- package/build/js/chunks/chunk-SHM7SU3B.js +1 -0
- package/build/js/chunks/chunk-U2WQ3WDE.js +1 -0
- package/build/js/chunks/chunk-U4IMOTYL.js +1 -0
- package/build/js/chunks/{chunk-PDJEYYPX.js → chunk-U6MFAGMG.js} +1 -1
- package/build/js/chunks/{chunk-GS7VZDY5.js → chunk-U7ETOWGJ.js} +1 -1
- package/build/js/chunks/chunk-UNO6YIIA.js +1 -0
- package/build/js/chunks/{chunk-UJYGOVXB.js → chunk-V2OKMBZD.js} +1 -1
- package/build/js/chunks/{chunk-FCXZZH3O.js → chunk-VSROWPI6.js} +1 -1
- package/build/js/chunks/{chunk-ZCEA7BEH.js → chunk-WHRRC6V6.js} +1 -1
- package/build/js/chunks/{chunk-DTREAYZQ.js → chunk-WOOPJWJS.js} +1 -1
- package/build/js/chunks/chunk-XUIVDVLK.js +6 -0
- package/build/js/chunks/{chunk-NMXQDQYI.js → chunk-YE2GYNRP.js} +1 -1
- package/build/js/chunks/{chunk-XV75QMNK.js → chunk-ZP3YIZEC.js} +1 -1
- package/build/js/chunks/{chunk-35JLCTLQ.js → chunk-ZTKCGHYQ.js} +1 -1
- package/build/js/controls/CameraFOVSwitchControl.d.ts +6 -3
- package/build/js/controls/CameraFOVSwitchControl.js +1 -1
- package/build/js/controls/CameraSwitchControl.d.ts +3 -3
- package/build/js/controls/CameraSwitchControl.js +1 -1
- package/build/js/controls/TorchSwitchControl.d.ts +3 -3
- package/build/js/controls/TorchSwitchControl.js +1 -1
- package/build/js/controls/ZoomSwitchControl.d.ts +97 -0
- package/build/js/controls/ZoomSwitchControl.js +1 -0
- package/build/js/controls/common.d.ts +3 -3
- package/build/js/controls/index.d.ts +5 -3
- package/build/js/controls/index.js +1 -1
- package/build/js/defaults/DefaultsCamera.d.ts +4 -3
- package/build/js/defaults/DefaultsCamera.js +1 -1
- package/build/js/defaults/DefaultsCameraSettings.d.ts +2 -1
- package/build/js/defaults/DefaultsCameraSettings.js +1 -1
- package/build/js/defaults/DefaultsDataCaptureView.d.ts +2 -2
- package/build/js/defaults/DefaultsDataCaptureView.js +1 -1
- package/build/js/defaults/DefaultsDeserializers.d.ts +1 -1
- package/build/js/defaults/DefaultsDeserializers.js +1 -1
- package/build/js/index.d.ts +6 -4
- package/build/js/index.js +1 -1
- package/build/js/moduleLoader.d.ts +3 -3
- package/build/js/private/CameraAccess.d.ts +1 -1
- package/build/js/private/CameraManager.d.ts +3 -3
- package/build/js/private/CameraManager.js +1 -1
- package/build/js/private/CameraPool.d.ts +56 -22
- package/build/js/private/CameraPool.js +1 -1
- package/build/js/private/CanvasDrawerWithMetrics.d.ts +3 -3
- package/build/js/private/CoreModuleLicenseTextProvider.d.ts +3 -3
- package/build/js/private/CoreModuleLicenseTextProvider.js +1 -1
- package/build/js/private/CustomLocationsView.js +1 -1
- package/build/js/private/DataCaptureContextRelated.d.ts +3 -3
- package/build/js/private/FrameReaders/FrameReader.d.ts +3 -3
- package/build/js/private/FrameReaders/FrameReader.js +1 -1
- package/build/js/private/FrameReaders/FrameReaderAbstract.d.ts +3 -3
- package/build/js/private/FrameReaders/GrayScaleFrameReader.d.ts +3 -3
- package/build/js/private/FrameReaders/GrayScaleFrameReader.js +1 -1
- package/build/js/private/FrameReaders/index.d.ts +3 -3
- package/build/js/private/FrameReaders/index.js +1 -1
- package/build/js/private/GestureRecognizer/GestureRecognizer.d.ts +34 -0
- package/build/js/private/GestureRecognizer/GestureRecognizer.js +1 -1
- package/build/js/private/GestureRecognizer/PointerEventsDetector.js +1 -1
- package/build/js/private/GestureRecognizer/index.d.ts +1 -1
- package/build/js/private/GestureRecognizer/index.js +1 -1
- package/build/js/private/NormalizedModuleLoaderOptions.d.ts +3 -3
- package/build/js/private/SingleImageUploaderView.d.ts +3 -3
- package/build/js/private/SingleImageUploaderView.js +1 -1
- package/build/js/private/ViewControls+related.js +1 -1
- package/build/js/private/ViewControls_related.d.ts +3 -3
- package/build/js/private/ViewStyles.js +1 -1
- package/build/js/private/ViewsRegistry.d.ts +3 -3
- package/build/js/private/customHowler/Howl.js +1 -1
- package/build/js/private/customHowler/index.js +1 -1
- package/build/js/private/customHowler/setup.js +1 -1
- package/build/js/private/ui/atoms/AimerSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/ArrowDownSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/ArrowLeftSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/ArrowRightSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/ArrowUpSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/ArrowsUp.js +1 -1
- package/build/js/private/ui/atoms/Backdrop.js +1 -1
- package/build/js/private/ui/atoms/CalendarExclamationMarkSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/CameraFOVUltrawideSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/CameraFOVWideSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/CameraSwitchReverseSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/CameraSwitchSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/Card.js +1 -1
- package/build/js/private/ui/atoms/CardList.js +1 -1
- package/build/js/private/ui/atoms/CheckSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/ChevronDownSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/ChevronLeftSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/ChevronRightSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/ChevronUpSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/CrossSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/DeleteSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/Dot5xSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/ExclamationMarkSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/GlassSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/HandLensCheckSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/KeyboardSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/LowStockSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/OnexSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/PauseSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/PrinterSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/ProgressBar.js +1 -1
- package/build/js/private/ui/atoms/QuestionMarkSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/RestartSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/RoundedCheckSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/RoundedCrossSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/RoundedExclamationMarkSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/ScanSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/ShutterButton.js +1 -1
- package/build/js/private/ui/atoms/SlashSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/StarFilledSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/StarHalfFilledSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/StarOutlinedSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/SvgIcon.js +1 -1
- package/build/js/private/ui/atoms/ToPickSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/Toast.d.ts +3 -3
- package/build/js/private/ui/atoms/Toast.js +1 -1
- package/build/js/private/ui/atoms/TorchOffSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/TorchOnSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/TwoxSvgIcon.js +1 -1
- package/build/js/private/ui/atoms/WrongItemSvgIcon.js +1 -1
- package/build/js/private/ui/molecules/ButtonEvents.d.ts +8 -1
- package/build/js/private/ui/molecules/ButtonEvents.js +1 -1
- package/build/js/private/ui/molecules/CameraFOVSwitchButton.d.ts +0 -1
- package/build/js/private/ui/molecules/CameraFOVSwitchButton.js +1 -1
- package/build/js/private/ui/molecules/CameraSwitchButton.d.ts +0 -1
- package/build/js/private/ui/molecules/CameraSwitchButton.js +1 -1
- package/build/js/private/ui/molecules/ControlsLayout.js +1 -1
- package/build/js/private/ui/molecules/HintPresenter.d.ts +3 -3
- package/build/js/private/ui/molecules/HintPresenter.js +1 -1
- package/build/js/private/ui/molecules/LoadingOverlay.js +1 -1
- package/build/js/private/ui/molecules/TorchSwitchIconButton.d.ts +1 -2
- package/build/js/private/ui/molecules/TorchSwitchIconButton.js +1 -1
- package/build/js/private/ui/molecules/ZoomSwitchPill.d.ts +70 -0
- package/build/js/private/ui/molecules/ZoomSwitchPill.js +1 -0
- package/build/js/private/utils/AnimationSimplePolyfill.js +1 -1
- package/build/js/private/utils/areEqualArrays.d.ts +4 -0
- package/build/js/private/utils/areEqualArrays.js +1 -0
- package/build/js/private/utils/index.d.ts +1 -0
- package/build/js/private/utils/index.js +1 -1
- package/build/js/private/utils/isPointerTouchEvent.d.ts +4 -0
- package/build/js/private/utils/isPointerTouchEvent.js +1 -0
- package/build/js/private/utils/polyfillLoader.js +1 -1
- package/build/js/private/utils/replaceImagesInViewUtils.d.ts +3 -3
- package/build/js/worker/ImageConverterForwarder.d.ts +3 -3
- package/build/js/worker/ViewInfoHelper.d.ts +3 -3
- package/build/js/worker/WorkerMain.d.ts +3 -3
- package/build/js/worker/WorkerMain.js +1 -1
- package/build/js/worker/coreCapture.inlineWorker.d.ts +3 -3
- package/build/js/worker/coreCapture.inlineWorker.js +1 -1
- package/build/js/worker/dataCaptureEngine.d.ts +3 -3
- package/build/js/worker/dataCaptureEngine.js +1 -1
- package/build/js/worker/dataCaptureLoader.d.ts +3 -3
- package/build/js/worker/dataCaptureWorkerRelated.d.ts +3 -3
- package/build/js/worker/helperFs.d.ts +3 -5
- package/build/js/worker/helperFs.js +1 -1
- package/build/js/worker/index.d.ts +3 -3
- package/build/js/worker/index.js +1 -1
- package/package.json +1 -1
- package/build/js/chunks/chunk-2AX7TBDI.js +0 -1
- package/build/js/chunks/chunk-2N546PXQ.js +0 -1
- package/build/js/chunks/chunk-3D2HNEVH.js +0 -1
- package/build/js/chunks/chunk-3JLTBSEJ.js +0 -1
- package/build/js/chunks/chunk-5DKZR6UB.js +0 -1
- package/build/js/chunks/chunk-6LHGFWQI.js +0 -1
- package/build/js/chunks/chunk-74GO72VC.js +0 -1
- package/build/js/chunks/chunk-A5G2NHT2.js +0 -1
- package/build/js/chunks/chunk-ATSAENLJ.js +0 -6
- package/build/js/chunks/chunk-DZKTI5AJ.js +0 -1
- package/build/js/chunks/chunk-EQP4U5U2.js +0 -1
- package/build/js/chunks/chunk-GX4YCYCH.js +0 -1
- package/build/js/chunks/chunk-INVYPEGF.js +0 -1
- package/build/js/chunks/chunk-KYAHE2Q3.js +0 -1
- package/build/js/chunks/chunk-QHBYNYWX.js +0 -1
- package/build/js/chunks/chunk-SSTFVERQ.js +0 -1
- package/build/js/chunks/chunk-U6MNF7M6.js +0 -35
- package/build/js/chunks/chunk-UQVVJP5Z.js +0 -1
- package/build/js/chunks/chunk-WJOT37ST.js +0 -1
- package/build/js/chunks/chunk-XIAF6V7E.js +0 -1
- /package/build/js/{chunks/chunk-BUKZPAC5.js → ZoomGestureListener.js} +0 -0
- /package/build/js/{chunks/chunk-VFOSFLTM.js → ZoomListener.js} +0 -0
- /package/build/js/chunks/{chunk-O5D4KVS5.js → chunk-Y7BTRVB4.js} +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{a as isPointerTouchEvent}from'../../chunks/chunk-FHUC75ND.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{a as loadPolyfills}from'../../chunks/chunk-
|
|
1
|
+
export{a as loadPolyfills}from'../../chunks/chunk-Y7BTRVB4.js';
|
|
@@ -2,17 +2,17 @@
|
|
|
2
2
|
import { Size } from '../../commons/Size.js';
|
|
3
3
|
import { Optional } from '../../tsHelper.js';
|
|
4
4
|
import '../../ScanditIcon.js';
|
|
5
|
-
import '../../DataCaptureContext-
|
|
5
|
+
import '../../DataCaptureContext-qacCkSOl.js';
|
|
6
6
|
import '../Serializable.js';
|
|
7
7
|
import '../../commons/Color.js';
|
|
8
8
|
import './ScanditHTMLElement.js';
|
|
9
|
-
import '../../Camera-
|
|
9
|
+
import '../../Camera-HgH6fwnW.js';
|
|
10
10
|
import '../../commons/Rect.js';
|
|
11
11
|
import '../../commons/Point.js';
|
|
12
12
|
import '../privateAccess.js';
|
|
13
13
|
import '../../DataCaptureContextSettings.js';
|
|
14
14
|
import '../../commons/JSONType.js';
|
|
15
|
-
import '../../DataCaptureViewPlusRelated.js';
|
|
15
|
+
import '../../DataCaptureViewPlusRelated-BOrDBPHq.js';
|
|
16
16
|
import '../../NotificationPresenter/NotificationPresenter.js';
|
|
17
17
|
import '../../NotificationPresenter/NotificationConfiguration.js';
|
|
18
18
|
import '../../NotificationPresenter/NotificationStyle.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/// <reference types="emscripten" />
|
|
2
2
|
import { ImageConverterInstance, ImageBuffer, BitmapWithFormat } from '../private/djinni-types/index.js';
|
|
3
|
-
import { W as WorkerFunctions } from '../DataCaptureContext-
|
|
4
|
-
import '../Camera-
|
|
3
|
+
import { W as WorkerFunctions } from '../DataCaptureContext-qacCkSOl.js';
|
|
4
|
+
import '../Camera-HgH6fwnW.js';
|
|
5
5
|
import '../commons/Rect.js';
|
|
6
6
|
import '../private/Serializable.js';
|
|
7
7
|
import '../commons/Point.js';
|
|
@@ -9,7 +9,7 @@ import '../commons/Size.js';
|
|
|
9
9
|
import '../private/privateAccess.js';
|
|
10
10
|
import '../DataCaptureContextSettings.js';
|
|
11
11
|
import '../commons/JSONType.js';
|
|
12
|
-
import '../DataCaptureViewPlusRelated.js';
|
|
12
|
+
import '../DataCaptureViewPlusRelated-BOrDBPHq.js';
|
|
13
13
|
import '../NotificationPresenter/NotificationPresenter.js';
|
|
14
14
|
import '../NotificationPresenter/NotificationConfiguration.js';
|
|
15
15
|
import '../commons/Color.js';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="emscripten" />
|
|
2
|
-
import { V as ViewInfo } from '../DataCaptureContext-
|
|
3
|
-
import '../Camera-
|
|
2
|
+
import { V as ViewInfo } from '../DataCaptureContext-qacCkSOl.js';
|
|
3
|
+
import '../Camera-HgH6fwnW.js';
|
|
4
4
|
import '../commons/Rect.js';
|
|
5
5
|
import '../private/Serializable.js';
|
|
6
6
|
import '../commons/Point.js';
|
|
@@ -8,7 +8,7 @@ import '../commons/Size.js';
|
|
|
8
8
|
import '../private/privateAccess.js';
|
|
9
9
|
import '../DataCaptureContextSettings.js';
|
|
10
10
|
import '../commons/JSONType.js';
|
|
11
|
-
import '../DataCaptureViewPlusRelated.js';
|
|
11
|
+
import '../DataCaptureViewPlusRelated-BOrDBPHq.js';
|
|
12
12
|
import '../NotificationPresenter/NotificationPresenter.js';
|
|
13
13
|
import '../NotificationPresenter/NotificationConfiguration.js';
|
|
14
14
|
import '../commons/Color.js';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="emscripten" />
|
|
2
|
-
import { K as DataCaptureEngine, L as Module, Q as AnyDataCaptureActionMessage, R as AugmentedWorker, S as ModuleHandler, T as DataCaptureCallbackMessage, U as DataCaptureActionMessageKey, X as EngineWorkerResponse } from '../DataCaptureContext-
|
|
3
|
-
import '../Camera-
|
|
2
|
+
import { K as DataCaptureEngine, L as Module, Q as AnyDataCaptureActionMessage, R as AugmentedWorker, S as ModuleHandler, T as DataCaptureCallbackMessage, U as DataCaptureActionMessageKey, X as EngineWorkerResponse } from '../DataCaptureContext-qacCkSOl.js';
|
|
3
|
+
import '../Camera-HgH6fwnW.js';
|
|
4
4
|
import '../commons/Rect.js';
|
|
5
5
|
import '../private/Serializable.js';
|
|
6
6
|
import '../commons/Point.js';
|
|
@@ -8,7 +8,7 @@ import '../commons/Size.js';
|
|
|
8
8
|
import '../private/privateAccess.js';
|
|
9
9
|
import '../DataCaptureContextSettings.js';
|
|
10
10
|
import '../commons/JSONType.js';
|
|
11
|
-
import '../DataCaptureViewPlusRelated.js';
|
|
11
|
+
import '../DataCaptureViewPlusRelated-BOrDBPHq.js';
|
|
12
12
|
import '../NotificationPresenter/NotificationPresenter.js';
|
|
13
13
|
import '../NotificationPresenter/NotificationConfiguration.js';
|
|
14
14
|
import '../commons/Color.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{a as WorkerMain}from'../chunks/chunk-
|
|
1
|
+
export{a as WorkerMain}from'../chunks/chunk-JLTSTUKY.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/// <reference types="emscripten" />
|
|
2
|
-
import { K as DataCaptureEngine, L as Module } from '../DataCaptureContext-
|
|
2
|
+
import { K as DataCaptureEngine, L as Module } from '../DataCaptureContext-qacCkSOl.js';
|
|
3
3
|
import { WorkerMain } from './WorkerMain.js';
|
|
4
|
-
import '../Camera-
|
|
4
|
+
import '../Camera-HgH6fwnW.js';
|
|
5
5
|
import '../commons/Rect.js';
|
|
6
6
|
import '../private/Serializable.js';
|
|
7
7
|
import '../commons/Point.js';
|
|
@@ -9,7 +9,7 @@ import '../commons/Size.js';
|
|
|
9
9
|
import '../private/privateAccess.js';
|
|
10
10
|
import '../DataCaptureContextSettings.js';
|
|
11
11
|
import '../commons/JSONType.js';
|
|
12
|
-
import '../DataCaptureViewPlusRelated.js';
|
|
12
|
+
import '../DataCaptureViewPlusRelated-BOrDBPHq.js';
|
|
13
13
|
import '../NotificationPresenter/NotificationPresenter.js';
|
|
14
14
|
import '../NotificationPresenter/NotificationConfiguration.js';
|
|
15
15
|
import '../commons/Color.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{b as InlineWorker,a as workerInstance}from'../chunks/chunk-
|
|
1
|
+
export{b as InlineWorker,a as workerInstance}from'../chunks/chunk-LPFXHHWJ.js';
|
|
@@ -3,18 +3,18 @@ import '../private/BatteryInterface.js';
|
|
|
3
3
|
import '../LoadingStatus.js';
|
|
4
4
|
import '../commons/Point.js';
|
|
5
5
|
import '../commons/Orientation.js';
|
|
6
|
-
export { a1 as CreateContextParameters, K as DataCaptureEngine, aJ as LoadLibraryParameters, aT as ProcessFrameParameters, aW as ReportCameraPropertiesParameters, a_ as SetFrameSourceParameters, ba as UpdateContextParameters, W as WorkerFunctions } from '../DataCaptureContext-
|
|
6
|
+
export { a1 as CreateContextParameters, K as DataCaptureEngine, aJ as LoadLibraryParameters, aT as ProcessFrameParameters, aW as ReportCameraPropertiesParameters, a_ as SetFrameSourceParameters, ba as UpdateContextParameters, W as WorkerFunctions } from '../DataCaptureContext-qacCkSOl.js';
|
|
7
7
|
import '../ScanditIcon.js';
|
|
8
8
|
import '../private/FrameReaders/ColorType.js';
|
|
9
9
|
import '../private/djinni-types/index.js';
|
|
10
10
|
import '../private/Serializable.js';
|
|
11
|
-
import '../Camera-
|
|
11
|
+
import '../Camera-HgH6fwnW.js';
|
|
12
12
|
import '../commons/Rect.js';
|
|
13
13
|
import '../commons/Size.js';
|
|
14
14
|
import '../private/privateAccess.js';
|
|
15
15
|
import '../DataCaptureContextSettings.js';
|
|
16
16
|
import '../commons/JSONType.js';
|
|
17
|
-
import '../DataCaptureViewPlusRelated.js';
|
|
17
|
+
import '../DataCaptureViewPlusRelated-BOrDBPHq.js';
|
|
18
18
|
import '../NotificationPresenter/NotificationPresenter.js';
|
|
19
19
|
import '../NotificationPresenter/NotificationConfiguration.js';
|
|
20
20
|
import '../commons/Color.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{a as DataCaptureEngine}from'../chunks/chunk-
|
|
1
|
+
export{a as DataCaptureEngine}from'../chunks/chunk-2UHUEJA4.js';
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/// <reference types="emscripten" />
|
|
2
|
-
export { k as DataCaptureLoader, l as DataCaptureLoaderOptions } from '../DataCaptureContext-
|
|
2
|
+
export { k as DataCaptureLoader, l as DataCaptureLoaderOptions } from '../DataCaptureContext-qacCkSOl.js';
|
|
3
3
|
import '../LoadingStatus.js';
|
|
4
4
|
import '../logger.js';
|
|
5
5
|
import '../ScanditIcon.js';
|
|
6
|
-
import '../Camera-
|
|
6
|
+
import '../Camera-HgH6fwnW.js';
|
|
7
7
|
import '../commons/Rect.js';
|
|
8
8
|
import '../private/Serializable.js';
|
|
9
9
|
import '../commons/Point.js';
|
|
@@ -11,7 +11,7 @@ import '../commons/Size.js';
|
|
|
11
11
|
import '../private/privateAccess.js';
|
|
12
12
|
import '../DataCaptureContextSettings.js';
|
|
13
13
|
import '../commons/JSONType.js';
|
|
14
|
-
import '../DataCaptureViewPlusRelated.js';
|
|
14
|
+
import '../DataCaptureViewPlusRelated-BOrDBPHq.js';
|
|
15
15
|
import '../NotificationPresenter/NotificationPresenter.js';
|
|
16
16
|
import '../NotificationPresenter/NotificationConfiguration.js';
|
|
17
17
|
import '../commons/Color.js';
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import '../commons/Orientation.js';
|
|
3
3
|
import '../commons/Point.js';
|
|
4
4
|
import '../commons/Rect.js';
|
|
5
|
-
export { Y as AddNativeOverlayAction, Q as AnyDataCaptureActionMessage, R as AugmentedWorker, Z as BatteryData, _ as CaptureModeDeserializerInstance, $ as ConvertToJPEGResultDataCaptureAction, a0 as CreateContextDataCaptureAction, U as DataCaptureActionMessageKey, T as DataCaptureCallbackMessage, a2 as DataCaptureCallbackMessageKeys, a3 as DataCaptureContext, a4 as DataCaptureContextDeserializer, a5 as DataCaptureContextDeserializerResult, a6 as DataCaptureImageBufferFrameSource, a7 as DataCaptureView, a8 as DataCaptureWorker, a9 as DeleteFrameDataDataCaptureAction, aa as DeviceInterfaceInstance, ab as DidTapTrackedBarcode, ac as DisposeDataCaptureAction, ad as EmscriptenClassHandle, X as EngineWorkerResponse, ae as ExtractCentaurusLicenseDataCaptureAction, af as ExtractCentaurusLicenseResponse, ag as FlushAnalyticsDataCaptureAction, N as GenericHint, ah as GestureListener, ai as GestureRecognizer, aj as GetOpenSourceSoftwareLicenseInfoAction, ak as GetOpenSourceSoftwareLicenseInfoResponse, al as GetViewfinderInfoAction, am as GetViewfinderInfoResponse, an as GuidanceHint, ao as GuidanceHintAnchor, ap as GuidanceHintStyle, aq as HideGuidanceMessage, ar as HideHintWorkerMessage, as as HideToastMessage, at as HintAnchor, au as HintCornerStyle, av as HintFont, aw as HintHeight, ax as HintIcon, ay as HintPresenterV2, az as HintPresenterV2updateAction, aA as HintStyle, aB as HintTextAlignment, aC as HintWidth, aD as IsFeatureSupportedAction, aE as IsFeatureSupportedMessage, aF as IsFeatureSupportedResponse, aG as JSONParseable, aH as LicensedFeature, aI as LoadLibraryDataCaptureAction, L as Module, S as ModuleHandler, aK as ModuleMirrorAxis, aL as OnFrameProcessingFinishedMessage, aM as OnFrameProcessingStartedMessage, aN as OnFrameSkippedMessage, aO as OnTapAction, aP as PayloadForCommand, I as PerformanceMetrics, aQ as PerformanceMetricsReportMessage, aR as PlatformHintPresenter, aS as ProcessFrameDataCaptureAction, aU as RemoveNativeOverlayAction, aV as ReportCameraPropertiesDataCaptureAction, aX as RequestFrameDataDataCaptureAction, aY as RequestFrameDataResponse, aZ as SetFrameSourceDataCaptureAction, a$ as SetLogLevelDataCaptureAction, b0 as ShowGuidanceMessage, b1 as ShowHintWorkerMessage, b2 as ShowToastMessage, b3 as StartUpdateTimerMessage, b4 as StopUpdateTimerMessage, b5 as SuccessFeedbackWorkerMessage, b6 as ToastHint, b7 as ToastHintStyle, b8 as UpdateBatteryInfoDataCaptureAction, b9 as UpdateContextDataCaptureAction, bb as UpdateHintWorkerMessage, bc as Vector, V as ViewInfo, bd as ViewSizeChangedMessage, be as VisibilityChangeAction, bf as
|
|
5
|
+
export { Y as AddNativeOverlayAction, Q as AnyDataCaptureActionMessage, R as AugmentedWorker, Z as BatteryData, _ as CaptureModeDeserializerInstance, $ as ConvertToJPEGResultDataCaptureAction, a0 as CreateContextDataCaptureAction, U as DataCaptureActionMessageKey, T as DataCaptureCallbackMessage, a2 as DataCaptureCallbackMessageKeys, a3 as DataCaptureContext, a4 as DataCaptureContextDeserializer, a5 as DataCaptureContextDeserializerResult, a6 as DataCaptureImageBufferFrameSource, a7 as DataCaptureView, a8 as DataCaptureWorker, a9 as DeleteFrameDataDataCaptureAction, aa as DeviceInterfaceInstance, ab as DidTapTrackedBarcode, ac as DisposeDataCaptureAction, ad as EmscriptenClassHandle, X as EngineWorkerResponse, ae as ExtractCentaurusLicenseDataCaptureAction, af as ExtractCentaurusLicenseResponse, ag as FlushAnalyticsDataCaptureAction, N as GenericHint, ah as GestureListener, ai as GestureRecognizer, aj as GetOpenSourceSoftwareLicenseInfoAction, ak as GetOpenSourceSoftwareLicenseInfoResponse, al as GetViewfinderInfoAction, am as GetViewfinderInfoResponse, an as GuidanceHint, ao as GuidanceHintAnchor, ap as GuidanceHintStyle, aq as HideGuidanceMessage, ar as HideHintWorkerMessage, as as HideToastMessage, at as HintAnchor, au as HintCornerStyle, av as HintFont, aw as HintHeight, ax as HintIcon, ay as HintPresenterV2, az as HintPresenterV2updateAction, aA as HintStyle, aB as HintTextAlignment, aC as HintWidth, aD as IsFeatureSupportedAction, aE as IsFeatureSupportedMessage, aF as IsFeatureSupportedResponse, aG as JSONParseable, aH as LicensedFeature, aI as LoadLibraryDataCaptureAction, L as Module, S as ModuleHandler, aK as ModuleMirrorAxis, aL as OnFrameProcessingFinishedMessage, aM as OnFrameProcessingStartedMessage, aN as OnFrameSkippedMessage, aO as OnTapAction, aP as PayloadForCommand, I as PerformanceMetrics, aQ as PerformanceMetricsReportMessage, aR as PlatformHintPresenter, aS as ProcessFrameDataCaptureAction, aU as RemoveNativeOverlayAction, aV as ReportCameraPropertiesDataCaptureAction, aX as RequestFrameDataDataCaptureAction, aY as RequestFrameDataResponse, aZ as SetFrameSourceDataCaptureAction, a$ as SetLogLevelDataCaptureAction, b0 as ShowGuidanceMessage, b1 as ShowHintWorkerMessage, b2 as ShowToastMessage, b3 as StartUpdateTimerMessage, b4 as StopUpdateTimerMessage, b5 as SuccessFeedbackWorkerMessage, b6 as ToastHint, b7 as ToastHintStyle, b8 as UpdateBatteryInfoDataCaptureAction, b9 as UpdateContextDataCaptureAction, bb as UpdateHintWorkerMessage, bc as Vector, V as ViewInfo, bd as ViewSizeChangedMessage, be as VisibilityChangeAction, bf as WasmFeedback, bg as WasmFrameData, bh as WorkerResponse } from '../DataCaptureContext-qacCkSOl.js';
|
|
6
6
|
import '../LoadingStatus.js';
|
|
7
7
|
import '../logger.js';
|
|
8
8
|
import '../private/BatteryInterface.js';
|
|
@@ -10,11 +10,11 @@ import '../private/FrameReaders/ColorType.js';
|
|
|
10
10
|
import '../private/djinni-types/index.js';
|
|
11
11
|
import '../private/Serializable.js';
|
|
12
12
|
import '../commons/Size.js';
|
|
13
|
-
import '../Camera-
|
|
13
|
+
import '../Camera-HgH6fwnW.js';
|
|
14
14
|
import '../private/privateAccess.js';
|
|
15
15
|
import '../DataCaptureContextSettings.js';
|
|
16
16
|
import '../commons/JSONType.js';
|
|
17
|
-
import '../DataCaptureViewPlusRelated.js';
|
|
17
|
+
import '../DataCaptureViewPlusRelated-BOrDBPHq.js';
|
|
18
18
|
import '../NotificationPresenter/NotificationPresenter.js';
|
|
19
19
|
import '../NotificationPresenter/NotificationConfiguration.js';
|
|
20
20
|
import '../commons/Color.js';
|
|
@@ -4,13 +4,11 @@ interface SetupFSOptions {
|
|
|
4
4
|
indexedDBTimeoutMs: number;
|
|
5
5
|
}
|
|
6
6
|
/**
|
|
7
|
-
* Initializes the filesystem
|
|
7
|
+
* Initializes the filesystem with IDBFS for persistent storage.
|
|
8
8
|
*
|
|
9
9
|
* Setup flow:
|
|
10
|
-
* 1.
|
|
11
|
-
* 2.
|
|
12
|
-
* 3. Create and mount IDBFS
|
|
13
|
-
* 4. Perform initial population sync
|
|
10
|
+
* 1. Create and mount IDBFS with autoPersist (writes are automatically persisted to IndexedDB)
|
|
11
|
+
* 2. Perform initial population sync to load previously persisted data
|
|
14
12
|
*/
|
|
15
13
|
declare function setupFS(options: SetupFSOptions): Promise<void>;
|
|
16
14
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{a as setupFS}from'../chunks/chunk-
|
|
1
|
+
export{a as setupFS}from'../chunks/chunk-GVHXM75D.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/// <reference types="emscripten" />
|
|
2
2
|
export { WorkerMain } from './WorkerMain.js';
|
|
3
|
-
export { Y as AddNativeOverlayAction, Q as AnyDataCaptureActionMessage, R as AugmentedWorker, Z as BatteryData, _ as CaptureModeDeserializerInstance, $ as ConvertToJPEGResultDataCaptureAction, a0 as CreateContextDataCaptureAction, a1 as CreateContextParameters, U as DataCaptureActionMessageKey, T as DataCaptureCallbackMessage, a2 as DataCaptureCallbackMessageKeys, a3 as DataCaptureContext, a4 as DataCaptureContextDeserializer, a5 as DataCaptureContextDeserializerResult, K as DataCaptureEngine, a6 as DataCaptureImageBufferFrameSource, k as DataCaptureLoader, l as DataCaptureLoaderOptions, a7 as DataCaptureView, a8 as DataCaptureWorker, a9 as DeleteFrameDataDataCaptureAction, aa as DeviceInterfaceInstance, ab as DidTapTrackedBarcode, ac as DisposeDataCaptureAction, ad as EmscriptenClassHandle, X as EngineWorkerResponse, ae as ExtractCentaurusLicenseDataCaptureAction, af as ExtractCentaurusLicenseResponse, ag as FlushAnalyticsDataCaptureAction, N as GenericHint, ah as GestureListener, ai as GestureRecognizer, aj as GetOpenSourceSoftwareLicenseInfoAction, ak as GetOpenSourceSoftwareLicenseInfoResponse, al as GetViewfinderInfoAction, am as GetViewfinderInfoResponse, an as GuidanceHint, ao as GuidanceHintAnchor, ap as GuidanceHintStyle, aq as HideGuidanceMessage, ar as HideHintWorkerMessage, as as HideToastMessage, at as HintAnchor, au as HintCornerStyle, av as HintFont, aw as HintHeight, ax as HintIcon, ay as HintPresenterV2, az as HintPresenterV2updateAction, aA as HintStyle, aB as HintTextAlignment, aC as HintWidth, aD as IsFeatureSupportedAction, aE as IsFeatureSupportedMessage, aF as IsFeatureSupportedResponse, aG as JSONParseable, aH as LicensedFeature, aI as LoadLibraryDataCaptureAction, aJ as LoadLibraryParameters, L as Module, S as ModuleHandler, aK as ModuleMirrorAxis, aL as OnFrameProcessingFinishedMessage, aM as OnFrameProcessingStartedMessage, aN as OnFrameSkippedMessage, aO as OnTapAction, aP as PayloadForCommand, I as PerformanceMetrics, aQ as PerformanceMetricsReportMessage, aR as PlatformHintPresenter, aS as ProcessFrameDataCaptureAction, aT as ProcessFrameParameters, aU as RemoveNativeOverlayAction, aV as ReportCameraPropertiesDataCaptureAction, aW as ReportCameraPropertiesParameters, aX as RequestFrameDataDataCaptureAction, aY as RequestFrameDataResponse, aZ as SetFrameSourceDataCaptureAction, a_ as SetFrameSourceParameters, a$ as SetLogLevelDataCaptureAction, b0 as ShowGuidanceMessage, b1 as ShowHintWorkerMessage, b2 as ShowToastMessage, b3 as StartUpdateTimerMessage, b4 as StopUpdateTimerMessage, b5 as SuccessFeedbackWorkerMessage, b6 as ToastHint, b7 as ToastHintStyle, b8 as UpdateBatteryInfoDataCaptureAction, b9 as UpdateContextDataCaptureAction, ba as UpdateContextParameters, bb as UpdateHintWorkerMessage, bc as Vector, V as ViewInfo, bd as ViewSizeChangedMessage, be as VisibilityChangeAction, bf as WasmFrameData, W as WorkerFunctions,
|
|
4
|
-
import '../Camera-
|
|
3
|
+
export { Y as AddNativeOverlayAction, Q as AnyDataCaptureActionMessage, R as AugmentedWorker, Z as BatteryData, _ as CaptureModeDeserializerInstance, $ as ConvertToJPEGResultDataCaptureAction, a0 as CreateContextDataCaptureAction, a1 as CreateContextParameters, U as DataCaptureActionMessageKey, T as DataCaptureCallbackMessage, a2 as DataCaptureCallbackMessageKeys, a3 as DataCaptureContext, a4 as DataCaptureContextDeserializer, a5 as DataCaptureContextDeserializerResult, K as DataCaptureEngine, a6 as DataCaptureImageBufferFrameSource, k as DataCaptureLoader, l as DataCaptureLoaderOptions, a7 as DataCaptureView, a8 as DataCaptureWorker, a9 as DeleteFrameDataDataCaptureAction, aa as DeviceInterfaceInstance, ab as DidTapTrackedBarcode, ac as DisposeDataCaptureAction, ad as EmscriptenClassHandle, X as EngineWorkerResponse, ae as ExtractCentaurusLicenseDataCaptureAction, af as ExtractCentaurusLicenseResponse, ag as FlushAnalyticsDataCaptureAction, N as GenericHint, ah as GestureListener, ai as GestureRecognizer, aj as GetOpenSourceSoftwareLicenseInfoAction, ak as GetOpenSourceSoftwareLicenseInfoResponse, al as GetViewfinderInfoAction, am as GetViewfinderInfoResponse, an as GuidanceHint, ao as GuidanceHintAnchor, ap as GuidanceHintStyle, aq as HideGuidanceMessage, ar as HideHintWorkerMessage, as as HideToastMessage, at as HintAnchor, au as HintCornerStyle, av as HintFont, aw as HintHeight, ax as HintIcon, ay as HintPresenterV2, az as HintPresenterV2updateAction, aA as HintStyle, aB as HintTextAlignment, aC as HintWidth, aD as IsFeatureSupportedAction, aE as IsFeatureSupportedMessage, aF as IsFeatureSupportedResponse, aG as JSONParseable, aH as LicensedFeature, aI as LoadLibraryDataCaptureAction, aJ as LoadLibraryParameters, L as Module, S as ModuleHandler, aK as ModuleMirrorAxis, aL as OnFrameProcessingFinishedMessage, aM as OnFrameProcessingStartedMessage, aN as OnFrameSkippedMessage, aO as OnTapAction, aP as PayloadForCommand, I as PerformanceMetrics, aQ as PerformanceMetricsReportMessage, aR as PlatformHintPresenter, aS as ProcessFrameDataCaptureAction, aT as ProcessFrameParameters, aU as RemoveNativeOverlayAction, aV as ReportCameraPropertiesDataCaptureAction, aW as ReportCameraPropertiesParameters, aX as RequestFrameDataDataCaptureAction, aY as RequestFrameDataResponse, aZ as SetFrameSourceDataCaptureAction, a_ as SetFrameSourceParameters, a$ as SetLogLevelDataCaptureAction, b0 as ShowGuidanceMessage, b1 as ShowHintWorkerMessage, b2 as ShowToastMessage, b3 as StartUpdateTimerMessage, b4 as StopUpdateTimerMessage, b5 as SuccessFeedbackWorkerMessage, b6 as ToastHint, b7 as ToastHintStyle, b8 as UpdateBatteryInfoDataCaptureAction, b9 as UpdateContextDataCaptureAction, ba as UpdateContextParameters, bb as UpdateHintWorkerMessage, bc as Vector, V as ViewInfo, bd as ViewSizeChangedMessage, be as VisibilityChangeAction, bf as WasmFeedback, bg as WasmFrameData, W as WorkerFunctions, bh as WorkerResponse } from '../DataCaptureContext-qacCkSOl.js';
|
|
4
|
+
import '../Camera-HgH6fwnW.js';
|
|
5
5
|
import '../commons/Rect.js';
|
|
6
6
|
import '../private/Serializable.js';
|
|
7
7
|
import '../commons/Point.js';
|
|
@@ -9,7 +9,7 @@ import '../commons/Size.js';
|
|
|
9
9
|
import '../private/privateAccess.js';
|
|
10
10
|
import '../DataCaptureContextSettings.js';
|
|
11
11
|
import '../commons/JSONType.js';
|
|
12
|
-
import '../DataCaptureViewPlusRelated.js';
|
|
12
|
+
import '../DataCaptureViewPlusRelated-BOrDBPHq.js';
|
|
13
13
|
import '../NotificationPresenter/NotificationPresenter.js';
|
|
14
14
|
import '../NotificationPresenter/NotificationConfiguration.js';
|
|
15
15
|
import '../commons/Color.js';
|
package/build/js/worker/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{a as DataCaptureLoader}from'../chunks/chunk-YJNJGCAN.js';export{a as WorkerMain}from'../chunks/chunk-
|
|
1
|
+
export{a as DataCaptureLoader}from'../chunks/chunk-YJNJGCAN.js';export{a as WorkerMain}from'../chunks/chunk-JLTSTUKY.js';export{a as DataCaptureEngine}from'../chunks/chunk-2UHUEJA4.js';export{h as GuidanceHintAnchor,i as GuidanceHintStyle,g as HintAnchor,e as HintCornerStyle,a as HintFont,d as HintHeight,f as HintIcon,b as HintTextAlignment,c as HintWidth,k as LicensedFeature,j as ToastHintStyle}from'../chunks/chunk-WFKB322J.js';
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
var e={preferredResolution:"hd",zoomFactor:1,focusGestureStrategy:"manualUntilCapture",zoomGestureZoomFactor:2};export{e as a};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import {a as a$9}from'./chunk-GS7VZDY5.js';import {b as b$2}from'./chunk-HILZP6OW.js';import {a as a$a}from'./chunk-ARODHCN7.js';import {a as a$j}from'./chunk-A5G2NHT2.js';import {b,a as a$4}from'./chunk-RXDVYEE5.js';import {a as a$h}from'./chunk-XDTXM6UX.js';import {a as a$b}from'./chunk-TPHGDMKG.js';import {a as a$f}from'./chunk-GPPCTFZF.js';import {a as a$l}from'./chunk-Y7V35LNT.js';import {b as b$1}from'./chunk-24MGHMOY.js';import {a as a$e}from'./chunk-DTREAYZQ.js';import {a as a$g}from'./chunk-XIAF6V7E.js';import {a as a$c}from'./chunk-KYNYQBNF.js';import {a}from'./chunk-UQVVJP5Z.js';import {a as a$7}from'./chunk-RSQRPDVQ.js';import {a as a$6}from'./chunk-IJQG3OU6.js';import {a as a$8}from'./chunk-I6SWF3FQ.js';import {a as a$3}from'./chunk-N5YZEC56.js';import {a as a$2}from'./chunk-VJB527QZ.js';import {a as a$1}from'./chunk-GHTCNOQN.js';import {a as a$d}from'./chunk-UWBNF47P.js';import {g}from'./chunk-U6MNF7M6.js';import {a as a$o}from'./chunk-LFJUGRQV.js';import {a as a$n}from'./chunk-E4XJ4GKD.js';import {a as a$k}from'./chunk-QOCHMKNY.js';import {a as a$5}from'./chunk-KAFNKP6O.js';import {a as a$i}from'./chunk-XR65N6EG.js';import {a as a$m}from'./chunk-WUHKODFA.js';var P="core.camera.recovery",K;K=a$o;var L=class L{constructor(){this.focusGesture=a.focusGesture;this.zoomGesture=a.zoomGesture;this._scanAreaMargins=a.scanAreaMargins;this._pointOfInterest=a.pointOfInterest;this._logoStyle=a.logoStyle;this._logoAnchor=a.logoAnchor;this._logoOffset=a.logoOffset;this._context=null;this.overlays=new Set;this.controls=new Set;this.frameSourceListener={didChangeState:this.onFrameSourceChange.bind(this)};this._previewCamera=null;this.isConnected=false;this.controlsElement=void 0;this.frozenFrameCanvas=document.createElement("canvas");this.listeners=[];this.isVideoElementDetached=false;this.orientation="portrait";this.hiddenProperties={stopVideoTracksOnVisibilityChange:true,freezeFrameWhenStoppingFrameSource:true};this.orientationObserver=new b;this.onOrientationChangeListener=this.onOrientationChange.bind(this);this.onHintPresenterUpdateHandler=this.onHintPresenterUpdate.bind(this);this.onViewFinderUpdateRequestedHandler=this.onViewFinderUpdateRequested.bind(this);this.onWorkerMessageHandler=this.onWorkerMessage.bind(this);this.htmlElementDidChangeHandler=this.htmlElementDidChange.bind(this);this.htmlElementDisconnectedHandler=this.htmlElementDisconnected.bind(this);this.notificationPresenter=null;this[K]={attachAdditionalLayer:this.attachAdditionalLayer.bind(this)};this.visibilityListener=this.onVisibilityChange.bind(this),this.cameraRecoveryListener=this.cameraRecovery.bind(this),a$1.getInstance().updateIfMissing(a$2);}get videoElement(){return g.instance().getVideoElement()}get scanAreaMargins(){return this._scanAreaMargins}set scanAreaMargins(e){var t;this._scanAreaMargins=e,(t=this.privateContext)==null||t.update();}get pointOfInterest(){return this._pointOfInterest}set pointOfInterest(e){var t;this._pointOfInterest=e,(t=this.privateContext)==null||t.update();}get logoStyle(){return this._logoStyle}set logoStyle(e){var t;this._logoStyle=e,(t=this.privateContext)==null||t.update();}get logoAnchor(){return this._logoAnchor}set logoAnchor(e){var t;this._logoAnchor=e,(t=this.privateContext)==null||t.update();}get logoOffset(){return this._logoOffset}set logoOffset(e){var t;this._logoOffset=e,(t=this.privateContext)==null||t.update();}get cameraRecoveryText(){return a$1.getInstance().get(P)}get width(){var e,t;return Math.round((t=(e=this.htmlElementState)==null?void 0:e.width)!=null?t:0)}get height(){var e,t;return Math.round((t=(e=this.htmlElementState)==null?void 0:e.height)!=null?t:0)}get canvasDrawer(){return !this._canvasDrawer&&this.canvasElement!=null&&(this._canvasDrawer=new b$1(this.canvasElement),this._canvasDrawer.startObservingCanvasResize()),this._canvasDrawer}get privateContext(){return this._context}static async forContext(e){let t=new L;return await t.setContext(e),t}showProgressBar(){var e;(e=this.loadingOverlay)==null||e.show();}hideProgressBar(){var e;(e=this.loadingOverlay)==null||e.hide();}setProgressBarPercentage(e){this.loadingOverlay&&(this.loadingOverlay.progress=e);}setProgressBarMessage(e){this.loadingOverlay&&(this.loadingOverlay.message=e);}getContext(){return this._context}async setContext(e){var t,i,a;if(this._context=e,e){if(this.overlays.size>0&&!((t=this.privateContext)!=null&&t.hasModes()))throw new Error(["Cannot assign this view to this context. This view has overlays but the context does not have any mode attached matching these overlays.","Remove the overlays first before attaching the view to the context, or add the corresponding mode to the context before attaching this view."].join(" "));await e.setView(this),(i=this.privateContext)==null||i.subscribeToWorkerMessages(this.onWorkerMessageHandler),(a=this._context)!=null&&a.frameSource&&await this.onFrameSourceChange(this._context.frameSource);}}connectToElement(e,t){var i,a,r,n;this.isConnected||(this.orientationObserver.register(),this.setupHtmlElement(e),(i=this.canvasDrawer)==null||i.startObservingCanvasResize(),this.htmlElementDidChange(),a$3.add(this),this.orientation=this.orientationObserver.orientation.value,this.orientationObserver.addEventListener(a$4,this.onOrientationChangeListener),(a=this.hintPresenter)==null||a.addEventListener("hintpresenterupdate",this.onHintPresenterUpdateHandler),(r=this.hintPresenter)==null||r.addEventListener("hintpresenterviewfinderupdaterequested",this.onViewFinderUpdateRequestedHandler),this.localizationSubscription=a$1.getInstance().subscribe(s=>{s[P]!=null&&(this.cameraRecoveryElement.textContent=s[P]);}),this._previewCamera=(n=t==null?void 0:t.camera)!=null?n:null,this._previewCamera&&(this._previewCamera.addListener(this.frameSourceListener),this.onFrameSourceChange(this._previewCamera)),this.updateControls(),this.isConnected=true);}detachFromElement(){var e,t,i,a,r,n,s,h;if(this.isConnected){(e=this.htmlElementState)==null||e.removeListeners(),this.removeStyles(),(t=this.canvasDrawer)==null||t.endObservingCanvasResize(),document.removeEventListener("visibilitychange",this.visibilityListener);for(let m of ["touchend","mousedown"])this.cameraRecoveryElement.removeEventListener(m,this.cameraRecoveryListener);(i=this.loadingOverlay)==null||i.remove(),(a=this.customLocationsView)==null||a.unmount(),this.notificationPresenter=null,this.htmlElementDidChange(),(r=this.gestureRecognizer)==null||r.removeAllListeners(),this.clearHtmlElementContent(),a$3.delete(this),this.orientationObserver.unregister(),this.orientationObserver.removeEventListener(a$4,this.onOrientationChangeListener),(n=this.hintPresenter)==null||n.removeEventListener("hintpresenterupdate",this.onHintPresenterUpdateHandler),(s=this.hintPresenter)==null||s.removeEventListener("hintpresenterviewfinderupdaterequested",this.onViewFinderUpdateRequestedHandler),(h=this.localizationSubscription)==null||h.cancel(),g.instance().disconnectedCallback(),this._previewCamera&&(this._previewCamera.removeListener(this.frameSourceListener),this._previewCamera=null);for(let m of this.controls)this.removeControl(m);this.isConnected=false;}}async addOverlay(e){var t;this.overlays.has(e)||(this.overlays.add(e),await((t=this.privateContext)==null?void 0:t.update([{type:"addOverlay",newValue:e,view:this}])));}async removeOverlay(e){var t;this.overlays.has(e)&&(await((t=this.privateContext)==null?void 0:t.update([{type:"removeOverlay",newValue:e,view:this}])),this.overlays.delete(e));}addListener(e){this.listeners.includes(e)||this.listeners.push(e);}removeListener(e){this.listeners.includes(e)&&this.listeners.splice(this.listeners.indexOf(e),1);}viewPointForFramePoint(e){var u,V,D,R,F,A,M,I;let t={width:(V=(u=this.htmlElementState)==null?void 0:u.width)!=null?V:0,height:(R=(D=this.htmlElementState)==null?void 0:D.height)!=null?R:0},i={width:(A=(F=this.videoElement)==null?void 0:F.videoWidth)!=null?A:0,height:(I=(M=this.videoElement)==null?void 0:M.videoHeight)!=null?I:0},a=t.width/t.height,r=i.width/i.height,n=a>r?t.width/i.width:t.height/i.height,s={x:e.x*n,y:e.y*n},h=(i.width*n-t.width)/2,m=(i.height*n-t.height)/2;return new a$5(s.x-h,s.y-m)}viewQuadrilateralForFrameQuadrilateral(e){let t=this.viewPointForFramePoint(e.topLeft),i=this.viewPointForFramePoint(e.topRight),a=this.viewPointForFramePoint(e.bottomLeft),r=this.viewPointForFramePoint(e.bottomRight);return new a$6(t,i,r,a)}addControl(e){this.controls.has(e)||(this.controls.add(e),e.install(this).then(t=>{var i;t&&((i=this.privateContext)==null||i.update([{type:"addControl",newValue:e}]));}));}removeControl(e){var t;this.controls.has(e)&&(e.remove(true),this.controls.delete(e),(t=this.privateContext)==null||t.update([{type:"removeControl",newValue:e}]));}toJSONObject(){var e;return {scanAreaMargins:this.scanAreaMargins.toJSONObject(),pointOfInterest:this.pointOfInterest.toJSONObject(),logoAnchor:this.logoAnchor,logoOffset:this.logoOffset.toJSONObject(),logoHidden:(e=this.logoHidden)!=null?e:false,logoStyle:this.logoStyle,overlays:[...this.overlays].map(t=>t.toJSONObject()),controls:[...this.controls].map(t=>t.toJSONObject()),focusGesture:this.focusGesture?this.focusGesture.toJSONObject():null,zoomGesture:this.zoomGesture?this.zoomGesture.toJSONObject():null}}isCameraRecoveryVisible(){return !this.cameraRecoveryElement.hidden}setCameraRecoveryVisible(e){this.cameraRecoveryElement.hidden=!e;}async allowPictureInPicture(e){await g.instance().allowPictureInPicture(e);}viewAnchorPositionsForFrameAnchorPositions(e){let t=this.viewPointForFramePoint(e.topLeft),i=this.viewPointForFramePoint(e.topRight),a=this.viewPointForFramePoint(e.bottomLeft),r=this.viewPointForFramePoint(e.bottomRight),n=this.viewPointForFramePoint(e.centerLeft),s=this.viewPointForFramePoint(e.centerRight),h=this.viewPointForFramePoint(e.topCenter),m=this.viewPointForFramePoint(e.bottomCenter),u=this.viewPointForFramePoint(e.center);return new a$7(t,i,r,a,n,h,s,m,u)}setDidTapCustomLocationsViewListener(e){this.customLocationsView&&this.customLocationsView.listener===null&&(this.customLocationsView.listener=e);}renderCustomLocationsView(e){this.customLocationsView!=null&&(this.customLocationsView.setMirrored(g.instance().isMirrorImageEnabled()),Object.keys(e).includes("removedIds")?this.customLocationsView.render(e):this.customLocationsView.renderDomView(e));}getNotificationPresenter(){var e;if(!this.notificationPresenter){let t=(e=this.htmlElement)==null?void 0:e.querySelector(b$2.tag);if(!t)throw new Error("Notification presenter cannot be found. Please ensure the DataCaptureView is connected.");this.notificationPresenter=new a$8(t);}return this.notificationPresenter}removeStyles(){for(let e of document.querySelectorAll("style[scandit]"))e.remove();}onHintPresenterUpdate(e){var t;(t=this.privateContext)==null||t.workerCommand("hintPresenterV2update",{});}async onViewFinderUpdateRequested(e){var i;let t=await((i=this.privateContext)==null?void 0:i.workerCommand("getViewfinderInfo",{}));t!=null&&this.updateHintPresenterViewFinderRect(t.rect);}clearHtmlElementContent(){var e;this.htmlElement&&((e=this.canvasDrawer)==null||e.endObservingCanvasResize(),this.htmlElement.innerHTML="",this.cameraPaintboardElement=void 0,this.singleImageUploaderPaintboardElement=void 0,this.htmlElement=void 0);}setupHtmlElement(e){var r,n,s;this.createStyles(),this.htmlElement=e,b$2.register(),a$9.register(),a$a.register();let t=a$d`<div class="${a$b.CONTAINER_CLASS_NAME}" role="main" aria-label="Data capture view"><div class="${a$b.PAINTBOARDS_CONTAINER_CLASS_NAME}"><div data-js-id="loading-overlay"></div><div class="${a$b.PAINTBOARD_CLASS_NAME}" data-js-id="camera-paintboard"><div data-js-id="video-container"></div><img class="${a$b.FROZEN_FRAME}" data-js-id="frozen-frame" alt="Last captured camera frame shown while camera is on standby" hidden /><canvas></canvas><div data-js-id="${a$c.CUSTOM_VIEW_CONTAINER}"></div><${b$2.tag}></${b$2.tag}><${a$9.tag}></${a$9.tag}><div class="${a$b.CAMERA_RECOVERY_CLASS_NAME}" role="alert" aria-live="polite" aria-atomic="true" hidden>${this.cameraRecoveryText}</div><div class="${a$b.ERROR_CLASS_NAME}" role="alert" aria-live="assertive" aria-atomic="true" hidden></div></div><div class="${a$b.PAINTBOARD_CLASS_NAME}" data-js-id="singleimage-paintboard"></div></div></div>`;this.htmlElement.innerHTML=t,g.instance().connectedCallback(this.htmlElement.querySelector('[data-js-id="video-container"]')),this.isVideoElementDetached=false,this.hintPresenter=this.htmlElement.querySelector(b$2.tag),this.notificationPresenter=this.hintPresenter?new a$8(this.hintPresenter):null,this.loadingOverlay&&this.loadingOverlay.remove(),this.loadingOverlay=a$a.create(),this.loadingOverlay.hide(),(r=this.htmlElement.querySelector('[data-js-id="loading-overlay"]'))==null||r.replaceWith(this.loadingOverlay),this.customLocationsView&&this.customLocationsView.unmount(),this.customLocationsView=new a$e,this.customLocationsView.mount(this.htmlElement.querySelector(`[data-js-id="${a$c.CUSTOM_VIEW_CONTAINER}"]`)),this.customLocationsView.mapViewAnchorPositionsForFramePoint=h=>this.viewAnchorPositionsForFrameAnchorPositions(h),this.containerElement=this.htmlElement.querySelector(`.${a$b.CONTAINER_CLASS_NAME}`),this.cameraPaintboardElement=this.containerElement.querySelector('[data-js-id="camera-paintboard"]'),this.singleImageUploaderPaintboardElement=this.containerElement.querySelector('[data-js-id="singleimage-paintboard"]');let i=this.cameraPaintboardElement.querySelector("canvas");this.canvasElement==null?this.canvasElement=i:i.replaceWith(this.canvasElement);let a=this.cameraPaintboardElement.querySelector('[data-js-id="frozen-frame"]');this.frozenFrame==null?this.frozenFrame=a:a.replaceWith(this.frozenFrame),this.controlsElement=this.cameraPaintboardElement.querySelector(a$9.tag),this.cameraRecoveryElement=this.cameraPaintboardElement.querySelector(`.${a$b.CAMERA_RECOVERY_CLASS_NAME}`),this.errorElement=this.cameraPaintboardElement.querySelector(`.${a$b.ERROR_CLASS_NAME}`),this.lastFrameSourceState!=null&&((s=(n=this._context)==null?void 0:n.frameSource)==null||s.switchToDesiredState(this.lastFrameSourceState)),document.addEventListener("visibilitychange",this.visibilityListener);for(let h of ["touchend","mousedown"])this.cameraRecoveryElement.addEventListener(h,this.cameraRecoveryListener);this.htmlElementState&&this.htmlElementState.removeListeners(),this.htmlElementState=new a$f(this.htmlElement),this.htmlElementState.onStateChanged(this.htmlElementDidChangeHandler),this.htmlElementState.onDisconnected(this.htmlElementDisconnectedHandler),this.gestureRecognizer=new a$g(this.htmlElement),this.gestureRecognizer.addListener({onTap:async h=>{var m;(m=this.privateContext)==null||m.workerCommand("onTap",{point:h.toJSONObject()});}});}setupHtmlElementSingleImageUploader(e){var i;if(this.singleImageUploaderPaintboardElement==null)return;this.singleImageUploaderView&&this.singleImageUploaderView.unmount(),this.singleImageUploaderView=new a$h(e),this.singleImageUploaderView.mount(this.containerElement.querySelector('[data-js-id="singleimage-paintboard"]'));let t=(i=this._context)==null?void 0:i.frameSource;this.singleImageUploaderView.onInputCheck(a=>{t.getCurrentState()!=="starting"&&a.preventDefault();}),this.singleImageUploaderView.onBeforeFileRead(()=>{t._context&&this.singleImageUploaderView&&(this.singleImageUploaderView.canUploadFile=t._context.hasEnabledMode());}),this.singleImageUploaderView.onImageLoadError(()=>{t.currentState="starting",a$i.log(a$i.Level.Error,"Could not load image from selected file");}),this.singleImageUploaderView.onFileReaderError(a=>{var n,s;let r=a.target;t.currentState="starting",a$i.log(a$i.Level.Error,`Error while reading the file: ${(s=(n=r.error)==null?void 0:n.toString())!=null?s:""}`);}),this.singleImageUploaderView.onCaptureReady(async a=>{await t.processUploadedFileCapture(a);}),this.singleImageUploaderView.setButtonState(t.getCurrentState()==="starting"?"enabled":"disabled"),t.addView(this.singleImageUploaderView);}setupHtmlElementVisibility(e){this.cameraPaintboardElement!=null&&(this.cameraPaintboardElement.hidden=e!=="camera"),this.singleImageUploaderPaintboardElement!=null&&(this.singleImageUploaderPaintboardElement.hidden=e!=="singleImageUploader");}createStyles(){if(document.querySelector("style[scandit]")===null){let e=a$j();for(let[t,i]of Object.entries(e))i.setAttribute("scandit",`data-capture-sdk-${t}`),document.head.append(i);}}async onOrientationChange(e){var t,i;this.orientation=e.detail.value,await((i=this.privateContext)==null?void 0:i.update([{type:"viewChange",newValue:{...(t=this.htmlElementState)==null?void 0:t.toJSONObject(),orientation:this.orientation}}]));}htmlElementDidChange(){var i,a;if(!this.htmlElementState)return;let e=this.htmlElementState,t=e.toJSONObject();if(!a$f.areEquivalentJSONStates(this.lastHtmlElementState,t)){this.orientation=this.orientationObserver.orientation.value,(i=this.privateContext)==null||i.update([{type:"viewChange",newValue:{...e.toJSONObject(),orientation:this.orientation}}]),this.lastHtmlElementState=t,(a=this.canvasDrawer)==null||a.updateCanvasSizeAttributes(this.width,this.height),this.handleVideoDisplay(t.visible);for(let r of this.listeners)typeof r.didChangeSize=="function"&&r.didChangeSize(this,new a$k(t.size.width.value,t.size.height.value),this.orientation);}}async htmlElementDisconnected(){var e,t,i,a,r,n;g.instance().disconnectedCallback(),this.lastFrameSourceState=(t=(e=this._context)==null?void 0:e.frameSource)==null?void 0:t.getCurrentState(),await((a=(i=this._context)==null?void 0:i.frameSource)==null?void 0:a.switchToDesiredState("off")),await((n=this.privateContext)==null?void 0:n.update([{type:"viewChange",newValue:{...(r=this.htmlElementState)==null?void 0:r.toJSONObject(),orientation:this.orientation}}])),this.isConnected=false;}attachAdditionalLayer(e,t){var i;t==="above-controls"&&((i=this.controlsElement)==null||i.insertAdjacentElement("afterend",e));}handleVideoDisplay(e){this.videoElement==null||this.cameraPaintboardElement==null||(!e&&!this.isVideoElementDetached?(this.videoElement.width=0,this.videoElement.height=0,this.videoElement.style.opacity="0",this.videoElement.style.visibility="hidden",document.body.append(this.videoElement),this.isVideoElementDetached=true):e&&this.isVideoElementDetached&&(this.cameraPaintboardElement.insertAdjacentElement("afterbegin",this.videoElement),this.isVideoElementDetached=false,this.videoElement.style.removeProperty("visibility"),this.videoElement.removeAttribute("width"),this.videoElement.removeAttribute("height"),this.videoElement.style.removeProperty("opacity")));}isCanvasDrawerWithMetrics(e){return e instanceof a$l}onWorkerMessage(e){var t,i;switch(e.type){case "draw":{this.drawEngineCommands(e.payload);break}case "performanceMetricsReport":{let a=this._canvasDrawer;a!=null&&this.isCanvasDrawerWithMetrics(a)&&a.setPerformanceMetrics(e.payload);break}case "contextDidChangeStatus":{let a=a$m.fromJSON(e.payload);(t=this.loadingOverlay)==null||t.hide(),a.isValid?(this.clearError(),this.setVideoElementOpacity("1")):this.displayError(a);break}case "viewSizeChanged":{let a=e.payload;if(a==null)return;this.onSDCViewSizeChangedCallback(a);break}default:{(i=this.hintPresenter)==null||i.handleMessage(e);break}}}onSDCViewSizeChangedCallback(e){this.updateHintPresenterViewFinderRect(e.viewFinderRect);}updateHintPresenterViewFinderRect(e){var t;(t=this.hintPresenter)==null||t.setViewFinderRect(new a$n(new a$5(e.origin.x,e.origin.y),new a$k(e.size.width,e.size.height)));}drawEngineCommands(e){var t;(t=this.canvasDrawer)==null||t.draw(e);}displayError(e){this.errorElement.textContent=`Error ${e.code}: ${e.message}`,this.errorElement.hidden=false;}clearError(){this.errorElement.textContent="",this.errorElement.hidden=true;}updateControls(){var e;for(let t of this.controls)(e=t.update)==null||e.call(t,this);}async onFrameSourceChange(e){let t=e==null?void 0:e.type;if(this.setupHtmlElementVisibility(t),t==="camera"){let i=e==null?void 0:e.getCurrentState();i!=null&&await this.onCameraStateChanged(i);}else t==="singleImageUploader"&&this.setupHtmlElementSingleImageUploader(e.settings);}async onCameraStateChanged(e){var t;switch((t=this.cameraPaintboardElement)==null||t.classList.toggle(a$b.PAINTBOARD_CLASS_NAME_STATE_ON,e==="on"),e){case "stopping":{this.hiddenProperties.freezeFrameWhenStoppingFrameSource&&this.freezeFrame(),this.setVideoElementOpacity("0");return}case "starting":case "bootingUp":case "wakingUp":{if(!this.htmlElement){a$i.error("cannot set frame source stream before connecting view to an HTML element");return}this.videoElement&&(g.instance().gui.isCameraRecoveryVisible=this.isCameraRecoveryVisible.bind(this),g.instance().gui.setCameraRecoveryVisible=this.setCameraRecoveryVisible.bind(this),this.setVideoElementOpacity("0"));return}case "off":{this.setVideoElementOpacity("0"),this.updateControls();return}case "on":{await g.instance().waitForCapabilities(),this.updateControls(),this.unfreezeFrame(),this.setVideoElementOpacity("1");break}case "goingToSleep":{this.freezeFrame();break}}}setVideoElementOpacity(e){this.videoElement&&(this.videoElement.style.opacity=e),this.canvasElement&&(this.canvasElement.style.opacity=e);}onSingleImageUploaderSettingsChange(e){this.setupHtmlElementSingleImageUploader(e);}setHiddenProperty(e,t){this.hiddenProperties[e]=t;}async onVisibilityChange(){var t,i;let e=(t=this.videoElement)==null?void 0:t.srcObject;if(this.hiddenProperties.stopVideoTracksOnVisibilityChange&&(document.visibilityState==="hidden"&&g.instance().stopVideoTracks(),document.visibilityState==="visible"&&g.instance().activeCamera!=null&&e!=null))if(!e.active||(i=e.getVideoTracks()[0])!=null&&i.muted)try{a$i.debug('Detected visibility change ("visible") event with inactive video source, try to reinitialize camera'),await g.instance().reinitializeCamera();}catch{}else a$i.debug('Detected visibility change ("visible") event with active video source, replay video'),g.instance().playVideo();}async cameraRecovery(e){e.preventDefault(),g.instance().activeCamera=g.instance().selectedCamera,await g.instance().reinitializeCamera();}freezeFrame(){var i;if(!this.frozenFrame)return;let e=g.instance().getCurrentFrame();if(!e)return;let t=new ImageData(e.data,e.width,e.height);this.frozenFrameCanvas.width=t.width,this.frozenFrameCanvas.height=t.height,this.frozenFrame.width=t.width,this.frozenFrame.height=t.height,(i=this.frozenFrameCanvas.getContext("2d"))==null||i.putImageData(t,0,0),this.frozenFrame.src=this.frozenFrameCanvas.toDataURL("image/jpeg",.4),this.frozenFrame.classList.toggle(a$b.MIRRORED_CLASS_NAME,g.instance().isMirrorImageEnabled()),this.frozenFrame.hidden=false;}unfreezeFrame(){this.frozenFrame&&(this.frozenFrame.src="",this.frozenFrame.hidden=true);}},B=L;export{B as a};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import {a}from'./chunk-6LHGFWQI.js';var u=(o=>(o.On="on",o.Off="off",o.Standby="standby",o.Starting="starting",o.Stopping="stopping",o.BootingUp="bootingUp",o.WakingUp="wakingUp",o.GoingToSleep="goingToSleep",o.ShuttingDown="shuttingDown",o))(u||{}),c=(t=>(t.On="on",t.Off="off",t))(c||{}),m=(t=>(t.WorldFacing="worldFacing",t.UserFacing="userFacing",t))(m||{}),p=(r=>(r.Auto="auto",r.HD="hd",r.FullHD="fullHd",r.UHD4K="uhd4k",r))(p||{}),g=(r=>(r.None="none",r.Manual="manual",r.ManualUntilCapture="manualUntilCapture",r.AutoOnLocation="autoOnLocation",r))(g||{});function l(a){var e;return ((e=a==null?void 0:a.toJSONObject())==null?void 0:e.type)==="camera"}var n=class a$1{constructor(e){this.preferredResolution=a.settings.preferredResolution;this.zoomFactor=a.settings.zoomFactor;this.zoomGestureZoomFactor=a.settings.zoomGestureZoomFactor;this.focus={focusGestureStrategy:a.settings.focusGestureStrategy};e!=null&&(this.preferredResolution=e.preferredResolution,this.zoomFactor=e.zoomFactor,this.zoomGestureZoomFactor=e.zoomGestureZoomFactor,this.focusGestureStrategy=e.focusGestureStrategy,this.copyPrivatePropertiesFrom(e));}get focusGestureStrategy(){return this.focus.focusGestureStrategy}set focusGestureStrategy(e){this.focus.focusGestureStrategy=e;}copyPrivatePropertiesFrom(e){for(let[t,s]of Object.entries(e))Object.getOwnPropertyNames(this).includes(t)||this.setProperty(t,s);}static fromJSON(e){let t=new a$1;return t.preferredResolution=e.preferredResolution,t.zoomFactor=e.zoomFactor,t.zoomGestureZoomFactor=e.zoomGestureZoomFactor,t.focusGestureStrategy=e.focusGestureStrategy,t.copyPrivatePropertiesFrom(e),t}setProperty(e,t){this[e]=t;}getProperty(e){return this[e]}toJSONObject(){let e={preferredResolution:this.preferredResolution,zoomFactor:this.zoomFactor,zoomGestureZoomFactor:this.zoomGestureZoomFactor,focus:{focusGestureStrategy:this.focus.focusGestureStrategy}},t={};for(let s of Object.keys(this))[...Object.keys(e),"focusGestureStrategy"].includes(s)||(t[s]=this[s]);return {...e,...t}}};export{u as a,c as b,m as c,p as d,g as e,l as f,n as g};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import {b,c,d}from'./chunk-TNIR74NN.js';function n(){b();}function p(){c();}function i(){d();}export{n as a,p as b,i as c};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import {g as g$1}from'./chunk-U6MNF7M6.js';import {d}from'./chunk-YUZDO2PC.js';import {b}from'./chunk-QHBYNYWX.js';import {a as a$1}from'./chunk-LFJUGRQV.js';import {b as b$1}from'./chunk-YONR3EGV.js';import {a as a$3}from'./chunk-XR65N6EG.js';import {g}from'./chunk-3D2HNEVH.js';import {a}from'./chunk-6LHGFWQI.js';import {a as a$2}from'./chunk-QCZSSQAQ.js';d.addVideoDevicesListener(w=>{b.integrateIncomingVideoDevices(w.map(e=>u.fromDeviceCamera(e)));});var C;C=a$1;var s=class s{constructor(e){this._label="";this._deviceId="";this._notFoundOnDevice=false;this._isBestGuess=false;this.type="camera";this._currentState="off";this._settings=new g;this._desiredTorchState="off";this._desiredState="off";this.listeners=[];this._context=null;this[C]={markAsUnmappedToDeviceCameras:this.markAsUnmappedToDeviceCameras.bind(this),resetUnmappedState:this.resetUnmappedState.bind(this),setDeviceId:this.setDeviceId.bind(this),setLabel:this.setLabel.bind(this),markAsBestGuess:this.markAsBestGuess.bind(this)};this._captureAndSendBound=this.captureAndSend.bind(this);this.stateTransitionStrategyMap={off:{on:this.transitionFromStateOffToOn.bind(this),standby:this.transitionFromStateOffToStandby.bind(this)},on:{off:this.transitionFromStateOnToOff.bind(this),standby:this.transitionFromStateOnToStandby.bind(this)},standby:{off:this.transitionFromStateStandbyToOff.bind(this),on:this.transitionFromStateStandbyToOn.bind(this)}};this.cameraManager=e!=null?e:g$1.instance();}static pickBestGuess(){return s.getOrCreate({position:"worldFacing",bestGuess:true})}static pickBestGuessForPosition(e){if(!a.availablePositions.includes(e))throw new Error(`Invalid camera position: "${e}"`);return s.getOrCreate({position:e})}static forDeviceId(e){return s.getOrCreate({deviceId:e})}static async getAll(e,t){return await d.getCameras(e!=null?e:false,t!=null?t:false),[...b.get()]}static getOrCreate(e){let{deviceId:t,position:r,bestGuess:i}=e,n=new s;return n._deviceId=t!=null?t:"",n.position=r!=null?r:"worldFacing",i&&n[a$1].markAsBestGuess(),b.getOrCreate(n)}static fromDeviceCamera(e){let t=new s;return t.position=e.position,t._deviceId=e.deviceId,t._label=e.label,t}get deviceId(){return this._deviceId}get label(){return this._label}get desiredState(){return this._desiredState}get settings(){return this._settings}get currentResolution(){var e;return (e=this._currentResolution)!=null?e:null}setDeviceId(e){this._deviceId=e;}setLabel(e){this._label=e;}get context(){return this._context}set context(e){this._context=e,this._context&&this.currentState==="on"&&this.startSendingCapturesToWorker();}get currentState(){return this._currentState}async switchToDesiredState(e){var t,r;if(this.currentTransitionStrategyPromise&&await this.currentTransitionStrategyPromise,this._notFoundOnDevice&&(e==="on"||e==="standby"))throw new a$2({message:`Cannot switch state to ${e}. This camera could not be mapped to a detected camera on the device. Please use another camera and delete this one.`,name:"Unmapped Camera"});return this.currentTransitionStrategyPromise=(r=(t=this.stateTransitionStrategyMap[this.currentState])==null?void 0:t[e])==null?void 0:r.call(t).catch(i=>{if(i instanceof DOMException&&i.message==="The associated Track is in an invalid state"){a$3.log(a$3.Level.Warn,i);return}throw i}),this.currentTransitionStrategyPromise}getDesiredTorchState(){return this._desiredTorchState}async setDesiredTorchState(e){this._desiredTorchState=e,await this.cameraManager.setTorchEnabled(this._desiredTorchState==="on"),await this.notifyContext({type:"torchState",newValue:this._desiredTorchState});}async isTorchAvailable(){return this.cameraManager.isTorchAvailable()}addListener(e){e!=null&&(this.listeners.includes(e)||this.listeners.push(e));}removeListener(e){e!=null&&this.listeners.includes(e)&&this.listeners.splice(this.listeners.indexOf(e),1);}async applySettings(e){var r;this._settings=new g(e);let t=this.settings.getProperty("grayScaleFrameReader");if(this.cameraManager.setFrameReaderType(t===true?"GRAYSCALE":"RGBA"),this.currentState==="on"||this.currentState==="standby"){let i=this.cameraManager.activeCameraSettings;(i==null?void 0:i.preferredResolution)!==this.settings.preferredResolution&&(await this.cameraManager.applyCameraSettings(this.settings),(r=this.cameraManager.activeCamera)!=null&&r.currentResolution&&(this._currentResolution={width:this.cameraManager.activeCamera.currentResolution.width,height:this.cameraManager.activeCamera.currentResolution.height})),await this.cameraManager.setZoom(this.settings.zoomFactor);let n=this.settings.getProperty("minFrameRate"),h=this.settings.getProperty("maxFrameRate");(n!=null||h!=null)&&await this.cameraManager.setFrameRate({min:n,max:h});let l=this.settings.getProperty("manualLensPosition");l!=null&&await this.cameraManager.setFocus(l);let p=this.settings.getProperty("exposureTargetBias"),S=this.settings.getProperty("exposureDuration");(p!=null||S!=null)&&await this.cameraManager.setExposure({compensation:p,time:S});}return this.notifyContext({type:"cameraSettings",newValue:this.settings})}toJSONObject(){return {type:this.type,position:this.position,settings:this.settings.toJSONObject(),desiredState:this.desiredState,desiredTorchState:this._desiredTorchState}}getMirrorImageEnabled(){var e;return (e=this._desiredMirrorImageEnabled)!=null?e:this.cameraManager.isMirrorImageEnabled()}async setMirrorImageEnabled(e){this._desiredMirrorImageEnabled=e,this.cameraManager.setMirrorImageEnabled(e,true),this.context&&await this.context.setFrameSource(this);}getCurrentState(){return this._currentState}async setClipArea(e){await this.cameraManager.setClipArea(e);}async setCurrentState(e){if(e!==this._currentState){this._currentState=e,this.notifyListeners();try{await this.notifyContext({type:"frameSourceState",newValue:e}),e==="on"&&this.startSendingCapturesToWorker();}catch{a$3.warn("Error while notifying context about new state of Camera");}}}async setupCamera(){if(this.cameraManager.setSelectedCameraSettings(this.settings),this.deviceId==="")this.cameraManager.setSelectedCamera(),this.cameraManager.setInitialCameraPosition(this.position);else {let t=(await d.getCameras()).find(r=>r.deviceId===this.deviceId);t&&(this.cameraManager.setInitialCameraPosition(t.position),this.cameraManager.setSelectedCamera(t));}await this.cameraManager.setupCameras(),typeof this._desiredMirrorImageEnabled=="boolean"?this.cameraManager.setMirrorImageEnabled(this._desiredMirrorImageEnabled,true):this.cameraManager.setMirrorImageEnabled(this.cameraManager.isMirrorImageEnabled(),false),this.context&&await this.context.setFrameSource(this),this.cameraManager.activeCamera&&(this._deviceId=this.cameraManager.activeCamera.deviceId,this._label=this.cameraManager.activeCamera.label,this.position=this.cameraManager.activeCamera.position,this._currentResolution=this.cameraManager.activeCamera.currentResolution);}markAsUnmappedToDeviceCameras(){this._notFoundOnDevice=true;}resetUnmappedState(){this._notFoundOnDevice=false;}markAsBestGuess(){this._isBestGuess=true;}async notifyContext(e){if(this.context)return this.context.update([e])}notifyListeners(){for(let e of this.listeners)e.didChangeState&&e.didChangeState(this,this.currentState);}updateCanvasVideoImage(){this.currentState==="on"&&this.context&&(this.cameraManager.updateCanvasVideoImage(),this._lastCanvasVideoPreviewAnimationFrame=this.cameraManager.requestVideoFrame(this.updateCanvasVideoImage.bind(this)));}async captureAndSend(){if(this.currentState!=="on"||!this.context)return;if(!this.context.hasEnabledMode()){this._lastCaptureRequestAnimationFrame=this.cameraManager.requestVideoFrame(this._captureAndSendBound);return}let e=null;try{e=this.cameraManager.captureImage();}catch(t){a$3.warn("Camera: error while capturing image.",t);}finally{if(e!=null)if(this.cameraManager.synchronousFrameHandling){let t=await this.context.sendFrameToProcessor(e);this.cameraManager.recycle(t.data);}else this.context.sendFrameToProcessor(e).then(t=>(this.cameraManager.recycle(t.data),null)).catch(t=>{a$3.warn("error while recycling uint8array",t);});this._lastCaptureRequestAnimationFrame=this.cameraManager.requestVideoFrame(this._captureAndSendBound);}}startSendingCapturesToWorker(){this.stopSendingCapturesToWorker(),this.captureAndSend();}stopSendingCapturesToWorker(){this._lastCanvasVideoPreviewAnimationFrame!=null&&this.cameraManager.cancelVideoFrame(this._lastCanvasVideoPreviewAnimationFrame),this._lastCaptureRequestAnimationFrame!=null&&this.cameraManager.cancelVideoFrame(this._lastCaptureRequestAnimationFrame);}async transitionFromStateOffToOn(){if(!(this.currentState==="on"||this.currentState==="starting"||this.currentState==="wakingUp")){this._desiredState="on",await this.setCurrentState("starting");try{await this.setupCamera(),await this.setCurrentState("on");}catch(e){throw a$3.log(a$3.Level.Error,e),await this.setCurrentState("off"),e}}}async transitionFromStateOffToStandby(){if(!(this.currentState==="standby"||this.currentState==="bootingUp"||this.currentState==="goingToSleep")){if(await this.isAndroidWebView()){a$3.log(a$3.Level.Warn,'Warning: "Standby" state does not work inside web views. Falling back to state "On".'),await this.transitionFromStateOffToOn();return}this._desiredState="standby",await this.setCurrentState("bootingUp");try{await this.setupCamera(),this.cameraManager.pauseStream(),await this.setCurrentState("standby");}catch(e){throw a$3.log(a$3.Level.Error,e),await this.setCurrentState("off"),e}await this.setCurrentState("standby"),await this.setDesiredTorchState("off");}}async transitionFromStateOnToOff(){this.currentState==="off"||this.currentState==="stopping"||(this._desiredState="off",await this.setCurrentState("stopping"),await this.cameraManager.stopStream(),await this.setCurrentState("off"),await this.setDesiredTorchState("off"));}async transitionFromStateOnToStandby(){if(!(this.currentState==="standby"||this.currentState==="bootingUp"||this.currentState==="goingToSleep")){if(await this.isAndroidWebView()){a$3.log(a$3.Level.Warn,'Warning: "Standby" state does not work inside web views. Falling back to state "Off".'),await this.transitionFromStateOnToOff();return}this._desiredState="standby",await this.setCurrentState("goingToSleep"),this.cameraManager.pauseStream(),await this.setCurrentState("standby"),await this.setDesiredTorchState("off");}}async transitionFromStateStandbyToOff(){this.currentState==="off"||this.currentState==="stopping"||(this._desiredState="off",await this.setCurrentState("shuttingDown"),await this.cameraManager.stopStream(),await this.setCurrentState("off"),await this.setDesiredTorchState("off"));}async transitionFromStateStandbyToOn(){this.currentState==="on"||this.currentState==="starting"||this.currentState==="wakingUp"||(this._desiredState="on",await this.setCurrentState("wakingUp"),this.cameraManager.resumeStream(),await this.setCurrentState("on"));}async isAndroidWebView(){return this._isAndroidWebView==null&&(this._isAndroidWebView=await b$1.isAndroidWebView()),this._isAndroidWebView}isZoomAvailable(){var e;return ((e=this.cameraManager.mediaTrackCapabilities)==null?void 0:e.zoom)!=null}},u=s;export{u as a};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import {a}from'./chunk-2AX7TBDI.js';var t={settings:a,defaultPosition:"worldFacing",availablePositions:["worldFacing","userFacing"]};export{t as a};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
var r=class extends CustomEvent{constructor(e){super("camera-fov-changed",{detail:e,bubbles:true,composed:true});}},a=class extends CustomEvent{constructor(e){super("camera-switched",{detail:e,bubbles:true,composed:true});}},o=class extends CustomEvent{constructor(e){super("torch-toggled",{detail:e,bubbles:true,composed:true});}};export{r as a,a as b,o as c};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import {a as a$1}from'./chunk-TPHGDMKG.js';import {a as a$2}from'./chunk-LSZZVJ6B.js';function a(){let i=a$2`@keyframes scandit-rotation{0%{transform:rotate(0deg)}to{transform:rotate(1turn)}}.${a$1.CONTAINER_CLASS_NAME}{align-items:center;display:flex;flex-direction:column;height:100%;justify-content:center;overflow:hidden;position:relative;width:100%}.${a$1.CONTAINER_CLASS_NAME}:before{animation:scandit-rotation 1s linear infinite;background-color:#fff;content:" ";height:1px;left:0;opacity:0;pointer-events:none;position:absolute;top:0;width:1px}`,o=a$2`.${a$1.PAINTBOARDS_CONTAINER_CLASS_NAME}{height:inherit;position:relative;width:100%}.${a$1.PAINTBOARD_CLASS_NAME}{aspect-ratio:16/9;background-color:#000;height:100%;min-height:1px;min-width:1px;position:relative;width:100%}.${a$1.PAINTBOARD_CLASS_NAME}.${a$1.PAINTBOARD_CLASS_NAME_STATE_ON}{aspect-ratio:auto}.${a$1.PAINTBOARD_CLASS_NAME} video{display:block;height:100%;object-fit:cover;transition:opacity .3s;width:100%}.${a$1.PAINTBOARD_CLASS_NAME} .${a$1.MIRRORED_CLASS_NAME}{transform:scaleX(-1)}.${a$1.PAINTBOARD_CLASS_NAME} .${a$1.CAMERA_RECOVERY_CLASS_NAME}{align-items:center;background-color:#000;color:#fff;cursor:pointer;display:flex;height:100%;justify-content:center;left:0;position:absolute;top:0;transition:background-color .2s;width:100%;z-index:5}.${a$1.PAINTBOARD_CLASS_NAME} .${a$1.CAMERA_RECOVERY_CLASS_NAME}:focus-visible{outline:2px solid #06c;outline-offset:-4px}.${a$1.PAINTBOARD_CLASS_NAME} .${a$1.CAMERA_RECOVERY_CLASS_NAME}:hover:not([hidden]){background-color:#000c}.${a$1.PAINTBOARD_CLASS_NAME} .${a$1.ERROR_CLASS_NAME}{align-items:center;background-color:#00000080;color:#fff;display:flex;height:100%;justify-content:center;left:0;position:absolute;text-align:center;top:0;width:100%;z-index:6}.${a$1.CAMERA_RECOVERY_CLASS_NAME}[hidden],.${a$1.ERROR_CLASS_NAME}[hidden]{display:none}.${a$1.PAINTBOARD_CLASS_NAME} canvas{height:100%;left:0;object-fit:cover;pointer-events:none;position:absolute;top:0;transition:opacity .3s;width:100%}`,n=a$2`.${a$1.PAINTBOARD_CLASS_NAME} .${a$1.SINGLE_IMAGE_UPLOADER_CONTAINER_CLASS_NAME}{-webkit-tap-highlight-color:rgba(255,255,255,0);align-items:center;display:flex;flex-direction:column;height:100%;justify-content:center;width:100%}.${a$1.PAINTBOARD_CLASS_NAME} .${a$1.SINGLE_IMAGE_UPLOADER_CONTAINER_CLASS_NAME} label{align-items:center;cursor:pointer;display:flex;flex-direction:column;justify-content:center}.${a$1.PAINTBOARD_CLASS_NAME} .${a$1.SINGLE_IMAGE_UPLOADER_CONTAINER_CLASS_NAME} label input[type=file]{position:absolute;top:-9999px}.${a$1.PAINTBOARD_CLASS_NAME}.${a$1.SINGLE_IMAGE_UPLOADER_CONTAINER_CLASS_NAME} label button{pointer-events:none}`,A=a$2`.${a$1.FROZEN_FRAME}{height:100%;left:0;object-fit:cover;opacity:1;position:absolute;top:0;width:100%}.${a$1.FROZEN_FRAME}[hidden]{opacity:0;pointer-events:none;visibility:hidden}`;return [i,o,n,A]}export{a};
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import {a as a$7}from'./chunk-O5D4KVS5.js';import {a as a$4}from'./chunk-ACFJP5SR.js';import {a as a$a,c as c$3,b as b$3}from'./chunk-L66S4DN2.js';import {a as a$j}from'./chunk-BA3RP6L2.js';import {a as a$8}from'./chunk-AIC4H5KG.js';import {a as a$h}from'./chunk-KSCFPJAW.js';import {a as a$f}from'./chunk-W3X3ZRQZ.js';import {a as a$d}from'./chunk-JS3T7K2Z.js';import {b as b$2}from'./chunk-6H6FKGVE.js';import {a as a$c}from'./chunk-N5YZEC56.js';import {a as a$6}from'./chunk-VJB527QZ.js';import {a as a$5}from'./chunk-GHTCNOQN.js';import {a as a$1}from'./chunk-LXOZUOZU.js';import {a as a$g}from'./chunk-FGO2SSRS.js';import {c as c$1,a as a$e}from'./chunk-3JLTBSEJ.js';import {g,e as e$1}from'./chunk-U6MNF7M6.js';import {a as a$9}from'./chunk-GPJEB376.js';import {b as b$1}from'./chunk-YONR3EGV.js';import {c as c$2,e}from'./chunk-SBC5K7IT.js';import {a as a$3}from'./chunk-XR65N6EG.js';import {f as f$1}from'./chunk-3D2HNEVH.js';import {a as a$i}from'./chunk-WUHKODFA.js';import {a as a$2}from'./chunk-7SW2PEHB.js';import {a as a$b}from'./chunk-QCZSSQAQ.js';import {c}from'./chunk-TR3NGINC.js';var Q=[{from:"unconfigured",to:"configuring"},{from:"configuring",to:"configured"},{from:"configuring",to:"unconfigured"},{from:"configured",to:"creating-context"},{from:"creating-context",to:"ready"},{from:"creating-context",to:"unconfigured"},{from:"ready",to:"unconfigured"},{from:"configured",to:"unconfigured"}];function v(C,e,t){let r=t.value;return t.value=function(...n){let i=f.stateMachine;return i.currentState==="ready"&&f.mainDataCaptureLoader!=null?r.apply(this,n):i.isInitializing||i.currentState==="configured"?i.waitForState("ready").then(()=>r.apply(this,n)):Promise.reject(new Error(`Please call DataCaptureContext.forLicenseKey() before calling ${String(e)}`))},t}function G(C){return C[a$j]!=null}function x(C){return "skipSerialization"in C||C[a$j]!=null}var q,Y,_,a=class a{constructor(){this._asyncImageConverterInstance=void 0;this.framework="web";this.runtimeEnvironment={deviceOS:(q=b$1.getUserAgentInfo().getOS().name)!=null?q:"",browser:(Y=b$1.getUserAgentInfo().getBrowser().name)!=null?Y:"",browserVersion:(_=b$1.getUserAgentInfo().getBrowser().version)!=null?_:"",get deviceModelName(){let{model:e,vendor:t}=b$1.getUserAgentInfo().getDevice();return (t==null||t==="")&&(t="Unknown"),(e==null||e==="")&&(e="Unknown"),[t,e].join(" ")}};this.settings=new a$2;this._frameSource=null;this._view=null;this.modes=new Set;this.components=[];this.listeners=[];this.updateListeners=new Set;this.cameraPropertiesReportListener=this.reportCameraProperties.bind(this);this.cameraAccessErrorListener=this.onCameraAccessError.bind(this);this.onWorkerMessageListener=this.onWorkerMessage.bind(this);this.onVisibilityChangeListener=this.onVisibilityChange.bind(this);this.batteryChangeListener=this.onBatteryChange.bind(this);this.pendingWorkerMessageListeners=new Set;this.delayedRegistration=false;this.highEndBlurryRecognition=false;this._frameHandlers=[];this._useSynchronousFrameFlow=false;}static get moduleLicenseTextProviders(){return [new b]}static get sharedInstance(){return a._sharedInstance==null&&(a._sharedInstance=new a),a._sharedInstance}static get currentState(){return a.stateMachine.currentState}static get isReady(){return a.stateMachine.currentState==="ready"}static get isInitializing(){return a.stateMachine.isInitializing}static addStateListener(e){a.stateMachine.addListener(e);}static removeStateListener(e){a.stateMachine.removeListener(e);}async initializeWithOptions(e){var t,r,n,i,s,o,u,c,l;a.deviceID===""&&(a.deviceID=await b$1.getDeviceId()),this.licenseKey=(r=(t=e.licenseKey)!=null?t:a.userLicenseKey)!=null?r:"",this.deviceName=(n=e.deviceName)!=null?n:"",this.dataCaptureInstance=(i=e.dataCaptureInstance)!=null?i:a.mainDataCaptureLoader,this.delayedRegistration=(s=e.delayedRegistration)!=null?s:false,e.settings!=null&&(this.settings=e.settings),this.highEndBlurryRecognition=(l=(c=(o=e.dataCaptureInstance)==null?void 0:o.highEndBlurryRecognition)!=null?c:(u=a.mainDataCaptureLoader)==null?void 0:u.highEndBlurryRecognition)!=null?l:false;for(let S of this.pendingWorkerMessageListeners)this.dataCaptureInstance.addWorkerListener(S);this.pendingWorkerMessageListeners.clear(),this.settings!=null&&await this.applySettings(this.settings),await this.createContext();}get frameSource(){return this._frameSource}get workerCommand(){if(this.dataCaptureInstance==null)throw new Error("Cannot call workerCommand before dataCaptureInstance is set");return this.dataCaptureInstance.workerCommand.bind(this.dataCaptureInstance)}static async forLicenseKey(e,t){return a$3.debug(`forLicenseKey called, current state: ${a.stateMachine.currentState}`),a.stateMachine.currentState==="ready"?(a$3.debug("DataCaptureContext is already ready, returning existing instance"),a.sharedInstance):a.stateMachine.isInitializing?(a$3.debug("DataCaptureContext is already initializing, waiting for completion"),await a.stateMachine.waitForState("ready"),a.sharedInstance):(a.stateMachine.currentState==="unconfigured"&&(a$3.debug("Starting initialization from unconfigured state"),await a.stateMachine.executeAsyncTransition({targetState:"configuring",action:async()=>{await a.internalConfigure(e,t);},onSuccess:"configured",onError:"unconfigured"}),await a.stateMachine.executeAsyncTransition({targetState:"creating-context",action:async()=>{await a.sharedInstance.initializeWithOptions({licenseKey:e,deviceName:t.deviceName,settings:t.settings});},onSuccess:"ready",onError:"unconfigured"})),a.sharedInstance)}static async internalConfigure(e$1,t){var S;a$4(),c$1(),a$5.getInstance().updateIfMissing(a$6);let{forceAllPolyfills:r,overrideThreadsSupport:n,overrideSimdSupport:i}=a.getOverridesFromQueryString(),[s,o,u]=await Promise.all([a$7({forceAllPolyfills:r}),c$2(),e()]);n!=="auto"&&(a$3.warn(`Threads support override: was ${u} is now ${n==="on"}`),u=n==="on"),i!=="auto"&&(a$3.warn(`SIMD support override: was ${o} is now ${i==="on"}`),o=i==="on"),a.capabilityInfo={simdSupport:o,threadsSupport:u},a$3.debug(`Capability info detected - SIMD: ${o}, Threads: ${u}`),await a.validateOptions({...t,licenseKey:e$1});let c={licenseKey:e$1,libraryLocation:a$8(t.libraryLocation),moduleLoaders:t.moduleLoaders,logLevel:(S=t.logLevel)!=null?S:a$3.Level.Debug,verifyResponseHash:true,loadProgressNotifier:b$2.notify.bind(b$2),simdSupport:o,threadsSupport:u};a$3.setLevel(c.logLevel),a.userLicenseKey=c.licenseKey,a.libraryLocation=c.libraryLocation,b$2.subscribe(a.updateViewsWithProgress);let l=b$1.checkBrowserCompatibility();if(!l.fullSupport&&!l.scannerSupport)throw new a$9(l);b$1.isSupportedIOSVersion()||a$3.warn(`Warning: Minimum supported iOS version is 14.6.
|
|
2
|
-
Please check the minimum system requirements here:
|
|
3
|
-
https://docs.scandit.com/system-requirements#browser-compatibility`),a.dataCaptureLoaders=await a.loadModules(c.moduleLoaders,c),a.mainDataCaptureLoader=[...a.dataCaptureLoaders.entries()][0][1],b$2.unsubscribe(a.updateViewsWithProgress);}static async forLicenseKeyInElectronPath(e,t){if(!a$a())throw new a$b({name:"MisconfigurationError",message:"forLicenseKeyInElectronPath can only be used in Electron applications"});let r=await c$3({licenseDataPath:e});if(r==null)throw new a$b({name:"NoLicenseKeyError",message:`Cannot retrieve license key for Electron app at ${e}`});return a.forLicenseKey(r.licenseKey,{...t})}static updateViewsWithProgress({percentage:e}){for(let t of a$c.values())t.setProgressBarPercentage(e);}static getOverridesFromQueryString(){var s,o,u;function e(c){return ["auto","off","on"].includes(c)}let t=new URLSearchParams(window.location.search),[r="auto",n="auto",i=false]=[(s=t.get("pthreads"))==null?void 0:s.toLowerCase(),(o=t.get("simd"))==null?void 0:o.toLowerCase(),((u=t.get("forceAllPolyfills"))==null?void 0:u.toLowerCase())==="true"];return {overrideThreadsSupport:e(r)?r:"auto",overrideSimdSupport:e(n)?n:"auto",forceAllPolyfills:i}}static async validateOptions(e){if(e.licenseKey==null||e.licenseKey.trim().length<64)throw new a$b({name:"NoLicenseKeyError",message:"No license key provided"});if(typeof e.libraryLocation!="string")throw new a$b({name:"MisconfigurationError",message:'Option "libraryLocation" was not provided'});if(!Array.isArray(e.moduleLoaders)||e.moduleLoaders.length===0)throw new a$b({name:"MisconfigurationError",message:'Option "moduleLoaders" is missing or empty'});let t=e.moduleLoaders.map(r=>r.moduleName);if(!["BarcodeCapture","IdCapture","LabelCapture"].includes(t[0]))throw new a$b({name:"MisconfigurationError",message:'Main modules must be loaded before side modules. For example "BarcodeCapture" must be loaded before "Parser".'})}static async loadModules(e,t){let r=new Map,n=new Map;for(let i of e)n.set(i.moduleName,i.load(t));await Promise.all(n.values());for(let[i,s]of n)r.set(i,await s);return r}static async getOpenSourceSoftwareLicenseInfo(){let e=[];for(let r of a.moduleLicenseTextProviders){let n=await r.getLicenseText();e.push(n);}let t=e.join(`
|
|
4
|
-
|
|
5
|
-
`);return new a$d(t)}async setFrameSource(e){let t=e!==this._frameSource;if(this._frameSource!==null&&(this._frameSource.context=null),this._frameSource=e!=null?e:null,e&&(e.context=this,await this.workerCommand("setFrameSource",{mirrorAxis:this.getMirrorAxisForFrameSource(e),isCameraFrameSource:f$1(e)})),await this.update([{type:"frameSourceState",newValue:this.frameSource}]),t)for(let r of this.listeners)r.didChangeFrameSource&&r.didChangeFrameSource(this,this._frameSource);}addListener(e){this.listeners.includes(e)||this.listeners.push(e);}async flushAnalytics(){await this.workerCommand("flushAnalytics",{});}removeListener(e){this.listeners.includes(e)&&this.listeners.splice(this.listeners.indexOf(e),1);}async addMode(e){this.modes.add(e),await e.attachedToContext(this),this.updateCameraFrameFlow(),await this.update([],{updateContext:!x(e)});}async removeMode(e){this.modes.delete(e),await e.detachedFromContext(),this.updateCameraFrameFlow(),await this.update([],{updateContext:!x(e)});}async setMode(e){this.modes.has(e)||(this.modes.clear(),this.modes.add(e),await e.attachedToContext(this),this.updateCameraFrameFlow(),await this.update());}async removeCurrentMode(){for(let e of this.modes)await e.detachedFromContext();this.modes.clear(),await this.update();}async removeAllModes(){let e=Array.from(this.modes);for(let t of e)await this.removeMode(t);}async dispose(){if(a.stateMachine.currentState!=="unconfigured")try{await a.stateMachine.executeAsyncTransition({targetState:"unconfigured",action:async()=>{g.instance().removeListener("cameraProperties",this.cameraPropertiesReportListener),g.instance().removeListener("cameraAccessError",this.cameraAccessErrorListener),this.unsubscribeToVisibilityChange(this.onVisibilityChangeListener);for(let e of this.modes)await e.detachedFromContext();this._view&&(await this._view.setContext(null),this._view=null),this.dataCaptureInstance&&(await this.dataCaptureInstance.terminateDataCaptureWorker(true).catch(()=>{}),this.dataCaptureInstance=void 0),this.webBatteryInterface&&(this.webBatteryInterface.dispose(),this.webBatteryInterface=void 0),a.deviceID="";},onSuccess:"unconfigured",onError:"unconfigured"});}catch(e){if(a.stateMachine.currentState==="unconfigured")return;throw e}finally{this.modes.clear(),this.listeners=[],this.components.length=0,this.updateListeners.clear(),this.pendingWorkerMessageListeners.clear(),this.delayedRegistration=false,this.highEndBlurryRecognition=false,this._frameHandlers.length=0,this.frameSource&&(this.frameSource.context=null,this._frameSource=null),g.instance().dispose(),this.licenseKey="",this.deviceName="",a$e();}}async applySettings(e){this.settings=e,await this.update();}toJSONObject(){var e,t;return {licenseKey:this.licenseKey,framework:this.framework,deviceName:this.deviceName,...this.runtimeEnvironment,modes:[...this.modes].filter(r=>!x(r)).map(r=>r.toJSONObject()),components:this.components.map(r=>r.toJSONObject()),frameSource:this.frameSource?this.frameSource.toJSONObject():null,settings:this.settings.toJSONObject(),view:(t=(e=this._view)==null?void 0:e.toJSONObject())!=null?t:null}}getView(){return this._view}async setView(e){return this._view=e,this.update([{type:"viewSet",newValue:e}])}async getAppName(){let e=null;if(a$a()){let t=await b$3();if((t==null?void 0:t.appName)==null||t.appName==="")throw new Error("Cannot retrieve electron appName. Did you set it up in package.json? https://www.electronjs.org/docs/latest/api/app#appgetname");e=t.appName;}return e}urlToHostname(e){try{return new URL(e!=null?e:"").hostname}catch{return ""}}getParentDomain(){var t;let e="";return parent!==window&&(e||(e=this.urlToHostname((t=location.ancestorOrigins)==null?void 0:t[0])),e||(e=this.urlToHostname(document.referrer)),e||(e="")),e.startsWith("[")&&e.endsWith("]")&&(e=e.slice(1,-1)),e}async createContext(){this.webBatteryInterface=await a$f.create();let e=this.webBatteryInterface.getBatteryInfo();await this.workerCommand("createContext",{context:this.toJSONObject(),deviceId:a.deviceID,delayedRegistration:this.delayedRegistration,highEndBlurryRecognition:this.highEndBlurryRecognition,appName:await this.getAppName(),parentDomain:this.getParentDomain(),isTablet:b$1.isTablet(),batteryInfo:e}),this.webBatteryInterface.addBatteryChangeListener(this.batteryChangeListener),this.subscribeToWorkerMessages(this.onWorkerMessageListener),this.subscribeToCameraManagerEvents(),this.subscribeToVisibilityChange(this.onVisibilityChangeListener),this._view!=null&&await this.setView(this._view),this.frameSource!=null&&await this.setFrameSource(this.frameSource);}subscribeToVisibilityChange(e){document.addEventListener("visibilitychange",e);}unsubscribeToVisibilityChange(e){document.removeEventListener("visibilitychange",e);}async requestFrameData(e){return this.workerCommand("requestFrameData",{frameId:e})}performanceMark(e){a$g(globalThis.performance)&&typeof globalThis.performance.mark=="function"&&performance.mark(e);}async sendFrameToProcessor(e){var n,i;let t=e instanceof ImageData?{data:e.data,width:e.width,height:e.height,frameId:(n=e.frameId)!=null?n:e$1(),colorType:(i=e.colorType)!=null?i:"RGBA"}:e,r=await this.sendFrameToHandlers(t);return t.data=r.capture.data,r.skip?r.capture:(this.performanceMark("processFrameBeforeSDC"),this.sendFrameToSDC(t))}async sendFrameToHandlers(e){for(let t of this._frameHandlers)if((await t(e)).action==="skip")return {skip:true,capture:e};return {skip:false,capture:e}}async sendFrameToSDC(e){return this.workerCommand("processFrame",e,[e.data.buffer])}registerFrameHandler(e){this._frameHandlers.includes(e)||this._frameHandlers.push(e);}unregisterFrameHandler(e){this._frameHandlers.includes(e)&&this._frameHandlers.splice(this._frameHandlers.indexOf(e),1);}onBatteryChange(e){this.workerCommand("updateBatteryInfo",{batteryInfo:e});}onVisibilityChange(){this.workerCommand("documentVisibility",{state:document.visibilityState});}getImageConverterInstance(e){return this._asyncImageConverterInstance==null&&(this._asyncImageConverterInstance=new a$h(e)),this._asyncImageConverterInstance}onWorkerMessage(e){if(e.type==="contextDidChangeStatus"){e.payload.isValid||a$3.error(e.payload);for(let t of this.listeners)t.didChangeStatus&&t.didChangeStatus(this,a$i.fromJSON(e.payload));}if(e.type==="didStartObservingContext")for(let t of this.listeners)t.didStartObservingContext&&t.didStartObservingContext(this);e.type==="onFrameProcessingFinished"&&this.performanceMark("processFrameAfterSDC"),e.type==="convertToJPEG"&&this.convertImageToJPEG(e);}async convertImageToJPEG(e){let{imageId:t,width:r,height:n,data:i,planes:s,orientation:o,quality:u}=e,c={getWidth:()=>r,getHeight:()=>n,getPlanes:()=>s,toBitmap:()=>i,getBitmapRepresentationFromYUV:()=>{throw new Error("Not implemented")},deepCopy:()=>{throw new Error("Not implemented")}},l=await this.getImageConverterInstance({quality:u}).convertToJpeg(c,o);return this.workerCommand("convertToJPEGResult",{imageId:t,result:l})}subscribeToCameraManagerEvents(){g.instance().addListener("cameraProperties",this.cameraPropertiesReportListener),g.instance().addListener("cameraAccessError",this.cameraAccessErrorListener);}async reportCameraProperties(e){return this.workerCommand("reportCameraProperties",e)}onCameraAccessError(e){for(let t of this.listeners)t.didChangeStatus&&t.didChangeStatus(this,a$i.fromJSON({code:33794,isValid:true,message:typeof(e==null?void 0:e.toString)=="function"?e.toString():"Unknown error"}));}async update(e=[],{updateContext:t=true}={}){var r,n;t&&await this.updateContext();for(let i of e){switch(i.type){case "frameSourceState":{await((r=this._view)==null?void 0:r.onFrameSourceChange(this.frameSource));break}case "singleImageModeUploaderSettings":{(n=this._view)==null||n.onSingleImageUploaderSettingsChange(i.newValue);break}case "addOverlay":{await this.addNativeOverlay(i.newValue);break}case "removeOverlay":{await this.removeNativeOverlay(i.newValue);break}}for(let s of this.updateListeners){let o=s(i);o instanceof Promise&&await o;}}}async updateContext(){await this.workerCommand("updateContext",{context:this.toJSONObject(),...this.getViewInfo()}).catch(e=>a$3.warn("Error while updating context:",e,this.toJSONObject()));}getViewInfo(){return this._view!=null?{view:{width:this._view.width,height:this._view.height,visible:this._view.width>0&&this._view.height>0,orientation:this._view.orientation}}:{view:null}}getMirrorAxisForFrameSource(e){let t="None";return f$1(e)&&e.getMirrorImageEnabled()&&(t="Y"),t}async addComponent(e){if(!this.components.includes(e))return this.components.push(e),e._context=this,this.update()}async addNativeOverlay(e){if(G(e))return this.workerCommand("addNativeOverlay",{overlayHandle:e[a$j]})}async removeNativeOverlay(e){if(G(e))return this.workerCommand("removeNativeOverlay",{overlayHandle:e[a$j]})}subscribeToWorkerMessages(e){this.dataCaptureInstance?this.dataCaptureInstance.addWorkerListener(e):this.pendingWorkerMessageListeners.add(e);}unsubscribeToWorkerMessages(e){this.dataCaptureInstance&&this.dataCaptureInstance.removeWorkerListener(e),this.pendingWorkerMessageListeners.delete(e);}hasEnabledMode(){return [...this.modes].some(e=>e.isEnabled())}updateCameraFrameFlow(){let e=[...this.modes].some(t=>t._synchronousFrameFlow===true);g.instance().setFrameHandling(e);}async isFeatureSupported(e){return (await this.workerCommand("isFeatureSupported",{feature:e})).supported}};a.deviceID="",a.stateMachine=new a$1("unconfigured",Q),a.mainDataCaptureLoader=void 0,a.dataCaptureLoaders=new Map,a.libraryLocation=void 0,a.userLicenseKey=null,a.capabilityInfo=void 0,c([v],a.prototype,"setFrameSource",1),c([v],a.prototype,"addMode",1),c([v],a.prototype,"removeMode",1),c([v],a.prototype,"setMode",1),c([v],a.prototype,"removeCurrentMode",1),c([v],a.prototype,"isFeatureSupported",1);var f=a;var b=class{constructor(e=f,t=a$3,r=globalThis.fetch.bind(globalThis)){this.staticContext=f;this.staticContext=e,this.logger=t,this.fetch=r;}get workerCommand(){var e;return (e=this.staticContext.mainDataCaptureLoader)==null?void 0:e.workerCommand.bind(this.staticContext.mainDataCaptureLoader)}async getLicenseText(){var i,s;let e=this.staticContext.stateMachine.currentState;if(e==="unconfigured"||e==="configuring")return this.logger.warn('You must call "DataCaptureContext.forLicenseKey" before retrieving open source license text info.'),"";let t=new URL(`${((i=this.staticContext.libraryLocation)!=null?i:"").replace(/\/$/,"")}/license/web-core-license.txt`),[r,n]=await Promise.all([(s=this.workerCommand)==null?void 0:s.call(this,"getOpenSourceSoftwareLicenseInfo",{}),this.fetchWebLicenseText(t.toString())]);return [r==null?void 0:r.licenseText,n].filter(o=>o!=null).join(`
|
|
6
|
-
`)}async fetchWebLicenseText(e){return this.fetch(e,{mode:"cors",credentials:"include",headers:{"Content-Type":"text/plain"}}).then(async t=>{if(!t.ok)throw new Error(`${t.status} ${t.statusText}`);return t.text()}).catch(t=>(this.logger.warn(`Failed to fetch license from ${e}: ${t.toString()}`),null))}};export{b as a,f as b};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import {a as a$1}from'./chunk-XR65N6EG.js';import {a as a$2}from'./chunk-QCZSSQAQ.js';var r=Promise.resolve(),u=false,a=false,t=false,o,l=1500,d="";async function S(e){if(o==null)return;u=true;let n;try{let i=new Promise((f,s)=>{n=setTimeout(()=>{a$1.debug(`IndexedDB database is blocked (timed out after ${l}ms). If you are running a Debug wasm build, things are slower and the timeout can be configured via IndexedDBBlockedTimeoutMs in localStorage (requires page reload).`),s(new a$2({name:"BlockedIndexedDB",message:"IndexedDB database is blocked"}));},l);}),w=new Promise((f,s)=>{o==null||o(e,c=>{c!=null?s(c):f();});});await Promise.race([w,i]);}finally{n!==void 0&&clearTimeout(n),u=false;}}async function b(e){return a?(t=e,r):(u?(a=true,t=e,r=r.then(async()=>(a=false,S(t)))):(t=e,r=S(e)),r)}function P(){FS.syncfs=((e,n)=>{b(e).then(()=>n(),i=>n(i));});}async function v(e){if(d=e.writableDataPath,l=e.indexedDBTimeoutMs,o=FS.syncfs,o==null)throw new Error("FS.syncfs is not available");P();try{FS.mkdir(d);}catch(n){if(n.code!=="EEXIST")throw o=void 0,n}try{FS.mount(IDBFS,{},d);}catch(n){throw o=void 0,n}return b(true)}export{v as a};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import {a as a$1}from'./chunk-IMXMNDKM.js';var a=class n{constructor(){this.type="singleImageUploader";this._settings=new a$1(null);this._desiredState="off";this.listeners=[];this._context=null;this._view=void 0;}static get default(){return new n}get desiredState(){return this._desiredState}get settings(){return this._settings}get context(){return this._context}set context(e){this._context=e;}set currentState(e){e!==this._currentState&&(this._currentState=e,this.notifyListeners(),this.notifyContext({type:"frameSourceState",newValue:e}));}get currentState(){return this._currentState}async switchToDesiredState(e){if(e==="on"){if(this.currentState==="on"||this.currentState==="starting")return}else if(this.currentState==="off"||this.currentState==="stopping")return;return this._desiredState=e,this.setCurrentState(e==="on"?"starting":"off")}addListener(e){e!=null&&(this.listeners.includes(e)||this.listeners.push(e));}removeListener(e){e!=null&&this.listeners.includes(e)&&this.listeners.splice(this.listeners.indexOf(e),1);}async applySettings(e){return this._settings=e,this.notifyContext({type:"singleImageModeUploaderSettings",newValue:this._settings})}toJSONObject(){return {type:this.type,settings:this.settings.toJSONObject(),desiredState:this.desiredState}}getCurrentState(){return this._currentState}async setCurrentState(e){if(e!==this._currentState)return this._currentState=e,this.notifyListeners(),this.notifyContext({type:"frameSourceState",newValue:e})}async notifyContext(e){if(this._context)return this._context.update([e])}notifyListeners(){for(let e of this.listeners)e.didChangeState&&e.didChangeState(this,this.currentState);}async processUploadedFileCapture(e){var t,r;await((t=this._context)==null?void 0:t.sendFrameToProcessor(e)),this.currentState="starting",(r=this._view)==null||r.onAfterImageProcessed();}addView(e){this._view=e;}};export{a};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
var i=(e=>(e.Minimal="minimal",e.Extended="extended",e))(i||{}),t=class{constructor(){this.type="tapToFocus";}toJSONObject(){return {type:this.type}}},r=class{constructor(){this.type="swipeToZoom";}toJSONObject(){return {type:this.type}}};export{i as a,t as b,r as c};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import {a}from'./chunk-GZCWMFWA.js';var t=new a(globalThis,{get:()=>globalThis.Module,set:e=>{globalThis.Module=e;}});function l(e){}export{t as a,l as b};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
var e;(o=>{function i(){let r="8.3.1";return r}o.sdkVersion=i;})(e||(e={}));export{e as a};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import {a}from'./chunk-LFJUGRQV.js';import {a as a$1}from'./chunk-XR65N6EG.js';var p=class{constructor(){this.cameraPool=new Set;}getOrCreate(a$1){var e;let{position:l,deviceId:n,label:s}=a$1,c=(e=a$1._isBestGuess)!=null?e:false;if(this.cameraPool.size===0)return this.push(a$1);let o=this.allCamerasNoDeviceId(),i=Array.from(this.cameraPool);if(n){let t=i.find(d=>d.deviceId===n);if(t)return t;if(o){let d=i.find(h=>h.position===l);if(d)return d[a].setDeviceId(n),d[a].setLabel(s),d}}if(c){let t=i.find(d=>d._isBestGuess);if(t)return t}if(o&&!n){let t=i.find(d=>d.position===l);if(t)return t}return this.push(a$1)}integrateIncomingVideoDevices(a$2){let l=Array.from(this.cameraPool),n=new Set,s=[...a$2].reverse();for(let o=s.length-1;o>=0;o--){let i=s[o];if(!i.deviceId)continue;let e=l.find(t=>t.deviceId===i.deviceId&&!n.has(t));e&&(e[a].setLabel(i.label),e.position=i.position,e[a].resetUnmappedState(),n.add(e),s.splice(o,1),this.debugLog("Updated pool camera by deviceId",{deviceId:e.deviceId,label:e.label,position:e.position}));}for(let o=s.length-1;o>=0;o--){let i=s[o],e=l.find(t=>t.position===i.position&&!n.has(t));e&&(e[a].setDeviceId(i.deviceId),e[a].setLabel(i.label),e[a].resetUnmappedState(),n.add(e),s.splice(o,1),this.debugLog("Updated pool camera by position",{deviceId:e.deviceId,label:e.label,position:e.position}));}if(s.length>0){let o=l.filter(i=>!n.has(i));if(o.length>0){for(let i=0;i<Math.min(s.length,o.length);i++){let e=o[i],t=s[i];e[a].setDeviceId(t.deviceId),e[a].setLabel(t.label),e.position=t.position,e[a].resetUnmappedState(),n.add(e),this.debugLog("Force updated pool camera",{deviceId:e.deviceId,label:e.label,position:e.position});}s.splice(0,Math.min(s.length,o.length));}for(let i of s)this.cameraPool.add(i),this.debugLog("Added new camera to pool",{deviceId:i.deviceId,label:i.label,position:i.position});}let c=l.filter(o=>!n.has(o));if(c.length>0){a$1.warn("Some cameras were created but could not be mapped to cameras found on the device. This happens when you create more Cameras than it exists. These cameras will not be accessible.");for(let o of c)a$1.warn("Removing non-updated camera:",{deviceId:o.deviceId,label:o.label,position:o.position}),o[a].markAsUnmappedToDeviceCameras(),this.cameraPool.delete(o);}this.debugLog("Camera pool state after reconciliation:"),this.logPool();}allCamerasNoDeviceId(){return Array.from(this.cameraPool).every(a=>a.deviceId==="")}get(){return Array.from(this.cameraPool)}clear(){this.cameraPool.clear();}push(a){return this.debugLog("adding camera to pool",JSON.stringify({deviceId:a.deviceId,position:a.position,label:a.label})),this.cameraPool.add(a),a}debugLog(...a){}logPool(){}dumpAsSimpleObjects(){return [...this.cameraPool].map(a=>({deviceId:a.deviceId,label:a.label,position:a.position}))}},f={[a]:{CameraPool:p}};var u=new p;export{f as a,u as b};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import {a}from'./chunk-33ZWDLU7.js';import {a as a$2}from'./chunk-UWBNF47P.js';import {a as a$1}from'./chunk-3A4KLILV.js';var e=class e extends a{static create(){return document.createElement(e.tag)}static register(){a$1({[e.tag]:e});}render(){return a$2`<style>${e.tag}{display:flex}</style><svg width="${this.size}" height="${this.heightForViewbox(32,32)}" viewBox="0 0 32 32" fill="none"><rect opacity="0.5" width="32" height="32" rx="16" fill="white"/><path d="M12.2881 21.1436C12.8965 21.1436 13.3066 20.7334 13.3066 20.1113V12.1406C13.3066 11.4297 12.8691 10.9854 12.1377 10.9854C11.7139 10.9854 11.3857 11.0469 10.9072 11.375L8.95215 12.7285C8.63086 12.9541 8.50781 13.1865 8.50781 13.501C8.50781 13.9385 8.81543 14.2393 9.23242 14.2393C9.44434 14.2393 9.58789 14.1914 9.7793 14.0547L11.2217 13.0498H11.2627V20.1113C11.2627 20.7334 11.6797 21.1436 12.2881 21.1436ZM16.9023 20.3164C17.2441 20.3164 17.4014 20.1865 17.6816 19.9131L19.3633 18.2451L21.0381 19.9062C21.3184 20.1865 21.4824 20.3164 21.8174 20.3164C22.2617 20.3164 22.6377 19.9746 22.6377 19.5234C22.6377 19.2158 22.4873 19.0176 22.2549 18.7852L20.5254 17.0488L22.2549 15.3057C22.4873 15.0732 22.6377 14.875 22.6377 14.5674C22.6377 14.1162 22.2617 13.7744 21.8174 13.7744C21.4824 13.7744 21.3184 13.9043 21.0381 14.1846L19.3633 15.8457L17.6885 14.1846C17.4082 13.9043 17.251 13.7744 16.9092 13.7744C16.4648 13.7744 16.0889 14.1162 16.0889 14.5674C16.0889 14.8818 16.2393 15.0732 16.4717 15.3057L18.1943 17.0488L16.4717 18.7852C16.2324 19.0244 16.0889 19.2158 16.0889 19.5234C16.0889 19.9814 16.458 20.3164 16.9023 20.3164Z" fill="white"/></svg>`}};e.tag="scandit-camera-fov-wide-icon";var r=e;export{r as a};
|