"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "dist/socket.io.esm.min.js.map" between
socket.io-client-4.5.1.tar.gz and socket.io-client-4.5.2.tar.gz

About: Socket.IO client is a Javascript client library for the browser (or a Node.js client) that enables real-time communication with an Socket.IO server.

socket.io.esm.min.js.map  (socket.io-client-4.5.1):socket.io.esm.min.js.map  (socket.io-client-4.5.2)
{"version":3,"file":"socket.io.esm.min.js","sources":["../node_modules/engine.io -client/node_modules/engine.io-parser/build/esm/commons.js","../node_modules/eng ine.io-client/node_modules/engine.io-parser/build/esm/encodePacket.browser.js"," ../node_modules/@socket.io/base64-arraybuffer/dist/base64-arraybuffer.es5.js",". ./node_modules/engine.io-client/node_modules/engine.io-parser/build/esm/decodePa cket.browser.js","../node_modules/engine.io-client/node_modules/engine.io-parser /build/esm/index.js","../node_modules/@socket.io/component-emitter/index.mjs",". ./node_modules/engine.io-client/build/esm/globalThis.browser.js","../node_module s/engine.io-client/build/esm/util.js","../node_modules/engine.io-client/build/es m/transport.js","../node_modules/engine.io-client/build/esm/contrib/yeast.js",". ./node_modules/engine.io-client/build/esm/contrib/parseqs.js","../node_modules/e ngine.io-client/build/esm/contrib/has-cors.js","../node_modules/engine.io-client /build/esm/transports/xmlhttprequest.browser.js","../node_modules/engine.io-clie nt/build/esm/transports/polling.js","../node_modules/engine.io-client/build/esm/ transports/websocket-constructor.browser.js","../node_modules/engine.io-client/b uild/esm/transports/websocket.js","../node_modules/engine.io-client/build/esm/tr ansports/index.js","../node_modules/engine.io-client/build/esm/contrib/parseuri. js","../node_modules/engine.io-client/build/esm/socket.js","../node_modules/sock et.io-parser/build/esm/is-binary.js","../node_modules/socket.io-parser/build/esm /binary.js","../node_modules/socket.io-parser/build/esm/index.js","../build/esm/ on.js","../build/esm/socket.js","../build/esm/contrib/backo2.js","../build/esm/m anager.js","../build/esm/index.js","../build/esm/url.js"],"sourcesContent":["con st PACKET_TYPES = Object.create(null); // no Map = no polyfill\nPACKET_TYPES[\"o pen\"] = \"0\";\nPACKET_TYPES[\"close\"] = \"1\";\nPACKET_TYPES[\"ping\"] = \"2\ ";\nPACKET_TYPES[\"pong\"] = \"3\";\nPACKET_TYPES[\"message\"] = \"4\";\nPACKET_ TYPES[\"upgrade\"] = \"5\";\nPACKET_TYPES[\"noop\"] = \"6\";\nconst PACKET_TYPES _REVERSE = Object.create(null);\nObject.keys(PACKET_TYPES).forEach(key => {\n PACKET_TYPES_REVERSE[PACKET_TYPES[key]] = key;\n});\nconst ERROR_PACKET = { typ e: \"error\", data: \"parser error\" };\nexport { PACKET_TYPES, PACKET_TYPES_REV ERSE, ERROR_PACKET };\n","import { PACKET_TYPES } from \"./commons.js\";\nconst withNativeBlob = typeof Blob === \"function\" ||\n (typeof Blob !== \"undefin ed\" &&\n Object.prototype.toString.call(Blob) === \"[object BlobConstruc tor]\");\nconst withNativeArrayBuffer = typeof ArrayBuffer === \"function\";\n// ArrayBuffer.isView method is not defined in IE10\nconst isView = obj => {\n return typeof ArrayBuffer.isView === \"function\"\n ? ArrayBuffer.isView( obj)\n : obj && obj.buffer instanceof ArrayBuffer;\n};\nconst encodePacke t = ({ type, data }, supportsBinary, callback) => {\n if (withNativeBlob && d ata instanceof Blob) {\n if (supportsBinary) {\n return callba ck(data);\n }\n else {\n return encodeBlobAsBase64(data , callback);\n }\n }\n else if (withNativeArrayBuffer &&\n ( data instanceof ArrayBuffer || isView(data))) {\n if (supportsBinary) {\n return callback(data);\n }\n else {\n retur n encodeBlobAsBase64(new Blob([data]), callback);\n }\n }\n // plai n string\n return callback(PACKET_TYPES[type] + (data || \"\"));\n};\nconst e ncodeBlobAsBase64 = (data, callback) => {\n const fileReader = new FileReader ();\n fileReader.onload = function () {\n const content = fileReader.r esult.split(\",\")[1];\n callback(\"b\" + content);\n };\n return f ileReader.readAsDataURL(data);\n};\nexport default encodePacket;\n","/*\n * base 64-arraybuffer 1.0.1 <https://github.com/niklasvh/base64-arraybuffer>\n * Copyri ght (c) 2022 Niklas von Hertzen <https://hertzen.com>\n * Released under MIT Lic ense\n */\nvar chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123 456789+/';\n// Use a lookup table to find the index.\nvar lookup = typeof Uint8A rray === 'undefined' ? [] : new Uint8Array(256);\nfor (var i = 0; i < chars.leng th; i++) {\n lookup[chars.charCodeAt(i)] = i;\n}\nvar encode = function (arra ybuffer) {\n var bytes = new Uint8Array(arraybuffer), i, len = bytes.length, base64 = '';\n for (i = 0; i < len; i += 3) {\n base64 += chars[bytes[ i] >> 2];\n base64 += chars[((bytes[i] & 3) << 4) | (bytes[i + 1] >> 4)]; \n base64 += chars[((bytes[i + 1] & 15) << 2) | (bytes[i + 2] >> 6)];\n base64 += chars[bytes[i + 2] & 63];\n }\n if (len % 3 === 2) {\n base64 = base64.substring(0, base64.length - 1) + '=';\n }\n else if ( len % 3 === 1) {\n base64 = base64.substring(0, base64.length - 2) + '==' ;\n }\n return base64;\n};\nvar decode = function (base64) {\n var buff erLength = base64.length * 0.75, len = base64.length, i, p = 0, encoded1, encode d2, encoded3, encoded4;\n if (base64[base64.length - 1] === '=') {\n b ufferLength--;\n if (base64[base64.length - 2] === '=') {\n bu fferLength--;\n }\n }\n var arraybuffer = new ArrayBuffer(bufferLen gth), bytes = new Uint8Array(arraybuffer);\n for (i = 0; i < len; i += 4) {\n encoded1 = lookup[base64.charCodeAt(i)];\n encoded2 = lookup[base 64.charCodeAt(i + 1)];\n encoded3 = lookup[base64.charCodeAt(i + 2)];\n encoded4 = lookup[base64.charCodeAt(i + 3)];\n bytes[p++] = (encode d1 << 2) | (encoded2 >> 4);\n bytes[p++] = ((encoded2 & 15) << 4) | (enco ded3 >> 2);\n bytes[p++] = ((encoded3 & 3) << 6) | (encoded4 & 63);\n }\n return arraybuffer;\n};\n\nexport { decode, encode };\n//# sourceMappingU RL=base64-arraybuffer.es5.js.map\n","import { ERROR_PACKET, PACKET_TYPES_REVERSE } from \"./commons.js\";\nimport { decode } from \"@socket.io/base64-arraybuffe r\";\nconst withNativeArrayBuffer = typeof ArrayBuffer === \"function\";\nconst decodePacket = (encodedPacket, binaryType) => {\n if (typeof encodedPacket != = \"string\") {\n return {\n type: \"message\",\n d ata: mapBinary(encodedPacket, binaryType)\n };\n }\n const type = e ncodedPacket.charAt(0);\n if (type === \"b\") {\n return {\n type: \"message\",\n data: decodeBase64Packet(encodedPacket.substri ng(1), binaryType)\n };\n }\n const packetType = PACKET_TYPES_REVER SE[type];\n if (!packetType) {\n return ERROR_PACKET;\n }\n retu rn encodedPacket.length > 1\n ? {\n type: PACKET_TYPES_REVERSE [type],\n data: encodedPacket.substring(1)\n }\n : {\n type: PACKET_TYPES_REVERSE[type]\n };\n};\nconst decodeBase64P acket = (data, binaryType) => {\n if (withNativeArrayBuffer) {\n const decoded = decode(data);\n return mapBinary(decoded, binaryType);\n }\ n else {\n return { base64: true, data }; // fallback for old browsers \n }\n};\nconst mapBinary = (data, binaryType) => {\n switch (binaryType) {\n case \"blob\":\n return data instanceof ArrayBuffer ? new Blob([data]) : data;\n case \"arraybuffer\":\n default:\n return data; // assuming the data is already an ArrayBuffer\n }\n};\nexpor t default decodePacket;\n","import encodePacket from \"./encodePacket.js\";\nimp ort decodePacket from \"./decodePacket.js\";\nconst SEPARATOR = String.fromCharC ode(30); // see https://en.wikipedia.org/wiki/Delimiter#ASCII_delimited_text\nco nst encodePayload = (packets, callback) => {\n // some packets may be added t o the array while encoding, so the initial length must be saved\n const lengt h = packets.length;\n const encodedPackets = new Array(length);\n let coun t = 0;\n packets.forEach((packet, i) => {\n // force base64 encoding f or binary packets\n encodePacket(packet, false, encodedPacket => {\n encodedPackets[i] = encodedPacket;\n if (++count === length) { \n callback(encodedPackets.join(SEPARATOR));\n }\n });\n });\n};\nconst decodePayload = (encodedPayload, binaryType) => {\n const encodedPackets = encodedPayload.split(SEPARATOR);\n const packets = [];\n for (let i = 0; i < encodedPackets.length; i++) {\n const decode dPacket = decodePacket(encodedPackets[i], binaryType);\n packets.push(dec odedPacket);\n if (decodedPacket.type === \"error\") {\n break ;\n }\n }\n return packets;\n};\nexport const protocol = 4;\nexport { encodePacket, encodePayload, decodePacket, decodePayload };\n","/**\n * Initi alize a new `Emitter`.\n *\n * @api public\n */\n\nexport function Emitter(obj) {\n if (obj) return mixin(obj);\n}\n\n/**\n * Mixin the emitter properties.\n * \n * @param {Object} obj\n * @return {Object}\n * @api private\n */\n\nfunction mixin(obj) {\n for (var key in Emitter.prototype) {\n obj[key] = Emitter.pro totype[key];\n }\n return obj;\n}\n\n/**\n * Listen on the given `event` with `fn`.\n *\n * @param {String} event\n * @param {Function} fn\n * @return {Emitte r}\n * @api public\n */\n\nEmitter.prototype.on =\nEmitter.prototype.addEventLis tener = function(event, fn){\n this._callbacks = this._callbacks || {};\n (thi s._callbacks['$' + event] = this._callbacks['$' + event] || [])\n .push(fn);\ n return this;\n};\n\n/**\n * Adds an `event` listener that will be invoked a s ingle\n * time then automatically removed.\n *\n * @param {String} event\n * @pa ram {Function} fn\n * @return {Emitter}\n * @api public\n */\n\nEmitter.prototyp e.once = function(event, fn){\n function on() {\n this.off(event, on);\n fn.apply(this, arguments);\n }\n\n on.fn = fn;\n this.on(event, on);\n retur n this;\n};\n\n/**\n * Remove the given callback for `event` or all\n * register ed callbacks.\n *\n * @param {String} event\n * @param {Function} fn\n * @return {Emitter}\n * @api public\n */\n\nEmitter.prototype.off =\nEmitter.prototype.re moveListener =\nEmitter.prototype.removeAllListeners =\nEmitter.prototype.remove EventListener = function(event, fn){\n this._callbacks = this._callbacks || {}; \n\n // all\n if (0 == arguments.length) {\n this._callbacks = {};\n ret urn this;\n }\n\n // specific event\n var callbacks = this._callbacks['$' + e vent];\n if (!callbacks) return this;\n\n // remove all handlers\n if (1 == a rguments.length) {\n delete this._callbacks['$' + event];\n return this;\n }\n\n // remove specific handler\n var cb;\n for (var i = 0; i < callbacks. length; i++) {\n cb = callbacks[i];\n if (cb === fn || cb.fn === fn) {\n callbacks.splice(i, 1);\n break;\n }\n }\n\n // Remove event speci fic arrays for event types that no\n // one is subscribed for to avoid memory l eak.\n if (callbacks.length === 0) {\n delete this._callbacks['$' + event];\ n }\n\n return this;\n};\n\n/**\n * Emit `event` with the given args.\n *\n * @param {String} event\n * @param {Mixed} ...\n * @return {Emitter}\n */\n\nEmitt er.prototype.emit = function(event){\n this._callbacks = this._callbacks || {}; \n\n var args = new Array(arguments.length - 1)\n , callbacks = this._callba cks['$' + event];\n\n for (var i = 1; i < arguments.length; i++) {\n args[i - 1] = arguments[i];\n }\n\n if (callbacks) {\n callbacks = callbacks.slice (0);\n for (var i = 0, len = callbacks.length; i < len; ++i) {\n callbac ks[i].apply(this, args);\n }\n }\n\n return this;\n};\n\n// alias used for reserved events (protected method)\nEmitter.prototype.emitReserved = Emitter.pro totype.emit;\n\n/**\n * Return array of callbacks for `event`.\n *\n * @param {S tring} event\n * @return {Array}\n * @api public\n */\n\nEmitter.prototype.liste ners = function(event){\n this._callbacks = this._callbacks || {};\n return th is._callbacks['$' + event] || [];\n};\n\n/**\n * Check if this emitter has `even t` handlers.\n *\n * @param {String} event\n * @return {Boolean}\n * @api public \n */\n\nEmitter.prototype.hasListeners = function(event){\n return !! this.lis teners(event).length;\n};\n","export default (() => {\n if (typeof self !== \ "undefined\") {\n return self;\n }\n else if (typeof window !== \"u ndefined\") {\n return window;\n }\n else {\n return Functio n(\"return this\")();\n }\n})();\n","import globalThis from \"./globalThis.js \";\nexport function pick(obj, ...attr) {\n return attr.reduce((acc, k) => {\ n if (obj.hasOwnProperty(k)) {\n acc[k] = obj[k];\n }\n return acc;\n }, {});\n}\n// Keep a reference to the real timeout fun ctions so they can be used when overridden\nconst NATIVE_SET_TIMEOUT = setTimeou t;\nconst NATIVE_CLEAR_TIMEOUT = clearTimeout;\nexport function installTimerFunc tions(obj, opts) {\n if (opts.useNativeTimers) {\n obj.setTimeoutFn = NATIVE_SET_TIMEOUT.bind(globalThis);\n obj.clearTimeoutFn = NATIVE_CLEAR_ TIMEOUT.bind(globalThis);\n }\n else {\n obj.setTimeoutFn = setTime out.bind(globalThis);\n obj.clearTimeoutFn = clearTimeout.bind(globalThis );\n }\n}\n// base64 encoded buffers are about 33% bigger (https://en.wikiped ia.org/wiki/Base64)\nconst BASE64_OVERHEAD = 1.33;\n// we could also have used ` new Blob([obj]).size`, but it isn't supported in IE9\nexport function byteLength (obj) {\n if (typeof obj === \"string\") {\n return utf8Length(obj);\n }\n // arraybuffer or blob\n return Math.ceil((obj.byteLength || obj.s ize) * BASE64_OVERHEAD);\n}\nfunction utf8Length(str) {\n let c = 0, length = 0;\n for (let i = 0, l = str.length; i < l; i++) {\n c = str.charCode At(i);\n if (c < 0x80) {\n length += 1;\n }\n el se if (c < 0x800) {\n length += 2;\n }\n else if (c < 0 xd800 || c >= 0xe000) {\n length += 3;\n }\n else {\n i++;\n length += 4;\n }\n }\n return length;\n }\n","import { decodePacket } from \"engine.io-parser\";\nimport { Emitter } fro m \"@socket.io/component-emitter\";\nimport { installTimerFunctions } from \"./u til.js\";\nclass TransportError extends Error {\n constructor(reason, descrip tion, context) {\n super(reason);\n this.description = description ;\n this.context = context;\n this.type = \"TransportError\";\n }\n}\nexport class Transport extends Emitter {\n /**\n * Transport abstr act constructor.\n *\n * @param {Object} options.\n * @api private\n */\n constructor(opts) {\n super();\n this.writable = fals e;\n installTimerFunctions(this, opts);\n this.opts = opts;\n this.query = opts.query;\n this.readyState = \"\";\n this.socke t = opts.socket;\n }\n /**\n * Emits an error.\n *\n * @param {String} reason\n * @param description\n * @param context - the error co ntext\n * @return {Transport} for chaining\n * @api protected\n */\n onError(reason, description, context) {\n super.emitReserved(\"error\ ", new TransportError(reason, description, context));\n return this;\n }\n /**\n * Opens the transport.\n *\n * @api public\n */\n open() {\n if (\"closed\" === this.readyState || \"\" === this.readySt ate) {\n this.readyState = \"opening\";\n this.doOpen();\n }\n return this;\n }\n /**\n * Closes the transport.\n *\n * @api public\n */\n close() {\n if (\"opening\" === t his.readyState || \"open\" === this.readyState) {\n this.doClose();\n this.onClose();\n }\n return this;\n }\n /**\n * Sends multiple packets.\n *\n * @param {Array} packets\n * @api public\n */\n send(packets) {\n if (\"open\" === this.readyState) {\n this.write(packets);\n }\n else {\n // this might happen if the transport was silently closed in the beforeunload event handler\n }\n }\n /**\n * Called upon open\n *\n * @ap i protected\n */\n onOpen() {\n this.readyState = \"open\";\n this.writable = true;\n super.emitReserved(\"open\");\n }\n /**\ n * Called with data.\n *\n * @param {String} data\n * @api prot ected\n */\n onData(data) {\n const packet = decodePacket(data, th is.socket.binaryType);\n this.onPacket(packet);\n }\n /**\n * C alled with a decoded packet.\n *\n * @api protected\n */\n onPack et(packet) {\n super.emitReserved(\"packet\", packet);\n }\n /**\n * Called upon close.\n *\n * @api protected\n */\n onClose(de tails) {\n this.readyState = \"closed\";\n super.emitReserved(\"cl ose\", details);\n }\n}\n","// imported from https://github.com/unshiftio/yea st\n'use strict';\nconst alphabet = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefg hijklmnopqrstuvwxyz-_'.split(''), length = 64, map = {};\nlet seed = 0, i = 0, p rev;\n/**\n * Return a string representing the specified number.\n *\n * @param {Number} num The number to convert.\n * @returns {String} The string representat ion of the number.\n * @api public\n */\nexport function encode(num) {\n let encoded = '';\n do {\n encoded = alphabet[num % length] + encoded;\n num = Math.floor(num / length);\n } while (num > 0);\n return encode d;\n}\n/**\n * Return the integer value specified by the given string.\n *\n * @ param {String} str The string to convert.\n * @returns {Number} The integer valu e represented by the string.\n * @api public\n */\nexport function decode(str) { \n let decoded = 0;\n for (i = 0; i < str.length; i++) {\n decoded = decoded * length + map[str.charAt(i)];\n }\n return decoded;\n}\n/**\n * Yeast: A tiny growing id generator.\n *\n * @returns {String} A unique id.\n * @api public\n */\nexport function yeast() {\n const now = encode(+new Date()) ;\n if (now !== prev)\n return seed = 0, prev = now;\n return now + '.' + encode(seed++);\n}\n//\n// Map each character to its index.\n//\nfor (; i < length; i++)\n map[alphabet[i]] = i;\n","// imported from https://github.c om/galkn/querystring\n/**\n * Compiles a querystring\n * Returns string represen tation of the object\n *\n * @param {Object}\n * @api private\n */\nexport funct ion encode(obj) {\n let str = '';\n for (let i in obj) {\n if (obj. hasOwnProperty(i)) {\n if (str.length)\n str += '&';\n str += encodeURIComponent(i) + '=' + encodeURIComponent(obj[i]);\n }\n }\n return str;\n}\n/**\n * Parses a simple querystring into an object\n *\n * @param {String} qs\n * @api private\n */\nexport function decode( qs) {\n let qry = {};\n let pairs = qs.split('&');\n for (let i = 0, l = pairs.length; i < l; i++) {\n let pair = pairs[i].split('=');\n qry[decodeURIComponent(pair[0])] = decodeURIComponent(pair[1]);\n }\n retu rn qry;\n}\n","// imported from https://github.com/component/has-cors\nlet value = false;\ntry {\n value = typeof XMLHttpRequest !== 'undefined' &&\n 'withCredentials' in new XMLHttpRequest();\n}\ncatch (err) {\n // if XMLHttp support is disabled in IE then it will throw\n // when trying to create\n}\ne xport const hasCORS = value;\n","// browser shim for xmlhttprequest module\nimpo rt { hasCORS } from \"../contrib/has-cors.js\";\nimport globalThis from \"../glo balThis.js\";\nexport default function (opts) {\n const xdomain = opts.xdomai n;\n // XMLHttpRequest can be disabled on IE\n try {\n if (\"undefi ned\" !== typeof XMLHttpRequest && (!xdomain || hasCORS)) {\n return new XMLHttpRequest();\n }\n }\n catch (e) { }\n if (!xdomain) {\ n try {\n return new globalThis[[\"Active\"].concat(\"Object\" ).join(\"X\")](\"Microsoft.XMLHTTP\");\n }\n catch (e) { }\n }\ n}\n","import { Transport } from \"../transport.js\";\nimport { yeast } from \". ./contrib/yeast.js\";\nimport { encode } from \"../contrib/parseqs.js\";\nimport { encodePayload, decodePayload } from \"engine.io-parser\";\nimport XMLHttpRequ est from \"./xmlhttprequest.js\";\nimport { Emitter } from \"@socket.io/componen t-emitter\";\nimport { installTimerFunctions, pick } from \"../util.js\";\nimpor t globalThis from \"../globalThis.js\";\nfunction empty() { }\nconst hasXHR2 = ( function () {\n const xhr = new XMLHttpRequest({\n xdomain: false\n });\n return null != xhr.responseType;\n})();\nexport class Polling extends Transport {\n /**\n * XHR Polling constructor.\n *\n * @param {Ob ject} opts\n * @api public\n */\n constructor(opts) {\n super( opts);\n this.polling = false;\n if (typeof location !== \"undefin ed\") {\n const isSSL = \"https:\" === location.protocol;\n let port = location.port;\n // some user agents have empty `locatio n.port`\n if (!port) {\n port = isSSL ? \"443\" : \"80 \";\n }\n this.xd =\n (typeof location !== \"undefined\" &&\n opts.hostname !== location.hostname) ||\n port !== opts.port;\n this.xs = opts.secure !== is SSL;\n }\n /**\n * XHR supports binary\n */\n const forceBase64 = opts && opts.forceBase64;\n this.supportsBinary = hasXHR2 && !forceBase64;\n }\n /**\n * Transport name.\n */\n g et name() {\n return \"polling\";\n }\n /**\n * Opens the socke t (triggers polling). We write a PING message to determine\n * when the tran sport is open.\n *\n * @api private\n */\n doOpen() {\n th is.poll();\n }\n /**\n * Pauses polling.\n *\n * @param {Funct ion} callback upon buffers are flushed and transport is paused\n * @api priv ate\n */\n pause(onPause) {\n this.readyState = \"pausing\";\n const pause = () => {\n this.readyState = \"paused\";\n onPause();\n };\n if (this.polling || !this.writable) {\n let total = 0;\n if (this.polling) {\n total++;\n this.once(\"pollComplete\", function () {\n - -total || pause();\n });\n }\n if (!this.wr itable) {\n total++;\n this.once(\"drain\", functi on () {\n --total || pause();\n });\n }\n }\n else {\n pause();\n }\n }\n /** \n * Starts polling cycle.\n *\n * @api public\n */\n poll() {\n this.polling = true;\n this.doPoll();\n this.emitReserv ed(\"poll\");\n }\n /**\n * Overloads onData to detect payloads.\n *\n * @api private\n */\n onData(data) {\n const callback = p acket => {\n // if its the first message we consider the transport op en\n if (\"opening\" === this.readyState && packet.type === \"open\") {\n this.onOpen();\n }\n // if its a close packet, we close the ongoing requests\n if (\"close\" === packet.typ e) {\n this.onClose({ description: \"transport closed by the serv er\" });\n return false;\n }\n // otherwise bypass onData and handle the message\n this.onPacket(packet);\n };\n // decode payload\n decodePayload(data, this.socket.binary Type).forEach(callback);\n // if an event did not trigger closing\n if (\"closed\" !== this.readyState) {\n // if we got data we're not polling\n this.polling = false;\n this.emitReserved(\"pol lComplete\");\n if (\"open\" === this.readyState) {\n this.poll();\n }\n else {\n }\n }\n } \n /**\n * For polling, send a close packet.\n *\n * @api private \n */\n doClose() {\n const close = () => {\n this.writ e([{ type: \"close\" }]);\n };\n if (\"open\" === this.readyState) {\n close();\n }\n else {\n // in case we'r e trying to close while\n // handshaking is in progress (GH-164)\n this.once(\"open\", close);\n }\n }\n /**\n * Writes a packets payload.\n *\n * @param {Array} data packets\n * @param {Fu nction} drain callback\n * @api private\n */\n write(packets) {\n this.writable = false;\n encodePayload(packets, data => {\n this.doWrite(data, () => {\n this.writable = true;\n this.emitReserved(\"drain\");\n });\n });\n }\n /** \n * Generates uri for connection.\n *\n * @api private\n */\n uri() {\n let query = this.query || {};\n const schema = this.op ts.secure ? \"https\" : \"http\";\n let port = \"\";\n // cache bu sting is forced\n if (false !== this.opts.timestampRequests) {\n query[this.opts.timestampParam] = yeast();\n }\n if (!this.supp ortsBinary && !query.sid) {\n query.b64 = 1;\n }\n // a void port if default for schema\n if (this.opts.port &&\n ((\" https\" === schema && Number(this.opts.port) !== 443) ||\n (\"htt p\" === schema && Number(this.opts.port) !== 80))) {\n port = \":\" + this.opts.port;\n }\n const encodedQuery = encode(query);\n const ipv6 = this.opts.hostname.indexOf(\":\") !== -1;\n return (schema +\n \"://\" +\n (ipv6 ? \"[\" + this.opts.hostname + \"]\ " : this.opts.hostname) +\n port +\n this.opts.path +\n (encodedQuery.length ? \"?\" + encodedQuery : \"\"));\n }\n /**\n * Creates a request.\n *\n * @param {String} method\n * @api pr ivate\n */\n request(opts = {}) {\n Object.assign(opts, { xd: this .xd, xs: this.xs }, this.opts);\n return new Request(this.uri(), opts);\n }\n /**\n * Sends data.\n *\n * @param {String} data to send. \n * @param {Function} called upon flush.\n * @api private\n */\n doWrite(data, fn) {\n const req = this.request({\n method: \" POST\",\n data: data\n });\n req.on(\"success\", fn);\n req.on(\"error\", (xhrStatus, context) => {\n this.onError(\" xhr post error\", xhrStatus, context);\n });\n }\n /**\n * Star ts a poll cycle.\n *\n * @api private\n */\n doPoll() {\n const req = this.request();\n req.on(\"data\", this.onData.bind(this));\n req.on(\"error\", (xhrStatus, context) => {\n this.onError(\" xhr poll error\", xhrStatus, context);\n });\n this.pollXhr = req; \n }\n}\nexport class Request extends Emitter {\n /**\n * Request cons tructor\n *\n * @param {Object} options\n * @api public\n */\n constructor(uri, opts) {\n super();\n installTimerFunctions(this , opts);\n this.opts = opts;\n this.method = opts.method || \"GET\ ";\n this.uri = uri;\n this.async = false !== opts.async;\n this.data = undefined !== opts.data ? opts.data : null;\n this.create(); \n }\n /**\n * Creates the XHR object and sends the request.\n *\n * @api private\n */\n create() {\n const opts = pick(this.opt s, \"agent\", \"pfx\", \"key\", \"passphrase\", \"cert\", \"ca\", \"ciphers\", \ "rejectUnauthorized\", \"autoUnref\");\n opts.xdomain = !!this.opts.xd;\n opts.xscheme = !!this.opts.xs;\n const xhr = (this.xhr = new XMLH ttpRequest(opts));\n try {\n xhr.open(this.method, this.uri, t his.async);\n try {\n if (this.opts.extraHeaders) {\n xhr.setDisableHeaderCheck && xhr.setDisableHeaderCheck(true); \n for (let i in this.opts.extraHeaders) {\n if (this.opts.extraHeaders.hasOwnProperty(i)) {\n xhr.setRequestHeader(i, this.opts.extraHeaders[i]);\n }\n }\n }\n }\n catch ( e) { }\n if (\"POST\" === this.method) {\n try {\n xhr.setRequestHeader(\"Content-type\", \"text/plain;charset=UTF- 8\");\n }\n catch (e) { }\n }\n try {\n xhr.setRequestHeader(\"Accept\", \"*/*\");\n }\n catch (e) { }\n // ie6 check\n if (\"wit hCredentials\" in xhr) {\n xhr.withCredentials = this.opts.withCr edentials;\n }\n if (this.opts.requestTimeout) {\n xhr.timeout = this.opts.requestTimeout;\n }\n xhr. onreadystatechange = () => {\n if (4 !== xhr.readyState)\n return;\n if (200 === xhr.status || 1223 === xhr.sta tus) {\n this.onLoad();\n }\n e lse {\n // make sure the `error` event handler that's user-se t\n // does not throw in the same tick and gets caught here\n this.setTimeoutFn(() => {\n this.onEr ror(typeof xhr.status === \"number\" ? xhr.status : 0);\n }, 0);\n }\n };\n xhr.send(this.data);\n }\n catch (e) {\n // Need to defer since .create() is called directly from the constructor\n // and thus the 'error' event can on ly be only bound *after* this exception\n // occurs. Therefore, also , we cannot throw here at all.\n this.setTimeoutFn(() => {\n this.onError(e);\n }, 0);\n return;\n }\n if (typeof document !== \"undefined\") {\n this.index = Request. requestsCount++;\n Request.requests[this.index] = this;\n }\n }\n /**\n * Called upon error.\n *\n * @api private\n */\n onError(err) {\n this.emitReserved(\"error\", err, this.xhr);\n this.cleanup(true);\n }\n /**\n * Cleans up house.\n *\n * @ api private\n */\n cleanup(fromError) {\n if (\"undefined\" === ty peof this.xhr || null === this.xhr) {\n return;\n }\n t his.xhr.onreadystatechange = empty;\n if (fromError) {\n try { \n this.xhr.abort();\n }\n catch (e) { }\n }\n if (typeof document !== \"undefined\") {\n delete R equest.requests[this.index];\n }\n this.xhr = null;\n }\n /* *\n * Called upon load.\n *\n * @api private\n */\n onLoad() {\n const data = this.xhr.responseText;\n if (data !== null) {\n this.emitReserved(\"data\", data);\n this.emitReserved(\"su ccess\");\n this.cleanup();\n }\n }\n /**\n * Aborts the request.\n *\n * @api public\n */\n abort() {\n this. cleanup();\n }\n}\nRequest.requestsCount = 0;\nRequest.requests = {};\n/**\n * Aborts pending requests when unloading the window. This is needed to prevent\n * memory leaks (e.g. when using IE) and to ensure that no spurious error is\n * emitted.\n */\nif (typeof document !== \"undefined\") {\n // @ts-ignore\n if (typeof attachEvent === \"function\") {\n // @ts-ignore\n atta chEvent(\"onunload\", unloadHandler);\n }\n else if (typeof addEventListen er === \"function\") {\n const terminationEvent = \"onpagehide\" in globa lThis ? \"pagehide\" : \"unload\";\n addEventListener(terminationEvent, u nloadHandler, false);\n }\n}\nfunction unloadHandler() {\n for (let i in R equest.requests) {\n if (Request.requests.hasOwnProperty(i)) {\n Request.requests[i].abort();\n }\n }\n}\n","import globalThis from \"../globalThis.js\";\nexport const nextTick = (() => {\n const isPromiseAvai lable = typeof Promise === \"function\" && typeof Promise.resolve === \"function \";\n if (isPromiseAvailable) {\n return cb => Promise.resolve().then( cb);\n }\n else {\n return (cb, setTimeoutFn) => setTimeoutFn(cb, 0 );\n }\n})();\nexport const WebSocket = globalThis.WebSocket || globalThis.Mo zWebSocket;\nexport const usingBrowserWebSocket = true;\nexport const defaultBin aryType = \"arraybuffer\";\n","import { Transport } from \"../transport.js\";\ni mport { encode } from \"../contrib/parseqs.js\";\nimport { yeast } from \"../con trib/yeast.js\";\nimport { pick } from \"../util.js\";\nimport { defaultBinaryTy pe, nextTick, usingBrowserWebSocket, WebSocket } from \"./websocket-constructor. js\";\nimport { encodePacket } from \"engine.io-parser\";\n// detect ReactNative environment\nconst isReactNative = typeof navigator !== \"undefined\" &&\n t ypeof navigator.product === \"string\" &&\n navigator.product.toLowerCase() = == \"reactnative\";\nexport class WS extends Transport {\n /**\n * WebSoc ket transport constructor.\n *\n * @api {Object} connection options\n * @api public\n */\n constructor(opts) {\n super(opts);\n this.supportsBinary = !opts.forceBase64;\n }\n /**\n * Transport name .\n *\n * @api public\n */\n get name() {\n return \"webso cket\";\n }\n /**\n * Opens socket.\n *\n * @api private\n */\n doOpen() {\n if (!this.check()) {\n // let probe time out\n return;\n }\n const uri = this.uri();\n co nst protocols = this.opts.protocols;\n // React Native only supports the 'headers' option, and will print a warning if anything else is passed\n c onst opts = isReactNative\n ? {}\n : pick(this.opts, \"age nt\", \"perMessageDeflate\", \"pfx\", \"key\", \"passphrase\", \"cert\", \"ca\", \"ciphers\", \"rejectUnauthorized\", \"localAddress\", \"protocolVersion\", \"o rigin\", \"maxPayload\", \"family\", \"checkServerIdentity\");\n if (this .opts.extraHeaders) {\n opts.headers = this.opts.extraHeaders;\n }\n try {\n this.ws =\n usingBrowserWebSocke t && !isReactNative\n ? protocols\n ? new WebSocket(uri, protocols)\n : new WebSocket(uri)\n : new WebSocket(uri, protocols, opts);\n }\n catc h (err) {\n return this.emitReserved(\"error\", err);\n }\n this.ws.binaryType = this.socket.binaryType || defaultBinaryType;\n this.addEventListeners();\n }\n /**\n * Adds event listeners to the so cket\n *\n * @api private\n */\n addEventListeners() {\n t his.ws.onopen = () => {\n if (this.opts.autoUnref) {\n this.ws._socket.unref();\n }\n this.onOpen();\n }; \n this.ws.onclose = closeEvent => this.onClose({\n descriptio n: \"websocket connection closed\",\n context: closeEvent\n }) ;\n this.ws.onmessage = ev => this.onData(ev.data);\n this.ws.oner ror = e => this.onError(\"websocket error\", e);\n }\n /**\n * Writes data to socket.\n *\n * @param {Array} array of packets.\n * @api pr ivate\n */\n write(packets) {\n this.writable = false;\n // encodePacket efficient as it uses WS framing\n // no need for encodePayl oad\n for (let i = 0; i < packets.length; i++) {\n const packe t = packets[i];\n const lastPacket = i === packets.length - 1;\n encodePacket(packet, this.supportsBinary, data => {\n // a lways create a new object (GH-437)\n const opts = {};\n if (!usingBrowserWebSocket) {\n if (packet.options) {\n opts.compress = packet.options.compress;\n }\n if (this.opts.perMessageDeflate) {\n const len = \n // @ts-ignore\n \"string\" === typeof data ? Buffer.byteLength(data) : data.length;\n if (len < this.opts.perMessageDeflate.threshold) {\n opts.compress = false;\n }\n }\n }\n // Sometimes the websocket has a lready been closed but the browser didn't\n // have a chance of i nforming us about it yet, in that case send will\n // throw an er ror\n try {\n if (usingBrowserWebSocket) {\n // TypeError is thrown when passing the second argument on Safari\n this.ws.send(data);\n }\n else {\n this.ws.send(data, opts);\n }\n }\n catch (e) {\n }\n if (lastPacket) {\n // fake drain\n // defer to next tick to allow Socket to clear writeBuffer\n nextTick(() => {\n this.writable = true;\ n this.emitReserved(\"drain\");\n }, t his.setTimeoutFn);\n }\n });\n }\n }\n /* *\n * Closes socket.\n *\n * @api private\n */\n doClose() {\ n if (typeof this.ws !== \"undefined\") {\n this.ws.close();\n this.ws = null;\n }\n }\n /**\n * Generates uri for connection.\n *\n * @api private\n */\n uri() {\n let que ry = this.query || {};\n const schema = this.opts.secure ? \"wss\" : \"ws \";\n let port = \"\";\n // avoid port if default for schema\n if (this.opts.port &&\n ((\"wss\" === schema && Number(this.opts. port) !== 443) ||\n (\"ws\" === schema && Number(this.opts.port) !== 80))) {\n port = \":\" + this.opts.port;\n }\n // a ppend timestamp to URI\n if (this.opts.timestampRequests) {\n query[this.opts.timestampParam] = yeast();\n }\n // communicate bi nary support capabilities\n if (!this.supportsBinary) {\n quer y.b64 = 1;\n }\n const encodedQuery = encode(query);\n cons t ipv6 = this.opts.hostname.indexOf(\":\") !== -1;\n return (schema +\n \"://\" +\n (ipv6 ? \"[\" + this.opts.hostname + \"]\" : th is.opts.hostname) +\n port +\n this.opts.path +\n (encodedQuery.length ? \"?\" + encodedQuery : \"\"));\n }\n /**\n * Feature detection for WebSocket.\n *\n * @return {Boolean} whether this transport is available.\n * @api public\n */\n check() {\n re turn (!!WebSocket &&\n !(\"__initialize\" in WebSocket && this.name = == WS.prototype.name));\n }\n}\n","import { Polling } from \"./polling.js\";\ nimport { WS } from \"./websocket.js\";\nexport const transports = {\n websoc ket: WS,\n polling: Polling\n};\n","// imported from https://github.com/galkn /parseuri\n/**\n * Parses an URI\n *\n * @author Steven Levithan <stevenlevithan .com> (MIT license)\n * @api private\n */\nconst re = /^(?:(?![^:@]+:[^:@\\/]*@) (http|https|ws|wss):\\/\\/)?((?:(([^:@]*)(?::([^:@]*))?)?@)?((?:[a-f0-9]{0,4}:){ 2,7}[a-f0-9]{0,4}|[^:\\/?#]*)(?::(\\d*))?)(((\\/(?:[^?#](?![^?#\\/]*\\.[^?#\\/.] +(?:[?#]|$)))*\\/?)?([^?#\\/]*))(?:\\?([^#]*))?(?:#(.*))?)/;\nconst parts = [\n 'source', 'protocol', 'authority', 'userInfo', 'user', 'password', 'host', 'p ort', 'relative', 'path', 'directory', 'file', 'query', 'anchor'\n];\nexport fun ction parse(str) {\n const src = str, b = str.indexOf('['), e = str.indexOf(' ]');\n if (b != -1 && e != -1) {\n str = str.substring(0, b) + str.sub string(b, e).replace(/:/g, ';') + str.substring(e, str.length);\n }\n let m = re.exec(str || ''), uri = {}, i = 14;\n while (i--) {\n uri[parts[ i]] = m[i] || '';\n }\n if (b != -1 && e != -1) {\n uri.source = sr c;\n uri.host = uri.host.substring(1, uri.host.length - 1).replace(/;/g, ':');\n uri.authority = uri.authority.replace('[', '').replace(']', '').r eplace(/;/g, ':');\n uri.ipv6uri = true;\n }\n uri.pathNames = path Names(uri, uri['path']);\n uri.queryKey = queryKey(uri, uri['query']);\n r eturn uri;\n}\nfunction pathNames(obj, path) {\n const regx = /\\/{2,9}/g, na mes = path.replace(regx, \"/\").split(\"/\");\n if (path.substr(0, 1) == '/' || path.length === 0) {\n names.splice(0, 1);\n }\n if (path.substr (path.length - 1, 1) == '/') {\n names.splice(names.length - 1, 1);\n }\n return names;\n}\nfunction queryKey(uri, query) {\n const data = {};\n query.replace(/(?:^|&)([^&=]*)=?([^&]*)/g, function ($0, $1, $2) {\n if ($1) {\n data[$1] = $2;\n }\n });\n return data;\n}\n ","import { transports } from \"./transports/index.js\";\nimport { installTimerF unctions, byteLength } from \"./util.js\";\nimport { decode } from \"./contrib/p arseqs.js\";\nimport { parse } from \"./contrib/parseuri.js\";\nimport { Emitter } from \"@socket.io/component-emitter\";\nimport { protocol } from \"engine.io- parser\";\nexport class Socket extends Emitter {\n /**\n * Socket constru ctor.\n *\n * @param {String|Object} uri or options\n * @param {Obje ct} opts - options\n * @api public\n */\n constructor(uri, opts = {}) {\n super();\n if (uri && \"object\" === typeof uri) {\n opts = uri;\n uri = null;\n }\n if (uri) {\n uri = parse(uri);\n opts.hostname = uri.host;\n opts.s ecure = uri.protocol === \"https\" || uri.protocol === \"wss\";\n opt s.port = uri.port;\n if (uri.query)\n opts.query = uri .query;\n }\n else if (opts.host) {\n opts.hostname = p arse(opts.host).host;\n }\n installTimerFunctions(this, opts);\n this.secure =\n null != opts.secure\n ? opts.sec ure\n : typeof location !== \"undefined\" && \"https:\" === locat ion.protocol;\n if (opts.hostname && !opts.port) {\n // if no port is specified manually, use the protocol default\n opts.port = th is.secure ? \"443\" : \"80\";\n }\n this.hostname =\n o pts.hostname ||\n (typeof location !== \"undefined\" ? location.h ostname : \"localhost\");\n this.port =\n opts.port ||\n (typeof location !== \"undefined\" && location.port\n ? location.port\n : this.secure\n ? \"443\"\n : \"80\");\n this.transports = opts.tra nsports || [\"polling\", \"websocket\"];\n this.readyState = \"\";\n this.writeBuffer = [];\n this.prevBufferLen = 0;\n this.opts = Object.assign({\n path: \"/engine.io\",\n agent: false,\n withCredentials: false,\n upgrade: true,\n time stampParam: \"t\",\n rememberUpgrade: false,\n rejectUnaut horized: true,\n perMessageDeflate: {\n threshold: 102 4\n },\n transportOptions: {},\n closeOnBeforeu nload: true\n }, opts);\n this.opts.path = this.opts.path.replace( /\\/$/, \"\") + \"/\";\n if (typeof this.opts.query === \"string\") {\n this.opts.query = decode(this.opts.query);\n }\n // set on handshake\n this.id = null;\n this.upgrades = null;\n th is.pingInterval = null;\n this.pingTimeout = null;\n // set on hea rtbeat\n this.pingTimeoutTimer = null;\n if (typeof addEventListen er === \"function\") {\n if (this.opts.closeOnBeforeunload) {\n // Firefox closes the connection when the \"beforeunload\" event is em itted but not Chrome. This event listener\n // ensures every brow ser behaves the same (no \"disconnect\" event at the Socket.IO level when the pa ge is\n // closed/reloaded)\n addEventListener(\"b eforeunload\", () => {\n if (this.transport) {\n // silently close the transport\n this.transpo rt.removeAllListeners();\n this.transport.close();\n }\n }, false);\n }\n if (thi s.hostname !== \"localhost\") {\n this.offlineEventListener = () => {\n this.onClose(\"transport close\", {\n description: \"network connection lost\"\n });\n };\n addEventListener(\"offline\", this.offlineEventLis tener, false);\n }\n }\n this.open();\n }\n /**\n * Creates transport of the given type.\n *\n * @param {String} tran sport name\n * @return {Transport}\n * @api private\n */\n create Transport(name) {\n const query = Object.assign({}, this.opts.query);\n // append engine.io protocol identifier\n query.EIO = protocol;\n // transport name\n query.transport = name;\n // session id if we already have one\n if (this.id)\n query.sid = this.id;\n const opts = Object.assign({}, this.opts.transportOptions[name], this.op ts, {\n query,\n socket: this,\n hostname: this .hostname,\n secure: this.secure,\n port: this.port\n });\n return new transports[name](opts);\n }\n /**\n * Initi alizes transport to use and starts probe.\n *\n * @api private\n */\ n open() {\n let transport;\n if (this.opts.rememberUpgrade &&\ n Socket.priorWebsocketSuccess &&\n this.transports.indexO f(\"websocket\") !== -1) {\n transport = \"websocket\";\n }\n else if (0 === this.transports.length) {\n // Emit error on ne xt tick so it can be listened to\n this.setTimeoutFn(() => {\n this.emitReserved(\"error\", \"No transports available\");\n }, 0);\n return;\n }\n else {\n transport = this.transports[0];\n }\n this.readyState = \"opening\";\n // Retry with the next transport if the transport is disabled (jsonp: false)\n try {\n transport = this.createTransport(transport);\n }\n catch (e) {\n this.transports.shift();\n this.o pen();\n return;\n }\n transport.open();\n this. setTransport(transport);\n }\n /**\n * Sets the current transport. Dis ables the existing one (if any).\n *\n * @api private\n */\n setT ransport(transport) {\n if (this.transport) {\n this.transport .removeAllListeners();\n }\n // set up transport\n this.tra nsport = transport;\n // set up transport listeners\n transport\n .on(\"drain\", this.onDrain.bind(this))\n .on(\"packet\", this.onPacket.bind(this))\n .on(\"error\", this.onError.bind(this))\n .on(\"close\", reason => this.onClose(\"transport close\", reason)); \n }\n /**\n * Probes a transport.\n *\n * @param {String} tra nsport name\n * @api private\n */\n probe(name) {\n let transp ort = this.createTransport(name);\n let failed = false;\n Socket.p riorWebsocketSuccess = false;\n const onTransportOpen = () => {\n if (failed)\n return;\n transport.send([{ type: \" ping\", data: \"probe\" }]);\n transport.once(\"packet\", msg => {\n if (failed)\n return;\n if (\"p ong\" === msg.type && \"probe\" === msg.data) {\n this.upgrad ing = true;\n this.emitReserved(\"upgrading\", transport);\n if (!transport)\n return;\n Socket.priorWebsocketSuccess = \"websocket\" === transport.name;\n this.transport.pause(() => {\n if (failed) \n return;\n if (\"closed\" == = this.readyState)\n return;\n cleanup();\n this.setTransport(transport);\n transport.send([{ type: \"upgrade\" }]);\n th is.emitReserved(\"upgrade\", transport);\n transport = nu ll;\n this.upgrading = false;\n th is.flush();\n });\n }\n else {\ n const err = new Error(\"probe error\");\n // @ts-ignore\n err.transport = transport.name;\n this.emitReserved(\"upgradeError\", err);\n }\n });\n };\n function freezeTransport() {\n if (faile d)\n return;\n // Any callback called by transport sho uld be ignored since now\n failed = true;\n cleanup();\n transport.close();\n transport = null;\n }\n // Handle any error that happens while probing\n const onerror = err => { \n const error = new Error(\"probe error: \" + err);\n // @ts-ignore\n error.transport = transport.name;\n freezeTra nsport();\n this.emitReserved(\"upgradeError\", error);\n };\n function onTransportClose() {\n onerror(\"transport closed\") ;\n }\n // When the socket is closed while we're probing\n function onclose() {\n onerror(\"socket closed\");\n }\n // When the socket is upgraded while we're probing\n function onupgrade (to) {\n if (transport && to.name !== transport.name) {\n freezeTransport();\n }\n }\n // Remove all listener s on the transport and on self\n const cleanup = () => {\n tra nsport.removeListener(\"open\", onTransportOpen);\n transport.removeL istener(\"error\", onerror);\n transport.removeListener(\"close\", on TransportClose);\n this.off(\"close\", onclose);\n this.of f(\"upgrading\", onupgrade);\n };\n transport.once(\"open\", onTra nsportOpen);\n transport.once(\"error\", onerror);\n transport.onc e(\"close\", onTransportClose);\n this.once(\"close\", onclose);\n this.once(\"upgrading\", onupgrade);\n transport.open();\n }\n /** \n * Called when connection is deemed open.\n *\n * @api private\n */\n onOpen() {\n this.readyState = \"open\";\n Socket.prior WebsocketSuccess = \"websocket\" === this.transport.name;\n this.emitRese rved(\"open\");\n this.flush();\n // we check for `readyState` in case an `open`\n // listener already closed the socket\n if (\"ope n\" === this.readyState &&\n this.opts.upgrade &&\n this.t ransport.pause) {\n let i = 0;\n const l = this.upgrades.l ength;\n for (; i < l; i++) {\n this.probe(this.upgrad es[i]);\n }\n }\n }\n /**\n * Handles a packet.\n *\n * @api private\n */\n onPacket(packet) {\n if (\"opening \" === this.readyState ||\n \"open\" === this.readyState ||\n \"closing\" === this.readyState) {\n this.emitReserved(\"packet\" , packet);\n // Socket is live - any packet counts\n this. emitReserved(\"heartbeat\");\n switch (packet.type) {\n case \"open\":\n this.onHandshake(JSON.parse(packet.data)); \n break;\n case \"ping\":\n this.resetPingTimeout();\n this.sendPacket(\"pong\");\n this.emitReserved(\"ping\");\n this.emitReser ved(\"pong\");\n break;\n case \"error\":\n const err = new Error(\"server error\");\n / / @ts-ignore\n err.code = packet.data;\n t his.onError(err);\n break;\n case \"message\": \n this.emitReserved(\"data\", packet.data);\n this.emitReserved(\"message\", packet.data);\n break;\n }\n }\n else {\n }\n }\n /**\n * Calle d upon handshake completion.\n *\n * @param {Object} data - handshake ob j\n * @api private\n */\n onHandshake(data) {\n this.emitReser ved(\"handshake\", data);\n this.id = data.sid;\n this.transport.q uery.sid = data.sid;\n this.upgrades = this.filterUpgrades(data.upgrades) ;\n this.pingInterval = data.pingInterval;\n this.pingTimeout = da ta.pingTimeout;\n this.maxPayload = data.maxPayload;\n this.onOpen ();\n // In case open handler closes socket\n if (\"closed\" === t his.readyState)\n return;\n this.resetPingTimeout();\n }\n /**\n * Sets and resets ping timeout timer based on server pings.\n * \n * @api private\n */\n resetPingTimeout() {\n this.clearTime outFn(this.pingTimeoutTimer);\n this.pingTimeoutTimer = this.setTimeoutFn (() => {\n this.onClose(\"ping timeout\");\n }, this.pingInter val + this.pingTimeout);\n if (this.opts.autoUnref) {\n this.p ingTimeoutTimer.unref();\n }\n }\n /**\n * Called on `drain` ev ent\n *\n * @api private\n */\n onDrain() {\n this.writeBu ffer.splice(0, this.prevBufferLen);\n // setting prevBufferLen = 0 is ver y important\n // for example, when upgrading, upgrade packet is sent over ,\n // and a nonzero prevBufferLen could cause problems on `drain`\n this.prevBufferLen = 0;\n if (0 === this.writeBuffer.length) {\n this.emitReserved(\"drain\");\n }\n else {\n this .flush();\n }\n }\n /**\n * Flush write buffers.\n *\n * @api private\n */\n flush() {\n if (\"closed\" !== this.readySta te &&\n this.transport.writable &&\n !this.upgrading &&\n this.writeBuffer.length) {\n const packets = this.getWrita blePackets();\n this.transport.send(packets);\n // keep tr ack of current length of writeBuffer\n // splice writeBuffer and call backBuffer on `drain`\n this.prevBufferLen = packets.length;\n this.emitReserved(\"flush\");\n }\n }\n /**\n * Ensure the encoded size of the writeBuffer is below the maxPayload value sent by the serve r (only for HTTP\n * long-polling)\n *\n * @private\n */\n ge tWritablePackets() {\n const shouldCheckPayloadSize = this.maxPayload &&\ n this.transport.name === \"polling\" &&\n this.writeBuffe r.length > 1;\n if (!shouldCheckPayloadSize) {\n return this.w riteBuffer;\n }\n let payloadSize = 1; // first packet type\n for (let i = 0; i < this.writeBuffer.length; i++) {\n const data = this.writeBuffer[i].data;\n if (data) {\n payloadSize += byteLength(data);\n }\n if (i > 0 && payloadSize > thi s.maxPayload) {\n return this.writeBuffer.slice(0, i);\n }\n payloadSize += 2; // separator + packet type\n }\n return this.writeBuffer;\n }\n /**\n * Sends a message.\n *\n * @param {String} message.\n * @param {Function} callback function.\n * @param {Object} options.\n * @return {Socket} for chaining.\n * @api public\n */\n write(msg, options, fn) {\n this.sendPacket(\"messag e\", msg, options, fn);\n return this;\n }\n send(msg, options, fn) {\n this.sendPacket(\"message\", msg, options, fn);\n return this ;\n }\n /**\n * Sends a packet.\n *\n * @param {String} packet type.\n * @param {String} data.\n * @param {Object} options.\n * @p aram {Function} callback function.\n * @api private\n */\n sendPacket (type, data, options, fn) {\n if (\"function\" === typeof data) {\n fn = data;\n data = undefined;\n }\n if (\"functi on\" === typeof options) {\n fn = options;\n options = nul l;\n }\n if (\"closing\" === this.readyState || \"closed\" === thi s.readyState) {\n return;\n }\n options = options || {} ;\n options.compress = false !== options.compress;\n const packet = {\n type: type,\n data: data,\n options: opti ons\n };\n this.emitReserved(\"packetCreate\", packet);\n t his.writeBuffer.push(packet);\n if (fn)\n this.once(\"flush\", fn);\n this.flush();\n }\n /**\n * Closes the connection.\n *\n * @api public\n */\n close() {\n const close = () => {\n this.onClose(\"forced close\");\n this.transport.close(); \n };\n const cleanupAndClose = () => {\n this.off(\"up grade\", cleanupAndClose);\n this.off(\"upgradeError\", cleanupAndClo se);\n close();\n };\n const waitForUpgrade = () => {\n // wait for upgrade to finish since we can't send packets while paus ing a transport\n this.once(\"upgrade\", cleanupAndClose);\n this.once(\"upgradeError\", cleanupAndClose);\n };\n if (\"open ing\" === this.readyState || \"open\" === this.readyState) {\n this.r eadyState = \"closing\";\n if (this.writeBuffer.length) {\n this.once(\"drain\", () => {\n if (this.upgrading) {\n waitForUpgrade();\n }\n else {\n close();\n }\n });\n }\n else if (this.upgrading) {\n waitForUpgrade();\n }\n else {\n close(); \n }\n }\n return this;\n }\n /**\n * Called upon transport error\n *\n * @api private\n */\n onError(err) {\n Socket.priorWebsocketSuccess = false;\n this.emitReserved(\"error \", err);\n this.onClose(\"transport error\", err);\n }\n /**\n * Called upon transport close.\n *\n * @api private\n */\n onClo se(reason, description) {\n if (\"opening\" === this.readyState ||\n \"open\" === this.readyState ||\n \"closing\" === this.readySt ate) {\n // clear timers\n this.clearTimeoutFn(this.pingTi meoutTimer);\n // stop event from firing again for transport\n this.transport.removeAllListeners(\"close\");\n // ensure transp ort won't stay open\n this.transport.close();\n // ignore further transport communication\n this.transport.removeAllListeners() ;\n if (typeof removeEventListener === \"function\") {\n removeEventListener(\"offline\", this.offlineEventListener, false);\n }\n // set ready state\n this.readyState = \"closed\"; \n // clear session id\n this.id = null;\n // e mit close event\n this.emitReserved(\"close\", reason, description);\ n // clean buffers after, so users can still\n // grab the buffers on `close` event\n this.writeBuffer = [];\n this. prevBufferLen = 0;\n }\n }\n /**\n * Filters upgrades, returnin g only those matching client transports.\n *\n * @param {Array} server u pgrades\n * @api private\n *\n */\n filterUpgrades(upgrades) {\n const filteredUpgrades = [];\n let i = 0;\n const j = upgra des.length;\n for (; i < j; i++) {\n if (~this.transports.inde xOf(upgrades[i]))\n filteredUpgrades.push(upgrades[i]);\n }\n return filteredUpgrades;\n }\n}\nSocket.protocol = protocol;\n","c onst withNativeArrayBuffer = typeof ArrayBuffer === \"function\";\nconst isView = (obj) => {\n return typeof ArrayBuffer.isView === \"function\"\n ? A rrayBuffer.isView(obj)\n : obj.buffer instanceof ArrayBuffer;\n};\nconst toString = Object.prototype.toString;\nconst withNativeBlob = typeof Blob === \" function\" ||\n (typeof Blob !== \"undefined\" &&\n toString.call(Blob ) === \"[object BlobConstructor]\");\nconst withNativeFile = typeof File === \"f unction\" ||\n (typeof File !== \"undefined\" &&\n toString.call(File) === \"[object FileConstructor]\");\n/**\n * Returns true if obj is a Buffer, an ArrayBuffer, a Blob or a File.\n *\n * @private\n */\nexport function isBinary( obj) {\n return ((withNativeArrayBuffer && (obj instanceof ArrayBuffer || isV iew(obj))) ||\n (withNativeBlob && obj instanceof Blob) ||\n (with NativeFile && obj instanceof File));\n}\nexport function hasBinary(obj, toJSON) {\n if (!obj || typeof obj !== \"object\") {\n return false;\n }\n if (Array.isArray(obj)) {\n for (let i = 0, l = obj.length; i < l; i++ ) {\n if (hasBinary(obj[i])) {\n return true;\n }\n }\n return false;\n }\n if (isBinary(obj)) {\n return true;\n }\n if (obj.toJSON &&\n typeof obj.toJSON === \"f unction\" &&\n arguments.length === 1) {\n return hasBinary(obj.to JSON(), true);\n }\n for (const key in obj) {\n if (Object.prototyp e.hasOwnProperty.call(obj, key) && hasBinary(obj[key])) {\n return tr ue;\n }\n }\n return false;\n}\n","import { isBinary } from \"./is- binary.js\";\n/**\n * Replaces every Buffer | ArrayBuffer | Blob | File in packe t with a numbered placeholder.\n *\n * @param {Object} packet - socket.io event packet\n * @return {Object} with deconstructed packet and list of buffers\n * @p ublic\n */\nexport function deconstructPacket(packet) {\n const buffers = []; \n const packetData = packet.data;\n const pack = packet;\n pack.data = _deconstructPacket(packetData, buffers);\n pack.attachments = buffers.length ; // number of binary 'attachments'\n return { packet: pack, buffers: buffers };\n}\nfunction _deconstructPacket(data, buffers) {\n if (!data)\n re turn data;\n if (isBinary(data)) {\n const placeholder = { _placeholde r: true, num: buffers.length };\n buffers.push(data);\n return pla ceholder;\n }\n else if (Array.isArray(data)) {\n const newData = n ew Array(data.length);\n for (let i = 0; i < data.length; i++) {\n newData[i] = _deconstructPacket(data[i], buffers);\n }\n retu rn newData;\n }\n else if (typeof data === \"object\" && !(data instanceof Date)) {\n const newData = {};\n for (const key in data) {\n if (Object.prototype.hasOwnProperty.call(data, key)) {\n n ewData[key] = _deconstructPacket(data[key], buffers);\n }\n }\ n return newData;\n }\n return data;\n}\n/**\n * Reconstructs a bin ary packet from its placeholder packet and buffers\n *\n * @param {Object} packe t - event packet with placeholders\n * @param {Array} buffers - binary buffers t o put in placeholder positions\n * @return {Object} reconstructed packet\n * @pu blic\n */\nexport function reconstructPacket(packet, buffers) {\n packet.data = _reconstructPacket(packet.data, buffers);\n packet.attachments = undefined ; // no longer useful\n return packet;\n}\nfunction _reconstructPacket(data, buffers) {\n if (!data)\n return data;\n if (data && data._placehol der) {\n return buffers[data.num]; // appropriate buffer (should be natur al order anyway)\n }\n else if (Array.isArray(data)) {\n for (let i = 0; i < data.length; i++) {\n data[i] = _reconstructPacket(data[i], buffers);\n }\n }\n else if (typeof data === \"object\") {\n for (const key in data) {\n if (Object.prototype.hasOwnProperty.cal l(data, key)) {\n data[key] = _reconstructPacket(data[key], buffe rs);\n }\n }\n }\n return data;\n}\n","import { Emitter } from \"@socket.io/component-emitter\";\nimport { deconstructPacket, reconstruc tPacket } from \"./binary.js\";\nimport { isBinary, hasBinary } from \"./is-bina ry.js\";\n/**\n * Protocol version.\n *\n * @public\n */\nexport const protocol = 5;\nexport var PacketType;\n(function (PacketType) {\n PacketType[PacketTyp e[\"CONNECT\"] = 0] = \"CONNECT\";\n PacketType[PacketType[\"DISCONNECT\"] = 1] = \"DISCONNECT\";\n PacketType[PacketType[\"EVENT\"] = 2] = \"EVENT\";\n PacketType[PacketType[\"ACK\"] = 3] = \"ACK\";\n PacketType[PacketType[\"CO NNECT_ERROR\"] = 4] = \"CONNECT_ERROR\";\n PacketType[PacketType[\"BINARY_EVE NT\"] = 5] = \"BINARY_EVENT\";\n PacketType[PacketType[\"BINARY_ACK\"] = 6] = \"BINARY_ACK\";\n})(PacketType || (PacketType = {}));\n/**\n * A socket.io Enco der instance\n */\nexport class Encoder {\n /**\n * Encoder constructor\n *\n * @param {function} replacer - custom replacer to pass down to JSON .parse\n */\n constructor(replacer) {\n this.replacer = replacer;\ n }\n /**\n * Encode a packet as a single string if non-binary, or as a\n * buffer sequence, depending on packet type.\n *\n * @param {Obj ect} obj - packet object\n */\n encode(obj) {\n if (obj.type === P acketType.EVENT || obj.type === PacketType.ACK) {\n if (hasBinary(obj )) {\n obj.type =\n obj.type === PacketType.EV ENT\n ? PacketType.BINARY_EVENT\n : PacketType.BINARY_ACK;\n return this.encodeAsBinary(obj);\n }\n }\n return [this.encodeAsString(obj)];\n }\n /** \n * Encode packet as string.\n */\n encodeAsString(obj) {\n / / first is type\n let str = \"\" + obj.type;\n // attachments if w e have them\n if (obj.type === PacketType.BINARY_EVENT ||\n ob j.type === PacketType.BINARY_ACK) {\n str += obj.attachments + \"-\"; \n }\n // if we have a namespace other than `/`\n // we app end it followed by a comma `,`\n if (obj.nsp && \"/\" !== obj.nsp) {\n str += obj.nsp + \",\";\n }\n // immediately followed by the id\n if (null != obj.id) {\n str += obj.id;\n }\n // json data\n if (null != obj.data) {\n str += JSON.str ingify(obj.data, this.replacer);\n }\n return str;\n }\n /** \n * Encode packet as 'buffer sequence' by removing blobs, and\n * decon structing packet into object with placeholders and\n * a list of buffers.\n */\n encodeAsBinary(obj) {\n const deconstruction = deconstructPac ket(obj);\n const pack = this.encodeAsString(deconstruction.packet);\n const buffers = deconstruction.buffers;\n buffers.unshift(pack); // add packet info to beginning of data list\n return buffers; // write all the buffers\n }\n}\n/**\n * A socket.io Decoder instance\n *\n * @return {Obj ect} decoder\n */\nexport class Decoder extends Emitter {\n /**\n * Decod er constructor\n *\n * @param {function} reviver - custom reviver to pas s down to JSON.stringify\n */\n constructor(reviver) {\n super();\ n this.reviver = reviver;\n }\n /**\n * Decodes an encoded pack et string into packet JSON.\n *\n * @param {String} obj - encoded packet \n */\n add(obj) {\n let packet;\n if (typeof obj === \"str ing\") {\n packet = this.decodeString(obj);\n if (packet.t ype === PacketType.BINARY_EVENT ||\n packet.type === PacketType.B INARY_ACK) {\n // binary packet's json\n this.reco nstructor = new BinaryReconstructor(packet);\n // no attachments, labeled binary but no binary data to follow\n if (packet.attachm ents === 0) {\n super.emitReserved(\"decoded\", packet);\n }\n }\n else {\n // non-binary full packet\n super.emitReserved(\"decoded\", packet);\n }\n }\n else if (isBinary(obj) || obj.base64) {\n / / raw binary data\n if (!this.reconstructor) {\n throw new Error(\"got binary data when not reconstructing a packet\");\n } \n else {\n packet = this.reconstructor.takeBinaryData (obj);\n if (packet) {\n // received final buf fer\n this.reconstructor = null;\n super.e mitReserved(\"decoded\", packet);\n }\n }\n }\n else {\n throw new Error(\"Unknown type: \" + obj);\n }\n }\n /**\n * Decode a packet String (JSON data)\n *\n * @pa ram {String} str\n * @return {Object} packet\n */\n decodeString(str) {\n let i = 0;\n // look up type\n const p = {\n type: Number(str.charAt(0)),\n };\n if (PacketType[p.type] === u ndefined) {\n throw new Error(\"unknown packet type \" + p.type);\n }\n // look up attachments if type binary\n if (p.type === P acketType.BINARY_EVENT ||\n p.type === PacketType.BINARY_ACK) {\n const start = i + 1;\n while (str.charAt(++i) !== \"-\" && i != str.length) { }\n const buf = str.substring(start, i);\n if (buf != Number(buf) || str.charAt(i) !== \"-\") {\n throw ne w Error(\"Illegal attachments\");\n }\n p.attachments = Nu mber(buf);\n }\n // look up namespace (if any)\n if (\"/\" === str.charAt(i + 1)) {\n const start = i + 1;\n while (+ +i) {\n const c = str.charAt(i);\n if (\",\" === c )\n break;\n if (i === str.length)\n break;\n }\n p.nsp = str.substring(start, i);\n }\n else {\n p.nsp = \"/\";\n }\n // look up id\n const next = str.charAt(i + 1);\n if (\"\" !== next && Nu mber(next) == next) {\n const start = i + 1;\n while (++i) {\n const c = str.charAt(i);\n if (null == c || N umber(c) != c) {\n --i;\n break;\n }\n if (i === str.length)\n break;\n }\n p.id = Number(str.substring(start, i + 1));\n }\ n // look up json data\n if (str.charAt(++i)) {\n const payload = this.tryParse(str.substr(i));\n if (Decoder.isPayloadValid (p.type, payload)) {\n p.data = payload;\n }\n else {\n throw new Error(\"invalid payload\");\n } \n }\n return p;\n }\n tryParse(str) {\n try {\n return JSON.parse(str, this.reviver);\n }\n catch (e) {\n return false;\n }\n }\n static isPayloadValid(type, paylo ad) {\n switch (type) {\n case PacketType.CONNECT:\n return typeof payload === \"object\";\n case PacketType.DISCONN ECT:\n return payload === undefined;\n case PacketType .CONNECT_ERROR:\n return typeof payload === \"string\" || typeof payload === \"object\";\n case PacketType.EVENT:\n case Pa cketType.BINARY_EVENT:\n return Array.isArray(payload) && payload .length > 0;\n case PacketType.ACK:\n case PacketType.BINA RY_ACK:\n return Array.isArray(payload);\n }\n }\n / **\n * Deallocates a parser's resources\n */\n destroy() {\n i f (this.reconstructor) {\n this.reconstructor.finishedReconstruction( );\n }\n }\n}\n/**\n * A manager of a binary event's 'buffer sequence' . Should\n * be constructed whenever a packet of type BINARY_EVENT is\n * decode d.\n *\n * @param {Object} packet\n * @return {BinaryReconstructor} initialized reconstructor\n */\nclass BinaryReconstructor {\n constructor(packet) {\n this.packet = packet;\n this.buffers = [];\n this.reconPack = packet;\n }\n /**\n * Method to be called when binary data received fr om connection\n * after a BINARY_EVENT packet.\n *\n * @param {Buffe r | ArrayBuffer} binData - the raw binary data received\n * @return {null | Object} returns null if more binary data is expected or\n * a reconstructe d packet object if all buffers have been received.\n */\n takeBinaryData( binData) {\n this.buffers.push(binData);\n if (this.buffers.length === this.reconPack.attachments) {\n // done with buffer list\n const packet = reconstructPacket(this.reconPack, this.buffers);\n this.finishedReconstruction();\n return packet;\n }\n return null;\n }\n /**\n * Cleans up binary packet reconstruction va riables.\n */\n finishedReconstruction() {\n this.reconPack = null ;\n this.buffers = [];\n }\n}\n","export function on(obj, ev, fn) {\n obj.on(ev, fn);\n return function subDestroy() {\n obj.off(ev, fn); \n };\n}\n","import { PacketType } from \"socket.io-parser\";\nimport { on } from \"./on.js\";\nimport { Emitter, } from \"@socket.io/component-emitter\";\n/ **\n * Internal events.\n * These events can't be emitted by the user.\n */\ncon st RESERVED_EVENTS = Object.freeze({\n connect: 1,\n connect_error: 1,\n disconnect: 1,\n disconnecting: 1,\n // EventEmitter reserved events: ht tps://nodejs.org/api/events.html#events_event_newlistener\n newListener: 1,\n removeListener: 1,\n});\nexport class Socket extends Emitter {\n /**\n * `Socket` constructor.\n *\n * @public\n */\n constructor(io, nsp, opts) {\n super();\n this.connected = false;\n this.re ceiveBuffer = [];\n this.sendBuffer = [];\n this.ids = 0;\n this.acks = {};\n this.flags = {};\n this.io = io;\n this. nsp = nsp;\n if (opts && opts.auth) {\n this.auth = opts.auth; \n }\n if (this.io._autoConnect)\n this.open();\n }\ n /**\n * Whether the socket is currently disconnected\n */\n get disconnected() {\n return !this.connected;\n }\n /**\n * Subscr ibe to open, close and packet events\n *\n * @private\n */\n subE vents() {\n if (this.subs)\n return;\n const io = this. io;\n this.subs = [\n on(io, \"open\", this.onopen.bind(this)) ,\n on(io, \"packet\", this.onpacket.bind(this)),\n on(io, \"error\", this.onerror.bind(this)),\n on(io, \"close\", this.onclos e.bind(this)),\n ];\n }\n /**\n * Whether the Socket will try t o reconnect when its Manager connects or reconnects\n */\n get active() { \n return !!this.subs;\n }\n /**\n * \"Opens\" the socket.\n *\n * @public\n */\n connect() {\n if (this.connected)\n return this;\n this.subEvents();\n if (!this.io[\"_reconne cting\"])\n this.io.open(); // ensure open\n if (\"open\" === this.io._readyState)\n this.onopen();\n return this;\n }\n /**\n * Alias for connect()\n */\n open() {\n return this.c onnect();\n }\n /**\n * Sends a `message` event.\n *\n * @retu rn self\n * @public\n */\n send(...args) {\n args.unshift(\"me ssage\");\n this.emit.apply(this, args);\n return this;\n }\n /**\n * Override `emit`.\n * If the event is in `events`, it's emitted normally.\n *\n * @return self\n * @public\n */\n emit(ev, . ..args) {\n if (RESERVED_EVENTS.hasOwnProperty(ev)) {\n throw new Error('\"' + ev + '\" is a reserved event name');\n }\n args.u nshift(ev);\n const packet = {\n type: PacketType.EVENT,\n data: args,\n };\n packet.options = {};\n packet.op tions.compress = this.flags.compress !== false;\n // event ack callback\n if (\"function\" === typeof args[args.length - 1]) {\n const id = this.ids++;\n const ack = args.pop();\n this._registe rAckCallback(id, ack);\n packet.id = id;\n }\n const is TransportWritable = this.io.engine &&\n this.io.engine.transport &&\n this.io.engine.transport.writable;\n const discardPacket = th is.flags.volatile && (!isTransportWritable || !this.connected);\n if (dis cardPacket) {\n }\n else if (this.connected) {\n this.n otifyOutgoingListeners(packet);\n this.packet(packet);\n }\n else {\n this.sendBuffer.push(packet);\n }\n this .flags = {};\n return this;\n }\n /**\n * @private\n */\n _registerAckCallback(id, ack) {\n const timeout = this.flags.timeout;\n if (timeout === undefined) {\n this.acks[id] = ack;\n return;\n }\n // @ts-ignore\n const timer = this.io.set TimeoutFn(() => {\n delete this.acks[id];\n for (let i = 0 ; i < this.sendBuffer.length; i++) {\n if (this.sendBuffer[i].id === id) {\n this.sendBuffer.splice(i, 1);\n }\ n }\n ack.call(this, new Error(\"operation has timed out\" ));\n }, timeout);\n this.acks[id] = (...args) => {\n / / @ts-ignore\n this.io.clearTimeoutFn(timer);\n ack.apply( this, [null, ...args]);\n };\n }\n /**\n * Sends a packet.\n *\n * @param packet\n * @private\n */\n packet(packet) {\n packet.nsp = this.nsp;\n this.io._packet(packet);\n }\n /**\n * Called upon engine `open`.\n *\n * @private\n */\n onopen() { \n if (typeof this.auth == \"function\") {\n this.auth((data) => {\n this.packet({ type: PacketType.CONNECT, data });\n });\n }\n else {\n this.packet({ type: PacketType.C ONNECT, data: this.auth });\n }\n }\n /**\n * Called upon engin e or manager `error`.\n *\n * @param err\n * @private\n */\n onerror(err) {\n if (!this.connected) {\n this.emitReserved(\" connect_error\", err);\n }\n }\n /**\n * Called upon engine `cl ose`.\n *\n * @param reason\n * @param description\n * @private\ n */\n onclose(reason, description) {\n this.connected = false;\n delete this.id;\n this.emitReserved(\"disconnect\", reason, descri ption);\n }\n /**\n * Called with socket packet.\n *\n * @para m packet\n * @private\n */\n onpacket(packet) {\n const sameNa mespace = packet.nsp === this.nsp;\n if (!sameNamespace)\n ret urn;\n switch (packet.type) {\n case PacketType.CONNECT:\n if (packet.data && packet.data.sid) {\n const id = packet.data.sid;\n this.onconnect(id);\n }\n else {\n this.emitReserved(\"connect_error\", new Error(\"It seems you are trying to reach a Socket.IO server in v2.x with a v3.x client, but they are not compatible (more information here: https://socket. io/docs/v3/migrating-from-2-x-to-3-0/)\"));\n }\n break;\n case PacketType.EVENT:\n case PacketType.BINARY_E VENT:\n this.onevent(packet);\n break;\n case PacketType.ACK:\n case PacketType.BINARY_ACK:\n this.onack(packet);\n break;\n case PacketType.DISCON NECT:\n this.ondisconnect();\n break;\n case PacketType.CONNECT_ERROR:\n this.destroy();\n const err = new Error(packet.data.message);\n // @ts-ignore\n err.data = packet.data.data;\n this.emitReserved(\" connect_error\", err);\n break;\n }\n }\n /**\n * Called upon a server event.\n *\n * @param packet\n * @private\n */\n onevent(packet) {\n const args = packet.data || [];\n i f (null != packet.id) {\n args.push(this.ack(packet.id));\n }\ n if (this.connected) {\n this.emitEvent(args);\n }\n else {\n this.receiveBuffer.push(Object.freeze(args));\n }\n }\n emitEvent(args) {\n if (this._anyListeners && this._anyLis teners.length) {\n const listeners = this._anyListeners.slice();\n for (const listener of listeners) {\n listener.apply(thi s, args);\n }\n }\n super.emit.apply(this, args);\n }\n /**\n * Produces an ack callback to emit with an event.\n *\n * @private\n */\n ack(id) {\n const self = this;\n let sen t = false;\n return function (...args) {\n // prevent double c allbacks\n if (sent)\n return;\n sent = tru e;\n self.packet({\n type: PacketType.ACK,\n id: id,\n data: args,\n });\n };\n }\n /**\n * Called upon a server acknowlegement.\n *\n * @param pack et\n * @private\n */\n onack(packet) {\n const ack = this.acks [packet.id];\n if (\"function\" === typeof ack) {\n ack.apply( this, packet.data);\n delete this.acks[packet.id];\n }\n else {\n }\n }\n /**\n * Called upon server connect.\n *\ n * @private\n */\n onconnect(id) {\n this.id = id;\n t his.connected = true;\n this.emitBuffered();\n this.emitReserved(\ "connect\");\n }\n /**\n * Emit buffered events (received and emitted) .\n *\n * @private\n */\n emitBuffered() {\n this.receiveB uffer.forEach((args) => this.emitEvent(args));\n this.receiveBuffer = []; \n this.sendBuffer.forEach((packet) => {\n this.notifyOutgoing Listeners(packet);\n this.packet(packet);\n });\n this. sendBuffer = [];\n }\n /**\n * Called upon server disconnect.\n *\ n * @private\n */\n ondisconnect() {\n this.destroy();\n this.onclose(\"io server disconnect\");\n }\n /**\n * Called upon fo rced client/server side disconnections,\n * this method ensures the manager stops tracking us and\n * that reconnections don't get triggered for this.\n *\n * @private\n */\n destroy() {\n if (this.subs) {\n // clean subscriptions to avoid reconnections\n this.subs.fo rEach((subDestroy) => subDestroy());\n this.subs = undefined;\n }\n this.io[\"_destroy\"](this);\n }\n /**\n * Disconnects th e socket manually.\n *\n * @return self\n * @public\n */\n di sconnect() {\n if (this.connected) {\n this.packet({ type: Pac ketType.DISCONNECT });\n }\n // remove socket from pool\n t his.destroy();\n if (this.connected) {\n // fire events\n this.onclose(\"io client disconnect\");\n }\n return this;\ n }\n /**\n * Alias for disconnect()\n *\n * @return self\n * @public\n */\n close() {\n return this.disconnect();\n }\n /**\n * Sets the compress flag.\n *\n * @param compress - if `tru e`, compresses the sending data\n * @return self\n * @public\n */\n compress(compress) {\n this.flags.compress = compress;\n return this;\n }\n /**\n * Sets a modifier for a subsequent event emission t hat the event message will be dropped when this socket is not\n * ready to s end messages.\n *\n * @returns self\n * @public\n */\n get vo latile() {\n this.flags.volatile = true;\n return this;\n }\n /**\n * Sets a modifier for a subsequent event emission that the callback will be called with an error when the\n * given number of milliseconds have elapsed without an acknowledgement from the server:\n *\n * ```\n * socket.timeout(5000).emit(\"my-event\", (err) => {\n * if (err) {\n * // the server did not acknowledge the event in the given delay\n * }\n * });\n * ```\n *\n * @returns self\n * @public\n */\n timeout(timeout) {\n this.flags.timeout = timeout;\n return thi s;\n }\n /**\n * Adds a listener that will be fired when any event is emitted. The event name is passed as the first argument to the\n * callback. \n *\n * @param listener\n * @public\n */\n onAny(listener) { \n this._anyListeners = this._anyListeners || [];\n this._anyListe ners.push(listener);\n return this;\n }\n /**\n * Adds a listen er that will be fired when any event is emitted. The event name is passed as the first argument to the\n * callback. The listener is added to the beginning of the listeners array.\n *\n * @param listener\n * @public\n */ \n prependAny(listener) {\n this._anyListeners = this._anyListeners || [];\n this._anyListeners.unshift(listener);\n return this;\n } \n /**\n * Removes the listener that will be fired when any event is emit ted.\n *\n * @param listener\n * @public\n */\n offAny(listen er) {\n if (!this._anyListeners) {\n return this;\n }\n if (listener) {\n const listeners = this._anyListeners;\n for (let i = 0; i < listeners.length; i++) {\n if (listen er === listeners[i]) {\n listeners.splice(i, 1);\n return this;\n }\n }\n }\n else {\n this._anyListeners = [];\n }\n return this;\n } \n /**\n * Returns an array of listeners that are listening for any event that is specified. This array can be manipulated,\n * e.g. to remove listen ers.\n *\n * @public\n */\n listenersAny() {\n return this ._anyListeners || [];\n }\n /**\n * Adds a listener that will be fired when any event is emitted. The event name is passed as the first argument to th e\n * callback.\n *\n * @param listener\n *\n * <pre><code>\ n *\n * socket.onAnyOutgoing((event, ...args) => {\n * console.log (event);\n * });\n *\n * </pre></code>\n *\n * @public\n */\n onAnyOutgoing(listener) {\n this._anyOutgoingListeners = this._a nyOutgoingListeners || [];\n this._anyOutgoingListeners.push(listener);\n return this;\n }\n /**\n * Adds a listener that will be fired when any event is emitted. The event name is passed as the first argument to the \n * callback. The listener is added to the beginning of the listeners array .\n *\n * @param listener\n *\n * <pre><code>\n *\n * so cket.prependAnyOutgoing((event, ...args) => {\n * console.log(event);\n * });\n *\n * </pre></code>\n *\n * @public\n */\n prep endAnyOutgoing(listener) {\n this._anyOutgoingListeners = this._anyOutgoi ngListeners || [];\n this._anyOutgoingListeners.unshift(listener);\n return this;\n }\n /**\n * Removes the listener that will be fired when any event is emitted.\n *\n * @param listener\n *\n * <pre> <code>\n *\n * const handler = (event, ...args) => {\n * console.l og(event);\n * }\n *\n * socket.onAnyOutgoing(handler);\n *\n * // then later\n * socket.offAnyOutgoing(handler);\n *\n * </pre> </code>\n *\n * @public\n */\n offAnyOutgoing(listener) {\n if (!this._anyOutgoingListeners) {\n return this;\n }\n if (listener) {\n const listeners = this._anyOutgoingListeners;\n for (let i = 0; i < listeners.length; i++) {\n if (lis tener === listeners[i]) {\n listeners.splice(i, 1);\n return this;\n }\n }\n }\n e lse {\n this._anyOutgoingListeners = [];\n }\n return t his;\n }\n /**\n * Returns an array of listeners that are listening fo r any event that is specified. This array can be manipulated,\n * e.g. to re move listeners.\n *\n * @public\n */\n listenersAnyOutgoing() {\n return this._anyOutgoingListeners || [];\n }\n /**\n * Notify the listeners for each packet sent\n *\n * @param packet\n *\n * @private\n */\n notifyOutgoingListeners(packet) {\n if (this._any OutgoingListeners && this._anyOutgoingListeners.length) {\n const lis teners = this._anyOutgoingListeners.slice();\n for (const listener of listeners) {\n listener.apply(this, packet.data);\n } \n }\n }\n}\n","/**\n * Initialize backoff timer with `opts`.\n *\n * - `min` initial timeout in milliseconds [100]\n * - `max` max timeout [10000]\n * - `jitter` [0]\n * - `factor` [2]\n *\n * @param {Object} opts\n * @api public \n */\nexport function Backoff(opts) {\n opts = opts || {};\n this.ms = op ts.min || 100;\n this.max = opts.max || 10000;\n this.factor = opts.factor || 2;\n this.jitter = opts.jitter > 0 && opts.jitter <= 1 ? opts.jitter : 0; \n this.attempts = 0;\n}\n/**\n * Return the backoff duration.\n *\n * @retur n {Number}\n * @api public\n */\nBackoff.prototype.duration = function () {\n var ms = this.ms * Math.pow(this.factor, this.attempts++);\n if (this.jitter ) {\n var rand = Math.random();\n var deviation = Math.floor(rand * this.jitter * ms);\n ms = (Math.floor(rand * 10) & 1) == 0 ? ms - devia tion : ms + deviation;\n }\n return Math.min(ms, this.max) | 0;\n};\n/**\n * Reset the number of attempts.\n *\n * @api public\n */\nBackoff.prototype.res et = function () {\n this.attempts = 0;\n};\n/**\n * Set the minimum duration \n *\n * @api public\n */\nBackoff.prototype.setMin = function (min) {\n this .ms = min;\n};\n/**\n * Set the maximum duration\n *\n * @api public\n */\nBacko ff.prototype.setMax = function (max) {\n this.max = max;\n};\n/**\n * Set the jitter\n *\n * @api public\n */\nBackoff.prototype.setJitter = function (jitter ) {\n this.jitter = jitter;\n};\n","import { Socket as Engine, installTimerFu nctions, } from \"engine.io-client\";\nimport { Socket } from \"./socket.js\";\n import * as parser from \"socket.io-parser\";\nimport { on } from \"./on.js\";\n import { Backoff } from \"./contrib/backo2.js\";\nimport { Emitter, } from \"@so cket.io/component-emitter\";\nexport class Manager extends Emitter {\n constr uctor(uri, opts) {\n var _a;\n super();\n this.nsps = {};\n this.subs = [];\n if (uri && \"object\" === typeof uri) {\n opts = uri;\n uri = undefined;\n }\n opts = opts || {};\n opts.path = opts.path || \"/socket.io\";\n this.opts = op ts;\n installTimerFunctions(this, opts);\n this.reconnection(opts. reconnection !== false);\n this.reconnectionAttempts(opts.reconnectionAtt empts || Infinity);\n this.reconnectionDelay(opts.reconnectionDelay || 10 00);\n this.reconnectionDelayMax(opts.reconnectionDelayMax || 5000);\n this.randomizationFactor((_a = opts.randomizationFactor) !== null && _a !== void 0 ? _a : 0.5);\n this.backoff = new Backoff({\n min: thi s.reconnectionDelay(),\n max: this.reconnectionDelayMax(),\n jitter: this.randomizationFactor(),\n });\n this.timeout(null = = opts.timeout ? 20000 : opts.timeout);\n this._readyState = \"closed\";\ n this.uri = uri;\n const _parser = opts.parser || parser;\n this.encoder = new _parser.Encoder();\n this.decoder = new _parser.Deco der();\n this._autoConnect = opts.autoConnect !== false;\n if (thi s._autoConnect)\n this.open();\n }\n reconnection(v) {\n if (!arguments.length)\n return this._reconnection;\n this._r econnection = !!v;\n return this;\n }\n reconnectionAttempts(v) {\n if (v === undefined)\n return this._reconnectionAttempts;\n this._reconnectionAttempts = v;\n return this;\n }\n reconnec tionDelay(v) {\n var _a;\n if (v === undefined)\n retur n this._reconnectionDelay;\n this._reconnectionDelay = v;\n (_a = this.backoff) === null || _a === void 0 ? void 0 : _a.setMin(v);\n return this;\n }\n randomizationFactor(v) {\n var _a;\n if (v === undefined)\n return this._randomizationFactor;\n this._randomi zationFactor = v;\n (_a = this.backoff) === null || _a === void 0 ? void 0 : _a.setJitter(v);\n return this;\n }\n reconnectionDelayMax(v) { \n var _a;\n if (v === undefined)\n return this._reconn ectionDelayMax;\n this._reconnectionDelayMax = v;\n (_a = this.bac koff) === null || _a === void 0 ? void 0 : _a.setMax(v);\n return this;\n }\n timeout(v) {\n if (!arguments.length)\n return this ._timeout;\n this._timeout = v;\n return this;\n }\n /**\n * Starts trying to reconnect if reconnection is enabled and we have not\n * started reconnecting yet\n *\n * @private\n */\n maybeReconnec tOnOpen() {\n // Only try to reconnect if it's the first time we're conne cting\n if (!this._reconnecting &&\n this._reconnection &&\n this.backoff.attempts === 0) {\n // keeps reconnection from firing twice for the same reconnection loop\n this.reconnect();\n }\n }\n /**\n * Sets the current transport `socket`.\n *\n * @param {Function} fn - optional, callback\n * @return self\n * @publ ic\n */\n open(fn) {\n if (~this._readyState.indexOf(\"open\"))\n return this;\n this.engine = new Engine(this.uri, this.opts);\ n const socket = this.engine;\n const self = this;\n this._ readyState = \"opening\";\n this.skipReconnect = false;\n // emit `open`\n const openSubDestroy = on(socket, \"open\", function () {\n self.onopen();\n fn && fn();\n });\n // emit `er ror`\n const errorSub = on(socket, \"error\", (err) => {\n sel f.cleanup();\n self._readyState = \"closed\";\n this.emitR eserved(\"error\", err);\n if (fn) {\n fn(err);\n }\n else {\n // Only do this if there is no fn to handle the error\n self.maybeReconnectOnOpen();\n } \n });\n if (false !== this._timeout) {\n const timeout = this._timeout;\n if (timeout === 0) {\n openSubDest roy(); // prevents a race condition with the 'open' event\n }\n // set timer\n const timer = this.setTimeoutFn(() => {\n openSubDestroy();\n socket.close();\n // @ts-ignore\n socket.emit(\"error\", new Error(\"timeout\"));\n }, timeout);\n if (this.opts.autoUnref) {\n t imer.unref();\n }\n this.subs.push(function subDestroy() { \n clearTimeout(timer);\n });\n }\n this .subs.push(openSubDestroy);\n this.subs.push(errorSub);\n return t his;\n }\n /**\n * Alias for open()\n *\n * @return self\n * @public\n */\n connect(fn) {\n return this.open(fn);\n }\n /**\n * Called upon transport open.\n *\n * @private\n */\n onopen() {\n // clear old subs\n this.cleanup();\n // mark as open\n this._readyState = \"open\";\n this.emitReserved(\"open \");\n // add new subs\n const socket = this.engine;\n this .subs.push(on(socket, \"ping\", this.onping.bind(this)), on(socket, \"data\", th is.ondata.bind(this)), on(socket, \"error\", this.onerror.bind(this)), on(socket , \"close\", this.onclose.bind(this)), on(this.decoder, \"decoded\", this.ondeco ded.bind(this)));\n }\n /**\n * Called upon a ping.\n *\n * @p rivate\n */\n onping() {\n this.emitReserved(\"ping\");\n }\n /**\n * Called with data.\n *\n * @private\n */\n ondata(da ta) {\n this.decoder.add(data);\n }\n /**\n * Called when parse r fully decodes a packet.\n *\n * @private\n */\n ondecoded(packe t) {\n this.emitReserved(\"packet\", packet);\n }\n /**\n * Cal led upon socket error.\n *\n * @private\n */\n onerror(err) {\n this.emitReserved(\"error\", err);\n }\n /**\n * Creates a new s ocket for the given `nsp`.\n *\n * @return {Socket}\n * @public\n */\n socket(nsp, opts) {\n let socket = this.nsps[nsp];\n if (!socket) {\n socket = new Socket(this, nsp, opts);\n this .nsps[nsp] = socket;\n }\n return socket;\n }\n /**\n * Called upon a socket close.\n *\n * @param socket\n * @private\n */\n _destroy(socket) {\n const nsps = Object.keys(this.nsps);\n for (const nsp of nsps) {\n const socket = this.nsps[nsp];\n if (socket.active) {\n return;\n }\n }\n this._close();\n }\n /**\n * Writes a packet.\n *\n * @ param packet\n * @private\n */\n _packet(packet) {\n const enc odedPackets = this.encoder.encode(packet);\n for (let i = 0; i < encodedP ackets.length; i++) {\n this.engine.write(encodedPackets[i], packet.o ptions);\n }\n }\n /**\n * Clean up transport subscriptions and packet buffer.\n *\n * @private\n */\n cleanup() {\n this .subs.forEach((subDestroy) => subDestroy());\n this.subs.length = 0;\n this.decoder.destroy();\n }\n /**\n * Close the current socket.\n *\n * @private\n */\n _close() {\n this.skipReconnect = t rue;\n this._reconnecting = false;\n this.onclose(\"forced close\" );\n if (this.engine)\n this.engine.close();\n }\n /**\n * Alias for close()\n *\n * @private\n */\n disconnect() {\n return this._close();\n }\n /**\n * Called upon engine close.\ n *\n * @private\n */\n onclose(reason, description) {\n t his.cleanup();\n this.backoff.reset();\n this._readyState = \"clos ed\";\n this.emitReserved(\"close\", reason, description);\n if (t his._reconnection && !this.skipReconnect) {\n this.reconnect();\n }\n }\n /**\n * Attempt a reconnection.\n *\n * @private\n */\n reconnect() {\n if (this._reconnecting || this.skipReconnect )\n return this;\n const self = this;\n if (this.backof f.attempts >= this._reconnectionAttempts) {\n this.backoff.reset();\n this.emitReserved(\"reconnect_failed\");\n this._reconnec ting = false;\n }\n else {\n const delay = this.backoff .duration();\n this._reconnecting = true;\n const timer = this.setTimeoutFn(() => {\n if (self.skipReconnect)\n return;\n this.emitReserved(\"reconnect_attempt\", self.b ackoff.attempts);\n // check again for the case socket closed in above events\n if (self.skipReconnect)\n retur n;\n self.open((err) => {\n if (err) {\n self._reconnecting = false;\n self.reco nnect();\n this.emitReserved(\"reconnect_error\", err);\n }\n else {\n self. onreconnect();\n }\n });\n }, delay );\n if (this.opts.autoUnref) {\n timer.unref();\n }\n this.subs.push(function subDestroy() {\n c learTimeout(timer);\n });\n }\n }\n /**\n * Called u pon successful reconnect.\n *\n * @private\n */\n onreconnect() { \n const attempt = this.backoff.attempts;\n this._reconnecting = f alse;\n this.backoff.reset();\n this.emitReserved(\"reconnect\", a ttempt);\n }\n}\n","import { url } from \"./url.js\";\nimport { Manager } fro m \"./manager.js\";\nimport { Socket } from \"./socket.js\";\n/**\n * Managers c ache.\n */\nconst cache = {};\nfunction lookup(uri, opts) {\n if (typeof uri === \"object\") {\n opts = uri;\n uri = undefined;\n }\n opt s = opts || {};\n const parsed = url(uri, opts.path || \"/socket.io\");\n const source = parsed.source;\n const id = parsed.id;\n const path = parse d.path;\n const sameNamespace = cache[id] && path in cache[id][\"nsps\"];\n const newConnection = opts.forceNew ||\n opts[\"force new connection\"] ||\n false === opts.multiplex ||\n sameNamespace;\n let io;\n if (newConnection) {\n io = new Manager(source, opts);\n }\n els e {\n if (!cache[id]) {\n cache[id] = new Manager(source, opts );\n }\n io = cache[id];\n }\n if (parsed.query && !opts.que ry) {\n opts.query = parsed.queryKey;\n }\n return io.socket(parsed .path, opts);\n}\n// so that \"lookup\" can be used both as a function (e.g. `io (...)`) and as a\n// namespace (e.g. `io.connect(...)`), for backward compatibil ity\nObject.assign(lookup, {\n Manager,\n Socket,\n io: lookup,\n co nnect: lookup,\n});\n/**\n * Protocol version.\n *\n * @public\n */\nexport { pr otocol } from \"socket.io-parser\";\n/**\n * Expose constructors for standalone build.\n *\n * @public\n */\nexport { Manager, Socket, lookup as io, lookup as c onnect, lookup as default, };\n","import { parse } from \"engine.io-client\";\n/ **\n * URL parser.\n *\n * @param uri - url\n * @param path - the request path o f the connection\n * @param loc - An object meant to mimic window.location.\n * Defaults to window.location.\n * @public\n */\nexport function url(uri, p ath = \"\", loc) {\n let obj = uri;\n // default to window.location\n l oc = loc || (typeof location !== \"undefined\" && location);\n if (null == ur i)\n uri = loc.protocol + \"//\" + loc.host;\n // relative path suppor t\n if (typeof uri === \"string\") {\n if (\"/\" === uri.charAt(0)) {\ n if (\"/\" === uri.charAt(1)) {\n uri = loc.protocol + uri;\n }\n else {\n uri = loc.host + uri; \n }\n }\n if (!/^(https?|wss?):\\/\\//.test(uri)) {\n if (\"undefined\" !== typeof loc) {\n uri = loc.protoc ol + \"//\" + uri;\n }\n else {\n uri = \"h ttps://\" + uri;\n }\n }\n // parse\n obj = pars e(uri);\n }\n // make sure we treat `localhost:80` and `localhost` equally \n if (!obj.port) {\n if (/^(http|ws)$/.test(obj.protocol)) {\n obj.port = \"80\";\n }\n else if (/^(http|ws)s$/.test(obj.pro tocol)) {\n obj.port = \"443\";\n }\n }\n obj.path = obj .path || \"/\";\n const ipv6 = obj.host.indexOf(\":\") !== -1;\n const hos t = ipv6 ? \"[\" + obj.host + \"]\" : obj.host;\n // define unique id\n ob j.id = obj.protocol + \"://\" + host + \":\" + obj.port + path;\n // define h ref\n obj.href =\n obj.protocol +\n \"://\" +\n host +\n (loc && loc.port === obj.port ? \"\" : \":\" + obj.port);\n return obj;\n}\n"],"names":["PACKET_TYPES","Object","create","PACKET_TYPES_RE VERSE","keys","forEach","key","ERROR_PACKET","type","data","withNativeBlob","Blo b","prototype","toString","call","withNativeArrayBuffer","ArrayBuffer","encodePa cket","supportsBinary","callback","encodeBlobAsBase64","obj","isView","buffer"," fileReader","FileReader","onload","content","result","split","readAsDataURL","ch ars","lookup","Uint8Array","i","length","charCodeAt","decodePacket","encodedPack et","binaryType","mapBinary","charAt","decodeBase64Packet","substring","decoded" ,"base64","encoded1","encoded2","encoded3","encoded4","bufferLength","len","p"," arraybuffer","bytes","decode","SEPARATOR","String","fromCharCode","Emitter","mix in","on","addEventListener","event","fn","this","_callbacks","push","once","off" ,"apply","arguments","removeListener","removeAllListeners","removeEventListener" ,"cb","callbacks","splice","emit","args","Array","slice","emitReserved","listene rs","hasListeners","self","window","Function","pick","attr","reduce","acc","k"," hasOwnProperty","NATIVE_SET_TIMEOUT","setTimeout","NATIVE_CLEAR_TIMEOUT","clearT imeout","installTimerFunctions","opts","useNativeTimers","setTimeoutFn","bind"," globalThis","clearTimeoutFn","TransportError","Error","constructor","reason","de scription","context","super","Transport","writable","query","readyState","socket ","onError","open","doOpen","close","doClose","onClose","send","packets","write" ,"onOpen","onData","packet","onPacket","details","alphabet","map","prev","seed", "encode","num","encoded","Math","floor","yeast","now","Date","str","encodeURICom ponent","value","XMLHttpRequest","err","hasCORS","xdomain","e","concat","join"," empty","hasXHR2","responseType","Request","uri","method","async","undefined","xd ","xscheme","xs","xhr","extraHeaders","setDisableHeaderCheck","setRequestHeader" ,"withCredentials","requestTimeout","timeout","onreadystatechange","status","onL oad","document","index","requestsCount","requests","cleanup","fromError","abort" ,"responseText","attachEvent","unloadHandler","nextTick","Promise","resolve","th en","WebSocket","MozWebSocket","isReactNative","navigator","product","toLowerCas e","WS","forceBase64","name","check","protocols","headers","ws","addEventListene rs","onopen","autoUnref","_socket","unref","onclose","closeEvent","onmessage","e v","onerror","lastPacket","schema","secure","port","Number","timestampRequests", "timestampParam","b64","encodedQuery","hostname","indexOf","path","transports"," websocket","polling","location","isSSL","protocol","poll","pause","onPause","tot al","doPoll","encodedPayload","encodedPackets","decodedPacket","decodePayload"," count","encodePayload","doWrite","sid","request","assign","req","xhrStatus","pol lXhr","re","parts","parse","src","b","replace","m","exec","source","host","autho rity","ipv6uri","pathNames","regx","names","substr","queryKey","$0","$1","$2","S ocket","writeBuffer","prevBufferLen","agent","upgrade","rememberUpgrade","reject Unauthorized","perMessageDeflate","threshold","transportOptions","closeOnBeforeu nload","qs","qry","pairs","l","pair","decodeURIComponent","id","upgrades","pingI nterval","pingTimeout","pingTimeoutTimer","transport","offlineEventListener","cr eateTransport","EIO","priorWebsocketSuccess","shift","setTransport","onDrain","p robe","failed","onTransportOpen","msg","upgrading","flush","freezeTransport","er ror","onTransportClose","onupgrade","to","onHandshake","JSON","resetPingTimeout" ,"sendPacket","code","filterUpgrades","maxPayload","getWritablePackets","payload Size","c","utf8Length","ceil","byteLength","size","options","compress","cleanupA ndClose","waitForUpgrade","filteredUpgrades","j","withNativeFile","File","isBina ry","hasBinary","toJSON","isArray","deconstructPacket","buffers","packetData","p ack","_deconstructPacket","attachments","placeholder","_placeholder","newData"," reconstructPacket","_reconstructPacket","PacketType","Decoder","reviver","add"," decodeString","BINARY_EVENT","BINARY_ACK","reconstructor","BinaryReconstructor", "takeBinaryData","start","buf","nsp","next","payload","tryParse","isPayloadValid ","static","CONNECT","DISCONNECT","CONNECT_ERROR","EVENT","ACK","destroy","finis hedReconstruction","reconPack","binData","replacer","encodeAsString","encodeAsBi nary","stringify","deconstruction","unshift","RESERVED_EVENTS","freeze","connect ","connect_error","disconnect","disconnecting","newListener","io","connected","r eceiveBuffer","sendBuffer","ids","acks","flags","auth","_autoConnect","disconnec ted","subEvents","subs","onpacket","active","_readyState","ack","pop","_register AckCallback","isTransportWritable","engine","volatile","notifyOutgoingListeners" ,"timer","_packet","onconnect","onevent","onack","ondisconnect","message","emitE vent","_anyListeners","listener","sent","emitBuffered","subDestroy","onAny","pre pendAny","offAny","listenersAny","onAnyOutgoing","_anyOutgoingListeners","prepen dAnyOutgoing","offAnyOutgoing","listenersAnyOutgoing","Backoff","ms","min","max" ,"factor","jitter","attempts","duration","pow","rand","random","deviation","rese t","setMin","setMax","setJitter","Manager","_a","nsps","reconnection","reconnect ionAttempts","Infinity","reconnectionDelay","reconnectionDelayMax","randomizatio nFactor","backoff","_parser","parser","encoder","Encoder","decoder","autoConnect ","v","_reconnection","_reconnectionAttempts","_reconnectionDelay","_randomizati onFactor","_reconnectionDelayMax","_timeout","maybeReconnectOnOpen","_reconnecti ng","reconnect","Engine","skipReconnect","openSubDestroy","errorSub","onping","o ndata","ondecoded","_destroy","_close","delay","onreconnect","attempt","cache"," parsed","loc","test","href","url","sameNamespace","forceNew","multiplex"],"mappi ngs":";;;;;AAAA,MAAMA,EAAeC,OAAOC,OAAO,MACnCF,EAAmB,KAAI,IACvBA,EAAoB,MAAI,IACxB A,EAAmB,KAAI,IACvBA,EAAmB,KAAI,IACvBA,EAAsB,QAAI,IAC1BA,EAAsB,QAAI,IAC1BA,EAAmB, KAAI,IACvB,MAAMG,EAAuBF,OAAOC,OAAO,MAC3CD,OAAOG,KAAKJ,GAAcK,SAAQC,IAC9BH,E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,CAAI3U,GADnB1D,EAAOA,GAAQ,IACc2H,MAAQ,cAC/BiC,EAASqO,EAAOrO,OAChB6B,EAAKw M,EAAOxM,GACZ9D,EAAOsQ,EAAOtQ,KACd2Q,EAAgBN,GAAMvM,IAAO9D,KAAQqQ,GAAMvM,GAAU,KAK 3D,IAAIqG,EAaJ,OAjBsB9R,EAAKuY,UACvBvY,EAAK,0BACL,IAAUA,EAAKwY,WACfF,EAGAxG,EAAK ,IAAI4D,GAAQ9L,EAAQ5J,IAGpBgY,GAAMvM,KACPuM,GAAMvM,GAAM,IAAIiK,GAAQ9L,EAAQ5J,IAE pC8R,EAAKkG,GAAMvM,IAEXwM,EAAOlX,QAAUf,EAAKe,QACtBf,EAAKe,MAAQkX,EAAO7N,UAEjB0H, EAAG7Q,OAAOgX,EAAOtQ,KAAM3H,GAIlClG,OAAOkP,OAAOnN,GAAQ,CAClB6Z,QAAAA,GACAlL,OAAA A,GACAsH,GAAIjW,GACJ4V,QAAS5V"} {"version":3,"file":"socket.io.esm.min.js","sources":["../node_modules/engine.io -parser/build/esm/commons.js","../node_modules/engine.io-parser/build/esm/encode Packet.browser.js","../node_modules/engine.io-parser/build/esm/contrib/base64-ar raybuffer.js","../node_modules/engine.io-parser/build/esm/decodePacket.browser.j s","../node_modules/engine.io-parser/build/esm/index.js","../node_modules/@socke t.io/component-emitter/index.mjs","../node_modules/engine.io-client/build/esm/gl obalThis.browser.js","../node_modules/engine.io-client/build/esm/util.js","../no de_modules/engine.io-client/build/esm/transport.js","../node_modules/engine.io-c lient/build/esm/contrib/yeast.js","../node_modules/engine.io-client/build/esm/co ntrib/parseqs.js","../node_modules/engine.io-client/build/esm/contrib/has-cors.j s","../node_modules/engine.io-client/build/esm/transports/xmlhttprequest.browser .js","../node_modules/engine.io-client/build/esm/transports/polling.js","../node _modules/engine.io-client/build/esm/transports/websocket-constructor.browser.js" ,"../node_modules/engine.io-client/build/esm/transports/websocket.js","../node_m odules/engine.io-client/build/esm/transports/index.js","../node_modules/engine.i o-client/build/esm/contrib/parseuri.js","../node_modules/engine.io-client/build/ esm/socket.js","../node_modules/socket.io-parser/build/esm/is-binary.js","../nod e_modules/socket.io-parser/build/esm/binary.js","../node_modules/socket.io-parse r/build/esm/index.js","../build/esm/on.js","../build/esm/socket.js","../build/es m/contrib/backo2.js","../build/esm/manager.js","../build/esm/index.js","../build /esm/url.js"],"sourcesContent":["const PACKET_TYPES = Object.create(null); // no Map = no polyfill\nPACKET_TYPES[\"open\"] = \"0\";\nPACKET_TYPES[\"close\"] = \ "1\";\nPACKET_TYPES[\"ping\"] = \"2\";\nPACKET_TYPES[\"pong\"] = \"3\";\nPACKET_ TYPES[\"message\"] = \"4\";\nPACKET_TYPES[\"upgrade\"] = \"5\";\nPACKET_TYPES[\" noop\"] = \"6\";\nconst PACKET_TYPES_REVERSE = Object.create(null);\nObject.keys (PACKET_TYPES).forEach(key => {\n PACKET_TYPES_REVERSE[PACKET_TYPES[key]] = k ey;\n});\nconst ERROR_PACKET = { type: \"error\", data: \"parser error\" };\nexp ort { PACKET_TYPES, PACKET_TYPES_REVERSE, ERROR_PACKET };\n","import { PACKET_TY PES } from \"./commons.js\";\nconst withNativeBlob = typeof Blob === \"function\ " ||\n (typeof Blob !== \"undefined\" &&\n Object.prototype.toString.c all(Blob) === \"[object BlobConstructor]\");\nconst withNativeArrayBuffer = type of ArrayBuffer === \"function\";\n// ArrayBuffer.isView method is not defined in IE10\nconst isView = obj => {\n return typeof ArrayBuffer.isView === \"funct ion\"\n ? ArrayBuffer.isView(obj)\n : obj && obj.buffer instanceof ArrayBuffer;\n};\nconst encodePacket = ({ type, data }, supportsBinary, callbac k) => {\n if (withNativeBlob && data instanceof Blob) {\n if (supports Binary) {\n return callback(data);\n }\n else {\n return encodeBlobAsBase64(data, callback);\n }\n }\n else if (withNativeArrayBuffer &&\n (data instanceof ArrayBuffer || isView(data)) ) {\n if (supportsBinary) {\n return callback(data);\n }\n else {\n return encodeBlobAsBase64(new Blob([data]), callb ack);\n }\n }\n // plain string\n return callback(PACKET_TYPES[t ype] + (data || \"\"));\n};\nconst encodeBlobAsBase64 = (data, callback) => {\n const fileReader = new FileReader();\n fileReader.onload = function () {\n const content = fileReader.result.split(\",\")[1];\n callback(\"b \" + content);\n };\n return fileReader.readAsDataURL(data);\n};\nexport d efault encodePacket;\n","const chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmn opqrstuvwxyz0123456789+/';\n// Use a lookup table to find the index.\nconst look up = typeof Uint8Array === 'undefined' ? [] : new Uint8Array(256);\nfor (let i = 0; i < chars.length; i++) {\n lookup[chars.charCodeAt(i)] = i;\n}\nexport co nst encode = (arraybuffer) => {\n let bytes = new Uint8Array(arraybuffer), i, len = bytes.length, base64 = '';\n for (i = 0; i < len; i += 3) {\n b ase64 += chars[bytes[i] >> 2];\n base64 += chars[((bytes[i] & 3) << 4) | (bytes[i + 1] >> 4)];\n base64 += chars[((bytes[i + 1] & 15) << 2) | (byt es[i + 2] >> 6)];\n base64 += chars[bytes[i + 2] & 63];\n }\n if (l en % 3 === 2) {\n base64 = base64.substring(0, base64.length - 1) + '=';\ n }\n else if (len % 3 === 1) {\n base64 = base64.substring(0, base 64.length - 2) + '==';\n }\n return base64;\n};\nexport const decode = (ba se64) => {\n let bufferLength = base64.length * 0.75, len = base64.length, i, p = 0, encoded1, encoded2, encoded3, encoded4;\n if (base64[base64.length - 1] === '=') {\n bufferLength--;\n if (base64[base64.length - 2] == = '=') {\n bufferLength--;\n }\n }\n const arraybuffer = new ArrayBuffer(bufferLength), bytes = new Uint8Array(arraybuffer);\n for (i = 0; i < len; i += 4) {\n encoded1 = lookup[base64.charCodeAt(i)];\n encoded2 = lookup[base64.charCodeAt(i + 1)];\n encoded3 = lookup[base 64.charCodeAt(i + 2)];\n encoded4 = lookup[base64.charCodeAt(i + 3)];\n bytes[p++] = (encoded1 << 2) | (encoded2 >> 4);\n bytes[p++] = ((en coded2 & 15) << 4) | (encoded3 >> 2);\n bytes[p++] = ((encoded3 & 3) << 6 ) | (encoded4 & 63);\n }\n return arraybuffer;\n};\n","import { ERROR_PACK ET, PACKET_TYPES_REVERSE } from \"./commons.js\";\nimport { decode } from \"./co ntrib/base64-arraybuffer.js\";\nconst withNativeArrayBuffer = typeof ArrayBuffer === \"function\";\nconst decodePacket = (encodedPacket, binaryType) => {\n i f (typeof encodedPacket !== \"string\") {\n return {\n type: \ "message\",\n data: mapBinary(encodedPacket, binaryType)\n };\ n }\n const type = encodedPacket.charAt(0);\n if (type === \"b\") {\n return {\n type: \"message\",\n data: decodeBase64Pa cket(encodedPacket.substring(1), binaryType)\n };\n }\n const packe tType = PACKET_TYPES_REVERSE[type];\n if (!packetType) {\n return ERRO R_PACKET;\n }\n return encodedPacket.length > 1\n ? {\n type: PACKET_TYPES_REVERSE[type],\n data: encodedPacket.substring(1)\ n }\n : {\n type: PACKET_TYPES_REVERSE[type]\n } ;\n};\nconst decodeBase64Packet = (data, binaryType) => {\n if (withNativeArr ayBuffer) {\n const decoded = decode(data);\n return mapBinary(dec oded, binaryType);\n }\n else {\n return { base64: true, data }; // fallback for old browsers\n }\n};\nconst mapBinary = (data, binaryType) => { \n switch (binaryType) {\n case \"blob\":\n return data ins tanceof ArrayBuffer ? new Blob([data]) : data;\n case \"arraybuffer\":\n default:\n return data; // assuming the data is already an Arr ayBuffer\n }\n};\nexport default decodePacket;\n","import encodePacket from \ "./encodePacket.js\";\nimport decodePacket from \"./decodePacket.js\";\nconst SE PARATOR = String.fromCharCode(30); // see https://en.wikipedia.org/wiki/Delimite r#ASCII_delimited_text\nconst encodePayload = (packets, callback) => {\n // s ome packets may be added to the array while encoding, so the initial length must be saved\n const length = packets.length;\n const encodedPackets = new Ar ray(length);\n let count = 0;\n packets.forEach((packet, i) => {\n // force base64 encoding for binary packets\n encodePacket(packet, false, encodedPacket => {\n encodedPackets[i] = encodedPacket;\n if (++count === length) {\n callback(encodedPackets.join(SEPARAT OR));\n }\n });\n });\n};\nconst decodePayload = (encodedPa yload, binaryType) => {\n const encodedPackets = encodedPayload.split(SEPARAT OR);\n const packets = [];\n for (let i = 0; i < encodedPackets.length; i+ +) {\n const decodedPacket = decodePacket(encodedPackets[i], binaryType); \n packets.push(decodedPacket);\n if (decodedPacket.type === \"err or\") {\n break;\n }\n }\n return packets;\n};\nexport c onst protocol = 4;\nexport { encodePacket, encodePayload, decodePacket, decodePa yload };\n","/**\n * Initialize a new `Emitter`.\n *\n * @api public\n */\n\nexp ort function Emitter(obj) {\n if (obj) return mixin(obj);\n}\n\n/**\n * Mixin t he emitter properties.\n *\n * @param {Object} obj\n * @return {Object}\n * @api private\n */\n\nfunction mixin(obj) {\n for (var key in Emitter.prototype) {\n obj[key] = Emitter.prototype[key];\n }\n return obj;\n}\n\n/**\n * Listen on the given `event` with `fn`.\n *\n * @param {String} event\n * @param {Functi on} fn\n * @return {Emitter}\n * @api public\n */\n\nEmitter.prototype.on =\nEmi tter.prototype.addEventListener = function(event, fn){\n this._callbacks = this ._callbacks || {};\n (this._callbacks['$' + event] = this._callbacks['$' + even t] || [])\n .push(fn);\n return this;\n};\n\n/**\n * Adds an `event` listene r that will be invoked a single\n * time then automatically removed.\n *\n * @pa ram {String} event\n * @param {Function} fn\n * @return {Emitter}\n * @api publi c\n */\n\nEmitter.prototype.once = function(event, fn){\n function on() {\n this.off(event, on);\n fn.apply(this, arguments);\n }\n\n on.fn = fn;\n th is.on(event, on);\n return this;\n};\n\n/**\n * Remove the given callback for ` event` or all\n * registered callbacks.\n *\n * @param {String} event\n * @param {Function} fn\n * @return {Emitter}\n * @api public\n */\n\nEmitter.prototype.o ff =\nEmitter.prototype.removeListener =\nEmitter.prototype.removeAllListeners = \nEmitter.prototype.removeEventListener = function(event, fn){\n this._callback s = this._callbacks || {};\n\n // all\n if (0 == arguments.length) {\n this ._callbacks = {};\n return this;\n }\n\n // specific event\n var callbacks = this._callbacks['$' + event];\n if (!callbacks) return this;\n\n // remove all handlers\n if (1 == arguments.length) {\n delete this._callbacks['$' + e vent];\n return this;\n }\n\n // remove specific handler\n var cb;\n for (var i = 0; i < callbacks.length; i++) {\n cb = callbacks[i];\n if (cb === fn || cb.fn === fn) {\n callbacks.splice(i, 1);\n break;\n }\n }\ n\n // Remove event specific arrays for event types that no\n // one is subscr ibed for to avoid memory leak.\n if (callbacks.length === 0) {\n delete this ._callbacks['$' + event];\n }\n\n return this;\n};\n\n/**\n * Emit `event` wit h the given args.\n *\n * @param {String} event\n * @param {Mixed} ...\n * @retu rn {Emitter}\n */\n\nEmitter.prototype.emit = function(event){\n this._callback s = this._callbacks || {};\n\n var args = new Array(arguments.length - 1)\n , callbacks = this._callbacks['$' + event];\n\n for (var i = 1; i < arguments.l ength; i++) {\n args[i - 1] = arguments[i];\n }\n\n if (callbacks) {\n c allbacks = callbacks.slice(0);\n for (var i = 0, len = callbacks.length; i < len; ++i) {\n callbacks[i].apply(this, args);\n }\n }\n\n return this; \n};\n\n// alias used for reserved events (protected method)\nEmitter.prototype. emitReserved = Emitter.prototype.emit;\n\n/**\n * Return array of callbacks for `event`.\n *\n * @param {String} event\n * @return {Array}\n * @api public\n */\ n\nEmitter.prototype.listeners = function(event){\n this._callbacks = this._cal lbacks || {};\n return this._callbacks['$' + event] || [];\n};\n\n/**\n * Check if this emitter has `event` handlers.\n *\n * @param {String} event\n * @return {Boolean}\n * @api public\n */\n\nEmitter.prototype.hasListeners = function(eve nt){\n return !! this.listeners(event).length;\n};\n","export const globalThisS him = (() => {\n if (typeof self !== \"undefined\") {\n return self;\n }\n else if (typeof window !== \"undefined\") {\n return window;\n }\n else {\n return Function(\"return this\")();\n }\n})();\n", "import { globalThisShim as globalThis } from \"./globalThis.js\";\nexport funct ion pick(obj, ...attr) {\n return attr.reduce((acc, k) => {\n if (obj. hasOwnProperty(k)) {\n acc[k] = obj[k];\n }\n return ac c;\n }, {});\n}\n// Keep a reference to the real timeout functions so they ca n be used when overridden\nconst NATIVE_SET_TIMEOUT = setTimeout;\nconst NATIVE_ CLEAR_TIMEOUT = clearTimeout;\nexport function installTimerFunctions(obj, opts) {\n if (opts.useNativeTimers) {\n obj.setTimeoutFn = NATIVE_SET_TIMEOU T.bind(globalThis);\n obj.clearTimeoutFn = NATIVE_CLEAR_TIMEOUT.bind(glob alThis);\n }\n else {\n obj.setTimeoutFn = setTimeout.bind(globalTh is);\n obj.clearTimeoutFn = clearTimeout.bind(globalThis);\n }\n}\n// base64 encoded buffers are about 33% bigger (https://en.wikipedia.org/wiki/Base6 4)\nconst BASE64_OVERHEAD = 1.33;\n// we could also have used `new Blob([obj]).s ize`, but it isn't supported in IE9\nexport function byteLength(obj) {\n if ( typeof obj === \"string\") {\n return utf8Length(obj);\n }\n // arr aybuffer or blob\n return Math.ceil((obj.byteLength || obj.size) * BASE64_OVE RHEAD);\n}\nfunction utf8Length(str) {\n let c = 0, length = 0;\n for (let i = 0, l = str.length; i < l; i++) {\n c = str.charCodeAt(i);\n i f (c < 0x80) {\n length += 1;\n }\n else if (c < 0x800) {\n length += 2;\n }\n else if (c < 0xd800 || c >= 0xe 000) {\n length += 3;\n }\n else {\n i++;\n length += 4;\n }\n }\n return length;\n}\n","import { de codePacket } from \"engine.io-parser\";\nimport { Emitter } from \"@socket.io/co mponent-emitter\";\nimport { installTimerFunctions } from \"./util.js\";\nclass TransportError extends Error {\n constructor(reason, description, context) {\ n super(reason);\n this.description = description;\n this.c ontext = context;\n this.type = \"TransportError\";\n }\n}\nexport cla ss Transport extends Emitter {\n /**\n * Transport abstract constructor.\ n *\n * @param {Object} options.\n * @api private\n */\n cons tructor(opts) {\n super();\n this.writable = false;\n insta llTimerFunctions(this, opts);\n this.opts = opts;\n this.query = o pts.query;\n this.readyState = \"\";\n this.socket = opts.socket;\ n }\n /**\n * Emits an error.\n *\n * @param {String} reason\n * @param description\n * @param context - the error context\n * @re turn {Transport} for chaining\n * @api protected\n */\n onError(reaso n, description, context) {\n super.emitReserved(\"error\", new TransportE rror(reason, description, context));\n return this;\n }\n /**\n * Opens the transport.\n *\n * @api public\n */\n open() {\n if (\"closed\" === this.readyState || \"\" === this.readyState) {\n this.readyState = \"opening\";\n this.doOpen();\n }\n return this;\n }\n /**\n * Closes the transport.\n *\n * @ap i public\n */\n close() {\n if (\"opening\" === this.readyState || \"open\" === this.readyState) {\n this.doClose();\n this. onClose();\n }\n return this;\n }\n /**\n * Sends multip le packets.\n *\n * @param {Array} packets\n * @api public\n */\ n send(packets) {\n if (\"open\" === this.readyState) {\n t his.write(packets);\n }\n else {\n // this might happen if the transport was silently closed in the beforeunload event handler\n }\n }\n /**\n * Called upon open\n *\n * @api protected\n */\n onOpen() {\n this.readyState = \"open\";\n this.writable = true;\n super.emitReserved(\"open\");\n }\n /**\n * Called wi th data.\n *\n * @param {String} data\n * @api protected\n */\n onData(data) {\n const packet = decodePacket(data, this.socket.binaryT ype);\n this.onPacket(packet);\n }\n /**\n * Called with a deco ded packet.\n *\n * @api protected\n */\n onPacket(packet) {\n super.emitReserved(\"packet\", packet);\n }\n /**\n * Called upon close.\n *\n * @api protected\n */\n onClose(details) {\n this.readyState = \"closed\";\n super.emitReserved(\"close\", details);\ n }\n}\n","// imported from https://github.com/unshiftio/yeast\n'use strict'; \nconst alphabet = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwx yz-_'.split(''), length = 64, map = {};\nlet seed = 0, i = 0, prev;\n/**\n * Ret urn a string representing the specified number.\n *\n * @param {Number} num The number to convert.\n * @returns {String} The string representation of the number .\n * @api public\n */\nexport function encode(num) {\n let encoded = '';\n do {\n encoded = alphabet[num % length] + encoded;\n num = Math. floor(num / length);\n } while (num > 0);\n return encoded;\n}\n/**\n * Re turn the integer value specified by the given string.\n *\n * @param {String} st r The string to convert.\n * @returns {Number} The integer value represented by the string.\n * @api public\n */\nexport function decode(str) {\n let decoded = 0;\n for (i = 0; i < str.length; i++) {\n decoded = decoded * lengt h + map[str.charAt(i)];\n }\n return decoded;\n}\n/**\n * Yeast: A tiny gr owing id generator.\n *\n * @returns {String} A unique id.\n * @api public\n */\ nexport function yeast() {\n const now = encode(+new Date());\n if (now != = prev)\n return seed = 0, prev = now;\n return now + '.' + encode(see d++);\n}\n//\n// Map each character to its index.\n//\nfor (; i < length; i++)\n map[alphabet[i]] = i;\n","// imported from https://github.com/galkn/querystr ing\n/**\n * Compiles a querystring\n * Returns string representation of the obj ect\n *\n * @param {Object}\n * @api private\n */\nexport function encode(obj) { \n let str = '';\n for (let i in obj) {\n if (obj.hasOwnProperty(i) ) {\n if (str.length)\n str += '&';\n str + = encodeURIComponent(i) + '=' + encodeURIComponent(obj[i]);\n }\n }\n return str;\n}\n/**\n * Parses a simple querystring into an object\n *\n * @p aram {String} qs\n * @api private\n */\nexport function decode(qs) {\n let qr y = {};\n let pairs = qs.split('&');\n for (let i = 0, l = pairs.length; i < l; i++) {\n let pair = pairs[i].split('=');\n qry[decodeURIComp onent(pair[0])] = decodeURIComponent(pair[1]);\n }\n return qry;\n}\n","// imported from https://github.com/component/has-cors\nlet value = false;\ntry {\ n value = typeof XMLHttpRequest !== 'undefined' &&\n 'withCredentials' in new XMLHttpRequest();\n}\ncatch (err) {\n // if XMLHttp support is disabl ed in IE then it will throw\n // when trying to create\n}\nexport const hasCO RS = value;\n","// browser shim for xmlhttprequest module\nimport { hasCORS } fr om \"../contrib/has-cors.js\";\nimport { globalThisShim as globalThis } from \". ./globalThis.js\";\nexport function XHR(opts) {\n const xdomain = opts.xdomai n;\n // XMLHttpRequest can be disabled on IE\n try {\n if (\"undefi ned\" !== typeof XMLHttpRequest && (!xdomain || hasCORS)) {\n return new XMLHttpRequest();\n }\n }\n catch (e) { }\n if (!xdomain) {\ n try {\n return new globalThis[[\"Active\"].concat(\"Object\" ).join(\"X\")](\"Microsoft.XMLHTTP\");\n }\n catch (e) { }\n }\ n}\n","import { Transport } from \"../transport.js\";\nimport { yeast } from \". ./contrib/yeast.js\";\nimport { encode } from \"../contrib/parseqs.js\";\nimport { encodePayload, decodePayload } from \"engine.io-parser\";\nimport { XHR as XM LHttpRequest } from \"./xmlhttprequest.js\";\nimport { Emitter } from \"@socket. io/component-emitter\";\nimport { installTimerFunctions, pick } from \"../util.j s\";\nimport { globalThisShim as globalThis } from \"../globalThis.js\";\nfuncti on empty() { }\nconst hasXHR2 = (function () {\n const xhr = new XMLHttpReque st({\n xdomain: false\n });\n return null != xhr.responseType;\n})( );\nexport class Polling extends Transport {\n /**\n * XHR Polling constr uctor.\n *\n * @param {Object} opts\n * @api public\n */\n co nstructor(opts) {\n super(opts);\n this.polling = false;\n if (typeof location !== \"undefined\") {\n const isSSL = \"https:\" = == location.protocol;\n let port = location.port;\n // som e user agents have empty `location.port`\n if (!port) {\n port = isSSL ? \"443\" : \"80\";\n }\n this.xd =\n (typeof location !== \"undefined\" &&\n opts.host name !== location.hostname) ||\n port !== opts.port;\n this.xs = opts.secure !== isSSL;\n }\n /**\n * XHR su pports binary\n */\n const forceBase64 = opts && opts.forceBase64 ;\n this.supportsBinary = hasXHR2 && !forceBase64;\n }\n /**\n * Transport name.\n */\n get name() {\n return \"polling\";\n } \n /**\n * Opens the socket (triggers polling). We write a PING message t o determine\n * when the transport is open.\n *\n * @api private\n */\n doOpen() {\n this.poll();\n }\n /**\n * Pauses polli ng.\n *\n * @param {Function} callback upon buffers are flushed and tran sport is paused\n * @api private\n */\n pause(onPause) {\n thi s.readyState = \"pausing\";\n const pause = () => {\n this.rea dyState = \"paused\";\n onPause();\n };\n if (this.poll ing || !this.writable) {\n let total = 0;\n if (this.polli ng) {\n total++;\n this.once(\"pollComplete\", fun ction () {\n --total || pause();\n });\n }\n if (!this.writable) {\n total++;\n this.once(\"drain\", function () {\n --total || pause() ;\n });\n }\n }\n else {\n pa use();\n }\n }\n /**\n * Starts polling cycle.\n *\n * @api public\n */\n poll() {\n this.polling = true;\n this.d oPoll();\n this.emitReserved(\"poll\");\n }\n /**\n * Overloads onData to detect payloads.\n *\n * @api private\n */\n onData(da ta) {\n const callback = packet => {\n // if its the first mes sage we consider the transport open\n if (\"opening\" === this.readyS tate && packet.type === \"open\") {\n this.onOpen();\n }\n // if its a close packet, we close the ongoing requests\n if (\"close\" === packet.type) {\n this.onClose({ descriptio n: \"transport closed by the server\" });\n return false;\n }\n // otherwise bypass onData and handle the message\n this.onPacket(packet);\n };\n // decode payload\n decod ePayload(data, this.socket.binaryType).forEach(callback);\n // if an even t did not trigger closing\n if (\"closed\" !== this.readyState) {\n // if we got data we're not polling\n this.polling = false;\n this.emitReserved(\"pollComplete\");\n if (\"open\" === thi s.readyState) {\n this.poll();\n }\n else { \n }\n }\n }\n /**\n * For polling, send a close pac ket.\n *\n * @api private\n */\n doClose() {\n const close = () => {\n this.write([{ type: \"close\" }]);\n };\n if (\"open\" === this.readyState) {\n close();\n }\n el se {\n // in case we're trying to close while\n // handsha king is in progress (GH-164)\n this.once(\"open\", close);\n } \n }\n /**\n * Writes a packets payload.\n *\n * @param {Array } data packets\n * @param {Function} drain callback\n * @api private\n */\n write(packets) {\n this.writable = false;\n encodePaylo ad(packets, data => {\n this.doWrite(data, () => {\n t his.writable = true;\n this.emitReserved(\"drain\");\n });\n });\n }\n /**\n * Generates uri for connection.\n *\ n * @api private\n */\n uri() {\n let query = this.query || {} ;\n const schema = this.opts.secure ? \"https\" : \"http\";\n let port = \"\";\n // cache busting is forced\n if (false !== this.opt s.timestampRequests) {\n query[this.opts.timestampParam] = yeast();\n }\n if (!this.supportsBinary && !query.sid) {\n query. b64 = 1;\n }\n // avoid port if default for schema\n if (th is.opts.port &&\n ((\"https\" === schema && Number(this.opts.port) != = 443) ||\n (\"http\" === schema && Number(this.opts.port) !== 80 ))) {\n port = \":\" + this.opts.port;\n }\n const enco dedQuery = encode(query);\n const ipv6 = this.opts.hostname.indexOf(\":\" ) !== -1;\n return (schema +\n \"://\" +\n (ipv6 ? \"[\" + this.opts.hostname + \"]\" : this.opts.hostname) +\n port +\n this.opts.path +\n (encodedQuery.length ? \"?\" + encoded Query : \"\"));\n }\n /**\n * Creates a request.\n *\n * @para m {String} method\n * @api private\n */\n request(opts = {}) {\n Object.assign(opts, { xd: this.xd, xs: this.xs }, this.opts);\n return new Request(this.uri(), opts);\n }\n /**\n * Sends data.\n *\n * @param {String} data to send.\n * @param {Function} called upon flush.\n * @api private\n */\n doWrite(data, fn) {\n const req = this. request({\n method: \"POST\",\n data: data\n });\n req.on(\"success\", fn);\n req.on(\"error\", (xhrStatus, context) => {\n this.onError(\"xhr post error\", xhrStatus, context);\n });\n }\n /**\n * Starts a poll cycle.\n *\n * @api private\n */\n doPoll() {\n const req = this.request();\n req.on(\"d ata\", this.onData.bind(this));\n req.on(\"error\", (xhrStatus, context) => {\n this.onError(\"xhr poll error\", xhrStatus, context);\n });\n this.pollXhr = req;\n }\n}\nexport class Request extends Emitte r {\n /**\n * Request constructor\n *\n * @param {Object} options \n * @api public\n */\n constructor(uri, opts) {\n super();\n installTimerFunctions(this, opts);\n this.opts = opts;\n th is.method = opts.method || \"GET\";\n this.uri = uri;\n this.async = false !== opts.async;\n this.data = undefined !== opts.data ? opts.dat a : null;\n this.create();\n }\n /**\n * Creates the XHR object and sends the request.\n *\n * @api private\n */\n create() {\n const opts = pick(this.opts, \"agent\", \"pfx\", \"key\", \"passphrase\", \"cert\", \"ca\", \"ciphers\", \"rejectUnauthorized\", \"autoUnref\");\n opts.xdomain = !!this.opts.xd;\n opts.xscheme = !!this.opts.xs;\n const xhr = (this.xhr = new XMLHttpRequest(opts));\n try {\n xhr.open(this.method, this.uri, this.async);\n try {\n if (this.opts.extraHeaders) {\n xhr.setDisableHeaderCheck && xhr.setDisableHeaderCheck(true);\n for (let i in this.opts.e xtraHeaders) {\n if (this.opts.extraHeaders.hasOwnPropert y(i)) {\n xhr.setRequestHeader(i, this.opts.extraHead ers[i]);\n }\n }\n }\n }\n catch (e) { }\n if (\"POST\" === this.metho d) {\n try {\n xhr.setRequestHeader(\"Content- type\", \"text/plain;charset=UTF-8\");\n }\n catch (e) { }\n }\n try {\n xhr.setRequestHeader (\"Accept\", \"*/*\");\n }\n catch (e) { }\n // ie6 check\n if (\"withCredentials\" in xhr) {\n xhr.w ithCredentials = this.opts.withCredentials;\n }\n if (this .opts.requestTimeout) {\n xhr.timeout = this.opts.requestTimeout; \n }\n xhr.onreadystatechange = () => {\n i f (4 !== xhr.readyState)\n return;\n if (200 = == xhr.status || 1223 === xhr.status) {\n this.onLoad();\n }\n else {\n // make sure the `er ror` event handler that's user-set\n // does not throw in the same tick and gets caught here\n this.setTimeoutFn(() => {\n this.onError(typeof xhr.status === \"number\" ? xhr.stat us : 0);\n }, 0);\n }\n };\n xhr.send(this.data);\n }\n catch (e) {\n // Need t o defer since .create() is called directly from the constructor\n // and thus the 'error' event can only be only bound *after* this exception\n // occurs. Therefore, also, we cannot throw here at all.\n thi s.setTimeoutFn(() => {\n this.onError(e);\n }, 0);\n return;\n }\n if (typeof document !== \"undefined\") {\n this.index = Request.requestsCount++;\n Request.requests[ this.index] = this;\n }\n }\n /**\n * Called upon error.\n *\n * @api private\n */\n onError(err) {\n this.emitReserved(\ "error\", err, this.xhr);\n this.cleanup(true);\n }\n /**\n * C leans up house.\n *\n * @api private\n */\n cleanup(fromError) {\ n if (\"undefined\" === typeof this.xhr || null === this.xhr) {\n return;\n }\n this.xhr.onreadystatechange = empty;\n if (fromError) {\n try {\n this.xhr.abort();\n }\n catch (e) { }\n }\n if (typeof document !== \"und efined\") {\n delete Request.requests[this.index];\n }\n this.xhr = null;\n }\n /**\n * Called upon load.\n *\n * @ap i private\n */\n onLoad() {\n const data = this.xhr.responseText;\ n if (data !== null) {\n this.emitReserved(\"data\", data);\n this.emitReserved(\"success\");\n this.cleanup();\n }\n }\n /**\n * Aborts the request.\n *\n * @api public\n */\n abort() {\n this.cleanup();\n }\n}\nRequest.requestsCount = 0 ;\nRequest.requests = {};\n/**\n * Aborts pending requests when unloading the wi ndow. This is needed to prevent\n * memory leaks (e.g. when using IE) and to ens ure that no spurious error is\n * emitted.\n */\nif (typeof document !== \"undef ined\") {\n // @ts-ignore\n if (typeof attachEvent === \"function\") {\n // @ts-ignore\n attachEvent(\"onunload\", unloadHandler);\n }\n else if (typeof addEventListener === \"function\") {\n const terminati onEvent = \"onpagehide\" in globalThis ? \"pagehide\" : \"unload\";\n add EventListener(terminationEvent, unloadHandler, false);\n }\n}\nfunction unloa dHandler() {\n for (let i in Request.requests) {\n if (Request.request s.hasOwnProperty(i)) {\n Request.requests[i].abort();\n }\n }\n}\n","import { globalThisShim as globalThis } from \"../globalThis.js\";\nex port const nextTick = (() => {\n const isPromiseAvailable = typeof Promise == = \"function\" && typeof Promise.resolve === \"function\";\n if (isPromiseAva ilable) {\n return cb => Promise.resolve().then(cb);\n }\n else {\n return (cb, setTimeoutFn) => setTimeoutFn(cb, 0);\n }\n})();\nexport const WebSocket = globalThis.WebSocket || globalThis.MozWebSocket;\nexport const usingBrowserWebSocket = true;\nexport const defaultBinaryType = \"arraybuffer\" ;\n","import { Transport } from \"../transport.js\";\nimport { encode } from \". ./contrib/parseqs.js\";\nimport { yeast } from \"../contrib/yeast.js\";\nimport { pick } from \"../util.js\";\nimport { defaultBinaryType, nextTick, usingBrowse rWebSocket, WebSocket } from \"./websocket-constructor.js\";\nimport { encodePac ket } from \"engine.io-parser\";\n// detect ReactNative environment\nconst isRea ctNative = typeof navigator !== \"undefined\" &&\n typeof navigator.product = == \"string\" &&\n navigator.product.toLowerCase() === \"reactnative\";\nexpo rt class WS extends Transport {\n /**\n * WebSocket transport constructor .\n *\n * @api {Object} connection options\n * @api public\n */\ n constructor(opts) {\n super(opts);\n this.supportsBinary = !o pts.forceBase64;\n }\n /**\n * Transport name.\n *\n * @api pu blic\n */\n get name() {\n return \"websocket\";\n }\n /**\n * Opens socket.\n *\n * @api private\n */\n doOpen() {\n if (!this.check()) {\n // let probe timeout\n return;\ n }\n const uri = this.uri();\n const protocols = this.opts .protocols;\n // React Native only supports the 'headers' option, and wil l print a warning if anything else is passed\n const opts = isReactNative \n ? {}\n : pick(this.opts, \"agent\", \"perMessageDeflate \", \"pfx\", \"key\", \"passphrase\", \"cert\", \"ca\", \"ciphers\", \"rejectUna uthorized\", \"localAddress\", \"protocolVersion\", \"origin\", \"maxPayload\", \"family\", \"checkServerIdentity\");\n if (this.opts.extraHeaders) {\n opts.headers = this.opts.extraHeaders;\n }\n try {\n this.ws =\n usingBrowserWebSocket && !isReactNative\n ? protocols\n ? new WebSocket(uri, protoc ols)\n : new WebSocket(uri)\n : new We bSocket(uri, protocols, opts);\n }\n catch (err) {\n re turn this.emitReserved(\"error\", err);\n }\n this.ws.binaryType = this.socket.binaryType || defaultBinaryType;\n this.addEventListeners(); \n }\n /**\n * Adds event listeners to the socket\n *\n * @api private\n */\n addEventListeners() {\n this.ws.onopen = () => {\n if (this.opts.autoUnref) {\n this.ws._socket.unref(); \n }\n this.onOpen();\n };\n this.ws.onclose = closeEvent => this.onClose({\n description: \"websocket connection closed\",\n context: closeEvent\n });\n this.ws.onmess age = ev => this.onData(ev.data);\n this.ws.onerror = e => this.onError(\ "websocket error\", e);\n }\n /**\n * Writes data to socket.\n *\n * @param {Array} array of packets.\n * @api private\n */\n write (packets) {\n this.writable = false;\n // encodePacket efficient a s it uses WS framing\n // no need for encodePayload\n for (let i = 0; i < packets.length; i++) {\n const packet = packets[i];\n const lastPacket = i === packets.length - 1;\n encodePacket(packe t, this.supportsBinary, data => {\n // always create a new object (GH-437)\n const opts = {};\n if (!usingBrowserWe bSocket) {\n if (packet.options) {\n o pts.compress = packet.options.compress;\n }\n if (this.opts.perMessageDeflate) {\n const len = \n // @ts-ignore\n \"string\" === type of data ? Buffer.byteLength(data) : data.length;\n if (le n < this.opts.perMessageDeflate.threshold) {\n opts.c ompress = false;\n }\n }\n }\n // Sometimes the websocket has already been closed but th e browser didn't\n // have a chance of informing us about it yet, in that case send will\n // throw an error\n try {\n if (usingBrowserWebSocket) {\n // TypeError is thrown when passing the second argument on Safari\n this.ws.send(data);\n }\n else {\n this.ws.send(data, opts);\n }\n }\n catch (e) {\n }\n if (lastPacket) {\n // fake drain\n // defer to next tick to allow Socket to clear writeBuffer\n nextTick( () => {\n this.writable = true;\n this.emitReserved(\"drain\");\n }, this.setTimeoutFn);\n }\n });\n }\n }\n /**\n * Closes socket.\ n *\n * @api private\n */\n doClose() {\n if (typeof this. ws !== \"undefined\") {\n this.ws.close();\n this.ws = nul l;\n }\n }\n /**\n * Generates uri for connection.\n *\n * @api private\n */\n uri() {\n let query = this.query || {};\n const schema = this.opts.secure ? \"wss\" : \"ws\";\n let port = \ "\";\n // avoid port if default for schema\n if (this.opts.port && \n ((\"wss\" === schema && Number(this.opts.port) !== 443) ||\n (\"ws\" === schema && Number(this.opts.port) !== 80))) {\n port = \":\" + this.opts.port;\n }\n // append timestamp to URI\n if (this.opts.timestampRequests) {\n query[this.opts.timestamp Param] = yeast();\n }\n // communicate binary support capabilities \n if (!this.supportsBinary) {\n query.b64 = 1;\n }\n const encodedQuery = encode(query);\n const ipv6 = this.opts.hostna me.indexOf(\":\") !== -1;\n return (schema +\n \"://\" +\n (ipv6 ? \"[\" + this.opts.hostname + \"]\" : this.opts.hostname) +\n port +\n this.opts.path +\n (encodedQuery.length ? \"?\" + encodedQuery : \"\"));\n }\n /**\n * Feature detection for We bSocket.\n *\n * @return {Boolean} whether this transport is available.\ n * @api public\n */\n check() {\n return !!WebSocket;\n }\ n}\n","import { Polling } from \"./polling.js\";\nimport { WS } from \"./websock et.js\";\nexport const transports = {\n websocket: WS,\n polling: Polling\ n};\n","// imported from https://github.com/galkn/parseuri\n/**\n * Parses an UR I\n *\n * @author Steven Levithan <stevenlevithan.com> (MIT license)\n * @api pr ivate\n */\nconst re = /^(?:(?![^:@]+:[^:@\\/]*@)(http|https|ws|wss):\\/\\/)?((? :(([^:@]*)(?::([^:@]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\\/?#]*)(? ::(\\d*))?)(((\\/(?:[^?#](?![^?#\\/]*\\.[^?#\\/.]+(?:[?#]|$)))*\\/?)?([^?#\\/]*) )(?:\\?([^#]*))?(?:#(.*))?)/;\nconst parts = [\n 'source', 'protocol', 'autho rity', 'userInfo', 'user', 'password', 'host', 'port', 'relative', 'path', 'dire ctory', 'file', 'query', 'anchor'\n];\nexport function parse(str) {\n const s rc = str, b = str.indexOf('['), e = str.indexOf(']');\n if (b != -1 && e != - 1) {\n str = str.substring(0, b) + str.substring(b, e).replace(/:/g, ';') + str.substring(e, str.length);\n }\n let m = re.exec(str || ''), uri = { }, i = 14;\n while (i--) {\n uri[parts[i]] = m[i] || '';\n }\n i f (b != -1 && e != -1) {\n uri.source = src;\n uri.host = uri.host .substring(1, uri.host.length - 1).replace(/;/g, ':');\n uri.authority = uri.authority.replace('[', '').replace(']', '').replace(/;/g, ':');\n uri .ipv6uri = true;\n }\n uri.pathNames = pathNames(uri, uri['path']);\n u ri.queryKey = queryKey(uri, uri['query']);\n return uri;\n}\nfunction pathNam es(obj, path) {\n const regx = /\\/{2,9}/g, names = path.replace(regx, \"/\") .split(\"/\");\n if (path.substr(0, 1) == '/' || path.length === 0) {\n names.splice(0, 1);\n }\n if (path.substr(path.length - 1, 1) == '/') {\ n names.splice(names.length - 1, 1);\n }\n return names;\n}\nfuncti on queryKey(uri, query) {\n const data = {};\n query.replace(/(?:^|&)([^&= ]*)=?([^&]*)/g, function ($0, $1, $2) {\n if ($1) {\n data[$1] = $2;\n }\n });\n return data;\n}\n","import { transports } from \ "./transports/index.js\";\nimport { installTimerFunctions, byteLength } from \". /util.js\";\nimport { decode } from \"./contrib/parseqs.js\";\nimport { parse } from \"./contrib/parseuri.js\";\nimport { Emitter } from \"@socket.io/component- emitter\";\nimport { protocol } from \"engine.io-parser\";\nexport class Socket extends Emitter {\n /**\n * Socket constructor.\n *\n * @param {S tring|Object} uri or options\n * @param {Object} opts - options\n * @api public\n */\n constructor(uri, opts = {}) {\n super();\n i f (uri && \"object\" === typeof uri) {\n opts = uri;\n uri = null;\n }\n if (uri) {\n uri = parse(uri);\n opts.hostname = uri.host;\n opts.secure = uri.protocol === \"http s\" || uri.protocol === \"wss\";\n opts.port = uri.port;\n if (uri.query)\n opts.query = uri.query;\n }\n els e if (opts.host) {\n opts.hostname = parse(opts.host).host;\n }\n installTimerFunctions(this, opts);\n this.secure =\n null != opts.secure\n ? opts.secure\n : typeof l ocation !== \"undefined\" && \"https:\" === location.protocol;\n if (opts .hostname && !opts.port) {\n // if no port is specified manually, use the protocol default\n opts.port = this.secure ? \"443\" : \"80\";\n }\n this.hostname =\n opts.hostname ||\n (typeof location !== \"undefined\" ? location.hostname : \"localhost\");\n this.port =\n opts.port ||\n (typeof location !== \"undefined\" && location.port\n ? location.port\n : this.secure\n ? \"443\"\n : \"80\");\n this.transports = opts.transports || [\"polling\", \"webs ocket\"];\n this.readyState = \"\";\n this.writeBuffer = [];\n this.prevBufferLen = 0;\n this.opts = Object.assign({\n pa th: \"/engine.io\",\n agent: false,\n withCredentials: fal se,\n upgrade: true,\n timestampParam: \"t\",\n rememberUpgrade: false,\n rejectUnauthorized: true,\n per MessageDeflate: {\n threshold: 1024\n },\n transportOptions: {},\n closeOnBeforeunload: true\n }, opts);\ n this.opts.path = this.opts.path.replace(/\\/$/, \"\") + \"/\";\n if (typeof this.opts.query === \"string\") {\n this.opts.query = dec ode(this.opts.query);\n }\n // set on handshake\n this.id = null;\n this.upgrades = null;\n this.pingInterval = null;\n this.pingTimeout = null;\n // set on heartbeat\n this.pingTimeou tTimer = null;\n if (typeof addEventListener === \"function\") {\n if (this.opts.closeOnBeforeunload) {\n // Firefox closes the connection when the \"beforeunload\" event is emitted but not Chrome. This even t listener\n // ensures every browser behaves the same (no \"disc onnect\" event at the Socket.IO level when the page is\n // close d/reloaded)\n addEventListener(\"beforeunload\", () => {\n if (this.transport) {\n // silently close th e transport\n this.transport.removeAllListeners();\n this.transport.close();\n }\n }, false);\n }\n if (this.hostname !== \"localhost\") { \n this.offlineEventListener = () => {\n this. onClose(\"transport close\", {\n description: \"network c onnection lost\"\n });\n };\n a ddEventListener(\"offline\", this.offlineEventListener, false);\n }\n }\n this.open();\n }\n /**\n * Creates transport of the given type.\n *\n * @param {String} transport name\n * @return {Tra nsport}\n * @api private\n */\n createTransport(name) {\n cons t query = Object.assign({}, this.opts.query);\n // append engine.io proto col identifier\n query.EIO = protocol;\n // transport name\n query.transport = name;\n // session id if we already have one\n if (this.id)\n query.sid = this.id;\n const opts = Object.ass ign({}, this.opts.transportOptions[name], this.opts, {\n query,\n socket: this,\n hostname: this.hostname,\n secure: this.secure,\n port: this.port\n });\n return new tran sports[name](opts);\n }\n /**\n * Initializes transport to use and sta rts probe.\n *\n * @api private\n */\n open() {\n let tran sport;\n if (this.opts.rememberUpgrade &&\n Socket.priorWebsoc ketSuccess &&\n this.transports.indexOf(\"websocket\") !== -1) {\n transport = \"websocket\";\n }\n else if (0 === this.tran sports.length) {\n // Emit error on next tick so it can be listened t o\n this.setTimeoutFn(() => {\n this.emitReserved(\"er ror\", \"No transports available\");\n }, 0);\n return;\n }\n else {\n transport = this.transports[0];\n } \n this.readyState = \"opening\";\n // Retry with the next transpo rt if the transport is disabled (jsonp: false)\n try {\n trans port = this.createTransport(transport);\n }\n catch (e) {\n this.transports.shift();\n this.open();\n return;\n }\n transport.open();\n this.setTransport(transport);\n } \n /**\n * Sets the current transport. Disables the existing one (if any) .\n *\n * @api private\n */\n setTransport(transport) {\n if (this.transport) {\n this.transport.removeAllListeners();\n }\n // set up transport\n this.transport = transport;\n // set up transport listeners\n transport\n .on(\"drain\", this. onDrain.bind(this))\n .on(\"packet\", this.onPacket.bind(this))\n .on(\"error\", this.onError.bind(this))\n .on(\"close\", reas on => this.onClose(\"transport close\", reason));\n }\n /**\n * Probes a transport.\n *\n * @param {String} transport name\n * @api privat e\n */\n probe(name) {\n let transport = this.createTransport(name );\n let failed = false;\n Socket.priorWebsocketSuccess = false;\n const onTransportOpen = () => {\n if (failed)\n return;\n transport.send([{ type: \"ping\", data: \"probe\" }]);\n transport.once(\"packet\", msg => {\n if (failed)\n return;\n if (\"pong\" === msg.type && \"probe\" === msg.data) {\n this.upgrading = true;\n this.emitReserved(\"upgrading\", transport);\n if (!transpo rt)\n return;\n Socket.priorWebsocketS uccess = \"websocket\" === transport.name;\n this.transport.p ause(() => {\n if (failed)\n r eturn;\n if (\"closed\" === this.readyState)\n return;\n cleanup();\n this.setTransport(transport);\n transport.send([{ t ype: \"upgrade\" }]);\n this.emitReserved(\"upgrade\", tr ansport);\n transport = null;\n th is.upgrading = false;\n this.flush();\n });\n }\n else {\n const err = new Error(\"probe error\");\n // @ts-ignore\n err.transport = transport.name;\n this.emitReserved(\"u pgradeError\", err);\n }\n });\n };\n fu nction freezeTransport() {\n if (failed)\n return;\n // Any callback called by transport should be ignored since now\n failed = true;\n cleanup();\n transport.close();\n transport = null;\n }\n // Handle any error that happen s while probing\n const onerror = err => {\n const error = new Error(\"probe error: \" + err);\n // @ts-ignore\n error.t ransport = transport.name;\n freezeTransport();\n this.emi tReserved(\"upgradeError\", error);\n };\n function onTransportClo se() {\n onerror(\"transport closed\");\n }\n // When t he socket is closed while we're probing\n function onclose() {\n onerror(\"socket closed\");\n }\n // When the socket is upgrade d while we're probing\n function onupgrade(to) {\n if (transpo rt && to.name !== transport.name) {\n freezeTransport();\n }\n }\n // Remove all listeners on the transport and on self\ n const cleanup = () => {\n transport.removeListener(\"open\", onTransportOpen);\n transport.removeListener(\"error\", onerror);\n transport.removeListener(\"close\", onTransportClose);\n t his.off(\"close\", onclose);\n this.off(\"upgrading\", onupgrade);\n };\n transport.once(\"open\", onTransportOpen);\n transport .once(\"error\", onerror);\n transport.once(\"close\", onTransportClose); \n this.once(\"close\", onclose);\n this.once(\"upgrading\", onupg rade);\n transport.open();\n }\n /**\n * Called when connection is deemed open.\n *\n * @api private\n */\n onOpen() {\n this.readyState = \"open\";\n Socket.priorWebsocketSuccess = \"websocket\ " === this.transport.name;\n this.emitReserved(\"open\");\n this.f lush();\n // we check for `readyState` in case an `open`\n // list ener already closed the socket\n if (\"open\" === this.readyState &&\n this.opts.upgrade &&\n this.transport.pause) {\n let i = 0;\n const l = this.upgrades.length;\n for (; i < l; i++) {\n this.probe(this.upgrades[i]);\n }\n }\n }\n /**\n * Handles a packet.\n *\n * @api private\n */\n onPacket(packet) {\n if (\"opening\" === this.readyState ||\n \"open\" === this.readyState ||\n \"closing\" === this.readyS tate) {\n this.emitReserved(\"packet\", packet);\n // Sock et is live - any packet counts\n this.emitReserved(\"heartbeat\");\n switch (packet.type) {\n case \"open\":\n this.onHandshake(JSON.parse(packet.data));\n break;\n case \"ping\":\n this.resetPingTimeout();\n this.sendPacket(\"pong\");\n this.emitReserv ed(\"ping\");\n this.emitReserved(\"pong\");\n break;\n case \"error\":\n const err = ne w Error(\"server error\");\n // @ts-ignore\n err.code = packet.data;\n this.onError(err);\n break;\n case \"message\":\n this.emit Reserved(\"data\", packet.data);\n this.emitReserved(\"messag e\", packet.data);\n break;\n }\n }\n else {\n }\n }\n /**\n * Called upon handshake completion.\n *\n * @param {Object} data - handshake obj\n * @api private\n */ \n onHandshake(data) {\n this.emitReserved(\"handshake\", data);\n this.id = data.sid;\n this.transport.query.sid = data.sid;\n t his.upgrades = this.filterUpgrades(data.upgrades);\n this.pingInterval = data.pingInterval;\n this.pingTimeout = data.pingTimeout;\n this.m axPayload = data.maxPayload;\n this.onOpen();\n // In case open ha ndler closes socket\n if (\"closed\" === this.readyState)\n re turn;\n this.resetPingTimeout();\n }\n /**\n * Sets and resets ping timeout timer based on server pings.\n *\n * @api private\n */\ n resetPingTimeout() {\n this.clearTimeoutFn(this.pingTimeoutTimer);\n this.pingTimeoutTimer = this.setTimeoutFn(() => {\n this.onCl ose(\"ping timeout\");\n }, this.pingInterval + this.pingTimeout);\n if (this.opts.autoUnref) {\n this.pingTimeoutTimer.unref();\n }\n }\n /**\n * Called on `drain` event\n *\n * @api privat e\n */\n onDrain() {\n this.writeBuffer.splice(0, this.prevBufferL en);\n // setting prevBufferLen = 0 is very important\n // for exa mple, when upgrading, upgrade packet is sent over,\n // and a nonzero pre vBufferLen could cause problems on `drain`\n this.prevBufferLen = 0;\n if (0 === this.writeBuffer.length) {\n this.emitReserved(\"drain \");\n }\n else {\n this.flush();\n }\n }\n /**\n * Flush write buffers.\n *\n * @api private\n */\n fl ush() {\n if (\"closed\" !== this.readyState &&\n this.transpo rt.writable &&\n !this.upgrading &&\n this.writeBuffer.len gth) {\n const packets = this.getWritablePackets();\n this .transport.send(packets);\n // keep track of current length of writeB uffer\n // splice writeBuffer and callbackBuffer on `drain`\n this.prevBufferLen = packets.length;\n this.emitReserved(\"flush\ ");\n }\n }\n /**\n * Ensure the encoded size of the writeBuffe r is below the maxPayload value sent by the server (only for HTTP\n * long-p olling)\n *\n * @private\n */\n getWritablePackets() {\n c onst shouldCheckPayloadSize = this.maxPayload &&\n this.transport.nam e === \"polling\" &&\n this.writeBuffer.length > 1;\n if (!sho uldCheckPayloadSize) {\n return this.writeBuffer;\n }\n let payloadSize = 1; // first packet type\n for (let i = 0; i < this.wri teBuffer.length; i++) {\n const data = this.writeBuffer[i].data;\n if (data) {\n payloadSize += byteLength(data);\n }\n if (i > 0 && payloadSize > this.maxPayload) {\n return this.writeBuffer.slice(0, i);\n }\n payloadSize + = 2; // separator + packet type\n }\n return this.writeBuffer;\n }\n /**\n * Sends a message.\n *\n * @param {String} message.\n * @param {Function} callback function.\n * @param {Object} options.\n * @return {Socket} for chaining.\n * @api public\n */\n write(msg, options, fn) {\n this.sendPacket(\"message\", msg, options, fn);\n return this;\n }\n send(msg, options, fn) {\n this.sendPacket(\"m essage\", msg, options, fn);\n return this;\n }\n /**\n * Sends a packet.\n *\n * @param {String} packet type.\n * @param {String} data.\n * @param {Object} options.\n * @param {Function} callback functi on.\n * @api private\n */\n sendPacket(type, data, options, fn) {\n if (\"function\" === typeof data) {\n fn = data;\n d ata = undefined;\n }\n if (\"function\" === typeof options) {\n fn = options;\n options = null;\n }\n if (\"cl osing\" === this.readyState || \"closed\" === this.readyState) {\n re turn;\n }\n options = options || {};\n options.compress = f alse !== options.compress;\n const packet = {\n type: type,\n data: data,\n options: options\n };\n this.e mitReserved(\"packetCreate\", packet);\n this.writeBuffer.push(packet);\n if (fn)\n this.once(\"flush\", fn);\n this.flush();\n }\n /**\n * Closes the connection.\n *\n * @api public\n * /\n close() {\n const close = () => {\n this.onClose(\"forc ed close\");\n this.transport.close();\n };\n const cle anupAndClose = () => {\n this.off(\"upgrade\", cleanupAndClose);\n this.off(\"upgradeError\", cleanupAndClose);\n close();\n };\n const waitForUpgrade = () => {\n // wait for upgrade to finish since we can't send packets while pausing a transport\n th is.once(\"upgrade\", cleanupAndClose);\n this.once(\"upgradeError\", cleanupAndClose);\n };\n if (\"opening\" === this.readyState || \" open\" === this.readyState) {\n this.readyState = \"closing\";\n if (this.writeBuffer.length) {\n this.once(\"drain\", () = > {\n if (this.upgrading) {\n waitForU pgrade();\n }\n else {\n close();\n }\n });\n }\n else if (this.upgrading) {\n waitForUpgrade();\n }\n else {\n close();\n }\n }\n return this;\n }\n /**\n * Called upon transport error\n *\n * @api private\n */\n onError(err) {\n Socket.priorWebsocketSu ccess = false;\n this.emitReserved(\"error\", err);\n this.onClose (\"transport error\", err);\n }\n /**\n * Called upon transport close. \n *\n * @api private\n */\n onClose(reason, description) {\n if (\"opening\" === this.readyState ||\n \"open\" === this.readyS tate ||\n \"closing\" === this.readyState) {\n // clear ti mers\n this.clearTimeoutFn(this.pingTimeoutTimer);\n // st op event from firing again for transport\n this.transport.removeAllLi steners(\"close\");\n // ensure transport won't stay open\n this.transport.close();\n // ignore further transport communication \n this.transport.removeAllListeners();\n if (typeof remov eEventListener === \"function\") {\n removeEventListener(\"offlin e\", this.offlineEventListener, false);\n }\n // set ready state\n this.readyState = \"closed\";\n // clear session id\n this.id = null;\n // emit close event\n th is.emitReserved(\"close\", reason, description);\n // clean buffers a fter, so users can still\n // grab the buffers on `close` event\n this.writeBuffer = [];\n this.prevBufferLen = 0;\n }\n }\n /**\n * Filters upgrades, returning only those matching client tr ansports.\n *\n * @param {Array} server upgrades\n * @api private\n *\n */\n filterUpgrades(upgrades) {\n const filteredUpgrades = [];\n let i = 0;\n const j = upgrades.length;\n for (; i < j; i++) {\n if (~this.transports.indexOf(upgrades[i]))\n filteredUpgrades.push(upgrades[i]);\n }\n return filteredUpgra des;\n }\n}\nSocket.protocol = protocol;\n","const withNativeArrayBuffer = ty peof ArrayBuffer === \"function\";\nconst isView = (obj) => {\n return typeof ArrayBuffer.isView === \"function\"\n ? ArrayBuffer.isView(obj)\n : obj.buffer instanceof ArrayBuffer;\n};\nconst toString = Object.prototype.toS tring;\nconst withNativeBlob = typeof Blob === \"function\" ||\n (typeof Blob !== \"undefined\" &&\n toString.call(Blob) === \"[object BlobConstructor ]\");\nconst withNativeFile = typeof File === \"function\" ||\n (typeof File !== \"undefined\" &&\n toString.call(File) === \"[object FileConstructor] \");\n/**\n * Returns true if obj is a Buffer, an ArrayBuffer, a Blob or a File. \n *\n * @private\n */\nexport function isBinary(obj) {\n return ((withNative ArrayBuffer && (obj instanceof ArrayBuffer || isView(obj))) ||\n (withNat iveBlob && obj instanceof Blob) ||\n (withNativeFile && obj instanceof Fi le));\n}\nexport function hasBinary(obj, toJSON) {\n if (!obj || typeof obj ! == \"object\") {\n return false;\n }\n if (Array.isArray(obj)) {\n for (let i = 0, l = obj.length; i < l; i++) {\n if (hasBinary( obj[i])) {\n return true;\n }\n }\n retu rn false;\n }\n if (isBinary(obj)) {\n return true;\n }\n if (obj.toJSON &&\n typeof obj.toJSON === \"function\" &&\n arguments .length === 1) {\n return hasBinary(obj.toJSON(), true);\n }\n for (const key in obj) {\n if (Object.prototype.hasOwnProperty.call(obj, key) && hasBinary(obj[key])) {\n return true;\n }\n }\n retu rn false;\n}\n","import { isBinary } from \"./is-binary.js\";\n/**\n * Replaces every Buffer | ArrayBuffer | Blob | File in packet with a numbered placeholder.\ n *\n * @param {Object} packet - socket.io event packet\n * @return {Object} wit h deconstructed packet and list of buffers\n * @public\n */\nexport function dec onstructPacket(packet) {\n const buffers = [];\n const packetData = packet .data;\n const pack = packet;\n pack.data = _deconstructPacket(packetData, buffers);\n pack.attachments = buffers.length; // number of binary 'attachme nts'\n return { packet: pack, buffers: buffers };\n}\nfunction _deconstructPa cket(data, buffers) {\n if (!data)\n return data;\n if (isBinary(da ta)) {\n const placeholder = { _placeholder: true, num: buffers.length }; \n buffers.push(data);\n return placeholder;\n }\n else if ( Array.isArray(data)) {\n const newData = new Array(data.length);\n for (let i = 0; i < data.length; i++) {\n newData[i] = _deconstructP acket(data[i], buffers);\n }\n return newData;\n }\n else if (typeof data === \"object\" && !(data instanceof Date)) {\n const newDat a = {};\n for (const key in data) {\n if (Object.prototype.has OwnProperty.call(data, key)) {\n newData[key] = _deconstructPacke t(data[key], buffers);\n }\n }\n return newData;\n } \n return data;\n}\n/**\n * Reconstructs a binary packet from its placeholder packet and buffers\n *\n * @param {Object} packet - event packet with placehold ers\n * @param {Array} buffers - binary buffers to put in placeholder positions\ n * @return {Object} reconstructed packet\n * @public\n */\nexport function reco nstructPacket(packet, buffers) {\n packet.data = _reconstructPacket(packet.da ta, buffers);\n packet.attachments = undefined; // no longer useful\n retu rn packet;\n}\nfunction _reconstructPacket(data, buffers) {\n if (!data)\n return data;\n if (data && data._placeholder) {\n return buffers[ data.num]; // appropriate buffer (should be natural order anyway)\n }\n el se if (Array.isArray(data)) {\n for (let i = 0; i < data.length; i++) {\n data[i] = _reconstructPacket(data[i], buffers);\n }\n }\n else if (typeof data === \"object\") {\n for (const key in data) {\n if (Object.prototype.hasOwnProperty.call(data, key)) {\n data[key] = _reconstructPacket(data[key], buffers);\n }\n }\ n }\n return data;\n}\n","import { Emitter } from \"@socket.io/component-e mitter\";\nimport { deconstructPacket, reconstructPacket } from \"./binary.js\"; \nimport { isBinary, hasBinary } from \"./is-binary.js\";\n/**\n * Protocol vers ion.\n *\n * @public\n */\nexport const protocol = 5;\nexport var PacketType;\n( function (PacketType) {\n PacketType[PacketType[\"CONNECT\"] = 0] = \"CONNECT \";\n PacketType[PacketType[\"DISCONNECT\"] = 1] = \"DISCONNECT\";\n Packe tType[PacketType[\"EVENT\"] = 2] = \"EVENT\";\n PacketType[PacketType[\"ACK\" ] = 3] = \"ACK\";\n PacketType[PacketType[\"CONNECT_ERROR\"] = 4] = \"CONNECT _ERROR\";\n PacketType[PacketType[\"BINARY_EVENT\"] = 5] = \"BINARY_EVENT\";\ n PacketType[PacketType[\"BINARY_ACK\"] = 6] = \"BINARY_ACK\";\n})(PacketType || (PacketType = {}));\n/**\n * A socket.io Encoder instance\n */\nexport class Encoder {\n /**\n * Encoder constructor\n *\n * @param {function } replacer - custom replacer to pass down to JSON.parse\n */\n constructo r(replacer) {\n this.replacer = replacer;\n }\n /**\n * Encode a packet as a single string if non-binary, or as a\n * buffer sequence, depe nding on packet type.\n *\n * @param {Object} obj - packet object\n */\n encode(obj) {\n if (obj.type === PacketType.EVENT || obj.type === PacketType.ACK) {\n if (hasBinary(obj)) {\n obj.type =\n obj.type === PacketType.EVENT\n ? PacketType.BINARY_EVENT\n : PacketType.BINARY_ACK;\n return this.encodeAsBinary(obj);\n }\n }\n r eturn [this.encodeAsString(obj)];\n }\n /**\n * Encode packet as strin g.\n */\n encodeAsString(obj) {\n // first is type\n let st r = \"\" + obj.type;\n // attachments if we have them\n if (obj.ty pe === PacketType.BINARY_EVENT ||\n obj.type === PacketType.BINARY_AC K) {\n str += obj.attachments + \"-\";\n }\n // if we h ave a namespace other than `/`\n // we append it followed by a comma `,`\ n if (obj.nsp && \"/\" !== obj.nsp) {\n str += obj.nsp + \",\" ;\n }\n // immediately followed by the id\n if (null != obj .id) {\n str += obj.id;\n }\n // json data\n if (null != obj.data) {\n str += JSON.stringify(obj.data, this.replacer) ;\n }\n return str;\n }\n /**\n * Encode packet as 'buff er sequence' by removing blobs, and\n * deconstructing packet into object wi th placeholders and\n * a list of buffers.\n */\n encodeAsBinary(obj) {\n const deconstruction = deconstructPacket(obj);\n const pack = this.encodeAsString(deconstruction.packet);\n const buffers = deconstruc tion.buffers;\n buffers.unshift(pack); // add packet info to beginning of data list\n return buffers; // write all the buffers\n }\n}\n/**\n * A socket.io Decoder instance\n *\n * @return {Object} decoder\n */\nexport class Decoder extends Emitter {\n /**\n * Decoder constructor\n *\n * @param {function} reviver - custom reviver to pass down to JSON.stringify\n */\n constructor(reviver) {\n super();\n this.reviver = reviver ;\n }\n /**\n * Decodes an encoded packet string into packet JSON.\n *\n * @param {String} obj - encoded packet\n */\n add(obj) {\n let packet;\n if (typeof obj === \"string\") {\n packet = this.decodeString(obj);\n if (packet.type === PacketType.BINARY_EVENT ||\n packet.type === PacketType.BINARY_ACK) {\n / / binary packet's json\n this.reconstructor = new BinaryReconstru ctor(packet);\n // no attachments, labeled binary but no binary d ata to follow\n if (packet.attachments === 0) {\n super.emitReserved(\"decoded\", packet);\n }\n }\n else {\n // non-binary full packet\n s uper.emitReserved(\"decoded\", packet);\n }\n }\n else if (isBinary(obj) || obj.base64) {\n // raw binary data\n if (!this.reconstructor) {\n throw new Error(\"got binary data wh en not reconstructing a packet\");\n }\n else {\n packet = this.reconstructor.takeBinaryData(obj);\n if (pac ket) {\n // received final buffer\n this.r econstructor = null;\n super.emitReserved(\"decoded\", packet );\n }\n }\n }\n else {\n thr ow new Error(\"Unknown type: \" + obj);\n }\n }\n /**\n * Decod e a packet String (JSON data)\n *\n * @param {String} str\n * @retur n {Object} packet\n */\n decodeString(str) {\n let i = 0;\n // look up type\n const p = {\n type: Number(str.charAt(0)),\ n };\n if (PacketType[p.type] === undefined) {\n throw new Error(\"unknown packet type \" + p.type);\n }\n // look up att achments if type binary\n if (p.type === PacketType.BINARY_EVENT ||\n p.type === PacketType.BINARY_ACK) {\n const start = i + 1;\n while (str.charAt(++i) !== \"-\" && i != str.length) { }\n const buf = str.substring(start, i);\n if (buf != Number(buf) || str .charAt(i) !== \"-\") {\n throw new Error(\"Illegal attachments\" );\n }\n p.attachments = Number(buf);\n }\n // look up namespace (if any)\n if (\"/\" === str.charAt(i + 1)) {\n const start = i + 1;\n while (++i) {\n const c = str.charAt(i);\n if (\",\" === c)\n break;\n if (i === str.length)\n break;\n } \n p.nsp = str.substring(start, i);\n }\n else {\n p.nsp = \"/\";\n }\n // look up id\n const next = st r.charAt(i + 1);\n if (\"\" !== next && Number(next) == next) {\n const start = i + 1;\n while (++i) {\n const c = s tr.charAt(i);\n if (null == c || Number(c) != c) {\n --i;\n break;\n }\n if ( i === str.length)\n break;\n }\n p.id = Number(str.substring(start, i + 1));\n }\n // look up json data\n if (str.charAt(++i)) {\n const payload = this.tryParse(str.su bstr(i));\n if (Decoder.isPayloadValid(p.type, payload)) {\n p.data = payload;\n }\n else {\n thr ow new Error(\"invalid payload\");\n }\n }\n return p;\ n }\n tryParse(str) {\n try {\n return JSON.parse(str, t his.reviver);\n }\n catch (e) {\n return false;\n }\n }\n static isPayloadValid(type, payload) {\n switch (type) {\ n case PacketType.CONNECT:\n return typeof payload === \"object\";\n case PacketType.DISCONNECT:\n return pa yload === undefined;\n case PacketType.CONNECT_ERROR:\n return typeof payload === \"string\" || typeof payload === \"object\";\n case PacketType.EVENT:\n case PacketType.BINARY_EVENT:\n return Array.isArray(payload) && payload.length > 0;\n case PacketType.ACK:\n case PacketType.BINARY_ACK:\n return Array.isArray(payload);\n }\n }\n /**\n * Deallocates a parser 's resources\n */\n destroy() {\n if (this.reconstructor) {\n this.reconstructor.finishedReconstruction();\n }\n }\n}\n/**\n * A manager of a binary event's 'buffer sequence'. Should\n * be constructed whe never a packet of type BINARY_EVENT is\n * decoded.\n *\n * @param {Object} pack et\n * @return {BinaryReconstructor} initialized reconstructor\n */\nclass Binar yReconstructor {\n constructor(packet) {\n this.packet = packet;\n this.buffers = [];\n this.reconPack = packet;\n }\n /**\n * Method to be called when binary data received from connection\n * after a B INARY_EVENT packet.\n *\n * @param {Buffer | ArrayBuffer} binData - the raw binary data received\n * @return {null | Object} returns null if more bi nary data is expected or\n * a reconstructed packet object if all buffers have been received.\n */\n takeBinaryData(binData) {\n this.buffer s.push(binData);\n if (this.buffers.length === this.reconPack.attachments ) {\n // done with buffer list\n const packet = reconstruc tPacket(this.reconPack, this.buffers);\n this.finishedReconstruction( );\n return packet;\n }\n return null;\n }\n /**\ n * Cleans up binary packet reconstruction variables.\n */\n finished Reconstruction() {\n this.reconPack = null;\n this.buffers = [];\n }\n}\n","export function on(obj, ev, fn) {\n obj.on(ev, fn);\n return function subDestroy() {\n obj.off(ev, fn);\n };\n}\n","import { Packet Type } from \"socket.io-parser\";\nimport { on } from \"./on.js\";\nimport { Emi tter, } from \"@socket.io/component-emitter\";\n/**\n * Internal events.\n * The se events can't be emitted by the user.\n */\nconst RESERVED_EVENTS = Object.fre eze({\n connect: 1,\n connect_error: 1,\n disconnect: 1,\n disconnec ting: 1,\n // EventEmitter reserved events: https://nodejs.org/api/events.htm l#events_event_newlistener\n newListener: 1,\n removeListener: 1,\n});\nex port class Socket extends Emitter {\n /**\n * `Socket` constructor.\n *\n * @public\n */\n constructor(io, nsp, opts) {\n super();\ n this.connected = false;\n this.receiveBuffer = [];\n this .sendBuffer = [];\n this.ids = 0;\n this.acks = {};\n this. flags = {};\n this.io = io;\n this.nsp = nsp;\n if (opts && opts.auth) {\n this.auth = opts.auth;\n }\n if (this.i o._autoConnect)\n this.open();\n }\n /**\n * Whether the so cket is currently disconnected\n */\n get disconnected() {\n retur n !this.connected;\n }\n /**\n * Subscribe to open, close and packet e vents\n *\n * @private\n */\n subEvents() {\n if (this.sub s)\n return;\n const io = this.io;\n this.subs = [\n on(io, \"open\", this.onopen.bind(this)),\n on(io, \"packet\ ", this.onpacket.bind(this)),\n on(io, \"error\", this.onerror.bind(t his)),\n on(io, \"close\", this.onclose.bind(this)),\n ];\n }\n /**\n * Whether the Socket will try to reconnect when its Manager co nnects or reconnects\n */\n get active() {\n return !!this.subs;\n }\n /**\n * \"Opens\" the socket.\n *\n * @public\n */\n connect() {\n if (this.connected)\n return this;\n t his.subEvents();\n if (!this.io[\"_reconnecting\"])\n this.io. open(); // ensure open\n if (\"open\" === this.io._readyState)\n this.onopen();\n return this;\n }\n /**\n * Alias for connec t()\n */\n open() {\n return this.connect();\n }\n /**\n * Sends a `message` event.\n *\n * @return self\n * @public\n * /\n send(...args) {\n args.unshift(\"message\");\n this.emit.ap ply(this, args);\n return this;\n }\n /**\n * Override `emit`.\ n * If the event is in `events`, it's emitted normally.\n *\n * @ret urn self\n * @public\n */\n emit(ev, ...args) {\n if (RESERVED _EVENTS.hasOwnProperty(ev)) {\n throw new Error('\"' + ev.toString() + '\" is a reserved event name');\n }\n args.unshift(ev);\n const packet = {\n type: PacketType.EVENT,\n data: args,\ n };\n packet.options = {};\n packet.options.compress = thi s.flags.compress !== false;\n // event ack callback\n if (\"functi on\" === typeof args[args.length - 1]) {\n const id = this.ids++;\n const ack = args.pop();\n this._registerAckCallback(id, ack );\n packet.id = id;\n }\n const isTransportWritable = this.io.engine &&\n this.io.engine.transport &&\n this.io. engine.transport.writable;\n const discardPacket = this.flags.volatile && (!isTransportWritable || !this.connected);\n if (discardPacket) {\n }\n else if (this.connected) {\n this.notifyOutgoingListene rs(packet);\n this.packet(packet);\n }\n else {\n this.sendBuffer.push(packet);\n }\n this.flags = {};\n return this;\n }\n /**\n * @private\n */\n _registerAckCallba ck(id, ack) {\n const timeout = this.flags.timeout;\n if (timeout === undefined) {\n this.acks[id] = ack;\n return;\n }\n // @ts-ignore\n const timer = this.io.setTimeoutFn(() => {\n delete this.acks[id];\n for (let i = 0; i < this.sendBuffe r.length; i++) {\n if (this.sendBuffer[i].id === id) {\n this.sendBuffer.splice(i, 1);\n }\n }\n ack.call(this, new Error(\"operation has timed out\"));\n }, time out);\n this.acks[id] = (...args) => {\n // @ts-ignore\n this.io.clearTimeoutFn(timer);\n ack.apply(this, [null, ...args ]);\n };\n }\n /**\n * Sends a packet.\n *\n * @param p acket\n * @private\n */\n packet(packet) {\n packet.nsp = this .nsp;\n this.io._packet(packet);\n }\n /**\n * Called upon engi ne `open`.\n *\n * @private\n */\n onopen() {\n if (typeof this.auth == \"function\") {\n this.auth((data) => {\n this.packet({ type: PacketType.CONNECT, data });\n });\n }\n else {\n this.packet({ type: PacketType.CONNECT, data: this.a uth });\n }\n }\n /**\n * Called upon engine or manager `error` .\n *\n * @param err\n * @private\n */\n onerror(err) {\n if (!this.connected) {\n this.emitReserved(\"connect_error\", err );\n }\n }\n /**\n * Called upon engine `close`.\n *\n * @param reason\n * @param description\n * @private\n */\n onclos e(reason, description) {\n this.connected = false;\n delete this.i d;\n this.emitReserved(\"disconnect\", reason, description);\n }\n /**\n * Called with socket packet.\n *\n * @param packet\n * @pr ivate\n */\n onpacket(packet) {\n const sameNamespace = packet.nsp === this.nsp;\n if (!sameNamespace)\n return;\n switch (packet.type) {\n case PacketType.CONNECT:\n if (pack et.data && packet.data.sid) {\n const id = packet.data.sid;\n this.onconnect(id);\n }\n else {\n this.emitReserved(\"connect_error\", new Error(\"It seem s you are trying to reach a Socket.IO server in v2.x with a v3.x client, but the y are not compatible (more information here: https://socket.io/docs/v3/migrating -from-2-x-to-3-0/)\"));\n }\n break;\n case PacketType.EVENT:\n case PacketType.BINARY_EVENT:\n this.onevent(packet);\n break;\n case PacketType.AC K:\n case PacketType.BINARY_ACK:\n this.onack(packet); \n break;\n case PacketType.DISCONNECT:\n this.ondisconnect();\n break;\n case PacketType.CON NECT_ERROR:\n this.destroy();\n const err = new Er ror(packet.data.message);\n // @ts-ignore\n err.da ta = packet.data.data;\n this.emitReserved(\"connect_error\", err );\n break;\n }\n }\n /**\n * Called upon a serv er event.\n *\n * @param packet\n * @private\n */\n onevent(p acket) {\n const args = packet.data || [];\n if (null != packet.id ) {\n args.push(this.ack(packet.id));\n }\n if (this.co nnected) {\n this.emitEvent(args);\n }\n else {\n this.receiveBuffer.push(Object.freeze(args));\n }\n }\n emitE vent(args) {\n if (this._anyListeners && this._anyListeners.length) {\n const listeners = this._anyListeners.slice();\n for (const listener of listeners) {\n listener.apply(this, args);\n }\n }\n super.emit.apply(this, args);\n }\n /**\n * P roduces an ack callback to emit with an event.\n *\n * @private\n */ \n ack(id) {\n const self = this;\n let sent = false;\n return function (...args) {\n // prevent double callbacks\n if (sent)\n return;\n sent = true;\n self .packet({\n type: PacketType.ACK,\n id: id,\n data: args,\n });\n };\n }\n /**\n * Call ed upon a server acknowlegement.\n *\n * @param packet\n * @private\ n */\n onack(packet) {\n const ack = this.acks[packet.id];\n if (\"function\" === typeof ack) {\n ack.apply(this, packet.data);\ n delete this.acks[packet.id];\n }\n else {\n }\ n }\n /**\n * Called upon server connect.\n *\n * @private\n */\n onconnect(id) {\n this.id = id;\n this.connected = true ;\n this.emitBuffered();\n this.emitReserved(\"connect\");\n }\ n /**\n * Emit buffered events (received and emitted).\n *\n * @p rivate\n */\n emitBuffered() {\n this.receiveBuffer.forEach((args) => this.emitEvent(args));\n this.receiveBuffer = [];\n this.sendB uffer.forEach((packet) => {\n this.notifyOutgoingListeners(packet);\n this.packet(packet);\n });\n this.sendBuffer = [];\n }\n /**\n * Called upon server disconnect.\n *\n * @private\n */\n ondisconnect() {\n this.destroy();\n this.onclose(\"io server disconnect\");\n }\n /**\n * Called upon forced client/server s ide disconnections,\n * this method ensures the manager stops tracking us an d\n * that reconnections don't get triggered for this.\n *\n * @priv ate\n */\n destroy() {\n if (this.subs) {\n // clean su bscriptions to avoid reconnections\n this.subs.forEach((subDestroy) = > subDestroy());\n this.subs = undefined;\n }\n this.io [\"_destroy\"](this);\n }\n /**\n * Disconnects the socket manually.\n *\n * @return self\n * @public\n */\n disconnect() {\n if (this.connected) {\n this.packet({ type: PacketType.DISCONNECT } );\n }\n // remove socket from pool\n this.destroy();\n if (this.connected) {\n // fire events\n this.onclose( \"io client disconnect\");\n }\n return this;\n }\n /**\n * Alias for disconnect()\n *\n * @return self\n * @public\n */ \n close() {\n return this.disconnect();\n }\n /**\n * Sets the compress flag.\n *\n * @param compress - if `true`, compresses the s ending data\n * @return self\n * @public\n */\n compress(compress ) {\n this.flags.compress = compress;\n return this;\n }\n / **\n * Sets a modifier for a subsequent event emission that the event messag e will be dropped when this socket is not\n * ready to send messages.\n *\n * @returns self\n * @public\n */\n get volatile() {\n this.flags.volatile = true;\n return this;\n }\n /**\n * Sets a modifier for a subsequent event emission that the callback will be called with an error when the\n * given number of milliseconds have elapsed without an a cknowledgement from the server:\n *\n * ```\n * socket.timeout(5000) .emit(\"my-event\", (err) => {\n * if (err) {\n * // the server di d not acknowledge the event in the given delay\n * }\n * });\n * ` ``\n *\n * @returns self\n * @public\n */\n timeout(timeout) {\n this.flags.timeout = timeout;\n return this;\n }\n /**\n * Adds a listener that will be fired when any event is emitted. The event n ame is passed as the first argument to the\n * callback.\n *\n * @pa ram listener\n * @public\n */\n onAny(listener) {\n this._anyL isteners = this._anyListeners || [];\n this._anyListeners.push(listener); \n return this;\n }\n /**\n * Adds a listener that will be fire d when any event is emitted. The event name is passed as the first argument to t he\n * callback. The listener is added to the beginning of the listeners arr ay.\n *\n * @param listener\n * @public\n */\n prependAny(lis tener) {\n this._anyListeners = this._anyListeners || [];\n this._ anyListeners.unshift(listener);\n return this;\n }\n /**\n * Re moves the listener that will be fired when any event is emitted.\n *\n * @param listener\n * @public\n */\n offAny(listener) {\n if (! this._anyListeners) {\n return this;\n }\n if (listener ) {\n const listeners = this._anyListeners;\n for (let i = 0; i < listeners.length; i++) {\n if (listener === listeners[i]) {\n listeners.splice(i, 1);\n return this ;\n }\n }\n }\n else {\n this ._anyListeners = [];\n }\n return this;\n }\n /**\n * Re turns an array of listeners that are listening for any event that is specified. This array can be manipulated,\n * e.g. to remove listeners.\n *\n * @public\n */\n listenersAny() {\n return this._anyListeners || [] ;\n }\n /**\n * Adds a listener that will be fired when any event is e mitted. The event name is passed as the first argument to the\n * callback.\ n *\n * @param listener\n *\n * <pre><code>\n *\n * sock et.onAnyOutgoing((event, ...args) => {\n * console.log(event);\n * }); \n *\n * </pre></code>\n *\n * @public\n */\n onAnyOutgoi ng(listener) {\n this._anyOutgoingListeners = this._anyOutgoingListeners || [];\n this._anyOutgoingListeners.push(listener);\n return this; \n }\n /**\n * Adds a listener that will be fired when any event is em itted. The event name is passed as the first argument to the\n * callback. T he listener is added to the beginning of the listeners array.\n *\n * @p aram listener\n *\n * <pre><code>\n *\n * socket.prependAnyOutgo ing((event, ...args) => {\n * console.log(event);\n * });\n *\n * </pre></code>\n *\n * @public\n */\n prependAnyOutgoing(liste ner) {\n this._anyOutgoingListeners = this._anyOutgoingListeners || [];\n this._anyOutgoingListeners.unshift(listener);\n return this;\n }\n /**\n * Removes the listener that will be fired when any event is em itted.\n *\n * @param listener\n *\n * <pre><code>\n *\n * const handler = (event, ...args) => {\n * console.log(event);\n * } \n *\n * socket.onAnyOutgoing(handler);\n *\n * // then later\n * socket.offAnyOutgoing(handler);\n *\n * </pre></code>\n *\n * @public\n */\n offAnyOutgoing(listener) {\n if (!this._anyOutg oingListeners) {\n return this;\n }\n if (listener) {\n const listeners = this._anyOutgoingListeners;\n for (let i = 0; i < listeners.length; i++) {\n if (listener === listeners[ i]) {\n listeners.splice(i, 1);\n return t his;\n }\n }\n }\n else {\n t his._anyOutgoingListeners = [];\n }\n return this;\n }\n /** \n * Returns an array of listeners that are listening for any event that is specified. This array can be manipulated,\n * e.g. to remove listeners.\n *\n * @public\n */\n listenersAnyOutgoing() {\n return this. _anyOutgoingListeners || [];\n }\n /**\n * Notify the listeners for ea ch packet sent\n *\n * @param packet\n *\n * @private\n */\n notifyOutgoingListeners(packet) {\n if (this._anyOutgoingListeners && this._anyOutgoingListeners.length) {\n const listeners = this._anyOu tgoingListeners.slice();\n for (const listener of listeners) {\n listener.apply(this, packet.data);\n }\n }\n }\n }\n","/**\n * Initialize backoff timer with `opts`.\n *\n * - `min` initial time out in milliseconds [100]\n * - `max` max timeout [10000]\n * - `jitter` [0]\n * - `factor` [2]\n *\n * @param {Object} opts\n * @api public\n */\nexport functi on Backoff(opts) {\n opts = opts || {};\n this.ms = opts.min || 100;\n this.max = opts.max || 10000;\n this.factor = opts.factor || 2;\n this.jit ter = opts.jitter > 0 && opts.jitter <= 1 ? opts.jitter : 0;\n this.attempts = 0;\n}\n/**\n * Return the backoff duration.\n *\n * @return {Number}\n * @api public\n */\nBackoff.prototype.duration = function () {\n var ms = this.ms * Math.pow(this.factor, this.attempts++);\n if (this.jitter) {\n var ran d = Math.random();\n var deviation = Math.floor(rand * this.jitter * ms); \n ms = (Math.floor(rand * 10) & 1) == 0 ? ms - deviation : ms + deviatio n;\n }\n return Math.min(ms, this.max) | 0;\n};\n/**\n * Reset the number of attempts.\n *\n * @api public\n */\nBackoff.prototype.reset = function () {\n this.attempts = 0;\n};\n/**\n * Set the minimum duration\n *\n * @api public \n */\nBackoff.prototype.setMin = function (min) {\n this.ms = min;\n};\n/**\ n * Set the maximum duration\n *\n * @api public\n */\nBackoff.prototype.setMax = function (max) {\n this.max = max;\n};\n/**\n * Set the jitter\n *\n * @api public\n */\nBackoff.prototype.setJitter = function (jitter) {\n this.jitter = jitter;\n};\n","import { Socket as Engine, installTimerFunctions, } from \"en gine.io-client\";\nimport { Socket } from \"./socket.js\";\nimport * as parser f rom \"socket.io-parser\";\nimport { on } from \"./on.js\";\nimport { Backoff } f rom \"./contrib/backo2.js\";\nimport { Emitter, } from \"@socket.io/component-em itter\";\nexport class Manager extends Emitter {\n constructor(uri, opts) {\n var _a;\n super();\n this.nsps = {};\n this.subs = [];\n if (uri && \"object\" === typeof uri) {\n opts = uri;\n uri = undefined;\n }\n opts = opts || {};\n opts .path = opts.path || \"/socket.io\";\n this.opts = opts;\n install TimerFunctions(this, opts);\n this.reconnection(opts.reconnection !== fal se);\n this.reconnectionAttempts(opts.reconnectionAttempts || Infinity);\ n this.reconnectionDelay(opts.reconnectionDelay || 1000);\n this.r econnectionDelayMax(opts.reconnectionDelayMax || 5000);\n this.randomizat ionFactor((_a = opts.randomizationFactor) !== null && _a !== void 0 ? _a : 0.5); \n this.backoff = new Backoff({\n min: this.reconnectionDelay( ),\n max: this.reconnectionDelayMax(),\n jitter: this.rand omizationFactor(),\n });\n this.timeout(null == opts.timeout ? 200 00 : opts.timeout);\n this._readyState = \"closed\";\n this.uri = uri;\n const _parser = opts.parser || parser;\n this.encoder = new _parser.Encoder();\n this.decoder = new _parser.Decoder();\n this ._autoConnect = opts.autoConnect !== false;\n if (this._autoConnect)\n this.open();\n }\n reconnection(v) {\n if (!arguments.leng th)\n return this._reconnection;\n this._reconnection = !!v;\n return this;\n }\n reconnectionAttempts(v) {\n if (v === un defined)\n return this._reconnectionAttempts;\n this._reconnec tionAttempts = v;\n return this;\n }\n reconnectionDelay(v) {\n var _a;\n if (v === undefined)\n return this._reconnection Delay;\n this._reconnectionDelay = v;\n (_a = this.backoff) === nu ll || _a === void 0 ? void 0 : _a.setMin(v);\n return this;\n }\n r andomizationFactor(v) {\n var _a;\n if (v === undefined)\n return this._randomizationFactor;\n this._randomizationFactor = v;\n (_a = this.backoff) === null || _a === void 0 ? void 0 : _a.setJitter(v); \n return this;\n }\n reconnectionDelayMax(v) {\n var _a;\n if (v === undefined)\n return this._reconnectionDelayMax;\n this._reconnectionDelayMax = v;\n (_a = this.backoff) === null || _a === void 0 ? void 0 : _a.setMax(v);\n return this;\n }\n timeout(v ) {\n if (!arguments.length)\n return this._timeout;\n this._timeout = v;\n return this;\n }\n /**\n * Starts trying t o reconnect if reconnection is enabled and we have not\n * started reconnect ing yet\n *\n * @private\n */\n maybeReconnectOnOpen() {\n // Only try to reconnect if it's the first time we're connecting\n if (! this._reconnecting &&\n this._reconnection &&\n this.backo ff.attempts === 0) {\n // keeps reconnection from firing twice for th e same reconnection loop\n this.reconnect();\n }\n }\n / **\n * Sets the current transport `socket`.\n *\n * @param {Function } fn - optional, callback\n * @return self\n * @public\n */\n ope n(fn) {\n if (~this._readyState.indexOf(\"open\"))\n return th is;\n this.engine = new Engine(this.uri, this.opts);\n const socke t = this.engine;\n const self = this;\n this._readyState = \"openi ng\";\n this.skipReconnect = false;\n // emit `open`\n cons t openSubDestroy = on(socket, \"open\", function () {\n self.onopen() ;\n fn && fn();\n });\n // emit `error`\n const errorSub = on(socket, \"error\", (err) => {\n self.cleanup();\n self._readyState = \"closed\";\n this.emitReserved(\"error\", e rr);\n if (fn) {\n fn(err);\n }\n else {\n // Only do this if there is no fn to handle the error\ n self.maybeReconnectOnOpen();\n }\n });\n if (false !== this._timeout) {\n const timeout = this._timeout;\n if (timeout === 0) {\n openSubDestroy(); // prevents a race condition with the 'open' event\n }\n // set timer\n const timer = this.setTimeoutFn(() => {\n openSubDest roy();\n socket.close();\n // @ts-ignore\n socket.emit(\"error\", new Error(\"timeout\"));\n }, timeout) ;\n if (this.opts.autoUnref) {\n timer.unref();\n }\n this.subs.push(function subDestroy() {\n cl earTimeout(timer);\n });\n }\n this.subs.push(openSubDe stroy);\n this.subs.push(errorSub);\n return this;\n }\n /** \n * Alias for open()\n *\n * @return self\n * @public\n */\ n connect(fn) {\n return this.open(fn);\n }\n /**\n * Called upon transport open.\n *\n * @private\n */\n onopen() {\n // clear old subs\n this.cleanup();\n // mark as open\n th is._readyState = \"open\";\n this.emitReserved(\"open\");\n // add new subs\n const socket = this.engine;\n this.subs.push(on(socket , \"ping\", this.onping.bind(this)), on(socket, \"data\", this.ondata.bind(this) ), on(socket, \"error\", this.onerror.bind(this)), on(socket, \"close\", this.on close.bind(this)), on(this.decoder, \"decoded\", this.ondecoded.bind(this)));\n }\n /**\n * Called upon a ping.\n *\n * @private\n */\n onping() {\n this.emitReserved(\"ping\");\n }\n /**\n * Called with data.\n *\n * @private\n */\n ondata(data) {\n try { \n this.decoder.add(data);\n }\n catch (e) {\n this.onclose(\"parse error\");\n }\n }\n /**\n * Called when parser fully decodes a packet.\n *\n * @private\n */\n ondecoded (packet) {\n this.emitReserved(\"packet\", packet);\n }\n /**\n * Called upon socket error.\n *\n * @private\n */\n onerror(err) {\n this.emitReserved(\"error\", err);\n }\n /**\n * Creates a new socket for the given `nsp`.\n *\n * @return {Socket}\n * @publi c\n */\n socket(nsp, opts) {\n let socket = this.nsps[nsp];\n if (!socket) {\n socket = new Socket(this, nsp, opts);\n this.nsps[nsp] = socket;\n }\n return socket;\n }\n /**\n * Called upon a socket close.\n *\n * @param socket\n * @private \n */\n _destroy(socket) {\n const nsps = Object.keys(this.nsps);\ n for (const nsp of nsps) {\n const socket = this.nsps[nsp];\n if (socket.active) {\n return;\n }\n }\n this._close();\n }\n /**\n * Writes a packet.\n *\n * @param packet\n * @private\n */\n _packet(packet) {\n con st encodedPackets = this.encoder.encode(packet);\n for (let i = 0; i < en codedPackets.length; i++) {\n this.engine.write(encodedPackets[i], pa cket.options);\n }\n }\n /**\n * Clean up transport subscriptio ns and packet buffer.\n *\n * @private\n */\n cleanup() {\n this.subs.forEach((subDestroy) => subDestroy());\n this.subs.length = 0 ;\n this.decoder.destroy();\n }\n /**\n * Close the current soc ket.\n *\n * @private\n */\n _close() {\n this.skipReconne ct = true;\n this._reconnecting = false;\n this.onclose(\"forced c lose\");\n if (this.engine)\n this.engine.close();\n }\n /**\n * Alias for close()\n *\n * @private\n */\n disconnect () {\n return this._close();\n }\n /**\n * Called upon engine c lose.\n *\n * @private\n */\n onclose(reason, description) {\n this.cleanup();\n this.backoff.reset();\n this._readyState = \"closed\";\n this.emitReserved(\"close\", reason, description);\n if (this._reconnection && !this.skipReconnect) {\n this.reconnect(); \n }\n }\n /**\n * Attempt a reconnection.\n *\n * @pri vate\n */\n reconnect() {\n if (this._reconnecting || this.skipRec onnect)\n return this;\n const self = this;\n if (this. backoff.attempts >= this._reconnectionAttempts) {\n this.backoff.rese t();\n this.emitReserved(\"reconnect_failed\");\n this._re connecting = false;\n }\n else {\n const delay = this.b ackoff.duration();\n this._reconnecting = true;\n const ti mer = this.setTimeoutFn(() => {\n if (self.skipReconnect)\n return;\n this.emitReserved(\"reconnect_attempt\", self.backoff.attempts);\n // check again for the case socket clos ed in above events\n if (self.skipReconnect)\n return;\n self.open((err) => {\n if (err) {\n self._reconnecting = false;\n sel f.reconnect();\n this.emitReserved(\"reconnect_error\", e rr);\n }\n else {\n self.onreconnect();\n }\n });\n }, delay);\n if (this.opts.autoUnref) {\n timer.unref(); \n }\n this.subs.push(function subDestroy() {\n clearTimeout(timer);\n });\n }\n }\n /**\n * Ca lled upon successful reconnect.\n *\n * @private\n */\n onreconne ct() {\n const attempt = this.backoff.attempts;\n this._reconnecti ng = false;\n this.backoff.reset();\n this.emitReserved(\"reconnec t\", attempt);\n }\n}\n","import { url } from \"./url.js\";\nimport { Manager } from \"./manager.js\";\nimport { Socket } from \"./socket.js\";\n/**\n * Mana gers cache.\n */\nconst cache = {};\nfunction lookup(uri, opts) {\n if (typeo f uri === \"object\") {\n opts = uri;\n uri = undefined;\n }\n opts = opts || {};\n const parsed = url(uri, opts.path || \"/socket.io\"); \n const source = parsed.source;\n const id = parsed.id;\n const path = parsed.path;\n const sameNamespace = cache[id] && path in cache[id][\"nsps\" ];\n const newConnection = opts.forceNew ||\n opts[\"force new connect ion\"] ||\n false === opts.multiplex ||\n sameNamespace;\n let io;\n if (newConnection) {\n io = new Manager(source, opts);\n }\n else {\n if (!cache[id]) {\n cache[id] = new Manager(source , opts);\n }\n io = cache[id];\n }\n if (parsed.query && !op ts.query) {\n opts.query = parsed.queryKey;\n }\n return io.socket( parsed.path, opts);\n}\n// so that \"lookup\" can be used both as a function (e. g. `io(...)`) and as a\n// namespace (e.g. `io.connect(...)`), for backward comp atibility\nObject.assign(lookup, {\n Manager,\n Socket,\n io: lookup,\n connect: lookup,\n});\n/**\n * Protocol version.\n *\n * @public\n */\nexpor t { protocol } from \"socket.io-parser\";\n/**\n * Expose constructors for stand alone build.\n *\n * @public\n */\nexport { Manager, Socket, lookup as io, looku p as connect, lookup as default, };\n","import { parse } from \"engine.io-client \";\n/**\n * URL parser.\n *\n * @param uri - url\n * @param path - the request path of the connection\n * @param loc - An object meant to mimic window.location .\n * Defaults to window.location.\n * @public\n */\nexport function url( uri, path = \"\", loc) {\n let obj = uri;\n // default to window.location\ n loc = loc || (typeof location !== \"undefined\" && location);\n if (null == uri)\n uri = loc.protocol + \"//\" + loc.host;\n // relative path support\n if (typeof uri === \"string\") {\n if (\"/\" === uri.charAt( 0)) {\n if (\"/\" === uri.charAt(1)) {\n uri = loc.pro tocol + uri;\n }\n else {\n uri = loc.host + uri;\n }\n }\n if (!/^(https?|wss?):\\/\\//.test(uri) ) {\n if (\"undefined\" !== typeof loc) {\n uri = loc. protocol + \"//\" + uri;\n }\n else {\n uri = \"https://\" + uri;\n }\n }\n // parse\n obj = parse(uri);\n }\n // make sure we treat `localhost:80` and `localhost` e qually\n if (!obj.port) {\n if (/^(http|ws)$/.test(obj.protocol)) {\n obj.port = \"80\";\n }\n else if (/^(http|ws)s$/.test(o bj.protocol)) {\n obj.port = \"443\";\n }\n }\n obj.path = obj.path || \"/\";\n const ipv6 = obj.host.indexOf(\":\") !== -1;\n con st host = ipv6 ? \"[\" + obj.host + \"]\" : obj.host;\n // define unique id\n obj.id = obj.protocol + \"://\" + host + \":\" + obj.port + path;\n // de fine href\n obj.href =\n obj.protocol +\n \"://\" +\n host +\n (loc && loc.port === obj.port ? \"\" : \":\" + obj.por t);\n return obj;\n}\n"],"names":["PACKET_TYPES","Object","create","PACKET_TY PES_REVERSE","keys","forEach","key","ERROR_PACKET","type","data","withNativeBlob ","Blob","prototype","toString","call","withNativeArrayBuffer","ArrayBuffer","en codePacket","supportsBinary","callback","encodeBlobAsBase64","obj","isView","buf fer","fileReader","FileReader","onload","content","result","split","readAsDataUR L","chars","lookup","Uint8Array","i","length","charCodeAt","decodePacket","encod edPacket","binaryType","mapBinary","charAt","decodeBase64Packet","substring","de coded","base64","encoded1","encoded2","encoded3","encoded4","bufferLength","len" ,"p","arraybuffer","bytes","decode","SEPARATOR","String","fromCharCode","Emitter ","mixin","on","addEventListener","event","fn","this","_callbacks","push","once" ,"off","apply","arguments","removeListener","removeAllListeners","removeEventLis tener","cb","callbacks","splice","emit","args","Array","slice","emitReserved","l isteners","hasListeners","globalThisShim","self","window","Function","pick","att r","reduce","acc","k","hasOwnProperty","NATIVE_SET_TIMEOUT","setTimeout","NATIVE _CLEAR_TIMEOUT","clearTimeout","installTimerFunctions","opts","useNativeTimers", "setTimeoutFn","bind","globalThis","clearTimeoutFn","TransportError","Error","co nstructor","reason","description","context","super","Transport","writable","quer y","readyState","socket","onError","open","doOpen","close","doClose","onClose"," send","packets","write","onOpen","onData","packet","onPacket","details","alphabe t","map","prev","seed","encode","num","encoded","Math","floor","yeast","now","Da te","str","encodeURIComponent","value","XMLHttpRequest","err","hasCORS","XHR","x domain","e","concat","join","empty","hasXHR2","responseType","Request","uri","me thod","async","undefined","xd","xscheme","xs","xhr","extraHeaders","setDisableHe aderCheck","setRequestHeader","withCredentials","requestTimeout","timeout","onre adystatechange","status","onLoad","document","index","requestsCount","requests", "cleanup","fromError","abort","responseText","attachEvent","unloadHandler","next Tick","Promise","resolve","then","WebSocket","MozWebSocket","isReactNative","nav igator","product","toLowerCase","transports","websocket","forceBase64","name","c heck","protocols","headers","ws","addEventListeners","onopen","autoUnref","_sock et","unref","onclose","closeEvent","onmessage","ev","onerror","lastPacket","sche ma","secure","port","Number","timestampRequests","timestampParam","b64","encoded Query","hostname","indexOf","path","polling","location","isSSL","protocol","poll ","pause","onPause","total","doPoll","encodedPayload","encodedPackets","decodedP acket","decodePayload","count","encodePayload","doWrite","sid","request","assign ","req","xhrStatus","pollXhr","re","parts","parse","src","b","replace","m","exec ","source","host","authority","ipv6uri","pathNames","regx","names","substr","que ryKey","$0","$1","$2","Socket","writeBuffer","prevBufferLen","agent","upgrade"," rememberUpgrade","rejectUnauthorized","perMessageDeflate","threshold","transport Options","closeOnBeforeunload","qs","qry","pairs","l","pair","decodeURIComponent ","id","upgrades","pingInterval","pingTimeout","pingTimeoutTimer","transport","o fflineEventListener","createTransport","EIO","priorWebsocketSuccess","shift","se tTransport","onDrain","probe","failed","onTransportOpen","msg","upgrading","flus h","freezeTransport","error","onTransportClose","onupgrade","to","onHandshake"," JSON","resetPingTimeout","sendPacket","code","filterUpgrades","maxPayload","getW ritablePackets","payloadSize","c","utf8Length","ceil","byteLength","size","optio ns","compress","cleanupAndClose","waitForUpgrade","filteredUpgrades","j","withNa tiveFile","File","isBinary","hasBinary","toJSON","isArray","deconstructPacket"," buffers","packetData","pack","_deconstructPacket","attachments","placeholder","_ placeholder","newData","reconstructPacket","_reconstructPacket","PacketType","De coder","reviver","add","decodeString","BINARY_EVENT","BINARY_ACK","reconstructor ","BinaryReconstructor","takeBinaryData","start","buf","nsp","next","payload","t ryParse","isPayloadValid","static","CONNECT","DISCONNECT","CONNECT_ERROR","EVENT ","ACK","destroy","finishedReconstruction","reconPack","binData","replacer","enc odeAsString","encodeAsBinary","stringify","deconstruction","unshift","RESERVED_E VENTS","freeze","connect","connect_error","disconnect","disconnecting","newListe ner","io","connected","receiveBuffer","sendBuffer","ids","acks","flags","auth"," _autoConnect","disconnected","subEvents","subs","onpacket","active","_readyState ","ack","pop","_registerAckCallback","isTransportWritable","engine","volatile"," notifyOutgoingListeners","timer","_packet","onconnect","onevent","onack","ondisc onnect","message","emitEvent","_anyListeners","listener","sent","emitBuffered"," subDestroy","onAny","prependAny","offAny","listenersAny","onAnyOutgoing","_anyOu tgoingListeners","prependAnyOutgoing","offAnyOutgoing","listenersAnyOutgoing","B ackoff","ms","min","max","factor","jitter","attempts","duration","pow","rand","r andom","deviation","reset","setMin","setMax","setJitter","Manager","_a","nsps"," reconnection","reconnectionAttempts","Infinity","reconnectionDelay","reconnectio nDelayMax","randomizationFactor","backoff","_parser","parser","encoder","Encoder ","decoder","autoConnect","v","_reconnection","_reconnectionAttempts","_reconnec tionDelay","_randomizationFactor","_reconnectionDelayMax","_timeout","maybeRecon nectOnOpen","_reconnecting","reconnect","Engine","skipReconnect","openSubDestroy ","errorSub","onping","ondata","ondecoded","_destroy","_close","delay","onreconn ect","attempt","cache","parsed","loc","test","href","url","sameNamespace","force New","multiplex"],"mappings":";;;;;AAAA,MAAMA,EAAeC,OAAOC,OAAO,MACnCF,EAAmB,KAAI ,IACvBA,EAAoB,MAAI,IACxBA,EAAmB,KAAI,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ExD5M,EAAImd,KACAnd,EAAIgN,SACA,MACA4B,GACCqO,GAAOA,EA AI7Q,OAASpM,EAAIoM,KAAO,GAAK,IAAMpM,EAAIoM,MAChDpM,ED5CQod,CAAI1U,GADnB3D,EAAOA, GAAQ,IACc6H,MAAQ,cAC/B+B,EAASqO,EAAOrO,OAChB6B,EAAKwM,EAAOxM,GACZ5D,EAAOoQ,EAAOp Q,KACdyQ,EAAgBN,GAAMvM,IAAO5D,KAAQmQ,GAAMvM,GAAU,KAK3D,IAAIqG,EAaJ,OAjBsB9R,EAAK uY,UACvBvY,EAAK,0BACL,IAAUA,EAAKwY,WACfF,EAGAxG,EAAK,IAAI4D,GAAQ9L,EAAQ5J,IAGpBg Y,GAAMvM,KACPuM,GAAMvM,GAAM,IAAIiK,GAAQ9L,EAAQ5J,IAEpC8R,EAAKkG,GAAMvM,IAEXwM,EA AOlX,QAAUf,EAAKe,QACtBf,EAAKe,MAAQkX,EAAO7N,UAEjB0H,EAAG7Q,OAAOgX,EAAOpQ,KAAM7H, GAIlCnG,OAAOmP,OAAOpN,GAAQ,CAClB8Z,WACAlL,UACAsH,GAAIlW,GACJ6V,QAAS7V"}
 End of changes. 1 change blocks. 
lines changed or deleted lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)