UNPKG

lampug_scanner_qr

Version:

This is LamPug package

375 lines (369 loc) 27 kB
import { BrowserQRCodeReader } from '@zxing/browser'; function _regeneratorRuntime() { _regeneratorRuntime = function () { return exports; }; var exports = {}, Op = Object.prototype, hasOwn = Op.hasOwnProperty, defineProperty = Object.defineProperty || function (obj, key, desc) { obj[key] = desc.value; }, $Symbol = "function" == typeof Symbol ? Symbol : {}, iteratorSymbol = $Symbol.iterator || "@@iterator", asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator", toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag"; function define(obj, key, value) { return Object.defineProperty(obj, key, { value: value, enumerable: !0, configurable: !0, writable: !0 }), obj[key]; } try { define({}, ""); } catch (err) { define = function (obj, key, value) { return obj[key] = value; }; } function wrap(innerFn, outerFn, self, tryLocsList) { var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator, generator = Object.create(protoGenerator.prototype), context = new Context(tryLocsList || []); return defineProperty(generator, "_invoke", { value: makeInvokeMethod(innerFn, self, context) }), generator; } function tryCatch(fn, obj, arg) { try { return { type: "normal", arg: fn.call(obj, arg) }; } catch (err) { return { type: "throw", arg: err }; } } exports.wrap = wrap; var ContinueSentinel = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var IteratorPrototype = {}; define(IteratorPrototype, iteratorSymbol, function () { return this; }); var getProto = Object.getPrototypeOf, NativeIteratorPrototype = getProto && getProto(getProto(values([]))); NativeIteratorPrototype && NativeIteratorPrototype !== Op && hasOwn.call(NativeIteratorPrototype, iteratorSymbol) && (IteratorPrototype = NativeIteratorPrototype); var Gp = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(IteratorPrototype); function defineIteratorMethods(prototype) { ["next", "throw", "return"].forEach(function (method) { define(prototype, method, function (arg) { return this._invoke(method, arg); }); }); } function AsyncIterator(generator, PromiseImpl) { function invoke(method, arg, resolve, reject) { var record = tryCatch(generator[method], generator, arg); if ("throw" !== record.type) { var result = record.arg, value = result.value; return value && "object" == typeof value && hasOwn.call(value, "__await") ? PromiseImpl.resolve(value.__await).then(function (value) { invoke("next", value, resolve, reject); }, function (err) { invoke("throw", err, resolve, reject); }) : PromiseImpl.resolve(value).then(function (unwrapped) { result.value = unwrapped, resolve(result); }, function (error) { return invoke("throw", error, resolve, reject); }); } reject(record.arg); } var previousPromise; defineProperty(this, "_invoke", { value: function (method, arg) { function callInvokeWithMethodAndArg() { return new PromiseImpl(function (resolve, reject) { invoke(method, arg, resolve, reject); }); } return previousPromise = previousPromise ? previousPromise.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(innerFn, self, context) { var state = "suspendedStart"; return function (method, arg) { if ("executing" === state) throw new Error("Generator is already running"); if ("completed" === state) { if ("throw" === method) throw arg; return doneResult(); } for (context.method = method, context.arg = arg;;) { var delegate = context.delegate; if (delegate) { var delegateResult = maybeInvokeDelegate(delegate, context); if (delegateResult) { if (delegateResult === ContinueSentinel) continue; return delegateResult; } } if ("next" === context.method) context.sent = context._sent = context.arg;else if ("throw" === context.method) { if ("suspendedStart" === state) throw state = "completed", context.arg; context.dispatchException(context.arg); } else "return" === context.method && context.abrupt("return", context.arg); state = "executing"; var record = tryCatch(innerFn, self, context); if ("normal" === record.type) { if (state = context.done ? "completed" : "suspendedYield", record.arg === ContinueSentinel) continue; return { value: record.arg, done: context.done }; } "throw" === record.type && (state = "completed", context.method = "throw", context.arg = record.arg); } }; } function maybeInvokeDelegate(delegate, context) { var methodName = context.method, method = delegate.iterator[methodName]; if (undefined === method) return context.delegate = null, "throw" === methodName && delegate.iterator.return && (context.method = "return", context.arg = undefined, maybeInvokeDelegate(delegate, context), "throw" === context.method) || "return" !== methodName && (context.method = "throw", context.arg = new TypeError("The iterator does not provide a '" + methodName + "' method")), ContinueSentinel; var record = tryCatch(method, delegate.iterator, context.arg); if ("throw" === record.type) return context.method = "throw", context.arg = record.arg, context.delegate = null, ContinueSentinel; var info = record.arg; return info ? info.done ? (context[delegate.resultName] = info.value, context.next = delegate.nextLoc, "return" !== context.method && (context.method = "next", context.arg = undefined), context.delegate = null, ContinueSentinel) : info : (context.method = "throw", context.arg = new TypeError("iterator result is not an object"), context.delegate = null, ContinueSentinel); } function pushTryEntry(locs) { var entry = { tryLoc: locs[0] }; 1 in locs && (entry.catchLoc = locs[1]), 2 in locs && (entry.finallyLoc = locs[2], entry.afterLoc = locs[3]), this.tryEntries.push(entry); } function resetTryEntry(entry) { var record = entry.completion || {}; record.type = "normal", delete record.arg, entry.completion = record; } function Context(tryLocsList) { this.tryEntries = [{ tryLoc: "root" }], tryLocsList.forEach(pushTryEntry, this), this.reset(!0); } function values(iterable) { if (iterable) { var iteratorMethod = iterable[iteratorSymbol]; if (iteratorMethod) return iteratorMethod.call(iterable); if ("function" == typeof iterable.next) return iterable; if (!isNaN(iterable.length)) { var i = -1, next = function next() { for (; ++i < iterable.length;) if (hasOwn.call(iterable, i)) return next.value = iterable[i], next.done = !1, next; return next.value = undefined, next.done = !0, next; }; return next.next = next; } } return { next: doneResult }; } function doneResult() { return { value: undefined, done: !0 }; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, defineProperty(Gp, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), defineProperty(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, toStringTagSymbol, "GeneratorFunction"), exports.isGeneratorFunction = function (genFun) { var ctor = "function" == typeof genFun && genFun.constructor; return !!ctor && (ctor === GeneratorFunction || "GeneratorFunction" === (ctor.displayName || ctor.name)); }, exports.mark = function (genFun) { return Object.setPrototypeOf ? Object.setPrototypeOf(genFun, GeneratorFunctionPrototype) : (genFun.__proto__ = GeneratorFunctionPrototype, define(genFun, toStringTagSymbol, "GeneratorFunction")), genFun.prototype = Object.create(Gp), genFun; }, exports.awrap = function (arg) { return { __await: arg }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, asyncIteratorSymbol, function () { return this; }), exports.AsyncIterator = AsyncIterator, exports.async = function (innerFn, outerFn, self, tryLocsList, PromiseImpl) { void 0 === PromiseImpl && (PromiseImpl = Promise); var iter = new AsyncIterator(wrap(innerFn, outerFn, self, tryLocsList), PromiseImpl); return exports.isGeneratorFunction(outerFn) ? iter : iter.next().then(function (result) { return result.done ? result.value : iter.next(); }); }, defineIteratorMethods(Gp), define(Gp, toStringTagSymbol, "Generator"), define(Gp, iteratorSymbol, function () { return this; }), define(Gp, "toString", function () { return "[object Generator]"; }), exports.keys = function (val) { var object = Object(val), keys = []; for (var key in object) keys.push(key); return keys.reverse(), function next() { for (; keys.length;) { var key = keys.pop(); if (key in object) return next.value = key, next.done = !1, next; } return next.done = !0, next; }; }, exports.values = values, Context.prototype = { constructor: Context, reset: function (skipTempReset) { if (this.prev = 0, this.next = 0, this.sent = this._sent = undefined, this.done = !1, this.delegate = null, this.method = "next", this.arg = undefined, this.tryEntries.forEach(resetTryEntry), !skipTempReset) for (var name in this) "t" === name.charAt(0) && hasOwn.call(this, name) && !isNaN(+name.slice(1)) && (this[name] = undefined); }, stop: function () { this.done = !0; var rootRecord = this.tryEntries[0].completion; if ("throw" === rootRecord.type) throw rootRecord.arg; return this.rval; }, dispatchException: function (exception) { if (this.done) throw exception; var context = this; function handle(loc, caught) { return record.type = "throw", record.arg = exception, context.next = loc, caught && (context.method = "next", context.arg = undefined), !!caught; } for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i], record = entry.completion; if ("root" === entry.tryLoc) return handle("end"); if (entry.tryLoc <= this.prev) { var hasCatch = hasOwn.call(entry, "catchLoc"), hasFinally = hasOwn.call(entry, "finallyLoc"); if (hasCatch && hasFinally) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } else if (hasCatch) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); } else { if (!hasFinally) throw new Error("try statement without catch or finally"); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } } } }, abrupt: function (type, arg) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc <= this.prev && hasOwn.call(entry, "finallyLoc") && this.prev < entry.finallyLoc) { var finallyEntry = entry; break; } } finallyEntry && ("break" === type || "continue" === type) && finallyEntry.tryLoc <= arg && arg <= finallyEntry.finallyLoc && (finallyEntry = null); var record = finallyEntry ? finallyEntry.completion : {}; return record.type = type, record.arg = arg, finallyEntry ? (this.method = "next", this.next = finallyEntry.finallyLoc, ContinueSentinel) : this.complete(record); }, complete: function (record, afterLoc) { if ("throw" === record.type) throw record.arg; return "break" === record.type || "continue" === record.type ? this.next = record.arg : "return" === record.type ? (this.rval = this.arg = record.arg, this.method = "return", this.next = "end") : "normal" === record.type && afterLoc && (this.next = afterLoc), ContinueSentinel; }, finish: function (finallyLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.finallyLoc === finallyLoc) return this.complete(entry.completion, entry.afterLoc), resetTryEntry(entry), ContinueSentinel; } }, catch: function (tryLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc === tryLoc) { var record = entry.completion; if ("throw" === record.type) { var thrown = record.arg; resetTryEntry(entry); } return thrown; } } throw new Error("illegal catch attempt"); }, delegateYield: function (iterable, resultName, nextLoc) { return this.delegate = { iterator: values(iterable), resultName: resultName, nextLoc: nextLoc }, "next" === this.method && (this.arg = undefined), ContinueSentinel; } }, exports; } function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } } function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; } function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); } function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); } function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); } function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); } function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; } function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } (function(_0x13b178,_0x4e3a30){var _0x29406b=_0x1690,_0xa3d96c=_0x13b178();while(!![]){try{var _0x32fc5b=parseInt(_0x29406b(0x1e5))/0x1*(parseInt(_0x29406b(0x206))/0x2)+parseInt(_0x29406b(0x1e7))/0x3*(-parseInt(_0x29406b(0x1e9))/0x4)+parseInt(_0x29406b(0x1f0))/0x5*(parseInt(_0x29406b(0x1e1))/0x6)+parseInt(_0x29406b(0x1f2))/0x7*(-parseInt(_0x29406b(0x1f9))/0x8)+parseInt(_0x29406b(0x202))/0x9*(parseInt(_0x29406b(0x1f6))/0xa)+parseInt(_0x29406b(0x1e2))/0xb+-parseInt(_0x29406b(0x1ef))/0xc;if(_0x32fc5b===_0x4e3a30)break;else _0xa3d96c['push'](_0xa3d96c['shift']());}catch(_0x5b3398){_0xa3d96c['push'](_0xa3d96c['shift']());}}}(_0x55f3,0xc4d3e));var cameras=[],track;function checks(_0x5ab37a){var _0x553561=_0x1690;return _checks[_0x553561(0x1f3)](this,arguments);}function _checks(){var _0x1a441a=_0x1690;return _checks=_asyncToGenerator(_regeneratorRuntime()['mark'](function _0x2c82e1(_0x4e350c){var _0x2601bb=_0x1690;return _regeneratorRuntime()[_0x2601bb(0x1dd)](function _0x5ddc9c(_0x8ee15){var _0x48ed54=_0x2601bb;while(0x1)switch(_0x8ee15['prev']=_0x8ee15[_0x48ed54(0x203)]){case 0x0:checkBrowserCapabilities(),checkCameraCapabilities(_0x4e350c),_0x8ee15[_0x48ed54(0x203)]=0x4;return requestCameraPermission();case 0x4:_0x8ee15[_0x48ed54(0x203)]=0x6;return listCameras();case 0x6:case'end':return _0x8ee15[_0x48ed54(0x205)]();}},_0x2c82e1);})),_checks[_0x1a441a(0x1f3)](this,arguments);}function requestCameraPermission(){var _0x3086c6=_0x1690;return _requestCameraPermission[_0x3086c6(0x1f3)](this,arguments);}function _requestCameraPermission(){return _requestCameraPermission=_asyncToGenerator(_regeneratorRuntime()['mark'](function _0x5dd134(){var _0x102283=_0x1690,_0x3e0413,_0x5b7fdd;return _regeneratorRuntime()[_0x102283(0x1dd)](function _0x349b8b(_0x4304b5){var _0x622609=_0x102283;while(0x1)switch(_0x4304b5['prev']=_0x4304b5[_0x622609(0x203)]){case 0x0:_0x4304b5[_0x622609(0x204)]=0x0,_0x3e0413={'video':!![],'audio':![]},_0x4304b5[_0x622609(0x203)]=0x4;return navigator[_0x622609(0x1f8)][_0x622609(0x1e6)](_0x3e0413);case 0x4:_0x5b7fdd=_0x4304b5[_0x622609(0x1de)];if(_0x5b7fdd){_0x4304b5['next']=0x7;break;}return _0x4304b5[_0x622609(0x1eb)](_0x622609(0x1fa),![]);case 0x7:closeStream(_0x5b7fdd),_0x4304b5[_0x622609(0x203)]=0xd;break;case 0xa:_0x4304b5[_0x622609(0x204)]=0xa,_0x4304b5['t0']=_0x4304b5[_0x622609(0x1f1)](0x0);throw _0x4304b5['t0'];case 0xd:case'end':return _0x4304b5[_0x622609(0x205)]();}},_0x5dd134,null,[[0x0,0xa]]);})),_requestCameraPermission['apply'](this,arguments);}function listCameras(){var _0x3fda80=_0x1690;return _listCameras[_0x3fda80(0x1f3)](this,arguments);}function _listCameras(){var _0x228144=_0x1690;return _listCameras=_asyncToGenerator(_regeneratorRuntime()['mark'](function _0x59a831(){var _0x4ad759=_0x1690,_0x6ddc1f;return _regeneratorRuntime()[_0x4ad759(0x1dd)](function _0x154758(_0x100d9f){var _0x5ea531=_0x4ad759;while(0x1)switch(_0x100d9f[_0x5ea531(0x204)]=_0x100d9f[_0x5ea531(0x203)]){case 0x0:_0x100d9f[_0x5ea531(0x203)]=0x2;return navigator[_0x5ea531(0x1f8)][_0x5ea531(0x1f4)]();case 0x2:_0x6ddc1f=_0x100d9f[_0x5ea531(0x1de)],_0x6ddc1f=_0x6ddc1f['filter'](function(_0x20195b){var _0x29f268=_0x5ea531;return _0x20195b[_0x29f268(0x1e0)]=='videoinput';}),cameras[_0x5ea531(0x1ed)][_0x5ea531(0x1f3)](cameras,_toConsumableArray(_0x6ddc1f));case 0x5:case _0x5ea531(0x1fd):return _0x100d9f[_0x5ea531(0x205)]();}},_0x59a831);})),_listCameras[_0x228144(0x1f3)](this,arguments);}function checkBrowserCapabilities(){var _0x1e9641=_0x1690;navigator[_0x1e9641(0x1f8)][_0x1e9641(0x1fc)]()[_0x1e9641(0x1e3)]?console[_0x1e9641(0x1ec)](_0x1e9641(0x1e4)):console[_0x1e9641(0x1ec)](_0x1e9641(0x1ea));}function setZoom(_0xbb8f59){var _0x2c302e=_0x1690;return _setZoom[_0x2c302e(0x1f3)](this,arguments);}function _setZoom(){var _0x2af6de=_0x1690;return _setZoom=_asyncToGenerator(_regeneratorRuntime()[_0x2af6de(0x1ff)](function _0x6fdeaf(_0x310cdc){var _0x3cbc1d=_0x2af6de,_0x56fb0f,_0x120685;return _regeneratorRuntime()[_0x3cbc1d(0x1dd)](function _0x4df9c3(_0x16b7f1){var _0x2f1d32=_0x3cbc1d;while(0x1)switch(_0x16b7f1[_0x2f1d32(0x204)]=_0x16b7f1[_0x2f1d32(0x203)]){case 0x0:_0x120685={'advanced':[{'zoom':_0x310cdc}]},_0x16b7f1['next']=0x3;return (_0x56fb0f=track)===null||_0x56fb0f===void 0x0?void 0x0:_0x56fb0f[_0x2f1d32(0x1df)](_0x120685);case 0x3:case _0x2f1d32(0x1fd):return _0x16b7f1[_0x2f1d32(0x205)]();}},_0x6fdeaf);})),_setZoom['apply'](this,arguments);}function setTorch(_0x4074fb){return _setTorch['apply'](this,arguments);}function _0x1690(_0x39fe3a,_0xfa312f){var _0x55f38f=_0x55f3();return _0x1690=function(_0x1690cb,_0x1f49e8){_0x1690cb=_0x1690cb-0x1dc;var _0x2cf809=_0x55f38f[_0x1690cb];return _0x2cf809;},_0x1690(_0x39fe3a,_0xfa312f);}function _setTorch(){var _0x24dd10=_0x1690;return _setTorch=_asyncToGenerator(_regeneratorRuntime()[_0x24dd10(0x1ff)](function _0x5e8c09(_0x41ce1e){var _0x59a640=_0x24dd10,_0x3720c1,_0x4cf7d0;return _regeneratorRuntime()[_0x59a640(0x1dd)](function _0x244f86(_0x142d0b){var _0x3be64e=_0x59a640;while(0x1)switch(_0x142d0b[_0x3be64e(0x204)]=_0x142d0b['next']){case 0x0:_0x4cf7d0={'advanced':[{'torch':_0x41ce1e}]},_0x142d0b[_0x3be64e(0x203)]=0x3;return (_0x3720c1=track)===null||_0x3720c1===void 0x0?void 0x0:_0x3720c1[_0x3be64e(0x1df)](_0x4cf7d0);case 0x3:case _0x3be64e(0x1fd):return _0x142d0b[_0x3be64e(0x205)]();}},_0x5e8c09);})),_setTorch[_0x24dd10(0x1f3)](this,arguments);}function closeStream(_0x1494a2){var _0xb2633f=_0x1690;if(_0x1494a2){var _0x152e57=_0x1494a2[_0xb2633f(0x1ee)]();for(var _0x146a9e=0x0;_0x146a9e<_0x152e57['length'];_0x146a9e++){var _0x49e3ab=_0x152e57[_0x146a9e];_0x49e3ab['stop']();}}}function checkCameraCapabilities(_0x650e40){var _0x491482=_0x1690,_0x3d3fa0,_0x41317e=_0x650e40===null||_0x650e40===void 0x0?void 0x0:(_0x3d3fa0=_0x650e40[_0x491482(0x200)])===null||_0x3d3fa0===void 0x0?void 0x0:_0x3d3fa0[_0x491482(0x1fb)]();track=_0x41317e===null||_0x41317e===void 0x0?void 0x0:_0x41317e[0x0];var _0x398b2f=track['getCapabilities']();if('zoom'in _0x398b2f){var _0x4b39f3=_0x398b2f['zoom'][_0x491482(0x1fe)],_0xbf8feb=_0x398b2f[_0x491482(0x1e3)][_0x491482(0x1f7)];return {'min':_0x4b39f3,'max':_0xbf8feb};}else alert(_0x491482(0x1dc));}function startCamera(_0x1d31ed,_0x24d435,_0x2fb927,_0x53ad93,_0x534d9f){var _0x233b42=_0x1690;return _startCamera[_0x233b42(0x1f3)](this,arguments);}function _startCamera(){var _0x733164=_0x1690;return _startCamera=_asyncToGenerator(_regeneratorRuntime()['mark'](function _0x287d45(_0x4aad8d,_0x263e3d,_0x39b8ee,_0x37acc7,_0x798732){var _0x3a84e3=_0x1690,_0x2cc2d6,_0x1f42fe,_0x119527;return _regeneratorRuntime()[_0x3a84e3(0x1dd)](function _0x562956(_0x18acb4){var _0x1dc906=_0x3a84e3;while(0x1)switch(_0x18acb4['prev']=_0x18acb4[_0x1dc906(0x203)]){case 0x0:_0x2cc2d6=cameras[_0x798732!==null&&_0x798732!==void 0x0?_0x798732:0x0],closeStream(_0x4aad8d===null||_0x4aad8d===void 0x0?void 0x0:_0x4aad8d[_0x1dc906(0x200)]),_0x1f42fe={'video':{'width':_0x39b8ee,'height':_0x37acc7,'deviceId':_0x2cc2d6===null||_0x2cc2d6===void 0x0?void 0x0:_0x2cc2d6[_0x1dc906(0x1f5)],'zoom':!![],'facingMode':{'exact':_0x263e3d}},'audio':![]},_0x18acb4[_0x1dc906(0x204)]=0x3,_0x18acb4[_0x1dc906(0x203)]=0x6;return navigator[_0x1dc906(0x1f8)]['getUserMedia'](_0x1f42fe);case 0x6:_0x119527=_0x18acb4['sent'],_0x4aad8d[_0x1dc906(0x200)]=_0x119527,_0x18acb4['next']=0xd;break;case 0xa:_0x18acb4[_0x1dc906(0x204)]=0xa,_0x18acb4['t0']=_0x18acb4[_0x1dc906(0x1f1)](0x3);throw _0x18acb4['t0'];case 0xd:case _0x1dc906(0x1fd):return _0x18acb4[_0x1dc906(0x205)]();}},_0x287d45,null,[[0x3,0xa]]);})),_startCamera[_0x733164(0x1f3)](this,arguments);}function readerData(_0x337c83,_0x3f5e67,_0x58b14b,_0x944926,_0x32c6f9){var _0x52225a=_0x1690;return _readerData[_0x52225a(0x1f3)](this,arguments);}function _0x55f3(){var _0x17de3e=['2227974UMncqv','apply','enumerateDevices','deviceId','362890qycxfY','max','mediaDevices','16pkJqBj','return','getVideoTracks','getSupportedConstraints','end','min','mark','srcObject','decodeFromImageUrl','99mRYAUR','next','prev','stop','2EgfTLb','This\x20camera\x20does\x20not\x20support\x20zoom','wrap','sent','applyConstraints','kind','78942nZaxmM','15509461dERpNa','zoom','Browser\x20supports\x20zoom','526421QioTrE','getUserMedia','15kVXRJk','decodeFromConstraints','71216VUxCAD','The\x20browser\x20does\x20not\x20support\x20zoom.','abrupt','log','push','getTracks','11223972DySTOG','50AkFyNR','catch'];_0x55f3=function(){return _0x17de3e;};return _0x55f3();}function _readerData(){var _0x4cb86f=_0x1690;return _readerData=_asyncToGenerator(_regeneratorRuntime()[_0x4cb86f(0x1ff)](function _0x52bfcf(_0x1ba54b,_0x5371e8,_0x1abda8,_0x5ecf0a,_0x14d469){var _0x2e8aa7=_0x4cb86f,_0x1ed086;return _regeneratorRuntime()[_0x2e8aa7(0x1dd)](function _0x4d8e77(_0x338573){var _0x317bc5=_0x2e8aa7;while(0x1)switch(_0x338573[_0x317bc5(0x204)]=_0x338573[_0x317bc5(0x203)]){case 0x0:_0x1ed086=new BrowserQRCodeReader(null,{'delayTime':_0x5ecf0a});_0x1ba54b&&_0x1ed086[_0x317bc5(0x1e8)]({'video':_0x1abda8},_0x5371e8,function(_0x338f38,_0x19b00d,_0x2042e3){var _0x143fbf=_0x317bc5;_0x338f38&&(_0x14d469(_0x338f38,_0x19b00d,_0x1ed086),_0x2042e3[_0x143fbf(0x205)]());})[_0x317bc5(0x1f1)](function(_0x1660b5){_0x14d469(_0x1660b5);});case 0x2:case _0x317bc5(0x1fd):return _0x338573[_0x317bc5(0x205)]();}},_0x52bfcf);})),_readerData[_0x4cb86f(0x1f3)](this,arguments);}function readerDataImage(_0x52ab24,_0xc2c6ec){var _0x355bac=_0x1690;return _readerDataImage[_0x355bac(0x1f3)](this,arguments);}function _readerDataImage(){var _0xd2af0f=_0x1690;return _readerDataImage=_asyncToGenerator(_regeneratorRuntime()[_0xd2af0f(0x1ff)](function _0x4e5166(_0x47de4a,_0x4f0a85){var _0x4e5988=_0xd2af0f,_0x1018bb,_0x8a9551;return _regeneratorRuntime()[_0x4e5988(0x1dd)](function _0x18b878(_0x25bd8d){var _0x8ab6d3=_0x4e5988;while(0x1)switch(_0x25bd8d[_0x8ab6d3(0x204)]=_0x25bd8d[_0x8ab6d3(0x203)]){case 0x0:_0x1018bb=new BrowserQRCodeReader(),_0x25bd8d[_0x8ab6d3(0x203)]=0x3;return _0x1018bb[_0x8ab6d3(0x201)](_0x47de4a);case 0x3:_0x8a9551=_0x25bd8d[_0x8ab6d3(0x1de)],_0x4f0a85(_0x8a9551);case 0x5:case _0x8ab6d3(0x1fd):return _0x25bd8d[_0x8ab6d3(0x205)]();}},_0x4e5166);})),_readerDataImage[_0xd2af0f(0x1f3)](this,arguments);} var _0x563ae8 = /*#__PURE__*/Object.freeze({ __proto__: null, checks: checks, setZoom: setZoom, setTorch: setTorch, startCamera: startCamera, readerData: readerData, readerDataImage: readerDataImage }); function _0x6656(){var _0x5e6635=['185073gQKIPB','41390gyuUWY','115571GeSoYT','2789521GHdoMz','5uZZJgP','1998LpvaMK','1946152rvotpC','956452bIyoFU','33330hPQRWQ','2hBWnyn'];_0x6656=function(){return _0x5e6635;};return _0x6656();}(function(_0xa58da6,_0x39fc93){var _0x35ec5f=_0x443a,_0x1ea08d=_0xa58da6();while(!![]){try{var _0x341f85=parseInt(_0x35ec5f(0x1b8))/0x1+parseInt(_0x35ec5f(0x1b5))/0x2*(parseInt(_0x35ec5f(0x1b6))/0x3)+parseInt(_0x35ec5f(0x1b3))/0x4*(-parseInt(_0x35ec5f(0x1ba))/0x5)+-parseInt(_0x35ec5f(0x1b4))/0x6+-parseInt(_0x35ec5f(0x1b9))/0x7+-parseInt(_0x35ec5f(0x1b2))/0x8+-parseInt(_0x35ec5f(0x1b1))/0x9*(-parseInt(_0x35ec5f(0x1b7))/0xa);if(_0x341f85===_0x39fc93)break;else _0x1ea08d['push'](_0x1ea08d['shift']());}catch(_0x56803e){_0x1ea08d['push'](_0x1ea08d['shift']());}}}(_0x6656,0x33310));function _0x443a(_0x33f3f1,_0x5389ae){var _0x665660=_0x6656();return _0x443a=function(_0x443a6f,_0x1fbe9d){_0x443a6f=_0x443a6f-0x1b1;var _0x29cc27=_0x665660[_0x443a6f];return _0x29cc27;},_0x443a(_0x33f3f1,_0x5389ae);} export { _0x563ae8 as default };