@scandit/web-datacapture-core 7.6.0-beta.1 → 7.6.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.
Files changed (208) hide show
  1. package/build/js/AimerViewfinder.js +1 -1
  2. package/build/js/Brush.js +1 -1
  3. package/build/js/{Camera-DYYZ5vW1.d.ts → Camera-C_4xOv5n.d.ts} +5 -8
  4. package/build/js/Camera.d.ts +1 -1
  5. package/build/js/Camera.js +1 -1
  6. package/build/js/CameraAccess.d.ts +1 -1
  7. package/build/js/CameraAccess.js +1 -1
  8. package/build/js/CameraRelated.d.ts +1 -1
  9. package/build/js/CameraRelated.js +1 -1
  10. package/build/js/Common.d.ts +1 -0
  11. package/build/js/Common.js +1 -1
  12. package/build/js/DataCaptureContext.d.ts +1 -1
  13. package/build/js/DataCaptureContext.js +1 -1
  14. package/build/js/DataCaptureContextRelated.d.ts +1 -1
  15. package/build/js/DataCaptureVersion.js +1 -1
  16. package/build/js/DataCaptureView.d.ts +1 -1
  17. package/build/js/DataCaptureView.js +1 -1
  18. package/build/js/DefaultViewClassnames.d.ts +0 -2
  19. package/build/js/DefaultViewClassnames.js +1 -1
  20. package/build/js/Defaults.d.ts +1 -1
  21. package/build/js/Defaults.js +1 -1
  22. package/build/js/Feedback.js +1 -1
  23. package/build/js/FrameData.d.ts +1 -1
  24. package/build/js/ImageFrameSource.d.ts +1 -1
  25. package/build/js/LaserlineViewfinder.js +1 -1
  26. package/build/js/LocationSelection.js +1 -1
  27. package/build/js/NotificationPresenter/NotificationBuilder.js +1 -1
  28. package/build/js/NotificationPresenter/index.d.ts +1 -1
  29. package/build/js/NotificationPresenter/index.js +1 -1
  30. package/build/js/NotificationPresenter/private/ConcreteNotificationPresenter.d.ts +1 -1
  31. package/build/js/NotificationPresenter/private/presets.d.ts +1 -1
  32. package/build/js/RectangularViewfinder.js +1 -1
  33. package/build/js/ScanditIcon.js +1 -1
  34. package/build/js/ScanditIconBuilder.js +1 -1
  35. package/build/js/SingleImageUploader.d.ts +1 -1
  36. package/build/js/SingleImageUploader.js +1 -1
  37. package/build/js/SingleImageUploaderSettings.js +1 -1
  38. package/build/js/Vibration.js +1 -1
  39. package/build/js/ViewControls.js +1 -1
  40. package/build/js/browserCompatibility.d.ts +6 -1
  41. package/build/js/browserCompatibility.js +1 -1
  42. package/build/js/browserHelper.d.ts +6 -0
  43. package/build/js/browserHelper.js +1 -1
  44. package/build/js/chunks/{chunk-O4TEQJ6H.js → chunk-26DQPDMK.js} +1 -1
  45. package/build/js/chunks/{chunk-FZWKZSE4.js → chunk-27Z5CYJL.js} +1 -1
  46. package/build/js/chunks/{chunk-3BBG6EVS.js → chunk-2HL2IEE2.js} +1 -1
  47. package/build/js/chunks/chunk-2LSO6JEZ.js +1 -0
  48. package/build/js/chunks/{chunk-RWDRTV7B.js → chunk-2QT7PJFA.js} +1 -1
  49. package/build/js/chunks/{chunk-7WQXUZB4.js → chunk-4TDWWHP2.js} +1 -1
  50. package/build/js/chunks/{chunk-O2SM24G4.js → chunk-4XTOUXDD.js} +1 -1
  51. package/build/js/chunks/{chunk-DAFXSVRW.js → chunk-5S5BT5PK.js} +1 -1
  52. package/build/js/chunks/{chunk-LEE5JACK.js → chunk-6NVWG2LP.js} +1 -1
  53. package/build/js/chunks/{chunk-LLU62JKU.js → chunk-6TG3MN7M.js} +1 -1
  54. package/build/js/chunks/{chunk-OPX62GWU.js → chunk-7ELPJFJV.js} +1 -1
  55. package/build/js/chunks/{chunk-JVZYXEYO.js → chunk-7TQID6JJ.js} +1 -1
  56. package/build/js/chunks/{chunk-2T36DQ52.js → chunk-AJE43LJ5.js} +1 -1
  57. package/build/js/chunks/{chunk-DCZONWJ2.js → chunk-AKDTQZ73.js} +1 -1
  58. package/build/js/chunks/chunk-BPNTTDTU.js +18 -0
  59. package/build/js/chunks/chunk-DFFYK2ZZ.js +1 -0
  60. package/build/js/chunks/chunk-DUFF6WVD.js +5 -0
  61. package/build/js/chunks/chunk-ECRBANIT.js +1 -0
  62. package/build/js/chunks/chunk-EKOWJS3E.js +1 -0
  63. package/build/js/chunks/{chunk-T5EUB6UG.js → chunk-FS52JIW4.js} +1 -1
  64. package/build/js/chunks/chunk-GC2ECHKL.js +2 -0
  65. package/build/js/chunks/{chunk-FUNKO4DC.js → chunk-GYQMVT7L.js} +1 -1
  66. package/build/js/chunks/{chunk-MCAVCIZT.js → chunk-GYSREBEJ.js} +1 -1
  67. package/build/js/chunks/{chunk-TSOWSKE3.js → chunk-H75G3H4R.js} +1 -1
  68. package/build/js/chunks/{chunk-FSWALUUO.js → chunk-K7MUTJWB.js} +1 -1
  69. package/build/js/chunks/{chunk-BMMGUF55.js → chunk-KK47T3R2.js} +1 -1
  70. package/build/js/chunks/{chunk-6G52QHDH.js → chunk-L3BBOGIY.js} +1 -1
  71. package/build/js/chunks/{chunk-EPP3SBHK.js → chunk-LISC6VSM.js} +1 -1
  72. package/build/js/chunks/{chunk-WSTE2OZY.js → chunk-M6SPJT67.js} +1 -1
  73. package/build/js/chunks/chunk-MQ6H2ORR.js +1 -0
  74. package/build/js/chunks/{chunk-5QETTOSS.js → chunk-N2GWO3EX.js} +1 -1
  75. package/build/js/chunks/chunk-NVK73TNL.js +1 -0
  76. package/build/js/chunks/{chunk-E67SHSCO.js → chunk-OQ4XCKFQ.js} +1 -1
  77. package/build/js/chunks/{chunk-EUZWZFRQ.js → chunk-PUP3NNKU.js} +1 -1
  78. package/build/js/chunks/{chunk-TAMEEK7W.js → chunk-Q5DQ3FTE.js} +1 -1
  79. package/build/js/chunks/{chunk-26YPQCXW.js → chunk-QR3AOFAD.js} +1 -1
  80. package/build/js/chunks/{chunk-I2LMKSHH.js → chunk-QUHRBS4G.js} +1 -1
  81. package/build/js/chunks/{chunk-PAZQUCPC.js → chunk-R3XUWVHG.js} +1 -1
  82. package/build/js/chunks/chunk-REEU55IG.js +11 -0
  83. package/build/js/chunks/{chunk-NA6AZIR5.js → chunk-S24T6WS2.js} +1 -1
  84. package/build/js/chunks/{chunk-JDX5TFXN.js → chunk-SJJGHQ52.js} +1 -1
  85. package/build/js/chunks/chunk-SM5S3DDC.js +1 -0
  86. package/build/js/chunks/{chunk-IVDD7PCI.js → chunk-TB4UKDDI.js} +1 -1
  87. package/build/js/chunks/chunk-TPQTY3KB.js +1 -0
  88. package/build/js/chunks/chunk-UCD6YLP3.js +2 -0
  89. package/build/js/chunks/chunk-UUD3OXOZ.js +1 -0
  90. package/build/js/chunks/chunk-VBNI76IP.js +1 -0
  91. package/build/js/chunks/{chunk-6YZS76QW.js → chunk-VBRTZG3W.js} +1 -1
  92. package/build/js/chunks/chunk-VQ7LLVHQ.js +1 -0
  93. package/build/js/chunks/{chunk-ZF7CDMAC.js → chunk-VT73QNQB.js} +1 -1
  94. package/build/js/chunks/{chunk-QM37NXPY.js → chunk-VW3DMTE7.js} +1 -1
  95. package/build/js/index.d.ts +2 -2
  96. package/build/js/index.js +3 -3
  97. package/build/js/private/AnchorPositions.js +1 -1
  98. package/build/js/private/CameraAccess.d.ts +1 -1
  99. package/build/js/private/CameraAccess.js +1 -1
  100. package/build/js/private/CameraManager.d.ts +1 -1
  101. package/build/js/private/CameraManager.js +1 -1
  102. package/build/js/private/CanvasDrawerWithMetrics.d.ts +1 -1
  103. package/build/js/private/CoreModuleLicenseTextProvider.d.ts +1 -1
  104. package/build/js/private/CustomLocationsView.js +1 -1
  105. package/build/js/private/DataCaptureContextRelated.d.ts +1 -1
  106. package/build/js/private/FrameReaders/FrameReader.d.ts +1 -1
  107. package/build/js/private/FrameReaders/FrameReaderAbstract.d.ts +1 -1
  108. package/build/js/private/FrameReaders/GrayScaleFrameReader.d.ts +1 -1
  109. package/build/js/private/FrameReaders/index.d.ts +1 -1
  110. package/build/js/private/GestureRecognizer/GestureRecognizer.js +1 -1
  111. package/build/js/private/GestureRecognizer/index.js +1 -1
  112. package/build/js/private/HtmlElementState.js +1 -1
  113. package/build/js/private/NormalizedConfigureOptions.d.ts +1 -1
  114. package/build/js/private/SingleImageUploaderView.js +1 -1
  115. package/build/js/private/ViewClassNames.d.ts +0 -2
  116. package/build/js/private/ViewClassNames.js +1 -1
  117. package/build/js/private/ViewControls+related.js +1 -1
  118. package/build/js/private/ViewControls_related.d.ts +1 -1
  119. package/build/js/private/ViewStyles.js +1 -1
  120. package/build/js/private/ViewsRegistry.d.ts +1 -1
  121. package/build/js/private/hybridDesktopPlatformHelpers.js +1 -1
  122. package/build/js/private/ui/atoms/AimerSvgIcon.js +1 -1
  123. package/build/js/private/ui/atoms/ArrowDownSvgIcon.js +1 -1
  124. package/build/js/private/ui/atoms/ArrowLeftSvgIcon.js +1 -1
  125. package/build/js/private/ui/atoms/ArrowRightSvgIcon.js +1 -1
  126. package/build/js/private/ui/atoms/ArrowUpSvgIcon.js +1 -1
  127. package/build/js/private/ui/atoms/ArrowsUp.js +1 -1
  128. package/build/js/private/ui/atoms/Backdrop.js +1 -1
  129. package/build/js/private/ui/atoms/CalendarExclamationMarkSvgIcon.js +1 -1
  130. package/build/js/private/ui/atoms/CameraSwitchReverseSvgIcon.js +1 -1
  131. package/build/js/private/ui/atoms/CameraSwitchSvgIcon.js +1 -1
  132. package/build/js/private/ui/atoms/Card.js +1 -1
  133. package/build/js/private/ui/atoms/CardList.js +1 -1
  134. package/build/js/private/ui/atoms/CheckSvgIcon.js +1 -1
  135. package/build/js/private/ui/atoms/ChevronDownSvgIcon.js +1 -1
  136. package/build/js/private/ui/atoms/ChevronLeftSvgIcon.js +1 -1
  137. package/build/js/private/ui/atoms/ChevronRightSvgIcon.js +1 -1
  138. package/build/js/private/ui/atoms/ChevronUpSvgIcon.js +1 -1
  139. package/build/js/private/ui/atoms/CrossSvgIcon.js +1 -1
  140. package/build/js/private/ui/atoms/Dot5xSvgIcon.js +1 -1
  141. package/build/js/private/ui/atoms/ExclamationMarkSvgIcon.js +1 -1
  142. package/build/js/private/ui/atoms/GlassSvgIcon.js +1 -1
  143. package/build/js/private/ui/atoms/HandLensCheckSvgIcon.js +1 -1
  144. package/build/js/private/ui/atoms/KeyboardSvgIcon.js +1 -1
  145. package/build/js/private/ui/atoms/LowStockSvgIcon.js +1 -1
  146. package/build/js/private/ui/atoms/OnexSvgIcon.js +1 -1
  147. package/build/js/private/ui/atoms/PrinterSvgIcon.js +1 -1
  148. package/build/js/private/ui/atoms/ProgressBar.js +1 -1
  149. package/build/js/private/ui/atoms/QuestionMarkSvgIcon.js +1 -1
  150. package/build/js/private/ui/atoms/RestartSvgIcon.js +1 -1
  151. package/build/js/private/ui/atoms/RoundedCheckSvgIcon.js +1 -1
  152. package/build/js/private/ui/atoms/RoundedCrossSvgIcon.js +1 -1
  153. package/build/js/private/ui/atoms/RoundedExclamationMarkSvgIcon.js +1 -1
  154. package/build/js/private/ui/atoms/ShutterButton.js +1 -1
  155. package/build/js/private/ui/atoms/StarFilledSvgIcon.js +1 -1
  156. package/build/js/private/ui/atoms/StarHalfFilledSvgIcon.js +1 -1
  157. package/build/js/private/ui/atoms/StarOutlinedSvgIcon.js +1 -1
  158. package/build/js/private/ui/atoms/SvgIcon.js +1 -1
  159. package/build/js/private/ui/atoms/ToPickSvgIcon.js +1 -1
  160. package/build/js/private/ui/atoms/Toast.d.ts +3 -2
  161. package/build/js/private/ui/atoms/Toast.js +1 -1
  162. package/build/js/private/ui/atoms/TwoxSvgIcon.js +1 -1
  163. package/build/js/private/ui/atoms/WrongItemSvgIcon.js +1 -1
  164. package/build/js/private/ui/colors.js +1 -1
  165. package/build/js/private/ui/molecules/HintPresenter.d.ts +1 -1
  166. package/build/js/private/ui/molecules/HintPresenter.js +1 -1
  167. package/build/js/private/ui/molecules/LoadingOverlay.js +1 -1
  168. package/build/js/private/utils/AnimationSimplePolyfill.d.ts +59 -0
  169. package/build/js/private/utils/AnimationSimplePolyfill.js +1 -0
  170. package/build/js/private/utils/domIdFromValues.d.ts +18 -0
  171. package/build/js/private/utils/domIdFromValues.js +1 -0
  172. package/build/js/private/utils/finalizationRegistryPolyfill.d.ts +0 -5
  173. package/build/js/private/utils/index.d.ts +2 -0
  174. package/build/js/private/utils/index.js +1 -1
  175. package/build/js/private/utils/polyfillLoader.d.ts +25 -0
  176. package/build/js/private/utils/polyfillLoader.js +1 -0
  177. package/build/js/private/utils/replaceImagesInViewUtils.d.ts +1 -1
  178. package/build/js/private/utils/safeCancelAnimation.d.ts +53 -0
  179. package/build/js/private/utils/safeCancelAnimation.js +1 -0
  180. package/build/js/private/utils/structuredClonePolyfill.d.ts +15 -0
  181. package/build/js/private/utils/structuredClonePolyfill.js +1 -0
  182. package/build/js/private/utils/warnMultithreadingUnavailable.js +1 -1
  183. package/build/js/sdk.d.ts +1 -1
  184. package/build/js/worker/WorkerMain.d.ts +1 -1
  185. package/build/js/worker/WorkerMain.js +1 -1
  186. package/build/js/worker/coreCapture.inlineWorker.d.ts +1 -1
  187. package/build/js/worker/coreCapture.inlineWorker.js +1 -1
  188. package/build/js/worker/dataCaptureEngine.d.ts +1 -1
  189. package/build/js/worker/dataCaptureEngine.js +1 -1
  190. package/build/js/worker/dataCaptureLoader.d.ts +1 -1
  191. package/build/js/worker/dataCaptureWorkerRelated.d.ts +1 -1
  192. package/build/js/worker/index.d.ts +1 -1
  193. package/build/js/worker/index.js +1 -1
  194. package/package.json +1 -1
  195. package/build/js/chunks/chunk-5FUZURCZ.js +0 -1
  196. package/build/js/chunks/chunk-5LIWL2C4.js +0 -1
  197. package/build/js/chunks/chunk-77BBIAZE.js +0 -1
  198. package/build/js/chunks/chunk-CVRIZLTM.js +0 -2
  199. package/build/js/chunks/chunk-DT4PRB74.js +0 -1
  200. package/build/js/chunks/chunk-JKL2W65E.js +0 -1
  201. package/build/js/chunks/chunk-MUJ7NKAY.js +0 -1
  202. package/build/js/chunks/chunk-NKYVY76A.js +0 -5
  203. package/build/js/chunks/chunk-NMX4VHW2.js +0 -1
  204. package/build/js/chunks/chunk-SHODT6PR.js +0 -21
  205. package/build/js/chunks/chunk-VQ2HNQ6B.js +0 -1
  206. package/build/js/chunks/chunk-WAUGWWV3.js +0 -1
  207. package/build/js/chunks/chunk-ZC7QACB2.js +0 -11
  208. /package/build/js/chunks/{chunk-2DXPVHBJ.js → chunk-EZFXLKBC.js} +0 -0
@@ -1 +1 @@
1
- import {d}from'./chunk-AIC4H5KG.js';import {a as a$5}from'./chunk-G2BRTVN7.js';import {c as c$1,a as a$6}from'./chunk-4W2T3TLN.js';import {c}from'./chunk-UWLAKRB2.js';import {a as a$4}from'./chunk-ZE2WH3AH.js';import {a as a$2}from'./chunk-VQ2HNQ6B.js';import {a as a$1}from'./chunk-O7TZTIHO.js';import {a as a$3}from'./chunk-QCZSSQAQ.js';import {c as c$2,e}from'./chunk-42THCP2K.js';import {a}from'./chunk-XR65N6EG.js';var D=class D{constructor(e,t){this.hintPresenterV2=null;this.MAX_NUMBER_OF_IMAGES_IN_FRAME_DATA_POOL=10;this.redrawInterval=1e3/30;this.redrawRequests=[];this._isDrawLoopRunning=false;this.frameDataPool=new Map;this.lastFrameCounter=-1;this.poorMansBenchmarkLogs=false;this.writableDataPathStandard="/scandit_sync_folder";this.resourceFilesSubfolder="resources";this.performanceMetricsReporterTimer=void 0;this.performanceMetrics={frameDataPoolSize:0,processedFramesCount:0,redrawRequestsCount:0,actualRedrawsCount:0};this.gestureListener=null;this.webPlatformHintPresenter=null;this.moduleHandler=e,this.workerFunctions=t,this._loadProgressCallback=this._loadProgressCallback.bind(this),c(this.getWasmMetadata());}get Module(){return this.moduleHandler.get()}set isDrawLoopRunning(e){this._isDrawLoopRunning=e,!e&&typeof this.loopTimeoutId=="number"&&(clearTimeout(this.loopTimeoutId),this.loopTimeoutId=void 0);}get isDrawLoopRunning(){return this._isDrawLoopRunning}convertToLoadableFrameData(e){let t=this.getNextFrameId();this.frameDataPool.set(t,new Uint8ClampedArray(e.getFrameData()));let s=this.lastUsedModuleMirrorAxis==null?false:this.lastUsedModuleMirrorAxis!==this.Module.Axis.None;return {frameId:t,width:e.getWidth(),height:e.getHeight(),isFrameSourceMirrored:s}}createContext(e){var m,C,f,b,h;let t=this.getModeDeserializers(),s=c$1(location);(s==="localhost"||s==="127.0.0.1")&&navigator.userAgent.includes("Electron")&&e.appName!=null&&(s+=`-${e.appName}`),this.parentDomain=e.parentDomain,this.contextDeserializer=new this.Module.DataCaptureContextDeserializer(this.writableDataPath,e.deviceId,e.context.deviceModelName,s,this.parentDomain,t,e.delayedRegistration,e.highEndBlurryRecognition,this.resourcePath);let i=this.contextDeserializer.contextFromJson(JSON.stringify(e.context));if(i==null){let r=this.contextDeserializer.getLastError();throw new Error(`Could not create the context: ${r}`)}let a=i.getView();this.context=i.getContext(),i.delete();let d=this.Module.DataCaptureContextListener.extend("DataCaptureContextListener",{didChangeStatus:(r,o)=>{this.contextDidChangeStatus(JSON.parse(o.toJson())),r.delete();},didStartObservingContext:r=>{this.didStartObservingContext(),r.delete();},didStopObservingContext:r=>{r.delete();}}),p=this.Module.DataCaptureContextFrameListener.extend("DataCaptureContextFrameListener",{onObservationStarted:r=>{r.delete();},onObservationStopped:r=>{r.delete();},onFrameProcessingStarted:(r,o)=>{this.workerFunctions.postMessage({type:"onFrameProcessingStarted"}),o.delete(),r.delete();},onFrameProcessingFinished:(r,o)=>{this.workerFunctions.postMessage({type:"onFrameProcessingFinished"}),o.delete(),r.delete();},onFrameSkipped:(r,o)=>{this.workerFunctions.postMessage({type:"onFrameSkipped"}),o.delete(),r.delete();}}),g=this.Module.GestureRecognizer.extend("GestureRecognizer",{setGestureListener:(r,o)=>{var w;(w=this.gestureListener)==null||w.delete(),this.gestureListener=r.clone(),r.delete();}});(m=this.gestureRecognizer)==null||m.delete(),this.gestureRecognizer=new g;let u=new d;this.context.addListener(u),u.delete();let c=new p;this.context.addFrameListener(c),c.delete(),this.setView(a),(C=this.view)==null||C.setGestureRecognizer(this.gestureRecognizer);let M=this.Module.PlatformHintPresenter.extend("PlatformHintPresenter",{setHintPresenter:r=>{r.delete();},showToast:r=>{this.workerFunctions.postMessage({type:"showToast",payload:JSON.parse(r)});},hideToast:r=>{this.workerFunctions.postMessage({type:"hideToast",payload:JSON.parse(r)});},showGuidance:r=>{this.workerFunctions.postMessage({type:"showGuidance",payload:JSON.parse(r)});},hideGuidance:r=>{this.workerFunctions.postMessage({type:"hideGuidance",payload:JSON.parse(r)});},startUpdateTimer:r=>{this.workerFunctions.postMessage({type:"startUpdateTimer",payload:{duration:{unit:"ms",value:r}}});},stopUpdateTimer:()=>{this.workerFunctions.postMessage({type:"stopUpdateTimer"});}});(f=this.hintPresenterV2)==null||f.delete(),this.hintPresenterV2=null,(b=this.webPlatformHintPresenter)==null||b.delete(),this.webPlatformHintPresenter=null,this.webPlatformHintPresenter=new M,this.view&&(this.hintPresenterV2=new this.Module.HintPresenterV2(this.webPlatformHintPresenter),(h=this.view)==null||h.setHintPresenterV2(this.hintPresenterV2));}onTap(e){var t;(t=this.gestureListener)==null||t.onTap(JSON.stringify(e));}hintPresenterV2Update(){var e;(e=this.hintPresenterV2)==null||e.update();}startReportingPerformanceMetrics(){this.performanceMetricsReporterTimer==null&&(this.performanceMetricsReporterTimer=setInterval(()=>{this.reportPerformanceMetrics();for(let e of Object.keys(this.performanceMetrics))this.performanceMetrics[e]=0;},1e3));}async reportPerformanceMetrics(){this.workerFunctions.postMessage({type:"performanceMetricsReport",payload:{...this.performanceMetrics}});}deleteFrameData(e){this.frameDataPool.delete(e);}dispose(){var e,t,s,i;this.context.dispose(),this.frameDataPool.clear(),this.isDrawLoopRunning=false,this.lastFrameCounter=-1,(e=this.gestureRecognizer)==null||e.delete(),this.gestureRecognizer=null,(t=this.gestureListener)==null||t.delete(),this.gestureListener=null,(s=this.hintPresenterV2)==null||s.delete(),this.hintPresenterV2=null,(i=this.webPlatformHintPresenter)==null||i.delete(),this.webPlatformHintPresenter=null;}flushAnalytics(){this.context.flushAnalytics();}extractCentaurusLicense(e){return {payload:{centaurus:{licenseKey:this.Module.LicenseUtils[D.get3dPartyLicenseKeyMethodName](e)}}}}getModeDeserializers(){return new this.Module.VectorDataCaptureModeDeserializer}loadLibrary(e){return this.libraryLoadingPromise!=null?this.libraryLoadingPromise:(this.libraryLoadingPromise=this.setup(e),this.libraryLoadingPromise)}processFrame(e){var a;if(this.context==null)return {payload:e,transferables:[e.data.buffer]};let t=e.data,s=e.colorType==="GRAYSCALE"?this.Module.ImageBufferFormat.Grayscale8:this.Module.ImageBufferFormat.Rgba8888,i=this.Module.allocateUint8Array(t.byteLength);return this.Module.HEAPU8.set(t,i),(a=this.imageFrameSource)==null||a.outputFrame(i,e.width,e.height,s),{payload:e,transferables:[e.data.buffer]}}reportCameraProperties(e){this.context.setCameraProperties(e.deviceId,e.isFrontFacing,e.hasAutofocus);}requestFrameData(e){let t=this.frameDataPool.get(e);return t==null?{payload:{data:null}}:{payload:{data:t},transferables:[t.buffer]}}scheduleRedraw(e,t){this.addRedrawRequest(t),this.isDrawLoopRunning||this.startDrawLoop(e);}sendViewRefreshCommands(e){this.workerFunctions.postMessage({type:"draw",payload:e},[e.buffer]);}setFrameSource(e,t){var s;this.lastUsedModuleMirrorAxis=this.mapMirrorAxisOnModule(e),(s=this.imageFrameSource)==null||s.delete(),this.imageFrameSource=new this.Module.ImageBufferFrameSource(this.lastUsedModuleMirrorAxis,t,0),this.context.setFrameSource(this.imageFrameSource);}startDrawLoop(e){this.isDrawLoopRunning=true;let t=a=>this.redrawRequests.length>0&&this.redrawRequests[0]<=a,s=a=>{for(;this.redrawRequests.length>0&&this.redrawRequests[0]<=a;)this.redrawRequests.shift();},i=()=>{this.loopTimeoutId=setTimeout(()=>{if(!this.isDrawLoopRunning)return;let a=performance.now();if(t(a)){s(a),e.draw();let d=e.getDrawCommands();this.sendViewRefreshCommands(new Uint8Array(d));}i();},this.redrawInterval);};i();}updateContext(e){if(this.context!=null&&this.contextDeserializer!=null){e.view!=null&&!e.view.visible&&this.context.flushAnalytics();let t=this.onBeforeUpdateContextHook(e),s=this.contextDeserializer.updateContextFromJson(this.context,this.view,JSON.stringify(t.context));if(s==null){let a=this.contextDeserializer.getLastError();throw new Error(`Could not update the context: ${a}`)}this.context.delete(),this.context=s.getContext();let i=s.getView();s.delete(),i!=null&&t.view!=null&&i.setViewSize(t.view.width,t.view.height,t.view.orientation),!this.hintPresenterV2&&this.webPlatformHintPresenter&&(this.hintPresenterV2=new this.Module.HintPresenterV2(this.webPlatformHintPresenter)),i!=null&&this.hintPresenterV2&&i.setHintPresenterV2(this.hintPresenterV2),this.gestureRecognizer!=null&&(i==null||i.setGestureRecognizer(this.gestureRecognizer)),this.setView(i),a.debug("context updated",t);}}onBeforeUpdateContextHook(e){return e}onDocumentVisibilityChange(e){e==="hidden"&&this.context.flushAnalytics();}isFeatureSupported(e){return {payload:{supported:this.context.isFeatureSupported(e)}}}getViewfinderInfo(){var e,t;return {payload:{isDisplayingViewfinder:(t=(e=this.view)==null?void 0:e.isDisplayingViewfinder())!=null?t:false,rect:JSON.parse(this.view.getViewfinderRect())}}}getOpenSourceSoftwareLicenseInfo(){return {payload:{licenseText:this.Module.OpenSourceSoftwareLicenseInfo.getLicenseText()}}}getNextFrameId(){return this.lastFrameCounter++,this.lastFrameCounter>=this.MAX_NUMBER_OF_IMAGES_IN_FRAME_DATA_POOL&&(this.lastFrameCounter=0),this.lastFrameCounter}getWasmDynamicLibraries(e){return this.getWasmSideModuleFileName()==null?[]:[`${e.replace(/\/[^/]*$/,"/")}${this.getWasmSideModuleFileName()}`]}getWasmCoreExpectedHash(e,t){return t?e?globalThis.SDC_WASM_CORE_MT_SIMD_HASH:globalThis.SDC_WASM_CORE_MT_HASH:e?globalThis.SDC_WASM_CORE_SIMD_HASH:""}getWasmCoreFileName(e,t){return t?e?globalThis.SDC_WASM_CORE_MT_SIMD_FILE_NAME:globalThis.SDC_WASM_CORE_MT_FILE_NAME:e?globalThis.SDC_WASM_CORE_SIMD_FILE_NAME:""}getWasmMetadata(){return globalThis.WASM_METADATA}getWasmSideModuleFileName(){return ""}_loadProgressCallback(e){this.workerFunctions.postMessage({type:"loadLibraryProgress",payload:e});}addRedrawRequest(e){this.redrawRequests.push(Math.round(performance.now())+e),this.redrawRequests.sort((t,s)=>t-s);}contextDidChangeStatus(e){e.code===260?e.message=e.message.replace("domain name",`domain name (${c$1(location)})`):e.code===265&&(e.message=e.message.replace("domain name",`domain name (${this.parentDomain})`)),this.workerFunctions.postMessage({type:"contextDidChangeStatus",payload:e});}didStartObservingContext(){this.workerFunctions.postMessage({type:"didStartObservingContext"});}mapMirrorAxisOnModule(e){switch(e){case "None":return this.Module.Axis.None;case "X":return this.Module.Axis.X;case "Y":return this.Module.Axis.Y;default:return this.Module.Axis.None}}setView(e){this.view=e,this.setViewRefreshHandler(e),e==null&&(this.isDrawLoopRunning=false,this.sendViewRefreshCommands(new Uint8Array([])));}addNativeOverlay(e){a.warn("addNativeOverlay has not been implemented for this module",e);}removeNativeOverlay(e){a.warn("removeNativeOverlay has not been implemented for this module",e);}setViewRefreshHandler(e){if(e==null||e.isViewRefreshHandlerSet)return;let t=this.Module.NeedsRedrawDelegate.extend("NeedsRedrawDelegate",{setNeedsRedrawIn:this.scheduleRedraw.bind(this,e)}),s=new t;e.setNeedsRedrawDelegate(s),e.isViewRefreshHandlerSet=true;}setupDataDecoding(){let e=this.moduleHandler.get(),t=e.DataDecoding.extend("DataDecoding",{decode(s,i){try{let a=JSON.parse(i),d=[];for(let p of a){let g=new TextDecoder(p.ianaName,{fatal:true});d.push(g.decode(s.slice(p.startIndex,p.endIndex)));}return d.join("")}catch(a){return ""}}});e.setDataDecoding(new t);}start(e,t,s){e&&t&&(this.setupDataDecoding(),this.moduleHandler.get().callMain(),this.moduleHandler.get().__emscripten_proxy_main!==void 0||s());}getWritableDataPath(e){return e!=null?(a.debug(`IndexedDB database name override in use to recover from blocked standard database: ${e}`),e):this.writableDataPathStandard}numOfMBToPages(e){return Math.ceil(1024*e*1024/64/1024)}async setup({libraryLocation:e$1,locationPath:t,writableDataPathOverride:s,overrideThreadsSupport:i,overrideSimdSupport:a$7,verifyResponseHash:d$1,referredOrigin:p,fixedWasmMemory:g}){var x;let u=false,c=false;this.writableDataPath=this.getWritableDataPath(s),this.resourcePath=`${e$1}${this.resourceFilesSubfolder}/`,globalThis.path=t;let{resolve:M,reject:m,promise:C}=new a$1,f=a$2.sdkVersion();if(f==="")throw new a$3({name:"Invalid library version",message:"Library version is not defined or empty, cannot generate proper path to library files."});let[b,h]=await Promise.all([c$2(),e()]);i!=="auto"&&(h=i==="on"),a$7!=="auto"&&(b=a$7==="on");let r=this.getWasmCoreFileName(b,h),o=d(f,e$1,r),{jsURI:w,wasmURI:R}=o,H={instantiateWasm:(l,W)=>(a$6({importObject:l,wasmURI:R,expectedHash:this.getWasmCoreExpectedHash(b,h),verifyResponseHash:d$1,successCallback:W,progressCallback:this._loadProgressCallback,errorCallback:N=>{m(N);},referredOrigin:p}),{})},y=g===null?null:new WebAssembly.Memory({initial:this.numOfMBToPages(g),maximum:this.numOfMBToPages(300),shared:h});return y!==null&&a.log(a.Level.Debug,"Fixed wasmMemory set",y),this.moduleHandler.set({...y?{wasmMemory:y}:{},mainScriptUrlOrBlob:w,canvas:(x=this.workerFunctions.getOffscreenCanvas())!=null?x:{getContext:()=>null},...H,dynamicLibraries:this.getWasmDynamicLibraries(R),locateFile:l=>e$1+l,noInitialRun:true,preRun:[async()=>{try{await a$4({writableDataPath:this.writableDataPath});}catch(l){if(l.name==="BlockedIndexedDB"){m(l.toString());return}a.log(a.Level.Debug,"No IndexedDB support, some data will not be persisted:",l);}c=true,this.start(c,u,M);}],onMainComplete:()=>{if([u,c].includes(false)){a.log(a.Level.Warn,{runtimeLoaded:u,fileSystemSynced:c},"Both runtimeLoaded and fileSystemSynced should be true when calling onMainComplete"),m("onMainComplete has been called but runtime or file system was not ready.");return}M();},onRuntimeInitialized:()=>{u=true,this.start(c,u,M);},print:l=>{a.log(a.Level.Info,l);}}),await a$5(w,f)||m(`Couldn't retrieve Scandit Data Capture library at ${w}, did you configure the path for it correctly?`),C}};D.get3dPartyLicenseKeyMethodName=atob("Z2V0QmxpbmtJZExpY2Vuc2VLZXk=");var T=D;export{T as a};
1
+ import {a as a$4}from'./chunk-ZE2WH3AH.js';import {a as a$5}from'./chunk-G2BRTVN7.js';import {c as c$1,a as a$6}from'./chunk-4W2T3TLN.js';import {c}from'./chunk-UWLAKRB2.js';import {d}from'./chunk-AIC4H5KG.js';import {a as a$2}from'./chunk-VBNI76IP.js';import {a as a$1}from'./chunk-O7TZTIHO.js';import {a as a$3}from'./chunk-QCZSSQAQ.js';import {c as c$2,e}from'./chunk-42THCP2K.js';import {a}from'./chunk-XR65N6EG.js';var D=class D{constructor(e,t){this.hintPresenterV2=null;this.MAX_NUMBER_OF_IMAGES_IN_FRAME_DATA_POOL=10;this.redrawInterval=1e3/30;this.redrawRequests=[];this._isDrawLoopRunning=false;this.frameDataPool=new Map;this.lastFrameCounter=-1;this.poorMansBenchmarkLogs=false;this.writableDataPathStandard="/scandit_sync_folder";this.resourceFilesSubfolder="resources";this.performanceMetricsReporterTimer=void 0;this.performanceMetrics={frameDataPoolSize:0,processedFramesCount:0,redrawRequestsCount:0,actualRedrawsCount:0};this.gestureListener=null;this.webPlatformHintPresenter=null;this.moduleHandler=e,this.workerFunctions=t,this._loadProgressCallback=this._loadProgressCallback.bind(this),c(this.getWasmMetadata());}get Module(){return this.moduleHandler.get()}set isDrawLoopRunning(e){this._isDrawLoopRunning=e,!e&&typeof this.loopTimeoutId=="number"&&(clearTimeout(this.loopTimeoutId),this.loopTimeoutId=void 0);}get isDrawLoopRunning(){return this._isDrawLoopRunning}convertToLoadableFrameData(e){let t=this.getNextFrameId();this.frameDataPool.set(t,new Uint8ClampedArray(e.getFrameData()));let s=this.lastUsedModuleMirrorAxis==null?false:this.lastUsedModuleMirrorAxis!==this.Module.Axis.None;return {frameId:t,width:e.getWidth(),height:e.getHeight(),isFrameSourceMirrored:s}}createContext(e){var m,C,f,b,h;let t=this.getModeDeserializers(),s=c$1(location);(s==="localhost"||s==="127.0.0.1")&&navigator.userAgent.includes("Electron")&&e.appName!=null&&(s+=`-${e.appName}`),this.parentDomain=e.parentDomain,this.contextDeserializer=new this.Module.DataCaptureContextDeserializer(this.writableDataPath,e.deviceId,e.context.deviceModelName,s,this.parentDomain,t,e.delayedRegistration,e.highEndBlurryRecognition,this.resourcePath);let i=this.contextDeserializer.contextFromJson(JSON.stringify(e.context));if(i==null){let r=this.contextDeserializer.getLastError();throw new Error(`Could not create the context: ${r}`)}let a=i.getView();this.context=i.getContext(),i.delete();let d=this.Module.DataCaptureContextListener.extend("DataCaptureContextListener",{didChangeStatus:(r,o)=>{this.contextDidChangeStatus(JSON.parse(o.toJson())),r.delete();},didStartObservingContext:r=>{this.didStartObservingContext(),r.delete();},didStopObservingContext:r=>{r.delete();}}),p=this.Module.DataCaptureContextFrameListener.extend("DataCaptureContextFrameListener",{onObservationStarted:r=>{r.delete();},onObservationStopped:r=>{r.delete();},onFrameProcessingStarted:(r,o)=>{this.workerFunctions.postMessage({type:"onFrameProcessingStarted"}),o.delete(),r.delete();},onFrameProcessingFinished:(r,o)=>{this.workerFunctions.postMessage({type:"onFrameProcessingFinished"}),o.delete(),r.delete();},onFrameSkipped:(r,o)=>{this.workerFunctions.postMessage({type:"onFrameSkipped"}),o.delete(),r.delete();}}),g=this.Module.GestureRecognizer.extend("GestureRecognizer",{setGestureListener:(r,o)=>{var w;(w=this.gestureListener)==null||w.delete(),this.gestureListener=r.clone(),r.delete();}});(m=this.gestureRecognizer)==null||m.delete(),this.gestureRecognizer=new g;let u=new d;this.context.addListener(u),u.delete();let c=new p;this.context.addFrameListener(c),c.delete(),this.setView(a),(C=this.view)==null||C.setGestureRecognizer(this.gestureRecognizer);let M=this.Module.PlatformHintPresenter.extend("PlatformHintPresenter",{setHintPresenter:r=>{r.delete();},showToast:r=>{this.workerFunctions.postMessage({type:"showToast",payload:JSON.parse(r)});},hideToast:r=>{this.workerFunctions.postMessage({type:"hideToast",payload:JSON.parse(r)});},showGuidance:r=>{this.workerFunctions.postMessage({type:"showGuidance",payload:JSON.parse(r)});},hideGuidance:r=>{this.workerFunctions.postMessage({type:"hideGuidance",payload:JSON.parse(r)});},startUpdateTimer:r=>{this.workerFunctions.postMessage({type:"startUpdateTimer",payload:{duration:{unit:"ms",value:r}}});},stopUpdateTimer:()=>{this.workerFunctions.postMessage({type:"stopUpdateTimer"});}});(f=this.hintPresenterV2)==null||f.delete(),this.hintPresenterV2=null,(b=this.webPlatformHintPresenter)==null||b.delete(),this.webPlatformHintPresenter=null,this.webPlatformHintPresenter=new M,this.view&&(this.hintPresenterV2=new this.Module.HintPresenterV2(this.webPlatformHintPresenter),(h=this.view)==null||h.setHintPresenterV2(this.hintPresenterV2));}onTap(e){var t;(t=this.gestureListener)==null||t.onTap(JSON.stringify(e));}hintPresenterV2Update(){var e;(e=this.hintPresenterV2)==null||e.update();}startReportingPerformanceMetrics(){this.performanceMetricsReporterTimer==null&&(this.performanceMetricsReporterTimer=setInterval(()=>{this.reportPerformanceMetrics();for(let e of Object.keys(this.performanceMetrics))this.performanceMetrics[e]=0;},1e3));}async reportPerformanceMetrics(){this.workerFunctions.postMessage({type:"performanceMetricsReport",payload:{...this.performanceMetrics}});}deleteFrameData(e){this.frameDataPool.delete(e);}dispose(){var e,t,s,i;this.context.dispose(),this.frameDataPool.clear(),this.isDrawLoopRunning=false,this.lastFrameCounter=-1,(e=this.gestureRecognizer)==null||e.delete(),this.gestureRecognizer=null,(t=this.gestureListener)==null||t.delete(),this.gestureListener=null,(s=this.hintPresenterV2)==null||s.delete(),this.hintPresenterV2=null,(i=this.webPlatformHintPresenter)==null||i.delete(),this.webPlatformHintPresenter=null;}flushAnalytics(){this.context.flushAnalytics();}extractCentaurusLicense(e){return {payload:{centaurus:{licenseKey:this.Module.LicenseUtils[D.get3dPartyLicenseKeyMethodName](e)}}}}getModeDeserializers(){return new this.Module.VectorDataCaptureModeDeserializer}loadLibrary(e){return this.libraryLoadingPromise!=null?this.libraryLoadingPromise:(this.libraryLoadingPromise=this.setup(e),this.libraryLoadingPromise)}processFrame(e){var a;if(this.context==null)return {payload:e,transferables:[e.data.buffer]};let t=e.data,s=e.colorType==="GRAYSCALE"?this.Module.ImageBufferFormat.Grayscale8:this.Module.ImageBufferFormat.Rgba8888,i=this.Module.allocateUint8Array(t.byteLength);return this.Module.HEAPU8.set(t,i),(a=this.imageFrameSource)==null||a.outputFrame(i,e.width,e.height,s),{payload:e,transferables:[e.data.buffer]}}reportCameraProperties(e){this.context.setCameraProperties(e.deviceId,e.isFrontFacing,e.hasAutofocus);}requestFrameData(e){let t=this.frameDataPool.get(e);return t==null?{payload:{data:null}}:{payload:{data:t},transferables:[t.buffer]}}scheduleRedraw(e,t){this.addRedrawRequest(t),this.isDrawLoopRunning||this.startDrawLoop(e);}sendViewRefreshCommands(e){this.workerFunctions.postMessage({type:"draw",payload:e},[e.buffer]);}setFrameSource(e,t){var s;this.lastUsedModuleMirrorAxis=this.mapMirrorAxisOnModule(e),(s=this.imageFrameSource)==null||s.delete(),this.imageFrameSource=new this.Module.ImageBufferFrameSource(this.lastUsedModuleMirrorAxis,t,0),this.context.setFrameSource(this.imageFrameSource);}startDrawLoop(e){this.isDrawLoopRunning=true;let t=a=>this.redrawRequests.length>0&&this.redrawRequests[0]<=a,s=a=>{for(;this.redrawRequests.length>0&&this.redrawRequests[0]<=a;)this.redrawRequests.shift();},i=()=>{this.loopTimeoutId=setTimeout(()=>{if(!this.isDrawLoopRunning)return;let a=performance.now();if(t(a)){s(a),e.draw();let d=e.getDrawCommands();this.sendViewRefreshCommands(new Uint8Array(d));}i();},this.redrawInterval);};i();}updateContext(e){if(this.context!=null&&this.contextDeserializer!=null){e.view!=null&&!e.view.visible&&this.context.flushAnalytics();let t=this.onBeforeUpdateContextHook(e),s=this.contextDeserializer.updateContextFromJson(this.context,this.view,JSON.stringify(t.context));if(s==null){let a=this.contextDeserializer.getLastError();throw new Error(`Could not update the context: ${a}`)}this.context.delete(),this.context=s.getContext();let i=s.getView();s.delete(),i!=null&&t.view!=null&&i.setViewSize(t.view.width,t.view.height,t.view.orientation),!this.hintPresenterV2&&this.webPlatformHintPresenter&&(this.hintPresenterV2=new this.Module.HintPresenterV2(this.webPlatformHintPresenter)),i!=null&&this.hintPresenterV2&&i.setHintPresenterV2(this.hintPresenterV2),this.gestureRecognizer!=null&&(i==null||i.setGestureRecognizer(this.gestureRecognizer)),this.setView(i),a.debug("context updated",t);}}onBeforeUpdateContextHook(e){return e}onDocumentVisibilityChange(e){e==="hidden"&&this.context.flushAnalytics();}isFeatureSupported(e){return {payload:{supported:this.context.isFeatureSupported(e)}}}getViewfinderInfo(){var e,t;return {payload:{isDisplayingViewfinder:(t=(e=this.view)==null?void 0:e.isDisplayingViewfinder())!=null?t:false,rect:JSON.parse(this.view.getViewfinderRect())}}}getOpenSourceSoftwareLicenseInfo(){return {payload:{licenseText:this.Module.OpenSourceSoftwareLicenseInfo.getLicenseText()}}}getNextFrameId(){return this.lastFrameCounter++,this.lastFrameCounter>=this.MAX_NUMBER_OF_IMAGES_IN_FRAME_DATA_POOL&&(this.lastFrameCounter=0),this.lastFrameCounter}getWasmDynamicLibraries(e){return this.getWasmSideModuleFileName()==null?[]:[`${e.replace(/\/[^/]*$/,"/")}${this.getWasmSideModuleFileName()}`]}getWasmCoreExpectedHash(e,t){return t?e?globalThis.SDC_WASM_CORE_MT_SIMD_HASH:globalThis.SDC_WASM_CORE_MT_HASH:e?globalThis.SDC_WASM_CORE_SIMD_HASH:""}getWasmCoreFileName(e,t){return t?e?globalThis.SDC_WASM_CORE_MT_SIMD_FILE_NAME:globalThis.SDC_WASM_CORE_MT_FILE_NAME:e?globalThis.SDC_WASM_CORE_SIMD_FILE_NAME:""}getWasmMetadata(){return globalThis.WASM_METADATA}getWasmSideModuleFileName(){return ""}_loadProgressCallback(e){this.workerFunctions.postMessage({type:"loadLibraryProgress",payload:e});}addRedrawRequest(e){this.redrawRequests.push(Math.round(performance.now())+e),this.redrawRequests.sort((t,s)=>t-s);}contextDidChangeStatus(e){e.code===260?e.message=e.message.replace("domain name",`domain name (${c$1(location)})`):e.code===265&&(e.message=e.message.replace("domain name",`domain name (${this.parentDomain})`)),this.workerFunctions.postMessage({type:"contextDidChangeStatus",payload:e});}didStartObservingContext(){this.workerFunctions.postMessage({type:"didStartObservingContext"});}mapMirrorAxisOnModule(e){switch(e){case "None":return this.Module.Axis.None;case "X":return this.Module.Axis.X;case "Y":return this.Module.Axis.Y;default:return this.Module.Axis.None}}setView(e){this.view=e,this.setViewRefreshHandler(e),e==null&&(this.isDrawLoopRunning=false,this.sendViewRefreshCommands(new Uint8Array([])));}addNativeOverlay(e){a.warn("addNativeOverlay has not been implemented for this module",e);}removeNativeOverlay(e){a.warn("removeNativeOverlay has not been implemented for this module",e);}setViewRefreshHandler(e){if(e==null||e.isViewRefreshHandlerSet)return;let t=this.Module.NeedsRedrawDelegate.extend("NeedsRedrawDelegate",{setNeedsRedrawIn:this.scheduleRedraw.bind(this,e)}),s=new t;e.setNeedsRedrawDelegate(s),e.isViewRefreshHandlerSet=true;}setupDataDecoding(){let e=this.moduleHandler.get(),t=e.DataDecoding.extend("DataDecoding",{decode(s,i){try{let a=JSON.parse(i),d=[];for(let p of a){let g=new TextDecoder(p.ianaName,{fatal:true});d.push(g.decode(s.slice(p.startIndex,p.endIndex)));}return d.join("")}catch(a){return ""}}});e.setDataDecoding(new t);}start(e,t,s){e&&t&&(this.setupDataDecoding(),this.moduleHandler.get().callMain(),this.moduleHandler.get().__emscripten_proxy_main!==void 0||s());}getWritableDataPath(e){return e!=null?(a.debug(`IndexedDB database name override in use to recover from blocked standard database: ${e}`),e):this.writableDataPathStandard}numOfMBToPages(e){return Math.ceil(1024*e*1024/64/1024)}async setup({libraryLocation:e$1,locationPath:t,writableDataPathOverride:s,overrideThreadsSupport:i,overrideSimdSupport:a$7,verifyResponseHash:d$1,referredOrigin:p,fixedWasmMemory:g}){var x;let u=false,c=false;this.writableDataPath=this.getWritableDataPath(s),this.resourcePath=`${e$1}${this.resourceFilesSubfolder}/`,globalThis.path=t;let{resolve:M,reject:m,promise:C}=new a$1,f=a$2.sdkVersion();if(f==="")throw new a$3({name:"Invalid library version",message:"Library version is not defined or empty, cannot generate proper path to library files."});let[b,h]=await Promise.all([c$2(),e()]);i!=="auto"&&(h=i==="on"),a$7!=="auto"&&(b=a$7==="on");let r=this.getWasmCoreFileName(b,h),o=d(f,e$1,r),{jsURI:w,wasmURI:R}=o,H={instantiateWasm:(l,W)=>(a$6({importObject:l,wasmURI:R,expectedHash:this.getWasmCoreExpectedHash(b,h),verifyResponseHash:d$1,successCallback:W,progressCallback:this._loadProgressCallback,errorCallback:N=>{m(N);},referredOrigin:p}),{})},y=g===null?null:new WebAssembly.Memory({initial:this.numOfMBToPages(g),maximum:this.numOfMBToPages(300),shared:h});return y!==null&&a.log(a.Level.Debug,"Fixed wasmMemory set",y),this.moduleHandler.set({...y?{wasmMemory:y}:{},mainScriptUrlOrBlob:w,canvas:(x=this.workerFunctions.getOffscreenCanvas())!=null?x:{getContext:()=>null},...H,dynamicLibraries:this.getWasmDynamicLibraries(R),locateFile:l=>e$1+l,noInitialRun:true,preRun:[async()=>{try{await a$4({writableDataPath:this.writableDataPath});}catch(l){if(l.name==="BlockedIndexedDB"){m(l.toString());return}a.log(a.Level.Debug,"No IndexedDB support, some data will not be persisted:",l);}c=true,this.start(c,u,M);}],onMainComplete:()=>{if([u,c].includes(false)){a.log(a.Level.Warn,{runtimeLoaded:u,fileSystemSynced:c},"Both runtimeLoaded and fileSystemSynced should be true when calling onMainComplete"),m("onMainComplete has been called but runtime or file system was not ready.");return}M();},onRuntimeInitialized:()=>{u=true,this.start(c,u,M);},print:l=>{a.log(a.Level.Info,l);}}),await a$5(w,f)||m(`Couldn't retrieve Scandit Data Capture library at ${w}, did you configure the path for it correctly?`),C}};D.get3dPartyLicenseKeyMethodName=atob("Z2V0QmxpbmtJZExpY2Vuc2VLZXk=");var T=D;export{T as a};
@@ -0,0 +1 @@
1
+ import {a}from'./chunk-UUD3OXOZ.js';import {a as a$1}from'./chunk-LSZZVJ6B.js';function r(){let A=a$1`@keyframes scandit-rotation{0%{transform:rotate(0deg)}to{transform:rotate(1turn)}}.${a.CONTAINER_CLASS_NAME}{align-items:center;display:flex;flex-direction:column;height:100%;justify-content:center;overflow:hidden;position:relative;width:100%}.${a.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}`,i=a$1`.${a.PAINTBOARDS_CONTAINER_CLASS_NAME}{height:inherit;position:relative;width:100%}.${a.PAINTBOARD_CLASS_NAME}{aspect-ratio:16/9;background-color:#000;height:100%;min-height:1px;min-width:1px;position:relative;width:100%}.${a.PAINTBOARD_CLASS_NAME}.${a.PAINTBOARD_CLASS_NAME_STATE_ON}{aspect-ratio:auto}.${a.PAINTBOARD_CLASS_NAME} video{display:block;height:100%;object-fit:cover;transition:opacity .3s;width:100%}.${a.PAINTBOARD_CLASS_NAME} .${a.MIRRORED_CLASS_NAME}{transform:scaleX(-1)}.${a.PAINTBOARD_CLASS_NAME} .${a.CAMERA_RECOVERY_CLASS_NAME}{background-color:#000;cursor:pointer;z-index:5}.${a.PAINTBOARD_CLASS_NAME} .${a.CAMERA_RECOVERY_CLASS_NAME},.${a.PAINTBOARD_CLASS_NAME} .${a.ERROR_CLASS_NAME}{align-items:center;color:#fff;display:flex;height:100%;justify-content:center;left:0;position:absolute;top:0;width:100%}.${a.PAINTBOARD_CLASS_NAME} .${a.ERROR_CLASS_NAME}{background-color:#00000080;text-align:center;z-index:6}.${a.CAMERA_RECOVERY_CLASS_NAME}[hidden],.${a.ERROR_CLASS_NAME}[hidden]{display:none}.${a.PAINTBOARD_CLASS_NAME} canvas{height:100%;left:0;object-fit:cover;pointer-events:none;position:absolute;top:0;transition:opacity .3s;width:100%}`,o=a$1`.${a.PAINTBOARD_CLASS_NAME} .${a.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.PAINTBOARD_CLASS_NAME} .${a.SINGLE_IMAGE_UPLOADER_CONTAINER_CLASS_NAME} label{align-items:center;cursor:pointer;display:flex;flex-direction:column;justify-content:center}.${a.PAINTBOARD_CLASS_NAME} .${a.SINGLE_IMAGE_UPLOADER_CONTAINER_CLASS_NAME} label input[type=file]{position:absolute;top:-9999px}.${a.PAINTBOARD_CLASS_NAME}.${a.SINGLE_IMAGE_UPLOADER_CONTAINER_CLASS_NAME} label button{pointer-events:none}`,n=a$1`.${a.PAINTBOARD_CLASS_NAME} .${a.CONTROLS_CLASS_NAME}{display:flex;height:100%;left:0;pointer-events:none;position:absolute;top:0;width:100%}.${a.PAINTBOARD_CLASS_NAME} .${a.CONTROL_WIDGET_CLASS_NAME}-${a.TORCH_SWITCH_CONTROL_CLASS_NAME}{left:16px;top:24px}.${a.PAINTBOARD_CLASS_NAME} .${a.CONTROL_WIDGET_CLASS_NAME}-${a.CAMERA_SWITCH_CONTROL_CLASS_NAME}{right:16px;top:24px}.${a.PAINTBOARD_CLASS_NAME} .${a.CONTROL_WIDGET_CLASS_NAME}-${a.CAMERA_FOV_SWITCH_CONTROL_CLASS_NAME}{bottom:24px;right:24px}.${a.CONTROL_WIDGET_CLASS_NAME}{background-color:initial;background-repeat:no-repeat;border:none;cursor:pointer;height:32px;pointer-events:all;position:absolute;width:32px}.${a.CONTROL_WIDGET_CLASS_NAME}+.${a.CONTROL_WIDGET_CLASS_NAME}{margin-left:16px}`,_=a$1`.${a.FROZEN_FRAME}{height:100%;left:0;object-fit:cover;opacity:1;position:absolute;top:0;width:100%}.${a.FROZEN_FRAME}[hidden]{opacity:0;pointer-events:none;visibility:hidden}`;return [A,i,n,o,_]}export{r as a};
@@ -1 +1 @@
1
- import {a as a$1}from'./chunk-AUWF33RB.js';import {a}from'./chunk-JDX5TFXN.js';var o=class r{constructor(i,e){this._vibration=null;this._sound=null;this._vibration=i,this._sound=e;}static get defaultFeedback(){return new r(a.defaultVibration,a$1.defaultSound)}get vibration(){return this._vibration}get sound(){return this._sound}emit(){this.sound&&this.sound.play(),this.vibration&&this.vibration.vibrate();}toJSONObject(){let i={};return this.sound!==null&&(i.sound=this.sound.toJSONObject()),this.vibration!==null&&(i.vibration=this.vibration.toJSONObject()),i}};export{o as a};
1
+ import {a as a$1}from'./chunk-AUWF33RB.js';import {a}from'./chunk-SJJGHQ52.js';var o=class r{constructor(i,e){this._vibration=null;this._sound=null;this._vibration=i,this._sound=e;}static get defaultFeedback(){return new r(a.defaultVibration,a$1.defaultSound)}get vibration(){return this._vibration}get sound(){return this._sound}emit(){this.sound&&this.sound.play(),this.vibration&&this.vibration.vibrate();}toJSONObject(){let i={};return this.sound!==null&&(i.sound=this.sound.toJSONObject()),this.vibration!==null&&(i.vibration=this.vibration.toJSONObject()),i}};export{o as a};
@@ -0,0 +1 @@
1
+ var e=(o=>(o.Blob="blob",o.MediaDevices="mediaDevices",o.OffscreenCanvas="offscreenCanvas",o.HttpProtocol="httpProtocol",o.SecureContext="secureContext",o.UrlObject="urlObject",o.WebWorkers="webWorkers",o.WebAssembly="webAssembly",o.WebAssemblyErrorFree="webAssemblyErrorFree",o.WebGL="webGL",o.SharedArrayBuffer="sharedArrayBuffer",o.CrossOriginIsolated="crossOriginIsolated",o.AnimationApi="animationApi",o))(e||{});export{e as a};
@@ -1 +1 @@
1
- import {a as a$1}from'./chunk-GPJEB376.js';import {a as a$3}from'./chunk-QCZSSQAQ.js';import {a}from'./chunk-CVRIZLTM.js';import {a as a$2}from'./chunk-XR65N6EG.js';var q=(p=>(p.WorldFacing="worldFacing",p.UserFacing="userFacing",p))(q||{}),J=(c=>(c[c.ULTRA_HD=0]="ULTRA_HD",c[c.FULL_HD=1]="FULL_HD",c[c.HD=2]="HD",c[c.SD=3]="SD",c[c.NONE=4]="NONE",c))(J||{}),Q=(v=>(v.AUTO="auto",v.FOUR_TO_THREE="fourToThree",v.SIXTEEN_TO_NINE="sixteenToNine",v))(Q||{}),L;(l=>{let T=new Map([["DeviceCaptureError","AbortError"],["NotSupportedError","AbortError"],["ScreenCaptureError","AbortError"],["TabCaptureError","AbortError"],["TypeError","AbortError"],["InvalidStateError","NotAllowedError"],["MediaDeviceFailedDueToShutdown","NotAllowedError"],["MediaDeviceKillSwitchOn","NotAllowedError"],["PermissionDeniedError","NotAllowedError"],["PermissionDismissedError","NotAllowedError"],["DevicesNotFoundError","NotFoundError"],["SourceUnavailableError","NotReadableError"],["TrackStartError","NotReadableError"],["ConstraintNotSatisfiedError","OverconstrainedError"]]),P=["rear","back","r\xFCck","arri\xE8re","trasera","tr\xE1s","traseira","posteriore","\u540E\u9762","\u5F8C\u9762","\u80CC\u9762","\u540E\u7F6E","\u5F8C\u7F6E","\u80CC\u7F6E","\u0437\u0430\u0434\u043D\u0435\u0439","\u0627\u0644\u062E\u0644\u0641\u064A\u0629","\uD6C4","arka","achterzijde","\u0E2B\u0E25\u0E31\u0E07","baksidan","bagside","sau","bak","tylny","takakamera","belakang","\u05D0\u05D7\u05D5\u05E8\u05D9\u05EA","\u03C0\u03AF\u03C3\u03C9","spate","h\xE1ts\xF3","zadn\xED","darrere","posterior","zadn\xE1","\u0437\u0430\u0434\u043D\u044F","stra\u017Enja","belakang","\u092C\u0948\u0915"],p=new Set(["Desk View Camera","Schreibtischansicht-Kamera","Cam\xE9ra Desk\xA0View","C\xE1mara de Vista Cenital","C\xE2mara da Vista de Secret\xE1ria","Fotocamera di Panoramica Scrivania","\u684C\u4E0A\u89C6\u89D2\u76F8\u673A","\u30C7\u30B9\u30AF\u30D3\u30E5\u30FC\u30AB\u30E1\u30E9","\u041A\u0430\u043C\u0435\u0440\u0430 \u041E\u0431\u0437\u043E\u0440\u0430 \u0441\u0442\u043E\u043B\u0430","Masa G\xF6r\xFCnt\xFCs\xFC Kameras\u0131","Bureauweergave-camera","\u0643\u0627\u0645\u064A\u0631\u0627 \u0627\u0644\u0639\u0631\u0636 \u0627\u0644\u0631\u0623\u0633\u064A","\u0E01\u0E25\u0E49\u0E2D\u0E07\u0E14\u0E39\u0E14\u0E49\u0E32\u0E19\u0E2B\u0E19\u0E49\u0E32\u0E42\u0E15\u0E4A\u0E30","Bordsvisningskamera","Kamera til Visning af skrivebord","Camera Desk View","Bordvisning-kamera","Kamera w\xA0aplikacji Widok blatu","Ty\xF6p\xF6yt\xE4n\xE4kym\xE4n kamera","Kamera Tampilan Meja","\u05DE\u05E6\u05DC\u05DE\u05EA \u05F4\u05EA\u05E6\u05D5\u05D2\u05EA \u05E9\u05D5\u05DC\u05D7\u05DF\u05F4","\u039A\u03AC\u03BC\u03B5\u03C1\u03B1 \u03C4\u03B7\u03C2 \u03A0\u03C1\u03BF\u03B2\u03BF\u03BB\u03AE\u03C2 \u03B3\u03C1\u03B1\u03C6\u03B5\u03AF\u03BF\u03C5","Camer\u0103 Vizualizare birou","\xCDr\xF3asztal n\xE9zet kamer\xE1ja","Stoln\xED kamera","C\xE0mera de l\u2019app Vista de l\u2019Escriptori"]),v=new Set(["Front Camera","Frontkamera","Appareil photo avant","C\xE1mara frontal","C\xE2mera Frontal","C\xE2mara frontal","Fotocamera (anteriore)","\u524D\u7F6E\u76F8\u673A","\u524D\u7F6E\u76F8\u6A5F","\u524D\u9762\u30AB\u30E1\u30E9","\u041A\u0430\u043C\u0435\u0440\u0430 \u043D\u0430 \u043F\u0435\u0440\u0435\u0434\u043D\u0435\u0439 \u043F\u0430\u043D\u0435\u043B\u0438","\xD6n Kamera","Camera aan voorzijde","\u0627\u0644\u0643\u0627\u0645\u064A\u0631\u0627 \u0627\u0644\u0623\u0645\u0627\u0645\u064A\u0629","\u0E01\u0E25\u0E49\u0E2D\u0E07\u0E14\u0E49\u0E32\u0E19\u0E2B\u0E19\u0E49\u0E32","Kamera p\xE5 framsidan","Forsidekamera","Camera m\u1EB7t tr\u01B0\u1EDBc","Kamera foran","Przedni aparat","Etukamera","Kamera Depan","\u05DE\u05E6\u05DC\u05DE\u05D4 \u05E7\u05D3\u05DE\u05D9\u05EA","\u039C\u03C0\u03C1\u03BF\u03C3\u03C4\u03B9\u03BD\u03AE \u03BA\u03AC\u03BC\u03B5\u03C1\u03B1","Camer\u0103 fa\u021B\u0103","El\xFCls\u0151 kamera","P\u0159edn\xED fotoapar\xE1t","C\xE0mera frontal","Predn\xE1 kamera","\u041F\u0435\u0440\u0435\u0434\u043D\u044F \u043A\u0430\u043C\u0435\u0440\u0430","Prednja kamera","Kamera Depan","\u092B\u093C\u094D\u0930\u0902\u091F \u0915\u0948\u092E\u0930\u093E"]),x=new Set(["Back Camera","R\xFCckkamera","Cam\xE9ra arri\xE8re","C\xE1mara trasera","C\xE2mera Traseira","C\xE2mara traseira","Fotocamera (posteriore)","\u540E\u7F6E\u76F8\u673A","\u5F8C\u7F6E\u76F8\u6A5F","\u80CC\u9762\u30AB\u30E1\u30E9","\u041A\u0430\u043C\u0435\u0440\u0430 \u043D\u0430 \u0437\u0430\u0434\u043D\u0435\u0439 \u043F\u0430\u043D\u0435\u043B\u0438","Arka Kamera","Camera aan achterzijde","\u0627\u0644\u0643\u0627\u0645\u064A\u0631\u0627 \u0627\u0644\u062E\u0644\u0641\u064A\u0629","\u0E01\u0E25\u0E49\u0E2D\u0E07\u0E14\u0E49\u0E32\u0E19\u0E2B\u0E25\u0E31\u0E07","Kamera p\xE5 baksidan","Bagsidekamera","Camera m\u1EB7t sau","Kamera bak","Tylny aparat","Takakamera","Kamera Belakang","\u05DE\u05E6\u05DC\u05DE\u05D4 \u05D0\u05D7\u05D5\u05E8\u05D9\u05EA","\u03A0\u03AF\u03C3\u03C9 \u03BA\u03AC\u03BC\u03B5\u03C1\u03B1","Camer\u0103 spate","H\xE1ts\xF3 kamera","Zadn\xED fotoapar\xE1t","C\xE0mera posterior","Zadn\xE1 kamera","\u0417\u0430\u0434\u043D\u044F \u043A\u0430\u043C\u0435\u0440\u0430","Stra\u017Enja kamera","Kamera Belakang","\u092C\u0948\u0915 \u0915\u0948\u092E\u0930\u093E"]),c=new Set(["Back Dual Wide Camera","R\xFCckseitige Dual-Weitwinkelkamera","Double appareil photo grand angle arri\xE8re","C\xE1mara trasera dual con gran angular","C\xE2mera Dupla Grande-Angular Traseira","C\xE2mara grande angular dupla traseira","Fotocamera doppia con grandangolo (posteriore)","\u540E\u7F6E\u53CC\u5E7F\u89D2\u955C\u5934","\u5F8C\u7F6E\u96D9\u5EE3\u89D2\u76F8\u6A5F","\u80CC\u9762\u30C7\u30E5\u30A2\u30EB\u5E83\u89D2\u30AB\u30E1\u30E9","\u0417\u0430\u0434\u043D\u044F\u044F \u0434\u0432\u043E\u0439\u043D\u0430\u044F \u0448\u0438\u0440\u043E\u043A\u043E\u0443\u0433\u043E\u043B\u044C\u043D\u0430\u044F \u043A\u0430\u043C\u0435\u0440\u0430","\xC7ift Geni\u015F Kamera Arka Y\xFCz\xFC","\u0643\u0627\u0645\u064A\u0631\u0627 \u062E\u0644\u0641\u064A\u0629 \u0645\u0632\u062F\u0648\u062C\u0629 \u0639\u0631\u064A\u0636\u0629","\u0E01\u0E25\u0E49\u0E2D\u0E07\u0E04\u0E39\u0E48\u0E14\u0E49\u0E32\u0E19\u0E2B\u0E25\u0E31\u0E07\u0E21\u0E38\u0E21\u0E01\u0E27\u0E49\u0E32\u0E07","Dubbel vidvinkelkamera p\xE5 baksidan","Camera k\xE9p r\u1ED9ng m\u1EB7t sau","Dobbelt vidvinkelkamera bak","Tylny dwuobiektywowy aparat szerokok\u0105tny","Laajakulmainen kaksoistakakamera","Kamera Lebar Belakang Ganda","\u05DE\u05E6\u05DC\u05DE\u05D4 \u05DB\u05E4\u05D5\u05DC\u05D4 \u05E8\u05D7\u05D1\u05D4 \u05D0\u05D7\u05D5\u05E8\u05D9\u05EA","\u03A0\u03AF\u03C3\u03C9 \u03B4\u03B9\u03C0\u03BB\u03AE \u03B5\u03C5\u03C1\u03B5\u03AF\u03B1 \u03BA\u03AC\u03BC\u03B5\u03C1\u03B1","Camer\u0103 dubl\u0103 cu obiectiv superangular spate","H\xE1ts\xF3, kett\u0151s, sz\xE9les l\xE1t\xF3sz\xF6g\u0171 kamera","Zadn\xED du\xE1ln\xED \u0161iroko\xFAhl\xFD fotoapar\xE1t","C\xE0mera dual posterior amb gran angular","Zadn\xE1 du\xE1lna \u0161irokouhl\xE1 kamera","\u0417\u0430\u0434\u043D\u044F \u0437\u0434\u0432\u043E\u0454\u043D\u0430 \u0448\u0438\u0440\u043E\u043A\u043E\u043A\u0443\u0442\u043D\u0430 \u043A\u0430\u043C\u0435\u0440\u0430","Stra\u017Enja dvostruka \u0161iroka kamera","Dwikamera Lebar Belakang","\u092C\u0948\u0915 \u0921\u094D\u092F\u0941\u0905\u0932 \u0935\u093E\u0907\u0921 \u0915\u0948\u092E\u0930\u093E"]),O=new Set(["Back Ultra Wide Camera","R\xFCckseitige Ultra-Weitwinkelkamera","Appareil photo ultra grand angle arri\xE8re","C\xE1mara trasera con ultra gran angular","C\xE2mera Ultra-Angular Traseira","C\xE2mara ultra grande angular traseira","Fotocamera con ultra-grandangolo (posteriore)","\u540E\u7F6E\u8D85\u5E7F\u89D2\u76F8\u673A","\u5F8C\u7F6E\u8D85\u5EE3\u89D2\u76F8\u6A5F","\u80CC\u9762\u8D85\u5E83\u89D2\u30AB\u30E1\u30E9","\u0417\u0430\u0434\u043D\u044F\u044F \u0441\u0432\u0435\u0440\u0445\u0448\u0438\u0440\u043E\u043A\u043E\u0443\u0433\u043E\u043B\u044C\u043D\u0430\u044F \u043A\u0430\u043C\u0435\u0440\u0430","Ultra Geni\u015F Kamera Arka Y\xFCz\xFC","Ultrabrede camera aan achterzijde","\u0643\u0627\u0645\u064A\u0631\u0627 \u062E\u0644\u0641\u064A\u0629 \u0639\u0631\u064A\u0636\u0629 \u062C\u062F\u064B\u0627","\u0E01\u0E25\u0E49\u0E2D\u0E07\u0E14\u0E49\u0E32\u0E19\u0E2B\u0E25\u0E31\u0E07\u0E21\u0E38\u0E21\u0E01\u0E27\u0E49\u0E32\u0E07\u0E2D\u0E31\u0E25\u0E15\u0E23\u0E49\u0E32","Ultravidvinkelkamera p\xE5 baksidan","Ultravidvinkelkameraet p\xE5 bagsiden","Camera c\u1EF1c r\u1ED9ng m\u1EB7t sau","Ultravidvinkelkamera bak","Tylny aparat ultraszerokok\u0105tny","Ultralaajakulmainen takakamera","Kamera Ultra Lebar Belakang","\u05DE\u05E6\u05DC\u05DE\u05D4 \u05D0\u05D5\u05DC\u05D8\u05E8\u05D4 \u05E8\u05D7\u05D1\u05D4 \u05D0\u05D7\u05D5\u05E8\u05D9\u05EA","\u03A0\u03AF\u03C3\u03C9 \u03C5\u03C0\u03B5\u03C1\u03B5\u03C5\u03C1\u03B5\u03AF\u03B1 \u03BA\u03AC\u03BC\u03B5\u03C1\u03B1","Camer\u0103 cu obiectiv ultra\u2011superangular spate","H\xE1ts\xF3, ultrasz\xE9les l\xE1t\xF3sz\xF6g\u0171 kamera","Zadn\xED ultra \u0161iroko\xFAhl\xFD fotoapar\xE1t","C\xE0mera posterior amb ultra gran angular","Zadn\xE1 ultra\u0161irokouhl\xE1 kamera","\u0417\u0430\u0434\u043D\u044F \u043D\u0430\u0434\u0448\u0438\u0440\u043E\u043A\u043E\u043A\u0443\u0442\u043D\u0430 \u043A\u0430\u043C\u0435\u0440\u0430","Stra\u017Enja ultra \u0161iroka kamera","Kamera Ultralebar Belakang","\u092C\u0948\u0915 \u0905\u0932\u094D\u091F\u094D\u0930\u093E \u0935\u093E\u0907\u0921 \u0915\u0948\u092E\u0930\u093E"]),d,D=false;l.mainCameraForPositionOverridesOnDesktop=new Map,l.deviceIdToCameraObjects=new Map,l.inaccessibleDeviceIds=new Set;function ee(e,i){l.mainCameraForPositionOverridesOnDesktop.set(e,i);}l.setMainCameraForPositionOverridesOnDesktop=ee;function ae(){l.mainCameraForPositionOverridesOnDesktop.clear();}l.clearMainCameraForPositionOverridesOnDesktop=ae;function F(){return navigator.mediaDevices.getUserMedia.bind(navigator.mediaDevices)}function N(){if(typeof navigator.enumerateDevices=="function")return navigator.enumerateDevices.bind(navigator);if(typeof navigator.mediaDevices=="object"&&typeof navigator.mediaDevices.enumerateDevices=="function")return navigator.mediaDevices.enumerateDevices.bind(navigator.mediaDevices)}function S(){D=true;}function B(e){let i=e.toLowerCase();return P.some(a=>i.includes(a))}function w(e){return v.has(e)}l.isIOSFrontCameraLabel=w;function E(e){return x.has(e)}l.isIOSBackCameraLabel=E;function M(e){return c.has(e)}l.isIOSBackDualWideCameraLabel=M;function W(e){return O.has(e)}l.isIOSUltraWideBackCameraLabel=W;function I(e){var a;let i=e.message==="Invalid constraint"?"OverconstrainedError":(a=T.get(e.name))!=null?a:e.name;Object.defineProperty(e,"name",{value:i});}function K(e){if(e.length===0)return {areSomeCameraLabelsFilled:false,areAllCameraLabelsFilled:false,areAllCameraLabelsUnfilled:false};let i=e.every(r=>r.label!==""),a=e.every(r=>r.label==="");return {areSomeCameraLabelsFilled:!a&&!i,areAllCameraLabelsFilled:i,areAllCameraLabelsUnfilled:a}}function R(e,i){var a;return (a=l.mainCameraForPositionOverridesOnDesktop.get(i))!=null?a:e.find(n=>n.position===i)}function j(e,i){if(i==="worldFacing"){let a=e.find(r=>M(r.label));if(a!=null)return a;let n=e.find(r=>E(r.label));if(n!=null)return n}else {let a=e.find(n=>w(n.label));if(a!=null)return a}}function z(e,i){let{areSomeCameraLabelsFilled:a$1,areAllCameraLabelsUnfilled:n}=K(e);if(n)return e[i==="userFacing"?0:e.length-1];if(a$1){let r=e.filter(t=>t.position===i);return r.length===1?r[0]:r[i==="userFacing"?0:r.length-1]}if(a.getUserAgentInfo().getOS().name==="iOS"){let r=j(e,i);if(r)return r}return e.filter(r=>r.position===i).sort((r,t)=>r.label.localeCompare(t.label))[0]}function re(e,i){return a.isDesktopDevice()?R(e,i):z(e,i)}l.getMainCameraForPosition=re;function k(e,i){return e.unshift(e.splice(i,1)[0])}function ie(e,i){function a$1(t,o){let s=l.mainCameraForPositionOverridesOnDesktop.get(o);return s!=null&&t.includes(s)&&(t=t.filter(f=>f!==s),t.unshift(s)),t}let n=e.filter(t=>t.position==="userFacing"),r=e.filter(t=>t.position==="worldFacing");return a.isDesktopDevice()?(n=a$1(n,"userFacing"),r=a$1(r,"worldFacing")):e.every(t=>t.label==="")?r.reverse():(n.sort((t,o)=>t.label.localeCompare(o.label)),r.sort((t,o)=>t.label.localeCompare(o.label)),a.getUserAgentInfo().getOS().name==="iOS"&&(n.some((t,o)=>w(t.label)&&k(n,o)>=0),r.some((t,o)=>W(t.label)&&k(r,o)>=0),r.some((t,o)=>M(t.label)&&k(r,o)>=0)||r.some((t,o)=>E(t.label)&&k(r,o)>=0))),i==="userFacing"?[...n,...r]:[...r,...n]}l.sortCamerasForCameraPosition=ie;function _(e,i){let a=e.getVideoTracks();if(a.length>0){let n=a[0],r;typeof n.getSettings=="function"&&(r=n.getSettings(),r.facingMode!=null&&r.facingMode.length>0&&(i.position=r.facingMode==="environment"?"worldFacing":"userFacing"));let{label:t=""}=n;t.length>0&&(i.label=t);}}l.adjustCameraFromMediaStream=_;function H(e,i,a$1){if(l.deviceIdToCameraObjects.has(e.deviceId))return l.deviceIdToCameraObjects.get(e.deviceId);let{label:n="",deviceId:r}=e,t;return !a.isDesktopDevice()&&a$1.every(o=>o.label===""&&!l.deviceIdToCameraObjects.has(o.deviceId))?t=a$1.length===1||i+1<=Math.floor(a$1.length/2)?"userFacing":"worldFacing":t=B(n)?"worldFacing":"userFacing",{position:t,label:n,deviceId:r}}function V(e){let i=e.map((a,n,r)=>H(a,n,r)).map(a=>(a.deviceId!==""&&l.deviceIdToCameraObjects.set(a.deviceId,a),a)).filter(a=>!/\b(?:ir|infrared)\b/i.test(a.label)||/^IR UVC WebCam$/i.test(a.label.toUpperCase())).filter(a=>!p.has(a.label)).filter(a=>!l.inaccessibleDeviceIds.has(a.deviceId));if(!a.isDesktopDevice()&&i.length>1&&!i.some(a=>a.position==="worldFacing")){let a=i.length-1,n=i.map(r=>{let t=/\b(\d+)mp?\b/i.exec(r.label);return t!=null?Number.parseInt(t[1],10):Number.NaN});n.some(r=>Number.isNaN(r))||(a=n.lastIndexOf(Math.max(...n))),i[a].position="worldFacing";}return i}async function A(){if(d!=null&&d.length>0&&d.every(e=>e.label===""&&!l.deviceIdToCameraObjects.has(e.deviceId)))try{return await F()({video:true,audio:false})}catch(e){}}function G(e,i){var a,n;if(i.length>0&&e.length===i.length&&!i.every((r,t)=>e[t].deviceId===r.deviceId)){let r={};for(let[t,o]of e.entries()){let s=l.deviceIdToCameraObjects.get(o.deviceId);if(s==null||s.label!==((n=(a=i[t])==null?void 0:a.label)!=null?n:""))continue;let f=i[t].deviceId;r[s.deviceId]=f,l.inaccessibleDeviceIds.has(s.deviceId)&&l.inaccessibleDeviceIds.add(f),s.deviceId=f,l.deviceIdToCameraObjects.set(f,s);}a$2.log(a$2.Level.Debug,"Detected updated camera deviceId information and updated it accordingly",r);}}function Z(){typeof navigator.mediaDevices.addEventListener=="function"?navigator.mediaDevices.addEventListener("devicechange",S):navigator.mediaDevices.ondevicechange=S;}async function y(){let e,i=N();if(i)e=await i();else throw new a$1({fullSupport:false,scannerSupport:true,missingFeatures:["mediaDevices"]});return e.filter(a=>a.kind==="videoinput")}async function te(e=false,i=false){var r;let a$3=a.checkBrowserCompatibility();if(!a$3.fullSupport)throw new a$1(a$3);if(Z(),d==null||e||D){D=false;let t,o=d!=null?d:[];d=[];try{d=await y(),i||(t=await A(),t!=null&&(d=await y())),a$2.debug("Camera list (devices):",...d),d.length>0&&d.every(s=>s.deviceId==="")&&a$2.log(a$2.Level.Debug,"Incomplete camera information listed due to user permission denial, cameras will not be accessible"),G(o,d);}catch(s){throw I(s),s}finally{for(let s of (r=t==null?void 0:t.getVideoTracks())!=null?r:[])s.stop();}}let n=V(d);return a$2.log(a$2.Level.Debug,"Camera list (cameras): ",...n),[...n]}l.getCameras=te;async function Y(e){return a$2.debug("Attempt to access camera (parameters):",e.video),new Promise((i,a)=>{setTimeout(async()=>{try{let n=await F()(e);if(n==null){a(new a$3({name:"AbortError",message:"Cannot get stream from getUserMedia function."}));return}i(n);}catch(n){a(n);}},0);})}function X(e,i){let a={resizeMode:"none"};switch(e){case 0:return {...a,width:{min:2880,ideal:i==="fourToThree"?2880:3840,max:4096},height:{min:1800,ideal:2160,max:2400}};case 1:return {...a,width:{min:1440,ideal:i==="fourToThree"?1440:1920,max:2160},height:{min:900,ideal:1080,max:1440}};case 2:return {...a,width:{min:960,ideal:i==="fourToThree"?960:1280,max:1440},height:{min:480,ideal:720,max:960}};case 3:return {...a,width:{min:640,ideal:640,max:800},height:{min:360,ideal:i==="fourToThree"?480:360,max:640}};default:return {}}}l.getUserMediaVideoParameters=X;function $(e){e.deviceId!==""&&(a$2.log(a$2.Level.Debug,"Camera marked to be inaccessible:",e),l.inaccessibleDeviceIds.add(e.deviceId));}l.markCameraAsInaccessible=$;async function ne(e,i,a){a$2.log(a$2.Level.Debug,"Attempt to access camera (camera):",e);let n={audio:false,video:X(i,a)};e.deviceId===""?n.video.facingMode={ideal:e.position==="worldFacing"?"environment":"user"}:n.video.deviceId={exact:e.deviceId};try{let r=await Y(n);return _(r,e),r}catch(r){throw I(r),["OverconstrainedError","NotReadableError","NotAllowedError"].includes(r.name)||$(e),r}}l.accessCameraStream=ne;})(L||(L={}));export{q as a,J as b,Q as c,L as d};
1
+ import {a as a$1}from'./chunk-GPJEB376.js';import {a as a$3}from'./chunk-QCZSSQAQ.js';import {a}from'./chunk-UCD6YLP3.js';import {a as a$2}from'./chunk-XR65N6EG.js';var q=(p=>(p.WorldFacing="worldFacing",p.UserFacing="userFacing",p))(q||{}),J=(c=>(c[c.ULTRA_HD=0]="ULTRA_HD",c[c.FULL_HD=1]="FULL_HD",c[c.HD=2]="HD",c[c.SD=3]="SD",c[c.NONE=4]="NONE",c))(J||{}),Q=(v=>(v.AUTO="auto",v.FOUR_TO_THREE="fourToThree",v.SIXTEEN_TO_NINE="sixteenToNine",v))(Q||{}),L;(l=>{let T=new Map([["DeviceCaptureError","AbortError"],["NotSupportedError","AbortError"],["ScreenCaptureError","AbortError"],["TabCaptureError","AbortError"],["TypeError","AbortError"],["InvalidStateError","NotAllowedError"],["MediaDeviceFailedDueToShutdown","NotAllowedError"],["MediaDeviceKillSwitchOn","NotAllowedError"],["PermissionDeniedError","NotAllowedError"],["PermissionDismissedError","NotAllowedError"],["DevicesNotFoundError","NotFoundError"],["SourceUnavailableError","NotReadableError"],["TrackStartError","NotReadableError"],["ConstraintNotSatisfiedError","OverconstrainedError"]]),P=["rear","back","r\xFCck","arri\xE8re","trasera","tr\xE1s","traseira","posteriore","\u540E\u9762","\u5F8C\u9762","\u80CC\u9762","\u540E\u7F6E","\u5F8C\u7F6E","\u80CC\u7F6E","\u0437\u0430\u0434\u043D\u0435\u0439","\u0627\u0644\u062E\u0644\u0641\u064A\u0629","\uD6C4","arka","achterzijde","\u0E2B\u0E25\u0E31\u0E07","baksidan","bagside","sau","bak","tylny","takakamera","belakang","\u05D0\u05D7\u05D5\u05E8\u05D9\u05EA","\u03C0\u03AF\u03C3\u03C9","spate","h\xE1ts\xF3","zadn\xED","darrere","posterior","zadn\xE1","\u0437\u0430\u0434\u043D\u044F","stra\u017Enja","belakang","\u092C\u0948\u0915"],p=new Set(["Desk View Camera","Schreibtischansicht-Kamera","Cam\xE9ra Desk\xA0View","C\xE1mara de Vista Cenital","C\xE2mara da Vista de Secret\xE1ria","Fotocamera di Panoramica Scrivania","\u684C\u4E0A\u89C6\u89D2\u76F8\u673A","\u30C7\u30B9\u30AF\u30D3\u30E5\u30FC\u30AB\u30E1\u30E9","\u041A\u0430\u043C\u0435\u0440\u0430 \u041E\u0431\u0437\u043E\u0440\u0430 \u0441\u0442\u043E\u043B\u0430","Masa G\xF6r\xFCnt\xFCs\xFC Kameras\u0131","Bureauweergave-camera","\u0643\u0627\u0645\u064A\u0631\u0627 \u0627\u0644\u0639\u0631\u0636 \u0627\u0644\u0631\u0623\u0633\u064A","\u0E01\u0E25\u0E49\u0E2D\u0E07\u0E14\u0E39\u0E14\u0E49\u0E32\u0E19\u0E2B\u0E19\u0E49\u0E32\u0E42\u0E15\u0E4A\u0E30","Bordsvisningskamera","Kamera til Visning af skrivebord","Camera Desk View","Bordvisning-kamera","Kamera w\xA0aplikacji Widok blatu","Ty\xF6p\xF6yt\xE4n\xE4kym\xE4n kamera","Kamera Tampilan Meja","\u05DE\u05E6\u05DC\u05DE\u05EA \u05F4\u05EA\u05E6\u05D5\u05D2\u05EA \u05E9\u05D5\u05DC\u05D7\u05DF\u05F4","\u039A\u03AC\u03BC\u03B5\u03C1\u03B1 \u03C4\u03B7\u03C2 \u03A0\u03C1\u03BF\u03B2\u03BF\u03BB\u03AE\u03C2 \u03B3\u03C1\u03B1\u03C6\u03B5\u03AF\u03BF\u03C5","Camer\u0103 Vizualizare birou","\xCDr\xF3asztal n\xE9zet kamer\xE1ja","Stoln\xED kamera","C\xE0mera de l\u2019app Vista de l\u2019Escriptori"]),v=new Set(["Front Camera","Frontkamera","Appareil photo avant","C\xE1mara frontal","C\xE2mera Frontal","C\xE2mara frontal","Fotocamera (anteriore)","\u524D\u7F6E\u76F8\u673A","\u524D\u7F6E\u76F8\u6A5F","\u524D\u9762\u30AB\u30E1\u30E9","\u041A\u0430\u043C\u0435\u0440\u0430 \u043D\u0430 \u043F\u0435\u0440\u0435\u0434\u043D\u0435\u0439 \u043F\u0430\u043D\u0435\u043B\u0438","\xD6n Kamera","Camera aan voorzijde","\u0627\u0644\u0643\u0627\u0645\u064A\u0631\u0627 \u0627\u0644\u0623\u0645\u0627\u0645\u064A\u0629","\u0E01\u0E25\u0E49\u0E2D\u0E07\u0E14\u0E49\u0E32\u0E19\u0E2B\u0E19\u0E49\u0E32","Kamera p\xE5 framsidan","Forsidekamera","Camera m\u1EB7t tr\u01B0\u1EDBc","Kamera foran","Przedni aparat","Etukamera","Kamera Depan","\u05DE\u05E6\u05DC\u05DE\u05D4 \u05E7\u05D3\u05DE\u05D9\u05EA","\u039C\u03C0\u03C1\u03BF\u03C3\u03C4\u03B9\u03BD\u03AE \u03BA\u03AC\u03BC\u03B5\u03C1\u03B1","Camer\u0103 fa\u021B\u0103","El\xFCls\u0151 kamera","P\u0159edn\xED fotoapar\xE1t","C\xE0mera frontal","Predn\xE1 kamera","\u041F\u0435\u0440\u0435\u0434\u043D\u044F \u043A\u0430\u043C\u0435\u0440\u0430","Prednja kamera","Kamera Depan","\u092B\u093C\u094D\u0930\u0902\u091F \u0915\u0948\u092E\u0930\u093E"]),x=new Set(["Back Camera","R\xFCckkamera","Cam\xE9ra arri\xE8re","C\xE1mara trasera","C\xE2mera Traseira","C\xE2mara traseira","Fotocamera (posteriore)","\u540E\u7F6E\u76F8\u673A","\u5F8C\u7F6E\u76F8\u6A5F","\u80CC\u9762\u30AB\u30E1\u30E9","\u041A\u0430\u043C\u0435\u0440\u0430 \u043D\u0430 \u0437\u0430\u0434\u043D\u0435\u0439 \u043F\u0430\u043D\u0435\u043B\u0438","Arka Kamera","Camera aan achterzijde","\u0627\u0644\u0643\u0627\u0645\u064A\u0631\u0627 \u0627\u0644\u062E\u0644\u0641\u064A\u0629","\u0E01\u0E25\u0E49\u0E2D\u0E07\u0E14\u0E49\u0E32\u0E19\u0E2B\u0E25\u0E31\u0E07","Kamera p\xE5 baksidan","Bagsidekamera","Camera m\u1EB7t sau","Kamera bak","Tylny aparat","Takakamera","Kamera Belakang","\u05DE\u05E6\u05DC\u05DE\u05D4 \u05D0\u05D7\u05D5\u05E8\u05D9\u05EA","\u03A0\u03AF\u03C3\u03C9 \u03BA\u03AC\u03BC\u03B5\u03C1\u03B1","Camer\u0103 spate","H\xE1ts\xF3 kamera","Zadn\xED fotoapar\xE1t","C\xE0mera posterior","Zadn\xE1 kamera","\u0417\u0430\u0434\u043D\u044F \u043A\u0430\u043C\u0435\u0440\u0430","Stra\u017Enja kamera","Kamera Belakang","\u092C\u0948\u0915 \u0915\u0948\u092E\u0930\u093E"]),c=new Set(["Back Dual Wide Camera","R\xFCckseitige Dual-Weitwinkelkamera","Double appareil photo grand angle arri\xE8re","C\xE1mara trasera dual con gran angular","C\xE2mera Dupla Grande-Angular Traseira","C\xE2mara grande angular dupla traseira","Fotocamera doppia con grandangolo (posteriore)","\u540E\u7F6E\u53CC\u5E7F\u89D2\u955C\u5934","\u5F8C\u7F6E\u96D9\u5EE3\u89D2\u76F8\u6A5F","\u80CC\u9762\u30C7\u30E5\u30A2\u30EB\u5E83\u89D2\u30AB\u30E1\u30E9","\u0417\u0430\u0434\u043D\u044F\u044F \u0434\u0432\u043E\u0439\u043D\u0430\u044F \u0448\u0438\u0440\u043E\u043A\u043E\u0443\u0433\u043E\u043B\u044C\u043D\u0430\u044F \u043A\u0430\u043C\u0435\u0440\u0430","\xC7ift Geni\u015F Kamera Arka Y\xFCz\xFC","\u0643\u0627\u0645\u064A\u0631\u0627 \u062E\u0644\u0641\u064A\u0629 \u0645\u0632\u062F\u0648\u062C\u0629 \u0639\u0631\u064A\u0636\u0629","\u0E01\u0E25\u0E49\u0E2D\u0E07\u0E04\u0E39\u0E48\u0E14\u0E49\u0E32\u0E19\u0E2B\u0E25\u0E31\u0E07\u0E21\u0E38\u0E21\u0E01\u0E27\u0E49\u0E32\u0E07","Dubbel vidvinkelkamera p\xE5 baksidan","Camera k\xE9p r\u1ED9ng m\u1EB7t sau","Dobbelt vidvinkelkamera bak","Tylny dwuobiektywowy aparat szerokok\u0105tny","Laajakulmainen kaksoistakakamera","Kamera Lebar Belakang Ganda","\u05DE\u05E6\u05DC\u05DE\u05D4 \u05DB\u05E4\u05D5\u05DC\u05D4 \u05E8\u05D7\u05D1\u05D4 \u05D0\u05D7\u05D5\u05E8\u05D9\u05EA","\u03A0\u03AF\u03C3\u03C9 \u03B4\u03B9\u03C0\u03BB\u03AE \u03B5\u03C5\u03C1\u03B5\u03AF\u03B1 \u03BA\u03AC\u03BC\u03B5\u03C1\u03B1","Camer\u0103 dubl\u0103 cu obiectiv superangular spate","H\xE1ts\xF3, kett\u0151s, sz\xE9les l\xE1t\xF3sz\xF6g\u0171 kamera","Zadn\xED du\xE1ln\xED \u0161iroko\xFAhl\xFD fotoapar\xE1t","C\xE0mera dual posterior amb gran angular","Zadn\xE1 du\xE1lna \u0161irokouhl\xE1 kamera","\u0417\u0430\u0434\u043D\u044F \u0437\u0434\u0432\u043E\u0454\u043D\u0430 \u0448\u0438\u0440\u043E\u043A\u043E\u043A\u0443\u0442\u043D\u0430 \u043A\u0430\u043C\u0435\u0440\u0430","Stra\u017Enja dvostruka \u0161iroka kamera","Dwikamera Lebar Belakang","\u092C\u0948\u0915 \u0921\u094D\u092F\u0941\u0905\u0932 \u0935\u093E\u0907\u0921 \u0915\u0948\u092E\u0930\u093E"]),O=new Set(["Back Ultra Wide Camera","R\xFCckseitige Ultra-Weitwinkelkamera","Appareil photo ultra grand angle arri\xE8re","C\xE1mara trasera con ultra gran angular","C\xE2mera Ultra-Angular Traseira","C\xE2mara ultra grande angular traseira","Fotocamera con ultra-grandangolo (posteriore)","\u540E\u7F6E\u8D85\u5E7F\u89D2\u76F8\u673A","\u5F8C\u7F6E\u8D85\u5EE3\u89D2\u76F8\u6A5F","\u80CC\u9762\u8D85\u5E83\u89D2\u30AB\u30E1\u30E9","\u0417\u0430\u0434\u043D\u044F\u044F \u0441\u0432\u0435\u0440\u0445\u0448\u0438\u0440\u043E\u043A\u043E\u0443\u0433\u043E\u043B\u044C\u043D\u0430\u044F \u043A\u0430\u043C\u0435\u0440\u0430","Ultra Geni\u015F Kamera Arka Y\xFCz\xFC","Ultrabrede camera aan achterzijde","\u0643\u0627\u0645\u064A\u0631\u0627 \u062E\u0644\u0641\u064A\u0629 \u0639\u0631\u064A\u0636\u0629 \u062C\u062F\u064B\u0627","\u0E01\u0E25\u0E49\u0E2D\u0E07\u0E14\u0E49\u0E32\u0E19\u0E2B\u0E25\u0E31\u0E07\u0E21\u0E38\u0E21\u0E01\u0E27\u0E49\u0E32\u0E07\u0E2D\u0E31\u0E25\u0E15\u0E23\u0E49\u0E32","Ultravidvinkelkamera p\xE5 baksidan","Ultravidvinkelkameraet p\xE5 bagsiden","Camera c\u1EF1c r\u1ED9ng m\u1EB7t sau","Ultravidvinkelkamera bak","Tylny aparat ultraszerokok\u0105tny","Ultralaajakulmainen takakamera","Kamera Ultra Lebar Belakang","\u05DE\u05E6\u05DC\u05DE\u05D4 \u05D0\u05D5\u05DC\u05D8\u05E8\u05D4 \u05E8\u05D7\u05D1\u05D4 \u05D0\u05D7\u05D5\u05E8\u05D9\u05EA","\u03A0\u03AF\u03C3\u03C9 \u03C5\u03C0\u03B5\u03C1\u03B5\u03C5\u03C1\u03B5\u03AF\u03B1 \u03BA\u03AC\u03BC\u03B5\u03C1\u03B1","Camer\u0103 cu obiectiv ultra\u2011superangular spate","H\xE1ts\xF3, ultrasz\xE9les l\xE1t\xF3sz\xF6g\u0171 kamera","Zadn\xED ultra \u0161iroko\xFAhl\xFD fotoapar\xE1t","C\xE0mera posterior amb ultra gran angular","Zadn\xE1 ultra\u0161irokouhl\xE1 kamera","\u0417\u0430\u0434\u043D\u044F \u043D\u0430\u0434\u0448\u0438\u0440\u043E\u043A\u043E\u043A\u0443\u0442\u043D\u0430 \u043A\u0430\u043C\u0435\u0440\u0430","Stra\u017Enja ultra \u0161iroka kamera","Kamera Ultralebar Belakang","\u092C\u0948\u0915 \u0905\u0932\u094D\u091F\u094D\u0930\u093E \u0935\u093E\u0907\u0921 \u0915\u0948\u092E\u0930\u093E"]),d,D=false;l.mainCameraForPositionOverridesOnDesktop=new Map,l.deviceIdToCameraObjects=new Map,l.inaccessibleDeviceIds=new Set;function ee(e,i){l.mainCameraForPositionOverridesOnDesktop.set(e,i);}l.setMainCameraForPositionOverridesOnDesktop=ee;function ae(){l.mainCameraForPositionOverridesOnDesktop.clear();}l.clearMainCameraForPositionOverridesOnDesktop=ae;function F(){return navigator.mediaDevices.getUserMedia.bind(navigator.mediaDevices)}function N(){if(typeof navigator.enumerateDevices=="function")return navigator.enumerateDevices.bind(navigator);if(typeof navigator.mediaDevices=="object"&&typeof navigator.mediaDevices.enumerateDevices=="function")return navigator.mediaDevices.enumerateDevices.bind(navigator.mediaDevices)}function S(){D=true;}function B(e){let i=e.toLowerCase();return P.some(a=>i.includes(a))}function w(e){return v.has(e)}l.isIOSFrontCameraLabel=w;function E(e){return x.has(e)}l.isIOSBackCameraLabel=E;function M(e){return c.has(e)}l.isIOSBackDualWideCameraLabel=M;function W(e){return O.has(e)}l.isIOSUltraWideBackCameraLabel=W;function I(e){var a;let i=e.message==="Invalid constraint"?"OverconstrainedError":(a=T.get(e.name))!=null?a:e.name;Object.defineProperty(e,"name",{value:i});}function K(e){if(e.length===0)return {areSomeCameraLabelsFilled:false,areAllCameraLabelsFilled:false,areAllCameraLabelsUnfilled:false};let i=e.every(r=>r.label!==""),a=e.every(r=>r.label==="");return {areSomeCameraLabelsFilled:!a&&!i,areAllCameraLabelsFilled:i,areAllCameraLabelsUnfilled:a}}function R(e,i){var a;return (a=l.mainCameraForPositionOverridesOnDesktop.get(i))!=null?a:e.find(n=>n.position===i)}function j(e,i){if(i==="worldFacing"){let a=e.find(r=>M(r.label));if(a!=null)return a;let n=e.find(r=>E(r.label));if(n!=null)return n}else {let a=e.find(n=>w(n.label));if(a!=null)return a}}function z(e,i){let{areSomeCameraLabelsFilled:a$1,areAllCameraLabelsUnfilled:n}=K(e);if(n)return e[i==="userFacing"?0:e.length-1];if(a$1){let r=e.filter(t=>t.position===i);return r.length===1?r[0]:r[i==="userFacing"?0:r.length-1]}if(a.getUserAgentInfo().getOS().name==="iOS"){let r=j(e,i);if(r)return r}return e.filter(r=>r.position===i).sort((r,t)=>r.label.localeCompare(t.label))[0]}function re(e,i){return a.isDesktopDevice()?R(e,i):z(e,i)}l.getMainCameraForPosition=re;function k(e,i){return e.unshift(e.splice(i,1)[0])}function ie(e,i){function a$1(t,o){let s=l.mainCameraForPositionOverridesOnDesktop.get(o);return s!=null&&t.includes(s)&&(t=t.filter(f=>f!==s),t.unshift(s)),t}let n=e.filter(t=>t.position==="userFacing"),r=e.filter(t=>t.position==="worldFacing");return a.isDesktopDevice()?(n=a$1(n,"userFacing"),r=a$1(r,"worldFacing")):e.every(t=>t.label==="")?r.reverse():(n.sort((t,o)=>t.label.localeCompare(o.label)),r.sort((t,o)=>t.label.localeCompare(o.label)),a.getUserAgentInfo().getOS().name==="iOS"&&(n.some((t,o)=>w(t.label)&&k(n,o)>=0),r.some((t,o)=>W(t.label)&&k(r,o)>=0),r.some((t,o)=>M(t.label)&&k(r,o)>=0)||r.some((t,o)=>E(t.label)&&k(r,o)>=0))),i==="userFacing"?[...n,...r]:[...r,...n]}l.sortCamerasForCameraPosition=ie;function _(e,i){let a=e.getVideoTracks();if(a.length>0){let n=a[0],r;typeof n.getSettings=="function"&&(r=n.getSettings(),r.facingMode!=null&&r.facingMode.length>0&&(i.position=r.facingMode==="environment"?"worldFacing":"userFacing"));let{label:t=""}=n;t.length>0&&(i.label=t);}}l.adjustCameraFromMediaStream=_;function H(e,i,a$1){if(l.deviceIdToCameraObjects.has(e.deviceId))return l.deviceIdToCameraObjects.get(e.deviceId);let{label:n="",deviceId:r}=e,t;return !a.isDesktopDevice()&&a$1.every(o=>o.label===""&&!l.deviceIdToCameraObjects.has(o.deviceId))?t=a$1.length===1||i+1<=Math.floor(a$1.length/2)?"userFacing":"worldFacing":t=B(n)?"worldFacing":"userFacing",{position:t,label:n,deviceId:r}}function V(e){let i=e.map((a,n,r)=>H(a,n,r)).map(a=>(a.deviceId!==""&&l.deviceIdToCameraObjects.set(a.deviceId,a),a)).filter(a=>!/\b(?:ir|infrared)\b/i.test(a.label)||/^IR UVC WebCam$/i.test(a.label.toUpperCase())).filter(a=>!p.has(a.label)).filter(a=>!l.inaccessibleDeviceIds.has(a.deviceId));if(!a.isDesktopDevice()&&i.length>1&&!i.some(a=>a.position==="worldFacing")){let a=i.length-1,n=i.map(r=>{let t=/\b(\d+)mp?\b/i.exec(r.label);return t!=null?Number.parseInt(t[1],10):Number.NaN});n.some(r=>Number.isNaN(r))||(a=n.lastIndexOf(Math.max(...n))),i[a].position="worldFacing";}return i}async function A(){if(d!=null&&d.length>0&&d.every(e=>e.label===""&&!l.deviceIdToCameraObjects.has(e.deviceId)))try{return await F()({video:true,audio:false})}catch(e){}}function G(e,i){var a,n;if(i.length>0&&e.length===i.length&&!i.every((r,t)=>e[t].deviceId===r.deviceId)){let r={};for(let[t,o]of e.entries()){let s=l.deviceIdToCameraObjects.get(o.deviceId);if(s==null||s.label!==((n=(a=i[t])==null?void 0:a.label)!=null?n:""))continue;let f=i[t].deviceId;r[s.deviceId]=f,l.inaccessibleDeviceIds.has(s.deviceId)&&l.inaccessibleDeviceIds.add(f),s.deviceId=f,l.deviceIdToCameraObjects.set(f,s);}a$2.log(a$2.Level.Debug,"Detected updated camera deviceId information and updated it accordingly",r);}}function Z(){typeof navigator.mediaDevices.addEventListener=="function"?navigator.mediaDevices.addEventListener("devicechange",S):navigator.mediaDevices.ondevicechange=S;}async function y(){let e,i=N();if(i)e=await i();else throw new a$1({fullSupport:false,scannerSupport:true,missingFeatures:["mediaDevices"]});return e.filter(a=>a.kind==="videoinput")}async function te(e=false,i=false){var r;let a$3=a.checkBrowserCompatibility();if(!a$3.fullSupport)throw new a$1(a$3);if(Z(),d==null||e||D){D=false;let t,o=d!=null?d:[];d=[];try{d=await y(),i||(t=await A(),t!=null&&(d=await y())),a$2.debug("Camera list (devices):",...d),d.length>0&&d.every(s=>s.deviceId==="")&&a$2.log(a$2.Level.Debug,"Incomplete camera information listed due to user permission denial, cameras will not be accessible"),G(o,d);}catch(s){throw I(s),s}finally{for(let s of (r=t==null?void 0:t.getVideoTracks())!=null?r:[])s.stop();}}let n=V(d);return a$2.log(a$2.Level.Debug,"Camera list (cameras): ",...n),[...n]}l.getCameras=te;async function Y(e){return a$2.debug("Attempt to access camera (parameters):",e.video),new Promise((i,a)=>{setTimeout(async()=>{try{let n=await F()(e);if(n==null){a(new a$3({name:"AbortError",message:"Cannot get stream from getUserMedia function."}));return}i(n);}catch(n){a(n);}},0);})}function X(e,i){let a={resizeMode:"none"};switch(e){case 0:return {...a,width:{min:2880,ideal:i==="fourToThree"?2880:3840,max:4096},height:{min:1800,ideal:2160,max:2400}};case 1:return {...a,width:{min:1440,ideal:i==="fourToThree"?1440:1920,max:2160},height:{min:900,ideal:1080,max:1440}};case 2:return {...a,width:{min:960,ideal:i==="fourToThree"?960:1280,max:1440},height:{min:480,ideal:720,max:960}};case 3:return {...a,width:{min:640,ideal:640,max:800},height:{min:360,ideal:i==="fourToThree"?480:360,max:640}};default:return {}}}l.getUserMediaVideoParameters=X;function $(e){e.deviceId!==""&&(a$2.log(a$2.Level.Debug,"Camera marked to be inaccessible:",e),l.inaccessibleDeviceIds.add(e.deviceId));}l.markCameraAsInaccessible=$;async function ne(e,i,a){a$2.log(a$2.Level.Debug,"Attempt to access camera (camera):",e);let n={audio:false,video:X(i,a)};e.deviceId===""?n.video.facingMode={ideal:e.position==="worldFacing"?"environment":"user"}:n.video.deviceId={exact:e.deviceId};try{let r=await Y(n);return _(r,e),r}catch(r){throw I(r),["OverconstrainedError","NotReadableError","NotAllowedError"].includes(r.name)||$(e),r}}l.accessCameraStream=ne;})(L||(L={}));export{q as a,J as b,Q as c,L as d};
@@ -1 +1 @@
1
- import {d}from'./chunk-QM37NXPY.js';import {n}from'./chunk-77BBIAZE.js';var i=class e{constructor(r=d.Brush.fillColor,o=d.Brush.strokeColor,s=d.Brush.strokeWidth){this.fill={color:r},this.stroke={color:o,width:s};}static get transparent(){let r=n.fromRGBA(255,255,255,0);return new e(r,r,0)}get fillColor(){return this.fill.color}get strokeColor(){return this.stroke.color}get strokeWidth(){return this.stroke.width}static areEquals(r,o){return r==null||o==null?false:n.areEquals(r.fill.color,o.fill.color)&&n.areEquals(r.stroke.color,o.stroke.color)&&r.stroke.width===o.stroke.width}toJSONObject(){return {fill:{color:this.fillColor.toJSON()},stroke:{width:this.strokeWidth,color:this.strokeColor.toJSON()}}}static fromJSONObject(r){return new e(n.fromJSON(r.fill.color),n.fromJSON(r.stroke.color),r.stroke.width)}};export{i as a};
1
+ import {d}from'./chunk-VW3DMTE7.js';import {n}from'./chunk-TPQTY3KB.js';var i=class e{constructor(r=d.Brush.fillColor,o=d.Brush.strokeColor,s=d.Brush.strokeWidth){this.fill={color:r},this.stroke={color:o,width:s};}static get transparent(){let r=n.fromRGBA(255,255,255,0);return new e(r,r,0)}get fillColor(){return this.fill.color}get strokeColor(){return this.stroke.color}get strokeWidth(){return this.stroke.width}static areEquals(r,o){return r==null||o==null?false:n.areEquals(r.fill.color,o.fill.color)&&n.areEquals(r.stroke.color,o.stroke.color)&&r.stroke.width===o.stroke.width}toJSONObject(){return {fill:{color:this.fillColor.toJSON()},stroke:{width:this.strokeWidth,color:this.strokeColor.toJSON()}}}static fromJSONObject(r){return new e(n.fromJSON(r.fill.color),n.fromJSON(r.stroke.color),r.stroke.width)}};export{i as a};
@@ -1 +1 @@
1
- import {a as a$1}from'./chunk-WAUGWWV3.js';import {d}from'./chunk-O2SM24G4.js';import {a as a$2}from'./chunk-CVRIZLTM.js';import {a}from'./chunk-XR65N6EG.js';import {g as g$1}from'./chunk-OPX62GWU.js';import {d as d$1}from'./chunk-QM37NXPY.js';var g=class n{constructor(e){this.deviceId="";this.type="camera";this._currentState="off";this._settings=new g$1;this._desiredTorchState="off";this._desiredState="off";this.listeners=[];this._context=null;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:d.instance(),this.updateCanvasVideoImage=this.updateCanvasVideoImage.bind(this),this.captureAndSend=this.captureAndSend.bind(this),this.setupCamera=this.setupCamera.bind(this);}static get default(){let e=new n;return e.position="worldFacing",e}get desiredState(){return this._desiredState}get settings(){return this._settings}get currentResolution(){var e;return (e=this._currentResolution)!=null?e:null}get context(){return this._context}set context(e){this._context=e,this._context&&this.currentState==="on"&&this.startSendingCapturesToWorker();}get currentState(){return this._currentState}static atPosition(e){if(d$1.Camera.availablePositions.includes(e)){let t=new n;return t.position=e,t}return a.warn(`invalid CameraPosition: "${e}"`),null}static fromDeviceCamera(e){let t=n.atPosition(e.position);return t.deviceId=e.deviceId,t.label=e.label,t}async switchToDesiredState(e){var t,i;return this.currentTransitionStrategyPromise&&await this.currentTransitionStrategyPromise,this.currentTransitionStrategyPromise=(i=(t=this.stateTransitionStrategyMap[this.currentState])==null?void 0:t[e])==null?void 0:i.call(t).catch(r=>{if(r instanceof DOMException&&r.message==="The associated Track is in an invalid state"){a.log(a.Level.Warn,r);return}throw r}),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 i;this._settings=new g$1(e);let t=this.settings.getProperty("grayScaleFrameReader");if(this.cameraManager.setFrameReaderType(t===true?"GRAYSCALE":"RGBA"),this.currentState==="on"||this.currentState==="standby"){let r=this.cameraManager.activeCameraSettings;(r==null?void 0:r.preferredResolution)!==this.settings.preferredResolution&&(await this.cameraManager.applyCameraSettings(this.settings),(i=this.cameraManager.activeCamera)!=null&&i.currentResolution&&(this._currentResolution={width:this.cameraManager.activeCamera.currentResolution.width,height:this.cameraManager.activeCamera.currentResolution.height})),await this.cameraManager.setZoom(this.settings.zoomFactor);let o=this.settings.getProperty("minFrameRate"),c=this.settings.getProperty("maxFrameRate");(o!=null||c!=null)&&await this.cameraManager.setFrameRate({min:o,max:c});let m=this.settings.getProperty("manualLensPosition");m!=null&&await this.cameraManager.setFocus(m);let u=this.settings.getProperty("exposureTargetBias"),d=this.settings.getProperty("exposureDuration");(u!=null||d!=null)&&await this.cameraManager.setExposure({compensation:u,time:d});}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(t){a.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 a$1.getCameras()).find(i=>i.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.label=this.cameraManager.activeCamera.label,this.position=this.cameraManager.activeCamera.position,this.deviceId=this.cameraManager.activeCamera.deviceId,this._currentResolution=this.cameraManager.activeCamera.currentResolution);}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));}async captureAndSend(){if(this.currentState!=="on"||!this.context)return;if(!this.context.hasEnabledMode()){this._lastCaptureRequestAnimationFrame=this.cameraManager.requestVideoFrame(this.captureAndSend);return}let e=null;try{e=this.cameraManager.captureImage();}catch(t){a.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.warn("error while recycling uint8array",t);});this._lastCaptureRequestAnimationFrame=this.cameraManager.requestVideoFrame(this.captureAndSend);}}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.log(a.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.log(a.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.log(a.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.log(a.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 a$2.isAndroidWebView()),this._isAndroidWebView}isZoomAvailable(){var e;return ((e=this.cameraManager.mediaTrackCapabilities)==null?void 0:e.zoom)!=null}};export{g as a};
1
+ import {a as a$1}from'./chunk-DFFYK2ZZ.js';import {d}from'./chunk-4XTOUXDD.js';import {a as a$2}from'./chunk-UCD6YLP3.js';import {a}from'./chunk-XR65N6EG.js';import {g as g$1}from'./chunk-7ELPJFJV.js';import {d as d$1}from'./chunk-VW3DMTE7.js';var g=class n{constructor(e){this.deviceId="";this.type="camera";this._currentState="off";this._settings=new g$1;this._desiredTorchState="off";this._desiredState="off";this.listeners=[];this._context=null;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:d.instance(),this.updateCanvasVideoImage=this.updateCanvasVideoImage.bind(this),this.captureAndSend=this.captureAndSend.bind(this),this.setupCamera=this.setupCamera.bind(this);}static get default(){let e=new n;return e.position="worldFacing",e}get desiredState(){return this._desiredState}get settings(){return this._settings}get currentResolution(){var e;return (e=this._currentResolution)!=null?e:null}get context(){return this._context}set context(e){this._context=e,this._context&&this.currentState==="on"&&this.startSendingCapturesToWorker();}get currentState(){return this._currentState}static atPosition(e){if(d$1.Camera.availablePositions.includes(e)){let t=new n;return t.position=e,t}return a.warn(`invalid CameraPosition: "${e}"`),null}static fromDeviceCamera(e){let t=n.atPosition(e.position);return t.deviceId=e.deviceId,t.label=e.label,t}async switchToDesiredState(e){var t,i;return this.currentTransitionStrategyPromise&&await this.currentTransitionStrategyPromise,this.currentTransitionStrategyPromise=(i=(t=this.stateTransitionStrategyMap[this.currentState])==null?void 0:t[e])==null?void 0:i.call(t).catch(r=>{if(r instanceof DOMException&&r.message==="The associated Track is in an invalid state"){a.log(a.Level.Warn,r);return}throw r}),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 i;this._settings=new g$1(e);let t=this.settings.getProperty("grayScaleFrameReader");if(this.cameraManager.setFrameReaderType(t===true?"GRAYSCALE":"RGBA"),this.currentState==="on"||this.currentState==="standby"){let r=this.cameraManager.activeCameraSettings;(r==null?void 0:r.preferredResolution)!==this.settings.preferredResolution&&(await this.cameraManager.applyCameraSettings(this.settings),(i=this.cameraManager.activeCamera)!=null&&i.currentResolution&&(this._currentResolution={width:this.cameraManager.activeCamera.currentResolution.width,height:this.cameraManager.activeCamera.currentResolution.height})),await this.cameraManager.setZoom(this.settings.zoomFactor);let o=this.settings.getProperty("minFrameRate"),c=this.settings.getProperty("maxFrameRate");(o!=null||c!=null)&&await this.cameraManager.setFrameRate({min:o,max:c});let m=this.settings.getProperty("manualLensPosition");m!=null&&await this.cameraManager.setFocus(m);let u=this.settings.getProperty("exposureTargetBias"),d=this.settings.getProperty("exposureDuration");(u!=null||d!=null)&&await this.cameraManager.setExposure({compensation:u,time:d});}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(t){a.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 a$1.getCameras()).find(i=>i.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.label=this.cameraManager.activeCamera.label,this.position=this.cameraManager.activeCamera.position,this.deviceId=this.cameraManager.activeCamera.deviceId,this._currentResolution=this.cameraManager.activeCamera.currentResolution);}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));}async captureAndSend(){if(this.currentState!=="on"||!this.context)return;if(!this.context.hasEnabledMode()){this._lastCaptureRequestAnimationFrame=this.cameraManager.requestVideoFrame(this.captureAndSend);return}let e=null;try{e=this.cameraManager.captureImage();}catch(t){a.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.warn("error while recycling uint8array",t);});this._lastCaptureRequestAnimationFrame=this.cameraManager.requestVideoFrame(this.captureAndSend);}}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.log(a.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.log(a.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.log(a.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.log(a.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 a$2.isAndroidWebView()),this._isAndroidWebView}isZoomAvailable(){var e;return ((e=this.cameraManager.mediaTrackCapabilities)==null?void 0:e.zoom)!=null}};export{g as a};
@@ -1,4 +1,4 @@
1
- import {a}from'./chunk-MU6SADSF.js';import {a as a$1}from'./chunk-EV4OEANA.js';import {a as a$2}from'./chunk-3A4KLILV.js';import {a as a$3}from'./chunk-LSZZVJ6B.js';import {n as n$1}from'./chunk-77BBIAZE.js';var n=a`
1
+ import {a as a$2}from'./chunk-3A4KLILV.js';import {a}from'./chunk-MU6SADSF.js';import {a as a$1}from'./chunk-EV4OEANA.js';import {a as a$3}from'./chunk-LSZZVJ6B.js';import {n as n$1}from'./chunk-TPQTY3KB.js';var n=a`
2
2
  <div role="listitem">
3
3
  <slot></slot>
4
4
  </div>
@@ -1,4 +1,4 @@
1
- import {a}from'./chunk-NA6AZIR5.js';import {a as a$2}from'./chunk-MU6SADSF.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`
1
+ import {a}from'./chunk-S24T6WS2.js';import {a as a$1}from'./chunk-3A4KLILV.js';import {a as a$2}from'./chunk-MU6SADSF.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`
2
2
  <style>
3
3
  ${e.tag} {
4
4
  display: flex;
@@ -1,4 +1,4 @@
1
- import {a as a$4}from'./chunk-2T36DQ52.js';import {a as a$6}from'./chunk-GHTCNOQN.js';import {a as a$2}from'./chunk-MU6SADSF.js';import {a as a$1}from'./chunk-EV4OEANA.js';import {a as a$3}from'./chunk-3A4KLILV.js';import {a as a$5}from'./chunk-LSZZVJ6B.js';var d="scandit-loading-overlay",t=class t extends a$1{constructor(){super();this._progressBar=null;this._label=null;let e=this.attachShadow({mode:"open"});e.innerHTML=a$2`
1
+ import {a as a$4}from'./chunk-AJE43LJ5.js';import {a as a$6}from'./chunk-GHTCNOQN.js';import {a as a$3}from'./chunk-3A4KLILV.js';import {a as a$2}from'./chunk-MU6SADSF.js';import {a as a$1}from'./chunk-EV4OEANA.js';import {a as a$5}from'./chunk-LSZZVJ6B.js';var d="scandit-loading-overlay",t=class t extends a$1{constructor(){super();this._progressBar=null;this._label=null;let e=this.attachShadow({mode:"open"});e.innerHTML=a$2`
2
2
  <div class="loading-overlay">
3
3
  <label for="scandit-progress" class="message">Loading...</label>
4
4
  <scandit-progress-bar id="scandit-progress" min="0" max="100"></scandit-progress-bar>
@@ -0,0 +1,11 @@
1
+ import {a as a$3}from'./chunk-2QT7PJFA.js';import {a as a$2}from'./chunk-QUHRBS4G.js';import {e}from'./chunk-TB4UKDDI.js';import {a as a$7,b}from'./chunk-SM5S3DDC.js';import {a as a$6}from'./chunk-3A4KLILV.js';import {a as a$4}from'./chunk-MU6SADSF.js';import {a as a$1}from'./chunk-EV4OEANA.js';import {a as a$5}from'./chunk-LSZZVJ6B.js';var E=(e=>(e.DidShow="didshow",e.DidHide="didhide",e.WillShow="willshow",e))(E||{}),o="--text-size",s="--text-color",n="--text-alignment",r="--text-weight",a="--line-height",l="--background-color",c="--corner-radius",h="--max-lines",w="ease-in-out",i=class i extends a$1{constructor(){super();this.toast=null;this._hintStyle=null;this._customIcon=null;this.currentAnimation=null;this.animationDuration=250;this._currentAnimationDirection=null;let t=this.attachShadow({mode:"open"});this._exclamationIcon=a$2.create(),this._checkIcon=a$3.create(),this._exclamationIcon.size=24,this._checkIcon.size=24,t.innerHTML=a$4`
2
+ <div class="toast">
3
+ <slot name="first-child"></slot>
4
+ <div class="left">
5
+ <slot name="icon"></slot>
6
+ </div>
7
+ <p class="middle">
8
+ <slot></slot>
9
+ </p>
10
+ </div>
11
+ `,t.append(i.createStyleElement().cloneNode(true)),this.toast=t.querySelector(".toast");}static createStyleElement(){return a$5`:host{display:inline-block;font-family:SF Pro Display,sans-serif}:host([hidden]){display:none}.toast{${o}:1rem;${s}:#000;${r}:400;${n}:${"center"};${a}:1.5rem;${l}:#fff;${c}:.25rem;${h}:2;align-items:flex-start;background-color:var(${l});border-radius:var(${c});color:var(${s});display:flex;flex-direction:row;font-size:var(${o});font-weight:var(${r});gap:.625rem;justify-content:var(${n});line-height:var(${a});padding:.75rem 1rem}:host([direction=column]) .toast{align-items:center;flex-direction:column}:host([direction=row]) .toast{align-items:center;flex-direction:row}.toast .left{align-self:flex-start;display:flex}.toast.icon-${"none"} .left{display:none}.toast p.middle{display:inline-block;display:-webkit-box;margin:0;padding:0;text-align:var(${n});-webkit-line-clamp:var(${h});-webkit-box-orient:vertical;align-self:center;overflow:hidden;text-shadow:0 1px 2px #${e.withAlpha(.3).toJSON()}}p.middle{text-align:var(${n})}`}get hintStyle(){return this._hintStyle}set hintStyle(t){this._hintStyle=t,this.render();}get customIcon(){return this._customIcon}set customIcon(t){this._customIcon=t,this.render();}get showAnimation(){return new Animation(new KeyframeEffect(this,[{opacity:0},{opacity:1}],{duration:this.animationDuration,fill:"both",easing:w}))}get hideAnimation(){return new Animation(new KeyframeEffect(this,[{opacity:1},{opacity:0}],{duration:this.animationDuration,fill:"both",easing:w}))}static create(){return i.register(),document.createElement(i.tag)}static register(){a$6({[i.tag]:i});}async show(){return this.toggle(true)}async hide(){return this.toggle(false)}connectedCallback(){this.render();}async toggle(t){var m,d;let e=t?"showing":"hiding";this.currentAnimation&&this._currentAnimationDirection===e&&this.currentAnimation.playState==="running"||(this.currentAnimation&&a$7(this.currentAnimation),this.animationDuration=(d=(m=this.hintStyle)==null?void 0:m.isAnimatedToView)==null||d?250:0,this._currentAnimationDirection=e,this.currentAnimation=t?this.showAnimation:this.hideAnimation,t&&this.dispatchEvent(new CustomEvent("willshow",{bubbles:true})),this.currentAnimation.play(),await b(this.currentAnimation),this.dispatchEvent(new CustomEvent(t?"didshow":"didhide",{bubbles:true,detail:{target:this}})),this.currentAnimation=null,this._currentAnimationDirection=null);}render(){var t;if(!(!this.toast||!this.hintStyle)){this.toast.className="toast",this.toast.style.setProperty(o,`${this.hintStyle.textSize}px`),this.toast.style.setProperty(s,`#${this.hintStyle.textColor}`),this.toast.style.setProperty(r,this.hintStyle.textWeight.toString()),this.toast.style.setProperty(n,this.hintStyle.textAlignment),this.toast.style.setProperty(a,`${this.hintStyle.lineHeight/14}`),this.toast.style.setProperty(l,`#${this.hintStyle.backgroundColor}`),this.toast.style.setProperty(c,`${this.hintStyle.cornerRadius/10}rem`),this.toast.style.setProperty(h,this.hintStyle.maxLines.toString());for(let e of this.querySelectorAll("[slot=icon]"))e.remove();this._customIcon?(this._customIcon.setAttribute("slot","icon"),this.append(this._customIcon),this.toast.classList.remove("icon-none")):(this.toast.classList.toggle("icon-none",this.hintStyle.hintIcon==="none"),this.hintStyle.hintIcon==="check"?(this._checkIcon.setAttribute("slot","icon"),this.append(this._checkIcon)):this.hintStyle.hintIcon==="exclamationMark"&&(this._exclamationIcon.setAttribute("slot","icon"),this.append(this._exclamationIcon)),this.hintStyle.iconColor&&((t=this.querySelector("[slot=icon]"))==null||t.setAttribute("fill",`#${this.hintStyle.iconColor}`)));}}};i.tag="scandit-toast-hint";var A=i;export{E as a,A as b};
@@ -1 +1 @@
1
- import {a as a$2}from'./chunk-MU6SADSF.js';import {a}from'./chunk-EV4OEANA.js';import {a as a$1}from'./chunk-3A4KLILV.js';var r="inline-style",e=class e extends a{get fill(){var t;return (t=this.getAttribute("fill"))!=null?t:"black"}set fill(t){this.setAttribute("fill",t);}get size(){var t;return Number((t=this.getAttribute("size"))!=null?t:"32")}set size(t){this.setAttribute("size",t.toString());}get[r](){return this.getAttribute(r)}set[r](t){t==null?this.removeAttribute(r):this.setAttribute(r,t);}static create(){return a$1({[e.tag]:e}),document.createElement(e.tag)}render(){return a$2`<div></div>`}heightForViewbox(t,i){return this.size*this.aspectRatioForViewbox(t,i)}aspectRatioForViewbox(t,i){return i/t}connectedCallback(){this.innerHTML=this.render();}attributeChangedCallback(t,i,b){b!==i&&(this.innerHTML=this.render());}};e.tag="scandit-svg-icon",e.observedAttributes=["fill","size"];var u=e;export{u as a};
1
+ import {a as a$1}from'./chunk-3A4KLILV.js';import {a as a$2}from'./chunk-MU6SADSF.js';import {a}from'./chunk-EV4OEANA.js';var r="inline-style",e=class e extends a{get fill(){var t;return (t=this.getAttribute("fill"))!=null?t:"black"}set fill(t){this.setAttribute("fill",t);}get size(){var t;return Number((t=this.getAttribute("size"))!=null?t:"32")}set size(t){this.setAttribute("size",t.toString());}get[r](){return this.getAttribute(r)}set[r](t){t==null?this.removeAttribute(r):this.setAttribute(r,t);}static create(){return a$1({[e.tag]:e}),document.createElement(e.tag)}render(){return a$2`<div></div>`}heightForViewbox(t,i){return this.size*this.aspectRatioForViewbox(t,i)}aspectRatioForViewbox(t,i){return i/t}connectedCallback(){this.innerHTML=this.render();}attributeChangedCallback(t,i,b){b!==i&&(this.innerHTML=this.render());}};e.tag="scandit-svg-icon",e.observedAttributes=["fill","size"];var u=e;export{u as a};
@@ -1 +1 @@
1
- import {a}from'./chunk-CVRIZLTM.js';import {d}from'./chunk-QM37NXPY.js';var n=class e{constructor(t,o=d.Feedback.defaultVibrationPattern){this.type=t,this.pattern=o;let r=a.getSupportedVibrationMethod();r&&(this._vibrate=r.bind(navigator));}static get defaultVibration(){return new e("default")}static withPattern(t){return new e("default",t)}toJSONObject(){return {type:this.type}}vibrate(){var t;return (t=this._vibrate)==null?void 0:t.call(this,this.pattern)}};export{n as a};
1
+ import {a}from'./chunk-UCD6YLP3.js';import {d}from'./chunk-VW3DMTE7.js';var n=class e{constructor(t,o=d.Feedback.defaultVibrationPattern){this.type=t,this.pattern=o;let r=a.getSupportedVibrationMethod();r&&(this._vibrate=r.bind(navigator));}static get defaultVibration(){return new e("default")}static withPattern(t){return new e("default",t)}toJSONObject(){return {type:this.type}}vibrate(){var t;return (t=this._vibrate)==null?void 0:t.call(this,this.pattern)}};export{n as a};
@@ -0,0 +1 @@
1
+ function t(n){if(!n)return false;try{return n.cancel(),true}catch(e){return false}}async function i(n){if(n)try{await n.finished;}catch(e){}}export{t as a,i as b};
@@ -1 +1 @@
1
- import {n as n$1}from'./chunk-77BBIAZE.js';var e=n$1.fromRGBA(46,193,206,1),n=n$1.fromRGBA(98,209,218,1),t=n$1.fromRGBA(151,224,230,1),c=n$1.fromRGBA(203,240,243,1),a=n$1.fromRGBA(18,22,25,1),m=n$1.fromRGBA(218,225,231,1),p=n$1.fromRGBA(40,211,128,1),G=n$1.fromRGBA(83,220,153,1),R=n$1.fromRGBA(126,229,179,1),B=n$1.fromRGBA(169,237,204,1),f=n$1.fromRGBA(212,246,230,1),s=n$1.fromRGBA(251,192,44,1),x=n$1.fromRGBA(252,205,86,1),y=n$1.fromRGBA(253,217,128,1),A=n$1.fromRGBA(254,230,171,1),d=n$1.fromRGBA(254,242,213,1),S=n$1.fromRGBA(250,68,70,1),l=n$1.fromRGBA(251,105,107,1),g=n$1.fromRGBA(252,143,144,1),i=n$1.fromRGBA(253,180,181,1),O=n$1.fromRGBA(254,218,218,1),T=n$1.fromRGBA(10,51,144,1),u=n$1.fromRGBA(22,96,217,1),C=n$1.fromRGBA(217,231,255,1);export{e as a,n as b,t as c,c as d,a as e,m as f,p as g,G as h,R as i,B as j,f as k,s as l,x as m,y as n,A as o,d as p,S as q,l as r,g as s,i as t,O as u,T as v,u as w,C as x};
1
+ import {n as n$1}from'./chunk-TPQTY3KB.js';var e=n$1.fromRGBA(46,193,206,1),n=n$1.fromRGBA(98,209,218,1),t=n$1.fromRGBA(151,224,230,1),c=n$1.fromRGBA(203,240,243,1),a=n$1.fromRGBA(18,22,25,1),m=n$1.fromRGBA(218,225,231,1),p=n$1.fromRGBA(40,211,128,1),G=n$1.fromRGBA(83,220,153,1),R=n$1.fromRGBA(126,229,179,1),B=n$1.fromRGBA(169,237,204,1),f=n$1.fromRGBA(212,246,230,1),s=n$1.fromRGBA(251,192,44,1),x=n$1.fromRGBA(252,205,86,1),y=n$1.fromRGBA(253,217,128,1),A=n$1.fromRGBA(254,230,171,1),d=n$1.fromRGBA(254,242,213,1),S=n$1.fromRGBA(250,68,70,1),l=n$1.fromRGBA(251,105,107,1),g=n$1.fromRGBA(252,143,144,1),i=n$1.fromRGBA(253,180,181,1),O=n$1.fromRGBA(254,218,218,1),T=n$1.fromRGBA(10,51,144,1),u=n$1.fromRGBA(22,96,217,1),C=n$1.fromRGBA(217,231,255,1);export{e as a,n as b,t as c,c as d,a as e,m as f,p as g,G as h,R as i,B as j,f as k,s as l,x as m,y as n,A as o,d as p,S as q,l as r,g as s,i as t,O as u,T as v,u as w,C as x};
@@ -0,0 +1 @@
1
+ var u=class e{constructor(t,i){this._x=t,this._y=i;}get x(){return this._x}get y(){return this._y}static mirrorX(t,i){let r=t.x-i.width;return r*=-1,new e(r,t.y)}static fromJSON(t){return new e(t.x,t.y)}toJSONObject(){return {x:this.x,y:this.y}}static areEquals(t,i){return t.x===i.x&&t.y===i.y}equals(t){return this.x===t.x&&this.y===t.y}},m=class e{constructor(t,i,r,o){this._topLeft=t,this._topRight=i,this._bottomRight=r,this._bottomLeft=o;}get topLeft(){return this._topLeft}get topRight(){return this._topRight}get bottomRight(){return this._bottomRight}get bottomLeft(){return this._bottomLeft}static fromJSON(t){return new e(u.fromJSON(t.topLeft),u.fromJSON(t.topRight),u.fromJSON(t.bottomRight),u.fromJSON(t.bottomLeft))}toJSONObject(){return {topLeft:this.topLeft.toJSONObject(),topRight:this.topRight.toJSONObject(),bottomLeft:this.bottomLeft.toJSONObject(),bottomRight:this.bottomRight.toJSONObject()}}},W=(i=>(i.Pixel="pixel",i.Fraction="fraction",i))(W||{}),n=class e{constructor(t,i){this._value=t,this._unit=i;}get value(){return this._value}get unit(){return this._unit}static fromJSON(t){return new e(t.value,t.unit)}toJSONObject(){return {unit:this.unit,value:this.value}}},S=class e{constructor(t,i){this._x=t,this._y=i;}static get zero(){return new e(new n(0,"pixel"),new n(0,"pixel"))}get x(){return this._x}get y(){return this._y}static fromJSON(t){return new e(n.fromJSON(t.x),n.fromJSON(t.y))}toJSONObject(){return {x:this.x.toJSONObject(),y:this.y.toJSONObject()}}},g=class{constructor(t,i){this._origin=t,this._size=i;}get origin(){return this._origin}get size(){return this._size}toJSONObject(){return {origin:this.origin.toJSONObject(),size:this.size.toJSONObject()}}},N=class{constructor(t,i){this._origin=t,this._size=i;}get origin(){return this._origin}get size(){return this._size}toJSONObject(){return {origin:this._origin.toJSONObject(),size:this._size.toJSONObject()}}},l=class e{constructor(t,i){this._width=t,this._height=i;}get width(){return this._width}get height(){return this._height}static fromJSON(t){return new e(n.fromJSON(t.width),n.fromJSON(t.height))}isSameAs(t){return JSON.stringify(this.toJSONObject())===JSON.stringify(t.toJSONObject())}toJSONObject(){return {width:this.width.toJSONObject(),height:this.height.toJSONObject()}}},d=class e{constructor(t,i){this._width=t,this._height=i;}get width(){return this._width}get height(){return this._height}static fromJSON(t){return new e(t.width,t.height)}toJSONObject(){return {height:this.height,width:this.width}}},p=class{constructor(t,i){this._size=t,this._aspect=i;}get size(){return this._size}get aspect(){return this._aspect}},f=(o=>(o.WidthAndHeight="widthAndHeight",o.WidthAndAspectRatio="widthAndAspectRatio",o.HeightAndAspectRatio="heightAndAspectRatio",o.ShorterDimensionAndAspectRatio="shorterDimensionAndAspectRatio",o))(f||{}),O=class e{constructor(){this._shorterDimensionAndAspectRatio=null;}get widthAndHeight(){return this._widthAndHeight}get widthAndAspectRatio(){return this._widthAndAspectRatio}get heightAndAspectRatio(){return this._heightAndAspectRatio}get shorterDimensionAndAspectRatio(){return this._shorterDimensionAndAspectRatio}get sizingMode(){return this.widthAndAspectRatio?"widthAndAspectRatio":this.heightAndAspectRatio?"heightAndAspectRatio":this.shorterDimensionAndAspectRatio?"shorterDimensionAndAspectRatio":"widthAndHeight"}static sizeWithWidthAndHeight(t){let i=new e;return i._widthAndHeight=t,i}static sizeWithWidthAndAspectRatio(t,i){let r=new e;return r._widthAndAspectRatio=new p(t,i),r}static sizeWithHeightAndAspectRatio(t,i){let r=new e;return r._heightAndAspectRatio=new p(t,i),r}static sizeWithShorterDimensionAndAspectRatio(t,i){let r=new e;return r._shorterDimensionAndAspectRatio=new p(t,i),r}static fromJSON(t){if(t.width&&t.height)return e.sizeWithWidthAndHeight(new l(n.fromJSON(t.width),n.fromJSON(t.height)));if(t.width&&typeof t.aspect=="number")return e.sizeWithWidthAndAspectRatio(n.fromJSON(t.width),t.aspect);if(t.height&&typeof t.aspect=="number")return e.sizeWithHeightAndAspectRatio(n.fromJSON(t.height),t.aspect);if(t.shorterDimension&&typeof t.aspect=="number")return e.sizeWithShorterDimensionAndAspectRatio(n.fromJSON(t.shorterDimension),t.aspect);throw new Error(`SizeWithUnitAndAspectJSON is malformed: ${JSON.stringify(t)}`)}toJSONObject(){var t,i,r,o,s,c,h,b;switch(this.sizingMode){case "widthAndAspectRatio":return {width:(t=this.widthAndAspectRatio)==null?void 0:t.size.toJSONObject(),aspect:(i=this.widthAndAspectRatio)==null?void 0:i.aspect};case "heightAndAspectRatio":return {height:(r=this.heightAndAspectRatio)==null?void 0:r.size.toJSONObject(),aspect:(o=this.heightAndAspectRatio)==null?void 0:o.aspect};case "shorterDimensionAndAspectRatio":return {shorterDimension:(s=this.shorterDimensionAndAspectRatio)==null?void 0:s.size.toJSONObject(),aspect:(c=this.shorterDimensionAndAspectRatio)==null?void 0:c.aspect};default:return {width:(h=this.widthAndHeight)==null?void 0:h.width.toJSONObject(),height:(b=this.widthAndHeight)==null?void 0:b.height.toJSONObject()}}}},J=class e{constructor(t,i,r,o){this._left=t,this._top=i,this._right=r,this._bottom=o;}static get zero(){return new e(new n(0,"pixel"),new n(0,"pixel"),new n(0,"pixel"),new n(0,"pixel"))}get left(){return this._left}get right(){return this._right}get top(){return this._top}get bottom(){return this._bottom}static fromJSON(t){return new e(n.fromJSON(t.left),n.fromJSON(t.top),n.fromJSON(t.right),n.fromJSON(t.bottom))}toJSONObject(){return {left:this.left.toJSONObject(),right:this.right.toJSONObject(),top:this.top.toJSONObject(),bottom:this.bottom.toJSONObject()}}},A=class e{constructor(t){this.hexadecimalString=t;}get redComponent(){return this.hexadecimalString.slice(0,2)}get greenComponent(){return this.hexadecimalString.slice(2,4)}get blueComponent(){return this.hexadecimalString.slice(4,6)}get alphaComponent(){return this.hexadecimalString.slice(6,8)}get red(){return e.hexToNumber(this.redComponent)}get green(){return e.hexToNumber(this.greenComponent)}get blue(){return e.hexToNumber(this.blueComponent)}get alpha(){return e.hexToNumber(this.alphaComponent)}static fromHex(t){return new e(e.normalizeHex(t))}static fromRGBA(t,i,r,o=1){let s=[t,i,r,e.normalizeAlpha(o)].reduce((c,h)=>c+e.numberToHex(h),"");return new e(s)}static areEquals(t,i){return t==null||i==null?false:t.hexadecimalString===i.hexadecimalString}static hexToNumber(t){return Number.parseInt(t,16)}static fromJSON(t){return e.fromHex(t)}static numberToHex(t){let r=Math.round(t).toString(16);return r.length===1&&(r=`0${r}`),r.toUpperCase()}static normalizeHex(t){let i=t;return i.startsWith("#")&&(i=i.slice(1)),i.length<6&&(i=[...i].map(r=>r+r).join("")),i.length===6&&(i+="FF"),i.toUpperCase()}static normalizeAlpha(t){return t>0&&t<=1?255*t:t}withAlpha(t){let i=this.hexadecimalString.slice(0,6)+e.numberToHex(e.normalizeAlpha(t));return e.fromHex(i)}toJSON(){return this.hexadecimalString}},U=(s=>(s.Unknown="unknown",s.Portrait="portrait",s.PortraitUpsideDown="portraitUpsideDown",s.LandscapeRight="landscapeRight",s.LandscapeLeft="landscapeLeft",s))(U||{}),z=(h=>(h.None="none",h.Horizontal="horizontal",h.LeftToRight="leftToRight",h.RightToLeft="rightToLeft",h.Vertical="vertical",h.TopToBottom="topToBottom",h.BottomToTop="bottomToTop",h))(z||{}),x=(a=>(a.TopLeft="topLeft",a.TopCenter="topCenter",a.TopRight="topRight",a.CenterLeft="centerLeft",a.Center="center",a.CenterRight="centerRight",a.BottomLeft="bottomLeft",a.BottomCenter="bottomCenter",a.BottomRight="bottomRight",a))(x||{});export{u as a,m as b,W as c,n as d,S as e,g as f,N as g,l as h,d as i,p as j,f as k,O as l,J as m,A as n,U as o,z as p,x as q};
@@ -0,0 +1,2 @@
1
+ import {b as b$2}from'./chunk-XEBHIXET.js';import {c,d,b as b$1,a as a$1,e}from'./chunk-42THCP2K.js';import {a,b}from'./chunk-TR3NGINC.js';var Ae=a((Y,ie)=>{(function(m,u){var I="1.0.40",R="",h="?",E="function",g="undefined",C="object",O="string",k="major",e="model",r="name",i="type",o="vendor",n="version",T="architecture",L="console",l="mobile",w="tablet",S="smarttv",_="wearable",W="embedded",X=500,j="Amazon",N="Apple",V="ASUS",a="BlackBerry",t="Browser",c="Chrome",x="Edge",y="Firefox",P="Google",D="Huawei",oe="LG",re="Microsoft",be="Motorola",F="Opera",G="Samsung",ce="Sharp",K="Sony",ne="Xiaomi",te="Zebra",ue="Facebook",we="Chromium OS",de="Mac OS",pe=" Browser",Te=function(d,p){var b={};for(var v in d)p[v]&&p[v].length%2===0?b[v]=p[v].concat(d[v]):b[v]=d[v];return b},Z=function(d){for(var p={},b=0;b<d.length;b++)p[d[b].toUpperCase()]=d[b];return p},fe=function(d,p){return typeof d===O?z(p).indexOf(z(d))!==-1:false},z=function(d){return d.toLowerCase()},_e=function(d){return typeof d===O?d.replace(/[^\d\.]/g,R).split(".")[0]:u},ae=function(d,p){if(typeof d===O)return d=d.replace(/^\s\s*/,R),typeof p===g?d:d.substring(0,X)},H=function(d,p){for(var b=0,v,B,U,f,s,M;b<p.length&&!s;){var se=p[b],ve=p[b+1];for(v=B=0;v<se.length&&!s&&se[v];)if(s=se[v++].exec(d),s)for(U=0;U<ve.length;U++)M=s[++B],f=ve[U],typeof f===C&&f.length>0?f.length===2?typeof f[1]==E?this[f[0]]=f[1].call(this,M):this[f[0]]=f[1]:f.length===3?typeof f[1]===E&&!(f[1].exec&&f[1].test)?this[f[0]]=M?f[1].call(this,M,f[2]):u:this[f[0]]=M?M.replace(f[1],f[2]):u:f.length===4&&(this[f[0]]=M?f[3].call(this,M.replace(f[1],f[2])):u):this[f]=M||u;b+=2;}},$=function(d,p){for(var b in p)if(typeof p[b]===C&&p[b].length>0){for(var v=0;v<p[b].length;v++)if(fe(p[b][v],d))return b===h?u:b}else if(fe(p[b],d))return b===h?u:b;return p.hasOwnProperty("*")?p["*"]:d},Re={"1.0":"/8","1.2":"/1","1.3":"/3","2.0":"/412","2.0.2":"/416","2.0.3":"/417","2.0.4":"/419","?":"/"},me={ME:"4.90","NT 3.11":"NT3.51","NT 4.0":"NT4.0",2e3:"NT 5.0",XP:["NT 5.1","NT 5.2"],Vista:"NT 6.0",7:"NT 6.1",8:"NT 6.2","8.1":"NT 6.3",10:["NT 6.4","NT 10.0"],RT:"ARM"},ge={browser:[[/\b(?:crmo|crios)\/([\w\.]+)/i],[n,[r,"Chrome"]],[/edg(?:e|ios|a)?\/([\w\.]+)/i],[n,[r,"Edge"]],[/(opera mini)\/([-\w\.]+)/i,/(opera [mobiletab]{3,6})\b.+version\/([-\w\.]+)/i,/(opera)(?:.+version\/|[\/ ]+)([\w\.]+)/i],[r,n],[/opios[\/ ]+([\w\.]+)/i],[n,[r,F+" Mini"]],[/\bop(?:rg)?x\/([\w\.]+)/i],[n,[r,F+" GX"]],[/\bopr\/([\w\.]+)/i],[n,[r,F]],[/\bb[ai]*d(?:uhd|[ub]*[aekoprswx]{5,6})[\/ ]?([\w\.]+)/i],[n,[r,"Baidu"]],[/\b(?:mxbrowser|mxios|myie2)\/?([-\w\.]*)\b/i],[n,[r,"Maxthon"]],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer|sleipnir)[\/ ]?([\w\.]*)/i,/(avant|iemobile|slim(?:browser|boat|jet))[\/ ]?([\d\.]*)/i,/(?:ms|\()(ie) ([\w\.]+)/i,/(flock|rockmelt|midori|epiphany|silk|skyfire|ovibrowser|bolt|iron|vivaldi|iridium|phantomjs|bowser|qupzilla|falkon|rekonq|puffin|brave|whale(?!.+naver)|qqbrowserlite|duckduckgo|klar|helio|(?=comodo_)?dragon)\/([-\w\.]+)/i,/(heytap|ovi|115)browser\/([\d\.]+)/i,/(weibo)__([\d\.]+)/i],[r,n],[/quark(?:pc)?\/([-\w\.]+)/i],[n,[r,"Quark"]],[/\bddg\/([\w\.]+)/i],[n,[r,"DuckDuckGo"]],[/(?:\buc? ?browser|(?:juc.+)ucweb)[\/ ]?([\w\.]+)/i],[n,[r,"UC"+t]],[/microm.+\bqbcore\/([\w\.]+)/i,/\bqbcore\/([\w\.]+).+microm/i,/micromessenger\/([\w\.]+)/i],[n,[r,"WeChat"]],[/konqueror\/([\w\.]+)/i],[n,[r,"Konqueror"]],[/trident.+rv[: ]([\w\.]{1,9})\b.+like gecko/i],[n,[r,"IE"]],[/ya(?:search)?browser\/([\w\.]+)/i],[n,[r,"Yandex"]],[/slbrowser\/([\w\.]+)/i],[n,[r,"Smart Lenovo "+t]],[/(avast|avg)\/([\w\.]+)/i],[[r,/(.+)/,"$1 Secure "+t],n],[/\bfocus\/([\w\.]+)/i],[n,[r,y+" Focus"]],[/\bopt\/([\w\.]+)/i],[n,[r,F+" Touch"]],[/coc_coc\w+\/([\w\.]+)/i],[n,[r,"Coc Coc"]],[/dolfin\/([\w\.]+)/i],[n,[r,"Dolphin"]],[/coast\/([\w\.]+)/i],[n,[r,F+" Coast"]],[/miuibrowser\/([\w\.]+)/i],[n,[r,"MIUI"+pe]],[/fxios\/([\w\.-]+)/i],[n,[r,y]],[/\bqihoobrowser\/?([\w\.]*)/i],[n,[r,"360"]],[/\b(qq)\/([\w\.]+)/i],[[r,/(.+)/,"$1Browser"],n],[/(oculus|sailfish|huawei|vivo|pico)browser\/([\w\.]+)/i],[[r,/(.+)/,"$1"+pe],n],[/samsungbrowser\/([\w\.]+)/i],[n,[r,G+" Internet"]],[/metasr[\/ ]?([\d\.]+)/i],[n,[r,"Sogou Explorer"]],[/(sogou)mo\w+\/([\d\.]+)/i],[[r,"Sogou Mobile"],n],[/(electron)\/([\w\.]+) safari/i,/(tesla)(?: qtcarbrowser|\/(20\d\d\.[-\w\.]+))/i,/m?(qqbrowser|2345(?=browser|chrome|explorer))\w*[\/ ]?v?([\w\.]+)/i],[r,n],[/(lbbrowser|rekonq)/i,/\[(linkedin)app\]/i],[r],[/ome\/([\w\.]+) \w* ?(iron) saf/i,/ome\/([\w\.]+).+qihu (360)[es]e/i],[n,r],[/((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i],[[r,ue],n],[/(Klarna)\/([\w\.]+)/i,/(kakao(?:talk|story))[\/ ]([\w\.]+)/i,/(naver)\(.*?(\d+\.[\w\.]+).*\)/i,/safari (line)\/([\w\.]+)/i,/\b(line)\/([\w\.]+)\/iab/i,/(alipay)client\/([\w\.]+)/i,/(twitter)(?:and| f.+e\/([\w\.]+))/i,/(chromium|instagram|snapchat)[\/ ]([-\w\.]+)/i],[r,n],[/\bgsa\/([\w\.]+) .*safari\//i],[n,[r,"GSA"]],[/musical_ly(?:.+app_?version\/|_)([\w\.]+)/i],[n,[r,"TikTok"]],[/headlesschrome(?:\/([\w\.]+)| )/i],[n,[r,c+" Headless"]],[/ wv\).+(chrome)\/([\w\.]+)/i],[[r,c+" WebView"],n],[/droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i],[n,[r,"Android "+t]],[/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i],[r,n],[/version\/([\w\.\,]+) .*mobile\/\w+ (safari)/i],[n,[r,"Mobile Safari"]],[/version\/([\w(\.|\,)]+) .*(mobile ?safari|safari)/i],[n,r],[/webkit.+?(mobile ?safari|safari)(\/[\w\.]+)/i],[r,[n,$,Re]],[/(webkit|khtml)\/([\w\.]+)/i],[r,n],[/(navigator|netscape\d?)\/([-\w\.]+)/i],[[r,"Netscape"],n],[/(wolvic|librewolf)\/([\w\.]+)/i],[r,n],[/mobile vr; rv:([\w\.]+)\).+firefox/i],[n,[r,y+" Reality"]],[/ekiohf.+(flow)\/([\w\.]+)/i,/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo browser|minimo|conkeror)[\/ ]?([\w\.\+]+)/i,/(seamonkey|k-meleon|icecat|iceape|firebird|phoenix|palemoon|basilisk|waterfox)\/([-\w\.]+)$/i,/(firefox)\/([\w\.]+)/i,/(mozilla)\/([\w\.]+) .+rv\:.+gecko\/\d+/i,/(polaris|lynx|dillo|icab|doris|amaya|w3m|netsurf|obigo|mosaic|(?:go|ice|up)[\. ]?browser)[-\/ ]?v?([\w\.]+)/i,/(links) \(([\w\.]+)/i],[r,[n,/_/g,"."]],[/(cobalt)\/([\w\.]+)/i],[r,[n,/master.|lts./,""]]],cpu:[[/(?:(amd|x(?:(?:86|64)[-_])?|wow|win)64)[;\)]/i],[[T,"amd64"]],[/(ia32(?=;))/i],[[T,z]],[/((?:i[346]|x)86)[;\)]/i],[[T,"ia32"]],[/\b(aarch64|arm(v?8e?l?|_?64))\b/i],[[T,"arm64"]],[/\b(arm(?:v[67])?ht?n?[fl]p?)\b/i],[[T,"armhf"]],[/windows (ce|mobile); ppc;/i],[[T,"arm"]],[/((?:ppc|powerpc)(?:64)?)(?: mac|;|\))/i],[[T,/ower/,R,z]],[/(sun4\w)[;\)]/i],[[T,"sparc"]],[/((?:avr32|ia64(?=;))|68k(?=\))|\barm(?=v(?:[1-7]|[5-7]1)l?|;|eabi)|(?=atmel )avr|(?:irix|mips|sparc)(?:64)?\b|pa-risc)/i],[[T,z]]],device:[[/\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i],[e,[o,G],[i,w]],[/\b((?:s[cgp]h|gt|sm)-(?![lr])\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,/samsung[- ]((?!sm-[lr])[-\w]+)/i,/sec-(sgh\w+)/i],[e,[o,G],[i,l]],[/(?:\/|\()(ip(?:hone|od)[\w, ]*)(?:\/|;)/i],[e,[o,N],[i,l]],[/\((ipad);[-\w\),; ]+apple/i,/applecoremedia\/[\w\.]+ \((ipad)/i,/\b(ipad)\d\d?,\d\d?[;\]].+ios/i],[e,[o,N],[i,w]],[/(macintosh);/i],[e,[o,N]],[/\b(sh-?[altvz]?\d\d[a-ekm]?)/i],[e,[o,ce],[i,l]],[/(?:honor)([-\w ]+)[;\)]/i],[e,[o,"Honor"],[i,l]],[/\b((?:ag[rs][23]?|bah2?|sht?|btv)-a?[lw]\d{2})\b(?!.+d\/s)/i],[e,[o,D],[i,w]],[/(?:huawei)([-\w ]+)[;\)]/i,/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][012359c][adn]?)\b(?!.+d\/s)/i],[e,[o,D],[i,l]],[/\b(poco[\w ]+|m2\d{3}j\d\d[a-z]{2})(?: bui|\))/i,/\b; (\w+) build\/hm\1/i,/\b(hm[-_ ]?note?[_ ]?(?:\d\w)?) bui/i,/\b(redmi[\-_ ]?(?:note|k)?[\w_ ]+)(?: bui|\))/i,/oid[^\)]+; (m?[12][0-389][01]\w{3,6}[c-y])( bui|; wv|\))/i,/\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note lte|max|cc)?[_ ]?(?:\d?\w?)[_ ]?(?:plus|se|lite|pro)?)(?: bui|\))/i],[[e,/_/g," "],[o,ne],[i,l]],[/oid[^\)]+; (2\d{4}(283|rpbf)[cgl])( bui|\))/i,/\b(mi[-_ ]?(?:pad)(?:[\w_ ]+))(?: bui|\))/i],[[e,/_/g," "],[o,ne],[i,w]],[/; (\w+) bui.+ oppo/i,/\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i],[e,[o,"OPPO"],[i,l]],[/\b(opd2\d{3}a?) bui/i],[e,[o,"OPPO"],[i,w]],[/vivo (\w+)(?: bui|\))/i,/\b(v[12]\d{3}\w?[at])(?: bui|;)/i],[e,[o,"Vivo"],[i,l]],[/\b(rmx[1-3]\d{3})(?: bui|;|\))/i],[e,[o,"Realme"],[i,l]],[/\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,/\bmot(?:orola)?[- ](\w*)/i,/((?:moto[\w\(\) ]+|xt\d{3,4}|nexus 6)(?= bui|\)))/i],[e,[o,be],[i,l]],[/\b(mz60\d|xoom[2 ]{0,2}) build\//i],[e,[o,be],[i,w]],[/((?=lg)?[vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i],[e,[o,oe],[i,w]],[/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,/\blg[-e;\/ ]+((?!browser|netcast|android tv)\w+)/i,/\blg-?([\d\w]+) bui/i],[e,[o,oe],[i,l]],[/(ideatab[-\w ]+)/i,/lenovo ?(s[56]000[-\w]+|tab(?:[\w ]+)|yt[-\d\w]{6}|tb[-\d\w]{6})/i],[e,[o,"Lenovo"],[i,w]],[/(?:maemo|nokia).*(n900|lumia \d+)/i,/nokia[-_ ]?([-\w\.]*)/i],[[e,/_/g," "],[o,"Nokia"],[i,l]],[/(pixel c)\b/i],[e,[o,P],[i,w]],[/droid.+; (pixel[\daxl ]{0,6})(?: bui|\))/i],[e,[o,P],[i,l]],[/droid.+; (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-a\w[4-7][12])(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[e,[o,K],[i,l]],[/sony tablet [ps]/i,/\b(?:sony)?sgp\w+(?: bui|\))/i],[[e,"Xperia Tablet"],[o,K],[i,w]],[/ (kb2005|in20[12]5|be20[12][59])\b/i,/(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i],[e,[o,"OnePlus"],[i,l]],[/(alexa)webm/i,/(kf[a-z]{2}wi|aeo(?!bc)\w\w)( bui|\))/i,/(kf[a-z]+)( bui|\)).+silk\//i],[e,[o,j],[i,w]],[/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i],[[e,/(.+)/g,"Fire Phone $1"],[o,j],[i,l]],[/(playbook);[-\w\),; ]+(rim)/i],[e,o,[i,w]],[/\b((?:bb[a-f]|st[hv])100-\d)/i,/\(bb10; (\w+)/i],[e,[o,a],[i,l]],[/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i],[e,[o,V],[i,w]],[/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i],[e,[o,V],[i,l]],[/(nexus 9)/i],[e,[o,"HTC"],[i,w]],[/(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,/(zte)[- ]([\w ]+?)(?: bui|\/|\))/i,/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i],[o,[e,/_/g," "],[i,l]],[/droid [\w\.]+; ((?:8[14]9[16]|9(?:0(?:48|60|8[01])|1(?:3[27]|66)|2(?:6[69]|9[56])|466))[gqswx])\w*(\)| bui)/i],[e,[o,"TCL"],[i,w]],[/(itel) ((\w+))/i],[[o,z],e,[i,$,{tablet:["p10001l","w7001"],"*":"mobile"}]],[/droid.+; ([ab][1-7]-?[0178a]\d\d?)/i],[e,[o,"Acer"],[i,w]],[/droid.+; (m[1-5] note) bui/i,/\bmz-([-\w]{2,})/i],[e,[o,"Meizu"],[i,l]],[/; ((?:power )?armor(?:[\w ]{0,8}))(?: bui|\))/i],[e,[o,"Ulefone"],[i,l]],[/; (energy ?\w+)(?: bui|\))/i,/; energizer ([\w ]+)(?: bui|\))/i],[e,[o,"Energizer"],[i,l]],[/; cat (b35);/i,/; (b15q?|s22 flip|s48c|s62 pro)(?: bui|\))/i],[e,[o,"Cat"],[i,l]],[/((?:new )?andromax[\w- ]+)(?: bui|\))/i],[e,[o,"Smartfren"],[i,l]],[/droid.+; (a(?:015|06[35]|142p?))/i],[e,[o,"Nothing"],[i,l]],[/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus|dell|meizu|motorola|polytron|infinix|tecno|micromax|advan)[-_ ]?([-\w]*)/i,/; (imo) ((?!tab)[\w ]+?)(?: bui|\))/i,/(hp) ([\w ]+\w)/i,/(asus)-?(\w+)/i,/(microsoft); (lumia[\w ]+)/i,/(lenovo)[-_ ]?([-\w]+)/i,/(jolla)/i,/(oppo) ?([\w ]+) bui/i],[o,e,[i,l]],[/(imo) (tab \w+)/i,/(kobo)\s(ereader|touch)/i,/(archos) (gamepad2?)/i,/(hp).+(touchpad(?!.+tablet)|tablet)/i,/(kindle)\/([\w\.]+)/i,/(nook)[\w ]+build\/(\w+)/i,/(dell) (strea[kpr\d ]*[\dko])/i,/(le[- ]+pan)[- ]+(\w{1,9}) bui/i,/(trinity)[- ]*(t\d{3}) bui/i,/(gigaset)[- ]+(q\w{1,9}) bui/i,/(vodafone) ([\w ]+)(?:\)| bui)/i],[o,e,[i,w]],[/(surface duo)/i],[e,[o,re],[i,w]],[/droid [\d\.]+; (fp\du?)(?: b|\))/i],[e,[o,"Fairphone"],[i,l]],[/(u304aa)/i],[e,[o,"AT&T"],[i,l]],[/\bsie-(\w*)/i],[e,[o,"Siemens"],[i,l]],[/\b(rct\w+) b/i],[e,[o,"RCA"],[i,w]],[/\b(venue[\d ]{2,7}) b/i],[e,[o,"Dell"],[i,w]],[/\b(q(?:mv|ta)\w+) b/i],[e,[o,"Verizon"],[i,w]],[/\b(?:barnes[& ]+noble |bn[rt])([\w\+ ]*) b/i],[e,[o,"Barnes & Noble"],[i,w]],[/\b(tm\d{3}\w+) b/i],[e,[o,"NuVision"],[i,w]],[/\b(k88) b/i],[e,[o,"ZTE"],[i,w]],[/\b(nx\d{3}j) b/i],[e,[o,"ZTE"],[i,l]],[/\b(gen\d{3}) b.+49h/i],[e,[o,"Swiss"],[i,l]],[/\b(zur\d{3}) b/i],[e,[o,"Swiss"],[i,w]],[/\b((zeki)?tb.*\b) b/i],[e,[o,"Zeki"],[i,w]],[/\b([yr]\d{2}) b/i,/\b(dragon[- ]+touch |dt)(\w{5}) b/i],[[o,"Dragon Touch"],e,[i,w]],[/\b(ns-?\w{0,9}) b/i],[e,[o,"Insignia"],[i,w]],[/\b((nxa|next)-?\w{0,9}) b/i],[e,[o,"NextBook"],[i,w]],[/\b(xtreme\_)?(v(1[045]|2[015]|[3469]0|7[05])) b/i],[[o,"Voice"],e,[i,l]],[/\b(lvtel\-)?(v1[12]) b/i],[[o,"LvTel"],e,[i,l]],[/\b(ph-1) /i],[e,[o,"Essential"],[i,l]],[/\b(v(100md|700na|7011|917g).*\b) b/i],[e,[o,"Envizen"],[i,w]],[/\b(trio[-\w\. ]+) b/i],[e,[o,"MachSpeed"],[i,w]],[/\btu_(1491) b/i],[e,[o,"Rotor"],[i,w]],[/(shield[\w ]+) b/i],[e,[o,"Nvidia"],[i,w]],[/(sprint) (\w+)/i],[o,e,[i,l]],[/(kin\.[onetw]{3})/i],[[e,/\./g," "],[o,re],[i,l]],[/droid.+; (cc6666?|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i],[e,[o,te],[i,w]],[/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i],[e,[o,te],[i,l]],[/smart-tv.+(samsung)/i],[o,[i,S]],[/hbbtv.+maple;(\d+)/i],[[e,/^/,"SmartTV"],[o,G],[i,S]],[/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i],[[o,oe],[i,S]],[/(apple) ?tv/i],[o,[e,N+" TV"],[i,S]],[/crkey/i],[[e,c+"cast"],[o,P],[i,S]],[/droid.+aft(\w+)( bui|\))/i],[e,[o,j],[i,S]],[/\(dtv[\);].+(aquos)/i,/(aquos-tv[\w ]+)\)/i],[e,[o,ce],[i,S]],[/(bravia[\w ]+)( bui|\))/i],[e,[o,K],[i,S]],[/(mitv-\w{5}) bui/i],[e,[o,ne],[i,S]],[/Hbbtv.*(technisat) (.*);/i],[o,e,[i,S]],[/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i],[[o,ae],[e,ae],[i,S]],[/\b(android tv|smart[- ]?tv|opera tv|tv; rv:)\b/i],[[i,S]],[/(ouya)/i,/(nintendo) ([wids3utch]+)/i],[o,e,[i,L]],[/droid.+; (shield) bui/i],[e,[o,"Nvidia"],[i,L]],[/(playstation [345portablevi]+)/i],[e,[o,K],[i,L]],[/\b(xbox(?: one)?(?!; xbox))[\); ]/i],[e,[o,re],[i,L]],[/\b(sm-[lr]\d\d[05][fnuw]?s?)\b/i],[e,[o,G],[i,_]],[/((pebble))app/i],[o,e,[i,_]],[/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i],[e,[o,N],[i,_]],[/droid.+; (glass) \d/i],[e,[o,P],[i,_]],[/droid.+; (wt63?0{2,3})\)/i],[e,[o,te],[i,_]],[/droid.+; (glass) \d/i],[e,[o,P],[i,_]],[/(pico) (4|neo3(?: link|pro)?)/i],[o,e,[i,_]],[/; (quest( \d| pro)?)/i],[e,[o,ue],[i,_]],[/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i],[o,[i,W]],[/(aeobc)\b/i],[e,[o,j],[i,W]],[/droid .+?; ([^;]+?)(?: bui|; wv\)|\) applew).+? mobile safari/i],[e,[i,l]],[/droid .+?; ([^;]+?)(?: bui|\) applew).+?(?! mobile) safari/i],[e,[i,w]],[/\b((tablet|tab)[;\/]|focus\/\d(?!.+mobile))/i],[[i,w]],[/(phone|mobile(?:[;\/]| [ \w\/\.]*safari)|pda(?=.+windows ce))/i],[[i,l]],[/(android[-\w\. ]{0,9});.+buil/i],[e,[o,"Generic"]]],engine:[[/windows.+ edge\/([\w\.]+)/i],[n,[r,x+"HTML"]],[/(arkweb)\/([\w\.]+)/i],[r,n],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[n,[r,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna|servo)\/([\w\.]+)/i,/ekioh(flow)\/([\w\.]+)/i,/(khtml|tasman|links)[\/ ]\(?([\w\.]+)/i,/(icab)[\/ ]([23]\.[\d\.]+)/i,/\b(libweb)/i],[r,n],[/rv\:([\w\.]{1,9})\b.+(gecko)/i],[n,r]],os:[[/microsoft (windows) (vista|xp)/i],[r,n],[/(windows (?:phone(?: os)?|mobile))[\/ ]?([\d\.\w ]*)/i],[r,[n,$,me]],[/windows nt 6\.2; (arm)/i,/windows[\/ ]?([ntce\d\. ]+\w)(?!.+xbox)/i,/(?:win(?=3|9|n)|win 9x )([nt\d\.]+)/i],[[n,$,me],[r,"Windows"]],[/ip[honead]{2,4}\b(?:.*os ([\w]+) like mac|; opera)/i,/(?:ios;fbsv\/|iphone.+ios[\/ ])([\d\.]+)/i,/cfnetwork\/.+darwin/i],[[n,/_/g,"."],[r,"iOS"]],[/(mac os x) ?([\w\. ]*)/i,/(macintosh|mac_powerpc\b)(?!.+haiku)/i],[[r,de],[n,/_/g,"."]],[/droid ([\w\.]+)\b.+(android[- ]x86|harmonyos)/i],[n,r],[/(android|webos|qnx|bada|rim tablet os|maemo|meego|sailfish|openharmony)[-\/ ]?([\w\.]*)/i,/(blackberry)\w*\/([\w\.]*)/i,/(tizen|kaios)[\/ ]([\w\.]+)/i,/\((series40);/i],[r,n],[/\(bb(10);/i],[n,[r,a]],[/(?:symbian ?os|symbos|s60(?=;)|series60)[-\/ ]?([\w\.]*)/i],[n,[r,"Symbian"]],[/mozilla\/[\d\.]+ \((?:mobile|tablet|tv|mobile; [\w ]+); rv:.+ gecko\/([\w\.]+)/i],[n,[r,y+" OS"]],[/web0s;.+rt(tv)/i,/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i],[n,[r,"webOS"]],[/watch(?: ?os[,\/]|\d,\d\/)([\d\.]+)/i],[n,[r,"watchOS"]],[/crkey\/([\d\.]+)/i],[n,[r,c+"cast"]],[/(cros) [\w]+(?:\)| ([\w\.]+)\b)/i],[[r,we],n],[/panasonic;(viera)/i,/(netrange)mmh/i,/(nettv)\/(\d+\.[\w\.]+)/i,/(nintendo|playstation) ([wids345portablevuch]+)/i,/(xbox); +xbox ([^\);]+)/i,/\b(joli|palm)\b ?(?:os)?\/?([\w\.]*)/i,/(mint)[\/\(\) ]?(\w*)/i,/(mageia|vectorlinux)[; ]/i,/([kxln]?ubuntu|debian|suse|opensuse|gentoo|arch(?= linux)|slackware|fedora|mandriva|centos|pclinuxos|red ?hat|zenwalk|linpus|raspbian|plan 9|minix|risc os|contiki|deepin|manjaro|elementary os|sabayon|linspire)(?: gnu\/linux)?(?: enterprise)?(?:[- ]linux)?(?:-gnu)?[-\/ ]?(?!chrom|package)([-\w\.]*)/i,/(hurd|linux) ?([\w\.]*)/i,/(gnu) ?([\w\.]*)/i,/\b([-frentopcghs]{0,5}bsd|dragonfly)[\/ ]?(?!amd|[ix346]{1,2}86)([\w\.]*)/i,/(haiku) (\w+)/i],[r,n],[/(sunos) ?([\w\.\d]*)/i],[[r,"Solaris"],n],[/((?:open)?solaris)[-\/ ]?([\w\.]*)/i,/(aix) ((\d)(?=\.|\)| )[\w\.])*/i,/\b(beos|os\/2|amigaos|morphos|openvms|fuchsia|hp-ux|serenityos)/i,/(unix) ?([\w\.]*)/i],[r,n]]},A=function(d,p){if(typeof d===C&&(p=d,d=u),!(this instanceof A))return new A(d,p).getResult();var b=typeof m!==g&&m.navigator?m.navigator:u,v=d||(b&&b.userAgent?b.userAgent:R),B=b&&b.userAgentData?b.userAgentData:u,U=p?Te(ge,p):ge,f=b&&b.userAgent==v;return this.getBrowser=function(){var s={};return s[r]=u,s[n]=u,H.call(s,v,U.browser),s[k]=_e(s[n]),f&&b&&b.brave&&typeof b.brave.isBrave==E&&(s[r]="Brave"),s},this.getCPU=function(){var s={};return s[T]=u,H.call(s,v,U.cpu),s},this.getDevice=function(){var s={};return s[o]=u,s[e]=u,s[i]=u,H.call(s,v,U.device),f&&!s[i]&&B&&B.mobile&&(s[i]=l),f&&s[e]=="Macintosh"&&b&&typeof b.standalone!==g&&b.maxTouchPoints&&b.maxTouchPoints>2&&(s[e]="iPad",s[i]=w),s},this.getEngine=function(){var s={};return s[r]=u,s[n]=u,H.call(s,v,U.engine),s},this.getOS=function(){var s={};return s[r]=u,s[n]=u,H.call(s,v,U.os),f&&!s[r]&&B&&B.platform&&B.platform!="Unknown"&&(s[r]=B.platform.replace(/chrome os/i,we).replace(/macos/i,de)),s},this.getResult=function(){return {ua:this.getUA(),browser:this.getBrowser(),engine:this.getEngine(),os:this.getOS(),device:this.getDevice(),cpu:this.getCPU()}},this.getUA=function(){return v},this.setUA=function(s){return v=typeof s===O&&s.length>X?ae(s,X):s,this},this.setUA(v),this};A.VERSION=I,A.BROWSER=Z([r,n,k]),A.CPU=Z([T]),A.DEVICE=Z([e,o,i,L,l,S,w,_,W]),A.ENGINE=A.OS=Z([r,n]),typeof Y!==g?(typeof ie!==g&&ie.exports&&(Y=ie.exports=A),Y.UAParser=A):typeof define===E&&define.amd?define(function(){return A}):typeof m!==g&&(m.UAParser=A);var q=typeof m!==g&&(m.jQuery||m.Zepto);if(q&&!q.ua){var J=new A;q.ua=J.getResult(),q.ua.get=function(){return J.getUA()},q.ua.set=function(d){J.setUA(d);var p=J.getResult();for(var b in p)q.ua[b]=p[b];};}})(typeof window=="object"?window:Y);});function ee(m){for(var u=1;u<arguments.length;u++){var I=arguments[u];for(var R in I)m[R]=I[R];}return m}var Ie={read:function(m){return m[0]==='"'&&(m=m.slice(1,-1)),m.replace(/(%[\dA-F]{2})+/gi,decodeURIComponent)},write:function(m){return encodeURIComponent(m).replace(/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[BCD])/g,decodeURIComponent)}};function le(m,u){function I(h,E,g){if(!(typeof document>"u")){g=ee({},u,g),typeof g.expires=="number"&&(g.expires=new Date(Date.now()+g.expires*864e5)),g.expires&&(g.expires=g.expires.toUTCString()),h=encodeURIComponent(h).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape);var C="";for(var O in g)g[O]&&(C+="; "+O,g[O]!==true&&(C+="="+g[O].split(";")[0]));return document.cookie=h+"="+m.write(E,h)+C}}function R(h){if(!(typeof document>"u"||arguments.length&&!h)){for(var E=document.cookie?document.cookie.split("; "):[],g={},C=0;C<E.length;C++){var O=E[C].split("="),k=O.slice(1).join("=");try{var e=decodeURIComponent(O[0]);if(g[e]=m.read(k,e),h===e)break}catch(r){}}return h?g[h]:g}}return Object.create({set:I,get:R,remove:function(h,E){I(h,"",ee({},E,{expires:-1}));},withAttributes:function(h){return le(this.converter,ee({},this.attributes,h))},withConverter:function(h){return le(ee({},this.converter,h),this.attributes)}},{attributes:{value:Object.freeze(u)},converter:{value:Object.freeze(m)}})}var Oe=le(Ie,{path:"/"});var Ce=b(Ae(),1);var Ee;(V=>{let m;function u(){return m==null&&(m=new Ce.default(navigator.userAgent)),m}V.getUserAgentInfo=u;function I(){var c;if("orientation"in window)return false;let a="(any-pointer: coarse)",t=(c=window.matchMedia)==null?void 0:c.call(window,a);return navigator.maxTouchPoints===0||(t==null?void 0:t.media)===a&&!(t!=null&&t.matches)}V.isDesktopDevice=I;function R(){return u().getDevice().model==="iPhone"}V.isIPhone=R;function h(){let a=u().getOS();return a.name==="iOS"&&a.version!=null&&a.version.localeCompare("16.3",void 0,{numeric:true})>=0}V.isIOSDeviceWithExtendedCameraAccess=h;function E(){return "document"in window?window.document.createElement("canvas"):null}V.getCanvas=E;function g(a){return a.name==="iOS"&&a.version!=null&&["11.2.2","11.2.5","11.2.6"].includes(a.version)}async function C(){return c()}V.hasSIMDSupport=C;async function O(){return d()}V.hasThreadsSupport=O;function k(a,t,c){let x=a[t[0]];return x==null?false:t.length===1?typeof x===c:(typeof x=="function"||typeof x=="object")&&k(x,t.slice(1),c)}function e$1(){var P;let a=true,t=null,c=null,x=null,y=null;try{if(t=V.getCanvas(),c=V.getCanvas(),x=t==null?void 0:t.getContext("webgl"),y=c==null?void 0:c.getContext("experimental-webgl"),!k(window,["WebGLRenderingContext"],"function")||x==null&&y==null)throw new Error("WebGLRenderingContext is not supported")}catch(D){a=false;}finally{for(let D of [x,y])typeof(D==null?void 0:D.getExtension)=="function"&&((P=D.getExtension("WEBGL_lose_context"))==null||P.loseContext());x=null,y=null,t=null,c=null;}return a}function r(){let a=true,t=true,c=new Set;location.protocol.startsWith("http")||c.add("httpProtocol"),k(window,["isSecureContext"],"boolean")&&!window.isSecureContext&&c.add("secureContext"),!k(navigator,["mediaDevices","getUserMedia"],"function")&&!k(navigator,["enumerateDevices"],"function")&&!k(window,["MediaStreamTrack","getSources"],"function")&&(c.add("mediaDevices"),a=false),k(window,["Worker"],"function")||(c.add("webWorkers"),a=false,t=false),k(window,["WebAssembly"],"object")||(c.add("webAssembly"),a=false,t=false),k(window,["Blob"],"function")||(c.add("blob"),a=false,t=false),k(window,["URL","createObjectURL"],"function")||(c.add("urlObject"),a=false,t=false),k(window,["OffscreenCanvas"],"function")||c.add("offscreenCanvas"),e$1()||c.add("webGL");let x=u().getOS();return g(x)&&(c.add("webAssemblyErrorFree"),a=false,t=false),b$1()||c.add("sharedArrayBuffer"),a$1()||c.add("crossOriginIsolated"),N()||c.add("animationApi"),{fullSupport:a,scannerSupport:t,missingFeatures:[...c]}}V.checkBrowserCompatibility=r;async function i(){return e()}V.checkMultithreadingSupport=i;function o(){let a="scandit-device-id",t=b$2.getItem(a);if(t!=null&&t!=="")return t;if(t=Oe.get(a),t!=null&&t!=="")return b$2.setItem(a,t),t;let c=new Uint8Array(20);return crypto.getRandomValues(c),t=[...c].map(x=>{let y=x.toString(16);return y.length===1?`0${y}`:y}).join(""),b$2.setItem(a,t),t}V.getDeviceId=o;function n(a){return a instanceof HTMLElement||a!=null&&typeof a=="object"&&typeof a.tagName=="string"}V.isValidHTMLElement=n;function T(){var x,y;let a=u().getOS();if(a.name!=="iOS")return true;let[t,c]=(y=(x=a.version)==null?void 0:x.split(".").map(Number))!=null?y:[];return t>14||t===14&&c>=6}V.isSupportedIOSVersion=T;function L(){var a,t;return (t=(a=u().getBrowser().name)==null?void 0:a.toLowerCase().includes("safari"))!=null?t:false}V.isSafari=L;function l(){var t,c;return /iphone|ipod|ipad/.test((c=(t=u().getDevice().model)==null?void 0:t.toLowerCase())!=null?c:"")&&!L()}V.isIosWebView=l;async function w(){var t;return ((t=u().getOS().name)==null?void 0:t.toLowerCase())!=="android"?false:u().getUA().includes("wv")?true:[...(await fetch(document.location.toString(),{method:"HEAD"})).headers].some(([c])=>c.toLowerCase()==="x-requested-with")}V.isAndroidWebView=w;function S(){return u().getOS().name==="Windows"}V.isWindows=S;function _(){return u().getBrowser().name==="Firefox"}V.isFirefox=_;function W(){if("navigator"in globalThis){for(let a of ["vibrate","webkitVibrate","msVibrate","mozVibrate"])if(typeof navigator[a]=="function")return navigator[a]}}V.getSupportedVibrationMethod=W;function X(){return W()!=null&&!I()&&!S()&&!_()}V.isVibrationAvailable=X;function j(){return u().getOS().name==="iOS"}V.isIOS=j;function N(){return typeof globalThis.Animation<"u"&&typeof globalThis.KeyframeEffect<"u"&&typeof globalThis.Element.prototype.animate<"u"}V.isAnimationApiSupported=N;})(Ee||(Ee={}));
2
+ export{Ee as a};
@@ -0,0 +1 @@
1
+ import {a}from'./chunk-VQ7LLVHQ.js';var S={CONTAINER_CLASS_NAME:a.CONTAINER_CLASS_NAME,PAINTBOARD_CLASS_NAME:a.PAINTBOARD_CLASS_NAME,PAINTBOARD_CLASS_NAME_STATE_ON:a.PAINTBOARD_CLASS_NAME_STATE_ON,CONTROLS_CLASS_NAME:a.CONTROLS_CLASS_NAME,CONTROL_WIDGET_CLASS_NAME:a.CONTROL_WIDGET_CLASS_NAME,MIRRORED_CLASS_NAME:a.MIRRORED_CLASS_NAME,CAMERA_RECOVERY_CLASS_NAME:a.CAMERA_RECOVERY_CLASS_NAME,ERROR_CLASS_NAME:a.ERROR_CLASS_NAME,PAINTBOARDS_CONTAINER_CLASS_NAME:a.PAINTBOARDS_CONTAINER_CLASS_NAME,SINGLE_IMAGE_UPLOADER_CONTAINER_CLASS_NAME:a.SINGLE_IMAGE_UPLOADER_CONTAINER_CLASS_NAME,CANVAS_VIDEO_PREVIEW_CLASS_NAME:a.CANVAS_VIDEO_PREVIEW_CLASS_NAME,TORCH_SWITCH_CONTROL_CLASS_NAME:a.TORCH_SWITCH_CONTROL_CLASS_NAME,CAMERA_SWITCH_CONTROL_CLASS_NAME:a.CAMERA_SWITCH_CONTROL_CLASS_NAME,CAMERA_FOV_SWITCH_CONTROL_CLASS_NAME:a.CAMERA_FOV_SWITCH_CONTROL_CLASS_NAME,SHUTTER_BUTTON_CONTROL_CLASS_NAME:a.SHUTTER_BUTTON_CONTROL_CLASS_NAME,FROZEN_FRAME:a.FROZEN_FRAME};export{S as a};
@@ -0,0 +1 @@
1
+ var e;(o=>{function i(){let r="7.6.1";return r}o.sdkVersion=i;})(e||(e={}));export{e as a};
@@ -1 +1 @@
1
- import {e,c,d,b}from'./chunk-GGMX65YP.js';import {a}from'./chunk-KUVVZN66.js';import {n}from'./chunk-77BBIAZE.js';var s=class u{constructor(){this._text="";this._tag="";this._textColor=n.fromHex(e.hintStyle.textColor);this._backgroundColor=n.fromHex(e.hintStyle.backgroundColor);}static init(t,o){let n=new u;return n._text=t,n._tag=o,n}withIcon(t){return this._icon=t,this}withTextColor(t){return this._textColor=t,this}withBackgroundColor(t){return this._backgroundColor=t,this}withNotificationStyle(t){this._style=t;let o={info:e,error:b,warning:d,success:c}[t];return this._textColor=n.fromHex(o.hintStyle.textColor),this._backgroundColor=n.fromHex(o.hintStyle.backgroundColor),this}build(){return new a(this._text,this._tag,this._style,this._icon,this._textColor,this._backgroundColor)}};export{s as a};
1
+ import {e,c,d,b}from'./chunk-GGMX65YP.js';import {a}from'./chunk-KUVVZN66.js';import {n}from'./chunk-TPQTY3KB.js';var s=class u{constructor(){this._text="";this._tag="";this._textColor=n.fromHex(e.hintStyle.textColor);this._backgroundColor=n.fromHex(e.hintStyle.backgroundColor);}static init(t,o){let n=new u;return n._text=t,n._tag=o,n}withIcon(t){return this._icon=t,this}withTextColor(t){return this._textColor=t,this}withBackgroundColor(t){return this._backgroundColor=t,this}withNotificationStyle(t){this._style=t;let o={info:e,error:b,warning:d,success:c}[t];return this._textColor=n.fromHex(o.hintStyle.textColor),this._backgroundColor=n.fromHex(o.hintStyle.backgroundColor),this}build(){return new a(this._text,this._tag,this._style,this._icon,this._textColor,this._backgroundColor)}};export{s as a};
@@ -0,0 +1 @@
1
+ var A={CONTAINER_CLASS_NAME:"scandit-container",PAINTBOARDS_CONTAINER_CLASS_NAME:"scandit-paintboards",PAINTBOARD_CLASS_NAME:"scandit-paintboard",PAINTBOARD_CLASS_NAME_STATE_ON:"scandit-paintboard--camera-on",CONTROLS_CLASS_NAME:"scandit-controls",CONTROL_WIDGET_CLASS_NAME:"scandit-control-widget",MIRRORED_CLASS_NAME:"scandit-mirrored",CAMERA_RECOVERY_CLASS_NAME:"scandit-camera-recovery",ERROR_CLASS_NAME:"scandit-error",SINGLE_IMAGE_UPLOADER_CONTAINER_CLASS_NAME:"scandit-single-image-uploader-container",CANVAS_VIDEO_PREVIEW_CLASS_NAME:"scandit-canvas-video-preview",TORCH_SWITCH_CONTROL_CLASS_NAME:"torch",CAMERA_SWITCH_CONTROL_CLASS_NAME:"camera",CAMERA_FOV_SWITCH_CONTROL_CLASS_NAME:"camera-fov",SHUTTER_BUTTON_CONTROL_CLASS_NAME:"shutter",FROZEN_FRAME:"frozen-frame"};export{A as a};
@@ -1,4 +1,4 @@
1
- import {a as a$3}from'./chunk-MU6SADSF.js';import {a}from'./chunk-EV4OEANA.js';import {a as a$2}from'./chunk-3A4KLILV.js';import {a as a$1}from'./chunk-LSZZVJ6B.js';var l="scandit-arrows-up",t=class t extends a{constructor(){super();let a=this.attachShadow({mode:"open"});a.innerHTML=this.render(),a.prepend(t.createStyleElement().cloneNode(true));}static createStyleElement(){return a$1`${t.tag}{display:flex}${t.tag}[hidden]{display:none}.arrow{animation:blink 1.5s infinite;animation-duration:2s}.arrow-1{animation-delay:0s}.arrow-2{animation-delay:.5s}.arrow-3{animation-delay:1s}@keyframes blink{0%,to{opacity:0}50%{opacity:1}}`}static create(){return document.createElement(t.tag)}static register(){a$2({[t.tag]:t});}render(){return a$3`
1
+ import {a as a$2}from'./chunk-3A4KLILV.js';import {a as a$3}from'./chunk-MU6SADSF.js';import {a}from'./chunk-EV4OEANA.js';import {a as a$1}from'./chunk-LSZZVJ6B.js';var l="scandit-arrows-up",t=class t extends a{constructor(){super();let a=this.attachShadow({mode:"open"});a.innerHTML=this.render(),a.prepend(t.createStyleElement().cloneNode(true));}static createStyleElement(){return a$1`${t.tag}{display:flex}${t.tag}[hidden]{display:none}.arrow{animation:blink 1.5s infinite;animation-duration:2s}.arrow-1{animation-delay:0s}.arrow-2{animation-delay:.5s}.arrow-3{animation-delay:1s}@keyframes blink{0%,to{opacity:0}50%{opacity:1}}`}static create(){return document.createElement(t.tag)}static register(){a$2({[t.tag]:t});}render(){return a$3`
2
2
  <svg width="120" height="45" viewBox="0 0 120 45" fill="none">
3
3
  <path
4
4
  class="arrow arrow-1"
@@ -1 +1 @@
1
- import {a}from'./chunk-BDLLVGRH.js';import {c}from'./chunk-WGLHZXRT.js';import {c as c$1,b}from'./chunk-GX4YCYCH.js';import {n as n$1,d,e,m,l as l$1}from'./chunk-77BBIAZE.js';var l=class{static fromJSON(t){return (t==null?void 0:t.type)==="tapToFocus"?new b:null}},s=class{static fromJSON(t){return (t==null?void 0:t.type)==="swipeToZoom"?new c$1:null}};function n(e){let t="document"in globalThis?globalThis.document:void 0,o=t==null?void 0:t.createRange().createContextualFragment(e);if(o)return o.firstElementChild}function y(e$1){var t;return {Camera:{Settings:{preferredResolution:e$1.Camera.Settings.preferredResolution,zoomFactor:e$1.Camera.Settings.zoomFactor,zoomGestureZoomFactor:e$1.Camera.Settings.zoomGestureZoomFactor,focusGestureStrategy:e$1.Camera.Settings.focusGestureStrategy},defaultPosition:(t=e$1.Camera.defaultPosition)!=null?t:null,availablePositions:e$1.Camera.availablePositions},SingleImageUploader:{Settings:{iconElement:n(e$1.SingleImageUploader.Settings.iconElement),informationElement:n(e$1.SingleImageUploader.Settings.informationElement),buttonElement:n(e$1.SingleImageUploader.Settings.buttonElement),containerStyle:e$1.SingleImageUploader.Settings.containerStyle,iconStyle:e$1.SingleImageUploader.Settings.iconStyle,informationStyle:e$1.SingleImageUploader.Settings.informationStyle,buttonStyle:e$1.SingleImageUploader.Settings.buttonStyle,onlyCameraCapture:e$1.SingleImageUploader.Settings.onlyCameraCapture}},DataCaptureView:{scanAreaMargins:m.fromJSON(JSON.parse(e$1.DataCaptureView.scanAreaMargins)),pointOfInterest:e.fromJSON(JSON.parse(e$1.DataCaptureView.pointOfInterest)),logoStyle:e$1.DataCaptureView.logoStyle,logoAnchor:e$1.DataCaptureView.logoAnchor,logoOffset:e.fromJSON(JSON.parse(e$1.DataCaptureView.logoOffset)),focusGesture:l.fromJSON(JSON.parse(e$1.DataCaptureView.focusGesture)),zoomGesture:s.fromJSON(JSON.parse(e$1.DataCaptureView.zoomGesture)),cameraRecoveryText:e$1.DataCaptureView.cameraRecoveryText},LaserlineViewfinder:{width:d.fromJSON(JSON.parse(e$1.LaserlineViewfinder.width)),enabledColor:n$1.fromJSON(e$1.LaserlineViewfinder.enabledColor),disabledColor:n$1.fromJSON(e$1.LaserlineViewfinder.disabledColor)},RectangularViewfinder:Object.keys(e$1.RectangularViewfinder.styles).reduce((o,u)=>{let i=e$1.RectangularViewfinder.styles[u];return o.styles[u]={size:l$1.fromJSON(JSON.parse(i.size)),color:n$1.fromJSON(i.color),style:i.style,lineStyle:i.lineStyle,dimming:Number.parseFloat(i.dimming.toString()),animation:c.fromJSON(JSON.parse(i.animation))},o},{defaultStyle:e$1.RectangularViewfinder.defaultStyle,styles:{}}),AimerViewfinder:{frameColor:n$1.fromJSON(e$1.AimerViewfinder.frameColor),dotColor:n$1.fromJSON(e$1.AimerViewfinder.dotColor)},Brush:{fillColor:n$1.fromJSON(e$1.Brush.fillColor),strokeColor:n$1.fromJSON(e$1.Brush.strokeColor),strokeWidth:e$1.Brush.strokeWidth},Feedback:{defaultVibrationPattern:e$1.Feedback.defaultVibrationPattern}}}var C=y({DataCaptureView:{focusGesture:"null",zoomGesture:"null",logoAnchor:"bottomRight",logoStyle:"extended",logoOffset:JSON.stringify({x:{value:0,unit:"fraction"},y:{value:0,unit:"fraction"}}),pointOfInterest:JSON.stringify({x:{value:.5,unit:"fraction"},y:{value:.5,unit:"fraction"}}),scanAreaMargins:JSON.stringify({left:{value:0,unit:"fraction"},right:{value:0,unit:"fraction"},top:{value:0,unit:"fraction"},bottom:{value:0,unit:"fraction"}}),cameraRecoveryText:"(This text is updated from translations)"},Camera:{Settings:{preferredResolution:"auto",zoomFactor:1,focusGestureStrategy:"manualUntilCapture",zoomGestureZoomFactor:2},defaultPosition:"worldFacing",availablePositions:["worldFacing","userFacing"]},SingleImageUploader:{Settings:{iconElement:atob(a),informationElement:"<p data-scandit-default>(This text is updated from translations)</p>",buttonElement:"<div data-scandit-default>(This text is updated from translations)</div>",containerStyle:{backgroundColor:"#FFFFFF"},iconStyle:{fill:"#121619"},informationStyle:{color:"#121619",marginBottom:"2em"},buttonStyle:{color:"#FFFFFF",backgroundColor:"#121619",fontWeight:"bold",padding:"1.25em",width:"12em",textAlign:"center",textTransform:"uppercase"},onlyCameraCapture:false}},LaserlineViewfinder:{width:JSON.stringify({unit:"fraction",value:.8}),enabledColor:"#FFFFFFFF",disabledColor:"#00000000"},AimerViewfinder:{frameColor:"#FFFFFFFF",dotColor:"#FFFFFFCC"},RectangularViewfinder:{defaultStyle:"rounded",styles:{rounded:{size:JSON.stringify({aspect:1,shorterDimension:{unit:"fraction",value:.75}}),color:"#FFFFFFFF",style:"rounded",lineStyle:"light",dimming:0,animation:JSON.stringify({looping:true})},square:{size:JSON.stringify({aspect:1,shorterDimension:{unit:"fraction",value:.75}}),color:"#FFFFFFFF",style:"square",lineStyle:"light",dimming:0,animation:JSON.stringify({looping:true})}}},Brush:{fillColor:"#00000000",strokeColor:"#00000000",strokeWidth:0},Feedback:{defaultVibrationPattern:[300]}});function O(e){C=e;}export{l as a,s as b,y as c,C as d,O as e};
1
+ import {a}from'./chunk-BDLLVGRH.js';import {c}from'./chunk-WGLHZXRT.js';import {c as c$1,b}from'./chunk-GX4YCYCH.js';import {n as n$1,d,e,m,l as l$1}from'./chunk-TPQTY3KB.js';var l=class{static fromJSON(t){return (t==null?void 0:t.type)==="tapToFocus"?new b:null}},s=class{static fromJSON(t){return (t==null?void 0:t.type)==="swipeToZoom"?new c$1:null}};function n(e){let t="document"in globalThis?globalThis.document:void 0,o=t==null?void 0:t.createRange().createContextualFragment(e);if(o)return o.firstElementChild}function y(e$1){var t;return {Camera:{Settings:{preferredResolution:e$1.Camera.Settings.preferredResolution,zoomFactor:e$1.Camera.Settings.zoomFactor,zoomGestureZoomFactor:e$1.Camera.Settings.zoomGestureZoomFactor,focusGestureStrategy:e$1.Camera.Settings.focusGestureStrategy},defaultPosition:(t=e$1.Camera.defaultPosition)!=null?t:null,availablePositions:e$1.Camera.availablePositions},SingleImageUploader:{Settings:{iconElement:n(e$1.SingleImageUploader.Settings.iconElement),informationElement:n(e$1.SingleImageUploader.Settings.informationElement),buttonElement:n(e$1.SingleImageUploader.Settings.buttonElement),containerStyle:e$1.SingleImageUploader.Settings.containerStyle,iconStyle:e$1.SingleImageUploader.Settings.iconStyle,informationStyle:e$1.SingleImageUploader.Settings.informationStyle,buttonStyle:e$1.SingleImageUploader.Settings.buttonStyle,onlyCameraCapture:e$1.SingleImageUploader.Settings.onlyCameraCapture}},DataCaptureView:{scanAreaMargins:m.fromJSON(JSON.parse(e$1.DataCaptureView.scanAreaMargins)),pointOfInterest:e.fromJSON(JSON.parse(e$1.DataCaptureView.pointOfInterest)),logoStyle:e$1.DataCaptureView.logoStyle,logoAnchor:e$1.DataCaptureView.logoAnchor,logoOffset:e.fromJSON(JSON.parse(e$1.DataCaptureView.logoOffset)),focusGesture:l.fromJSON(JSON.parse(e$1.DataCaptureView.focusGesture)),zoomGesture:s.fromJSON(JSON.parse(e$1.DataCaptureView.zoomGesture)),cameraRecoveryText:e$1.DataCaptureView.cameraRecoveryText},LaserlineViewfinder:{width:d.fromJSON(JSON.parse(e$1.LaserlineViewfinder.width)),enabledColor:n$1.fromJSON(e$1.LaserlineViewfinder.enabledColor),disabledColor:n$1.fromJSON(e$1.LaserlineViewfinder.disabledColor)},RectangularViewfinder:Object.keys(e$1.RectangularViewfinder.styles).reduce((o,u)=>{let i=e$1.RectangularViewfinder.styles[u];return o.styles[u]={size:l$1.fromJSON(JSON.parse(i.size)),color:n$1.fromJSON(i.color),style:i.style,lineStyle:i.lineStyle,dimming:Number.parseFloat(i.dimming.toString()),animation:c.fromJSON(JSON.parse(i.animation))},o},{defaultStyle:e$1.RectangularViewfinder.defaultStyle,styles:{}}),AimerViewfinder:{frameColor:n$1.fromJSON(e$1.AimerViewfinder.frameColor),dotColor:n$1.fromJSON(e$1.AimerViewfinder.dotColor)},Brush:{fillColor:n$1.fromJSON(e$1.Brush.fillColor),strokeColor:n$1.fromJSON(e$1.Brush.strokeColor),strokeWidth:e$1.Brush.strokeWidth},Feedback:{defaultVibrationPattern:e$1.Feedback.defaultVibrationPattern}}}var C=y({DataCaptureView:{focusGesture:"null",zoomGesture:"null",logoAnchor:"bottomRight",logoStyle:"extended",logoOffset:JSON.stringify({x:{value:0,unit:"fraction"},y:{value:0,unit:"fraction"}}),pointOfInterest:JSON.stringify({x:{value:.5,unit:"fraction"},y:{value:.5,unit:"fraction"}}),scanAreaMargins:JSON.stringify({left:{value:0,unit:"fraction"},right:{value:0,unit:"fraction"},top:{value:0,unit:"fraction"},bottom:{value:0,unit:"fraction"}}),cameraRecoveryText:"(This text is updated from translations)"},Camera:{Settings:{preferredResolution:"auto",zoomFactor:1,focusGestureStrategy:"manualUntilCapture",zoomGestureZoomFactor:2},defaultPosition:"worldFacing",availablePositions:["worldFacing","userFacing"]},SingleImageUploader:{Settings:{iconElement:atob(a),informationElement:"<p data-scandit-default>(This text is updated from translations)</p>",buttonElement:"<div data-scandit-default>(This text is updated from translations)</div>",containerStyle:{backgroundColor:"#FFFFFF"},iconStyle:{fill:"#121619"},informationStyle:{color:"#121619",marginBottom:"2em"},buttonStyle:{color:"#FFFFFF",backgroundColor:"#121619",fontWeight:"bold",padding:"1.25em",width:"12em",textAlign:"center",textTransform:"uppercase"},onlyCameraCapture:false}},LaserlineViewfinder:{width:JSON.stringify({unit:"fraction",value:.8}),enabledColor:"#FFFFFFFF",disabledColor:"#00000000"},AimerViewfinder:{frameColor:"#FFFFFFFF",dotColor:"#FFFFFFCC"},RectangularViewfinder:{defaultStyle:"rounded",styles:{rounded:{size:JSON.stringify({aspect:1,shorterDimension:{unit:"fraction",value:.75}}),color:"#FFFFFFFF",style:"rounded",lineStyle:"light",dimming:0,animation:JSON.stringify({looping:true})},square:{size:JSON.stringify({aspect:1,shorterDimension:{unit:"fraction",value:.75}}),color:"#FFFFFFFF",style:"square",lineStyle:"light",dimming:0,animation:JSON.stringify({looping:true})}}},Brush:{fillColor:"#00000000",strokeColor:"#00000000",strokeWidth:0},Feedback:{defaultVibrationPattern:[300]}});function O(e){C=e;}export{l as a,s as b,y as c,C as d,O as e};
@@ -4,8 +4,8 @@ import { ConfigurePhase } from './sdk.js';
4
4
  export { WorkerMain } from './worker/WorkerMain.js';
5
5
  export { Anchor, Color, ColorJSON, Direction, JSONType, MarginsWithUnit, MarginsWithUnitJSON, MeasureUnit, NumberWithUnit, NumberWithUnitJSON, Orientation, Point, PointJSON, PointWithUnit, PointWithUnitJSON, Quadrilateral, QuadrilateralJSON, Rect, RectJSON, RectWithUnit, RectWithUnitJSON, Size, SizeJSON, SizeWithAspect, SizeWithUnit, SizeWithUnitAndAspect, SizeWithUnitAndAspectJSON, SizeWithUnitJSON, SizingMode } from './Common.js';
6
6
  export { OverrideState } from './worker/OverrideState.js';
7
- import { D as DataCaptureLoader } from './Camera-DYYZ5vW1.js';
8
- export { g as Camera, h as CameraAccess, e as CameraJSON, C as CameraPosition, n as CameraSettings, k as CameraSettingsFromJSON, l as CameraSettingsJSON, j as CameraSettingsJSONBase, o as Change, H as ContextStatus, G as ContextStatusJSON, u as DataCaptureComponent, t as DataCaptureComponentJSON, B as DataCaptureContext, x as DataCaptureContextCreationOptions, y as DataCaptureContextJSON, E as DataCaptureContextListener, S as DataCaptureLoaderOptions, p as DataCaptureMode, r as DataCaptureModeJSON, J as DataCaptureOverlay, N as DataCaptureView, M as DataCaptureViewConnectOptions, L as DataCaptureViewJSON, K as DataCaptureViewListener, i as DeviceCamera, F as FocusGestureStrategy, O as FrameData, a as FrameSource, d as FrameSourceJSON, c as FrameSourceListener, b as FrameSourceState, P as PrivateChangeSet, s as PrivateDataCaptureComponent, w as PrivateDataCaptureContext, v as PrivateDataCaptureContextOptions, q as PrivateDataCaptureMode, A as PrivateFrameHandler, z as PrivateFrameHandlerResponse, Q as PrivateLoadableFrameData, I as PrivateMirrorAxis, T as TorchState, f as VideoFrameResolution, V as VideoResolution, R as convertToPublicFrameData, m as isCameraFrameSource } from './Camera-DYYZ5vW1.js';
7
+ import { D as DataCaptureLoader } from './Camera-C_4xOv5n.js';
8
+ export { g as Camera, h as CameraAccess, e as CameraJSON, C as CameraPosition, n as CameraSettings, k as CameraSettingsFromJSON, l as CameraSettingsJSON, j as CameraSettingsJSONBase, o as Change, H as ContextStatus, G as ContextStatusJSON, u as DataCaptureComponent, t as DataCaptureComponentJSON, B as DataCaptureContext, x as DataCaptureContextCreationOptions, y as DataCaptureContextJSON, E as DataCaptureContextListener, S as DataCaptureLoaderOptions, p as DataCaptureMode, r as DataCaptureModeJSON, J as DataCaptureOverlay, N as DataCaptureView, M as DataCaptureViewConnectOptions, L as DataCaptureViewJSON, K as DataCaptureViewListener, i as DeviceCamera, F as FocusGestureStrategy, O as FrameData, a as FrameSource, d as FrameSourceJSON, c as FrameSourceListener, b as FrameSourceState, P as PrivateChangeSet, s as PrivateDataCaptureComponent, w as PrivateDataCaptureContext, v as PrivateDataCaptureContextOptions, q as PrivateDataCaptureMode, A as PrivateFrameHandler, z as PrivateFrameHandlerResponse, Q as PrivateLoadableFrameData, I as PrivateMirrorAxis, T as TorchState, f as VideoFrameResolution, V as VideoResolution, R as convertToPublicFrameData, m as isCameraFrameSource } from './Camera-C_4xOv5n.js';
9
9
  export { LoadingStatus, LoadingStatusSubscriber, ProgressInfo, default as loadingStatus } from './LoadingStatus.js';
10
10
  export { DeepMutable, DeepPartial, DistributiveKeyOf, MethodSignature, Mutable, Optional, Prettify, assert, assertUnreachable, assertUnreachableThrowException } from './tsHelper.js';
11
11
  export { AimerViewfinder } from './AimerViewfinder.js';
package/build/js/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import {a as a$1}from'./chunks/chunk-ACFJP5SR.js';export{a as DataCaptureLoader}from'./chunks/chunk-VGSPU525.js';export{a as NotificationBuilder}from'./chunks/chunk-6YZS76QW.js';export{a as WorkerMain}from'./chunks/chunk-BMMGUF55.js';import {a as a$5}from'./chunks/chunk-AIC4H5KG.js';export{a as OverrideState}from'./chunks/chunk-6W7FX6LD.js';export{c as ScanditIconBuilder,b as ScanditIconForIconType,a as ScanditIconType}from'./chunks/chunk-LLU62JKU.js';export{a as SingleImageUploader}from'./chunks/chunk-7WQXUZB4.js';export{a as SingleImageUploaderSettings}from'./chunks/chunk-DAFXSVRW.js';export{c as CameraFOVSwitchControl,b as CameraSwitchControl,a as TorchSwitchControl}from'./chunks/chunk-T5EUB6UG.js';export{a as NoViewfinder}from'./chunks/chunk-4ZMCJXZS.js';export{a as convertToPublicFrameData}from'./chunks/chunk-UHFABUTI.js';export{a as ImageFrameSource}from'./chunks/chunk-BS7MAI4E.js';export{a as LaserlineViewfinder}from'./chunks/chunk-TSOWSKE3.js';export{a as PrivateNoneLocationSelection,b as RadiusLocationSelection,c as RectangularLocationSelection}from'./chunks/chunk-DCZONWJ2.js';export{a as RectangularViewfinder}from'./chunks/chunk-LEE5JACK.js';export{b as ScanditIcon,a as ScanditIconShape}from'./chunks/chunk-FZWKZSE4.js';export{a as DataCaptureVersion}from'./chunks/chunk-VQ2HNQ6B.js';export{a as DataCaptureView}from'./chunks/chunk-SHODT6PR.js';import {a as a$9}from'./chunks/chunk-N5YZEC56.js';export{a as AnchorPositions}from'./chunks/chunk-5FUZURCZ.js';export{a as NotificationConfiguration}from'./chunks/chunk-KUVVZN66.js';export{a as NotificationStyle}from'./chunks/chunk-RXT3JWWR.js';import {a as a$4}from'./chunks/chunk-VJB527QZ.js';import {a as a$3}from'./chunks/chunk-GHTCNOQN.js';export{a as Localization}from'./chunks/chunk-GHTCNOQN.js';export{a as Feedback}from'./chunks/chunk-5QETTOSS.js';export{a as Sound}from'./chunks/chunk-AUWF33RB.js';export{a as Vibration}from'./chunks/chunk-JDX5TFXN.js';export{a as AimerViewfinder}from'./chunks/chunk-O4TEQJ6H.js';export{a as Brush}from'./chunks/chunk-EUZWZFRQ.js';export{a as Camera}from'./chunks/chunk-TAMEEK7W.js';export{a as CameraAccess}from'./chunks/chunk-WAUGWWV3.js';export{a as DataCaptureContext}from'./chunks/chunk-6G52QHDH.js';import {a as a$a,c}from'./chunks/chunk-EPP3SBHK.js';import {a as a$2}from'./chunks/chunk-NKCR7VPO.js';import {b}from'./chunks/chunk-6H6FKGVE.js';export{b as loadingStatus}from'./chunks/chunk-6H6FKGVE.js';export{a as DataCaptureContextSettings}from'./chunks/chunk-7SW2PEHB.js';export{a as ScanditHTMLElement}from'./chunks/chunk-EV4OEANA.js';export{a as assert,b as assertUnreachable,c as assertUnreachableThrowException}from'./chunks/chunk-FTD535WI.js';import {a as a$8}from'./chunks/chunk-GPJEB376.js';import {a as a$b}from'./chunks/chunk-QCZSSQAQ.js';export{a as DataCaptureError}from'./chunks/chunk-QCZSSQAQ.js';import {a as a$7}from'./chunks/chunk-CVRIZLTM.js';export{a as BrowserHelper}from'./chunks/chunk-CVRIZLTM.js';export{a as Feature}from'./chunks/chunk-5LIWL2C4.js';import {a as a$6}from'./chunks/chunk-XR65N6EG.js';export{a as Logger}from'./chunks/chunk-XR65N6EG.js';export{c as CameraPosition,g as CameraSettings,e as FocusGestureStrategy,a as FrameSourceState,b as TorchState,d as VideoResolution,f as isCameraFrameSource}from'./chunks/chunk-OPX62GWU.js';export{c as RectangularViewfinderAnimation,b as RectangularViewfinderLineStyle,a as RectangularViewfinderStyle}from'./chunks/chunk-WGLHZXRT.js';export{a as LogoStyle,c as SwipeToZoom,b as TapToFocus}from'./chunks/chunk-GX4YCYCH.js';export{q as Anchor,n as Color,p as Direction,m as MarginsWithUnit,c as MeasureUnit,d as NumberWithUnit,o as Orientation,a as Point,e as PointWithUnit,b as Quadrilateral,f as Rect,g as RectWithUnit,i as Size,j as SizeWithAspect,h as SizeWithUnit,l as SizeWithUnitAndAspect,k as SizingMode}from'./chunks/chunk-77BBIAZE.js';export{a as ContextStatus,b as PrivateMirrorAxis}from'./chunks/chunk-WUHKODFA.js';a$1();var a=a$2;async function k(){var e;a.configurePhase="unconfigured",a.configurePromise=null,(e=a.mainDataCaptureLoader)!=null&&e.terminateDataCaptureWorker&&await a.mainDataCaptureLoader.terminateDataCaptureWorker(true);}function d({percentage:e}){for(let o of a$9.values())o.setProgressBarPercentage(e);}function E(){var s,p;function e(v){return ["auto","off","on"].includes(v)}let o=new URLSearchParams(window.location.search),[r="auto",i="auto"]=[(s=o.get("pthreads"))==null?void 0:s.toLowerCase(),(p=o.get("simd"))==null?void 0:p.toLowerCase()];return {overrideThreadsSupport:e(r)?r:"auto",overrideSimdSupport:e(i)?i:"auto"}}async function K(e){if(a$a()&&typeof e.licenseDataPath!="string")throw new a$b({name:"MisconfigurationError",message:'"licenseDataPath" string is missing or not valid'});if(a$a()&&typeof e.licenseDataPath=="string"){let r=await c({licenseDataPath:e.licenseDataPath});if(r==null)throw new Error("Cannot retrieve license key for Electron");e.licenseKey=r.licenseKey;}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 o=e.moduleLoaders.map(r=>r.moduleName);if(!["BarcodeCapture","IdCapture","LabelCapture"].includes(o[0]))throw new a$b({name:"MisconfigurationError",message:'Main modules must be loaded before side modules. For example "BarcodeCapture" must be loaded before "Parser".'})}async function B(e,o){let r=new Map,i=new Map;for(let s of e)i.set(s.moduleName,s.load(o));await Promise.all(i.values());for(let[s,p]of i)r.set(s,await p);return r}async function tr(e){if(a.configurePhase!=="unconfigured"&&a.configurePromise!=null)return a.configurePromise;a$3.getInstance().updateIfMissing(a$4);async function o(){var s;a$2.configurePhase="started",await K(e);let r={...E(),...e,libraryLocation:a$5(e.libraryLocation),logLevel:(s=e.logLevel)!=null?s:a$6.Level.Debug,verifyResponseHash:true,loadProgressNotifier:b.notify.bind(b)};a$6.setLevel(r.logLevel),a$2.userLicenseKey=r.licenseKey,a$2.libraryLocation=r.libraryLocation,b.subscribe(d);let i=a$7.checkBrowserCompatibility();if(!i.fullSupport&&!i.scannerSupport)throw new a$8(i);a$7.isSupportedIOSVersion()||a$6.log(a$6.Level.Warn,`Warning: Minimum supported iOS version is 14.6.
1
+ import {a as a$5}from'./chunks/chunk-GC2ECHKL.js';import {a as a$1}from'./chunks/chunk-ACFJP5SR.js';export{a as DataCaptureLoader}from'./chunks/chunk-VGSPU525.js';export{a as WorkerMain}from'./chunks/chunk-KK47T3R2.js';export{a as OverrideState}from'./chunks/chunk-6W7FX6LD.js';import {a as a$6}from'./chunks/chunk-AIC4H5KG.js';export{a as NotificationBuilder}from'./chunks/chunk-VBRTZG3W.js';export{c as ScanditIconBuilder,b as ScanditIconForIconType,a as ScanditIconType}from'./chunks/chunk-6TG3MN7M.js';export{a as SingleImageUploader}from'./chunks/chunk-4TDWWHP2.js';export{a as SingleImageUploaderSettings}from'./chunks/chunk-5S5BT5PK.js';export{c as CameraFOVSwitchControl,b as CameraSwitchControl,a as TorchSwitchControl}from'./chunks/chunk-FS52JIW4.js';export{a as NoViewfinder}from'./chunks/chunk-4ZMCJXZS.js';export{a as convertToPublicFrameData}from'./chunks/chunk-UHFABUTI.js';export{a as ImageFrameSource}from'./chunks/chunk-BS7MAI4E.js';export{a as LaserlineViewfinder}from'./chunks/chunk-H75G3H4R.js';export{a as PrivateNoneLocationSelection,b as RadiusLocationSelection,c as RectangularLocationSelection}from'./chunks/chunk-AKDTQZ73.js';export{a as RectangularViewfinder}from'./chunks/chunk-6NVWG2LP.js';export{b as ScanditIcon,a as ScanditIconShape}from'./chunks/chunk-27Z5CYJL.js';export{a as DataCaptureVersion}from'./chunks/chunk-VBNI76IP.js';export{a as DataCaptureView}from'./chunks/chunk-BPNTTDTU.js';import {a as a$a}from'./chunks/chunk-N5YZEC56.js';export{a as AnchorPositions}from'./chunks/chunk-EKOWJS3E.js';export{a as NotificationConfiguration}from'./chunks/chunk-KUVVZN66.js';export{a as NotificationStyle}from'./chunks/chunk-RXT3JWWR.js';import {a as a$4}from'./chunks/chunk-VJB527QZ.js';import {a as a$3}from'./chunks/chunk-GHTCNOQN.js';export{a as Localization}from'./chunks/chunk-GHTCNOQN.js';export{a as Feedback}from'./chunks/chunk-N2GWO3EX.js';export{a as Sound}from'./chunks/chunk-AUWF33RB.js';export{a as Vibration}from'./chunks/chunk-SJJGHQ52.js';export{a as AimerViewfinder}from'./chunks/chunk-26DQPDMK.js';export{a as Brush}from'./chunks/chunk-PUP3NNKU.js';export{a as Camera}from'./chunks/chunk-Q5DQ3FTE.js';export{a as CameraAccess}from'./chunks/chunk-DFFYK2ZZ.js';export{a as DataCaptureContext}from'./chunks/chunk-L3BBOGIY.js';import {a as a$b,c}from'./chunks/chunk-LISC6VSM.js';import {a as a$2}from'./chunks/chunk-NKCR7VPO.js';import {b}from'./chunks/chunk-6H6FKGVE.js';export{b as loadingStatus}from'./chunks/chunk-6H6FKGVE.js';export{a as DataCaptureContextSettings}from'./chunks/chunk-7SW2PEHB.js';export{a as ScanditHTMLElement}from'./chunks/chunk-EV4OEANA.js';export{a as assert,b as assertUnreachable,c as assertUnreachableThrowException}from'./chunks/chunk-FTD535WI.js';import {a as a$9}from'./chunks/chunk-GPJEB376.js';import {a as a$c}from'./chunks/chunk-QCZSSQAQ.js';export{a as DataCaptureError}from'./chunks/chunk-QCZSSQAQ.js';import {a as a$8}from'./chunks/chunk-UCD6YLP3.js';export{a as BrowserHelper}from'./chunks/chunk-UCD6YLP3.js';export{a as Feature}from'./chunks/chunk-NVK73TNL.js';import {a as a$7}from'./chunks/chunk-XR65N6EG.js';export{a as Logger}from'./chunks/chunk-XR65N6EG.js';export{c as CameraPosition,g as CameraSettings,e as FocusGestureStrategy,a as FrameSourceState,b as TorchState,d as VideoResolution,f as isCameraFrameSource}from'./chunks/chunk-7ELPJFJV.js';export{c as RectangularViewfinderAnimation,b as RectangularViewfinderLineStyle,a as RectangularViewfinderStyle}from'./chunks/chunk-WGLHZXRT.js';export{a as LogoStyle,c as SwipeToZoom,b as TapToFocus}from'./chunks/chunk-GX4YCYCH.js';export{q as Anchor,n as Color,p as Direction,m as MarginsWithUnit,c as MeasureUnit,d as NumberWithUnit,o as Orientation,a as Point,e as PointWithUnit,b as Quadrilateral,f as Rect,g as RectWithUnit,i as Size,j as SizeWithAspect,h as SizeWithUnit,l as SizeWithUnitAndAspect,k as SizingMode}from'./chunks/chunk-TPQTY3KB.js';export{a as ContextStatus,b as PrivateMirrorAxis}from'./chunks/chunk-WUHKODFA.js';a$1();var a=a$2;async function A(){var e;a.configurePhase="unconfigured",a.configurePromise=null,(e=a.mainDataCaptureLoader)!=null&&e.terminateDataCaptureWorker&&await a.mainDataCaptureLoader.terminateDataCaptureWorker(true);}function g({percentage:e}){for(let r of a$a.values())r.setProgressBarPercentage(e);}function B(){var i,u,f;function e(b){return ["auto","off","on"].includes(b)}let r=new URLSearchParams(window.location.search),[o="auto",s="auto",n=false]=[(i=r.get("pthreads"))==null?void 0:i.toLowerCase(),(u=r.get("simd"))==null?void 0:u.toLowerCase(),((f=r.get("forceAllPolyfills"))==null?void 0:f.toLowerCase())==="true"];return {overrideThreadsSupport:e(o)?o:"auto",overrideSimdSupport:e(s)?s:"auto",forceAllPolyfills:n}}async function I(e){if(a$b()&&typeof e.licenseDataPath!="string")throw new a$c({name:"MisconfigurationError",message:'"licenseDataPath" string is missing or not valid'});if(a$b()&&typeof e.licenseDataPath=="string"){let o=await c({licenseDataPath:e.licenseDataPath});if(o==null)throw new Error("Cannot retrieve license key for Electron");e.licenseKey=o.licenseKey;}if(e.licenseKey==null||e.licenseKey.trim().length<64)throw new a$c({name:"NoLicenseKeyError",message:"No license key provided"});if(typeof e.libraryLocation!="string")throw new a$c({name:"MisconfigurationError",message:'Option "libraryLocation" was not provided'});if(!Array.isArray(e.moduleLoaders)||e.moduleLoaders.length===0)throw new a$c({name:"MisconfigurationError",message:'Option "moduleLoaders" is missing or empty'});let r=e.moduleLoaders.map(o=>o.moduleName);if(!["BarcodeCapture","IdCapture","LabelCapture"].includes(r[0]))throw new a$c({name:"MisconfigurationError",message:'Main modules must be loaded before side modules. For example "BarcodeCapture" must be loaded before "Parser".'})}async function z(e,r){let o=new Map,s=new Map;for(let n of e)s.set(n.moduleName,n.load(r));await Promise.all(s.values());for(let[n,i]of s)o.set(n,await i);return o}async function nr(e){if(a.configurePhase!=="unconfigured"&&a.configurePromise!=null)return a.configurePromise;a$3.getInstance().updateIfMissing(a$4);async function r(){var f;a$2.configurePhase="started";let{forceAllPolyfills:o,overrideThreadsSupport:s,overrideSimdSupport:n}=B();await a$5({forceAllPolyfills:o}),await I(e);let i={overrideThreadsSupport:s,overrideSimdSupport:n,...e,libraryLocation:a$6(e.libraryLocation),logLevel:(f=e.logLevel)!=null?f:a$7.Level.Debug,verifyResponseHash:true,loadProgressNotifier:b.notify.bind(b)};a$7.setLevel(i.logLevel),a$2.userLicenseKey=i.licenseKey,a$2.libraryLocation=i.libraryLocation,b.subscribe(g);let u=a$8.checkBrowserCompatibility();if(!u.fullSupport&&!u.scannerSupport)throw new a$9(u);a$8.isSupportedIOSVersion()||a$7.log(a$7.Level.Warn,`Warning: Minimum supported iOS version is 14.6.
2
2
  Please check the minimum system requirements here:
3
- https://docs.scandit.com/system-requirements#web-sdk`),a$2.dataCaptureLoaders=await B(r.moduleLoaders,r),a$2.mainDataCaptureLoader=[...a$2.dataCaptureLoaders.entries()][0][1],a$2.configurePhase="done",b.unsubscribe(d);}return a$2.configurePromise=o().catch(r=>{throw k(),b.unsubscribe(d),r}),a$2.configurePromise}function ar(e,o){switch(a.configurePhase=e,e){case "done":o&&(a.mainDataCaptureLoader=o),a.configurePromise=Promise.resolve();break;case "unconfigured":a.configurePromise=null;break;default:throw new Error(`Invalid configure phase: ${e}`)}}
4
- export{ar as __setConfigurePhase,tr as configure,k as resetConfigure};
3
+ https://docs.scandit.com/system-requirements#web-sdk`),a$2.dataCaptureLoaders=await z(i.moduleLoaders,i),a$2.mainDataCaptureLoader=[...a$2.dataCaptureLoaders.entries()][0][1],a$2.configurePhase="done",b.unsubscribe(g);}return a$2.configurePromise=r().catch(o=>{throw A(),b.unsubscribe(g),o}),a$2.configurePromise}function mr(e,r){switch(a.configurePhase=e,e){case "done":r&&(a.mainDataCaptureLoader=r),a.configurePromise=Promise.resolve();break;case "unconfigured":a.configurePromise=null;break;default:throw new Error(`Invalid configure phase: ${e}`)}}
4
+ export{mr as __setConfigurePhase,nr as configure,A as resetConfigure};
@@ -1 +1 @@
1
- export{a as AnchorPositions}from'../chunks/chunk-5FUZURCZ.js';
1
+ export{a as AnchorPositions}from'../chunks/chunk-EKOWJS3E.js';
@@ -1,5 +1,5 @@
1
1
  /// <reference types="emscripten" />
2
- export { bs as AspectRatio, bu as CameraAccess, bq as CameraPosition, br as CameraResolutionConstraint, bt as DeviceCamera } from '../Camera-DYYZ5vW1.js';
2
+ export { bs as AspectRatio, bu as CameraAccess, bq as CameraPosition, br as CameraResolutionConstraint, bt as DeviceCamera } from '../Camera-C_4xOv5n.js';
3
3
  import './Serializable.js';
4
4
  import '../Common.js';
5
5
  import './FrameReaders/WatermarkStack.js';
@@ -1 +1 @@
1
- export{c as AspectRatio,d as CameraAccess,a as CameraPosition,b as CameraResolutionConstraint}from'../chunks/chunk-E67SHSCO.js';
1
+ export{c as AspectRatio,d as CameraAccess,a as CameraPosition,b as CameraResolutionConstraint}from'../chunks/chunk-OQ4XCKFQ.js';