作者 宋国杰

sgj

... ... @@ -80,14 +80,14 @@
.poster-img {
border-radius: 16rpx;
height: 700rpx;
height: 630rpx;
width: 600rpx;
}
.btn-wrap {
.save-btn {
width: 600rpx;
height: 72rpx;
margin-left: 20rpx;
text-align: center;
line-height: 72rpx;
margin-top: 20rpx;
... ...
{
"hash": "e1f86111",
"browserHash": "e5aba368",
"hash": "65eb0560",
"browserHash": "a8e0fdec",
"optimized": {
"uview-plus": {
"src": "../../uview-plus/index.js",
"file": "uview-plus.js",
"fileHash": "4fb9748b",
"fileHash": "53a100fc",
"needsInterop": false
},
"event-source-polyfill": {
"src": "../../event-source-polyfill/src/eventsource.js",
"file": "event-source-polyfill.js",
"fileHash": "d472ec4b",
"fileHash": "fea7ada0",
"needsInterop": true
}
},
... ...
var __getOwnPropNames = Object.getOwnPropertyNames;
var __commonJS = (cb, mod) => function __require() {
return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
};
export {
__commonJS
};
//# sourceMappingURL=chunk-RSJERJUL.js.map
... ...
{
"version": 3,
"sources": [],
"sourcesContent": [],
"mappings": "",
"names": []
}
... ...
import {
__commonJS
} from "./chunk-RSJERJUL.js";
// ../../../../uni/ai-dialogue/node_modules/event-source-polyfill/src/eventsource.js
var require_eventsource = __commonJS({
"../../../../uni/ai-dialogue/node_modules/event-source-polyfill/src/eventsource.js"(exports, module) {
(function(global) {
"use strict";
var setTimeout = global.setTimeout;
var clearTimeout = global.clearTimeout;
var XMLHttpRequest = global.XMLHttpRequest;
var XDomainRequest = global.XDomainRequest;
var ActiveXObject = global.ActiveXObject;
var NativeEventSource = global.EventSource;
var document = global.document;
var Promise2 = global.Promise;
var fetch = global.fetch;
var Response = global.Response;
var TextDecoder = global.TextDecoder;
var TextEncoder = global.TextEncoder;
var AbortController = global.AbortController;
if (typeof window !== "undefined" && typeof document !== "undefined" && !("readyState" in document) && document.body == null) {
document.readyState = "loading";
window.addEventListener("load", function(event) {
document.readyState = "complete";
}, false);
}
if (XMLHttpRequest == null && ActiveXObject != null) {
XMLHttpRequest = function() {
return new ActiveXObject("Microsoft.XMLHTTP");
};
}
if (Object.create == void 0) {
Object.create = function(C) {
function F() {
}
F.prototype = C;
return new F();
};
}
if (!Date.now) {
Date.now = function now() {
return (/* @__PURE__ */ new Date()).getTime();
};
}
if (AbortController == void 0) {
var originalFetch2 = fetch;
fetch = function(url, options) {
var signal = options.signal;
return originalFetch2(url, { headers: options.headers, credentials: options.credentials, cache: options.cache }).then(function(response) {
var reader = response.body.getReader();
signal._reader = reader;
if (signal._aborted) {
signal._reader.cancel();
}
return {
status: response.status,
statusText: response.statusText,
headers: response.headers,
body: {
getReader: function() {
return reader;
}
}
};
});
};
AbortController = function() {
this.signal = {
_reader: null,
_aborted: false
};
this.abort = function() {
if (this.signal._reader != null) {
this.signal._reader.cancel();
}
this.signal._aborted = true;
};
};
}
function TextDecoderPolyfill() {
this.bitsNeeded = 0;
this.codePoint = 0;
}
TextDecoderPolyfill.prototype.decode = function(octets) {
function valid(codePoint2, shift, octetsCount2) {
if (octetsCount2 === 1) {
return codePoint2 >= 128 >> shift && codePoint2 << shift <= 2047;
}
if (octetsCount2 === 2) {
return codePoint2 >= 2048 >> shift && codePoint2 << shift <= 55295 || codePoint2 >= 57344 >> shift && codePoint2 << shift <= 65535;
}
if (octetsCount2 === 3) {
return codePoint2 >= 65536 >> shift && codePoint2 << shift <= 1114111;
}
throw new Error();
}
function octetsCount(bitsNeeded2, codePoint2) {
if (bitsNeeded2 === 6 * 1) {
return codePoint2 >> 6 > 15 ? 3 : codePoint2 > 31 ? 2 : 1;
}
if (bitsNeeded2 === 6 * 2) {
return codePoint2 > 15 ? 3 : 2;
}
if (bitsNeeded2 === 6 * 3) {
return 3;
}
throw new Error();
}
var REPLACER = 65533;
var string = "";
var bitsNeeded = this.bitsNeeded;
var codePoint = this.codePoint;
for (var i = 0; i < octets.length; i += 1) {
var octet = octets[i];
if (bitsNeeded !== 0) {
if (octet < 128 || octet > 191 || !valid(codePoint << 6 | octet & 63, bitsNeeded - 6, octetsCount(bitsNeeded, codePoint))) {
bitsNeeded = 0;
codePoint = REPLACER;
string += String.fromCharCode(codePoint);
}
}
if (bitsNeeded === 0) {
if (octet >= 0 && octet <= 127) {
bitsNeeded = 0;
codePoint = octet;
} else if (octet >= 192 && octet <= 223) {
bitsNeeded = 6 * 1;
codePoint = octet & 31;
} else if (octet >= 224 && octet <= 239) {
bitsNeeded = 6 * 2;
codePoint = octet & 15;
} else if (octet >= 240 && octet <= 247) {
bitsNeeded = 6 * 3;
codePoint = octet & 7;
} else {
bitsNeeded = 0;
codePoint = REPLACER;
}
if (bitsNeeded !== 0 && !valid(codePoint, bitsNeeded, octetsCount(bitsNeeded, codePoint))) {
bitsNeeded = 0;
codePoint = REPLACER;
}
} else {
bitsNeeded -= 6;
codePoint = codePoint << 6 | octet & 63;
}
if (bitsNeeded === 0) {
if (codePoint <= 65535) {
string += String.fromCharCode(codePoint);
} else {
string += String.fromCharCode(55296 + (codePoint - 65535 - 1 >> 10));
string += String.fromCharCode(56320 + (codePoint - 65535 - 1 & 1023));
}
}
}
this.bitsNeeded = bitsNeeded;
this.codePoint = codePoint;
return string;
};
var supportsStreamOption = function() {
try {
return new TextDecoder().decode(new TextEncoder().encode("test"), { stream: true }) === "test";
} catch (error) {
console.debug("TextDecoder does not support streaming option. Using polyfill instead: " + error);
}
return false;
};
if (TextDecoder == void 0 || TextEncoder == void 0 || !supportsStreamOption()) {
TextDecoder = TextDecoderPolyfill;
}
var k = function() {
};
function XHRWrapper(xhr) {
this.withCredentials = false;
this.readyState = 0;
this.status = 0;
this.statusText = "";
this.responseText = "";
this.onprogress = k;
this.onload = k;
this.onerror = k;
this.onreadystatechange = k;
this._contentType = "";
this._xhr = xhr;
this._sendTimeout = 0;
this._abort = k;
}
XHRWrapper.prototype.open = function(method, url) {
this._abort(true);
var that = this;
var xhr = this._xhr;
var state = 1;
var timeout = 0;
this._abort = function(silent) {
if (that._sendTimeout !== 0) {
clearTimeout(that._sendTimeout);
that._sendTimeout = 0;
}
if (state === 1 || state === 2 || state === 3) {
state = 4;
xhr.onload = k;
xhr.onerror = k;
xhr.onabort = k;
xhr.onprogress = k;
xhr.onreadystatechange = k;
xhr.abort();
if (timeout !== 0) {
clearTimeout(timeout);
timeout = 0;
}
if (!silent) {
that.readyState = 4;
that.onabort(null);
that.onreadystatechange();
}
}
state = 0;
};
var onStart = function() {
if (state === 1) {
var status = 0;
var statusText = "";
var contentType = void 0;
if (!("contentType" in xhr)) {
try {
status = xhr.status;
statusText = xhr.statusText;
contentType = xhr.getResponseHeader("Content-Type");
} catch (error) {
status = 0;
statusText = "";
contentType = void 0;
}
} else {
status = 200;
statusText = "OK";
contentType = xhr.contentType;
}
if (status !== 0) {
state = 2;
that.readyState = 2;
that.status = status;
that.statusText = statusText;
that._contentType = contentType;
that.onreadystatechange();
}
}
};
var onProgress = function() {
onStart();
if (state === 2 || state === 3) {
state = 3;
var responseText = "";
try {
responseText = xhr.responseText;
} catch (error) {
}
that.readyState = 3;
that.responseText = responseText;
that.onprogress();
}
};
var onFinish = function(type, event) {
if (event == null || event.preventDefault == null) {
event = {
preventDefault: k
};
}
onProgress();
if (state === 1 || state === 2 || state === 3) {
state = 4;
if (timeout !== 0) {
clearTimeout(timeout);
timeout = 0;
}
that.readyState = 4;
if (type === "load") {
that.onload(event);
} else if (type === "error") {
that.onerror(event);
} else if (type === "abort") {
that.onabort(event);
} else {
throw new TypeError();
}
that.onreadystatechange();
}
};
var onReadyStateChange = function(event) {
if (xhr != void 0) {
if (xhr.readyState === 4) {
if (!("onload" in xhr) || !("onerror" in xhr) || !("onabort" in xhr)) {
onFinish(xhr.responseText === "" ? "error" : "load", event);
}
} else if (xhr.readyState === 3) {
if (!("onprogress" in xhr)) {
onProgress();
}
} else if (xhr.readyState === 2) {
onStart();
}
}
};
var onTimeout = function() {
timeout = setTimeout(function() {
onTimeout();
}, 500);
if (xhr.readyState === 3) {
onProgress();
}
};
if ("onload" in xhr) {
xhr.onload = function(event) {
onFinish("load", event);
};
}
if ("onerror" in xhr) {
xhr.onerror = function(event) {
onFinish("error", event);
};
}
if ("onabort" in xhr) {
xhr.onabort = function(event) {
onFinish("abort", event);
};
}
if ("onprogress" in xhr) {
xhr.onprogress = onProgress;
}
if ("onreadystatechange" in xhr) {
xhr.onreadystatechange = function(event) {
onReadyStateChange(event);
};
}
if ("contentType" in xhr || !("ontimeout" in XMLHttpRequest.prototype)) {
url += (url.indexOf("?") === -1 ? "?" : "&") + "padding=true";
}
xhr.open(method, url, true);
if ("readyState" in xhr) {
timeout = setTimeout(function() {
onTimeout();
}, 0);
}
};
XHRWrapper.prototype.abort = function() {
this._abort(false);
};
XHRWrapper.prototype.getResponseHeader = function(name) {
return this._contentType;
};
XHRWrapper.prototype.setRequestHeader = function(name, value) {
var xhr = this._xhr;
if ("setRequestHeader" in xhr) {
xhr.setRequestHeader(name, value);
}
};
XHRWrapper.prototype.getAllResponseHeaders = function() {
return this._xhr.getAllResponseHeaders != void 0 ? this._xhr.getAllResponseHeaders() || "" : "";
};
XHRWrapper.prototype.send = function() {
if ((!("ontimeout" in XMLHttpRequest.prototype) || !("sendAsBinary" in XMLHttpRequest.prototype) && !("mozAnon" in XMLHttpRequest.prototype)) && document != void 0 && document.readyState != void 0 && document.readyState !== "complete") {
var that = this;
that._sendTimeout = setTimeout(function() {
that._sendTimeout = 0;
that.send();
}, 4);
return;
}
var xhr = this._xhr;
if ("withCredentials" in xhr) {
xhr.withCredentials = this.withCredentials;
}
try {
xhr.send(void 0);
} catch (error1) {
throw error1;
}
};
function toLowerCase(name) {
return name.replace(/[A-Z]/g, function(c) {
return String.fromCharCode(c.charCodeAt(0) + 32);
});
}
function HeadersPolyfill(all) {
var map = /* @__PURE__ */ Object.create(null);
var array = all.split("\r\n");
for (var i = 0; i < array.length; i += 1) {
var line = array[i];
var parts = line.split(": ");
var name = parts.shift();
var value = parts.join(": ");
map[toLowerCase(name)] = value;
}
this._map = map;
}
HeadersPolyfill.prototype.get = function(name) {
return this._map[toLowerCase(name)];
};
if (XMLHttpRequest != null && XMLHttpRequest.HEADERS_RECEIVED == null) {
XMLHttpRequest.HEADERS_RECEIVED = 2;
}
function XHRTransport() {
}
XHRTransport.prototype.open = function(xhr, onStartCallback, onProgressCallback, onFinishCallback, url, withCredentials, headers) {
xhr.open("GET", url);
var offset = 0;
xhr.onprogress = function() {
var responseText = xhr.responseText;
var chunk = responseText.slice(offset);
offset += chunk.length;
onProgressCallback(chunk);
};
xhr.onerror = function(event) {
event.preventDefault();
onFinishCallback(new Error("NetworkError"));
};
xhr.onload = function() {
onFinishCallback(null);
};
xhr.onabort = function() {
onFinishCallback(null);
};
xhr.onreadystatechange = function() {
if (xhr.readyState === XMLHttpRequest.HEADERS_RECEIVED) {
var status = xhr.status;
var statusText = xhr.statusText;
var contentType = xhr.getResponseHeader("Content-Type");
var headers2 = xhr.getAllResponseHeaders();
onStartCallback(status, statusText, contentType, new HeadersPolyfill(headers2));
}
};
xhr.withCredentials = withCredentials;
for (var name in headers) {
if (Object.prototype.hasOwnProperty.call(headers, name)) {
xhr.setRequestHeader(name, headers[name]);
}
}
xhr.send();
return xhr;
};
function HeadersWrapper(headers) {
this._headers = headers;
}
HeadersWrapper.prototype.get = function(name) {
return this._headers.get(name);
};
function FetchTransport() {
}
FetchTransport.prototype.open = function(xhr, onStartCallback, onProgressCallback, onFinishCallback, url, withCredentials, headers) {
var reader = null;
var controller = new AbortController();
var signal = controller.signal;
var textDecoder = new TextDecoder();
fetch(url, {
headers,
credentials: withCredentials ? "include" : "same-origin",
signal,
cache: "no-store"
}).then(function(response) {
reader = response.body.getReader();
onStartCallback(response.status, response.statusText, response.headers.get("Content-Type"), new HeadersWrapper(response.headers));
return new Promise2(function(resolve, reject) {
var readNextChunk = function() {
reader.read().then(function(result) {
if (result.done) {
resolve(void 0);
} else {
var chunk = textDecoder.decode(result.value, { stream: true });
onProgressCallback(chunk);
readNextChunk();
}
})["catch"](function(error) {
reject(error);
});
};
readNextChunk();
});
})["catch"](function(error) {
if (error.name === "AbortError") {
return void 0;
} else {
return error;
}
}).then(function(error) {
onFinishCallback(error);
});
return {
abort: function() {
if (reader != null) {
reader.cancel();
}
controller.abort();
}
};
};
function EventTarget() {
this._listeners = /* @__PURE__ */ Object.create(null);
}
function throwError(e) {
setTimeout(function() {
throw e;
}, 0);
}
EventTarget.prototype.dispatchEvent = function(event) {
event.target = this;
var typeListeners = this._listeners[event.type];
if (typeListeners != void 0) {
var length = typeListeners.length;
for (var i = 0; i < length; i += 1) {
var listener = typeListeners[i];
try {
if (typeof listener.handleEvent === "function") {
listener.handleEvent(event);
} else {
listener.call(this, event);
}
} catch (e) {
throwError(e);
}
}
}
};
EventTarget.prototype.addEventListener = function(type, listener) {
type = String(type);
var listeners = this._listeners;
var typeListeners = listeners[type];
if (typeListeners == void 0) {
typeListeners = [];
listeners[type] = typeListeners;
}
var found = false;
for (var i = 0; i < typeListeners.length; i += 1) {
if (typeListeners[i] === listener) {
found = true;
}
}
if (!found) {
typeListeners.push(listener);
}
};
EventTarget.prototype.removeEventListener = function(type, listener) {
type = String(type);
var listeners = this._listeners;
var typeListeners = listeners[type];
if (typeListeners != void 0) {
var filtered = [];
for (var i = 0; i < typeListeners.length; i += 1) {
if (typeListeners[i] !== listener) {
filtered.push(typeListeners[i]);
}
}
if (filtered.length === 0) {
delete listeners[type];
} else {
listeners[type] = filtered;
}
}
};
function Event(type) {
this.type = type;
this.target = void 0;
}
function MessageEvent(type, options) {
Event.call(this, type);
this.data = options.data;
this.lastEventId = options.lastEventId;
}
MessageEvent.prototype = Object.create(Event.prototype);
function ConnectionEvent(type, options) {
Event.call(this, type);
this.status = options.status;
this.statusText = options.statusText;
this.headers = options.headers;
}
ConnectionEvent.prototype = Object.create(Event.prototype);
function ErrorEvent(type, options) {
Event.call(this, type);
this.error = options.error;
}
ErrorEvent.prototype = Object.create(Event.prototype);
var WAITING = -1;
var CONNECTING = 0;
var OPEN = 1;
var CLOSED = 2;
var AFTER_CR = -1;
var FIELD_START = 0;
var FIELD = 1;
var VALUE_START = 2;
var VALUE = 3;
var contentTypeRegExp = /^text\/event\-stream(;.*)?$/i;
var MINIMUM_DURATION = 1e3;
var MAXIMUM_DURATION = 18e6;
var parseDuration = function(value, def) {
var n = value == null ? def : parseInt(value, 10);
if (n !== n) {
n = def;
}
return clampDuration(n);
};
var clampDuration = function(n) {
return Math.min(Math.max(n, MINIMUM_DURATION), MAXIMUM_DURATION);
};
var fire = function(that, f, event) {
try {
if (typeof f === "function") {
f.call(that, event);
}
} catch (e) {
throwError(e);
}
};
function EventSourcePolyfill(url, options) {
EventTarget.call(this);
options = options || {};
this.onopen = void 0;
this.onmessage = void 0;
this.onerror = void 0;
this.url = void 0;
this.readyState = void 0;
this.withCredentials = void 0;
this.headers = void 0;
this._close = void 0;
start(this, url, options);
}
function getBestXHRTransport() {
return XMLHttpRequest != void 0 && "withCredentials" in XMLHttpRequest.prototype || XDomainRequest == void 0 ? new XMLHttpRequest() : new XDomainRequest();
}
var isFetchSupported = fetch != void 0 && Response != void 0 && "body" in Response.prototype;
function start(es, url, options) {
url = String(url);
var withCredentials = Boolean(options.withCredentials);
var lastEventIdQueryParameterName = options.lastEventIdQueryParameterName || "lastEventId";
var initialRetry = clampDuration(1e3);
var heartbeatTimeout = parseDuration(options.heartbeatTimeout, 45e3);
var lastEventId = "";
var retry = initialRetry;
var wasActivity = false;
var textLength = 0;
var headers = options.headers || {};
var TransportOption = options.Transport;
var xhr = isFetchSupported && TransportOption == void 0 ? void 0 : new XHRWrapper(TransportOption != void 0 ? new TransportOption() : getBestXHRTransport());
var transport = TransportOption != null && typeof TransportOption !== "string" ? new TransportOption() : xhr == void 0 ? new FetchTransport() : new XHRTransport();
var abortController = void 0;
var timeout = 0;
var currentState = WAITING;
var dataBuffer = "";
var lastEventIdBuffer = "";
var eventTypeBuffer = "";
var textBuffer = "";
var state = FIELD_START;
var fieldStart = 0;
var valueStart = 0;
var onStart = function(status, statusText, contentType, headers2) {
if (currentState === CONNECTING) {
if (status === 200 && contentType != void 0 && contentTypeRegExp.test(contentType)) {
currentState = OPEN;
wasActivity = Date.now();
retry = initialRetry;
es.readyState = OPEN;
var event = new ConnectionEvent("open", {
status,
statusText,
headers: headers2
});
es.dispatchEvent(event);
fire(es, es.onopen, event);
} else {
var message = "";
if (status !== 200) {
if (statusText) {
statusText = statusText.replace(/\s+/g, " ");
}
message = "EventSource's response has a status " + status + " " + statusText + " that is not 200. Aborting the connection.";
} else {
message = "EventSource's response has a Content-Type specifying an unsupported type: " + (contentType == void 0 ? "-" : contentType.replace(/\s+/g, " ")) + ". Aborting the connection.";
}
close();
var event = new ConnectionEvent("error", {
status,
statusText,
headers: headers2
});
es.dispatchEvent(event);
fire(es, es.onerror, event);
console.error(message);
}
}
};
var onProgress = function(textChunk) {
if (currentState === OPEN) {
var n = -1;
for (var i = 0; i < textChunk.length; i += 1) {
var c = textChunk.charCodeAt(i);
if (c === "\n".charCodeAt(0) || c === "\r".charCodeAt(0)) {
n = i;
}
}
var chunk = (n !== -1 ? textBuffer : "") + textChunk.slice(0, n + 1);
textBuffer = (n === -1 ? textBuffer : "") + textChunk.slice(n + 1);
if (textChunk !== "") {
wasActivity = Date.now();
textLength += textChunk.length;
}
for (var position = 0; position < chunk.length; position += 1) {
var c = chunk.charCodeAt(position);
if (state === AFTER_CR && c === "\n".charCodeAt(0)) {
state = FIELD_START;
} else {
if (state === AFTER_CR) {
state = FIELD_START;
}
if (c === "\r".charCodeAt(0) || c === "\n".charCodeAt(0)) {
if (state !== FIELD_START) {
if (state === FIELD) {
valueStart = position + 1;
}
var field = chunk.slice(fieldStart, valueStart - 1);
var value = chunk.slice(valueStart + (valueStart < position && chunk.charCodeAt(valueStart) === " ".charCodeAt(0) ? 1 : 0), position);
if (field === "data") {
dataBuffer += "\n";
dataBuffer += value;
} else if (field === "id") {
lastEventIdBuffer = value;
} else if (field === "event") {
eventTypeBuffer = value;
} else if (field === "retry") {
initialRetry = parseDuration(value, initialRetry);
retry = initialRetry;
} else if (field === "heartbeatTimeout") {
heartbeatTimeout = parseDuration(value, heartbeatTimeout);
if (timeout !== 0) {
clearTimeout(timeout);
timeout = setTimeout(function() {
onTimeout();
}, heartbeatTimeout);
}
}
}
if (state === FIELD_START) {
if (dataBuffer !== "") {
lastEventId = lastEventIdBuffer;
if (eventTypeBuffer === "") {
eventTypeBuffer = "message";
}
var event = new MessageEvent(eventTypeBuffer, {
data: dataBuffer.slice(1),
lastEventId: lastEventIdBuffer
});
es.dispatchEvent(event);
if (eventTypeBuffer === "open") {
fire(es, es.onopen, event);
} else if (eventTypeBuffer === "message") {
fire(es, es.onmessage, event);
} else if (eventTypeBuffer === "error") {
fire(es, es.onerror, event);
}
if (currentState === CLOSED) {
return;
}
}
dataBuffer = "";
eventTypeBuffer = "";
}
state = c === "\r".charCodeAt(0) ? AFTER_CR : FIELD_START;
} else {
if (state === FIELD_START) {
fieldStart = position;
state = FIELD;
}
if (state === FIELD) {
if (c === ":".charCodeAt(0)) {
valueStart = position + 1;
state = VALUE_START;
}
} else if (state === VALUE_START) {
state = VALUE;
}
}
}
}
}
};
var onFinish = function(error) {
if (currentState === OPEN || currentState === CONNECTING) {
currentState = WAITING;
if (timeout !== 0) {
clearTimeout(timeout);
timeout = 0;
}
timeout = setTimeout(function() {
onTimeout();
}, retry);
retry = clampDuration(Math.min(initialRetry * 16, retry * 2));
es.readyState = CONNECTING;
var event = new ErrorEvent("error", { error });
es.dispatchEvent(event);
fire(es, es.onerror, event);
if (error != void 0) {
console.error(error);
}
}
};
var close = function() {
currentState = CLOSED;
if (abortController != void 0) {
abortController.abort();
abortController = void 0;
}
if (timeout !== 0) {
clearTimeout(timeout);
timeout = 0;
}
es.readyState = CLOSED;
};
var onTimeout = function() {
timeout = 0;
if (currentState !== WAITING) {
if (!wasActivity && abortController != void 0) {
onFinish(new Error("No activity within " + heartbeatTimeout + " milliseconds. " + (currentState === CONNECTING ? "No response received." : textLength + " chars received.") + " Reconnecting."));
if (abortController != void 0) {
abortController.abort();
abortController = void 0;
}
} else {
var nextHeartbeat = Math.max((wasActivity || Date.now()) + heartbeatTimeout - Date.now(), 1);
wasActivity = false;
timeout = setTimeout(function() {
onTimeout();
}, nextHeartbeat);
}
return;
}
wasActivity = false;
textLength = 0;
timeout = setTimeout(function() {
onTimeout();
}, heartbeatTimeout);
currentState = CONNECTING;
dataBuffer = "";
eventTypeBuffer = "";
lastEventIdBuffer = lastEventId;
textBuffer = "";
fieldStart = 0;
valueStart = 0;
state = FIELD_START;
var requestURL = url;
if (url.slice(0, 5) !== "data:" && url.slice(0, 5) !== "blob:") {
if (lastEventId !== "") {
var i = url.indexOf("?");
requestURL = i === -1 ? url : url.slice(0, i + 1) + url.slice(i + 1).replace(/(?:^|&)([^=&]*)(?:=[^&]*)?/g, function(p, paramName) {
return paramName === lastEventIdQueryParameterName ? "" : p;
});
requestURL += (url.indexOf("?") === -1 ? "?" : "&") + lastEventIdQueryParameterName + "=" + encodeURIComponent(lastEventId);
}
}
var withCredentials2 = es.withCredentials;
var requestHeaders = {};
requestHeaders["Accept"] = "text/event-stream";
var headers2 = es.headers;
if (headers2 != void 0) {
for (var name in headers2) {
if (Object.prototype.hasOwnProperty.call(headers2, name)) {
requestHeaders[name] = headers2[name];
}
}
}
try {
abortController = transport.open(xhr, onStart, onProgress, onFinish, requestURL, withCredentials2, requestHeaders);
} catch (error) {
close();
throw error;
}
};
es.url = url;
es.readyState = CONNECTING;
es.withCredentials = withCredentials;
es.headers = headers;
es._close = close;
onTimeout();
}
EventSourcePolyfill.prototype = Object.create(EventTarget.prototype);
EventSourcePolyfill.prototype.CONNECTING = CONNECTING;
EventSourcePolyfill.prototype.OPEN = OPEN;
EventSourcePolyfill.prototype.CLOSED = CLOSED;
EventSourcePolyfill.prototype.close = function() {
this._close();
};
EventSourcePolyfill.CONNECTING = CONNECTING;
EventSourcePolyfill.OPEN = OPEN;
EventSourcePolyfill.CLOSED = CLOSED;
EventSourcePolyfill.prototype.withCredentials = void 0;
var R = NativeEventSource;
if (XMLHttpRequest != void 0 && (NativeEventSource == void 0 || !("withCredentials" in NativeEventSource.prototype))) {
R = EventSourcePolyfill;
}
(function(factory) {
if (typeof module === "object" && typeof module.exports === "object") {
var v = factory(exports);
if (v !== void 0)
module.exports = v;
} else if (typeof define === "function" && define.amd) {
define(["exports"], factory);
} else {
factory(global);
}
})(function(exports2) {
exports2.EventSourcePolyfill = EventSourcePolyfill;
exports2.NativeEventSource = NativeEventSource;
exports2.EventSource = R;
});
})(typeof globalThis === "undefined" ? typeof window !== "undefined" ? window : typeof self !== "undefined" ? self : exports : globalThis);
}
});
export default require_eventsource();
/*! Bundled license information:
event-source-polyfill/src/eventsource.js:
(** @license
* eventsource.js
* Available under MIT License (MIT)
* https://github.com/Yaffle/EventSource/
*)
*/
//# sourceMappingURL=event-source-polyfill.js.map
... ...
{
"version": 3,
"sources": ["../../event-source-polyfill/src/eventsource.js"],
"sourcesContent": ["/** @license\r\n * eventsource.js\r\n * Available under MIT License (MIT)\r\n * https://github.com/Yaffle/EventSource/\r\n */\r\n\r\n/*jslint indent: 2, vars: true, plusplus: true */\r\n/*global setTimeout, clearTimeout */\r\n\r\n(function (global) {\r\n \"use strict\";\r\n\r\n var setTimeout = global.setTimeout;\r\n var clearTimeout = global.clearTimeout;\r\n var XMLHttpRequest = global.XMLHttpRequest;\r\n var XDomainRequest = global.XDomainRequest;\r\n var ActiveXObject = global.ActiveXObject;\r\n var NativeEventSource = global.EventSource;\r\n\r\n var document = global.document;\r\n var Promise = global.Promise;\r\n var fetch = global.fetch;\r\n var Response = global.Response;\r\n var TextDecoder = global.TextDecoder;\r\n var TextEncoder = global.TextEncoder;\r\n var AbortController = global.AbortController;\r\n\r\n if (typeof window !== \"undefined\" && typeof document !== \"undefined\" && !(\"readyState\" in document) && document.body == null) { // Firefox 2\r\n document.readyState = \"loading\";\r\n window.addEventListener(\"load\", function (event) {\r\n document.readyState = \"complete\";\r\n }, false);\r\n }\r\n\r\n if (XMLHttpRequest == null && ActiveXObject != null) { // https://developer.mozilla.org/en-US/docs/Web/API/XMLHttpRequest/Using_XMLHttpRequest_in_IE6\r\n XMLHttpRequest = function () {\r\n return new ActiveXObject(\"Microsoft.XMLHTTP\");\r\n };\r\n }\r\n\r\n if (Object.create == undefined) {\r\n Object.create = function (C) {\r\n function F(){}\r\n F.prototype = C;\r\n return new F();\r\n };\r\n }\r\n\r\n if (!Date.now) {\r\n Date.now = function now() {\r\n return new Date().getTime();\r\n };\r\n }\r\n\r\n // see #118 (Promise#finally with polyfilled Promise)\r\n // see #123 (data URLs crash Edge)\r\n // see #125 (CSP violations)\r\n // see pull/#138\r\n // => No way to polyfill Promise#finally\r\n\r\n if (AbortController == undefined) {\r\n var originalFetch2 = fetch;\r\n fetch = function (url, options) {\r\n var signal = options.signal;\r\n return originalFetch2(url, {headers: options.headers, credentials: options.credentials, cache: options.cache}).then(function (response) {\r\n var reader = response.body.getReader();\r\n signal._reader = reader;\r\n if (signal._aborted) {\r\n signal._reader.cancel();\r\n }\r\n return {\r\n status: response.status,\r\n statusText: response.statusText,\r\n headers: response.headers,\r\n body: {\r\n getReader: function () {\r\n return reader;\r\n }\r\n }\r\n };\r\n });\r\n };\r\n AbortController = function () {\r\n this.signal = {\r\n _reader: null,\r\n _aborted: false\r\n };\r\n this.abort = function () {\r\n if (this.signal._reader != null) {\r\n this.signal._reader.cancel();\r\n }\r\n this.signal._aborted = true;\r\n };\r\n };\r\n }\r\n\r\n function TextDecoderPolyfill() {\r\n this.bitsNeeded = 0;\r\n this.codePoint = 0;\r\n }\r\n\r\n TextDecoderPolyfill.prototype.decode = function (octets) {\r\n function valid(codePoint, shift, octetsCount) {\r\n if (octetsCount === 1) {\r\n return codePoint >= 0x0080 >> shift && codePoint << shift <= 0x07FF;\r\n }\r\n if (octetsCount === 2) {\r\n return codePoint >= 0x0800 >> shift && codePoint << shift <= 0xD7FF || codePoint >= 0xE000 >> shift && codePoint << shift <= 0xFFFF;\r\n }\r\n if (octetsCount === 3) {\r\n return codePoint >= 0x010000 >> shift && codePoint << shift <= 0x10FFFF;\r\n }\r\n throw new Error();\r\n }\r\n function octetsCount(bitsNeeded, codePoint) {\r\n if (bitsNeeded === 6 * 1) {\r\n return codePoint >> 6 > 15 ? 3 : codePoint > 31 ? 2 : 1;\r\n }\r\n if (bitsNeeded === 6 * 2) {\r\n return codePoint > 15 ? 3 : 2;\r\n }\r\n if (bitsNeeded === 6 * 3) {\r\n return 3;\r\n }\r\n throw new Error();\r\n }\r\n var REPLACER = 0xFFFD;\r\n var string = \"\";\r\n var bitsNeeded = this.bitsNeeded;\r\n var codePoint = this.codePoint;\r\n for (var i = 0; i < octets.length; i += 1) {\r\n var octet = octets[i];\r\n if (bitsNeeded !== 0) {\r\n if (octet < 128 || octet > 191 || !valid(codePoint << 6 | octet & 63, bitsNeeded - 6, octetsCount(bitsNeeded, codePoint))) {\r\n bitsNeeded = 0;\r\n codePoint = REPLACER;\r\n string += String.fromCharCode(codePoint);\r\n }\r\n }\r\n if (bitsNeeded === 0) {\r\n if (octet >= 0 && octet <= 127) {\r\n bitsNeeded = 0;\r\n codePoint = octet;\r\n } else if (octet >= 192 && octet <= 223) {\r\n bitsNeeded = 6 * 1;\r\n codePoint = octet & 31;\r\n } else if (octet >= 224 && octet <= 239) {\r\n bitsNeeded = 6 * 2;\r\n codePoint = octet & 15;\r\n } else if (octet >= 240 && octet <= 247) {\r\n bitsNeeded = 6 * 3;\r\n codePoint = octet & 7;\r\n } else {\r\n bitsNeeded = 0;\r\n codePoint = REPLACER;\r\n }\r\n if (bitsNeeded !== 0 && !valid(codePoint, bitsNeeded, octetsCount(bitsNeeded, codePoint))) {\r\n bitsNeeded = 0;\r\n codePoint = REPLACER;\r\n }\r\n } else {\r\n bitsNeeded -= 6;\r\n codePoint = codePoint << 6 | octet & 63;\r\n }\r\n if (bitsNeeded === 0) {\r\n if (codePoint <= 0xFFFF) {\r\n string += String.fromCharCode(codePoint);\r\n } else {\r\n string += String.fromCharCode(0xD800 + (codePoint - 0xFFFF - 1 >> 10));\r\n string += String.fromCharCode(0xDC00 + (codePoint - 0xFFFF - 1 & 0x3FF));\r\n }\r\n }\r\n }\r\n this.bitsNeeded = bitsNeeded;\r\n this.codePoint = codePoint;\r\n return string;\r\n };\r\n\r\n // Firefox < 38 throws an error with stream option\r\n var supportsStreamOption = function () {\r\n try {\r\n return new TextDecoder().decode(new TextEncoder().encode(\"test\"), {stream: true}) === \"test\";\r\n } catch (error) {\r\n console.debug(\"TextDecoder does not support streaming option. Using polyfill instead: \" + error);\r\n }\r\n return false;\r\n };\r\n\r\n // IE, Edge\r\n if (TextDecoder == undefined || TextEncoder == undefined || !supportsStreamOption()) {\r\n TextDecoder = TextDecoderPolyfill;\r\n }\r\n\r\n var k = function () {\r\n };\r\n\r\n function XHRWrapper(xhr) {\r\n this.withCredentials = false;\r\n this.readyState = 0;\r\n this.status = 0;\r\n this.statusText = \"\";\r\n this.responseText = \"\";\r\n this.onprogress = k;\r\n this.onload = k;\r\n this.onerror = k;\r\n this.onreadystatechange = k;\r\n this._contentType = \"\";\r\n this._xhr = xhr;\r\n this._sendTimeout = 0;\r\n this._abort = k;\r\n }\r\n\r\n XHRWrapper.prototype.open = function (method, url) {\r\n this._abort(true);\r\n\r\n var that = this;\r\n var xhr = this._xhr;\r\n var state = 1;\r\n var timeout = 0;\r\n\r\n this._abort = function (silent) {\r\n if (that._sendTimeout !== 0) {\r\n clearTimeout(that._sendTimeout);\r\n that._sendTimeout = 0;\r\n }\r\n if (state === 1 || state === 2 || state === 3) {\r\n state = 4;\r\n xhr.onload = k;\r\n xhr.onerror = k;\r\n xhr.onabort = k;\r\n xhr.onprogress = k;\r\n xhr.onreadystatechange = k;\r\n // IE 8 - 9: XDomainRequest#abort() does not fire any event\r\n // Opera < 10: XMLHttpRequest#abort() does not fire any event\r\n xhr.abort();\r\n if (timeout !== 0) {\r\n clearTimeout(timeout);\r\n timeout = 0;\r\n }\r\n if (!silent) {\r\n that.readyState = 4;\r\n that.onabort(null);\r\n that.onreadystatechange();\r\n }\r\n }\r\n state = 0;\r\n };\r\n\r\n var onStart = function () {\r\n if (state === 1) {\r\n //state = 2;\r\n var status = 0;\r\n var statusText = \"\";\r\n var contentType = undefined;\r\n if (!(\"contentType\" in xhr)) {\r\n try {\r\n status = xhr.status;\r\n statusText = xhr.statusText;\r\n contentType = xhr.getResponseHeader(\"Content-Type\");\r\n } catch (error) {\r\n // IE < 10 throws exception for `xhr.status` when xhr.readyState === 2 || xhr.readyState === 3\r\n // Opera < 11 throws exception for `xhr.status` when xhr.readyState === 2\r\n // https://bugs.webkit.org/show_bug.cgi?id=29121\r\n status = 0;\r\n statusText = \"\";\r\n contentType = undefined;\r\n // Firefox < 14, Chrome ?, Safari ?\r\n // https://bugs.webkit.org/show_bug.cgi?id=29658\r\n // https://bugs.webkit.org/show_bug.cgi?id=77854\r\n }\r\n } else {\r\n status = 200;\r\n statusText = \"OK\";\r\n contentType = xhr.contentType;\r\n }\r\n if (status !== 0) {\r\n state = 2;\r\n that.readyState = 2;\r\n that.status = status;\r\n that.statusText = statusText;\r\n that._contentType = contentType;\r\n that.onreadystatechange();\r\n }\r\n }\r\n };\r\n var onProgress = function () {\r\n onStart();\r\n if (state === 2 || state === 3) {\r\n state = 3;\r\n var responseText = \"\";\r\n try {\r\n responseText = xhr.responseText;\r\n } catch (error) {\r\n // IE 8 - 9 with XMLHttpRequest\r\n }\r\n that.readyState = 3;\r\n that.responseText = responseText;\r\n that.onprogress();\r\n }\r\n };\r\n var onFinish = function (type, event) {\r\n if (event == null || event.preventDefault == null) {\r\n event = {\r\n preventDefault: k\r\n };\r\n }\r\n // Firefox 52 fires \"readystatechange\" (xhr.readyState === 4) without final \"readystatechange\" (xhr.readyState === 3)\r\n // IE 8 fires \"onload\" without \"onprogress\"\r\n onProgress();\r\n if (state === 1 || state === 2 || state === 3) {\r\n state = 4;\r\n if (timeout !== 0) {\r\n clearTimeout(timeout);\r\n timeout = 0;\r\n }\r\n that.readyState = 4;\r\n if (type === \"load\") {\r\n that.onload(event);\r\n } else if (type === \"error\") {\r\n that.onerror(event);\r\n } else if (type === \"abort\") {\r\n that.onabort(event);\r\n } else {\r\n throw new TypeError();\r\n }\r\n that.onreadystatechange();\r\n }\r\n };\r\n var onReadyStateChange = function (event) {\r\n if (xhr != undefined) { // Opera 12\r\n if (xhr.readyState === 4) {\r\n if (!(\"onload\" in xhr) || !(\"onerror\" in xhr) || !(\"onabort\" in xhr)) {\r\n onFinish(xhr.responseText === \"\" ? \"error\" : \"load\", event);\r\n }\r\n } else if (xhr.readyState === 3) {\r\n if (!(\"onprogress\" in xhr)) { // testing XMLHttpRequest#responseText too many times is too slow in IE 11\r\n // and in Firefox 3.6\r\n onProgress();\r\n }\r\n } else if (xhr.readyState === 2) {\r\n onStart();\r\n }\r\n }\r\n };\r\n var onTimeout = function () {\r\n timeout = setTimeout(function () {\r\n onTimeout();\r\n }, 500);\r\n if (xhr.readyState === 3) {\r\n onProgress();\r\n }\r\n };\r\n\r\n // XDomainRequest#abort removes onprogress, onerror, onload\r\n if (\"onload\" in xhr) {\r\n xhr.onload = function (event) {\r\n onFinish(\"load\", event);\r\n };\r\n }\r\n if (\"onerror\" in xhr) {\r\n xhr.onerror = function (event) {\r\n onFinish(\"error\", event);\r\n };\r\n }\r\n // improper fix to match Firefox behaviour, but it is better than just ignore abort\r\n // see https://bugzilla.mozilla.org/show_bug.cgi?id=768596\r\n // https://bugzilla.mozilla.org/show_bug.cgi?id=880200\r\n // https://code.google.com/p/chromium/issues/detail?id=153570\r\n // IE 8 fires \"onload\" without \"onprogress\r\n if (\"onabort\" in xhr) {\r\n xhr.onabort = function (event) {\r\n onFinish(\"abort\", event);\r\n };\r\n }\r\n\r\n if (\"onprogress\" in xhr) {\r\n xhr.onprogress = onProgress;\r\n }\r\n\r\n // IE 8 - 9 (XMLHTTPRequest)\r\n // Opera < 12\r\n // Firefox < 3.5\r\n // Firefox 3.5 - 3.6 - ? < 9.0\r\n // onprogress is not fired sometimes or delayed\r\n // see also #64 (significant lag in IE 11)\r\n if (\"onreadystatechange\" in xhr) {\r\n xhr.onreadystatechange = function (event) {\r\n onReadyStateChange(event);\r\n };\r\n }\r\n\r\n if (\"contentType\" in xhr || !(\"ontimeout\" in XMLHttpRequest.prototype)) {\r\n url += (url.indexOf(\"?\") === -1 ? \"?\" : \"&\") + \"padding=true\";\r\n }\r\n xhr.open(method, url, true);\r\n\r\n if (\"readyState\" in xhr) {\r\n // workaround for Opera 12 issue with \"progress\" events\r\n // #91 (XMLHttpRequest onprogress not fired for streaming response in Edge 14-15-?)\r\n timeout = setTimeout(function () {\r\n onTimeout();\r\n }, 0);\r\n }\r\n };\r\n XHRWrapper.prototype.abort = function () {\r\n this._abort(false);\r\n };\r\n XHRWrapper.prototype.getResponseHeader = function (name) {\r\n return this._contentType;\r\n };\r\n XHRWrapper.prototype.setRequestHeader = function (name, value) {\r\n var xhr = this._xhr;\r\n if (\"setRequestHeader\" in xhr) {\r\n xhr.setRequestHeader(name, value);\r\n }\r\n };\r\n XHRWrapper.prototype.getAllResponseHeaders = function () {\r\n // XMLHttpRequest#getAllResponseHeaders returns null for CORS requests in Firefox 3.6.28\r\n return this._xhr.getAllResponseHeaders != undefined ? this._xhr.getAllResponseHeaders() || \"\" : \"\";\r\n };\r\n XHRWrapper.prototype.send = function () {\r\n // loading indicator in Safari < ? (6), Chrome < 14, Firefox\r\n // https://bugzilla.mozilla.org/show_bug.cgi?id=736723\r\n if ((!(\"ontimeout\" in XMLHttpRequest.prototype) || (!(\"sendAsBinary\" in XMLHttpRequest.prototype) && !(\"mozAnon\" in XMLHttpRequest.prototype))) &&\r\n document != undefined &&\r\n document.readyState != undefined &&\r\n document.readyState !== \"complete\") {\r\n var that = this;\r\n that._sendTimeout = setTimeout(function () {\r\n that._sendTimeout = 0;\r\n that.send();\r\n }, 4);\r\n return;\r\n }\r\n\r\n var xhr = this._xhr;\r\n // withCredentials should be set after \"open\" for Safari and Chrome (< 19 ?)\r\n if (\"withCredentials\" in xhr) {\r\n xhr.withCredentials = this.withCredentials;\r\n }\r\n try {\r\n // xhr.send(); throws \"Not enough arguments\" in Firefox 3.0\r\n xhr.send(undefined);\r\n } catch (error1) {\r\n // Safari 5.1.7, Opera 12\r\n throw error1;\r\n }\r\n };\r\n\r\n function toLowerCase(name) {\r\n return name.replace(/[A-Z]/g, function (c) {\r\n return String.fromCharCode(c.charCodeAt(0) + 0x20);\r\n });\r\n }\r\n\r\n function HeadersPolyfill(all) {\r\n // Get headers: implemented according to mozilla's example code: https://developer.mozilla.org/en-US/docs/Web/API/XMLHttpRequest/getAllResponseHeaders#Example\r\n var map = Object.create(null);\r\n var array = all.split(\"\\r\\n\");\r\n for (var i = 0; i < array.length; i += 1) {\r\n var line = array[i];\r\n var parts = line.split(\": \");\r\n var name = parts.shift();\r\n var value = parts.join(\": \");\r\n map[toLowerCase(name)] = value;\r\n }\r\n this._map = map;\r\n }\r\n HeadersPolyfill.prototype.get = function (name) {\r\n return this._map[toLowerCase(name)];\r\n };\r\n\r\n if (XMLHttpRequest != null && XMLHttpRequest.HEADERS_RECEIVED == null) { // IE < 9, Firefox 3.6\r\n XMLHttpRequest.HEADERS_RECEIVED = 2;\r\n }\r\n\r\n function XHRTransport() {\r\n }\r\n\r\n XHRTransport.prototype.open = function (xhr, onStartCallback, onProgressCallback, onFinishCallback, url, withCredentials, headers) {\r\n xhr.open(\"GET\", url);\r\n var offset = 0;\r\n xhr.onprogress = function () {\r\n var responseText = xhr.responseText;\r\n var chunk = responseText.slice(offset);\r\n offset += chunk.length;\r\n onProgressCallback(chunk);\r\n };\r\n xhr.onerror = function (event) {\r\n event.preventDefault();\r\n onFinishCallback(new Error(\"NetworkError\"));\r\n };\r\n xhr.onload = function () {\r\n onFinishCallback(null);\r\n };\r\n xhr.onabort = function () {\r\n onFinishCallback(null);\r\n };\r\n xhr.onreadystatechange = function () {\r\n if (xhr.readyState === XMLHttpRequest.HEADERS_RECEIVED) {\r\n var status = xhr.status;\r\n var statusText = xhr.statusText;\r\n var contentType = xhr.getResponseHeader(\"Content-Type\");\r\n var headers = xhr.getAllResponseHeaders();\r\n onStartCallback(status, statusText, contentType, new HeadersPolyfill(headers));\r\n }\r\n };\r\n xhr.withCredentials = withCredentials;\r\n for (var name in headers) {\r\n if (Object.prototype.hasOwnProperty.call(headers, name)) {\r\n xhr.setRequestHeader(name, headers[name]);\r\n }\r\n }\r\n xhr.send();\r\n return xhr;\r\n };\r\n\r\n function HeadersWrapper(headers) {\r\n this._headers = headers;\r\n }\r\n HeadersWrapper.prototype.get = function (name) {\r\n return this._headers.get(name);\r\n };\r\n\r\n function FetchTransport() {\r\n }\r\n\r\n FetchTransport.prototype.open = function (xhr, onStartCallback, onProgressCallback, onFinishCallback, url, withCredentials, headers) {\r\n var reader = null;\r\n var controller = new AbortController();\r\n var signal = controller.signal;\r\n var textDecoder = new TextDecoder();\r\n fetch(url, {\r\n headers: headers,\r\n credentials: withCredentials ? \"include\" : \"same-origin\",\r\n signal: signal,\r\n cache: \"no-store\"\r\n }).then(function (response) {\r\n reader = response.body.getReader();\r\n onStartCallback(response.status, response.statusText, response.headers.get(\"Content-Type\"), new HeadersWrapper(response.headers));\r\n // see https://github.com/promises-aplus/promises-spec/issues/179\r\n return new Promise(function (resolve, reject) {\r\n var readNextChunk = function () {\r\n reader.read().then(function (result) {\r\n if (result.done) {\r\n //Note: bytes in textDecoder are ignored\r\n resolve(undefined);\r\n } else {\r\n var chunk = textDecoder.decode(result.value, {stream: true});\r\n onProgressCallback(chunk);\r\n readNextChunk();\r\n }\r\n })[\"catch\"](function (error) {\r\n reject(error);\r\n });\r\n };\r\n readNextChunk();\r\n });\r\n })[\"catch\"](function (error) {\r\n if (error.name === \"AbortError\") {\r\n return undefined;\r\n } else {\r\n return error;\r\n }\r\n }).then(function (error) {\r\n onFinishCallback(error);\r\n });\r\n return {\r\n abort: function () {\r\n if (reader != null) {\r\n reader.cancel(); // https://bugzilla.mozilla.org/show_bug.cgi?id=1583815\r\n }\r\n controller.abort();\r\n }\r\n };\r\n };\r\n\r\n function EventTarget() {\r\n this._listeners = Object.create(null);\r\n }\r\n\r\n function throwError(e) {\r\n setTimeout(function () {\r\n throw e;\r\n }, 0);\r\n }\r\n\r\n EventTarget.prototype.dispatchEvent = function (event) {\r\n event.target = this;\r\n var typeListeners = this._listeners[event.type];\r\n if (typeListeners != undefined) {\r\n var length = typeListeners.length;\r\n for (var i = 0; i < length; i += 1) {\r\n var listener = typeListeners[i];\r\n try {\r\n if (typeof listener.handleEvent === \"function\") {\r\n listener.handleEvent(event);\r\n } else {\r\n listener.call(this, event);\r\n }\r\n } catch (e) {\r\n throwError(e);\r\n }\r\n }\r\n }\r\n };\r\n EventTarget.prototype.addEventListener = function (type, listener) {\r\n type = String(type);\r\n var listeners = this._listeners;\r\n var typeListeners = listeners[type];\r\n if (typeListeners == undefined) {\r\n typeListeners = [];\r\n listeners[type] = typeListeners;\r\n }\r\n var found = false;\r\n for (var i = 0; i < typeListeners.length; i += 1) {\r\n if (typeListeners[i] === listener) {\r\n found = true;\r\n }\r\n }\r\n if (!found) {\r\n typeListeners.push(listener);\r\n }\r\n };\r\n EventTarget.prototype.removeEventListener = function (type, listener) {\r\n type = String(type);\r\n var listeners = this._listeners;\r\n var typeListeners = listeners[type];\r\n if (typeListeners != undefined) {\r\n var filtered = [];\r\n for (var i = 0; i < typeListeners.length; i += 1) {\r\n if (typeListeners[i] !== listener) {\r\n filtered.push(typeListeners[i]);\r\n }\r\n }\r\n if (filtered.length === 0) {\r\n delete listeners[type];\r\n } else {\r\n listeners[type] = filtered;\r\n }\r\n }\r\n };\r\n\r\n function Event(type) {\r\n this.type = type;\r\n this.target = undefined;\r\n }\r\n\r\n function MessageEvent(type, options) {\r\n Event.call(this, type);\r\n this.data = options.data;\r\n this.lastEventId = options.lastEventId;\r\n }\r\n\r\n MessageEvent.prototype = Object.create(Event.prototype);\r\n\r\n function ConnectionEvent(type, options) {\r\n Event.call(this, type);\r\n this.status = options.status;\r\n this.statusText = options.statusText;\r\n this.headers = options.headers;\r\n }\r\n\r\n ConnectionEvent.prototype = Object.create(Event.prototype);\r\n\r\n function ErrorEvent(type, options) {\r\n Event.call(this, type);\r\n this.error = options.error;\r\n }\r\n\r\n ErrorEvent.prototype = Object.create(Event.prototype);\r\n\r\n var WAITING = -1;\r\n var CONNECTING = 0;\r\n var OPEN = 1;\r\n var CLOSED = 2;\r\n\r\n var AFTER_CR = -1;\r\n var FIELD_START = 0;\r\n var FIELD = 1;\r\n var VALUE_START = 2;\r\n var VALUE = 3;\r\n\r\n var contentTypeRegExp = /^text\\/event\\-stream(;.*)?$/i;\r\n\r\n var MINIMUM_DURATION = 1000;\r\n var MAXIMUM_DURATION = 18000000;\r\n\r\n var parseDuration = function (value, def) {\r\n var n = value == null ? def : parseInt(value, 10);\r\n if (n !== n) {\r\n n = def;\r\n }\r\n return clampDuration(n);\r\n };\r\n var clampDuration = function (n) {\r\n return Math.min(Math.max(n, MINIMUM_DURATION), MAXIMUM_DURATION);\r\n };\r\n\r\n var fire = function (that, f, event) {\r\n try {\r\n if (typeof f === \"function\") {\r\n f.call(that, event);\r\n }\r\n } catch (e) {\r\n throwError(e);\r\n }\r\n };\r\n\r\n function EventSourcePolyfill(url, options) {\r\n EventTarget.call(this);\r\n options = options || {};\r\n\r\n this.onopen = undefined;\r\n this.onmessage = undefined;\r\n this.onerror = undefined;\r\n\r\n this.url = undefined;\r\n this.readyState = undefined;\r\n this.withCredentials = undefined;\r\n this.headers = undefined;\r\n\r\n this._close = undefined;\r\n\r\n start(this, url, options);\r\n }\r\n\r\n function getBestXHRTransport() {\r\n return (XMLHttpRequest != undefined && (\"withCredentials\" in XMLHttpRequest.prototype)) || XDomainRequest == undefined\r\n ? new XMLHttpRequest()\r\n : new XDomainRequest();\r\n }\r\n\r\n var isFetchSupported = fetch != undefined && Response != undefined && \"body\" in Response.prototype;\r\n\r\n function start(es, url, options) {\r\n url = String(url);\r\n var withCredentials = Boolean(options.withCredentials);\r\n var lastEventIdQueryParameterName = options.lastEventIdQueryParameterName || \"lastEventId\";\r\n\r\n var initialRetry = clampDuration(1000);\r\n var heartbeatTimeout = parseDuration(options.heartbeatTimeout, 45000);\r\n\r\n var lastEventId = \"\";\r\n var retry = initialRetry;\r\n var wasActivity = false;\r\n var textLength = 0;\r\n var headers = options.headers || {};\r\n var TransportOption = options.Transport;\r\n var xhr = isFetchSupported && TransportOption == undefined ? undefined : new XHRWrapper(TransportOption != undefined ? new TransportOption() : getBestXHRTransport());\r\n var transport = TransportOption != null && typeof TransportOption !== \"string\" ? new TransportOption() : (xhr == undefined ? new FetchTransport() : new XHRTransport());\r\n var abortController = undefined;\r\n var timeout = 0;\r\n var currentState = WAITING;\r\n var dataBuffer = \"\";\r\n var lastEventIdBuffer = \"\";\r\n var eventTypeBuffer = \"\";\r\n\r\n var textBuffer = \"\";\r\n var state = FIELD_START;\r\n var fieldStart = 0;\r\n var valueStart = 0;\r\n\r\n var onStart = function (status, statusText, contentType, headers) {\r\n if (currentState === CONNECTING) {\r\n if (status === 200 && contentType != undefined && contentTypeRegExp.test(contentType)) {\r\n currentState = OPEN;\r\n wasActivity = Date.now();\r\n retry = initialRetry;\r\n es.readyState = OPEN;\r\n var event = new ConnectionEvent(\"open\", {\r\n status: status,\r\n statusText: statusText,\r\n headers: headers\r\n });\r\n es.dispatchEvent(event);\r\n fire(es, es.onopen, event);\r\n } else {\r\n var message = \"\";\r\n if (status !== 200) {\r\n if (statusText) {\r\n statusText = statusText.replace(/\\s+/g, \" \");\r\n }\r\n message = \"EventSource's response has a status \" + status + \" \" + statusText + \" that is not 200. Aborting the connection.\";\r\n } else {\r\n message = \"EventSource's response has a Content-Type specifying an unsupported type: \" + (contentType == undefined ? \"-\" : contentType.replace(/\\s+/g, \" \")) + \". Aborting the connection.\";\r\n }\r\n close();\r\n var event = new ConnectionEvent(\"error\", {\r\n status: status,\r\n statusText: statusText,\r\n headers: headers\r\n });\r\n es.dispatchEvent(event);\r\n fire(es, es.onerror, event);\r\n console.error(message);\r\n }\r\n }\r\n };\r\n\r\n var onProgress = function (textChunk) {\r\n if (currentState === OPEN) {\r\n var n = -1;\r\n for (var i = 0; i < textChunk.length; i += 1) {\r\n var c = textChunk.charCodeAt(i);\r\n if (c === \"\\n\".charCodeAt(0) || c === \"\\r\".charCodeAt(0)) {\r\n n = i;\r\n }\r\n }\r\n var chunk = (n !== -1 ? textBuffer : \"\") + textChunk.slice(0, n + 1);\r\n textBuffer = (n === -1 ? textBuffer : \"\") + textChunk.slice(n + 1);\r\n if (textChunk !== \"\") {\r\n wasActivity = Date.now();\r\n textLength += textChunk.length;\r\n }\r\n for (var position = 0; position < chunk.length; position += 1) {\r\n var c = chunk.charCodeAt(position);\r\n if (state === AFTER_CR && c === \"\\n\".charCodeAt(0)) {\r\n state = FIELD_START;\r\n } else {\r\n if (state === AFTER_CR) {\r\n state = FIELD_START;\r\n }\r\n if (c === \"\\r\".charCodeAt(0) || c === \"\\n\".charCodeAt(0)) {\r\n if (state !== FIELD_START) {\r\n if (state === FIELD) {\r\n valueStart = position + 1;\r\n }\r\n var field = chunk.slice(fieldStart, valueStart - 1);\r\n var value = chunk.slice(valueStart + (valueStart < position && chunk.charCodeAt(valueStart) === \" \".charCodeAt(0) ? 1 : 0), position);\r\n if (field === \"data\") {\r\n dataBuffer += \"\\n\";\r\n dataBuffer += value;\r\n } else if (field === \"id\") {\r\n lastEventIdBuffer = value;\r\n } else if (field === \"event\") {\r\n eventTypeBuffer = value;\r\n } else if (field === \"retry\") {\r\n initialRetry = parseDuration(value, initialRetry);\r\n retry = initialRetry;\r\n } else if (field === \"heartbeatTimeout\") {\r\n heartbeatTimeout = parseDuration(value, heartbeatTimeout);\r\n if (timeout !== 0) {\r\n clearTimeout(timeout);\r\n timeout = setTimeout(function () {\r\n onTimeout();\r\n }, heartbeatTimeout);\r\n }\r\n }\r\n }\r\n if (state === FIELD_START) {\r\n if (dataBuffer !== \"\") {\r\n lastEventId = lastEventIdBuffer;\r\n if (eventTypeBuffer === \"\") {\r\n eventTypeBuffer = \"message\";\r\n }\r\n var event = new MessageEvent(eventTypeBuffer, {\r\n data: dataBuffer.slice(1),\r\n lastEventId: lastEventIdBuffer\r\n });\r\n es.dispatchEvent(event);\r\n if (eventTypeBuffer === \"open\") {\r\n fire(es, es.onopen, event);\r\n } else if (eventTypeBuffer === \"message\") {\r\n fire(es, es.onmessage, event);\r\n } else if (eventTypeBuffer === \"error\") {\r\n fire(es, es.onerror, event);\r\n }\r\n if (currentState === CLOSED) {\r\n return;\r\n }\r\n }\r\n dataBuffer = \"\";\r\n eventTypeBuffer = \"\";\r\n }\r\n state = c === \"\\r\".charCodeAt(0) ? AFTER_CR : FIELD_START;\r\n } else {\r\n if (state === FIELD_START) {\r\n fieldStart = position;\r\n state = FIELD;\r\n }\r\n if (state === FIELD) {\r\n if (c === \":\".charCodeAt(0)) {\r\n valueStart = position + 1;\r\n state = VALUE_START;\r\n }\r\n } else if (state === VALUE_START) {\r\n state = VALUE;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n };\r\n\r\n var onFinish = function (error) {\r\n if (currentState === OPEN || currentState === CONNECTING) {\r\n currentState = WAITING;\r\n if (timeout !== 0) {\r\n clearTimeout(timeout);\r\n timeout = 0;\r\n }\r\n timeout = setTimeout(function () {\r\n onTimeout();\r\n }, retry);\r\n retry = clampDuration(Math.min(initialRetry * 16, retry * 2));\r\n\r\n es.readyState = CONNECTING;\r\n var event = new ErrorEvent(\"error\", {error: error});\r\n es.dispatchEvent(event);\r\n fire(es, es.onerror, event);\r\n if (error != undefined) {\r\n console.error(error);\r\n }\r\n }\r\n };\r\n\r\n var close = function () {\r\n currentState = CLOSED;\r\n if (abortController != undefined) {\r\n abortController.abort();\r\n abortController = undefined;\r\n }\r\n if (timeout !== 0) {\r\n clearTimeout(timeout);\r\n timeout = 0;\r\n }\r\n es.readyState = CLOSED;\r\n };\r\n\r\n var onTimeout = function () {\r\n timeout = 0;\r\n\r\n if (currentState !== WAITING) {\r\n if (!wasActivity && abortController != undefined) {\r\n onFinish(new Error(\"No activity within \" + heartbeatTimeout + \" milliseconds.\" + \" \" + (currentState === CONNECTING ? \"No response received.\" : textLength + \" chars received.\") + \" \" + \"Reconnecting.\"));\r\n if (abortController != undefined) {\r\n abortController.abort();\r\n abortController = undefined;\r\n }\r\n } else {\r\n var nextHeartbeat = Math.max((wasActivity || Date.now()) + heartbeatTimeout - Date.now(), 1);\r\n wasActivity = false;\r\n timeout = setTimeout(function () {\r\n onTimeout();\r\n }, nextHeartbeat);\r\n }\r\n return;\r\n }\r\n\r\n wasActivity = false;\r\n textLength = 0;\r\n timeout = setTimeout(function () {\r\n onTimeout();\r\n }, heartbeatTimeout);\r\n\r\n currentState = CONNECTING;\r\n dataBuffer = \"\";\r\n eventTypeBuffer = \"\";\r\n lastEventIdBuffer = lastEventId;\r\n textBuffer = \"\";\r\n fieldStart = 0;\r\n valueStart = 0;\r\n state = FIELD_START;\r\n\r\n // https://bugzilla.mozilla.org/show_bug.cgi?id=428916\r\n // Request header field Last-Event-ID is not allowed by Access-Control-Allow-Headers.\r\n var requestURL = url;\r\n if (url.slice(0, 5) !== \"data:\" && url.slice(0, 5) !== \"blob:\") {\r\n if (lastEventId !== \"\") {\r\n // Remove the lastEventId parameter if it's already part of the request URL.\r\n var i = url.indexOf(\"?\");\r\n requestURL = i === -1 ? url : url.slice(0, i + 1) + url.slice(i + 1).replace(/(?:^|&)([^=&]*)(?:=[^&]*)?/g, function (p, paramName) {\r\n return paramName === lastEventIdQueryParameterName ? '' : p;\r\n });\r\n // Append the current lastEventId to the request URL.\r\n requestURL += (url.indexOf(\"?\") === -1 ? \"?\" : \"&\") + lastEventIdQueryParameterName +\"=\" + encodeURIComponent(lastEventId);\r\n }\r\n }\r\n var withCredentials = es.withCredentials;\r\n var requestHeaders = {};\r\n requestHeaders[\"Accept\"] = \"text/event-stream\";\r\n var headers = es.headers;\r\n if (headers != undefined) {\r\n for (var name in headers) {\r\n if (Object.prototype.hasOwnProperty.call(headers, name)) {\r\n requestHeaders[name] = headers[name];\r\n }\r\n }\r\n }\r\n try {\r\n abortController = transport.open(xhr, onStart, onProgress, onFinish, requestURL, withCredentials, requestHeaders);\r\n } catch (error) {\r\n close();\r\n throw error;\r\n }\r\n };\r\n\r\n es.url = url;\r\n es.readyState = CONNECTING;\r\n es.withCredentials = withCredentials;\r\n es.headers = headers;\r\n es._close = close;\r\n\r\n onTimeout();\r\n }\r\n\r\n EventSourcePolyfill.prototype = Object.create(EventTarget.prototype);\r\n EventSourcePolyfill.prototype.CONNECTING = CONNECTING;\r\n EventSourcePolyfill.prototype.OPEN = OPEN;\r\n EventSourcePolyfill.prototype.CLOSED = CLOSED;\r\n EventSourcePolyfill.prototype.close = function () {\r\n this._close();\r\n };\r\n\r\n EventSourcePolyfill.CONNECTING = CONNECTING;\r\n EventSourcePolyfill.OPEN = OPEN;\r\n EventSourcePolyfill.CLOSED = CLOSED;\r\n EventSourcePolyfill.prototype.withCredentials = undefined;\r\n\r\n var R = NativeEventSource\r\n if (XMLHttpRequest != undefined && (NativeEventSource == undefined || !(\"withCredentials\" in NativeEventSource.prototype))) {\r\n // Why replace a native EventSource ?\r\n // https://bugzilla.mozilla.org/show_bug.cgi?id=444328\r\n // https://bugzilla.mozilla.org/show_bug.cgi?id=831392\r\n // https://code.google.com/p/chromium/issues/detail?id=260144\r\n // https://code.google.com/p/chromium/issues/detail?id=225654\r\n // ...\r\n R = EventSourcePolyfill;\r\n }\r\n\r\n (function (factory) {\r\n if (typeof module === \"object\" && typeof module.exports === \"object\") {\r\n var v = factory(exports);\r\n if (v !== undefined) module.exports = v;\r\n }\r\n else if (typeof define === \"function\" && define.amd) {\r\n define([\"exports\"], factory);\r\n }\r\n else {\r\n factory(global);\r\n }\r\n })(function (exports) {\r\n exports.EventSourcePolyfill = EventSourcePolyfill;\r\n exports.NativeEventSource = NativeEventSource;\r\n exports.EventSource = R;\r\n });\r\n}(typeof globalThis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AAC,SAAS,GAAG,OAAO;AAAA,QAC7B,OACK;AACH,kBAAQ,MAAM;AAAA,QAChB;AAAA,MACF,GAAG,SAAUC,UAAS;AACpB,QAAAA,SAAQ,sBAAsB;AAC9B,QAAAA,SAAQ,oBAAoB;AAC5B,QAAAA,SAAQ,cAAc;AAAA,MACxB,CAAC;AAAA,IACH,GAAE,OAAO,eAAe,cAAe,OAAO,WAAW,cAAc,SAAS,OAAO,SAAS,cAAc,OAAO,UAAQ,UAAU;AAAA;AAAA;",
"names": ["Promise", "codePoint", "octetsCount", "bitsNeeded", "headers", "withCredentials", "exports"]
}
... ...
import "./chunk-RSJERJUL.js";
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/mixin/mixin.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/mixin/mixin.js
var mixin_default = {
// 定义每个组件都可能需要用到的外部样式以及类名
props: {
... ... @@ -131,10 +131,10 @@ var mixin_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/mixin/mpMixin.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/mixin/mpMixin.js
var mpMixin_default = {};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/luch-request/utils.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/luch-request/utils.js
var { toString } = Object.prototype;
function isArray(val) {
return toString.call(val) === "[object Array]";
... ... @@ -190,7 +190,7 @@ function isUndefined(val) {
return typeof val === "undefined";
}
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/luch-request/helpers/buildURL.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/luch-request/helpers/buildURL.js
function encode(val) {
return encodeURIComponent(val).replace(/%40/gi, "@").replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+").replace(/%5B/gi, "[").replace(/%5D/gi, "]");
}
... ... @@ -233,17 +233,17 @@ function buildURL(url2, params) {
return url2;
}
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/luch-request/helpers/isAbsoluteURL.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/luch-request/helpers/isAbsoluteURL.js
function isAbsoluteURL(url2) {
return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(url2);
}
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/luch-request/helpers/combineURLs.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/luch-request/helpers/combineURLs.js
function combineURLs(baseURL, relativeURL) {
return relativeURL ? `${baseURL.replace(/\/+$/, "")}/${relativeURL.replace(/^\/+/, "")}` : baseURL;
}
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/luch-request/core/buildFullPath.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/luch-request/core/buildFullPath.js
function buildFullPath(baseURL, requestedURL) {
if (baseURL && !isAbsoluteURL(requestedURL)) {
return combineURLs(baseURL, requestedURL);
... ... @@ -251,7 +251,7 @@ function buildFullPath(baseURL, requestedURL) {
return requestedURL;
}
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/luch-request/core/settle.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/luch-request/core/settle.js
function settle(resolve, reject, response) {
const { validateStatus: validateStatus2 } = response.config;
const status = response.statusCode;
... ... @@ -262,7 +262,7 @@ function settle(resolve, reject, response) {
}
}
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/luch-request/adapters/index.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/luch-request/adapters/index.js
var mergeKeys = (keys, config2) => {
const config = {};
keys.forEach((prop) => {
... ... @@ -325,10 +325,10 @@ var adapters_default = (config) => new Promise((resolve, reject) => {
}
});
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/luch-request/core/dispatchRequest.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/luch-request/core/dispatchRequest.js
var dispatchRequest_default = (config) => adapters_default(config);
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/luch-request/core/InterceptorManager.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/luch-request/core/InterceptorManager.js
function InterceptorManager() {
this.handlers = [];
}
... ... @@ -353,7 +353,7 @@ InterceptorManager.prototype.forEach = function forEach2(fn) {
};
var InterceptorManager_default = InterceptorManager;
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/luch-request/core/mergeConfig.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/luch-request/core/mergeConfig.js
var mergeKeys2 = (keys, globalsConfig, config2) => {
const config = {};
keys.forEach((prop) => {
... ... @@ -415,7 +415,7 @@ var mergeConfig_default = (globalsConfig, config2 = {}) => {
return config;
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/luch-request/core/defaults.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/luch-request/core/defaults.js
var defaults_default = {
baseURL: "",
header: {},
... ... @@ -430,7 +430,7 @@ var defaults_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/luch-request/utils/clone.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/luch-request/utils/clone.js
var clone = function() {
"use strict";
function _instanceof(obj, type) {
... ... @@ -627,7 +627,7 @@ var clone = function() {
}();
var clone_default = clone;
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/luch-request/core/Request.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/luch-request/core/Request.js
var Request = class {
/**
* @param {Object} arg - 全局配置
... ... @@ -765,10 +765,10 @@ var Request = class {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/luch-request/index.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/luch-request/index.js
var luch_request_default = Request;
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/util/route.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/util/route.js
var Router = class {
constructor() {
this.config = {
... ... @@ -868,7 +868,7 @@ var Router = class {
};
var route_default = new Router().route;
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/function/colorGradient.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/function/colorGradient.js
function colorGradient(startColor = "rgb(0, 0, 0)", endColor = "rgb(255, 255, 255)", step = 10) {
const startRGB = hexToRgb(startColor, false);
const startR = startRGB[0];
... ... @@ -980,7 +980,7 @@ var colorGradient_default = {
colorToRgba
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/function/test.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/function/test.js
function email(value) {
return /^\w+((-\w+)|(\.\w+))*\@[A-Za-z0-9]+((\.|-)[A-Za-z0-9]+)*\.[A-Za-z0-9]+$/.test(value);
}
... ... @@ -1154,7 +1154,7 @@ var test_default = {
string
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/function/debounce.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/function/debounce.js
var timeout = null;
function debounce(func2, wait = 500, immediate = false) {
if (timeout !== null)
... ... @@ -1174,7 +1174,7 @@ function debounce(func2, wait = 500, immediate = false) {
}
var debounce_default = debounce;
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/function/throttle.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/function/throttle.js
var timer;
var flag;
function throttle(func2, wait = 500, immediate = true) {
... ... @@ -1196,7 +1196,7 @@ function throttle(func2, wait = 500, immediate = true) {
}
var throttle_default = throttle;
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/function/digit.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/function/digit.js
var _boundaryCheckingState = true;
function strip(num, precision = 15) {
return +parseFloat(Number(num).toPrecision(precision));
... ... @@ -1260,7 +1260,7 @@ function round(num, ratio) {
return result;
}
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/function/index.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/function/index.js
function range2(min = 0, max = 0, value = 0) {
return Math.max(min, Math.min(max, Number(value)));
}
... ... @@ -1732,7 +1732,7 @@ var function_default = {
setConfig
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/config.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/config.js
var version = "3";
if (true) {
console.log(`
... ... @@ -1767,7 +1767,7 @@ var config_default = {
unit: "px"
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/actionSheet.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/actionSheet.js
var actionSheet_default = {
// action-sheet组件
actionSheet: {
... ... @@ -1785,7 +1785,7 @@ var actionSheet_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/album.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/album.js
var album_default = {
// album 组件
album: {
... ... @@ -1803,7 +1803,7 @@ var album_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/alert.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/alert.js
var alert_default = {
// alert警告组件
alert: {
... ... @@ -1818,7 +1818,7 @@ var alert_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/avatar.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/avatar.js
var avatar_default = {
// avatar 组件
avatar: {
... ... @@ -1839,7 +1839,7 @@ var avatar_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/avatarGroup.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/avatarGroup.js
var avatarGroup_default = {
// avatarGroup 组件
avatarGroup: {
... ... @@ -1855,7 +1855,7 @@ var avatarGroup_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/backtop.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/backtop.js
var backtop_default = {
// backtop组件
backtop: {
... ... @@ -1875,7 +1875,7 @@ var backtop_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/badge.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/badge.js
var badge_default = {
// 徽标数组件
badge: {
... ... @@ -1895,7 +1895,7 @@ var badge_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/button.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/button.js
var button_default = {
// button组件
button: {
... ... @@ -1930,7 +1930,7 @@ var button_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/calendar.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/calendar.js
var calendar_default = {
// calendar 组件
calendar: {
... ... @@ -1967,7 +1967,7 @@ var calendar_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/carKeyboard.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/carKeyboard.js
var carKeyboard_default = {
// 车牌号键盘
carKeyboard: {
... ... @@ -1975,7 +1975,7 @@ var carKeyboard_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/cell.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/cell.js
var cell_default = {
// cell组件的props
cell: {
... ... @@ -2003,7 +2003,7 @@ var cell_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/cellGroup.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/cellGroup.js
var cellGroup_default = {
// cell-group组件的props
cellGroup: {
... ... @@ -2013,7 +2013,7 @@ var cellGroup_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/checkbox.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/checkbox.js
var checkbox_default = {
// checkbox组件
checkbox: {
... ... @@ -2033,7 +2033,7 @@ var checkbox_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/checkboxGroup.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/checkboxGroup.js
var checkboxGroup_default = {
// checkbox-group组件
checkboxGroup: {
... ... @@ -2055,7 +2055,7 @@ var checkboxGroup_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/circleProgress.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/circleProgress.js
var circleProgress_default = {
// circleProgress 组件
circleProgress: {
... ... @@ -2063,7 +2063,7 @@ var circleProgress_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/code.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/code.js
var code_default = {
// code 组件
code: {
... ... @@ -2076,7 +2076,7 @@ var code_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/codeInput.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/codeInput.js
var codeInput_default = {
// codeInput 组件
codeInput: {
... ... @@ -2098,7 +2098,7 @@ var codeInput_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/col.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/col.js
var col_default = {
// col 组件
col: {
... ... @@ -2110,7 +2110,7 @@ var col_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/collapse.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/collapse.js
var collapse_default = {
// collapse 组件
collapse: {
... ... @@ -2120,7 +2120,7 @@ var collapse_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/collapseItem.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/collapseItem.js
var collapseItem_default = {
// collapseItem 组件
collapseItem: {
... ... @@ -2138,7 +2138,7 @@ var collapseItem_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/columnNotice.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/columnNotice.js
var columnNotice_default = {
// columnNotice 组件
columnNotice: {
... ... @@ -2155,7 +2155,7 @@ var columnNotice_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/countDown.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/countDown.js
var countDown_default = {
// u-count-down 计时器组件
countDown: {
... ... @@ -2166,7 +2166,7 @@ var countDown_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/countTo.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/countTo.js
var countTo_default = {
// countTo 组件
countTo: {
... ... @@ -2184,7 +2184,7 @@ var countTo_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/datetimePicker.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/datetimePicker.js
var datetimePicker_default = {
// datetimePicker 组件
datetimePicker: {
... ... @@ -2213,7 +2213,7 @@ var datetimePicker_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/divider.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/divider.js
var divider_default = {
// divider组件
divider: {
... ... @@ -2228,7 +2228,7 @@ var divider_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/empty.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/empty.js
var empty_default = {
// empty组件
empty: {
... ... @@ -2246,7 +2246,7 @@ var empty_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/form.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/form.js
var form_default = {
// form 组件
form: {
... ... @@ -2261,7 +2261,7 @@ var form_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/formItem.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/formItem.js
var formItem_default = {
// formItem 组件
formItem: {
... ... @@ -2276,7 +2276,7 @@ var formItem_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/gap.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/gap.js
var gap_default = {
// gap组件
gap: {
... ... @@ -2288,7 +2288,7 @@ var gap_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/grid.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/grid.js
var grid_default = {
// grid组件
grid: {
... ... @@ -2298,7 +2298,7 @@ var grid_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/gridItem.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/gridItem.js
var gridItem_default = {
// grid-item组件
gridItem: {
... ... @@ -2307,7 +2307,7 @@ var gridItem_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/icon.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/icon.js
var {
color
} = config_default;
... ... @@ -2334,7 +2334,7 @@ var icon_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/image.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/image.js
var image_default = {
// image组件
image: {
... ... @@ -2357,7 +2357,7 @@ var image_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/indexAnchor.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/indexAnchor.js
var indexAnchor_default = {
// indexAnchor 组件
indexAnchor: {
... ... @@ -2369,7 +2369,7 @@ var indexAnchor_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/indexList.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/indexList.js
var indexList_default = {
// indexList 组件
indexList: {
... ... @@ -2381,7 +2381,7 @@ var indexList_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/input.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/input.js
var input_default = {
// index 组件
input: {
... ... @@ -2422,7 +2422,7 @@ var input_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/keyboard.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/keyboard.js
var keyboard_default = {
// 键盘组件
keyboard: {
... ... @@ -2445,7 +2445,7 @@ var keyboard_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/line.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/line.js
var line_default = {
// line组件
line: {
... ... @@ -2458,7 +2458,7 @@ var line_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/lineProgress.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/lineProgress.js
var lineProgress_default = {
// lineProgress 组件
lineProgress: {
... ... @@ -2470,7 +2470,7 @@ var lineProgress_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/link.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/link.js
var {
color: color2
} = config_default;
... ... @@ -2487,7 +2487,7 @@ var link_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/list.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/list.js
var list_default = {
// list 组件
list: {
... ... @@ -2508,7 +2508,7 @@ var list_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/listItem.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/listItem.js
var listItem_default = {
// listItem 组件
listItem: {
... ... @@ -2516,7 +2516,7 @@ var listItem_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/loadingIcon.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/loadingIcon.js
var {
color: color3
} = config_default;
... ... @@ -2537,7 +2537,7 @@ var loadingIcon_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/loadingPage.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/loadingPage.js
var loadingPage_default = {
// loading-page组件
loadingPage: {
... ... @@ -2553,7 +2553,7 @@ var loadingPage_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/loadmore.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/loadmore.js
var loadmore_default = {
// loadmore 组件
loadmore: {
... ... @@ -2578,7 +2578,7 @@ var loadmore_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/modal.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/modal.js
var modal_default = {
// modal 组件
modal: {
... ... @@ -2601,7 +2601,7 @@ var modal_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/color.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/color.js
var color4 = {
primary: "#3c9cff",
info: "#909399",
... ... @@ -2617,7 +2617,7 @@ var color4 = {
};
var color_default = color4;
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/navbar.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/navbar.js
var navbar_default = {
// navbar 组件
navbar: {
... ... @@ -2640,7 +2640,7 @@ var navbar_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/noNetwork.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/noNetwork.js
var noNetwork_default = {
// noNetwork
noNetwork: {
... ... @@ -2650,7 +2650,7 @@ var noNetwork_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/noticeBar.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/noticeBar.js
var noticeBar_default = {
// noticeBar
noticeBar: {
... ... @@ -2670,7 +2670,7 @@ var noticeBar_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/notify.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/notify.js
var notify_default = {
// notify组件
notify: {
... ... @@ -2685,7 +2685,7 @@ var notify_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/numberBox.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/numberBox.js
var numberBox_default = {
// 步进器组件
numberBox: {
... ... @@ -2713,7 +2713,7 @@ var numberBox_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/numberKeyboard.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/numberKeyboard.js
var numberKeyboard_default = {
// 数字键盘
numberKeyboard: {
... ... @@ -2723,7 +2723,7 @@ var numberKeyboard_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/overlay.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/overlay.js
var overlay_default = {
// overlay组件
overlay: {
... ... @@ -2734,7 +2734,7 @@ var overlay_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/parse.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/parse.js
var parse_default = {
// parse
parse: {
... ... @@ -2749,7 +2749,7 @@ var parse_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/picker.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/picker.js
var picker_default = {
// picker
picker: {
... ... @@ -2771,7 +2771,7 @@ var picker_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/popup.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/popup.js
var popup_default = {
// popup组件
popup: {
... ... @@ -2794,7 +2794,7 @@ var popup_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/radio.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/radio.js
var radio_default = {
// radio组件
radio: {
... ... @@ -2814,7 +2814,7 @@ var radio_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/radioGroup.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/radioGroup.js
var radioGroup_default = {
// radio-group组件
radioGroup: {
... ... @@ -2837,7 +2837,7 @@ var radioGroup_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/rate.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/rate.js
var rate_default = {
// rate组件
rate: {
... ... @@ -2856,7 +2856,7 @@ var rate_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/readMore.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/readMore.js
var readMore_default = {
// readMore
readMore: {
... ... @@ -2871,7 +2871,7 @@ var readMore_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/row.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/row.js
var row_default = {
// row
row: {
... ... @@ -2881,7 +2881,7 @@ var row_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/rowNotice.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/rowNotice.js
var rowNotice_default = {
// rowNotice
rowNotice: {
... ... @@ -2895,7 +2895,7 @@ var rowNotice_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/scrollList.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/scrollList.js
var scrollList_default = {
// scrollList
scrollList: {
... ... @@ -2908,7 +2908,7 @@ var scrollList_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/search.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/search.js
var search_default = {
// search
search: {
... ... @@ -2938,7 +2938,7 @@ var search_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/section.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/section.js
var section_default = {
// u-section组件
section: {
... ... @@ -2955,7 +2955,7 @@ var section_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/skeleton.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/skeleton.js
var skeleton_default = {
// skeleton
skeleton: {
... ... @@ -2973,7 +2973,7 @@ var skeleton_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/slider.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/slider.js
var slider_default = {
// slider组件
slider: {
... ... @@ -2992,7 +2992,7 @@ var slider_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/statusBar.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/statusBar.js
var statusBar_default = {
// statusBar
statusBar: {
... ... @@ -3000,7 +3000,7 @@ var statusBar_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/steps.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/steps.js
var steps_default = {
// steps组件
steps: {
... ... @@ -3014,7 +3014,7 @@ var steps_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/stepsItem.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/stepsItem.js
var stepsItem_default = {
// steps-item组件
stepsItem: {
... ... @@ -3025,7 +3025,7 @@ var stepsItem_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/sticky.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/sticky.js
var sticky_default = {
// sticky组件
sticky: {
... ... @@ -3038,7 +3038,7 @@ var sticky_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/subsection.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/subsection.js
var subsection_default = {
// subsection组件
subsection: {
... ... @@ -3054,7 +3054,7 @@ var subsection_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/swipeAction.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/swipeAction.js
var swipeAction_default = {
// swipe-action组件
swipeAction: {
... ... @@ -3062,7 +3062,7 @@ var swipeAction_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/swipeActionItem.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/swipeActionItem.js
var swipeActionItem_default = {
// swipeActionItem 组件
swipeActionItem: {
... ... @@ -3076,7 +3076,7 @@ var swipeActionItem_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/swiper.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/swiper.js
var swiper_default = {
// swiper 组件
swiper: {
... ... @@ -3107,7 +3107,7 @@ var swiper_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/swipterIndicator.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/swipterIndicator.js
var swipterIndicator_default = {
// swiperIndicator 组件
swiperIndicator: {
... ... @@ -3119,7 +3119,7 @@ var swipterIndicator_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/switch.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/switch.js
var switch_default = {
// switch
switch: {
... ... @@ -3136,7 +3136,7 @@ var switch_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/tabbar.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/tabbar.js
var tabbar_default = {
// tabbar
tabbar: {
... ... @@ -3151,7 +3151,7 @@ var tabbar_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/tabbarItem.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/tabbarItem.js
var tabbarItem_default = {
//
tabbarItem: {
... ... @@ -3164,7 +3164,7 @@ var tabbarItem_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/tabs.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/tabs.js
var tabs_default = {
//
tabs: {
... ... @@ -3189,7 +3189,7 @@ var tabs_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/tag.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/tag.js
var tag_default = {
// tag 组件
tag: {
... ... @@ -3211,7 +3211,7 @@ var tag_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/text.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/text.js
var text_default = {
// text 组件
text: {
... ... @@ -3241,7 +3241,7 @@ var text_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/textarea.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/textarea.js
var textarea_default = {
// textarea 组件
textarea: {
... ... @@ -3270,7 +3270,7 @@ var textarea_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/toast.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/toast.js
var toast_default = {
// toast组件
toast: {
... ... @@ -3293,7 +3293,7 @@ var toast_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/toolbar.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/toolbar.js
var toolbar_default = {
// toolbar 组件
toolbar: {
... ... @@ -3306,7 +3306,7 @@ var toolbar_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/tooltip.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/tooltip.js
var tooltip_default = {
// tooltip 组件
tooltip: {
... ... @@ -3324,7 +3324,7 @@ var tooltip_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/transition.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/transition.js
var transition_default = {
// transition动画组件的props
transition: {
... ... @@ -3335,7 +3335,7 @@ var transition_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props/upload.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props/upload.js
var upload_default = {
// upload组件
upload: {
... ... @@ -3364,7 +3364,7 @@ var upload_default = {
}
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/props.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/props.js
var {
color: color5
} = config_default;
... ... @@ -3459,7 +3459,7 @@ var props_default = {
...upload_default
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/config/zIndex.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/config/zIndex.js
var zIndex_default = {
toast: 10090,
noNetwork: 10080,
... ... @@ -3472,13 +3472,13 @@ var zIndex_default = {
indexListSticky: 965
};
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/libs/function/platform.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/libs/function/platform.js
var platform = "none";
platform = "vue3";
platform = "h5";
var platform_default = platform;
// C:/Users/zhuo/Desktop/practice/vue-three/AI-interlocution/node_modules/uview-plus/index.js
// ../../../../uni/ai-dialogue/node_modules/uview-plus/index.js
var pleaseSetTranspileDependencies = {};
var babelTest = pleaseSetTranspileDependencies == null ? void 0 : pleaseSetTranspileDependencies.test;
var $u = {
... ...
The MIT License (MIT)
Copyright (c) 2012 vic99999@yandex.ru
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
... ...
MIT License
Copyright (c) 2018 Viktor
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
... ...
EventSource polyfill - https://html.spec.whatwg.org/multipage/server-sent-events.html#server-sent-events
========================================================
Пожалуйста не используйте эту обосранную библиотеку!
Installing:
-----------
You can get the code from npm or bower:
```
npm install event-source-polyfill
```
```
bower install event-source-polyfill
```
Just include `src/eventsource.js` or `src/eventsource.min.js` in your page to use the polyfill.
Ionic2/Angular2 Installation:
-----------------------------
Unless a typescript definition file is created for this polyfill, this is how you would use it in an Ionic2 project. It should (in theory) be very similar in an Angular2 project.
```
npm install event-source-polyfill
```
Add to (or create) src/app/polyfills.ts (path is relative to where polyfills.ts is) :
```
import 'path/to/event-source-polyfill/src/eventsource.min.js'
```
Add anywhere you need access to EventSourcePolyfill class :
```
declare var EventSourcePolyfill: any;
```
Usage with webpack/browserify:
------------------------------
```javascript
import { NativeEventSource, EventSourcePolyfill } from 'event-source-polyfill';
const EventSource = NativeEventSource || EventSourcePolyfill;
// OR: may also need to set as global property
global.EventSource = NativeEventSource || EventSourcePolyfill;
```
Browser support:
----------------
* IE 10+, Firefox 3.5+, Chrome 3+, Safari 4+, Opera 12+
* IE 8 - IE 9: XDomainRequest is used internally, which has some limitations (2KB padding in the beginning is required, no way to send cookies, no way to use client certificates)
* It works on Mobile Safari, Opera Mobile, Chrome for Android, Firefox for Android
* It does not work on: Android Browser(requires 4 KB padding after every chunk), Opera Mini
Advantages:
-----------
* Simple server-side code
* Cross-domain requests support
Server-side requirements:
-------------------------
* "Last-Event-ID" is sent in a query string (CORS + "Last-Event-ID" header is not supported by all browsers)
* It is required to send 2 KB padding for IE < 10 and Chrome < 13 at the top of the response stream (the polyfill sends `padding=true` query argument)
* You need to send "comment" messages each 15-30 seconds, these messages will be used as heartbeat to detect disconnects - see https://bugzilla.mozilla.org/show_bug.cgi?id=444328
Specification:
--------------
* http://www.w3.org/TR/eventsource/
Build:
------
* To build EventSource, just install npm modules (`npm install`) and then run the build (`npm run build`). It should generate a new version of `src/eventsource.min.js`.
Notes:
-----
* If you are using HTTP Basic Authentication, you can embed credentials into the URL - `http://username:password@github.com`.
Custom Headers:
---------------
```
var es = new EventSourcePolyfill('/events', {
headers: {
'X-Custom-Header': 'value'
}
});
```
Custom query parameter name for the last event id:
---------------
* Some server require a special query parameter name for last-event-id, you can change that via option
* The default is `lastEventId`
* Example for mercure-hub (https://mercure.rocks/)
```
var es = new EventSourcePolyfill(hubUrl, {
lastEventIdQueryParameterName: 'Last-Event-Id'
});
```
Other EventSource polyfills:
----------------------------
* https://github.com/remy/polyfills/blob/master/EventSource.js by Remy Sharp
* https://github.com/rwldrn/jquery.eventsource by Rick Waldron
* https://github.com/amvtek/EventSource by AmvTek
EXAMPLE
-------
server-side (node.js)
---------------------
```javascript
var PORT = 8081;
var http = require("http");
var fs = require("fs");
var url = require("url");
http.createServer(function (request, response) {
var parsedURL = url.parse(request.url, true);
var pathname = parsedURL.pathname;
if (pathname === "/events.php") {
response.writeHead(200, {
"Content-Type": "text/event-stream",
"Cache-Control": "no-store",
"Access-Control-Allow-Origin": "*"
});
var padding = new Array(2049);
response.write(":" + padding.join(" ") + "\n"); // 2kB padding for IE
response.write("retry: 2000\n");
var lastEventId = Number(request.headers["last-event-id"]) || Number(parsedURL.query.lastEventId) || 0;
var timeoutId = 0;
var i = lastEventId;
var c = i + 100;
var f = function () {
if (++i < c) {
response.write("id: " + i + "\n");
response.write("data: " + i + "\n\n");
timeoutId = setTimeout(f, 1000);
} else {
response.end();
}
};
f();
response.on("close", function () {
clearTimeout(timeoutId);
});
} else {
if (pathname === "/") {
pathname = "/index.html";
}
if (pathname === "/index.html" || pathname === "../src/eventsource.js") {
response.writeHead(200, {
"Content-Type": pathname === "/index.html" ? "text/html" : "text/javascript"
});
response.write(fs.readFileSync(__dirname + pathname));
}
response.end();
}
}).listen(PORT);
```
or use PHP (see php/events.php)
-------------------------------
```php
<?php
header("Content-Type: text/event-stream");
header("Cache-Control: no-store");
header("Access-Control-Allow-Origin: *");
$lastEventId = floatval(isset($_SERVER["HTTP_LAST_EVENT_ID"]) ? $_SERVER["HTTP_LAST_EVENT_ID"] : 0);
if ($lastEventId == 0) {
$lastEventId = floatval(isset($_GET["lastEventId"]) ? $_GET["lastEventId"] : 0);
}
echo ":" . str_repeat(" ", 2048) . "\n"; // 2 kB padding for IE
echo "retry: 2000\n";
// event-stream
$i = $lastEventId;
$c = $i + 100;
while (++$i < $c) {
echo "id: " . $i . "\n";
echo "data: " . $i . ";\n\n";
ob_flush();
flush();
sleep(1);
}
?>
```
index.html (php/index.html):
----------------------------
```html
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<title>EventSource example</title>
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<script src="../src/eventsource.js"></script>
<script>
var es = new EventSource("events.php");
var listener = function (event) {
var div = document.createElement("div");
var type = event.type;
div.appendChild(document.createTextNode(type + ": " + (type === "message" ? event.data : es.url)));
document.body.appendChild(div);
};
es.addEventListener("open", listener);
es.addEventListener("message", listener);
es.addEventListener("error", listener);
</script>
</head>
<body>
</body>
</html>
```
Usage in node.js:
=================
With some dynamic imports it may work in node.js:
Install the library and the dependency:
`npm install @titelmedia/node-fetch`
`npm install event-source-polyfill`
x.js:
```javascript
// The @titelmedia/node-fetch is used instead of node-fetch as it supports ReadableStream Web API
import('@titelmedia/node-fetch').then(function (fetch) {
globalThis.fetch = fetch.default;
globalThis.Response = fetch.default.Response;
import('event-source-polyfill').then(function (x) {
var es = new x.default.EventSourcePolyfill('http://localhost:8004/events');
es.onerror = es.onopen = es.onmessage = function (event) {
console.log(event.type + ': ' + event.data);
};
});
});
```
`node --experimental-modules ./x.js`
License
-------
The MIT License (MIT)
Copyright (c) 2012 vic99999@yandex.ru
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
... ...
{
"name": "event-source-polyfill",
"version": "1.0.31",
"description": "A polyfill for http://www.w3.org/TR/eventsource/ ",
"main": "src/eventsource.js",
"scripts": {
"build": "grunt"
},
"repository": {
"type": "git",
"url": "git://github.com/Yaffle/EventSource.git"
},
"keywords": [
"sse",
"server sent events",
"eventsource",
"event-source",
"polyfill"
],
"files": [
"src/*"
],
"author": "Yaffle (https://github.com/Yaffle)",
"license": "MIT",
"bugs": {
"url": "https://github.com/Yaffle/EventSource/issues"
},
"homepage": "https://github.com/Yaffle/EventSource",
"devDependencies": {
"grunt": "^1.4.1",
"grunt-cli": "^1.4.3",
"grunt-contrib-uglify": "^5.0.1"
}
}
... ...
/** @license
* eventsource.js
* Available under MIT License (MIT)
* https://github.com/Yaffle/EventSource/
*/
/*jslint indent: 2, vars: true, plusplus: true */
/*global setTimeout, clearTimeout */
(function (global) {
"use strict";
var setTimeout = global.setTimeout;
var clearTimeout = global.clearTimeout;
var XMLHttpRequest = global.XMLHttpRequest;
var XDomainRequest = global.XDomainRequest;
var ActiveXObject = global.ActiveXObject;
var NativeEventSource = global.EventSource;
var document = global.document;
var Promise = global.Promise;
var fetch = global.fetch;
var Response = global.Response;
var TextDecoder = global.TextDecoder;
var TextEncoder = global.TextEncoder;
var AbortController = global.AbortController;
if (typeof window !== "undefined" && typeof document !== "undefined" && !("readyState" in document) && document.body == null) { // Firefox 2
document.readyState = "loading";
window.addEventListener("load", function (event) {
document.readyState = "complete";
}, false);
}
if (XMLHttpRequest == null && ActiveXObject != null) { // https://developer.mozilla.org/en-US/docs/Web/API/XMLHttpRequest/Using_XMLHttpRequest_in_IE6
XMLHttpRequest = function () {
return new ActiveXObject("Microsoft.XMLHTTP");
};
}
if (Object.create == undefined) {
Object.create = function (C) {
function F(){}
F.prototype = C;
return new F();
};
}
if (!Date.now) {
Date.now = function now() {
return new Date().getTime();
};
}
// see #118 (Promise#finally with polyfilled Promise)
// see #123 (data URLs crash Edge)
// see #125 (CSP violations)
// see pull/#138
// => No way to polyfill Promise#finally
if (AbortController == undefined) {
var originalFetch2 = fetch;
fetch = function (url, options) {
var signal = options.signal;
return originalFetch2(url, {headers: options.headers, credentials: options.credentials, cache: options.cache}).then(function (response) {
var reader = response.body.getReader();
signal._reader = reader;
if (signal._aborted) {
signal._reader.cancel();
}
return {
status: response.status,
statusText: response.statusText,
headers: response.headers,
body: {
getReader: function () {
return reader;
}
}
};
});
};
AbortController = function () {
this.signal = {
_reader: null,
_aborted: false
};
this.abort = function () {
if (this.signal._reader != null) {
this.signal._reader.cancel();
}
this.signal._aborted = true;
};
};
}
function TextDecoderPolyfill() {
this.bitsNeeded = 0;
this.codePoint = 0;
}
TextDecoderPolyfill.prototype.decode = function (octets) {
function valid(codePoint, shift, octetsCount) {
if (octetsCount === 1) {
return codePoint >= 0x0080 >> shift && codePoint << shift <= 0x07FF;
}
if (octetsCount === 2) {
return codePoint >= 0x0800 >> shift && codePoint << shift <= 0xD7FF || codePoint >= 0xE000 >> shift && codePoint << shift <= 0xFFFF;
}
if (octetsCount === 3) {
return codePoint >= 0x010000 >> shift && codePoint << shift <= 0x10FFFF;
}
throw new Error();
}
function octetsCount(bitsNeeded, codePoint) {
if (bitsNeeded === 6 * 1) {
return codePoint >> 6 > 15 ? 3 : codePoint > 31 ? 2 : 1;
}
if (bitsNeeded === 6 * 2) {
return codePoint > 15 ? 3 : 2;
}
if (bitsNeeded === 6 * 3) {
return 3;
}
throw new Error();
}
var REPLACER = 0xFFFD;
var string = "";
var bitsNeeded = this.bitsNeeded;
var codePoint = this.codePoint;
for (var i = 0; i < octets.length; i += 1) {
var octet = octets[i];
if (bitsNeeded !== 0) {
if (octet < 128 || octet > 191 || !valid(codePoint << 6 | octet & 63, bitsNeeded - 6, octetsCount(bitsNeeded, codePoint))) {
bitsNeeded = 0;
codePoint = REPLACER;
string += String.fromCharCode(codePoint);
}
}
if (bitsNeeded === 0) {
if (octet >= 0 && octet <= 127) {
bitsNeeded = 0;
codePoint = octet;
} else if (octet >= 192 && octet <= 223) {
bitsNeeded = 6 * 1;
codePoint = octet & 31;
} else if (octet >= 224 && octet <= 239) {
bitsNeeded = 6 * 2;
codePoint = octet & 15;
} else if (octet >= 240 && octet <= 247) {
bitsNeeded = 6 * 3;
codePoint = octet & 7;
} else {
bitsNeeded = 0;
codePoint = REPLACER;
}
if (bitsNeeded !== 0 && !valid(codePoint, bitsNeeded, octetsCount(bitsNeeded, codePoint))) {
bitsNeeded = 0;
codePoint = REPLACER;
}
} else {
bitsNeeded -= 6;
codePoint = codePoint << 6 | octet & 63;
}
if (bitsNeeded === 0) {
if (codePoint <= 0xFFFF) {
string += String.fromCharCode(codePoint);
} else {
string += String.fromCharCode(0xD800 + (codePoint - 0xFFFF - 1 >> 10));
string += String.fromCharCode(0xDC00 + (codePoint - 0xFFFF - 1 & 0x3FF));
}
}
}
this.bitsNeeded = bitsNeeded;
this.codePoint = codePoint;
return string;
};
// Firefox < 38 throws an error with stream option
var supportsStreamOption = function () {
try {
return new TextDecoder().decode(new TextEncoder().encode("test"), {stream: true}) === "test";
} catch (error) {
console.debug("TextDecoder does not support streaming option. Using polyfill instead: " + error);
}
return false;
};
// IE, Edge
if (TextDecoder == undefined || TextEncoder == undefined || !supportsStreamOption()) {
TextDecoder = TextDecoderPolyfill;
}
var k = function () {
};
function XHRWrapper(xhr) {
this.withCredentials = false;
this.readyState = 0;
this.status = 0;
this.statusText = "";
this.responseText = "";
this.onprogress = k;
this.onload = k;
this.onerror = k;
this.onreadystatechange = k;
this._contentType = "";
this._xhr = xhr;
this._sendTimeout = 0;
this._abort = k;
}
XHRWrapper.prototype.open = function (method, url) {
this._abort(true);
var that = this;
var xhr = this._xhr;
var state = 1;
var timeout = 0;
this._abort = function (silent) {
if (that._sendTimeout !== 0) {
clearTimeout(that._sendTimeout);
that._sendTimeout = 0;
}
if (state === 1 || state === 2 || state === 3) {
state = 4;
xhr.onload = k;
xhr.onerror = k;
xhr.onabort = k;
xhr.onprogress = k;
xhr.onreadystatechange = k;
// IE 8 - 9: XDomainRequest#abort() does not fire any event
// Opera < 10: XMLHttpRequest#abort() does not fire any event
xhr.abort();
if (timeout !== 0) {
clearTimeout(timeout);
timeout = 0;
}
if (!silent) {
that.readyState = 4;
that.onabort(null);
that.onreadystatechange();
}
}
state = 0;
};
var onStart = function () {
if (state === 1) {
//state = 2;
var status = 0;
var statusText = "";
var contentType = undefined;
if (!("contentType" in xhr)) {
try {
status = xhr.status;
statusText = xhr.statusText;
contentType = xhr.getResponseHeader("Content-Type");
} catch (error) {
// IE < 10 throws exception for `xhr.status` when xhr.readyState === 2 || xhr.readyState === 3
// Opera < 11 throws exception for `xhr.status` when xhr.readyState === 2
// https://bugs.webkit.org/show_bug.cgi?id=29121
status = 0;
statusText = "";
contentType = undefined;
// Firefox < 14, Chrome ?, Safari ?
// https://bugs.webkit.org/show_bug.cgi?id=29658
// https://bugs.webkit.org/show_bug.cgi?id=77854
}
} else {
status = 200;
statusText = "OK";
contentType = xhr.contentType;
}
if (status !== 0) {
state = 2;
that.readyState = 2;
that.status = status;
that.statusText = statusText;
that._contentType = contentType;
that.onreadystatechange();
}
}
};
var onProgress = function () {
onStart();
if (state === 2 || state === 3) {
state = 3;
var responseText = "";
try {
responseText = xhr.responseText;
} catch (error) {
// IE 8 - 9 with XMLHttpRequest
}
that.readyState = 3;
that.responseText = responseText;
that.onprogress();
}
};
var onFinish = function (type, event) {
if (event == null || event.preventDefault == null) {
event = {
preventDefault: k
};
}
// Firefox 52 fires "readystatechange" (xhr.readyState === 4) without final "readystatechange" (xhr.readyState === 3)
// IE 8 fires "onload" without "onprogress"
onProgress();
if (state === 1 || state === 2 || state === 3) {
state = 4;
if (timeout !== 0) {
clearTimeout(timeout);
timeout = 0;
}
that.readyState = 4;
if (type === "load") {
that.onload(event);
} else if (type === "error") {
that.onerror(event);
} else if (type === "abort") {
that.onabort(event);
} else {
throw new TypeError();
}
that.onreadystatechange();
}
};
var onReadyStateChange = function (event) {
if (xhr != undefined) { // Opera 12
if (xhr.readyState === 4) {
if (!("onload" in xhr) || !("onerror" in xhr) || !("onabort" in xhr)) {
onFinish(xhr.responseText === "" ? "error" : "load", event);
}
} else if (xhr.readyState === 3) {
if (!("onprogress" in xhr)) { // testing XMLHttpRequest#responseText too many times is too slow in IE 11
// and in Firefox 3.6
onProgress();
}
} else if (xhr.readyState === 2) {
onStart();
}
}
};
var onTimeout = function () {
timeout = setTimeout(function () {
onTimeout();
}, 500);
if (xhr.readyState === 3) {
onProgress();
}
};
// XDomainRequest#abort removes onprogress, onerror, onload
if ("onload" in xhr) {
xhr.onload = function (event) {
onFinish("load", event);
};
}
if ("onerror" in xhr) {
xhr.onerror = function (event) {
onFinish("error", event);
};
}
// improper fix to match Firefox behaviour, but it is better than just ignore abort
// see https://bugzilla.mozilla.org/show_bug.cgi?id=768596
// https://bugzilla.mozilla.org/show_bug.cgi?id=880200
// https://code.google.com/p/chromium/issues/detail?id=153570
// IE 8 fires "onload" without "onprogress
if ("onabort" in xhr) {
xhr.onabort = function (event) {
onFinish("abort", event);
};
}
if ("onprogress" in xhr) {
xhr.onprogress = onProgress;
}
// IE 8 - 9 (XMLHTTPRequest)
// Opera < 12
// Firefox < 3.5
// Firefox 3.5 - 3.6 - ? < 9.0
// onprogress is not fired sometimes or delayed
// see also #64 (significant lag in IE 11)
if ("onreadystatechange" in xhr) {
xhr.onreadystatechange = function (event) {
onReadyStateChange(event);
};
}
if ("contentType" in xhr || !("ontimeout" in XMLHttpRequest.prototype)) {
url += (url.indexOf("?") === -1 ? "?" : "&") + "padding=true";
}
xhr.open(method, url, true);
if ("readyState" in xhr) {
// workaround for Opera 12 issue with "progress" events
// #91 (XMLHttpRequest onprogress not fired for streaming response in Edge 14-15-?)
timeout = setTimeout(function () {
onTimeout();
}, 0);
}
};
XHRWrapper.prototype.abort = function () {
this._abort(false);
};
XHRWrapper.prototype.getResponseHeader = function (name) {
return this._contentType;
};
XHRWrapper.prototype.setRequestHeader = function (name, value) {
var xhr = this._xhr;
if ("setRequestHeader" in xhr) {
xhr.setRequestHeader(name, value);
}
};
XHRWrapper.prototype.getAllResponseHeaders = function () {
// XMLHttpRequest#getAllResponseHeaders returns null for CORS requests in Firefox 3.6.28
return this._xhr.getAllResponseHeaders != undefined ? this._xhr.getAllResponseHeaders() || "" : "";
};
XHRWrapper.prototype.send = function () {
// loading indicator in Safari < ? (6), Chrome < 14, Firefox
// https://bugzilla.mozilla.org/show_bug.cgi?id=736723
if ((!("ontimeout" in XMLHttpRequest.prototype) || (!("sendAsBinary" in XMLHttpRequest.prototype) && !("mozAnon" in XMLHttpRequest.prototype))) &&
document != undefined &&
document.readyState != undefined &&
document.readyState !== "complete") {
var that = this;
that._sendTimeout = setTimeout(function () {
that._sendTimeout = 0;
that.send();
}, 4);
return;
}
var xhr = this._xhr;
// withCredentials should be set after "open" for Safari and Chrome (< 19 ?)
if ("withCredentials" in xhr) {
xhr.withCredentials = this.withCredentials;
}
try {
// xhr.send(); throws "Not enough arguments" in Firefox 3.0
xhr.send(undefined);
} catch (error1) {
// Safari 5.1.7, Opera 12
throw error1;
}
};
function toLowerCase(name) {
return name.replace(/[A-Z]/g, function (c) {
return String.fromCharCode(c.charCodeAt(0) + 0x20);
});
}
function HeadersPolyfill(all) {
// Get headers: implemented according to mozilla's example code: https://developer.mozilla.org/en-US/docs/Web/API/XMLHttpRequest/getAllResponseHeaders#Example
var map = Object.create(null);
var array = all.split("\r\n");
for (var i = 0; i < array.length; i += 1) {
var line = array[i];
var parts = line.split(": ");
var name = parts.shift();
var value = parts.join(": ");
map[toLowerCase(name)] = value;
}
this._map = map;
}
HeadersPolyfill.prototype.get = function (name) {
return this._map[toLowerCase(name)];
};
if (XMLHttpRequest != null && XMLHttpRequest.HEADERS_RECEIVED == null) { // IE < 9, Firefox 3.6
XMLHttpRequest.HEADERS_RECEIVED = 2;
}
function XHRTransport() {
}
XHRTransport.prototype.open = function (xhr, onStartCallback, onProgressCallback, onFinishCallback, url, withCredentials, headers) {
xhr.open("GET", url);
var offset = 0;
xhr.onprogress = function () {
var responseText = xhr.responseText;
var chunk = responseText.slice(offset);
offset += chunk.length;
onProgressCallback(chunk);
};
xhr.onerror = function (event) {
event.preventDefault();
onFinishCallback(new Error("NetworkError"));
};
xhr.onload = function () {
onFinishCallback(null);
};
xhr.onabort = function () {
onFinishCallback(null);
};
xhr.onreadystatechange = function () {
if (xhr.readyState === XMLHttpRequest.HEADERS_RECEIVED) {
var status = xhr.status;
var statusText = xhr.statusText;
var contentType = xhr.getResponseHeader("Content-Type");
var headers = xhr.getAllResponseHeaders();
onStartCallback(status, statusText, contentType, new HeadersPolyfill(headers));
}
};
xhr.withCredentials = withCredentials;
for (var name in headers) {
if (Object.prototype.hasOwnProperty.call(headers, name)) {
xhr.setRequestHeader(name, headers[name]);
}
}
xhr.send();
return xhr;
};
function HeadersWrapper(headers) {
this._headers = headers;
}
HeadersWrapper.prototype.get = function (name) {
return this._headers.get(name);
};
function FetchTransport() {
}
FetchTransport.prototype.open = function (xhr, onStartCallback, onProgressCallback, onFinishCallback, url, withCredentials, headers) {
var reader = null;
var controller = new AbortController();
var signal = controller.signal;
var textDecoder = new TextDecoder();
fetch(url, {
headers: headers,
credentials: withCredentials ? "include" : "same-origin",
signal: signal,
cache: "no-store"
}).then(function (response) {
reader = response.body.getReader();
onStartCallback(response.status, response.statusText, response.headers.get("Content-Type"), new HeadersWrapper(response.headers));
// see https://github.com/promises-aplus/promises-spec/issues/179
return new Promise(function (resolve, reject) {
var readNextChunk = function () {
reader.read().then(function (result) {
if (result.done) {
//Note: bytes in textDecoder are ignored
resolve(undefined);
} else {
var chunk = textDecoder.decode(result.value, {stream: true});
onProgressCallback(chunk);
readNextChunk();
}
})["catch"](function (error) {
reject(error);
});
};
readNextChunk();
});
})["catch"](function (error) {
if (error.name === "AbortError") {
return undefined;
} else {
return error;
}
}).then(function (error) {
onFinishCallback(error);
});
return {
abort: function () {
if (reader != null) {
reader.cancel(); // https://bugzilla.mozilla.org/show_bug.cgi?id=1583815
}
controller.abort();
}
};
};
function EventTarget() {
this._listeners = Object.create(null);
}
function throwError(e) {
setTimeout(function () {
throw e;
}, 0);
}
EventTarget.prototype.dispatchEvent = function (event) {
event.target = this;
var typeListeners = this._listeners[event.type];
if (typeListeners != undefined) {
var length = typeListeners.length;
for (var i = 0; i < length; i += 1) {
var listener = typeListeners[i];
try {
if (typeof listener.handleEvent === "function") {
listener.handleEvent(event);
} else {
listener.call(this, event);
}
} catch (e) {
throwError(e);
}
}
}
};
EventTarget.prototype.addEventListener = function (type, listener) {
type = String(type);
var listeners = this._listeners;
var typeListeners = listeners[type];
if (typeListeners == undefined) {
typeListeners = [];
listeners[type] = typeListeners;
}
var found = false;
for (var i = 0; i < typeListeners.length; i += 1) {
if (typeListeners[i] === listener) {
found = true;
}
}
if (!found) {
typeListeners.push(listener);
}
};
EventTarget.prototype.removeEventListener = function (type, listener) {
type = String(type);
var listeners = this._listeners;
var typeListeners = listeners[type];
if (typeListeners != undefined) {
var filtered = [];
for (var i = 0; i < typeListeners.length; i += 1) {
if (typeListeners[i] !== listener) {
filtered.push(typeListeners[i]);
}
}
if (filtered.length === 0) {
delete listeners[type];
} else {
listeners[type] = filtered;
}
}
};
function Event(type) {
this.type = type;
this.target = undefined;
}
function MessageEvent(type, options) {
Event.call(this, type);
this.data = options.data;
this.lastEventId = options.lastEventId;
}
MessageEvent.prototype = Object.create(Event.prototype);
function ConnectionEvent(type, options) {
Event.call(this, type);
this.status = options.status;
this.statusText = options.statusText;
this.headers = options.headers;
}
ConnectionEvent.prototype = Object.create(Event.prototype);
function ErrorEvent(type, options) {
Event.call(this, type);
this.error = options.error;
}
ErrorEvent.prototype = Object.create(Event.prototype);
var WAITING = -1;
var CONNECTING = 0;
var OPEN = 1;
var CLOSED = 2;
var AFTER_CR = -1;
var FIELD_START = 0;
var FIELD = 1;
var VALUE_START = 2;
var VALUE = 3;
var contentTypeRegExp = /^text\/event\-stream(;.*)?$/i;
var MINIMUM_DURATION = 1000;
var MAXIMUM_DURATION = 18000000;
var parseDuration = function (value, def) {
var n = value == null ? def : parseInt(value, 10);
if (n !== n) {
n = def;
}
return clampDuration(n);
};
var clampDuration = function (n) {
return Math.min(Math.max(n, MINIMUM_DURATION), MAXIMUM_DURATION);
};
var fire = function (that, f, event) {
try {
if (typeof f === "function") {
f.call(that, event);
}
} catch (e) {
throwError(e);
}
};
function EventSourcePolyfill(url, options) {
EventTarget.call(this);
options = options || {};
this.onopen = undefined;
this.onmessage = undefined;
this.onerror = undefined;
this.url = undefined;
this.readyState = undefined;
this.withCredentials = undefined;
this.headers = undefined;
this._close = undefined;
start(this, url, options);
}
function getBestXHRTransport() {
return (XMLHttpRequest != undefined && ("withCredentials" in XMLHttpRequest.prototype)) || XDomainRequest == undefined
? new XMLHttpRequest()
: new XDomainRequest();
}
var isFetchSupported = fetch != undefined && Response != undefined && "body" in Response.prototype;
function start(es, url, options) {
url = String(url);
var withCredentials = Boolean(options.withCredentials);
var lastEventIdQueryParameterName = options.lastEventIdQueryParameterName || "lastEventId";
var initialRetry = clampDuration(1000);
var heartbeatTimeout = parseDuration(options.heartbeatTimeout, 45000);
var lastEventId = "";
var retry = initialRetry;
var wasActivity = false;
var textLength = 0;
var headers = options.headers || {};
var TransportOption = options.Transport;
var xhr = isFetchSupported && TransportOption == undefined ? undefined : new XHRWrapper(TransportOption != undefined ? new TransportOption() : getBestXHRTransport());
var transport = TransportOption != null && typeof TransportOption !== "string" ? new TransportOption() : (xhr == undefined ? new FetchTransport() : new XHRTransport());
var abortController = undefined;
var timeout = 0;
var currentState = WAITING;
var dataBuffer = "";
var lastEventIdBuffer = "";
var eventTypeBuffer = "";
var textBuffer = "";
var state = FIELD_START;
var fieldStart = 0;
var valueStart = 0;
var onStart = function (status, statusText, contentType, headers) {
if (currentState === CONNECTING) {
if (status === 200 && contentType != undefined && contentTypeRegExp.test(contentType)) {
currentState = OPEN;
wasActivity = Date.now();
retry = initialRetry;
es.readyState = OPEN;
var event = new ConnectionEvent("open", {
status: status,
statusText: statusText,
headers: headers
});
es.dispatchEvent(event);
fire(es, es.onopen, event);
} else {
var message = "";
if (status !== 200) {
if (statusText) {
statusText = statusText.replace(/\s+/g, " ");
}
message = "EventSource's response has a status " + status + " " + statusText + " that is not 200. Aborting the connection.";
} else {
message = "EventSource's response has a Content-Type specifying an unsupported type: " + (contentType == undefined ? "-" : contentType.replace(/\s+/g, " ")) + ". Aborting the connection.";
}
close();
var event = new ConnectionEvent("error", {
status: status,
statusText: statusText,
headers: headers
});
es.dispatchEvent(event);
fire(es, es.onerror, event);
console.error(message);
}
}
};
var onProgress = function (textChunk) {
if (currentState === OPEN) {
var n = -1;
for (var i = 0; i < textChunk.length; i += 1) {
var c = textChunk.charCodeAt(i);
if (c === "\n".charCodeAt(0) || c === "\r".charCodeAt(0)) {
n = i;
}
}
var chunk = (n !== -1 ? textBuffer : "") + textChunk.slice(0, n + 1);
textBuffer = (n === -1 ? textBuffer : "") + textChunk.slice(n + 1);
if (textChunk !== "") {
wasActivity = Date.now();
textLength += textChunk.length;
}
for (var position = 0; position < chunk.length; position += 1) {
var c = chunk.charCodeAt(position);
if (state === AFTER_CR && c === "\n".charCodeAt(0)) {
state = FIELD_START;
} else {
if (state === AFTER_CR) {
state = FIELD_START;
}
if (c === "\r".charCodeAt(0) || c === "\n".charCodeAt(0)) {
if (state !== FIELD_START) {
if (state === FIELD) {
valueStart = position + 1;
}
var field = chunk.slice(fieldStart, valueStart - 1);
var value = chunk.slice(valueStart + (valueStart < position && chunk.charCodeAt(valueStart) === " ".charCodeAt(0) ? 1 : 0), position);
if (field === "data") {
dataBuffer += "\n";
dataBuffer += value;
} else if (field === "id") {
lastEventIdBuffer = value;
} else if (field === "event") {
eventTypeBuffer = value;
} else if (field === "retry") {
initialRetry = parseDuration(value, initialRetry);
retry = initialRetry;
} else if (field === "heartbeatTimeout") {
heartbeatTimeout = parseDuration(value, heartbeatTimeout);
if (timeout !== 0) {
clearTimeout(timeout);
timeout = setTimeout(function () {
onTimeout();
}, heartbeatTimeout);
}
}
}
if (state === FIELD_START) {
if (dataBuffer !== "") {
lastEventId = lastEventIdBuffer;
if (eventTypeBuffer === "") {
eventTypeBuffer = "message";
}
var event = new MessageEvent(eventTypeBuffer, {
data: dataBuffer.slice(1),
lastEventId: lastEventIdBuffer
});
es.dispatchEvent(event);
if (eventTypeBuffer === "open") {
fire(es, es.onopen, event);
} else if (eventTypeBuffer === "message") {
fire(es, es.onmessage, event);
} else if (eventTypeBuffer === "error") {
fire(es, es.onerror, event);
}
if (currentState === CLOSED) {
return;
}
}
dataBuffer = "";
eventTypeBuffer = "";
}
state = c === "\r".charCodeAt(0) ? AFTER_CR : FIELD_START;
} else {
if (state === FIELD_START) {
fieldStart = position;
state = FIELD;
}
if (state === FIELD) {
if (c === ":".charCodeAt(0)) {
valueStart = position + 1;
state = VALUE_START;
}
} else if (state === VALUE_START) {
state = VALUE;
}
}
}
}
}
};
var onFinish = function (error) {
if (currentState === OPEN || currentState === CONNECTING) {
currentState = WAITING;
if (timeout !== 0) {
clearTimeout(timeout);
timeout = 0;
}
timeout = setTimeout(function () {
onTimeout();
}, retry);
retry = clampDuration(Math.min(initialRetry * 16, retry * 2));
es.readyState = CONNECTING;
var event = new ErrorEvent("error", {error: error});
es.dispatchEvent(event);
fire(es, es.onerror, event);
if (error != undefined) {
console.error(error);
}
}
};
var close = function () {
currentState = CLOSED;
if (abortController != undefined) {
abortController.abort();
abortController = undefined;
}
if (timeout !== 0) {
clearTimeout(timeout);
timeout = 0;
}
es.readyState = CLOSED;
};
var onTimeout = function () {
timeout = 0;
if (currentState !== WAITING) {
if (!wasActivity && abortController != undefined) {
onFinish(new Error("No activity within " + heartbeatTimeout + " milliseconds." + " " + (currentState === CONNECTING ? "No response received." : textLength + " chars received.") + " " + "Reconnecting."));
if (abortController != undefined) {
abortController.abort();
abortController = undefined;
}
} else {
var nextHeartbeat = Math.max((wasActivity || Date.now()) + heartbeatTimeout - Date.now(), 1);
wasActivity = false;
timeout = setTimeout(function () {
onTimeout();
}, nextHeartbeat);
}
return;
}
wasActivity = false;
textLength = 0;
timeout = setTimeout(function () {
onTimeout();
}, heartbeatTimeout);
currentState = CONNECTING;
dataBuffer = "";
eventTypeBuffer = "";
lastEventIdBuffer = lastEventId;
textBuffer = "";
fieldStart = 0;
valueStart = 0;
state = FIELD_START;
// https://bugzilla.mozilla.org/show_bug.cgi?id=428916
// Request header field Last-Event-ID is not allowed by Access-Control-Allow-Headers.
var requestURL = url;
if (url.slice(0, 5) !== "data:" && url.slice(0, 5) !== "blob:") {
if (lastEventId !== "") {
// Remove the lastEventId parameter if it's already part of the request URL.
var i = url.indexOf("?");
requestURL = i === -1 ? url : url.slice(0, i + 1) + url.slice(i + 1).replace(/(?:^|&)([^=&]*)(?:=[^&]*)?/g, function (p, paramName) {
return paramName === lastEventIdQueryParameterName ? '' : p;
});
// Append the current lastEventId to the request URL.
requestURL += (url.indexOf("?") === -1 ? "?" : "&") + lastEventIdQueryParameterName +"=" + encodeURIComponent(lastEventId);
}
}
var withCredentials = es.withCredentials;
var requestHeaders = {};
requestHeaders["Accept"] = "text/event-stream";
var headers = es.headers;
if (headers != undefined) {
for (var name in headers) {
if (Object.prototype.hasOwnProperty.call(headers, name)) {
requestHeaders[name] = headers[name];
}
}
}
try {
abortController = transport.open(xhr, onStart, onProgress, onFinish, requestURL, withCredentials, requestHeaders);
} catch (error) {
close();
throw error;
}
};
es.url = url;
es.readyState = CONNECTING;
es.withCredentials = withCredentials;
es.headers = headers;
es._close = close;
onTimeout();
}
EventSourcePolyfill.prototype = Object.create(EventTarget.prototype);
EventSourcePolyfill.prototype.CONNECTING = CONNECTING;
EventSourcePolyfill.prototype.OPEN = OPEN;
EventSourcePolyfill.prototype.CLOSED = CLOSED;
EventSourcePolyfill.prototype.close = function () {
this._close();
};
EventSourcePolyfill.CONNECTING = CONNECTING;
EventSourcePolyfill.OPEN = OPEN;
EventSourcePolyfill.CLOSED = CLOSED;
EventSourcePolyfill.prototype.withCredentials = undefined;
var R = NativeEventSource
if (XMLHttpRequest != undefined && (NativeEventSource == undefined || !("withCredentials" in NativeEventSource.prototype))) {
// Why replace a native EventSource ?
// https://bugzilla.mozilla.org/show_bug.cgi?id=444328
// https://bugzilla.mozilla.org/show_bug.cgi?id=831392
// https://code.google.com/p/chromium/issues/detail?id=260144
// https://code.google.com/p/chromium/issues/detail?id=225654
// ...
R = EventSourcePolyfill;
}
(function (factory) {
if (typeof module === "object" && typeof module.exports === "object") {
var v = factory(exports);
if (v !== undefined) module.exports = v;
}
else if (typeof define === "function" && define.amd) {
define(["exports"], factory);
}
else {
factory(global);
}
})(function (exports) {
exports.EventSourcePolyfill = EventSourcePolyfill;
exports.NativeEventSource = NativeEventSource;
exports.EventSource = R;
});
}(typeof globalThis === 'undefined' ? (typeof window !== 'undefined' ? window : typeof self !== 'undefined' ? self : this) : globalThis));
... ...
/** @license
* eventsource.js
* Available under MIT License (MIT)
* https://github.com/Yaffle/EventSource/
*/
!function(e){"use strict";var r,H=e.setTimeout,N=e.clearTimeout,j=e.XMLHttpRequest,o=e.XDomainRequest,t=e.ActiveXObject,n=e.EventSource,i=e.document,w=e.Promise,d=e.fetch,a=e.Response,h=e.TextDecoder,s=e.TextEncoder,p=e.AbortController;function c(){this.bitsNeeded=0,this.codePoint=0}"undefined"==typeof window||void 0===i||"readyState"in i||null!=i.body||(i.readyState="loading",window.addEventListener("load",function(e){i.readyState="complete"},!1)),null==j&&null!=t&&(j=function(){return new t("Microsoft.XMLHTTP")}),null==Object.create&&(Object.create=function(e){function t(){}return t.prototype=e,new t}),Date.now||(Date.now=function(){return(new Date).getTime()}),null==p&&(r=d,d=function(e,t){var n=t.signal;return r(e,{headers:t.headers,credentials:t.credentials,cache:t.cache}).then(function(e){var t=e.body.getReader();return n._reader=t,n._aborted&&n._reader.cancel(),{status:e.status,statusText:e.statusText,headers:e.headers,body:{getReader:function(){return t}}}})},p=function(){this.signal={_reader:null,_aborted:!1},this.abort=function(){null!=this.signal._reader&&this.signal._reader.cancel(),this.signal._aborted=!0}}),c.prototype.decode=function(e){function t(e,t,n){if(1===n)return 128>>t<=e&&e<<t<=2047;if(2===n)return 2048>>t<=e&&e<<t<=55295||57344>>t<=e&&e<<t<=65535;if(3===n)return 65536>>t<=e&&e<<t<=1114111;throw new Error}function n(e,t){if(6===e)return 15<t>>6?3:31<t?2:1;if(12===e)return 15<t?3:2;if(18===e)return 3;throw new Error}for(var r="",o=this.bitsNeeded,i=this.codePoint,a=0;a<e.length;a+=1){var s=e[a];0!==o&&(s<128||191<s||!t(i<<6|63&s,o-6,n(o,i)))&&(o=0,i=65533,r+=String.fromCharCode(i)),0===o?(i=0<=s&&s<=127?(o=0,s):192<=s&&s<=223?(o=6,31&s):224<=s&&s<=239?(o=12,15&s):240<=s&&s<=247?(o=18,7&s):(o=0,65533),0===o||t(i,o,n(o,i))||(o=0,i=65533)):(o-=6,i=i<<6|63&s),0===o&&(i<=65535?r+=String.fromCharCode(i):r=(r+=String.fromCharCode(55296+(i-65535-1>>10)))+String.fromCharCode(56320+(i-65535-1&1023)))}return this.bitsNeeded=o,this.codePoint=i,r};function u(){}null!=h&&null!=s&&function(){try{return"test"===(new h).decode((new s).encode("test"),{stream:!0})}catch(e){}return!1}()||(h=c);function I(e){this.withCredentials=!1,this.readyState=0,this.status=0,this.statusText="",this.responseText="",this.onprogress=u,this.onload=u,this.onerror=u,this.onreadystatechange=u,this._contentType="",this._xhr=e,this._sendTimeout=0,this._abort=u}function l(e){return e.replace(/[A-Z]/g,function(e){return String.fromCharCode(e.charCodeAt(0)+32)})}function f(e){for(var t=Object.create(null),n=e.split("\r\n"),r=0;r<n.length;r+=1){var o=n[r].split(": "),i=o.shift(),o=o.join(": ");t[l(i)]=o}this._map=t}function P(){}function y(e){this._headers=e}function L(){}function M(){this._listeners=Object.create(null)}function b(e){H(function(){throw e},0)}function v(e){this.type=e,this.target=void 0}function $(e,t){v.call(this,e),this.data=t.data,this.lastEventId=t.lastEventId}function q(e,t){v.call(this,e),this.status=t.status,this.statusText=t.statusText,this.headers=t.headers}function F(e,t){v.call(this,e),this.error=t.error}I.prototype.open=function(e,t){this._abort(!0);var o=this,i=this._xhr,a=1,n=0,r=(this._abort=function(e){0!==o._sendTimeout&&(N(o._sendTimeout),o._sendTimeout=0),1!==a&&2!==a&&3!==a||(a=4,i.onload=u,i.onerror=u,i.onabort=u,i.onprogress=u,i.onreadystatechange=u,i.abort(),0!==n&&(N(n),n=0),e||(o.readyState=4,o.onabort(null),o.onreadystatechange())),a=0},function(){if(1===a){var t=0,n="",r=void 0;if("contentType"in i)t=200,n="OK",r=i.contentType;else try{t=i.status,n=i.statusText,r=i.getResponseHeader("Content-Type")}catch(e){n="",r=void(t=0)}0!==t&&(a=2,o.readyState=2,o.status=t,o.statusText=n,o._contentType=r,o.onreadystatechange())}}),s=function(){if(r(),2===a||3===a){a=3;var e="";try{e=i.responseText}catch(e){}o.readyState=3,o.responseText=e,o.onprogress()}},c=function(e,t){if(null!=t&&null!=t.preventDefault||(t={preventDefault:u}),s(),1===a||2===a||3===a){if(a=4,0!==n&&(N(n),n=0),o.readyState=4,"load"===e)o.onload(t);else if("error"===e)o.onerror(t);else{if("abort"!==e)throw new TypeError;o.onabort(t)}o.onreadystatechange()}},l=function(){n=H(function(){l()},500),3===i.readyState&&s()};"onload"in i&&(i.onload=function(e){c("load",e)}),"onerror"in i&&(i.onerror=function(e){c("error",e)}),"onabort"in i&&(i.onabort=function(e){c("abort",e)}),"onprogress"in i&&(i.onprogress=s),"onreadystatechange"in i&&(i.onreadystatechange=function(e){e=e,null!=i&&(4===i.readyState?"onload"in i&&"onerror"in i&&"onabort"in i||c(""===i.responseText?"error":"load",e):3===i.readyState?"onprogress"in i||s():2===i.readyState&&r())}),!("contentType"in i)&&"ontimeout"in j.prototype||(t+=(-1===t.indexOf("?")?"?":"&")+"padding=true"),i.open(e,t,!0),"readyState"in i&&(n=H(function(){l()},0))},I.prototype.abort=function(){this._abort(!1)},I.prototype.getResponseHeader=function(e){return this._contentType},I.prototype.setRequestHeader=function(e,t){var n=this._xhr;"setRequestHeader"in n&&n.setRequestHeader(e,t)},I.prototype.getAllResponseHeaders=function(){return null!=this._xhr.getAllResponseHeaders&&this._xhr.getAllResponseHeaders()||""},I.prototype.send=function(){var e;if("ontimeout"in j.prototype&&("sendAsBinary"in j.prototype||"mozAnon"in j.prototype)||null==i||null==i.readyState||"complete"===i.readyState){var t=this._xhr;"withCredentials"in t&&(t.withCredentials=this.withCredentials);try{t.send(void 0)}catch(e){throw e}}else(e=this)._sendTimeout=H(function(){e._sendTimeout=0,e.send()},4)},f.prototype.get=function(e){return this._map[l(e)]},null!=j&&null==j.HEADERS_RECEIVED&&(j.HEADERS_RECEIVED=2),P.prototype.open=function(o,i,t,n,e,r,a){o.open("GET",e);var s,c=0;for(s in o.onprogress=function(){var e=o.responseText.slice(c);c+=e.length,t(e)},o.onerror=function(e){e.preventDefault(),n(new Error("NetworkError"))},o.onload=function(){n(null)},o.onabort=function(){n(null)},o.onreadystatechange=function(){var e,t,n,r;o.readyState===j.HEADERS_RECEIVED&&(e=o.status,t=o.statusText,n=o.getResponseHeader("Content-Type"),r=o.getAllResponseHeaders(),i(e,t,n,new f(r)))},o.withCredentials=r,a)Object.prototype.hasOwnProperty.call(a,s)&&o.setRequestHeader(s,a[s]);return o.send(),o},y.prototype.get=function(e){return this._headers.get(e)},L.prototype.open=function(e,t,o,n,r,i,a){var s=null,c=new p,l=c.signal,u=new h;return d(r,{headers:a,credentials:i?"include":"same-origin",signal:l,cache:"no-store"}).then(function(e){return s=e.body.getReader(),t(e.status,e.statusText,e.headers.get("Content-Type"),new y(e.headers)),new w(function(t,n){function r(){s.read().then(function(e){e.done?t(void 0):(e=u.decode(e.value,{stream:!0}),o(e),r())}).catch(function(e){n(e)})}r()})}).catch(function(e){if("AbortError"!==e.name)return e}).then(function(e){n(e)}),{abort:function(){null!=s&&s.cancel(),c.abort()}}},M.prototype.dispatchEvent=function(e){var t=(e.target=this)._listeners[e.type];if(null!=t)for(var n=t.length,r=0;r<n;r+=1){var o=t[r];try{"function"==typeof o.handleEvent?o.handleEvent(e):o.call(this,e)}catch(e){b(e)}}},M.prototype.addEventListener=function(e,t){e=String(e);for(var n=this._listeners,r=n[e],o=(null==r&&(n[e]=r=[]),!1),i=0;i<r.length;i+=1)r[i]===t&&(o=!0);o||r.push(t)},M.prototype.removeEventListener=function(e,t){e=String(e);var n=this._listeners,r=n[e];if(null!=r){for(var o=[],i=0;i<r.length;i+=1)r[i]!==t&&o.push(r[i]);0===o.length?delete n[e]:n[e]=o}},$.prototype=Object.create(v.prototype),q.prototype=Object.create(v.prototype),F.prototype=Object.create(v.prototype);var X=-1,G=0,V=1,B=2,k=-1,z=0,K=1,J=2,W=3,Y=/^text\/event\-stream(;.*)?$/i,E=1e3,m=18e6,Q=function(e,t){e=null==e?t:parseInt(e,10);return U(e=e!=e?t:e)},U=function(e){return Math.min(Math.max(e,E),m)},Z=function(e,t,n){try{"function"==typeof t&&t.call(e,n)}catch(e){b(e)}};function g(e,t){function i(e,t,n,r){var o;m===G&&(200===e&&null!=n&&Y.test(n)?(m=V,y=Date.now(),f=d,c.readyState=V,o=new q("open",{status:e,statusText:t,headers:r}),c.dispatchEvent(o),Z(c,c.onopen,o)):(200!==e?t=t&&t.replace(/\s+/g," "):null!=n&&n.replace(/\s+/g," "),O(),o=new q("error",{status:e,statusText:t,headers:r}),c.dispatchEvent(o),Z(c,c.onerror,o)))}function a(e){if(m===V){for(var t=-1,n=0;n<e.length;n+=1)(a=e.charCodeAt(n))!=="\n".charCodeAt(0)&&a!=="\r".charCodeAt(0)||(t=n);var r=(-1!==t?S:"")+e.slice(0,t+1);S=(-1===t?S:"")+e.slice(t+1),""!==e&&(y=Date.now(),v+=e.length);for(var o=0;o<r.length;o+=1){var i,a=r.charCodeAt(o);if(x===k&&a==="\n".charCodeAt(0))x=z;else if(x===k&&(x=z),a==="\r".charCodeAt(0)||a==="\n".charCodeAt(0)){if(x!==z&&(x===K&&(R=o+1),s=r.slice(A,R-1),i=r.slice(R+(R<o&&r.charCodeAt(R)===" ".charCodeAt(0)?1:0),o),"data"===s?C=C+"\n"+i:"id"===s?T=i:"event"===s?_=i:"retry"===s?(d=Q(i,d),f=d):"heartbeatTimeout"===s&&(h=Q(i,h),0!==E&&(N(E),E=H(function(){D()},h)))),x===z){if(""!==C){p=T;var s=new $(_=""===_?"message":_,{data:C.slice(1),lastEventId:T});if(c.dispatchEvent(s),"open"===_?Z(c,c.onopen,s):"message"===_?Z(c,c.onmessage,s):"error"===_&&Z(c,c.onerror,s),m===B)return}_=C=""}x=a==="\r".charCodeAt(0)?k:z}else x===z&&(A=o,x=K),x===K?a===":".charCodeAt(0)&&(R=o+1,x=J):x===J&&(x=W)}}}function s(e){m!==V&&m!==G||(m=X,0!==E&&(N(E),E=0),E=H(function(){D()},f),f=U(Math.min(16*d,2*f)),c.readyState=G,e=new F("error",{error:e}),c.dispatchEvent(e),Z(c,c.onerror,e))}var c,l,u,d,h,p,f,y,v,n,g,w,b,E,m,C,T,_,S,x,A,R,O,D;M.call(this),t=t||{},this.onopen=void 0,this.onmessage=void 0,this.onerror=void 0,this.url=void 0,this.readyState=void 0,this.withCredentials=void 0,this.headers=void 0,this._close=void 0,c=this,l=e,e=t,l=String(l),t=Boolean(e.withCredentials),u=e.lastEventIdQueryParameterName||"lastEventId",d=U(1e3),h=Q(e.heartbeatTimeout,45e3),p="",f=d,y=!1,v=0,n=e.headers||{},e=e.Transport,g=ee&&null==e?void 0:new I(new(null!=e?e:null!=j&&"withCredentials"in j.prototype||null==o?j:o)),w=new(null!=e&&"string"!=typeof e?e:null==g?L:P),b=void 0,m=X,S=_=T=C="",x=z,R=A=E=0,O=function(){m=B,null!=b&&(b.abort(),b=void 0),0!==E&&(N(E),E=0),c.readyState=B},D=function(){if(E=0,m!==X)y||null==b?(e=Math.max((y||Date.now())+h-Date.now(),1),y=!1,E=H(function(){D()},e)):(s(new Error("No activity within "+h+" milliseconds. "+(m===G?"No response received.":v+" chars received.")+" Reconnecting.")),null!=b&&(b.abort(),b=void 0));else{y=!1,v=0,E=H(function(){D()},h),m=G,T=p,S=_=C="",R=A=0,x=z;var e=l,t=("data:"!==l.slice(0,5)&&"blob:"!==l.slice(0,5)&&""!==p&&(e=-1===(t=l.indexOf("?"))?l:l.slice(0,t+1)+l.slice(t+1).replace(/(?:^|&)([^=&]*)(?:=[^&]*)?/g,function(e,t){return t===u?"":e}),e+=(-1===l.indexOf("?")?"?":"&")+u+"="+encodeURIComponent(p)),c.withCredentials),n={Accept:"text/event-stream"},r=c.headers;if(null!=r)for(var o in r)Object.prototype.hasOwnProperty.call(r,o)&&(n[o]=r[o]);try{b=w.open(g,i,a,s,e,t,n)}catch(e){throw O(),e}}},c.url=l,c.readyState=G,c.withCredentials=t,c.headers=n,c._close=O,D()}var ee=null!=d&&null!=a&&"body"in a.prototype;(g.prototype=Object.create(M.prototype)).CONNECTING=G,g.prototype.OPEN=V,g.prototype.CLOSED=B,g.prototype.close=function(){this._close()},g.CONNECTING=G,g.OPEN=V,g.CLOSED=B,g.prototype.withCredentials=void 0;var C=n;null==j||null!=n&&"withCredentials"in n.prototype||(C=g),a=function(e){e.EventSourcePolyfill=g,e.NativeEventSource=n,e.EventSource=C},"object"==typeof module&&"object"==typeof module.exports?a(exports):"function"==typeof define&&define.amd?define(["exports"],a):a(e)}("undefined"==typeof globalThis?"undefined"!=typeof window?window:"undefined"!=typeof self?self:this:globalThis);
\ No newline at end of file
... ...