[SignalingServer] Upgrade signaling server as v0.4.1 26/263026/1
authorHunseop Jeong <hs85.jeong@samsung.com>
Wed, 25 Aug 2021 00:29:43 +0000 (09:29 +0900)
committerHunseop Jeong <hs85.jeong@samsung.com>
Wed, 25 Aug 2021 00:29:43 +0000 (09:29 +0900)
Release Note:
https://github.sec.samsung.net/HighPerformanceWeb/offload.js/releases/tag/0.4.1

Change-Id: Ibba174c8fc641a34d53e7f93d8fb5ec761c55620
Signed-off-by: Hunseop Jeong <hs85.jeong@samsung.com>
device_home/signaling_server/gen/app.js
device_home/signaling_server/gen/edge.js [new file with mode: 0644]
device_home/signaling_server/gen/public/js/log.js [new file with mode: 0644]
device_home/signaling_server/gen/public/js/main.js [new file with mode: 0644]
device_home/signaling_server/gen/public/offload-worker.html
device_home/signaling_server/gen/public/offload-worker.js
device_home/signaling_server/gen/public/offload.js
device_home/signaling_server/gen/socket-tizen.js [new file with mode: 0644]
device_home/signaling_server/gen/util.js [new file with mode: 0644]

index ef2a0d9..5419924 100644 (file)
@@ -1,8 +1,10 @@
 const path = require('path');
 const fs = require('fs');
 const express = require('express');
-const os = require('os');
 const QRCode = require('qrcode');
+const Edge = require('./edge');
+const SocketTizen = require('./socket-tizen');
+const { getMyAddress } = require('./util');
 
 const TAG = 'app.js';
 
@@ -13,14 +15,19 @@ const options = {
   cert: fs.readFileSync(path.resolve(__dirname, 'cert.pem'))
 };
 
+console.log(TAG, `platform : ${process.platform}`);
+
 const httpPort = process.env.HTTP_PORT || 9559;
 const httpsPort = process.env.PORT || process.env.HTTPS_PORT || 5443;
 const httpsServer = require('https').createServer(options, app);
 const httpServer = require('http').createServer(app);
 const io = require('socket.io')();
 const isTizen = process.platform === 'tizen';
-
-console.log(TAG, `platform : ${process.platform}`);
+const supportMessagePort = isTizen;
+// Implementation for edge orchestration
+const supportEdgeOrchestration =
+  typeof webapis !== 'undefined' && webapis.hasOwnProperty('edge');
+console.log(TAG, `supportEdgeOrchestration : ${supportEdgeOrchestration}`);
 
 io.attach(httpServer);
 io.attach(httpsServer);
@@ -33,26 +40,27 @@ let forceQuitTimer = null;
 let isMeerkatStarted = false;
 
 app.set('host', '0.0.0.0');
+
 if (isTizen) {
   app.use(express.static(path.join(__dirname, './public')));
 } else {
   app.use(
     '/offload.html',
-    express.static(path.join(__dirname, '../../sample/src/offload.html'))
+    express.static(path.join(__dirname, '../../sample/offload.html'))
   );
+  // Host offload-worker
   app.use(
-    '/offload-worker.html',
-    express.static(path.join(__dirname, '../../offload-worker/src/index.html'))
+    '/offload-worker',
+    express.static(path.join(__dirname, '../../offload-worker/src/'))
   );
-  const serveIndex = require('serve-index');
   app.use(
-    '/',
-    express.static(path.join(__dirname, '../../dist')),
-    express.static(path.join(__dirname, '../../sample/src')),
-    serveIndex(path.join(__dirname, '../../sample/src'))
+    '/offload-worker/offload-worker.js',
+    express.static(path.join(__dirname, '../../build/offload-worker.js'))
   );
+  const serveIndex = require('serve-index');
   app.use(
-    '/sample',
+    '/',
+    express.static(path.join(__dirname, '../../build')),
     express.static(path.join(__dirname, '../../sample')),
     serveIndex(path.join(__dirname, '../../sample'))
   );
@@ -63,7 +71,7 @@ if (isTizen) {
   );
 }
 
-io.of('/offload-js').on('connection', function (socket) {
+function onConnection(socket) {
   if (isTizen && !isMeerkatStarted) {
     try {
       console.log(TAG, `Try to start Meerkat client.`);
@@ -169,7 +177,8 @@ io.of('/offload-js').on('connection', function (socket) {
     );
 
     for (const client of clients) {
-      socket.to(client).emit('worker', {
+      const socket = sockets.get(client);
+      socket.emit('worker', {
         event: 'join',
         workerId: worker.id,
         socketId: socket.id,
@@ -191,32 +200,41 @@ io.of('/offload-js').on('connection', function (socket) {
     }
 
     if (socketId) {
-      socket.to(socketId).emit('message', data);
+      const socket = sockets.get(socketId);
+      socket.emit('message', data);
     }
   });
 
   socket.on('disconnect', function (reason) {
-    sockets.delete(socket.id);
-    if (clients.has(socket.id)) {
-      console.log(TAG, `[client] session terminated by client: ${socket.id}`);
+    const socketId = socket.id;
+    sockets.delete(socketId);
+    if (clients.has(socketId)) {
+      console.log(TAG, `[client] session terminated by client: ${socketId}`);
 
       // broadcast to offload-worker
-      socket.broadcast.emit('client', {
-        event: 'bye',
-        socketId: socket.id
-      });
-      clients.delete(socket.id);
+      for (const socket of sockets.values()) {
+        socket.emit('client', {
+          event: 'bye',
+          socketId: socketId
+        });
+      }
+      clients.delete(socketId);
 
       if (clients.size === 0) {
+        if (supportMessagePort) {
+          closeServer();
+        }
         forceQuitTimer = setTimeout(function () {
           console.log(
             TAG,
             `All clients are destroyed. Broadcast 'forceQuit' to workers`
           );
-          socket.broadcast.emit('client', {
-            event: 'forceQuit',
-            socketId: socket.id
-          });
+          for (const socket of sockets.values()) {
+            socket.emit('client', {
+              event: 'forceQuit',
+              socketId: socketId
+            });
+          }
         }, 5000);
       }
     } else {
@@ -240,7 +258,8 @@ io.of('/offload-js').on('connection', function (socket) {
 
       if (workerId) {
         for (const client of clients) {
-          socket.to(client).emit('worker', {
+          const socket = sockets.get(client);
+          socket.emit('worker', {
             event: 'bye',
             workerId: workerId,
             socketId: socket.id
@@ -251,151 +270,97 @@ io.of('/offload-js').on('connection', function (socket) {
       }
     }
   });
-});
-
-httpsServer.listen(httpsPort, function () {
-  console.log(TAG, `server is listening on https ${httpsPort} port.`);
-});
-httpServer.listen(httpPort, function () {
-  console.log(TAG, `server is listening on http ${httpPort} port.`);
-});
-
-function getMyAddress() {
-  const interfaces = os.networkInterfaces();
-  const addresses = {};
-  for (const intf in interfaces) {
-    if (interfaces.hasOwnProperty(intf)) {
-      for (const addr in interfaces[intf]) {
-        if (interfaces[intf].hasOwnProperty(addr)) {
-          const address = interfaces[intf][addr];
-          if (address.family === 'IPv4' && !address.internal) {
-            addresses[intf] = address.address;
-          }
-        }
-      }
-    }
-  }
-  if (Object.keys(addresses).length === 0) {
-    return null;
-  }
+}
 
-  // Try to connect with 'wl' prefix interface first.
-  const wlanKeys = Object.keys(addresses).filter(intf => /^wl/.test(intf));
-  return wlanKeys.length > 0
-    ? addresses[wlanKeys[0]]
-    : Object.entries(addresses)[0][1];
+io.of('/offload-js').on('connection', onConnection);
+
+if (supportEdgeOrchestration) {
+  edgeForCastanets = new Edge(
+    'castanets',
+    'android',
+    'com.samsung.android.castanets'
+  );
 }
 
-// Implementation for edge orchestration
-const supportEdgeOrchestration =
-  typeof webapis !== 'undefined' && webapis.hasOwnProperty('edge');
-console.log(TAG, `supportEdgeOrchestration : ${supportEdgeOrchestration}`);
+function startServer() {
+  console.log(TAG, 'starting server...');
 
-class Edge {
-  constructor(service, execType, packageName) {
-    this.devices_ = new Set();
-    this.capabilities_ = new Map();
-    this.service_ = service;
-    this.execType_ = execType;
-    this.packageName_ = packageName;
-    console.log(TAG, `Edge : ${this.service_}, ${this.packageName_}`);
+  if (!httpsServer.listening) {
+    httpsServer.listen(httpsPort, function () {
+      console.log(TAG, `server is listening on https ${httpsPort} port.`);
+    });
   }
 
-  getDevices() {
-    return this.devices_;
+  if (!httpServer.listening) {
+    httpServer.listen(httpPort, function () {
+      console.log(TAG, `server is listening on http ${httpPort} port.`);
+    });
   }
+}
 
-  joinDevice(joined) {
-    console.log(TAG, `${joined} is joined`);
-    this.devices_.add(joined);
+function closeServer() {
+  console.log(TAG, 'closing server...');
+
+  if (httpsServer.listening) {
+    httpsServer.close(err => {
+      if (err) {
+        console.error(`failed to close the https server:`, err);
+      }
+    });
   }
 
-  disconnectDevice(disconnected) {
-    if (this.devices_.has(disconnected)) {
-      console.log(TAG, `'${disconnected} is disconnected`);
-      this.devices_.delete(disconnected);
-    }
+  if (httpServer.listening) {
+    httpServer.close(err => {
+      if (err) {
+        console.error(`failed to close the http server:`, err);
+      }
+    });
   }
+}
 
-  getCapabilities(reload = true) {
-    if (!reload) {
-      return this.capabilities_;
+if (supportMessagePort) {
+  console.log(TAG, 'listening tizen messageport...');
+  const localPort = tizen.messageport.requestLocalMessagePort('offload');
+  localPort.addMessagePortListener(messages => {
+    if (messages.length === 0) {
+      console.error(TAG, 'Not found message');
+      return;
     }
-    const start = Date.now();
-    this.capabilities_.clear();
-
-    const execType = this.execType_;
-    const deviceList = webapis.edge.orchestrationGetDevicelist(
-      this.service_,
-      execType
-    );
 
-    if (deviceList === null || deviceList.ipaddrs.length === 0) {
-      console.log(TAG, `deviceList is null`);
-      return this.capabilities_;
+    const message = messages[0];
+    const event = message.key;
+    const value = JSON.parse(message.value);
+    const id = value.id;
+
+    if (event === 'connect') {
+      const socket = new SocketTizen(id, localPort);
+      socket.on('connection', onConnection);
+      socket.connect();
+      sockets.set(id, socket);
+      startServer();
+    } else {
+      const socket = sockets.get(id);
+      socket.handleEvents(event, value.data);
     }
+  });
 
-    console.log(
-      TAG,
-      `${this.service_} deviceList : ${JSON.stringify(deviceList)}`
-    );
-
-    for (const ipaddr of deviceList.ipaddrs) {
-      const features = webapis.edge.orchestrationReadCapability(ipaddr);
-      console.log(TAG, `ReadCapability : ${ipaddr}, ${features.capability}`);
-      try {
-        let jsonCapability = JSON.parse(features.capability);
-        if (jsonCapability.hasOwnProperty('offloadjs')) {
-          jsonCapability = jsonCapability['offloadjs'];
+  // Check the client status
+  function checkConnectionStatus() {
+    for (const client of clients) {
+      const socket = sockets.get(client);
+      if (socket.constructor === SocketTizen) {
+        try {
+          socket.emit('status');
+        } catch (e) {
+          console.error(TAG, `Failed to check ${client} status`);
+          socket.handleEvents('disconnect');
         }
-        this.capabilities_.set(jsonCapability.id, {
-          ipaddr: ipaddr,
-          name: jsonCapability.name,
-          features: jsonCapability.features,
-          options: null
-        });
-      } catch (err) {
-        console.error(TAG, 'Failed to read capability : ' + err);
       }
     }
-    console.log(TAG, `getCapabilities() ${Date.now() - start}ms`);
-    return this.capabilities_;
   }
 
-  requestService(workerId) {
-    if (!this.capabilities_.has(workerId)) {
-      return this;
-    }
-
-    const ipaddr = this.capabilities_.get(workerId).ipaddr;
-
-    const execType = this.execType_;
-
-    const myAddress = getMyAddress();
-    if (!myAddress) {
-      return this;
-    }
-
-    const parameter = `${this.packageName_} --type=offloadworker --signaling-server=https://${myAddress}:${httpsPort}/offload-js`;
-
-    console.log(
-      TAG,
-      `RequestService : ${this.service_}, ${execType}, ${parameter}, ${ipaddr}`
-    );
-    webapis.edge.orchestrationRequestServiceOnDevice(
-      this.service_,
-      false,
-      execType,
-      parameter,
-      ipaddr
-    );
-
-    return this;
-  }
+  // Prevent to terminate the process
+  setInterval(checkConnectionStatus, 1000);
+} else {
+  startServer();
 }
-
-edgeForCastanets = new Edge(
-  'castanets',
-  'android',
-  'com.samsung.android.castanets'
-);
diff --git a/device_home/signaling_server/gen/edge.js b/device_home/signaling_server/gen/edge.js
new file mode 100644 (file)
index 0000000..d6f5092
--- /dev/null
@@ -0,0 +1,106 @@
+const TAG = 'edge.js';
+
+class Edge {
+  constructor(service, execType, packageName) {
+    this._devices = new Set();
+    this._capabilities = new Map();
+    this._service = service;
+    this._execType = execType;
+    this._packageName = packageName;
+    console.log(TAG, `Edge : ${this._service}, ${this._packageName}`);
+  }
+
+  getDevices() {
+    return this._devices;
+  }
+
+  joinDevice(joined) {
+    console.log(TAG, `${joined} is joined`);
+    this._devices.add(joined);
+  }
+
+  disconnectDevice(disconnected) {
+    if (this._devices.has(disconnected)) {
+      console.log(TAG, `'${disconnected} is disconnected`);
+      this._devices.delete(disconnected);
+    }
+  }
+
+  getCapabilities(reload = true) {
+    if (!reload) {
+      return this._capabilities;
+    }
+    const start = Date.now();
+    this._capabilities.clear();
+
+    const execType = this._execType;
+    const deviceList = webapis.edge.orchestrationGetDevicelist(
+      this._service,
+      execType
+    );
+
+    if (deviceList === null || deviceList.ipaddrs.length === 0) {
+      console.log(TAG, `deviceList is null`);
+      return this._capabilities;
+    }
+
+    console.log(
+      TAG,
+      `${this._service} deviceList : ${JSON.stringify(deviceList)}`
+    );
+
+    for (const ipaddr of deviceList.ipaddrs) {
+      const features = webapis.edge.orchestrationReadCapability(ipaddr);
+      console.log(TAG, `ReadCapability : ${ipaddr}, ${features.capability}`);
+      try {
+        let jsonCapability = JSON.parse(features.capability);
+        if (jsonCapability.hasOwnProperty('offloadjs')) {
+          jsonCapability = jsonCapability['offloadjs'];
+        }
+        this._capabilities.set(jsonCapability.id, {
+          ipaddr: ipaddr,
+          name: jsonCapability.name,
+          features: jsonCapability.features,
+          options: null
+        });
+      } catch (err) {
+        console.error(TAG, 'Failed to read capability : ' + err);
+      }
+    }
+    console.log(TAG, `getCapabilities() ${Date.now() - start}ms`);
+    return this._capabilities;
+  }
+
+  requestService(workerId) {
+    if (!this._capabilities.has(workerId)) {
+      return this;
+    }
+
+    const ipaddr = this._capabilities.get(workerId).ipaddr;
+
+    const execType = this._execType;
+
+    const myAddress = getMyAddress();
+    if (!myAddress) {
+      return this;
+    }
+
+    const parameter = `${this._packageName} --type=offloadworker --signaling-server=https://${myAddress}:${httpsPort}/offload-js`;
+
+    console.log(
+      TAG,
+      `RequestService : ${this._service}, ${execType}, ${parameter}, ${ipaddr}`
+    );
+    webapis.edge.orchestrationRequestServiceOnDevice(
+      this._service,
+      false,
+      execType,
+      parameter,
+      ipaddr
+    );
+
+    return this;
+  }
+}
+
+module.exports = Edge;
diff --git a/device_home/signaling_server/gen/public/js/log.js b/device_home/signaling_server/gen/public/js/log.js
new file mode 100644 (file)
index 0000000..91b83ae
--- /dev/null
@@ -0,0 +1,100 @@
+function timeFormat(date, useDate) {
+  return (
+    (useDate
+      ? [
+          ('0' + (date.getMonth() + 1)).slice(-2),
+          ('0' + date.getDate()).slice(-2)
+        ].join('-') + ' '
+      : '') +
+    [
+      ('0' + (date.getHours() + 1)).slice(-2),
+      ('0' + date.getMinutes()).slice(-2),
+      ('0' + date.getSeconds()).slice(-2),
+      ('00' + date.getMilliseconds()).slice(-3)
+    ].join(':')
+  );
+}
+
+function makeLogMessage(message, level) {
+  const color = {
+    debug: 'black',
+    error: 'red',
+    info: 'blue',
+    log: 'black',
+    warn: 'green',
+    time: 'black',
+    timeEnd: 'black',
+    table: 'black'
+  };
+  const now = new Date();
+  message =
+    typeof message === 'object'
+      ? JSON.stringify(message)
+      : message.replace(/(\w+:\w+:[\w-_.]+|\%c)/g, '').trim();
+  return (
+    `<span style="color:${color[level]}">` +
+    `${timeFormat(now)} ${message}` +
+    `</span><br>`
+  );
+}
+
+function setLogElement(targetId) {
+  const log = document.getElementById(targetId);
+  if (!log) {
+    return;
+  }
+
+  Object.keys(console).forEach(level => {
+    console[level] = function (...params) {
+      log.innerHTML += makeLogMessage(params[0], level);
+      this.apply(this, params);
+    }.bind(console[level]);
+  });
+}
+
+function toString(object, maxDepth, maxLength, depth) {
+  depth = depth || 0;
+  maxDepth = maxDepth || 3;
+  maxLength = maxLength || 120;
+  let str;
+  if (depth++ >= maxDepth) {
+    return object;
+  }
+  if (Array.isArray(object)) {
+    str = '[\n';
+    for (const key of object) {
+      str += `${' '.repeat(depth)}${toString(
+        key,
+        maxDepth,
+        maxLength,
+        depth
+      )},\n`;
+    }
+    str += `${' '.repeat(depth - 1)}]`;
+  } else if (typeof object === 'object') {
+    str = '{\n';
+    // eslint-disable-next-line guard-for-in
+    for (const key in object) {
+      str += `${' '.repeat(depth)}${key}:${toString(
+        object[key],
+        maxDepth,
+        maxLength,
+        depth
+      )},\n`;
+    }
+    str += `${' '.repeat(depth - 1)}}`;
+  } else if (typeof object === 'string') {
+    str = `'${object}'`;
+  } else if (typeof object === 'function') {
+    str = `<<function>>`;
+  } else {
+    str = `${object}`;
+  }
+  if (str.length < maxLength) {
+    str = str.replace(/\n */g, ' ');
+  }
+  return str;
+}
+
+// Print console log to offloadingText Element
+setLogElement('offloadLogText');
diff --git a/device_home/signaling_server/gen/public/js/main.js b/device_home/signaling_server/gen/public/js/main.js
new file mode 100644 (file)
index 0000000..3c13e93
--- /dev/null
@@ -0,0 +1,129 @@
+'use strict';
+
+const videoCheckBox = document.getElementById('videoCheckBox');
+const videoBlock = document.getElementById('videoBlock');
+const video = document.querySelector('video');
+
+const statsCheckBox = document.getElementById('statsCheckBox');
+const statsInfo = document.getElementById('stats');
+
+let myStream;
+let statsIntervalId = 0;
+let prevFramesSent = 0;
+
+document.getElementById('connectBtn').onclick = function () {
+  const url = document.getElementById('serverURL').innerHTML;
+  offloadWorker.connect(url, { forceConnect: true });
+};
+
+document.getElementById('logClearBtn').onclick = function () {
+  document.getElementById('offloadLogText').innerHTML = '';
+};
+
+if (videoCheckBox && videoBlock && video) {
+  videoBlock.style.display = 'none';
+  videoCheckBox.onchange = event => {
+    if (event.currentTarget.checked) {
+      videoBlock.style.display = 'block';
+      video.srcObject = myStream;
+    } else {
+      videoBlock.style.display = 'none';
+      video.srcObject = null;
+    }
+  };
+}
+
+if (statsCheckBox && statsInfo) {
+  statsCheckBox.onchange = event => {
+    if (event.currentTarget.checked) {
+      if (statsIntervalId > 0) {
+        return;
+      }
+      prevFramesSent = 0;
+      statsIntervalId = setInterval(function () {
+        if (!myStream || !myStream.peerConnection) {
+          return;
+        }
+        myStream.peerConnection.getStats().then(stats => {
+          let outboundCnt = 0;
+          statsInfo.innerHTML = '';
+          stats.forEach(stat => {
+            if (!(stat.type === 'outbound-rtp' && stat.kind === 'video')) {
+              return;
+            }
+            outboundCnt++;
+            const statTrack = stats.get(stat.trackId);
+            if (
+              statTrack &&
+              statTrack.trackIdentifier === myStream.getVideoTracks()[0].id
+            ) {
+              const statCodec = stats.get(stat.codecId);
+              statsInfo.innerHTML += 'codec:' + statCodec.mimeType + ', ';
+              statsInfo.innerHTML +=
+                'size:' +
+                statTrack.frameWidth +
+                'x' +
+                statTrack.frameHeight +
+                ' ' +
+                stat.framesPerSecond +
+                'fps, ';
+              statsInfo.innerHTML +=
+                'framesSent:' +
+                (statTrack.framesSent - prevFramesSent) +
+                '/' +
+                statTrack.framesSent +
+                ', ';
+              prevFramesSent = statTrack.framesSent;
+            }
+          });
+          statsInfo.innerHTML =
+            'rtp cnt:' + outboundCnt + ', ' + statsInfo.innerHTML;
+        });
+      }, 1000);
+    } else {
+      clearInterval(statsIntervalId);
+      statsIntervalId = 0;
+      statsInfo.innerHTML = '';
+    }
+  };
+}
+
+offloadWorker.on('connect', url => {
+  console.log('onconnect : ' + url);
+  const serverURL = document.getElementById('serverURL');
+  serverURL.innerHTML = serverURL.value = url;
+});
+
+offloadWorker.on('stream', stream => {
+  console.log('onstream : ' + stream);
+  myStream = stream;
+  if (video) {
+    video.onresize = () => {
+      const track = myStream.getVideoTracks()[0];
+      statsInfo.innerHTML =
+        `${track.getSettings().width}x${track.getSettings().height}` +
+        ` ${track.getSettings().frameRate}fps`;
+    };
+    if (!videoCheckBox || videoCheckBox.checked) {
+      video.srcObject = myStream;
+    }
+  }
+
+  // TODO: If WebRTC connection is disconnected, the event should be also delivered to Android side.
+  if (typeof android !== 'undefined') {
+    const gumEventArgs = {
+      event: 'started',
+      video: myStream.getVideoTracks().length > 0,
+      audio: myStream.getAudioTracks().length > 0
+    };
+    console.log('Send getUserMedia : ' + gumEventArgs);
+    android.emit('getUserMedia', JSON.stringify(gumEventArgs));
+  }
+});
+
+const params = new URLSearchParams(document.location.search);
+let serverUrl = params.get('server');
+if (serverUrl === null && location.protocol !== 'file:') {
+  serverUrl = localStorage.getItem('serverURL') || location.origin;
+}
+offloadWorker.connect(serverUrl);
index 7a4a0d8..cc27a6f 100644 (file)
       </div>
     </div>
   </body>
+  <script src="js/log.js"></script>
   <script src="offload-worker.js"></script>
-  <script>
-    window.onload = function() {
-      if (location.protocol !== 'file:') {
-        let serverUrl = localStorage.getItem("serverURL") || location.origin;
-        serverUrl = window.connect(serverUrl);
-        if (serverUrl) {
-          document.getElementById("serverURL").defaultValue = serverUrl;
-        }
-      }
-
-      const connectBtn = document.getElementById("connectBtn");
-      connectBtn.addEventListener("click", function() {
-        let url = document.getElementById("serverURL").value;
-        url = window.connect(url, {forceConnect: true});
-        if (url) {
-          localStorage.setItem("serverURL", url);
-          document.getElementById("serverURL").value = url;
-        }
-      });
-
-      document.getElementById("logClearBtn").onclick = function() {
-        document.getElementById("log").innerHTML = "";
-      };
-    };
-  </script>
+  <script src="js/main.js"></script>
 </html>
index b07cdd9..46b17a4 100644 (file)
@@ -1,18 +1,20 @@
-window["offload-worker"]=function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=82)}([function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r,o=(r=n(61))&&r.__esModule?r:{default:r};function i(e){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var a="offload",c=function(){function e(t){if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),!t)throw new Error("Need a prefix when creating Logger class");this._debug=(0,o.default)("".concat(a,":DEBUG:").concat(t)),this._error=(0,o.default)("".concat(a,":ERROR:").concat(t)),this._info=(0,o.default)("".concat(a,":INFO:").concat(t)),this._log=(0,o.default)("".concat(a,":LOG:").concat(t)),this._warn=(0,o.default)("".concat(a,":WARN:").concat(t)),this._table=(0,o.default)("".concat(a,":TABLE:").concat(t)),this._time=(0,o.default)("".concat(a,":TIME:")),this._timeEnd=(0,o.default)("".concat(a,":TIME:")),this._debug.log=console.debug.bind(console),this._error.log=console.error.bind(console),this._info.log=console.info.bind(console),this._log.log=console.log.bind(console),this._warn.log=console.warn.bind(console),this._time.log=console.time.bind(console),this._timeEnd.log=console.timeEnd.bind(console),this._table.log=console.table.bind(console),this._replacePrintLog("offloadLogText")}var t,n,r;return t=e,(n=[{key:"_makeLogMessage",value:function(e,t){var n=new Date;return e="object"===i(e)?JSON.stringify(e):e.replace(/(\w+:\w+:[\w-_.]+|\%c)/g,"").trim(),'<span style="color:'.concat({_debug:"black",_error:"red",_info:"blue",_log:"black",_warn:"green",_time:"black",_timeEnd:"black",_table:"black"}[t],'">').concat(n.logTime()," ").concat(e,"</span><br>")}},{key:"_replacePrintLog",value:function(e){var t=this,n=this,r=document.getElementById(e);r?(Date.prototype.logTime=function(){return[("0"+(this.getMonth()+1)).slice(-2),("0"+this.getDate()).slice(-2)].join("-")+" "+[("0"+(this.getHours()+1)).slice(-2),("0"+this.getMinutes()).slice(-2),("0"+this.getSeconds()).slice(-2),("00"+this.getMilliseconds()).slice(-3)].join(":")},Object.keys(this).forEach((function(e){t[e].log=function(){for(var t=arguments.length,o=new Array(t),i=0;i<t;i++)o[i]=arguments[i];console.log(o[0].replace(/%c/g,"")),r.innerHTML+=n._makeLogMessage(o[0],e)}}))):Object.keys(this).forEach((function(e){t[e].log=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];console[e.substr(1)](n[0].replace(/\%c/g,""))}}))}},{key:"debug",get:function(){return this._debug}},{key:"error",get:function(){return this._error}},{key:"info",get:function(){return this._info}},{key:"log",get:function(){return this._log}},{key:"warn",get:function(){return this._warn}},{key:"time",get:function(){return this._time}},{key:"timeEnd",get:function(){return this._timeEnd}},{key:"table",get:function(){return this._table}}])&&s(t.prototype,n),r&&s(t,r),e}();t.default=c},function(e,t,n){var r,o=n(47),i=n(23),s=n(49),a=n(50),c=n(51);"undefined"!=typeof ArrayBuffer&&(r=n(52));var u="undefined"!=typeof navigator&&/Android/i.test(navigator.userAgent),f="undefined"!=typeof navigator&&/PhantomJS/i.test(navigator.userAgent),l=u||f;t.protocol=3;var h=t.packets={open:0,close:1,ping:2,pong:3,message:4,upgrade:5,noop:6},p=o(h),d={type:"error",data:"parser error"},y=n(53);function g(e,t,n){for(var r=new Array(e.length),o=a(e.length,n),i=function(e,n,o){t(n,(function(t,n){r[e]=n,o(t,r)}))},s=0;s<e.length;s++)i(s,e[s],o)}t.encodePacket=function(e,n,r,o){"function"==typeof n&&(o=n,n=!1),"function"==typeof r&&(o=r,r=null);var i=void 0===e.data?void 0:e.data.buffer||e.data;if("undefined"!=typeof ArrayBuffer&&i instanceof ArrayBuffer)return function(e,n,r){if(!n)return t.encodeBase64Packet(e,r);var o=e.data,i=new Uint8Array(o),s=new Uint8Array(1+o.byteLength);s[0]=h[e.type];for(var a=0;a<i.length;a++)s[a+1]=i[a];return r(s.buffer)}(e,n,o);if(void 0!==y&&i instanceof y)return function(e,n,r){if(!n)return t.encodeBase64Packet(e,r);if(l)return function(e,n,r){if(!n)return t.encodeBase64Packet(e,r);var o=new FileReader;return o.onload=function(){t.encodePacket({type:e.type,data:o.result},n,!0,r)},o.readAsArrayBuffer(e.data)}(e,n,r);var o=new Uint8Array(1);o[0]=h[e.type];var i=new y([o.buffer,e.data]);return r(i)}(e,n,o);if(i&&i.base64)return function(e,n){var r="b"+t.packets[e.type]+e.data.data;return n(r)}(e,o);var s=h[e.type];return void 0!==e.data&&(s+=r?c.encode(String(e.data),{strict:!1}):String(e.data)),o(""+s)},t.encodeBase64Packet=function(e,n){var r,o="b"+t.packets[e.type];if(void 0!==y&&e.data instanceof y){var i=new FileReader;return i.onload=function(){var e=i.result.split(",")[1];n(o+e)},i.readAsDataURL(e.data)}try{r=String.fromCharCode.apply(null,new Uint8Array(e.data))}catch(t){for(var s=new Uint8Array(e.data),a=new Array(s.length),c=0;c<s.length;c++)a[c]=s[c];r=String.fromCharCode.apply(null,a)}return o+=btoa(r),n(o)},t.decodePacket=function(e,n,r){if(void 0===e)return d;if("string"==typeof e){if("b"===e.charAt(0))return t.decodeBase64Packet(e.substr(1),n);if(r&&!1===(e=function(e){try{e=c.decode(e,{strict:!1})}catch(e){return!1}return e}(e)))return d;var o=e.charAt(0);return Number(o)==o&&p[o]?e.length>1?{type:p[o],data:e.substring(1)}:{type:p[o]}:d}o=new Uint8Array(e)[0];var i=s(e,1);return y&&"blob"===n&&(i=new y([i])),{type:p[o],data:i}},t.decodeBase64Packet=function(e,t){var n=p[e.charAt(0)];if(!r)return{type:n,data:{base64:!0,data:e.substr(1)}};var o=r.decode(e.substr(1));return"blob"===t&&y&&(o=new y([o])),{type:n,data:o}},t.encodePayload=function(e,n,r){"function"==typeof n&&(r=n,n=null);var o=i(e);if(n&&o)return y&&!l?t.encodePayloadAsBlob(e,r):t.encodePayloadAsArrayBuffer(e,r);if(!e.length)return r("0:");g(e,(function(e,r){t.encodePacket(e,!!o&&n,!1,(function(e){r(null,function(e){return e.length+":"+e}(e))}))}),(function(e,t){return r(t.join(""))}))},t.decodePayload=function(e,n,r){if("string"!=typeof e)return t.decodePayloadAsBinary(e,n,r);var o;if("function"==typeof n&&(r=n,n=null),""===e)return r(d,0,1);for(var i,s,a="",c=0,u=e.length;c<u;c++){var f=e.charAt(c);if(":"===f){if(""===a||a!=(i=Number(a)))return r(d,0,1);if(a!=(s=e.substr(c+1,i)).length)return r(d,0,1);if(s.length){if(o=t.decodePacket(s,n,!1),d.type===o.type&&d.data===o.data)return r(d,0,1);if(!1===r(o,c+i,u))return}c+=i,a=""}else a+=f}return""!==a?r(d,0,1):void 0},t.encodePayloadAsArrayBuffer=function(e,n){if(!e.length)return n(new ArrayBuffer(0));g(e,(function(e,n){t.encodePacket(e,!0,!0,(function(e){return n(null,e)}))}),(function(e,t){var r=t.reduce((function(e,t){var n;return e+(n="string"==typeof t?t.length:t.byteLength).toString().length+n+2}),0),o=new Uint8Array(r),i=0;return t.forEach((function(e){var t="string"==typeof e,n=e;if(t){for(var r=new Uint8Array(e.length),s=0;s<e.length;s++)r[s]=e.charCodeAt(s);n=r.buffer}o[i++]=t?0:1;var a=n.byteLength.toString();for(s=0;s<a.length;s++)o[i++]=parseInt(a[s]);o[i++]=255;for(r=new Uint8Array(n),s=0;s<r.length;s++)o[i++]=r[s]})),n(o.buffer)}))},t.encodePayloadAsBlob=function(e,n){g(e,(function(e,n){t.encodePacket(e,!0,!0,(function(e){var t=new Uint8Array(1);if(t[0]=1,"string"==typeof e){for(var r=new Uint8Array(e.length),o=0;o<e.length;o++)r[o]=e.charCodeAt(o);e=r.buffer,t[0]=0}var i=(e instanceof ArrayBuffer?e.byteLength:e.size).toString(),s=new Uint8Array(i.length+1);for(o=0;o<i.length;o++)s[o]=parseInt(i[o]);if(s[i.length]=255,y){var a=new y([t.buffer,s.buffer,e]);n(null,a)}}))}),(function(e,t){return n(new y(t))}))},t.decodePayloadAsBinary=function(e,n,r){"function"==typeof n&&(r=n,n=null);for(var o=e,i=[];o.byteLength>0;){for(var a=new Uint8Array(o),c=0===a[0],u="",f=1;255!==a[f];f++){if(u.length>310)return r(d,0,1);u+=a[f]}o=s(o,2+u.length),u=parseInt(u);var l=s(o,0,u);if(c)try{l=String.fromCharCode.apply(null,new Uint8Array(l))}catch(e){var h=new Uint8Array(l);l="";for(f=0;f<h.length;f++)l+=String.fromCharCode(h[f])}i.push(l),o=s(o,u)}var p=i.length;i.forEach((function(e,o){r(t.decodePacket(e,n,!0),o,p)}))}},function(e,t,n){(function(r){t.log=function(...e){return"object"==typeof console&&console.log&&console.log(...e)},t.formatArgs=function(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const n="color: "+this.color;t.splice(1,0,n,"color: inherit");let r=0,o=0;t[0].replace(/%[a-zA-Z%]/g,(e=>{"%%"!==e&&(r++,"%c"===e&&(o=r))})),t.splice(o,0,n)},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}},t.load=function(){let e;try{e=t.storage.getItem("debug")}catch(e){}!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG);return e},t.useColors=function(){if("undefined"!=typeof window&&window.process&&("renderer"===window.process.type||window.process.__nwjs))return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage=function(){try{return localStorage}catch(e){}}(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],e.exports=n(34)(t);const{formatters:o}=e.exports;o.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}}).call(this,n(3))},function(e,t){var n,r,o=e.exports={};function i(){throw new Error("setTimeout has not been defined")}function s(){throw new Error("clearTimeout has not been defined")}function a(e){if(n===setTimeout)return setTimeout(e,0);if((n===i||!n)&&setTimeout)return n=setTimeout,setTimeout(e,0);try{return n(e,0)}catch(t){try{return n.call(null,e,0)}catch(t){return n.call(this,e,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:i}catch(e){n=i}try{r="function"==typeof clearTimeout?clearTimeout:s}catch(e){r=s}}();var c,u=[],f=!1,l=-1;function h(){f&&c&&(f=!1,c.length?u=c.concat(u):l=-1,u.length&&p())}function p(){if(!f){var e=a(h);f=!0;for(var t=u.length;t;){for(c=u,u=[];++l<t;)c&&c[l].run();l=-1,t=u.length}c=null,f=!1,function(e){if(r===clearTimeout)return clearTimeout(e);if((r===s||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(e);try{r(e)}catch(t){try{return r.call(null,e)}catch(t){return r.call(this,e)}}}(e)}}function d(e,t){this.fun=e,this.array=t}function y(){}o.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];u.push(new d(e,t)),1!==u.length||f||a(p)},d.prototype.run=function(){this.fun.apply(null,this.array)},o.title="browser",o.browser=!0,o.env={},o.argv=[],o.version="",o.versions={},o.on=y,o.addListener=y,o.once=y,o.off=y,o.removeListener=y,o.removeAllListeners=y,o.emit=y,o.prependListener=y,o.prependOnceListener=y,o.listeners=function(e){return[]},o.binding=function(e){throw new Error("process.binding is not supported")},o.cwd=function(){return"/"},o.chdir=function(e){throw new Error("process.chdir is not supported")},o.umask=function(){return 0}},function(e,t){t.encode=function(e){var t="";for(var n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t},t.decode=function(e){for(var t={},n=e.split("&"),r=0,o=n.length;r<o;r++){var i=n[r].split("=");t[decodeURIComponent(i[0])]=decodeURIComponent(i[1])}return t}},function(e,t){e.exports=function(e,t){var n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e}},function(e,t,n){(function(r){t.log=function(...e){return"object"==typeof console&&console.log&&console.log(...e)},t.formatArgs=function(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const n="color: "+this.color;t.splice(1,0,n,"color: inherit");let r=0,o=0;t[0].replace(/%[a-zA-Z%]/g,(e=>{"%%"!==e&&(r++,"%c"===e&&(o=r))})),t.splice(o,0,n)},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}},t.load=function(){let e;try{e=t.storage.getItem("debug")}catch(e){}!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG);return e},t.useColors=function(){if("undefined"!=typeof window&&window.process&&("renderer"===window.process.type||window.process.__nwjs))return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage=function(){try{return localStorage}catch(e){}}(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],e.exports=n(54)(t);const{formatters:o}=e.exports;o.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}}).call(this,n(3))},function(e,t){var n=1e3,r=60*n,o=60*r,i=24*o,s=7*i,a=365.25*i;function c(e,t,n,r){var o=t>=1.5*n;return Math.round(e/n)+" "+r+(o?"s":"")}e.exports=function(e,t){t=t||{};var u=typeof e;if("string"===u&&e.length>0)return function(e){if((e=String(e)).length>100)return;var t=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(!t)return;var c=parseFloat(t[1]);switch((t[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return c*a;case"weeks":case"week":case"w":return c*s;case"days":case"day":case"d":return c*i;case"hours":case"hour":case"hrs":case"hr":case"h":return c*o;case"minutes":case"minute":case"mins":case"min":case"m":return c*r;case"seconds":case"second":case"secs":case"sec":case"s":return c*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return c;default:return}}(e);if("number"===u&&isFinite(e))return t.long?function(e){var t=Math.abs(e);if(t>=i)return c(e,t,i,"day");if(t>=o)return c(e,t,o,"hour");if(t>=r)return c(e,t,r,"minute");if(t>=n)return c(e,t,n,"second");return e+" ms"}(e):function(e){var t=Math.abs(e);if(t>=i)return Math.round(e/i)+"d";if(t>=o)return Math.round(e/o)+"h";if(t>=r)return Math.round(e/r)+"m";if(t>=n)return Math.round(e/n)+"s";return e+"ms"}(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},function(e,t,n){var r=n(35)("socket.io-parser"),o=n(9),i=n(38),s=n(18),a=n(19);function c(){}t.protocol=4,t.types=["CONNECT","DISCONNECT","EVENT","ACK","ERROR","BINARY_EVENT","BINARY_ACK"],t.CONNECT=0,t.DISCONNECT=1,t.EVENT=2,t.ACK=3,t.ERROR=4,t.BINARY_EVENT=5,t.BINARY_ACK=6,t.Encoder=c,t.Decoder=l;var u=t.ERROR+'"encode error"';function f(e){var n=""+e.type;if(t.BINARY_EVENT!==e.type&&t.BINARY_ACK!==e.type||(n+=e.attachments+"-"),e.nsp&&"/"!==e.nsp&&(n+=e.nsp+","),null!=e.id&&(n+=e.id),null!=e.data){var o=function(e){try{return JSON.stringify(e)}catch(e){return!1}}(e.data);if(!1===o)return u;n+=o}return r("encoded %j as %s",e,n),n}function l(){this.reconstructor=null}function h(e){this.reconPack=e,this.buffers=[]}function p(e){return{type:t.ERROR,data:"parser error: "+e}}c.prototype.encode=function(e,n){(r("encoding packet %j",e),t.BINARY_EVENT===e.type||t.BINARY_ACK===e.type)?function(e,t){function n(e){var n=i.deconstructPacket(e),r=f(n.packet),o=n.buffers;o.unshift(r),t(o)}i.removeBlobs(e,n)}(e,n):n([f(e)])},o(l.prototype),l.prototype.add=function(e){var n;if("string"==typeof e)n=function(e){var n=0,o={type:Number(e.charAt(0))};if(null==t.types[o.type])return p("unknown packet type "+o.type);if(t.BINARY_EVENT===o.type||t.BINARY_ACK===o.type){for(var i="";"-"!==e.charAt(++n)&&(i+=e.charAt(n),n!=e.length););if(i!=Number(i)||"-"!==e.charAt(n))throw new Error("Illegal attachments");o.attachments=Number(i)}if("/"===e.charAt(n+1))for(o.nsp="";++n;){if(","===(c=e.charAt(n)))break;if(o.nsp+=c,n===e.length)break}else o.nsp="/";var a=e.charAt(n+1);if(""!==a&&Number(a)==a){for(o.id="";++n;){var c;if(null==(c=e.charAt(n))||Number(c)!=c){--n;break}if(o.id+=e.charAt(n),n===e.length)break}o.id=Number(o.id)}if(e.charAt(++n)){var u=function(e){try{return JSON.parse(e)}catch(e){return!1}}(e.substr(n));if(!(!1!==u&&(o.type===t.ERROR||s(u))))return p("invalid payload");o.data=u}return r("decoded %s as %j",e,o),o}(e),t.BINARY_EVENT===n.type||t.BINARY_ACK===n.type?(this.reconstructor=new h(n),0===this.reconstructor.reconPack.attachments&&this.emit("decoded",n)):this.emit("decoded",n);else{if(!a(e)&&!e.base64)throw new Error("Unknown type: "+e);if(!this.reconstructor)throw new Error("got binary data when not reconstructing a packet");(n=this.reconstructor.takeBinaryData(e))&&(this.reconstructor=null,this.emit("decoded",n))}},l.prototype.destroy=function(){this.reconstructor&&this.reconstructor.finishedReconstruction()},h.prototype.takeBinaryData=function(e){if(this.buffers.push(e),this.buffers.length===this.reconPack.attachments){var t=i.reconstructPacket(this.reconPack,this.buffers);return this.finishedReconstruction(),t}return null},h.prototype.finishedReconstruction=function(){this.reconPack=null,this.buffers=[]}},function(e,t,n){function r(e){if(e)return function(e){for(var t in r.prototype)e[t]=r.prototype[t];return e}(e)}e.exports=r,r.prototype.on=r.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},r.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},r.prototype.off=r.prototype.removeListener=r.prototype.removeAllListeners=r.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var n,r=this._callbacks["$"+e];if(!r)return this;if(1==arguments.length)return delete this._callbacks["$"+e],this;for(var o=0;o<r.length;o++)if((n=r[o])===t||n.fn===t){r.splice(o,1);break}return this},r.prototype.emit=function(e){this._callbacks=this._callbacks||{};var t=[].slice.call(arguments,1),n=this._callbacks["$"+e];if(n)for(var r=0,o=(n=n.slice(0)).length;r<o;++r)n[r].apply(this,t);return this},r.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},r.prototype.hasListeners=function(e){return!!this.listeners(e).length}},function(e,t,n){"use strict";(function(e){
+window["offload-worker"]=function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=87)}([function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r,o=(r=n(28))&&r.__esModule?r:{default:r};var i=["debug","error","info","log","warn","time","timeEnd","table"];t.default=function e(t){var n=this;if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),!t)throw new Error("Need a prefix when creating Logger class");i.forEach((function(e){e.indexOf("time")>-1?n[e]=(0,o.default)("".concat("offload",":TIME:")):n[e]=(0,o.default)("".concat("offload",":").concat(e.toUpperCase(),":").concat(t)),n[e].log=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];this.apply(this,t)}.bind(console[e])}))}},function(e,t,n){var r,o=n(47),i=n(15),s=n(48),a=n(49),c=n(50);"undefined"!=typeof ArrayBuffer&&(r=n(51));var u="undefined"!=typeof navigator&&/Android/i.test(navigator.userAgent),f="undefined"!=typeof navigator&&/PhantomJS/i.test(navigator.userAgent),l=u||f;t.protocol=3;var h=t.packets={open:0,close:1,ping:2,pong:3,message:4,upgrade:5,noop:6},p=o(h),d={type:"error",data:"parser error"},y=n(52);function g(e,t,n){for(var r=new Array(e.length),o=a(e.length,n),i=function(e,n,o){t(n,(function(t,n){r[e]=n,o(t,r)}))},s=0;s<e.length;s++)i(s,e[s],o)}t.encodePacket=function(e,n,r,o){"function"==typeof n&&(o=n,n=!1),"function"==typeof r&&(o=r,r=null);var i=void 0===e.data?void 0:e.data.buffer||e.data;if("undefined"!=typeof ArrayBuffer&&i instanceof ArrayBuffer)return function(e,n,r){if(!n)return t.encodeBase64Packet(e,r);var o=e.data,i=new Uint8Array(o),s=new Uint8Array(1+o.byteLength);s[0]=h[e.type];for(var a=0;a<i.length;a++)s[a+1]=i[a];return r(s.buffer)}(e,n,o);if(void 0!==y&&i instanceof y)return function(e,n,r){if(!n)return t.encodeBase64Packet(e,r);if(l)return function(e,n,r){if(!n)return t.encodeBase64Packet(e,r);var o=new FileReader;return o.onload=function(){t.encodePacket({type:e.type,data:o.result},n,!0,r)},o.readAsArrayBuffer(e.data)}(e,n,r);var o=new Uint8Array(1);o[0]=h[e.type];var i=new y([o.buffer,e.data]);return r(i)}(e,n,o);if(i&&i.base64)return function(e,n){var r="b"+t.packets[e.type]+e.data.data;return n(r)}(e,o);var s=h[e.type];return void 0!==e.data&&(s+=r?c.encode(String(e.data),{strict:!1}):String(e.data)),o(""+s)},t.encodeBase64Packet=function(e,n){var r,o="b"+t.packets[e.type];if(void 0!==y&&e.data instanceof y){var i=new FileReader;return i.onload=function(){var e=i.result.split(",")[1];n(o+e)},i.readAsDataURL(e.data)}try{r=String.fromCharCode.apply(null,new Uint8Array(e.data))}catch(t){for(var s=new Uint8Array(e.data),a=new Array(s.length),c=0;c<s.length;c++)a[c]=s[c];r=String.fromCharCode.apply(null,a)}return o+=btoa(r),n(o)},t.decodePacket=function(e,n,r){if(void 0===e)return d;if("string"==typeof e){if("b"===e.charAt(0))return t.decodeBase64Packet(e.substr(1),n);if(r&&!1===(e=function(e){try{e=c.decode(e,{strict:!1})}catch(e){return!1}return e}(e)))return d;var o=e.charAt(0);return Number(o)==o&&p[o]?e.length>1?{type:p[o],data:e.substring(1)}:{type:p[o]}:d}o=new Uint8Array(e)[0];var i=s(e,1);return y&&"blob"===n&&(i=new y([i])),{type:p[o],data:i}},t.decodeBase64Packet=function(e,t){var n=p[e.charAt(0)];if(!r)return{type:n,data:{base64:!0,data:e.substr(1)}};var o=r.decode(e.substr(1));return"blob"===t&&y&&(o=new y([o])),{type:n,data:o}},t.encodePayload=function(e,n,r){"function"==typeof n&&(r=n,n=null);var o=i(e);if(n&&o)return y&&!l?t.encodePayloadAsBlob(e,r):t.encodePayloadAsArrayBuffer(e,r);if(!e.length)return r("0:");g(e,(function(e,r){t.encodePacket(e,!!o&&n,!1,(function(e){r(null,function(e){return e.length+":"+e}(e))}))}),(function(e,t){return r(t.join(""))}))},t.decodePayload=function(e,n,r){if("string"!=typeof e)return t.decodePayloadAsBinary(e,n,r);var o;if("function"==typeof n&&(r=n,n=null),""===e)return r(d,0,1);for(var i,s,a="",c=0,u=e.length;c<u;c++){var f=e.charAt(c);if(":"===f){if(""===a||a!=(i=Number(a)))return r(d,0,1);if(a!=(s=e.substr(c+1,i)).length)return r(d,0,1);if(s.length){if(o=t.decodePacket(s,n,!1),d.type===o.type&&d.data===o.data)return r(d,0,1);if(!1===r(o,c+i,u))return}c+=i,a=""}else a+=f}return""!==a?r(d,0,1):void 0},t.encodePayloadAsArrayBuffer=function(e,n){if(!e.length)return n(new ArrayBuffer(0));g(e,(function(e,n){t.encodePacket(e,!0,!0,(function(e){return n(null,e)}))}),(function(e,t){var r=t.reduce((function(e,t){var n;return e+(n="string"==typeof t?t.length:t.byteLength).toString().length+n+2}),0),o=new Uint8Array(r),i=0;return t.forEach((function(e){var t="string"==typeof e,n=e;if(t){for(var r=new Uint8Array(e.length),s=0;s<e.length;s++)r[s]=e.charCodeAt(s);n=r.buffer}o[i++]=t?0:1;var a=n.byteLength.toString();for(s=0;s<a.length;s++)o[i++]=parseInt(a[s]);o[i++]=255;for(r=new Uint8Array(n),s=0;s<r.length;s++)o[i++]=r[s]})),n(o.buffer)}))},t.encodePayloadAsBlob=function(e,n){g(e,(function(e,n){t.encodePacket(e,!0,!0,(function(e){var t=new Uint8Array(1);if(t[0]=1,"string"==typeof e){for(var r=new Uint8Array(e.length),o=0;o<e.length;o++)r[o]=e.charCodeAt(o);e=r.buffer,t[0]=0}var i=(e instanceof ArrayBuffer?e.byteLength:e.size).toString(),s=new Uint8Array(i.length+1);for(o=0;o<i.length;o++)s[o]=parseInt(i[o]);if(s[i.length]=255,y){var a=new y([t.buffer,s.buffer,e]);n(null,a)}}))}),(function(e,t){return n(new y(t))}))},t.decodePayloadAsBinary=function(e,n,r){"function"==typeof n&&(r=n,n=null);for(var o=e,i=[];o.byteLength>0;){for(var a=new Uint8Array(o),c=0===a[0],u="",f=1;255!==a[f];f++){if(u.length>310)return r(d,0,1);u+=a[f]}o=s(o,2+u.length),u=parseInt(u);var l=s(o,0,u);if(c)try{l=String.fromCharCode.apply(null,new Uint8Array(l))}catch(e){var h=new Uint8Array(l);l="";for(f=0;f<h.length;f++)l+=String.fromCharCode(h[f])}i.push(l),o=s(o,u)}var p=i.length;i.forEach((function(e,o){r(t.decodePacket(e,n,!0),o,p)}))}},function(e,t){var n,r,o=e.exports={};function i(){throw new Error("setTimeout has not been defined")}function s(){throw new Error("clearTimeout has not been defined")}function a(e){if(n===setTimeout)return setTimeout(e,0);if((n===i||!n)&&setTimeout)return n=setTimeout,setTimeout(e,0);try{return n(e,0)}catch(t){try{return n.call(null,e,0)}catch(t){return n.call(this,e,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:i}catch(e){n=i}try{r="function"==typeof clearTimeout?clearTimeout:s}catch(e){r=s}}();var c,u=[],f=!1,l=-1;function h(){f&&c&&(f=!1,c.length?u=c.concat(u):l=-1,u.length&&p())}function p(){if(!f){var e=a(h);f=!0;for(var t=u.length;t;){for(c=u,u=[];++l<t;)c&&c[l].run();l=-1,t=u.length}c=null,f=!1,function(e){if(r===clearTimeout)return clearTimeout(e);if((r===s||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(e);try{r(e)}catch(t){try{return r.call(null,e)}catch(t){return r.call(this,e)}}}(e)}}function d(e,t){this.fun=e,this.array=t}function y(){}o.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];u.push(new d(e,t)),1!==u.length||f||a(p)},d.prototype.run=function(){this.fun.apply(null,this.array)},o.title="browser",o.browser=!0,o.env={},o.argv=[],o.version="",o.versions={},o.on=y,o.addListener=y,o.once=y,o.off=y,o.removeListener=y,o.removeAllListeners=y,o.emit=y,o.prependListener=y,o.prependOnceListener=y,o.listeners=function(e){return[]},o.binding=function(e){throw new Error("process.binding is not supported")},o.cwd=function(){return"/"},o.chdir=function(e){throw new Error("process.chdir is not supported")},o.umask=function(){return 0}},function(e,t,n){(function(r){function o(){var e;try{e=t.storage.debug}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}(t=e.exports=n(34)).log=function(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)},t.formatArgs=function(e){var n=this.useColors;if(e[0]=(n?"%c":"")+this.namespace+(n?" %c":" ")+e[0]+(n?"%c ":" ")+"+"+t.humanize(this.diff),!n)return;var r="color: "+this.color;e.splice(1,0,r,"color: inherit");var o=0,i=0;e[0].replace(/%[a-zA-Z%]/g,(function(e){"%%"!==e&&(o++,"%c"===e&&(i=o))})),e.splice(i,0,r)},t.save=function(e){try{null==e?t.storage.removeItem("debug"):t.storage.debug=e}catch(e){}},t.load=o,t.useColors=function(){if("undefined"!=typeof window&&window.process&&"renderer"===window.process.type)return!0;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:function(){try{return window.localStorage}catch(e){}}(),t.colors=["lightseagreen","forestgreen","goldenrod","dodgerblue","darkorchid","crimson"],t.formatters.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}},t.enable(o())}).call(this,n(3))},function(e,t){t.encode=function(e){var t="";for(var n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t},t.decode=function(e){for(var t={},n=e.split("&"),r=0,o=n.length;r<o;r++){var i=n[r].split("=");t[decodeURIComponent(i[0])]=decodeURIComponent(i[1])}return t}},function(e,t){e.exports=function(e,t){var n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e}},function(e,t,n){(function(r){function o(){var e;try{e=t.storage.debug}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}(t=e.exports=n(53)).log=function(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)},t.formatArgs=function(e){var n=this.useColors;if(e[0]=(n?"%c":"")+this.namespace+(n?" %c":" ")+e[0]+(n?"%c ":" ")+"+"+t.humanize(this.diff),!n)return;var r="color: "+this.color;e.splice(1,0,r,"color: inherit");var o=0,i=0;e[0].replace(/%[a-zA-Z%]/g,(function(e){"%%"!==e&&(o++,"%c"===e&&(i=o))})),e.splice(i,0,r)},t.save=function(e){try{null==e?t.storage.removeItem("debug"):t.storage.debug=e}catch(e){}},t.load=o,t.useColors=function(){if("undefined"!=typeof window&&window.process&&"renderer"===window.process.type)return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:function(){try{return window.localStorage}catch(e){}}(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.formatters.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}},t.enable(o())}).call(this,n(3))},function(e,t,n){var r=n(35)("socket.io-parser"),o=n(9),i=n(15),s=n(42),a=n(16),c=n(17);function u(){}function f(e){var n=""+e.type;return t.BINARY_EVENT!==e.type&&t.BINARY_ACK!==e.type||(n+=e.attachments+"-"),e.nsp&&"/"!==e.nsp&&(n+=e.nsp+","),null!=e.id&&(n+=e.id),null!=e.data&&(n+=JSON.stringify(e.data)),r("encoded %j as %s",e,n),n}function l(){this.reconstructor=null}function h(e){this.reconPack=e,this.buffers=[]}function p(e){return{type:t.ERROR,data:"parser error: "+e}}t.protocol=4,t.types=["CONNECT","DISCONNECT","EVENT","ACK","ERROR","BINARY_EVENT","BINARY_ACK"],t.CONNECT=0,t.DISCONNECT=1,t.EVENT=2,t.ACK=3,t.ERROR=4,t.BINARY_EVENT=5,t.BINARY_ACK=6,t.Encoder=u,t.Decoder=l,u.prototype.encode=function(e,n){(e.type!==t.EVENT&&e.type!==t.ACK||!i(e.data)||(e.type=e.type===t.EVENT?t.BINARY_EVENT:t.BINARY_ACK),r("encoding packet %j",e),t.BINARY_EVENT===e.type||t.BINARY_ACK===e.type)?function(e,t){s.removeBlobs(e,(function(e){var n=s.deconstructPacket(e),r=f(n.packet),o=n.buffers;o.unshift(r),t(o)}))}(e,n):n([f(e)])},o(l.prototype),l.prototype.add=function(e){var n;if("string"==typeof e)n=function(e){var n=0,o={type:Number(e.charAt(0))};if(null==t.types[o.type])return p("unknown packet type "+o.type);if(t.BINARY_EVENT===o.type||t.BINARY_ACK===o.type){for(var i="";"-"!==e.charAt(++n)&&(i+=e.charAt(n),n!=e.length););if(i!=Number(i)||"-"!==e.charAt(n))throw new Error("Illegal attachments");o.attachments=Number(i)}if("/"===e.charAt(n+1))for(o.nsp="";++n;){if(","===(c=e.charAt(n)))break;if(o.nsp+=c,n===e.length)break}else o.nsp="/";var s=e.charAt(n+1);if(""!==s&&Number(s)==s){for(o.id="";++n;){var c;if(null==(c=e.charAt(n))||Number(c)!=c){--n;break}if(o.id+=e.charAt(n),n===e.length)break}o.id=Number(o.id)}if(e.charAt(++n)){var u=function(e){try{return JSON.parse(e)}catch(e){return!1}}(e.substr(n));if(!(!1!==u&&(o.type===t.ERROR||a(u))))return p("invalid payload");o.data=u}return r("decoded %s as %j",e,o),o}(e),t.BINARY_EVENT===n.type||t.BINARY_ACK===n.type?(this.reconstructor=new h(n),0===this.reconstructor.reconPack.attachments&&this.emit("decoded",n)):this.emit("decoded",n);else{if(!c(e)&&!e.base64)throw new Error("Unknown type: "+e);if(!this.reconstructor)throw new Error("got binary data when not reconstructing a packet");(n=this.reconstructor.takeBinaryData(e))&&(this.reconstructor=null,this.emit("decoded",n))}},l.prototype.destroy=function(){this.reconstructor&&this.reconstructor.finishedReconstruction()},h.prototype.takeBinaryData=function(e){if(this.buffers.push(e),this.buffers.length===this.reconPack.attachments){var t=s.reconstructPacket(this.reconPack,this.buffers);return this.finishedReconstruction(),t}return null},h.prototype.finishedReconstruction=function(){this.reconPack=null,this.buffers=[]}},function(e,t,n){function r(e){if(e)return function(e){for(var t in r.prototype)e[t]=r.prototype[t];return e}(e)}e.exports=r,r.prototype.on=r.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},r.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},r.prototype.off=r.prototype.removeListener=r.prototype.removeAllListeners=r.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var n,r=this._callbacks["$"+e];if(!r)return this;if(1==arguments.length)return delete this._callbacks["$"+e],this;for(var o=0;o<r.length;o++)if((n=r[o])===t||n.fn===t){r.splice(o,1);break}return this},r.prototype.emit=function(e){this._callbacks=this._callbacks||{};var t=[].slice.call(arguments,1),n=this._callbacks["$"+e];if(n)for(var r=0,o=(n=n.slice(0)).length;r<o;++r)n[r].apply(this,t);return this},r.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},r.prototype.hasListeners=function(e){return!!this.listeners(e).length}},function(e,t,n){(function(t){var r=n(45);e.exports=function(e){var n=e.xdomain,o=e.xscheme,i=e.enablesXDR;try{if("undefined"!=typeof XMLHttpRequest&&(!n||r))return new XMLHttpRequest}catch(e){}try{if("undefined"!=typeof XDomainRequest&&!o&&i)return new XDomainRequest}catch(e){}if(!n)try{return new(t[["Active"].concat("Object").join("X")])("Microsoft.XMLHTTP")}catch(e){}}}).call(this,n(0))},function(e,t,n){var r=n(2),o=n(12);function i(e){this.path=e.path,this.hostname=e.hostname,this.port=e.port,this.secure=e.secure,this.query=e.query,this.timestampParam=e.timestampParam,this.timestampRequests=e.timestampRequests,this.readyState="",this.agent=e.agent||!1,this.socket=e.socket,this.enablesXDR=e.enablesXDR,this.pfx=e.pfx,this.key=e.key,this.passphrase=e.passphrase,this.cert=e.cert,this.ca=e.ca,this.ciphers=e.ciphers,this.rejectUnauthorized=e.rejectUnauthorized,this.forceNode=e.forceNode,this.extraHeaders=e.extraHeaders,this.localAddress=e.localAddress}e.exports=i,o(i.prototype),i.prototype.onError=function(e,t){var n=new Error(e);return n.type="TransportError",n.description=t,this.emit("error",n),this},i.prototype.open=function(){return"closed"!==this.readyState&&""!==this.readyState||(this.readyState="opening",this.doOpen()),this},i.prototype.close=function(){return"opening"!==this.readyState&&"open"!==this.readyState||(this.doClose(),this.onClose()),this},i.prototype.send=function(e){if("open"!==this.readyState)throw new Error("Transport not open");this.write(e)},i.prototype.onOpen=function(){this.readyState="open",this.writable=!0,this.emit("open")},i.prototype.onData=function(e){var t=r.decodePacket(e,this.socket.binaryType);this.onPacket(t)},i.prototype.onPacket=function(e){this.emit("packet",e)},i.prototype.onClose=function(){this.readyState="closed",this.emit("close")}},function(e,t,n){function r(e){if(e)return function(e){for(var t in r.prototype)e[t]=r.prototype[t];return e}(e)}e.exports=r,r.prototype.on=r.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},r.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},r.prototype.off=r.prototype.removeListener=r.prototype.removeAllListeners=r.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var n,r=this._callbacks["$"+e];if(!r)return this;if(1==arguments.length)return delete this._callbacks["$"+e],this;for(var o=0;o<r.length;o++)if((n=r[o])===t||n.fn===t){r.splice(o,1);break}return this},r.prototype.emit=function(e){this._callbacks=this._callbacks||{};var t=[].slice.call(arguments,1),n=this._callbacks["$"+e];if(n)for(var r=0,o=(n=n.slice(0)).length;r<o;++r)n[r].apply(this,t);return this},r.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},r.prototype.hasListeners=function(e){return!!this.listeners(e).length}},function(e,t){var n=/^(?:(?![^:@]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@]*)(?::([^:@]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,r=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];e.exports=function(e){var t=e,o=e.indexOf("["),i=e.indexOf("]");-1!=o&&-1!=i&&(e=e.substring(0,o)+e.substring(o,i).replace(/:/g,";")+e.substring(i,e.length));for(var s=n.exec(e||""),a={},c=14;c--;)a[r[c]]=s[c]||"";return-1!=o&&-1!=i&&(a.source=t,a.host=a.host.substring(1,a.host.length-1).replace(/;/g,":"),a.authority=a.authority.replace("[","").replace("]","").replace(/;/g,":"),a.ipv6uri=!0),a}},function(e,t){var n=1e3,r=6e4,o=60*r,i=24*o;function s(e,t,n){if(!(e<t))return e<1.5*t?Math.floor(e/t)+" "+n:Math.ceil(e/t)+" "+n+"s"}e.exports=function(e,t){t=t||{};var a,c=typeof e;if("string"===c&&e.length>0)return function(e){if((e=String(e)).length>100)return;var t=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(e);if(!t)return;var s=parseFloat(t[1]);switch((t[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*s;case"days":case"day":case"d":return s*i;case"hours":case"hour":case"hrs":case"hr":case"h":return s*o;case"minutes":case"minute":case"mins":case"min":case"m":return s*r;case"seconds":case"second":case"secs":case"sec":case"s":return s*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return s;default:return}}(e);if("number"===c&&!1===isNaN(e))return t.long?s(a=e,i,"day")||s(a,o,"hour")||s(a,r,"minute")||s(a,n,"second")||a+" ms":function(e){if(e>=i)return Math.round(e/i)+"d";if(e>=o)return Math.round(e/o)+"h";if(e>=r)return Math.round(e/r)+"m";if(e>=n)return Math.round(e/n)+"s";return e+"ms"}(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},function(e,t,n){(function(t){var r=n(41),o=Object.prototype.toString,i="function"==typeof Blob||"undefined"!=typeof Blob&&"[object BlobConstructor]"===o.call(Blob),s="function"==typeof File||"undefined"!=typeof File&&"[object FileConstructor]"===o.call(File);e.exports=function e(n){if(!n||"object"!=typeof n)return!1;if(r(n)){for(var o=0,a=n.length;o<a;o++)if(e(n[o]))return!0;return!1}if("function"==typeof t&&t.isBuffer&&t.isBuffer(n)||"function"==typeof ArrayBuffer&&n instanceof ArrayBuffer||i&&n instanceof Blob||s&&n instanceof File)return!0;if(n.toJSON&&"function"==typeof n.toJSON&&1===arguments.length)return e(n.toJSON(),!0);for(var c in n)if(Object.prototype.hasOwnProperty.call(n,c)&&e(n[c]))return!0;return!1}}).call(this,n(37).Buffer)},function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},function(e,t,n){(function(t){e.exports=function(e){return t.Buffer&&t.Buffer.isBuffer(e)||t.ArrayBuffer&&(e instanceof ArrayBuffer||ArrayBuffer.isView(e))}}).call(this,n(0))},function(e,t,n){var r=n(43),o=n(23),i=n(9),s=n(8),a=n(24),c=n(25),u=n(4)("socket.io-client:manager"),f=n(22),l=n(59),h=Object.prototype.hasOwnProperty;function p(e,t){if(!(this instanceof p))return new p(e,t);e&&"object"==typeof e&&(t=e,e=void 0),(t=t||{}).path=t.path||"/socket.io",this.nsps={},this.subs=[],this.opts=t,this.reconnection(!1!==t.reconnection),this.reconnectionAttempts(t.reconnectionAttempts||1/0),this.reconnectionDelay(t.reconnectionDelay||1e3),this.reconnectionDelayMax(t.reconnectionDelayMax||5e3),this.randomizationFactor(t.randomizationFactor||.5),this.backoff=new l({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(null==t.timeout?2e4:t.timeout),this.readyState="closed",this.uri=e,this.connecting=[],this.lastPing=null,this.encoding=!1,this.packetBuffer=[];var n=t.parser||s;this.encoder=new n.Encoder,this.decoder=new n.Decoder,this.autoConnect=!1!==t.autoConnect,this.autoConnect&&this.open()}e.exports=p,p.prototype.emitAll=function(){for(var e in this.emit.apply(this,arguments),this.nsps)h.call(this.nsps,e)&&this.nsps[e].emit.apply(this.nsps[e],arguments)},p.prototype.updateSocketIds=function(){for(var e in this.nsps)h.call(this.nsps,e)&&(this.nsps[e].id=this.generateId(e))},p.prototype.generateId=function(e){return("/"===e?"":e+"#")+this.engine.id},i(p.prototype),p.prototype.reconnection=function(e){return arguments.length?(this._reconnection=!!e,this):this._reconnection},p.prototype.reconnectionAttempts=function(e){return arguments.length?(this._reconnectionAttempts=e,this):this._reconnectionAttempts},p.prototype.reconnectionDelay=function(e){return arguments.length?(this._reconnectionDelay=e,this.backoff&&this.backoff.setMin(e),this):this._reconnectionDelay},p.prototype.randomizationFactor=function(e){return arguments.length?(this._randomizationFactor=e,this.backoff&&this.backoff.setJitter(e),this):this._randomizationFactor},p.prototype.reconnectionDelayMax=function(e){return arguments.length?(this._reconnectionDelayMax=e,this.backoff&&this.backoff.setMax(e),this):this._reconnectionDelayMax},p.prototype.timeout=function(e){return arguments.length?(this._timeout=e,this):this._timeout},p.prototype.maybeReconnectOnOpen=function(){!this.reconnecting&&this._reconnection&&0===this.backoff.attempts&&this.reconnect()},p.prototype.open=p.prototype.connect=function(e,t){if(u("readyState %s",this.readyState),~this.readyState.indexOf("open"))return this;u("opening %s",this.uri),this.engine=r(this.uri,this.opts);var n=this.engine,o=this;this.readyState="opening",this.skipReconnect=!1;var i=a(n,"open",(function(){o.onopen(),e&&e()})),s=a(n,"error",(function(t){if(u("connect_error"),o.cleanup(),o.readyState="closed",o.emitAll("connect_error",t),e){var n=new Error("Connection error");n.data=t,e(n)}else o.maybeReconnectOnOpen()}));if(!1!==this._timeout){var c=this._timeout;u("connect attempt will timeout after %d",c);var f=setTimeout((function(){u("connect attempt timed out after %d",c),i.destroy(),n.close(),n.emit("error","timeout"),o.emitAll("connect_timeout",c)}),c);this.subs.push({destroy:function(){clearTimeout(f)}})}return this.subs.push(i),this.subs.push(s),this},p.prototype.onopen=function(){u("open"),this.cleanup(),this.readyState="open",this.emit("open");var e=this.engine;this.subs.push(a(e,"data",c(this,"ondata"))),this.subs.push(a(e,"ping",c(this,"onping"))),this.subs.push(a(e,"pong",c(this,"onpong"))),this.subs.push(a(e,"error",c(this,"onerror"))),this.subs.push(a(e,"close",c(this,"onclose"))),this.subs.push(a(this.decoder,"decoded",c(this,"ondecoded")))},p.prototype.onping=function(){this.lastPing=new Date,this.emitAll("ping")},p.prototype.onpong=function(){this.emitAll("pong",new Date-this.lastPing)},p.prototype.ondata=function(e){this.decoder.add(e)},p.prototype.ondecoded=function(e){this.emit("packet",e)},p.prototype.onerror=function(e){u("error",e),this.emitAll("error",e)},p.prototype.socket=function(e,t){var n=this.nsps[e];if(!n){n=new o(this,e,t),this.nsps[e]=n;var r=this;n.on("connecting",i),n.on("connect",(function(){n.id=r.generateId(e)})),this.autoConnect&&i()}function i(){~f(r.connecting,n)||r.connecting.push(n)}return n},p.prototype.destroy=function(e){var t=f(this.connecting,e);~t&&this.connecting.splice(t,1),this.connecting.length||this.close()},p.prototype.packet=function(e){u("writing packet %j",e);var t=this;e.query&&0===e.type&&(e.nsp+="?"+e.query),t.encoding?t.packetBuffer.push(e):(t.encoding=!0,this.encoder.encode(e,(function(n){for(var r=0;r<n.length;r++)t.engine.write(n[r],e.options);t.encoding=!1,t.processPacketQueue()})))},p.prototype.processPacketQueue=function(){if(this.packetBuffer.length>0&&!this.encoding){var e=this.packetBuffer.shift();this.packet(e)}},p.prototype.cleanup=function(){u("cleanup");for(var e=this.subs.length,t=0;t<e;t++){this.subs.shift().destroy()}this.packetBuffer=[],this.encoding=!1,this.lastPing=null,this.decoder.destroy()},p.prototype.close=p.prototype.disconnect=function(){u("disconnect"),this.skipReconnect=!0,this.reconnecting=!1,"opening"===this.readyState&&this.cleanup(),this.backoff.reset(),this.readyState="closed",this.engine&&this.engine.close()},p.prototype.onclose=function(e){u("onclose"),this.cleanup(),this.backoff.reset(),this.readyState="closed",this.emit("close",e),this._reconnection&&!this.skipReconnect&&this.reconnect()},p.prototype.reconnect=function(){if(this.reconnecting||this.skipReconnect)return this;var e=this;if(this.backoff.attempts>=this._reconnectionAttempts)u("reconnect failed"),this.backoff.reset(),this.emitAll("reconnect_failed"),this.reconnecting=!1;else{var t=this.backoff.duration();u("will wait %dms before reconnect attempt",t),this.reconnecting=!0;var n=setTimeout((function(){e.skipReconnect||(u("attempting reconnect"),e.emitAll("reconnect_attempt",e.backoff.attempts),e.emitAll("reconnecting",e.backoff.attempts),e.skipReconnect||e.open((function(t){t?(u("reconnect attempt error"),e.reconnecting=!1,e.reconnect(),e.emitAll("reconnect_error",t.data)):(u("reconnect success"),e.onreconnect())})))}),t);this.subs.push({destroy:function(){clearTimeout(n)}})}},p.prototype.onreconnect=function(){var e=this.backoff.attempts;this.reconnecting=!1,this.backoff.reset(),this.updateSocketIds(),this.emitAll("reconnect",e)}},function(e,t,n){(function(e){var r=n(10),o=n(46),i=n(55),s=n(56);t.polling=function(t){var n=!1,s=!1,a=!1!==t.jsonp;if(e.location){var c="https:"===location.protocol,u=location.port;u||(u=c?443:80),n=t.hostname!==location.hostname||u!==t.port,s=t.secure!==c}if(t.xdomain=n,t.xscheme=s,"open"in new r(t)&&!t.forceJSONP)return new o(t);if(!a)throw new Error("JSONP disabled");return new i(t)},t.websocket=s}).call(this,n(0))},function(e,t,n){var r=n(11),o=n(5),i=n(2),s=n(6),a=n(21),c=n(7)("engine.io-client:polling");e.exports=f;var u=null!=new(n(10))({xdomain:!1}).responseType;function f(e){var t=e&&e.forceBase64;u&&!t||(this.supportsBinary=!1),r.call(this,e)}s(f,r),f.prototype.name="polling",f.prototype.doOpen=function(){this.poll()},f.prototype.pause=function(e){var t=this;function n(){c("paused"),t.readyState="paused",e()}if(this.readyState="pausing",this.polling||!this.writable){var r=0;this.polling&&(c("we are currently polling - waiting to pause"),r++,this.once("pollComplete",(function(){c("pre-pause polling complete"),--r||n()}))),this.writable||(c("we are currently writing - waiting to pause"),r++,this.once("drain",(function(){c("pre-pause writing complete"),--r||n()})))}else n()},f.prototype.poll=function(){c("polling"),this.polling=!0,this.doPoll(),this.emit("poll")},f.prototype.onData=function(e){var t=this;c("polling got data %s",e);i.decodePayload(e,this.socket.binaryType,(function(e,n,r){if("opening"===t.readyState&&t.onOpen(),"close"===e.type)return t.onClose(),!1;t.onPacket(e)})),"closed"!==this.readyState&&(this.polling=!1,this.emit("pollComplete"),"open"===this.readyState?this.poll():c('ignoring poll - transport state "%s"',this.readyState))},f.prototype.doClose=function(){var e=this;function t(){c("writing close packet"),e.write([{type:"close"}])}"open"===this.readyState?(c("transport open - closing"),t()):(c("transport not open - deferring close"),this.once("open",t))},f.prototype.write=function(e){var t=this;this.writable=!1;var n=function(){t.writable=!0,t.emit("drain")};i.encodePayload(e,this.supportsBinary,(function(e){t.doWrite(e,n)}))},f.prototype.uri=function(){var e=this.query||{},t=this.secure?"https":"http",n="";return!1!==this.timestampRequests&&(e[this.timestampParam]=a()),this.supportsBinary||e.sid||(e.b64=1),e=o.encode(e),this.port&&("https"===t&&443!==Number(this.port)||"http"===t&&80!==Number(this.port))&&(n=":"+this.port),e.length&&(e="?"+e),t+"://"+(-1!==this.hostname.indexOf(":")?"["+this.hostname+"]":this.hostname)+n+this.path+e}},function(e,t,n){"use strict";var r,o="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-_".split(""),i={},s=0,a=0;function c(e){var t="";do{t=o[e%64]+t,e=Math.floor(e/64)}while(e>0);return t}function u(){var e=c(+new Date);return e!==r?(s=0,r=e):e+"."+c(s++)}for(;a<64;a++)i[o[a]]=a;u.encode=c,u.decode=function(e){var t=0;for(a=0;a<e.length;a++)t=64*t+i[e.charAt(a)];return t},e.exports=u},function(e,t){var n=[].indexOf;e.exports=function(e,t){if(n)return e.indexOf(t);for(var r=0;r<e.length;++r)if(e[r]===t)return r;return-1}},function(e,t,n){var r=n(8),o=n(9),i=n(58),s=n(24),a=n(25),c=n(4)("socket.io-client:socket"),u=n(5);e.exports=h;var f={connect:1,connect_error:1,connect_timeout:1,connecting:1,disconnect:1,error:1,reconnect:1,reconnect_attempt:1,reconnect_failed:1,reconnect_error:1,reconnecting:1,ping:1,pong:1},l=o.prototype.emit;function h(e,t,n){this.io=e,this.nsp=t,this.json=this,this.ids=0,this.acks={},this.receiveBuffer=[],this.sendBuffer=[],this.connected=!1,this.disconnected=!0,n&&n.query&&(this.query=n.query),this.io.autoConnect&&this.open()}o(h.prototype),h.prototype.subEvents=function(){if(!this.subs){var e=this.io;this.subs=[s(e,"open",a(this,"onopen")),s(e,"packet",a(this,"onpacket")),s(e,"close",a(this,"onclose"))]}},h.prototype.open=h.prototype.connect=function(){return this.connected||(this.subEvents(),this.io.open(),"open"===this.io.readyState&&this.onopen(),this.emit("connecting")),this},h.prototype.send=function(){var e=i(arguments);return e.unshift("message"),this.emit.apply(this,e),this},h.prototype.emit=function(e){if(f.hasOwnProperty(e))return l.apply(this,arguments),this;var t=i(arguments),n={type:r.EVENT,data:t,options:{}};return n.options.compress=!this.flags||!1!==this.flags.compress,"function"==typeof t[t.length-1]&&(c("emitting packet with ack id %d",this.ids),this.acks[this.ids]=t.pop(),n.id=this.ids++),this.connected?this.packet(n):this.sendBuffer.push(n),delete this.flags,this},h.prototype.packet=function(e){e.nsp=this.nsp,this.io.packet(e)},h.prototype.onopen=function(){if(c("transport is open - connecting"),"/"!==this.nsp)if(this.query){var e="object"==typeof this.query?u.encode(this.query):this.query;c("sending connect packet with query %s",e),this.packet({type:r.CONNECT,query:e})}else this.packet({type:r.CONNECT})},h.prototype.onclose=function(e){c("close (%s)",e),this.connected=!1,this.disconnected=!0,delete this.id,this.emit("disconnect",e)},h.prototype.onpacket=function(e){if(e.nsp===this.nsp)switch(e.type){case r.CONNECT:this.onconnect();break;case r.EVENT:case r.BINARY_EVENT:this.onevent(e);break;case r.ACK:case r.BINARY_ACK:this.onack(e);break;case r.DISCONNECT:this.ondisconnect();break;case r.ERROR:this.emit("error",e.data)}},h.prototype.onevent=function(e){var t=e.data||[];c("emitting event %j",t),null!=e.id&&(c("attaching ack callback to event"),t.push(this.ack(e.id))),this.connected?l.apply(this,t):this.receiveBuffer.push(t)},h.prototype.ack=function(e){var t=this,n=!1;return function(){if(!n){n=!0;var o=i(arguments);c("sending ack %j",o),t.packet({type:r.ACK,id:e,data:o})}}},h.prototype.onack=function(e){var t=this.acks[e.id];"function"==typeof t?(c("calling ack %s with %j",e.id,e.data),t.apply(this,e.data),delete this.acks[e.id]):c("bad ack %s",e.id)},h.prototype.onconnect=function(){this.connected=!0,this.disconnected=!1,this.emit("connect"),this.emitBuffered()},h.prototype.emitBuffered=function(){var e;for(e=0;e<this.receiveBuffer.length;e++)l.apply(this,this.receiveBuffer[e]);for(this.receiveBuffer=[],e=0;e<this.sendBuffer.length;e++)this.packet(this.sendBuffer[e]);this.sendBuffer=[]},h.prototype.ondisconnect=function(){c("server disconnect (%s)",this.nsp),this.destroy(),this.onclose("io server disconnect")},h.prototype.destroy=function(){if(this.subs){for(var e=0;e<this.subs.length;e++)this.subs[e].destroy();this.subs=null}this.io.destroy(this)},h.prototype.close=h.prototype.disconnect=function(){return this.connected&&(c("performing disconnect (%s)",this.nsp),this.packet({type:r.DISCONNECT})),this.destroy(),this.connected&&this.onclose("io client disconnect"),this},h.prototype.compress=function(e){return this.flags=this.flags||{},this.flags.compress=e,this}},function(e,t){e.exports=function(e,t,n){return e.on(t,n),{destroy:function(){e.removeListener(t,n)}}}},function(e,t){var n=[].slice;e.exports=function(e,t){if("string"==typeof t&&(t=e[t]),"function"!=typeof t)throw new Error("bind() requires a function");var r=n.call(arguments,2);return function(){return t.apply(e,r.concat(n.call(arguments)))}}},,function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getServerUrlFromLocation=function(){if(location){if("http:"===location.protocol)return"http://"+location.hostname+":9559";if("https:"===location.protocol)return"https://"+location.hostname+":5443"}return null},t.getServerUrlFromLocalhost=function(){if(location&&"https:"===location.protocol)return"https://127.0.0.1:5443";return"http://127.0.0.1:9559"},t.optionEnabled=function(e){return!("true"!==o()[e])},t.getOptions=o,t.getDeviceName=function(){var e=(new r.UAParser).getResult(),t="Unknown";e.device.vendor&&e.device.model?t="[".concat(e.device.vendor,"] ").concat(e.device.model):e.os.name&&e.browser.name&&(t="[".concat(e.os.name,"] ").concat(e.browser.name));return t},t.getClientId=function(){var e=localStorage.getItem("clientId");if(null===e){var t=(new r.UAParser).getResult(),n="Unknown";void 0!==t.device.vendor?n=t.device.vendor:void 0!==t.os.name&&(n=t.os.name),e=n+i(),localStorage.setItem("clientId",e)}return e},t.isPromise=function(e){return!!e&&"function"==typeof e.then},t.getUniqueId=i,t.getOffloadId=function(e){return e+"_"+e.toLowerCase().split("").reverse().join("")};var r=n(31);function o(){var e={},t=["debug","info"],n=function(){var e=window.location.search.substr(1).split("&");if(""===e)return{};for(var t={},n=0;n<e.length;n++){var r=e[n].split("=",2);1===r.length?t[r[0]]="":t[r[0]]=decodeURIComponent(r[1].replace(/\+/g," "))}return t}();for(var r in n)-1!==t.indexOf(r)&&(e[r]=n[r]);return e}function i(){return"_"+Math.random().toString(36).substr(2,9)}},function(e,t,n){(function(r){t.formatArgs=function(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const n="color: "+this.color;t.splice(1,0,n,"color: inherit");let r=0,o=0;t[0].replace(/%[a-zA-Z%]/g,e=>{"%%"!==e&&(r++,"%c"===e&&(o=r))}),t.splice(o,0,n)},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}},t.load=function(){let e;try{e=t.storage.getItem("debug")}catch(e){}!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG);return e},t.useColors=function(){if("undefined"!=typeof window&&window.process&&("renderer"===window.process.type||window.process.__nwjs))return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage=function(){try{return localStorage}catch(e){}}(),t.destroy=(()=>{let e=!1;return()=>{e||(e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.log=console.debug||console.log||(()=>{}),e.exports=n(29)(t);const{formatters:o}=e.exports;o.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}}).call(this,n(3))},function(e,t,n){e.exports=function(e){function t(e){let n,o=null;function i(...e){if(!i.enabled)return;const r=i,o=Number(new Date),s=o-(n||o);r.diff=s,r.prev=n,r.curr=o,n=o,e[0]=t.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let a=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,(n,o)=>{if("%%"===n)return"%";a++;const i=t.formatters[o];if("function"==typeof i){const t=e[a];n=i.call(r,t),e.splice(a,1),a--}return n}),t.formatArgs.call(r,e);(r.log||t.log).apply(r,e)}return i.namespace=e,i.useColors=t.useColors(),i.color=t.selectColor(e),i.extend=r,i.destroy=t.destroy,Object.defineProperty(i,"enabled",{enumerable:!0,configurable:!1,get:()=>null===o?t.enabled(e):o,set:e=>{o=e}}),"function"==typeof t.init&&t.init(i),i}function r(e,n){const r=t(this.namespace+(void 0===n?":":n)+e);return r.log=this.log,r}function o(e){return e.toString().substring(2,e.toString().length-2).replace(/\.\*\?$/,"*")}return t.debug=t,t.default=t,t.coerce=function(e){if(e instanceof Error)return e.stack||e.message;return e},t.disable=function(){const e=[...t.names.map(o),...t.skips.map(o).map(e=>"-"+e)].join(",");return t.enable(""),e},t.enable=function(e){let n;t.save(e),t.names=[],t.skips=[];const r=("string"==typeof e?e:"").split(/[\s,]+/),o=r.length;for(n=0;n<o;n++)r[n]&&("-"===(e=r[n].replace(/\*/g,".*?"))[0]?t.skips.push(new RegExp("^"+e.substr(1)+"$")):t.names.push(new RegExp("^"+e+"$")))},t.enabled=function(e){if("*"===e[e.length-1])return!0;let n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1},t.humanize=n(30),t.destroy=function(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")},Object.keys(e).forEach(n=>{t[n]=e[n]}),t.names=[],t.skips=[],t.formatters={},t.selectColor=function(e){let n=0;for(let t=0;t<e.length;t++)n=(n<<5)-n+e.charCodeAt(t),n|=0;return t.colors[Math.abs(n)%t.colors.length]},t.enable(t.load()),t}},function(e,t){var n=1e3,r=6e4,o=60*r,i=24*o;function s(e,t,n,r){var o=t>=1.5*n;return Math.round(e/n)+" "+r+(o?"s":"")}e.exports=function(e,t){t=t||{};var a=typeof e;if("string"===a&&e.length>0)return function(e){if((e=String(e)).length>100)return;var t=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(!t)return;var s=parseFloat(t[1]);switch((t[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*s;case"weeks":case"week":case"w":return 6048e5*s;case"days":case"day":case"d":return s*i;case"hours":case"hour":case"hrs":case"hr":case"h":return s*o;case"minutes":case"minute":case"mins":case"min":case"m":return s*r;case"seconds":case"second":case"secs":case"sec":case"s":return s*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return s;default:return}}(e);if("number"===a&&isFinite(e))return t.long?function(e){var t=Math.abs(e);if(t>=i)return s(e,t,i,"day");if(t>=o)return s(e,t,o,"hour");if(t>=r)return s(e,t,r,"minute");if(t>=n)return s(e,t,n,"second");return e+" ms"}(e):function(e){var t=Math.abs(e);if(t>=i)return Math.round(e/i)+"d";if(t>=o)return Math.round(e/o)+"h";if(t>=r)return Math.round(e/r)+"m";if(t>=n)return Math.round(e/n)+"s";return e+"ms"}(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},function(e,t,n){var r;
+/*!
+ * UAParser.js v0.7.21
+ * Lightweight JavaScript-based User-Agent string parser
+ * https://github.com/faisalman/ua-parser-js
+ *
+ * Copyright Â© 2012-2019 Faisal Salman <f@faisalman.com>
+ * Licensed under MIT License
+ */!function(o,i){"use strict";var s="model",a="name",c="type",u="vendor",f="version",l="mobile",h="tablet",p="smarttv",d={extend:function(e,t){var n={};for(var r in e)t[r]&&t[r].length%2==0?n[r]=t[r].concat(e[r]):n[r]=e[r];return n},has:function(e,t){return"string"==typeof e&&-1!==t.toLowerCase().indexOf(e.toLowerCase())},lowerize:function(e){return e.toLowerCase()},major:function(e){return"string"==typeof e?e.replace(/[^\d\.]/g,"").split(".")[0]:void 0},trim:function(e){return e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}},y={rgx:function(e,t){for(var n,r,o,i,s,a,c=0;c<t.length&&!s;){var u=t[c],f=t[c+1];for(n=r=0;n<u.length&&!s;)if(s=u[n++].exec(e))for(o=0;o<f.length;o++)a=s[++r],"object"==typeof(i=f[o])&&i.length>0?2==i.length?"function"==typeof i[1]?this[i[0]]=i[1].call(this,a):this[i[0]]=i[1]:3==i.length?"function"!=typeof i[1]||i[1].exec&&i[1].test?this[i[0]]=a?a.replace(i[1],i[2]):void 0:this[i[0]]=a?i[1].call(this,a,i[2]):void 0:4==i.length&&(this[i[0]]=a?i[3].call(this,a.replace(i[1],i[2])):void 0):this[i]=a||void 0;c+=2}},str:function(e,t){for(var n in t)if("object"==typeof t[n]&&t[n].length>0){for(var r=0;r<t[n].length;r++)if(d.has(t[n][r],e))return"?"===n?void 0:n}else if(d.has(t[n],e))return"?"===n?void 0:n;return e}},g={browser:{oldsafari:{version:{"1.0":"/8",1.2:"/1",1.3:"/3","2.0":"/412","2.0.2":"/416","2.0.3":"/417","2.0.4":"/419","?":"/"}}},device:{amazon:{model:{"Fire Phone":["SD","KF"]}},sprint:{model:{"Evo Shift 4G":"7373KT"},vendor:{HTC:"APA",Sprint:"Sprint"}}},os:{windows:{version:{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"}}}},m={browser:[[/(opera\smini)\/([\w\.-]+)/i,/(opera\s[mobiletab]+).+version\/([\w\.-]+)/i,/(opera).+version\/([\w\.]+)/i,/(opera)[\/\s]+([\w\.]+)/i],[a,f],[/(opios)[\/\s]+([\w\.]+)/i],[[a,"Opera Mini"],f],[/\s(opr)\/([\w\.]+)/i],[[a,"Opera"],f],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer)[\/\s]?([\w\.]*)/i,/(avant\s|iemobile|slim)(?:browser)?[\/\s]?([\w\.]*)/i,/(bidubrowser|baidubrowser)[\/\s]?([\w\.]+)/i,/(?:ms|\()(ie)\s([\w\.]+)/i,/(rekonq)\/([\w\.]*)/i,/(chromium|flock|rockmelt|midori|epiphany|silk|skyfire|ovibrowser|bolt|iron|vivaldi|iridium|phantomjs|bowser|quark|qupzilla|falkon)\/([\w\.-]+)/i],[a,f],[/(konqueror)\/([\w\.]+)/i],[[a,"Konqueror"],f],[/(trident).+rv[:\s]([\w\.]+).+like\sgecko/i],[[a,"IE"],f],[/(edge|edgios|edga|edg)\/((\d+)?[\w\.]+)/i],[[a,"Edge"],f],[/(yabrowser)\/([\w\.]+)/i],[[a,"Yandex"],f],[/(Avast)\/([\w\.]+)/i],[[a,"Avast Secure Browser"],f],[/(AVG)\/([\w\.]+)/i],[[a,"AVG Secure Browser"],f],[/(puffin)\/([\w\.]+)/i],[[a,"Puffin"],f],[/(focus)\/([\w\.]+)/i],[[a,"Firefox Focus"],f],[/(opt)\/([\w\.]+)/i],[[a,"Opera Touch"],f],[/((?:[\s\/])uc?\s?browser|(?:juc.+)ucweb)[\/\s]?([\w\.]+)/i],[[a,"UCBrowser"],f],[/(comodo_dragon)\/([\w\.]+)/i],[[a,/_/g," "],f],[/(windowswechat qbcore)\/([\w\.]+)/i],[[a,"WeChat(Win) Desktop"],f],[/(micromessenger)\/([\w\.]+)/i],[[a,"WeChat"],f],[/(brave)\/([\w\.]+)/i],[[a,"Brave"],f],[/(qqbrowserlite)\/([\w\.]+)/i],[a,f],[/(QQ)\/([\d\.]+)/i],[a,f],[/m?(qqbrowser)[\/\s]?([\w\.]+)/i],[a,f],[/(baiduboxapp)[\/\s]?([\w\.]+)/i],[a,f],[/(2345Explorer)[\/\s]?([\w\.]+)/i],[a,f],[/(MetaSr)[\/\s]?([\w\.]+)/i],[a],[/(LBBROWSER)/i],[a],[/xiaomi\/miuibrowser\/([\w\.]+)/i],[f,[a,"MIUI Browser"]],[/;fbav\/([\w\.]+);/i],[f,[a,"Facebook"]],[/safari\s(line)\/([\w\.]+)/i,/android.+(line)\/([\w\.]+)\/iab/i],[a,f],[/headlesschrome(?:\/([\w\.]+)|\s)/i],[f,[a,"Chrome Headless"]],[/\swv\).+(chrome)\/([\w\.]+)/i],[[a,/(.+)/,"$1 WebView"],f],[/((?:oculus|samsung)browser)\/([\w\.]+)/i],[[a,/(.+(?:g|us))(.+)/,"$1 $2"],f],[/android.+version\/([\w\.]+)\s+(?:mobile\s?safari|safari)*/i],[f,[a,"Android Browser"]],[/(sailfishbrowser)\/([\w\.]+)/i],[[a,"Sailfish Browser"],f],[/(chrome|omniweb|arora|[tizenoka]{5}\s?browser)\/v?([\w\.]+)/i],[a,f],[/(dolfin)\/([\w\.]+)/i],[[a,"Dolphin"],f],[/(qihu|qhbrowser|qihoobrowser|360browser)/i],[[a,"360 Browser"]],[/((?:android.+)crmo|crios)\/([\w\.]+)/i],[[a,"Chrome"],f],[/(coast)\/([\w\.]+)/i],[[a,"Opera Coast"],f],[/fxios\/([\w\.-]+)/i],[f,[a,"Firefox"]],[/version\/([\w\.]+).+?mobile\/\w+\s(safari)/i],[f,[a,"Mobile Safari"]],[/version\/([\w\.]+).+?(mobile\s?safari|safari)/i],[f,a],[/webkit.+?(gsa)\/([\w\.]+).+?(mobile\s?safari|safari)(\/[\w\.]+)/i],[[a,"GSA"],f],[/webkit.+?(mobile\s?safari|safari)(\/[\w\.]+)/i],[a,[f,y.str,g.browser.oldsafari.version]],[/(webkit|khtml)\/([\w\.]+)/i],[a,f],[/(navigator|netscape)\/([\w\.-]+)/i],[[a,"Netscape"],f],[/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo\sbrowser|minimo|conkeror)[\/\s]?([\w\.\+]+)/i,/(firefox|seamonkey|k-meleon|icecat|iceape|firebird|phoenix|palemoon|basilisk|waterfox)\/([\w\.-]+)$/i,/(mozilla)\/([\w\.]+).+rv\:.+gecko\/\d+/i,/(polaris|lynx|dillo|icab|doris|amaya|w3m|netsurf|sleipnir)[\/\s]?([\w\.]+)/i,/(links)\s\(([\w\.]+)/i,/(gobrowser)\/?([\w\.]*)/i,/(ice\s?browser)\/v?([\w\._]+)/i,/(mosaic)[\/\s]([\w\.]+)/i],[a,f]],cpu:[[/(?:(amd|x(?:(?:86|64)[_-])?|wow|win)64)[;\)]/i],[["architecture","amd64"]],[/(ia32(?=;))/i],[["architecture",d.lowerize]],[/((?:i[346]|x)86)[;\)]/i],[["architecture","ia32"]],[/windows\s(ce|mobile);\sppc;/i],[["architecture","arm"]],[/((?:ppc|powerpc)(?:64)?)(?:\smac|;|\))/i],[["architecture",/ower/,"",d.lowerize]],[/(sun4\w)[;\)]/i],[["architecture","sparc"]],[/((?:avr32|ia64(?=;))|68k(?=\))|arm(?:64|(?=v\d+[;l]))|(?=atmel\s)avr|(?:irix|mips|sparc)(?:64)?(?=;)|pa-risc)/i],[["architecture",d.lowerize]]],device:[[/\((ipad|playbook);[\w\s\),;-]+(rim|apple)/i],[s,u,[c,h]],[/applecoremedia\/[\w\.]+ \((ipad)/],[s,[u,"Apple"],[c,h]],[/(apple\s{0,1}tv)/i],[[s,"Apple TV"],[u,"Apple"],[c,p]],[/(archos)\s(gamepad2?)/i,/(hp).+(touchpad)/i,/(hp).+(tablet)/i,/(kindle)\/([\w\.]+)/i,/\s(nook)[\w\s]+build\/(\w+)/i,/(dell)\s(strea[kpr\s\d]*[\dko])/i],[u,s,[c,h]],[/(kf[A-z]+)\sbuild\/.+silk\//i],[s,[u,"Amazon"],[c,h]],[/(sd|kf)[0349hijorstuw]+\sbuild\/.+silk\//i],[[s,y.str,g.device.amazon.model],[u,"Amazon"],[c,l]],[/android.+aft([bms])\sbuild/i],[s,[u,"Amazon"],[c,p]],[/\((ip[honed|\s\w*]+);.+(apple)/i],[s,u,[c,l]],[/\((ip[honed|\s\w*]+);/i],[s,[u,"Apple"],[c,l]],[/(blackberry)[\s-]?(\w+)/i,/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus|dell|meizu|motorola|polytron)[\s_-]?([\w-]*)/i,/(hp)\s([\w\s]+\w)/i,/(asus)-?(\w+)/i],[u,s,[c,l]],[/\(bb10;\s(\w+)/i],[s,[u,"BlackBerry"],[c,l]],[/android.+(transfo[prime\s]{4,10}\s\w+|eeepc|slider\s\w+|nexus 7|padfone|p00c)/i],[s,[u,"Asus"],[c,h]],[/(sony)\s(tablet\s[ps])\sbuild\//i,/(sony)?(?:sgp.+)\sbuild\//i],[[u,"Sony"],[s,"Xperia Tablet"],[c,h]],[/android.+\s([c-g]\d{4}|so[-l]\w+)(?=\sbuild\/|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[s,[u,"Sony"],[c,l]],[/\s(ouya)\s/i,/(nintendo)\s([wids3u]+)/i],[u,s,[c,"console"]],[/android.+;\s(shield)\sbuild/i],[s,[u,"Nvidia"],[c,"console"]],[/(playstation\s[34portablevi]+)/i],[s,[u,"Sony"],[c,"console"]],[/(sprint\s(\w+))/i],[[u,y.str,g.device.sprint.vendor],[s,y.str,g.device.sprint.model],[c,l]],[/(htc)[;_\s-]+([\w\s]+(?=\)|\sbuild)|\w+)/i,/(zte)-(\w*)/i,/(alcatel|geeksphone|nexian|panasonic|(?=;\s)sony)[_\s-]?([\w-]*)/i],[u,[s,/_/g," "],[c,l]],[/(nexus\s9)/i],[s,[u,"HTC"],[c,h]],[/d\/huawei([\w\s-]+)[;\)]/i,/(nexus\s6p|vog-l29|ane-lx1|eml-l29)/i],[s,[u,"Huawei"],[c,l]],[/android.+(bah2?-a?[lw]\d{2})/i],[s,[u,"Huawei"],[c,h]],[/(microsoft);\s(lumia[\s\w]+)/i],[u,s,[c,l]],[/[\s\(;](xbox(?:\sone)?)[\s\);]/i],[s,[u,"Microsoft"],[c,"console"]],[/(kin\.[onetw]{3})/i],[[s,/\./g," "],[u,"Microsoft"],[c,l]],[/\s(milestone|droid(?:[2-4x]|\s(?:bionic|x2|pro|razr))?:?(\s4g)?)[\w\s]+build\//i,/mot[\s-]?(\w*)/i,/(XT\d{3,4}) build\//i,/(nexus\s6)/i],[s,[u,"Motorola"],[c,l]],[/android.+\s(mz60\d|xoom[\s2]{0,2})\sbuild\//i],[s,[u,"Motorola"],[c,h]],[/hbbtv\/\d+\.\d+\.\d+\s+\([\w\s]*;\s*(\w[^;]*);([^;]*)/i],[[u,d.trim],[s,d.trim],[c,p]],[/hbbtv.+maple;(\d+)/i],[[s,/^/,"SmartTV"],[u,"Samsung"],[c,p]],[/\(dtv[\);].+(aquos)/i],[s,[u,"Sharp"],[c,p]],[/android.+((sch-i[89]0\d|shw-m380s|gt-p\d{4}|gt-n\d+|sgh-t8[56]9|nexus 10))/i,/((SM-T\w+))/i],[[u,"Samsung"],s,[c,h]],[/smart-tv.+(samsung)/i],[u,[c,p],s],[/((s[cgp]h-\w+|gt-\w+|galaxy\snexus|sm-\w[\w\d]+))/i,/(sam[sung]*)[\s-]*(\w+-?[\w-]*)/i,/sec-((sgh\w+))/i],[[u,"Samsung"],s,[c,l]],[/sie-(\w*)/i],[s,[u,"Siemens"],[c,l]],[/(maemo|nokia).*(n900|lumia\s\d+)/i,/(nokia)[\s_-]?([\w-]*)/i],[[u,"Nokia"],s,[c,l]],[/android[x\d\.\s;]+\s([ab][1-7]\-?[0178a]\d\d?)/i],[s,[u,"Acer"],[c,h]],[/android.+([vl]k\-?\d{3})\s+build/i],[s,[u,"LG"],[c,h]],[/android\s3\.[\s\w;-]{10}(lg?)-([06cv9]{3,4})/i],[[u,"LG"],s,[c,h]],[/(lg) netcast\.tv/i],[u,s,[c,p]],[/(nexus\s[45])/i,/lg[e;\s\/-]+(\w*)/i,/android.+lg(\-?[\d\w]+)\s+build/i],[s,[u,"LG"],[c,l]],[/(lenovo)\s?(s(?:5000|6000)(?:[\w-]+)|tab(?:[\s\w]+))/i],[u,s,[c,h]],[/android.+(ideatab[a-z0-9\-\s]+)/i],[s,[u,"Lenovo"],[c,h]],[/(lenovo)[_\s-]?([\w-]+)/i],[u,s,[c,l]],[/linux;.+((jolla));/i],[u,s,[c,l]],[/((pebble))app\/[\d\.]+\s/i],[u,s,[c,"wearable"]],[/android.+;\s(oppo)\s?([\w\s]+)\sbuild/i],[u,s,[c,l]],[/crkey/i],[[s,"Chromecast"],[u,"Google"],[c,p]],[/android.+;\s(glass)\s\d/i],[s,[u,"Google"],[c,"wearable"]],[/android.+;\s(pixel c)[\s)]/i],[s,[u,"Google"],[c,h]],[/android.+;\s(pixel( [23])?( xl)?)[\s)]/i],[s,[u,"Google"],[c,l]],[/android.+;\s(\w+)\s+build\/hm\1/i,/android.+(hm[\s\-_]*note?[\s_]*(?:\d\w)?)\s+build/i,/android.+(mi[\s\-_]*(?:a\d|one|one[\s_]plus|note lte)?[\s_]*(?:\d?\w?)[\s_]*(?:plus)?)\s+build/i,/android.+(redmi[\s\-_]*(?:note)?(?:[\s_]*[\w\s]+))\s+build/i],[[s,/_/g," "],[u,"Xiaomi"],[c,l]],[/android.+(mi[\s\-_]*(?:pad)(?:[\s_]*[\w\s]+))\s+build/i],[[s,/_/g," "],[u,"Xiaomi"],[c,h]],[/android.+;\s(m[1-5]\snote)\sbuild/i],[s,[u,"Meizu"],[c,l]],[/(mz)-([\w-]{2,})/i],[[u,"Meizu"],s,[c,l]],[/android.+a000(1)\s+build/i,/android.+oneplus\s(a\d{4})[\s)]/i],[s,[u,"OnePlus"],[c,l]],[/android.+[;\/]\s*(RCT[\d\w]+)\s+build/i],[s,[u,"RCA"],[c,h]],[/android.+[;\/\s]+(Venue[\d\s]{2,7})\s+build/i],[s,[u,"Dell"],[c,h]],[/android.+[;\/]\s*(Q[T|M][\d\w]+)\s+build/i],[s,[u,"Verizon"],[c,h]],[/android.+[;\/]\s+(Barnes[&\s]+Noble\s+|BN[RT])(V?.*)\s+build/i],[[u,"Barnes & Noble"],s,[c,h]],[/android.+[;\/]\s+(TM\d{3}.*\b)\s+build/i],[s,[u,"NuVision"],[c,h]],[/android.+;\s(k88)\sbuild/i],[s,[u,"ZTE"],[c,h]],[/android.+[;\/]\s*(gen\d{3})\s+build.*49h/i],[s,[u,"Swiss"],[c,l]],[/android.+[;\/]\s*(zur\d{3})\s+build/i],[s,[u,"Swiss"],[c,h]],[/android.+[;\/]\s*((Zeki)?TB.*\b)\s+build/i],[s,[u,"Zeki"],[c,h]],[/(android).+[;\/]\s+([YR]\d{2})\s+build/i,/android.+[;\/]\s+(Dragon[\-\s]+Touch\s+|DT)(\w{5})\sbuild/i],[[u,"Dragon Touch"],s,[c,h]],[/android.+[;\/]\s*(NS-?\w{0,9})\sbuild/i],[s,[u,"Insignia"],[c,h]],[/android.+[;\/]\s*((NX|Next)-?\w{0,9})\s+build/i],[s,[u,"NextBook"],[c,h]],[/android.+[;\/]\s*(Xtreme\_)?(V(1[045]|2[015]|30|40|60|7[05]|90))\s+build/i],[[u,"Voice"],s,[c,l]],[/android.+[;\/]\s*(LVTEL\-)?(V1[12])\s+build/i],[[u,"LvTel"],s,[c,l]],[/android.+;\s(PH-1)\s/i],[s,[u,"Essential"],[c,l]],[/android.+[;\/]\s*(V(100MD|700NA|7011|917G).*\b)\s+build/i],[s,[u,"Envizen"],[c,h]],[/android.+[;\/]\s*(Le[\s\-]+Pan)[\s\-]+(\w{1,9})\s+build/i],[u,s,[c,h]],[/android.+[;\/]\s*(Trio[\s\-]*.*)\s+build/i],[s,[u,"MachSpeed"],[c,h]],[/android.+[;\/]\s*(Trinity)[\-\s]*(T\d{3})\s+build/i],[u,s,[c,h]],[/android.+[;\/]\s*TU_(1491)\s+build/i],[s,[u,"Rotor"],[c,h]],[/android.+(KS(.+))\s+build/i],[s,[u,"Amazon"],[c,h]],[/android.+(Gigaset)[\s\-]+(Q\w{1,9})\s+build/i],[u,s,[c,h]],[/\s(tablet|tab)[;\/]/i,/\s(mobile)(?:[;\/]|\ssafari)/i],[[c,d.lowerize],u,s],[/[\s\/\(](smart-?tv)[;\)]/i],[[c,p]],[/(android[\w\.\s\-]{0,9});.+build/i],[s,[u,"Generic"]]],engine:[[/windows.+\sedge\/([\w\.]+)/i],[f,[a,"EdgeHTML"]],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[f,[a,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna)\/([\w\.]+)/i,/(khtml|tasman|links)[\/\s]\(?([\w\.]+)/i,/(icab)[\/\s]([23]\.[\d\.]+)/i],[a,f],[/rv\:([\w\.]{1,9}).+(gecko)/i],[f,a]],os:[[/microsoft\s(windows)\s(vista|xp)/i],[a,f],[/(windows)\snt\s6\.2;\s(arm)/i,/(windows\sphone(?:\sos)*)[\s\/]?([\d\.\s\w]*)/i,/(windows\smobile|windows)[\s\/]?([ntce\d\.\s]+\w)/i],[a,[f,y.str,g.os.windows.version]],[/(win(?=3|9|n)|win\s9x\s)([nt\d\.]+)/i],[[a,"Windows"],[f,y.str,g.os.windows.version]],[/\((bb)(10);/i],[[a,"BlackBerry"],f],[/(blackberry)\w*\/?([\w\.]*)/i,/(tizen|kaios)[\/\s]([\w\.]+)/i,/(android|webos|palm\sos|qnx|bada|rim\stablet\sos|meego|sailfish|contiki)[\/\s-]?([\w\.]*)/i],[a,f],[/(symbian\s?os|symbos|s60(?=;))[\/\s-]?([\w\.]*)/i],[[a,"Symbian"],f],[/\((series40);/i],[a],[/mozilla.+\(mobile;.+gecko.+firefox/i],[[a,"Firefox OS"],f],[/(nintendo|playstation)\s([wids34portablevu]+)/i,/(mint)[\/\s\(]?(\w*)/i,/(mageia|vectorlinux)[;\s]/i,/(joli|[kxln]?ubuntu|debian|suse|opensuse|gentoo|(?=\s)arch|slackware|fedora|mandriva|centos|pclinuxos|redhat|zenwalk|linpus)[\/\s-]?(?!chrom)([\w\.-]*)/i,/(hurd|linux)\s?([\w\.]*)/i,/(gnu)\s?([\w\.]*)/i],[a,f],[/(cros)\s[\w]+\s([\w\.]+\w)/i],[[a,"Chromium OS"],f],[/(sunos)\s?([\w\.\d]*)/i],[[a,"Solaris"],f],[/\s([frentopc-]{0,4}bsd|dragonfly)\s?([\w\.]*)/i],[a,f],[/(haiku)\s(\w+)/i],[a,f],[/cfnetwork\/.+darwin/i,/ip[honead]{2,4}(?:.*os\s([\w]+)\slike\smac|;\sopera)/i],[[f,/_/g,"."],[a,"iOS"]],[/(mac\sos\sx)\s?([\w\s\.]*)/i,/(macintosh|mac(?=_powerpc)\s)/i],[[a,"Mac OS"],[f,/_/g,"."]],[/((?:open)?solaris)[\/\s-]?([\w\.]*)/i,/(aix)\s((\d)(?=\.|\)|\s)[\w\.])*/i,/(plan\s9|minix|beos|os\/2|amigaos|morphos|risc\sos|openvms|fuchsia)/i,/(unix)\s?([\w\.]*)/i],[a,f]]},v=function(e,t){if("object"==typeof e&&(t=e,e=void 0),!(this instanceof v))return new v(e,t).getResult();var n=e||(o&&o.navigator&&o.navigator.userAgent?o.navigator.userAgent:""),r=t?d.extend(m,t):m;return this.getBrowser=function(){var e={name:void 0,version:void 0};return y.rgx.call(e,n,r.browser),e.major=d.major(e.version),e},this.getCPU=function(){var e={architecture:void 0};return y.rgx.call(e,n,r.cpu),e},this.getDevice=function(){var e={vendor:void 0,model:void 0,type:void 0};return y.rgx.call(e,n,r.device),e},this.getEngine=function(){var e={name:void 0,version:void 0};return y.rgx.call(e,n,r.engine),e},this.getOS=function(){var e={name:void 0,version:void 0};return y.rgx.call(e,n,r.os),e},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 n},this.setUA=function(e){return n=e,this},this};v.VERSION="0.7.21",v.BROWSER={NAME:a,MAJOR:"major",VERSION:f},v.CPU={ARCHITECTURE:"architecture"},v.DEVICE={MODEL:s,VENDOR:u,TYPE:c,CONSOLE:"console",MOBILE:l,SMARTTV:p,TABLET:h,WEARABLE:"wearable",EMBEDDED:"embedded"},v.ENGINE={NAME:a,VERSION:f},v.OS={NAME:a,VERSION:f},void 0!==t?(void 0!==e&&e.exports&&(t=e.exports=v),t.UAParser=v):void 0===(r=function(){return v}.call(t,n,t,e))||(e.exports=r);var b=o&&(o.jQuery||o.Zepto);if(b&&!b.ua){var w=new v;b.ua=w.getResult(),b.ua.get=function(){return w.getUA()},b.ua.set=function(e){w.setUA(e);var t=w.getResult();for(var n in t)b.ua[n]=t[n]}}}("object"==typeof window?window:this)},function(e,t,n){var r=n(33),o=n(8),i=n(18),s=n(4)("socket.io-client");e.exports=t=c;var a=t.managers={};function c(e,t){"object"==typeof e&&(t=e,e=void 0),t=t||{};var n,o=r(e),c=o.source,u=o.id,f=o.path,l=a[u]&&f in a[u].nsps;return t.forceNew||t["force new connection"]||!1===t.multiplex||l?(s("ignoring socket cache for %s",c),n=i(c,t)):(a[u]||(s("new io instance for %s",c),a[u]=i(c,t)),n=a[u]),o.query&&!t.query&&(t.query=o.query),n.socket(o.path,t)}t.protocol=o.protocol,t.connect=c,t.Manager=n(18),t.Socket=n(23)},function(e,t,n){(function(t){var r=n(13),o=n(4)("socket.io-client:url");e.exports=function(e,n){var i=e;n=n||t.location,null==e&&(e=n.protocol+"//"+n.host);"string"==typeof e&&("/"===e.charAt(0)&&(e="/"===e.charAt(1)?n.protocol+e:n.host+e),/^(https?|wss?):\/\//.test(e)||(o("protocol-less url %s",e),e=void 0!==n?n.protocol+"//"+e:"https://"+e),o("parse %s",e),i=r(e));i.port||(/^(http|ws)$/.test(i.protocol)?i.port="80":/^(http|ws)s$/.test(i.protocol)&&(i.port="443"));i.path=i.path||"/";var s=-1!==i.host.indexOf(":")?"["+i.host+"]":i.host;return i.id=i.protocol+"://"+s+":"+i.port,i.href=i.protocol+"://"+s+(n&&n.port===i.port?"":":"+i.port),i}}).call(this,n(0))},function(e,t,n){var r;function o(e){function n(){if(n.enabled){var e=n,o=+new Date,i=o-(r||o);e.diff=i,e.prev=r,e.curr=o,r=o;for(var s=new Array(arguments.length),a=0;a<s.length;a++)s[a]=arguments[a];s[0]=t.coerce(s[0]),"string"!=typeof s[0]&&s.unshift("%O");var c=0;s[0]=s[0].replace(/%([a-zA-Z%])/g,(function(n,r){if("%%"===n)return n;c++;var o=t.formatters[r];if("function"==typeof o){var i=s[c];n=o.call(e,i),s.splice(c,1),c--}return n})),t.formatArgs.call(e,s);var u=n.log||t.log||console.log.bind(console);u.apply(e,s)}}return n.namespace=e,n.enabled=t.enabled(e),n.useColors=t.useColors(),n.color=function(e){var n,r=0;for(n in e)r=(r<<5)-r+e.charCodeAt(n),r|=0;return t.colors[Math.abs(r)%t.colors.length]}(e),"function"==typeof t.init&&t.init(n),n}(t=e.exports=o.debug=o.default=o).coerce=function(e){return e instanceof Error?e.stack||e.message:e},t.disable=function(){t.enable("")},t.enable=function(e){t.save(e),t.names=[],t.skips=[];for(var n=("string"==typeof e?e:"").split(/[\s,]+/),r=n.length,o=0;o<r;o++)n[o]&&("-"===(e=n[o].replace(/\*/g,".*?"))[0]?t.skips.push(new RegExp("^"+e.substr(1)+"$")):t.names.push(new RegExp("^"+e+"$")))},t.enabled=function(e){var n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1},t.humanize=n(14),t.names=[],t.skips=[],t.formatters={}},function(e,t,n){(function(r){function o(){var e;try{e=t.storage.debug}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}(t=e.exports=n(36)).log=function(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)},t.formatArgs=function(e){var n=this.useColors;if(e[0]=(n?"%c":"")+this.namespace+(n?" %c":" ")+e[0]+(n?"%c ":" ")+"+"+t.humanize(this.diff),!n)return;var r="color: "+this.color;e.splice(1,0,r,"color: inherit");var o=0,i=0;e[0].replace(/%[a-zA-Z%]/g,(function(e){"%%"!==e&&(o++,"%c"===e&&(i=o))})),e.splice(i,0,r)},t.save=function(e){try{null==e?t.storage.removeItem("debug"):t.storage.debug=e}catch(e){}},t.load=o,t.useColors=function(){if("undefined"!=typeof window&&window.process&&"renderer"===window.process.type)return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:function(){try{return window.localStorage}catch(e){}}(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.formatters.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}},t.enable(o())}).call(this,n(3))},function(e,t,n){function r(e){var n;function r(){if(r.enabled){var e=r,o=+new Date,i=o-(n||o);e.diff=i,e.prev=n,e.curr=o,n=o;for(var s=new Array(arguments.length),a=0;a<s.length;a++)s[a]=arguments[a];s[0]=t.coerce(s[0]),"string"!=typeof s[0]&&s.unshift("%O");var c=0;s[0]=s[0].replace(/%([a-zA-Z%])/g,(function(n,r){if("%%"===n)return n;c++;var o=t.formatters[r];if("function"==typeof o){var i=s[c];n=o.call(e,i),s.splice(c,1),c--}return n})),t.formatArgs.call(e,s);var u=r.log||t.log||console.log.bind(console);u.apply(e,s)}}return r.namespace=e,r.enabled=t.enabled(e),r.useColors=t.useColors(),r.color=function(e){var n,r=0;for(n in e)r=(r<<5)-r+e.charCodeAt(n),r|=0;return t.colors[Math.abs(r)%t.colors.length]}(e),r.destroy=o,"function"==typeof t.init&&t.init(r),t.instances.push(r),r}function o(){var e=t.instances.indexOf(this);return-1!==e&&(t.instances.splice(e,1),!0)}(t=e.exports=r.debug=r.default=r).coerce=function(e){return e instanceof Error?e.stack||e.message:e},t.disable=function(){t.enable("")},t.enable=function(e){var n;t.save(e),t.names=[],t.skips=[];var r=("string"==typeof e?e:"").split(/[\s,]+/),o=r.length;for(n=0;n<o;n++)r[n]&&("-"===(e=r[n].replace(/\*/g,".*?"))[0]?t.skips.push(new RegExp("^"+e.substr(1)+"$")):t.names.push(new RegExp("^"+e+"$")));for(n=0;n<t.instances.length;n++){var i=t.instances[n];i.enabled=t.enabled(i.namespace)}},t.enabled=function(e){if("*"===e[e.length-1])return!0;var n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1},t.humanize=n(14),t.instances=[],t.names=[],t.skips=[],t.formatters={}},function(e,t,n){"use strict";(function(e){
 /*!
  * The buffer module from node.js, for the browser.
  *
  * @author   Feross Aboukhadijeh <http://feross.org>
  * @license  MIT
  */
-var r=n(40),o=n(41),i=n(42);function s(){return c.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function a(e,t){if(s()<t)throw new RangeError("Invalid typed array length");return c.TYPED_ARRAY_SUPPORT?(e=new Uint8Array(t)).__proto__=c.prototype:(null===e&&(e=new c(t)),e.length=t),e}function c(e,t,n){if(!(c.TYPED_ARRAY_SUPPORT||this instanceof c))return new c(e,t,n);if("number"==typeof e){if("string"==typeof t)throw new Error("If encoding is specified then the first argument must be a string");return l(this,e)}return u(this,e,t,n)}function u(e,t,n,r){if("number"==typeof t)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&t instanceof ArrayBuffer?function(e,t,n,r){if(t.byteLength,n<0||t.byteLength<n)throw new RangeError("'offset' is out of bounds");if(t.byteLength<n+(r||0))throw new RangeError("'length' is out of bounds");t=void 0===n&&void 0===r?new Uint8Array(t):void 0===r?new Uint8Array(t,n):new Uint8Array(t,n,r);c.TYPED_ARRAY_SUPPORT?(e=t).__proto__=c.prototype:e=h(e,t);return e}(e,t,n,r):"string"==typeof t?function(e,t,n){"string"==typeof n&&""!==n||(n="utf8");if(!c.isEncoding(n))throw new TypeError('"encoding" must be a valid string encoding');var r=0|d(t,n),o=(e=a(e,r)).write(t,n);o!==r&&(e=e.slice(0,o));return e}(e,t,n):function(e,t){if(c.isBuffer(t)){var n=0|p(t.length);return 0===(e=a(e,n)).length||t.copy(e,0,0,n),e}if(t){if("undefined"!=typeof ArrayBuffer&&t.buffer instanceof ArrayBuffer||"length"in t)return"number"!=typeof t.length||(r=t.length)!=r?a(e,0):h(e,t);if("Buffer"===t.type&&i(t.data))return h(e,t.data)}var r;throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(e,t)}function f(e){if("number"!=typeof e)throw new TypeError('"size" argument must be a number');if(e<0)throw new RangeError('"size" argument must not be negative')}function l(e,t){if(f(t),e=a(e,t<0?0:0|p(t)),!c.TYPED_ARRAY_SUPPORT)for(var n=0;n<t;++n)e[n]=0;return e}function h(e,t){var n=t.length<0?0:0|p(t.length);e=a(e,n);for(var r=0;r<n;r+=1)e[r]=255&t[r];return e}function p(e){if(e>=s())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s().toString(16)+" bytes");return 0|e}function d(e,t){if(c.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var n=e.length;if(0===n)return 0;for(var r=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":case void 0:return q(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return z(e).length;default:if(r)return q(e).length;t=(""+t).toLowerCase(),r=!0}}function y(e,t,n){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if((n>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return O(this,t,n);case"utf8":case"utf-8":return A(this,t,n);case"ascii":return x(this,t,n);case"latin1":case"binary":return R(this,t,n);case"base64":return S(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return T(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function g(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function m(e,t,n,r,o){if(0===e.length)return-1;if("string"==typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,isNaN(n)&&(n=o?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(o)return-1;n=e.length-1}else if(n<0){if(!o)return-1;n=0}if("string"==typeof t&&(t=c.from(t,r)),c.isBuffer(t))return 0===t.length?-1:b(e,t,n,r,o);if("number"==typeof t)return t&=255,c.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):b(e,[t],n,r,o);throw new TypeError("val must be string, number or Buffer")}function b(e,t,n,r,o){var i,s=1,a=e.length,c=t.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;s=2,a/=2,c/=2,n/=2}function u(e,t){return 1===s?e[t]:e.readUInt16BE(t*s)}if(o){var f=-1;for(i=n;i<a;i++)if(u(e,i)===u(t,-1===f?0:i-f)){if(-1===f&&(f=i),i-f+1===c)return f*s}else-1!==f&&(i-=i-f),f=-1}else for(n+c>a&&(n=a-c),i=n;i>=0;i--){for(var l=!0,h=0;h<c;h++)if(u(e,i+h)!==u(t,h)){l=!1;break}if(l)return i}return-1}function v(e,t,n,r){n=Number(n)||0;var o=e.length-n;r?(r=Number(r))>o&&(r=o):r=o;var i=t.length;if(i%2!=0)throw new TypeError("Invalid hex string");r>i/2&&(r=i/2);for(var s=0;s<r;++s){var a=parseInt(t.substr(2*s,2),16);if(isNaN(a))return s;e[n+s]=a}return s}function w(e,t,n,r){return Y(q(t,e.length-n),e,n,r)}function C(e,t,n,r){return Y(function(e){for(var t=[],n=0;n<e.length;++n)t.push(255&e.charCodeAt(n));return t}(t),e,n,r)}function k(e,t,n,r){return C(e,t,n,r)}function _(e,t,n,r){return Y(z(t),e,n,r)}function E(e,t,n,r){return Y(function(e,t){for(var n,r,o,i=[],s=0;s<e.length&&!((t-=2)<0);++s)r=(n=e.charCodeAt(s))>>8,o=n%256,i.push(o),i.push(r);return i}(t,e.length-n),e,n,r)}function S(e,t,n){return 0===t&&n===e.length?r.fromByteArray(e):r.fromByteArray(e.slice(t,n))}function A(e,t,n){n=Math.min(e.length,n);for(var r=[],o=t;o<n;){var i,s,a,c,u=e[o],f=null,l=u>239?4:u>223?3:u>191?2:1;if(o+l<=n)switch(l){case 1:u<128&&(f=u);break;case 2:128==(192&(i=e[o+1]))&&(c=(31&u)<<6|63&i)>127&&(f=c);break;case 3:i=e[o+1],s=e[o+2],128==(192&i)&&128==(192&s)&&(c=(15&u)<<12|(63&i)<<6|63&s)>2047&&(c<55296||c>57343)&&(f=c);break;case 4:i=e[o+1],s=e[o+2],a=e[o+3],128==(192&i)&&128==(192&s)&&128==(192&a)&&(c=(15&u)<<18|(63&i)<<12|(63&s)<<6|63&a)>65535&&c<1114112&&(f=c)}null===f?(f=65533,l=1):f>65535&&(f-=65536,r.push(f>>>10&1023|55296),f=56320|1023&f),r.push(f),o+=l}return function(e){var t=e.length;if(t<=F)return String.fromCharCode.apply(String,e);var n="",r=0;for(;r<t;)n+=String.fromCharCode.apply(String,e.slice(r,r+=F));return n}(r)}t.Buffer=c,t.SlowBuffer=function(e){+e!=e&&(e=0);return c.alloc(+e)},t.INSPECT_MAX_BYTES=50,c.TYPED_ARRAY_SUPPORT=void 0!==e.TYPED_ARRAY_SUPPORT?e.TYPED_ARRAY_SUPPORT:function(){try{var e=new Uint8Array(1);return e.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===e.foo()&&"function"==typeof e.subarray&&0===e.subarray(1,1).byteLength}catch(e){return!1}}(),t.kMaxLength=s(),c.poolSize=8192,c._augment=function(e){return e.__proto__=c.prototype,e},c.from=function(e,t,n){return u(null,e,t,n)},c.TYPED_ARRAY_SUPPORT&&(c.prototype.__proto__=Uint8Array.prototype,c.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&c[Symbol.species]===c&&Object.defineProperty(c,Symbol.species,{value:null,configurable:!0})),c.alloc=function(e,t,n){return function(e,t,n,r){return f(t),t<=0?a(e,t):void 0!==n?"string"==typeof r?a(e,t).fill(n,r):a(e,t).fill(n):a(e,t)}(null,e,t,n)},c.allocUnsafe=function(e){return l(null,e)},c.allocUnsafeSlow=function(e){return l(null,e)},c.isBuffer=function(e){return!(null==e||!e._isBuffer)},c.compare=function(e,t){if(!c.isBuffer(e)||!c.isBuffer(t))throw new TypeError("Arguments must be Buffers");if(e===t)return 0;for(var n=e.length,r=t.length,o=0,i=Math.min(n,r);o<i;++o)if(e[o]!==t[o]){n=e[o],r=t[o];break}return n<r?-1:r<n?1:0},c.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},c.concat=function(e,t){if(!i(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return c.alloc(0);var n;if(void 0===t)for(t=0,n=0;n<e.length;++n)t+=e[n].length;var r=c.allocUnsafe(t),o=0;for(n=0;n<e.length;++n){var s=e[n];if(!c.isBuffer(s))throw new TypeError('"list" argument must be an Array of Buffers');s.copy(r,o),o+=s.length}return r},c.byteLength=d,c.prototype._isBuffer=!0,c.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)g(this,t,t+1);return this},c.prototype.swap32=function(){var e=this.length;if(e%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)g(this,t,t+3),g(this,t+1,t+2);return this},c.prototype.swap64=function(){var e=this.length;if(e%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)g(this,t,t+7),g(this,t+1,t+6),g(this,t+2,t+5),g(this,t+3,t+4);return this},c.prototype.toString=function(){var e=0|this.length;return 0===e?"":0===arguments.length?A(this,0,e):y.apply(this,arguments)},c.prototype.equals=function(e){if(!c.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===c.compare(this,e)},c.prototype.inspect=function(){var e="",n=t.INSPECT_MAX_BYTES;return this.length>0&&(e=this.toString("hex",0,n).match(/.{2}/g).join(" "),this.length>n&&(e+=" ... ")),"<Buffer "+e+">"},c.prototype.compare=function(e,t,n,r,o){if(!c.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===r&&(r=0),void 0===o&&(o=this.length),t<0||n>e.length||r<0||o>this.length)throw new RangeError("out of range index");if(r>=o&&t>=n)return 0;if(r>=o)return-1;if(t>=n)return 1;if(this===e)return 0;for(var i=(o>>>=0)-(r>>>=0),s=(n>>>=0)-(t>>>=0),a=Math.min(i,s),u=this.slice(r,o),f=e.slice(t,n),l=0;l<a;++l)if(u[l]!==f[l]){i=u[l],s=f[l];break}return i<s?-1:s<i?1:0},c.prototype.includes=function(e,t,n){return-1!==this.indexOf(e,t,n)},c.prototype.indexOf=function(e,t,n){return m(this,e,t,n,!0)},c.prototype.lastIndexOf=function(e,t,n){return m(this,e,t,n,!1)},c.prototype.write=function(e,t,n,r){if(void 0===t)r="utf8",n=this.length,t=0;else if(void 0===n&&"string"==typeof t)r=t,n=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t|=0,isFinite(n)?(n|=0,void 0===r&&(r="utf8")):(r=n,n=void 0)}var o=this.length-t;if((void 0===n||n>o)&&(n=o),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var i=!1;;)switch(r){case"hex":return v(this,e,t,n);case"utf8":case"utf-8":return w(this,e,t,n);case"ascii":return C(this,e,t,n);case"latin1":case"binary":return k(this,e,t,n);case"base64":return _(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return E(this,e,t,n);default:if(i)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),i=!0}},c.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var F=4096;function x(e,t,n){var r="";n=Math.min(e.length,n);for(var o=t;o<n;++o)r+=String.fromCharCode(127&e[o]);return r}function R(e,t,n){var r="";n=Math.min(e.length,n);for(var o=t;o<n;++o)r+=String.fromCharCode(e[o]);return r}function O(e,t,n){var r=e.length;(!t||t<0)&&(t=0),(!n||n<0||n>r)&&(n=r);for(var o="",i=t;i<n;++i)o+=L(e[i]);return o}function T(e,t,n){for(var r=e.slice(t,n),o="",i=0;i<r.length;i+=2)o+=String.fromCharCode(r[i]+256*r[i+1]);return o}function P(e,t,n){if(e%1!=0||e<0)throw new RangeError("offset is not uint");if(e+t>n)throw new RangeError("Trying to access beyond buffer length")}function B(e,t,n,r,o,i){if(!c.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>o||t<i)throw new RangeError('"value" argument is out of bounds');if(n+r>e.length)throw new RangeError("Index out of range")}function N(e,t,n,r){t<0&&(t=65535+t+1);for(var o=0,i=Math.min(e.length-n,2);o<i;++o)e[n+o]=(t&255<<8*(r?o:1-o))>>>8*(r?o:1-o)}function I(e,t,n,r){t<0&&(t=4294967295+t+1);for(var o=0,i=Math.min(e.length-n,4);o<i;++o)e[n+o]=t>>>8*(r?o:3-o)&255}function M(e,t,n,r,o,i){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function j(e,t,n,r,i){return i||M(e,0,n,4),o.write(e,t,n,r,23,4),n+4}function D(e,t,n,r,i){return i||M(e,0,n,8),o.write(e,t,n,r,52,8),n+8}c.prototype.slice=function(e,t){var n,r=this.length;if((e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t<e&&(t=e),c.TYPED_ARRAY_SUPPORT)(n=this.subarray(e,t)).__proto__=c.prototype;else{var o=t-e;n=new c(o,void 0);for(var i=0;i<o;++i)n[i]=this[i+e]}return n},c.prototype.readUIntLE=function(e,t,n){e|=0,t|=0,n||P(e,t,this.length);for(var r=this[e],o=1,i=0;++i<t&&(o*=256);)r+=this[e+i]*o;return r},c.prototype.readUIntBE=function(e,t,n){e|=0,t|=0,n||P(e,t,this.length);for(var r=this[e+--t],o=1;t>0&&(o*=256);)r+=this[e+--t]*o;return r},c.prototype.readUInt8=function(e,t){return t||P(e,1,this.length),this[e]},c.prototype.readUInt16LE=function(e,t){return t||P(e,2,this.length),this[e]|this[e+1]<<8},c.prototype.readUInt16BE=function(e,t){return t||P(e,2,this.length),this[e]<<8|this[e+1]},c.prototype.readUInt32LE=function(e,t){return t||P(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},c.prototype.readUInt32BE=function(e,t){return t||P(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},c.prototype.readIntLE=function(e,t,n){e|=0,t|=0,n||P(e,t,this.length);for(var r=this[e],o=1,i=0;++i<t&&(o*=256);)r+=this[e+i]*o;return r>=(o*=128)&&(r-=Math.pow(2,8*t)),r},c.prototype.readIntBE=function(e,t,n){e|=0,t|=0,n||P(e,t,this.length);for(var r=t,o=1,i=this[e+--r];r>0&&(o*=256);)i+=this[e+--r]*o;return i>=(o*=128)&&(i-=Math.pow(2,8*t)),i},c.prototype.readInt8=function(e,t){return t||P(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},c.prototype.readInt16LE=function(e,t){t||P(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},c.prototype.readInt16BE=function(e,t){t||P(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},c.prototype.readInt32LE=function(e,t){return t||P(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},c.prototype.readInt32BE=function(e,t){return t||P(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},c.prototype.readFloatLE=function(e,t){return t||P(e,4,this.length),o.read(this,e,!0,23,4)},c.prototype.readFloatBE=function(e,t){return t||P(e,4,this.length),o.read(this,e,!1,23,4)},c.prototype.readDoubleLE=function(e,t){return t||P(e,8,this.length),o.read(this,e,!0,52,8)},c.prototype.readDoubleBE=function(e,t){return t||P(e,8,this.length),o.read(this,e,!1,52,8)},c.prototype.writeUIntLE=function(e,t,n,r){(e=+e,t|=0,n|=0,r)||B(this,e,t,n,Math.pow(2,8*n)-1,0);var o=1,i=0;for(this[t]=255&e;++i<n&&(o*=256);)this[t+i]=e/o&255;return t+n},c.prototype.writeUIntBE=function(e,t,n,r){(e=+e,t|=0,n|=0,r)||B(this,e,t,n,Math.pow(2,8*n)-1,0);var o=n-1,i=1;for(this[t+o]=255&e;--o>=0&&(i*=256);)this[t+o]=e/i&255;return t+n},c.prototype.writeUInt8=function(e,t,n){return e=+e,t|=0,n||B(this,e,t,1,255,0),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},c.prototype.writeUInt16LE=function(e,t,n){return e=+e,t|=0,n||B(this,e,t,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):N(this,e,t,!0),t+2},c.prototype.writeUInt16BE=function(e,t,n){return e=+e,t|=0,n||B(this,e,t,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):N(this,e,t,!1),t+2},c.prototype.writeUInt32LE=function(e,t,n){return e=+e,t|=0,n||B(this,e,t,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):I(this,e,t,!0),t+4},c.prototype.writeUInt32BE=function(e,t,n){return e=+e,t|=0,n||B(this,e,t,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):I(this,e,t,!1),t+4},c.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t|=0,!r){var o=Math.pow(2,8*n-1);B(this,e,t,n,o-1,-o)}var i=0,s=1,a=0;for(this[t]=255&e;++i<n&&(s*=256);)e<0&&0===a&&0!==this[t+i-1]&&(a=1),this[t+i]=(e/s>>0)-a&255;return t+n},c.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t|=0,!r){var o=Math.pow(2,8*n-1);B(this,e,t,n,o-1,-o)}var i=n-1,s=1,a=0;for(this[t+i]=255&e;--i>=0&&(s*=256);)e<0&&0===a&&0!==this[t+i+1]&&(a=1),this[t+i]=(e/s>>0)-a&255;return t+n},c.prototype.writeInt8=function(e,t,n){return e=+e,t|=0,n||B(this,e,t,1,127,-128),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},c.prototype.writeInt16LE=function(e,t,n){return e=+e,t|=0,n||B(this,e,t,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):N(this,e,t,!0),t+2},c.prototype.writeInt16BE=function(e,t,n){return e=+e,t|=0,n||B(this,e,t,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):N(this,e,t,!1),t+2},c.prototype.writeInt32LE=function(e,t,n){return e=+e,t|=0,n||B(this,e,t,4,2147483647,-2147483648),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):I(this,e,t,!0),t+4},c.prototype.writeInt32BE=function(e,t,n){return e=+e,t|=0,n||B(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):I(this,e,t,!1),t+4},c.prototype.writeFloatLE=function(e,t,n){return j(this,e,t,!0,n)},c.prototype.writeFloatBE=function(e,t,n){return j(this,e,t,!1,n)},c.prototype.writeDoubleLE=function(e,t,n){return D(this,e,t,!0,n)},c.prototype.writeDoubleBE=function(e,t,n){return D(this,e,t,!1,n)},c.prototype.copy=function(e,t,n,r){if(n||(n=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r<n&&(r=n),r===n)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(n<0||n>=this.length)throw new RangeError("sourceStart out of bounds");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t<r-n&&(r=e.length-t+n);var o,i=r-n;if(this===e&&n<t&&t<r)for(o=i-1;o>=0;--o)e[o+t]=this[o+n];else if(i<1e3||!c.TYPED_ARRAY_SUPPORT)for(o=0;o<i;++o)e[o+t]=this[o+n];else Uint8Array.prototype.set.call(e,this.subarray(n,n+i),t);return i},c.prototype.fill=function(e,t,n,r){if("string"==typeof e){if("string"==typeof t?(r=t,t=0,n=this.length):"string"==typeof n&&(r=n,n=this.length),1===e.length){var o=e.charCodeAt(0);o<256&&(e=o)}if(void 0!==r&&"string"!=typeof r)throw new TypeError("encoding must be a string");if("string"==typeof r&&!c.isEncoding(r))throw new TypeError("Unknown encoding: "+r)}else"number"==typeof e&&(e&=255);if(t<0||this.length<t||this.length<n)throw new RangeError("Out of range index");if(n<=t)return this;var i;if(t>>>=0,n=void 0===n?this.length:n>>>0,e||(e=0),"number"==typeof e)for(i=t;i<n;++i)this[i]=e;else{var s=c.isBuffer(e)?e:q(new c(e,r).toString()),a=s.length;for(i=0;i<n-t;++i)this[i+t]=s[i%a]}return this};var U=/[^+\/0-9A-Za-z-_]/g;function L(e){return e<16?"0"+e.toString(16):e.toString(16)}function q(e,t){var n;t=t||1/0;for(var r=e.length,o=null,i=[],s=0;s<r;++s){if((n=e.charCodeAt(s))>55295&&n<57344){if(!o){if(n>56319){(t-=3)>-1&&i.push(239,191,189);continue}if(s+1===r){(t-=3)>-1&&i.push(239,191,189);continue}o=n;continue}if(n<56320){(t-=3)>-1&&i.push(239,191,189),o=n;continue}n=65536+(o-55296<<10|n-56320)}else o&&(t-=3)>-1&&i.push(239,191,189);if(o=null,n<128){if((t-=1)<0)break;i.push(n)}else if(n<2048){if((t-=2)<0)break;i.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;i.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;i.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return i}function z(e){return r.toByteArray(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(U,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function Y(e,t,n,r){for(var o=0;o<r&&!(o+n>=t.length||o>=e.length);++o)t[o+n]=e[o];return o}}).call(this,n(39))},function(e,t,n){var r=n(45),o=n(12);e.exports=function(e){var t=e.xdomain,n=e.xscheme,i=e.enablesXDR;try{if("undefined"!=typeof XMLHttpRequest&&(!t||r))return new XMLHttpRequest}catch(e){}try{if("undefined"!=typeof XDomainRequest&&!n&&i)return new XDomainRequest}catch(e){}if(!t)try{return new(o[["Active"].concat("Object").join("X")])("Microsoft.XMLHTTP")}catch(e){}}},function(e,t){e.exports="undefined"!=typeof self?self:"undefined"!=typeof window?window:Function("return this")()},function(e,t,n){var r=n(1),o=n(14);function i(e){this.path=e.path,this.hostname=e.hostname,this.port=e.port,this.secure=e.secure,this.query=e.query,this.timestampParam=e.timestampParam,this.timestampRequests=e.timestampRequests,this.readyState="",this.agent=e.agent||!1,this.socket=e.socket,this.enablesXDR=e.enablesXDR,this.withCredentials=e.withCredentials,this.pfx=e.pfx,this.key=e.key,this.passphrase=e.passphrase,this.cert=e.cert,this.ca=e.ca,this.ciphers=e.ciphers,this.rejectUnauthorized=e.rejectUnauthorized,this.forceNode=e.forceNode,this.isReactNative=e.isReactNative,this.extraHeaders=e.extraHeaders,this.localAddress=e.localAddress}e.exports=i,o(i.prototype),i.prototype.onError=function(e,t){var n=new Error(e);return n.type="TransportError",n.description=t,this.emit("error",n),this},i.prototype.open=function(){return"closed"!==this.readyState&&""!==this.readyState||(this.readyState="opening",this.doOpen()),this},i.prototype.close=function(){return"opening"!==this.readyState&&"open"!==this.readyState||(this.doClose(),this.onClose()),this},i.prototype.send=function(e){if("open"!==this.readyState)throw new Error("Transport not open");this.write(e)},i.prototype.onOpen=function(){this.readyState="open",this.writable=!0,this.emit("open")},i.prototype.onData=function(e){var t=r.decodePacket(e,this.socket.binaryType);this.onPacket(t)},i.prototype.onPacket=function(e){this.emit("packet",e)},i.prototype.onClose=function(){this.readyState="closed",this.emit("close")}},function(e,t,n){function r(e){if(e)return function(e){for(var t in r.prototype)e[t]=r.prototype[t];return e}(e)}e.exports=r,r.prototype.on=r.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},r.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},r.prototype.off=r.prototype.removeListener=r.prototype.removeAllListeners=r.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var n,r=this._callbacks["$"+e];if(!r)return this;if(1==arguments.length)return delete this._callbacks["$"+e],this;for(var o=0;o<r.length;o++)if((n=r[o])===t||n.fn===t){r.splice(o,1);break}return 0===r.length&&delete this._callbacks["$"+e],this},r.prototype.emit=function(e){this._callbacks=this._callbacks||{};for(var t=new Array(arguments.length-1),n=this._callbacks["$"+e],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(n){r=0;for(var o=(n=n.slice(0)).length;r<o;++r)n[r].apply(this,t)}return this},r.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},r.prototype.hasListeners=function(e){return!!this.listeners(e).length}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getServerUrlFromLocation=function(){if(location){if("http:"===location.protocol)return"http://"+location.hostname+":9559";if("https:"===location.protocol)return"https://"+location.hostname+":5443"}return null},t.getServerUrlFromLocalhost=function(){if(location&&"https:"===location.protocol)return"https://127.0.0.1:5443";return"http://127.0.0.1:9559"},t.isDebugMode=function(){return!("true"!==function(){var e=window.location.search.substr(1).split("&");if(""===e)return{};for(var t={},n=0;n<e.length;n++){var r=e[n].split("=",2);1===r.length?t[r[0]]="":t[r[0]]=decodeURIComponent(r[1].replace(/\+/g," "))}return t}().debug)},t.getDeviceName=function(){var e=(new o.UAParser).getResult(),t="Unknown";e.device.vendor&&e.device.model?t="[".concat(e.device.vendor,"] ").concat(e.device.model):e.os.name&&e.browser.name&&(t="[".concat(e.os.name,"] ").concat(e.browser.name));return t},t.getClientId=function(){var e=localStorage.getItem("clientId");if(null===e){var t=(new o.UAParser).getResult(),n="Unknown";void 0!==t.device.vendor?n=t.device.vendor:void 0!==t.os.name&&(n=t.os.name),e=n+i(),localStorage.setItem("clientId",e)}return e},t.isPromise=function(e){return!!e&&"function"==typeof e.then},t.getUniqueId=i,t.getOffloadId=function(e){return e+"_"+e.toLowerCase().split("").reverse().join("")};var r,o=n(60);(r=n(0))&&r.__esModule;function i(){return"_"+Math.random().toString(36).substr(2,9)}},,function(e,t){var n=/^(?:(?![^:@]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@]*)(?::([^:@]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,r=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];e.exports=function(e){var t=e,o=e.indexOf("["),i=e.indexOf("]");-1!=o&&-1!=i&&(e=e.substring(0,o)+e.substring(o,i).replace(/:/g,";")+e.substring(i,e.length));for(var s=n.exec(e||""),a={},c=14;c--;)a[r[c]]=s[c]||"";return-1!=o&&-1!=i&&(a.source=t,a.host=a.host.substring(1,a.host.length-1).replace(/;/g,":"),a.authority=a.authority.replace("[","").replace("]","").replace(/;/g,":"),a.ipv6uri=!0),a}},function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},function(e,t,n){(function(t){e.exports=function(e){return n&&t.isBuffer(e)||r&&(e instanceof ArrayBuffer||function(e){return"function"==typeof ArrayBuffer.isView?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer}(e))};var n="function"==typeof t&&"function"==typeof t.isBuffer,r="function"==typeof ArrayBuffer}).call(this,n(10).Buffer)},function(e,t,n){var r=n(43),o=n(26),i=n(9),s=n(8),a=n(27),c=n(28),u=n(2)("socket.io-client:manager"),f=n(25),l=n(59),h=Object.prototype.hasOwnProperty;function p(e,t){if(!(this instanceof p))return new p(e,t);e&&"object"==typeof e&&(t=e,e=void 0),(t=t||{}).path=t.path||"/socket.io",this.nsps={},this.subs=[],this.opts=t,this.reconnection(!1!==t.reconnection),this.reconnectionAttempts(t.reconnectionAttempts||1/0),this.reconnectionDelay(t.reconnectionDelay||1e3),this.reconnectionDelayMax(t.reconnectionDelayMax||5e3),this.randomizationFactor(t.randomizationFactor||.5),this.backoff=new l({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(null==t.timeout?2e4:t.timeout),this.readyState="closed",this.uri=e,this.connecting=[],this.lastPing=null,this.encoding=!1,this.packetBuffer=[];var n=t.parser||s;this.encoder=new n.Encoder,this.decoder=new n.Decoder,this.autoConnect=!1!==t.autoConnect,this.autoConnect&&this.open()}e.exports=p,p.prototype.emitAll=function(){for(var e in this.emit.apply(this,arguments),this.nsps)h.call(this.nsps,e)&&this.nsps[e].emit.apply(this.nsps[e],arguments)},p.prototype.updateSocketIds=function(){for(var e in this.nsps)h.call(this.nsps,e)&&(this.nsps[e].id=this.generateId(e))},p.prototype.generateId=function(e){return("/"===e?"":e+"#")+this.engine.id},i(p.prototype),p.prototype.reconnection=function(e){return arguments.length?(this._reconnection=!!e,this):this._reconnection},p.prototype.reconnectionAttempts=function(e){return arguments.length?(this._reconnectionAttempts=e,this):this._reconnectionAttempts},p.prototype.reconnectionDelay=function(e){return arguments.length?(this._reconnectionDelay=e,this.backoff&&this.backoff.setMin(e),this):this._reconnectionDelay},p.prototype.randomizationFactor=function(e){return arguments.length?(this._randomizationFactor=e,this.backoff&&this.backoff.setJitter(e),this):this._randomizationFactor},p.prototype.reconnectionDelayMax=function(e){return arguments.length?(this._reconnectionDelayMax=e,this.backoff&&this.backoff.setMax(e),this):this._reconnectionDelayMax},p.prototype.timeout=function(e){return arguments.length?(this._timeout=e,this):this._timeout},p.prototype.maybeReconnectOnOpen=function(){!this.reconnecting&&this._reconnection&&0===this.backoff.attempts&&this.reconnect()},p.prototype.open=p.prototype.connect=function(e,t){if(u("readyState %s",this.readyState),~this.readyState.indexOf("open"))return this;u("opening %s",this.uri),this.engine=r(this.uri,this.opts);var n=this.engine,o=this;this.readyState="opening",this.skipReconnect=!1;var i=a(n,"open",(function(){o.onopen(),e&&e()})),s=a(n,"error",(function(t){if(u("connect_error"),o.cleanup(),o.readyState="closed",o.emitAll("connect_error",t),e){var n=new Error("Connection error");n.data=t,e(n)}else o.maybeReconnectOnOpen()}));if(!1!==this._timeout){var c=this._timeout;u("connect attempt will timeout after %d",c);var f=setTimeout((function(){u("connect attempt timed out after %d",c),i.destroy(),n.close(),n.emit("error","timeout"),o.emitAll("connect_timeout",c)}),c);this.subs.push({destroy:function(){clearTimeout(f)}})}return this.subs.push(i),this.subs.push(s),this},p.prototype.onopen=function(){u("open"),this.cleanup(),this.readyState="open",this.emit("open");var e=this.engine;this.subs.push(a(e,"data",c(this,"ondata"))),this.subs.push(a(e,"ping",c(this,"onping"))),this.subs.push(a(e,"pong",c(this,"onpong"))),this.subs.push(a(e,"error",c(this,"onerror"))),this.subs.push(a(e,"close",c(this,"onclose"))),this.subs.push(a(this.decoder,"decoded",c(this,"ondecoded")))},p.prototype.onping=function(){this.lastPing=new Date,this.emitAll("ping")},p.prototype.onpong=function(){this.emitAll("pong",new Date-this.lastPing)},p.prototype.ondata=function(e){this.decoder.add(e)},p.prototype.ondecoded=function(e){this.emit("packet",e)},p.prototype.onerror=function(e){u("error",e),this.emitAll("error",e)},p.prototype.socket=function(e,t){var n=this.nsps[e];if(!n){n=new o(this,e,t),this.nsps[e]=n;var r=this;n.on("connecting",i),n.on("connect",(function(){n.id=r.generateId(e)})),this.autoConnect&&i()}function i(){~f(r.connecting,n)||r.connecting.push(n)}return n},p.prototype.destroy=function(e){var t=f(this.connecting,e);~t&&this.connecting.splice(t,1),this.connecting.length||this.close()},p.prototype.packet=function(e){u("writing packet %j",e);var t=this;e.query&&0===e.type&&(e.nsp+="?"+e.query),t.encoding?t.packetBuffer.push(e):(t.encoding=!0,this.encoder.encode(e,(function(n){for(var r=0;r<n.length;r++)t.engine.write(n[r],e.options);t.encoding=!1,t.processPacketQueue()})))},p.prototype.processPacketQueue=function(){if(this.packetBuffer.length>0&&!this.encoding){var e=this.packetBuffer.shift();this.packet(e)}},p.prototype.cleanup=function(){u("cleanup");for(var e=this.subs.length,t=0;t<e;t++){this.subs.shift().destroy()}this.packetBuffer=[],this.encoding=!1,this.lastPing=null,this.decoder.destroy()},p.prototype.close=p.prototype.disconnect=function(){u("disconnect"),this.skipReconnect=!0,this.reconnecting=!1,"opening"===this.readyState&&this.cleanup(),this.backoff.reset(),this.readyState="closed",this.engine&&this.engine.close()},p.prototype.onclose=function(e){u("onclose"),this.cleanup(),this.backoff.reset(),this.readyState="closed",this.emit("close",e),this._reconnection&&!this.skipReconnect&&this.reconnect()},p.prototype.reconnect=function(){if(this.reconnecting||this.skipReconnect)return this;var e=this;if(this.backoff.attempts>=this._reconnectionAttempts)u("reconnect failed"),this.backoff.reset(),this.emitAll("reconnect_failed"),this.reconnecting=!1;else{var t=this.backoff.duration();u("will wait %dms before reconnect attempt",t),this.reconnecting=!0;var n=setTimeout((function(){e.skipReconnect||(u("attempting reconnect"),e.emitAll("reconnect_attempt",e.backoff.attempts),e.emitAll("reconnecting",e.backoff.attempts),e.skipReconnect||e.open((function(t){t?(u("reconnect attempt error"),e.reconnecting=!1,e.reconnect(),e.emitAll("reconnect_error",t.data)):(u("reconnect success"),e.onreconnect())})))}),t);this.subs.push({destroy:function(){clearTimeout(n)}})}},p.prototype.onreconnect=function(){var e=this.backoff.attempts;this.reconnecting=!1,this.backoff.reset(),this.updateSocketIds(),this.emitAll("reconnect",e)}},function(e,t,n){var r=n(11),o=n(46),i=n(55),s=n(56);t.polling=function(e){var t=!1,n=!1,s=!1!==e.jsonp;if("undefined"!=typeof location){var a="https:"===location.protocol,c=location.port;c||(c=a?443:80),t=e.hostname!==location.hostname||c!==e.port,n=e.secure!==a}if(e.xdomain=t,e.xscheme=n,"open"in new r(e)&&!e.forceJSONP)return new o(e);if(!s)throw new Error("JSONP disabled");return new i(e)},t.websocket=s},function(e,t,n){var r=n(13),o=n(4),i=n(1),s=n(5),a=n(24),c=n(6)("engine.io-client:polling");e.exports=f;var u=null!=new(n(11))({xdomain:!1}).responseType;function f(e){var t=e&&e.forceBase64;u&&!t||(this.supportsBinary=!1),r.call(this,e)}s(f,r),f.prototype.name="polling",f.prototype.doOpen=function(){this.poll()},f.prototype.pause=function(e){var t=this;function n(){c("paused"),t.readyState="paused",e()}if(this.readyState="pausing",this.polling||!this.writable){var r=0;this.polling&&(c("we are currently polling - waiting to pause"),r++,this.once("pollComplete",(function(){c("pre-pause polling complete"),--r||n()}))),this.writable||(c("we are currently writing - waiting to pause"),r++,this.once("drain",(function(){c("pre-pause writing complete"),--r||n()})))}else n()},f.prototype.poll=function(){c("polling"),this.polling=!0,this.doPoll(),this.emit("poll")},f.prototype.onData=function(e){var t=this;c("polling got data %s",e);i.decodePayload(e,this.socket.binaryType,(function(e,n,r){if("opening"===t.readyState&&t.onOpen(),"close"===e.type)return t.onClose(),!1;t.onPacket(e)})),"closed"!==this.readyState&&(this.polling=!1,this.emit("pollComplete"),"open"===this.readyState?this.poll():c('ignoring poll - transport state "%s"',this.readyState))},f.prototype.doClose=function(){var e=this;function t(){c("writing close packet"),e.write([{type:"close"}])}"open"===this.readyState?(c("transport open - closing"),t()):(c("transport not open - deferring close"),this.once("open",t))},f.prototype.write=function(e){var t=this;this.writable=!1;var n=function(){t.writable=!0,t.emit("drain")};i.encodePayload(e,this.supportsBinary,(function(e){t.doWrite(e,n)}))},f.prototype.uri=function(){var e=this.query||{},t=this.secure?"https":"http",n="";return!1!==this.timestampRequests&&(e[this.timestampParam]=a()),this.supportsBinary||e.sid||(e.b64=1),e=o.encode(e),this.port&&("https"===t&&443!==Number(this.port)||"http"===t&&80!==Number(this.port))&&(n=":"+this.port),e.length&&(e="?"+e),t+"://"+(-1!==this.hostname.indexOf(":")?"["+this.hostname+"]":this.hostname)+n+this.path+e}},function(e,t,n){(function(t){var r=n(48),o=Object.prototype.toString,i="function"==typeof Blob||"undefined"!=typeof Blob&&"[object BlobConstructor]"===o.call(Blob),s="function"==typeof File||"undefined"!=typeof File&&"[object FileConstructor]"===o.call(File);e.exports=function e(n){if(!n||"object"!=typeof n)return!1;if(r(n)){for(var o=0,a=n.length;o<a;o++)if(e(n[o]))return!0;return!1}if("function"==typeof t&&t.isBuffer&&t.isBuffer(n)||"function"==typeof ArrayBuffer&&n instanceof ArrayBuffer||i&&n instanceof Blob||s&&n instanceof File)return!0;if(n.toJSON&&"function"==typeof n.toJSON&&1===arguments.length)return e(n.toJSON(),!0);for(var c in n)if(Object.prototype.hasOwnProperty.call(n,c)&&e(n[c]))return!0;return!1}}).call(this,n(10).Buffer)},function(e,t,n){"use strict";var r,o="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-_".split(""),i={},s=0,a=0;function c(e){var t="";do{t=o[e%64]+t,e=Math.floor(e/64)}while(e>0);return t}function u(){var e=c(+new Date);return e!==r?(s=0,r=e):e+"."+c(s++)}for(;a<64;a++)i[o[a]]=a;u.encode=c,u.decode=function(e){var t=0;for(a=0;a<e.length;a++)t=64*t+i[e.charAt(a)];return t},e.exports=u},function(e,t){var n=[].indexOf;e.exports=function(e,t){if(n)return e.indexOf(t);for(var r=0;r<e.length;++r)if(e[r]===t)return r;return-1}},function(e,t,n){var r=n(8),o=n(9),i=n(58),s=n(27),a=n(28),c=n(2)("socket.io-client:socket"),u=n(4),f=n(23);e.exports=p;var l={connect:1,connect_error:1,connect_timeout:1,connecting:1,disconnect:1,error:1,reconnect:1,reconnect_attempt:1,reconnect_failed:1,reconnect_error:1,reconnecting:1,ping:1,pong:1},h=o.prototype.emit;function p(e,t,n){this.io=e,this.nsp=t,this.json=this,this.ids=0,this.acks={},this.receiveBuffer=[],this.sendBuffer=[],this.connected=!1,this.disconnected=!0,this.flags={},n&&n.query&&(this.query=n.query),this.io.autoConnect&&this.open()}o(p.prototype),p.prototype.subEvents=function(){if(!this.subs){var e=this.io;this.subs=[s(e,"open",a(this,"onopen")),s(e,"packet",a(this,"onpacket")),s(e,"close",a(this,"onclose"))]}},p.prototype.open=p.prototype.connect=function(){return this.connected||(this.subEvents(),this.io.open(),"open"===this.io.readyState&&this.onopen(),this.emit("connecting")),this},p.prototype.send=function(){var e=i(arguments);return e.unshift("message"),this.emit.apply(this,e),this},p.prototype.emit=function(e){if(l.hasOwnProperty(e))return h.apply(this,arguments),this;var t=i(arguments),n={type:(void 0!==this.flags.binary?this.flags.binary:f(t))?r.BINARY_EVENT:r.EVENT,data:t,options:{}};return n.options.compress=!this.flags||!1!==this.flags.compress,"function"==typeof t[t.length-1]&&(c("emitting packet with ack id %d",this.ids),this.acks[this.ids]=t.pop(),n.id=this.ids++),this.connected?this.packet(n):this.sendBuffer.push(n),this.flags={},this},p.prototype.packet=function(e){e.nsp=this.nsp,this.io.packet(e)},p.prototype.onopen=function(){if(c("transport is open - connecting"),"/"!==this.nsp)if(this.query){var e="object"==typeof this.query?u.encode(this.query):this.query;c("sending connect packet with query %s",e),this.packet({type:r.CONNECT,query:e})}else this.packet({type:r.CONNECT})},p.prototype.onclose=function(e){c("close (%s)",e),this.connected=!1,this.disconnected=!0,delete this.id,this.emit("disconnect",e)},p.prototype.onpacket=function(e){var t=e.nsp===this.nsp,n=e.type===r.ERROR&&"/"===e.nsp;if(t||n)switch(e.type){case r.CONNECT:this.onconnect();break;case r.EVENT:case r.BINARY_EVENT:this.onevent(e);break;case r.ACK:case r.BINARY_ACK:this.onack(e);break;case r.DISCONNECT:this.ondisconnect();break;case r.ERROR:this.emit("error",e.data)}},p.prototype.onevent=function(e){var t=e.data||[];c("emitting event %j",t),null!=e.id&&(c("attaching ack callback to event"),t.push(this.ack(e.id))),this.connected?h.apply(this,t):this.receiveBuffer.push(t)},p.prototype.ack=function(e){var t=this,n=!1;return function(){if(!n){n=!0;var o=i(arguments);c("sending ack %j",o),t.packet({type:f(o)?r.BINARY_ACK:r.ACK,id:e,data:o})}}},p.prototype.onack=function(e){var t=this.acks[e.id];"function"==typeof t?(c("calling ack %s with %j",e.id,e.data),t.apply(this,e.data),delete this.acks[e.id]):c("bad ack %s",e.id)},p.prototype.onconnect=function(){this.connected=!0,this.disconnected=!1,this.emit("connect"),this.emitBuffered()},p.prototype.emitBuffered=function(){var e;for(e=0;e<this.receiveBuffer.length;e++)h.apply(this,this.receiveBuffer[e]);for(this.receiveBuffer=[],e=0;e<this.sendBuffer.length;e++)this.packet(this.sendBuffer[e]);this.sendBuffer=[]},p.prototype.ondisconnect=function(){c("server disconnect (%s)",this.nsp),this.destroy(),this.onclose("io server disconnect")},p.prototype.destroy=function(){if(this.subs){for(var e=0;e<this.subs.length;e++)this.subs[e].destroy();this.subs=null}this.io.destroy(this)},p.prototype.close=p.prototype.disconnect=function(){return this.connected&&(c("performing disconnect (%s)",this.nsp),this.packet({type:r.DISCONNECT})),this.destroy(),this.connected&&this.onclose("io client disconnect"),this},p.prototype.compress=function(e){return this.flags.compress=e,this},p.prototype.binary=function(e){return this.flags.binary=e,this}},function(e,t){e.exports=function(e,t,n){return e.on(t,n),{destroy:function(){e.removeListener(t,n)}}}},function(e,t){var n=[].slice;e.exports=function(e,t){if("string"==typeof t&&(t=e[t]),"function"!=typeof t)throw new Error("bind() requires a function");var r=n.call(arguments,2);return function(){return t.apply(e,r.concat(n.call(arguments)))}}},,function(e,t,n){"use strict";var r;function o(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}Object.defineProperty(t,"__esModule",{value:!0}),t.Worker=void 0;var i=new(((r=n(0))&&r.__esModule?r:{default:r}).default)("worker.js"),s=1e3,a=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.dataChannel=null,this.peerConnection=null,this.features=new Set,this.confirmations=new Map}var t,n,r;return t=e,(n=[{key:"setPeerConnection",value:function(e){this.peerConnection=e}},{key:"setDataChannel",value:function(e){this.dataChannel=e}},{key:"hasFeature",value:function(e){return this.features.has(e)}},{key:"requestConfirmation",value:function(e,t,n){var r=this;return i.debug("requestConfirmation feature:".concat(e," clientId:").concat(t," deviceName:").concat(n)),new Promise((function(o){"undefined"!=typeof android?(android.emit("requestConfirmation",JSON.stringify({id:s,feature:e,clientId:t,deviceName:n})),r.confirmations.set(s,o),s++):o(!0)}))}},{key:"onConfirmationResult",value:function(e,t){return i.debug("onConfirmationResult id:".concat(e," allowed:").concat(t)),!!this.confirmations.has(e)&&(this.confirmations.get(e)(t),this.confirmations.delete(e),!0)}}])&&o(t.prototype,n),r&&o(t,r),e}();t.Worker=a},,function(e,t,n){var r=n(33),o=n(8),i=n(20),s=n(2)("socket.io-client");e.exports=t=c;var a=t.managers={};function c(e,t){"object"==typeof e&&(t=e,e=void 0),t=t||{};var n,o=r(e),c=o.source,u=o.id,f=o.path,l=a[u]&&f in a[u].nsps;return t.forceNew||t["force new connection"]||!1===t.multiplex||l?(s("ignoring socket cache for %s",c),n=i(c,t)):(a[u]||(s("new io instance for %s",c),a[u]=i(c,t)),n=a[u]),o.query&&!t.query&&(t.query=o.query),n.socket(o.path,t)}t.protocol=o.protocol,t.connect=c,t.Manager=n(20),t.Socket=n(26)},function(e,t,n){var r=n(17),o=n(2)("socket.io-client:url");e.exports=function(e,t){var n=e;t=t||"undefined"!=typeof location&&location,null==e&&(e=t.protocol+"//"+t.host);"string"==typeof e&&("/"===e.charAt(0)&&(e="/"===e.charAt(1)?t.protocol+e:t.host+e),/^(https?|wss?):\/\//.test(e)||(o("protocol-less url %s",e),e=void 0!==t?t.protocol+"//"+e:"https://"+e),o("parse %s",e),n=r(e));n.port||(/^(http|ws)$/.test(n.protocol)?n.port="80":/^(http|ws)s$/.test(n.protocol)&&(n.port="443"));n.path=n.path||"/";var i=-1!==n.host.indexOf(":")?"["+n.host+"]":n.host;return n.id=n.protocol+"://"+i+":"+n.port,n.href=n.protocol+"://"+i+(t&&t.port===n.port?"":":"+n.port),n}},function(e,t,n){e.exports=function(e){function t(e){let t=0;for(let n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n),t|=0;return r.colors[Math.abs(t)%r.colors.length]}function r(e){let n;function s(...e){if(!s.enabled)return;const t=s,o=Number(new Date),i=o-(n||o);t.diff=i,t.prev=n,t.curr=o,n=o,e[0]=r.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let a=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,((n,o)=>{if("%%"===n)return n;a++;const i=r.formatters[o];if("function"==typeof i){const r=e[a];n=i.call(t,r),e.splice(a,1),a--}return n})),r.formatArgs.call(t,e);(t.log||r.log).apply(t,e)}return s.namespace=e,s.enabled=r.enabled(e),s.useColors=r.useColors(),s.color=t(e),s.destroy=o,s.extend=i,"function"==typeof r.init&&r.init(s),r.instances.push(s),s}function o(){const e=r.instances.indexOf(this);return-1!==e&&(r.instances.splice(e,1),!0)}function i(e,t){const n=r(this.namespace+(void 0===t?":":t)+e);return n.log=this.log,n}function s(e){return e.toString().substring(2,e.toString().length-2).replace(/\.\*\?$/,"*")}return r.debug=r,r.default=r,r.coerce=function(e){if(e instanceof Error)return e.stack||e.message;return e},r.disable=function(){const e=[...r.names.map(s),...r.skips.map(s).map((e=>"-"+e))].join(",");return r.enable(""),e},r.enable=function(e){let t;r.save(e),r.names=[],r.skips=[];const n=("string"==typeof e?e:"").split(/[\s,]+/),o=n.length;for(t=0;t<o;t++)n[t]&&("-"===(e=n[t].replace(/\*/g,".*?"))[0]?r.skips.push(new RegExp("^"+e.substr(1)+"$")):r.names.push(new RegExp("^"+e+"$")));for(t=0;t<r.instances.length;t++){const e=r.instances[t];e.enabled=r.enabled(e.namespace)}},r.enabled=function(e){if("*"===e[e.length-1])return!0;let t,n;for(t=0,n=r.skips.length;t<n;t++)if(r.skips[t].test(e))return!1;for(t=0,n=r.names.length;t<n;t++)if(r.names[t].test(e))return!0;return!1},r.humanize=n(7),Object.keys(e).forEach((t=>{r[t]=e[t]})),r.instances=[],r.names=[],r.skips=[],r.formatters={},r.selectColor=t,r.enable(r.load()),r}},function(e,t,n){(function(r){function o(){var e;try{e=t.storage.debug}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}(t=e.exports=n(36)).log=function(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)},t.formatArgs=function(e){var n=this.useColors;if(e[0]=(n?"%c":"")+this.namespace+(n?" %c":" ")+e[0]+(n?"%c ":" ")+"+"+t.humanize(this.diff),!n)return;var r="color: "+this.color;e.splice(1,0,r,"color: inherit");var o=0,i=0;e[0].replace(/%[a-zA-Z%]/g,(function(e){"%%"!==e&&(o++,"%c"===e&&(i=o))})),e.splice(i,0,r)},t.save=function(e){try{null==e?t.storage.removeItem("debug"):t.storage.debug=e}catch(e){}},t.load=o,t.useColors=function(){if("undefined"!=typeof window&&window.process&&"renderer"===window.process.type)return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:function(){try{return window.localStorage}catch(e){}}(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.formatters.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}},t.enable(o())}).call(this,n(3))},function(e,t,n){function r(e){var n;function r(){if(r.enabled){var e=r,o=+new Date,i=o-(n||o);e.diff=i,e.prev=n,e.curr=o,n=o;for(var s=new Array(arguments.length),a=0;a<s.length;a++)s[a]=arguments[a];s[0]=t.coerce(s[0]),"string"!=typeof s[0]&&s.unshift("%O");var c=0;s[0]=s[0].replace(/%([a-zA-Z%])/g,(function(n,r){if("%%"===n)return n;c++;var o=t.formatters[r];if("function"==typeof o){var i=s[c];n=o.call(e,i),s.splice(c,1),c--}return n})),t.formatArgs.call(e,s);var u=r.log||t.log||console.log.bind(console);u.apply(e,s)}}return r.namespace=e,r.enabled=t.enabled(e),r.useColors=t.useColors(),r.color=function(e){var n,r=0;for(n in e)r=(r<<5)-r+e.charCodeAt(n),r|=0;return t.colors[Math.abs(r)%t.colors.length]}(e),r.destroy=o,"function"==typeof t.init&&t.init(r),t.instances.push(r),r}function o(){var e=t.instances.indexOf(this);return-1!==e&&(t.instances.splice(e,1),!0)}(t=e.exports=r.debug=r.default=r).coerce=function(e){return e instanceof Error?e.stack||e.message:e},t.disable=function(){t.enable("")},t.enable=function(e){var n;t.save(e),t.names=[],t.skips=[];var r=("string"==typeof e?e:"").split(/[\s,]+/),o=r.length;for(n=0;n<o;n++)r[n]&&("-"===(e=r[n].replace(/\*/g,".*?"))[0]?t.skips.push(new RegExp("^"+e.substr(1)+"$")):t.names.push(new RegExp("^"+e+"$")));for(n=0;n<t.instances.length;n++){var i=t.instances[n];i.enabled=t.enabled(i.namespace)}},t.enabled=function(e){if("*"===e[e.length-1])return!0;var n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1},t.humanize=n(37),t.instances=[],t.names=[],t.skips=[],t.formatters={}},function(e,t){var n=1e3,r=60*n,o=60*r,i=24*o,s=365.25*i;function a(e,t,n){if(!(e<t))return e<1.5*t?Math.floor(e/t)+" "+n:Math.ceil(e/t)+" "+n+"s"}e.exports=function(e,t){t=t||{};var c,u=typeof e;if("string"===u&&e.length>0)return function(e){if((e=String(e)).length>100)return;var t=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(e);if(!t)return;var a=parseFloat(t[1]);switch((t[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return a*s;case"days":case"day":case"d":return a*i;case"hours":case"hour":case"hrs":case"hr":case"h":return a*o;case"minutes":case"minute":case"mins":case"min":case"m":return a*r;case"seconds":case"second":case"secs":case"sec":case"s":return a*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return a;default:return}}(e);if("number"===u&&!1===isNaN(e))return t.long?a(c=e,i,"day")||a(c,o,"hour")||a(c,r,"minute")||a(c,n,"second")||c+" ms":function(e){if(e>=i)return Math.round(e/i)+"d";if(e>=o)return Math.round(e/o)+"h";if(e>=r)return Math.round(e/r)+"m";if(e>=n)return Math.round(e/n)+"s";return e+"ms"}(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},function(e,t,n){var r=n(18),o=n(19),i=Object.prototype.toString,s="function"==typeof Blob||"undefined"!=typeof Blob&&"[object BlobConstructor]"===i.call(Blob),a="function"==typeof File||"undefined"!=typeof File&&"[object FileConstructor]"===i.call(File);function c(e,t){if(!e)return e;if(o(e)){var n={_placeholder:!0,num:t.length};return t.push(e),n}if(r(e)){for(var i=new Array(e.length),s=0;s<e.length;s++)i[s]=c(e[s],t);return i}if("object"==typeof e&&!(e instanceof Date)){i={};for(var a in e)i[a]=c(e[a],t);return i}return e}function u(e,t){if(!e)return e;if(e&&e._placeholder)return t[e.num];if(r(e))for(var n=0;n<e.length;n++)e[n]=u(e[n],t);else if("object"==typeof e)for(var o in e)e[o]=u(e[o],t);return e}t.deconstructPacket=function(e){var t=[],n=e.data,r=e;return r.data=c(n,t),r.attachments=t.length,{packet:r,buffers:t}},t.reconstructPacket=function(e,t){return e.data=u(e.data,t),e.attachments=void 0,e},t.removeBlobs=function(e,t){var n=0,i=e;!function e(c,u,f){if(!c)return c;if(s&&c instanceof Blob||a&&c instanceof File){n++;var l=new FileReader;l.onload=function(){f?f[u]=this.result:i=this.result,--n||t(i)},l.readAsArrayBuffer(c)}else if(r(c))for(var h=0;h<c.length;h++)e(c[h],h,c);else if("object"==typeof c&&!o(c))for(var p in c)e(c[p],p,c)}(i),n||t(i)}},function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t,n){"use strict";t.byteLength=function(e){var t=u(e),n=t[0],r=t[1];return 3*(n+r)/4-r},t.toByteArray=function(e){var t,n,r=u(e),s=r[0],a=r[1],c=new i(function(e,t,n){return 3*(t+n)/4-n}(0,s,a)),f=0,l=a>0?s-4:s;for(n=0;n<l;n+=4)t=o[e.charCodeAt(n)]<<18|o[e.charCodeAt(n+1)]<<12|o[e.charCodeAt(n+2)]<<6|o[e.charCodeAt(n+3)],c[f++]=t>>16&255,c[f++]=t>>8&255,c[f++]=255&t;2===a&&(t=o[e.charCodeAt(n)]<<2|o[e.charCodeAt(n+1)]>>4,c[f++]=255&t);1===a&&(t=o[e.charCodeAt(n)]<<10|o[e.charCodeAt(n+1)]<<4|o[e.charCodeAt(n+2)]>>2,c[f++]=t>>8&255,c[f++]=255&t);return c},t.fromByteArray=function(e){for(var t,n=e.length,o=n%3,i=[],s=16383,a=0,c=n-o;a<c;a+=s)i.push(f(e,a,a+s>c?c:a+s));1===o?(t=e[n-1],i.push(r[t>>2]+r[t<<4&63]+"==")):2===o&&(t=(e[n-2]<<8)+e[n-1],i.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"="));return i.join("")};for(var r=[],o=[],i="undefined"!=typeof Uint8Array?Uint8Array:Array,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,c=s.length;a<c;++a)r[a]=s[a],o[s.charCodeAt(a)]=a;function u(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");return-1===n&&(n=t),[n,n===t?0:4-n%4]}function f(e,t,n){for(var o,i,s=[],a=t;a<n;a+=3)o=(e[a]<<16&16711680)+(e[a+1]<<8&65280)+(255&e[a+2]),s.push(r[(i=o)>>18&63]+r[i>>12&63]+r[i>>6&63]+r[63&i]);return s.join("")}o["-".charCodeAt(0)]=62,o["_".charCodeAt(0)]=63},function(e,t){t.read=function(e,t,n,r,o){var i,s,a=8*o-r-1,c=(1<<a)-1,u=c>>1,f=-7,l=n?o-1:0,h=n?-1:1,p=e[t+l];for(l+=h,i=p&(1<<-f)-1,p>>=-f,f+=a;f>0;i=256*i+e[t+l],l+=h,f-=8);for(s=i&(1<<-f)-1,i>>=-f,f+=r;f>0;s=256*s+e[t+l],l+=h,f-=8);if(0===i)i=1-u;else{if(i===c)return s?NaN:1/0*(p?-1:1);s+=Math.pow(2,r),i-=u}return(p?-1:1)*s*Math.pow(2,i-r)},t.write=function(e,t,n,r,o,i){var s,a,c,u=8*i-o-1,f=(1<<u)-1,l=f>>1,h=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,p=r?0:i-1,d=r?1:-1,y=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(a=isNaN(t)?1:0,s=f):(s=Math.floor(Math.log(t)/Math.LN2),t*(c=Math.pow(2,-s))<1&&(s--,c*=2),(t+=s+l>=1?h/c:h*Math.pow(2,1-l))*c>=2&&(s++,c/=2),s+l>=f?(a=0,s=f):s+l>=1?(a=(t*c-1)*Math.pow(2,o),s+=l):(a=t*Math.pow(2,l-1)*Math.pow(2,o),s=0));o>=8;e[n+p]=255&a,p+=d,a/=256,o-=8);for(s=s<<o|a,u+=o;u>0;e[n+p]=255&s,p+=d,s/=256,u-=8);e[n+p-d]|=128*y}},function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},function(e,t,n){e.exports=n(44),e.exports.parser=n(1)},function(e,t,n){var r=n(21),o=n(14),i=n(6)("engine.io-client:socket"),s=n(25),a=n(1),c=n(17),u=n(4);function f(e,t){if(!(this instanceof f))return new f(e,t);t=t||{},e&&"object"==typeof e&&(t=e,e=null),e?(e=c(e),t.hostname=e.host,t.secure="https"===e.protocol||"wss"===e.protocol,t.port=e.port,e.query&&(t.query=e.query)):t.host&&(t.hostname=c(t.host).host),this.secure=null!=t.secure?t.secure:"undefined"!=typeof location&&"https:"===location.protocol,t.hostname&&!t.port&&(t.port=this.secure?"443":"80"),this.agent=t.agent||!1,this.hostname=t.hostname||("undefined"!=typeof location?location.hostname:"localhost"),this.port=t.port||("undefined"!=typeof location&&location.port?location.port:this.secure?443:80),this.query=t.query||{},"string"==typeof this.query&&(this.query=u.decode(this.query)),this.upgrade=!1!==t.upgrade,this.path=(t.path||"/engine.io").replace(/\/$/,"")+"/",this.forceJSONP=!!t.forceJSONP,this.jsonp=!1!==t.jsonp,this.forceBase64=!!t.forceBase64,this.enablesXDR=!!t.enablesXDR,this.withCredentials=!1!==t.withCredentials,this.timestampParam=t.timestampParam||"t",this.timestampRequests=t.timestampRequests,this.transports=t.transports||["polling","websocket"],this.transportOptions=t.transportOptions||{},this.readyState="",this.writeBuffer=[],this.prevBufferLen=0,this.policyPort=t.policyPort||843,this.rememberUpgrade=t.rememberUpgrade||!1,this.binaryType=null,this.onlyBinaryUpgrades=t.onlyBinaryUpgrades,this.perMessageDeflate=!1!==t.perMessageDeflate&&(t.perMessageDeflate||{}),!0===this.perMessageDeflate&&(this.perMessageDeflate={}),this.perMessageDeflate&&null==this.perMessageDeflate.threshold&&(this.perMessageDeflate.threshold=1024),this.pfx=t.pfx||null,this.key=t.key||null,this.passphrase=t.passphrase||null,this.cert=t.cert||null,this.ca=t.ca||null,this.ciphers=t.ciphers||null,this.rejectUnauthorized=void 0===t.rejectUnauthorized||t.rejectUnauthorized,this.forceNode=!!t.forceNode,this.isReactNative="undefined"!=typeof navigator&&"string"==typeof navigator.product&&"reactnative"===navigator.product.toLowerCase(),("undefined"==typeof self||this.isReactNative)&&(t.extraHeaders&&Object.keys(t.extraHeaders).length>0&&(this.extraHeaders=t.extraHeaders),t.localAddress&&(this.localAddress=t.localAddress)),this.id=null,this.upgrades=null,this.pingInterval=null,this.pingTimeout=null,this.pingIntervalTimer=null,this.pingTimeoutTimer=null,this.open()}e.exports=f,f.priorWebsocketSuccess=!1,o(f.prototype),f.protocol=a.protocol,f.Socket=f,f.Transport=n(13),f.transports=n(21),f.parser=n(1),f.prototype.createTransport=function(e){i('creating transport "%s"',e);var t=function(e){var t={};for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return t}(this.query);t.EIO=a.protocol,t.transport=e;var n=this.transportOptions[e]||{};return this.id&&(t.sid=this.id),new r[e]({query:t,socket:this,agent:n.agent||this.agent,hostname:n.hostname||this.hostname,port:n.port||this.port,secure:n.secure||this.secure,path:n.path||this.path,forceJSONP:n.forceJSONP||this.forceJSONP,jsonp:n.jsonp||this.jsonp,forceBase64:n.forceBase64||this.forceBase64,enablesXDR:n.enablesXDR||this.enablesXDR,withCredentials:n.withCredentials||this.withCredentials,timestampRequests:n.timestampRequests||this.timestampRequests,timestampParam:n.timestampParam||this.timestampParam,policyPort:n.policyPort||this.policyPort,pfx:n.pfx||this.pfx,key:n.key||this.key,passphrase:n.passphrase||this.passphrase,cert:n.cert||this.cert,ca:n.ca||this.ca,ciphers:n.ciphers||this.ciphers,rejectUnauthorized:n.rejectUnauthorized||this.rejectUnauthorized,perMessageDeflate:n.perMessageDeflate||this.perMessageDeflate,extraHeaders:n.extraHeaders||this.extraHeaders,forceNode:n.forceNode||this.forceNode,localAddress:n.localAddress||this.localAddress,requestTimeout:n.requestTimeout||this.requestTimeout,protocols:n.protocols||void 0,isReactNative:this.isReactNative})},f.prototype.open=function(){var e;if(this.rememberUpgrade&&f.priorWebsocketSuccess&&-1!==this.transports.indexOf("websocket"))e="websocket";else{if(0===this.transports.length){var t=this;return void setTimeout((function(){t.emit("error","No transports available")}),0)}e=this.transports[0]}this.readyState="opening";try{e=this.createTransport(e)}catch(e){return this.transports.shift(),void this.open()}e.open(),this.setTransport(e)},f.prototype.setTransport=function(e){i("setting transport %s",e.name);var t=this;this.transport&&(i("clearing existing transport %s",this.transport.name),this.transport.removeAllListeners()),this.transport=e,e.on("drain",(function(){t.onDrain()})).on("packet",(function(e){t.onPacket(e)})).on("error",(function(e){t.onError(e)})).on("close",(function(){t.onClose("transport close")}))},f.prototype.probe=function(e){i('probing transport "%s"',e);var t=this.createTransport(e,{probe:1}),n=!1,r=this;function o(){if(r.onlyBinaryUpgrades){var o=!this.supportsBinary&&r.transport.supportsBinary;n=n||o}n||(i('probe transport "%s" opened',e),t.send([{type:"ping",data:"probe"}]),t.once("packet",(function(o){if(!n)if("pong"===o.type&&"probe"===o.data){if(i('probe transport "%s" pong',e),r.upgrading=!0,r.emit("upgrading",t),!t)return;f.priorWebsocketSuccess="websocket"===t.name,i('pausing current transport "%s"',r.transport.name),r.transport.pause((function(){n||"closed"!==r.readyState&&(i("changing transport and sending upgrade packet"),h(),r.setTransport(t),t.send([{type:"upgrade"}]),r.emit("upgrade",t),t=null,r.upgrading=!1,r.flush())}))}else{i('probe transport "%s" failed',e);var s=new Error("probe error");s.transport=t.name,r.emit("upgradeError",s)}})))}function s(){n||(n=!0,h(),t.close(),t=null)}function a(n){var o=new Error("probe error: "+n);o.transport=t.name,s(),i('probe transport "%s" failed because of error: %s',e,n),r.emit("upgradeError",o)}function c(){a("transport closed")}function u(){a("socket closed")}function l(e){t&&e.name!==t.name&&(i('"%s" works - aborting "%s"',e.name,t.name),s())}function h(){t.removeListener("open",o),t.removeListener("error",a),t.removeListener("close",c),r.removeListener("close",u),r.removeListener("upgrading",l)}f.priorWebsocketSuccess=!1,t.once("open",o),t.once("error",a),t.once("close",c),this.once("close",u),this.once("upgrading",l),t.open()},f.prototype.onOpen=function(){if(i("socket open"),this.readyState="open",f.priorWebsocketSuccess="websocket"===this.transport.name,this.emit("open"),this.flush(),"open"===this.readyState&&this.upgrade&&this.transport.pause){i("starting upgrade probes");for(var e=0,t=this.upgrades.length;e<t;e++)this.probe(this.upgrades[e])}},f.prototype.onPacket=function(e){if("opening"===this.readyState||"open"===this.readyState||"closing"===this.readyState)switch(i('socket receive: type "%s", data "%s"',e.type,e.data),this.emit("packet",e),this.emit("heartbeat"),e.type){case"open":this.onHandshake(JSON.parse(e.data));break;case"pong":this.setPing(),this.emit("pong");break;case"error":var t=new Error("server error");t.code=e.data,this.onError(t);break;case"message":this.emit("data",e.data),this.emit("message",e.data)}else i('packet received with socket readyState "%s"',this.readyState)},f.prototype.onHandshake=function(e){this.emit("handshake",e),this.id=e.sid,this.transport.query.sid=e.sid,this.upgrades=this.filterUpgrades(e.upgrades),this.pingInterval=e.pingInterval,this.pingTimeout=e.pingTimeout,this.onOpen(),"closed"!==this.readyState&&(this.setPing(),this.removeListener("heartbeat",this.onHeartbeat),this.on("heartbeat",this.onHeartbeat))},f.prototype.onHeartbeat=function(e){clearTimeout(this.pingTimeoutTimer);var t=this;t.pingTimeoutTimer=setTimeout((function(){"closed"!==t.readyState&&t.onClose("ping timeout")}),e||t.pingInterval+t.pingTimeout)},f.prototype.setPing=function(){var e=this;clearTimeout(e.pingIntervalTimer),e.pingIntervalTimer=setTimeout((function(){i("writing ping packet - expecting pong within %sms",e.pingTimeout),e.ping(),e.onHeartbeat(e.pingTimeout)}),e.pingInterval)},f.prototype.ping=function(){var e=this;this.sendPacket("ping",(function(){e.emit("ping")}))},f.prototype.onDrain=function(){this.writeBuffer.splice(0,this.prevBufferLen),this.prevBufferLen=0,0===this.writeBuffer.length?this.emit("drain"):this.flush()},f.prototype.flush=function(){"closed"!==this.readyState&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length&&(i("flushing %d packets in socket",this.writeBuffer.length),this.transport.send(this.writeBuffer),this.prevBufferLen=this.writeBuffer.length,this.emit("flush"))},f.prototype.write=f.prototype.send=function(e,t,n){return this.sendPacket("message",e,t,n),this},f.prototype.sendPacket=function(e,t,n,r){if("function"==typeof t&&(r=t,t=void 0),"function"==typeof n&&(r=n,n=null),"closing"!==this.readyState&&"closed"!==this.readyState){(n=n||{}).compress=!1!==n.compress;var o={type:e,data:t,options:n};this.emit("packetCreate",o),this.writeBuffer.push(o),r&&this.once("flush",r),this.flush()}},f.prototype.close=function(){if("opening"===this.readyState||"open"===this.readyState){this.readyState="closing";var e=this;this.writeBuffer.length?this.once("drain",(function(){this.upgrading?r():t()})):this.upgrading?r():t()}function t(){e.onClose("forced close"),i("socket closing - telling transport to close"),e.transport.close()}function n(){e.removeListener("upgrade",n),e.removeListener("upgradeError",n),t()}function r(){e.once("upgrade",n),e.once("upgradeError",n)}return this},f.prototype.onError=function(e){i("socket error %j",e),f.priorWebsocketSuccess=!1,this.emit("error",e),this.onClose("transport error",e)},f.prototype.onClose=function(e,t){if("opening"===this.readyState||"open"===this.readyState||"closing"===this.readyState){i('socket close with reason: "%s"',e);clearTimeout(this.pingIntervalTimer),clearTimeout(this.pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),this.readyState="closed",this.id=null,this.emit("close",e,t),this.writeBuffer=[],this.prevBufferLen=0}},f.prototype.filterUpgrades=function(e){for(var t=[],n=0,r=e.length;n<r;n++)~s(this.transports,e[n])&&t.push(e[n]);return t}},function(e,t){try{e.exports="undefined"!=typeof XMLHttpRequest&&"withCredentials"in new XMLHttpRequest}catch(t){e.exports=!1}},function(e,t,n){var r=n(11),o=n(22),i=n(14),s=n(5),a=n(6)("engine.io-client:polling-xhr"),c=n(12);function u(){}function f(e){if(o.call(this,e),this.requestTimeout=e.requestTimeout,this.extraHeaders=e.extraHeaders,"undefined"!=typeof location){var t="https:"===location.protocol,n=location.port;n||(n=t?443:80),this.xd="undefined"!=typeof location&&e.hostname!==location.hostname||n!==e.port,this.xs=e.secure!==t}}function l(e){this.method=e.method||"GET",this.uri=e.uri,this.xd=!!e.xd,this.xs=!!e.xs,this.async=!1!==e.async,this.data=void 0!==e.data?e.data:null,this.agent=e.agent,this.isBinary=e.isBinary,this.supportsBinary=e.supportsBinary,this.enablesXDR=e.enablesXDR,this.withCredentials=e.withCredentials,this.requestTimeout=e.requestTimeout,this.pfx=e.pfx,this.key=e.key,this.passphrase=e.passphrase,this.cert=e.cert,this.ca=e.ca,this.ciphers=e.ciphers,this.rejectUnauthorized=e.rejectUnauthorized,this.extraHeaders=e.extraHeaders,this.create()}if(e.exports=f,e.exports.Request=l,s(f,o),f.prototype.supportsBinary=!0,f.prototype.request=function(e){return(e=e||{}).uri=this.uri(),e.xd=this.xd,e.xs=this.xs,e.agent=this.agent||!1,e.supportsBinary=this.supportsBinary,e.enablesXDR=this.enablesXDR,e.withCredentials=this.withCredentials,e.pfx=this.pfx,e.key=this.key,e.passphrase=this.passphrase,e.cert=this.cert,e.ca=this.ca,e.ciphers=this.ciphers,e.rejectUnauthorized=this.rejectUnauthorized,e.requestTimeout=this.requestTimeout,e.extraHeaders=this.extraHeaders,new l(e)},f.prototype.doWrite=function(e,t){var n="string"!=typeof e&&void 0!==e,r=this.request({method:"POST",data:e,isBinary:n}),o=this;r.on("success",t),r.on("error",(function(e){o.onError("xhr post error",e)})),this.sendXhr=r},f.prototype.doPoll=function(){a("xhr poll");var e=this.request(),t=this;e.on("data",(function(e){t.onData(e)})),e.on("error",(function(e){t.onError("xhr poll error",e)})),this.pollXhr=e},i(l.prototype),l.prototype.create=function(){var e={agent:this.agent,xdomain:this.xd,xscheme:this.xs,enablesXDR:this.enablesXDR};e.pfx=this.pfx,e.key=this.key,e.passphrase=this.passphrase,e.cert=this.cert,e.ca=this.ca,e.ciphers=this.ciphers,e.rejectUnauthorized=this.rejectUnauthorized;var t=this.xhr=new r(e),n=this;try{a("xhr open %s: %s",this.method,this.uri),t.open(this.method,this.uri,this.async);try{if(this.extraHeaders)for(var o in t.setDisableHeaderCheck&&t.setDisableHeaderCheck(!0),this.extraHeaders)this.extraHeaders.hasOwnProperty(o)&&t.setRequestHeader(o,this.extraHeaders[o])}catch(e){}if("POST"===this.method)try{this.isBinary?t.setRequestHeader("Content-type","application/octet-stream"):t.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch(e){}try{t.setRequestHeader("Accept","*/*")}catch(e){}"withCredentials"in t&&(t.withCredentials=this.withCredentials),this.requestTimeout&&(t.timeout=this.requestTimeout),this.hasXDR()?(t.onload=function(){n.onLoad()},t.onerror=function(){n.onError(t.responseText)}):t.onreadystatechange=function(){if(2===t.readyState)try{var e=t.getResponseHeader("Content-Type");(n.supportsBinary&&"application/octet-stream"===e||"application/octet-stream; charset=UTF-8"===e)&&(t.responseType="arraybuffer")}catch(e){}4===t.readyState&&(200===t.status||1223===t.status?n.onLoad():setTimeout((function(){n.onError("number"==typeof t.status?t.status:0)}),0))},a("xhr data %s",this.data),t.send(this.data)}catch(e){return void setTimeout((function(){n.onError(e)}),0)}"undefined"!=typeof document&&(this.index=l.requestsCount++,l.requests[this.index]=this)},l.prototype.onSuccess=function(){this.emit("success"),this.cleanup()},l.prototype.onData=function(e){this.emit("data",e),this.onSuccess()},l.prototype.onError=function(e){this.emit("error",e),this.cleanup(!0)},l.prototype.cleanup=function(e){if(void 0!==this.xhr&&null!==this.xhr){if(this.hasXDR()?this.xhr.onload=this.xhr.onerror=u:this.xhr.onreadystatechange=u,e)try{this.xhr.abort()}catch(e){}"undefined"!=typeof document&&delete l.requests[this.index],this.xhr=null}},l.prototype.onLoad=function(){var e;try{var t;try{t=this.xhr.getResponseHeader("Content-Type")}catch(e){}e=("application/octet-stream"===t||"application/octet-stream; charset=UTF-8"===t)&&this.xhr.response||this.xhr.responseText}catch(e){this.onError(e)}null!=e&&this.onData(e)},l.prototype.hasXDR=function(){return"undefined"!=typeof XDomainRequest&&!this.xs&&this.enablesXDR},l.prototype.abort=function(){this.cleanup()},l.requestsCount=0,l.requests={},"undefined"!=typeof document)if("function"==typeof attachEvent)attachEvent("onunload",h);else if("function"==typeof addEventListener){addEventListener("onpagehide"in c?"pagehide":"unload",h,!1)}function h(){for(var e in l.requests)l.requests.hasOwnProperty(e)&&l.requests[e].abort()}},function(e,t){e.exports=Object.keys||function(e){var t=[],n=Object.prototype.hasOwnProperty;for(var r in e)n.call(e,r)&&t.push(r);return t}},function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},function(e,t){e.exports=function(e,t,n){var r=e.byteLength;if(t=t||0,n=n||r,e.slice)return e.slice(t,n);if(t<0&&(t+=r),n<0&&(n+=r),n>r&&(n=r),t>=r||t>=n||0===r)return new ArrayBuffer(0);for(var o=new Uint8Array(e),i=new Uint8Array(n-t),s=t,a=0;s<n;s++,a++)i[a]=o[s];return i.buffer}},function(e,t){function n(){}e.exports=function(e,t,r){var o=!1;return r=r||n,i.count=e,0===e?t():i;function i(e,n){if(i.count<=0)throw new Error("after called too many times");--i.count,e?(o=!0,t(e),t=r):0!==i.count||o||t(null,n)}}},function(e,t){
+var r=n(38),o=n(39),i=n(40);function s(){return c.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function a(e,t){if(s()<t)throw new RangeError("Invalid typed array length");return c.TYPED_ARRAY_SUPPORT?(e=new Uint8Array(t)).__proto__=c.prototype:(null===e&&(e=new c(t)),e.length=t),e}function c(e,t,n){if(!(c.TYPED_ARRAY_SUPPORT||this instanceof c))return new c(e,t,n);if("number"==typeof e){if("string"==typeof t)throw new Error("If encoding is specified then the first argument must be a string");return l(this,e)}return u(this,e,t,n)}function u(e,t,n,r){if("number"==typeof t)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&t instanceof ArrayBuffer?function(e,t,n,r){if(t.byteLength,n<0||t.byteLength<n)throw new RangeError("'offset' is out of bounds");if(t.byteLength<n+(r||0))throw new RangeError("'length' is out of bounds");t=void 0===n&&void 0===r?new Uint8Array(t):void 0===r?new Uint8Array(t,n):new Uint8Array(t,n,r);c.TYPED_ARRAY_SUPPORT?(e=t).__proto__=c.prototype:e=h(e,t);return e}(e,t,n,r):"string"==typeof t?function(e,t,n){"string"==typeof n&&""!==n||(n="utf8");if(!c.isEncoding(n))throw new TypeError('"encoding" must be a valid string encoding');var r=0|d(t,n),o=(e=a(e,r)).write(t,n);o!==r&&(e=e.slice(0,o));return e}(e,t,n):function(e,t){if(c.isBuffer(t)){var n=0|p(t.length);return 0===(e=a(e,n)).length||t.copy(e,0,0,n),e}if(t){if("undefined"!=typeof ArrayBuffer&&t.buffer instanceof ArrayBuffer||"length"in t)return"number"!=typeof t.length||(r=t.length)!=r?a(e,0):h(e,t);if("Buffer"===t.type&&i(t.data))return h(e,t.data)}var r;throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(e,t)}function f(e){if("number"!=typeof e)throw new TypeError('"size" argument must be a number');if(e<0)throw new RangeError('"size" argument must not be negative')}function l(e,t){if(f(t),e=a(e,t<0?0:0|p(t)),!c.TYPED_ARRAY_SUPPORT)for(var n=0;n<t;++n)e[n]=0;return e}function h(e,t){var n=t.length<0?0:0|p(t.length);e=a(e,n);for(var r=0;r<n;r+=1)e[r]=255&t[r];return e}function p(e){if(e>=s())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s().toString(16)+" bytes");return 0|e}function d(e,t){if(c.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var n=e.length;if(0===n)return 0;for(var r=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":case void 0:return U(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return q(e).length;default:if(r)return U(e).length;t=(""+t).toLowerCase(),r=!0}}function y(e,t,n){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if((n>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return O(this,t,n);case"utf8":case"utf-8":return S(this,t,n);case"ascii":return x(this,t,n);case"latin1":case"binary":return R(this,t,n);case"base64":return A(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return T(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function g(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function m(e,t,n,r,o){if(0===e.length)return-1;if("string"==typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,isNaN(n)&&(n=o?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(o)return-1;n=e.length-1}else if(n<0){if(!o)return-1;n=0}if("string"==typeof t&&(t=c.from(t,r)),c.isBuffer(t))return 0===t.length?-1:v(e,t,n,r,o);if("number"==typeof t)return t&=255,c.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):v(e,[t],n,r,o);throw new TypeError("val must be string, number or Buffer")}function v(e,t,n,r,o){var i,s=1,a=e.length,c=t.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;s=2,a/=2,c/=2,n/=2}function u(e,t){return 1===s?e[t]:e.readUInt16BE(t*s)}if(o){var f=-1;for(i=n;i<a;i++)if(u(e,i)===u(t,-1===f?0:i-f)){if(-1===f&&(f=i),i-f+1===c)return f*s}else-1!==f&&(i-=i-f),f=-1}else for(n+c>a&&(n=a-c),i=n;i>=0;i--){for(var l=!0,h=0;h<c;h++)if(u(e,i+h)!==u(t,h)){l=!1;break}if(l)return i}return-1}function b(e,t,n,r){n=Number(n)||0;var o=e.length-n;r?(r=Number(r))>o&&(r=o):r=o;var i=t.length;if(i%2!=0)throw new TypeError("Invalid hex string");r>i/2&&(r=i/2);for(var s=0;s<r;++s){var a=parseInt(t.substr(2*s,2),16);if(isNaN(a))return s;e[n+s]=a}return s}function w(e,t,n,r){return z(U(t,e.length-n),e,n,r)}function C(e,t,n,r){return z(function(e){for(var t=[],n=0;n<e.length;++n)t.push(255&e.charCodeAt(n));return t}(t),e,n,r)}function k(e,t,n,r){return C(e,t,n,r)}function _(e,t,n,r){return z(q(t),e,n,r)}function E(e,t,n,r){return z(function(e,t){for(var n,r,o,i=[],s=0;s<e.length&&!((t-=2)<0);++s)n=e.charCodeAt(s),r=n>>8,o=n%256,i.push(o),i.push(r);return i}(t,e.length-n),e,n,r)}function A(e,t,n){return 0===t&&n===e.length?r.fromByteArray(e):r.fromByteArray(e.slice(t,n))}function S(e,t,n){n=Math.min(e.length,n);for(var r=[],o=t;o<n;){var i,s,a,c,u=e[o],f=null,l=u>239?4:u>223?3:u>191?2:1;if(o+l<=n)switch(l){case 1:u<128&&(f=u);break;case 2:128==(192&(i=e[o+1]))&&(c=(31&u)<<6|63&i)>127&&(f=c);break;case 3:i=e[o+1],s=e[o+2],128==(192&i)&&128==(192&s)&&(c=(15&u)<<12|(63&i)<<6|63&s)>2047&&(c<55296||c>57343)&&(f=c);break;case 4:i=e[o+1],s=e[o+2],a=e[o+3],128==(192&i)&&128==(192&s)&&128==(192&a)&&(c=(15&u)<<18|(63&i)<<12|(63&s)<<6|63&a)>65535&&c<1114112&&(f=c)}null===f?(f=65533,l=1):f>65535&&(f-=65536,r.push(f>>>10&1023|55296),f=56320|1023&f),r.push(f),o+=l}return function(e){var t=e.length;if(t<=4096)return String.fromCharCode.apply(String,e);var n="",r=0;for(;r<t;)n+=String.fromCharCode.apply(String,e.slice(r,r+=4096));return n}(r)}t.Buffer=c,t.SlowBuffer=function(e){+e!=e&&(e=0);return c.alloc(+e)},t.INSPECT_MAX_BYTES=50,c.TYPED_ARRAY_SUPPORT=void 0!==e.TYPED_ARRAY_SUPPORT?e.TYPED_ARRAY_SUPPORT:function(){try{var e=new Uint8Array(1);return e.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===e.foo()&&"function"==typeof e.subarray&&0===e.subarray(1,1).byteLength}catch(e){return!1}}(),t.kMaxLength=s(),c.poolSize=8192,c._augment=function(e){return e.__proto__=c.prototype,e},c.from=function(e,t,n){return u(null,e,t,n)},c.TYPED_ARRAY_SUPPORT&&(c.prototype.__proto__=Uint8Array.prototype,c.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&c[Symbol.species]===c&&Object.defineProperty(c,Symbol.species,{value:null,configurable:!0})),c.alloc=function(e,t,n){return function(e,t,n,r){return f(t),t<=0?a(e,t):void 0!==n?"string"==typeof r?a(e,t).fill(n,r):a(e,t).fill(n):a(e,t)}(null,e,t,n)},c.allocUnsafe=function(e){return l(null,e)},c.allocUnsafeSlow=function(e){return l(null,e)},c.isBuffer=function(e){return!(null==e||!e._isBuffer)},c.compare=function(e,t){if(!c.isBuffer(e)||!c.isBuffer(t))throw new TypeError("Arguments must be Buffers");if(e===t)return 0;for(var n=e.length,r=t.length,o=0,i=Math.min(n,r);o<i;++o)if(e[o]!==t[o]){n=e[o],r=t[o];break}return n<r?-1:r<n?1:0},c.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},c.concat=function(e,t){if(!i(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return c.alloc(0);var n;if(void 0===t)for(t=0,n=0;n<e.length;++n)t+=e[n].length;var r=c.allocUnsafe(t),o=0;for(n=0;n<e.length;++n){var s=e[n];if(!c.isBuffer(s))throw new TypeError('"list" argument must be an Array of Buffers');s.copy(r,o),o+=s.length}return r},c.byteLength=d,c.prototype._isBuffer=!0,c.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)g(this,t,t+1);return this},c.prototype.swap32=function(){var e=this.length;if(e%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)g(this,t,t+3),g(this,t+1,t+2);return this},c.prototype.swap64=function(){var e=this.length;if(e%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)g(this,t,t+7),g(this,t+1,t+6),g(this,t+2,t+5),g(this,t+3,t+4);return this},c.prototype.toString=function(){var e=0|this.length;return 0===e?"":0===arguments.length?S(this,0,e):y.apply(this,arguments)},c.prototype.equals=function(e){if(!c.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===c.compare(this,e)},c.prototype.inspect=function(){var e="",n=t.INSPECT_MAX_BYTES;return this.length>0&&(e=this.toString("hex",0,n).match(/.{2}/g).join(" "),this.length>n&&(e+=" ... ")),"<Buffer "+e+">"},c.prototype.compare=function(e,t,n,r,o){if(!c.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===r&&(r=0),void 0===o&&(o=this.length),t<0||n>e.length||r<0||o>this.length)throw new RangeError("out of range index");if(r>=o&&t>=n)return 0;if(r>=o)return-1;if(t>=n)return 1;if(this===e)return 0;for(var i=(o>>>=0)-(r>>>=0),s=(n>>>=0)-(t>>>=0),a=Math.min(i,s),u=this.slice(r,o),f=e.slice(t,n),l=0;l<a;++l)if(u[l]!==f[l]){i=u[l],s=f[l];break}return i<s?-1:s<i?1:0},c.prototype.includes=function(e,t,n){return-1!==this.indexOf(e,t,n)},c.prototype.indexOf=function(e,t,n){return m(this,e,t,n,!0)},c.prototype.lastIndexOf=function(e,t,n){return m(this,e,t,n,!1)},c.prototype.write=function(e,t,n,r){if(void 0===t)r="utf8",n=this.length,t=0;else if(void 0===n&&"string"==typeof t)r=t,n=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t|=0,isFinite(n)?(n|=0,void 0===r&&(r="utf8")):(r=n,n=void 0)}var o=this.length-t;if((void 0===n||n>o)&&(n=o),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var i=!1;;)switch(r){case"hex":return b(this,e,t,n);case"utf8":case"utf-8":return w(this,e,t,n);case"ascii":return C(this,e,t,n);case"latin1":case"binary":return k(this,e,t,n);case"base64":return _(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return E(this,e,t,n);default:if(i)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),i=!0}},c.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function x(e,t,n){var r="";n=Math.min(e.length,n);for(var o=t;o<n;++o)r+=String.fromCharCode(127&e[o]);return r}function R(e,t,n){var r="";n=Math.min(e.length,n);for(var o=t;o<n;++o)r+=String.fromCharCode(e[o]);return r}function O(e,t,n){var r=e.length;(!t||t<0)&&(t=0),(!n||n<0||n>r)&&(n=r);for(var o="",i=t;i<n;++i)o+=L(e[i]);return o}function T(e,t,n){for(var r=e.slice(t,n),o="",i=0;i<r.length;i+=2)o+=String.fromCharCode(r[i]+256*r[i+1]);return o}function F(e,t,n){if(e%1!=0||e<0)throw new RangeError("offset is not uint");if(e+t>n)throw new RangeError("Trying to access beyond buffer length")}function P(e,t,n,r,o,i){if(!c.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>o||t<i)throw new RangeError('"value" argument is out of bounds');if(n+r>e.length)throw new RangeError("Index out of range")}function B(e,t,n,r){t<0&&(t=65535+t+1);for(var o=0,i=Math.min(e.length-n,2);o<i;++o)e[n+o]=(t&255<<8*(r?o:1-o))>>>8*(r?o:1-o)}function N(e,t,n,r){t<0&&(t=4294967295+t+1);for(var o=0,i=Math.min(e.length-n,4);o<i;++o)e[n+o]=t>>>8*(r?o:3-o)&255}function j(e,t,n,r,o,i){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function M(e,t,n,r,i){return i||j(e,0,n,4),o.write(e,t,n,r,23,4),n+4}function I(e,t,n,r,i){return i||j(e,0,n,8),o.write(e,t,n,r,52,8),n+8}c.prototype.slice=function(e,t){var n,r=this.length;if((e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t<e&&(t=e),c.TYPED_ARRAY_SUPPORT)(n=this.subarray(e,t)).__proto__=c.prototype;else{var o=t-e;n=new c(o,void 0);for(var i=0;i<o;++i)n[i]=this[i+e]}return n},c.prototype.readUIntLE=function(e,t,n){e|=0,t|=0,n||F(e,t,this.length);for(var r=this[e],o=1,i=0;++i<t&&(o*=256);)r+=this[e+i]*o;return r},c.prototype.readUIntBE=function(e,t,n){e|=0,t|=0,n||F(e,t,this.length);for(var r=this[e+--t],o=1;t>0&&(o*=256);)r+=this[e+--t]*o;return r},c.prototype.readUInt8=function(e,t){return t||F(e,1,this.length),this[e]},c.prototype.readUInt16LE=function(e,t){return t||F(e,2,this.length),this[e]|this[e+1]<<8},c.prototype.readUInt16BE=function(e,t){return t||F(e,2,this.length),this[e]<<8|this[e+1]},c.prototype.readUInt32LE=function(e,t){return t||F(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},c.prototype.readUInt32BE=function(e,t){return t||F(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},c.prototype.readIntLE=function(e,t,n){e|=0,t|=0,n||F(e,t,this.length);for(var r=this[e],o=1,i=0;++i<t&&(o*=256);)r+=this[e+i]*o;return r>=(o*=128)&&(r-=Math.pow(2,8*t)),r},c.prototype.readIntBE=function(e,t,n){e|=0,t|=0,n||F(e,t,this.length);for(var r=t,o=1,i=this[e+--r];r>0&&(o*=256);)i+=this[e+--r]*o;return i>=(o*=128)&&(i-=Math.pow(2,8*t)),i},c.prototype.readInt8=function(e,t){return t||F(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},c.prototype.readInt16LE=function(e,t){t||F(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},c.prototype.readInt16BE=function(e,t){t||F(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},c.prototype.readInt32LE=function(e,t){return t||F(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},c.prototype.readInt32BE=function(e,t){return t||F(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},c.prototype.readFloatLE=function(e,t){return t||F(e,4,this.length),o.read(this,e,!0,23,4)},c.prototype.readFloatBE=function(e,t){return t||F(e,4,this.length),o.read(this,e,!1,23,4)},c.prototype.readDoubleLE=function(e,t){return t||F(e,8,this.length),o.read(this,e,!0,52,8)},c.prototype.readDoubleBE=function(e,t){return t||F(e,8,this.length),o.read(this,e,!1,52,8)},c.prototype.writeUIntLE=function(e,t,n,r){(e=+e,t|=0,n|=0,r)||P(this,e,t,n,Math.pow(2,8*n)-1,0);var o=1,i=0;for(this[t]=255&e;++i<n&&(o*=256);)this[t+i]=e/o&255;return t+n},c.prototype.writeUIntBE=function(e,t,n,r){(e=+e,t|=0,n|=0,r)||P(this,e,t,n,Math.pow(2,8*n)-1,0);var o=n-1,i=1;for(this[t+o]=255&e;--o>=0&&(i*=256);)this[t+o]=e/i&255;return t+n},c.prototype.writeUInt8=function(e,t,n){return e=+e,t|=0,n||P(this,e,t,1,255,0),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},c.prototype.writeUInt16LE=function(e,t,n){return e=+e,t|=0,n||P(this,e,t,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):B(this,e,t,!0),t+2},c.prototype.writeUInt16BE=function(e,t,n){return e=+e,t|=0,n||P(this,e,t,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):B(this,e,t,!1),t+2},c.prototype.writeUInt32LE=function(e,t,n){return e=+e,t|=0,n||P(this,e,t,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):N(this,e,t,!0),t+4},c.prototype.writeUInt32BE=function(e,t,n){return e=+e,t|=0,n||P(this,e,t,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):N(this,e,t,!1),t+4},c.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t|=0,!r){var o=Math.pow(2,8*n-1);P(this,e,t,n,o-1,-o)}var i=0,s=1,a=0;for(this[t]=255&e;++i<n&&(s*=256);)e<0&&0===a&&0!==this[t+i-1]&&(a=1),this[t+i]=(e/s>>0)-a&255;return t+n},c.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t|=0,!r){var o=Math.pow(2,8*n-1);P(this,e,t,n,o-1,-o)}var i=n-1,s=1,a=0;for(this[t+i]=255&e;--i>=0&&(s*=256);)e<0&&0===a&&0!==this[t+i+1]&&(a=1),this[t+i]=(e/s>>0)-a&255;return t+n},c.prototype.writeInt8=function(e,t,n){return e=+e,t|=0,n||P(this,e,t,1,127,-128),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},c.prototype.writeInt16LE=function(e,t,n){return e=+e,t|=0,n||P(this,e,t,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):B(this,e,t,!0),t+2},c.prototype.writeInt16BE=function(e,t,n){return e=+e,t|=0,n||P(this,e,t,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):B(this,e,t,!1),t+2},c.prototype.writeInt32LE=function(e,t,n){return e=+e,t|=0,n||P(this,e,t,4,2147483647,-2147483648),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):N(this,e,t,!0),t+4},c.prototype.writeInt32BE=function(e,t,n){return e=+e,t|=0,n||P(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):N(this,e,t,!1),t+4},c.prototype.writeFloatLE=function(e,t,n){return M(this,e,t,!0,n)},c.prototype.writeFloatBE=function(e,t,n){return M(this,e,t,!1,n)},c.prototype.writeDoubleLE=function(e,t,n){return I(this,e,t,!0,n)},c.prototype.writeDoubleBE=function(e,t,n){return I(this,e,t,!1,n)},c.prototype.copy=function(e,t,n,r){if(n||(n=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r<n&&(r=n),r===n)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(n<0||n>=this.length)throw new RangeError("sourceStart out of bounds");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t<r-n&&(r=e.length-t+n);var o,i=r-n;if(this===e&&n<t&&t<r)for(o=i-1;o>=0;--o)e[o+t]=this[o+n];else if(i<1e3||!c.TYPED_ARRAY_SUPPORT)for(o=0;o<i;++o)e[o+t]=this[o+n];else Uint8Array.prototype.set.call(e,this.subarray(n,n+i),t);return i},c.prototype.fill=function(e,t,n,r){if("string"==typeof e){if("string"==typeof t?(r=t,t=0,n=this.length):"string"==typeof n&&(r=n,n=this.length),1===e.length){var o=e.charCodeAt(0);o<256&&(e=o)}if(void 0!==r&&"string"!=typeof r)throw new TypeError("encoding must be a string");if("string"==typeof r&&!c.isEncoding(r))throw new TypeError("Unknown encoding: "+r)}else"number"==typeof e&&(e&=255);if(t<0||this.length<t||this.length<n)throw new RangeError("Out of range index");if(n<=t)return this;var i;if(t>>>=0,n=void 0===n?this.length:n>>>0,e||(e=0),"number"==typeof e)for(i=t;i<n;++i)this[i]=e;else{var s=c.isBuffer(e)?e:U(new c(e,r).toString()),a=s.length;for(i=0;i<n-t;++i)this[i+t]=s[i%a]}return this};var D=/[^+\/0-9A-Za-z-_]/g;function L(e){return e<16?"0"+e.toString(16):e.toString(16)}function U(e,t){var n;t=t||1/0;for(var r=e.length,o=null,i=[],s=0;s<r;++s){if((n=e.charCodeAt(s))>55295&&n<57344){if(!o){if(n>56319){(t-=3)>-1&&i.push(239,191,189);continue}if(s+1===r){(t-=3)>-1&&i.push(239,191,189);continue}o=n;continue}if(n<56320){(t-=3)>-1&&i.push(239,191,189),o=n;continue}n=65536+(o-55296<<10|n-56320)}else o&&(t-=3)>-1&&i.push(239,191,189);if(o=null,n<128){if((t-=1)<0)break;i.push(n)}else if(n<2048){if((t-=2)<0)break;i.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;i.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;i.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return i}function q(e){return r.toByteArray(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(D,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function z(e,t,n,r){for(var o=0;o<r&&!(o+n>=t.length||o>=e.length);++o)t[o+n]=e[o];return o}}).call(this,n(0))},function(e,t,n){"use strict";t.byteLength=function(e){var t=u(e),n=t[0],r=t[1];return 3*(n+r)/4-r},t.toByteArray=function(e){var t,n,r=u(e),s=r[0],a=r[1],c=new i(function(e,t,n){return 3*(t+n)/4-n}(0,s,a)),f=0,l=a>0?s-4:s;for(n=0;n<l;n+=4)t=o[e.charCodeAt(n)]<<18|o[e.charCodeAt(n+1)]<<12|o[e.charCodeAt(n+2)]<<6|o[e.charCodeAt(n+3)],c[f++]=t>>16&255,c[f++]=t>>8&255,c[f++]=255&t;2===a&&(t=o[e.charCodeAt(n)]<<2|o[e.charCodeAt(n+1)]>>4,c[f++]=255&t);1===a&&(t=o[e.charCodeAt(n)]<<10|o[e.charCodeAt(n+1)]<<4|o[e.charCodeAt(n+2)]>>2,c[f++]=t>>8&255,c[f++]=255&t);return c},t.fromByteArray=function(e){for(var t,n=e.length,o=n%3,i=[],s=0,a=n-o;s<a;s+=16383)i.push(f(e,s,s+16383>a?a:s+16383));1===o?(t=e[n-1],i.push(r[t>>2]+r[t<<4&63]+"==")):2===o&&(t=(e[n-2]<<8)+e[n-1],i.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"="));return i.join("")};for(var r=[],o=[],i="undefined"!=typeof Uint8Array?Uint8Array:Array,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,c=s.length;a<c;++a)r[a]=s[a],o[s.charCodeAt(a)]=a;function u(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");return-1===n&&(n=t),[n,n===t?0:4-n%4]}function f(e,t,n){for(var o,i,s=[],a=t;a<n;a+=3)o=(e[a]<<16&16711680)+(e[a+1]<<8&65280)+(255&e[a+2]),s.push(r[(i=o)>>18&63]+r[i>>12&63]+r[i>>6&63]+r[63&i]);return s.join("")}o["-".charCodeAt(0)]=62,o["_".charCodeAt(0)]=63},function(e,t){
+/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */
+t.read=function(e,t,n,r,o){var i,s,a=8*o-r-1,c=(1<<a)-1,u=c>>1,f=-7,l=n?o-1:0,h=n?-1:1,p=e[t+l];for(l+=h,i=p&(1<<-f)-1,p>>=-f,f+=a;f>0;i=256*i+e[t+l],l+=h,f-=8);for(s=i&(1<<-f)-1,i>>=-f,f+=r;f>0;s=256*s+e[t+l],l+=h,f-=8);if(0===i)i=1-u;else{if(i===c)return s?NaN:1/0*(p?-1:1);s+=Math.pow(2,r),i-=u}return(p?-1:1)*s*Math.pow(2,i-r)},t.write=function(e,t,n,r,o,i){var s,a,c,u=8*i-o-1,f=(1<<u)-1,l=f>>1,h=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,p=r?0:i-1,d=r?1:-1,y=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(a=isNaN(t)?1:0,s=f):(s=Math.floor(Math.log(t)/Math.LN2),t*(c=Math.pow(2,-s))<1&&(s--,c*=2),(t+=s+l>=1?h/c:h*Math.pow(2,1-l))*c>=2&&(s++,c/=2),s+l>=f?(a=0,s=f):s+l>=1?(a=(t*c-1)*Math.pow(2,o),s+=l):(a=t*Math.pow(2,l-1)*Math.pow(2,o),s=0));o>=8;e[n+p]=255&a,p+=d,a/=256,o-=8);for(s=s<<o|a,u+=o;u>0;e[n+p]=255&s,p+=d,s/=256,u-=8);e[n+p-d]|=128*y}},function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},function(e,t,n){(function(e){var r=n(16),o=n(17),i=Object.prototype.toString,s="function"==typeof e.Blob||"[object BlobConstructor]"===i.call(e.Blob),a="function"==typeof e.File||"[object FileConstructor]"===i.call(e.File);t.deconstructPacket=function(e){var t=[],n=e.data,i=e;return i.data=function e(t,n){if(!t)return t;if(o(t)){var i={_placeholder:!0,num:n.length};return n.push(t),i}if(r(t)){for(var s=new Array(t.length),a=0;a<t.length;a++)s[a]=e(t[a],n);return s}if("object"==typeof t&&!(t instanceof Date)){s={};for(var c in t)s[c]=e(t[c],n);return s}return t}(n,t),i.attachments=t.length,{packet:i,buffers:t}},t.reconstructPacket=function(e,t){return e.data=function e(t,n){if(!t)return t;if(t&&t._placeholder)return n[t.num];if(r(t))for(var o=0;o<t.length;o++)t[o]=e(t[o],n);else if("object"==typeof t)for(var i in t)t[i]=e(t[i],n);return t}(e.data,t),e.attachments=void 0,e},t.removeBlobs=function(e,t){var n=0,i=e;!function e(c,u,f){if(!c)return c;if(s&&c instanceof Blob||a&&c instanceof File){n++;var l=new FileReader;l.onload=function(){f?f[u]=this.result:i=this.result,--n||t(i)},l.readAsArrayBuffer(c)}else if(r(c))for(var h=0;h<c.length;h++)e(c[h],h,c);else if("object"==typeof c&&!o(c))for(var p in c)e(c[p],p,c)}(i),n||t(i)}}).call(this,n(0))},function(e,t,n){e.exports=n(44),e.exports.parser=n(2)},function(e,t,n){(function(t){var r=n(19),o=n(12),i=n(7)("engine.io-client:socket"),s=n(22),a=n(2),c=n(13),u=n(5);function f(e,n){if(!(this instanceof f))return new f(e,n);n=n||{},e&&"object"==typeof e&&(n=e,e=null),e?(e=c(e),n.hostname=e.host,n.secure="https"===e.protocol||"wss"===e.protocol,n.port=e.port,e.query&&(n.query=e.query)):n.host&&(n.hostname=c(n.host).host),this.secure=null!=n.secure?n.secure:t.location&&"https:"===location.protocol,n.hostname&&!n.port&&(n.port=this.secure?"443":"80"),this.agent=n.agent||!1,this.hostname=n.hostname||(t.location?location.hostname:"localhost"),this.port=n.port||(t.location&&location.port?location.port:this.secure?443:80),this.query=n.query||{},"string"==typeof this.query&&(this.query=u.decode(this.query)),this.upgrade=!1!==n.upgrade,this.path=(n.path||"/engine.io").replace(/\/$/,"")+"/",this.forceJSONP=!!n.forceJSONP,this.jsonp=!1!==n.jsonp,this.forceBase64=!!n.forceBase64,this.enablesXDR=!!n.enablesXDR,this.timestampParam=n.timestampParam||"t",this.timestampRequests=n.timestampRequests,this.transports=n.transports||["polling","websocket"],this.transportOptions=n.transportOptions||{},this.readyState="",this.writeBuffer=[],this.prevBufferLen=0,this.policyPort=n.policyPort||843,this.rememberUpgrade=n.rememberUpgrade||!1,this.binaryType=null,this.onlyBinaryUpgrades=n.onlyBinaryUpgrades,this.perMessageDeflate=!1!==n.perMessageDeflate&&(n.perMessageDeflate||{}),!0===this.perMessageDeflate&&(this.perMessageDeflate={}),this.perMessageDeflate&&null==this.perMessageDeflate.threshold&&(this.perMessageDeflate.threshold=1024),this.pfx=n.pfx||null,this.key=n.key||null,this.passphrase=n.passphrase||null,this.cert=n.cert||null,this.ca=n.ca||null,this.ciphers=n.ciphers||null,this.rejectUnauthorized=void 0===n.rejectUnauthorized||n.rejectUnauthorized,this.forceNode=!!n.forceNode;var r="object"==typeof t&&t;r.global===r&&(n.extraHeaders&&Object.keys(n.extraHeaders).length>0&&(this.extraHeaders=n.extraHeaders),n.localAddress&&(this.localAddress=n.localAddress)),this.id=null,this.upgrades=null,this.pingInterval=null,this.pingTimeout=null,this.pingIntervalTimer=null,this.pingTimeoutTimer=null,this.open()}e.exports=f,f.priorWebsocketSuccess=!1,o(f.prototype),f.protocol=a.protocol,f.Socket=f,f.Transport=n(11),f.transports=n(19),f.parser=n(2),f.prototype.createTransport=function(e){i('creating transport "%s"',e);var t=function(e){var t={};for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return t}(this.query);t.EIO=a.protocol,t.transport=e;var n=this.transportOptions[e]||{};return this.id&&(t.sid=this.id),new r[e]({query:t,socket:this,agent:n.agent||this.agent,hostname:n.hostname||this.hostname,port:n.port||this.port,secure:n.secure||this.secure,path:n.path||this.path,forceJSONP:n.forceJSONP||this.forceJSONP,jsonp:n.jsonp||this.jsonp,forceBase64:n.forceBase64||this.forceBase64,enablesXDR:n.enablesXDR||this.enablesXDR,timestampRequests:n.timestampRequests||this.timestampRequests,timestampParam:n.timestampParam||this.timestampParam,policyPort:n.policyPort||this.policyPort,pfx:n.pfx||this.pfx,key:n.key||this.key,passphrase:n.passphrase||this.passphrase,cert:n.cert||this.cert,ca:n.ca||this.ca,ciphers:n.ciphers||this.ciphers,rejectUnauthorized:n.rejectUnauthorized||this.rejectUnauthorized,perMessageDeflate:n.perMessageDeflate||this.perMessageDeflate,extraHeaders:n.extraHeaders||this.extraHeaders,forceNode:n.forceNode||this.forceNode,localAddress:n.localAddress||this.localAddress,requestTimeout:n.requestTimeout||this.requestTimeout,protocols:n.protocols||void 0})},f.prototype.open=function(){var e;if(this.rememberUpgrade&&f.priorWebsocketSuccess&&-1!==this.transports.indexOf("websocket"))e="websocket";else{if(0===this.transports.length){var t=this;return void setTimeout((function(){t.emit("error","No transports available")}),0)}e=this.transports[0]}this.readyState="opening";try{e=this.createTransport(e)}catch(e){return this.transports.shift(),void this.open()}e.open(),this.setTransport(e)},f.prototype.setTransport=function(e){i("setting transport %s",e.name);var t=this;this.transport&&(i("clearing existing transport %s",this.transport.name),this.transport.removeAllListeners()),this.transport=e,e.on("drain",(function(){t.onDrain()})).on("packet",(function(e){t.onPacket(e)})).on("error",(function(e){t.onError(e)})).on("close",(function(){t.onClose("transport close")}))},f.prototype.probe=function(e){i('probing transport "%s"',e);var t=this.createTransport(e,{probe:1}),n=!1,r=this;function o(){if(r.onlyBinaryUpgrades){var o=!this.supportsBinary&&r.transport.supportsBinary;n=n||o}n||(i('probe transport "%s" opened',e),t.send([{type:"ping",data:"probe"}]),t.once("packet",(function(o){if(!n)if("pong"===o.type&&"probe"===o.data){if(i('probe transport "%s" pong',e),r.upgrading=!0,r.emit("upgrading",t),!t)return;f.priorWebsocketSuccess="websocket"===t.name,i('pausing current transport "%s"',r.transport.name),r.transport.pause((function(){n||"closed"!==r.readyState&&(i("changing transport and sending upgrade packet"),h(),r.setTransport(t),t.send([{type:"upgrade"}]),r.emit("upgrade",t),t=null,r.upgrading=!1,r.flush())}))}else{i('probe transport "%s" failed',e);var s=new Error("probe error");s.transport=t.name,r.emit("upgradeError",s)}})))}function s(){n||(n=!0,h(),t.close(),t=null)}function a(n){var o=new Error("probe error: "+n);o.transport=t.name,s(),i('probe transport "%s" failed because of error: %s',e,n),r.emit("upgradeError",o)}function c(){a("transport closed")}function u(){a("socket closed")}function l(e){t&&e.name!==t.name&&(i('"%s" works - aborting "%s"',e.name,t.name),s())}function h(){t.removeListener("open",o),t.removeListener("error",a),t.removeListener("close",c),r.removeListener("close",u),r.removeListener("upgrading",l)}f.priorWebsocketSuccess=!1,t.once("open",o),t.once("error",a),t.once("close",c),this.once("close",u),this.once("upgrading",l),t.open()},f.prototype.onOpen=function(){if(i("socket open"),this.readyState="open",f.priorWebsocketSuccess="websocket"===this.transport.name,this.emit("open"),this.flush(),"open"===this.readyState&&this.upgrade&&this.transport.pause){i("starting upgrade probes");for(var e=0,t=this.upgrades.length;e<t;e++)this.probe(this.upgrades[e])}},f.prototype.onPacket=function(e){if("opening"===this.readyState||"open"===this.readyState||"closing"===this.readyState)switch(i('socket receive: type "%s", data "%s"',e.type,e.data),this.emit("packet",e),this.emit("heartbeat"),e.type){case"open":this.onHandshake(JSON.parse(e.data));break;case"pong":this.setPing(),this.emit("pong");break;case"error":var t=new Error("server error");t.code=e.data,this.onError(t);break;case"message":this.emit("data",e.data),this.emit("message",e.data)}else i('packet received with socket readyState "%s"',this.readyState)},f.prototype.onHandshake=function(e){this.emit("handshake",e),this.id=e.sid,this.transport.query.sid=e.sid,this.upgrades=this.filterUpgrades(e.upgrades),this.pingInterval=e.pingInterval,this.pingTimeout=e.pingTimeout,this.onOpen(),"closed"!==this.readyState&&(this.setPing(),this.removeListener("heartbeat",this.onHeartbeat),this.on("heartbeat",this.onHeartbeat))},f.prototype.onHeartbeat=function(e){clearTimeout(this.pingTimeoutTimer);var t=this;t.pingTimeoutTimer=setTimeout((function(){"closed"!==t.readyState&&t.onClose("ping timeout")}),e||t.pingInterval+t.pingTimeout)},f.prototype.setPing=function(){var e=this;clearTimeout(e.pingIntervalTimer),e.pingIntervalTimer=setTimeout((function(){i("writing ping packet - expecting pong within %sms",e.pingTimeout),e.ping(),e.onHeartbeat(e.pingTimeout)}),e.pingInterval)},f.prototype.ping=function(){var e=this;this.sendPacket("ping",(function(){e.emit("ping")}))},f.prototype.onDrain=function(){this.writeBuffer.splice(0,this.prevBufferLen),this.prevBufferLen=0,0===this.writeBuffer.length?this.emit("drain"):this.flush()},f.prototype.flush=function(){"closed"!==this.readyState&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length&&(i("flushing %d packets in socket",this.writeBuffer.length),this.transport.send(this.writeBuffer),this.prevBufferLen=this.writeBuffer.length,this.emit("flush"))},f.prototype.write=f.prototype.send=function(e,t,n){return this.sendPacket("message",e,t,n),this},f.prototype.sendPacket=function(e,t,n,r){if("function"==typeof t&&(r=t,t=void 0),"function"==typeof n&&(r=n,n=null),"closing"!==this.readyState&&"closed"!==this.readyState){(n=n||{}).compress=!1!==n.compress;var o={type:e,data:t,options:n};this.emit("packetCreate",o),this.writeBuffer.push(o),r&&this.once("flush",r),this.flush()}},f.prototype.close=function(){if("opening"===this.readyState||"open"===this.readyState){this.readyState="closing";var e=this;this.writeBuffer.length?this.once("drain",(function(){this.upgrading?r():t()})):this.upgrading?r():t()}function t(){e.onClose("forced close"),i("socket closing - telling transport to close"),e.transport.close()}function n(){e.removeListener("upgrade",n),e.removeListener("upgradeError",n),t()}function r(){e.once("upgrade",n),e.once("upgradeError",n)}return this},f.prototype.onError=function(e){i("socket error %j",e),f.priorWebsocketSuccess=!1,this.emit("error",e),this.onClose("transport error",e)},f.prototype.onClose=function(e,t){if("opening"===this.readyState||"open"===this.readyState||"closing"===this.readyState){i('socket close with reason: "%s"',e);clearTimeout(this.pingIntervalTimer),clearTimeout(this.pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),this.readyState="closed",this.id=null,this.emit("close",e,t),this.writeBuffer=[],this.prevBufferLen=0}},f.prototype.filterUpgrades=function(e){for(var t=[],n=0,r=e.length;n<r;n++)~s(this.transports,e[n])&&t.push(e[n]);return t}}).call(this,n(0))},function(e,t){try{e.exports="undefined"!=typeof XMLHttpRequest&&"withCredentials"in new XMLHttpRequest}catch(t){e.exports=!1}},function(e,t,n){(function(t){var r=n(10),o=n(20),i=n(12),s=n(6),a=n(7)("engine.io-client:polling-xhr");function c(){}function u(e){if(o.call(this,e),this.requestTimeout=e.requestTimeout,this.extraHeaders=e.extraHeaders,t.location){var n="https:"===location.protocol,r=location.port;r||(r=n?443:80),this.xd=e.hostname!==t.location.hostname||r!==e.port,this.xs=e.secure!==n}}function f(e){this.method=e.method||"GET",this.uri=e.uri,this.xd=!!e.xd,this.xs=!!e.xs,this.async=!1!==e.async,this.data=void 0!==e.data?e.data:null,this.agent=e.agent,this.isBinary=e.isBinary,this.supportsBinary=e.supportsBinary,this.enablesXDR=e.enablesXDR,this.requestTimeout=e.requestTimeout,this.pfx=e.pfx,this.key=e.key,this.passphrase=e.passphrase,this.cert=e.cert,this.ca=e.ca,this.ciphers=e.ciphers,this.rejectUnauthorized=e.rejectUnauthorized,this.extraHeaders=e.extraHeaders,this.create()}function l(){for(var e in f.requests)f.requests.hasOwnProperty(e)&&f.requests[e].abort()}e.exports=u,e.exports.Request=f,s(u,o),u.prototype.supportsBinary=!0,u.prototype.request=function(e){return(e=e||{}).uri=this.uri(),e.xd=this.xd,e.xs=this.xs,e.agent=this.agent||!1,e.supportsBinary=this.supportsBinary,e.enablesXDR=this.enablesXDR,e.pfx=this.pfx,e.key=this.key,e.passphrase=this.passphrase,e.cert=this.cert,e.ca=this.ca,e.ciphers=this.ciphers,e.rejectUnauthorized=this.rejectUnauthorized,e.requestTimeout=this.requestTimeout,e.extraHeaders=this.extraHeaders,new f(e)},u.prototype.doWrite=function(e,t){var n="string"!=typeof e&&void 0!==e,r=this.request({method:"POST",data:e,isBinary:n}),o=this;r.on("success",t),r.on("error",(function(e){o.onError("xhr post error",e)})),this.sendXhr=r},u.prototype.doPoll=function(){a("xhr poll");var e=this.request(),t=this;e.on("data",(function(e){t.onData(e)})),e.on("error",(function(e){t.onError("xhr poll error",e)})),this.pollXhr=e},i(f.prototype),f.prototype.create=function(){var e={agent:this.agent,xdomain:this.xd,xscheme:this.xs,enablesXDR:this.enablesXDR};e.pfx=this.pfx,e.key=this.key,e.passphrase=this.passphrase,e.cert=this.cert,e.ca=this.ca,e.ciphers=this.ciphers,e.rejectUnauthorized=this.rejectUnauthorized;var n=this.xhr=new r(e),o=this;try{a("xhr open %s: %s",this.method,this.uri),n.open(this.method,this.uri,this.async);try{if(this.extraHeaders)for(var i in n.setDisableHeaderCheck&&n.setDisableHeaderCheck(!0),this.extraHeaders)this.extraHeaders.hasOwnProperty(i)&&n.setRequestHeader(i,this.extraHeaders[i])}catch(e){}if("POST"===this.method)try{this.isBinary?n.setRequestHeader("Content-type","application/octet-stream"):n.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch(e){}try{n.setRequestHeader("Accept","*/*")}catch(e){}"withCredentials"in n&&(n.withCredentials=!0),this.requestTimeout&&(n.timeout=this.requestTimeout),this.hasXDR()?(n.onload=function(){o.onLoad()},n.onerror=function(){o.onError(n.responseText)}):n.onreadystatechange=function(){if(2===n.readyState)try{var e=n.getResponseHeader("Content-Type");o.supportsBinary&&"application/octet-stream"===e&&(n.responseType="arraybuffer")}catch(e){}4===n.readyState&&(200===n.status||1223===n.status?o.onLoad():setTimeout((function(){o.onError(n.status)}),0))},a("xhr data %s",this.data),n.send(this.data)}catch(e){return void setTimeout((function(){o.onError(e)}),0)}t.document&&(this.index=f.requestsCount++,f.requests[this.index]=this)},f.prototype.onSuccess=function(){this.emit("success"),this.cleanup()},f.prototype.onData=function(e){this.emit("data",e),this.onSuccess()},f.prototype.onError=function(e){this.emit("error",e),this.cleanup(!0)},f.prototype.cleanup=function(e){if(void 0!==this.xhr&&null!==this.xhr){if(this.hasXDR()?this.xhr.onload=this.xhr.onerror=c:this.xhr.onreadystatechange=c,e)try{this.xhr.abort()}catch(e){}t.document&&delete f.requests[this.index],this.xhr=null}},f.prototype.onLoad=function(){var e;try{var t;try{t=this.xhr.getResponseHeader("Content-Type")}catch(e){}e="application/octet-stream"===t&&this.xhr.response||this.xhr.responseText}catch(e){this.onError(e)}null!=e&&this.onData(e)},f.prototype.hasXDR=function(){return void 0!==t.XDomainRequest&&!this.xs&&this.enablesXDR},f.prototype.abort=function(){this.cleanup()},f.requestsCount=0,f.requests={},t.document&&(t.attachEvent?t.attachEvent("onunload",l):t.addEventListener&&t.addEventListener("beforeunload",l,!1))}).call(this,n(0))},function(e,t){e.exports=Object.keys||function(e){var t=[],n=Object.prototype.hasOwnProperty;for(var r in e)n.call(e,r)&&t.push(r);return t}},function(e,t){e.exports=function(e,t,n){var r=e.byteLength;if(t=t||0,n=n||r,e.slice)return e.slice(t,n);if(t<0&&(t+=r),n<0&&(n+=r),n>r&&(n=r),t>=r||t>=n||0===r)return new ArrayBuffer(0);for(var o=new Uint8Array(e),i=new Uint8Array(n-t),s=t,a=0;s<n;s++,a++)i[a]=o[s];return i.buffer}},function(e,t){function n(){}e.exports=function(e,t,r){var o=!1;return r=r||n,i.count=e,0===e?t():i;function i(e,n){if(i.count<=0)throw new Error("after called too many times");--i.count,e?(o=!0,t(e),t=r):0!==i.count||o||t(null,n)}}},function(e,t){
 /*! https://mths.be/utf8js v2.1.2 by @mathias */
-var n,r,o,i=String.fromCharCode;function s(e){for(var t,n,r=[],o=0,i=e.length;o<i;)(t=e.charCodeAt(o++))>=55296&&t<=56319&&o<i?56320==(64512&(n=e.charCodeAt(o++)))?r.push(((1023&t)<<10)+(1023&n)+65536):(r.push(t),o--):r.push(t);return r}function a(e,t){if(e>=55296&&e<=57343){if(t)throw Error("Lone surrogate U+"+e.toString(16).toUpperCase()+" is not a scalar value");return!1}return!0}function c(e,t){return i(e>>t&63|128)}function u(e,t){if(0==(4294967168&e))return i(e);var n="";return 0==(4294965248&e)?n=i(e>>6&31|192):0==(4294901760&e)?(a(e,t)||(e=65533),n=i(e>>12&15|224),n+=c(e,6)):0==(4292870144&e)&&(n=i(e>>18&7|240),n+=c(e,12),n+=c(e,6)),n+=i(63&e|128)}function f(){if(o>=r)throw Error("Invalid byte index");var e=255&n[o];if(o++,128==(192&e))return 63&e;throw Error("Invalid continuation byte")}function l(e){var t,i;if(o>r)throw Error("Invalid byte index");if(o==r)return!1;if(t=255&n[o],o++,0==(128&t))return t;if(192==(224&t)){if((i=(31&t)<<6|f())>=128)return i;throw Error("Invalid continuation byte")}if(224==(240&t)){if((i=(15&t)<<12|f()<<6|f())>=2048)return a(i,e)?i:65533;throw Error("Invalid continuation byte")}if(240==(248&t)&&(i=(7&t)<<18|f()<<12|f()<<6|f())>=65536&&i<=1114111)return i;throw Error("Invalid UTF-8 detected")}e.exports={version:"2.1.2",encode:function(e,t){for(var n=!1!==(t=t||{}).strict,r=s(e),o=r.length,i=-1,a="";++i<o;)a+=u(r[i],n);return a},decode:function(e,t){var a=!1!==(t=t||{}).strict;n=s(e),r=n.length,o=0;for(var c,u=[];!1!==(c=l(a));)u.push(c);return function(e){for(var t,n=e.length,r=-1,o="";++r<n;)(t=e[r])>65535&&(o+=i((t-=65536)>>>10&1023|55296),t=56320|1023&t),o+=i(t);return o}(u)}}},function(e,t){!function(){"use strict";for(var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",n=new Uint8Array(256),r=0;r<e.length;r++)n[e.charCodeAt(r)]=r;t.encode=function(t){var n,r=new Uint8Array(t),o=r.length,i="";for(n=0;n<o;n+=3)i+=e[r[n]>>2],i+=e[(3&r[n])<<4|r[n+1]>>4],i+=e[(15&r[n+1])<<2|r[n+2]>>6],i+=e[63&r[n+2]];return o%3==2?i=i.substring(0,i.length-1)+"=":o%3==1&&(i=i.substring(0,i.length-2)+"=="),i},t.decode=function(e){var t,r,o,i,s,a=.75*e.length,c=e.length,u=0;"="===e[e.length-1]&&(a--,"="===e[e.length-2]&&a--);var f=new ArrayBuffer(a),l=new Uint8Array(f);for(t=0;t<c;t+=4)r=n[e.charCodeAt(t)],o=n[e.charCodeAt(t+1)],i=n[e.charCodeAt(t+2)],s=n[e.charCodeAt(t+3)],l[u++]=r<<2|o>>4,l[u++]=(15&o)<<4|i>>2,l[u++]=(3&i)<<6|63&s;return f}}()},function(e,t){var n=void 0!==n?n:"undefined"!=typeof WebKitBlobBuilder?WebKitBlobBuilder:"undefined"!=typeof MSBlobBuilder?MSBlobBuilder:"undefined"!=typeof MozBlobBuilder&&MozBlobBuilder,r=function(){try{return 2===new Blob(["hi"]).size}catch(e){return!1}}(),o=r&&function(){try{return 2===new Blob([new Uint8Array([1,2])]).size}catch(e){return!1}}(),i=n&&n.prototype.append&&n.prototype.getBlob;function s(e){return e.map((function(e){if(e.buffer instanceof ArrayBuffer){var t=e.buffer;if(e.byteLength!==t.byteLength){var n=new Uint8Array(e.byteLength);n.set(new Uint8Array(t,e.byteOffset,e.byteLength)),t=n.buffer}return t}return e}))}function a(e,t){t=t||{};var r=new n;return s(e).forEach((function(e){r.append(e)})),t.type?r.getBlob(t.type):r.getBlob()}function c(e,t){return new Blob(s(e),t||{})}"undefined"!=typeof Blob&&(a.prototype=Blob.prototype,c.prototype=Blob.prototype),e.exports=r?o?Blob:c:i?a:void 0},function(e,t,n){e.exports=function(e){function t(e){let t=0;for(let n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n),t|=0;return r.colors[Math.abs(t)%r.colors.length]}function r(e){let n;function s(...e){if(!s.enabled)return;const t=s,o=Number(new Date),i=o-(n||o);t.diff=i,t.prev=n,t.curr=o,n=o,e[0]=r.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let a=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,((n,o)=>{if("%%"===n)return n;a++;const i=r.formatters[o];if("function"==typeof i){const r=e[a];n=i.call(t,r),e.splice(a,1),a--}return n})),r.formatArgs.call(t,e);(t.log||r.log).apply(t,e)}return s.namespace=e,s.enabled=r.enabled(e),s.useColors=r.useColors(),s.color=t(e),s.destroy=o,s.extend=i,"function"==typeof r.init&&r.init(s),r.instances.push(s),s}function o(){const e=r.instances.indexOf(this);return-1!==e&&(r.instances.splice(e,1),!0)}function i(e,t){const n=r(this.namespace+(void 0===t?":":t)+e);return n.log=this.log,n}function s(e){return e.toString().substring(2,e.toString().length-2).replace(/\.\*\?$/,"*")}return r.debug=r,r.default=r,r.coerce=function(e){if(e instanceof Error)return e.stack||e.message;return e},r.disable=function(){const e=[...r.names.map(s),...r.skips.map(s).map((e=>"-"+e))].join(",");return r.enable(""),e},r.enable=function(e){let t;r.save(e),r.names=[],r.skips=[];const n=("string"==typeof e?e:"").split(/[\s,]+/),o=n.length;for(t=0;t<o;t++)n[t]&&("-"===(e=n[t].replace(/\*/g,".*?"))[0]?r.skips.push(new RegExp("^"+e.substr(1)+"$")):r.names.push(new RegExp("^"+e+"$")));for(t=0;t<r.instances.length;t++){const e=r.instances[t];e.enabled=r.enabled(e.namespace)}},r.enabled=function(e){if("*"===e[e.length-1])return!0;let t,n;for(t=0,n=r.skips.length;t<n;t++)if(r.skips[t].test(e))return!1;for(t=0,n=r.names.length;t<n;t++)if(r.names[t].test(e))return!0;return!1},r.humanize=n(7),Object.keys(e).forEach((t=>{r[t]=e[t]})),r.instances=[],r.names=[],r.skips=[],r.formatters={},r.selectColor=t,r.enable(r.load()),r}},function(e,t,n){var r=n(22),o=n(5),i=n(12);e.exports=f;var s,a=/\n/g,c=/\\n/g;function u(){}function f(e){r.call(this,e),this.query=this.query||{},s||(s=i.___eio=i.___eio||[]),this.index=s.length;var t=this;s.push((function(e){t.onData(e)})),this.query.j=this.index,"function"==typeof addEventListener&&addEventListener("beforeunload",(function(){t.script&&(t.script.onerror=u)}),!1)}o(f,r),f.prototype.supportsBinary=!1,f.prototype.doClose=function(){this.script&&(this.script.parentNode.removeChild(this.script),this.script=null),this.form&&(this.form.parentNode.removeChild(this.form),this.form=null,this.iframe=null),r.prototype.doClose.call(this)},f.prototype.doPoll=function(){var e=this,t=document.createElement("script");this.script&&(this.script.parentNode.removeChild(this.script),this.script=null),t.async=!0,t.src=this.uri(),t.onerror=function(t){e.onError("jsonp poll error",t)};var n=document.getElementsByTagName("script")[0];n?n.parentNode.insertBefore(t,n):(document.head||document.body).appendChild(t),this.script=t,"undefined"!=typeof navigator&&/gecko/i.test(navigator.userAgent)&&setTimeout((function(){var e=document.createElement("iframe");document.body.appendChild(e),document.body.removeChild(e)}),100)},f.prototype.doWrite=function(e,t){var n=this;if(!this.form){var r,o=document.createElement("form"),i=document.createElement("textarea"),s=this.iframeId="eio_iframe_"+this.index;o.className="socketio",o.style.position="absolute",o.style.top="-1000px",o.style.left="-1000px",o.target=s,o.method="POST",o.setAttribute("accept-charset","utf-8"),i.name="d",o.appendChild(i),document.body.appendChild(o),this.form=o,this.area=i}function u(){f(),t()}function f(){if(n.iframe)try{n.form.removeChild(n.iframe)}catch(e){n.onError("jsonp polling iframe removal error",e)}try{var e='<iframe src="javascript:0" name="'+n.iframeId+'">';r=document.createElement(e)}catch(e){(r=document.createElement("iframe")).name=n.iframeId,r.src="javascript:0"}r.id=n.iframeId,n.form.appendChild(r),n.iframe=r}this.form.action=this.uri(),f(),e=e.replace(c,"\\\n"),this.area.value=e.replace(a,"\\n");try{this.form.submit()}catch(e){}this.iframe.attachEvent?this.iframe.onreadystatechange=function(){"complete"===n.iframe.readyState&&u()}:this.iframe.onload=u}},function(e,t,n){(function(t){var r,o,i=n(13),s=n(1),a=n(4),c=n(5),u=n(24),f=n(6)("engine.io-client:websocket");if("undefined"!=typeof WebSocket?r=WebSocket:"undefined"!=typeof self&&(r=self.WebSocket||self.MozWebSocket),"undefined"==typeof window)try{o=n(57)}catch(e){}var l=r||o;function h(e){e&&e.forceBase64&&(this.supportsBinary=!1),this.perMessageDeflate=e.perMessageDeflate,this.usingBrowserWebSocket=r&&!e.forceNode,this.protocols=e.protocols,this.usingBrowserWebSocket||(l=o),i.call(this,e)}e.exports=h,c(h,i),h.prototype.name="websocket",h.prototype.supportsBinary=!0,h.prototype.doOpen=function(){if(this.check()){var e=this.uri(),t=this.protocols,n={};this.isReactNative||(n.agent=this.agent,n.perMessageDeflate=this.perMessageDeflate,n.pfx=this.pfx,n.key=this.key,n.passphrase=this.passphrase,n.cert=this.cert,n.ca=this.ca,n.ciphers=this.ciphers,n.rejectUnauthorized=this.rejectUnauthorized),this.extraHeaders&&(n.headers=this.extraHeaders),this.localAddress&&(n.localAddress=this.localAddress);try{this.ws=this.usingBrowserWebSocket&&!this.isReactNative?t?new l(e,t):new l(e):new l(e,t,n)}catch(e){return this.emit("error",e)}void 0===this.ws.binaryType&&(this.supportsBinary=!1),this.ws.supports&&this.ws.supports.binary?(this.supportsBinary=!0,this.ws.binaryType="nodebuffer"):this.ws.binaryType="arraybuffer",this.addEventListeners()}},h.prototype.addEventListeners=function(){var e=this;this.ws.onopen=function(){e.onOpen()},this.ws.onclose=function(){e.onClose()},this.ws.onmessage=function(t){e.onData(t.data)},this.ws.onerror=function(t){e.onError("websocket error",t)}},h.prototype.write=function(e){var n=this;this.writable=!1;for(var r=e.length,o=0,i=r;o<i;o++)!function(e){s.encodePacket(e,n.supportsBinary,(function(o){if(!n.usingBrowserWebSocket){var i={};if(e.options&&(i.compress=e.options.compress),n.perMessageDeflate)("string"==typeof o?t.byteLength(o):o.length)<n.perMessageDeflate.threshold&&(i.compress=!1)}try{n.usingBrowserWebSocket?n.ws.send(o):n.ws.send(o,i)}catch(e){f("websocket closed before onclose event")}--r||a()}))}(e[o]);function a(){n.emit("flush"),setTimeout((function(){n.writable=!0,n.emit("drain")}),0)}},h.prototype.onClose=function(){i.prototype.onClose.call(this)},h.prototype.doClose=function(){void 0!==this.ws&&this.ws.close()},h.prototype.uri=function(){var e=this.query||{},t=this.secure?"wss":"ws",n="";return this.port&&("wss"===t&&443!==Number(this.port)||"ws"===t&&80!==Number(this.port))&&(n=":"+this.port),this.timestampRequests&&(e[this.timestampParam]=u()),this.supportsBinary||(e.b64=1),(e=a.encode(e)).length&&(e="?"+e),t+"://"+(-1!==this.hostname.indexOf(":")?"["+this.hostname+"]":this.hostname)+n+this.path+e},h.prototype.check=function(){return!(!l||"__initialize"in l&&this.name===h.prototype.name)}}).call(this,n(10).Buffer)},function(e,t){},function(e,t){e.exports=function(e,t){for(var n=[],r=(t=t||0)||0;r<e.length;r++)n[r-t]=e[r];return n}},function(e,t){function n(e){e=e||{},this.ms=e.min||100,this.max=e.max||1e4,this.factor=e.factor||2,this.jitter=e.jitter>0&&e.jitter<=1?e.jitter:0,this.attempts=0}e.exports=n,n.prototype.duration=function(){var e=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var t=Math.random(),n=Math.floor(t*this.jitter*e);e=0==(1&Math.floor(10*t))?e-n:e+n}return 0|Math.min(e,this.max)},n.prototype.reset=function(){this.attempts=0},n.prototype.setMin=function(e){this.ms=e},n.prototype.setMax=function(e){this.max=e},n.prototype.setJitter=function(e){this.jitter=e}},function(e,t,n){var r;
-/*!
- * UAParser.js v0.7.22
- * Lightweight JavaScript-based User-Agent string parser
- * https://github.com/faisalman/ua-parser-js
- *
- * Copyright Â© 2012-2019 Faisal Salman <f@faisalman.com>
- * Licensed under MIT License
- */!function(o,i){"use strict";var s="function",a="undefined",c="object",u="model",f="name",l="type",h="vendor",p="version",d="architecture",y="console",g="mobile",m="tablet",b="smarttv",v="wearable",w={extend:function(e,t){var n={};for(var r in e)t[r]&&t[r].length%2==0?n[r]=t[r].concat(e[r]):n[r]=e[r];return n},has:function(e,t){return"string"==typeof e&&-1!==t.toLowerCase().indexOf(e.toLowerCase())},lowerize:function(e){return e.toLowerCase()},major:function(e){return"string"==typeof e?e.replace(/[^\d\.]/g,"").split(".")[0]:i},trim:function(e){return e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}},C={rgx:function(e,t){for(var n,r,o,a,u,f,l=0;l<t.length&&!u;){var h=t[l],p=t[l+1];for(n=r=0;n<h.length&&!u;)if(u=h[n++].exec(e))for(o=0;o<p.length;o++)f=u[++r],typeof(a=p[o])===c&&a.length>0?2==a.length?typeof a[1]==s?this[a[0]]=a[1].call(this,f):this[a[0]]=a[1]:3==a.length?typeof a[1]!==s||a[1].exec&&a[1].test?this[a[0]]=f?f.replace(a[1],a[2]):i:this[a[0]]=f?a[1].call(this,f,a[2]):i:4==a.length&&(this[a[0]]=f?a[3].call(this,f.replace(a[1],a[2])):i):this[a]=f||i;l+=2}},str:function(e,t){for(var n in t)if(typeof t[n]===c&&t[n].length>0){for(var r=0;r<t[n].length;r++)if(w.has(t[n][r],e))return"?"===n?i:n}else if(w.has(t[n],e))return"?"===n?i:n;return e}},k={browser:{oldsafari:{version:{"1.0":"/8",1.2:"/1",1.3:"/3","2.0":"/412","2.0.2":"/416","2.0.3":"/417","2.0.4":"/419","?":"/"}}},device:{amazon:{model:{"Fire Phone":["SD","KF"]}},sprint:{model:{"Evo Shift 4G":"7373KT"},vendor:{HTC:"APA",Sprint:"Sprint"}}},os:{windows:{version:{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"}}}},_={browser:[[/(opera\smini)\/([\w\.-]+)/i,/(opera\s[mobiletab]+).+version\/([\w\.-]+)/i,/(opera).+version\/([\w\.]+)/i,/(opera)[\/\s]+([\w\.]+)/i],[f,p],[/(opios)[\/\s]+([\w\.]+)/i],[[f,"Opera Mini"],p],[/\s(opr)\/([\w\.]+)/i],[[f,"Opera"],p],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer)[\/\s]?([\w\.]*)/i,/(avant\s|iemobile|slim)(?:browser)?[\/\s]?([\w\.]*)/i,/(bidubrowser|baidubrowser)[\/\s]?([\w\.]+)/i,/(?:ms|\()(ie)\s([\w\.]+)/i,/(rekonq)\/([\w\.]*)/i,/(chromium|flock|rockmelt|midori|epiphany|silk|skyfire|ovibrowser|bolt|iron|vivaldi|iridium|phantomjs|bowser|quark|qupzilla|falkon)\/([\w\.-]+)/i],[f,p],[/(konqueror)\/([\w\.]+)/i],[[f,"Konqueror"],p],[/(trident).+rv[:\s]([\w\.]+).+like\sgecko/i],[[f,"IE"],p],[/(edge|edgios|edga|edg)\/((\d+)?[\w\.]+)/i],[[f,"Edge"],p],[/(yabrowser)\/([\w\.]+)/i],[[f,"Yandex"],p],[/(Avast)\/([\w\.]+)/i],[[f,"Avast Secure Browser"],p],[/(AVG)\/([\w\.]+)/i],[[f,"AVG Secure Browser"],p],[/(puffin)\/([\w\.]+)/i],[[f,"Puffin"],p],[/(focus)\/([\w\.]+)/i],[[f,"Firefox Focus"],p],[/(opt)\/([\w\.]+)/i],[[f,"Opera Touch"],p],[/((?:[\s\/])uc?\s?browser|(?:juc.+)ucweb)[\/\s]?([\w\.]+)/i],[[f,"UCBrowser"],p],[/(comodo_dragon)\/([\w\.]+)/i],[[f,/_/g," "],p],[/(windowswechat qbcore)\/([\w\.]+)/i],[[f,"WeChat(Win) Desktop"],p],[/(micromessenger)\/([\w\.]+)/i],[[f,"WeChat"],p],[/(brave)\/([\w\.]+)/i],[[f,"Brave"],p],[/(qqbrowserlite)\/([\w\.]+)/i],[f,p],[/(QQ)\/([\d\.]+)/i],[f,p],[/m?(qqbrowser)[\/\s]?([\w\.]+)/i],[f,p],[/(baiduboxapp)[\/\s]?([\w\.]+)/i],[f,p],[/(2345Explorer)[\/\s]?([\w\.]+)/i],[f,p],[/(MetaSr)[\/\s]?([\w\.]+)/i],[f],[/(LBBROWSER)/i],[f],[/xiaomi\/miuibrowser\/([\w\.]+)/i],[p,[f,"MIUI Browser"]],[/;fbav\/([\w\.]+);/i],[p,[f,"Facebook"]],[/safari\s(line)\/([\w\.]+)/i,/android.+(line)\/([\w\.]+)\/iab/i],[f,p],[/headlesschrome(?:\/([\w\.]+)|\s)/i],[p,[f,"Chrome Headless"]],[/\swv\).+(chrome)\/([\w\.]+)/i],[[f,/(.+)/,"$1 WebView"],p],[/((?:oculus|samsung)browser)\/([\w\.]+)/i],[[f,/(.+(?:g|us))(.+)/,"$1 $2"],p],[/android.+version\/([\w\.]+)\s+(?:mobile\s?safari|safari)*/i],[p,[f,"Android Browser"]],[/(sailfishbrowser)\/([\w\.]+)/i],[[f,"Sailfish Browser"],p],[/(chrome|omniweb|arora|[tizenoka]{5}\s?browser)\/v?([\w\.]+)/i],[f,p],[/(dolfin)\/([\w\.]+)/i],[[f,"Dolphin"],p],[/(qihu|qhbrowser|qihoobrowser|360browser)/i],[[f,"360 Browser"]],[/((?:android.+)crmo|crios)\/([\w\.]+)/i],[[f,"Chrome"],p],[/(coast)\/([\w\.]+)/i],[[f,"Opera Coast"],p],[/fxios\/([\w\.-]+)/i],[p,[f,"Firefox"]],[/version\/([\w\.]+).+?mobile\/\w+\s(safari)/i],[p,[f,"Mobile Safari"]],[/version\/([\w\.]+).+?(mobile\s?safari|safari)/i],[p,f],[/webkit.+?(gsa)\/([\w\.]+).+?(mobile\s?safari|safari)(\/[\w\.]+)/i],[[f,"GSA"],p],[/webkit.+?(mobile\s?safari|safari)(\/[\w\.]+)/i],[f,[p,C.str,k.browser.oldsafari.version]],[/(webkit|khtml)\/([\w\.]+)/i],[f,p],[/(navigator|netscape)\/([\w\.-]+)/i],[[f,"Netscape"],p],[/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo\sbrowser|minimo|conkeror)[\/\s]?([\w\.\+]+)/i,/(firefox|seamonkey|k-meleon|icecat|iceape|firebird|phoenix|palemoon|basilisk|waterfox)\/([\w\.-]+)$/i,/(mozilla)\/([\w\.]+).+rv\:.+gecko\/\d+/i,/(polaris|lynx|dillo|icab|doris|amaya|w3m|netsurf|sleipnir)[\/\s]?([\w\.]+)/i,/(links)\s\(([\w\.]+)/i,/(gobrowser)\/?([\w\.]*)/i,/(ice\s?browser)\/v?([\w\._]+)/i,/(mosaic)[\/\s]([\w\.]+)/i],[f,p]],cpu:[[/(?:(amd|x(?:(?:86|64)[_-])?|wow|win)64)[;\)]/i],[[d,"amd64"]],[/(ia32(?=;))/i],[[d,w.lowerize]],[/((?:i[346]|x)86)[;\)]/i],[[d,"ia32"]],[/windows\s(ce|mobile);\sppc;/i],[[d,"arm"]],[/((?:ppc|powerpc)(?:64)?)(?:\smac|;|\))/i],[[d,/ower/,"",w.lowerize]],[/(sun4\w)[;\)]/i],[[d,"sparc"]],[/((?:avr32|ia64(?=;))|68k(?=\))|arm(?:64|(?=v\d+[;l]))|(?=atmel\s)avr|(?:irix|mips|sparc)(?:64)?(?=;)|pa-risc)/i],[[d,w.lowerize]]],device:[[/\((ipad|playbook);[\w\s\),;-]+(rim|apple)/i],[u,h,[l,m]],[/applecoremedia\/[\w\.]+ \((ipad)/],[u,[h,"Apple"],[l,m]],[/(apple\s{0,1}tv)/i],[[u,"Apple TV"],[h,"Apple"],[l,b]],[/(archos)\s(gamepad2?)/i,/(hp).+(touchpad)/i,/(hp).+(tablet)/i,/(kindle)\/([\w\.]+)/i,/\s(nook)[\w\s]+build\/(\w+)/i,/(dell)\s(strea[kpr\s\d]*[\dko])/i],[h,u,[l,m]],[/(kf[A-z]+)\sbuild\/.+silk\//i],[u,[h,"Amazon"],[l,m]],[/(sd|kf)[0349hijorstuw]+\sbuild\/.+silk\//i],[[u,C.str,k.device.amazon.model],[h,"Amazon"],[l,g]],[/android.+aft([bms])\sbuild/i],[u,[h,"Amazon"],[l,b]],[/\((ip[honed|\s\w*]+);.+(apple)/i],[u,h,[l,g]],[/\((ip[honed|\s\w*]+);/i],[u,[h,"Apple"],[l,g]],[/(blackberry)[\s-]?(\w+)/i,/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus|dell|meizu|motorola|polytron)[\s_-]?([\w-]*)/i,/(hp)\s([\w\s]+\w)/i,/(asus)-?(\w+)/i],[h,u,[l,g]],[/\(bb10;\s(\w+)/i],[u,[h,"BlackBerry"],[l,g]],[/android.+(transfo[prime\s]{4,10}\s\w+|eeepc|slider\s\w+|nexus 7|padfone|p00c)/i],[u,[h,"Asus"],[l,m]],[/(sony)\s(tablet\s[ps])\sbuild\//i,/(sony)?(?:sgp.+)\sbuild\//i],[[h,"Sony"],[u,"Xperia Tablet"],[l,m]],[/android.+\s([c-g]\d{4}|so[-l]\w+)(?=\sbuild\/|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[u,[h,"Sony"],[l,g]],[/\s(ouya)\s/i,/(nintendo)\s([wids3u]+)/i],[h,u,[l,y]],[/android.+;\s(shield)\sbuild/i],[u,[h,"Nvidia"],[l,y]],[/(playstation\s[34portablevi]+)/i],[u,[h,"Sony"],[l,y]],[/(sprint\s(\w+))/i],[[h,C.str,k.device.sprint.vendor],[u,C.str,k.device.sprint.model],[l,g]],[/(htc)[;_\s-]+([\w\s]+(?=\)|\sbuild)|\w+)/i,/(zte)-(\w*)/i,/(alcatel|geeksphone|nexian|panasonic|(?=;\s)sony)[_\s-]?([\w-]*)/i],[h,[u,/_/g," "],[l,g]],[/(nexus\s9)/i],[u,[h,"HTC"],[l,m]],[/d\/huawei([\w\s-]+)[;\)]/i,/(nexus\s6p|vog-l29|ane-lx1|eml-l29|ele-l29)/i],[u,[h,"Huawei"],[l,g]],[/android.+(bah2?-a?[lw]\d{2})/i],[u,[h,"Huawei"],[l,m]],[/(microsoft);\s(lumia[\s\w]+)/i],[h,u,[l,g]],[/[\s\(;](xbox(?:\sone)?)[\s\);]/i],[u,[h,"Microsoft"],[l,y]],[/(kin\.[onetw]{3})/i],[[u,/\./g," "],[h,"Microsoft"],[l,g]],[/\s(milestone|droid(?:[2-4x]|\s(?:bionic|x2|pro|razr))?:?(\s4g)?)[\w\s]+build\//i,/mot[\s-]?(\w*)/i,/(XT\d{3,4}) build\//i,/(nexus\s6)/i],[u,[h,"Motorola"],[l,g]],[/android.+\s(mz60\d|xoom[\s2]{0,2})\sbuild\//i],[u,[h,"Motorola"],[l,m]],[/hbbtv\/\d+\.\d+\.\d+\s+\([\w\s]*;\s*(\w[^;]*);([^;]*)/i],[[h,w.trim],[u,w.trim],[l,b]],[/hbbtv.+maple;(\d+)/i],[[u,/^/,"SmartTV"],[h,"Samsung"],[l,b]],[/\(dtv[\);].+(aquos)/i],[u,[h,"Sharp"],[l,b]],[/android.+((sch-i[89]0\d|shw-m380s|gt-p\d{4}|gt-n\d+|sgh-t8[56]9|nexus 10))/i,/((SM-T\w+))/i],[[h,"Samsung"],u,[l,m]],[/smart-tv.+(samsung)/i],[h,[l,b],u],[/((s[cgp]h-\w+|gt-\w+|galaxy\snexus|sm-\w[\w\d]+))/i,/(sam[sung]*)[\s-]*(\w+-?[\w-]*)/i,/sec-((sgh\w+))/i],[[h,"Samsung"],u,[l,g]],[/sie-(\w*)/i],[u,[h,"Siemens"],[l,g]],[/(maemo|nokia).*(n900|lumia\s\d+)/i,/(nokia)[\s_-]?([\w-]*)/i],[[h,"Nokia"],u,[l,g]],[/android[x\d\.\s;]+\s([ab][1-7]\-?[0178a]\d\d?)/i],[u,[h,"Acer"],[l,m]],[/android.+([vl]k\-?\d{3})\s+build/i],[u,[h,"LG"],[l,m]],[/android\s3\.[\s\w;-]{10}(lg?)-([06cv9]{3,4})/i],[[h,"LG"],u,[l,m]],[/(lg) netcast\.tv/i],[h,u,[l,b]],[/(nexus\s[45])/i,/lg[e;\s\/-]+(\w*)/i,/android.+lg(\-?[\d\w]+)\s+build/i],[u,[h,"LG"],[l,g]],[/(lenovo)\s?(s(?:5000|6000)(?:[\w-]+)|tab(?:[\s\w]+))/i],[h,u,[l,m]],[/android.+(ideatab[a-z0-9\-\s]+)/i],[u,[h,"Lenovo"],[l,m]],[/(lenovo)[_\s-]?([\w-]+)/i],[h,u,[l,g]],[/linux;.+((jolla));/i],[h,u,[l,g]],[/((pebble))app\/[\d\.]+\s/i],[h,u,[l,v]],[/android.+;\s(oppo)\s?([\w\s]+)\sbuild/i],[h,u,[l,g]],[/crkey/i],[[u,"Chromecast"],[h,"Google"],[l,b]],[/android.+;\s(glass)\s\d/i],[u,[h,"Google"],[l,v]],[/android.+;\s(pixel c)[\s)]/i],[u,[h,"Google"],[l,m]],[/android.+;\s(pixel( [23])?( xl)?)[\s)]/i],[u,[h,"Google"],[l,g]],[/android.+;\s(\w+)\s+build\/hm\1/i,/android.+(hm[\s\-_]*note?[\s_]*(?:\d\w)?)\s+build/i,/android.+(mi[\s\-_]*(?:a\d|one|one[\s_]plus|note lte)?[\s_]*(?:\d?\w?)[\s_]*(?:plus)?)\s+build/i,/android.+(redmi[\s\-_]*(?:note)?(?:[\s_]?[\w\s]+))\s+build/i],[[u,/_/g," "],[h,"Xiaomi"],[l,g]],[/android.+(mi[\s\-_]*(?:pad)(?:[\s_]?[\w\s]+))\s+build/i],[[u,/_/g," "],[h,"Xiaomi"],[l,m]],[/android.+;\s(m[1-5]\snote)\sbuild/i],[u,[h,"Meizu"],[l,g]],[/(mz)-([\w-]{2,})/i],[[h,"Meizu"],u,[l,g]],[/android.+a000(1)\s+build/i,/android.+oneplus\s(a\d{4})[\s)]/i],[u,[h,"OnePlus"],[l,g]],[/android.+[;\/]\s*(RCT[\d\w]+)\s+build/i],[u,[h,"RCA"],[l,m]],[/android.+[;\/\s]+(Venue[\d\s]{2,7})\s+build/i],[u,[h,"Dell"],[l,m]],[/android.+[;\/]\s*(Q[T|M][\d\w]+)\s+build/i],[u,[h,"Verizon"],[l,m]],[/android.+[;\/]\s+(Barnes[&\s]+Noble\s+|BN[RT])(V?.*)\s+build/i],[[h,"Barnes & Noble"],u,[l,m]],[/android.+[;\/]\s+(TM\d{3}.*\b)\s+build/i],[u,[h,"NuVision"],[l,m]],[/android.+;\s(k88)\sbuild/i],[u,[h,"ZTE"],[l,m]],[/android.+[;\/]\s*(gen\d{3})\s+build.*49h/i],[u,[h,"Swiss"],[l,g]],[/android.+[;\/]\s*(zur\d{3})\s+build/i],[u,[h,"Swiss"],[l,m]],[/android.+[;\/]\s*((Zeki)?TB.*\b)\s+build/i],[u,[h,"Zeki"],[l,m]],[/(android).+[;\/]\s+([YR]\d{2})\s+build/i,/android.+[;\/]\s+(Dragon[\-\s]+Touch\s+|DT)(\w{5})\sbuild/i],[[h,"Dragon Touch"],u,[l,m]],[/android.+[;\/]\s*(NS-?\w{0,9})\sbuild/i],[u,[h,"Insignia"],[l,m]],[/android.+[;\/]\s*((NX|Next)-?\w{0,9})\s+build/i],[u,[h,"NextBook"],[l,m]],[/android.+[;\/]\s*(Xtreme\_)?(V(1[045]|2[015]|30|40|60|7[05]|90))\s+build/i],[[h,"Voice"],u,[l,g]],[/android.+[;\/]\s*(LVTEL\-)?(V1[12])\s+build/i],[[h,"LvTel"],u,[l,g]],[/android.+;\s(PH-1)\s/i],[u,[h,"Essential"],[l,g]],[/android.+[;\/]\s*(V(100MD|700NA|7011|917G).*\b)\s+build/i],[u,[h,"Envizen"],[l,m]],[/android.+[;\/]\s*(Le[\s\-]+Pan)[\s\-]+(\w{1,9})\s+build/i],[h,u,[l,m]],[/android.+[;\/]\s*(Trio[\s\-]*.*)\s+build/i],[u,[h,"MachSpeed"],[l,m]],[/android.+[;\/]\s*(Trinity)[\-\s]*(T\d{3})\s+build/i],[h,u,[l,m]],[/android.+[;\/]\s*TU_(1491)\s+build/i],[u,[h,"Rotor"],[l,m]],[/android.+(KS(.+))\s+build/i],[u,[h,"Amazon"],[l,m]],[/android.+(Gigaset)[\s\-]+(Q\w{1,9})\s+build/i],[h,u,[l,m]],[/\s(tablet|tab)[;\/]/i,/\s(mobile)(?:[;\/]|\ssafari)/i],[[l,w.lowerize],h,u],[/[\s\/\(](smart-?tv)[;\)]/i],[[l,b]],[/(android[\w\.\s\-]{0,9});.+build/i],[u,[h,"Generic"]]],engine:[[/windows.+\sedge\/([\w\.]+)/i],[p,[f,"EdgeHTML"]],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[p,[f,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna)\/([\w\.]+)/i,/(khtml|tasman|links)[\/\s]\(?([\w\.]+)/i,/(icab)[\/\s]([23]\.[\d\.]+)/i],[f,p],[/rv\:([\w\.]{1,9}).+(gecko)/i],[p,f]],os:[[/microsoft\s(windows)\s(vista|xp)/i],[f,p],[/(windows)\snt\s6\.2;\s(arm)/i,/(windows\sphone(?:\sos)*)[\s\/]?([\d\.\s\w]*)/i,/(windows\smobile|windows)[\s\/]?([ntce\d\.\s]+\w)/i],[f,[p,C.str,k.os.windows.version]],[/(win(?=3|9|n)|win\s9x\s)([nt\d\.]+)/i],[[f,"Windows"],[p,C.str,k.os.windows.version]],[/\((bb)(10);/i],[[f,"BlackBerry"],p],[/(blackberry)\w*\/?([\w\.]*)/i,/(tizen|kaios)[\/\s]([\w\.]+)/i,/(android|webos|palm\sos|qnx|bada|rim\stablet\sos|meego|sailfish|contiki)[\/\s-]?([\w\.]*)/i],[f,p],[/(symbian\s?os|symbos|s60(?=;))[\/\s-]?([\w\.]*)/i],[[f,"Symbian"],p],[/\((series40);/i],[f],[/mozilla.+\(mobile;.+gecko.+firefox/i],[[f,"Firefox OS"],p],[/(nintendo|playstation)\s([wids34portablevu]+)/i,/(mint)[\/\s\(]?(\w*)/i,/(mageia|vectorlinux)[;\s]/i,/(joli|[kxln]?ubuntu|debian|suse|opensuse|gentoo|(?=\s)arch|slackware|fedora|mandriva|centos|pclinuxos|redhat|zenwalk|linpus)[\/\s-]?(?!chrom)([\w\.-]*)/i,/(hurd|linux)\s?([\w\.]*)/i,/(gnu)\s?([\w\.]*)/i],[f,p],[/(cros)\s[\w]+\s([\w\.]+\w)/i],[[f,"Chromium OS"],p],[/(sunos)\s?([\w\.\d]*)/i],[[f,"Solaris"],p],[/\s([frentopc-]{0,4}bsd|dragonfly)\s?([\w\.]*)/i],[f,p],[/(haiku)\s(\w+)/i],[f,p],[/cfnetwork\/.+darwin/i,/ip[honead]{2,4}(?:.*os\s([\w]+)\slike\smac|;\sopera)/i],[[p,/_/g,"."],[f,"iOS"]],[/(mac\sos\sx)\s?([\w\s\.]*)/i,/(macintosh|mac(?=_powerpc)\s)/i],[[f,"Mac OS"],[p,/_/g,"."]],[/((?:open)?solaris)[\/\s-]?([\w\.]*)/i,/(aix)\s((\d)(?=\.|\)|\s)[\w\.])*/i,/(plan\s9|minix|beos|os\/2|amigaos|morphos|risc\sos|openvms|fuchsia)/i,/(unix)\s?([\w\.]*)/i],[f,p]]},E=function(e,t){if("object"==typeof e&&(t=e,e=i),!(this instanceof E))return new E(e,t).getResult();var n=e||(o&&o.navigator&&o.navigator.userAgent?o.navigator.userAgent:""),r=t?w.extend(_,t):_;return this.getBrowser=function(){var e={name:i,version:i};return C.rgx.call(e,n,r.browser),e.major=w.major(e.version),e},this.getCPU=function(){var e={architecture:i};return C.rgx.call(e,n,r.cpu),e},this.getDevice=function(){var e={vendor:i,model:i,type:i};return C.rgx.call(e,n,r.device),e},this.getEngine=function(){var e={name:i,version:i};return C.rgx.call(e,n,r.engine),e},this.getOS=function(){var e={name:i,version:i};return C.rgx.call(e,n,r.os),e},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 n},this.setUA=function(e){return n=e,this},this};E.VERSION="0.7.22",E.BROWSER={NAME:f,MAJOR:"major",VERSION:p},E.CPU={ARCHITECTURE:d},E.DEVICE={MODEL:u,VENDOR:h,TYPE:l,CONSOLE:y,MOBILE:g,SMARTTV:b,TABLET:m,WEARABLE:v,EMBEDDED:"embedded"},E.ENGINE={NAME:f,VERSION:p},E.OS={NAME:f,VERSION:p},typeof t!==a?(typeof e!==a&&e.exports&&(t=e.exports=E),t.UAParser=E):(r=function(){return E}.call(t,n,t,e))===i||(e.exports=r);var S=o&&(o.jQuery||o.Zepto);if(S&&!S.ua){var A=new E;S.ua=A.getResult(),S.ua.get=function(){return A.getUA()},S.ua.set=function(e){A.setUA(e);var t=A.getResult();for(var n in t)S.ua[n]=t[n]}}}("object"==typeof window?window:this)},function(e,t,n){(function(r){t.formatArgs=function(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const n="color: "+this.color;t.splice(1,0,n,"color: inherit");let r=0,o=0;t[0].replace(/%[a-zA-Z%]/g,(e=>{"%%"!==e&&(r++,"%c"===e&&(o=r))})),t.splice(o,0,n)},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}},t.load=function(){let e;try{e=t.storage.getItem("debug")}catch(e){}!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG);return e},t.useColors=function(){if("undefined"!=typeof window&&window.process&&("renderer"===window.process.type||window.process.__nwjs))return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage=function(){try{return localStorage}catch(e){}}(),t.destroy=(()=>{let e=!1;return()=>{e||(e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.log=console.debug||console.log||(()=>{}),e.exports=n(62)(t);const{formatters:o}=e.exports;o.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}}).call(this,n(3))},function(e,t,n){e.exports=function(e){function t(e){let n,o=null;function i(...e){if(!i.enabled)return;const r=i,o=Number(new Date),s=o-(n||o);r.diff=s,r.prev=n,r.curr=o,n=o,e[0]=t.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let a=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,((n,o)=>{if("%%"===n)return"%";a++;const i=t.formatters[o];if("function"==typeof i){const t=e[a];n=i.call(r,t),e.splice(a,1),a--}return n})),t.formatArgs.call(r,e);(r.log||t.log).apply(r,e)}return i.namespace=e,i.useColors=t.useColors(),i.color=t.selectColor(e),i.extend=r,i.destroy=t.destroy,Object.defineProperty(i,"enabled",{enumerable:!0,configurable:!1,get:()=>null===o?t.enabled(e):o,set:e=>{o=e}}),"function"==typeof t.init&&t.init(i),i}function r(e,n){const r=t(this.namespace+(void 0===n?":":n)+e);return r.log=this.log,r}function o(e){return e.toString().substring(2,e.toString().length-2).replace(/\.\*\?$/,"*")}return t.debug=t,t.default=t,t.coerce=function(e){if(e instanceof Error)return e.stack||e.message;return e},t.disable=function(){const e=[...t.names.map(o),...t.skips.map(o).map((e=>"-"+e))].join(",");return t.enable(""),e},t.enable=function(e){let n;t.save(e),t.names=[],t.skips=[];const r=("string"==typeof e?e:"").split(/[\s,]+/),o=r.length;for(n=0;n<o;n++)r[n]&&("-"===(e=r[n].replace(/\*/g,".*?"))[0]?t.skips.push(new RegExp("^"+e.substr(1)+"$")):t.names.push(new RegExp("^"+e+"$")))},t.enabled=function(e){if("*"===e[e.length-1])return!0;let n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1},t.humanize=n(7),t.destroy=function(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")},Object.keys(e).forEach((n=>{t[n]=e[n]})),t.names=[],t.skips=[],t.formatters={},t.selectColor=function(e){let n=0;for(let t=0;t<e.length;t++)n=(n<<5)-n+e.charCodeAt(t),n|=0;return t.colors[Math.abs(n)%t.colors.length]},t.enable(t.load()),t}},,,,,,,,,,,,,,,,,,,,function(e,t,n){e.exports=n(83)},function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var o=c(n(32)),i=n(15),s=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var t=a();if(t&&t.has(e))return t.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)){var s=o?Object.getOwnPropertyDescriptor(e,i):null;s&&(s.get||s.set)?Object.defineProperty(n,i,s):n[i]=e[i]}n.default=e,t&&t.set(e,n);return n}(n(84));function a(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return a=function(){return e},e}function c(e){return e&&e.__esModule?e:{default:e}}function u(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return f(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return f(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,s=!0,a=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return s=e.done,e},e:function(e){a=!0,i=e},f:function(){try{s||null==n.return||n.return()}finally{if(a)throw i}}}}function f(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function l(e,t,n,r,o,i,s){try{var a=e[i](s),c=a.value}catch(e){return void n(e)}a.done?t(c):Promise.resolve(c).then(r,o)}function h(e){return function(){var t=this,n=arguments;return new Promise((function(r,o){var i=e.apply(t,n);function s(e){l(i,r,o,s,a,"next",e)}function a(e){l(i,r,o,s,a,"throw",e)}s(void 0)}))}}function p(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var d=new(c(n(0)).default)("index.js");window.localStorage.setItem("debug","offload:INFO*, offload:ERROR*");var y=(0,i.isDebugMode)(),g=["CAMERA","PEDOMETER","HRM","MIC","GESTURE","GYRO","COMPUTE"],m=Object.freeze({IDLE:0,CONNECTING:1,CONNECTED:2}),b=new(function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.socket_=null,this.peerConnection_=null,this.dataChannel_=null,this.id_=null,this.peerId_=null,this.currentUrl_=null,this.features_=null,this.mediaDeviceInfos_=null,this.deviceName_=null,this.workers_=[],this.connectionStatus_=m.IDLE,this.initialize_()}var t,n,r,a,c;return t=e,(n=[{key:"initialize_",value:function(){this.id_=localStorage.getItem("workerId"),null===this.id_&&(this.id_=(0,i.getUniqueId)(),d.debug("New workerId : ".concat(this.id_)),localStorage.setItem("workerId",this.id_));for(var e=0,t=Object.values(s);e<t.length;e++){var n=t[e];this.workers_.push(new n)}y&&(this.features_=new Set(g))}},{key:"connect",value:function(e,t){if(this.deviceName_=t&&t.deviceName||(0,i.getDeviceName)(),null!==e&&!e.includes("file://")){if(e.endsWith("/offload-js")||(e+="/offload-js"),this.connectionStatus_!==m.IDLE){if(!t||!t.forceConnect)return void d.debug("Already connected or connecting to ".concat(this.currentUrl_));this.socket_.disconnect(),this.connectionStatus_=m.IDLE}return d.debug("Try to connect to ".concat(e)),this.createSocket_(e),this.connectionStatus_=m.CONNECTING,this.currentUrl_=e,e}d.error("No valid server URL found.")}},{key:"onConfirmationResult",value:function(e,t){this.workers_.some((function(n){return n.onConfirmationResult(e,t)}))}},{key:"checkCapability",value:(c=h((function*(){d.debug("checkCapability");var e="";yield this.getCapability_(),"undefined"!=typeof android&&(e=Array.from(this.features_).toString(),android.emit("writeCapability",JSON.stringify({id:this.id_,name:(0,i.getDeviceName)(),features:e})))})),function(){return c.apply(this,arguments)})},{key:"createSocket_",value:function(e){var t=this;this.socket_=(0,o.default)(e,{transports:["websocket"],reconnectionAttempts:5}),this.socket_.on("connect",h((function*(){d.debug("".concat(t.socket_.id," connected")),t.connectionStatus_=m.CONNECTED,yield t.getCapability_(),t.join_()}))),this.socket_.on("reconnect_attempt",(function(){d.debug("reconnect attempt"),t.socket_.io.opts.transports=["polling","websocket"]})),this.socket_.on("connect_error",(function(e){d.error("connect error: %o",e)})),this.socket_.on("reconnect_failed",(function(){d.error("reconnect failed"),t.connectionStatus_=m.IDLE})),this.socket_.on("disconnect",(function(e){d.debug("disconnect ".concat(e)),t.connectionStatus_=m.IDLE})),this.socket_.on("client",this.handleClient_.bind(this)),this.socket_.on("message",this.handleMessage_.bind(this))}},{key:"getCapability_",value:(a=h((function*(){var e=this;if(d.debug("getCapability_"),null===this.features_&&(this.features_=new Set,yield Promise.all(this.workers_.map(function(){var t=h((function*(t){(yield t.checkCapability()).forEach((function(t){e.features_.add(t)}))}));return function(e){return t.apply(this,arguments)}}())),this.features_.has("CAMERA")||this.features_.has("MIC")))try{this.mediaDeviceInfos_=yield navigator.mediaDevices.enumerateDevices()}catch(e){d.error(e.name+": "+e.message)}})),function(){return a.apply(this,arguments)})},{key:"join_",value:function(){this.socket_.emit("join",{id:this.id_,name:this.deviceName_,features:Array.from(this.features_),mediaDeviceInfos:this.mediaDeviceInfos_})}},{key:"handleClient_",value:function(e){"bye"===e.event?(d.debug("client bye: '".concat(e.socketId,"'")),this.hangup_()):"forceQuit"===e.event&&(d.debug("offload-worker will be closed now!"),"undefined"!=typeof tizen?tizen.application.getCurrentApplication().exit():"undefined"!=typeof android?android.emit("destroyService",""):window.open("","_self").close())}},{key:"hangup_",value:function(){d.debug("hangup"),null!==this.peerConnection_&&(null!==this.dataChannel_&&(this.dataChannel_.onopen=null,this.dataChannel_.onclose=null,this.dataChannel_.onmessage=null,this.dataChannel_.close(),this.dataChannel_=null,this.workers_.forEach((function(e){e.setDataChannel(null)}))),this.peerConnection_.onnegotiationneeded=null,this.peerConnection_.onicecandidate=null,this.peerConnection_.ondatachannel=null,this.peerConnection_.close(),this.peerConnection_=null,this.workers_.forEach((function(e){e.setPeerConnection(null)}))),this.peerId_=null}},{key:"handleMessage_",value:function(e,t){if("offer"===e.message.type)this.setupPeerConnectionIfNeeded_(e.from),this.handleOffer_(e.message);else if("answer"===e.message.type)this.handleAnswer_(e.message);else if("candidate"===e.message.type)this.handleCandidate_(e.message.candidate);else if("COMPUTE"===e.message.type){var n,r=u(this.workers_);try{for(r.s();!(n=r.n()).done;){var o=n.value;if(o.hasFeature("COMPUTE")){o.doComputingJob(e,t);break}}}catch(e){r.e(e)}finally{r.f()}}}},{key:"setupPeerConnectionIfNeeded_",value:function(e){var t=this;null===this.peerConnection_&&(d.debug("create peer connection"),this.peerConnection_=new RTCPeerConnection,this.peerConnection_.onnegotiationneeded=this.handleNegotiationNeeded_.bind(this),this.peerConnection_.onicecandidate=this.handleIceCandidate_.bind(this),this.peerConnection_.ondatachannel=this.handleDataChannel_.bind(this),this.workers_.forEach((function(e){e.setPeerConnection(t.peerConnection_)})),this.peerId_=e)}},{key:"handleNegotiationNeeded_",value:function(){var e=this;this.peerConnection_.createOffer().then((function(t){return"stable"!==e.peerConnection_.signalingState?new DOMException("The RTCPeerConnection's signalingState is not 'statble'","InvalidStateError"):e.peerConnection_.setLocalDescription(t)})).then((function(){d.debug("send offer"),e.sendPeerMessage_(e.peerConnection_.localDescription)})).catch((function(e){return d.error(TAG+"reason: "+e.message)}))}},{key:"handleIceCandidate_",value:function(e){e.candidate&&(d.debug("send candidate"),this.sendPeerMessage_({type:"candidate",candidate:e.candidate}))}},{key:"handleDataChannel_",value:function(e){var t=this;this.dataChannel_=e.channel,this.dataChannel_.onopen=function(){d.debug("data channel opened"),t.workers_.forEach((function(e){e.setDataChannel(t.dataChannel_)}))},this.dataChannel_.onclose=function(){d.debug("data channel closed"),t.hangup_()},this.dataChannel_.onmessage=function(e){var n=JSON.parse(e.data);t.workers_.forEach((function(e){e.hasFeature(n.feature)&&e.handleMessage(n)}))}}},{key:"handleOffer_",value:function(e){var t=this;d.debug("got offer"),this.peerConnection_.setRemoteDescription(e).then((function(){return t.peerConnection_.createAnswer()})).then((function(e){return t.peerConnection_.setLocalDescription(e)})).then((function(){d.debug("send answer"),t.sendPeerMessage_(t.peerConnection_.localDescription)})).catch((function(e){return d.error("reason: "+e.toString())}))}},{key:"handleAnswer_",value:function(e){d.debug("got answer"),this.peerConnection_.setRemoteDescription(e).catch((function(e){return d.error("reason: "+e.toString())}))}},{key:"handleCandidate_",value:function(e){d.debug("got candidate"),this.peerConnection_.addIceCandidate(e).catch((function(e){return d.error("reason: "+e.toString())}))}},{key:"sendPeerMessage_",value:function(e){null!==this.socket_&&this.socket_.emit("message",{to:this.peerId_,from:this.id_,message:e})}}])&&p(t.prototype,n),r&&p(t,r),e}());window.connect=function(e,t){return b.connect(e,t)},window.onConfirmationResult=function(e,t){return b.onConfirmationResult(e,t)},window.checkCapability=function(){return b.checkCapability()}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"HAMWorker",{enumerable:!0,get:function(){return r.HAMWorker}}),Object.defineProperty(t,"GUMWorker",{enumerable:!0,get:function(){return o.GUMWorker}}),Object.defineProperty(t,"GyroWorker",{enumerable:!0,get:function(){return i.GyroWorker}}),Object.defineProperty(t,"ComputeWorker",{enumerable:!0,get:function(){return s.ComputeWorker}});var r=n(85),o=n(86),i=n(87),s=n(88)},function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.HAMWorker=void 0;var o,i=n(15),s=n(30);function a(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function c(e,t){return(c=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function u(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=l(e);if(t){var o=l(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return f(this,n)}}function f(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function l(e){return(l=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var h=new(((o=n(0))&&o.__esModule?o:{default:o}).default)("ham.js"),p=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&c(e,t)}(s,e);var t,n,r,o=u(s);function s(){var e;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,s),(e=o.call(this)).listenerId=0,e.intervalId=0,e}return t=s,(n=[{key:"checkCapability",value:function(){return"undefined"!=typeof tizen&&tizen.humanactivitymonitor&&(this.features.add("HRM"),this.features.add("PEDOMETER"),this.features.add("GESTURE")),this.features}},{key:"handleMessage",value:function(e){switch(e.feature){case"PEDOMETER":case"HRM":"start"===e.type?this.startHam(e.feature):this.stopHam(e.feature);break;case"GESTURE":"start"===e.type?this.startGestureRecognition():this.stopGestureRecognition();break;default:h.debug("unsupported feature",e.feature)}}},{key:"startHam",value:function(e){var t=this;h.debug("start HAM");var n=e,r={},o=this;(0,i.isDebugMode)()?this.intervalId=setInterval((function(){"HRM"===n?(r.heartRate=Math.floor(150*Math.random()+50),r.rRInterval=0):"PEDOMETER"===n&&(r.stepStatus="WALKING",r.cumulativeTotalStepCount=Math.floor(150*Math.random()+50)),t.dataChannel.send(JSON.stringify({type:"data",feature:n,data:r}))}),1e3):tizen.ppm.requestPermission("http://tizen.org/privilege/healthinfo",(function(){tizen.humanactivitymonitor.start(n,(function(e){"HRM"===n?(r.heartRate=e.heartRate,r.rRInterval=e.rRInterval):"PEDOMETER"===n&&(r.stepStatus=e.stepStatus,r.speed=e.speed,r.walkingFrequency=e.walkingFrequency,r.cumulativeDistance=e.cumulativeDistance,r.cumulativeCalorie=e.cumulativeCalorie,r.cumulativeTotalStepCount=e.cumulativeTotalStepCount,r.cumulativeWalkStepCount=e.cumulativeWalkStepCount,r.cumulativeRunStepCount=e.cumulativeRunStepCount,r.stepCountDifferences=e.stepCountDifferences.slice()),o.dataChannel.send(JSON.stringify({type:"data",feature:n,data:r}))}))}),(function(e){return h.error("error: "+JSON.stringify(e))}))}},{key:"stopHam",value:function(e){tizen.humanactivitymonitor.stop(e)}},{key:"startGestureRecognition",value:function(){var e=this;if(!(this.listenerId>0))if((0,i.isDebugMode)())this.intervalId=setInterval((function(){e.dataChannel.send(JSON.stringify({type:"data",feature:"GESTURE",data:{type:"GESTURE_WRIST_UP",event:"GESTURE_EVENT_DETECTED",timestamp:(new Date).getTime()}}))}),3e3);else try{this.listenerId=tizen.humanactivitymonitor.addGestureRecognitionListener("GESTURE_WRIST_UP",(function(t){h.debug("Received "+t.event+" event on "+new Date(1e3*t.timestamp)+" for "+t.type+" type"),e.dataChannel.send(JSON.stringify({type:"data",feature:"GESTURE",data:{type:t.type,event:t.event,timestamp:t.timestamp}}))}),(function(e){return h.error("error: "+JSON.stringify(e))}),!0),h.debug("Listener with id "+this.listenerId+" has been added")}catch(e){h.error("error: "+JSON.stringify(e))}}},{key:"stopGestureRecognition",value:function(){this.listenerId>0&&tizen.humanactivitymonitor.removeGestureRecognitionListener(this.listenerId)}}])&&a(t.prototype,n),r&&a(t,r),s}(s.Worker);t.HAMWorker=p},function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.GUMWorker=void 0;var o,i=n(15),s=n(30);function a(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function c(e,t){return(c=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function u(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=l(e);if(t){var o=l(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return f(this,n)}}function f(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function l(e){return(l=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var h=new(((o=n(0))&&o.__esModule?o:{default:o}).default)("gum.js"),p=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&c(e,t)}(s,e);var t,n,r,o=u(s);function s(){var e;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,s),(e=o.call(this)).mediaStream=null,e}return t=s,(n=[{key:"checkCapability",value:function(){var e=this;return"undefined"!=typeof android&&alert(RTCRtpSender.getCapabilities("video")),new Promise((function(t,n){navigator.mediaDevices.enumerateDevices().then((function(n){n.forEach((function(t){"videoinput"===t.kind&&e.features.add("CAMERA"),"audioinput"===t.kind&&e.features.add("MIC")})),t(e.features)})).catch((function(t){h.error("err.code: "+t.code),h.error(t.name+": "+t.message),n(e.features)}))})).catch((function(t){return e.features}))}},{key:"handleMessage",value:function(e){var t=this;"start"===e.type?this.requestConfirmation(e.feature,e.clientId,e.deviceName).then((function(n){n?t.startGum(e.arguments[0],e.feature):t.dataChannel.send(JSON.stringify({type:"error",feature:e.feature,error:{message:"Permission denied",name:"NotAllowedError"}}))})):"applyConstraints"===e.type&&this.applyConstraints(e.constraints,e.feature)}},{key:"getStream",value:function(e,t){var n=this;if(this.mediaStream=e,e.getTracks().forEach((function(t){n.peerConnection.addTrack(t,e)})),"CAMERA"===t){var r=e.getVideoTracks()[0];this.dataChannel.send(JSON.stringify({type:"data",feature:t,data:{capabilities:r.getCapabilities(),settings:r.getSettings()}}))}}},{key:"startGum",value:function(e,t){var n=this,r=this;(0,i.isDebugMode)()?navigator.mediaDevices.getDisplayMedia({video:!0}).then((function(e){return n.getStream(e,t)})).catch((function(e){h.error("error: "+e)})):navigator.mediaDevices.getUserMedia(e).then((function(e){return n.getStream(e,t)})).catch((function(e){h.error("error: "+e),r.dataChannel.send(JSON.stringify({type:"error",feature:t,error:{message:e.message,name:e.name}}))}))}},{key:"applyConstraints",value:function(e,t){var n=this,r=this.mediaStream.getVideoTracks()[0];r.applyConstraints(e).then((function(){n.dataChannel.send(JSON.stringify({type:"applyConstraints",feature:t,result:"success",resultSettings:r.getSettings()}))})).catch((function(e){n.dataChannel.send(JSON.stringify({type:"applyConstraints",feature:t,result:"error",error:{message:e.message,name:e.name}}))}))}}])&&a(t.prototype,n),r&&a(t,r),s}(s.Worker);t.GUMWorker=p},function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.GyroWorker=void 0;var o,i=n(30);function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function a(e,t){return(a=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function c(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=f(e);if(t){var o=f(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return u(this,n)}}function u(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function f(e){return(f=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var l=new(((o=n(0))&&o.__esModule?o:{default:o}).default)("gyro.js"),h=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&a(e,t)}(i,e);var t,n,r,o=c(i);function i(){var e;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),(e=o.call(this)).gyroSensor=null,e}return t=i,(n=[{key:"checkCapability",value:function(){return"undefined"!=typeof tizen&&tizen.sensorservice&&this.features.add("GYRO"),this.features}},{key:"handleMessage",value:function(e){"start"===e.arguments[0]?this.startGyro():"getGyroscopeRotationVectorSensorData"===e.arguments[0]?this.getGyroscopeRotationVectorSensorData():this.stopGyro()}},{key:"startGyro",value:function(){var e=this;function t(t){l.error("error: "+JSON.stringify(t)),e.dataChannel.send(JSON.stringify({type:"error",feature:"GYRO",error:{message:t.message,name:t.name}}))}try{this.gyroSensor=tizen.sensorservice.getDefaultSensor("GYROSCOPE_ROTATION_VECTOR"),this.gyroSensor.start((function(t){e.dataChannel.send(JSON.stringify({type:"data",feature:"GYRO",data:t}))}),t)}catch(e){t(e)}}},{key:"getGyroscopeRotationVectorSensorData",value:function(){var e=this;function t(t){l.error("error: "+JSON.stringify(t)),e.dataChannel.send(JSON.stringify({type:"error",feature:"GYRO",error:{message:t.message,name:t.name}}))}try{this.gyroSensor.getGyroscopeRotationVectorSensorData((function(t){e.dataChannel.send(JSON.stringify({type:"data",feature:"GYRO",data:t}))}),t)}catch(e){t(e)}}},{key:"stopGyro",value:function(){this.gyroSensor&&this.gyroSensor.stop(),this.gyroSensor=null}}])&&s(t.prototype,n),r&&s(t,r),i}(i.Worker);t.GyroWorker=h},function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.ComputeWorker=void 0;var o=a(n(89)),i=n(30),s=n(15);function a(e){return e&&e.__esModule?e:{default:e}}function c(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function u(e,t){return(u=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function f(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=h(e);if(t){var o=h(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return l(this,n)}}function l(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function h(e){return(h=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var p=new(a(n(0)).default)("compute.js"),d=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&u(e,t)}(a,e);var t,n,r,i=f(a);function a(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),i.call(this)}return t=a,(n=[{key:"checkCapability",value:function(){return this.features.add("COMPUTE"),this.features}},{key:"handleMessage",value:function(e){this.doComputingJob(e.arguments)}},{key:"doComputingJob",value:function(e,t){var n=this,r="function"==typeof t?JSON.parse(e.message.data):JSON.parse(e),i=performance.now(),a={function:"",timeout:0,result:0,errorCode:0,offloadId:r.offloadId},c="-1";try{var u=new o.default.Script(r.execStatement),f=o.default.createContext({a:1,b:2,c:0});c=u.runInContext(f,{timeout:r.timeout},{displayErrors:!0})}catch(e){return p.error(e),"ERR_SCRIPT_EXECUTION_TIMEOUT"===e.code&&(p.error(" 408 error : request timeout ",r.timeout),a.errorCode=e.code),p.error(" 400 error"),void(a.errorCode="UNKNOWN ERROR")}a.execStatement=r.execStatement,(0,s.isPromise)(c)?c.then((function(e){a.result=e,a.workerTime=performance.now()-i,"function"==typeof t?(p.debug(" Sending compute result via callback"),t(a)):(p.debug(" Sending compute result back in data channel"),n.dataChannel.send(JSON.stringify({type:"data",feature:"COMPUTE",data:a})))})):(a.result=c,a.workerTime=performance.now()-i,"function"==typeof t?(p.debug("Sending compute result via callback"),t(a)):(p.debug("Sending compute result back in data channel"),this.dataChannel.send(JSON.stringify({type:"data",feature:"COMPUTE",data:a}))))}}])&&c(t.prototype,n),r&&c(t,r),a}(i.Worker);t.ComputeWorker=d},function(module,exports){var indexOf=function(e,t){if(e.indexOf)return e.indexOf(t);for(var n=0;n<e.length;n++)if(e[n]===t)return n;return-1},Object_keys=function(e){if(Object.keys)return Object.keys(e);var t=[];for(var n in e)t.push(n);return t},forEach=function(e,t){if(e.forEach)return e.forEach(t);for(var n=0;n<e.length;n++)t(e[n],n,e)},defineProp=function(){try{return Object.defineProperty({},"_",{}),function(e,t,n){Object.defineProperty(e,t,{writable:!0,enumerable:!1,configurable:!0,value:n})}}catch(e){return function(e,t,n){e[t]=n}}}(),globals=["Array","Boolean","Date","Error","EvalError","Function","Infinity","JSON","Math","NaN","Number","Object","RangeError","ReferenceError","RegExp","String","SyntaxError","TypeError","URIError","decodeURI","decodeURIComponent","encodeURI","encodeURIComponent","escape","eval","isFinite","isNaN","parseFloat","parseInt","undefined","unescape"];function Context(){}Context.prototype={};var Script=exports.Script=function(e){if(!(this instanceof Script))return new Script(e);this.code=e};Script.prototype.runInContext=function(e){if(!(e instanceof Context))throw new TypeError("needs a 'context' argument.");var t=document.createElement("iframe");t.style||(t.style={}),t.style.display="none",document.body.appendChild(t);var n=t.contentWindow,r=n.eval,o=n.execScript;!r&&o&&(o.call(n,"null"),r=n.eval),forEach(Object_keys(e),(function(t){n[t]=e[t]})),forEach(globals,(function(t){e[t]&&(n[t]=e[t])}));var i=Object_keys(n),s=r.call(n,this.code);return forEach(Object_keys(n),(function(t){(t in e||-1===indexOf(i,t))&&(e[t]=n[t])})),forEach(globals,(function(t){t in e||defineProp(e,t,n[t])})),document.body.removeChild(t),s},Script.prototype.runInThisContext=function(){return eval(this.code)},Script.prototype.runInNewContext=function(e){var t=Script.createContext(e),n=this.runInContext(t);return e&&forEach(Object_keys(t),(function(n){e[n]=t[n]})),n},forEach(Object_keys(Script.prototype),(function(e){exports[e]=Script[e]=function(t){var n=Script(t);return n[e].apply(n,[].slice.call(arguments,1))}})),exports.isContext=function(e){return e instanceof Context},exports.createScript=function(e){return exports.Script(e)},exports.createContext=Script.createContext=function(e){var t=new Context;return"object"==typeof e&&forEach(Object_keys(e),(function(n){t[n]=e[n]})),t}}]).default;
\ No newline at end of file
+var n,r,o,i=String.fromCharCode;function s(e){for(var t,n,r=[],o=0,i=e.length;o<i;)(t=e.charCodeAt(o++))>=55296&&t<=56319&&o<i?56320==(64512&(n=e.charCodeAt(o++)))?r.push(((1023&t)<<10)+(1023&n)+65536):(r.push(t),o--):r.push(t);return r}function a(e,t){if(e>=55296&&e<=57343){if(t)throw Error("Lone surrogate U+"+e.toString(16).toUpperCase()+" is not a scalar value");return!1}return!0}function c(e,t){return i(e>>t&63|128)}function u(e,t){if(0==(4294967168&e))return i(e);var n="";return 0==(4294965248&e)?n=i(e>>6&31|192):0==(4294901760&e)?(a(e,t)||(e=65533),n=i(e>>12&15|224),n+=c(e,6)):0==(4292870144&e)&&(n=i(e>>18&7|240),n+=c(e,12),n+=c(e,6)),n+=i(63&e|128)}function f(){if(o>=r)throw Error("Invalid byte index");var e=255&n[o];if(o++,128==(192&e))return 63&e;throw Error("Invalid continuation byte")}function l(e){var t,i;if(o>r)throw Error("Invalid byte index");if(o==r)return!1;if(t=255&n[o],o++,0==(128&t))return t;if(192==(224&t)){if((i=(31&t)<<6|f())>=128)return i;throw Error("Invalid continuation byte")}if(224==(240&t)){if((i=(15&t)<<12|f()<<6|f())>=2048)return a(i,e)?i:65533;throw Error("Invalid continuation byte")}if(240==(248&t)&&(i=(7&t)<<18|f()<<12|f()<<6|f())>=65536&&i<=1114111)return i;throw Error("Invalid UTF-8 detected")}e.exports={version:"2.1.2",encode:function(e,t){for(var n=!1!==(t=t||{}).strict,r=s(e),o=r.length,i=-1,a="";++i<o;)a+=u(r[i],n);return a},decode:function(e,t){var a=!1!==(t=t||{}).strict;n=s(e),r=n.length,o=0;for(var c,u=[];!1!==(c=l(a));)u.push(c);return function(e){for(var t,n=e.length,r=-1,o="";++r<n;)(t=e[r])>65535&&(o+=i((t-=65536)>>>10&1023|55296),t=56320|1023&t),o+=i(t);return o}(u)}}},function(e,t){!function(){"use strict";for(var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",n=new Uint8Array(256),r=0;r<e.length;r++)n[e.charCodeAt(r)]=r;t.encode=function(t){var n,r=new Uint8Array(t),o=r.length,i="";for(n=0;n<o;n+=3)i+=e[r[n]>>2],i+=e[(3&r[n])<<4|r[n+1]>>4],i+=e[(15&r[n+1])<<2|r[n+2]>>6],i+=e[63&r[n+2]];return o%3==2?i=i.substring(0,i.length-1)+"=":o%3==1&&(i=i.substring(0,i.length-2)+"=="),i},t.decode=function(e){var t,r,o,i,s,a=.75*e.length,c=e.length,u=0;"="===e[e.length-1]&&(a--,"="===e[e.length-2]&&a--);var f=new ArrayBuffer(a),l=new Uint8Array(f);for(t=0;t<c;t+=4)r=n[e.charCodeAt(t)],o=n[e.charCodeAt(t+1)],i=n[e.charCodeAt(t+2)],s=n[e.charCodeAt(t+3)],l[u++]=r<<2|o>>4,l[u++]=(15&o)<<4|i>>2,l[u++]=(3&i)<<6|63&s;return f}}()},function(e,t){var n=void 0!==n?n:"undefined"!=typeof WebKitBlobBuilder?WebKitBlobBuilder:"undefined"!=typeof MSBlobBuilder?MSBlobBuilder:"undefined"!=typeof MozBlobBuilder&&MozBlobBuilder,r=function(){try{return 2===new Blob(["hi"]).size}catch(e){return!1}}(),o=r&&function(){try{return 2===new Blob([new Uint8Array([1,2])]).size}catch(e){return!1}}(),i=n&&n.prototype.append&&n.prototype.getBlob;function s(e){return e.map((function(e){if(e.buffer instanceof ArrayBuffer){var t=e.buffer;if(e.byteLength!==t.byteLength){var n=new Uint8Array(e.byteLength);n.set(new Uint8Array(t,e.byteOffset,e.byteLength)),t=n.buffer}return t}return e}))}function a(e,t){t=t||{};var r=new n;return s(e).forEach((function(e){r.append(e)})),t.type?r.getBlob(t.type):r.getBlob()}function c(e,t){return new Blob(s(e),t||{})}"undefined"!=typeof Blob&&(a.prototype=Blob.prototype,c.prototype=Blob.prototype),e.exports=r?o?Blob:c:i?a:void 0},function(e,t,n){function r(e){var n;function r(){if(r.enabled){var e=r,o=+new Date,i=o-(n||o);e.diff=i,e.prev=n,e.curr=o,n=o;for(var s=new Array(arguments.length),a=0;a<s.length;a++)s[a]=arguments[a];s[0]=t.coerce(s[0]),"string"!=typeof s[0]&&s.unshift("%O");var c=0;s[0]=s[0].replace(/%([a-zA-Z%])/g,(function(n,r){if("%%"===n)return n;c++;var o=t.formatters[r];if("function"==typeof o){var i=s[c];n=o.call(e,i),s.splice(c,1),c--}return n})),t.formatArgs.call(e,s);var u=r.log||t.log||console.log.bind(console);u.apply(e,s)}}return r.namespace=e,r.enabled=t.enabled(e),r.useColors=t.useColors(),r.color=function(e){var n,r=0;for(n in e)r=(r<<5)-r+e.charCodeAt(n),r|=0;return t.colors[Math.abs(r)%t.colors.length]}(e),r.destroy=o,"function"==typeof t.init&&t.init(r),t.instances.push(r),r}function o(){var e=t.instances.indexOf(this);return-1!==e&&(t.instances.splice(e,1),!0)}(t=e.exports=r.debug=r.default=r).coerce=function(e){return e instanceof Error?e.stack||e.message:e},t.disable=function(){t.enable("")},t.enable=function(e){var n;t.save(e),t.names=[],t.skips=[];var r=("string"==typeof e?e:"").split(/[\s,]+/),o=r.length;for(n=0;n<o;n++)r[n]&&("-"===(e=r[n].replace(/\*/g,".*?"))[0]?t.skips.push(new RegExp("^"+e.substr(1)+"$")):t.names.push(new RegExp("^"+e+"$")));for(n=0;n<t.instances.length;n++){var i=t.instances[n];i.enabled=t.enabled(i.namespace)}},t.enabled=function(e){if("*"===e[e.length-1])return!0;var n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1},t.humanize=n(54),t.instances=[],t.names=[],t.skips=[],t.formatters={}},function(e,t){var n=1e3,r=6e4,o=60*r,i=24*o;function s(e,t,n){if(!(e<t))return e<1.5*t?Math.floor(e/t)+" "+n:Math.ceil(e/t)+" "+n+"s"}e.exports=function(e,t){t=t||{};var a,c=typeof e;if("string"===c&&e.length>0)return function(e){if((e=String(e)).length>100)return;var t=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(e);if(!t)return;var s=parseFloat(t[1]);switch((t[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*s;case"days":case"day":case"d":return s*i;case"hours":case"hour":case"hrs":case"hr":case"h":return s*o;case"minutes":case"minute":case"mins":case"min":case"m":return s*r;case"seconds":case"second":case"secs":case"sec":case"s":return s*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return s;default:return}}(e);if("number"===c&&!1===isNaN(e))return t.long?s(a=e,i,"day")||s(a,o,"hour")||s(a,r,"minute")||s(a,n,"second")||a+" ms":function(e){if(e>=i)return Math.round(e/i)+"d";if(e>=o)return Math.round(e/o)+"h";if(e>=r)return Math.round(e/r)+"m";if(e>=n)return Math.round(e/n)+"s";return e+"ms"}(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},function(e,t,n){(function(t){var r=n(20),o=n(6);e.exports=u;var i,s=/\n/g,a=/\\n/g;function c(){}function u(e){r.call(this,e),this.query=this.query||{},i||(t.___eio||(t.___eio=[]),i=t.___eio),this.index=i.length;var n=this;i.push((function(e){n.onData(e)})),this.query.j=this.index,t.document&&t.addEventListener&&t.addEventListener("beforeunload",(function(){n.script&&(n.script.onerror=c)}),!1)}o(u,r),u.prototype.supportsBinary=!1,u.prototype.doClose=function(){this.script&&(this.script.parentNode.removeChild(this.script),this.script=null),this.form&&(this.form.parentNode.removeChild(this.form),this.form=null,this.iframe=null),r.prototype.doClose.call(this)},u.prototype.doPoll=function(){var e=this,t=document.createElement("script");this.script&&(this.script.parentNode.removeChild(this.script),this.script=null),t.async=!0,t.src=this.uri(),t.onerror=function(t){e.onError("jsonp poll error",t)};var n=document.getElementsByTagName("script")[0];n?n.parentNode.insertBefore(t,n):(document.head||document.body).appendChild(t),this.script=t,"undefined"!=typeof navigator&&/gecko/i.test(navigator.userAgent)&&setTimeout((function(){var e=document.createElement("iframe");document.body.appendChild(e),document.body.removeChild(e)}),100)},u.prototype.doWrite=function(e,t){var n=this;if(!this.form){var r,o=document.createElement("form"),i=document.createElement("textarea"),c=this.iframeId="eio_iframe_"+this.index;o.className="socketio",o.style.position="absolute",o.style.top="-1000px",o.style.left="-1000px",o.target=c,o.method="POST",o.setAttribute("accept-charset","utf-8"),i.name="d",o.appendChild(i),document.body.appendChild(o),this.form=o,this.area=i}function u(){f(),t()}function f(){if(n.iframe)try{n.form.removeChild(n.iframe)}catch(e){n.onError("jsonp polling iframe removal error",e)}try{var e='<iframe src="javascript:0" name="'+n.iframeId+'">';r=document.createElement(e)}catch(e){(r=document.createElement("iframe")).name=n.iframeId,r.src="javascript:0"}r.id=n.iframeId,n.form.appendChild(r),n.iframe=r}this.form.action=this.uri(),f(),e=e.replace(a,"\\\n"),this.area.value=e.replace(s,"\\n");try{this.form.submit()}catch(e){}this.iframe.attachEvent?this.iframe.onreadystatechange=function(){"complete"===n.iframe.readyState&&u()}:this.iframe.onload=u}}).call(this,n(0))},function(e,t,n){(function(t){var r,o=n(11),i=n(2),s=n(5),a=n(6),c=n(21),u=n(7)("engine.io-client:websocket"),f=t.WebSocket||t.MozWebSocket;if("undefined"==typeof window)try{r=n(57)}catch(e){}var l=f;function h(e){e&&e.forceBase64&&(this.supportsBinary=!1),this.perMessageDeflate=e.perMessageDeflate,this.usingBrowserWebSocket=f&&!e.forceNode,this.protocols=e.protocols,this.usingBrowserWebSocket||(l=r),o.call(this,e)}l||"undefined"!=typeof window||(l=r),e.exports=h,a(h,o),h.prototype.name="websocket",h.prototype.supportsBinary=!0,h.prototype.doOpen=function(){if(this.check()){var e=this.uri(),t=this.protocols,n={agent:this.agent,perMessageDeflate:this.perMessageDeflate};n.pfx=this.pfx,n.key=this.key,n.passphrase=this.passphrase,n.cert=this.cert,n.ca=this.ca,n.ciphers=this.ciphers,n.rejectUnauthorized=this.rejectUnauthorized,this.extraHeaders&&(n.headers=this.extraHeaders),this.localAddress&&(n.localAddress=this.localAddress);try{this.ws=this.usingBrowserWebSocket?t?new l(e,t):new l(e):new l(e,t,n)}catch(e){return this.emit("error",e)}void 0===this.ws.binaryType&&(this.supportsBinary=!1),this.ws.supports&&this.ws.supports.binary?(this.supportsBinary=!0,this.ws.binaryType="nodebuffer"):this.ws.binaryType="arraybuffer",this.addEventListeners()}},h.prototype.addEventListeners=function(){var e=this;this.ws.onopen=function(){e.onOpen()},this.ws.onclose=function(){e.onClose()},this.ws.onmessage=function(t){e.onData(t.data)},this.ws.onerror=function(t){e.onError("websocket error",t)}},h.prototype.write=function(e){var n=this;this.writable=!1;for(var r=e.length,o=0,s=r;o<s;o++)!function(e){i.encodePacket(e,n.supportsBinary,(function(o){if(!n.usingBrowserWebSocket){var i={};if(e.options&&(i.compress=e.options.compress),n.perMessageDeflate)("string"==typeof o?t.Buffer.byteLength(o):o.length)<n.perMessageDeflate.threshold&&(i.compress=!1)}try{n.usingBrowserWebSocket?n.ws.send(o):n.ws.send(o,i)}catch(e){u("websocket closed before onclose event")}--r||a()}))}(e[o]);function a(){n.emit("flush"),setTimeout((function(){n.writable=!0,n.emit("drain")}),0)}},h.prototype.onClose=function(){o.prototype.onClose.call(this)},h.prototype.doClose=function(){void 0!==this.ws&&this.ws.close()},h.prototype.uri=function(){var e=this.query||{},t=this.secure?"wss":"ws",n="";return this.port&&("wss"===t&&443!==Number(this.port)||"ws"===t&&80!==Number(this.port))&&(n=":"+this.port),this.timestampRequests&&(e[this.timestampParam]=c()),this.supportsBinary||(e.b64=1),(e=s.encode(e)).length&&(e="?"+e),t+"://"+(-1!==this.hostname.indexOf(":")?"["+this.hostname+"]":this.hostname)+n+this.path+e},h.prototype.check=function(){return!(!l||"__initialize"in l&&this.name===h.prototype.name)}}).call(this,n(0))},function(e,t){},function(e,t){e.exports=function(e,t){for(var n=[],r=(t=t||0)||0;r<e.length;r++)n[r-t]=e[r];return n}},function(e,t){function n(e){e=e||{},this.ms=e.min||100,this.max=e.max||1e4,this.factor=e.factor||2,this.jitter=e.jitter>0&&e.jitter<=1?e.jitter:0,this.attempts=0}e.exports=n,n.prototype.duration=function(){var e=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var t=Math.random(),n=Math.floor(t*this.jitter*e);e=0==(1&Math.floor(10*t))?e-n:e+n}return 0|Math.min(e,this.max)},n.prototype.reset=function(){this.attempts=0},n.prototype.setMin=function(e){this.ms=e},n.prototype.setMax=function(e){this.max=e},n.prototype.setJitter=function(e){this.jitter=e}},function(e,t,n){"use strict";var r,o="object"==typeof Reflect?Reflect:null,i=o&&"function"==typeof o.apply?o.apply:function(e,t,n){return Function.prototype.apply.call(e,t,n)};r=o&&"function"==typeof o.ownKeys?o.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};var s=Number.isNaN||function(e){return e!=e};function a(){a.init.call(this)}e.exports=a,e.exports.once=function(e,t){return new Promise((function(n,r){function o(n){e.removeListener(t,i),r(n)}function i(){"function"==typeof e.removeListener&&e.removeListener("error",o),n([].slice.call(arguments))}m(e,t,i,{once:!0}),"error"!==t&&function(e,t,n){"function"==typeof e.on&&m(e,"error",t,n)}(e,o,{once:!0})}))},a.EventEmitter=a,a.prototype._events=void 0,a.prototype._eventsCount=0,a.prototype._maxListeners=void 0;var c=10;function u(e){if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function f(e){return void 0===e._maxListeners?a.defaultMaxListeners:e._maxListeners}function l(e,t,n,r){var o,i,s,a;if(u(n),void 0===(i=e._events)?(i=e._events=Object.create(null),e._eventsCount=0):(void 0!==i.newListener&&(e.emit("newListener",t,n.listener?n.listener:n),i=e._events),s=i[t]),void 0===s)s=i[t]=n,++e._eventsCount;else if("function"==typeof s?s=i[t]=r?[n,s]:[s,n]:r?s.unshift(n):s.push(n),(o=f(e))>0&&s.length>o&&!s.warned){s.warned=!0;var c=new Error("Possible EventEmitter memory leak detected. "+s.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");c.name="MaxListenersExceededWarning",c.emitter=e,c.type=t,c.count=s.length,a=c,console&&console.warn&&console.warn(a)}return e}function h(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function p(e,t,n){var r={fired:!1,wrapFn:void 0,target:e,type:t,listener:n},o=h.bind(r);return o.listener=n,r.wrapFn=o,o}function d(e,t,n){var r=e._events;if(void 0===r)return[];var o=r[t];return void 0===o?[]:"function"==typeof o?n?[o.listener||o]:[o]:n?function(e){for(var t=new Array(e.length),n=0;n<t.length;++n)t[n]=e[n].listener||e[n];return t}(o):g(o,o.length)}function y(e){var t=this._events;if(void 0!==t){var n=t[e];if("function"==typeof n)return 1;if(void 0!==n)return n.length}return 0}function g(e,t){for(var n=new Array(t),r=0;r<t;++r)n[r]=e[r];return n}function m(e,t,n,r){if("function"==typeof e.on)r.once?e.once(t,n):e.on(t,n);else{if("function"!=typeof e.addEventListener)throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof e);e.addEventListener(t,(function o(i){r.once&&e.removeEventListener(t,o),n(i)}))}}Object.defineProperty(a,"defaultMaxListeners",{enumerable:!0,get:function(){return c},set:function(e){if("number"!=typeof e||e<0||s(e))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");c=e}}),a.init=function(){void 0!==this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},a.prototype.setMaxListeners=function(e){if("number"!=typeof e||e<0||s(e))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+e+".");return this._maxListeners=e,this},a.prototype.getMaxListeners=function(){return f(this)},a.prototype.emit=function(e){for(var t=[],n=1;n<arguments.length;n++)t.push(arguments[n]);var r="error"===e,o=this._events;if(void 0!==o)r=r&&void 0===o.error;else if(!r)return!1;if(r){var s;if(t.length>0&&(s=t[0]),s instanceof Error)throw s;var a=new Error("Unhandled error."+(s?" ("+s.message+")":""));throw a.context=s,a}var c=o[e];if(void 0===c)return!1;if("function"==typeof c)i(c,this,t);else{var u=c.length,f=g(c,u);for(n=0;n<u;++n)i(f[n],this,t)}return!0},a.prototype.addListener=function(e,t){return l(this,e,t,!1)},a.prototype.on=a.prototype.addListener,a.prototype.prependListener=function(e,t){return l(this,e,t,!0)},a.prototype.once=function(e,t){return u(t),this.on(e,p(this,e,t)),this},a.prototype.prependOnceListener=function(e,t){return u(t),this.prependListener(e,p(this,e,t)),this},a.prototype.removeListener=function(e,t){var n,r,o,i,s;if(u(t),void 0===(r=this._events))return this;if(void 0===(n=r[e]))return this;if(n===t||n.listener===t)0==--this._eventsCount?this._events=Object.create(null):(delete r[e],r.removeListener&&this.emit("removeListener",e,n.listener||t));else if("function"!=typeof n){for(o=-1,i=n.length-1;i>=0;i--)if(n[i]===t||n[i].listener===t){s=n[i].listener,o=i;break}if(o<0)return this;0===o?n.shift():function(e,t){for(;t+1<e.length;t++)e[t]=e[t+1];e.pop()}(n,o),1===n.length&&(r[e]=n[0]),void 0!==r.removeListener&&this.emit("removeListener",e,s||t)}return this},a.prototype.off=a.prototype.removeListener,a.prototype.removeAllListeners=function(e){var t,n,r;if(void 0===(n=this._events))return this;if(void 0===n.removeListener)return 0===arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==n[e]&&(0==--this._eventsCount?this._events=Object.create(null):delete n[e]),this;if(0===arguments.length){var o,i=Object.keys(n);for(r=0;r<i.length;++r)"removeListener"!==(o=i[r])&&this.removeAllListeners(o);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if("function"==typeof(t=n[e]))this.removeListener(e,t);else if(void 0!==t)for(r=t.length-1;r>=0;r--)this.removeListener(e,t[r]);return this},a.prototype.listeners=function(e){return d(this,e,!0)},a.prototype.rawListeners=function(e){return d(this,e,!1)},a.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):y.call(e,t)},a.prototype.listenerCount=y,a.prototype.eventNames=function(){return this._eventsCount>0?r(this._events):[]}},function(e){e.exports=JSON.parse('{"name":"offload.js","version":"0.4.1","description":"","main":"dist/offload.js","scripts":{"build":"webpack --config ./webpack.dev.js","build:prod":"webpack --config ./webpack.prod.js","build:apps":"./script/build-script.js --all","dev":"npm-run-all --parallel watch:offload watch:server","lint":"npm run lint:prettier && npm run lint:eslint","lint:eslint":"eslint --fix \\"**/*.js\\"","lint:prettier":"prettier --write --ignore-unknown \\"**/*.js\\"","release":"release-it","castanets":"cp dist/offload-worker.js offload-worker/android/app/libs/","test":"karma start ./karma.conf.js","test:e2e":"cypress open","watch:offload":"nodemon --watch offload.js -e \'js,css\' --exec npm run build","watch:server":"nodemon --watch offload-server/src offload-server/src/app.js"},"author":"Hunseop Jeong <hs85.jeong@samsung.com>","dependencies":{"debug":"4.3.1","express":"4.17.1","filemanager-webpack-plugin":"2.0.5","lokijs":"1.5.11","qrcode":"1.4.4","serve-index":"1.9.1","socket.io":"2.3.0","socket.io-client":"2.0.2","ua-parser-js":"0.7.21","uuid":"8.2.0"},"devDependencies":{"@babel/core":"7.12.3","@babel/plugin-transform-modules-commonjs":"7.12.1","@babel/preset-env":"7.12.1","babel-eslint":"10.1.0","babel-loader":"8.1.0","commander":"6.2.0","css-loader":"3.5.3","cypress":"6.5.0","eslint":"7.30.0","eslint-config-google":"0.14.0","eslint-config-prettier":"8.3.0","filemanager-webpack-plugin":"2.0.5","fs-extra":"9.0.1","glob":"7.1.6","husky":"4.3.0","istanbul":"0.4.5","istanbul-instrumenter-loader":"3.0.1","karma":"5.2.3","karma-chrome-launcher":"3.1.0","karma-coverage":"2.0.3","karma-expect":"1.1.3","karma-mocha":"2.0.1","karma-sinon":"1.0.5","karma-webpack":"4.0.2","lint-staged":"10.3.0","mocha":"8.1.3","mustache-loader":"1.4.3","nodemon":"2.0.4","npm-run-all":"4.1.5","prettier":"2.3.2","release-it":"14.2.0","rimraf":"3.0.2","sinon":"9.2.0","to-string-loader":"1.1.6","url-loader":"4.1.1","webpack":"4.44.2","webpack-cli":"3.3.12","webpack-merge":"5.1.4"},"husky":{"hooks":{"pre-commit":"lint-staged"}},"lint-staged":{"**/*.js":"npm run lint"},"repository":{"type":"git","url":"git@github.sec.samsung.net:HighPerformanceWeb/offload.js.git"},"release-it":{"npm":{"publish":false},"github":{"release":true,"assets":["dist/*"]},"hooks":{"before:init":["npm run lint"],"after:bump":["npm run build:prod","npm run castanets","npm run build:apps"]}}}')},function(e,t,n){"use strict";var r;function o(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}Object.defineProperty(t,"__esModule",{value:!0}),t.Worker=void 0;var i=new(((r=n(1))&&r.__esModule?r:{default:r}).default)("worker.js"),s=1e3,a=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.options=t||{},this.debugEnabled=this.options.debug||!1,this.dataChannel=null,this.peerConnection=null,this.features=new Set,this.confirmations=new Map}var t,n,r;return t=e,(n=[{key:"setPeerConnection",value:function(e){this.peerConnection=e}},{key:"setDataChannel",value:function(e){this.dataChannel=e}},{key:"hasFeature",value:function(e){return this.features.has(e)}},{key:"requestConfirmation",value:function(e,t,n){var r=this;return i.debug("requestConfirmation feature:".concat(e," clientId:").concat(t," deviceName:").concat(n)),new Promise((function(o){"undefined"!=typeof android?(android.emit("requestConfirmation",JSON.stringify({id:s,feature:e,clientId:t,deviceName:n})),r.confirmations.set(s,o),s++):o(!0)}))}},{key:"onConfirmationResult",value:function(e,t){return i.debug("onConfirmationResult id:".concat(e," allowed:").concat(t)),!!this.confirmations.has(e)&&(this.confirmations.get(e)(t),this.confirmations.delete(e),!0)}},{key:"sendData",value:function(e){this.dataChannel?this.dataChannel.send(JSON.stringify(e)):i.error("dataChannel is not open yet")}}])&&o(t.prototype,n),r&&o(t,r),e}();t.Worker=a},,,,,,,,,,,,,,,,,,,,,,,,,function(e,t,n){e.exports=n(88)},function(e,t,n){"use strict";var r=n(89),o=n(95);window.localStorage.setItem("debug","offload:INFO*, offload:ERROR*");var i=new o.OffloadWorker(new r.OffloadWorkerImpl);window.offloadWorker=i},function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.OffloadWorkerImpl=void 0;var o=u(n(60)),i=u(n(32)),s=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var n=c(t);if(n&&n.has(e))return n.get(e);var o={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&Object.prototype.hasOwnProperty.call(e,s)){var a=i?Object.getOwnPropertyDescriptor(e,s):null;a&&(a.get||a.set)?Object.defineProperty(o,s,a):o[s]=e[s]}o.default=e,n&&n.set(e,o);return o}(n(90)),a=n(27);function c(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(c=function(e){return e?n:t})(e)}function u(e){return e&&e.__esModule?e:{default:e}}function f(e,t,n,r,o,i,s){try{var a=e[i](s),c=a.value}catch(e){return void n(e)}a.done?t(c):Promise.resolve(c).then(r,o)}function l(e){return function(){var t=this,n=arguments;return new Promise((function(r,o){var i=e.apply(t,n);function s(e){f(i,r,o,s,a,"next",e)}function a(e){f(i,r,o,s,a,"throw",e)}s(void 0)}))}}function h(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function p(e,t){return(p=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function d(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=g(e);if(t){var o=g(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return y(this,n)}}function y(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function g(e){return(g=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var m=new(u(n(1)).default)("offload-worker-impl.js"),v=(0,a.optionEnabled)("debug"),b=Object.freeze({IDLE:0,CONNECTING:1,CONNECTED:2}),w=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&p(e,t)}(f,e);var t,n,r,o,c,u=d(f);function f(){var e;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,f),(e=u.call(this))._socket=null,e._peerConnection=null,e._dataChannel=null,e._id=null,e._peerId=null,e._currentUrl=null,e._features=null,e._mediaDeviceInfos=null,e._deviceName=null,e._workers=[],e._connectionStatus=b.IDLE,e._initialize(),e}return t=f,(n=[{key:"_initialize",value:function(){this._id=localStorage.getItem("workerId"),null===this._id&&(this._id=(0,a.getUniqueId)(),m.debug("New workerId : ".concat(this._id)),localStorage.setItem("workerId",this._id));for(var e=0,t=Object.values(s);e<t.length;e++){var n=t[e];this._workers.push(new n({debug:v}))}}},{key:"connect",value:function(e,t){if(this._deviceName=t&&t.deviceName||(0,a.getDeviceName)(),null===e||e.includes("file://"))m.error("No valid server URL found.");else{if(e.endsWith("/offload-js")||(e+="/offload-js"),this._connectionStatus!==b.IDLE){if(!t||!t.forceConnect)return void m.debug("Already connected or connecting to ".concat(this._currentUrl));this._socket.disconnect(),this._connectionStatus=b.IDLE}m.debug("Try to connect to ".concat(e)),this._createSocket(e),this._connectionStatus=b.CONNECTING,this._currentUrl=e}}},{key:"onConfirmationResult",value:function(e,t){this._workers.some((function(n){return n.onConfirmationResult(e,t)}))}},{key:"checkCapability",value:(c=l((function*(){m.debug("checkCapability");var e="";yield this._getCapability(),"undefined"!=typeof android&&(e=Array.from(this._features).toString(),android.emit("writeCapability",JSON.stringify({id:this._id,name:(0,a.getDeviceName)(),features:e})))})),function(){return c.apply(this,arguments)})},{key:"_createSocket",value:function(e){var t=this;this._socket=(0,i.default)(e,{transports:["websocket"],reconnectionAttempts:5}),this._socket.on("connect",l((function*(){m.debug("".concat(t._socket.id," connected")),t._connectionStatus=b.CONNECTED,yield t._getCapability(),t._join(),t.emit("connect",t._currentUrl)}))),this._socket.on("reconnect_attempt",(function(){m.debug("reconnect attempt"),t._socket.io.opts.transports=["polling","websocket"]})),this._socket.on("connect_error",(function(e){m.error("connect error: %o",e)})),this._socket.on("reconnect_failed",(function(){m.error("reconnect failed"),t._connectionStatus=b.IDLE})),this._socket.on("disconnect",(function(e){m.debug("disconnect ".concat(e)),t._connectionStatus=b.IDLE})),this._socket.on("client",this._handleClient.bind(this)),this._socket.on("message",this._handleMessage.bind(this))}},{key:"_getCapability",value:(o=l((function*(){var e=this;if(m.debug("_getCapability"),null===this._features&&(this._features=new Set,yield Promise.all(this._workers.map(function(){var t=l((function*(t){(yield t.checkCapability()).forEach((function(t){e._features.add(t)}))}));return function(e){return t.apply(this,arguments)}}())),this._features.has("CAMERA")||this._features.has("MIC")))try{this._mediaDeviceInfos=yield navigator.mediaDevices.enumerateDevices()}catch(e){m.error(e.name+": "+e.message)}})),function(){return o.apply(this,arguments)})},{key:"_join",value:function(){this._socket.emit("join",{id:this._id,name:this._deviceName,features:Array.from(this._features),mediaDeviceInfos:this._mediaDeviceInfos})}},{key:"_handleClient",value:function(e){"bye"===e.event?(m.debug("client bye: '".concat(e.socketId,"'")),this._hangup(e.socketId)):"forceQuit"===e.event&&(m.debug("offload-worker will be closed now!"),"undefined"!=typeof tizen?tizen.application.getCurrentApplication().exit():"undefined"!=typeof android?android.emit("destroyService",""):window.open("","_self").close())}},{key:"_hangup",value:function(e){e&&e!==this._peerId||(m.debug("hangup"),null!==this._peerConnection&&(null!==this._dataChannel&&(this._dataChannel.onopen=null,this._dataChannel.onclose=null,this._dataChannel.onmessage=null,this._dataChannel.close(),this._dataChannel=null,this._workers.forEach((function(e){e.setDataChannel(null)}))),this._peerConnection.onnegotiationneeded=null,this._peerConnection.onicecandidate=null,this._peerConnection.ondatachannel=null,this._peerConnection.close(),this._peerConnection=null,this._workers.forEach((function(e){e.setPeerConnection(null)}))),this._peerId=null)}},{key:"_handleMessage",value:function(e,t){"offer"===e.message.type?(this._setupPeerConnectionIfNeeded(e.from),this._handleOffer(e.message)):"answer"===e.message.type?this._handleAnswer(e.message):"candidate"===e.message.type?this._handleCandidate(e.message.candidate):m.error("unhandled message type: ".concat(e.message.type))}},{key:"_setupPeerConnectionIfNeeded",value:function(e){var t=this;null===this._peerConnection&&(m.debug("create peer connection. "+e),this._peerConnection=new RTCPeerConnection,this._peerConnection.onnegotiationneeded=this._handleNegotiationNeeded.bind(this),this._peerConnection.onicecandidate=this._handleIceCandidate.bind(this),this._peerConnection.ondatachannel=this._handleDataChannel.bind(this),this._workers.forEach((function(e){e.setPeerConnection(t._peerConnection)})),this._peerId=e)}},{key:"_handleNegotiationNeeded",value:function(){var e=this;this._peerConnection.createOffer().then((function(t){return"stable"!==e._peerConnection.signalingState?new DOMException("The RTCPeerConnection's signalingState is not 'statble'","InvalidStateError"):e._peerConnection.setLocalDescription(t)})).then((function(){m.debug("send offer"),e._sendPeerMessage(e._peerConnection.localDescription)})).catch((function(e){return m.error(TAG+"reason: "+e.message)}))}},{key:"_handleIceCandidate",value:function(e){e.candidate&&(m.debug("send candidate"),this._sendPeerMessage({type:"candidate",candidate:e.candidate}))}},{key:"_handleDataChannel",value:function(e){var t=this;this._dataChannel=e.channel,this._dataChannel.onopen=function(){m.debug("data channel opened"),t._workers.forEach((function(e){e.setDataChannel(t._dataChannel)}))},this._dataChannel.onclose=function(){m.debug("data channel closed"),t._hangup()},this._dataChannel.onmessage=function(e){var n=JSON.parse(e.data);t._workers.forEach((function(e){e.hasFeature(n.feature)&&e.handleMessage(n)}))}}},{key:"_handleOffer",value:function(e){var t=this;m.debug("got offer"),this._peerConnection.setRemoteDescription(e).then((function(){return t._peerConnection.createAnswer()})).then((function(e){return t._peerConnection.setLocalDescription(e)})).then((function(){m.debug("send answer"),t._sendPeerMessage(t._peerConnection.localDescription)})).catch((function(e){return m.error("reason: "+e.toString())}))}},{key:"_handleAnswer",value:function(e){m.debug("got answer"),this._peerConnection.setRemoteDescription(e).catch((function(e){return m.error("reason: "+e.toString())}))}},{key:"_handleCandidate",value:function(e){m.debug("got candidate"),this._peerConnection.addIceCandidate(e).catch((function(e){return m.error("reason: "+e.toString())}))}},{key:"_sendPeerMessage",value:function(e){null!==this._socket&&this._socket.emit("message",{to:this._peerId,from:this._id,message:e})}}])&&h(t.prototype,n),r&&h(t,r),f}(o.default);t.OffloadWorkerImpl=w},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"HAMWorker",{enumerable:!0,get:function(){return r.HAMWorker}}),Object.defineProperty(t,"GUMWorker",{enumerable:!0,get:function(){return o.GUMWorker}}),Object.defineProperty(t,"SensorWorker",{enumerable:!0,get:function(){return i.SensorWorker}});var r=n(91),o=n(92),i=n(94)},function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.HAMWorker=void 0;var o,i=n(62);function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function a(e,t){return(a=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function c(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=f(e);if(t){var o=f(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return u(this,n)}}function u(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function f(e){return(f=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var l=new(((o=n(1))&&o.__esModule?o:{default:o}).default)("ham.js"),h=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&a(e,t)}(i,e);var t,n,r,o=c(i);function i(){var e;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),(e=o.call(this)).listenerId=0,e.intervalId=0,e}return t=i,(n=[{key:"checkCapability",value:function(){return("undefined"!=typeof tizen&&tizen.humanactivitymonitor||this.debugEnabled)&&(this.features.add("HRM"),this.features.add("PEDOMETER"),this.features.add("GESTURE")),this.features}},{key:"handleMessage",value:function(e){switch(e.feature){case"PEDOMETER":case"HRM":"start"===e.type?this.startHam(e.feature):this.stopHam(e.feature);break;case"GESTURE":"start"===e.type?this.startGestureRecognition():this.stopGestureRecognition();break;default:l.debug("unsupported feature",e.feature)}}},{key:"startHam",value:function(e){var t=this;l.debug("start HAM");var n=e,r={},o=this;this.debugEnabled?this.intervalId=setInterval((function(){"HRM"===n?(r.heartRate=Math.floor(150*Math.random()+50),r.rRInterval=0):"PEDOMETER"===n&&(r.stepStatus="WALKING",r.cumulativeTotalStepCount=Math.floor(150*Math.random()+50)),t.sendData({type:"data",feature:n,data:r})}),1e3):tizen.ppm.requestPermission("http://tizen.org/privilege/healthinfo",(function(){tizen.humanactivitymonitor.start(n,(function(e){"HRM"===n?(r.heartRate=e.heartRate,r.rRInterval=e.rRInterval):"PEDOMETER"===n&&(r.stepStatus=e.stepStatus,r.speed=e.speed,r.walkingFrequency=e.walkingFrequency,r.cumulativeDistance=e.cumulativeDistance,r.cumulativeCalorie=e.cumulativeCalorie,r.cumulativeTotalStepCount=e.cumulativeTotalStepCount,r.cumulativeWalkStepCount=e.cumulativeWalkStepCount,r.cumulativeRunStepCount=e.cumulativeRunStepCount,r.stepCountDifferences=e.stepCountDifferences.slice()),o.sendData({type:"data",feature:n,data:r})}))}),(function(e){return l.error("error: "+JSON.stringify(e))}))}},{key:"stopHam",value:function(e){tizen.humanactivitymonitor.stop(e)}},{key:"startGestureRecognition",value:function(){var e=this;if(!(this.listenerId>0))if(this.debugEnabled)this.intervalId=setInterval((function(){e.sendData({type:"data",feature:"GESTURE",data:{type:"GESTURE_WRIST_UP",event:"GESTURE_EVENT_DETECTED",timestamp:(new Date).getTime()}})}),3e3);else try{this.listenerId=tizen.humanactivitymonitor.addGestureRecognitionListener("GESTURE_WRIST_UP",(function(t){l.debug("Received "+t.event+" event on "+new Date(1e3*t.timestamp)+" for "+t.type+" type"),e.sendData({type:"data",feature:"GESTURE",data:{type:t.type,event:t.event,timestamp:t.timestamp}})}),(function(e){return l.error("error: "+JSON.stringify(e))}),!0),l.debug("Listener with id "+this.listenerId+" has been added")}catch(e){l.error("error: "+JSON.stringify(e))}}},{key:"stopGestureRecognition",value:function(){this.listenerId>0&&tizen.humanactivitymonitor.removeGestureRecognitionListener(this.listenerId)}}])&&s(t.prototype,n),r&&s(t,r),i}(i.Worker);t.HAMWorker=h},function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.GUMWorker=void 0;var o=n(62),i=a(n(1)),s=a(n(93));function a(e){return e&&e.__esModule?e:{default:e}}function c(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return u(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return u(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,s=!0,a=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return s=e.done,e},e:function(e){a=!0,i=e},f:function(){try{s||null==n.return||n.return()}finally{if(a)throw i}}}}function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function f(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function l(e,t){return(l=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d(e);if(t){var o=d(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return p(this,n)}}function p(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function d(e){return(d=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var y=new i.default("gum.js"),g=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&l(e,t)}(i,e);var t,n,r,o=h(i);function i(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),(t=o.call(this,e)).mediaStream=null,t}return t=i,(n=[{key:"checkCapability",value:function(){var e=this;return y.debug("checkCapability"),"undefined"!=typeof android&&alert(RTCRtpSender.getCapabilities("video")),this.debugEnabled?(this.features.add("CAMERA"),this.features.add("MIC"),this.features):new Promise((function(t,n){navigator.mediaDevices.enumerateDevices().then((function(n){n.forEach((function(t){"videoinput"===t.kind&&e.features.add("CAMERA"),"audioinput"===t.kind&&e.features.add("MIC")})),t(e.features)})).catch((function(t){y.error("err.code: "+t.code),y.error(t.name+": "+t.message),n(e.features)}))})).catch((function(t){return e.features}))}},{key:"handleMessage",value:function(e){var t=this;if("start"===e.type)this.requestConfirmation(e.feature,e.clientId,e.deviceName).then((function(n){n?t.startGum(e.arguments[0],e.feature):t.sendData({type:"error",feature:e.feature,error:{message:"Permission denied",name:"NotAllowedError"}})}));else if("applyConstraints"===e.type)this.applyConstraints(e.constraints,e.feature);else if("stopTrack"===e.type){var n=this.peerConnection.getTransceivers().find((function(t){return t.sender&&t.sender.track.id===e.trackId}));n&&n.sender?(n.sender.track.stop(),n.stop(),this.peerConnection.removeTrack(n.sender)):y.log("Failed to stopTrack() "+e.trackId)}}},{key:"setPreferredCodecs",value:function(e,t){var n=this.peerConnection.getTransceivers().find((function(t){return t.sender&&t.sender.track===e}));n?(t=s.default.getPreferredCodecs(t),n.direction="sendonly",n.setCodecPreferences(t)):(y.warn("Can't find transceiver for "+e.label),y.debug(JSON.stringify(e)))}},{key:"getStream",value:function(e,t,n){var r=this;y.debug("getStream feature:".concat(n," ").concat(e.id));var o,i=c(e.getTracks());try{for(i.s();!(o=i.n()).done;){var s=o.value;"video"===s.kind?y.info("[Track:video]"+" ".concat(s.label)+", size:".concat(s.getSettings().width,"x").concat(s.getSettings().height)+", frameRate:".concat(s.getSettings().frameRate)):console.info("[Track:".concat(s.kind,"] id:").concat(s.id)),y.debug("track:".concat(JSON.stringify(s))),y.debug("settings:".concat(JSON.stringify(s.getSettings()))),y.debug("constraints:".concat(JSON.stringify(s.getConstraints()))),y.debug("capabilities:".concat(JSON.stringify(s.getCapabilities())))}}catch(e){i.e(e)}finally{i.f()}if(this.mediaStream=e,e.peerConnection=this.peerConnection,e.onaddtrack=function(e){return y.debug("onaddtrack"+JSON.stringify(e))},e.onremovetrack=function(e){return y.debug("onremovetrack"+JSON.stringify(e))},e.onactive=function(e){return y.debug("onactive"+JSON.stringify(e))},e.oninactive=function(e){return y.debug("oninactive"+JSON.stringify(e))},e.getTracks().forEach((function(t){r.peerConnection.addTrack(t,e)})),t.offload&&t.offload.videoCodecs&&this.setPreferredCodecs(e.getVideoTracks()[0],t.offload.videoCodecs),"CAMERA"===n){var a=e.getVideoTracks()[0];if(void 0===a.getCapabilities){if(void 0===a.getConstraints)throw new Error("getCapabilities is not supported");a.getCapabilities=a.getConstraints}this.sendData({type:"data",feature:n,data:{capabilities:a.getCapabilities(),settings:a.getSettings(),constraints:a.getConstraints()}})}offloadWorker.impl.emit("stream",e)}},{key:"startGum",value:function(e,t){var n=this;y.debug("startGum constraints:".concat(JSON.stringify(e)," feature:").concat(t)),this.debugEnabled?navigator.mediaDevices.getDisplayMedia({video:!0}).then((function(r){return n.getStream(r,e,t)})).catch((function(e){y.error("error: "+e)})):navigator.mediaDevices.getUserMedia(e).then((function(r){return n.getStream(r,e,t)})).catch((function(e){y.error("error: "+e),n.sendData({type:"error",feature:t,error:{message:e.message,name:e.name}})}))}},{key:"applyConstraints",value:function(e,t){var n=this;y.debug("applyConstraints ".concat(JSON.stringify(e)," feature:").concat(t));var r=this.mediaStream.getVideoTracks()[0];r.applyConstraints(e).then((function(){n.sendData({type:"applyConstraints",feature:t,result:"success",data:{settings:r.getSettings(),constraints:r.getConstraints()}})})).catch((function(e){n.sendData({type:"applyConstraints",feature:t,result:"error",error:{message:e.message,name:e.name}})}))}}])&&f(t.prototype,n),r&&f(t,r),i}(o.Worker);t.GUMWorker=g},function(e,t,n){"use strict";var r;function o(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return i(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return i(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var s,a=!0,c=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){c=!0,s=e},f:function(){try{a||null==n.return||n.return()}finally{if(c)throw s}}}}function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var a=new(((r=n(1))&&r.__esModule?r:{default:r}).default)("codec-helper.js"),c=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e)}var t,n,r;return t=e,r=[{key:"getPreferredCodecs",value:function(e){Array.isArray(e)||(e=[e]);var t=[];if(e.length>0){var n,r=RTCRtpSender.getCapabilities("video").codecs,i=o(e);try{var s=function(){var e=n.value;r=r.filter((function(n){return!n.mimeType.match(new RegExp(e,"i"))||(t.push(n),!1)}))};for(i.s();!(n=i.n()).done;)s()}catch(e){i.e(e)}finally{i.f()}var c,u="",f=o(t=t.concat(r));try{for(f.s();!(c=f.n()).done;){var l=c.value;-1===u.indexOf(l.mimeType)&&(u+=l.mimeType+", ")}}catch(e){f.e(e)}finally{f.f()}a.info("codec order : "+u)}return t}}],(n=null)&&s(t.prototype,n),r&&s(t,r),e}();t.default=c},function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.SensorWorker=void 0;var o,i=n(62);function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function a(e,t){return(a=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function c(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=f(e);if(t){var o=f(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return u(this,n)}}function u(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function f(e){return(f=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var l=new(((o=n(1))&&o.__esModule?o:{default:o}).default)("sensor.js"),h=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&a(e,t)}(i,e);var t,n,r,o=c(i);function i(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),(t=o.call(this,e))._sensor=null,t}return t=i,(n=[{key:"checkCapability",value:function(){return l.debug("checkCapability sensor"),"undefined"!=typeof tizen&&tizen.sensorservice&&this.features.add("SENSOR"),this.debugEnabled?(this.features.add("SENSOR"),this.features):this.features}},{key:"handleMessage",value:function(e){"start"===e.arguments[0]?this._start(e.arguments[1]):"stop"===e.arguments[0]?this._stop():"getSensorData"===e.arguments[0]&&this._getSensorData(e.arguments[1])}},{key:"_getSensorData",value:function(e){l.debug("getSensorData:"+e);var t=this;this._sensor["get".concat(e,"SensorData")]((function(e){l.debug("successCallback:"+JSON.stringify(e)),t.sendData({type:"data",feature:"SENSOR",data:e})}))}},{key:"_start",value:function(e){var t=this;l.debug("startSensor: "+e);var n=this;try{this._sensor=tizen.sensorservice.getDefaultSensor(e),this._sensor.start((function(){l.debug("successCallback"),n.sendData({type:"data",feature:"SENSOR"})}),(function(e){l.error("errorCallback: "+JSON.stringify(e.message)),n.sendData({type:"error",feature:"SENSOR",error:{name:e.name,message:e.message}})}))}catch(e){l.error("error: "+JSON.stringify(e.message)),setTimeout((function(){t.sendData({type:"error",feature:"SENSOR",error:{message:e.message,name:e.name}})}),1e3)}}},{key:"_stop",value:function(){l.debug("stopSensor"),this._sensor&&this._sensor.stop(),this._sensor=null}}])&&s(t.prototype,n),r&&s(t,r),i}(i.Worker);t.SensorWorker=h},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.OffloadWorker=void 0;var r,o=n(61);function i(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}new(((r=n(1))&&r.__esModule?r:{default:r}).default)("offload-worker.js").info("offloadWorker version: ".concat(o.version));var s=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this._impl=t,this.version=o.version}var t,n,r;return t=e,(n=[{key:"connect",value:function(e,t){this._impl.connect(e,t)}},{key:"on",value:function(e,t){this._impl.on(e,t)}},{key:"onConfirmationResult",value:function(e,t){this._impl.onConfirmationResult(e,t)}},{key:"checkCapability",value:function(){this._impl.checkCapability()}},{key:"impl",get:function(){return this._impl}}])&&i(t.prototype,n),r&&i(t,r),e}();t.OffloadWorker=s}]).default;
\ No newline at end of file
index cdb56b1..66a50a5 100644 (file)
@@ -1,18 +1,20 @@
-window.offload=function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=64)}([function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r,o=(r=n(61))&&r.__esModule?r:{default:r};function i(e){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var a="offload",c=function(){function e(t){if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),!t)throw new Error("Need a prefix when creating Logger class");this._debug=(0,o.default)("".concat(a,":DEBUG:").concat(t)),this._error=(0,o.default)("".concat(a,":ERROR:").concat(t)),this._info=(0,o.default)("".concat(a,":INFO:").concat(t)),this._log=(0,o.default)("".concat(a,":LOG:").concat(t)),this._warn=(0,o.default)("".concat(a,":WARN:").concat(t)),this._table=(0,o.default)("".concat(a,":TABLE:").concat(t)),this._time=(0,o.default)("".concat(a,":TIME:")),this._timeEnd=(0,o.default)("".concat(a,":TIME:")),this._debug.log=console.debug.bind(console),this._error.log=console.error.bind(console),this._info.log=console.info.bind(console),this._log.log=console.log.bind(console),this._warn.log=console.warn.bind(console),this._time.log=console.time.bind(console),this._timeEnd.log=console.timeEnd.bind(console),this._table.log=console.table.bind(console),this._replacePrintLog("offloadLogText")}var t,n,r;return t=e,(n=[{key:"_makeLogMessage",value:function(e,t){var n=new Date;return e="object"===i(e)?JSON.stringify(e):e.replace(/(\w+:\w+:[\w-_.]+|\%c)/g,"").trim(),'<span style="color:'.concat({_debug:"black",_error:"red",_info:"blue",_log:"black",_warn:"green",_time:"black",_timeEnd:"black",_table:"black"}[t],'">').concat(n.logTime()," ").concat(e,"</span><br>")}},{key:"_replacePrintLog",value:function(e){var t=this,n=this,r=document.getElementById(e);r?(Date.prototype.logTime=function(){return[("0"+(this.getMonth()+1)).slice(-2),("0"+this.getDate()).slice(-2)].join("-")+" "+[("0"+(this.getHours()+1)).slice(-2),("0"+this.getMinutes()).slice(-2),("0"+this.getSeconds()).slice(-2),("00"+this.getMilliseconds()).slice(-3)].join(":")},Object.keys(this).forEach((function(e){t[e].log=function(){for(var t=arguments.length,o=new Array(t),i=0;i<t;i++)o[i]=arguments[i];console.log(o[0].replace(/%c/g,"")),r.innerHTML+=n._makeLogMessage(o[0],e)}}))):Object.keys(this).forEach((function(e){t[e].log=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];console[e.substr(1)](n[0].replace(/\%c/g,""))}}))}},{key:"debug",get:function(){return this._debug}},{key:"error",get:function(){return this._error}},{key:"info",get:function(){return this._info}},{key:"log",get:function(){return this._log}},{key:"warn",get:function(){return this._warn}},{key:"time",get:function(){return this._time}},{key:"timeEnd",get:function(){return this._timeEnd}},{key:"table",get:function(){return this._table}}])&&s(t.prototype,n),r&&s(t,r),e}();t.default=c},function(e,t,n){var r,o=n(47),i=n(23),s=n(49),a=n(50),c=n(51);"undefined"!=typeof ArrayBuffer&&(r=n(52));var u="undefined"!=typeof navigator&&/Android/i.test(navigator.userAgent),l="undefined"!=typeof navigator&&/PhantomJS/i.test(navigator.userAgent),f=u||l;t.protocol=3;var h=t.packets={open:0,close:1,ping:2,pong:3,message:4,upgrade:5,noop:6},p=o(h),d={type:"error",data:"parser error"},g=n(53);function y(e,t,n){for(var r=new Array(e.length),o=a(e.length,n),i=function(e,n,o){t(n,(function(t,n){r[e]=n,o(t,r)}))},s=0;s<e.length;s++)i(s,e[s],o)}t.encodePacket=function(e,n,r,o){"function"==typeof n&&(o=n,n=!1),"function"==typeof r&&(o=r,r=null);var i=void 0===e.data?void 0:e.data.buffer||e.data;if("undefined"!=typeof ArrayBuffer&&i instanceof ArrayBuffer)return function(e,n,r){if(!n)return t.encodeBase64Packet(e,r);var o=e.data,i=new Uint8Array(o),s=new Uint8Array(1+o.byteLength);s[0]=h[e.type];for(var a=0;a<i.length;a++)s[a+1]=i[a];return r(s.buffer)}(e,n,o);if(void 0!==g&&i instanceof g)return function(e,n,r){if(!n)return t.encodeBase64Packet(e,r);if(f)return function(e,n,r){if(!n)return t.encodeBase64Packet(e,r);var o=new FileReader;return o.onload=function(){t.encodePacket({type:e.type,data:o.result},n,!0,r)},o.readAsArrayBuffer(e.data)}(e,n,r);var o=new Uint8Array(1);o[0]=h[e.type];var i=new g([o.buffer,e.data]);return r(i)}(e,n,o);if(i&&i.base64)return function(e,n){var r="b"+t.packets[e.type]+e.data.data;return n(r)}(e,o);var s=h[e.type];return void 0!==e.data&&(s+=r?c.encode(String(e.data),{strict:!1}):String(e.data)),o(""+s)},t.encodeBase64Packet=function(e,n){var r,o="b"+t.packets[e.type];if(void 0!==g&&e.data instanceof g){var i=new FileReader;return i.onload=function(){var e=i.result.split(",")[1];n(o+e)},i.readAsDataURL(e.data)}try{r=String.fromCharCode.apply(null,new Uint8Array(e.data))}catch(t){for(var s=new Uint8Array(e.data),a=new Array(s.length),c=0;c<s.length;c++)a[c]=s[c];r=String.fromCharCode.apply(null,a)}return o+=btoa(r),n(o)},t.decodePacket=function(e,n,r){if(void 0===e)return d;if("string"==typeof e){if("b"===e.charAt(0))return t.decodeBase64Packet(e.substr(1),n);if(r&&!1===(e=function(e){try{e=c.decode(e,{strict:!1})}catch(e){return!1}return e}(e)))return d;var o=e.charAt(0);return Number(o)==o&&p[o]?e.length>1?{type:p[o],data:e.substring(1)}:{type:p[o]}:d}o=new Uint8Array(e)[0];var i=s(e,1);return g&&"blob"===n&&(i=new g([i])),{type:p[o],data:i}},t.decodeBase64Packet=function(e,t){var n=p[e.charAt(0)];if(!r)return{type:n,data:{base64:!0,data:e.substr(1)}};var o=r.decode(e.substr(1));return"blob"===t&&g&&(o=new g([o])),{type:n,data:o}},t.encodePayload=function(e,n,r){"function"==typeof n&&(r=n,n=null);var o=i(e);if(n&&o)return g&&!f?t.encodePayloadAsBlob(e,r):t.encodePayloadAsArrayBuffer(e,r);if(!e.length)return r("0:");y(e,(function(e,r){t.encodePacket(e,!!o&&n,!1,(function(e){r(null,function(e){return e.length+":"+e}(e))}))}),(function(e,t){return r(t.join(""))}))},t.decodePayload=function(e,n,r){if("string"!=typeof e)return t.decodePayloadAsBinary(e,n,r);var o;if("function"==typeof n&&(r=n,n=null),""===e)return r(d,0,1);for(var i,s,a="",c=0,u=e.length;c<u;c++){var l=e.charAt(c);if(":"===l){if(""===a||a!=(i=Number(a)))return r(d,0,1);if(a!=(s=e.substr(c+1,i)).length)return r(d,0,1);if(s.length){if(o=t.decodePacket(s,n,!1),d.type===o.type&&d.data===o.data)return r(d,0,1);if(!1===r(o,c+i,u))return}c+=i,a=""}else a+=l}return""!==a?r(d,0,1):void 0},t.encodePayloadAsArrayBuffer=function(e,n){if(!e.length)return n(new ArrayBuffer(0));y(e,(function(e,n){t.encodePacket(e,!0,!0,(function(e){return n(null,e)}))}),(function(e,t){var r=t.reduce((function(e,t){var n;return e+(n="string"==typeof t?t.length:t.byteLength).toString().length+n+2}),0),o=new Uint8Array(r),i=0;return t.forEach((function(e){var t="string"==typeof e,n=e;if(t){for(var r=new Uint8Array(e.length),s=0;s<e.length;s++)r[s]=e.charCodeAt(s);n=r.buffer}o[i++]=t?0:1;var a=n.byteLength.toString();for(s=0;s<a.length;s++)o[i++]=parseInt(a[s]);o[i++]=255;for(r=new Uint8Array(n),s=0;s<r.length;s++)o[i++]=r[s]})),n(o.buffer)}))},t.encodePayloadAsBlob=function(e,n){y(e,(function(e,n){t.encodePacket(e,!0,!0,(function(e){var t=new Uint8Array(1);if(t[0]=1,"string"==typeof e){for(var r=new Uint8Array(e.length),o=0;o<e.length;o++)r[o]=e.charCodeAt(o);e=r.buffer,t[0]=0}var i=(e instanceof ArrayBuffer?e.byteLength:e.size).toString(),s=new Uint8Array(i.length+1);for(o=0;o<i.length;o++)s[o]=parseInt(i[o]);if(s[i.length]=255,g){var a=new g([t.buffer,s.buffer,e]);n(null,a)}}))}),(function(e,t){return n(new g(t))}))},t.decodePayloadAsBinary=function(e,n,r){"function"==typeof n&&(r=n,n=null);for(var o=e,i=[];o.byteLength>0;){for(var a=new Uint8Array(o),c=0===a[0],u="",l=1;255!==a[l];l++){if(u.length>310)return r(d,0,1);u+=a[l]}o=s(o,2+u.length),u=parseInt(u);var f=s(o,0,u);if(c)try{f=String.fromCharCode.apply(null,new Uint8Array(f))}catch(e){var h=new Uint8Array(f);f="";for(l=0;l<h.length;l++)f+=String.fromCharCode(h[l])}i.push(f),o=s(o,u)}var p=i.length;i.forEach((function(e,o){r(t.decodePacket(e,n,!0),o,p)}))}},function(e,t,n){(function(r){t.log=function(...e){return"object"==typeof console&&console.log&&console.log(...e)},t.formatArgs=function(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const n="color: "+this.color;t.splice(1,0,n,"color: inherit");let r=0,o=0;t[0].replace(/%[a-zA-Z%]/g,(e=>{"%%"!==e&&(r++,"%c"===e&&(o=r))})),t.splice(o,0,n)},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}},t.load=function(){let e;try{e=t.storage.getItem("debug")}catch(e){}!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG);return e},t.useColors=function(){if("undefined"!=typeof window&&window.process&&("renderer"===window.process.type||window.process.__nwjs))return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage=function(){try{return localStorage}catch(e){}}(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],e.exports=n(34)(t);const{formatters:o}=e.exports;o.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}}).call(this,n(3))},function(e,t){var n,r,o=e.exports={};function i(){throw new Error("setTimeout has not been defined")}function s(){throw new Error("clearTimeout has not been defined")}function a(e){if(n===setTimeout)return setTimeout(e,0);if((n===i||!n)&&setTimeout)return n=setTimeout,setTimeout(e,0);try{return n(e,0)}catch(t){try{return n.call(null,e,0)}catch(t){return n.call(this,e,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:i}catch(e){n=i}try{r="function"==typeof clearTimeout?clearTimeout:s}catch(e){r=s}}();var c,u=[],l=!1,f=-1;function h(){l&&c&&(l=!1,c.length?u=c.concat(u):f=-1,u.length&&p())}function p(){if(!l){var e=a(h);l=!0;for(var t=u.length;t;){for(c=u,u=[];++f<t;)c&&c[f].run();f=-1,t=u.length}c=null,l=!1,function(e){if(r===clearTimeout)return clearTimeout(e);if((r===s||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(e);try{r(e)}catch(t){try{return r.call(null,e)}catch(t){return r.call(this,e)}}}(e)}}function d(e,t){this.fun=e,this.array=t}function g(){}o.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];u.push(new d(e,t)),1!==u.length||l||a(p)},d.prototype.run=function(){this.fun.apply(null,this.array)},o.title="browser",o.browser=!0,o.env={},o.argv=[],o.version="",o.versions={},o.on=g,o.addListener=g,o.once=g,o.off=g,o.removeListener=g,o.removeAllListeners=g,o.emit=g,o.prependListener=g,o.prependOnceListener=g,o.listeners=function(e){return[]},o.binding=function(e){throw new Error("process.binding is not supported")},o.cwd=function(){return"/"},o.chdir=function(e){throw new Error("process.chdir is not supported")},o.umask=function(){return 0}},function(e,t){t.encode=function(e){var t="";for(var n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t},t.decode=function(e){for(var t={},n=e.split("&"),r=0,o=n.length;r<o;r++){var i=n[r].split("=");t[decodeURIComponent(i[0])]=decodeURIComponent(i[1])}return t}},function(e,t){e.exports=function(e,t){var n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e}},function(e,t,n){(function(r){t.log=function(...e){return"object"==typeof console&&console.log&&console.log(...e)},t.formatArgs=function(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const n="color: "+this.color;t.splice(1,0,n,"color: inherit");let r=0,o=0;t[0].replace(/%[a-zA-Z%]/g,(e=>{"%%"!==e&&(r++,"%c"===e&&(o=r))})),t.splice(o,0,n)},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}},t.load=function(){let e;try{e=t.storage.getItem("debug")}catch(e){}!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG);return e},t.useColors=function(){if("undefined"!=typeof window&&window.process&&("renderer"===window.process.type||window.process.__nwjs))return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage=function(){try{return localStorage}catch(e){}}(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],e.exports=n(54)(t);const{formatters:o}=e.exports;o.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}}).call(this,n(3))},function(e,t){var n=1e3,r=60*n,o=60*r,i=24*o,s=7*i,a=365.25*i;function c(e,t,n,r){var o=t>=1.5*n;return Math.round(e/n)+" "+r+(o?"s":"")}e.exports=function(e,t){t=t||{};var u=typeof e;if("string"===u&&e.length>0)return function(e){if((e=String(e)).length>100)return;var t=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(!t)return;var c=parseFloat(t[1]);switch((t[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return c*a;case"weeks":case"week":case"w":return c*s;case"days":case"day":case"d":return c*i;case"hours":case"hour":case"hrs":case"hr":case"h":return c*o;case"minutes":case"minute":case"mins":case"min":case"m":return c*r;case"seconds":case"second":case"secs":case"sec":case"s":return c*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return c;default:return}}(e);if("number"===u&&isFinite(e))return t.long?function(e){var t=Math.abs(e);if(t>=i)return c(e,t,i,"day");if(t>=o)return c(e,t,o,"hour");if(t>=r)return c(e,t,r,"minute");if(t>=n)return c(e,t,n,"second");return e+" ms"}(e):function(e){var t=Math.abs(e);if(t>=i)return Math.round(e/i)+"d";if(t>=o)return Math.round(e/o)+"h";if(t>=r)return Math.round(e/r)+"m";if(t>=n)return Math.round(e/n)+"s";return e+"ms"}(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},function(e,t,n){var r=n(35)("socket.io-parser"),o=n(9),i=n(38),s=n(18),a=n(19);function c(){}t.protocol=4,t.types=["CONNECT","DISCONNECT","EVENT","ACK","ERROR","BINARY_EVENT","BINARY_ACK"],t.CONNECT=0,t.DISCONNECT=1,t.EVENT=2,t.ACK=3,t.ERROR=4,t.BINARY_EVENT=5,t.BINARY_ACK=6,t.Encoder=c,t.Decoder=f;var u=t.ERROR+'"encode error"';function l(e){var n=""+e.type;if(t.BINARY_EVENT!==e.type&&t.BINARY_ACK!==e.type||(n+=e.attachments+"-"),e.nsp&&"/"!==e.nsp&&(n+=e.nsp+","),null!=e.id&&(n+=e.id),null!=e.data){var o=function(e){try{return JSON.stringify(e)}catch(e){return!1}}(e.data);if(!1===o)return u;n+=o}return r("encoded %j as %s",e,n),n}function f(){this.reconstructor=null}function h(e){this.reconPack=e,this.buffers=[]}function p(e){return{type:t.ERROR,data:"parser error: "+e}}c.prototype.encode=function(e,n){(r("encoding packet %j",e),t.BINARY_EVENT===e.type||t.BINARY_ACK===e.type)?function(e,t){function n(e){var n=i.deconstructPacket(e),r=l(n.packet),o=n.buffers;o.unshift(r),t(o)}i.removeBlobs(e,n)}(e,n):n([l(e)])},o(f.prototype),f.prototype.add=function(e){var n;if("string"==typeof e)n=function(e){var n=0,o={type:Number(e.charAt(0))};if(null==t.types[o.type])return p("unknown packet type "+o.type);if(t.BINARY_EVENT===o.type||t.BINARY_ACK===o.type){for(var i="";"-"!==e.charAt(++n)&&(i+=e.charAt(n),n!=e.length););if(i!=Number(i)||"-"!==e.charAt(n))throw new Error("Illegal attachments");o.attachments=Number(i)}if("/"===e.charAt(n+1))for(o.nsp="";++n;){if(","===(c=e.charAt(n)))break;if(o.nsp+=c,n===e.length)break}else o.nsp="/";var a=e.charAt(n+1);if(""!==a&&Number(a)==a){for(o.id="";++n;){var c;if(null==(c=e.charAt(n))||Number(c)!=c){--n;break}if(o.id+=e.charAt(n),n===e.length)break}o.id=Number(o.id)}if(e.charAt(++n)){var u=function(e){try{return JSON.parse(e)}catch(e){return!1}}(e.substr(n));if(!(!1!==u&&(o.type===t.ERROR||s(u))))return p("invalid payload");o.data=u}return r("decoded %s as %j",e,o),o}(e),t.BINARY_EVENT===n.type||t.BINARY_ACK===n.type?(this.reconstructor=new h(n),0===this.reconstructor.reconPack.attachments&&this.emit("decoded",n)):this.emit("decoded",n);else{if(!a(e)&&!e.base64)throw new Error("Unknown type: "+e);if(!this.reconstructor)throw new Error("got binary data when not reconstructing a packet");(n=this.reconstructor.takeBinaryData(e))&&(this.reconstructor=null,this.emit("decoded",n))}},f.prototype.destroy=function(){this.reconstructor&&this.reconstructor.finishedReconstruction()},h.prototype.takeBinaryData=function(e){if(this.buffers.push(e),this.buffers.length===this.reconPack.attachments){var t=i.reconstructPacket(this.reconPack,this.buffers);return this.finishedReconstruction(),t}return null},h.prototype.finishedReconstruction=function(){this.reconPack=null,this.buffers=[]}},function(e,t,n){function r(e){if(e)return function(e){for(var t in r.prototype)e[t]=r.prototype[t];return e}(e)}e.exports=r,r.prototype.on=r.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},r.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},r.prototype.off=r.prototype.removeListener=r.prototype.removeAllListeners=r.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var n,r=this._callbacks["$"+e];if(!r)return this;if(1==arguments.length)return delete this._callbacks["$"+e],this;for(var o=0;o<r.length;o++)if((n=r[o])===t||n.fn===t){r.splice(o,1);break}return this},r.prototype.emit=function(e){this._callbacks=this._callbacks||{};var t=[].slice.call(arguments,1),n=this._callbacks["$"+e];if(n)for(var r=0,o=(n=n.slice(0)).length;r<o;++r)n[r].apply(this,t);return this},r.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},r.prototype.hasListeners=function(e){return!!this.listeners(e).length}},function(e,t,n){"use strict";(function(e){
+window.offload=function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=65)}([function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r,o=(r=n(28))&&r.__esModule?r:{default:r};var i=["debug","error","info","log","warn","time","timeEnd","table"];t.default=function e(t){var n=this;if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),!t)throw new Error("Need a prefix when creating Logger class");i.forEach((function(e){e.indexOf("time")>-1?n[e]=(0,o.default)("".concat("offload",":TIME:")):n[e]=(0,o.default)("".concat("offload",":").concat(e.toUpperCase(),":").concat(t)),n[e].log=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];this.apply(this,t)}.bind(console[e])}))}},function(e,t,n){var r,o=n(47),i=n(15),s=n(48),a=n(49),c=n(50);"undefined"!=typeof ArrayBuffer&&(r=n(51));var u="undefined"!=typeof navigator&&/Android/i.test(navigator.userAgent),l="undefined"!=typeof navigator&&/PhantomJS/i.test(navigator.userAgent),f=u||l;t.protocol=3;var h=t.packets={open:0,close:1,ping:2,pong:3,message:4,upgrade:5,noop:6},p=o(h),d={type:"error",data:"parser error"},g=n(52);function y(e,t,n){for(var r=new Array(e.length),o=a(e.length,n),i=function(e,n,o){t(n,(function(t,n){r[e]=n,o(t,r)}))},s=0;s<e.length;s++)i(s,e[s],o)}t.encodePacket=function(e,n,r,o){"function"==typeof n&&(o=n,n=!1),"function"==typeof r&&(o=r,r=null);var i=void 0===e.data?void 0:e.data.buffer||e.data;if("undefined"!=typeof ArrayBuffer&&i instanceof ArrayBuffer)return function(e,n,r){if(!n)return t.encodeBase64Packet(e,r);var o=e.data,i=new Uint8Array(o),s=new Uint8Array(1+o.byteLength);s[0]=h[e.type];for(var a=0;a<i.length;a++)s[a+1]=i[a];return r(s.buffer)}(e,n,o);if(void 0!==g&&i instanceof g)return function(e,n,r){if(!n)return t.encodeBase64Packet(e,r);if(f)return function(e,n,r){if(!n)return t.encodeBase64Packet(e,r);var o=new FileReader;return o.onload=function(){t.encodePacket({type:e.type,data:o.result},n,!0,r)},o.readAsArrayBuffer(e.data)}(e,n,r);var o=new Uint8Array(1);o[0]=h[e.type];var i=new g([o.buffer,e.data]);return r(i)}(e,n,o);if(i&&i.base64)return function(e,n){var r="b"+t.packets[e.type]+e.data.data;return n(r)}(e,o);var s=h[e.type];return void 0!==e.data&&(s+=r?c.encode(String(e.data),{strict:!1}):String(e.data)),o(""+s)},t.encodeBase64Packet=function(e,n){var r,o="b"+t.packets[e.type];if(void 0!==g&&e.data instanceof g){var i=new FileReader;return i.onload=function(){var e=i.result.split(",")[1];n(o+e)},i.readAsDataURL(e.data)}try{r=String.fromCharCode.apply(null,new Uint8Array(e.data))}catch(t){for(var s=new Uint8Array(e.data),a=new Array(s.length),c=0;c<s.length;c++)a[c]=s[c];r=String.fromCharCode.apply(null,a)}return o+=btoa(r),n(o)},t.decodePacket=function(e,n,r){if(void 0===e)return d;if("string"==typeof e){if("b"===e.charAt(0))return t.decodeBase64Packet(e.substr(1),n);if(r&&!1===(e=function(e){try{e=c.decode(e,{strict:!1})}catch(e){return!1}return e}(e)))return d;var o=e.charAt(0);return Number(o)==o&&p[o]?e.length>1?{type:p[o],data:e.substring(1)}:{type:p[o]}:d}o=new Uint8Array(e)[0];var i=s(e,1);return g&&"blob"===n&&(i=new g([i])),{type:p[o],data:i}},t.decodeBase64Packet=function(e,t){var n=p[e.charAt(0)];if(!r)return{type:n,data:{base64:!0,data:e.substr(1)}};var o=r.decode(e.substr(1));return"blob"===t&&g&&(o=new g([o])),{type:n,data:o}},t.encodePayload=function(e,n,r){"function"==typeof n&&(r=n,n=null);var o=i(e);if(n&&o)return g&&!f?t.encodePayloadAsBlob(e,r):t.encodePayloadAsArrayBuffer(e,r);if(!e.length)return r("0:");y(e,(function(e,r){t.encodePacket(e,!!o&&n,!1,(function(e){r(null,function(e){return e.length+":"+e}(e))}))}),(function(e,t){return r(t.join(""))}))},t.decodePayload=function(e,n,r){if("string"!=typeof e)return t.decodePayloadAsBinary(e,n,r);var o;if("function"==typeof n&&(r=n,n=null),""===e)return r(d,0,1);for(var i,s,a="",c=0,u=e.length;c<u;c++){var l=e.charAt(c);if(":"===l){if(""===a||a!=(i=Number(a)))return r(d,0,1);if(a!=(s=e.substr(c+1,i)).length)return r(d,0,1);if(s.length){if(o=t.decodePacket(s,n,!1),d.type===o.type&&d.data===o.data)return r(d,0,1);if(!1===r(o,c+i,u))return}c+=i,a=""}else a+=l}return""!==a?r(d,0,1):void 0},t.encodePayloadAsArrayBuffer=function(e,n){if(!e.length)return n(new ArrayBuffer(0));y(e,(function(e,n){t.encodePacket(e,!0,!0,(function(e){return n(null,e)}))}),(function(e,t){var r=t.reduce((function(e,t){var n;return e+(n="string"==typeof t?t.length:t.byteLength).toString().length+n+2}),0),o=new Uint8Array(r),i=0;return t.forEach((function(e){var t="string"==typeof e,n=e;if(t){for(var r=new Uint8Array(e.length),s=0;s<e.length;s++)r[s]=e.charCodeAt(s);n=r.buffer}o[i++]=t?0:1;var a=n.byteLength.toString();for(s=0;s<a.length;s++)o[i++]=parseInt(a[s]);o[i++]=255;for(r=new Uint8Array(n),s=0;s<r.length;s++)o[i++]=r[s]})),n(o.buffer)}))},t.encodePayloadAsBlob=function(e,n){y(e,(function(e,n){t.encodePacket(e,!0,!0,(function(e){var t=new Uint8Array(1);if(t[0]=1,"string"==typeof e){for(var r=new Uint8Array(e.length),o=0;o<e.length;o++)r[o]=e.charCodeAt(o);e=r.buffer,t[0]=0}var i=(e instanceof ArrayBuffer?e.byteLength:e.size).toString(),s=new Uint8Array(i.length+1);for(o=0;o<i.length;o++)s[o]=parseInt(i[o]);if(s[i.length]=255,g){var a=new g([t.buffer,s.buffer,e]);n(null,a)}}))}),(function(e,t){return n(new g(t))}))},t.decodePayloadAsBinary=function(e,n,r){"function"==typeof n&&(r=n,n=null);for(var o=e,i=[];o.byteLength>0;){for(var a=new Uint8Array(o),c=0===a[0],u="",l=1;255!==a[l];l++){if(u.length>310)return r(d,0,1);u+=a[l]}o=s(o,2+u.length),u=parseInt(u);var f=s(o,0,u);if(c)try{f=String.fromCharCode.apply(null,new Uint8Array(f))}catch(e){var h=new Uint8Array(f);f="";for(l=0;l<h.length;l++)f+=String.fromCharCode(h[l])}i.push(f),o=s(o,u)}var p=i.length;i.forEach((function(e,o){r(t.decodePacket(e,n,!0),o,p)}))}},function(e,t){var n,r,o=e.exports={};function i(){throw new Error("setTimeout has not been defined")}function s(){throw new Error("clearTimeout has not been defined")}function a(e){if(n===setTimeout)return setTimeout(e,0);if((n===i||!n)&&setTimeout)return n=setTimeout,setTimeout(e,0);try{return n(e,0)}catch(t){try{return n.call(null,e,0)}catch(t){return n.call(this,e,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:i}catch(e){n=i}try{r="function"==typeof clearTimeout?clearTimeout:s}catch(e){r=s}}();var c,u=[],l=!1,f=-1;function h(){l&&c&&(l=!1,c.length?u=c.concat(u):f=-1,u.length&&p())}function p(){if(!l){var e=a(h);l=!0;for(var t=u.length;t;){for(c=u,u=[];++f<t;)c&&c[f].run();f=-1,t=u.length}c=null,l=!1,function(e){if(r===clearTimeout)return clearTimeout(e);if((r===s||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(e);try{r(e)}catch(t){try{return r.call(null,e)}catch(t){return r.call(this,e)}}}(e)}}function d(e,t){this.fun=e,this.array=t}function g(){}o.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];u.push(new d(e,t)),1!==u.length||l||a(p)},d.prototype.run=function(){this.fun.apply(null,this.array)},o.title="browser",o.browser=!0,o.env={},o.argv=[],o.version="",o.versions={},o.on=g,o.addListener=g,o.once=g,o.off=g,o.removeListener=g,o.removeAllListeners=g,o.emit=g,o.prependListener=g,o.prependOnceListener=g,o.listeners=function(e){return[]},o.binding=function(e){throw new Error("process.binding is not supported")},o.cwd=function(){return"/"},o.chdir=function(e){throw new Error("process.chdir is not supported")},o.umask=function(){return 0}},function(e,t,n){(function(r){function o(){var e;try{e=t.storage.debug}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}(t=e.exports=n(34)).log=function(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)},t.formatArgs=function(e){var n=this.useColors;if(e[0]=(n?"%c":"")+this.namespace+(n?" %c":" ")+e[0]+(n?"%c ":" ")+"+"+t.humanize(this.diff),!n)return;var r="color: "+this.color;e.splice(1,0,r,"color: inherit");var o=0,i=0;e[0].replace(/%[a-zA-Z%]/g,(function(e){"%%"!==e&&(o++,"%c"===e&&(i=o))})),e.splice(i,0,r)},t.save=function(e){try{null==e?t.storage.removeItem("debug"):t.storage.debug=e}catch(e){}},t.load=o,t.useColors=function(){if("undefined"!=typeof window&&window.process&&"renderer"===window.process.type)return!0;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:function(){try{return window.localStorage}catch(e){}}(),t.colors=["lightseagreen","forestgreen","goldenrod","dodgerblue","darkorchid","crimson"],t.formatters.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}},t.enable(o())}).call(this,n(3))},function(e,t){t.encode=function(e){var t="";for(var n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t},t.decode=function(e){for(var t={},n=e.split("&"),r=0,o=n.length;r<o;r++){var i=n[r].split("=");t[decodeURIComponent(i[0])]=decodeURIComponent(i[1])}return t}},function(e,t){e.exports=function(e,t){var n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e}},function(e,t,n){(function(r){function o(){var e;try{e=t.storage.debug}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}(t=e.exports=n(53)).log=function(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)},t.formatArgs=function(e){var n=this.useColors;if(e[0]=(n?"%c":"")+this.namespace+(n?" %c":" ")+e[0]+(n?"%c ":" ")+"+"+t.humanize(this.diff),!n)return;var r="color: "+this.color;e.splice(1,0,r,"color: inherit");var o=0,i=0;e[0].replace(/%[a-zA-Z%]/g,(function(e){"%%"!==e&&(o++,"%c"===e&&(i=o))})),e.splice(i,0,r)},t.save=function(e){try{null==e?t.storage.removeItem("debug"):t.storage.debug=e}catch(e){}},t.load=o,t.useColors=function(){if("undefined"!=typeof window&&window.process&&"renderer"===window.process.type)return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:function(){try{return window.localStorage}catch(e){}}(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.formatters.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}},t.enable(o())}).call(this,n(3))},function(e,t,n){var r=n(35)("socket.io-parser"),o=n(9),i=n(15),s=n(42),a=n(16),c=n(17);function u(){}function l(e){var n=""+e.type;return t.BINARY_EVENT!==e.type&&t.BINARY_ACK!==e.type||(n+=e.attachments+"-"),e.nsp&&"/"!==e.nsp&&(n+=e.nsp+","),null!=e.id&&(n+=e.id),null!=e.data&&(n+=JSON.stringify(e.data)),r("encoded %j as %s",e,n),n}function f(){this.reconstructor=null}function h(e){this.reconPack=e,this.buffers=[]}function p(e){return{type:t.ERROR,data:"parser error: "+e}}t.protocol=4,t.types=["CONNECT","DISCONNECT","EVENT","ACK","ERROR","BINARY_EVENT","BINARY_ACK"],t.CONNECT=0,t.DISCONNECT=1,t.EVENT=2,t.ACK=3,t.ERROR=4,t.BINARY_EVENT=5,t.BINARY_ACK=6,t.Encoder=u,t.Decoder=f,u.prototype.encode=function(e,n){(e.type!==t.EVENT&&e.type!==t.ACK||!i(e.data)||(e.type=e.type===t.EVENT?t.BINARY_EVENT:t.BINARY_ACK),r("encoding packet %j",e),t.BINARY_EVENT===e.type||t.BINARY_ACK===e.type)?function(e,t){s.removeBlobs(e,(function(e){var n=s.deconstructPacket(e),r=l(n.packet),o=n.buffers;o.unshift(r),t(o)}))}(e,n):n([l(e)])},o(f.prototype),f.prototype.add=function(e){var n;if("string"==typeof e)n=function(e){var n=0,o={type:Number(e.charAt(0))};if(null==t.types[o.type])return p("unknown packet type "+o.type);if(t.BINARY_EVENT===o.type||t.BINARY_ACK===o.type){for(var i="";"-"!==e.charAt(++n)&&(i+=e.charAt(n),n!=e.length););if(i!=Number(i)||"-"!==e.charAt(n))throw new Error("Illegal attachments");o.attachments=Number(i)}if("/"===e.charAt(n+1))for(o.nsp="";++n;){if(","===(c=e.charAt(n)))break;if(o.nsp+=c,n===e.length)break}else o.nsp="/";var s=e.charAt(n+1);if(""!==s&&Number(s)==s){for(o.id="";++n;){var c;if(null==(c=e.charAt(n))||Number(c)!=c){--n;break}if(o.id+=e.charAt(n),n===e.length)break}o.id=Number(o.id)}if(e.charAt(++n)){var u=function(e){try{return JSON.parse(e)}catch(e){return!1}}(e.substr(n));if(!(!1!==u&&(o.type===t.ERROR||a(u))))return p("invalid payload");o.data=u}return r("decoded %s as %j",e,o),o}(e),t.BINARY_EVENT===n.type||t.BINARY_ACK===n.type?(this.reconstructor=new h(n),0===this.reconstructor.reconPack.attachments&&this.emit("decoded",n)):this.emit("decoded",n);else{if(!c(e)&&!e.base64)throw new Error("Unknown type: "+e);if(!this.reconstructor)throw new Error("got binary data when not reconstructing a packet");(n=this.reconstructor.takeBinaryData(e))&&(this.reconstructor=null,this.emit("decoded",n))}},f.prototype.destroy=function(){this.reconstructor&&this.reconstructor.finishedReconstruction()},h.prototype.takeBinaryData=function(e){if(this.buffers.push(e),this.buffers.length===this.reconPack.attachments){var t=s.reconstructPacket(this.reconPack,this.buffers);return this.finishedReconstruction(),t}return null},h.prototype.finishedReconstruction=function(){this.reconPack=null,this.buffers=[]}},function(e,t,n){function r(e){if(e)return function(e){for(var t in r.prototype)e[t]=r.prototype[t];return e}(e)}e.exports=r,r.prototype.on=r.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},r.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},r.prototype.off=r.prototype.removeListener=r.prototype.removeAllListeners=r.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var n,r=this._callbacks["$"+e];if(!r)return this;if(1==arguments.length)return delete this._callbacks["$"+e],this;for(var o=0;o<r.length;o++)if((n=r[o])===t||n.fn===t){r.splice(o,1);break}return this},r.prototype.emit=function(e){this._callbacks=this._callbacks||{};var t=[].slice.call(arguments,1),n=this._callbacks["$"+e];if(n)for(var r=0,o=(n=n.slice(0)).length;r<o;++r)n[r].apply(this,t);return this},r.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},r.prototype.hasListeners=function(e){return!!this.listeners(e).length}},function(e,t,n){(function(t){var r=n(45);e.exports=function(e){var n=e.xdomain,o=e.xscheme,i=e.enablesXDR;try{if("undefined"!=typeof XMLHttpRequest&&(!n||r))return new XMLHttpRequest}catch(e){}try{if("undefined"!=typeof XDomainRequest&&!o&&i)return new XDomainRequest}catch(e){}if(!n)try{return new(t[["Active"].concat("Object").join("X")])("Microsoft.XMLHTTP")}catch(e){}}}).call(this,n(0))},function(e,t,n){var r=n(2),o=n(12);function i(e){this.path=e.path,this.hostname=e.hostname,this.port=e.port,this.secure=e.secure,this.query=e.query,this.timestampParam=e.timestampParam,this.timestampRequests=e.timestampRequests,this.readyState="",this.agent=e.agent||!1,this.socket=e.socket,this.enablesXDR=e.enablesXDR,this.pfx=e.pfx,this.key=e.key,this.passphrase=e.passphrase,this.cert=e.cert,this.ca=e.ca,this.ciphers=e.ciphers,this.rejectUnauthorized=e.rejectUnauthorized,this.forceNode=e.forceNode,this.extraHeaders=e.extraHeaders,this.localAddress=e.localAddress}e.exports=i,o(i.prototype),i.prototype.onError=function(e,t){var n=new Error(e);return n.type="TransportError",n.description=t,this.emit("error",n),this},i.prototype.open=function(){return"closed"!==this.readyState&&""!==this.readyState||(this.readyState="opening",this.doOpen()),this},i.prototype.close=function(){return"opening"!==this.readyState&&"open"!==this.readyState||(this.doClose(),this.onClose()),this},i.prototype.send=function(e){if("open"!==this.readyState)throw new Error("Transport not open");this.write(e)},i.prototype.onOpen=function(){this.readyState="open",this.writable=!0,this.emit("open")},i.prototype.onData=function(e){var t=r.decodePacket(e,this.socket.binaryType);this.onPacket(t)},i.prototype.onPacket=function(e){this.emit("packet",e)},i.prototype.onClose=function(){this.readyState="closed",this.emit("close")}},function(e,t,n){function r(e){if(e)return function(e){for(var t in r.prototype)e[t]=r.prototype[t];return e}(e)}e.exports=r,r.prototype.on=r.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},r.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},r.prototype.off=r.prototype.removeListener=r.prototype.removeAllListeners=r.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var n,r=this._callbacks["$"+e];if(!r)return this;if(1==arguments.length)return delete this._callbacks["$"+e],this;for(var o=0;o<r.length;o++)if((n=r[o])===t||n.fn===t){r.splice(o,1);break}return this},r.prototype.emit=function(e){this._callbacks=this._callbacks||{};var t=[].slice.call(arguments,1),n=this._callbacks["$"+e];if(n)for(var r=0,o=(n=n.slice(0)).length;r<o;++r)n[r].apply(this,t);return this},r.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},r.prototype.hasListeners=function(e){return!!this.listeners(e).length}},function(e,t){var n=/^(?:(?![^:@]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@]*)(?::([^:@]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,r=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];e.exports=function(e){var t=e,o=e.indexOf("["),i=e.indexOf("]");-1!=o&&-1!=i&&(e=e.substring(0,o)+e.substring(o,i).replace(/:/g,";")+e.substring(i,e.length));for(var s=n.exec(e||""),a={},c=14;c--;)a[r[c]]=s[c]||"";return-1!=o&&-1!=i&&(a.source=t,a.host=a.host.substring(1,a.host.length-1).replace(/;/g,":"),a.authority=a.authority.replace("[","").replace("]","").replace(/;/g,":"),a.ipv6uri=!0),a}},function(e,t){var n=1e3,r=6e4,o=60*r,i=24*o;function s(e,t,n){if(!(e<t))return e<1.5*t?Math.floor(e/t)+" "+n:Math.ceil(e/t)+" "+n+"s"}e.exports=function(e,t){t=t||{};var a,c=typeof e;if("string"===c&&e.length>0)return function(e){if((e=String(e)).length>100)return;var t=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(e);if(!t)return;var s=parseFloat(t[1]);switch((t[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*s;case"days":case"day":case"d":return s*i;case"hours":case"hour":case"hrs":case"hr":case"h":return s*o;case"minutes":case"minute":case"mins":case"min":case"m":return s*r;case"seconds":case"second":case"secs":case"sec":case"s":return s*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return s;default:return}}(e);if("number"===c&&!1===isNaN(e))return t.long?s(a=e,i,"day")||s(a,o,"hour")||s(a,r,"minute")||s(a,n,"second")||a+" ms":function(e){if(e>=i)return Math.round(e/i)+"d";if(e>=o)return Math.round(e/o)+"h";if(e>=r)return Math.round(e/r)+"m";if(e>=n)return Math.round(e/n)+"s";return e+"ms"}(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},function(e,t,n){(function(t){var r=n(41),o=Object.prototype.toString,i="function"==typeof Blob||"undefined"!=typeof Blob&&"[object BlobConstructor]"===o.call(Blob),s="function"==typeof File||"undefined"!=typeof File&&"[object FileConstructor]"===o.call(File);e.exports=function e(n){if(!n||"object"!=typeof n)return!1;if(r(n)){for(var o=0,a=n.length;o<a;o++)if(e(n[o]))return!0;return!1}if("function"==typeof t&&t.isBuffer&&t.isBuffer(n)||"function"==typeof ArrayBuffer&&n instanceof ArrayBuffer||i&&n instanceof Blob||s&&n instanceof File)return!0;if(n.toJSON&&"function"==typeof n.toJSON&&1===arguments.length)return e(n.toJSON(),!0);for(var c in n)if(Object.prototype.hasOwnProperty.call(n,c)&&e(n[c]))return!0;return!1}}).call(this,n(37).Buffer)},function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},function(e,t,n){(function(t){e.exports=function(e){return t.Buffer&&t.Buffer.isBuffer(e)||t.ArrayBuffer&&(e instanceof ArrayBuffer||ArrayBuffer.isView(e))}}).call(this,n(0))},function(e,t,n){var r=n(43),o=n(23),i=n(9),s=n(8),a=n(24),c=n(25),u=n(4)("socket.io-client:manager"),l=n(22),f=n(59),h=Object.prototype.hasOwnProperty;function p(e,t){if(!(this instanceof p))return new p(e,t);e&&"object"==typeof e&&(t=e,e=void 0),(t=t||{}).path=t.path||"/socket.io",this.nsps={},this.subs=[],this.opts=t,this.reconnection(!1!==t.reconnection),this.reconnectionAttempts(t.reconnectionAttempts||1/0),this.reconnectionDelay(t.reconnectionDelay||1e3),this.reconnectionDelayMax(t.reconnectionDelayMax||5e3),this.randomizationFactor(t.randomizationFactor||.5),this.backoff=new f({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(null==t.timeout?2e4:t.timeout),this.readyState="closed",this.uri=e,this.connecting=[],this.lastPing=null,this.encoding=!1,this.packetBuffer=[];var n=t.parser||s;this.encoder=new n.Encoder,this.decoder=new n.Decoder,this.autoConnect=!1!==t.autoConnect,this.autoConnect&&this.open()}e.exports=p,p.prototype.emitAll=function(){for(var e in this.emit.apply(this,arguments),this.nsps)h.call(this.nsps,e)&&this.nsps[e].emit.apply(this.nsps[e],arguments)},p.prototype.updateSocketIds=function(){for(var e in this.nsps)h.call(this.nsps,e)&&(this.nsps[e].id=this.generateId(e))},p.prototype.generateId=function(e){return("/"===e?"":e+"#")+this.engine.id},i(p.prototype),p.prototype.reconnection=function(e){return arguments.length?(this._reconnection=!!e,this):this._reconnection},p.prototype.reconnectionAttempts=function(e){return arguments.length?(this._reconnectionAttempts=e,this):this._reconnectionAttempts},p.prototype.reconnectionDelay=function(e){return arguments.length?(this._reconnectionDelay=e,this.backoff&&this.backoff.setMin(e),this):this._reconnectionDelay},p.prototype.randomizationFactor=function(e){return arguments.length?(this._randomizationFactor=e,this.backoff&&this.backoff.setJitter(e),this):this._randomizationFactor},p.prototype.reconnectionDelayMax=function(e){return arguments.length?(this._reconnectionDelayMax=e,this.backoff&&this.backoff.setMax(e),this):this._reconnectionDelayMax},p.prototype.timeout=function(e){return arguments.length?(this._timeout=e,this):this._timeout},p.prototype.maybeReconnectOnOpen=function(){!this.reconnecting&&this._reconnection&&0===this.backoff.attempts&&this.reconnect()},p.prototype.open=p.prototype.connect=function(e,t){if(u("readyState %s",this.readyState),~this.readyState.indexOf("open"))return this;u("opening %s",this.uri),this.engine=r(this.uri,this.opts);var n=this.engine,o=this;this.readyState="opening",this.skipReconnect=!1;var i=a(n,"open",(function(){o.onopen(),e&&e()})),s=a(n,"error",(function(t){if(u("connect_error"),o.cleanup(),o.readyState="closed",o.emitAll("connect_error",t),e){var n=new Error("Connection error");n.data=t,e(n)}else o.maybeReconnectOnOpen()}));if(!1!==this._timeout){var c=this._timeout;u("connect attempt will timeout after %d",c);var l=setTimeout((function(){u("connect attempt timed out after %d",c),i.destroy(),n.close(),n.emit("error","timeout"),o.emitAll("connect_timeout",c)}),c);this.subs.push({destroy:function(){clearTimeout(l)}})}return this.subs.push(i),this.subs.push(s),this},p.prototype.onopen=function(){u("open"),this.cleanup(),this.readyState="open",this.emit("open");var e=this.engine;this.subs.push(a(e,"data",c(this,"ondata"))),this.subs.push(a(e,"ping",c(this,"onping"))),this.subs.push(a(e,"pong",c(this,"onpong"))),this.subs.push(a(e,"error",c(this,"onerror"))),this.subs.push(a(e,"close",c(this,"onclose"))),this.subs.push(a(this.decoder,"decoded",c(this,"ondecoded")))},p.prototype.onping=function(){this.lastPing=new Date,this.emitAll("ping")},p.prototype.onpong=function(){this.emitAll("pong",new Date-this.lastPing)},p.prototype.ondata=function(e){this.decoder.add(e)},p.prototype.ondecoded=function(e){this.emit("packet",e)},p.prototype.onerror=function(e){u("error",e),this.emitAll("error",e)},p.prototype.socket=function(e,t){var n=this.nsps[e];if(!n){n=new o(this,e,t),this.nsps[e]=n;var r=this;n.on("connecting",i),n.on("connect",(function(){n.id=r.generateId(e)})),this.autoConnect&&i()}function i(){~l(r.connecting,n)||r.connecting.push(n)}return n},p.prototype.destroy=function(e){var t=l(this.connecting,e);~t&&this.connecting.splice(t,1),this.connecting.length||this.close()},p.prototype.packet=function(e){u("writing packet %j",e);var t=this;e.query&&0===e.type&&(e.nsp+="?"+e.query),t.encoding?t.packetBuffer.push(e):(t.encoding=!0,this.encoder.encode(e,(function(n){for(var r=0;r<n.length;r++)t.engine.write(n[r],e.options);t.encoding=!1,t.processPacketQueue()})))},p.prototype.processPacketQueue=function(){if(this.packetBuffer.length>0&&!this.encoding){var e=this.packetBuffer.shift();this.packet(e)}},p.prototype.cleanup=function(){u("cleanup");for(var e=this.subs.length,t=0;t<e;t++){this.subs.shift().destroy()}this.packetBuffer=[],this.encoding=!1,this.lastPing=null,this.decoder.destroy()},p.prototype.close=p.prototype.disconnect=function(){u("disconnect"),this.skipReconnect=!0,this.reconnecting=!1,"opening"===this.readyState&&this.cleanup(),this.backoff.reset(),this.readyState="closed",this.engine&&this.engine.close()},p.prototype.onclose=function(e){u("onclose"),this.cleanup(),this.backoff.reset(),this.readyState="closed",this.emit("close",e),this._reconnection&&!this.skipReconnect&&this.reconnect()},p.prototype.reconnect=function(){if(this.reconnecting||this.skipReconnect)return this;var e=this;if(this.backoff.attempts>=this._reconnectionAttempts)u("reconnect failed"),this.backoff.reset(),this.emitAll("reconnect_failed"),this.reconnecting=!1;else{var t=this.backoff.duration();u("will wait %dms before reconnect attempt",t),this.reconnecting=!0;var n=setTimeout((function(){e.skipReconnect||(u("attempting reconnect"),e.emitAll("reconnect_attempt",e.backoff.attempts),e.emitAll("reconnecting",e.backoff.attempts),e.skipReconnect||e.open((function(t){t?(u("reconnect attempt error"),e.reconnecting=!1,e.reconnect(),e.emitAll("reconnect_error",t.data)):(u("reconnect success"),e.onreconnect())})))}),t);this.subs.push({destroy:function(){clearTimeout(n)}})}},p.prototype.onreconnect=function(){var e=this.backoff.attempts;this.reconnecting=!1,this.backoff.reset(),this.updateSocketIds(),this.emitAll("reconnect",e)}},function(e,t,n){(function(e){var r=n(10),o=n(46),i=n(55),s=n(56);t.polling=function(t){var n=!1,s=!1,a=!1!==t.jsonp;if(e.location){var c="https:"===location.protocol,u=location.port;u||(u=c?443:80),n=t.hostname!==location.hostname||u!==t.port,s=t.secure!==c}if(t.xdomain=n,t.xscheme=s,"open"in new r(t)&&!t.forceJSONP)return new o(t);if(!a)throw new Error("JSONP disabled");return new i(t)},t.websocket=s}).call(this,n(0))},function(e,t,n){var r=n(11),o=n(5),i=n(2),s=n(6),a=n(21),c=n(7)("engine.io-client:polling");e.exports=l;var u=null!=new(n(10))({xdomain:!1}).responseType;function l(e){var t=e&&e.forceBase64;u&&!t||(this.supportsBinary=!1),r.call(this,e)}s(l,r),l.prototype.name="polling",l.prototype.doOpen=function(){this.poll()},l.prototype.pause=function(e){var t=this;function n(){c("paused"),t.readyState="paused",e()}if(this.readyState="pausing",this.polling||!this.writable){var r=0;this.polling&&(c("we are currently polling - waiting to pause"),r++,this.once("pollComplete",(function(){c("pre-pause polling complete"),--r||n()}))),this.writable||(c("we are currently writing - waiting to pause"),r++,this.once("drain",(function(){c("pre-pause writing complete"),--r||n()})))}else n()},l.prototype.poll=function(){c("polling"),this.polling=!0,this.doPoll(),this.emit("poll")},l.prototype.onData=function(e){var t=this;c("polling got data %s",e);i.decodePayload(e,this.socket.binaryType,(function(e,n,r){if("opening"===t.readyState&&t.onOpen(),"close"===e.type)return t.onClose(),!1;t.onPacket(e)})),"closed"!==this.readyState&&(this.polling=!1,this.emit("pollComplete"),"open"===this.readyState?this.poll():c('ignoring poll - transport state "%s"',this.readyState))},l.prototype.doClose=function(){var e=this;function t(){c("writing close packet"),e.write([{type:"close"}])}"open"===this.readyState?(c("transport open - closing"),t()):(c("transport not open - deferring close"),this.once("open",t))},l.prototype.write=function(e){var t=this;this.writable=!1;var n=function(){t.writable=!0,t.emit("drain")};i.encodePayload(e,this.supportsBinary,(function(e){t.doWrite(e,n)}))},l.prototype.uri=function(){var e=this.query||{},t=this.secure?"https":"http",n="";return!1!==this.timestampRequests&&(e[this.timestampParam]=a()),this.supportsBinary||e.sid||(e.b64=1),e=o.encode(e),this.port&&("https"===t&&443!==Number(this.port)||"http"===t&&80!==Number(this.port))&&(n=":"+this.port),e.length&&(e="?"+e),t+"://"+(-1!==this.hostname.indexOf(":")?"["+this.hostname+"]":this.hostname)+n+this.path+e}},function(e,t,n){"use strict";var r,o="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-_".split(""),i={},s=0,a=0;function c(e){var t="";do{t=o[e%64]+t,e=Math.floor(e/64)}while(e>0);return t}function u(){var e=c(+new Date);return e!==r?(s=0,r=e):e+"."+c(s++)}for(;a<64;a++)i[o[a]]=a;u.encode=c,u.decode=function(e){var t=0;for(a=0;a<e.length;a++)t=64*t+i[e.charAt(a)];return t},e.exports=u},function(e,t){var n=[].indexOf;e.exports=function(e,t){if(n)return e.indexOf(t);for(var r=0;r<e.length;++r)if(e[r]===t)return r;return-1}},function(e,t,n){var r=n(8),o=n(9),i=n(58),s=n(24),a=n(25),c=n(4)("socket.io-client:socket"),u=n(5);e.exports=h;var l={connect:1,connect_error:1,connect_timeout:1,connecting:1,disconnect:1,error:1,reconnect:1,reconnect_attempt:1,reconnect_failed:1,reconnect_error:1,reconnecting:1,ping:1,pong:1},f=o.prototype.emit;function h(e,t,n){this.io=e,this.nsp=t,this.json=this,this.ids=0,this.acks={},this.receiveBuffer=[],this.sendBuffer=[],this.connected=!1,this.disconnected=!0,n&&n.query&&(this.query=n.query),this.io.autoConnect&&this.open()}o(h.prototype),h.prototype.subEvents=function(){if(!this.subs){var e=this.io;this.subs=[s(e,"open",a(this,"onopen")),s(e,"packet",a(this,"onpacket")),s(e,"close",a(this,"onclose"))]}},h.prototype.open=h.prototype.connect=function(){return this.connected||(this.subEvents(),this.io.open(),"open"===this.io.readyState&&this.onopen(),this.emit("connecting")),this},h.prototype.send=function(){var e=i(arguments);return e.unshift("message"),this.emit.apply(this,e),this},h.prototype.emit=function(e){if(l.hasOwnProperty(e))return f.apply(this,arguments),this;var t=i(arguments),n={type:r.EVENT,data:t,options:{}};return n.options.compress=!this.flags||!1!==this.flags.compress,"function"==typeof t[t.length-1]&&(c("emitting packet with ack id %d",this.ids),this.acks[this.ids]=t.pop(),n.id=this.ids++),this.connected?this.packet(n):this.sendBuffer.push(n),delete this.flags,this},h.prototype.packet=function(e){e.nsp=this.nsp,this.io.packet(e)},h.prototype.onopen=function(){if(c("transport is open - connecting"),"/"!==this.nsp)if(this.query){var e="object"==typeof this.query?u.encode(this.query):this.query;c("sending connect packet with query %s",e),this.packet({type:r.CONNECT,query:e})}else this.packet({type:r.CONNECT})},h.prototype.onclose=function(e){c("close (%s)",e),this.connected=!1,this.disconnected=!0,delete this.id,this.emit("disconnect",e)},h.prototype.onpacket=function(e){if(e.nsp===this.nsp)switch(e.type){case r.CONNECT:this.onconnect();break;case r.EVENT:case r.BINARY_EVENT:this.onevent(e);break;case r.ACK:case r.BINARY_ACK:this.onack(e);break;case r.DISCONNECT:this.ondisconnect();break;case r.ERROR:this.emit("error",e.data)}},h.prototype.onevent=function(e){var t=e.data||[];c("emitting event %j",t),null!=e.id&&(c("attaching ack callback to event"),t.push(this.ack(e.id))),this.connected?f.apply(this,t):this.receiveBuffer.push(t)},h.prototype.ack=function(e){var t=this,n=!1;return function(){if(!n){n=!0;var o=i(arguments);c("sending ack %j",o),t.packet({type:r.ACK,id:e,data:o})}}},h.prototype.onack=function(e){var t=this.acks[e.id];"function"==typeof t?(c("calling ack %s with %j",e.id,e.data),t.apply(this,e.data),delete this.acks[e.id]):c("bad ack %s",e.id)},h.prototype.onconnect=function(){this.connected=!0,this.disconnected=!1,this.emit("connect"),this.emitBuffered()},h.prototype.emitBuffered=function(){var e;for(e=0;e<this.receiveBuffer.length;e++)f.apply(this,this.receiveBuffer[e]);for(this.receiveBuffer=[],e=0;e<this.sendBuffer.length;e++)this.packet(this.sendBuffer[e]);this.sendBuffer=[]},h.prototype.ondisconnect=function(){c("server disconnect (%s)",this.nsp),this.destroy(),this.onclose("io server disconnect")},h.prototype.destroy=function(){if(this.subs){for(var e=0;e<this.subs.length;e++)this.subs[e].destroy();this.subs=null}this.io.destroy(this)},h.prototype.close=h.prototype.disconnect=function(){return this.connected&&(c("performing disconnect (%s)",this.nsp),this.packet({type:r.DISCONNECT})),this.destroy(),this.connected&&this.onclose("io client disconnect"),this},h.prototype.compress=function(e){return this.flags=this.flags||{},this.flags.compress=e,this}},function(e,t){e.exports=function(e,t,n){return e.on(t,n),{destroy:function(){e.removeListener(t,n)}}}},function(e,t){var n=[].slice;e.exports=function(e,t){if("string"==typeof t&&(t=e[t]),"function"!=typeof t)throw new Error("bind() requires a function");var r=n.call(arguments,2);return function(){return t.apply(e,r.concat(n.call(arguments)))}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"Resource",{enumerable:!0,get:function(){return r.Resource}}),Object.defineProperty(t,"Worker",{enumerable:!0,get:function(){return o.Worker}}),Object.defineProperty(t,"WorkerManager",{enumerable:!0,get:function(){return i.WorkerManager}});var r=n(68),o=n(63),i=n(69)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getServerUrlFromLocation=function(){if(location){if("http:"===location.protocol)return"http://"+location.hostname+":9559";if("https:"===location.protocol)return"https://"+location.hostname+":5443"}return null},t.getServerUrlFromLocalhost=function(){if(location&&"https:"===location.protocol)return"https://127.0.0.1:5443";return"http://127.0.0.1:9559"},t.optionEnabled=function(e){return!("true"!==o()[e])},t.getOptions=o,t.getDeviceName=function(){var e=(new r.UAParser).getResult(),t="Unknown";e.device.vendor&&e.device.model?t="[".concat(e.device.vendor,"] ").concat(e.device.model):e.os.name&&e.browser.name&&(t="[".concat(e.os.name,"] ").concat(e.browser.name));return t},t.getClientId=function(){var e=localStorage.getItem("clientId");if(null===e){var t=(new r.UAParser).getResult(),n="Unknown";void 0!==t.device.vendor?n=t.device.vendor:void 0!==t.os.name&&(n=t.os.name),e=n+i(),localStorage.setItem("clientId",e)}return e},t.isPromise=function(e){return!!e&&"function"==typeof e.then},t.getUniqueId=i,t.getOffloadId=function(e){return e+"_"+e.toLowerCase().split("").reverse().join("")};var r=n(31);function o(){var e={},t=["debug","info"],n=function(){var e=window.location.search.substr(1).split("&");if(""===e)return{};for(var t={},n=0;n<e.length;n++){var r=e[n].split("=",2);1===r.length?t[r[0]]="":t[r[0]]=decodeURIComponent(r[1].replace(/\+/g," "))}return t}();for(var r in n)-1!==t.indexOf(r)&&(e[r]=n[r]);return e}function i(){return"_"+Math.random().toString(36).substr(2,9)}},function(e,t,n){(function(r){t.formatArgs=function(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const n="color: "+this.color;t.splice(1,0,n,"color: inherit");let r=0,o=0;t[0].replace(/%[a-zA-Z%]/g,e=>{"%%"!==e&&(r++,"%c"===e&&(o=r))}),t.splice(o,0,n)},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}},t.load=function(){let e;try{e=t.storage.getItem("debug")}catch(e){}!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG);return e},t.useColors=function(){if("undefined"!=typeof window&&window.process&&("renderer"===window.process.type||window.process.__nwjs))return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage=function(){try{return localStorage}catch(e){}}(),t.destroy=(()=>{let e=!1;return()=>{e||(e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.log=console.debug||console.log||(()=>{}),e.exports=n(29)(t);const{formatters:o}=e.exports;o.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}}).call(this,n(3))},function(e,t,n){e.exports=function(e){function t(e){let n,o=null;function i(...e){if(!i.enabled)return;const r=i,o=Number(new Date),s=o-(n||o);r.diff=s,r.prev=n,r.curr=o,n=o,e[0]=t.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let a=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,(n,o)=>{if("%%"===n)return"%";a++;const i=t.formatters[o];if("function"==typeof i){const t=e[a];n=i.call(r,t),e.splice(a,1),a--}return n}),t.formatArgs.call(r,e);(r.log||t.log).apply(r,e)}return i.namespace=e,i.useColors=t.useColors(),i.color=t.selectColor(e),i.extend=r,i.destroy=t.destroy,Object.defineProperty(i,"enabled",{enumerable:!0,configurable:!1,get:()=>null===o?t.enabled(e):o,set:e=>{o=e}}),"function"==typeof t.init&&t.init(i),i}function r(e,n){const r=t(this.namespace+(void 0===n?":":n)+e);return r.log=this.log,r}function o(e){return e.toString().substring(2,e.toString().length-2).replace(/\.\*\?$/,"*")}return t.debug=t,t.default=t,t.coerce=function(e){if(e instanceof Error)return e.stack||e.message;return e},t.disable=function(){const e=[...t.names.map(o),...t.skips.map(o).map(e=>"-"+e)].join(",");return t.enable(""),e},t.enable=function(e){let n;t.save(e),t.names=[],t.skips=[];const r=("string"==typeof e?e:"").split(/[\s,]+/),o=r.length;for(n=0;n<o;n++)r[n]&&("-"===(e=r[n].replace(/\*/g,".*?"))[0]?t.skips.push(new RegExp("^"+e.substr(1)+"$")):t.names.push(new RegExp("^"+e+"$")))},t.enabled=function(e){if("*"===e[e.length-1])return!0;let n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1},t.humanize=n(30),t.destroy=function(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")},Object.keys(e).forEach(n=>{t[n]=e[n]}),t.names=[],t.skips=[],t.formatters={},t.selectColor=function(e){let n=0;for(let t=0;t<e.length;t++)n=(n<<5)-n+e.charCodeAt(t),n|=0;return t.colors[Math.abs(n)%t.colors.length]},t.enable(t.load()),t}},function(e,t){var n=1e3,r=6e4,o=60*r,i=24*o;function s(e,t,n,r){var o=t>=1.5*n;return Math.round(e/n)+" "+r+(o?"s":"")}e.exports=function(e,t){t=t||{};var a=typeof e;if("string"===a&&e.length>0)return function(e){if((e=String(e)).length>100)return;var t=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(!t)return;var s=parseFloat(t[1]);switch((t[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*s;case"weeks":case"week":case"w":return 6048e5*s;case"days":case"day":case"d":return s*i;case"hours":case"hour":case"hrs":case"hr":case"h":return s*o;case"minutes":case"minute":case"mins":case"min":case"m":return s*r;case"seconds":case"second":case"secs":case"sec":case"s":return s*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return s;default:return}}(e);if("number"===a&&isFinite(e))return t.long?function(e){var t=Math.abs(e);if(t>=i)return s(e,t,i,"day");if(t>=o)return s(e,t,o,"hour");if(t>=r)return s(e,t,r,"minute");if(t>=n)return s(e,t,n,"second");return e+" ms"}(e):function(e){var t=Math.abs(e);if(t>=i)return Math.round(e/i)+"d";if(t>=o)return Math.round(e/o)+"h";if(t>=r)return Math.round(e/r)+"m";if(t>=n)return Math.round(e/n)+"s";return e+"ms"}(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},function(e,t,n){var r;
+/*!
+ * UAParser.js v0.7.21
+ * Lightweight JavaScript-based User-Agent string parser
+ * https://github.com/faisalman/ua-parser-js
+ *
+ * Copyright Â© 2012-2019 Faisal Salman <f@faisalman.com>
+ * Licensed under MIT License
+ */!function(o,i){"use strict";var s="model",a="name",c="type",u="vendor",l="version",f="mobile",h="tablet",p="smarttv",d={extend:function(e,t){var n={};for(var r in e)t[r]&&t[r].length%2==0?n[r]=t[r].concat(e[r]):n[r]=e[r];return n},has:function(e,t){return"string"==typeof e&&-1!==t.toLowerCase().indexOf(e.toLowerCase())},lowerize:function(e){return e.toLowerCase()},major:function(e){return"string"==typeof e?e.replace(/[^\d\.]/g,"").split(".")[0]:void 0},trim:function(e){return e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}},g={rgx:function(e,t){for(var n,r,o,i,s,a,c=0;c<t.length&&!s;){var u=t[c],l=t[c+1];for(n=r=0;n<u.length&&!s;)if(s=u[n++].exec(e))for(o=0;o<l.length;o++)a=s[++r],"object"==typeof(i=l[o])&&i.length>0?2==i.length?"function"==typeof i[1]?this[i[0]]=i[1].call(this,a):this[i[0]]=i[1]:3==i.length?"function"!=typeof i[1]||i[1].exec&&i[1].test?this[i[0]]=a?a.replace(i[1],i[2]):void 0:this[i[0]]=a?i[1].call(this,a,i[2]):void 0:4==i.length&&(this[i[0]]=a?i[3].call(this,a.replace(i[1],i[2])):void 0):this[i]=a||void 0;c+=2}},str:function(e,t){for(var n in t)if("object"==typeof t[n]&&t[n].length>0){for(var r=0;r<t[n].length;r++)if(d.has(t[n][r],e))return"?"===n?void 0:n}else if(d.has(t[n],e))return"?"===n?void 0:n;return e}},y={browser:{oldsafari:{version:{"1.0":"/8",1.2:"/1",1.3:"/3","2.0":"/412","2.0.2":"/416","2.0.3":"/417","2.0.4":"/419","?":"/"}}},device:{amazon:{model:{"Fire Phone":["SD","KF"]}},sprint:{model:{"Evo Shift 4G":"7373KT"},vendor:{HTC:"APA",Sprint:"Sprint"}}},os:{windows:{version:{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"}}}},v={browser:[[/(opera\smini)\/([\w\.-]+)/i,/(opera\s[mobiletab]+).+version\/([\w\.-]+)/i,/(opera).+version\/([\w\.]+)/i,/(opera)[\/\s]+([\w\.]+)/i],[a,l],[/(opios)[\/\s]+([\w\.]+)/i],[[a,"Opera Mini"],l],[/\s(opr)\/([\w\.]+)/i],[[a,"Opera"],l],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer)[\/\s]?([\w\.]*)/i,/(avant\s|iemobile|slim)(?:browser)?[\/\s]?([\w\.]*)/i,/(bidubrowser|baidubrowser)[\/\s]?([\w\.]+)/i,/(?:ms|\()(ie)\s([\w\.]+)/i,/(rekonq)\/([\w\.]*)/i,/(chromium|flock|rockmelt|midori|epiphany|silk|skyfire|ovibrowser|bolt|iron|vivaldi|iridium|phantomjs|bowser|quark|qupzilla|falkon)\/([\w\.-]+)/i],[a,l],[/(konqueror)\/([\w\.]+)/i],[[a,"Konqueror"],l],[/(trident).+rv[:\s]([\w\.]+).+like\sgecko/i],[[a,"IE"],l],[/(edge|edgios|edga|edg)\/((\d+)?[\w\.]+)/i],[[a,"Edge"],l],[/(yabrowser)\/([\w\.]+)/i],[[a,"Yandex"],l],[/(Avast)\/([\w\.]+)/i],[[a,"Avast Secure Browser"],l],[/(AVG)\/([\w\.]+)/i],[[a,"AVG Secure Browser"],l],[/(puffin)\/([\w\.]+)/i],[[a,"Puffin"],l],[/(focus)\/([\w\.]+)/i],[[a,"Firefox Focus"],l],[/(opt)\/([\w\.]+)/i],[[a,"Opera Touch"],l],[/((?:[\s\/])uc?\s?browser|(?:juc.+)ucweb)[\/\s]?([\w\.]+)/i],[[a,"UCBrowser"],l],[/(comodo_dragon)\/([\w\.]+)/i],[[a,/_/g," "],l],[/(windowswechat qbcore)\/([\w\.]+)/i],[[a,"WeChat(Win) Desktop"],l],[/(micromessenger)\/([\w\.]+)/i],[[a,"WeChat"],l],[/(brave)\/([\w\.]+)/i],[[a,"Brave"],l],[/(qqbrowserlite)\/([\w\.]+)/i],[a,l],[/(QQ)\/([\d\.]+)/i],[a,l],[/m?(qqbrowser)[\/\s]?([\w\.]+)/i],[a,l],[/(baiduboxapp)[\/\s]?([\w\.]+)/i],[a,l],[/(2345Explorer)[\/\s]?([\w\.]+)/i],[a,l],[/(MetaSr)[\/\s]?([\w\.]+)/i],[a],[/(LBBROWSER)/i],[a],[/xiaomi\/miuibrowser\/([\w\.]+)/i],[l,[a,"MIUI Browser"]],[/;fbav\/([\w\.]+);/i],[l,[a,"Facebook"]],[/safari\s(line)\/([\w\.]+)/i,/android.+(line)\/([\w\.]+)\/iab/i],[a,l],[/headlesschrome(?:\/([\w\.]+)|\s)/i],[l,[a,"Chrome Headless"]],[/\swv\).+(chrome)\/([\w\.]+)/i],[[a,/(.+)/,"$1 WebView"],l],[/((?:oculus|samsung)browser)\/([\w\.]+)/i],[[a,/(.+(?:g|us))(.+)/,"$1 $2"],l],[/android.+version\/([\w\.]+)\s+(?:mobile\s?safari|safari)*/i],[l,[a,"Android Browser"]],[/(sailfishbrowser)\/([\w\.]+)/i],[[a,"Sailfish Browser"],l],[/(chrome|omniweb|arora|[tizenoka]{5}\s?browser)\/v?([\w\.]+)/i],[a,l],[/(dolfin)\/([\w\.]+)/i],[[a,"Dolphin"],l],[/(qihu|qhbrowser|qihoobrowser|360browser)/i],[[a,"360 Browser"]],[/((?:android.+)crmo|crios)\/([\w\.]+)/i],[[a,"Chrome"],l],[/(coast)\/([\w\.]+)/i],[[a,"Opera Coast"],l],[/fxios\/([\w\.-]+)/i],[l,[a,"Firefox"]],[/version\/([\w\.]+).+?mobile\/\w+\s(safari)/i],[l,[a,"Mobile Safari"]],[/version\/([\w\.]+).+?(mobile\s?safari|safari)/i],[l,a],[/webkit.+?(gsa)\/([\w\.]+).+?(mobile\s?safari|safari)(\/[\w\.]+)/i],[[a,"GSA"],l],[/webkit.+?(mobile\s?safari|safari)(\/[\w\.]+)/i],[a,[l,g.str,y.browser.oldsafari.version]],[/(webkit|khtml)\/([\w\.]+)/i],[a,l],[/(navigator|netscape)\/([\w\.-]+)/i],[[a,"Netscape"],l],[/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo\sbrowser|minimo|conkeror)[\/\s]?([\w\.\+]+)/i,/(firefox|seamonkey|k-meleon|icecat|iceape|firebird|phoenix|palemoon|basilisk|waterfox)\/([\w\.-]+)$/i,/(mozilla)\/([\w\.]+).+rv\:.+gecko\/\d+/i,/(polaris|lynx|dillo|icab|doris|amaya|w3m|netsurf|sleipnir)[\/\s]?([\w\.]+)/i,/(links)\s\(([\w\.]+)/i,/(gobrowser)\/?([\w\.]*)/i,/(ice\s?browser)\/v?([\w\._]+)/i,/(mosaic)[\/\s]([\w\.]+)/i],[a,l]],cpu:[[/(?:(amd|x(?:(?:86|64)[_-])?|wow|win)64)[;\)]/i],[["architecture","amd64"]],[/(ia32(?=;))/i],[["architecture",d.lowerize]],[/((?:i[346]|x)86)[;\)]/i],[["architecture","ia32"]],[/windows\s(ce|mobile);\sppc;/i],[["architecture","arm"]],[/((?:ppc|powerpc)(?:64)?)(?:\smac|;|\))/i],[["architecture",/ower/,"",d.lowerize]],[/(sun4\w)[;\)]/i],[["architecture","sparc"]],[/((?:avr32|ia64(?=;))|68k(?=\))|arm(?:64|(?=v\d+[;l]))|(?=atmel\s)avr|(?:irix|mips|sparc)(?:64)?(?=;)|pa-risc)/i],[["architecture",d.lowerize]]],device:[[/\((ipad|playbook);[\w\s\),;-]+(rim|apple)/i],[s,u,[c,h]],[/applecoremedia\/[\w\.]+ \((ipad)/],[s,[u,"Apple"],[c,h]],[/(apple\s{0,1}tv)/i],[[s,"Apple TV"],[u,"Apple"],[c,p]],[/(archos)\s(gamepad2?)/i,/(hp).+(touchpad)/i,/(hp).+(tablet)/i,/(kindle)\/([\w\.]+)/i,/\s(nook)[\w\s]+build\/(\w+)/i,/(dell)\s(strea[kpr\s\d]*[\dko])/i],[u,s,[c,h]],[/(kf[A-z]+)\sbuild\/.+silk\//i],[s,[u,"Amazon"],[c,h]],[/(sd|kf)[0349hijorstuw]+\sbuild\/.+silk\//i],[[s,g.str,y.device.amazon.model],[u,"Amazon"],[c,f]],[/android.+aft([bms])\sbuild/i],[s,[u,"Amazon"],[c,p]],[/\((ip[honed|\s\w*]+);.+(apple)/i],[s,u,[c,f]],[/\((ip[honed|\s\w*]+);/i],[s,[u,"Apple"],[c,f]],[/(blackberry)[\s-]?(\w+)/i,/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus|dell|meizu|motorola|polytron)[\s_-]?([\w-]*)/i,/(hp)\s([\w\s]+\w)/i,/(asus)-?(\w+)/i],[u,s,[c,f]],[/\(bb10;\s(\w+)/i],[s,[u,"BlackBerry"],[c,f]],[/android.+(transfo[prime\s]{4,10}\s\w+|eeepc|slider\s\w+|nexus 7|padfone|p00c)/i],[s,[u,"Asus"],[c,h]],[/(sony)\s(tablet\s[ps])\sbuild\//i,/(sony)?(?:sgp.+)\sbuild\//i],[[u,"Sony"],[s,"Xperia Tablet"],[c,h]],[/android.+\s([c-g]\d{4}|so[-l]\w+)(?=\sbuild\/|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[s,[u,"Sony"],[c,f]],[/\s(ouya)\s/i,/(nintendo)\s([wids3u]+)/i],[u,s,[c,"console"]],[/android.+;\s(shield)\sbuild/i],[s,[u,"Nvidia"],[c,"console"]],[/(playstation\s[34portablevi]+)/i],[s,[u,"Sony"],[c,"console"]],[/(sprint\s(\w+))/i],[[u,g.str,y.device.sprint.vendor],[s,g.str,y.device.sprint.model],[c,f]],[/(htc)[;_\s-]+([\w\s]+(?=\)|\sbuild)|\w+)/i,/(zte)-(\w*)/i,/(alcatel|geeksphone|nexian|panasonic|(?=;\s)sony)[_\s-]?([\w-]*)/i],[u,[s,/_/g," "],[c,f]],[/(nexus\s9)/i],[s,[u,"HTC"],[c,h]],[/d\/huawei([\w\s-]+)[;\)]/i,/(nexus\s6p|vog-l29|ane-lx1|eml-l29)/i],[s,[u,"Huawei"],[c,f]],[/android.+(bah2?-a?[lw]\d{2})/i],[s,[u,"Huawei"],[c,h]],[/(microsoft);\s(lumia[\s\w]+)/i],[u,s,[c,f]],[/[\s\(;](xbox(?:\sone)?)[\s\);]/i],[s,[u,"Microsoft"],[c,"console"]],[/(kin\.[onetw]{3})/i],[[s,/\./g," "],[u,"Microsoft"],[c,f]],[/\s(milestone|droid(?:[2-4x]|\s(?:bionic|x2|pro|razr))?:?(\s4g)?)[\w\s]+build\//i,/mot[\s-]?(\w*)/i,/(XT\d{3,4}) build\//i,/(nexus\s6)/i],[s,[u,"Motorola"],[c,f]],[/android.+\s(mz60\d|xoom[\s2]{0,2})\sbuild\//i],[s,[u,"Motorola"],[c,h]],[/hbbtv\/\d+\.\d+\.\d+\s+\([\w\s]*;\s*(\w[^;]*);([^;]*)/i],[[u,d.trim],[s,d.trim],[c,p]],[/hbbtv.+maple;(\d+)/i],[[s,/^/,"SmartTV"],[u,"Samsung"],[c,p]],[/\(dtv[\);].+(aquos)/i],[s,[u,"Sharp"],[c,p]],[/android.+((sch-i[89]0\d|shw-m380s|gt-p\d{4}|gt-n\d+|sgh-t8[56]9|nexus 10))/i,/((SM-T\w+))/i],[[u,"Samsung"],s,[c,h]],[/smart-tv.+(samsung)/i],[u,[c,p],s],[/((s[cgp]h-\w+|gt-\w+|galaxy\snexus|sm-\w[\w\d]+))/i,/(sam[sung]*)[\s-]*(\w+-?[\w-]*)/i,/sec-((sgh\w+))/i],[[u,"Samsung"],s,[c,f]],[/sie-(\w*)/i],[s,[u,"Siemens"],[c,f]],[/(maemo|nokia).*(n900|lumia\s\d+)/i,/(nokia)[\s_-]?([\w-]*)/i],[[u,"Nokia"],s,[c,f]],[/android[x\d\.\s;]+\s([ab][1-7]\-?[0178a]\d\d?)/i],[s,[u,"Acer"],[c,h]],[/android.+([vl]k\-?\d{3})\s+build/i],[s,[u,"LG"],[c,h]],[/android\s3\.[\s\w;-]{10}(lg?)-([06cv9]{3,4})/i],[[u,"LG"],s,[c,h]],[/(lg) netcast\.tv/i],[u,s,[c,p]],[/(nexus\s[45])/i,/lg[e;\s\/-]+(\w*)/i,/android.+lg(\-?[\d\w]+)\s+build/i],[s,[u,"LG"],[c,f]],[/(lenovo)\s?(s(?:5000|6000)(?:[\w-]+)|tab(?:[\s\w]+))/i],[u,s,[c,h]],[/android.+(ideatab[a-z0-9\-\s]+)/i],[s,[u,"Lenovo"],[c,h]],[/(lenovo)[_\s-]?([\w-]+)/i],[u,s,[c,f]],[/linux;.+((jolla));/i],[u,s,[c,f]],[/((pebble))app\/[\d\.]+\s/i],[u,s,[c,"wearable"]],[/android.+;\s(oppo)\s?([\w\s]+)\sbuild/i],[u,s,[c,f]],[/crkey/i],[[s,"Chromecast"],[u,"Google"],[c,p]],[/android.+;\s(glass)\s\d/i],[s,[u,"Google"],[c,"wearable"]],[/android.+;\s(pixel c)[\s)]/i],[s,[u,"Google"],[c,h]],[/android.+;\s(pixel( [23])?( xl)?)[\s)]/i],[s,[u,"Google"],[c,f]],[/android.+;\s(\w+)\s+build\/hm\1/i,/android.+(hm[\s\-_]*note?[\s_]*(?:\d\w)?)\s+build/i,/android.+(mi[\s\-_]*(?:a\d|one|one[\s_]plus|note lte)?[\s_]*(?:\d?\w?)[\s_]*(?:plus)?)\s+build/i,/android.+(redmi[\s\-_]*(?:note)?(?:[\s_]*[\w\s]+))\s+build/i],[[s,/_/g," "],[u,"Xiaomi"],[c,f]],[/android.+(mi[\s\-_]*(?:pad)(?:[\s_]*[\w\s]+))\s+build/i],[[s,/_/g," "],[u,"Xiaomi"],[c,h]],[/android.+;\s(m[1-5]\snote)\sbuild/i],[s,[u,"Meizu"],[c,f]],[/(mz)-([\w-]{2,})/i],[[u,"Meizu"],s,[c,f]],[/android.+a000(1)\s+build/i,/android.+oneplus\s(a\d{4})[\s)]/i],[s,[u,"OnePlus"],[c,f]],[/android.+[;\/]\s*(RCT[\d\w]+)\s+build/i],[s,[u,"RCA"],[c,h]],[/android.+[;\/\s]+(Venue[\d\s]{2,7})\s+build/i],[s,[u,"Dell"],[c,h]],[/android.+[;\/]\s*(Q[T|M][\d\w]+)\s+build/i],[s,[u,"Verizon"],[c,h]],[/android.+[;\/]\s+(Barnes[&\s]+Noble\s+|BN[RT])(V?.*)\s+build/i],[[u,"Barnes & Noble"],s,[c,h]],[/android.+[;\/]\s+(TM\d{3}.*\b)\s+build/i],[s,[u,"NuVision"],[c,h]],[/android.+;\s(k88)\sbuild/i],[s,[u,"ZTE"],[c,h]],[/android.+[;\/]\s*(gen\d{3})\s+build.*49h/i],[s,[u,"Swiss"],[c,f]],[/android.+[;\/]\s*(zur\d{3})\s+build/i],[s,[u,"Swiss"],[c,h]],[/android.+[;\/]\s*((Zeki)?TB.*\b)\s+build/i],[s,[u,"Zeki"],[c,h]],[/(android).+[;\/]\s+([YR]\d{2})\s+build/i,/android.+[;\/]\s+(Dragon[\-\s]+Touch\s+|DT)(\w{5})\sbuild/i],[[u,"Dragon Touch"],s,[c,h]],[/android.+[;\/]\s*(NS-?\w{0,9})\sbuild/i],[s,[u,"Insignia"],[c,h]],[/android.+[;\/]\s*((NX|Next)-?\w{0,9})\s+build/i],[s,[u,"NextBook"],[c,h]],[/android.+[;\/]\s*(Xtreme\_)?(V(1[045]|2[015]|30|40|60|7[05]|90))\s+build/i],[[u,"Voice"],s,[c,f]],[/android.+[;\/]\s*(LVTEL\-)?(V1[12])\s+build/i],[[u,"LvTel"],s,[c,f]],[/android.+;\s(PH-1)\s/i],[s,[u,"Essential"],[c,f]],[/android.+[;\/]\s*(V(100MD|700NA|7011|917G).*\b)\s+build/i],[s,[u,"Envizen"],[c,h]],[/android.+[;\/]\s*(Le[\s\-]+Pan)[\s\-]+(\w{1,9})\s+build/i],[u,s,[c,h]],[/android.+[;\/]\s*(Trio[\s\-]*.*)\s+build/i],[s,[u,"MachSpeed"],[c,h]],[/android.+[;\/]\s*(Trinity)[\-\s]*(T\d{3})\s+build/i],[u,s,[c,h]],[/android.+[;\/]\s*TU_(1491)\s+build/i],[s,[u,"Rotor"],[c,h]],[/android.+(KS(.+))\s+build/i],[s,[u,"Amazon"],[c,h]],[/android.+(Gigaset)[\s\-]+(Q\w{1,9})\s+build/i],[u,s,[c,h]],[/\s(tablet|tab)[;\/]/i,/\s(mobile)(?:[;\/]|\ssafari)/i],[[c,d.lowerize],u,s],[/[\s\/\(](smart-?tv)[;\)]/i],[[c,p]],[/(android[\w\.\s\-]{0,9});.+build/i],[s,[u,"Generic"]]],engine:[[/windows.+\sedge\/([\w\.]+)/i],[l,[a,"EdgeHTML"]],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[l,[a,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna)\/([\w\.]+)/i,/(khtml|tasman|links)[\/\s]\(?([\w\.]+)/i,/(icab)[\/\s]([23]\.[\d\.]+)/i],[a,l],[/rv\:([\w\.]{1,9}).+(gecko)/i],[l,a]],os:[[/microsoft\s(windows)\s(vista|xp)/i],[a,l],[/(windows)\snt\s6\.2;\s(arm)/i,/(windows\sphone(?:\sos)*)[\s\/]?([\d\.\s\w]*)/i,/(windows\smobile|windows)[\s\/]?([ntce\d\.\s]+\w)/i],[a,[l,g.str,y.os.windows.version]],[/(win(?=3|9|n)|win\s9x\s)([nt\d\.]+)/i],[[a,"Windows"],[l,g.str,y.os.windows.version]],[/\((bb)(10);/i],[[a,"BlackBerry"],l],[/(blackberry)\w*\/?([\w\.]*)/i,/(tizen|kaios)[\/\s]([\w\.]+)/i,/(android|webos|palm\sos|qnx|bada|rim\stablet\sos|meego|sailfish|contiki)[\/\s-]?([\w\.]*)/i],[a,l],[/(symbian\s?os|symbos|s60(?=;))[\/\s-]?([\w\.]*)/i],[[a,"Symbian"],l],[/\((series40);/i],[a],[/mozilla.+\(mobile;.+gecko.+firefox/i],[[a,"Firefox OS"],l],[/(nintendo|playstation)\s([wids34portablevu]+)/i,/(mint)[\/\s\(]?(\w*)/i,/(mageia|vectorlinux)[;\s]/i,/(joli|[kxln]?ubuntu|debian|suse|opensuse|gentoo|(?=\s)arch|slackware|fedora|mandriva|centos|pclinuxos|redhat|zenwalk|linpus)[\/\s-]?(?!chrom)([\w\.-]*)/i,/(hurd|linux)\s?([\w\.]*)/i,/(gnu)\s?([\w\.]*)/i],[a,l],[/(cros)\s[\w]+\s([\w\.]+\w)/i],[[a,"Chromium OS"],l],[/(sunos)\s?([\w\.\d]*)/i],[[a,"Solaris"],l],[/\s([frentopc-]{0,4}bsd|dragonfly)\s?([\w\.]*)/i],[a,l],[/(haiku)\s(\w+)/i],[a,l],[/cfnetwork\/.+darwin/i,/ip[honead]{2,4}(?:.*os\s([\w]+)\slike\smac|;\sopera)/i],[[l,/_/g,"."],[a,"iOS"]],[/(mac\sos\sx)\s?([\w\s\.]*)/i,/(macintosh|mac(?=_powerpc)\s)/i],[[a,"Mac OS"],[l,/_/g,"."]],[/((?:open)?solaris)[\/\s-]?([\w\.]*)/i,/(aix)\s((\d)(?=\.|\)|\s)[\w\.])*/i,/(plan\s9|minix|beos|os\/2|amigaos|morphos|risc\sos|openvms|fuchsia)/i,/(unix)\s?([\w\.]*)/i],[a,l]]},m=function(e,t){if("object"==typeof e&&(t=e,e=void 0),!(this instanceof m))return new m(e,t).getResult();var n=e||(o&&o.navigator&&o.navigator.userAgent?o.navigator.userAgent:""),r=t?d.extend(v,t):v;return this.getBrowser=function(){var e={name:void 0,version:void 0};return g.rgx.call(e,n,r.browser),e.major=d.major(e.version),e},this.getCPU=function(){var e={architecture:void 0};return g.rgx.call(e,n,r.cpu),e},this.getDevice=function(){var e={vendor:void 0,model:void 0,type:void 0};return g.rgx.call(e,n,r.device),e},this.getEngine=function(){var e={name:void 0,version:void 0};return g.rgx.call(e,n,r.engine),e},this.getOS=function(){var e={name:void 0,version:void 0};return g.rgx.call(e,n,r.os),e},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 n},this.setUA=function(e){return n=e,this},this};m.VERSION="0.7.21",m.BROWSER={NAME:a,MAJOR:"major",VERSION:l},m.CPU={ARCHITECTURE:"architecture"},m.DEVICE={MODEL:s,VENDOR:u,TYPE:c,CONSOLE:"console",MOBILE:f,SMARTTV:p,TABLET:h,WEARABLE:"wearable",EMBEDDED:"embedded"},m.ENGINE={NAME:a,VERSION:l},m.OS={NAME:a,VERSION:l},void 0!==t?(void 0!==e&&e.exports&&(t=e.exports=m),t.UAParser=m):void 0===(r=function(){return m}.call(t,n,t,e))||(e.exports=r);var b=o&&(o.jQuery||o.Zepto);if(b&&!b.ua){var w=new m;b.ua=w.getResult(),b.ua.get=function(){return w.getUA()},b.ua.set=function(e){w.setUA(e);var t=w.getResult();for(var n in t)b.ua[n]=t[n]}}}("object"==typeof window?window:this)},function(e,t,n){var r=n(33),o=n(8),i=n(18),s=n(4)("socket.io-client");e.exports=t=c;var a=t.managers={};function c(e,t){"object"==typeof e&&(t=e,e=void 0),t=t||{};var n,o=r(e),c=o.source,u=o.id,l=o.path,f=a[u]&&l in a[u].nsps;return t.forceNew||t["force new connection"]||!1===t.multiplex||f?(s("ignoring socket cache for %s",c),n=i(c,t)):(a[u]||(s("new io instance for %s",c),a[u]=i(c,t)),n=a[u]),o.query&&!t.query&&(t.query=o.query),n.socket(o.path,t)}t.protocol=o.protocol,t.connect=c,t.Manager=n(18),t.Socket=n(23)},function(e,t,n){(function(t){var r=n(13),o=n(4)("socket.io-client:url");e.exports=function(e,n){var i=e;n=n||t.location,null==e&&(e=n.protocol+"//"+n.host);"string"==typeof e&&("/"===e.charAt(0)&&(e="/"===e.charAt(1)?n.protocol+e:n.host+e),/^(https?|wss?):\/\//.test(e)||(o("protocol-less url %s",e),e=void 0!==n?n.protocol+"//"+e:"https://"+e),o("parse %s",e),i=r(e));i.port||(/^(http|ws)$/.test(i.protocol)?i.port="80":/^(http|ws)s$/.test(i.protocol)&&(i.port="443"));i.path=i.path||"/";var s=-1!==i.host.indexOf(":")?"["+i.host+"]":i.host;return i.id=i.protocol+"://"+s+":"+i.port,i.href=i.protocol+"://"+s+(n&&n.port===i.port?"":":"+i.port),i}}).call(this,n(0))},function(e,t,n){var r;function o(e){function n(){if(n.enabled){var e=n,o=+new Date,i=o-(r||o);e.diff=i,e.prev=r,e.curr=o,r=o;for(var s=new Array(arguments.length),a=0;a<s.length;a++)s[a]=arguments[a];s[0]=t.coerce(s[0]),"string"!=typeof s[0]&&s.unshift("%O");var c=0;s[0]=s[0].replace(/%([a-zA-Z%])/g,(function(n,r){if("%%"===n)return n;c++;var o=t.formatters[r];if("function"==typeof o){var i=s[c];n=o.call(e,i),s.splice(c,1),c--}return n})),t.formatArgs.call(e,s);var u=n.log||t.log||console.log.bind(console);u.apply(e,s)}}return n.namespace=e,n.enabled=t.enabled(e),n.useColors=t.useColors(),n.color=function(e){var n,r=0;for(n in e)r=(r<<5)-r+e.charCodeAt(n),r|=0;return t.colors[Math.abs(r)%t.colors.length]}(e),"function"==typeof t.init&&t.init(n),n}(t=e.exports=o.debug=o.default=o).coerce=function(e){return e instanceof Error?e.stack||e.message:e},t.disable=function(){t.enable("")},t.enable=function(e){t.save(e),t.names=[],t.skips=[];for(var n=("string"==typeof e?e:"").split(/[\s,]+/),r=n.length,o=0;o<r;o++)n[o]&&("-"===(e=n[o].replace(/\*/g,".*?"))[0]?t.skips.push(new RegExp("^"+e.substr(1)+"$")):t.names.push(new RegExp("^"+e+"$")))},t.enabled=function(e){var n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1},t.humanize=n(14),t.names=[],t.skips=[],t.formatters={}},function(e,t,n){(function(r){function o(){var e;try{e=t.storage.debug}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}(t=e.exports=n(36)).log=function(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)},t.formatArgs=function(e){var n=this.useColors;if(e[0]=(n?"%c":"")+this.namespace+(n?" %c":" ")+e[0]+(n?"%c ":" ")+"+"+t.humanize(this.diff),!n)return;var r="color: "+this.color;e.splice(1,0,r,"color: inherit");var o=0,i=0;e[0].replace(/%[a-zA-Z%]/g,(function(e){"%%"!==e&&(o++,"%c"===e&&(i=o))})),e.splice(i,0,r)},t.save=function(e){try{null==e?t.storage.removeItem("debug"):t.storage.debug=e}catch(e){}},t.load=o,t.useColors=function(){if("undefined"!=typeof window&&window.process&&"renderer"===window.process.type)return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:function(){try{return window.localStorage}catch(e){}}(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.formatters.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}},t.enable(o())}).call(this,n(3))},function(e,t,n){function r(e){var n;function r(){if(r.enabled){var e=r,o=+new Date,i=o-(n||o);e.diff=i,e.prev=n,e.curr=o,n=o;for(var s=new Array(arguments.length),a=0;a<s.length;a++)s[a]=arguments[a];s[0]=t.coerce(s[0]),"string"!=typeof s[0]&&s.unshift("%O");var c=0;s[0]=s[0].replace(/%([a-zA-Z%])/g,(function(n,r){if("%%"===n)return n;c++;var o=t.formatters[r];if("function"==typeof o){var i=s[c];n=o.call(e,i),s.splice(c,1),c--}return n})),t.formatArgs.call(e,s);var u=r.log||t.log||console.log.bind(console);u.apply(e,s)}}return r.namespace=e,r.enabled=t.enabled(e),r.useColors=t.useColors(),r.color=function(e){var n,r=0;for(n in e)r=(r<<5)-r+e.charCodeAt(n),r|=0;return t.colors[Math.abs(r)%t.colors.length]}(e),r.destroy=o,"function"==typeof t.init&&t.init(r),t.instances.push(r),r}function o(){var e=t.instances.indexOf(this);return-1!==e&&(t.instances.splice(e,1),!0)}(t=e.exports=r.debug=r.default=r).coerce=function(e){return e instanceof Error?e.stack||e.message:e},t.disable=function(){t.enable("")},t.enable=function(e){var n;t.save(e),t.names=[],t.skips=[];var r=("string"==typeof e?e:"").split(/[\s,]+/),o=r.length;for(n=0;n<o;n++)r[n]&&("-"===(e=r[n].replace(/\*/g,".*?"))[0]?t.skips.push(new RegExp("^"+e.substr(1)+"$")):t.names.push(new RegExp("^"+e+"$")));for(n=0;n<t.instances.length;n++){var i=t.instances[n];i.enabled=t.enabled(i.namespace)}},t.enabled=function(e){if("*"===e[e.length-1])return!0;var n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1},t.humanize=n(14),t.instances=[],t.names=[],t.skips=[],t.formatters={}},function(e,t,n){"use strict";(function(e){
 /*!
  * The buffer module from node.js, for the browser.
  *
  * @author   Feross Aboukhadijeh <http://feross.org>
  * @license  MIT
  */
-var r=n(40),o=n(41),i=n(42);function s(){return c.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function a(e,t){if(s()<t)throw new RangeError("Invalid typed array length");return c.TYPED_ARRAY_SUPPORT?(e=new Uint8Array(t)).__proto__=c.prototype:(null===e&&(e=new c(t)),e.length=t),e}function c(e,t,n){if(!(c.TYPED_ARRAY_SUPPORT||this instanceof c))return new c(e,t,n);if("number"==typeof e){if("string"==typeof t)throw new Error("If encoding is specified then the first argument must be a string");return f(this,e)}return u(this,e,t,n)}function u(e,t,n,r){if("number"==typeof t)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&t instanceof ArrayBuffer?function(e,t,n,r){if(t.byteLength,n<0||t.byteLength<n)throw new RangeError("'offset' is out of bounds");if(t.byteLength<n+(r||0))throw new RangeError("'length' is out of bounds");t=void 0===n&&void 0===r?new Uint8Array(t):void 0===r?new Uint8Array(t,n):new Uint8Array(t,n,r);c.TYPED_ARRAY_SUPPORT?(e=t).__proto__=c.prototype:e=h(e,t);return e}(e,t,n,r):"string"==typeof t?function(e,t,n){"string"==typeof n&&""!==n||(n="utf8");if(!c.isEncoding(n))throw new TypeError('"encoding" must be a valid string encoding');var r=0|d(t,n),o=(e=a(e,r)).write(t,n);o!==r&&(e=e.slice(0,o));return e}(e,t,n):function(e,t){if(c.isBuffer(t)){var n=0|p(t.length);return 0===(e=a(e,n)).length||t.copy(e,0,0,n),e}if(t){if("undefined"!=typeof ArrayBuffer&&t.buffer instanceof ArrayBuffer||"length"in t)return"number"!=typeof t.length||(r=t.length)!=r?a(e,0):h(e,t);if("Buffer"===t.type&&i(t.data))return h(e,t.data)}var r;throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(e,t)}function l(e){if("number"!=typeof e)throw new TypeError('"size" argument must be a number');if(e<0)throw new RangeError('"size" argument must not be negative')}function f(e,t){if(l(t),e=a(e,t<0?0:0|p(t)),!c.TYPED_ARRAY_SUPPORT)for(var n=0;n<t;++n)e[n]=0;return e}function h(e,t){var n=t.length<0?0:0|p(t.length);e=a(e,n);for(var r=0;r<n;r+=1)e[r]=255&t[r];return e}function p(e){if(e>=s())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s().toString(16)+" bytes");return 0|e}function d(e,t){if(c.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var n=e.length;if(0===n)return 0;for(var r=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":case void 0:return Q(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return z(e).length;default:if(r)return Q(e).length;t=(""+t).toLowerCase(),r=!0}}function g(e,t,n){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if((n>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return R(this,t,n);case"utf8":case"utf-8":return S(this,t,n);case"ascii":return x(this,t,n);case"latin1":case"binary":return I(this,t,n);case"base64":return B(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return M(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function y(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function m(e,t,n,r,o){if(0===e.length)return-1;if("string"==typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,isNaN(n)&&(n=o?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(o)return-1;n=e.length-1}else if(n<0){if(!o)return-1;n=0}if("string"==typeof t&&(t=c.from(t,r)),c.isBuffer(t))return 0===t.length?-1:b(e,t,n,r,o);if("number"==typeof t)return t&=255,c.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):b(e,[t],n,r,o);throw new TypeError("val must be string, number or Buffer")}function b(e,t,n,r,o){var i,s=1,a=e.length,c=t.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;s=2,a/=2,c/=2,n/=2}function u(e,t){return 1===s?e[t]:e.readUInt16BE(t*s)}if(o){var l=-1;for(i=n;i<a;i++)if(u(e,i)===u(t,-1===l?0:i-l)){if(-1===l&&(l=i),i-l+1===c)return l*s}else-1!==l&&(i-=i-l),l=-1}else for(n+c>a&&(n=a-c),i=n;i>=0;i--){for(var f=!0,h=0;h<c;h++)if(u(e,i+h)!==u(t,h)){f=!1;break}if(f)return i}return-1}function v(e,t,n,r){n=Number(n)||0;var o=e.length-n;r?(r=Number(r))>o&&(r=o):r=o;var i=t.length;if(i%2!=0)throw new TypeError("Invalid hex string");r>i/2&&(r=i/2);for(var s=0;s<r;++s){var a=parseInt(t.substr(2*s,2),16);if(isNaN(a))return s;e[n+s]=a}return s}function w(e,t,n,r){return G(Q(t,e.length-n),e,n,r)}function C(e,t,n,r){return G(function(e){for(var t=[],n=0;n<e.length;++n)t.push(255&e.charCodeAt(n));return t}(t),e,n,r)}function A(e,t,n,r){return C(e,t,n,r)}function k(e,t,n,r){return G(z(t),e,n,r)}function E(e,t,n,r){return G(function(e,t){for(var n,r,o,i=[],s=0;s<e.length&&!((t-=2)<0);++s)r=(n=e.charCodeAt(s))>>8,o=n%256,i.push(o),i.push(r);return i}(t,e.length-n),e,n,r)}function B(e,t,n){return 0===t&&n===e.length?r.fromByteArray(e):r.fromByteArray(e.slice(t,n))}function S(e,t,n){n=Math.min(e.length,n);for(var r=[],o=t;o<n;){var i,s,a,c,u=e[o],l=null,f=u>239?4:u>223?3:u>191?2:1;if(o+f<=n)switch(f){case 1:u<128&&(l=u);break;case 2:128==(192&(i=e[o+1]))&&(c=(31&u)<<6|63&i)>127&&(l=c);break;case 3:i=e[o+1],s=e[o+2],128==(192&i)&&128==(192&s)&&(c=(15&u)<<12|(63&i)<<6|63&s)>2047&&(c<55296||c>57343)&&(l=c);break;case 4:i=e[o+1],s=e[o+2],a=e[o+3],128==(192&i)&&128==(192&s)&&128==(192&a)&&(c=(15&u)<<18|(63&i)<<12|(63&s)<<6|63&a)>65535&&c<1114112&&(l=c)}null===l?(l=65533,f=1):l>65535&&(l-=65536,r.push(l>>>10&1023|55296),l=56320|1023&l),r.push(l),o+=f}return function(e){var t=e.length;if(t<=F)return String.fromCharCode.apply(String,e);var n="",r=0;for(;r<t;)n+=String.fromCharCode.apply(String,e.slice(r,r+=F));return n}(r)}t.Buffer=c,t.SlowBuffer=function(e){+e!=e&&(e=0);return c.alloc(+e)},t.INSPECT_MAX_BYTES=50,c.TYPED_ARRAY_SUPPORT=void 0!==e.TYPED_ARRAY_SUPPORT?e.TYPED_ARRAY_SUPPORT:function(){try{var e=new Uint8Array(1);return e.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===e.foo()&&"function"==typeof e.subarray&&0===e.subarray(1,1).byteLength}catch(e){return!1}}(),t.kMaxLength=s(),c.poolSize=8192,c._augment=function(e){return e.__proto__=c.prototype,e},c.from=function(e,t,n){return u(null,e,t,n)},c.TYPED_ARRAY_SUPPORT&&(c.prototype.__proto__=Uint8Array.prototype,c.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&c[Symbol.species]===c&&Object.defineProperty(c,Symbol.species,{value:null,configurable:!0})),c.alloc=function(e,t,n){return function(e,t,n,r){return l(t),t<=0?a(e,t):void 0!==n?"string"==typeof r?a(e,t).fill(n,r):a(e,t).fill(n):a(e,t)}(null,e,t,n)},c.allocUnsafe=function(e){return f(null,e)},c.allocUnsafeSlow=function(e){return f(null,e)},c.isBuffer=function(e){return!(null==e||!e._isBuffer)},c.compare=function(e,t){if(!c.isBuffer(e)||!c.isBuffer(t))throw new TypeError("Arguments must be Buffers");if(e===t)return 0;for(var n=e.length,r=t.length,o=0,i=Math.min(n,r);o<i;++o)if(e[o]!==t[o]){n=e[o],r=t[o];break}return n<r?-1:r<n?1:0},c.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},c.concat=function(e,t){if(!i(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return c.alloc(0);var n;if(void 0===t)for(t=0,n=0;n<e.length;++n)t+=e[n].length;var r=c.allocUnsafe(t),o=0;for(n=0;n<e.length;++n){var s=e[n];if(!c.isBuffer(s))throw new TypeError('"list" argument must be an Array of Buffers');s.copy(r,o),o+=s.length}return r},c.byteLength=d,c.prototype._isBuffer=!0,c.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)y(this,t,t+1);return this},c.prototype.swap32=function(){var e=this.length;if(e%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)y(this,t,t+3),y(this,t+1,t+2);return this},c.prototype.swap64=function(){var e=this.length;if(e%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)y(this,t,t+7),y(this,t+1,t+6),y(this,t+2,t+5),y(this,t+3,t+4);return this},c.prototype.toString=function(){var e=0|this.length;return 0===e?"":0===arguments.length?S(this,0,e):g.apply(this,arguments)},c.prototype.equals=function(e){if(!c.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===c.compare(this,e)},c.prototype.inspect=function(){var e="",n=t.INSPECT_MAX_BYTES;return this.length>0&&(e=this.toString("hex",0,n).match(/.{2}/g).join(" "),this.length>n&&(e+=" ... ")),"<Buffer "+e+">"},c.prototype.compare=function(e,t,n,r,o){if(!c.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===r&&(r=0),void 0===o&&(o=this.length),t<0||n>e.length||r<0||o>this.length)throw new RangeError("out of range index");if(r>=o&&t>=n)return 0;if(r>=o)return-1;if(t>=n)return 1;if(this===e)return 0;for(var i=(o>>>=0)-(r>>>=0),s=(n>>>=0)-(t>>>=0),a=Math.min(i,s),u=this.slice(r,o),l=e.slice(t,n),f=0;f<a;++f)if(u[f]!==l[f]){i=u[f],s=l[f];break}return i<s?-1:s<i?1:0},c.prototype.includes=function(e,t,n){return-1!==this.indexOf(e,t,n)},c.prototype.indexOf=function(e,t,n){return m(this,e,t,n,!0)},c.prototype.lastIndexOf=function(e,t,n){return m(this,e,t,n,!1)},c.prototype.write=function(e,t,n,r){if(void 0===t)r="utf8",n=this.length,t=0;else if(void 0===n&&"string"==typeof t)r=t,n=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t|=0,isFinite(n)?(n|=0,void 0===r&&(r="utf8")):(r=n,n=void 0)}var o=this.length-t;if((void 0===n||n>o)&&(n=o),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var i=!1;;)switch(r){case"hex":return v(this,e,t,n);case"utf8":case"utf-8":return w(this,e,t,n);case"ascii":return C(this,e,t,n);case"latin1":case"binary":return A(this,e,t,n);case"base64":return k(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return E(this,e,t,n);default:if(i)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),i=!0}},c.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var F=4096;function x(e,t,n){var r="";n=Math.min(e.length,n);for(var o=t;o<n;++o)r+=String.fromCharCode(127&e[o]);return r}function I(e,t,n){var r="";n=Math.min(e.length,n);for(var o=t;o<n;++o)r+=String.fromCharCode(e[o]);return r}function R(e,t,n){var r=e.length;(!t||t<0)&&(t=0),(!n||n<0||n>r)&&(n=r);for(var o="",i=t;i<n;++i)o+=L(e[i]);return o}function M(e,t,n){for(var r=e.slice(t,n),o="",i=0;i<r.length;i+=2)o+=String.fromCharCode(r[i]+256*r[i+1]);return o}function O(e,t,n){if(e%1!=0||e<0)throw new RangeError("offset is not uint");if(e+t>n)throw new RangeError("Trying to access beyond buffer length")}function D(e,t,n,r,o,i){if(!c.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>o||t<i)throw new RangeError('"value" argument is out of bounds');if(n+r>e.length)throw new RangeError("Index out of range")}function T(e,t,n,r){t<0&&(t=65535+t+1);for(var o=0,i=Math.min(e.length-n,2);o<i;++o)e[n+o]=(t&255<<8*(r?o:1-o))>>>8*(r?o:1-o)}function P(e,t,n,r){t<0&&(t=4294967295+t+1);for(var o=0,i=Math.min(e.length-n,4);o<i;++o)e[n+o]=t>>>8*(r?o:3-o)&255}function j(e,t,n,r,o,i){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function _(e,t,n,r,i){return i||j(e,0,n,4),o.write(e,t,n,r,23,4),n+4}function U(e,t,n,r,i){return i||j(e,0,n,8),o.write(e,t,n,r,52,8),n+8}c.prototype.slice=function(e,t){var n,r=this.length;if((e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t<e&&(t=e),c.TYPED_ARRAY_SUPPORT)(n=this.subarray(e,t)).__proto__=c.prototype;else{var o=t-e;n=new c(o,void 0);for(var i=0;i<o;++i)n[i]=this[i+e]}return n},c.prototype.readUIntLE=function(e,t,n){e|=0,t|=0,n||O(e,t,this.length);for(var r=this[e],o=1,i=0;++i<t&&(o*=256);)r+=this[e+i]*o;return r},c.prototype.readUIntBE=function(e,t,n){e|=0,t|=0,n||O(e,t,this.length);for(var r=this[e+--t],o=1;t>0&&(o*=256);)r+=this[e+--t]*o;return r},c.prototype.readUInt8=function(e,t){return t||O(e,1,this.length),this[e]},c.prototype.readUInt16LE=function(e,t){return t||O(e,2,this.length),this[e]|this[e+1]<<8},c.prototype.readUInt16BE=function(e,t){return t||O(e,2,this.length),this[e]<<8|this[e+1]},c.prototype.readUInt32LE=function(e,t){return t||O(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},c.prototype.readUInt32BE=function(e,t){return t||O(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},c.prototype.readIntLE=function(e,t,n){e|=0,t|=0,n||O(e,t,this.length);for(var r=this[e],o=1,i=0;++i<t&&(o*=256);)r+=this[e+i]*o;return r>=(o*=128)&&(r-=Math.pow(2,8*t)),r},c.prototype.readIntBE=function(e,t,n){e|=0,t|=0,n||O(e,t,this.length);for(var r=t,o=1,i=this[e+--r];r>0&&(o*=256);)i+=this[e+--r]*o;return i>=(o*=128)&&(i-=Math.pow(2,8*t)),i},c.prototype.readInt8=function(e,t){return t||O(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},c.prototype.readInt16LE=function(e,t){t||O(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},c.prototype.readInt16BE=function(e,t){t||O(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},c.prototype.readInt32LE=function(e,t){return t||O(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},c.prototype.readInt32BE=function(e,t){return t||O(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},c.prototype.readFloatLE=function(e,t){return t||O(e,4,this.length),o.read(this,e,!0,23,4)},c.prototype.readFloatBE=function(e,t){return t||O(e,4,this.length),o.read(this,e,!1,23,4)},c.prototype.readDoubleLE=function(e,t){return t||O(e,8,this.length),o.read(this,e,!0,52,8)},c.prototype.readDoubleBE=function(e,t){return t||O(e,8,this.length),o.read(this,e,!1,52,8)},c.prototype.writeUIntLE=function(e,t,n,r){(e=+e,t|=0,n|=0,r)||D(this,e,t,n,Math.pow(2,8*n)-1,0);var o=1,i=0;for(this[t]=255&e;++i<n&&(o*=256);)this[t+i]=e/o&255;return t+n},c.prototype.writeUIntBE=function(e,t,n,r){(e=+e,t|=0,n|=0,r)||D(this,e,t,n,Math.pow(2,8*n)-1,0);var o=n-1,i=1;for(this[t+o]=255&e;--o>=0&&(i*=256);)this[t+o]=e/i&255;return t+n},c.prototype.writeUInt8=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,1,255,0),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},c.prototype.writeUInt16LE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):T(this,e,t,!0),t+2},c.prototype.writeUInt16BE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):T(this,e,t,!1),t+2},c.prototype.writeUInt32LE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):P(this,e,t,!0),t+4},c.prototype.writeUInt32BE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):P(this,e,t,!1),t+4},c.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t|=0,!r){var o=Math.pow(2,8*n-1);D(this,e,t,n,o-1,-o)}var i=0,s=1,a=0;for(this[t]=255&e;++i<n&&(s*=256);)e<0&&0===a&&0!==this[t+i-1]&&(a=1),this[t+i]=(e/s>>0)-a&255;return t+n},c.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t|=0,!r){var o=Math.pow(2,8*n-1);D(this,e,t,n,o-1,-o)}var i=n-1,s=1,a=0;for(this[t+i]=255&e;--i>=0&&(s*=256);)e<0&&0===a&&0!==this[t+i+1]&&(a=1),this[t+i]=(e/s>>0)-a&255;return t+n},c.prototype.writeInt8=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,1,127,-128),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},c.prototype.writeInt16LE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):T(this,e,t,!0),t+2},c.prototype.writeInt16BE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):T(this,e,t,!1),t+2},c.prototype.writeInt32LE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,4,2147483647,-2147483648),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):P(this,e,t,!0),t+4},c.prototype.writeInt32BE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):P(this,e,t,!1),t+4},c.prototype.writeFloatLE=function(e,t,n){return _(this,e,t,!0,n)},c.prototype.writeFloatBE=function(e,t,n){return _(this,e,t,!1,n)},c.prototype.writeDoubleLE=function(e,t,n){return U(this,e,t,!0,n)},c.prototype.writeDoubleBE=function(e,t,n){return U(this,e,t,!1,n)},c.prototype.copy=function(e,t,n,r){if(n||(n=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r<n&&(r=n),r===n)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(n<0||n>=this.length)throw new RangeError("sourceStart out of bounds");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t<r-n&&(r=e.length-t+n);var o,i=r-n;if(this===e&&n<t&&t<r)for(o=i-1;o>=0;--o)e[o+t]=this[o+n];else if(i<1e3||!c.TYPED_ARRAY_SUPPORT)for(o=0;o<i;++o)e[o+t]=this[o+n];else Uint8Array.prototype.set.call(e,this.subarray(n,n+i),t);return i},c.prototype.fill=function(e,t,n,r){if("string"==typeof e){if("string"==typeof t?(r=t,t=0,n=this.length):"string"==typeof n&&(r=n,n=this.length),1===e.length){var o=e.charCodeAt(0);o<256&&(e=o)}if(void 0!==r&&"string"!=typeof r)throw new TypeError("encoding must be a string");if("string"==typeof r&&!c.isEncoding(r))throw new TypeError("Unknown encoding: "+r)}else"number"==typeof e&&(e&=255);if(t<0||this.length<t||this.length<n)throw new RangeError("Out of range index");if(n<=t)return this;var i;if(t>>>=0,n=void 0===n?this.length:n>>>0,e||(e=0),"number"==typeof e)for(i=t;i<n;++i)this[i]=e;else{var s=c.isBuffer(e)?e:Q(new c(e,r).toString()),a=s.length;for(i=0;i<n-t;++i)this[i+t]=s[i%a]}return this};var N=/[^+\/0-9A-Za-z-_]/g;function L(e){return e<16?"0"+e.toString(16):e.toString(16)}function Q(e,t){var n;t=t||1/0;for(var r=e.length,o=null,i=[],s=0;s<r;++s){if((n=e.charCodeAt(s))>55295&&n<57344){if(!o){if(n>56319){(t-=3)>-1&&i.push(239,191,189);continue}if(s+1===r){(t-=3)>-1&&i.push(239,191,189);continue}o=n;continue}if(n<56320){(t-=3)>-1&&i.push(239,191,189),o=n;continue}n=65536+(o-55296<<10|n-56320)}else o&&(t-=3)>-1&&i.push(239,191,189);if(o=null,n<128){if((t-=1)<0)break;i.push(n)}else if(n<2048){if((t-=2)<0)break;i.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;i.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;i.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return i}function z(e){return r.toByteArray(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(N,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function G(e,t,n,r){for(var o=0;o<r&&!(o+n>=t.length||o>=e.length);++o)t[o+n]=e[o];return o}}).call(this,n(39))},function(e,t,n){var r=n(45),o=n(12);e.exports=function(e){var t=e.xdomain,n=e.xscheme,i=e.enablesXDR;try{if("undefined"!=typeof XMLHttpRequest&&(!t||r))return new XMLHttpRequest}catch(e){}try{if("undefined"!=typeof XDomainRequest&&!n&&i)return new XDomainRequest}catch(e){}if(!t)try{return new(o[["Active"].concat("Object").join("X")])("Microsoft.XMLHTTP")}catch(e){}}},function(e,t){e.exports="undefined"!=typeof self?self:"undefined"!=typeof window?window:Function("return this")()},function(e,t,n){var r=n(1),o=n(14);function i(e){this.path=e.path,this.hostname=e.hostname,this.port=e.port,this.secure=e.secure,this.query=e.query,this.timestampParam=e.timestampParam,this.timestampRequests=e.timestampRequests,this.readyState="",this.agent=e.agent||!1,this.socket=e.socket,this.enablesXDR=e.enablesXDR,this.withCredentials=e.withCredentials,this.pfx=e.pfx,this.key=e.key,this.passphrase=e.passphrase,this.cert=e.cert,this.ca=e.ca,this.ciphers=e.ciphers,this.rejectUnauthorized=e.rejectUnauthorized,this.forceNode=e.forceNode,this.isReactNative=e.isReactNative,this.extraHeaders=e.extraHeaders,this.localAddress=e.localAddress}e.exports=i,o(i.prototype),i.prototype.onError=function(e,t){var n=new Error(e);return n.type="TransportError",n.description=t,this.emit("error",n),this},i.prototype.open=function(){return"closed"!==this.readyState&&""!==this.readyState||(this.readyState="opening",this.doOpen()),this},i.prototype.close=function(){return"opening"!==this.readyState&&"open"!==this.readyState||(this.doClose(),this.onClose()),this},i.prototype.send=function(e){if("open"!==this.readyState)throw new Error("Transport not open");this.write(e)},i.prototype.onOpen=function(){this.readyState="open",this.writable=!0,this.emit("open")},i.prototype.onData=function(e){var t=r.decodePacket(e,this.socket.binaryType);this.onPacket(t)},i.prototype.onPacket=function(e){this.emit("packet",e)},i.prototype.onClose=function(){this.readyState="closed",this.emit("close")}},function(e,t,n){function r(e){if(e)return function(e){for(var t in r.prototype)e[t]=r.prototype[t];return e}(e)}e.exports=r,r.prototype.on=r.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},r.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},r.prototype.off=r.prototype.removeListener=r.prototype.removeAllListeners=r.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var n,r=this._callbacks["$"+e];if(!r)return this;if(1==arguments.length)return delete this._callbacks["$"+e],this;for(var o=0;o<r.length;o++)if((n=r[o])===t||n.fn===t){r.splice(o,1);break}return 0===r.length&&delete this._callbacks["$"+e],this},r.prototype.emit=function(e){this._callbacks=this._callbacks||{};for(var t=new Array(arguments.length-1),n=this._callbacks["$"+e],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(n){r=0;for(var o=(n=n.slice(0)).length;r<o;++r)n[r].apply(this,t)}return this},r.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},r.prototype.hasListeners=function(e){return!!this.listeners(e).length}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getServerUrlFromLocation=function(){if(location){if("http:"===location.protocol)return"http://"+location.hostname+":9559";if("https:"===location.protocol)return"https://"+location.hostname+":5443"}return null},t.getServerUrlFromLocalhost=function(){if(location&&"https:"===location.protocol)return"https://127.0.0.1:5443";return"http://127.0.0.1:9559"},t.isDebugMode=function(){return!("true"!==function(){var e=window.location.search.substr(1).split("&");if(""===e)return{};for(var t={},n=0;n<e.length;n++){var r=e[n].split("=",2);1===r.length?t[r[0]]="":t[r[0]]=decodeURIComponent(r[1].replace(/\+/g," "))}return t}().debug)},t.getDeviceName=function(){var e=(new o.UAParser).getResult(),t="Unknown";e.device.vendor&&e.device.model?t="[".concat(e.device.vendor,"] ").concat(e.device.model):e.os.name&&e.browser.name&&(t="[".concat(e.os.name,"] ").concat(e.browser.name));return t},t.getClientId=function(){var e=localStorage.getItem("clientId");if(null===e){var t=(new o.UAParser).getResult(),n="Unknown";void 0!==t.device.vendor?n=t.device.vendor:void 0!==t.os.name&&(n=t.os.name),e=n+i(),localStorage.setItem("clientId",e)}return e},t.isPromise=function(e){return!!e&&"function"==typeof e.then},t.getUniqueId=i,t.getOffloadId=function(e){return e+"_"+e.toLowerCase().split("").reverse().join("")};var r,o=n(60);(r=n(0))&&r.__esModule;function i(){return"_"+Math.random().toString(36).substr(2,9)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WorkerManager=void 0;var r=a(n(32)),o=n(63),i=n(31),s=n(15);function a(e){return e&&e.__esModule?e:{default:e}}function c(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function u(e,t,n){return t&&c(e.prototype,t),n&&c(e,n),e}function l(e){return(l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var f,h=new(a(n(0)).default)("worker-manager.js"),p=(0,s.isDebugMode)(),d="object"===("undefined"==typeof tizen?"undefined":l(tizen)),g=function(){function e(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.workerInfos_=new Map,this.activeWorkers_=new Map,this.capabilities_=new Map,this.socket_=null,this.id_=(0,s.getClientId)(),this.qrCode_=null,this.callbacks_={qrcode:[],capability:[]},this.signalingStatus=!1,this}return u(e,null,[{key:"getInstance",value:function(){return f||(f=new e,p||f.connect()),f}}]),u(e,[{key:"connect",value:function(e){var t=e||this.getServerUrl_();if(null!==t)return t.endsWith("/offload-js")||(t+="/offload-js"),null!==this.socket_&&this.socket_.close(),h.time("socket connected"),this.socket_=(0,r.default)(t),this.socket_.on("greeting",this.initFromGreeting_.bind(this)),this.socket_.on("worker",this.handleWorkerEvent_.bind(this)),this.socket_.on("capabilities",this.updateCapabilities_.bind(this)),this.socket_.on("message",this.handleMessage_.bind(this)),this.socket_.on("connect",this.socketConnected_.bind(this)),this.socket_.on("disconnect",this.socketDisconnected_.bind(this)),t;h.error("No valid server URL found.")}},{key:"getServerUrl_",value:function(){return d?(0,s.getServerUrlFromLocalhost)():(0,s.getServerUrlFromLocation)()}},{key:"initFromGreeting_",value:function(e){for(h.debug("greeting: "+JSON.stringify(e)),this.signalingStatus=!0,this.qrCode_=e.qrCode,this.workerInfos_=new Map(e.workers);this.callbacks_.qrcode.length;)this.callbacks_.qrcode.pop().call(this,this.qrCode_)}},{key:"updateCapabilities_",value:function(e){for(h.debug("capabilities: ".concat(JSON.stringify(e))),this.capabilities_=new Map(e);this.callbacks_.capability.length;)this.callbacks_.capability.pop().call(this,this.capabilities_)}},{key:"handleWorkerEvent_",value:function(e){if("join"===e.event){if(h.debug("join: '".concat(e.workerId,"' - '").concat(e.name,"', '").concat(e.features,"', '").concat(e.mediaDeviceInfos,"'")),this.workerInfos_.set(e.workerId,{socketId:e.socketId,name:e.name,features:e.features,mediaDeviceInfos:e.mediaDeviceInfos,compute_tasks:0}),this.capabilities_.has(e.workerId)){var t=this.capabilities_.get(e.workerId);t.options&&(h.debug("resolve successCallback"),t.options.successCallback(),t.options=null)}}else"bye"===e.event&&(h.debug("bye: '".concat(e.workerId,"'")),this.workerInfos_.delete(e.workerId),this.activeWorkers_.delete(e.workerId))}},{key:"handleMessage_",value:function(e){this.activeWorkers_.has(e.from)&&this.activeWorkers_.get(e.from).handleMessage(e.message),"computeResult"===e.message.type&&(0,i.computeResultObtained)(e)}},{key:"socketConnected_",value:function(){h.debug("".concat(this.socket_.id," connected")),h.timeEnd("socket connected"),this.socket_&&this.socket_.emit("create")}},{key:"socketDisconnected_",value:function(){h.debug("".concat(this.socket_.id," disconnected")),this.signalingStatus=!1}},{key:"getOrCreateWorker",value:function(e){if(this.activeWorkers_.has(e))return this.activeWorkers_.get(e);var t=new o.Worker(e);return this.activeWorkers_.set(e,t),t}},{key:"getWorkerInfos",value:function(){return this.workerInfos_}},{key:"getSupportedWorkers",value:function(e){var t=this,n=[];return this.capabilities_.forEach((function(t,r,o){t.features.indexOf(e)>=0&&n.push({id:r,name:t.name})})),this.workerInfos_.forEach((function(r,o,i){!t.capabilities_.has(o)&&r.features.indexOf(e)>=0&&n.push({id:o,name:r.name})})),n}},{key:"getId",value:function(){return this.id_}},{key:"requestService",value:function(e,t){if(this.workerInfos_.has(e))return h.debug("Already existed in workInfos. Resolve successCallback directly"),void t.successCallback();this.capabilities_.get(e).options=t,this.socket_.emit("requestService",e)}},{key:"updateCapability",value:function(e){h.debug("updateCapability"),this.socket_.emit("getcapabilities"),this.callbacks_.capability.push(e)}},{key:"sendMessage",value:function(e,t){this.socket_?this.socket_.emit("message",{to:e,from:this.socket_.id,message:t}):h.error("socket is null")}},{key:"getQrCode",value:function(){var e=this;return new Promise((function(t){e.qrCode_?t(e.qrCode_):e.callbacks_.qrcode.push(t)}))}}]),e}();t.WorkerManager=g},function(e,t){var n=/^(?:(?![^:@]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@]*)(?::([^:@]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,r=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];e.exports=function(e){var t=e,o=e.indexOf("["),i=e.indexOf("]");-1!=o&&-1!=i&&(e=e.substring(0,o)+e.substring(o,i).replace(/:/g,";")+e.substring(i,e.length));for(var s=n.exec(e||""),a={},c=14;c--;)a[r[c]]=s[c]||"";return-1!=o&&-1!=i&&(a.source=t,a.host=a.host.substring(1,a.host.length-1).replace(/;/g,":"),a.authority=a.authority.replace("[","").replace("]","").replace(/;/g,":"),a.ipv6uri=!0),a}},function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},function(e,t,n){(function(t){e.exports=function(e){return n&&t.isBuffer(e)||r&&(e instanceof ArrayBuffer||function(e){return"function"==typeof ArrayBuffer.isView?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer}(e))};var n="function"==typeof t&&"function"==typeof t.isBuffer,r="function"==typeof ArrayBuffer}).call(this,n(10).Buffer)},function(e,t,n){var r=n(43),o=n(26),i=n(9),s=n(8),a=n(27),c=n(28),u=n(2)("socket.io-client:manager"),l=n(25),f=n(59),h=Object.prototype.hasOwnProperty;function p(e,t){if(!(this instanceof p))return new p(e,t);e&&"object"==typeof e&&(t=e,e=void 0),(t=t||{}).path=t.path||"/socket.io",this.nsps={},this.subs=[],this.opts=t,this.reconnection(!1!==t.reconnection),this.reconnectionAttempts(t.reconnectionAttempts||1/0),this.reconnectionDelay(t.reconnectionDelay||1e3),this.reconnectionDelayMax(t.reconnectionDelayMax||5e3),this.randomizationFactor(t.randomizationFactor||.5),this.backoff=new f({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(null==t.timeout?2e4:t.timeout),this.readyState="closed",this.uri=e,this.connecting=[],this.lastPing=null,this.encoding=!1,this.packetBuffer=[];var n=t.parser||s;this.encoder=new n.Encoder,this.decoder=new n.Decoder,this.autoConnect=!1!==t.autoConnect,this.autoConnect&&this.open()}e.exports=p,p.prototype.emitAll=function(){for(var e in this.emit.apply(this,arguments),this.nsps)h.call(this.nsps,e)&&this.nsps[e].emit.apply(this.nsps[e],arguments)},p.prototype.updateSocketIds=function(){for(var e in this.nsps)h.call(this.nsps,e)&&(this.nsps[e].id=this.generateId(e))},p.prototype.generateId=function(e){return("/"===e?"":e+"#")+this.engine.id},i(p.prototype),p.prototype.reconnection=function(e){return arguments.length?(this._reconnection=!!e,this):this._reconnection},p.prototype.reconnectionAttempts=function(e){return arguments.length?(this._reconnectionAttempts=e,this):this._reconnectionAttempts},p.prototype.reconnectionDelay=function(e){return arguments.length?(this._reconnectionDelay=e,this.backoff&&this.backoff.setMin(e),this):this._reconnectionDelay},p.prototype.randomizationFactor=function(e){return arguments.length?(this._randomizationFactor=e,this.backoff&&this.backoff.setJitter(e),this):this._randomizationFactor},p.prototype.reconnectionDelayMax=function(e){return arguments.length?(this._reconnectionDelayMax=e,this.backoff&&this.backoff.setMax(e),this):this._reconnectionDelayMax},p.prototype.timeout=function(e){return arguments.length?(this._timeout=e,this):this._timeout},p.prototype.maybeReconnectOnOpen=function(){!this.reconnecting&&this._reconnection&&0===this.backoff.attempts&&this.reconnect()},p.prototype.open=p.prototype.connect=function(e,t){if(u("readyState %s",this.readyState),~this.readyState.indexOf("open"))return this;u("opening %s",this.uri),this.engine=r(this.uri,this.opts);var n=this.engine,o=this;this.readyState="opening",this.skipReconnect=!1;var i=a(n,"open",(function(){o.onopen(),e&&e()})),s=a(n,"error",(function(t){if(u("connect_error"),o.cleanup(),o.readyState="closed",o.emitAll("connect_error",t),e){var n=new Error("Connection error");n.data=t,e(n)}else o.maybeReconnectOnOpen()}));if(!1!==this._timeout){var c=this._timeout;u("connect attempt will timeout after %d",c);var l=setTimeout((function(){u("connect attempt timed out after %d",c),i.destroy(),n.close(),n.emit("error","timeout"),o.emitAll("connect_timeout",c)}),c);this.subs.push({destroy:function(){clearTimeout(l)}})}return this.subs.push(i),this.subs.push(s),this},p.prototype.onopen=function(){u("open"),this.cleanup(),this.readyState="open",this.emit("open");var e=this.engine;this.subs.push(a(e,"data",c(this,"ondata"))),this.subs.push(a(e,"ping",c(this,"onping"))),this.subs.push(a(e,"pong",c(this,"onpong"))),this.subs.push(a(e,"error",c(this,"onerror"))),this.subs.push(a(e,"close",c(this,"onclose"))),this.subs.push(a(this.decoder,"decoded",c(this,"ondecoded")))},p.prototype.onping=function(){this.lastPing=new Date,this.emitAll("ping")},p.prototype.onpong=function(){this.emitAll("pong",new Date-this.lastPing)},p.prototype.ondata=function(e){this.decoder.add(e)},p.prototype.ondecoded=function(e){this.emit("packet",e)},p.prototype.onerror=function(e){u("error",e),this.emitAll("error",e)},p.prototype.socket=function(e,t){var n=this.nsps[e];if(!n){n=new o(this,e,t),this.nsps[e]=n;var r=this;n.on("connecting",i),n.on("connect",(function(){n.id=r.generateId(e)})),this.autoConnect&&i()}function i(){~l(r.connecting,n)||r.connecting.push(n)}return n},p.prototype.destroy=function(e){var t=l(this.connecting,e);~t&&this.connecting.splice(t,1),this.connecting.length||this.close()},p.prototype.packet=function(e){u("writing packet %j",e);var t=this;e.query&&0===e.type&&(e.nsp+="?"+e.query),t.encoding?t.packetBuffer.push(e):(t.encoding=!0,this.encoder.encode(e,(function(n){for(var r=0;r<n.length;r++)t.engine.write(n[r],e.options);t.encoding=!1,t.processPacketQueue()})))},p.prototype.processPacketQueue=function(){if(this.packetBuffer.length>0&&!this.encoding){var e=this.packetBuffer.shift();this.packet(e)}},p.prototype.cleanup=function(){u("cleanup");for(var e=this.subs.length,t=0;t<e;t++){this.subs.shift().destroy()}this.packetBuffer=[],this.encoding=!1,this.lastPing=null,this.decoder.destroy()},p.prototype.close=p.prototype.disconnect=function(){u("disconnect"),this.skipReconnect=!0,this.reconnecting=!1,"opening"===this.readyState&&this.cleanup(),this.backoff.reset(),this.readyState="closed",this.engine&&this.engine.close()},p.prototype.onclose=function(e){u("onclose"),this.cleanup(),this.backoff.reset(),this.readyState="closed",this.emit("close",e),this._reconnection&&!this.skipReconnect&&this.reconnect()},p.prototype.reconnect=function(){if(this.reconnecting||this.skipReconnect)return this;var e=this;if(this.backoff.attempts>=this._reconnectionAttempts)u("reconnect failed"),this.backoff.reset(),this.emitAll("reconnect_failed"),this.reconnecting=!1;else{var t=this.backoff.duration();u("will wait %dms before reconnect attempt",t),this.reconnecting=!0;var n=setTimeout((function(){e.skipReconnect||(u("attempting reconnect"),e.emitAll("reconnect_attempt",e.backoff.attempts),e.emitAll("reconnecting",e.backoff.attempts),e.skipReconnect||e.open((function(t){t?(u("reconnect attempt error"),e.reconnecting=!1,e.reconnect(),e.emitAll("reconnect_error",t.data)):(u("reconnect success"),e.onreconnect())})))}),t);this.subs.push({destroy:function(){clearTimeout(n)}})}},p.prototype.onreconnect=function(){var e=this.backoff.attempts;this.reconnecting=!1,this.backoff.reset(),this.updateSocketIds(),this.emitAll("reconnect",e)}},function(e,t,n){var r=n(11),o=n(46),i=n(55),s=n(56);t.polling=function(e){var t=!1,n=!1,s=!1!==e.jsonp;if("undefined"!=typeof location){var a="https:"===location.protocol,c=location.port;c||(c=a?443:80),t=e.hostname!==location.hostname||c!==e.port,n=e.secure!==a}if(e.xdomain=t,e.xscheme=n,"open"in new r(e)&&!e.forceJSONP)return new o(e);if(!s)throw new Error("JSONP disabled");return new i(e)},t.websocket=s},function(e,t,n){var r=n(13),o=n(4),i=n(1),s=n(5),a=n(24),c=n(6)("engine.io-client:polling");e.exports=l;var u=null!=new(n(11))({xdomain:!1}).responseType;function l(e){var t=e&&e.forceBase64;u&&!t||(this.supportsBinary=!1),r.call(this,e)}s(l,r),l.prototype.name="polling",l.prototype.doOpen=function(){this.poll()},l.prototype.pause=function(e){var t=this;function n(){c("paused"),t.readyState="paused",e()}if(this.readyState="pausing",this.polling||!this.writable){var r=0;this.polling&&(c("we are currently polling - waiting to pause"),r++,this.once("pollComplete",(function(){c("pre-pause polling complete"),--r||n()}))),this.writable||(c("we are currently writing - waiting to pause"),r++,this.once("drain",(function(){c("pre-pause writing complete"),--r||n()})))}else n()},l.prototype.poll=function(){c("polling"),this.polling=!0,this.doPoll(),this.emit("poll")},l.prototype.onData=function(e){var t=this;c("polling got data %s",e);i.decodePayload(e,this.socket.binaryType,(function(e,n,r){if("opening"===t.readyState&&t.onOpen(),"close"===e.type)return t.onClose(),!1;t.onPacket(e)})),"closed"!==this.readyState&&(this.polling=!1,this.emit("pollComplete"),"open"===this.readyState?this.poll():c('ignoring poll - transport state "%s"',this.readyState))},l.prototype.doClose=function(){var e=this;function t(){c("writing close packet"),e.write([{type:"close"}])}"open"===this.readyState?(c("transport open - closing"),t()):(c("transport not open - deferring close"),this.once("open",t))},l.prototype.write=function(e){var t=this;this.writable=!1;var n=function(){t.writable=!0,t.emit("drain")};i.encodePayload(e,this.supportsBinary,(function(e){t.doWrite(e,n)}))},l.prototype.uri=function(){var e=this.query||{},t=this.secure?"https":"http",n="";return!1!==this.timestampRequests&&(e[this.timestampParam]=a()),this.supportsBinary||e.sid||(e.b64=1),e=o.encode(e),this.port&&("https"===t&&443!==Number(this.port)||"http"===t&&80!==Number(this.port))&&(n=":"+this.port),e.length&&(e="?"+e),t+"://"+(-1!==this.hostname.indexOf(":")?"["+this.hostname+"]":this.hostname)+n+this.path+e}},function(e,t,n){(function(t){var r=n(48),o=Object.prototype.toString,i="function"==typeof Blob||"undefined"!=typeof Blob&&"[object BlobConstructor]"===o.call(Blob),s="function"==typeof File||"undefined"!=typeof File&&"[object FileConstructor]"===o.call(File);e.exports=function e(n){if(!n||"object"!=typeof n)return!1;if(r(n)){for(var o=0,a=n.length;o<a;o++)if(e(n[o]))return!0;return!1}if("function"==typeof t&&t.isBuffer&&t.isBuffer(n)||"function"==typeof ArrayBuffer&&n instanceof ArrayBuffer||i&&n instanceof Blob||s&&n instanceof File)return!0;if(n.toJSON&&"function"==typeof n.toJSON&&1===arguments.length)return e(n.toJSON(),!0);for(var c in n)if(Object.prototype.hasOwnProperty.call(n,c)&&e(n[c]))return!0;return!1}}).call(this,n(10).Buffer)},function(e,t,n){"use strict";var r,o="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-_".split(""),i={},s=0,a=0;function c(e){var t="";do{t=o[e%64]+t,e=Math.floor(e/64)}while(e>0);return t}function u(){var e=c(+new Date);return e!==r?(s=0,r=e):e+"."+c(s++)}for(;a<64;a++)i[o[a]]=a;u.encode=c,u.decode=function(e){var t=0;for(a=0;a<e.length;a++)t=64*t+i[e.charAt(a)];return t},e.exports=u},function(e,t){var n=[].indexOf;e.exports=function(e,t){if(n)return e.indexOf(t);for(var r=0;r<e.length;++r)if(e[r]===t)return r;return-1}},function(e,t,n){var r=n(8),o=n(9),i=n(58),s=n(27),a=n(28),c=n(2)("socket.io-client:socket"),u=n(4),l=n(23);e.exports=p;var f={connect:1,connect_error:1,connect_timeout:1,connecting:1,disconnect:1,error:1,reconnect:1,reconnect_attempt:1,reconnect_failed:1,reconnect_error:1,reconnecting:1,ping:1,pong:1},h=o.prototype.emit;function p(e,t,n){this.io=e,this.nsp=t,this.json=this,this.ids=0,this.acks={},this.receiveBuffer=[],this.sendBuffer=[],this.connected=!1,this.disconnected=!0,this.flags={},n&&n.query&&(this.query=n.query),this.io.autoConnect&&this.open()}o(p.prototype),p.prototype.subEvents=function(){if(!this.subs){var e=this.io;this.subs=[s(e,"open",a(this,"onopen")),s(e,"packet",a(this,"onpacket")),s(e,"close",a(this,"onclose"))]}},p.prototype.open=p.prototype.connect=function(){return this.connected||(this.subEvents(),this.io.open(),"open"===this.io.readyState&&this.onopen(),this.emit("connecting")),this},p.prototype.send=function(){var e=i(arguments);return e.unshift("message"),this.emit.apply(this,e),this},p.prototype.emit=function(e){if(f.hasOwnProperty(e))return h.apply(this,arguments),this;var t=i(arguments),n={type:(void 0!==this.flags.binary?this.flags.binary:l(t))?r.BINARY_EVENT:r.EVENT,data:t,options:{}};return n.options.compress=!this.flags||!1!==this.flags.compress,"function"==typeof t[t.length-1]&&(c("emitting packet with ack id %d",this.ids),this.acks[this.ids]=t.pop(),n.id=this.ids++),this.connected?this.packet(n):this.sendBuffer.push(n),this.flags={},this},p.prototype.packet=function(e){e.nsp=this.nsp,this.io.packet(e)},p.prototype.onopen=function(){if(c("transport is open - connecting"),"/"!==this.nsp)if(this.query){var e="object"==typeof this.query?u.encode(this.query):this.query;c("sending connect packet with query %s",e),this.packet({type:r.CONNECT,query:e})}else this.packet({type:r.CONNECT})},p.prototype.onclose=function(e){c("close (%s)",e),this.connected=!1,this.disconnected=!0,delete this.id,this.emit("disconnect",e)},p.prototype.onpacket=function(e){var t=e.nsp===this.nsp,n=e.type===r.ERROR&&"/"===e.nsp;if(t||n)switch(e.type){case r.CONNECT:this.onconnect();break;case r.EVENT:case r.BINARY_EVENT:this.onevent(e);break;case r.ACK:case r.BINARY_ACK:this.onack(e);break;case r.DISCONNECT:this.ondisconnect();break;case r.ERROR:this.emit("error",e.data)}},p.prototype.onevent=function(e){var t=e.data||[];c("emitting event %j",t),null!=e.id&&(c("attaching ack callback to event"),t.push(this.ack(e.id))),this.connected?h.apply(this,t):this.receiveBuffer.push(t)},p.prototype.ack=function(e){var t=this,n=!1;return function(){if(!n){n=!0;var o=i(arguments);c("sending ack %j",o),t.packet({type:l(o)?r.BINARY_ACK:r.ACK,id:e,data:o})}}},p.prototype.onack=function(e){var t=this.acks[e.id];"function"==typeof t?(c("calling ack %s with %j",e.id,e.data),t.apply(this,e.data),delete this.acks[e.id]):c("bad ack %s",e.id)},p.prototype.onconnect=function(){this.connected=!0,this.disconnected=!1,this.emit("connect"),this.emitBuffered()},p.prototype.emitBuffered=function(){var e;for(e=0;e<this.receiveBuffer.length;e++)h.apply(this,this.receiveBuffer[e]);for(this.receiveBuffer=[],e=0;e<this.sendBuffer.length;e++)this.packet(this.sendBuffer[e]);this.sendBuffer=[]},p.prototype.ondisconnect=function(){c("server disconnect (%s)",this.nsp),this.destroy(),this.onclose("io server disconnect")},p.prototype.destroy=function(){if(this.subs){for(var e=0;e<this.subs.length;e++)this.subs[e].destroy();this.subs=null}this.io.destroy(this)},p.prototype.close=p.prototype.disconnect=function(){return this.connected&&(c("performing disconnect (%s)",this.nsp),this.packet({type:r.DISCONNECT})),this.destroy(),this.connected&&this.onclose("io client disconnect"),this},p.prototype.compress=function(e){return this.flags.compress=e,this},p.prototype.binary=function(e){return this.flags.binary=e,this}},function(e,t){e.exports=function(e,t,n){return e.on(t,n),{destroy:function(){e.removeListener(t,n)}}}},function(e,t){var n=[].slice;e.exports=function(e,t){if("string"==typeof t&&(t=e[t]),"function"!=typeof t)throw new Error("bind() requires a function");var r=n.call(arguments,2);return function(){return t.apply(e,r.concat(n.call(arguments)))}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"Resource",{enumerable:!0,get:function(){return r.Resource}}),Object.defineProperty(t,"Worker",{enumerable:!0,get:function(){return o.Worker}}),Object.defineProperty(t,"WorkerManager",{enumerable:!0,get:function(){return i.WorkerManager}});var r=n(70),o=n(63),i=n(16)},,function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.computeResultObtained=computeResultObtained,exports.loadConfigurationFrom=loadConfigurationFrom;var _workerManager=__webpack_require__(16),_OffloadIDAndPromiseMap=_interopRequireDefault(__webpack_require__(66)),_serializeJavascript=_interopRequireDefault(__webpack_require__(67)),_logger=_interopRequireDefault(__webpack_require__(0));function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}function _slicedToArray(e,t){return _arrayWithHoles(e)||_iterableToArrayLimit(e,t)||_unsupportedIterableToArray(e,t)||_nonIterableRest()}function _nonIterableRest(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function _iterableToArrayLimit(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,o=!1,i=void 0;try{for(var s,a=e[Symbol.iterator]();!(r=(s=a.next()).done)&&(n.push(s.value),!t||n.length!==t);r=!0);}catch(e){o=!0,i=e}finally{try{r||null==a.return||a.return()}finally{if(o)throw i}}return n}}function _arrayWithHoles(e){if(Array.isArray(e))return e}function _createForOfIteratorHelper(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=_unsupportedIterableToArray(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,s=!0,a=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return s=e.done,e},e:function(e){a=!0,i=e},f:function(){try{s||null==n.return||n.return()}finally{if(a)throw i}}}}function _unsupportedIterableToArray(e,t){if(e){if("string"==typeof e)return _arrayLikeToArray(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?_arrayLikeToArray(e,t):void 0}}function _arrayLikeToArray(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var logger=new _logger.default("task/index.js"),workerManager,workers,coffConfigs;function computeResultObtained(e,t){var n=e.data,r=n.offloadId,o=n.result;workers.get(t).compute_tasks--,_OffloadIDAndPromiseMap.default.getResolver(r)(o)}function loadConfigurationFrom(e){try{var t=new XMLHttpRequest("application/json");if(t.open("GET",e,!1),t.send(null),200!==t.status)throw logger.error("Unable to load config file: "+t.status),new Error("Unable to load config file");coffConfigs=JSON.parse(t.responseText),startOffloading()}catch(e){throw logger.error(e),new Error("Unable to load config file")}}var startOffloading=function startOffloading(){var offloadInfoMap=new Map,ELAPSED_TIME_THRESHOLD_MS=-1;if(coffConfigs&&coffConfigs.functions&&coffConfigs.functions.length>0){var _iterator=_createForOfIteratorHelper(coffConfigs.functions),_step;try{for(_iterator.s();!(_step=_iterator.n()).done;){var func=_step.value;makeOffloadable(func),func.asyncDeps&&func.asyncDeps.length>0&&reWriteNonOffloadableAsyncFunction(func)}}catch(e){_iterator.e(e)}finally{_iterator.f()}}else logger.debug("Config file is not in expected format. Offloading will not work.");function makeOffloadable(fn){for(var functionName=fn.id,names=functionName.split("."),object=window,i=0;i<names.length-1;i++)object=object[names[i]];if("function"==typeof object[names[names.length-1]]){var realName=names[names.length-1],offloadId=realName+"_"+Math.random().toString(36).substr(2,9);offloadInfoMap[offloadId]={funcObject:object[realName],elapsedTime:0};var funcString=object[realName].toString(),params=funcString.slice(funcString.indexOf("("),funcString.indexOf(")")+1),newoffloadableFuncDef="object[realName] = function "+realName+params+' {\n  let ret;\n  const args = Array.prototype.slice.call(arguments);\n  if (offloadInfoMap["'+offloadId+'"].elapsedTime > ELAPSED_TIME_THRESHOLD_MS) {\n    const t0 = performance.now();\n    ret = offloadTo("'+offloadId+'", args);\n    const t1 = performance.now();\n    console.log("elapsed time for '+realName+': " + (t1 - t0));\n  } else {\n    const t0 = performance.now();\n    ret = offloadInfoMap["'+offloadId+'"].funcObject.\n        apply(null, args);\n    const t1 = performance.now();\n    console.log("elapsed time for '+realName+': " + (t1 - t0));\n    offloadInfoMap["'+offloadId+'"].elapsedTime = t1 - t0;\n  }\n  return ret;\n};';(fn.isAsync||fn.asyncDeps&&fn.asyncDeps.length>0)&&(newoffloadableFuncDef="object[realName] = async function "+realName+params+' {\n  let ret;\n  const args = Array.prototype.slice.call(arguments);\n  if (offloadInfoMap["'+offloadId+'"].elapsedTime > ELAPSED_TIME_THRESHOLD_MS) {\n    ret = offloadToAsync("'+offloadId+'", args);\n  } else {\n    const t0 = performance.now();\n    ret = offloadInfoMap["'+offloadId+'"].funcObject.\n        apply(null, args);\n    const t1 = performance.now();\n    console.log("elapsed time for '+realName+': " + (t1 - t0));\n    offloadInfoMap["'+offloadId+'"].elapsedTime = t1 - t0;\n  }\n  return ret;\n};'),eval(newoffloadableFuncDef),logger.debug("From now on, "+functionName+" is offloadable.")}else logger.debug(functionName+"is not function object.")}function findOffloadWorker(){workerManager=_workerManager.WorkerManager.getInstance();var e,t=void 0,n=999999,r=_createForOfIteratorHelper((workers=workerManager.getWorkerInfos()).entries());try{for(r.s();!(e=r.n()).done;){var o,i=_slicedToArray(e.value,2),s=i[0],a=i[1],c=_createForOfIteratorHelper(a.features);try{for(c.s();!(o=c.n()).done;){"COMPUTE"===o.value&&a.compute_tasks<n&&(t=s,n=a.compute_tasks)}}catch(e){c.e(e)}finally{c.f()}}}catch(e){r.e(e)}finally{r.f()}return t}function reWriteNonOffloadableAsyncFunction(func){var offloadableFuncName=func.id,offloadableFuncDeps=func.asyncDeps;offloadableFuncDeps.forEach((function(dependency){for(var names=dependency.split("."),object=window,i=0;i<names.length-1;i++)object=object[names[i]];if("function"==typeof object[names[names.length-1]]){var realName=names[names.length-1],funcString=(0,_serializeJavascript.default)(object[realName]).toString(),params=funcString.slice(funcString.indexOf("("),funcString.indexOf(")")+1),fnBody=funcString.slice(funcString.indexOf("{"),funcString.lastIndexOf("}")+1).replace(offloadableFuncName+"(","await "+offloadableFuncName+"("),newFuncDefAsync="object[realName] = async function "+realName+params+fnBody;eval(newFuncDefAsync),logger.debug(dependency+" is re-written successfully.")}else logger.debug(dependency+" is not a function object.")}))}function offloadToAsync(e,t){var n=new Promise((function(n,r){logger.debug("Function "+offloadInfoMap[e].funcObject.name+" will be offloaded asynchronously with "+t.toString());var o={};o.execStatement=offloadInfoMap[e].funcObject.toString()+"\n"+offloadInfoMap[e].funcObject.name+".call(null"+(t.length>0?", "+(0,_serializeJavascript.default)(t):"")+");",o.timeout=3e3,o.offloadId=e;var i=findOffloadWorker();void 0!==i?(workers.get(i).compute_tasks++,_OffloadIDAndPromiseMap.default.setResolver(e,n),workerManager.getOrCreateWorker(i).startJob({arguments:JSON.stringify(o),feature:"COMPUTE"})):(logger.debug("No compute worker registered"),n(void 0))}));return _OffloadIDAndPromiseMap.default.setPromise(e,n),n}function offloadTo(e,t){logger.debug("Function "+offloadInfoMap[e].funcObject.name+" will be offloaded with "+t.toString());try{var n=new XMLHttpRequest("application/json");n.open("POST","http://127.0.0.1:9559/api/js-offloading",!1);var r={};r.execStatement=offloadInfoMap[e].funcObject.toString()+"\n"+offloadInfoMap[e].funcObject.name+".call(null"+(t.length>0?", "+(0,_serializeJavascript.default)(t):"")+");",r.timeout=3e3;var o=findOffloadWorker();void 0!==o&&(workers.get(o).compute_tasks++,r.workerSocket=workers.get(o).socketId),n.send(JSON.stringify(r));var i=void 0;if(200===n.status)i=JSON.parse(n.responseText).result,workers.get(o).compute_tasks--;else logger.debug("Unable to offload "+offloadInfoMap[e].funcObject.name+": "+n.status);return i}catch(e){return logger.error(e),0}}}},function(e,t,n){var r=n(33),o=n(8),i=n(20),s=n(2)("socket.io-client");e.exports=t=c;var a=t.managers={};function c(e,t){"object"==typeof e&&(t=e,e=void 0),t=t||{};var n,o=r(e),c=o.source,u=o.id,l=o.path,f=a[u]&&l in a[u].nsps;return t.forceNew||t["force new connection"]||!1===t.multiplex||f?(s("ignoring socket cache for %s",c),n=i(c,t)):(a[u]||(s("new io instance for %s",c),a[u]=i(c,t)),n=a[u]),o.query&&!t.query&&(t.query=o.query),n.socket(o.path,t)}t.protocol=o.protocol,t.connect=c,t.Manager=n(20),t.Socket=n(26)},function(e,t,n){var r=n(17),o=n(2)("socket.io-client:url");e.exports=function(e,t){var n=e;t=t||"undefined"!=typeof location&&location,null==e&&(e=t.protocol+"//"+t.host);"string"==typeof e&&("/"===e.charAt(0)&&(e="/"===e.charAt(1)?t.protocol+e:t.host+e),/^(https?|wss?):\/\//.test(e)||(o("protocol-less url %s",e),e=void 0!==t?t.protocol+"//"+e:"https://"+e),o("parse %s",e),n=r(e));n.port||(/^(http|ws)$/.test(n.protocol)?n.port="80":/^(http|ws)s$/.test(n.protocol)&&(n.port="443"));n.path=n.path||"/";var i=-1!==n.host.indexOf(":")?"["+n.host+"]":n.host;return n.id=n.protocol+"://"+i+":"+n.port,n.href=n.protocol+"://"+i+(t&&t.port===n.port?"":":"+n.port),n}},function(e,t,n){e.exports=function(e){function t(e){let t=0;for(let n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n),t|=0;return r.colors[Math.abs(t)%r.colors.length]}function r(e){let n;function s(...e){if(!s.enabled)return;const t=s,o=Number(new Date),i=o-(n||o);t.diff=i,t.prev=n,t.curr=o,n=o,e[0]=r.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let a=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,((n,o)=>{if("%%"===n)return n;a++;const i=r.formatters[o];if("function"==typeof i){const r=e[a];n=i.call(t,r),e.splice(a,1),a--}return n})),r.formatArgs.call(t,e);(t.log||r.log).apply(t,e)}return s.namespace=e,s.enabled=r.enabled(e),s.useColors=r.useColors(),s.color=t(e),s.destroy=o,s.extend=i,"function"==typeof r.init&&r.init(s),r.instances.push(s),s}function o(){const e=r.instances.indexOf(this);return-1!==e&&(r.instances.splice(e,1),!0)}function i(e,t){const n=r(this.namespace+(void 0===t?":":t)+e);return n.log=this.log,n}function s(e){return e.toString().substring(2,e.toString().length-2).replace(/\.\*\?$/,"*")}return r.debug=r,r.default=r,r.coerce=function(e){if(e instanceof Error)return e.stack||e.message;return e},r.disable=function(){const e=[...r.names.map(s),...r.skips.map(s).map((e=>"-"+e))].join(",");return r.enable(""),e},r.enable=function(e){let t;r.save(e),r.names=[],r.skips=[];const n=("string"==typeof e?e:"").split(/[\s,]+/),o=n.length;for(t=0;t<o;t++)n[t]&&("-"===(e=n[t].replace(/\*/g,".*?"))[0]?r.skips.push(new RegExp("^"+e.substr(1)+"$")):r.names.push(new RegExp("^"+e+"$")));for(t=0;t<r.instances.length;t++){const e=r.instances[t];e.enabled=r.enabled(e.namespace)}},r.enabled=function(e){if("*"===e[e.length-1])return!0;let t,n;for(t=0,n=r.skips.length;t<n;t++)if(r.skips[t].test(e))return!1;for(t=0,n=r.names.length;t<n;t++)if(r.names[t].test(e))return!0;return!1},r.humanize=n(7),Object.keys(e).forEach((t=>{r[t]=e[t]})),r.instances=[],r.names=[],r.skips=[],r.formatters={},r.selectColor=t,r.enable(r.load()),r}},function(e,t,n){(function(r){function o(){var e;try{e=t.storage.debug}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}(t=e.exports=n(36)).log=function(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)},t.formatArgs=function(e){var n=this.useColors;if(e[0]=(n?"%c":"")+this.namespace+(n?" %c":" ")+e[0]+(n?"%c ":" ")+"+"+t.humanize(this.diff),!n)return;var r="color: "+this.color;e.splice(1,0,r,"color: inherit");var o=0,i=0;e[0].replace(/%[a-zA-Z%]/g,(function(e){"%%"!==e&&(o++,"%c"===e&&(i=o))})),e.splice(i,0,r)},t.save=function(e){try{null==e?t.storage.removeItem("debug"):t.storage.debug=e}catch(e){}},t.load=o,t.useColors=function(){if("undefined"!=typeof window&&window.process&&"renderer"===window.process.type)return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:function(){try{return window.localStorage}catch(e){}}(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.formatters.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}},t.enable(o())}).call(this,n(3))},function(e,t,n){function r(e){var n;function r(){if(r.enabled){var e=r,o=+new Date,i=o-(n||o);e.diff=i,e.prev=n,e.curr=o,n=o;for(var s=new Array(arguments.length),a=0;a<s.length;a++)s[a]=arguments[a];s[0]=t.coerce(s[0]),"string"!=typeof s[0]&&s.unshift("%O");var c=0;s[0]=s[0].replace(/%([a-zA-Z%])/g,(function(n,r){if("%%"===n)return n;c++;var o=t.formatters[r];if("function"==typeof o){var i=s[c];n=o.call(e,i),s.splice(c,1),c--}return n})),t.formatArgs.call(e,s);var u=r.log||t.log||console.log.bind(console);u.apply(e,s)}}return r.namespace=e,r.enabled=t.enabled(e),r.useColors=t.useColors(),r.color=function(e){var n,r=0;for(n in e)r=(r<<5)-r+e.charCodeAt(n),r|=0;return t.colors[Math.abs(r)%t.colors.length]}(e),r.destroy=o,"function"==typeof t.init&&t.init(r),t.instances.push(r),r}function o(){var e=t.instances.indexOf(this);return-1!==e&&(t.instances.splice(e,1),!0)}(t=e.exports=r.debug=r.default=r).coerce=function(e){return e instanceof Error?e.stack||e.message:e},t.disable=function(){t.enable("")},t.enable=function(e){var n;t.save(e),t.names=[],t.skips=[];var r=("string"==typeof e?e:"").split(/[\s,]+/),o=r.length;for(n=0;n<o;n++)r[n]&&("-"===(e=r[n].replace(/\*/g,".*?"))[0]?t.skips.push(new RegExp("^"+e.substr(1)+"$")):t.names.push(new RegExp("^"+e+"$")));for(n=0;n<t.instances.length;n++){var i=t.instances[n];i.enabled=t.enabled(i.namespace)}},t.enabled=function(e){if("*"===e[e.length-1])return!0;var n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1},t.humanize=n(37),t.instances=[],t.names=[],t.skips=[],t.formatters={}},function(e,t){var n=1e3,r=60*n,o=60*r,i=24*o,s=365.25*i;function a(e,t,n){if(!(e<t))return e<1.5*t?Math.floor(e/t)+" "+n:Math.ceil(e/t)+" "+n+"s"}e.exports=function(e,t){t=t||{};var c,u=typeof e;if("string"===u&&e.length>0)return function(e){if((e=String(e)).length>100)return;var t=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(e);if(!t)return;var a=parseFloat(t[1]);switch((t[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return a*s;case"days":case"day":case"d":return a*i;case"hours":case"hour":case"hrs":case"hr":case"h":return a*o;case"minutes":case"minute":case"mins":case"min":case"m":return a*r;case"seconds":case"second":case"secs":case"sec":case"s":return a*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return a;default:return}}(e);if("number"===u&&!1===isNaN(e))return t.long?a(c=e,i,"day")||a(c,o,"hour")||a(c,r,"minute")||a(c,n,"second")||c+" ms":function(e){if(e>=i)return Math.round(e/i)+"d";if(e>=o)return Math.round(e/o)+"h";if(e>=r)return Math.round(e/r)+"m";if(e>=n)return Math.round(e/n)+"s";return e+"ms"}(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},function(e,t,n){var r=n(18),o=n(19),i=Object.prototype.toString,s="function"==typeof Blob||"undefined"!=typeof Blob&&"[object BlobConstructor]"===i.call(Blob),a="function"==typeof File||"undefined"!=typeof File&&"[object FileConstructor]"===i.call(File);function c(e,t){if(!e)return e;if(o(e)){var n={_placeholder:!0,num:t.length};return t.push(e),n}if(r(e)){for(var i=new Array(e.length),s=0;s<e.length;s++)i[s]=c(e[s],t);return i}if("object"==typeof e&&!(e instanceof Date)){i={};for(var a in e)i[a]=c(e[a],t);return i}return e}function u(e,t){if(!e)return e;if(e&&e._placeholder)return t[e.num];if(r(e))for(var n=0;n<e.length;n++)e[n]=u(e[n],t);else if("object"==typeof e)for(var o in e)e[o]=u(e[o],t);return e}t.deconstructPacket=function(e){var t=[],n=e.data,r=e;return r.data=c(n,t),r.attachments=t.length,{packet:r,buffers:t}},t.reconstructPacket=function(e,t){return e.data=u(e.data,t),e.attachments=void 0,e},t.removeBlobs=function(e,t){var n=0,i=e;!function e(c,u,l){if(!c)return c;if(s&&c instanceof Blob||a&&c instanceof File){n++;var f=new FileReader;f.onload=function(){l?l[u]=this.result:i=this.result,--n||t(i)},f.readAsArrayBuffer(c)}else if(r(c))for(var h=0;h<c.length;h++)e(c[h],h,c);else if("object"==typeof c&&!o(c))for(var p in c)e(c[p],p,c)}(i),n||t(i)}},function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t,n){"use strict";t.byteLength=function(e){var t=u(e),n=t[0],r=t[1];return 3*(n+r)/4-r},t.toByteArray=function(e){var t,n,r=u(e),s=r[0],a=r[1],c=new i(function(e,t,n){return 3*(t+n)/4-n}(0,s,a)),l=0,f=a>0?s-4:s;for(n=0;n<f;n+=4)t=o[e.charCodeAt(n)]<<18|o[e.charCodeAt(n+1)]<<12|o[e.charCodeAt(n+2)]<<6|o[e.charCodeAt(n+3)],c[l++]=t>>16&255,c[l++]=t>>8&255,c[l++]=255&t;2===a&&(t=o[e.charCodeAt(n)]<<2|o[e.charCodeAt(n+1)]>>4,c[l++]=255&t);1===a&&(t=o[e.charCodeAt(n)]<<10|o[e.charCodeAt(n+1)]<<4|o[e.charCodeAt(n+2)]>>2,c[l++]=t>>8&255,c[l++]=255&t);return c},t.fromByteArray=function(e){for(var t,n=e.length,o=n%3,i=[],s=16383,a=0,c=n-o;a<c;a+=s)i.push(l(e,a,a+s>c?c:a+s));1===o?(t=e[n-1],i.push(r[t>>2]+r[t<<4&63]+"==")):2===o&&(t=(e[n-2]<<8)+e[n-1],i.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"="));return i.join("")};for(var r=[],o=[],i="undefined"!=typeof Uint8Array?Uint8Array:Array,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,c=s.length;a<c;++a)r[a]=s[a],o[s.charCodeAt(a)]=a;function u(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");return-1===n&&(n=t),[n,n===t?0:4-n%4]}function l(e,t,n){for(var o,i,s=[],a=t;a<n;a+=3)o=(e[a]<<16&16711680)+(e[a+1]<<8&65280)+(255&e[a+2]),s.push(r[(i=o)>>18&63]+r[i>>12&63]+r[i>>6&63]+r[63&i]);return s.join("")}o["-".charCodeAt(0)]=62,o["_".charCodeAt(0)]=63},function(e,t){t.read=function(e,t,n,r,o){var i,s,a=8*o-r-1,c=(1<<a)-1,u=c>>1,l=-7,f=n?o-1:0,h=n?-1:1,p=e[t+f];for(f+=h,i=p&(1<<-l)-1,p>>=-l,l+=a;l>0;i=256*i+e[t+f],f+=h,l-=8);for(s=i&(1<<-l)-1,i>>=-l,l+=r;l>0;s=256*s+e[t+f],f+=h,l-=8);if(0===i)i=1-u;else{if(i===c)return s?NaN:1/0*(p?-1:1);s+=Math.pow(2,r),i-=u}return(p?-1:1)*s*Math.pow(2,i-r)},t.write=function(e,t,n,r,o,i){var s,a,c,u=8*i-o-1,l=(1<<u)-1,f=l>>1,h=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,p=r?0:i-1,d=r?1:-1,g=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(a=isNaN(t)?1:0,s=l):(s=Math.floor(Math.log(t)/Math.LN2),t*(c=Math.pow(2,-s))<1&&(s--,c*=2),(t+=s+f>=1?h/c:h*Math.pow(2,1-f))*c>=2&&(s++,c/=2),s+f>=l?(a=0,s=l):s+f>=1?(a=(t*c-1)*Math.pow(2,o),s+=f):(a=t*Math.pow(2,f-1)*Math.pow(2,o),s=0));o>=8;e[n+p]=255&a,p+=d,a/=256,o-=8);for(s=s<<o|a,u+=o;u>0;e[n+p]=255&s,p+=d,s/=256,u-=8);e[n+p-d]|=128*g}},function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},function(e,t,n){e.exports=n(44),e.exports.parser=n(1)},function(e,t,n){var r=n(21),o=n(14),i=n(6)("engine.io-client:socket"),s=n(25),a=n(1),c=n(17),u=n(4);function l(e,t){if(!(this instanceof l))return new l(e,t);t=t||{},e&&"object"==typeof e&&(t=e,e=null),e?(e=c(e),t.hostname=e.host,t.secure="https"===e.protocol||"wss"===e.protocol,t.port=e.port,e.query&&(t.query=e.query)):t.host&&(t.hostname=c(t.host).host),this.secure=null!=t.secure?t.secure:"undefined"!=typeof location&&"https:"===location.protocol,t.hostname&&!t.port&&(t.port=this.secure?"443":"80"),this.agent=t.agent||!1,this.hostname=t.hostname||("undefined"!=typeof location?location.hostname:"localhost"),this.port=t.port||("undefined"!=typeof location&&location.port?location.port:this.secure?443:80),this.query=t.query||{},"string"==typeof this.query&&(this.query=u.decode(this.query)),this.upgrade=!1!==t.upgrade,this.path=(t.path||"/engine.io").replace(/\/$/,"")+"/",this.forceJSONP=!!t.forceJSONP,this.jsonp=!1!==t.jsonp,this.forceBase64=!!t.forceBase64,this.enablesXDR=!!t.enablesXDR,this.withCredentials=!1!==t.withCredentials,this.timestampParam=t.timestampParam||"t",this.timestampRequests=t.timestampRequests,this.transports=t.transports||["polling","websocket"],this.transportOptions=t.transportOptions||{},this.readyState="",this.writeBuffer=[],this.prevBufferLen=0,this.policyPort=t.policyPort||843,this.rememberUpgrade=t.rememberUpgrade||!1,this.binaryType=null,this.onlyBinaryUpgrades=t.onlyBinaryUpgrades,this.perMessageDeflate=!1!==t.perMessageDeflate&&(t.perMessageDeflate||{}),!0===this.perMessageDeflate&&(this.perMessageDeflate={}),this.perMessageDeflate&&null==this.perMessageDeflate.threshold&&(this.perMessageDeflate.threshold=1024),this.pfx=t.pfx||null,this.key=t.key||null,this.passphrase=t.passphrase||null,this.cert=t.cert||null,this.ca=t.ca||null,this.ciphers=t.ciphers||null,this.rejectUnauthorized=void 0===t.rejectUnauthorized||t.rejectUnauthorized,this.forceNode=!!t.forceNode,this.isReactNative="undefined"!=typeof navigator&&"string"==typeof navigator.product&&"reactnative"===navigator.product.toLowerCase(),("undefined"==typeof self||this.isReactNative)&&(t.extraHeaders&&Object.keys(t.extraHeaders).length>0&&(this.extraHeaders=t.extraHeaders),t.localAddress&&(this.localAddress=t.localAddress)),this.id=null,this.upgrades=null,this.pingInterval=null,this.pingTimeout=null,this.pingIntervalTimer=null,this.pingTimeoutTimer=null,this.open()}e.exports=l,l.priorWebsocketSuccess=!1,o(l.prototype),l.protocol=a.protocol,l.Socket=l,l.Transport=n(13),l.transports=n(21),l.parser=n(1),l.prototype.createTransport=function(e){i('creating transport "%s"',e);var t=function(e){var t={};for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return t}(this.query);t.EIO=a.protocol,t.transport=e;var n=this.transportOptions[e]||{};return this.id&&(t.sid=this.id),new r[e]({query:t,socket:this,agent:n.agent||this.agent,hostname:n.hostname||this.hostname,port:n.port||this.port,secure:n.secure||this.secure,path:n.path||this.path,forceJSONP:n.forceJSONP||this.forceJSONP,jsonp:n.jsonp||this.jsonp,forceBase64:n.forceBase64||this.forceBase64,enablesXDR:n.enablesXDR||this.enablesXDR,withCredentials:n.withCredentials||this.withCredentials,timestampRequests:n.timestampRequests||this.timestampRequests,timestampParam:n.timestampParam||this.timestampParam,policyPort:n.policyPort||this.policyPort,pfx:n.pfx||this.pfx,key:n.key||this.key,passphrase:n.passphrase||this.passphrase,cert:n.cert||this.cert,ca:n.ca||this.ca,ciphers:n.ciphers||this.ciphers,rejectUnauthorized:n.rejectUnauthorized||this.rejectUnauthorized,perMessageDeflate:n.perMessageDeflate||this.perMessageDeflate,extraHeaders:n.extraHeaders||this.extraHeaders,forceNode:n.forceNode||this.forceNode,localAddress:n.localAddress||this.localAddress,requestTimeout:n.requestTimeout||this.requestTimeout,protocols:n.protocols||void 0,isReactNative:this.isReactNative})},l.prototype.open=function(){var e;if(this.rememberUpgrade&&l.priorWebsocketSuccess&&-1!==this.transports.indexOf("websocket"))e="websocket";else{if(0===this.transports.length){var t=this;return void setTimeout((function(){t.emit("error","No transports available")}),0)}e=this.transports[0]}this.readyState="opening";try{e=this.createTransport(e)}catch(e){return this.transports.shift(),void this.open()}e.open(),this.setTransport(e)},l.prototype.setTransport=function(e){i("setting transport %s",e.name);var t=this;this.transport&&(i("clearing existing transport %s",this.transport.name),this.transport.removeAllListeners()),this.transport=e,e.on("drain",(function(){t.onDrain()})).on("packet",(function(e){t.onPacket(e)})).on("error",(function(e){t.onError(e)})).on("close",(function(){t.onClose("transport close")}))},l.prototype.probe=function(e){i('probing transport "%s"',e);var t=this.createTransport(e,{probe:1}),n=!1,r=this;function o(){if(r.onlyBinaryUpgrades){var o=!this.supportsBinary&&r.transport.supportsBinary;n=n||o}n||(i('probe transport "%s" opened',e),t.send([{type:"ping",data:"probe"}]),t.once("packet",(function(o){if(!n)if("pong"===o.type&&"probe"===o.data){if(i('probe transport "%s" pong',e),r.upgrading=!0,r.emit("upgrading",t),!t)return;l.priorWebsocketSuccess="websocket"===t.name,i('pausing current transport "%s"',r.transport.name),r.transport.pause((function(){n||"closed"!==r.readyState&&(i("changing transport and sending upgrade packet"),h(),r.setTransport(t),t.send([{type:"upgrade"}]),r.emit("upgrade",t),t=null,r.upgrading=!1,r.flush())}))}else{i('probe transport "%s" failed',e);var s=new Error("probe error");s.transport=t.name,r.emit("upgradeError",s)}})))}function s(){n||(n=!0,h(),t.close(),t=null)}function a(n){var o=new Error("probe error: "+n);o.transport=t.name,s(),i('probe transport "%s" failed because of error: %s',e,n),r.emit("upgradeError",o)}function c(){a("transport closed")}function u(){a("socket closed")}function f(e){t&&e.name!==t.name&&(i('"%s" works - aborting "%s"',e.name,t.name),s())}function h(){t.removeListener("open",o),t.removeListener("error",a),t.removeListener("close",c),r.removeListener("close",u),r.removeListener("upgrading",f)}l.priorWebsocketSuccess=!1,t.once("open",o),t.once("error",a),t.once("close",c),this.once("close",u),this.once("upgrading",f),t.open()},l.prototype.onOpen=function(){if(i("socket open"),this.readyState="open",l.priorWebsocketSuccess="websocket"===this.transport.name,this.emit("open"),this.flush(),"open"===this.readyState&&this.upgrade&&this.transport.pause){i("starting upgrade probes");for(var e=0,t=this.upgrades.length;e<t;e++)this.probe(this.upgrades[e])}},l.prototype.onPacket=function(e){if("opening"===this.readyState||"open"===this.readyState||"closing"===this.readyState)switch(i('socket receive: type "%s", data "%s"',e.type,e.data),this.emit("packet",e),this.emit("heartbeat"),e.type){case"open":this.onHandshake(JSON.parse(e.data));break;case"pong":this.setPing(),this.emit("pong");break;case"error":var t=new Error("server error");t.code=e.data,this.onError(t);break;case"message":this.emit("data",e.data),this.emit("message",e.data)}else i('packet received with socket readyState "%s"',this.readyState)},l.prototype.onHandshake=function(e){this.emit("handshake",e),this.id=e.sid,this.transport.query.sid=e.sid,this.upgrades=this.filterUpgrades(e.upgrades),this.pingInterval=e.pingInterval,this.pingTimeout=e.pingTimeout,this.onOpen(),"closed"!==this.readyState&&(this.setPing(),this.removeListener("heartbeat",this.onHeartbeat),this.on("heartbeat",this.onHeartbeat))},l.prototype.onHeartbeat=function(e){clearTimeout(this.pingTimeoutTimer);var t=this;t.pingTimeoutTimer=setTimeout((function(){"closed"!==t.readyState&&t.onClose("ping timeout")}),e||t.pingInterval+t.pingTimeout)},l.prototype.setPing=function(){var e=this;clearTimeout(e.pingIntervalTimer),e.pingIntervalTimer=setTimeout((function(){i("writing ping packet - expecting pong within %sms",e.pingTimeout),e.ping(),e.onHeartbeat(e.pingTimeout)}),e.pingInterval)},l.prototype.ping=function(){var e=this;this.sendPacket("ping",(function(){e.emit("ping")}))},l.prototype.onDrain=function(){this.writeBuffer.splice(0,this.prevBufferLen),this.prevBufferLen=0,0===this.writeBuffer.length?this.emit("drain"):this.flush()},l.prototype.flush=function(){"closed"!==this.readyState&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length&&(i("flushing %d packets in socket",this.writeBuffer.length),this.transport.send(this.writeBuffer),this.prevBufferLen=this.writeBuffer.length,this.emit("flush"))},l.prototype.write=l.prototype.send=function(e,t,n){return this.sendPacket("message",e,t,n),this},l.prototype.sendPacket=function(e,t,n,r){if("function"==typeof t&&(r=t,t=void 0),"function"==typeof n&&(r=n,n=null),"closing"!==this.readyState&&"closed"!==this.readyState){(n=n||{}).compress=!1!==n.compress;var o={type:e,data:t,options:n};this.emit("packetCreate",o),this.writeBuffer.push(o),r&&this.once("flush",r),this.flush()}},l.prototype.close=function(){if("opening"===this.readyState||"open"===this.readyState){this.readyState="closing";var e=this;this.writeBuffer.length?this.once("drain",(function(){this.upgrading?r():t()})):this.upgrading?r():t()}function t(){e.onClose("forced close"),i("socket closing - telling transport to close"),e.transport.close()}function n(){e.removeListener("upgrade",n),e.removeListener("upgradeError",n),t()}function r(){e.once("upgrade",n),e.once("upgradeError",n)}return this},l.prototype.onError=function(e){i("socket error %j",e),l.priorWebsocketSuccess=!1,this.emit("error",e),this.onClose("transport error",e)},l.prototype.onClose=function(e,t){if("opening"===this.readyState||"open"===this.readyState||"closing"===this.readyState){i('socket close with reason: "%s"',e);clearTimeout(this.pingIntervalTimer),clearTimeout(this.pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),this.readyState="closed",this.id=null,this.emit("close",e,t),this.writeBuffer=[],this.prevBufferLen=0}},l.prototype.filterUpgrades=function(e){for(var t=[],n=0,r=e.length;n<r;n++)~s(this.transports,e[n])&&t.push(e[n]);return t}},function(e,t){try{e.exports="undefined"!=typeof XMLHttpRequest&&"withCredentials"in new XMLHttpRequest}catch(t){e.exports=!1}},function(e,t,n){var r=n(11),o=n(22),i=n(14),s=n(5),a=n(6)("engine.io-client:polling-xhr"),c=n(12);function u(){}function l(e){if(o.call(this,e),this.requestTimeout=e.requestTimeout,this.extraHeaders=e.extraHeaders,"undefined"!=typeof location){var t="https:"===location.protocol,n=location.port;n||(n=t?443:80),this.xd="undefined"!=typeof location&&e.hostname!==location.hostname||n!==e.port,this.xs=e.secure!==t}}function f(e){this.method=e.method||"GET",this.uri=e.uri,this.xd=!!e.xd,this.xs=!!e.xs,this.async=!1!==e.async,this.data=void 0!==e.data?e.data:null,this.agent=e.agent,this.isBinary=e.isBinary,this.supportsBinary=e.supportsBinary,this.enablesXDR=e.enablesXDR,this.withCredentials=e.withCredentials,this.requestTimeout=e.requestTimeout,this.pfx=e.pfx,this.key=e.key,this.passphrase=e.passphrase,this.cert=e.cert,this.ca=e.ca,this.ciphers=e.ciphers,this.rejectUnauthorized=e.rejectUnauthorized,this.extraHeaders=e.extraHeaders,this.create()}if(e.exports=l,e.exports.Request=f,s(l,o),l.prototype.supportsBinary=!0,l.prototype.request=function(e){return(e=e||{}).uri=this.uri(),e.xd=this.xd,e.xs=this.xs,e.agent=this.agent||!1,e.supportsBinary=this.supportsBinary,e.enablesXDR=this.enablesXDR,e.withCredentials=this.withCredentials,e.pfx=this.pfx,e.key=this.key,e.passphrase=this.passphrase,e.cert=this.cert,e.ca=this.ca,e.ciphers=this.ciphers,e.rejectUnauthorized=this.rejectUnauthorized,e.requestTimeout=this.requestTimeout,e.extraHeaders=this.extraHeaders,new f(e)},l.prototype.doWrite=function(e,t){var n="string"!=typeof e&&void 0!==e,r=this.request({method:"POST",data:e,isBinary:n}),o=this;r.on("success",t),r.on("error",(function(e){o.onError("xhr post error",e)})),this.sendXhr=r},l.prototype.doPoll=function(){a("xhr poll");var e=this.request(),t=this;e.on("data",(function(e){t.onData(e)})),e.on("error",(function(e){t.onError("xhr poll error",e)})),this.pollXhr=e},i(f.prototype),f.prototype.create=function(){var e={agent:this.agent,xdomain:this.xd,xscheme:this.xs,enablesXDR:this.enablesXDR};e.pfx=this.pfx,e.key=this.key,e.passphrase=this.passphrase,e.cert=this.cert,e.ca=this.ca,e.ciphers=this.ciphers,e.rejectUnauthorized=this.rejectUnauthorized;var t=this.xhr=new r(e),n=this;try{a("xhr open %s: %s",this.method,this.uri),t.open(this.method,this.uri,this.async);try{if(this.extraHeaders)for(var o in t.setDisableHeaderCheck&&t.setDisableHeaderCheck(!0),this.extraHeaders)this.extraHeaders.hasOwnProperty(o)&&t.setRequestHeader(o,this.extraHeaders[o])}catch(e){}if("POST"===this.method)try{this.isBinary?t.setRequestHeader("Content-type","application/octet-stream"):t.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch(e){}try{t.setRequestHeader("Accept","*/*")}catch(e){}"withCredentials"in t&&(t.withCredentials=this.withCredentials),this.requestTimeout&&(t.timeout=this.requestTimeout),this.hasXDR()?(t.onload=function(){n.onLoad()},t.onerror=function(){n.onError(t.responseText)}):t.onreadystatechange=function(){if(2===t.readyState)try{var e=t.getResponseHeader("Content-Type");(n.supportsBinary&&"application/octet-stream"===e||"application/octet-stream; charset=UTF-8"===e)&&(t.responseType="arraybuffer")}catch(e){}4===t.readyState&&(200===t.status||1223===t.status?n.onLoad():setTimeout((function(){n.onError("number"==typeof t.status?t.status:0)}),0))},a("xhr data %s",this.data),t.send(this.data)}catch(e){return void setTimeout((function(){n.onError(e)}),0)}"undefined"!=typeof document&&(this.index=f.requestsCount++,f.requests[this.index]=this)},f.prototype.onSuccess=function(){this.emit("success"),this.cleanup()},f.prototype.onData=function(e){this.emit("data",e),this.onSuccess()},f.prototype.onError=function(e){this.emit("error",e),this.cleanup(!0)},f.prototype.cleanup=function(e){if(void 0!==this.xhr&&null!==this.xhr){if(this.hasXDR()?this.xhr.onload=this.xhr.onerror=u:this.xhr.onreadystatechange=u,e)try{this.xhr.abort()}catch(e){}"undefined"!=typeof document&&delete f.requests[this.index],this.xhr=null}},f.prototype.onLoad=function(){var e;try{var t;try{t=this.xhr.getResponseHeader("Content-Type")}catch(e){}e=("application/octet-stream"===t||"application/octet-stream; charset=UTF-8"===t)&&this.xhr.response||this.xhr.responseText}catch(e){this.onError(e)}null!=e&&this.onData(e)},f.prototype.hasXDR=function(){return"undefined"!=typeof XDomainRequest&&!this.xs&&this.enablesXDR},f.prototype.abort=function(){this.cleanup()},f.requestsCount=0,f.requests={},"undefined"!=typeof document)if("function"==typeof attachEvent)attachEvent("onunload",h);else if("function"==typeof addEventListener){addEventListener("onpagehide"in c?"pagehide":"unload",h,!1)}function h(){for(var e in f.requests)f.requests.hasOwnProperty(e)&&f.requests[e].abort()}},function(e,t){e.exports=Object.keys||function(e){var t=[],n=Object.prototype.hasOwnProperty;for(var r in e)n.call(e,r)&&t.push(r);return t}},function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},function(e,t){e.exports=function(e,t,n){var r=e.byteLength;if(t=t||0,n=n||r,e.slice)return e.slice(t,n);if(t<0&&(t+=r),n<0&&(n+=r),n>r&&(n=r),t>=r||t>=n||0===r)return new ArrayBuffer(0);for(var o=new Uint8Array(e),i=new Uint8Array(n-t),s=t,a=0;s<n;s++,a++)i[a]=o[s];return i.buffer}},function(e,t){function n(){}e.exports=function(e,t,r){var o=!1;return r=r||n,i.count=e,0===e?t():i;function i(e,n){if(i.count<=0)throw new Error("after called too many times");--i.count,e?(o=!0,t(e),t=r):0!==i.count||o||t(null,n)}}},function(e,t){
+var r=n(38),o=n(39),i=n(40);function s(){return c.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function a(e,t){if(s()<t)throw new RangeError("Invalid typed array length");return c.TYPED_ARRAY_SUPPORT?(e=new Uint8Array(t)).__proto__=c.prototype:(null===e&&(e=new c(t)),e.length=t),e}function c(e,t,n){if(!(c.TYPED_ARRAY_SUPPORT||this instanceof c))return new c(e,t,n);if("number"==typeof e){if("string"==typeof t)throw new Error("If encoding is specified then the first argument must be a string");return f(this,e)}return u(this,e,t,n)}function u(e,t,n,r){if("number"==typeof t)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&t instanceof ArrayBuffer?function(e,t,n,r){if(t.byteLength,n<0||t.byteLength<n)throw new RangeError("'offset' is out of bounds");if(t.byteLength<n+(r||0))throw new RangeError("'length' is out of bounds");t=void 0===n&&void 0===r?new Uint8Array(t):void 0===r?new Uint8Array(t,n):new Uint8Array(t,n,r);c.TYPED_ARRAY_SUPPORT?(e=t).__proto__=c.prototype:e=h(e,t);return e}(e,t,n,r):"string"==typeof t?function(e,t,n){"string"==typeof n&&""!==n||(n="utf8");if(!c.isEncoding(n))throw new TypeError('"encoding" must be a valid string encoding');var r=0|d(t,n),o=(e=a(e,r)).write(t,n);o!==r&&(e=e.slice(0,o));return e}(e,t,n):function(e,t){if(c.isBuffer(t)){var n=0|p(t.length);return 0===(e=a(e,n)).length||t.copy(e,0,0,n),e}if(t){if("undefined"!=typeof ArrayBuffer&&t.buffer instanceof ArrayBuffer||"length"in t)return"number"!=typeof t.length||(r=t.length)!=r?a(e,0):h(e,t);if("Buffer"===t.type&&i(t.data))return h(e,t.data)}var r;throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(e,t)}function l(e){if("number"!=typeof e)throw new TypeError('"size" argument must be a number');if(e<0)throw new RangeError('"size" argument must not be negative')}function f(e,t){if(l(t),e=a(e,t<0?0:0|p(t)),!c.TYPED_ARRAY_SUPPORT)for(var n=0;n<t;++n)e[n]=0;return e}function h(e,t){var n=t.length<0?0:0|p(t.length);e=a(e,n);for(var r=0;r<n;r+=1)e[r]=255&t[r];return e}function p(e){if(e>=s())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s().toString(16)+" bytes");return 0|e}function d(e,t){if(c.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var n=e.length;if(0===n)return 0;for(var r=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":case void 0:return N(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return Q(e).length;default:if(r)return N(e).length;t=(""+t).toLowerCase(),r=!0}}function g(e,t,n){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if((n>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return F(this,t,n);case"utf8":case"utf-8":return x(this,t,n);case"ascii":return S(this,t,n);case"latin1":case"binary":return I(this,t,n);case"base64":return B(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return P(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function y(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function v(e,t,n,r,o){if(0===e.length)return-1;if("string"==typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,isNaN(n)&&(n=o?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(o)return-1;n=e.length-1}else if(n<0){if(!o)return-1;n=0}if("string"==typeof t&&(t=c.from(t,r)),c.isBuffer(t))return 0===t.length?-1:m(e,t,n,r,o);if("number"==typeof t)return t&=255,c.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):m(e,[t],n,r,o);throw new TypeError("val must be string, number or Buffer")}function m(e,t,n,r,o){var i,s=1,a=e.length,c=t.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;s=2,a/=2,c/=2,n/=2}function u(e,t){return 1===s?e[t]:e.readUInt16BE(t*s)}if(o){var l=-1;for(i=n;i<a;i++)if(u(e,i)===u(t,-1===l?0:i-l)){if(-1===l&&(l=i),i-l+1===c)return l*s}else-1!==l&&(i-=i-l),l=-1}else for(n+c>a&&(n=a-c),i=n;i>=0;i--){for(var f=!0,h=0;h<c;h++)if(u(e,i+h)!==u(t,h)){f=!1;break}if(f)return i}return-1}function b(e,t,n,r){n=Number(n)||0;var o=e.length-n;r?(r=Number(r))>o&&(r=o):r=o;var i=t.length;if(i%2!=0)throw new TypeError("Invalid hex string");r>i/2&&(r=i/2);for(var s=0;s<r;++s){var a=parseInt(t.substr(2*s,2),16);if(isNaN(a))return s;e[n+s]=a}return s}function w(e,t,n,r){return z(N(t,e.length-n),e,n,r)}function A(e,t,n,r){return z(function(e){for(var t=[],n=0;n<e.length;++n)t.push(255&e.charCodeAt(n));return t}(t),e,n,r)}function C(e,t,n,r){return A(e,t,n,r)}function k(e,t,n,r){return z(Q(t),e,n,r)}function E(e,t,n,r){return z(function(e,t){for(var n,r,o,i=[],s=0;s<e.length&&!((t-=2)<0);++s)n=e.charCodeAt(s),r=n>>8,o=n%256,i.push(o),i.push(r);return i}(t,e.length-n),e,n,r)}function B(e,t,n){return 0===t&&n===e.length?r.fromByteArray(e):r.fromByteArray(e.slice(t,n))}function x(e,t,n){n=Math.min(e.length,n);for(var r=[],o=t;o<n;){var i,s,a,c,u=e[o],l=null,f=u>239?4:u>223?3:u>191?2:1;if(o+f<=n)switch(f){case 1:u<128&&(l=u);break;case 2:128==(192&(i=e[o+1]))&&(c=(31&u)<<6|63&i)>127&&(l=c);break;case 3:i=e[o+1],s=e[o+2],128==(192&i)&&128==(192&s)&&(c=(15&u)<<12|(63&i)<<6|63&s)>2047&&(c<55296||c>57343)&&(l=c);break;case 4:i=e[o+1],s=e[o+2],a=e[o+3],128==(192&i)&&128==(192&s)&&128==(192&a)&&(c=(15&u)<<18|(63&i)<<12|(63&s)<<6|63&a)>65535&&c<1114112&&(l=c)}null===l?(l=65533,f=1):l>65535&&(l-=65536,r.push(l>>>10&1023|55296),l=56320|1023&l),r.push(l),o+=f}return function(e){var t=e.length;if(t<=4096)return String.fromCharCode.apply(String,e);var n="",r=0;for(;r<t;)n+=String.fromCharCode.apply(String,e.slice(r,r+=4096));return n}(r)}t.Buffer=c,t.SlowBuffer=function(e){+e!=e&&(e=0);return c.alloc(+e)},t.INSPECT_MAX_BYTES=50,c.TYPED_ARRAY_SUPPORT=void 0!==e.TYPED_ARRAY_SUPPORT?e.TYPED_ARRAY_SUPPORT:function(){try{var e=new Uint8Array(1);return e.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===e.foo()&&"function"==typeof e.subarray&&0===e.subarray(1,1).byteLength}catch(e){return!1}}(),t.kMaxLength=s(),c.poolSize=8192,c._augment=function(e){return e.__proto__=c.prototype,e},c.from=function(e,t,n){return u(null,e,t,n)},c.TYPED_ARRAY_SUPPORT&&(c.prototype.__proto__=Uint8Array.prototype,c.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&c[Symbol.species]===c&&Object.defineProperty(c,Symbol.species,{value:null,configurable:!0})),c.alloc=function(e,t,n){return function(e,t,n,r){return l(t),t<=0?a(e,t):void 0!==n?"string"==typeof r?a(e,t).fill(n,r):a(e,t).fill(n):a(e,t)}(null,e,t,n)},c.allocUnsafe=function(e){return f(null,e)},c.allocUnsafeSlow=function(e){return f(null,e)},c.isBuffer=function(e){return!(null==e||!e._isBuffer)},c.compare=function(e,t){if(!c.isBuffer(e)||!c.isBuffer(t))throw new TypeError("Arguments must be Buffers");if(e===t)return 0;for(var n=e.length,r=t.length,o=0,i=Math.min(n,r);o<i;++o)if(e[o]!==t[o]){n=e[o],r=t[o];break}return n<r?-1:r<n?1:0},c.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},c.concat=function(e,t){if(!i(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return c.alloc(0);var n;if(void 0===t)for(t=0,n=0;n<e.length;++n)t+=e[n].length;var r=c.allocUnsafe(t),o=0;for(n=0;n<e.length;++n){var s=e[n];if(!c.isBuffer(s))throw new TypeError('"list" argument must be an Array of Buffers');s.copy(r,o),o+=s.length}return r},c.byteLength=d,c.prototype._isBuffer=!0,c.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)y(this,t,t+1);return this},c.prototype.swap32=function(){var e=this.length;if(e%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)y(this,t,t+3),y(this,t+1,t+2);return this},c.prototype.swap64=function(){var e=this.length;if(e%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)y(this,t,t+7),y(this,t+1,t+6),y(this,t+2,t+5),y(this,t+3,t+4);return this},c.prototype.toString=function(){var e=0|this.length;return 0===e?"":0===arguments.length?x(this,0,e):g.apply(this,arguments)},c.prototype.equals=function(e){if(!c.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===c.compare(this,e)},c.prototype.inspect=function(){var e="",n=t.INSPECT_MAX_BYTES;return this.length>0&&(e=this.toString("hex",0,n).match(/.{2}/g).join(" "),this.length>n&&(e+=" ... ")),"<Buffer "+e+">"},c.prototype.compare=function(e,t,n,r,o){if(!c.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===r&&(r=0),void 0===o&&(o=this.length),t<0||n>e.length||r<0||o>this.length)throw new RangeError("out of range index");if(r>=o&&t>=n)return 0;if(r>=o)return-1;if(t>=n)return 1;if(this===e)return 0;for(var i=(o>>>=0)-(r>>>=0),s=(n>>>=0)-(t>>>=0),a=Math.min(i,s),u=this.slice(r,o),l=e.slice(t,n),f=0;f<a;++f)if(u[f]!==l[f]){i=u[f],s=l[f];break}return i<s?-1:s<i?1:0},c.prototype.includes=function(e,t,n){return-1!==this.indexOf(e,t,n)},c.prototype.indexOf=function(e,t,n){return v(this,e,t,n,!0)},c.prototype.lastIndexOf=function(e,t,n){return v(this,e,t,n,!1)},c.prototype.write=function(e,t,n,r){if(void 0===t)r="utf8",n=this.length,t=0;else if(void 0===n&&"string"==typeof t)r=t,n=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t|=0,isFinite(n)?(n|=0,void 0===r&&(r="utf8")):(r=n,n=void 0)}var o=this.length-t;if((void 0===n||n>o)&&(n=o),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var i=!1;;)switch(r){case"hex":return b(this,e,t,n);case"utf8":case"utf-8":return w(this,e,t,n);case"ascii":return A(this,e,t,n);case"latin1":case"binary":return C(this,e,t,n);case"base64":return k(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return E(this,e,t,n);default:if(i)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),i=!0}},c.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function S(e,t,n){var r="";n=Math.min(e.length,n);for(var o=t;o<n;++o)r+=String.fromCharCode(127&e[o]);return r}function I(e,t,n){var r="";n=Math.min(e.length,n);for(var o=t;o<n;++o)r+=String.fromCharCode(e[o]);return r}function F(e,t,n){var r=e.length;(!t||t<0)&&(t=0),(!n||n<0||n>r)&&(n=r);for(var o="",i=t;i<n;++i)o+=U(e[i]);return o}function P(e,t,n){for(var r=e.slice(t,n),o="",i=0;i<r.length;i+=2)o+=String.fromCharCode(r[i]+256*r[i+1]);return o}function R(e,t,n){if(e%1!=0||e<0)throw new RangeError("offset is not uint");if(e+t>n)throw new RangeError("Trying to access beyond buffer length")}function D(e,t,n,r,o,i){if(!c.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>o||t<i)throw new RangeError('"value" argument is out of bounds');if(n+r>e.length)throw new RangeError("Index out of range")}function M(e,t,n,r){t<0&&(t=65535+t+1);for(var o=0,i=Math.min(e.length-n,2);o<i;++o)e[n+o]=(t&255<<8*(r?o:1-o))>>>8*(r?o:1-o)}function O(e,t,n,r){t<0&&(t=4294967295+t+1);for(var o=0,i=Math.min(e.length-n,4);o<i;++o)e[n+o]=t>>>8*(r?o:3-o)&255}function _(e,t,n,r,o,i){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function T(e,t,n,r,i){return i||_(e,0,n,4),o.write(e,t,n,r,23,4),n+4}function j(e,t,n,r,i){return i||_(e,0,n,8),o.write(e,t,n,r,52,8),n+8}c.prototype.slice=function(e,t){var n,r=this.length;if((e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t<e&&(t=e),c.TYPED_ARRAY_SUPPORT)(n=this.subarray(e,t)).__proto__=c.prototype;else{var o=t-e;n=new c(o,void 0);for(var i=0;i<o;++i)n[i]=this[i+e]}return n},c.prototype.readUIntLE=function(e,t,n){e|=0,t|=0,n||R(e,t,this.length);for(var r=this[e],o=1,i=0;++i<t&&(o*=256);)r+=this[e+i]*o;return r},c.prototype.readUIntBE=function(e,t,n){e|=0,t|=0,n||R(e,t,this.length);for(var r=this[e+--t],o=1;t>0&&(o*=256);)r+=this[e+--t]*o;return r},c.prototype.readUInt8=function(e,t){return t||R(e,1,this.length),this[e]},c.prototype.readUInt16LE=function(e,t){return t||R(e,2,this.length),this[e]|this[e+1]<<8},c.prototype.readUInt16BE=function(e,t){return t||R(e,2,this.length),this[e]<<8|this[e+1]},c.prototype.readUInt32LE=function(e,t){return t||R(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},c.prototype.readUInt32BE=function(e,t){return t||R(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},c.prototype.readIntLE=function(e,t,n){e|=0,t|=0,n||R(e,t,this.length);for(var r=this[e],o=1,i=0;++i<t&&(o*=256);)r+=this[e+i]*o;return r>=(o*=128)&&(r-=Math.pow(2,8*t)),r},c.prototype.readIntBE=function(e,t,n){e|=0,t|=0,n||R(e,t,this.length);for(var r=t,o=1,i=this[e+--r];r>0&&(o*=256);)i+=this[e+--r]*o;return i>=(o*=128)&&(i-=Math.pow(2,8*t)),i},c.prototype.readInt8=function(e,t){return t||R(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},c.prototype.readInt16LE=function(e,t){t||R(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},c.prototype.readInt16BE=function(e,t){t||R(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},c.prototype.readInt32LE=function(e,t){return t||R(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},c.prototype.readInt32BE=function(e,t){return t||R(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},c.prototype.readFloatLE=function(e,t){return t||R(e,4,this.length),o.read(this,e,!0,23,4)},c.prototype.readFloatBE=function(e,t){return t||R(e,4,this.length),o.read(this,e,!1,23,4)},c.prototype.readDoubleLE=function(e,t){return t||R(e,8,this.length),o.read(this,e,!0,52,8)},c.prototype.readDoubleBE=function(e,t){return t||R(e,8,this.length),o.read(this,e,!1,52,8)},c.prototype.writeUIntLE=function(e,t,n,r){(e=+e,t|=0,n|=0,r)||D(this,e,t,n,Math.pow(2,8*n)-1,0);var o=1,i=0;for(this[t]=255&e;++i<n&&(o*=256);)this[t+i]=e/o&255;return t+n},c.prototype.writeUIntBE=function(e,t,n,r){(e=+e,t|=0,n|=0,r)||D(this,e,t,n,Math.pow(2,8*n)-1,0);var o=n-1,i=1;for(this[t+o]=255&e;--o>=0&&(i*=256);)this[t+o]=e/i&255;return t+n},c.prototype.writeUInt8=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,1,255,0),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},c.prototype.writeUInt16LE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):M(this,e,t,!0),t+2},c.prototype.writeUInt16BE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):M(this,e,t,!1),t+2},c.prototype.writeUInt32LE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):O(this,e,t,!0),t+4},c.prototype.writeUInt32BE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):O(this,e,t,!1),t+4},c.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t|=0,!r){var o=Math.pow(2,8*n-1);D(this,e,t,n,o-1,-o)}var i=0,s=1,a=0;for(this[t]=255&e;++i<n&&(s*=256);)e<0&&0===a&&0!==this[t+i-1]&&(a=1),this[t+i]=(e/s>>0)-a&255;return t+n},c.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t|=0,!r){var o=Math.pow(2,8*n-1);D(this,e,t,n,o-1,-o)}var i=n-1,s=1,a=0;for(this[t+i]=255&e;--i>=0&&(s*=256);)e<0&&0===a&&0!==this[t+i+1]&&(a=1),this[t+i]=(e/s>>0)-a&255;return t+n},c.prototype.writeInt8=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,1,127,-128),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},c.prototype.writeInt16LE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):M(this,e,t,!0),t+2},c.prototype.writeInt16BE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):M(this,e,t,!1),t+2},c.prototype.writeInt32LE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,4,2147483647,-2147483648),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):O(this,e,t,!0),t+4},c.prototype.writeInt32BE=function(e,t,n){return e=+e,t|=0,n||D(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):O(this,e,t,!1),t+4},c.prototype.writeFloatLE=function(e,t,n){return T(this,e,t,!0,n)},c.prototype.writeFloatBE=function(e,t,n){return T(this,e,t,!1,n)},c.prototype.writeDoubleLE=function(e,t,n){return j(this,e,t,!0,n)},c.prototype.writeDoubleBE=function(e,t,n){return j(this,e,t,!1,n)},c.prototype.copy=function(e,t,n,r){if(n||(n=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r<n&&(r=n),r===n)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(n<0||n>=this.length)throw new RangeError("sourceStart out of bounds");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t<r-n&&(r=e.length-t+n);var o,i=r-n;if(this===e&&n<t&&t<r)for(o=i-1;o>=0;--o)e[o+t]=this[o+n];else if(i<1e3||!c.TYPED_ARRAY_SUPPORT)for(o=0;o<i;++o)e[o+t]=this[o+n];else Uint8Array.prototype.set.call(e,this.subarray(n,n+i),t);return i},c.prototype.fill=function(e,t,n,r){if("string"==typeof e){if("string"==typeof t?(r=t,t=0,n=this.length):"string"==typeof n&&(r=n,n=this.length),1===e.length){var o=e.charCodeAt(0);o<256&&(e=o)}if(void 0!==r&&"string"!=typeof r)throw new TypeError("encoding must be a string");if("string"==typeof r&&!c.isEncoding(r))throw new TypeError("Unknown encoding: "+r)}else"number"==typeof e&&(e&=255);if(t<0||this.length<t||this.length<n)throw new RangeError("Out of range index");if(n<=t)return this;var i;if(t>>>=0,n=void 0===n?this.length:n>>>0,e||(e=0),"number"==typeof e)for(i=t;i<n;++i)this[i]=e;else{var s=c.isBuffer(e)?e:N(new c(e,r).toString()),a=s.length;for(i=0;i<n-t;++i)this[i+t]=s[i%a]}return this};var L=/[^+\/0-9A-Za-z-_]/g;function U(e){return e<16?"0"+e.toString(16):e.toString(16)}function N(e,t){var n;t=t||1/0;for(var r=e.length,o=null,i=[],s=0;s<r;++s){if((n=e.charCodeAt(s))>55295&&n<57344){if(!o){if(n>56319){(t-=3)>-1&&i.push(239,191,189);continue}if(s+1===r){(t-=3)>-1&&i.push(239,191,189);continue}o=n;continue}if(n<56320){(t-=3)>-1&&i.push(239,191,189),o=n;continue}n=65536+(o-55296<<10|n-56320)}else o&&(t-=3)>-1&&i.push(239,191,189);if(o=null,n<128){if((t-=1)<0)break;i.push(n)}else if(n<2048){if((t-=2)<0)break;i.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;i.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;i.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return i}function Q(e){return r.toByteArray(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(L,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function z(e,t,n,r){for(var o=0;o<r&&!(o+n>=t.length||o>=e.length);++o)t[o+n]=e[o];return o}}).call(this,n(0))},function(e,t,n){"use strict";t.byteLength=function(e){var t=u(e),n=t[0],r=t[1];return 3*(n+r)/4-r},t.toByteArray=function(e){var t,n,r=u(e),s=r[0],a=r[1],c=new i(function(e,t,n){return 3*(t+n)/4-n}(0,s,a)),l=0,f=a>0?s-4:s;for(n=0;n<f;n+=4)t=o[e.charCodeAt(n)]<<18|o[e.charCodeAt(n+1)]<<12|o[e.charCodeAt(n+2)]<<6|o[e.charCodeAt(n+3)],c[l++]=t>>16&255,c[l++]=t>>8&255,c[l++]=255&t;2===a&&(t=o[e.charCodeAt(n)]<<2|o[e.charCodeAt(n+1)]>>4,c[l++]=255&t);1===a&&(t=o[e.charCodeAt(n)]<<10|o[e.charCodeAt(n+1)]<<4|o[e.charCodeAt(n+2)]>>2,c[l++]=t>>8&255,c[l++]=255&t);return c},t.fromByteArray=function(e){for(var t,n=e.length,o=n%3,i=[],s=0,a=n-o;s<a;s+=16383)i.push(l(e,s,s+16383>a?a:s+16383));1===o?(t=e[n-1],i.push(r[t>>2]+r[t<<4&63]+"==")):2===o&&(t=(e[n-2]<<8)+e[n-1],i.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"="));return i.join("")};for(var r=[],o=[],i="undefined"!=typeof Uint8Array?Uint8Array:Array,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,c=s.length;a<c;++a)r[a]=s[a],o[s.charCodeAt(a)]=a;function u(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");return-1===n&&(n=t),[n,n===t?0:4-n%4]}function l(e,t,n){for(var o,i,s=[],a=t;a<n;a+=3)o=(e[a]<<16&16711680)+(e[a+1]<<8&65280)+(255&e[a+2]),s.push(r[(i=o)>>18&63]+r[i>>12&63]+r[i>>6&63]+r[63&i]);return s.join("")}o["-".charCodeAt(0)]=62,o["_".charCodeAt(0)]=63},function(e,t){
+/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */
+t.read=function(e,t,n,r,o){var i,s,a=8*o-r-1,c=(1<<a)-1,u=c>>1,l=-7,f=n?o-1:0,h=n?-1:1,p=e[t+f];for(f+=h,i=p&(1<<-l)-1,p>>=-l,l+=a;l>0;i=256*i+e[t+f],f+=h,l-=8);for(s=i&(1<<-l)-1,i>>=-l,l+=r;l>0;s=256*s+e[t+f],f+=h,l-=8);if(0===i)i=1-u;else{if(i===c)return s?NaN:1/0*(p?-1:1);s+=Math.pow(2,r),i-=u}return(p?-1:1)*s*Math.pow(2,i-r)},t.write=function(e,t,n,r,o,i){var s,a,c,u=8*i-o-1,l=(1<<u)-1,f=l>>1,h=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,p=r?0:i-1,d=r?1:-1,g=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(a=isNaN(t)?1:0,s=l):(s=Math.floor(Math.log(t)/Math.LN2),t*(c=Math.pow(2,-s))<1&&(s--,c*=2),(t+=s+f>=1?h/c:h*Math.pow(2,1-f))*c>=2&&(s++,c/=2),s+f>=l?(a=0,s=l):s+f>=1?(a=(t*c-1)*Math.pow(2,o),s+=f):(a=t*Math.pow(2,f-1)*Math.pow(2,o),s=0));o>=8;e[n+p]=255&a,p+=d,a/=256,o-=8);for(s=s<<o|a,u+=o;u>0;e[n+p]=255&s,p+=d,s/=256,u-=8);e[n+p-d]|=128*g}},function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},function(e,t,n){(function(e){var r=n(16),o=n(17),i=Object.prototype.toString,s="function"==typeof e.Blob||"[object BlobConstructor]"===i.call(e.Blob),a="function"==typeof e.File||"[object FileConstructor]"===i.call(e.File);t.deconstructPacket=function(e){var t=[],n=e.data,i=e;return i.data=function e(t,n){if(!t)return t;if(o(t)){var i={_placeholder:!0,num:n.length};return n.push(t),i}if(r(t)){for(var s=new Array(t.length),a=0;a<t.length;a++)s[a]=e(t[a],n);return s}if("object"==typeof t&&!(t instanceof Date)){s={};for(var c in t)s[c]=e(t[c],n);return s}return t}(n,t),i.attachments=t.length,{packet:i,buffers:t}},t.reconstructPacket=function(e,t){return e.data=function e(t,n){if(!t)return t;if(t&&t._placeholder)return n[t.num];if(r(t))for(var o=0;o<t.length;o++)t[o]=e(t[o],n);else if("object"==typeof t)for(var i in t)t[i]=e(t[i],n);return t}(e.data,t),e.attachments=void 0,e},t.removeBlobs=function(e,t){var n=0,i=e;!function e(c,u,l){if(!c)return c;if(s&&c instanceof Blob||a&&c instanceof File){n++;var f=new FileReader;f.onload=function(){l?l[u]=this.result:i=this.result,--n||t(i)},f.readAsArrayBuffer(c)}else if(r(c))for(var h=0;h<c.length;h++)e(c[h],h,c);else if("object"==typeof c&&!o(c))for(var p in c)e(c[p],p,c)}(i),n||t(i)}}).call(this,n(0))},function(e,t,n){e.exports=n(44),e.exports.parser=n(2)},function(e,t,n){(function(t){var r=n(19),o=n(12),i=n(7)("engine.io-client:socket"),s=n(22),a=n(2),c=n(13),u=n(5);function l(e,n){if(!(this instanceof l))return new l(e,n);n=n||{},e&&"object"==typeof e&&(n=e,e=null),e?(e=c(e),n.hostname=e.host,n.secure="https"===e.protocol||"wss"===e.protocol,n.port=e.port,e.query&&(n.query=e.query)):n.host&&(n.hostname=c(n.host).host),this.secure=null!=n.secure?n.secure:t.location&&"https:"===location.protocol,n.hostname&&!n.port&&(n.port=this.secure?"443":"80"),this.agent=n.agent||!1,this.hostname=n.hostname||(t.location?location.hostname:"localhost"),this.port=n.port||(t.location&&location.port?location.port:this.secure?443:80),this.query=n.query||{},"string"==typeof this.query&&(this.query=u.decode(this.query)),this.upgrade=!1!==n.upgrade,this.path=(n.path||"/engine.io").replace(/\/$/,"")+"/",this.forceJSONP=!!n.forceJSONP,this.jsonp=!1!==n.jsonp,this.forceBase64=!!n.forceBase64,this.enablesXDR=!!n.enablesXDR,this.timestampParam=n.timestampParam||"t",this.timestampRequests=n.timestampRequests,this.transports=n.transports||["polling","websocket"],this.transportOptions=n.transportOptions||{},this.readyState="",this.writeBuffer=[],this.prevBufferLen=0,this.policyPort=n.policyPort||843,this.rememberUpgrade=n.rememberUpgrade||!1,this.binaryType=null,this.onlyBinaryUpgrades=n.onlyBinaryUpgrades,this.perMessageDeflate=!1!==n.perMessageDeflate&&(n.perMessageDeflate||{}),!0===this.perMessageDeflate&&(this.perMessageDeflate={}),this.perMessageDeflate&&null==this.perMessageDeflate.threshold&&(this.perMessageDeflate.threshold=1024),this.pfx=n.pfx||null,this.key=n.key||null,this.passphrase=n.passphrase||null,this.cert=n.cert||null,this.ca=n.ca||null,this.ciphers=n.ciphers||null,this.rejectUnauthorized=void 0===n.rejectUnauthorized||n.rejectUnauthorized,this.forceNode=!!n.forceNode;var r="object"==typeof t&&t;r.global===r&&(n.extraHeaders&&Object.keys(n.extraHeaders).length>0&&(this.extraHeaders=n.extraHeaders),n.localAddress&&(this.localAddress=n.localAddress)),this.id=null,this.upgrades=null,this.pingInterval=null,this.pingTimeout=null,this.pingIntervalTimer=null,this.pingTimeoutTimer=null,this.open()}e.exports=l,l.priorWebsocketSuccess=!1,o(l.prototype),l.protocol=a.protocol,l.Socket=l,l.Transport=n(11),l.transports=n(19),l.parser=n(2),l.prototype.createTransport=function(e){i('creating transport "%s"',e);var t=function(e){var t={};for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return t}(this.query);t.EIO=a.protocol,t.transport=e;var n=this.transportOptions[e]||{};return this.id&&(t.sid=this.id),new r[e]({query:t,socket:this,agent:n.agent||this.agent,hostname:n.hostname||this.hostname,port:n.port||this.port,secure:n.secure||this.secure,path:n.path||this.path,forceJSONP:n.forceJSONP||this.forceJSONP,jsonp:n.jsonp||this.jsonp,forceBase64:n.forceBase64||this.forceBase64,enablesXDR:n.enablesXDR||this.enablesXDR,timestampRequests:n.timestampRequests||this.timestampRequests,timestampParam:n.timestampParam||this.timestampParam,policyPort:n.policyPort||this.policyPort,pfx:n.pfx||this.pfx,key:n.key||this.key,passphrase:n.passphrase||this.passphrase,cert:n.cert||this.cert,ca:n.ca||this.ca,ciphers:n.ciphers||this.ciphers,rejectUnauthorized:n.rejectUnauthorized||this.rejectUnauthorized,perMessageDeflate:n.perMessageDeflate||this.perMessageDeflate,extraHeaders:n.extraHeaders||this.extraHeaders,forceNode:n.forceNode||this.forceNode,localAddress:n.localAddress||this.localAddress,requestTimeout:n.requestTimeout||this.requestTimeout,protocols:n.protocols||void 0})},l.prototype.open=function(){var e;if(this.rememberUpgrade&&l.priorWebsocketSuccess&&-1!==this.transports.indexOf("websocket"))e="websocket";else{if(0===this.transports.length){var t=this;return void setTimeout((function(){t.emit("error","No transports available")}),0)}e=this.transports[0]}this.readyState="opening";try{e=this.createTransport(e)}catch(e){return this.transports.shift(),void this.open()}e.open(),this.setTransport(e)},l.prototype.setTransport=function(e){i("setting transport %s",e.name);var t=this;this.transport&&(i("clearing existing transport %s",this.transport.name),this.transport.removeAllListeners()),this.transport=e,e.on("drain",(function(){t.onDrain()})).on("packet",(function(e){t.onPacket(e)})).on("error",(function(e){t.onError(e)})).on("close",(function(){t.onClose("transport close")}))},l.prototype.probe=function(e){i('probing transport "%s"',e);var t=this.createTransport(e,{probe:1}),n=!1,r=this;function o(){if(r.onlyBinaryUpgrades){var o=!this.supportsBinary&&r.transport.supportsBinary;n=n||o}n||(i('probe transport "%s" opened',e),t.send([{type:"ping",data:"probe"}]),t.once("packet",(function(o){if(!n)if("pong"===o.type&&"probe"===o.data){if(i('probe transport "%s" pong',e),r.upgrading=!0,r.emit("upgrading",t),!t)return;l.priorWebsocketSuccess="websocket"===t.name,i('pausing current transport "%s"',r.transport.name),r.transport.pause((function(){n||"closed"!==r.readyState&&(i("changing transport and sending upgrade packet"),h(),r.setTransport(t),t.send([{type:"upgrade"}]),r.emit("upgrade",t),t=null,r.upgrading=!1,r.flush())}))}else{i('probe transport "%s" failed',e);var s=new Error("probe error");s.transport=t.name,r.emit("upgradeError",s)}})))}function s(){n||(n=!0,h(),t.close(),t=null)}function a(n){var o=new Error("probe error: "+n);o.transport=t.name,s(),i('probe transport "%s" failed because of error: %s',e,n),r.emit("upgradeError",o)}function c(){a("transport closed")}function u(){a("socket closed")}function f(e){t&&e.name!==t.name&&(i('"%s" works - aborting "%s"',e.name,t.name),s())}function h(){t.removeListener("open",o),t.removeListener("error",a),t.removeListener("close",c),r.removeListener("close",u),r.removeListener("upgrading",f)}l.priorWebsocketSuccess=!1,t.once("open",o),t.once("error",a),t.once("close",c),this.once("close",u),this.once("upgrading",f),t.open()},l.prototype.onOpen=function(){if(i("socket open"),this.readyState="open",l.priorWebsocketSuccess="websocket"===this.transport.name,this.emit("open"),this.flush(),"open"===this.readyState&&this.upgrade&&this.transport.pause){i("starting upgrade probes");for(var e=0,t=this.upgrades.length;e<t;e++)this.probe(this.upgrades[e])}},l.prototype.onPacket=function(e){if("opening"===this.readyState||"open"===this.readyState||"closing"===this.readyState)switch(i('socket receive: type "%s", data "%s"',e.type,e.data),this.emit("packet",e),this.emit("heartbeat"),e.type){case"open":this.onHandshake(JSON.parse(e.data));break;case"pong":this.setPing(),this.emit("pong");break;case"error":var t=new Error("server error");t.code=e.data,this.onError(t);break;case"message":this.emit("data",e.data),this.emit("message",e.data)}else i('packet received with socket readyState "%s"',this.readyState)},l.prototype.onHandshake=function(e){this.emit("handshake",e),this.id=e.sid,this.transport.query.sid=e.sid,this.upgrades=this.filterUpgrades(e.upgrades),this.pingInterval=e.pingInterval,this.pingTimeout=e.pingTimeout,this.onOpen(),"closed"!==this.readyState&&(this.setPing(),this.removeListener("heartbeat",this.onHeartbeat),this.on("heartbeat",this.onHeartbeat))},l.prototype.onHeartbeat=function(e){clearTimeout(this.pingTimeoutTimer);var t=this;t.pingTimeoutTimer=setTimeout((function(){"closed"!==t.readyState&&t.onClose("ping timeout")}),e||t.pingInterval+t.pingTimeout)},l.prototype.setPing=function(){var e=this;clearTimeout(e.pingIntervalTimer),e.pingIntervalTimer=setTimeout((function(){i("writing ping packet - expecting pong within %sms",e.pingTimeout),e.ping(),e.onHeartbeat(e.pingTimeout)}),e.pingInterval)},l.prototype.ping=function(){var e=this;this.sendPacket("ping",(function(){e.emit("ping")}))},l.prototype.onDrain=function(){this.writeBuffer.splice(0,this.prevBufferLen),this.prevBufferLen=0,0===this.writeBuffer.length?this.emit("drain"):this.flush()},l.prototype.flush=function(){"closed"!==this.readyState&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length&&(i("flushing %d packets in socket",this.writeBuffer.length),this.transport.send(this.writeBuffer),this.prevBufferLen=this.writeBuffer.length,this.emit("flush"))},l.prototype.write=l.prototype.send=function(e,t,n){return this.sendPacket("message",e,t,n),this},l.prototype.sendPacket=function(e,t,n,r){if("function"==typeof t&&(r=t,t=void 0),"function"==typeof n&&(r=n,n=null),"closing"!==this.readyState&&"closed"!==this.readyState){(n=n||{}).compress=!1!==n.compress;var o={type:e,data:t,options:n};this.emit("packetCreate",o),this.writeBuffer.push(o),r&&this.once("flush",r),this.flush()}},l.prototype.close=function(){if("opening"===this.readyState||"open"===this.readyState){this.readyState="closing";var e=this;this.writeBuffer.length?this.once("drain",(function(){this.upgrading?r():t()})):this.upgrading?r():t()}function t(){e.onClose("forced close"),i("socket closing - telling transport to close"),e.transport.close()}function n(){e.removeListener("upgrade",n),e.removeListener("upgradeError",n),t()}function r(){e.once("upgrade",n),e.once("upgradeError",n)}return this},l.prototype.onError=function(e){i("socket error %j",e),l.priorWebsocketSuccess=!1,this.emit("error",e),this.onClose("transport error",e)},l.prototype.onClose=function(e,t){if("opening"===this.readyState||"open"===this.readyState||"closing"===this.readyState){i('socket close with reason: "%s"',e);clearTimeout(this.pingIntervalTimer),clearTimeout(this.pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),this.readyState="closed",this.id=null,this.emit("close",e,t),this.writeBuffer=[],this.prevBufferLen=0}},l.prototype.filterUpgrades=function(e){for(var t=[],n=0,r=e.length;n<r;n++)~s(this.transports,e[n])&&t.push(e[n]);return t}}).call(this,n(0))},function(e,t){try{e.exports="undefined"!=typeof XMLHttpRequest&&"withCredentials"in new XMLHttpRequest}catch(t){e.exports=!1}},function(e,t,n){(function(t){var r=n(10),o=n(20),i=n(12),s=n(6),a=n(7)("engine.io-client:polling-xhr");function c(){}function u(e){if(o.call(this,e),this.requestTimeout=e.requestTimeout,this.extraHeaders=e.extraHeaders,t.location){var n="https:"===location.protocol,r=location.port;r||(r=n?443:80),this.xd=e.hostname!==t.location.hostname||r!==e.port,this.xs=e.secure!==n}}function l(e){this.method=e.method||"GET",this.uri=e.uri,this.xd=!!e.xd,this.xs=!!e.xs,this.async=!1!==e.async,this.data=void 0!==e.data?e.data:null,this.agent=e.agent,this.isBinary=e.isBinary,this.supportsBinary=e.supportsBinary,this.enablesXDR=e.enablesXDR,this.requestTimeout=e.requestTimeout,this.pfx=e.pfx,this.key=e.key,this.passphrase=e.passphrase,this.cert=e.cert,this.ca=e.ca,this.ciphers=e.ciphers,this.rejectUnauthorized=e.rejectUnauthorized,this.extraHeaders=e.extraHeaders,this.create()}function f(){for(var e in l.requests)l.requests.hasOwnProperty(e)&&l.requests[e].abort()}e.exports=u,e.exports.Request=l,s(u,o),u.prototype.supportsBinary=!0,u.prototype.request=function(e){return(e=e||{}).uri=this.uri(),e.xd=this.xd,e.xs=this.xs,e.agent=this.agent||!1,e.supportsBinary=this.supportsBinary,e.enablesXDR=this.enablesXDR,e.pfx=this.pfx,e.key=this.key,e.passphrase=this.passphrase,e.cert=this.cert,e.ca=this.ca,e.ciphers=this.ciphers,e.rejectUnauthorized=this.rejectUnauthorized,e.requestTimeout=this.requestTimeout,e.extraHeaders=this.extraHeaders,new l(e)},u.prototype.doWrite=function(e,t){var n="string"!=typeof e&&void 0!==e,r=this.request({method:"POST",data:e,isBinary:n}),o=this;r.on("success",t),r.on("error",(function(e){o.onError("xhr post error",e)})),this.sendXhr=r},u.prototype.doPoll=function(){a("xhr poll");var e=this.request(),t=this;e.on("data",(function(e){t.onData(e)})),e.on("error",(function(e){t.onError("xhr poll error",e)})),this.pollXhr=e},i(l.prototype),l.prototype.create=function(){var e={agent:this.agent,xdomain:this.xd,xscheme:this.xs,enablesXDR:this.enablesXDR};e.pfx=this.pfx,e.key=this.key,e.passphrase=this.passphrase,e.cert=this.cert,e.ca=this.ca,e.ciphers=this.ciphers,e.rejectUnauthorized=this.rejectUnauthorized;var n=this.xhr=new r(e),o=this;try{a("xhr open %s: %s",this.method,this.uri),n.open(this.method,this.uri,this.async);try{if(this.extraHeaders)for(var i in n.setDisableHeaderCheck&&n.setDisableHeaderCheck(!0),this.extraHeaders)this.extraHeaders.hasOwnProperty(i)&&n.setRequestHeader(i,this.extraHeaders[i])}catch(e){}if("POST"===this.method)try{this.isBinary?n.setRequestHeader("Content-type","application/octet-stream"):n.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch(e){}try{n.setRequestHeader("Accept","*/*")}catch(e){}"withCredentials"in n&&(n.withCredentials=!0),this.requestTimeout&&(n.timeout=this.requestTimeout),this.hasXDR()?(n.onload=function(){o.onLoad()},n.onerror=function(){o.onError(n.responseText)}):n.onreadystatechange=function(){if(2===n.readyState)try{var e=n.getResponseHeader("Content-Type");o.supportsBinary&&"application/octet-stream"===e&&(n.responseType="arraybuffer")}catch(e){}4===n.readyState&&(200===n.status||1223===n.status?o.onLoad():setTimeout((function(){o.onError(n.status)}),0))},a("xhr data %s",this.data),n.send(this.data)}catch(e){return void setTimeout((function(){o.onError(e)}),0)}t.document&&(this.index=l.requestsCount++,l.requests[this.index]=this)},l.prototype.onSuccess=function(){this.emit("success"),this.cleanup()},l.prototype.onData=function(e){this.emit("data",e),this.onSuccess()},l.prototype.onError=function(e){this.emit("error",e),this.cleanup(!0)},l.prototype.cleanup=function(e){if(void 0!==this.xhr&&null!==this.xhr){if(this.hasXDR()?this.xhr.onload=this.xhr.onerror=c:this.xhr.onreadystatechange=c,e)try{this.xhr.abort()}catch(e){}t.document&&delete l.requests[this.index],this.xhr=null}},l.prototype.onLoad=function(){var e;try{var t;try{t=this.xhr.getResponseHeader("Content-Type")}catch(e){}e="application/octet-stream"===t&&this.xhr.response||this.xhr.responseText}catch(e){this.onError(e)}null!=e&&this.onData(e)},l.prototype.hasXDR=function(){return void 0!==t.XDomainRequest&&!this.xs&&this.enablesXDR},l.prototype.abort=function(){this.cleanup()},l.requestsCount=0,l.requests={},t.document&&(t.attachEvent?t.attachEvent("onunload",f):t.addEventListener&&t.addEventListener("beforeunload",f,!1))}).call(this,n(0))},function(e,t){e.exports=Object.keys||function(e){var t=[],n=Object.prototype.hasOwnProperty;for(var r in e)n.call(e,r)&&t.push(r);return t}},function(e,t){e.exports=function(e,t,n){var r=e.byteLength;if(t=t||0,n=n||r,e.slice)return e.slice(t,n);if(t<0&&(t+=r),n<0&&(n+=r),n>r&&(n=r),t>=r||t>=n||0===r)return new ArrayBuffer(0);for(var o=new Uint8Array(e),i=new Uint8Array(n-t),s=t,a=0;s<n;s++,a++)i[a]=o[s];return i.buffer}},function(e,t){function n(){}e.exports=function(e,t,r){var o=!1;return r=r||n,i.count=e,0===e?t():i;function i(e,n){if(i.count<=0)throw new Error("after called too many times");--i.count,e?(o=!0,t(e),t=r):0!==i.count||o||t(null,n)}}},function(e,t){
 /*! https://mths.be/utf8js v2.1.2 by @mathias */
-var n,r,o,i=String.fromCharCode;function s(e){for(var t,n,r=[],o=0,i=e.length;o<i;)(t=e.charCodeAt(o++))>=55296&&t<=56319&&o<i?56320==(64512&(n=e.charCodeAt(o++)))?r.push(((1023&t)<<10)+(1023&n)+65536):(r.push(t),o--):r.push(t);return r}function a(e,t){if(e>=55296&&e<=57343){if(t)throw Error("Lone surrogate U+"+e.toString(16).toUpperCase()+" is not a scalar value");return!1}return!0}function c(e,t){return i(e>>t&63|128)}function u(e,t){if(0==(4294967168&e))return i(e);var n="";return 0==(4294965248&e)?n=i(e>>6&31|192):0==(4294901760&e)?(a(e,t)||(e=65533),n=i(e>>12&15|224),n+=c(e,6)):0==(4292870144&e)&&(n=i(e>>18&7|240),n+=c(e,12),n+=c(e,6)),n+=i(63&e|128)}function l(){if(o>=r)throw Error("Invalid byte index");var e=255&n[o];if(o++,128==(192&e))return 63&e;throw Error("Invalid continuation byte")}function f(e){var t,i;if(o>r)throw Error("Invalid byte index");if(o==r)return!1;if(t=255&n[o],o++,0==(128&t))return t;if(192==(224&t)){if((i=(31&t)<<6|l())>=128)return i;throw Error("Invalid continuation byte")}if(224==(240&t)){if((i=(15&t)<<12|l()<<6|l())>=2048)return a(i,e)?i:65533;throw Error("Invalid continuation byte")}if(240==(248&t)&&(i=(7&t)<<18|l()<<12|l()<<6|l())>=65536&&i<=1114111)return i;throw Error("Invalid UTF-8 detected")}e.exports={version:"2.1.2",encode:function(e,t){for(var n=!1!==(t=t||{}).strict,r=s(e),o=r.length,i=-1,a="";++i<o;)a+=u(r[i],n);return a},decode:function(e,t){var a=!1!==(t=t||{}).strict;n=s(e),r=n.length,o=0;for(var c,u=[];!1!==(c=f(a));)u.push(c);return function(e){for(var t,n=e.length,r=-1,o="";++r<n;)(t=e[r])>65535&&(o+=i((t-=65536)>>>10&1023|55296),t=56320|1023&t),o+=i(t);return o}(u)}}},function(e,t){!function(){"use strict";for(var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",n=new Uint8Array(256),r=0;r<e.length;r++)n[e.charCodeAt(r)]=r;t.encode=function(t){var n,r=new Uint8Array(t),o=r.length,i="";for(n=0;n<o;n+=3)i+=e[r[n]>>2],i+=e[(3&r[n])<<4|r[n+1]>>4],i+=e[(15&r[n+1])<<2|r[n+2]>>6],i+=e[63&r[n+2]];return o%3==2?i=i.substring(0,i.length-1)+"=":o%3==1&&(i=i.substring(0,i.length-2)+"=="),i},t.decode=function(e){var t,r,o,i,s,a=.75*e.length,c=e.length,u=0;"="===e[e.length-1]&&(a--,"="===e[e.length-2]&&a--);var l=new ArrayBuffer(a),f=new Uint8Array(l);for(t=0;t<c;t+=4)r=n[e.charCodeAt(t)],o=n[e.charCodeAt(t+1)],i=n[e.charCodeAt(t+2)],s=n[e.charCodeAt(t+3)],f[u++]=r<<2|o>>4,f[u++]=(15&o)<<4|i>>2,f[u++]=(3&i)<<6|63&s;return l}}()},function(e,t){var n=void 0!==n?n:"undefined"!=typeof WebKitBlobBuilder?WebKitBlobBuilder:"undefined"!=typeof MSBlobBuilder?MSBlobBuilder:"undefined"!=typeof MozBlobBuilder&&MozBlobBuilder,r=function(){try{return 2===new Blob(["hi"]).size}catch(e){return!1}}(),o=r&&function(){try{return 2===new Blob([new Uint8Array([1,2])]).size}catch(e){return!1}}(),i=n&&n.prototype.append&&n.prototype.getBlob;function s(e){return e.map((function(e){if(e.buffer instanceof ArrayBuffer){var t=e.buffer;if(e.byteLength!==t.byteLength){var n=new Uint8Array(e.byteLength);n.set(new Uint8Array(t,e.byteOffset,e.byteLength)),t=n.buffer}return t}return e}))}function a(e,t){t=t||{};var r=new n;return s(e).forEach((function(e){r.append(e)})),t.type?r.getBlob(t.type):r.getBlob()}function c(e,t){return new Blob(s(e),t||{})}"undefined"!=typeof Blob&&(a.prototype=Blob.prototype,c.prototype=Blob.prototype),e.exports=r?o?Blob:c:i?a:void 0},function(e,t,n){e.exports=function(e){function t(e){let t=0;for(let n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n),t|=0;return r.colors[Math.abs(t)%r.colors.length]}function r(e){let n;function s(...e){if(!s.enabled)return;const t=s,o=Number(new Date),i=o-(n||o);t.diff=i,t.prev=n,t.curr=o,n=o,e[0]=r.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let a=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,((n,o)=>{if("%%"===n)return n;a++;const i=r.formatters[o];if("function"==typeof i){const r=e[a];n=i.call(t,r),e.splice(a,1),a--}return n})),r.formatArgs.call(t,e);(t.log||r.log).apply(t,e)}return s.namespace=e,s.enabled=r.enabled(e),s.useColors=r.useColors(),s.color=t(e),s.destroy=o,s.extend=i,"function"==typeof r.init&&r.init(s),r.instances.push(s),s}function o(){const e=r.instances.indexOf(this);return-1!==e&&(r.instances.splice(e,1),!0)}function i(e,t){const n=r(this.namespace+(void 0===t?":":t)+e);return n.log=this.log,n}function s(e){return e.toString().substring(2,e.toString().length-2).replace(/\.\*\?$/,"*")}return r.debug=r,r.default=r,r.coerce=function(e){if(e instanceof Error)return e.stack||e.message;return e},r.disable=function(){const e=[...r.names.map(s),...r.skips.map(s).map((e=>"-"+e))].join(",");return r.enable(""),e},r.enable=function(e){let t;r.save(e),r.names=[],r.skips=[];const n=("string"==typeof e?e:"").split(/[\s,]+/),o=n.length;for(t=0;t<o;t++)n[t]&&("-"===(e=n[t].replace(/\*/g,".*?"))[0]?r.skips.push(new RegExp("^"+e.substr(1)+"$")):r.names.push(new RegExp("^"+e+"$")));for(t=0;t<r.instances.length;t++){const e=r.instances[t];e.enabled=r.enabled(e.namespace)}},r.enabled=function(e){if("*"===e[e.length-1])return!0;let t,n;for(t=0,n=r.skips.length;t<n;t++)if(r.skips[t].test(e))return!1;for(t=0,n=r.names.length;t<n;t++)if(r.names[t].test(e))return!0;return!1},r.humanize=n(7),Object.keys(e).forEach((t=>{r[t]=e[t]})),r.instances=[],r.names=[],r.skips=[],r.formatters={},r.selectColor=t,r.enable(r.load()),r}},function(e,t,n){var r=n(22),o=n(5),i=n(12);e.exports=l;var s,a=/\n/g,c=/\\n/g;function u(){}function l(e){r.call(this,e),this.query=this.query||{},s||(s=i.___eio=i.___eio||[]),this.index=s.length;var t=this;s.push((function(e){t.onData(e)})),this.query.j=this.index,"function"==typeof addEventListener&&addEventListener("beforeunload",(function(){t.script&&(t.script.onerror=u)}),!1)}o(l,r),l.prototype.supportsBinary=!1,l.prototype.doClose=function(){this.script&&(this.script.parentNode.removeChild(this.script),this.script=null),this.form&&(this.form.parentNode.removeChild(this.form),this.form=null,this.iframe=null),r.prototype.doClose.call(this)},l.prototype.doPoll=function(){var e=this,t=document.createElement("script");this.script&&(this.script.parentNode.removeChild(this.script),this.script=null),t.async=!0,t.src=this.uri(),t.onerror=function(t){e.onError("jsonp poll error",t)};var n=document.getElementsByTagName("script")[0];n?n.parentNode.insertBefore(t,n):(document.head||document.body).appendChild(t),this.script=t,"undefined"!=typeof navigator&&/gecko/i.test(navigator.userAgent)&&setTimeout((function(){var e=document.createElement("iframe");document.body.appendChild(e),document.body.removeChild(e)}),100)},l.prototype.doWrite=function(e,t){var n=this;if(!this.form){var r,o=document.createElement("form"),i=document.createElement("textarea"),s=this.iframeId="eio_iframe_"+this.index;o.className="socketio",o.style.position="absolute",o.style.top="-1000px",o.style.left="-1000px",o.target=s,o.method="POST",o.setAttribute("accept-charset","utf-8"),i.name="d",o.appendChild(i),document.body.appendChild(o),this.form=o,this.area=i}function u(){l(),t()}function l(){if(n.iframe)try{n.form.removeChild(n.iframe)}catch(e){n.onError("jsonp polling iframe removal error",e)}try{var e='<iframe src="javascript:0" name="'+n.iframeId+'">';r=document.createElement(e)}catch(e){(r=document.createElement("iframe")).name=n.iframeId,r.src="javascript:0"}r.id=n.iframeId,n.form.appendChild(r),n.iframe=r}this.form.action=this.uri(),l(),e=e.replace(c,"\\\n"),this.area.value=e.replace(a,"\\n");try{this.form.submit()}catch(e){}this.iframe.attachEvent?this.iframe.onreadystatechange=function(){"complete"===n.iframe.readyState&&u()}:this.iframe.onload=u}},function(e,t,n){(function(t){var r,o,i=n(13),s=n(1),a=n(4),c=n(5),u=n(24),l=n(6)("engine.io-client:websocket");if("undefined"!=typeof WebSocket?r=WebSocket:"undefined"!=typeof self&&(r=self.WebSocket||self.MozWebSocket),"undefined"==typeof window)try{o=n(57)}catch(e){}var f=r||o;function h(e){e&&e.forceBase64&&(this.supportsBinary=!1),this.perMessageDeflate=e.perMessageDeflate,this.usingBrowserWebSocket=r&&!e.forceNode,this.protocols=e.protocols,this.usingBrowserWebSocket||(f=o),i.call(this,e)}e.exports=h,c(h,i),h.prototype.name="websocket",h.prototype.supportsBinary=!0,h.prototype.doOpen=function(){if(this.check()){var e=this.uri(),t=this.protocols,n={};this.isReactNative||(n.agent=this.agent,n.perMessageDeflate=this.perMessageDeflate,n.pfx=this.pfx,n.key=this.key,n.passphrase=this.passphrase,n.cert=this.cert,n.ca=this.ca,n.ciphers=this.ciphers,n.rejectUnauthorized=this.rejectUnauthorized),this.extraHeaders&&(n.headers=this.extraHeaders),this.localAddress&&(n.localAddress=this.localAddress);try{this.ws=this.usingBrowserWebSocket&&!this.isReactNative?t?new f(e,t):new f(e):new f(e,t,n)}catch(e){return this.emit("error",e)}void 0===this.ws.binaryType&&(this.supportsBinary=!1),this.ws.supports&&this.ws.supports.binary?(this.supportsBinary=!0,this.ws.binaryType="nodebuffer"):this.ws.binaryType="arraybuffer",this.addEventListeners()}},h.prototype.addEventListeners=function(){var e=this;this.ws.onopen=function(){e.onOpen()},this.ws.onclose=function(){e.onClose()},this.ws.onmessage=function(t){e.onData(t.data)},this.ws.onerror=function(t){e.onError("websocket error",t)}},h.prototype.write=function(e){var n=this;this.writable=!1;for(var r=e.length,o=0,i=r;o<i;o++)!function(e){s.encodePacket(e,n.supportsBinary,(function(o){if(!n.usingBrowserWebSocket){var i={};if(e.options&&(i.compress=e.options.compress),n.perMessageDeflate)("string"==typeof o?t.byteLength(o):o.length)<n.perMessageDeflate.threshold&&(i.compress=!1)}try{n.usingBrowserWebSocket?n.ws.send(o):n.ws.send(o,i)}catch(e){l("websocket closed before onclose event")}--r||a()}))}(e[o]);function a(){n.emit("flush"),setTimeout((function(){n.writable=!0,n.emit("drain")}),0)}},h.prototype.onClose=function(){i.prototype.onClose.call(this)},h.prototype.doClose=function(){void 0!==this.ws&&this.ws.close()},h.prototype.uri=function(){var e=this.query||{},t=this.secure?"wss":"ws",n="";return this.port&&("wss"===t&&443!==Number(this.port)||"ws"===t&&80!==Number(this.port))&&(n=":"+this.port),this.timestampRequests&&(e[this.timestampParam]=u()),this.supportsBinary||(e.b64=1),(e=a.encode(e)).length&&(e="?"+e),t+"://"+(-1!==this.hostname.indexOf(":")?"["+this.hostname+"]":this.hostname)+n+this.path+e},h.prototype.check=function(){return!(!f||"__initialize"in f&&this.name===h.prototype.name)}}).call(this,n(10).Buffer)},function(e,t){},function(e,t){e.exports=function(e,t){for(var n=[],r=(t=t||0)||0;r<e.length;r++)n[r-t]=e[r];return n}},function(e,t){function n(e){e=e||{},this.ms=e.min||100,this.max=e.max||1e4,this.factor=e.factor||2,this.jitter=e.jitter>0&&e.jitter<=1?e.jitter:0,this.attempts=0}e.exports=n,n.prototype.duration=function(){var e=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var t=Math.random(),n=Math.floor(t*this.jitter*e);e=0==(1&Math.floor(10*t))?e-n:e+n}return 0|Math.min(e,this.max)},n.prototype.reset=function(){this.attempts=0},n.prototype.setMin=function(e){this.ms=e},n.prototype.setMax=function(e){this.max=e},n.prototype.setJitter=function(e){this.jitter=e}},function(e,t,n){var r;
-/*!
- * UAParser.js v0.7.22
- * Lightweight JavaScript-based User-Agent string parser
- * https://github.com/faisalman/ua-parser-js
- *
- * Copyright Â© 2012-2019 Faisal Salman <f@faisalman.com>
- * Licensed under MIT License
- */!function(o,i){"use strict";var s="function",a="undefined",c="object",u="model",l="name",f="type",h="vendor",p="version",d="architecture",g="console",y="mobile",m="tablet",b="smarttv",v="wearable",w={extend:function(e,t){var n={};for(var r in e)t[r]&&t[r].length%2==0?n[r]=t[r].concat(e[r]):n[r]=e[r];return n},has:function(e,t){return"string"==typeof e&&-1!==t.toLowerCase().indexOf(e.toLowerCase())},lowerize:function(e){return e.toLowerCase()},major:function(e){return"string"==typeof e?e.replace(/[^\d\.]/g,"").split(".")[0]:i},trim:function(e){return e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}},C={rgx:function(e,t){for(var n,r,o,a,u,l,f=0;f<t.length&&!u;){var h=t[f],p=t[f+1];for(n=r=0;n<h.length&&!u;)if(u=h[n++].exec(e))for(o=0;o<p.length;o++)l=u[++r],typeof(a=p[o])===c&&a.length>0?2==a.length?typeof a[1]==s?this[a[0]]=a[1].call(this,l):this[a[0]]=a[1]:3==a.length?typeof a[1]!==s||a[1].exec&&a[1].test?this[a[0]]=l?l.replace(a[1],a[2]):i:this[a[0]]=l?a[1].call(this,l,a[2]):i:4==a.length&&(this[a[0]]=l?a[3].call(this,l.replace(a[1],a[2])):i):this[a]=l||i;f+=2}},str:function(e,t){for(var n in t)if(typeof t[n]===c&&t[n].length>0){for(var r=0;r<t[n].length;r++)if(w.has(t[n][r],e))return"?"===n?i:n}else if(w.has(t[n],e))return"?"===n?i:n;return e}},A={browser:{oldsafari:{version:{"1.0":"/8",1.2:"/1",1.3:"/3","2.0":"/412","2.0.2":"/416","2.0.3":"/417","2.0.4":"/419","?":"/"}}},device:{amazon:{model:{"Fire Phone":["SD","KF"]}},sprint:{model:{"Evo Shift 4G":"7373KT"},vendor:{HTC:"APA",Sprint:"Sprint"}}},os:{windows:{version:{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"}}}},k={browser:[[/(opera\smini)\/([\w\.-]+)/i,/(opera\s[mobiletab]+).+version\/([\w\.-]+)/i,/(opera).+version\/([\w\.]+)/i,/(opera)[\/\s]+([\w\.]+)/i],[l,p],[/(opios)[\/\s]+([\w\.]+)/i],[[l,"Opera Mini"],p],[/\s(opr)\/([\w\.]+)/i],[[l,"Opera"],p],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer)[\/\s]?([\w\.]*)/i,/(avant\s|iemobile|slim)(?:browser)?[\/\s]?([\w\.]*)/i,/(bidubrowser|baidubrowser)[\/\s]?([\w\.]+)/i,/(?:ms|\()(ie)\s([\w\.]+)/i,/(rekonq)\/([\w\.]*)/i,/(chromium|flock|rockmelt|midori|epiphany|silk|skyfire|ovibrowser|bolt|iron|vivaldi|iridium|phantomjs|bowser|quark|qupzilla|falkon)\/([\w\.-]+)/i],[l,p],[/(konqueror)\/([\w\.]+)/i],[[l,"Konqueror"],p],[/(trident).+rv[:\s]([\w\.]+).+like\sgecko/i],[[l,"IE"],p],[/(edge|edgios|edga|edg)\/((\d+)?[\w\.]+)/i],[[l,"Edge"],p],[/(yabrowser)\/([\w\.]+)/i],[[l,"Yandex"],p],[/(Avast)\/([\w\.]+)/i],[[l,"Avast Secure Browser"],p],[/(AVG)\/([\w\.]+)/i],[[l,"AVG Secure Browser"],p],[/(puffin)\/([\w\.]+)/i],[[l,"Puffin"],p],[/(focus)\/([\w\.]+)/i],[[l,"Firefox Focus"],p],[/(opt)\/([\w\.]+)/i],[[l,"Opera Touch"],p],[/((?:[\s\/])uc?\s?browser|(?:juc.+)ucweb)[\/\s]?([\w\.]+)/i],[[l,"UCBrowser"],p],[/(comodo_dragon)\/([\w\.]+)/i],[[l,/_/g," "],p],[/(windowswechat qbcore)\/([\w\.]+)/i],[[l,"WeChat(Win) Desktop"],p],[/(micromessenger)\/([\w\.]+)/i],[[l,"WeChat"],p],[/(brave)\/([\w\.]+)/i],[[l,"Brave"],p],[/(qqbrowserlite)\/([\w\.]+)/i],[l,p],[/(QQ)\/([\d\.]+)/i],[l,p],[/m?(qqbrowser)[\/\s]?([\w\.]+)/i],[l,p],[/(baiduboxapp)[\/\s]?([\w\.]+)/i],[l,p],[/(2345Explorer)[\/\s]?([\w\.]+)/i],[l,p],[/(MetaSr)[\/\s]?([\w\.]+)/i],[l],[/(LBBROWSER)/i],[l],[/xiaomi\/miuibrowser\/([\w\.]+)/i],[p,[l,"MIUI Browser"]],[/;fbav\/([\w\.]+);/i],[p,[l,"Facebook"]],[/safari\s(line)\/([\w\.]+)/i,/android.+(line)\/([\w\.]+)\/iab/i],[l,p],[/headlesschrome(?:\/([\w\.]+)|\s)/i],[p,[l,"Chrome Headless"]],[/\swv\).+(chrome)\/([\w\.]+)/i],[[l,/(.+)/,"$1 WebView"],p],[/((?:oculus|samsung)browser)\/([\w\.]+)/i],[[l,/(.+(?:g|us))(.+)/,"$1 $2"],p],[/android.+version\/([\w\.]+)\s+(?:mobile\s?safari|safari)*/i],[p,[l,"Android Browser"]],[/(sailfishbrowser)\/([\w\.]+)/i],[[l,"Sailfish Browser"],p],[/(chrome|omniweb|arora|[tizenoka]{5}\s?browser)\/v?([\w\.]+)/i],[l,p],[/(dolfin)\/([\w\.]+)/i],[[l,"Dolphin"],p],[/(qihu|qhbrowser|qihoobrowser|360browser)/i],[[l,"360 Browser"]],[/((?:android.+)crmo|crios)\/([\w\.]+)/i],[[l,"Chrome"],p],[/(coast)\/([\w\.]+)/i],[[l,"Opera Coast"],p],[/fxios\/([\w\.-]+)/i],[p,[l,"Firefox"]],[/version\/([\w\.]+).+?mobile\/\w+\s(safari)/i],[p,[l,"Mobile Safari"]],[/version\/([\w\.]+).+?(mobile\s?safari|safari)/i],[p,l],[/webkit.+?(gsa)\/([\w\.]+).+?(mobile\s?safari|safari)(\/[\w\.]+)/i],[[l,"GSA"],p],[/webkit.+?(mobile\s?safari|safari)(\/[\w\.]+)/i],[l,[p,C.str,A.browser.oldsafari.version]],[/(webkit|khtml)\/([\w\.]+)/i],[l,p],[/(navigator|netscape)\/([\w\.-]+)/i],[[l,"Netscape"],p],[/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo\sbrowser|minimo|conkeror)[\/\s]?([\w\.\+]+)/i,/(firefox|seamonkey|k-meleon|icecat|iceape|firebird|phoenix|palemoon|basilisk|waterfox)\/([\w\.-]+)$/i,/(mozilla)\/([\w\.]+).+rv\:.+gecko\/\d+/i,/(polaris|lynx|dillo|icab|doris|amaya|w3m|netsurf|sleipnir)[\/\s]?([\w\.]+)/i,/(links)\s\(([\w\.]+)/i,/(gobrowser)\/?([\w\.]*)/i,/(ice\s?browser)\/v?([\w\._]+)/i,/(mosaic)[\/\s]([\w\.]+)/i],[l,p]],cpu:[[/(?:(amd|x(?:(?:86|64)[_-])?|wow|win)64)[;\)]/i],[[d,"amd64"]],[/(ia32(?=;))/i],[[d,w.lowerize]],[/((?:i[346]|x)86)[;\)]/i],[[d,"ia32"]],[/windows\s(ce|mobile);\sppc;/i],[[d,"arm"]],[/((?:ppc|powerpc)(?:64)?)(?:\smac|;|\))/i],[[d,/ower/,"",w.lowerize]],[/(sun4\w)[;\)]/i],[[d,"sparc"]],[/((?:avr32|ia64(?=;))|68k(?=\))|arm(?:64|(?=v\d+[;l]))|(?=atmel\s)avr|(?:irix|mips|sparc)(?:64)?(?=;)|pa-risc)/i],[[d,w.lowerize]]],device:[[/\((ipad|playbook);[\w\s\),;-]+(rim|apple)/i],[u,h,[f,m]],[/applecoremedia\/[\w\.]+ \((ipad)/],[u,[h,"Apple"],[f,m]],[/(apple\s{0,1}tv)/i],[[u,"Apple TV"],[h,"Apple"],[f,b]],[/(archos)\s(gamepad2?)/i,/(hp).+(touchpad)/i,/(hp).+(tablet)/i,/(kindle)\/([\w\.]+)/i,/\s(nook)[\w\s]+build\/(\w+)/i,/(dell)\s(strea[kpr\s\d]*[\dko])/i],[h,u,[f,m]],[/(kf[A-z]+)\sbuild\/.+silk\//i],[u,[h,"Amazon"],[f,m]],[/(sd|kf)[0349hijorstuw]+\sbuild\/.+silk\//i],[[u,C.str,A.device.amazon.model],[h,"Amazon"],[f,y]],[/android.+aft([bms])\sbuild/i],[u,[h,"Amazon"],[f,b]],[/\((ip[honed|\s\w*]+);.+(apple)/i],[u,h,[f,y]],[/\((ip[honed|\s\w*]+);/i],[u,[h,"Apple"],[f,y]],[/(blackberry)[\s-]?(\w+)/i,/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus|dell|meizu|motorola|polytron)[\s_-]?([\w-]*)/i,/(hp)\s([\w\s]+\w)/i,/(asus)-?(\w+)/i],[h,u,[f,y]],[/\(bb10;\s(\w+)/i],[u,[h,"BlackBerry"],[f,y]],[/android.+(transfo[prime\s]{4,10}\s\w+|eeepc|slider\s\w+|nexus 7|padfone|p00c)/i],[u,[h,"Asus"],[f,m]],[/(sony)\s(tablet\s[ps])\sbuild\//i,/(sony)?(?:sgp.+)\sbuild\//i],[[h,"Sony"],[u,"Xperia Tablet"],[f,m]],[/android.+\s([c-g]\d{4}|so[-l]\w+)(?=\sbuild\/|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[u,[h,"Sony"],[f,y]],[/\s(ouya)\s/i,/(nintendo)\s([wids3u]+)/i],[h,u,[f,g]],[/android.+;\s(shield)\sbuild/i],[u,[h,"Nvidia"],[f,g]],[/(playstation\s[34portablevi]+)/i],[u,[h,"Sony"],[f,g]],[/(sprint\s(\w+))/i],[[h,C.str,A.device.sprint.vendor],[u,C.str,A.device.sprint.model],[f,y]],[/(htc)[;_\s-]+([\w\s]+(?=\)|\sbuild)|\w+)/i,/(zte)-(\w*)/i,/(alcatel|geeksphone|nexian|panasonic|(?=;\s)sony)[_\s-]?([\w-]*)/i],[h,[u,/_/g," "],[f,y]],[/(nexus\s9)/i],[u,[h,"HTC"],[f,m]],[/d\/huawei([\w\s-]+)[;\)]/i,/(nexus\s6p|vog-l29|ane-lx1|eml-l29|ele-l29)/i],[u,[h,"Huawei"],[f,y]],[/android.+(bah2?-a?[lw]\d{2})/i],[u,[h,"Huawei"],[f,m]],[/(microsoft);\s(lumia[\s\w]+)/i],[h,u,[f,y]],[/[\s\(;](xbox(?:\sone)?)[\s\);]/i],[u,[h,"Microsoft"],[f,g]],[/(kin\.[onetw]{3})/i],[[u,/\./g," "],[h,"Microsoft"],[f,y]],[/\s(milestone|droid(?:[2-4x]|\s(?:bionic|x2|pro|razr))?:?(\s4g)?)[\w\s]+build\//i,/mot[\s-]?(\w*)/i,/(XT\d{3,4}) build\//i,/(nexus\s6)/i],[u,[h,"Motorola"],[f,y]],[/android.+\s(mz60\d|xoom[\s2]{0,2})\sbuild\//i],[u,[h,"Motorola"],[f,m]],[/hbbtv\/\d+\.\d+\.\d+\s+\([\w\s]*;\s*(\w[^;]*);([^;]*)/i],[[h,w.trim],[u,w.trim],[f,b]],[/hbbtv.+maple;(\d+)/i],[[u,/^/,"SmartTV"],[h,"Samsung"],[f,b]],[/\(dtv[\);].+(aquos)/i],[u,[h,"Sharp"],[f,b]],[/android.+((sch-i[89]0\d|shw-m380s|gt-p\d{4}|gt-n\d+|sgh-t8[56]9|nexus 10))/i,/((SM-T\w+))/i],[[h,"Samsung"],u,[f,m]],[/smart-tv.+(samsung)/i],[h,[f,b],u],[/((s[cgp]h-\w+|gt-\w+|galaxy\snexus|sm-\w[\w\d]+))/i,/(sam[sung]*)[\s-]*(\w+-?[\w-]*)/i,/sec-((sgh\w+))/i],[[h,"Samsung"],u,[f,y]],[/sie-(\w*)/i],[u,[h,"Siemens"],[f,y]],[/(maemo|nokia).*(n900|lumia\s\d+)/i,/(nokia)[\s_-]?([\w-]*)/i],[[h,"Nokia"],u,[f,y]],[/android[x\d\.\s;]+\s([ab][1-7]\-?[0178a]\d\d?)/i],[u,[h,"Acer"],[f,m]],[/android.+([vl]k\-?\d{3})\s+build/i],[u,[h,"LG"],[f,m]],[/android\s3\.[\s\w;-]{10}(lg?)-([06cv9]{3,4})/i],[[h,"LG"],u,[f,m]],[/(lg) netcast\.tv/i],[h,u,[f,b]],[/(nexus\s[45])/i,/lg[e;\s\/-]+(\w*)/i,/android.+lg(\-?[\d\w]+)\s+build/i],[u,[h,"LG"],[f,y]],[/(lenovo)\s?(s(?:5000|6000)(?:[\w-]+)|tab(?:[\s\w]+))/i],[h,u,[f,m]],[/android.+(ideatab[a-z0-9\-\s]+)/i],[u,[h,"Lenovo"],[f,m]],[/(lenovo)[_\s-]?([\w-]+)/i],[h,u,[f,y]],[/linux;.+((jolla));/i],[h,u,[f,y]],[/((pebble))app\/[\d\.]+\s/i],[h,u,[f,v]],[/android.+;\s(oppo)\s?([\w\s]+)\sbuild/i],[h,u,[f,y]],[/crkey/i],[[u,"Chromecast"],[h,"Google"],[f,b]],[/android.+;\s(glass)\s\d/i],[u,[h,"Google"],[f,v]],[/android.+;\s(pixel c)[\s)]/i],[u,[h,"Google"],[f,m]],[/android.+;\s(pixel( [23])?( xl)?)[\s)]/i],[u,[h,"Google"],[f,y]],[/android.+;\s(\w+)\s+build\/hm\1/i,/android.+(hm[\s\-_]*note?[\s_]*(?:\d\w)?)\s+build/i,/android.+(mi[\s\-_]*(?:a\d|one|one[\s_]plus|note lte)?[\s_]*(?:\d?\w?)[\s_]*(?:plus)?)\s+build/i,/android.+(redmi[\s\-_]*(?:note)?(?:[\s_]?[\w\s]+))\s+build/i],[[u,/_/g," "],[h,"Xiaomi"],[f,y]],[/android.+(mi[\s\-_]*(?:pad)(?:[\s_]?[\w\s]+))\s+build/i],[[u,/_/g," "],[h,"Xiaomi"],[f,m]],[/android.+;\s(m[1-5]\snote)\sbuild/i],[u,[h,"Meizu"],[f,y]],[/(mz)-([\w-]{2,})/i],[[h,"Meizu"],u,[f,y]],[/android.+a000(1)\s+build/i,/android.+oneplus\s(a\d{4})[\s)]/i],[u,[h,"OnePlus"],[f,y]],[/android.+[;\/]\s*(RCT[\d\w]+)\s+build/i],[u,[h,"RCA"],[f,m]],[/android.+[;\/\s]+(Venue[\d\s]{2,7})\s+build/i],[u,[h,"Dell"],[f,m]],[/android.+[;\/]\s*(Q[T|M][\d\w]+)\s+build/i],[u,[h,"Verizon"],[f,m]],[/android.+[;\/]\s+(Barnes[&\s]+Noble\s+|BN[RT])(V?.*)\s+build/i],[[h,"Barnes & Noble"],u,[f,m]],[/android.+[;\/]\s+(TM\d{3}.*\b)\s+build/i],[u,[h,"NuVision"],[f,m]],[/android.+;\s(k88)\sbuild/i],[u,[h,"ZTE"],[f,m]],[/android.+[;\/]\s*(gen\d{3})\s+build.*49h/i],[u,[h,"Swiss"],[f,y]],[/android.+[;\/]\s*(zur\d{3})\s+build/i],[u,[h,"Swiss"],[f,m]],[/android.+[;\/]\s*((Zeki)?TB.*\b)\s+build/i],[u,[h,"Zeki"],[f,m]],[/(android).+[;\/]\s+([YR]\d{2})\s+build/i,/android.+[;\/]\s+(Dragon[\-\s]+Touch\s+|DT)(\w{5})\sbuild/i],[[h,"Dragon Touch"],u,[f,m]],[/android.+[;\/]\s*(NS-?\w{0,9})\sbuild/i],[u,[h,"Insignia"],[f,m]],[/android.+[;\/]\s*((NX|Next)-?\w{0,9})\s+build/i],[u,[h,"NextBook"],[f,m]],[/android.+[;\/]\s*(Xtreme\_)?(V(1[045]|2[015]|30|40|60|7[05]|90))\s+build/i],[[h,"Voice"],u,[f,y]],[/android.+[;\/]\s*(LVTEL\-)?(V1[12])\s+build/i],[[h,"LvTel"],u,[f,y]],[/android.+;\s(PH-1)\s/i],[u,[h,"Essential"],[f,y]],[/android.+[;\/]\s*(V(100MD|700NA|7011|917G).*\b)\s+build/i],[u,[h,"Envizen"],[f,m]],[/android.+[;\/]\s*(Le[\s\-]+Pan)[\s\-]+(\w{1,9})\s+build/i],[h,u,[f,m]],[/android.+[;\/]\s*(Trio[\s\-]*.*)\s+build/i],[u,[h,"MachSpeed"],[f,m]],[/android.+[;\/]\s*(Trinity)[\-\s]*(T\d{3})\s+build/i],[h,u,[f,m]],[/android.+[;\/]\s*TU_(1491)\s+build/i],[u,[h,"Rotor"],[f,m]],[/android.+(KS(.+))\s+build/i],[u,[h,"Amazon"],[f,m]],[/android.+(Gigaset)[\s\-]+(Q\w{1,9})\s+build/i],[h,u,[f,m]],[/\s(tablet|tab)[;\/]/i,/\s(mobile)(?:[;\/]|\ssafari)/i],[[f,w.lowerize],h,u],[/[\s\/\(](smart-?tv)[;\)]/i],[[f,b]],[/(android[\w\.\s\-]{0,9});.+build/i],[u,[h,"Generic"]]],engine:[[/windows.+\sedge\/([\w\.]+)/i],[p,[l,"EdgeHTML"]],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[p,[l,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna)\/([\w\.]+)/i,/(khtml|tasman|links)[\/\s]\(?([\w\.]+)/i,/(icab)[\/\s]([23]\.[\d\.]+)/i],[l,p],[/rv\:([\w\.]{1,9}).+(gecko)/i],[p,l]],os:[[/microsoft\s(windows)\s(vista|xp)/i],[l,p],[/(windows)\snt\s6\.2;\s(arm)/i,/(windows\sphone(?:\sos)*)[\s\/]?([\d\.\s\w]*)/i,/(windows\smobile|windows)[\s\/]?([ntce\d\.\s]+\w)/i],[l,[p,C.str,A.os.windows.version]],[/(win(?=3|9|n)|win\s9x\s)([nt\d\.]+)/i],[[l,"Windows"],[p,C.str,A.os.windows.version]],[/\((bb)(10);/i],[[l,"BlackBerry"],p],[/(blackberry)\w*\/?([\w\.]*)/i,/(tizen|kaios)[\/\s]([\w\.]+)/i,/(android|webos|palm\sos|qnx|bada|rim\stablet\sos|meego|sailfish|contiki)[\/\s-]?([\w\.]*)/i],[l,p],[/(symbian\s?os|symbos|s60(?=;))[\/\s-]?([\w\.]*)/i],[[l,"Symbian"],p],[/\((series40);/i],[l],[/mozilla.+\(mobile;.+gecko.+firefox/i],[[l,"Firefox OS"],p],[/(nintendo|playstation)\s([wids34portablevu]+)/i,/(mint)[\/\s\(]?(\w*)/i,/(mageia|vectorlinux)[;\s]/i,/(joli|[kxln]?ubuntu|debian|suse|opensuse|gentoo|(?=\s)arch|slackware|fedora|mandriva|centos|pclinuxos|redhat|zenwalk|linpus)[\/\s-]?(?!chrom)([\w\.-]*)/i,/(hurd|linux)\s?([\w\.]*)/i,/(gnu)\s?([\w\.]*)/i],[l,p],[/(cros)\s[\w]+\s([\w\.]+\w)/i],[[l,"Chromium OS"],p],[/(sunos)\s?([\w\.\d]*)/i],[[l,"Solaris"],p],[/\s([frentopc-]{0,4}bsd|dragonfly)\s?([\w\.]*)/i],[l,p],[/(haiku)\s(\w+)/i],[l,p],[/cfnetwork\/.+darwin/i,/ip[honead]{2,4}(?:.*os\s([\w]+)\slike\smac|;\sopera)/i],[[p,/_/g,"."],[l,"iOS"]],[/(mac\sos\sx)\s?([\w\s\.]*)/i,/(macintosh|mac(?=_powerpc)\s)/i],[[l,"Mac OS"],[p,/_/g,"."]],[/((?:open)?solaris)[\/\s-]?([\w\.]*)/i,/(aix)\s((\d)(?=\.|\)|\s)[\w\.])*/i,/(plan\s9|minix|beos|os\/2|amigaos|morphos|risc\sos|openvms|fuchsia)/i,/(unix)\s?([\w\.]*)/i],[l,p]]},E=function(e,t){if("object"==typeof e&&(t=e,e=i),!(this instanceof E))return new E(e,t).getResult();var n=e||(o&&o.navigator&&o.navigator.userAgent?o.navigator.userAgent:""),r=t?w.extend(k,t):k;return this.getBrowser=function(){var e={name:i,version:i};return C.rgx.call(e,n,r.browser),e.major=w.major(e.version),e},this.getCPU=function(){var e={architecture:i};return C.rgx.call(e,n,r.cpu),e},this.getDevice=function(){var e={vendor:i,model:i,type:i};return C.rgx.call(e,n,r.device),e},this.getEngine=function(){var e={name:i,version:i};return C.rgx.call(e,n,r.engine),e},this.getOS=function(){var e={name:i,version:i};return C.rgx.call(e,n,r.os),e},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 n},this.setUA=function(e){return n=e,this},this};E.VERSION="0.7.22",E.BROWSER={NAME:l,MAJOR:"major",VERSION:p},E.CPU={ARCHITECTURE:d},E.DEVICE={MODEL:u,VENDOR:h,TYPE:f,CONSOLE:g,MOBILE:y,SMARTTV:b,TABLET:m,WEARABLE:v,EMBEDDED:"embedded"},E.ENGINE={NAME:l,VERSION:p},E.OS={NAME:l,VERSION:p},typeof t!==a?(typeof e!==a&&e.exports&&(t=e.exports=E),t.UAParser=E):(r=function(){return E}.call(t,n,t,e))===i||(e.exports=r);var B=o&&(o.jQuery||o.Zepto);if(B&&!B.ua){var S=new E;B.ua=S.getResult(),B.ua.get=function(){return S.getUA()},B.ua.set=function(e){S.setUA(e);var t=S.getResult();for(var n in t)B.ua[n]=t[n]}}}("object"==typeof window?window:this)},function(e,t,n){(function(r){t.formatArgs=function(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const n="color: "+this.color;t.splice(1,0,n,"color: inherit");let r=0,o=0;t[0].replace(/%[a-zA-Z%]/g,(e=>{"%%"!==e&&(r++,"%c"===e&&(o=r))})),t.splice(o,0,n)},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}},t.load=function(){let e;try{e=t.storage.getItem("debug")}catch(e){}!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG);return e},t.useColors=function(){if("undefined"!=typeof window&&window.process&&("renderer"===window.process.type||window.process.__nwjs))return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage=function(){try{return localStorage}catch(e){}}(),t.destroy=(()=>{let e=!1;return()=>{e||(e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.log=console.debug||console.log||(()=>{}),e.exports=n(62)(t);const{formatters:o}=e.exports;o.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}}).call(this,n(3))},function(e,t,n){e.exports=function(e){function t(e){let n,o=null;function i(...e){if(!i.enabled)return;const r=i,o=Number(new Date),s=o-(n||o);r.diff=s,r.prev=n,r.curr=o,n=o,e[0]=t.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let a=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,((n,o)=>{if("%%"===n)return"%";a++;const i=t.formatters[o];if("function"==typeof i){const t=e[a];n=i.call(r,t),e.splice(a,1),a--}return n})),t.formatArgs.call(r,e);(r.log||t.log).apply(r,e)}return i.namespace=e,i.useColors=t.useColors(),i.color=t.selectColor(e),i.extend=r,i.destroy=t.destroy,Object.defineProperty(i,"enabled",{enumerable:!0,configurable:!1,get:()=>null===o?t.enabled(e):o,set:e=>{o=e}}),"function"==typeof t.init&&t.init(i),i}function r(e,n){const r=t(this.namespace+(void 0===n?":":n)+e);return r.log=this.log,r}function o(e){return e.toString().substring(2,e.toString().length-2).replace(/\.\*\?$/,"*")}return t.debug=t,t.default=t,t.coerce=function(e){if(e instanceof Error)return e.stack||e.message;return e},t.disable=function(){const e=[...t.names.map(o),...t.skips.map(o).map((e=>"-"+e))].join(",");return t.enable(""),e},t.enable=function(e){let n;t.save(e),t.names=[],t.skips=[];const r=("string"==typeof e?e:"").split(/[\s,]+/),o=r.length;for(n=0;n<o;n++)r[n]&&("-"===(e=r[n].replace(/\*/g,".*?"))[0]?t.skips.push(new RegExp("^"+e.substr(1)+"$")):t.names.push(new RegExp("^"+e+"$")))},t.enabled=function(e){if("*"===e[e.length-1])return!0;let n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1},t.humanize=n(7),t.destroy=function(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")},Object.keys(e).forEach((n=>{t[n]=e[n]})),t.names=[],t.skips=[],t.formatters={},t.selectColor=function(e){let n=0;for(let t=0;t<e.length;t++)n=(n<<5)-n+e.charCodeAt(t),n|=0;return t.colors[Math.abs(n)%t.colors.length]},t.enable(t.load()),t}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Worker=void 0;var r,o=n(16),i=n(31),s=n(15);function a(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var c=new(((r=n(0))&&r.__esModule?r:{default:r}).default)("worker.js"),u=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.workerId_=t,this.clientId_=o.WorkerManager.getInstance().getId(),this.deviceName_=(0,s.getDeviceName)(),this.peerConnection_=null,this.dataChannel_=null,this.isConnected_=!1,this.runningJobs_=new Map,this.pendingJobs_=new Map,this.gumStream_=null,this.gumCapabilities_=null,this.gumSettings_=null,this.applyConstraintsResolve_=null,this.applyConstraintsReject_=null,this.setUpPeerConnection_()}var t,n,r;return t=e,(n=[{key:"setUpPeerConnection_",value:function(){var e=this;this.peerConnection_=new RTCPeerConnection,this.peerConnection_.onicecandidate=this.handleIceCandidateEvent_.bind(this),this.peerConnection_.ontrack=this.handleTrackEvent_.bind(this),this.dataChannel_=this.peerConnection_.createDataChannel("offload"),this.dataChannel_.onopen=this.handleDataChannelOpenEvent_.bind(this),this.dataChannel_.onclose=this.handleDataChannelCloseEvent_.bind(this),this.dataChannel_.onmessage=this.handleDataChannelMessageEvent_.bind(this),this.peerConnection_.createOffer().then((function(t){return e.peerConnection_.setLocalDescription(t)})).then((function(){c.debug("send offer"),e.sendSignalMessage_(e.peerConnection_.localDescription)})).catch((function(e){return c.error("reason: "+e.toString())}))}},{key:"handleIceCandidateEvent_",value:function(e){e.candidate&&(c.debug("send candidate"),this.sendSignalMessage_({type:"candidate",candidate:e.candidate}))}},{key:"handleTrackEvent_",value:function(e){c.debug("got track"),this.gumStream_=e.streams[0];var t=null;this.gumStream_.getVideoTracks().length>0?(this.updateMediaStreamTrack_(this.gumStream_.getVideoTracks()[0]),t=this.getRunningJob_("CAMERA")):this.gumStream_.getAudioTracks().length>0&&(t=this.getRunningJob_("MIC")),t&&(c.timeEnd("job complete"),t.successCallback(this.gumStream_))}},{key:"updateMediaStreamTrack_",value:function(e){var t=this;e.getCapabilities=function(){return t.gumCapabilities_},e.getSettings=function(){return t.gumSettings_},e.applyConstraints=function(e){return new Promise((function(n,r){t.applyConstraintsResolve_=n,t.applyConstraintsReject_=r,t.sendPeerMessage_({type:"applyConstraints",feature:"CAMERA",constraints:e})}))}}},{key:"handleDataChannelOpenEvent_",value:function(){var e=this;c.debug("data channel opened"),this.isConnected_=!0,this.pendingJobs_.forEach((function(t){return e.startJob(t)})),this.pendingJobs_.clear()}},{key:"handleDataChannelCloseEvent_",value:function(){c.debug("data channel closed"),this.isConnected_=!1,this.dataChannel_=null,this.closePeerConnection_()}},{key:"closePeerConnection_",value:function(){this.peerConnection_&&(this.peerConnection_.onicecandidate=null,this.peerConnection_.ontrack=null,this.peerConnection_.close(),this.peerConnection_=null)}},{key:"handleDataChannelMessageEvent_",value:function(e){var t=JSON.parse(e.data),n=this.getRunningJob_(t.feature);if(null!==n)switch(t.type){case"data":"CAMERA"===t.feature?(this.gumCapabilities_=t.data.capabilities,this.gumSettings_=t.data.settings):"COMPUTE"===t.feature?(0,i.computeResultObtained)(t,this.workerId_):(c.timeEnd("job complete"),n.successCallback(t.data));break;case"error":n.errorCallback(new DOMException(t.error.message,t.error.name)),this.stopJob(t.feature);break;case"applyConstraints":"success"===t.result?(this.gumSettings_=t.resultSettings,this.applyConstraintsResolve_()):this.applyConstraintsReject_(new DOMException(t.error.message,t.error.name));break;default:c.debug("unsupported message type",t.type)}else c.error("no job related to feature",t.feature)}},{key:"getRunningJob_",value:function(e){return this.runningJobs_.has(e)?this.runningJobs_.get(e):null}},{key:"sendSignalMessage_",value:function(e){var t=o.WorkerManager.getInstance();t&&t.sendMessage(this.workerId_,e)}},{key:"sendPeerMessage_",value:function(e){this.isConnected_?this.dataChannel_.send(JSON.stringify(e)):c.error("data channel is not connected")}},{key:"startJob",value:function(e){c.debug("startJob",this.workerId_,e.feature),this.isConnected_?(this.sendPeerMessage_({type:"start",feature:e.feature,arguments:e.arguments,clientId:this.clientId_,deviceName:this.deviceName_}),this.runningJobs_.set(e.feature,e)):this.pendingJobs_.set(e.feature,e)}},{key:"stopJob",value:function(e){c.debug("stopJob",this.workerId_,e),this.runningJobs_.has(e)?(this.sendPeerMessage_({type:"stop",feature:e}),this.runningJobs_.delete(e)):this.pendingJobs_.has(e)&&this.pendingJobs_.delete(e)}},{key:"handleMessage",value:function(e){"offer"===e.type?this.handleOffer_(e):"answer"===e.type?this.handleAnswer_(e):"candidate"===e.type&&this.handleCandidate_(e.candidate)}},{key:"handleOffer_",value:function(e){var t=this;c.debug("got offer"),this.peerConnection_.setRemoteDescription(e).then((function(){return t.peerConnection_.createAnswer()})).then((function(e){return t.peerConnection_.setLocalDescription(e)})).then((function(){c.debug("send answer"),t.sendSignalMessage_(t.peerConnection_.localDescription)})).catch((function(e){return c.error("reason: "+e.toString())}))}},{key:"handleAnswer_",value:function(e){c.debug("got answer"),this.peerConnection_.setRemoteDescription(e).catch((function(e){return c.error("reason: "+e.toString())}))}},{key:"handleCandidate_",value:function(e){c.debug("got candidate"),this.peerConnection_.addIceCandidate(e).catch((function(e){return c.error("reason: "+e.toString())}))}}])&&a(t.prototype,n),r&&a(t,r),e}();t.Worker=u},function(e,t,n){e.exports=n(65)},function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.Offload=void 0;var o=c(n(31)),i=c(n(68)),s=n(29);function a(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return a=function(){return e},e}function c(e){if(e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var t=a();if(t&&t.has(e))return t.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)){var s=o?Object.getOwnPropertyDescriptor(e,i):null;s&&(s.get||s.set)?Object.defineProperty(n,i,s):n[i]=e[i]}return n.default=e,t&&t.set(e,n),n}function u(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var l=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.resources=[];for(var t=0,n=Object.values(i);t<n.length;t++){var r=n[t];this.resources.push(new r)}}var t,n,r;return t=e,(n=[{key:"connect",value:function(e){return s.WorkerManager.getInstance().connect(e)}},{key:"loadConfig",value:function(e){o.loadConfigurationFrom(e)}}])&&u(t.prototype,n),r&&u(t,r),e}();t.Offload=l;var f=new l;t.default=f},function(e,t,n){"use strict";var r;function o(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=new(((r=n(0))&&r.__esModule?r:{default:r}).default)("OffloadIDAndPromiseMap.js"),s=new(function(){function e(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),e.instance||(this._data={offloadId:{deps:[],promise:null,resolver:null}},e.instance=this),e.instance}var t,n,r;return t=e,(n=[{key:"set",value:function(e,t){i.debug("Setting Value: "+JSON.stringify(t)+" to key: "+e),this._data[e]=t}},{key:"setPromise",value:function(e,t){i.debug("Setting promise: "+JSON.stringify(t)+" to key: "+e);var n=this._data[e];n?n.promise=t:this._data[e]={promise:t,deps:[],resolver:null}}},{key:"setDependencies",value:function(e,t){i.debug("Setting Dependencies: "+JSON.stringify(t)+" to key: "+e);var n=this._data[e];n?n.deps=t:this._data[e]={promise:null,deps:t,resolver:null}}},{key:"setResolver",value:function(e,t){i.debug("Setting Resolver: "+JSON.stringify(t)+" to key: "+e);var n=this.get(e);n?n.resolver=t:this._data[e]={promise:null,deps:[],resolver:t}}},{key:"get",value:function(e){if(i.debug("Getting data for key: "+e),this._data.hasOwnProperty(e))return this._data[e]}},{key:"viewData",value:function(){i.debug("Getting data : "),i.table(this._data)}},{key:"getPromise",value:function(e){i.debug("Getting promise for key: "+e);var t=this._data[e];if(t)return t.promise}},{key:"getDependencies",value:function(e){i.debug("Getting dependencies for key: "+e);var t=this._data[e];return t?t.deps:[]}},{key:"getResolver",value:function(e){i.debug("Getting Resolver for key: "+e);var t=this._data[e];if(t)return t.resolver}}])&&o(t.prototype,n),r&&o(t,r),e}());Object.freeze(s);var a=s;t.default=a},function(e,t,n){"use strict";var r,o,i,s;function a(e){return(a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}s=function(){return function e(t,n,r){function o(s,a){if(!n[s]){if(!t[s]){if(i)return i(s,!0);var c=new Error("Cannot find module '"+s+"'");throw c.code="MODULE_NOT_FOUND",c}var u=n[s]={exports:{}};t[s][0].call(u.exports,(function(e){return o(t[s][1][e]||e)}),u,u.exports,e,t,n,r)}return n[s].exports}for(var i=!1,s=0;s<r.length;s++)o(r[s]);return o}({1:[function(e,t,n){var r=Math.floor(1099511627776*Math.random()).toString(16),o=new RegExp('"@__(F|R|D|M|S|U|I)-'+r+'-(\\d+)__@"',"g"),i=/\{\s*\[native code\]\s*\}/g,s=/function.*?\(/,c=/.*?=>.*?/,u=/[<>\/\u2028\u2029]/g,l=["*","async"],f={"<":"\\u003C",">":"\\u003E","/":"\\u002F","\u2028":"\\u2028","\u2029":"\\u2029"};function h(e){return f[e]}t.exports=function e(t,n){n||(n={}),"number"!=typeof n&&"string"!=typeof n||(n={space:n});var f,p=[],d=[],g=[],y=[],m=[],b=[],v=[];return n.ignoreFunction&&"function"==typeof t&&(t=void 0),void 0===t?String(t):"string"!=typeof(f=n.isJSON&&!n.space?JSON.stringify(t):JSON.stringify(t,n.isJSON?null:function(e,t){if(n.ignoreFunction&&function(e){var t=[];for(var n in e)"function"==typeof e[n]&&t.push(n);for(var r=0;r<t.length;r++)delete e[t[r]]}(t),!t&&void 0!==t)return t;var o=this[e],i=a(o);if("object"===i){if(o instanceof RegExp)return"@__R-"+r+"-"+(d.push(o)-1)+"__@";if(o instanceof Date)return"@__D-"+r+"-"+(g.push(o)-1)+"__@";if(o instanceof Map)return"@__M-"+r+"-"+(y.push(o)-1)+"__@";if(o instanceof Set)return"@__S-"+r+"-"+(m.push(o)-1)+"__@"}return"function"===i?"@__F-"+r+"-"+(p.push(o)-1)+"__@":"undefined"===i?"@__U-"+r+"-"+(b.push(o)-1)+"__@":"number"!==i||isNaN(o)||isFinite(o)?t:"@__I-"+r+"-"+(v.push(o)-1)+"__@"},n.space))?String(f):(!0!==n.unsafe&&(f=f.replace(u,h)),0===p.length&&0===d.length&&0===g.length&&0===y.length&&0===m.length&&0===b.length&&0===v.length?f:f.replace(o,(function(t,r,o){return"D"===r?'new Date("'+g[o].toISOString()+'")':"R"===r?"new RegExp("+e(d[o].source)+', "'+d[o].flags+'")':"M"===r?"new Map("+e(Array.from(y[o].entries()),n)+")":"S"===r?"new Set("+e(Array.from(m[o].values()),n)+")":"U"===r?"undefined":"I"===r?v[o]:function(e){var t=e.toString();if(i.test(t))throw new TypeError("Serializing native function: "+e.name);if(s.test(t))return t;if(c.test(t))return t;var n=t.indexOf("("),r=t.substr(0,n).trim().split(" ").filter((function(e){return e.length>0}));return r.filter((function(e){return-1===l.indexOf(e)})).length>0?(r.indexOf("async")>-1?"async ":"")+"function"+(r.join("").indexOf("*")>-1?"*":"")+t.substr(n):t}(p[o])})))}},{}]},{},[1])(1)},"object"===a(t)&&void 0!==e?e.exports=s():(o=[],void 0===(i="function"==typeof(r=s)?r.apply(t,o):r)||(e.exports=i))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"GUMResource",{enumerable:!0,get:function(){return r.GUMResource}}),Object.defineProperty(t,"HAMResource",{enumerable:!0,get:function(){return o.HAMResource}}),Object.defineProperty(t,"GYROResource",{enumerable:!0,get:function(){return i.GYROResource}});var r=n(69),o=n(80),i=n(81)},function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.GUMResource=void 0;var o,i=n(29);function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function a(e,t){return(a=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function c(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=l(e);if(t){var o=l(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return u(this,n)}}function u(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function l(e){return(l=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var f=new(((o=n(0))&&o.__esModule?o:{default:o}).default)("gum.js"),h=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&a(e,t)}(u,e);var t,n,r,o=c(u);function u(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,u),(e=o.call(this))._hasLocalVideoInput=!1,e._hasLocalAudioInput=!1,e._nativeEnumerateDevices=null,e._nativeGetUserMedia=null,e._nativeGetUserMediaDeprecated=null;try{e.installOffloadGUM()}catch(e){f.error(e)}return e}return t=u,(n=[{key:"checkIfLocalUserMediaExists",value:function(){var e=this;return new Promise((function(t,n){e._nativeEnumerateDevices().then((function(n){n.forEach((function(t){switch(t.kind){case"videoinput":e._hasLocalVideoInput=!0;break;case"audioinput":e._hasLocalAudioInput=!0;break;case"audiooutput":break;default:f.error("Unknown device kind.")}})),t()})).catch((function(e){n(e)}))}))}},{key:"checkConstraintsType",value:function(e){return void 0!==e.video&&!1!==e.video?"CAMERA":void 0!==e.audio&&!1!==e.audio?"MIC":"NONE"}},{key:"checkLocalGumIsCallable",value:function(e){var t=this;return new Promise((function(n,r){try{void 0!==e.video&&!1!==e.video&&!1===t._hasLocalVideoInput&&n(!1),void 0!==e.audio&&!1!==e.audio&&!1===t._hasLocalAudioInput&&n(!1),n(!0)}catch(e){r(e)}}))}},{key:"printErrorMessage",value:function(e){f.error(e.name+": "+e.message)}},{key:"getUserMediaDeprecated",value:function(){for(var e=this,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var o=[].slice.call(n),i=o[0]||{},s=o[1],a=o[2],c=this.checkConstraintsType(i);"NONE"!==c?this.checkIfLocalUserMediaExists().then((function(){e.checkLocalGumIsCallable(i).then((function(t){e.startJob({feature:c,arguments:[i],successCallback:s,errorCallback:a,localGumIsCallable:t,nativeGetUserMedia:e._nativeGetUserMedia})})).catch((function(t){return e.printErrorMessage(t)}))})).catch((function(t){return e.printErrorMessage(t)})):a(new TypeError("The list of constraints specified is empty, or has all constraints set to false."))}},{key:"getUserMedia",value:function(){for(var e=this,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var o=[].slice.call(n),i=o[0]||{},s=this.checkConstraintsType(i);return new Promise((function(t,n){"NONE"!==s?e.checkIfLocalUserMediaExists().then((function(){e.checkLocalGumIsCallable(i).then((function(r){e.startJob({feature:s,arguments:[i],successCallback:t,errorCallback:n,localGumIsCallable:r,nativeGetUserMedia:e._nativeGetUserMedia})})).catch((function(t){return e.printErrorMessage(t)}))})).catch((function(t){return e.printErrorMessage(t)})):n(new TypeError("The list of constraints specified is empty, or has all constraints set to false."))}))}},{key:"checkAndAddRemoteMediaDeviceInfos",value:function(e,t,n){try{var r=i.WorkerManager.getInstance(),o=null;if(r&&(o=r.getWorkerInfos()),!r||!o||!o.size&&this.checkAndAddRemoteMediaDeviceInfos.elapsedTime<3e3)return setTimeout(this.checkAndAddRemoteMediaDeviceInfos.bind(this),500,e,t,n),void(this.checkAndAddRemoteMediaDeviceInfos.elapsedTime+=500);o.forEach((function(t,n,r){t.mediaDeviceInfos.forEach((function(t){e.push(t)}))})),t(e)}catch(e){n(e)}}},{key:"installOffloadGUM",value:function(){var e=this;f.debug("getUserMedia for video is not usable on this device. Start using offload getUserMedia instead."),this._nativeGetUserMediaDeprecated=navigator.getUserMedia.bind(navigator),this._nativeGetUserMedia=navigator.mediaDevices.getUserMedia.bind(navigator.mediaDevices),navigator.getUserMedia=this.getUserMediaDeprecated.bind(this),navigator.mediaDevices.getUserMedia=this.getUserMedia.bind(this),this._nativeEnumerateDevices=navigator.mediaDevices.enumerateDevices.bind(navigator.mediaDevices),navigator.mediaDevices.enumerateDevices=function(){return new Promise((function(t,n){e._nativeEnumerateDevices().then((function(r){e.checkAndAddRemoteMediaDeviceInfos.call(e,r,t,n)})).catch((function(e){n(e)}))}))}}}])&&s(t.prototype,n),r&&s(t,r),u}(i.Resource);t.GUMResource=h},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Resource=void 0;var r,o=n(71),i=n(16);function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var a=new(((r=n(0))&&r.__esModule?r:{default:r}).default)("resource.js"),c=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.worker_=null,this.alwaysConnect_=null}var t,n,r;return t=e,(n=[{key:"checkCapability",value:function(){}},{key:"startJob",value:function(e){var t=this;if(this.alwaysConnect_)this.startJobImpl(this.alwaysConnect_,e);else{var n=e.feature,r=e.localGumIsCallable;this.showResourcePopup(n,r).then((function(n){t.alwaysConnect_=n.always?n.workerId:null,t.startJobImpl(n.workerId,e)})).catch((function(t){a.error(t),e.errorCallback&&e.errorCallback(t)}))}}},{key:"startJobImpl",value:function(e,t){var n=this;"localdevice"!==this.alwaysConnect_&&"localdevice"!==e?this.requestService(e).then((function(){var r=i.WorkerManager.getInstance();n.worker_=r.getOrCreateWorker(e),a.time("job complete"),n.worker_.startJob(t)})).catch((function(e){a.error(TAG+e),t.errorCallback&&t.errorCallback(e)})):t.nativeGetUserMedia(t.arguments[0]).then(t.successCallback).catch(t.errorCallback)}},{key:"startJobWithExistingWorker",value:function(e){this.worker_&&this.worker_.startJob(e)}},{key:"stopJob",value:function(e){this.worker_&&(this.worker_.stopJob(e),this.worker_=null)}},{key:"showResourcePopup",value:function(e,t){return new Promise((function(n,r){(0,o.showPopup)({feature:e,successCallback:n,errorCallback:r,localGumIsCallable:t})}))}},{key:"requestService",value:function(e){return new Promise((function(t,n){i.WorkerManager.getInstance().requestService(e,{successCallback:t,errorCallback:n})}))}}])&&s(t.prototype,n),r&&s(t,r),e}();t.Resource=c},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.showPopup=function(e){o.default.use();var t=document.getElementById("popup");t||((t=document.createElement("div")).classList.add("modal"),t.id="popup",t.classList.add("overlay"),t.setAttribute("tabindex","-1"),t.setAttribute("role","dialog"),document.body.appendChild(t));(0,i.showDevicePopup)(t,e)};var r,o=(r=n(72))&&r.__esModule?r:{default:r},i=n(76)},function(e,t,n){var r=n(73),o=n(74);"string"==typeof(o=o.__esModule?o.default:o)&&(o=[[e.i,o,""]]);var i,s=0,a={injectType:"lazyStyleTag",insert:"head",singleton:!1},c={};c.locals=o.locals||{},c.use=function(){return s++||(i=r(o,a)),c},c.unuse=function(){s>0&&!--s&&(i(),i=null)},e.exports=c},function(e,t,n){"use strict";var r,o=function(){return void 0===r&&(r=Boolean(window&&document&&document.all&&!window.atob)),r},i=function(){var e={};return function(t){if(void 0===e[t]){var n=document.querySelector(t);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}e[t]=n}return e[t]}}(),s=[];function a(e){for(var t=-1,n=0;n<s.length;n++)if(s[n].identifier===e){t=n;break}return t}function c(e,t){for(var n={},r=[],o=0;o<e.length;o++){var i=e[o],c=t.base?i[0]+t.base:i[0],u=n[c]||0,l="".concat(c," ").concat(u);n[c]=u+1;var f=a(l),h={css:i[1],media:i[2],sourceMap:i[3]};-1!==f?(s[f].references++,s[f].updater(h)):s.push({identifier:l,updater:y(h,t),references:1}),r.push(l)}return r}function u(e){var t=document.createElement("style"),r=e.attributes||{};if(void 0===r.nonce){var o=n.nc;o&&(r.nonce=o)}if(Object.keys(r).forEach((function(e){t.setAttribute(e,r[e])})),"function"==typeof e.insert)e.insert(t);else{var s=i(e.insert||"head");if(!s)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");s.appendChild(t)}return t}var l,f=(l=[],function(e,t){return l[e]=t,l.filter(Boolean).join("\n")});function h(e,t,n,r){var o=n?"":r.media?"@media ".concat(r.media," {").concat(r.css,"}"):r.css;if(e.styleSheet)e.styleSheet.cssText=f(t,o);else{var i=document.createTextNode(o),s=e.childNodes;s[t]&&e.removeChild(s[t]),s.length?e.insertBefore(i,s[t]):e.appendChild(i)}}function p(e,t,n){var r=n.css,o=n.media,i=n.sourceMap;if(o?e.setAttribute("media",o):e.removeAttribute("media"),i&&btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(i))))," */")),e.styleSheet)e.styleSheet.cssText=r;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(r))}}var d=null,g=0;function y(e,t){var n,r,o;if(t.singleton){var i=g++;n=d||(d=u(t)),r=h.bind(null,n,i,!1),o=h.bind(null,n,i,!0)}else n=u(t),r=p.bind(null,n,t),o=function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(n)};return r(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap)return;r(e=t)}else o()}}e.exports=function(e,t){(t=t||{}).singleton||"boolean"==typeof t.singleton||(t.singleton=o());var n=c(e=e||[],t);return function(e){if(e=e||[],"[object Array]"===Object.prototype.toString.call(e)){for(var r=0;r<n.length;r++){var o=a(n[r]);s[o].references--}for(var i=c(e,t),u=0;u<n.length;u++){var l=a(n[u]);0===s[l].references&&(s[l].updater(),s.splice(l,1))}n=i}}}},function(e,t,n){(t=n(75)(!1)).push([e.i,".modal {\n  position: fixed;\n  top: 0;\n  left: 0;\n  z-index: 1000;\n  width: 100%;\n  height: 100%;\n  outline: 0;\n  display: none;\n}\n\n.overlay {\n  position: fixed;\n  top: 0;\n  bottom: 0;\n  left: 0;\n  right: 0;\n  background: rgba(0, 0, 0, 0.7);\n  visibility: visible;\n  opacity: 1;\n}\n\n.modal.show {\n  background: rgba(0, 0, 0, 0.7);\n  opacity: 1;\n  display: block;\n}\n\n.modal-open {\n  overflow: hidden;\n}\n\n.modal-open .modal {\n  overflow-x: hidden;\n  overflow-y: auto;\n}\n\n.modal-dialog {\n  position: relative;\n  width: auto;\n}\n\n@media (min-width: 576px) {\n  .modal-dialog {\n    max-width: 500px;\n    margin: 1.75rem auto;\n  }\n}\n\n.modal-content {\n  position: relative;\n  display: flex;\n  flex-direction: column;\n  width: 100%;\n  pointer-events: auto;\n  background-color: #fff;\n  background-clip: padding-box;\n  border: 1px solid rgba(0, 0, 0, 0.2);\n  border-radius: 0.3rem;\n  color: #000;\n  outline: 0;\n}\n\n.modal-header {\n  display: flex;\n  align-items: flex-start;\n  justify-content: space-between;\n  padding: 1rem 1rem;\n  border-bottom: 1px solid #dee2e6;\n  border-top-left-radius: 0.3rem;\n  border-top-right-radius: 0.3rem;\n}\n\n.modal-header img {\n  margin-left: 5px;\n}\n\n.modal-title {\n  color: #007bff;\n  font-weight: 900;\n}\n\n.modal-body {\n  position: relative;\n  flex: 1 1 auto;\n  padding: 1rem;\n  border-radius: 0.3rem;\n}\n\n.form-check-input:focus {\n  box-shadow: 0 0 0 0.2rem black;\n}\n\n.modal-footer {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  justify-content: center;\n  padding: 0.75rem;\n  border-top: 1px solid #dee2e6;\n  border-bottom-left-radius: 0.3rem;\n  border-bottom-right-radius: 0.3rem;\n}\n\n.modal-footer > * {\n  margin: 0.25rem;\n}\n\n.modal-footer > .btn {\n  display: inline-block;\n  font-weight: 400;\n  text-align: center;\n  vertical-align: middle;\n  user-select: none;\n  border: 1px solid transparent;\n  padding: 0.375rem 0.75rem;\n  font-size: 1rem;\n  line-height: 1.5;\n  border-radius: 0.25rem;\n}\n\n.modal-footer > .btn:focus {\n  box-shadow: 0 0 0 0.3rem black;\n}\n\n.modal-footer > .btn.btn-primary {\n  color: #fff;\n  background-color: #007bff;\n  border-color: #007bff;\n}\n\n.modal-footer > .btn.btn-secondary {\n  color: #fff;\n  background-color: #6c757d;\n  border-color: #6c757d;\n}\n\n.modal-footer > .btn.btn-success {\n  color: #fff;\n  background-color: #28a745;\n  border-color: #28a745;\n}\n\n.mr-auto {\n  margin-right: auto !important;\n}\n\n.progress-circular {\n  -webkit-appearance: none;\n  -moz-appearance: none;\n  appearance: none;\n  box-sizing: border-box;\n  border: none;\n  border-radius: 50%;\n  padding: 0;\n  width: 2em;\n  height: 2em;\n  color: rgb(var(--primary-rgb, 33, 150, 243));\n  background-color: transparent;\n  font-size: 16px;\n  overflow: hidden;\n}\n\n.progress-circular::-webkit-progress-bar {\n  background-color: transparent;\n}\n\n/* Indeterminate */\n.progress-circular:indeterminate {\n  -webkit-mask-image: linear-gradient(transparent 50%, black 50%),\n    linear-gradient(to right, transparent 50%, black 50%);\n  mask-image: linear-gradient(transparent 50%, black 50%),\n    linear-gradient(to right, transparent 50%, black 50%);\n  animation: progress-circular 6s infinite cubic-bezier(0.3, 0.6, 1, 1);\n}\n\n:-ms-lang(x),\n.progress-circular:indeterminate {\n  animation: none;\n}\n\n.progress-circular:indeterminate::before,\n.progress-circular:indeterminate::-webkit-progress-value {\n  content: '';\n  display: block;\n  box-sizing: border-box;\n  margin-bottom: 0.25em;\n  border: solid 0.25em transparent;\n  border-top-color: currentColor;\n  border-radius: 50%;\n  width: 100% !important;\n  height: 100%;\n  background-color: transparent;\n  animation: progress-circular-pseudo 0.75s infinite linear alternate;\n}\n\n.progress-circular:indeterminate::-moz-progress-bar {\n  box-sizing: border-box;\n  border: solid 0.25em transparent;\n  border-top-color: currentColor;\n  border-radius: 50%;\n  width: 100%;\n  height: 100%;\n  background-color: transparent;\n  animation: progress-circular-pseudo 0.75s infinite linear alternate;\n}\n\n.progress-circular:indeterminate::-ms-fill {\n  animation-name: -ms-ring;\n}\n\n@keyframes progress-circular {\n  0% {\n    transform: rotate(0deg);\n  }\n  12.5% {\n    transform: rotate(180deg);\n    animation-timing-function: linear;\n  }\n  25% {\n    transform: rotate(630deg);\n  }\n  37.5% {\n    transform: rotate(810deg);\n    animation-timing-function: linear;\n  }\n  50% {\n    transform: rotate(1260deg);\n  }\n  62.5% {\n    transform: rotate(1440deg);\n    animation-timing-function: linear;\n  }\n  75% {\n    transform: rotate(1890deg);\n  }\n  87.5% {\n    transform: rotate(2070deg);\n    animation-timing-function: linear;\n  }\n  100% {\n    transform: rotate(2520deg);\n  }\n}\n\n@keyframes progress-circular-pseudo {\n  0% {\n    transform: rotate(-30deg);\n  }\n  29.4% {\n    border-left-color: transparent;\n  }\n  29.41% {\n    border-left-color: currentColor;\n  }\n  64.7% {\n    border-bottom-color: transparent;\n  }\n  64.71% {\n    border-bottom-color: currentColor;\n  }\n  100% {\n    border-left-color: currentColor;\n    border-bottom-color: currentColor;\n    transform: rotate(225deg);\n  }\n}\n\n.row-container {\n  display: flex;\n  justify-content: space-between;\n}\n\n.vertical-align-center {\n  display: flex;\n  flex-direction: column;\n  align-items: center;\n}\n",""]),e.exports=t},function(e,t,n){"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n=function(e,t){var n=e[1]||"",r=e[3];if(!r)return n;if(t&&"function"==typeof btoa){var o=(s=r,a=btoa(unescape(encodeURIComponent(JSON.stringify(s)))),c="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(a),"/*# ".concat(c," */")),i=r.sources.map((function(e){return"/*# sourceURL=".concat(r.sourceRoot||"").concat(e," */")}));return[n].concat(i).concat([o]).join("\n")}var s,a,c;return[n].join("\n")}(t,e);return t[2]?"@media ".concat(t[2]," {").concat(n,"}"):n})).join("")},t.i=function(e,n,r){"string"==typeof e&&(e=[[null,e,""]]);var o={};if(r)for(var i=0;i<this.length;i++){var s=this[i][0];null!=s&&(o[s]=!0)}for(var a=0;a<e.length;a++){var c=[].concat(e[a]);r&&o[c[0]]||(n&&(c[2]?c[2]="".concat(n," and ").concat(c[2]):c[2]=n),t.push(c))}},t}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.showDevicePopup=function(e,t){e.innerHTML=(n=t.feature,o=t.localGumIsCallable,'\n    <div class="modal-dialog" role="document">\n      <div class="modal-content">\n        <div class="modal-header">\n          <span class="modal-title mr-auto">Available devices</span>\n          <img width="24" src="'.concat(i.default,'" />\n          <img width="24" id="signalingStatus" src="').concat(s.default,'" />\n        </div>\n        <div class="modal-body">\n          <div class="row-container">\n            <div id="deviceList">\n              ').concat(function(e,t){var n="",o=r.WorkerManager.getInstance().getSupportedWorkers(e);t&&(n+=function(e){return'\n    <div class="form-check">\n      <input class="form-check-input" type="radio" name="radios" id="localdevice" value="localdevice" '.concat(e?"checked":"",' tabindex=0>\n      <label class="form-check-label" for="localdevice">\n        Local Device\n      </label>\n    </div>')}(!0));for(var i=0;i<o.length;i++){var s=!1;t||(s=0===i),n+=b(o[i].id,o[i].name,s)}return n}(n,o),'\n            </div>\n            <div class="vertical-align-center">\n              <image id="qrCodeImage" width="132" height="132" style="display:none;"></image>\n            </div>\n          </div>\n          <div class="form-check" id="alwaysForm">\n            <input class="form-check-input" type="checkbox" id="alwaysCb" ').concat(y?"checked":"",' tabindex=0>\n            <label class="form-check-label" for="alwaysCb">\n              Always connect to selected device\n            </label>\n          </div>\n        </div>\n        <div class="modal-footer">\n          <button type="button" class="btn btn-success mr-auto" id="refreshBtn" tabindex=0>Scan</button>\n          <button type="button" class="btn btn-primary" id="connectBtn" tabindex=0>Connect</button>\n          <button type="button" class="btn btn-secondary" id="closeBtn" tabindex=0>Close</button>\n        </div>\n      </div>\n    </div>\n  ')),e.qrGenerated=!1,e.style.display="block",E(e,t.feature,t.localGumIsCallable),function(e){B(),g=setInterval(A,h,e)}(e);var n,o;var a=e.querySelector(".modal-dialog"),c=a.querySelector("input[type=radio]:checked");c?c.focus():a.querySelector("#refreshBtn").focus();e.addEventListener("keydown",w),e.querySelector("#alwaysCb").addEventListener("change",(function(e){y=e.target.checked})),e.querySelector("#refreshBtn").addEventListener("click",(function(n){E(e,t.feature,t.localGumIsCallable)})),e.querySelector("#closeBtn").addEventListener("click",(function(n){"function"==typeof t.errorCallback&&t.errorCallback(new DOMException("Requested device not found")),k(),B(),e.innerHTML="",e.style.display="none",e.removeEventListener("keydown",w)})),e.querySelector("#connectBtn").addEventListener("click",(function(n){var r=document.querySelector("input[type=radio]:checked");r&&(k(),B(),t.successCallback({workerId:r.value,always:document.querySelector("#alwaysCb").checked}),e.innerHTML="",e.style.display="none",e.removeEventListener("keydown",w))}))};var r=n(16),o=c(n(0)),i=c(n(77)),s=c(n(78)),a=c(n(79));function c(e){return e&&e.__esModule?e:{default:e}}function u(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return l(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return l(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,s=!0,a=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return s=e.done,e},e:function(e){a=!0,i=e},f:function(){try{s||null==n.return||n.return()}finally{if(a)throw i}}}}function l(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var f=new o.default("device.js"),h=1e3,p=0,d=null,g=null,y=!0,m=!1,b=function(e,t,n){return'\n    <div class="form-check">\n      <input class="form-check-input" type="radio" name="radios" id="'.concat(e,'" value="').concat(e,'" ').concat(n?"checked":"",' tabindex=0>\n      <label class="form-check-label" for="').concat(e,'">\n        ').concat(t,"\n      </label>\n    </div>")};function v(e,t){var n=Array.from(e.querySelectorAll("[tabindex]")).filter((function(e){return null!==e.offsetParent}));t>=n.length?t=0:t<0&&(t=n.length-1),n[t].focus(),f.debug("device.js setFocus() >> "+t+" : "+n[t].id+"="+document.activeElement.id)}function w(e){switch(e.which){case 37:case 38:case 39:case 40:!function(e){for(var t=document.querySelector(".modal-dialog"),n=Array.from(t.querySelectorAll("[tabindex]")).filter((function(e){return null!==e.offsetParent})),r=0,o=0;o<n.length;o++)document.activeElement.id===n[o].id&&(r=o);switch(f.debug("focused elm : "+r+", "+document.activeElement.id),e){case 37:case 38:r--;break;case 39:case 40:r++}v(t,r)}(e.which),e.preventDefault()}}function C(e,t,n){r.WorkerManager.getInstance().updateCapability((function(){p+=h;var o=e.querySelector("#deviceList"),i=r.WorkerManager.getInstance().getSupportedWorkers(t);if(p>=1e4)return 0!==i.length||n||(o.innerHTML="<p>None</p>"),clearInterval(d),void(p=0);var s=o.querySelectorAll(".form-check-input");0===s.length&&(o.innerHTML="");var a,c=s.length,l=u(s);try{var f=function(){var e=a.value,t=i.findIndex((function(t){return t.id===e.value}));if("localdevice"===e.value)return"continue";-1===t?(e.parentNode.remove(),c--):i.splice(t,1)};for(l.s();!(a=l.n()).done;)f()}catch(e){l.e(e)}finally{l.f()}for(var g=0;g<i.length;g++){var y=document.createRange().createContextualFragment(b(i[g].id,i[g].name,0===c&&0===g));o.appendChild(y),c++}e.querySelector("#alwaysForm").style.display=c>0?"block":"none",e.qrGenerated||(r.WorkerManager.getInstance().getQrCode().then((function(e){var t=document.getElementById("qrCodeImage");t.src=e,t.style.display="block";var n=document.createElement("span"),r=document.createTextNode("Scan QR code for connecting");n.appendChild(r),t.parentNode.appendChild(n)})),e.qrGenerated=!0),s.length>0!=c>0&&v(e,0)}))}function A(e){var t=e.querySelector("#signalingStatus");m=r.WorkerManager.getInstance().signalingStatus,t.src=t&&m?s.default:a.default}function k(){d&&(p=0,clearInterval(d),d=null)}function E(e,t,n){k(),d=setInterval(C,h,e,t,n)}function B(){g&&(clearInterval(g),g=null)}},function(e,t,n){"use strict";n.r(t),t.default="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAACXBIWXMAAAsTAAALEwEAmpwYAAAGgUlEQVR4nO2bW2xVRRSGv7bcEgHBgiCE4hUCQVSQW4JFELEqD17ACyYEkAKCEeOD4hM+mIjEGDUx3ohACE+iBgQSJdUAikhijEFCJUVFCoIitwotbQ/Hh9ltNqf/2nv2OaeNl/MnkzRz/nWZtfeeWbNmCgUUUEAB/2MUdaCtfsA4YCBQGmoAJ0KtFtgT/P2vRi/gcWAtUAOkE7YDwBpgHnB5x7qePYqAycB6oJ7kg7baeWAdcDsd+9Ymwn1ANfkbtNWqA1v/GNwEfE77DzyzVQEjc3U+l9epM7ACeBooTiB3BjgE/AGcC/ouA/oCVwM9E+i6CLwGPAc0J5DLGQOBr/B7UnXAx8B8YJCH7sHAAmAjLkA+NnYA/fMyMg9MBo57OLUBmAZ0zcFWN6ACF4w4e0eBiTnY8kIFcCHGkc+AW9vB9gTgixjb9bgH1C6YhFuOLOM/AFPay3gI04hebepwwcorxgFnI4x+BHTPt9EI9AQ2R/hzGrglX8b6AscMQxeBF/BbTfrhJrf1wHZcplcXtANB3/qA089DXzFuFbKCUAtc4aEnFp8YBhqAB2NkOwGVwC4gFeFsZksFMpWBjijMAhoNPR94j9LAoggn58TIPkB+MsPqQFcUnsjBTxPXYK/Dr0bIlQLbIhzKtm0j+pV+y5Crwy//aIM1hsJPgRJDZjhwMIdBxrWawIZCZ9w8ouTesQZpTV43APvFQI8CI4BTQqYcNzP3sIwFqMHtHX4N9AEMAMpwy+j1MfJngenATvFbH2AfcGVGfxMwBPglRncr1qEjudDgX4srYFhPrgF4BRjmYXt4wG2I0HcC94kqLDVkVnnYBtyGpFkoqEHPyD1wSZDl7Abc002KskDW0rsX/bZ1xT3pTH4Tbg8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Cyj+BMBQ9qeAcjFAOkQE0p5s6dxOIFU5g7u4daRw0Q8yC3iYP02o3x7t0TQevwu/CAh7xPFKCoD9TZtuMQGzfvZ+u2g9StpQJoRi4Gfmrh7rtgPcAbmABhwkjlrYYnZY6iArrbW5g/ZxILFkzhtGmdVGqVHJjMAy3GfRVU+uIRhFZ5yyxpPWXXvn42HwV9yysHODzYxAKV0dcb6xY+5yV43jwEkFIyX/P+MvmotEIV6OpoYdZp3cyY3smMqR309LRSSTSqoiHREpML4HFCaIXLRWBTQ5oZDh0aZk/fAHv29rNz1xGODNRpQny1l4P/K+AeKem+SQkA8DXorMKngI8r6GSUYiWPgAaqWtHeWqG7s0ZXVyvdXS10HR13dNSoVROqVU1LS0UUANBopDSbhnozY2CgzpH+OoePNDhyZJjDR8eDwylNYzFAAuhXf960H/jLJnzhnnzMm5wAIn8F51fgfgXvYQxiXTOuOfVMRYFWCqXV8V4YAMZarLHH+9SKmdEC9ngcM/2nFO77KLyAyAQBQieRD+hcG1zFOIkteVYncWVYeNLAX94F36JcJggAcAckb4d3K7hXwQ28DsXCYxa++jP4zsOQAUwQYPSiHoLbgDsU3KJg6ikOeh/wAwvfuhN6PWUzQYCxyFdhdlXIcI2CtlME9CELTwAPN6H3XthBKBMEGOftZ2dreCtwrYIrgXkKaq8R4HVgq4WngMcNrLwbXuJ1KIo3gHwJ2tpgcZIT4WLgcuBsoEOBYuy1wAFygFcBz2Xw1BBs+CQM8ZuUCQLETy8bmKFgMbBYwSJgITAXmAR0AZO9PeMHgCPAQWAbsMnCRmCDhQ0a9shO3NefTMiETMiETMiETMiETMiETMiETMiETMiE/H+NKm6SUuq55AAAAABJRU5ErkJggg=="},function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function o(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function i(e,t){return(i=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function s(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=c(e);if(t){var o=c(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return a(this,n)}}function a(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function c(e){return(c=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.HAMResource=void 0;var u=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&i(e,t)}(c,e);var t,n,r,a=s(c);function c(){var e;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,c),(e=a.call(this)).listenerId_=0,e.checkCapability(),e}return t=c,(n=[{key:"start",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=[].slice.call(t);this.startJob({feature:r[0],successCallback:r[1]})}},{key:"stop",value:function(e){this.stopJob(e)}},{key:"addGestureRecognitionListener",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=[].slice.call(t);return this.startJob({feature:"GESTURE",successCallback:r[1],errorCallback:r[2]}),++this.listenerId_}},{key:"checkCapability",value:function(){"undefined"==typeof tizen&&(window.tizen={}),void 0===tizen.ppm&&(tizen.ppm={},tizen.ppm.requestPermission=function(){var e=arguments.length<=0?void 0:arguments[0],t=arguments.length<=1?void 0:arguments[1];t("PPM_ALLOW_FOREVER",e)},tizen.ppm.requestPermissions=function(){var e=arguments.length<=0?void 0:arguments[0],t=[];e.forEach((function(e){var n={};n.privilege=e,n.result="PPM_ALLOW_FOREVER",t.push(n)}));var n=arguments.length<=1?void 0:arguments[1];return n(t),t},tizen.ppm.checkPermission=function(){return"PPM_ALLOW"},tizen.ppm.checkPermissions=function(){var e=arguments.length<=0?void 0:arguments[0],t=[];return e.forEach((function(e){var n={};n.privilege=e,n.type="PPM_ALLOW",t.push(n)})),t}),tizen.humanactivitymonitor||(tizen.humanactivitymonitor={},tizen.humanactivitymonitor.start=this.start.bind(this),tizen.humanactivitymonitor.stop=this.stop.bind(this),tizen.humanactivitymonitor.addGestureRecognitionListener=this.addGestureRecognitionListener.bind(this))}}])&&o(t.prototype,n),r&&o(t,r),c}(n(29).Resource);t.HAMResource=u},function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.GYROResource=void 0;var o,i=n(29);function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function a(e,t){return(a=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function c(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=l(e);if(t){var o=l(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return u(this,n)}}function u(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function l(e){return(l=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var f=new(((o=n(0))&&o.__esModule?o:{default:o}).default)("gyro.js"),h=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&a(e,t)}(i,e);var t,n,r,o=c(i);function i(){var e;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),(e=o.call(this)).checkCapability(),e}return t=i,(n=[{key:"getGyroscopeRotationVectorSensorData",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=[].slice.call(t);this.startJobWithExistingWorker({feature:"GYRO",arguments:["getGyroscopeRotationVectorSensorData"],successCallback:r[0],errorCallback:r[1]})}},{key:"gyroStart",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=[].slice.call(t);this.startJob({feature:"GYRO",arguments:["start"],successCallback:r[0],errorCallback:r[1]})}},{key:"gyroStop",value:function(){this.stopJob("GYRO")}},{key:"checkCapability",value:function(){var e=this;f.debug("checkCapability"),"undefined"==typeof tizen&&(f.debug("tizen is undefined"),window.tizen={}),void 0===tizen.sensorservice&&(f.debug("tizen.sensorservice is undefined"),tizen.sensorservice={},tizen.sensorservice.getDefaultSensor=function(){var t={};return t.sensorType=arguments.length<=0?void 0:arguments[0],t.start=e.gyroStart.bind(e),t.getGyroscopeRotationVectorSensorData=e.getGyroscopeRotationVectorSensorData.bind(e),t.stop=e.gyroStop.bind(e),t})}}])&&s(t.prototype,n),r&&s(t,r),i}(i.Resource);t.GYROResource=h}]).default;
\ No newline at end of file
+var n,r,o,i=String.fromCharCode;function s(e){for(var t,n,r=[],o=0,i=e.length;o<i;)(t=e.charCodeAt(o++))>=55296&&t<=56319&&o<i?56320==(64512&(n=e.charCodeAt(o++)))?r.push(((1023&t)<<10)+(1023&n)+65536):(r.push(t),o--):r.push(t);return r}function a(e,t){if(e>=55296&&e<=57343){if(t)throw Error("Lone surrogate U+"+e.toString(16).toUpperCase()+" is not a scalar value");return!1}return!0}function c(e,t){return i(e>>t&63|128)}function u(e,t){if(0==(4294967168&e))return i(e);var n="";return 0==(4294965248&e)?n=i(e>>6&31|192):0==(4294901760&e)?(a(e,t)||(e=65533),n=i(e>>12&15|224),n+=c(e,6)):0==(4292870144&e)&&(n=i(e>>18&7|240),n+=c(e,12),n+=c(e,6)),n+=i(63&e|128)}function l(){if(o>=r)throw Error("Invalid byte index");var e=255&n[o];if(o++,128==(192&e))return 63&e;throw Error("Invalid continuation byte")}function f(e){var t,i;if(o>r)throw Error("Invalid byte index");if(o==r)return!1;if(t=255&n[o],o++,0==(128&t))return t;if(192==(224&t)){if((i=(31&t)<<6|l())>=128)return i;throw Error("Invalid continuation byte")}if(224==(240&t)){if((i=(15&t)<<12|l()<<6|l())>=2048)return a(i,e)?i:65533;throw Error("Invalid continuation byte")}if(240==(248&t)&&(i=(7&t)<<18|l()<<12|l()<<6|l())>=65536&&i<=1114111)return i;throw Error("Invalid UTF-8 detected")}e.exports={version:"2.1.2",encode:function(e,t){for(var n=!1!==(t=t||{}).strict,r=s(e),o=r.length,i=-1,a="";++i<o;)a+=u(r[i],n);return a},decode:function(e,t){var a=!1!==(t=t||{}).strict;n=s(e),r=n.length,o=0;for(var c,u=[];!1!==(c=f(a));)u.push(c);return function(e){for(var t,n=e.length,r=-1,o="";++r<n;)(t=e[r])>65535&&(o+=i((t-=65536)>>>10&1023|55296),t=56320|1023&t),o+=i(t);return o}(u)}}},function(e,t){!function(){"use strict";for(var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",n=new Uint8Array(256),r=0;r<e.length;r++)n[e.charCodeAt(r)]=r;t.encode=function(t){var n,r=new Uint8Array(t),o=r.length,i="";for(n=0;n<o;n+=3)i+=e[r[n]>>2],i+=e[(3&r[n])<<4|r[n+1]>>4],i+=e[(15&r[n+1])<<2|r[n+2]>>6],i+=e[63&r[n+2]];return o%3==2?i=i.substring(0,i.length-1)+"=":o%3==1&&(i=i.substring(0,i.length-2)+"=="),i},t.decode=function(e){var t,r,o,i,s,a=.75*e.length,c=e.length,u=0;"="===e[e.length-1]&&(a--,"="===e[e.length-2]&&a--);var l=new ArrayBuffer(a),f=new Uint8Array(l);for(t=0;t<c;t+=4)r=n[e.charCodeAt(t)],o=n[e.charCodeAt(t+1)],i=n[e.charCodeAt(t+2)],s=n[e.charCodeAt(t+3)],f[u++]=r<<2|o>>4,f[u++]=(15&o)<<4|i>>2,f[u++]=(3&i)<<6|63&s;return l}}()},function(e,t){var n=void 0!==n?n:"undefined"!=typeof WebKitBlobBuilder?WebKitBlobBuilder:"undefined"!=typeof MSBlobBuilder?MSBlobBuilder:"undefined"!=typeof MozBlobBuilder&&MozBlobBuilder,r=function(){try{return 2===new Blob(["hi"]).size}catch(e){return!1}}(),o=r&&function(){try{return 2===new Blob([new Uint8Array([1,2])]).size}catch(e){return!1}}(),i=n&&n.prototype.append&&n.prototype.getBlob;function s(e){return e.map((function(e){if(e.buffer instanceof ArrayBuffer){var t=e.buffer;if(e.byteLength!==t.byteLength){var n=new Uint8Array(e.byteLength);n.set(new Uint8Array(t,e.byteOffset,e.byteLength)),t=n.buffer}return t}return e}))}function a(e,t){t=t||{};var r=new n;return s(e).forEach((function(e){r.append(e)})),t.type?r.getBlob(t.type):r.getBlob()}function c(e,t){return new Blob(s(e),t||{})}"undefined"!=typeof Blob&&(a.prototype=Blob.prototype,c.prototype=Blob.prototype),e.exports=r?o?Blob:c:i?a:void 0},function(e,t,n){function r(e){var n;function r(){if(r.enabled){var e=r,o=+new Date,i=o-(n||o);e.diff=i,e.prev=n,e.curr=o,n=o;for(var s=new Array(arguments.length),a=0;a<s.length;a++)s[a]=arguments[a];s[0]=t.coerce(s[0]),"string"!=typeof s[0]&&s.unshift("%O");var c=0;s[0]=s[0].replace(/%([a-zA-Z%])/g,(function(n,r){if("%%"===n)return n;c++;var o=t.formatters[r];if("function"==typeof o){var i=s[c];n=o.call(e,i),s.splice(c,1),c--}return n})),t.formatArgs.call(e,s);var u=r.log||t.log||console.log.bind(console);u.apply(e,s)}}return r.namespace=e,r.enabled=t.enabled(e),r.useColors=t.useColors(),r.color=function(e){var n,r=0;for(n in e)r=(r<<5)-r+e.charCodeAt(n),r|=0;return t.colors[Math.abs(r)%t.colors.length]}(e),r.destroy=o,"function"==typeof t.init&&t.init(r),t.instances.push(r),r}function o(){var e=t.instances.indexOf(this);return-1!==e&&(t.instances.splice(e,1),!0)}(t=e.exports=r.debug=r.default=r).coerce=function(e){return e instanceof Error?e.stack||e.message:e},t.disable=function(){t.enable("")},t.enable=function(e){var n;t.save(e),t.names=[],t.skips=[];var r=("string"==typeof e?e:"").split(/[\s,]+/),o=r.length;for(n=0;n<o;n++)r[n]&&("-"===(e=r[n].replace(/\*/g,".*?"))[0]?t.skips.push(new RegExp("^"+e.substr(1)+"$")):t.names.push(new RegExp("^"+e+"$")));for(n=0;n<t.instances.length;n++){var i=t.instances[n];i.enabled=t.enabled(i.namespace)}},t.enabled=function(e){if("*"===e[e.length-1])return!0;var n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1},t.humanize=n(54),t.instances=[],t.names=[],t.skips=[],t.formatters={}},function(e,t){var n=1e3,r=6e4,o=60*r,i=24*o;function s(e,t,n){if(!(e<t))return e<1.5*t?Math.floor(e/t)+" "+n:Math.ceil(e/t)+" "+n+"s"}e.exports=function(e,t){t=t||{};var a,c=typeof e;if("string"===c&&e.length>0)return function(e){if((e=String(e)).length>100)return;var t=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(e);if(!t)return;var s=parseFloat(t[1]);switch((t[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*s;case"days":case"day":case"d":return s*i;case"hours":case"hour":case"hrs":case"hr":case"h":return s*o;case"minutes":case"minute":case"mins":case"min":case"m":return s*r;case"seconds":case"second":case"secs":case"sec":case"s":return s*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return s;default:return}}(e);if("number"===c&&!1===isNaN(e))return t.long?s(a=e,i,"day")||s(a,o,"hour")||s(a,r,"minute")||s(a,n,"second")||a+" ms":function(e){if(e>=i)return Math.round(e/i)+"d";if(e>=o)return Math.round(e/o)+"h";if(e>=r)return Math.round(e/r)+"m";if(e>=n)return Math.round(e/n)+"s";return e+"ms"}(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},function(e,t,n){(function(t){var r=n(20),o=n(6);e.exports=u;var i,s=/\n/g,a=/\\n/g;function c(){}function u(e){r.call(this,e),this.query=this.query||{},i||(t.___eio||(t.___eio=[]),i=t.___eio),this.index=i.length;var n=this;i.push((function(e){n.onData(e)})),this.query.j=this.index,t.document&&t.addEventListener&&t.addEventListener("beforeunload",(function(){n.script&&(n.script.onerror=c)}),!1)}o(u,r),u.prototype.supportsBinary=!1,u.prototype.doClose=function(){this.script&&(this.script.parentNode.removeChild(this.script),this.script=null),this.form&&(this.form.parentNode.removeChild(this.form),this.form=null,this.iframe=null),r.prototype.doClose.call(this)},u.prototype.doPoll=function(){var e=this,t=document.createElement("script");this.script&&(this.script.parentNode.removeChild(this.script),this.script=null),t.async=!0,t.src=this.uri(),t.onerror=function(t){e.onError("jsonp poll error",t)};var n=document.getElementsByTagName("script")[0];n?n.parentNode.insertBefore(t,n):(document.head||document.body).appendChild(t),this.script=t,"undefined"!=typeof navigator&&/gecko/i.test(navigator.userAgent)&&setTimeout((function(){var e=document.createElement("iframe");document.body.appendChild(e),document.body.removeChild(e)}),100)},u.prototype.doWrite=function(e,t){var n=this;if(!this.form){var r,o=document.createElement("form"),i=document.createElement("textarea"),c=this.iframeId="eio_iframe_"+this.index;o.className="socketio",o.style.position="absolute",o.style.top="-1000px",o.style.left="-1000px",o.target=c,o.method="POST",o.setAttribute("accept-charset","utf-8"),i.name="d",o.appendChild(i),document.body.appendChild(o),this.form=o,this.area=i}function u(){l(),t()}function l(){if(n.iframe)try{n.form.removeChild(n.iframe)}catch(e){n.onError("jsonp polling iframe removal error",e)}try{var e='<iframe src="javascript:0" name="'+n.iframeId+'">';r=document.createElement(e)}catch(e){(r=document.createElement("iframe")).name=n.iframeId,r.src="javascript:0"}r.id=n.iframeId,n.form.appendChild(r),n.iframe=r}this.form.action=this.uri(),l(),e=e.replace(a,"\\\n"),this.area.value=e.replace(s,"\\n");try{this.form.submit()}catch(e){}this.iframe.attachEvent?this.iframe.onreadystatechange=function(){"complete"===n.iframe.readyState&&u()}:this.iframe.onload=u}}).call(this,n(0))},function(e,t,n){(function(t){var r,o=n(11),i=n(2),s=n(5),a=n(6),c=n(21),u=n(7)("engine.io-client:websocket"),l=t.WebSocket||t.MozWebSocket;if("undefined"==typeof window)try{r=n(57)}catch(e){}var f=l;function h(e){e&&e.forceBase64&&(this.supportsBinary=!1),this.perMessageDeflate=e.perMessageDeflate,this.usingBrowserWebSocket=l&&!e.forceNode,this.protocols=e.protocols,this.usingBrowserWebSocket||(f=r),o.call(this,e)}f||"undefined"!=typeof window||(f=r),e.exports=h,a(h,o),h.prototype.name="websocket",h.prototype.supportsBinary=!0,h.prototype.doOpen=function(){if(this.check()){var e=this.uri(),t=this.protocols,n={agent:this.agent,perMessageDeflate:this.perMessageDeflate};n.pfx=this.pfx,n.key=this.key,n.passphrase=this.passphrase,n.cert=this.cert,n.ca=this.ca,n.ciphers=this.ciphers,n.rejectUnauthorized=this.rejectUnauthorized,this.extraHeaders&&(n.headers=this.extraHeaders),this.localAddress&&(n.localAddress=this.localAddress);try{this.ws=this.usingBrowserWebSocket?t?new f(e,t):new f(e):new f(e,t,n)}catch(e){return this.emit("error",e)}void 0===this.ws.binaryType&&(this.supportsBinary=!1),this.ws.supports&&this.ws.supports.binary?(this.supportsBinary=!0,this.ws.binaryType="nodebuffer"):this.ws.binaryType="arraybuffer",this.addEventListeners()}},h.prototype.addEventListeners=function(){var e=this;this.ws.onopen=function(){e.onOpen()},this.ws.onclose=function(){e.onClose()},this.ws.onmessage=function(t){e.onData(t.data)},this.ws.onerror=function(t){e.onError("websocket error",t)}},h.prototype.write=function(e){var n=this;this.writable=!1;for(var r=e.length,o=0,s=r;o<s;o++)!function(e){i.encodePacket(e,n.supportsBinary,(function(o){if(!n.usingBrowserWebSocket){var i={};if(e.options&&(i.compress=e.options.compress),n.perMessageDeflate)("string"==typeof o?t.Buffer.byteLength(o):o.length)<n.perMessageDeflate.threshold&&(i.compress=!1)}try{n.usingBrowserWebSocket?n.ws.send(o):n.ws.send(o,i)}catch(e){u("websocket closed before onclose event")}--r||a()}))}(e[o]);function a(){n.emit("flush"),setTimeout((function(){n.writable=!0,n.emit("drain")}),0)}},h.prototype.onClose=function(){o.prototype.onClose.call(this)},h.prototype.doClose=function(){void 0!==this.ws&&this.ws.close()},h.prototype.uri=function(){var e=this.query||{},t=this.secure?"wss":"ws",n="";return this.port&&("wss"===t&&443!==Number(this.port)||"ws"===t&&80!==Number(this.port))&&(n=":"+this.port),this.timestampRequests&&(e[this.timestampParam]=c()),this.supportsBinary||(e.b64=1),(e=s.encode(e)).length&&(e="?"+e),t+"://"+(-1!==this.hostname.indexOf(":")?"["+this.hostname+"]":this.hostname)+n+this.path+e},h.prototype.check=function(){return!(!f||"__initialize"in f&&this.name===h.prototype.name)}}).call(this,n(0))},function(e,t){},function(e,t){e.exports=function(e,t){for(var n=[],r=(t=t||0)||0;r<e.length;r++)n[r-t]=e[r];return n}},function(e,t){function n(e){e=e||{},this.ms=e.min||100,this.max=e.max||1e4,this.factor=e.factor||2,this.jitter=e.jitter>0&&e.jitter<=1?e.jitter:0,this.attempts=0}e.exports=n,n.prototype.duration=function(){var e=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var t=Math.random(),n=Math.floor(t*this.jitter*e);e=0==(1&Math.floor(10*t))?e-n:e+n}return 0|Math.min(e,this.max)},n.prototype.reset=function(){this.attempts=0},n.prototype.setMin=function(e){this.ms=e},n.prototype.setMax=function(e){this.max=e},n.prototype.setJitter=function(e){this.jitter=e}},function(e,t,n){"use strict";var r,o="object"==typeof Reflect?Reflect:null,i=o&&"function"==typeof o.apply?o.apply:function(e,t,n){return Function.prototype.apply.call(e,t,n)};r=o&&"function"==typeof o.ownKeys?o.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};var s=Number.isNaN||function(e){return e!=e};function a(){a.init.call(this)}e.exports=a,e.exports.once=function(e,t){return new Promise((function(n,r){function o(n){e.removeListener(t,i),r(n)}function i(){"function"==typeof e.removeListener&&e.removeListener("error",o),n([].slice.call(arguments))}v(e,t,i,{once:!0}),"error"!==t&&function(e,t,n){"function"==typeof e.on&&v(e,"error",t,n)}(e,o,{once:!0})}))},a.EventEmitter=a,a.prototype._events=void 0,a.prototype._eventsCount=0,a.prototype._maxListeners=void 0;var c=10;function u(e){if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function l(e){return void 0===e._maxListeners?a.defaultMaxListeners:e._maxListeners}function f(e,t,n,r){var o,i,s,a;if(u(n),void 0===(i=e._events)?(i=e._events=Object.create(null),e._eventsCount=0):(void 0!==i.newListener&&(e.emit("newListener",t,n.listener?n.listener:n),i=e._events),s=i[t]),void 0===s)s=i[t]=n,++e._eventsCount;else if("function"==typeof s?s=i[t]=r?[n,s]:[s,n]:r?s.unshift(n):s.push(n),(o=l(e))>0&&s.length>o&&!s.warned){s.warned=!0;var c=new Error("Possible EventEmitter memory leak detected. "+s.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");c.name="MaxListenersExceededWarning",c.emitter=e,c.type=t,c.count=s.length,a=c,console&&console.warn&&console.warn(a)}return e}function h(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function p(e,t,n){var r={fired:!1,wrapFn:void 0,target:e,type:t,listener:n},o=h.bind(r);return o.listener=n,r.wrapFn=o,o}function d(e,t,n){var r=e._events;if(void 0===r)return[];var o=r[t];return void 0===o?[]:"function"==typeof o?n?[o.listener||o]:[o]:n?function(e){for(var t=new Array(e.length),n=0;n<t.length;++n)t[n]=e[n].listener||e[n];return t}(o):y(o,o.length)}function g(e){var t=this._events;if(void 0!==t){var n=t[e];if("function"==typeof n)return 1;if(void 0!==n)return n.length}return 0}function y(e,t){for(var n=new Array(t),r=0;r<t;++r)n[r]=e[r];return n}function v(e,t,n,r){if("function"==typeof e.on)r.once?e.once(t,n):e.on(t,n);else{if("function"!=typeof e.addEventListener)throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof e);e.addEventListener(t,(function o(i){r.once&&e.removeEventListener(t,o),n(i)}))}}Object.defineProperty(a,"defaultMaxListeners",{enumerable:!0,get:function(){return c},set:function(e){if("number"!=typeof e||e<0||s(e))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");c=e}}),a.init=function(){void 0!==this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},a.prototype.setMaxListeners=function(e){if("number"!=typeof e||e<0||s(e))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+e+".");return this._maxListeners=e,this},a.prototype.getMaxListeners=function(){return l(this)},a.prototype.emit=function(e){for(var t=[],n=1;n<arguments.length;n++)t.push(arguments[n]);var r="error"===e,o=this._events;if(void 0!==o)r=r&&void 0===o.error;else if(!r)return!1;if(r){var s;if(t.length>0&&(s=t[0]),s instanceof Error)throw s;var a=new Error("Unhandled error."+(s?" ("+s.message+")":""));throw a.context=s,a}var c=o[e];if(void 0===c)return!1;if("function"==typeof c)i(c,this,t);else{var u=c.length,l=y(c,u);for(n=0;n<u;++n)i(l[n],this,t)}return!0},a.prototype.addListener=function(e,t){return f(this,e,t,!1)},a.prototype.on=a.prototype.addListener,a.prototype.prependListener=function(e,t){return f(this,e,t,!0)},a.prototype.once=function(e,t){return u(t),this.on(e,p(this,e,t)),this},a.prototype.prependOnceListener=function(e,t){return u(t),this.prependListener(e,p(this,e,t)),this},a.prototype.removeListener=function(e,t){var n,r,o,i,s;if(u(t),void 0===(r=this._events))return this;if(void 0===(n=r[e]))return this;if(n===t||n.listener===t)0==--this._eventsCount?this._events=Object.create(null):(delete r[e],r.removeListener&&this.emit("removeListener",e,n.listener||t));else if("function"!=typeof n){for(o=-1,i=n.length-1;i>=0;i--)if(n[i]===t||n[i].listener===t){s=n[i].listener,o=i;break}if(o<0)return this;0===o?n.shift():function(e,t){for(;t+1<e.length;t++)e[t]=e[t+1];e.pop()}(n,o),1===n.length&&(r[e]=n[0]),void 0!==r.removeListener&&this.emit("removeListener",e,s||t)}return this},a.prototype.off=a.prototype.removeListener,a.prototype.removeAllListeners=function(e){var t,n,r;if(void 0===(n=this._events))return this;if(void 0===n.removeListener)return 0===arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==n[e]&&(0==--this._eventsCount?this._events=Object.create(null):delete n[e]),this;if(0===arguments.length){var o,i=Object.keys(n);for(r=0;r<i.length;++r)"removeListener"!==(o=i[r])&&this.removeAllListeners(o);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if("function"==typeof(t=n[e]))this.removeListener(e,t);else if(void 0!==t)for(r=t.length-1;r>=0;r--)this.removeListener(e,t[r]);return this},a.prototype.listeners=function(e){return d(this,e,!0)},a.prototype.rawListeners=function(e){return d(this,e,!1)},a.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):g.call(e,t)},a.prototype.listenerCount=g,a.prototype.eventNames=function(){return this._eventsCount>0?r(this._events):[]}},function(e){e.exports=JSON.parse('{"name":"offload.js","version":"0.4.1","description":"","main":"dist/offload.js","scripts":{"build":"webpack --config ./webpack.dev.js","build:prod":"webpack --config ./webpack.prod.js","build:apps":"./script/build-script.js --all","dev":"npm-run-all --parallel watch:offload watch:server","lint":"npm run lint:prettier && npm run lint:eslint","lint:eslint":"eslint --fix \\"**/*.js\\"","lint:prettier":"prettier --write --ignore-unknown \\"**/*.js\\"","release":"release-it","castanets":"cp dist/offload-worker.js offload-worker/android/app/libs/","test":"karma start ./karma.conf.js","test:e2e":"cypress open","watch:offload":"nodemon --watch offload.js -e \'js,css\' --exec npm run build","watch:server":"nodemon --watch offload-server/src offload-server/src/app.js"},"author":"Hunseop Jeong <hs85.jeong@samsung.com>","dependencies":{"debug":"4.3.1","express":"4.17.1","filemanager-webpack-plugin":"2.0.5","lokijs":"1.5.11","qrcode":"1.4.4","serve-index":"1.9.1","socket.io":"2.3.0","socket.io-client":"2.0.2","ua-parser-js":"0.7.21","uuid":"8.2.0"},"devDependencies":{"@babel/core":"7.12.3","@babel/plugin-transform-modules-commonjs":"7.12.1","@babel/preset-env":"7.12.1","babel-eslint":"10.1.0","babel-loader":"8.1.0","commander":"6.2.0","css-loader":"3.5.3","cypress":"6.5.0","eslint":"7.30.0","eslint-config-google":"0.14.0","eslint-config-prettier":"8.3.0","filemanager-webpack-plugin":"2.0.5","fs-extra":"9.0.1","glob":"7.1.6","husky":"4.3.0","istanbul":"0.4.5","istanbul-instrumenter-loader":"3.0.1","karma":"5.2.3","karma-chrome-launcher":"3.1.0","karma-coverage":"2.0.3","karma-expect":"1.1.3","karma-mocha":"2.0.1","karma-sinon":"1.0.5","karma-webpack":"4.0.2","lint-staged":"10.3.0","mocha":"8.1.3","mustache-loader":"1.4.3","nodemon":"2.0.4","npm-run-all":"4.1.5","prettier":"2.3.2","release-it":"14.2.0","rimraf":"3.0.2","sinon":"9.2.0","to-string-loader":"1.1.6","url-loader":"4.1.1","webpack":"4.44.2","webpack-cli":"3.3.12","webpack-merge":"5.1.4"},"husky":{"hooks":{"pre-commit":"lint-staged"}},"lint-staged":{"**/*.js":"npm run lint"},"repository":{"type":"git","url":"git@github.sec.samsung.net:HighPerformanceWeb/offload.js.git"},"release-it":{"npm":{"publish":false},"github":{"release":true,"assets":["dist/*"]},"hooks":{"before:init":["npm run lint"],"after:bump":["npm run build:prod","npm run castanets","npm run build:apps"]}}}')},,function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Worker=void 0;var r,o=n(27);function i(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var s=new(((r=n(1))&&r.__esModule?r:{default:r}).default)("worker.js"),a=function(){function e(t,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this._workerId=n,this._workerManager=t,this._clientId=this._workerManager.getId(),this._deviceName=(0,o.getDeviceName)(),this._peerConnection=null,this._dataChannel=null,this._isConnected=!1,this._runningJobs=new Map,this._pendingJobs=new Map,this._gumStream=null,this._gumCapabilities=null,this._gumSettings=null,this._gumConstraints=null,this._applyConstraintsResolve=null,this._applyConstraintsReject=null,this._nativeApplyConstraints=null,this._setUpPeerConnection()}var t,n,r;return t=e,(n=[{key:"_setUpPeerConnection",value:function(){var e=this;this._peerConnection=new RTCPeerConnection,this._peerConnection.onicecandidate=this._handleIceCandidateEvent.bind(this),this._peerConnection.ontrack=this._handleTrackEvent.bind(this),this._dataChannel=this._peerConnection.createDataChannel("offload"),this._dataChannel.onopen=this._handleDataChannelOpenEvent.bind(this),this._dataChannel.onclose=this._handleDataChannelCloseEvent.bind(this),this._dataChannel.onmessage=this._handleDataChannelMessageEvent.bind(this),this._peerConnection.createOffer().then((function(t){return e._peerConnection.setLocalDescription(t)})).then((function(){s.debug("send offer"),e._sendSignalMessage(e._peerConnection.localDescription)})).catch((function(e){return s.error("reason: "+e.toString())}))}},{key:"_handleIceCandidateEvent",value:function(e){e.candidate&&(s.debug("send candidate"),this._sendSignalMessage({type:"candidate",candidate:e.candidate}))}},{key:"_handleTrackEvent",value:function(e){var t=this;s.debug("got track");var n=e.streams[0];this._gumStream=n,n.peerConnection=this._peerConnection,n.getTracks().forEach((function(e){var n=e.stop;e.stop=function(){t._sendPeerMessage({type:"stopTrack",feature:"CAMERA",trackId:e.id}),n.call(e)}}));var r=null;n.getVideoTracks().length>0?(this._updateMediaStreamTrack(n.getVideoTracks()[0]),r=this._getRunningJob("CAMERA")):n.getAudioTracks().length>0&&(r=this._getRunningJob("MIC")),r&&(s.timeEnd("job complete"),r.successCallback(n))}},{key:"_updateMediaStreamTrack",value:function(e){var t=this;e.getCapabilities=function(){return t._gumCapabilities},e.getSettings=function(){return t._gumSettings},e.getConstraints=function(){return t._gumConstraints},this._nativeApplyConstraints=e.applyConstraints.bind(e),e.applyConstraints=function(e){if(t._hasAutoZoomConstraints(e)){var n=t._extractAutoZoomConstraints(e);t._nativeApplyConstraints(n)}return new Promise((function(n,r){t._applyConstraintsResolve=n,t._applyConstraintsReject=r,t._sendPeerMessage({type:"applyConstraints",feature:"CAMERA",constraints:e})}))}}},{key:"_handleDataChannelOpenEvent",value:function(){var e=this;s.debug("data channel opened"),this._isConnected=!0,this._pendingJobs.forEach((function(t){return e.startJob(t)})),this._pendingJobs.clear()}},{key:"_handleDataChannelCloseEvent",value:function(){s.debug("data channel closed"),this._isConnected=!1,this._dataChannel=null,this._closePeerConnection()}},{key:"_closePeerConnection",value:function(){this._peerConnection&&(this._peerConnection.onicecandidate=null,this._peerConnection.ontrack=null,this._peerConnection.close(),this._peerConnection=null)}},{key:"_handleDataChannelMessageEvent",value:function(e){var t=JSON.parse(e.data),n=this._getRunningJob(t.feature);if(null!==n)switch(t.type){case"data":"CAMERA"===t.feature?(this._gumCapabilities=t.data.capabilities,this._gumSettings=t.data.settings,this._gumConstraints=t.data.constraints):(s.timeEnd("job complete"),n.successCallback(t.data));break;case"error":n.errorCallback(new DOMException(t.error.message,t.error.name)),this.stopJob(t.feature);break;case"applyConstraints":"success"===t.result?(this._gumSettings=t.data.settings,this._gumConstraints=t.data.constraints,this._applyConstraintsResolve()):this._applyConstraintsReject(new DOMException(t.error.message,t.error.name));break;default:s.debug("unsupported message type",t.type)}else s.error("no job related to feature",t.feature)}},{key:"_getRunningJob",value:function(e){return this._runningJobs.has(e)?this._runningJobs.get(e):null}},{key:"_sendSignalMessage",value:function(e){this._workerManager.sendMessage(this._workerId,e)}},{key:"_sendPeerMessage",value:function(e){this._isConnected?this._dataChannel.send(JSON.stringify(e)):s.error("data channel is not connected")}},{key:"startJob",value:function(e){s.debug("startJob id:".concat(this._workerId," feature:").concat(e.feature)),this._isConnected?(this._sendPeerMessage({type:"start",feature:e.feature,arguments:e.arguments,resolver:e.resolver,clientId:this._clientId,deviceName:this._deviceName}),this._runningJobs.set(e.feature,e),e.resolver&&"function"==typeof e.resolver&&e.resolver()):this._pendingJobs.set(e.feature,e)}},{key:"stopJob",value:function(e){s.debug("stopJob",this._workerId,e),this._runningJobs.has(e)?(this._sendPeerMessage({type:"stop",feature:e}),this._runningJobs.delete(e)):this._pendingJobs.has(e)&&this._pendingJobs.delete(e)}},{key:"handleMessage",value:function(e){"offer"===e.type?this._handleOffer(e):"answer"===e.type?this._handleAnswer(e):"candidate"===e.type?this._handleCandidate(e.candidate):s.error("unhandled message type: ".concat(e.type))}},{key:"_handleOffer",value:function(e){var t=this;s.debug("got offer"),this._peerConnection.setRemoteDescription(e).then((function(){return t._peerConnection.createAnswer()})).then((function(e){return t._peerConnection.setLocalDescription(e)})).then((function(){s.debug("send answer"),t._sendSignalMessage(t._peerConnection.localDescription)})).catch((function(e){return s.error("reason: "+e.toString())}))}},{key:"_handleAnswer",value:function(e){s.debug("got answer"),this._peerConnection.setRemoteDescription(e).catch((function(e){return s.error("reason: "+e.toString())}))}},{key:"_handleCandidate",value:function(e){s.debug("got candidate"),this._peerConnection.addIceCandidate(e).catch((function(e){return s.error("reason: "+e.toString())}))}},{key:"_hasAutoZoomConstraints",value:function(e){for(var t in e)if(t.startsWith("tizenAiAutoZoom"))return!0;return!1}},{key:"_extractAutoZoomConstraints",value:function(e){var t={};for(var n in e)n.startsWith("tizenAiAutoZoom")&&(t[n]=e[n]);return t}}])&&i(t.prototype,n),r&&i(t,r),e}();t.Worker=a},function(e,t,n){var r=n(74);r.Template=n(75).Template,r.template=r.Template,e.exports=r},function(e,t,n){e.exports=n(66)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=n(67);window.localStorage.setItem("debug","offload:INFO*, offload:ERROR*");var o=new r.Offload;t.default=o},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Offload=void 0;var r,o=n(26),i=n(72),s=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!==u(e)&&"function"!=typeof e)return{default:e};var n=c(t);if(n&&n.has(e))return n.get(e);var r={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if("default"!==i&&Object.prototype.hasOwnProperty.call(e,i)){var s=o?Object.getOwnPropertyDescriptor(e,i):null;s&&(s.get||s.set)?Object.defineProperty(r,i,s):r[i]=e[i]}r.default=e,n&&n.set(e,r);return r}(n(83)),a=n(61);function c(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(c=function(e){return e?n:t})(e)}function u(e){return(u="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function l(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var f=new(((r=n(1))&&r.__esModule?r:{default:r}).default)("offload.js");f.info("offload.js version: ".concat(a.version));var h=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e);var n={autoconnect:!0};"object"===u(t)&&Object.assign(n,t),this.resources=[],this._workerManager=new o.WorkerManager,this._popup=new i.DevicePopup(this._workerManager),n.autoconnect&&this._workerManager.connect();for(var r=0,a=Object.values(s);r<a.length;r++){var c=a[r];this.resources.push(new c(this._workerManager,this._popup))}}var t,n,r;return t=e,(n=[{key:"version",get:function(){return a.version}},{key:"connect",value:function(e){return this._workerManager.connect(e)}},{key:"on",value:function(e,t){switch(e){case"showDevicePopup":case"hideDevicePopup":this._popup.on(e,t);break;default:f.error("unhandled event name: ".concat(e))}}},{key:"off",value:function(e,t){switch(e){case"showDevicePopup":case"hideDevicePopup":this._popup.off(e,t);break;default:f.error("unhandled event name: ".concat(e))}}}])&&l(t.prototype,n),r&&l(t,r),e}();t.Offload=h},function(e,t,n){"use strict";var r;function o(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}Object.defineProperty(t,"__esModule",{value:!0}),t.Resource=void 0;var i=new(((r=n(1))&&r.__esModule?r:{default:r}).default)("resource.js"),s=function(){function e(t,n){if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.constructor===e)throw new Error("Resource is abstract class");this._workerManager=t,this._popup=n,this._worker=null,this._alwaysConnect=null,this.injectOffloadAPI()}var t,n,r;return t=e,(n=[{key:"injectOffloadAPI",value:function(){throw new Error("Need to inject Offload API")}},{key:"startJob",value:function(e){var t=this;if(this._alwaysConnect)this.startJobImpl(this._alwaysConnect,e);else{var n=e.feature,r=e.localGumIsCallable;this.showResourcePopup(n,r).then((function(n){t._alwaysConnect=n.always?n.workerId:null,t.startJobImpl(n.workerId,e)})).catch((function(t){i.error(t),e.errorCallback&&e.errorCallback(t)}))}}},{key:"startJobImpl",value:function(e,t){var n=this;"localdevice"!==this._alwaysConnect&&"localdevice"!==e?this.requestService(e).then((function(){n._worker=n._workerManager.getOrCreateWorker(e),i.time("job complete"),n._worker.startJob(t)})).catch((function(e){i.error(e),t.errorCallback&&t.errorCallback(e)})):t.nativeGetUserMedia(t.arguments[0]).then(t.successCallback).catch(t.errorCallback)}},{key:"startJobWithExistingWorker",value:function(e){this._worker&&this._worker.startJob(e)}},{key:"stopJob",value:function(e){this._worker&&(this._worker.stopJob(e),this._worker=null)}},{key:"showResourcePopup",value:function(e,t){var n=this;return new Promise((function(r,o){n._popup.show({feature:e,successCallback:r,errorCallback:o,localGumIsCallable:t})}))}},{key:"requestService",value:function(e){var t=this;return new Promise((function(n,r){t._workerManager.requestService(e,{successCallback:n,errorCallback:r})}))}}])&&o(t.prototype,n),r&&o(t,r),e}();t.Resource=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WorkerManager=void 0;var r,o=n(63),i=n(70),s=n(71),a=n(27);function c(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function u(e){return(u="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var l=new(((r=n(1))&&r.__esModule?r:{default:r}).default)("worker-manager.js"),f="object"===("undefined"==typeof tizen?"undefined":u(tizen)),h=function(){function e(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this._workerInfos=new Map,this._activeWorkers=new Map,this._capabilities=new Map,this._socket=null,this._id=(0,a.getClientId)(),this._qrCode=null,this._callbacks={qrcode:[],capability:[]},this.signalingStatus=!1,this}var t,n,r;return t=e,(n=[{key:"connect",value:function(e){var t=e||this._getServerUrl();return null===t?(l.error("No valid server URL found."),null):(t.endsWith("/offload-js")||(t+="/offload-js"),null!==this._socket&&this._socket.close(),l.time("socket connected"),this._socket=this._createSocket(),this._socket.connect(t),this._socket.on("greeting",this._initFromGreeting.bind(this)),this._socket.on("worker",this._handleWorkerEvent.bind(this)),this._socket.on("capabilities",this._updateCapabilities.bind(this)),this._socket.on("message",this._handleMessage.bind(this)),this._socket.on("connect",this._socketConnected.bind(this)),this._socket.on("disconnect",this._socketDisconnected.bind(this)),t)}},{key:"_createSocket",value:function(){return"undefined"!=typeof tizen&&tizen.messageport?new s.SocketTizen:new i.SocketWeb}},{key:"_getServerUrl",value:function(){return f?(0,a.getServerUrlFromLocalhost)():(0,a.getServerUrlFromLocation)()}},{key:"_initFromGreeting",value:function(e){for(l.debug("greeting: "+JSON.stringify(e)),this.signalingStatus=!0,this._qrCode=e.qrCode,this._workerInfos=new Map(e.workers);this._callbacks.qrcode.length;)this._callbacks.qrcode.pop().call(this,this._qrCode)}},{key:"_updateCapabilities",value:function(e){for(this._capabilities=new Map(e);this._callbacks.capability.length;)this._callbacks.capability.pop().call(this,this._capabilities)}},{key:"_handleWorkerEvent",value:function(e){if("join"===e.event){if(l.debug("join: '".concat(e.workerId,"' - '").concat(e.name,"', '").concat(e.features,"', '").concat(e.mediaDeviceInfos,"'")),this._workerInfos.set(e.workerId,{socketId:e.socketId,name:e.name,features:e.features,mediaDeviceInfos:e.mediaDeviceInfos,compute_tasks:0}),this._capabilities.has(e.workerId)){var t=this._capabilities.get(e.workerId);t.options&&(l.debug("resolve successCallback"),t.options.successCallback(),t.options=null)}}else"bye"===e.event&&(l.debug("bye: '".concat(e.workerId,"'")),this._workerInfos.delete(e.workerId),this._activeWorkers.delete(e.workerId))}},{key:"_handleMessage",value:function(e){this._activeWorkers.has(e.from)&&this._activeWorkers.get(e.from).handleMessage(e.message)}},{key:"_socketConnected",value:function(){l.debug("".concat(this._socket.id," connected")),l.timeEnd("socket connected"),this._socket&&this._socket.emit("create")}},{key:"_socketDisconnected",value:function(){l.debug("".concat(this._socket.id," disconnected")),this.signalingStatus=!1}},{key:"getOrCreateWorker",value:function(e){if(this._activeWorkers.has(e))return this._activeWorkers.get(e);var t=new o.Worker(this,e);return this._activeWorkers.set(e,t),t}},{key:"getWorkerInfos",value:function(){return this._workerInfos}},{key:"getSupportedWorkers",value:function(e){var t=this,n=[];return this._capabilities.forEach((function(t,r,o){t.features.indexOf(e)>=0&&n.push({id:r,name:t.name})})),this._workerInfos.forEach((function(r,o,i){!t._capabilities.has(o)&&r.features.indexOf(e)>=0&&n.push({id:o,name:r.name})})),n}},{key:"getId",value:function(){return this._id}},{key:"requestService",value:function(e,t){if(this._workerInfos.has(e))return l.debug("Already existed in workInfos. Resolve successCallback directly"),void t.successCallback();this._capabilities.get(e).options=t,this._socket.emit("requestService",e)}},{key:"updateCapability",value:function(e){this._socket.emit("getcapabilities"),this._callbacks.capability.push(e)}},{key:"sendMessage",value:function(e,t){this._socket?this._socket.emit("message",{to:e,from:this._socket.id,message:t}):l.error("socket is null")}},{key:"getQrCode",value:function(){var e=this;return new Promise((function(t){e._qrCode?t(e._qrCode):e._callbacks.qrcode.push(t)}))}}])&&c(t.prototype,n),r&&c(t,r),e}();t.WorkerManager=h},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SocketWeb=void 0;var r=o(n(32));function o(e){return e&&e.__esModule?e:{default:e}}function i(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var s=new(o(n(1)).default)("socket-web.js"),a=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),s.debug("SocketWeb created"),this._serverUrl=null,this._socket=null}var t,n,o;return t=e,(n=[{key:"id",get:function(){return this._socket.id}},{key:"on",value:function(e,t){s.debug("on: ".concat(e)),this._socket.on(e,t)}},{key:"emit",value:function(e,t){s.debug("emit: ".concat(e)),this._socket.emit(e,t)}},{key:"connect",value:function(e){s.debug("connect url:".concat(e)),this._serverUrl=e,this._socket=(0,r.default)(e,{transports:["websocket","polling"]})}},{key:"close",value:function(){s.debug("close"),this._socket.close()}}])&&i(t.prototype,n),o&&i(t,o),e}();t.SocketWeb=a},function(e,t,n){"use strict";var r;function o(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}Object.defineProperty(t,"__esModule",{value:!0}),t.SocketTizen=void 0;var i=new(((r=n(1))&&r.__esModule?r:{default:r}).default)("socket-tizen.js"),s=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),i.debug("SocketTizen created"),this._portName="offload",this._localPort=null,this._remotePort=null,this._eventHandlers={};var t=tizen.application.getCurrentApplication();this._appId=t.appInfo.id}var t,n,r;return t=e,(n=[{key:"id",get:function(){return this._appId}},{key:"on",value:function(e,t){i.debug("on event:".concat(e)),this._eventHandlers[e]=t.bind(null)}},{key:"emit",value:function(e,t){i.debug("emit: ".concat(e));var n=t||{};try{this._remotePort.sendMessage([{key:e,value:JSON.stringify({id:this._appId,data:n})}],this._localPort)}catch(e){i.error(e)}}},{key:"connect",value:function(){var e=this;i.debug("connect");try{this._localPort=tizen.messageport.requestLocalMessagePort(this._portName),this._localPort.addMessagePortListener((function(t){if(0!==t.length){var n=t[0],r=n.key,o=e._eventHandlers[r];o?o(JSON.parse(n.value)):i.error("Not found ".concat(r," handler"))}else i.error("Not found message")})),this._remotePort=tizen.messageport.requestRemoteMessagePort("org.tizen.chromium-efl.wrt-service",this._portName),this.emit("connect")}catch(e){i.error("Message port connection failed: "+e)}}},{key:"close",value:function(){i.debug("close")}}])&&o(t.prototype,n),r&&o(t,r),e}();t.SocketTizen=s},function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.DevicePopup=void 0;var o=n(60),i=h(n(1)),s=h(n(73)),a=h(n(76)),c=h(n(77)),u=h(n(80)),l=h(n(81)),f=h(n(82));function h(e){return e&&e.__esModule?e:{default:e}}function p(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return d(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return d(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,s=!0,a=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return s=e.done,e},e:function(e){a=!0,i=e},f:function(){try{s||null==n.return||n.return()}finally{if(a)throw i}}}}function d(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function g(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function y(e,t){return(y=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=b(e);if(t){var o=b(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return m(this,n)}}function m(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function b(e){return(b=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var w=new i.default("device-popup.js"),A={BACKSPACE:8,ENTER:13,SPACE:32,LEFT:37,UP:38,RIGHT:39,DOWN:40,XF86_BACK:10009},C="__oFfLoAdPoPuP210426__",k=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&y(e,t)}(i,e);var t,n,r,o=v(i);function i(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),(t=o.call(this))._workerManager=e,t._updateIntervalID=0,t._signalingIntervalID=0,t.createElement(),t.addQrImage(),t}return t=i,(n=[{key:"createElement",value:function(){var e=this;this._root=document.createElement("div"),this._shadow=this._root.attachShadow({mode:"open"});var t=document.createElement("style");t.innerText=c.default.toString(),this._shadow.appendChild(t),this._element=document.createElement("div"),this._element.classList.add("modal"),this._element.id=C,this._element.classList.add("overlay"),this._element.setAttribute("tabindex","-1"),this._element.setAttribute("role","dialog"),this._shadow.appendChild(this._element),this._element.innerHTML=(0,a.default)({SIGNAL_IMG:u.default,ENABLE_IMG:l.default,alwaysUseSameDevice:!0}),this._keydownEventListener=function(t){var n=!1;switch(t.which){case A.LEFT:case A.UP:case A.RIGHT:case A.DOWN:e.moveElement(t.which),n=!0;break;case A.BACKSPACE:case A.XF86_BACK:e._element.querySelector("#closeBtn").click(),n=!0;break;case A.ENTER:case A.SPACE:n=e.selectElement()}n?(t.preventDefault(),t.stopPropagation()):w.debug("Not handled keydown. ".concat(t.which," ").concat(t.code," ").concat(t.currentTarget.id))},this._keyupEventListener=function(e){Object.keys(A).some((function(t){return e.which===A[t]&&(e.preventDefault(),e.stopPropagation(),!0)}))||w.debug("Not handled keyup. ".concat(e.which," ").concat(e.code," ").concat(e.currentTarget.id))},this._focusInEventListener=function(t){e.setFocusBack()},this._focusOutEventListener=function(t){setTimeout((function(){e.setFocusBack()}),100)},this._element.querySelector("#refreshBtn").addEventListener("click",(function(t){return e.startUpdateInterval()})),this._element.querySelector("#closeBtn").addEventListener("click",(function(t){"function"==typeof e._options.errorCallback&&e._options.errorCallback(new DOMException("Requested device not found")),e.hide()})),this._element.querySelector("#connectBtn").addEventListener("click",(function(t){var n=e._element.querySelector("input[type=radio]:checked");n&&("function"==typeof e._options.successCallback&&e._options.successCallback({workerId:n.value,always:e._element.querySelector("#alwaysCb").checked}),e.hide())}))}},{key:"addQrImage",value:function(){var e=this;this._workerManager.getQrCode().then((function(t){var n=e._element.querySelector("#qrCodeImage");n.src=t,n.style.display="block";var r=document.createElement("span"),o=document.createTextNode("Scan QR code for connecting");r.appendChild(o),n.parentNode.appendChild(r)}))}},{key:"show",value:function(e){this._options=e,document.getElementById(C)||document.body.appendChild(this._root),this._element.style.display="block",this._element.addEventListener("keydown",this._keydownEventListener),this._element.addEventListener("keyup",this._keyupEventListener),document.addEventListener("focusin",this._focusInEventListener),document.addEventListener("focusout",this._focusOutEventListener);var t=this._element.querySelector("input[type=radio]:checked");t?t.focus():this._element.querySelector("#refreshBtn").focus(),this.startUpdateInterval(),this.startSignalingStatusInterval(),this.emit("showDevicePopup",this)}},{key:"hide",value:function(){this.clearUpdateInterval(),this.clearSignalingStatusInterval(),document.body.removeChild(this._root),this._element.style.display="none",this._element.removeEventListener("keydown",this._keydownEventListener),this._element.removeEventListener("keyup",this._keyupEventListener),document.removeEventListener("focusin",this._focusInEventListener),document.removeEventListener("focusout",this._focusOutEventListener),this.emit("hideDevicePopup",this)}},{key:"setFocus",value:function(e){var t=Array.from(this._element.querySelectorAll("[tabindex]")).filter((function(e){return null!==e.offsetParent}));return t.length?(e>=t.length?e=0:e<0&&(e=t.length-1),t[e].focus(),w.debug("setFocus() >> [".concat(e,"] ").concat(t[e].id)),this._lastFocusedElm=t[e],t[e]):null}},{key:"setFocusBack",value:function(){this._element.offsetParent&&this._lastFocusedElm!==document.activeElement&&(Array.from(this._element.querySelectorAll("[tabindex]")).some((function(e){return e===document.activeElement}))||(this._lastFocusedElm&&this._lastFocusedElm.closest("#".concat(C))&&null!==this._lastFocusedElm.offsetParent?this._lastFocusedElm.focus():this._lastFocusedElm=this.setFocus(0),w.debug("[focus] >> focus back to ".concat(this._lastFocusedElm.id," ").concat(null!==this._lastFocusedElm.offsetParent))))}},{key:"moveElement",value:function(e){for(var t=Array.from(this._element.querySelectorAll("[tabindex]")).filter((function(e){return null!==e.offsetParent})),n=0,r=0;r<t.length;r++)this._shadow.activeElement.id===t[r].id&&(n=r);switch(e){case A.LEFT:case A.UP:n--;break;case A.RIGHT:case A.DOWN:n++}this.setFocus(n)}},{key:"selectElement",value:function(){if(!this._shadow.activeElement)return!1;for(var e=Array.from(this._element.querySelectorAll("[tabindex]")).filter((function(e){return null!==e.offsetParent})),t=0;t<e.length;t++)if(this._shadow.activeElement.id===e[t].id)return e[t].click(),"form-device-input"===e[t].className&&this._element.querySelector("#connectBtn").click(),!0;return w.debug("selectElement() : Not Handled "+this._shadow.activeElement.id),!1}},{key:"updateDeviceList",value:function(e){var t=this,n={id:"localdevice",name:"Local Device"};!this.isDeviceListUpdated&&this._options&&this._options.localGumIsCallable&&this._showDeviceList([n]),this._workerManager.updateCapability((function(){t.isDeviceListUpdated=!0;var r=t._workerManager.getSupportedWorkers(t._options.feature);t._options.localGumIsCallable&&r.unshift(n),t._showDeviceList(r),e&&e()&&0===r.length&&!t._options.localGumIsCallable&&(t._element.querySelector("#deviceList").innerHTML="<p>None</p>")}))}},{key:"_showDeviceList",value:function(e){var t,n=this._element.querySelector("#deviceList"),r=n.querySelectorAll(".form-device-input"),o=new Set,i=r.length,a=p(r);try{var c=function(){var n=t.value;-1===e.findIndex((function(e){return e.id===n.value}))?(n.parentNode.remove(),i--):o.add(n.id)};for(a.s();!(t=a.n()).done;)c()}catch(e){a.e(e)}finally{a.f()}0===r.length&&(n.innerHTML="");for(var u=0;u<e.length;u++)if(!o.has(e[u].id)){var l=document.createRange().createContextualFragment((0,s.default)({id:e[u].id,name:e[u].name,checked:0===i&&0===u}));n.appendChild(l),i++}this._element.querySelector("#alwaysForm").style.display=i>0?"block":"none",r.length>0!=i>0&&this.setFocus(0)}},{key:"updateSignalingStatus",value:function(){var e=this._element.querySelector("#signalingStatus");e&&this._workerManager.signalingStatus?e.src=l.default:e.src=f.default}},{key:"clearUpdateInterval",value:function(){this._updateIntervalID&&(w.debug("Capability Interval Ended."),clearInterval(this._updateIntervalID),this._updateIntervalID=0)}},{key:"startUpdateInterval",value:function(){var e=this;this.clearUpdateInterval(),w.debug("Capability Interval Starting...");var t=0;this.isDeviceListUpdated=!1,this._updateIntervalID=setInterval((function(){e.updateDeviceList((function(){return(t+=1e3)>=1e4&&(e.clearUpdateInterval(),!0)}))}),1e3),this.updateDeviceList()}},{key:"clearSignalingStatusInterval",value:function(){this._signalingIntervalID&&(clearInterval(this._signalingIntervalID),this._signalingIntervalID=0)}},{key:"startSignalingStatusInterval",value:function(){this.clearSignalingStatusInterval(),this._signalingIntervalID=setInterval(this.updateSignalingStatus.bind(this),1e3)}}])&&g(t.prototype,n),r&&g(t,r),i}(o.EventEmitter);t.DevicePopup=k},function(e,t,n){var r=n(64);e.exports=function(){var e=new r.Template({code:function(e,t,n){var r=this;return r.b(n=n||""),r.b('<div class="form-check">'),r.b("\n"+n),r.b("  <input"),r.b("\n"+n),r.b('    class="form-device-input"'),r.b("\n"+n),r.b('    type="radio"'),r.b("\n"+n),r.b('    name="radios"'),r.b("\n"+n),r.b('    id="'),r.b(r.v(r.f("id",e,t,0))),r.b('"'),r.b("\n"+n),r.b('    value="'),r.b(r.v(r.f("id",e,t,0))),r.b('"'),r.b("\n"+n),r.b("    tabindex=0"),r.b("\n"+n),r.s(r.f("checked",e,t,1),e,t,0,165,182,"{{ }}")&&(r.rs(e,t,(function(e,t,r){r.b("    checked"),r.b("\n"+n)})),e.pop()),r.b("  >"),r.b("\n"+n),r.b('  <label class="form-check-label" for="'),r.b(r.v(r.f("id",e,t,0))),r.b('">'),r.b("\n"+n),r.b("    "),r.b(r.v(r.f("name",e,t,0))),r.b("\n"+n),r.b("  </label>"),r.b("\n"+n),r.b("</div>"),r.b("\n"),r.fl()},partials:{},subs:{}},'<div class="form-check">\n  <input\n    class="form-device-input"\n    type="radio"\n    name="radios"\n    id="{{id}}"\n    value="{{id}}"\n    tabindex=0\n    {{#checked}}\n    checked\n    {{/checked}}\n  >\n  <label class="form-check-label" for="{{id}}">\n    {{name}}\n  </label>\n</div>\n',r);return e.render.apply(e,arguments)}},function(e,t,n){!function(e){var t=/\S/,n=/\"/g,r=/\n/g,o=/\r/g,i=/\\/g,s=/\u2028/,a=/\u2029/;function c(e){"}"===e.n.substr(e.n.length-1)&&(e.n=e.n.substring(0,e.n.length-1))}function u(e){return e.trim?e.trim():e.replace(/^\s*|\s*$/g,"")}function l(e,t,n){if(t.charAt(n)!=e.charAt(0))return!1;for(var r=1,o=e.length;r<o;r++)if(t.charAt(n+r)!=e.charAt(r))return!1;return!0}e.tags={"#":1,"^":2,"<":3,$:4,"/":5,"!":6,">":7,"=":8,_v:9,"{":10,"&":11,_t:12},e.scan=function(n,r){var o=n.length,i=0,s=null,a=null,f="",h=[],p=!1,d=0,g=0,y="{{",v="}}";function m(){f.length>0&&(h.push({tag:"_t",text:new String(f)}),f="")}function b(n,r){if(m(),n&&function(){for(var n=!0,r=g;r<h.length;r++)if(!(n=e.tags[h[r].tag]<e.tags._v||"_t"==h[r].tag&&null===h[r].text.match(t)))return!1;return n}())for(var o,i=g;i<h.length;i++)h[i].text&&((o=h[i+1])&&">"==o.tag&&(o.indent=h[i].text.toString()),h.splice(i,1));else r||h.push({tag:"\n"});p=!1,g=h.length}function w(e,t){var n="="+v,r=e.indexOf(n,t),o=u(e.substring(e.indexOf("=",t)+1,r)).split(" ");return y=o[0],v=o[o.length-1],r+n.length-1}for(r&&(r=r.split(" "),y=r[0],v=r[1]),d=0;d<o;d++)0==i?l(y,n,d)?(--d,m(),i=1):"\n"==n.charAt(d)?b(p):f+=n.charAt(d):1==i?(d+=y.length-1,"="==(s=(a=e.tags[n.charAt(d+1)])?n.charAt(d+1):"_v")?(d=w(n,d),i=0):(a&&d++,i=2),p=d):l(v,n,d)?(h.push({tag:s,n:u(f),otag:y,ctag:v,i:"/"==s?p-y.length:d+v.length}),f="",d+=v.length-1,i=0,"{"==s&&("}}"==v?d++:c(h[h.length-1]))):f+=n.charAt(d);return b(p,!0),h};var f={_t:!0,"\n":!0,$:!0,"/":!0};function h(e,t){for(var n=0,r=t.length;n<r;n++)if(t[n].o==e.n)return e.tag="#",!0}function p(e,t,n){for(var r=0,o=n.length;r<o;r++)if(n[r].c==e&&n[r].o==t)return!0}function d(e){var t=[];for(var n in e.partials)t.push('"'+y(n)+'":{name:"'+y(e.partials[n].name)+'", '+d(e.partials[n])+"}");return"partials: {"+t.join(",")+"}, subs: "+function(e){var t=[];for(var n in e)t.push('"'+y(n)+'": function(c,p,t,i) {'+e[n]+"}");return"{ "+t.join(",")+" }"}(e.subs)}e.stringify=function(t,n,r){return"{code: function (c,p,i) { "+e.wrapMain(t.code)+" },"+d(t)+"}"};var g=0;function y(e){return e.replace(i,"\\\\").replace(n,'\\"').replace(r,"\\n").replace(o,"\\r").replace(s,"\\u2028").replace(a,"\\u2029")}function v(e){return~e.indexOf(".")?"d":"f"}function m(e,t){var n="<"+(t.prefix||"")+e.n+g++;return t.partials[n]={name:e.n,partials:{}},t.code+='t.b(t.rp("'+y(n)+'",c,p,"'+(e.indent||"")+'"));',n}function b(e,t){t.code+="t.b(t.t(t."+v(e.n)+'("'+y(e.n)+'",c,p,0)));'}function w(e){return"t.b("+e+");"}e.generate=function(t,n,r){g=0;var o={code:"",subs:{},partials:{}};return e.walk(t,o),r.asString?this.stringify(o,n,r):this.makeTemplate(o,n,r)},e.wrapMain=function(e){return'var t=this;t.b(i=i||"");'+e+"return t.fl();"},e.template=e.Template,e.makeTemplate=function(e,t,n){var r=this.makePartials(e);return r.code=new Function("c","p","i",this.wrapMain(e.code)),new this.template(r,t,this,n)},e.makePartials=function(e){var t,n={subs:{},partials:e.partials,name:e.name};for(t in n.partials)n.partials[t]=this.makePartials(n.partials[t]);for(t in e.subs)n.subs[t]=new Function("c","p","t","i",e.subs[t]);return n},e.codegen={"#":function(t,n){n.code+="if(t.s(t."+v(t.n)+'("'+y(t.n)+'",c,p,1),c,p,0,'+t.i+","+t.end+',"'+t.otag+" "+t.ctag+'")){t.rs(c,p,function(c,p,t){',e.walk(t.nodes,n),n.code+="});c.pop();}"},"^":function(t,n){n.code+="if(!t.s(t."+v(t.n)+'("'+y(t.n)+'",c,p,1),c,p,1,0,0,"")){',e.walk(t.nodes,n),n.code+="};"},">":m,"<":function(t,n){var r={partials:{},code:"",subs:{},inPartial:!0};e.walk(t.nodes,r);var o=n.partials[m(t,n)];o.subs=r.subs,o.partials=r.partials},$:function(t,n){var r={subs:{},code:"",partials:n.partials,prefix:t.n};e.walk(t.nodes,r),n.subs[t.n]=r.code,n.inPartial||(n.code+='t.sub("'+y(t.n)+'",c,p,i);')},"\n":function(e,t){t.code+=w('"\\n"'+(e.last?"":" + i"))},_v:function(e,t){t.code+="t.b(t.v(t."+v(e.n)+'("'+y(e.n)+'",c,p,0)));'},_t:function(e,t){t.code+=w('"'+y(e.text)+'"')},"{":b,"&":b},e.walk=function(t,n){for(var r,o=0,i=t.length;o<i;o++)(r=e.codegen[t[o].tag])&&r(t[o],n);return n},e.parse=function(t,n,r){return function t(n,r,o,i){var s,a=[],c=null,u=null;for(s=o[o.length-1];n.length>0;){if(u=n.shift(),s&&"<"==s.tag&&!(u.tag in f))throw new Error("Illegal content in < super tag.");if(e.tags[u.tag]<=e.tags.$||h(u,i))o.push(u),u.nodes=t(n,u.tag,o,i);else{if("/"==u.tag){if(0===o.length)throw new Error("Closing tag without opener: /"+u.n);if(c=o.pop(),u.n!=c.n&&!p(u.n,c.n,i))throw new Error("Nesting error: "+c.n+" vs. "+u.n);return c.end=u.i,a}"\n"==u.tag&&(u.last=0==n.length||"\n"==n[0].tag)}a.push(u)}if(o.length>0)throw new Error("missing closing tag: "+o.pop().n);return a}(t,0,[],(r=r||{}).sectionTags||[])},e.cache={},e.cacheKey=function(e,t){return[e,!!t.asString,!!t.disableLambda,t.delimiters,!!t.modelGet].join("||")},e.compile=function(t,n){n=n||{};var r=e.cacheKey(t,n),o=this.cache[r];if(o){var i=o.partials;for(var s in i)delete i[s].instance;return o}return o=this.generate(this.parse(this.scan(t,n.delimiters),t,n),t,n),this.cache[r]=o}}(t)},function(e,t,n){!function(e){function t(e,t,n){var r;return t&&"object"==typeof t&&(void 0!==t[e]?r=t[e]:n&&t.get&&"function"==typeof t.get&&(r=t.get(e))),r}e.Template=function(e,t,n,r){e=e||{},this.r=e.code||this.r,this.c=n,this.options=r||{},this.text=t||"",this.partials=e.partials||{},this.subs=e.subs||{},this.buf=""},e.Template.prototype={r:function(e,t,n){return""},v:function(e){return e=c(e),a.test(e)?e.replace(n,"&amp;").replace(r,"&lt;").replace(o,"&gt;").replace(i,"&#39;").replace(s,"&quot;"):e},t:c,render:function(e,t,n){return this.ri([e],t||{},n)},ri:function(e,t,n){return this.r(e,t,n)},ep:function(e,t){var n=this.partials[e],r=t[n.name];if(n.instance&&n.base==r)return n.instance;if("string"==typeof r){if(!this.c)throw new Error("No compiler available.");r=this.c.compile(r,this.options)}if(!r)return null;if(this.partials[e].base=r,n.subs){for(key in t.stackText||(t.stackText={}),n.subs)t.stackText[key]||(t.stackText[key]=void 0!==this.activeSub&&t.stackText[this.activeSub]?t.stackText[this.activeSub]:this.text);r=function(e,t,n,r,o,i){function s(){}function a(){}var c;s.prototype=e,a.prototype=e.subs;var u=new s;for(c in u.subs=new a,u.subsText={},u.buf="",r=r||{},u.stackSubs=r,u.subsText=i,t)r[c]||(r[c]=t[c]);for(c in r)u.subs[c]=r[c];for(c in o=o||{},u.stackPartials=o,n)o[c]||(o[c]=n[c]);for(c in o)u.partials[c]=o[c];return u}(r,n.subs,n.partials,this.stackSubs,this.stackPartials,t.stackText)}return this.partials[e].instance=r,r},rp:function(e,t,n,r){var o=this.ep(e,n);return o?o.ri(t,n,r):""},rs:function(e,t,n){var r=e[e.length-1];if(u(r))for(var o=0;o<r.length;o++)e.push(r[o]),n(e,t,this),e.pop();else n(e,t,this)},s:function(e,t,n,r,o,i,s){var a;return(!u(e)||0!==e.length)&&("function"==typeof e&&(e=this.ms(e,t,n,r,o,i,s)),a=!!e,!r&&a&&t&&t.push("object"==typeof e?e:t[t.length-1]),a)},d:function(e,n,r,o){var i,s=e.split("."),a=this.f(s[0],n,r,o),c=this.options.modelGet,l=null;if("."===e&&u(n[n.length-2]))a=n[n.length-1];else for(var f=1;f<s.length;f++)void 0!==(i=t(s[f],a,c))?(l=a,a=i):a="";return!(o&&!a)&&(o||"function"!=typeof a||(n.push(l),a=this.mv(a,n,r),n.pop()),a)},f:function(e,n,r,o){for(var i=!1,s=!1,a=this.options.modelGet,c=n.length-1;c>=0;c--)if(void 0!==(i=t(e,n[c],a))){s=!0;break}return s?(o||"function"!=typeof i||(i=this.mv(i,n,r)),i):!o&&""},ls:function(e,t,n,r,o){var i=this.options.delimiters;return this.options.delimiters=o,this.b(this.ct(c(e.call(t,r)),t,n)),this.options.delimiters=i,!1},ct:function(e,t,n){if(this.options.disableLambda)throw new Error("Lambda features disabled.");return this.c.compile(e,this.options).render(t,n)},b:function(e){this.buf+=e},fl:function(){var e=this.buf;return this.buf="",e},ms:function(e,t,n,r,o,i,s){var a,c=t[t.length-1],u=e.call(c);return"function"==typeof u?!!r||(a=this.activeSub&&this.subsText&&this.subsText[this.activeSub]?this.subsText[this.activeSub]:this.text,this.ls(u,c,n,a.substring(o,i),s)):u},mv:function(e,t,n){var r=t[t.length-1],o=e.call(r);return"function"==typeof o?this.ct(c(o.call(r)),r,n):o},sub:function(e,t,n,r){var o=this.subs[e];o&&(this.activeSub=e,o(t,n,this,r),this.activeSub=!1)}};var n=/&/g,r=/</g,o=/>/g,i=/\'/g,s=/\"/g,a=/[&<>\"\']/;function c(e){return String(null==e?"":e)}var u=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)}}(t)},function(e,t,n){var r=n(64);e.exports=function(){var e=new r.Template({code:function(e,t,n){var r=this;return r.b(n=n||""),r.b('<div class="modal-dialog" role="document">'),r.b("\n"+n),r.b('  <div class="modal-content">'),r.b("\n"+n),r.b('    <div class="modal-header">'),r.b("\n"+n),r.b('      <span class="modal-title mr-auto">Available devices</span>'),r.b("\n"+n),r.b('      <img width="24" src="'),r.b(r.v(r.f("SIGNAL_IMG",e,t,0))),r.b('" />'),r.b("\n"+n),r.b('      <img width="24" id="signalingStatus" src="'),r.b(r.v(r.f("ENABLE_IMG",e,t,0))),r.b('" />'),r.b("\n"+n),r.b("    </div>"),r.b("\n"+n),r.b('    <div class="modal-body">'),r.b("\n"+n),r.b('      <div class="row-container">'),r.b("\n"+n),r.b('        <div id="deviceList">'),r.b("\n"+n),r.b("        </div>"),r.b("\n"+n),r.b('        <div class="vertical-align-center">'),r.b("\n"+n),r.b("          <image"),r.b("\n"+n),r.b('            id="qrCodeImage"'),r.b("\n"+n),r.b('            width="132"'),r.b("\n"+n),r.b('            height="132"'),r.b("\n"+n),r.b('            style="display:none;"'),r.b("\n"+n),r.b("          />"),r.b("\n"+n),r.b("        </div>"),r.b("\n"+n),r.b("      </div>"),r.b("\n"+n),r.b('      <div class="form-check" id="alwaysForm">'),r.b("\n"+n),r.b("        <input"),r.b("\n"+n),r.b('          class="form-check-input"'),r.b("\n"+n),r.b('          type="checkbox"'),r.b("\n"+n),r.b('          id="alwaysCb"'),r.b("\n"+n),r.b("          tabindex=0"),r.b("\n"+n),r.s(r.f("alwaysUseSameDevice",e,t,1),e,t,0,817,846,"{{ }}")&&(r.rs(e,t,(function(e,t,r){r.b("          checked"),r.b("\n"+n)})),e.pop()),r.b("        >"),r.b("\n"+n),r.b('        <label class="form-check-label" for="alwaysCb">'),r.b("\n"+n),r.b("          Always connect to selected device"),r.b("\n"+n),r.b("        </label>"),r.b("\n"+n),r.b("      </div>"),r.b("\n"+n),r.b("    </div>"),r.b("\n"+n),r.b('    <div class="modal-footer">'),r.b("\n"+n),r.b('      <button type="button" class="btn btn-success mr-auto" id="refreshBtn" tabindex=0>Scan</button>'),r.b("\n"+n),r.b('      <button type="button" class="btn btn-primary" id="connectBtn" tabindex=0>Connect</button>'),r.b("\n"+n),r.b('      <button type="button" class="btn btn-secondary" id="closeBtn" tabindex=0>Close</button>'),r.b("\n"+n),r.b("    </div>"),r.b("\n"+n),r.b("  </div>"),r.b("\n"+n),r.b("</div>"),r.b("\n"),r.fl()},partials:{},subs:{}},'<div class="modal-dialog" role="document">\n  <div class="modal-content">\n    <div class="modal-header">\n      <span class="modal-title mr-auto">Available devices</span>\n      <img width="24" src="{{SIGNAL_IMG}}" />\n      <img width="24" id="signalingStatus" src="{{ENABLE_IMG}}" />\n    </div>\n    <div class="modal-body">\n      <div class="row-container">\n        <div id="deviceList">\n        </div>\n        <div class="vertical-align-center">\n          <image\n            id="qrCodeImage"\n            width="132"\n            height="132"\n            style="display:none;"\n          />\n        </div>\n      </div>\n      <div class="form-check" id="alwaysForm">\n        <input\n          class="form-check-input"\n          type="checkbox"\n          id="alwaysCb"\n          tabindex=0\n          {{#alwaysUseSameDevice}}\n          checked\n          {{/alwaysUseSameDevice}}\n        >\n        <label class="form-check-label" for="alwaysCb">\n          Always connect to selected device\n        </label>\n      </div>\n    </div>\n    <div class="modal-footer">\n      <button type="button" class="btn btn-success mr-auto" id="refreshBtn" tabindex=0>Scan</button>\n      <button type="button" class="btn btn-primary" id="connectBtn" tabindex=0>Connect</button>\n      <button type="button" class="btn btn-secondary" id="closeBtn" tabindex=0>Close</button>\n    </div>\n  </div>\n</div>\n',r);return e.render.apply(e,arguments)}},function(e,t,n){var r=n(78);e.exports="string"==typeof r?r:r.toString()},function(e,t,n){(t=n(79)(!1)).push([e.i,":host {\n  all: initial;\n}\n\n.modal {\n  position: fixed;\n  top: 0;\n  left: 0;\n  z-index: 1000;\n  width: 100%;\n  height: 100%;\n  outline: 0;\n  display: none;\n}\n\n.overlay {\n  position: fixed;\n  top: 0;\n  bottom: 0;\n  left: 0;\n  right: 0;\n  background: rgba(0, 0, 0, 0.7);\n  visibility: visible;\n  opacity: 1;\n}\n\n.modal.show {\n  background: rgba(0, 0, 0, 0.7);\n  opacity: 1;\n  display: block;\n}\n\n.modal-open {\n  overflow: hidden;\n}\n\n.modal-open .modal {\n  overflow-x: hidden;\n  overflow-y: auto;\n}\n\n.modal-dialog {\n  position: relative;\n  width: auto;\n}\n\n@media (min-width: 576px) {\n  .modal-dialog {\n    max-width: 500px;\n    margin: 10px auto;\n  }\n}\n\n.modal-content {\n  position: relative;\n  display: flex;\n  flex-direction: column;\n  width: 100%;\n  pointer-events: auto;\n  background-color: #fff;\n  background-clip: padding-box;\n  border: 1px solid rgba(0, 0, 0, 0.2);\n  border-radius: 10px;\n  color: #000;\n  outline: 0;\n}\n\n.modal-header {\n  display: flex;\n  align-items: flex-start;\n  justify-content: space-between;\n  padding: 10px;\n  border-bottom: 1px solid #dee2e6;\n  border-top-left-radius: 10px;\n  border-top-right-radius: 10px;\n}\n\n.modal-header img {\n  margin-left: 5px;\n}\n\n.modal-title {\n  color: #007bff;\n  font-weight: 900;\n}\n\n.modal-body {\n  position: relative;\n  flex: 1 1 auto;\n  padding: 10px;\n  border-radius: 10px;\n}\n\n.form-check-input:focus,\n.form-device-input:focus {\n  box-shadow: 0 0 0 5px black;\n}\n\n.modal-footer {\n  display: flex;\n  flex-wrap: wrap;\n  align-items: center;\n  justify-content: center;\n  padding: 10px;\n  border-top: 1px solid #dee2e6;\n  border-bottom-left-radius: 10px;\n  border-bottom-right-radius: 10px;\n}\n\n.modal-footer > * {\n  margin: 0 5px;\n}\n\n.modal-footer > .btn {\n  display: inline-block;\n  font-weight: 400;\n  text-align: center;\n  vertical-align: middle;\n  user-select: none;\n  padding: 5px 10px;\n  font-size: 20px;\n  line-height: 1.5;\n  border-radius: 10px;\n}\n\n.modal-footer > .btn:focus {\n  box-shadow: 0 0 0 5px black;\n}\n\n.modal-footer > .btn.btn-primary {\n  color: #fff;\n  background-color: #007bff;\n  border-color: #007bff;\n}\n\n.modal-footer > .btn.btn-secondary {\n  color: #fff;\n  background-color: #6c757d;\n  border-color: #6c757d;\n}\n\n.modal-footer > .btn.btn-success {\n  color: #fff;\n  background-color: #28a745;\n  border-color: #28a745;\n}\n\n.mr-auto {\n  margin-right: auto !important;\n}\n\n.row-container {\n  display: flex;\n  justify-content: space-between;\n}\n\n.vertical-align-center {\n  display: flex;\n  flex-direction: column;\n  align-items: center;\n}\n",""]),e.exports=t},function(e,t,n){"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n=function(e,t){var n=e[1]||"",r=e[3];if(!r)return n;if(t&&"function"==typeof btoa){var o=(s=r,a=btoa(unescape(encodeURIComponent(JSON.stringify(s)))),c="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(a),"/*# ".concat(c," */")),i=r.sources.map((function(e){return"/*# sourceURL=".concat(r.sourceRoot||"").concat(e," */")}));return[n].concat(i).concat([o]).join("\n")}var s,a,c;return[n].join("\n")}(t,e);return t[2]?"@media ".concat(t[2]," {").concat(n,"}"):n})).join("")},t.i=function(e,n,r){"string"==typeof e&&(e=[[null,e,""]]);var o={};if(r)for(var i=0;i<this.length;i++){var s=this[i][0];null!=s&&(o[s]=!0)}for(var a=0;a<e.length;a++){var c=[].concat(e[a]);r&&o[c[0]]||(n&&(c[2]?c[2]="".concat(n," and ").concat(c[2]):c[2]=n),t.push(c))}},t}},function(e,t,n){"use strict";n.r(t),t.default="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAACXBIWXMAAAsTAAALEwEAmpwYAAAGgUlEQVR4nO2bW2xVRRSGv7bcEgHBgiCE4hUCQVSQW4JFELEqD17ACyYEkAKCEeOD4hM+mIjEGDUx3ohAC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GWLN7Mw9tf5rHdm3EthTMPjcg3o5yNVfxJMCrmQBpwgiXNOreVyIgMLWnjyUz53Py7IUsmHKYf4CCcfWFXDUATirSofwb1xcgE+P/bctQc5SNe3e8CPpTL4K+iRdGh0HZH+DHgBuSBM+rngBpKfnG9Mnk4zcPZDCjp59jph3BUVNnM39gFof1TXWNKPWs5lS0YrGqBSFKNIC3/VIkoXKXmGrYFjuGX2DT4E42vrCd9c9vYffokP9v73fD4YMIHwwl3f+eBAhNJRkfQ/g9hIH9jtQsgHMcnTaY2TvArO4pzOidwszuAWcuemp1l4rtqXVF2fzRVsOlokdbTafWd40Nurug7hzby66RQbfrnUMHYA6o03QQ5TPk/GnRzDFJgEI+z+uo8WngcpiA0F3DGwNiBGMEg1PnBMGpdveyiloFW3LLwgOTf6PFtfwuPyeSSQKkLefwexjeyESKvkxnxfJj4DNx6/YkAarlXWScxzuAaxDO4ZUoyp3A5/ge3+Kb5ACTBNh3EW7mEkcJuAhh1iEO+k6U2xB3pe7KSO9MEuAA5XMcSb0gA2cj9B4ioI8A9wDfpMlKruFZXiEivFLlJo7H8BZgGXAmcBRC90ECfAx4BrgXuBvLXVzNE7wCRXg1yF/SSy+LyRwRXo+yFDge6EeQCWgHGgKeQFgN/IycexlhHb/PCC+bTBKg+uplyxyExcBilEUIx6AsQJgOTAFmIEgAmd3AXv+MpI0+N78eWIeyDsM214n7CpVJmZRJmZRJmZRJmZRJmZRJmZRJmZRJmZT/B1SpnBPNoYAnAAAAAElFTkSuQmCC"},function(e,t,n){"use strict";n.r(t),t.default="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAIAAAACACAYAAADDPmHLAAAlA0lEQVR4Xu2dCbBdxXnnf93n3nff/rQLCe1iETL7vhtjgx1AeBnjeDLxjGucKgGG2LEn8aQSm4A95bgc18RLMMqMM05mpiYxnklsP7wbowQKEBhjiCUhoR3telrfdu89p3skna76St3V57zHe8IC3lfV1X36HGzV/f/7W7v78aaRCZmQCZmQCZmQCZmQCZ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TSqoiHREpML4HFCaIXLRWBTQ5oZDh0aZk/fAHv29rNz1xGODNRpQny1l4P/K+AeKem+SQkA8DXorMKngI8r6GSUYiWPgAaqWtHeWqG7s0ZXVyvdXS10HR13dNSoVROqVU1LS0UUANBopDSbhnozY2CgzpH+OoePNDhyZJjDR8eDwylNYzFAAuhXf960H/jLJnzhnnzMm5wAIn8F51fgfgXvYQxiXTOuOfVMRYFWCqXV8V4YAMZarLHH+9SKmdEC9ngcM/2nFO77KLyAyAQBQieRD+hcG1zFOIkteVYncWVYeNLAX94F36JcJggAcAckb4d3K7hXwQ28DsXCYxa++jP4zsOQAUwQYPSiHoLbgDsU3KJg6ikOeh/wAwvfuhN6PWUzQYCxyFdhdlXIcI2CtlME9CELTwAPN6H3XthBKBMEGOftZ2dreCtwrYIrgXkKaq8R4HVgq4WngMcNrLwbXuJ1KIo3gHwJ2tpgcZIT4WLgcuBsoEOBYuy1wAFygFcBz2Xw1BBs+CQM8ZuUCQLETy8bmKFgMbBYwSJgITAXmAR0AZO9PeMHgCPAQWAbsMnCRmCDhQ0a9shO3NefTMiETMiETMiETMiETMiETMiETMiETMiE/H+NKm6SUuq55AAAAABJRU5ErkJggg=="},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"GUMResource",{enumerable:!0,get:function(){return r.GUMResource}}),Object.defineProperty(t,"HAMResource",{enumerable:!0,get:function(){return o.HAMResource}}),Object.defineProperty(t,"SensorResource",{enumerable:!0,get:function(){return i.SensorResource}});var r=n(84),o=n(85),i=n(86)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.GUMResource=void 0;var r,o=n(26);function i(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return s(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return s(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,c=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){c=!0,i=e},f:function(){try{a||null==n.return||n.return()}finally{if(c)throw i}}}}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function a(e){return(a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function c(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function u(e,t,n){return(u="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=p(e)););return e}(e,t);if(r){var o=Object.getOwnPropertyDescriptor(r,t);return o.get?o.get.call(n):o.value}})(e,t,n||e)}function l(e,t){return(l=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function f(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=p(e);if(t){var o=p(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return h(this,n)}}function h(e,t){return!t||"object"!==a(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function p(e){return(p=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var d=new(((r=n(1))&&r.__esModule?r:{default:r}).default)("gum.js"),g=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&l(e,t)}(s,e);var t,n,r,o=f(s);function s(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,s),(n=o.call(this,e,t))._hasLocalVideoInput=!1,n._hasLocalAudioInput=!1,n._checkElapsedTime=0,n}return t=s,(n=[{key:"checkIfLocalUserMediaExists",value:function(){var e=this;return new Promise((function(t,n){e._nativeEnumerateDevices().then((function(n){n.forEach((function(t){switch(t.kind){case"videoinput":e._hasLocalVideoInput=!0;break;case"audioinput":e._hasLocalAudioInput=!0;break;case"audiooutput":break;default:d.error("Unknown device kind.")}})),t()})).catch((function(e){n(e)}))}))}},{key:"checkConstraintsType",value:function(e){return void 0!==e.video&&!1!==e.video?"CAMERA":void 0!==e.audio&&!1!==e.audio?"MIC":"NONE"}},{key:"checkLocalGumIsCallable",value:function(e){var t=this;return new Promise((function(n,r){try{void 0!==e.video&&!1!==e.video&&!1===t._hasLocalVideoInput&&n(!1),void 0!==e.audio&&!1!==e.audio&&!1===t._hasLocalAudioInput&&n(!1),n(!0)}catch(e){r(e)}}))}},{key:"printErrorMessage",value:function(e){d.error(e.name+": "+e.message)}},{key:"getUserMediaDeprecated",value:function(){for(var e=this,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var o=[].slice.call(n),i=o[0]||{},s=o[1],a=o[2],c=this.checkConstraintsType(i);"NONE"!==c?this.checkIfLocalUserMediaExists().then((function(){e.checkLocalGumIsCallable(i).then((function(t){e.startJob({feature:c,arguments:[i],successCallback:s,errorCallback:a,localGumIsCallable:t,nativeGetUserMedia:e._nativeGetUserMedia})})).catch((function(t){return e.printErrorMessage(t)}))})).catch((function(t){return e.printErrorMessage(t)})):a(new TypeError("The list of constraints specified is empty, or has all constraints set to false."))}},{key:"getUserMedia",value:function(){for(var e=this,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var o=[].slice.call(n),i=o[0]||{},s=this.checkConstraintsType(i);return new Promise((function(t,n){"NONE"!==s?e.checkIfLocalUserMediaExists().then((function(){e.checkLocalGumIsCallable(i).then((function(r){e.startJob({feature:s,arguments:[i],successCallback:t,errorCallback:n,localGumIsCallable:r,nativeGetUserMedia:e._nativeGetUserMedia})})).catch((function(t){return e.printErrorMessage(t)}))})).catch((function(t){return e.printErrorMessage(t)})):n(new TypeError("The list of constraints specified is empty, or has all constraints set to false."))}))}},{key:"checkAndAddRemoteMediaDeviceInfos",value:function(e,t,n){try{var r=this._workerManager.getWorkerInfos();if(!r.size&&this._checkElapsedTime<3e3)return setTimeout(this.checkAndAddRemoteMediaDeviceInfos.bind(this),500,e,t,n),void(this._checkElapsedTime+=500);r.forEach((function(t,n,r){t.mediaDeviceInfos.forEach((function(t){e.push(t)}))})),t(e)}catch(e){n(e)}}},{key:"injectOffloadAPI",value:function(){var e=this;d.debug("inject getUserMedia API"),this._nativeGetUserMediaDeprecated=navigator.getUserMedia.bind(navigator),this._nativeGetUserMedia=navigator.mediaDevices.getUserMedia.bind(navigator.mediaDevices),navigator.getUserMedia=this.getUserMediaDeprecated.bind(this),navigator.mediaDevices.getUserMedia=this.getUserMedia.bind(this),this._nativeEnumerateDevices=navigator.mediaDevices.enumerateDevices.bind(navigator.mediaDevices),navigator.mediaDevices.enumerateDevices=function(){return new Promise((function(t,n){e._nativeEnumerateDevices().then((function(r){e.checkAndAddRemoteMediaDeviceInfos.call(e,r,t,n)})).catch((function(e){n(e)}))}))}}},{key:"startJob",value:function(e){var t=e.arguments[0];if(t.hasOwnProperty("video")&&null!==t.video.deviceId){var n=t.video.deviceId;"object"===a(t.video.deviceId)&&t.video.deviceId.hasOwnProperty("exact")&&(n=t.video.deviceId.exact);var r,o=this._workerManager.getWorkerInfos(),c=i(o.keys());try{for(c.s();!(r=c.n()).done;){var l,f=r.value,h=i(o.get(f).mediaDeviceInfos);try{for(h.s();!(l=h.n()).done;)if(l.value.deviceId===n)return void u(p(s.prototype),"startJobImpl",this).call(this,f,e)}catch(e){h.e(e)}finally{h.f()}}}catch(e){c.e(e)}finally{c.f()}}u(p(s.prototype),"startJob",this).call(this,e)}}])&&c(t.prototype,n),r&&c(t,r),s}(o.Resource);t.GUMResource=g},function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.HAMResource=void 0;var o,i=n(26);function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function a(e,t){return(a=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function c(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=l(e);if(t){var o=l(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return u(this,n)}}function u(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function l(e){return(l=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var f=new(((o=n(1))&&o.__esModule?o:{default:o}).default)("ham.js"),h=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&a(e,t)}(i,e);var t,n,r,o=c(i);function i(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),(n=o.call(this,e,t))._listenerId=0,n}return t=i,(n=[{key:"start",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=[].slice.call(t);this.startJob({feature:r[0],successCallback:r[1]})}},{key:"stop",value:function(e){this.stopJob(e)}},{key:"addGestureRecognitionListener",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=[].slice.call(t);return this.startJob({feature:"GESTURE",successCallback:r[1],errorCallback:r[2]}),++this._listenerId}},{key:"injectOffloadAPI",value:function(){"undefined"==typeof tizen&&(window.tizen={}),void 0===tizen.ppm&&(tizen.ppm={},tizen.ppm.requestPermission=function(){var e=arguments.length<=0?void 0:arguments[0],t=arguments.length<=1?void 0:arguments[1];t("PPM_ALLOW_FOREVER",e)},tizen.ppm.requestPermissions=function(){var e=arguments.length<=0?void 0:arguments[0],t=[];e.forEach((function(e){var n={};n.privilege=e,n.result="PPM_ALLOW_FOREVER",t.push(n)}));var n=arguments.length<=1?void 0:arguments[1];return n(t),t},tizen.ppm.checkPermission=function(){return"PPM_ALLOW"},tizen.ppm.checkPermissions=function(){var e=arguments.length<=0?void 0:arguments[0],t=[];return e.forEach((function(e){var n={};n.privilege=e,n.type="PPM_ALLOW",t.push(n)})),t}),tizen.humanactivitymonitor||(f.debug("inject tizen.humanactivitymonitor API"),tizen.humanactivitymonitor={},tizen.humanactivitymonitor.start=this.start.bind(this),tizen.humanactivitymonitor.stop=this.stop.bind(this),tizen.humanactivitymonitor.addGestureRecognitionListener=this.addGestureRecognitionListener.bind(this))}}])&&s(t.prototype,n),r&&s(t,r),i}(i.Resource);t.HAMResource=h},function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.SensorResource=void 0;var o,i=n(26);function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function a(e,t){return(a=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function c(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=l(e);if(t){var o=l(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return u(this,n)}}function u(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function l(e){return(l=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var f=new(((o=n(1))&&o.__esModule?o:{default:o}).default)("sensor.js"),h=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&a(e,t)}(i,e);var t,n,r,o=c(i);function i(e,t){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),(n=o.call(this,e,t))._type=null,n._intervalID=null,n._started=!1,n}return t=i,(n=[{key:"_convertSensorDataName",value:function(e){return e.split("_").map((function(e){return"HRM"===e?e:(e=e.toLowerCase()).charAt(0).toUpperCase()+e.slice(1)})).join("")}},{key:"_start",value:function(){var e=this;if(f.debug("start"),this._started)f.debug("sensor is already started");else{for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var o=[].slice.call(n);this.startJob({feature:"SENSOR",arguments:["start",this._type],successCallback:o[0],errorCallback:o[1],resolver:function(){e._started=!0}})}}},{key:"_stop",value:function(){f.debug("stop"),this._started&&(this.stopJob("SENSOR"),this._started=!1,null!==this._intervalID&&clearInterval(this._intervalID))}},{key:"_getSensorData",value:function(e,t){f.debug("getSensorData"),this.startJob({feature:"SENSOR",arguments:["getSensorData",this._convertSensorDataName(this._type)],successCallback:e,errorCallback:t})}},{key:"_setChangeListener",value:function(e,t,n){var r=this;f.debug("setChangeListener interval:".concat(t));var o=t||100;o<10?o=10:t>1e3&&(o=1e3),this._intervalID=setInterval((function(){r._started&&r.startJob({feature:"SENSOR",arguments:["getSensorData",r._convertSensorDataName(r._type)],successCallback:e})}),o)}},{key:"_unsetChangeListener",value:function(){f.debug("unsetChangeListener"),null!==this._intervalID&&clearInterval(this._intervalID)}},{key:"injectOffloadAPI",value:function(){var e=this;"undefined"==typeof tizen&&(f.debug("tizen is undefined"),window.tizen={}),void 0===tizen.sensorservice&&(f.debug("inject tizen.sensorservice API"),tizen.sensorservice={},tizen.sensorservice.getDefaultSensor=function(){var t={};return t.sensorType=e._type=arguments.length<=0?void 0:arguments[0],t.start=e._start.bind(e),t.stop=e._stop.bind(e),t["get".concat(e._convertSensorDataName(e._type),"SensorData")]=e._getSensorData.bind(e),t.setChangeListener=e._setChangeListener.bind(e),t.unsetChangeListener=e._unsetChangeListener.bind(e),t})}}])&&s(t.prototype,n),r&&s(t,r),i}(i.Resource);t.SensorResource=h}]).default;
\ No newline at end of file
diff --git a/device_home/signaling_server/gen/socket-tizen.js b/device_home/signaling_server/gen/socket-tizen.js
new file mode 100644 (file)
index 0000000..bb1f726
--- /dev/null
@@ -0,0 +1,70 @@
+const TAG = 'socket-tizen.js';
+
+class SocketTizen {
+  constructor(id, localPort) {
+    console.log(TAG, `SocketTizen created for ${id}`);
+    this._appId = id;
+    this._portName = 'offload';
+    this._localPort = localPort;
+    this._remotePort = null;
+    this._eventHandlers = {};
+  }
+
+  get id() {
+    return this._appId;
+  }
+
+  on(event, callback) {
+    this._eventHandlers[event] = callback.bind(null);
+  }
+
+  handleEvents(event, value) {
+    const handler = this._eventHandlers[event];
+    if (!handler) {
+      console.error(TAG, `Messageport ${event} handler is not found`);
+      return;
+    }
+
+    handler(value);
+  }
+
+  emit(event, message) {
+    console.log(TAG, `Messageport emit: ${event}`);
+    const value = message || {};
+    try {
+      this._remotePort.sendMessage(
+        [
+          {
+            key: event,
+            value: JSON.stringify(value)
+          }
+        ],
+        this._localPort
+      );
+    } catch (error) {
+      console.error(TAG, 'Messageport emit failed:' + error);
+      throw new Error('Messageport emit failed');
+    }
+  }
+
+  connect() {
+    console.log(TAG, `Messageport try to connect ${this._appId}`);
+    try {
+      this._remotePort = tizen.messageport.requestRemoteMessagePort(
+        this._appId,
+        this._portName
+      );
+
+      this.handleEvents('connection', this);
+      this.emit('connect');
+    } catch (error) {
+      console.error(TAG, `Messageport connection failed: ` + error);
+    }
+  }
+
+  close() {
+    // TODO: Need to implement
+  }
+}
+
+module.exports = SocketTizen;
diff --git a/device_home/signaling_server/gen/util.js b/device_home/signaling_server/gen/util.js
new file mode 100644 (file)
index 0000000..38a0e8e
--- /dev/null
@@ -0,0 +1,31 @@
+const os = require('os');
+
+function getMyAddress() {
+  const interfaces = os.networkInterfaces();
+  const addresses = {};
+  for (const intf in interfaces) {
+    if (interfaces.hasOwnProperty(intf)) {
+      for (const addr in interfaces[intf]) {
+        if (interfaces[intf].hasOwnProperty(addr)) {
+          const address = interfaces[intf][addr];
+          if (address.family === 'IPv4' && !address.internal) {
+            addresses[intf] = address.address;
+          }
+        }
+      }
+    }
+  }
+  if (Object.keys(addresses).length === 0) {
+    return null;
+  }
+
+  // Try to connect with 'wl' prefix interface first.
+  const wlanKeys = Object.keys(addresses).filter(intf => /^wl/.test(intf));
+  return wlanKeys.length > 0
+    ? addresses[wlanKeys[0]]
+    : Object.entries(addresses)[0][1];
+}
+
+module.exports = {
+  getMyAddress
+};