vue-element-ui-x 0.1.6-beta → 0.1.8-beta
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/attachments.js +3082 -0
- package/lib/bubble-list.js +13840 -0
- package/lib/bubble.js +13125 -0
- package/lib/components/Attachments/index.js +2 -2
- package/lib/components/Bubble/index.js +74 -79
- package/lib/components/BubbleList/index.js +75 -80
- package/lib/components/Conversations/index.js +6 -6
- package/lib/components/FilesCard/index.js +1 -1
- package/lib/components/Prompts/index.js +21 -21
- package/lib/components/Sender/index.js +4 -4
- package/lib/components/Think/index.js +1 -1
- package/lib/components/Thinking/index.js +11 -11
- package/lib/components/ThoughtChain/index.js +77 -82
- package/lib/components/Typewriter/index.js +73 -78
- package/lib/components/Welcome/index.js +1 -1
- package/lib/conversations.js +18825 -0
- package/lib/files-card.js +2471 -0
- package/lib/index.common.js +1 -1
- package/lib/index.esm.js +1 -1
- package/lib/index.js +1463 -1457
- package/lib/index.umd.js +1 -1
- package/lib/mixins/index.js +2 -2
- package/lib/mixins.js +1016 -0
- package/lib/prompts.js +832 -0
- package/lib/sender.js +1911 -0
- package/lib/think.js +799 -0
- package/lib/thinking.js +809 -0
- package/lib/thought-chain.js +30391 -0
- package/lib/typewriter.js +12788 -0
- package/lib/welcome.js +755 -0
- package/package.json +1 -2
- package/src/components/Attachments/index.js +8 -8
- package/src/components/Bubble/index.js +6 -6
- package/src/components/Bubble/src/main.vue +299 -299
- package/src/components/BubbleList/index.js +8 -8
- package/src/components/BubbleList/src/loading.vue +75 -75
- package/src/components/BubbleList/src/main.vue +466 -466
- package/src/components/Conversations/index.js +8 -8
- package/src/components/Conversations/src/main.vue +635 -635
- package/src/components/FilesCard/index.js +8 -8
- package/src/components/FilesCard/src/fileSvg/audio.vue +38 -38
- package/src/components/FilesCard/src/fileSvg/code.vue +35 -35
- package/src/components/FilesCard/src/fileSvg/database.vue +94 -94
- package/src/components/FilesCard/src/fileSvg/excel.vue +38 -38
- package/src/components/FilesCard/src/fileSvg/file.vue +40 -40
- package/src/components/FilesCard/src/fileSvg/image.vue +40 -40
- package/src/components/FilesCard/src/fileSvg/index.js +46 -46
- package/src/components/FilesCard/src/fileSvg/link.vue +54 -54
- package/src/components/FilesCard/src/fileSvg/mark.vue +38 -38
- package/src/components/FilesCard/src/fileSvg/pdf.vue +38 -38
- package/src/components/FilesCard/src/fileSvg/ppt.vue +38 -38
- package/src/components/FilesCard/src/fileSvg/three.vue +38 -38
- package/src/components/FilesCard/src/fileSvg/txt.vue +38 -38
- package/src/components/FilesCard/src/fileSvg/unknown.vue +54 -54
- package/src/components/FilesCard/src/fileSvg/video.vue +38 -38
- package/src/components/FilesCard/src/fileSvg/word.vue +38 -38
- package/src/components/FilesCard/src/fileSvg/zip.vue +38 -38
- package/src/components/FilesCard/src/options.js +18 -18
- package/src/components/Prompts/index.js +8 -8
- package/src/components/Prompts/src/main.vue +248 -248
- package/src/components/Sender/index.js +8 -8
- package/src/components/Sender/src/components/ClearButton.vue +28 -28
- package/src/components/Sender/src/components/Loading.vue +53 -53
- package/src/components/Sender/src/components/LoadingButton.vue +39 -39
- package/src/components/Sender/src/components/SendButton.vue +26 -26
- package/src/components/Sender/src/components/SpeechButton.vue +24 -24
- package/src/components/Sender/src/components/SpeechLoading.vue +87 -87
- package/src/components/Sender/src/components/SpeechLoadingButton.vue +43 -43
- package/src/components/Think/index.js +8 -8
- package/src/components/Think/src/main.vue +190 -190
- package/src/components/Thinking/index.js +8 -8
- package/src/components/Thinking/src/main.vue +1 -1
- package/src/components/ThoughtChain/index.js +8 -8
- package/src/components/ThoughtChain/src/main.vue +293 -293
- package/src/components/Typewriter/index.js +8 -8
- package/src/components/Welcome/index.js +8 -8
- package/src/components/Welcome/src/main.vue +151 -151
- package/src/index.js +23 -3
- package/src/styles/Attachments.scss +236 -236
- package/src/styles/Bubble.scss +157 -157
- package/src/styles/BubbleList.scss +148 -148
- package/src/styles/Conversations.scss +260 -260
- package/src/styles/FilesCard.scss +221 -221
- package/src/styles/Prompts.scss +195 -195
- package/src/styles/Sender.scss +199 -199
- package/src/styles/Think.scss +134 -134
- package/src/styles/Thinking.scss +2 -2
- package/src/styles/ThoughtChain.scss +113 -113
- package/src/styles/Typewriter.scss +66 -66
- package/src/styles/button.scss +302 -0
- package/src/styles/var.scss +1052 -0
- package/src/theme/var.scss +72 -72
package/lib/index.js
CHANGED
|
@@ -273,7 +273,7 @@ var UNESCAPE_ALL_RE = new RegExp(UNESCAPE_MD_RE.source + '|' + ENTITY_RE.source,
|
|
|
273
273
|
|
|
274
274
|
var DIGITAL_ENTITY_TEST_RE = /^#((?:x[a-f0-9]{1,8}|[0-9]{1,8}))/i;
|
|
275
275
|
|
|
276
|
-
var entities = __webpack_require__(
|
|
276
|
+
var entities = __webpack_require__(13);
|
|
277
277
|
|
|
278
278
|
function replaceEntityPattern(match, name) {
|
|
279
279
|
var code = 0;
|
|
@@ -378,7 +378,7 @@ function isWhiteSpace(code) {
|
|
|
378
378
|
////////////////////////////////////////////////////////////////////////////////
|
|
379
379
|
|
|
380
380
|
/*eslint-disable max-len*/
|
|
381
|
-
var UNICODE_PUNCT_RE = __webpack_require__(
|
|
381
|
+
var UNICODE_PUNCT_RE = __webpack_require__(7);
|
|
382
382
|
|
|
383
383
|
// Currently without astral characters support.
|
|
384
384
|
function isPunctChar(ch) {
|
|
@@ -492,7 +492,7 @@ function normalizeReference(str) {
|
|
|
492
492
|
// bundled size (e.g. a browser build).
|
|
493
493
|
//
|
|
494
494
|
exports.lib = {};
|
|
495
|
-
exports.lib.mdurl = __webpack_require__(
|
|
495
|
+
exports.lib.mdurl = __webpack_require__(14);
|
|
496
496
|
exports.lib.ucmicro = __webpack_require__(35);
|
|
497
497
|
|
|
498
498
|
exports.assign = assign;
|
|
@@ -2811,213 +2811,1138 @@ Prism.languages.js = Prism.languages.javascript;
|
|
|
2811
2811
|
|
|
2812
2812
|
}());
|
|
2813
2813
|
|
|
2814
|
-
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(
|
|
2814
|
+
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(11)))
|
|
2815
2815
|
|
|
2816
2816
|
/***/ }),
|
|
2817
2817
|
/* 5 */
|
|
2818
|
-
/***/ (function(module,
|
|
2819
|
-
|
|
2820
|
-
/* WEBPACK VAR INJECTION */(function(global, module) {var __WEBPACK_AMD_DEFINE_RESULT__;/**
|
|
2821
|
-
* @license
|
|
2822
|
-
* Lodash <https://lodash.com/>
|
|
2823
|
-
* Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
|
|
2824
|
-
* Released under MIT license <https://lodash.com/license>
|
|
2825
|
-
* Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
|
|
2826
|
-
* Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
|
|
2827
|
-
*/
|
|
2828
|
-
;(function() {
|
|
2818
|
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
2829
2819
|
|
|
2830
|
-
|
|
2831
|
-
|
|
2820
|
+
"use strict";
|
|
2821
|
+
// ESM COMPAT FLAG
|
|
2822
|
+
__webpack_require__.r(__webpack_exports__);
|
|
2832
2823
|
|
|
2833
|
-
|
|
2834
|
-
|
|
2824
|
+
// EXPORTS
|
|
2825
|
+
__webpack_require__.d(__webpack_exports__, "createSendUtils", function() { return /* reexport */ createSendUtils; });
|
|
2826
|
+
__webpack_require__.d(__webpack_exports__, "createStreamUtils", function() { return /* reexport */ createStreamUtils; });
|
|
2827
|
+
__webpack_require__.d(__webpack_exports__, "DEFAULT_KV_SEPARATOR", function() { return /* reexport */ DEFAULT_KV_SEPARATOR; });
|
|
2828
|
+
__webpack_require__.d(__webpack_exports__, "DEFAULT_PART_SEPARATOR", function() { return /* reexport */ DEFAULT_PART_SEPARATOR; });
|
|
2829
|
+
__webpack_require__.d(__webpack_exports__, "DEFAULT_STREAM_SEPARATOR", function() { return /* reexport */ DEFAULT_STREAM_SEPARATOR; });
|
|
2830
|
+
__webpack_require__.d(__webpack_exports__, "isValidString", function() { return /* reexport */ isValidString; });
|
|
2831
|
+
__webpack_require__.d(__webpack_exports__, "recordMixin", function() { return /* reexport */ recordMixin; });
|
|
2832
|
+
__webpack_require__.d(__webpack_exports__, "sendMixin", function() { return /* reexport */ sendMixin; });
|
|
2833
|
+
__webpack_require__.d(__webpack_exports__, "splitPart", function() { return /* reexport */ splitPart; });
|
|
2834
|
+
__webpack_require__.d(__webpack_exports__, "splitStream", function() { return /* reexport */ splitStream; });
|
|
2835
|
+
__webpack_require__.d(__webpack_exports__, "streamMixin", function() { return /* reexport */ streamMixin; });
|
|
2836
|
+
__webpack_require__.d(__webpack_exports__, "XRequest", function() { return /* reexport */ XRequest; });
|
|
2837
|
+
__webpack_require__.d(__webpack_exports__, "XStream", function() { return /* reexport */ XStream; });
|
|
2835
2838
|
|
|
2836
|
-
|
|
2837
|
-
|
|
2839
|
+
// CONCATENATED MODULE: ./src/mixins/recordMixin.js
|
|
2840
|
+
/**
|
|
2841
|
+
* @description 提供语音识别的混入,允许语音输入并处理开始、结束、结果及错误等各种事件。
|
|
2842
|
+
*
|
|
2843
|
+
* @mixin recordMixin
|
|
2844
|
+
*/
|
|
2838
2845
|
|
|
2839
|
-
|
|
2840
|
-
|
|
2841
|
-
|
|
2842
|
-
|
|
2846
|
+
/* harmony default export */ var recordMixin = ({
|
|
2847
|
+
data() {
|
|
2848
|
+
return {
|
|
2849
|
+
// 语音识别状态
|
|
2850
|
+
recordLoading: false,
|
|
2851
|
+
// 识别结果
|
|
2852
|
+
recordValue: '',
|
|
2853
|
+
// 识别实例
|
|
2854
|
+
recordRecognition: null,
|
|
2855
|
+
// 配置选项
|
|
2856
|
+
recordOptions: {
|
|
2857
|
+
onError: null,
|
|
2858
|
+
onStart: null,
|
|
2859
|
+
onEnd: null,
|
|
2860
|
+
onResult: null
|
|
2861
|
+
}
|
|
2862
|
+
};
|
|
2863
|
+
},
|
|
2864
|
+
methods: {
|
|
2865
|
+
/**
|
|
2866
|
+
* 初始化语音识别配置
|
|
2867
|
+
* @param {Object} options - 配置选项
|
|
2868
|
+
* @param {Function} [options.onError] - 错误回调
|
|
2869
|
+
* @param {Function} [options.onStart] - 开始回调
|
|
2870
|
+
* @param {Function} [options.onEnd] - 结束回调
|
|
2871
|
+
* @param {Function} [options.onResult] - 结果回调
|
|
2872
|
+
*/
|
|
2873
|
+
initRecord(options = {}) {
|
|
2874
|
+
this.recordOptions = {
|
|
2875
|
+
...this.recordOptions,
|
|
2876
|
+
...options
|
|
2877
|
+
};
|
|
2878
|
+
},
|
|
2879
|
+
/**
|
|
2880
|
+
* 开始语音识别
|
|
2881
|
+
*/
|
|
2882
|
+
startRecord() {
|
|
2883
|
+
if ('webkitSpeechRecognition' in window) {
|
|
2884
|
+
this.recordRecognition = new window.webkitSpeechRecognition();
|
|
2885
|
+
this.recordRecognition.continuous = true;
|
|
2886
|
+
this.recordRecognition.interimResults = true;
|
|
2887
|
+
this.recordRecognition.lang = 'zh-CN';
|
|
2888
|
+
this.recordRecognition.onstart = () => {
|
|
2889
|
+
this.recordLoading = true;
|
|
2890
|
+
this.recordValue = '';
|
|
2891
|
+
if (this.recordOptions.onStart) {
|
|
2892
|
+
this.recordOptions.onStart();
|
|
2893
|
+
}
|
|
2894
|
+
};
|
|
2895
|
+
this.recordRecognition.onend = () => {
|
|
2896
|
+
this.recordLoading = false;
|
|
2897
|
+
if (this.recordOptions.onEnd) {
|
|
2898
|
+
this.recordOptions.onEnd(this.recordValue);
|
|
2899
|
+
}
|
|
2900
|
+
};
|
|
2901
|
+
this.recordRecognition.onerror = e => {
|
|
2902
|
+
this.recordLoading = false;
|
|
2903
|
+
if (this.recordOptions.onError) {
|
|
2904
|
+
this.recordOptions.onError(e);
|
|
2905
|
+
}
|
|
2906
|
+
};
|
|
2907
|
+
this.recordRecognition.onresult = e => {
|
|
2908
|
+
let results = '';
|
|
2909
|
+
for (let i = 0; i <= e.resultIndex; i++) {
|
|
2910
|
+
results += e.results[i][0].transcript;
|
|
2911
|
+
}
|
|
2912
|
+
this.recordValue = results;
|
|
2913
|
+
if (this.recordOptions.onResult) {
|
|
2914
|
+
this.recordOptions.onResult(results);
|
|
2915
|
+
}
|
|
2916
|
+
};
|
|
2917
|
+
this.recordRecognition.start();
|
|
2918
|
+
} else {
|
|
2919
|
+
const error = {
|
|
2920
|
+
code: -1,
|
|
2921
|
+
message: 'The current browser does not support voice recognition'
|
|
2922
|
+
};
|
|
2923
|
+
if (this.recordOptions.onError) {
|
|
2924
|
+
this.recordOptions.onError(error);
|
|
2925
|
+
}
|
|
2926
|
+
}
|
|
2927
|
+
},
|
|
2928
|
+
/**
|
|
2929
|
+
* 停止语音识别
|
|
2930
|
+
*/
|
|
2931
|
+
stopRecord() {
|
|
2932
|
+
if (this.recordRecognition) {
|
|
2933
|
+
this.recordRecognition.stop();
|
|
2934
|
+
}
|
|
2935
|
+
},
|
|
2936
|
+
/**
|
|
2937
|
+
* 清理语音识别资源
|
|
2938
|
+
*/
|
|
2939
|
+
cleanupRecord() {
|
|
2940
|
+
this.stopRecord();
|
|
2941
|
+
this.recordRecognition = null;
|
|
2942
|
+
}
|
|
2943
|
+
},
|
|
2944
|
+
beforeDestroy() {
|
|
2945
|
+
this.cleanupRecord();
|
|
2946
|
+
}
|
|
2947
|
+
});
|
|
2948
|
+
// CONCATENATED MODULE: ./src/mixins/sendMixin.js
|
|
2949
|
+
/**
|
|
2950
|
+
* XRequest 类 - 用于处理 SSE 和 Fetch 请求
|
|
2951
|
+
*/
|
|
2952
|
+
class XRequest {
|
|
2953
|
+
constructor(options = {}) {
|
|
2954
|
+
const {
|
|
2955
|
+
baseURL,
|
|
2956
|
+
onAbort,
|
|
2957
|
+
onMessage,
|
|
2958
|
+
onError,
|
|
2959
|
+
baseOptions,
|
|
2960
|
+
transformer,
|
|
2961
|
+
type,
|
|
2962
|
+
onFinish,
|
|
2963
|
+
onOpen
|
|
2964
|
+
} = options;
|
|
2965
|
+
this._instance = null;
|
|
2966
|
+
this._transformer = transformer;
|
|
2967
|
+
this._baseURL = baseURL || '';
|
|
2968
|
+
this._baseOptions = baseOptions || {};
|
|
2969
|
+
this._onAbort = onAbort;
|
|
2970
|
+
this._onMessage = onMessage;
|
|
2971
|
+
this._onError = onError;
|
|
2972
|
+
this._onOpen = onOpen;
|
|
2973
|
+
this._type = type || 'sse';
|
|
2974
|
+
this._controller = null;
|
|
2975
|
+
this._onFinish = onFinish;
|
|
2976
|
+
this._messages = [];
|
|
2977
|
+
// 添加结束标志和超时控制
|
|
2978
|
+
this._isFinished = false;
|
|
2979
|
+
this._finishTimeout = null;
|
|
2843
2980
|
|
|
2844
|
-
|
|
2845
|
-
|
|
2981
|
+
// 绑定方法上下文
|
|
2982
|
+
this.abort = this.abort.bind(this);
|
|
2983
|
+
this.send = this.send.bind(this);
|
|
2984
|
+
}
|
|
2985
|
+
_sendWithFetch(url, options = {}) {
|
|
2986
|
+
this._controller = new AbortController();
|
|
2987
|
+
const signal = this._controller.signal;
|
|
2988
|
+
const fetchOptions = {
|
|
2989
|
+
...options,
|
|
2990
|
+
signal
|
|
2991
|
+
};
|
|
2992
|
+
return fetch(this._baseURL + url, fetchOptions).then(res => res.body).then(async body => {
|
|
2993
|
+
if (!body) {
|
|
2994
|
+
return Promise.reject(new Error('Response body is null in stream mode'));
|
|
2995
|
+
}
|
|
2996
|
+
const reader = body.getReader();
|
|
2997
|
+
const decoder = new TextDecoder('utf-8');
|
|
2998
|
+
let done = false;
|
|
2999
|
+
while (!done) {
|
|
3000
|
+
const {
|
|
3001
|
+
value,
|
|
3002
|
+
done: streamDone
|
|
3003
|
+
} = await reader.read();
|
|
3004
|
+
done = streamDone;
|
|
3005
|
+
if (streamDone) {
|
|
3006
|
+
this._onFinish && this._onFinish(this._messages);
|
|
3007
|
+
return;
|
|
3008
|
+
}
|
|
3009
|
+
if (value) {
|
|
3010
|
+
const chunk = decoder.decode(value, {
|
|
3011
|
+
stream: true
|
|
3012
|
+
});
|
|
3013
|
+
const chunkUse = chunk.startsWith('data: ') ? chunk.slice(6) : chunk;
|
|
3014
|
+
try {
|
|
3015
|
+
const res = this._transformer ? this._transformer(chunkUse) : chunkUse;
|
|
3016
|
+
this._messages.push(res);
|
|
3017
|
+
this._onMessage && this._onMessage(res);
|
|
3018
|
+
} catch (error) {
|
|
3019
|
+
this._onError && this._onError(error);
|
|
3020
|
+
this._controller && this._controller.abort();
|
|
3021
|
+
return Promise.reject(error);
|
|
3022
|
+
}
|
|
3023
|
+
}
|
|
3024
|
+
}
|
|
3025
|
+
}).catch(err => {
|
|
3026
|
+
if (err.name === 'AbortError') {
|
|
3027
|
+
this._onAbort && this._onAbort(this._messages);
|
|
3028
|
+
return;
|
|
3029
|
+
}
|
|
3030
|
+
this._onError && this._onError(err);
|
|
3031
|
+
this._controller && this._controller.abort();
|
|
3032
|
+
});
|
|
3033
|
+
}
|
|
3034
|
+
_sendWithSSE(url, options = {}) {
|
|
3035
|
+
const es = new EventSource(this._baseURL + url, {
|
|
3036
|
+
...this._baseOptions,
|
|
3037
|
+
...options
|
|
3038
|
+
});
|
|
3039
|
+
es.onmessage = e => {
|
|
3040
|
+
// 检查是否是结束消息
|
|
3041
|
+
if (e.data === '[DONE]' || e.data === 'data: [DONE]') {
|
|
3042
|
+
this._isFinished = true;
|
|
3043
|
+
this._onFinish && this._onFinish(this._messages);
|
|
3044
|
+
this.abort();
|
|
3045
|
+
return;
|
|
3046
|
+
}
|
|
3047
|
+
const res = this._transformer ? this._transformer(e.data) : e;
|
|
3048
|
+
this._messages.push(res);
|
|
3049
|
+
this._onMessage && this._onMessage(res);
|
|
2846
3050
|
|
|
2847
|
-
|
|
2848
|
-
|
|
3051
|
+
// 重置超时定时器
|
|
3052
|
+
if (this._finishTimeout) {
|
|
3053
|
+
clearTimeout(this._finishTimeout);
|
|
3054
|
+
}
|
|
2849
3055
|
|
|
2850
|
-
|
|
2851
|
-
|
|
3056
|
+
// 设置超时检测:如果 10 秒内没有新消息,认为连接可能已结束
|
|
3057
|
+
this._finishTimeout = setTimeout(() => {
|
|
3058
|
+
if (!this._isFinished && es.readyState !== EventSource.CONNECTING) {
|
|
3059
|
+
this._isFinished = true;
|
|
3060
|
+
this._onFinish && this._onFinish(this._messages);
|
|
3061
|
+
this.abort();
|
|
3062
|
+
}
|
|
3063
|
+
}, 10000);
|
|
3064
|
+
};
|
|
3065
|
+
es.onopen = () => {
|
|
3066
|
+
this._onOpen && this._onOpen();
|
|
3067
|
+
};
|
|
3068
|
+
es.onerror = ev => {
|
|
3069
|
+
// 清除超时定时器
|
|
3070
|
+
if (this._finishTimeout) {
|
|
3071
|
+
clearTimeout(this._finishTimeout);
|
|
3072
|
+
this._finishTimeout = null;
|
|
3073
|
+
}
|
|
2852
3074
|
|
|
2853
|
-
|
|
2854
|
-
|
|
2855
|
-
|
|
2856
|
-
|
|
3075
|
+
// 如果已经标记为结束,直接返回
|
|
3076
|
+
if (this._isFinished) {
|
|
3077
|
+
return;
|
|
3078
|
+
}
|
|
2857
3079
|
|
|
2858
|
-
|
|
2859
|
-
|
|
2860
|
-
|
|
3080
|
+
// 更可靠的结束检测逻辑
|
|
3081
|
+
if (es.readyState === EventSource.CLOSED || this._messages.length > 0 && es.readyState !== EventSource.CONNECTING) {
|
|
3082
|
+
// 有消息且连接状态不是正在连接,很可能是正常结束
|
|
3083
|
+
this._isFinished = true;
|
|
3084
|
+
this._onFinish && this._onFinish(this._messages);
|
|
3085
|
+
} else {
|
|
3086
|
+
// 真正的错误情况
|
|
3087
|
+
this._onError && this._onError(es, ev);
|
|
3088
|
+
}
|
|
3089
|
+
this.abort();
|
|
3090
|
+
};
|
|
3091
|
+
this._instance = es;
|
|
3092
|
+
return es;
|
|
3093
|
+
}
|
|
3094
|
+
send(url, options = {}) {
|
|
3095
|
+
switch (this._type) {
|
|
3096
|
+
case 'fetch':
|
|
3097
|
+
this._sendWithFetch(url, options);
|
|
3098
|
+
break;
|
|
3099
|
+
default:
|
|
3100
|
+
this._sendWithSSE(url, options);
|
|
3101
|
+
}
|
|
3102
|
+
return this;
|
|
3103
|
+
}
|
|
3104
|
+
abort() {
|
|
3105
|
+
// 清除超时定时器
|
|
3106
|
+
if (this._finishTimeout) {
|
|
3107
|
+
clearTimeout(this._finishTimeout);
|
|
3108
|
+
this._finishTimeout = null;
|
|
3109
|
+
}
|
|
3110
|
+
if (this._instance && this._instance.close) {
|
|
3111
|
+
this._instance.close();
|
|
3112
|
+
}
|
|
3113
|
+
this._instance = null;
|
|
3114
|
+
if (this._controller) {
|
|
3115
|
+
this._controller.abort();
|
|
3116
|
+
}
|
|
3117
|
+
this._controller = null;
|
|
2861
3118
|
|
|
2862
|
-
|
|
2863
|
-
|
|
2864
|
-
|
|
2865
|
-
|
|
2866
|
-
|
|
2867
|
-
|
|
2868
|
-
|
|
2869
|
-
|
|
2870
|
-
WRAP_ARY_FLAG = 128,
|
|
2871
|
-
WRAP_REARG_FLAG = 256,
|
|
2872
|
-
WRAP_FLIP_FLAG = 512;
|
|
3119
|
+
// 只有在未正常结束时才调用 onAbort
|
|
3120
|
+
if (!this._isFinished) {
|
|
3121
|
+
this._onAbort && this._onAbort(this._messages);
|
|
3122
|
+
}
|
|
3123
|
+
this._messages = [];
|
|
3124
|
+
this._isFinished = false;
|
|
3125
|
+
}
|
|
3126
|
+
}
|
|
2873
3127
|
|
|
2874
|
-
|
|
2875
|
-
|
|
2876
|
-
|
|
3128
|
+
/**
|
|
3129
|
+
* sendMixin -
|
|
3130
|
+
* 用于处理发送操作管理请求状态的 mixin,支持可选的中止功能,同时支持 Promise 和 SSE(服务端事件)
|
|
3131
|
+
*/
|
|
3132
|
+
const sendMixin = {
|
|
3133
|
+
data() {
|
|
3134
|
+
return {
|
|
3135
|
+
loading: false,
|
|
3136
|
+
_sendPromise: null,
|
|
3137
|
+
_sendController: null
|
|
3138
|
+
};
|
|
3139
|
+
},
|
|
3140
|
+
methods: {
|
|
3141
|
+
/**
|
|
3142
|
+
* 初始化发送配置
|
|
3143
|
+
* @param {Object} options - 配置选项
|
|
3144
|
+
* @param {Function} options.onAbort - 中止回调
|
|
3145
|
+
* @param {Function} options.sendHandler - 发送处理器
|
|
3146
|
+
* @param {Function} options.abortHandler - 中止处理器
|
|
3147
|
+
* @param {Function} options.finishHandler - 完成处理器
|
|
3148
|
+
*/
|
|
3149
|
+
initSend(options = {}) {
|
|
3150
|
+
this._sendOptions = {
|
|
3151
|
+
onAbort: options.onAbort,
|
|
3152
|
+
sendHandler: options.sendHandler,
|
|
3153
|
+
abortHandler: options.abortHandler,
|
|
3154
|
+
finishHandler: options.finishHandler
|
|
3155
|
+
};
|
|
3156
|
+
},
|
|
3157
|
+
/**
|
|
3158
|
+
* 发送操作
|
|
3159
|
+
* @param {...any} args - 传递给 sendHandler 的参数
|
|
3160
|
+
*/
|
|
3161
|
+
handleSend(...args) {
|
|
3162
|
+
if (this.loading) {
|
|
3163
|
+
return;
|
|
3164
|
+
}
|
|
3165
|
+
if (this._sendOptions && this._sendOptions.sendHandler) {
|
|
3166
|
+
this._sendOptions.sendHandler(...args);
|
|
3167
|
+
}
|
|
3168
|
+
this.loading = true;
|
|
3169
|
+
},
|
|
3170
|
+
/**
|
|
3171
|
+
* 中止操作
|
|
3172
|
+
*/
|
|
3173
|
+
handleAbort() {
|
|
3174
|
+
this.loading = false;
|
|
3175
|
+
if (this._sendOptions && this._sendOptions.abortHandler) {
|
|
3176
|
+
this._sendOptions.abortHandler();
|
|
3177
|
+
}
|
|
3178
|
+
if (this._sendOptions && this._sendOptions.onAbort) {
|
|
3179
|
+
this._sendOptions.onAbort();
|
|
3180
|
+
}
|
|
3181
|
+
},
|
|
3182
|
+
/**
|
|
3183
|
+
* 完成操作
|
|
3184
|
+
*/
|
|
3185
|
+
handleFinish() {
|
|
3186
|
+
this.loading = false;
|
|
3187
|
+
if (this._sendOptions && this._sendOptions.finishHandler) {
|
|
3188
|
+
this._sendOptions.finishHandler();
|
|
3189
|
+
}
|
|
3190
|
+
},
|
|
3191
|
+
/**
|
|
3192
|
+
* 创建 XRequest 实例的便捷方法
|
|
3193
|
+
* @param {Object} options - XRequest 配置选项
|
|
3194
|
+
* @returns {XRequest} XRequest 实例
|
|
3195
|
+
*/
|
|
3196
|
+
createXRequest(options = {}) {
|
|
3197
|
+
return new XRequest({
|
|
3198
|
+
...options,
|
|
3199
|
+
onAbort: (...args) => {
|
|
3200
|
+
this.handleAbort();
|
|
3201
|
+
if (options.onAbort) {
|
|
3202
|
+
options.onAbort(...args);
|
|
3203
|
+
}
|
|
3204
|
+
},
|
|
3205
|
+
onFinish: (...args) => {
|
|
3206
|
+
this.handleFinish();
|
|
3207
|
+
if (options.onFinish) {
|
|
3208
|
+
options.onFinish(...args);
|
|
3209
|
+
}
|
|
3210
|
+
}
|
|
3211
|
+
});
|
|
3212
|
+
}
|
|
3213
|
+
},
|
|
3214
|
+
beforeDestroy() {
|
|
3215
|
+
// 组件销毁时清理资源
|
|
3216
|
+
if (this._sendController) {
|
|
3217
|
+
this._sendController.abort();
|
|
3218
|
+
}
|
|
3219
|
+
}
|
|
3220
|
+
};
|
|
2877
3221
|
|
|
2878
|
-
|
|
2879
|
-
|
|
2880
|
-
|
|
3222
|
+
/**
|
|
3223
|
+
* 工具函数版本 - 用于非组件场景
|
|
3224
|
+
* @param {Object} options - 配置选项
|
|
3225
|
+
* @returns {Object} 包含发送相关方法的对象
|
|
3226
|
+
*/
|
|
3227
|
+
function createSendUtils(options = {}) {
|
|
3228
|
+
const state = {
|
|
3229
|
+
loading: false
|
|
3230
|
+
};
|
|
3231
|
+
const handleSend = (...args) => {
|
|
3232
|
+
if (state.loading) {
|
|
3233
|
+
return;
|
|
3234
|
+
}
|
|
3235
|
+
if (options.sendHandler) {
|
|
3236
|
+
options.sendHandler(...args);
|
|
3237
|
+
}
|
|
3238
|
+
state.loading = true;
|
|
3239
|
+
};
|
|
3240
|
+
const handleAbort = () => {
|
|
3241
|
+
state.loading = false;
|
|
3242
|
+
if (options.abortHandler) {
|
|
3243
|
+
options.abortHandler();
|
|
3244
|
+
}
|
|
3245
|
+
if (options.onAbort) {
|
|
3246
|
+
options.onAbort();
|
|
3247
|
+
}
|
|
3248
|
+
};
|
|
3249
|
+
const handleFinish = () => {
|
|
3250
|
+
state.loading = false;
|
|
3251
|
+
if (options.finishHandler) {
|
|
3252
|
+
options.finishHandler();
|
|
3253
|
+
}
|
|
3254
|
+
};
|
|
3255
|
+
return {
|
|
3256
|
+
state,
|
|
3257
|
+
send: handleSend,
|
|
3258
|
+
abort: handleAbort,
|
|
3259
|
+
finish: handleFinish
|
|
3260
|
+
};
|
|
3261
|
+
}
|
|
3262
|
+
/* harmony default export */ var mixins_sendMixin = (sendMixin);
|
|
3263
|
+
// CONCATENATED MODULE: ./src/mixins/streamMixin.js
|
|
3264
|
+
/**
|
|
3265
|
+
* @fileoverview Vue2 流式数据处理 Mixin
|
|
3266
|
+
* 从 Vue3 useXStream hooks 转换而来,支持 SSE 数据解析和中断功能
|
|
3267
|
+
* @author Element UI X Team
|
|
3268
|
+
* @version 1.0.0
|
|
3269
|
+
*/
|
|
2881
3270
|
|
|
2882
|
-
|
|
2883
|
-
|
|
2884
|
-
|
|
2885
|
-
|
|
3271
|
+
/**
|
|
3272
|
+
* 默认流分隔符
|
|
3273
|
+
* @type {string}
|
|
3274
|
+
* @constant
|
|
3275
|
+
*/
|
|
3276
|
+
const DEFAULT_STREAM_SEPARATOR = '\n\n';
|
|
2886
3277
|
|
|
2887
|
-
|
|
2888
|
-
|
|
2889
|
-
|
|
2890
|
-
|
|
2891
|
-
|
|
3278
|
+
/**
|
|
3279
|
+
* 默认部分分隔符
|
|
3280
|
+
* @type {string}
|
|
3281
|
+
* @constant
|
|
3282
|
+
*/
|
|
3283
|
+
const DEFAULT_PART_SEPARATOR = '\n';
|
|
2892
3284
|
|
|
2893
|
-
|
|
2894
|
-
|
|
2895
|
-
|
|
2896
|
-
|
|
3285
|
+
/**
|
|
3286
|
+
* 默认键值分隔符
|
|
3287
|
+
* @type {string}
|
|
3288
|
+
* @constant
|
|
3289
|
+
*/
|
|
3290
|
+
const DEFAULT_KV_SEPARATOR = ':';
|
|
2897
3291
|
|
|
2898
|
-
|
|
2899
|
-
|
|
2900
|
-
|
|
2901
|
-
|
|
2902
|
-
['bindKey', WRAP_BIND_KEY_FLAG],
|
|
2903
|
-
['curry', WRAP_CURRY_FLAG],
|
|
2904
|
-
['curryRight', WRAP_CURRY_RIGHT_FLAG],
|
|
2905
|
-
['flip', WRAP_FLIP_FLAG],
|
|
2906
|
-
['partial', WRAP_PARTIAL_FLAG],
|
|
2907
|
-
['partialRight', WRAP_PARTIAL_RIGHT_FLAG],
|
|
2908
|
-
['rearg', WRAP_REARG_FLAG]
|
|
2909
|
-
];
|
|
3292
|
+
/**
|
|
3293
|
+
* SSE 字段类型定义
|
|
3294
|
+
* @typedef {'data'|'event'|'id'|'retry'} SSEFields
|
|
3295
|
+
*/
|
|
2910
3296
|
|
|
2911
|
-
|
|
2912
|
-
|
|
2913
|
-
|
|
2914
|
-
|
|
2915
|
-
|
|
2916
|
-
|
|
2917
|
-
|
|
2918
|
-
|
|
2919
|
-
funcTag = '[object Function]',
|
|
2920
|
-
genTag = '[object GeneratorFunction]',
|
|
2921
|
-
mapTag = '[object Map]',
|
|
2922
|
-
numberTag = '[object Number]',
|
|
2923
|
-
nullTag = '[object Null]',
|
|
2924
|
-
objectTag = '[object Object]',
|
|
2925
|
-
promiseTag = '[object Promise]',
|
|
2926
|
-
proxyTag = '[object Proxy]',
|
|
2927
|
-
regexpTag = '[object RegExp]',
|
|
2928
|
-
setTag = '[object Set]',
|
|
2929
|
-
stringTag = '[object String]',
|
|
2930
|
-
symbolTag = '[object Symbol]',
|
|
2931
|
-
undefinedTag = '[object Undefined]',
|
|
2932
|
-
weakMapTag = '[object WeakMap]',
|
|
2933
|
-
weakSetTag = '[object WeakSet]';
|
|
3297
|
+
/**
|
|
3298
|
+
* SSE 输出对象类型
|
|
3299
|
+
* @typedef {Object} SSEOutput
|
|
3300
|
+
* @property {string} [data] - 数据字段
|
|
3301
|
+
* @property {string} [event] - 事件字段
|
|
3302
|
+
* @property {string} [id] - ID字段
|
|
3303
|
+
* @property {string} [retry] - 重试字段
|
|
3304
|
+
*/
|
|
2934
3305
|
|
|
2935
|
-
|
|
2936
|
-
|
|
2937
|
-
|
|
2938
|
-
|
|
2939
|
-
|
|
2940
|
-
|
|
2941
|
-
int32Tag = '[object Int32Array]',
|
|
2942
|
-
uint8Tag = '[object Uint8Array]',
|
|
2943
|
-
uint8ClampedTag = '[object Uint8ClampedArray]',
|
|
2944
|
-
uint16Tag = '[object Uint16Array]',
|
|
2945
|
-
uint32Tag = '[object Uint32Array]';
|
|
3306
|
+
/**
|
|
3307
|
+
* 流配置选项
|
|
3308
|
+
* @typedef {Object} XStreamOptions
|
|
3309
|
+
* @property {ReadableStream<Uint8Array>} readableStream - 可读流
|
|
3310
|
+
* @property {TransformStream<string, *>} [transformStream] - 可选的转换流
|
|
3311
|
+
*/
|
|
2946
3312
|
|
|
2947
|
-
|
|
2948
|
-
|
|
2949
|
-
|
|
2950
|
-
|
|
3313
|
+
/**
|
|
3314
|
+
* 流状态对象
|
|
3315
|
+
* @typedef {Object} StreamState
|
|
3316
|
+
* @property {Array<*>} data - 流数据数组
|
|
3317
|
+
* @property {Error|null} error - 错误信息
|
|
3318
|
+
* @property {boolean} loading - 加载状态
|
|
3319
|
+
*/
|
|
2951
3320
|
|
|
2952
|
-
|
|
2953
|
-
|
|
2954
|
-
|
|
2955
|
-
|
|
2956
|
-
|
|
3321
|
+
/**
|
|
3322
|
+
* 流回调函数配置
|
|
3323
|
+
* @typedef {Object} StreamCallbacks
|
|
3324
|
+
* @property {function(*): void} [onData] - 数据回调函数
|
|
3325
|
+
* @property {function(Array<*>): void} [onComplete] - 完成回调函数
|
|
3326
|
+
* @property {function(Error): void} [onError] - 错误回调函数
|
|
3327
|
+
* @property {function(): void} [onCancel] - 取消回调函数
|
|
3328
|
+
* @property {function(): void} [onFinish] - 结束回调函数
|
|
3329
|
+
*/
|
|
2957
3330
|
|
|
2958
|
-
|
|
2959
|
-
|
|
2960
|
-
|
|
2961
|
-
|
|
3331
|
+
/**
|
|
3332
|
+
* 流工具函数返回对象
|
|
3333
|
+
* @typedef {Object} StreamUtils
|
|
3334
|
+
* @property {StreamState} state - 流状态
|
|
3335
|
+
* @property {function(XStreamOptions): Promise<void>} startStream - 启动流处理
|
|
3336
|
+
* @property {function(): void} cancel - 取消流处理
|
|
3337
|
+
* @property {function(): void} reset - 重置流状态
|
|
3338
|
+
*/
|
|
2962
3339
|
|
|
2963
|
-
|
|
2964
|
-
|
|
2965
|
-
|
|
2966
|
-
|
|
3340
|
+
/**
|
|
3341
|
+
* 验证字符串是否有效(非空且非空白)
|
|
3342
|
+
* @param {string} str - 待验证的字符串
|
|
3343
|
+
* @returns {boolean} 是否为有效字符串
|
|
3344
|
+
*/
|
|
3345
|
+
const isValidString = str => (str === null || str === undefined ? '' : str).trim() !== '';
|
|
2967
3346
|
|
|
2968
|
-
|
|
2969
|
-
|
|
2970
|
-
|
|
2971
|
-
|
|
2972
|
-
|
|
2973
|
-
|
|
3347
|
+
/**
|
|
3348
|
+
* 创建流分割转换器
|
|
3349
|
+
* 按照默认分隔符分割流数据
|
|
3350
|
+
* @returns {TransformStream<string, string>} 流分割转换器
|
|
3351
|
+
*/
|
|
3352
|
+
function splitStream() {
|
|
3353
|
+
let buffer = '';
|
|
3354
|
+
return new TransformStream({
|
|
3355
|
+
/**
|
|
3356
|
+
* 转换函数
|
|
3357
|
+
* @param {string} chunk - 数据块
|
|
3358
|
+
* @param {TransformStreamDefaultController<string>} controller - 控制器
|
|
3359
|
+
*/
|
|
3360
|
+
transform(chunk, controller) {
|
|
3361
|
+
buffer += chunk;
|
|
3362
|
+
const parts = buffer.split(DEFAULT_STREAM_SEPARATOR);
|
|
3363
|
+
parts.slice(0, -1).forEach(part => {
|
|
3364
|
+
if (isValidString(part)) controller.enqueue(part);
|
|
3365
|
+
});
|
|
3366
|
+
buffer = parts[parts.length - 1];
|
|
3367
|
+
},
|
|
3368
|
+
/**
|
|
3369
|
+
* 刷新函数
|
|
3370
|
+
* @param {TransformStreamDefaultController<string>} controller - 控制器
|
|
3371
|
+
*/
|
|
3372
|
+
flush(controller) {
|
|
3373
|
+
if (isValidString(buffer)) controller.enqueue(buffer);
|
|
3374
|
+
}
|
|
3375
|
+
});
|
|
3376
|
+
}
|
|
2974
3377
|
|
|
2975
|
-
|
|
2976
|
-
|
|
3378
|
+
/**
|
|
3379
|
+
* 创建 SSE 数据解析转换器
|
|
3380
|
+
* 将文本数据解析为 SSE 格式对象
|
|
3381
|
+
* @returns {TransformStream<string, SSEOutput>} SSE 解析转换器
|
|
3382
|
+
*/
|
|
3383
|
+
function splitPart() {
|
|
3384
|
+
return new TransformStream({
|
|
3385
|
+
/**
|
|
3386
|
+
* 转换函数
|
|
3387
|
+
* @param {string} partChunk - 数据块
|
|
3388
|
+
* @param {TransformStreamDefaultController<SSEOutput>} controller - 控制器
|
|
3389
|
+
*/
|
|
3390
|
+
transform(partChunk, controller) {
|
|
3391
|
+
const lines = partChunk.split(DEFAULT_PART_SEPARATOR);
|
|
3392
|
+
const sseEvent = lines.reduce((acc, line) => {
|
|
3393
|
+
const sepIndex = line.indexOf(DEFAULT_KV_SEPARATOR);
|
|
3394
|
+
if (sepIndex === -1) return acc;
|
|
3395
|
+
const key = line.slice(0, sepIndex);
|
|
3396
|
+
if (!isValidString(key)) return acc;
|
|
3397
|
+
const value = line.slice(sepIndex + 1);
|
|
3398
|
+
return {
|
|
3399
|
+
...acc,
|
|
3400
|
+
[key]: value
|
|
3401
|
+
};
|
|
3402
|
+
}, {});
|
|
3403
|
+
if (Object.keys(sseEvent).length > 0) controller.enqueue(sseEvent);
|
|
3404
|
+
}
|
|
3405
|
+
});
|
|
3406
|
+
}
|
|
2977
3407
|
|
|
2978
|
-
|
|
2979
|
-
|
|
3408
|
+
/**
|
|
3409
|
+
* 核心流处理函数(支持中断)
|
|
3410
|
+
* @param {XStreamOptions} options - 配置选项
|
|
3411
|
+
* @param {ReadableStream<Uint8Array>} options.readableStream - 可读流
|
|
3412
|
+
* @param {TransformStream<string, *>} [options.transformStream] - 可选的转换流
|
|
3413
|
+
* @param {AbortSignal} [signal] - 中断信号
|
|
3414
|
+
* @returns {ReadableStream<*>} 处理后的流,支持异步迭代
|
|
3415
|
+
* @throws {TypeError} 当 readableStream 不是 ReadableStream 实例时抛出
|
|
3416
|
+
*/
|
|
3417
|
+
function XStream(options, signal) {
|
|
3418
|
+
const {
|
|
3419
|
+
readableStream,
|
|
3420
|
+
transformStream
|
|
3421
|
+
} = options;
|
|
3422
|
+
if (!(readableStream instanceof ReadableStream)) {
|
|
3423
|
+
throw new TypeError('options.readableStream 必须是 ReadableStream 的实例。');
|
|
3424
|
+
}
|
|
3425
|
+
const decoderStream = new TextDecoderStream();
|
|
3426
|
+
const processedStream = transformStream ? readableStream.pipeThrough(decoderStream).pipeThrough(transformStream) : readableStream.pipeThrough(decoderStream).pipeThrough(splitStream()).pipeThrough(splitPart());
|
|
2980
3427
|
|
|
2981
|
-
|
|
2982
|
-
|
|
2983
|
-
|
|
2984
|
-
|
|
3428
|
+
// 为流添加异步迭代器并处理中断信号
|
|
3429
|
+
processedStream[Symbol.asyncIterator] = async function* () {
|
|
3430
|
+
const reader = this.getReader();
|
|
3431
|
+
this.reader = reader; // 保存读取器引用
|
|
3432
|
+
try {
|
|
3433
|
+
while (true) {
|
|
3434
|
+
if (signal && signal.aborted) {
|
|
3435
|
+
await reader.cancel(); // 主动取消 reader
|
|
3436
|
+
break;
|
|
3437
|
+
}
|
|
3438
|
+
const {
|
|
3439
|
+
done,
|
|
3440
|
+
value
|
|
3441
|
+
} = await reader.read();
|
|
3442
|
+
if (done) break;
|
|
3443
|
+
if (value) yield value;
|
|
3444
|
+
}
|
|
3445
|
+
} finally {
|
|
3446
|
+
reader.releaseLock(); // 释放锁
|
|
3447
|
+
}
|
|
3448
|
+
};
|
|
3449
|
+
return processedStream;
|
|
3450
|
+
}
|
|
2985
3451
|
|
|
2986
|
-
|
|
2987
|
-
|
|
3452
|
+
/**
|
|
3453
|
+
* streamMixin -
|
|
3454
|
+
* 用于处理流式数据的 mixin,支持 SSE 数据解析和中断功能
|
|
3455
|
+
* @namespace streamMixin
|
|
3456
|
+
* @type {Object}
|
|
3457
|
+
*/
|
|
3458
|
+
const streamMixin = {
|
|
3459
|
+
/**
|
|
3460
|
+
* 组件数据
|
|
3461
|
+
* @returns {Object} 响应式数据对象
|
|
3462
|
+
* @property {Array<*>} streamData - 流数据数组
|
|
3463
|
+
* @property {Error|null} streamError - 流错误信息
|
|
3464
|
+
* @property {boolean} streamLoading - 流处理状态
|
|
3465
|
+
* @property {AbortController|null} _abortController - 私有:中断控制器
|
|
3466
|
+
* @property {ReadableStream|null} _currentStream - 私有:当前流引用
|
|
3467
|
+
*/
|
|
3468
|
+
data() {
|
|
3469
|
+
return {
|
|
3470
|
+
streamData: [],
|
|
3471
|
+
streamError: null,
|
|
3472
|
+
streamLoading: false,
|
|
3473
|
+
_abortController: null,
|
|
3474
|
+
_currentStream: null
|
|
3475
|
+
};
|
|
3476
|
+
},
|
|
3477
|
+
methods: {
|
|
3478
|
+
/**
|
|
3479
|
+
* 启动流式请求
|
|
3480
|
+
* @async
|
|
3481
|
+
* @param {XStreamOptions} options - 流配置选项
|
|
3482
|
+
* @param {ReadableStream<Uint8Array>} options.readableStream - 可读流
|
|
3483
|
+
* @param {TransformStream<string, *>} [options.transformStream] - 可选的转换流
|
|
3484
|
+
* @returns {Promise<void>} 流处理完成的 Promise
|
|
3485
|
+
* @fires streamMixin#stream-data - 收到新数据时触发
|
|
3486
|
+
* @fires streamMixin#stream-complete - 流完成时触发
|
|
3487
|
+
* @fires streamMixin#stream-error - 流错误时触发
|
|
3488
|
+
* @fires streamMixin#stream-finish - 流处理结束时触发
|
|
3489
|
+
* @example
|
|
3490
|
+
* // 基础使用
|
|
3491
|
+
* const response = await fetch('/api/stream')
|
|
3492
|
+
* await this.startStream({ readableStream: response.body })
|
|
3493
|
+
*
|
|
3494
|
+
* // 使用自定义转换流
|
|
3495
|
+
* const customTransform = new TransformStream({ ... })
|
|
3496
|
+
* await this.startStream({
|
|
3497
|
+
* readableStream: response.body,
|
|
3498
|
+
* transformStream: customTransform
|
|
3499
|
+
* })
|
|
3500
|
+
*/
|
|
3501
|
+
async startStream(options) {
|
|
3502
|
+
this.streamLoading = true;
|
|
3503
|
+
this.streamError = null;
|
|
3504
|
+
this.streamData = [];
|
|
3505
|
+
this._abortController = new AbortController();
|
|
3506
|
+
this._currentStream = XStream(options, this._abortController.signal);
|
|
3507
|
+
try {
|
|
3508
|
+
for await (const item of this._currentStream) {
|
|
3509
|
+
this.streamData.push(item);
|
|
3510
|
+
// 触发数据更新事件
|
|
3511
|
+
/**
|
|
3512
|
+
* 流数据事件
|
|
3513
|
+
* @event streamMixin#stream-data
|
|
3514
|
+
* @type {*} 流数据项
|
|
3515
|
+
*/
|
|
3516
|
+
this.$emit('stream-data', item);
|
|
3517
|
+
}
|
|
3518
|
+
// 流完成事件
|
|
3519
|
+
/**
|
|
3520
|
+
* 流完成事件
|
|
3521
|
+
* @event streamMixin#stream-complete
|
|
3522
|
+
* @type {Array<*>} 所有流数据
|
|
3523
|
+
*/
|
|
3524
|
+
this.$emit('stream-complete', this.streamData);
|
|
3525
|
+
} catch (err) {
|
|
3526
|
+
if (err instanceof Error) {
|
|
3527
|
+
this.streamError = err;
|
|
3528
|
+
/**
|
|
3529
|
+
* 流错误事件
|
|
3530
|
+
* @event streamMixin#stream-error
|
|
3531
|
+
* @type {Error} 错误对象
|
|
3532
|
+
*/
|
|
3533
|
+
this.$emit('stream-error', err);
|
|
3534
|
+
}
|
|
3535
|
+
} finally {
|
|
3536
|
+
this.streamLoading = false;
|
|
3537
|
+
this._currentStream = null; // 释放流引用
|
|
3538
|
+
this._abortController = null; // 释放控制器
|
|
3539
|
+
/**
|
|
3540
|
+
* 流处理结束事件
|
|
3541
|
+
* @event streamMixin#stream-finish
|
|
3542
|
+
*/
|
|
3543
|
+
this.$emit('stream-finish');
|
|
3544
|
+
}
|
|
3545
|
+
},
|
|
3546
|
+
/**
|
|
3547
|
+
* 中断流式请求(强制关闭流)
|
|
3548
|
+
* @returns {void}
|
|
3549
|
+
* @fires streamMixin#stream-cancel - 流被中断时触发
|
|
3550
|
+
* @example
|
|
3551
|
+
* this.cancelStream()
|
|
3552
|
+
*/
|
|
3553
|
+
cancelStream() {
|
|
3554
|
+
if (this._abortController) {
|
|
3555
|
+
this._abortController.abort();
|
|
3556
|
+
/**
|
|
3557
|
+
* 流取消事件
|
|
3558
|
+
* @event streamMixin#stream-cancel
|
|
3559
|
+
*/
|
|
3560
|
+
this.$emit('stream-cancel');
|
|
3561
|
+
}
|
|
3562
|
+
},
|
|
3563
|
+
/**
|
|
3564
|
+
* 重置流状态
|
|
3565
|
+
* 清空所有数据和状态,但不触发事件
|
|
3566
|
+
* @returns {void}
|
|
3567
|
+
* @example
|
|
3568
|
+
* this.resetStream()
|
|
3569
|
+
*/
|
|
3570
|
+
resetStream() {
|
|
3571
|
+
this.streamData = [];
|
|
3572
|
+
this.streamError = null;
|
|
3573
|
+
this.streamLoading = false;
|
|
3574
|
+
this._abortController = null;
|
|
3575
|
+
this._currentStream = null;
|
|
3576
|
+
},
|
|
3577
|
+
/**
|
|
3578
|
+
* 创建流处理器的便捷方法
|
|
3579
|
+
* @param {ReadableStream<Uint8Array>} readableStream - 可读流
|
|
3580
|
+
* @param {TransformStream<string, *>} [transformStream] - 可选的转换流
|
|
3581
|
+
* @returns {XStreamOptions} 流处理器配置对象
|
|
3582
|
+
* @example
|
|
3583
|
+
* const processor = this.createStreamProcessor(response.body)
|
|
3584
|
+
* await this.startStream(processor)
|
|
3585
|
+
*/
|
|
3586
|
+
createStreamProcessor(readableStream, transformStream) {
|
|
3587
|
+
return {
|
|
3588
|
+
readableStream,
|
|
3589
|
+
transformStream
|
|
3590
|
+
};
|
|
3591
|
+
}
|
|
3592
|
+
},
|
|
3593
|
+
/**
|
|
3594
|
+
* 组件销毁前的生命周期钩子
|
|
3595
|
+
* 自动清理流资源
|
|
3596
|
+
* @returns {void}
|
|
3597
|
+
*/
|
|
3598
|
+
beforeDestroy() {
|
|
3599
|
+
// 组件销毁时清理资源
|
|
3600
|
+
this.cancelStream();
|
|
3601
|
+
}
|
|
3602
|
+
};
|
|
2988
3603
|
|
|
2989
|
-
|
|
2990
|
-
|
|
2991
|
-
|
|
2992
|
-
|
|
2993
|
-
|
|
2994
|
-
|
|
2995
|
-
|
|
2996
|
-
|
|
2997
|
-
|
|
3604
|
+
/**
|
|
3605
|
+
* 工具函数版本 - 用于非组件场景
|
|
3606
|
+
* @param {StreamCallbacks} [callbacks={}] - 回调函数配置
|
|
3607
|
+
* @param {function(*): void} [callbacks.onData] - 数据回调函数
|
|
3608
|
+
* @param {function(Array<*>): void} [callbacks.onComplete] - 完成回调函数
|
|
3609
|
+
* @param {function(Error): void} [callbacks.onError] - 错误回调函数
|
|
3610
|
+
* @param {function(): void} [callbacks.onCancel] - 取消回调函数
|
|
3611
|
+
* @param {function(): void} [callbacks.onFinish] - 结束回调函数
|
|
3612
|
+
* @returns {StreamUtils} 包含流处理相关方法的对象
|
|
3613
|
+
* @example
|
|
3614
|
+
* // 基础使用
|
|
3615
|
+
* const streamUtils = createStreamUtils({
|
|
3616
|
+
* onData: (item) => console.log('数据:', item),
|
|
3617
|
+
* onComplete: (allData) => console.log('完成:', allData),
|
|
3618
|
+
* onError: (error) => console.error('错误:', error)
|
|
3619
|
+
* })
|
|
3620
|
+
*
|
|
3621
|
+
* const response = await fetch('/api/stream')
|
|
3622
|
+
* await streamUtils.startStream({ readableStream: response.body })
|
|
3623
|
+
*/
|
|
3624
|
+
function createStreamUtils(callbacks = {}) {
|
|
3625
|
+
/**
|
|
3626
|
+
* 流状态对象
|
|
3627
|
+
* @type {StreamState}
|
|
2998
3628
|
*/
|
|
2999
|
-
|
|
3629
|
+
const state = {
|
|
3630
|
+
data: [],
|
|
3631
|
+
error: null,
|
|
3632
|
+
loading: false
|
|
3633
|
+
};
|
|
3634
|
+
let abortController = null;
|
|
3635
|
+
let currentStream = null;
|
|
3000
3636
|
|
|
3001
|
-
/**
|
|
3002
|
-
|
|
3637
|
+
/**
|
|
3638
|
+
* 启动流处理
|
|
3639
|
+
* @async
|
|
3640
|
+
* @param {XStreamOptions} options - 流配置选项
|
|
3641
|
+
* @returns {Promise<void>} 流处理完成的 Promise
|
|
3642
|
+
*/
|
|
3643
|
+
const startStream = async options => {
|
|
3644
|
+
state.loading = true;
|
|
3645
|
+
state.error = null;
|
|
3646
|
+
state.data = [];
|
|
3647
|
+
abortController = new AbortController();
|
|
3648
|
+
currentStream = XStream(options, abortController.signal);
|
|
3649
|
+
try {
|
|
3650
|
+
for await (const item of currentStream) {
|
|
3651
|
+
state.data.push(item);
|
|
3652
|
+
if (callbacks.onData) {
|
|
3653
|
+
callbacks.onData(item);
|
|
3654
|
+
}
|
|
3655
|
+
}
|
|
3656
|
+
if (callbacks.onComplete) {
|
|
3657
|
+
callbacks.onComplete(state.data);
|
|
3658
|
+
}
|
|
3659
|
+
} catch (err) {
|
|
3660
|
+
if (err instanceof Error) {
|
|
3661
|
+
state.error = err;
|
|
3662
|
+
if (callbacks.onError) {
|
|
3663
|
+
callbacks.onError(err);
|
|
3664
|
+
}
|
|
3665
|
+
}
|
|
3666
|
+
} finally {
|
|
3667
|
+
state.loading = false;
|
|
3668
|
+
currentStream = null;
|
|
3669
|
+
abortController = null;
|
|
3670
|
+
if (callbacks.onFinish) {
|
|
3671
|
+
callbacks.onFinish();
|
|
3672
|
+
}
|
|
3673
|
+
}
|
|
3674
|
+
};
|
|
3003
3675
|
|
|
3004
|
-
/**
|
|
3005
|
-
*
|
|
3006
|
-
*
|
|
3676
|
+
/**
|
|
3677
|
+
* 取消流处理
|
|
3678
|
+
* @returns {void}
|
|
3007
3679
|
*/
|
|
3008
|
-
|
|
3680
|
+
const cancel = () => {
|
|
3681
|
+
if (abortController) {
|
|
3682
|
+
abortController.abort();
|
|
3683
|
+
if (callbacks.onCancel) {
|
|
3684
|
+
callbacks.onCancel();
|
|
3685
|
+
}
|
|
3686
|
+
}
|
|
3687
|
+
};
|
|
3009
3688
|
|
|
3010
|
-
/**
|
|
3011
|
-
|
|
3689
|
+
/**
|
|
3690
|
+
* 重置流状态
|
|
3691
|
+
* @returns {void}
|
|
3692
|
+
*/
|
|
3693
|
+
const reset = () => {
|
|
3694
|
+
state.data = [];
|
|
3695
|
+
state.error = null;
|
|
3696
|
+
state.loading = false;
|
|
3697
|
+
abortController = null;
|
|
3698
|
+
currentStream = null;
|
|
3699
|
+
};
|
|
3700
|
+
return {
|
|
3701
|
+
state,
|
|
3702
|
+
startStream,
|
|
3703
|
+
cancel,
|
|
3704
|
+
reset
|
|
3705
|
+
};
|
|
3706
|
+
}
|
|
3012
3707
|
|
|
3013
|
-
|
|
3014
|
-
var reIsBadHex = /^[-+]0x[0-9a-f]+$/i;
|
|
3708
|
+
// 导出常量和工具函数
|
|
3015
3709
|
|
|
3016
|
-
/** Used to detect binary string values. */
|
|
3017
|
-
var reIsBinary = /^0b[01]+$/i;
|
|
3018
3710
|
|
|
3019
|
-
|
|
3020
|
-
|
|
3711
|
+
/**
|
|
3712
|
+
* 默认导出 streamMixin
|
|
3713
|
+
* @type {Object}
|
|
3714
|
+
*/
|
|
3715
|
+
/* harmony default export */ var mixins_streamMixin = (streamMixin);
|
|
3716
|
+
// CONCATENATED MODULE: ./src/mixins/index.js
|
|
3717
|
+
/**
|
|
3718
|
+
* Mixins 入口文件
|
|
3719
|
+
*/
|
|
3720
|
+
|
|
3721
|
+
|
|
3722
|
+
|
|
3723
|
+
|
|
3724
|
+
|
|
3725
|
+
/* harmony default export */ var mixins = __webpack_exports__["default"] = ({
|
|
3726
|
+
recordMixin: recordMixin,
|
|
3727
|
+
sendMixin: sendMixin,
|
|
3728
|
+
XRequest: XRequest,
|
|
3729
|
+
createSendUtils: createSendUtils,
|
|
3730
|
+
streamMixin: streamMixin,
|
|
3731
|
+
createStreamUtils: createStreamUtils,
|
|
3732
|
+
XStream: XStream,
|
|
3733
|
+
splitStream: splitStream,
|
|
3734
|
+
splitPart: splitPart,
|
|
3735
|
+
isValidString: isValidString,
|
|
3736
|
+
DEFAULT_STREAM_SEPARATOR: DEFAULT_STREAM_SEPARATOR,
|
|
3737
|
+
DEFAULT_PART_SEPARATOR: DEFAULT_PART_SEPARATOR,
|
|
3738
|
+
DEFAULT_KV_SEPARATOR: DEFAULT_KV_SEPARATOR
|
|
3739
|
+
});
|
|
3740
|
+
|
|
3741
|
+
/***/ }),
|
|
3742
|
+
/* 6 */
|
|
3743
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
3744
|
+
|
|
3745
|
+
/* WEBPACK VAR INJECTION */(function(global, module) {var __WEBPACK_AMD_DEFINE_RESULT__;/**
|
|
3746
|
+
* @license
|
|
3747
|
+
* Lodash <https://lodash.com/>
|
|
3748
|
+
* Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
|
|
3749
|
+
* Released under MIT license <https://lodash.com/license>
|
|
3750
|
+
* Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
|
|
3751
|
+
* Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
|
|
3752
|
+
*/
|
|
3753
|
+
;(function() {
|
|
3754
|
+
|
|
3755
|
+
/** Used as a safe reference for `undefined` in pre-ES5 environments. */
|
|
3756
|
+
var undefined;
|
|
3757
|
+
|
|
3758
|
+
/** Used as the semantic version number. */
|
|
3759
|
+
var VERSION = '4.17.21';
|
|
3760
|
+
|
|
3761
|
+
/** Used as the size to enable large array optimizations. */
|
|
3762
|
+
var LARGE_ARRAY_SIZE = 200;
|
|
3763
|
+
|
|
3764
|
+
/** Error message constants. */
|
|
3765
|
+
var CORE_ERROR_TEXT = 'Unsupported core-js use. Try https://npms.io/search?q=ponyfill.',
|
|
3766
|
+
FUNC_ERROR_TEXT = 'Expected a function',
|
|
3767
|
+
INVALID_TEMPL_VAR_ERROR_TEXT = 'Invalid `variable` option passed into `_.template`';
|
|
3768
|
+
|
|
3769
|
+
/** Used to stand-in for `undefined` hash values. */
|
|
3770
|
+
var HASH_UNDEFINED = '__lodash_hash_undefined__';
|
|
3771
|
+
|
|
3772
|
+
/** Used as the maximum memoize cache size. */
|
|
3773
|
+
var MAX_MEMOIZE_SIZE = 500;
|
|
3774
|
+
|
|
3775
|
+
/** Used as the internal argument placeholder. */
|
|
3776
|
+
var PLACEHOLDER = '__lodash_placeholder__';
|
|
3777
|
+
|
|
3778
|
+
/** Used to compose bitmasks for cloning. */
|
|
3779
|
+
var CLONE_DEEP_FLAG = 1,
|
|
3780
|
+
CLONE_FLAT_FLAG = 2,
|
|
3781
|
+
CLONE_SYMBOLS_FLAG = 4;
|
|
3782
|
+
|
|
3783
|
+
/** Used to compose bitmasks for value comparisons. */
|
|
3784
|
+
var COMPARE_PARTIAL_FLAG = 1,
|
|
3785
|
+
COMPARE_UNORDERED_FLAG = 2;
|
|
3786
|
+
|
|
3787
|
+
/** Used to compose bitmasks for function metadata. */
|
|
3788
|
+
var WRAP_BIND_FLAG = 1,
|
|
3789
|
+
WRAP_BIND_KEY_FLAG = 2,
|
|
3790
|
+
WRAP_CURRY_BOUND_FLAG = 4,
|
|
3791
|
+
WRAP_CURRY_FLAG = 8,
|
|
3792
|
+
WRAP_CURRY_RIGHT_FLAG = 16,
|
|
3793
|
+
WRAP_PARTIAL_FLAG = 32,
|
|
3794
|
+
WRAP_PARTIAL_RIGHT_FLAG = 64,
|
|
3795
|
+
WRAP_ARY_FLAG = 128,
|
|
3796
|
+
WRAP_REARG_FLAG = 256,
|
|
3797
|
+
WRAP_FLIP_FLAG = 512;
|
|
3798
|
+
|
|
3799
|
+
/** Used as default options for `_.truncate`. */
|
|
3800
|
+
var DEFAULT_TRUNC_LENGTH = 30,
|
|
3801
|
+
DEFAULT_TRUNC_OMISSION = '...';
|
|
3802
|
+
|
|
3803
|
+
/** Used to detect hot functions by number of calls within a span of milliseconds. */
|
|
3804
|
+
var HOT_COUNT = 800,
|
|
3805
|
+
HOT_SPAN = 16;
|
|
3806
|
+
|
|
3807
|
+
/** Used to indicate the type of lazy iteratees. */
|
|
3808
|
+
var LAZY_FILTER_FLAG = 1,
|
|
3809
|
+
LAZY_MAP_FLAG = 2,
|
|
3810
|
+
LAZY_WHILE_FLAG = 3;
|
|
3811
|
+
|
|
3812
|
+
/** Used as references for various `Number` constants. */
|
|
3813
|
+
var INFINITY = 1 / 0,
|
|
3814
|
+
MAX_SAFE_INTEGER = 9007199254740991,
|
|
3815
|
+
MAX_INTEGER = 1.7976931348623157e+308,
|
|
3816
|
+
NAN = 0 / 0;
|
|
3817
|
+
|
|
3818
|
+
/** Used as references for the maximum length and index of an array. */
|
|
3819
|
+
var MAX_ARRAY_LENGTH = 4294967295,
|
|
3820
|
+
MAX_ARRAY_INDEX = MAX_ARRAY_LENGTH - 1,
|
|
3821
|
+
HALF_MAX_ARRAY_LENGTH = MAX_ARRAY_LENGTH >>> 1;
|
|
3822
|
+
|
|
3823
|
+
/** Used to associate wrap methods with their bit flags. */
|
|
3824
|
+
var wrapFlags = [
|
|
3825
|
+
['ary', WRAP_ARY_FLAG],
|
|
3826
|
+
['bind', WRAP_BIND_FLAG],
|
|
3827
|
+
['bindKey', WRAP_BIND_KEY_FLAG],
|
|
3828
|
+
['curry', WRAP_CURRY_FLAG],
|
|
3829
|
+
['curryRight', WRAP_CURRY_RIGHT_FLAG],
|
|
3830
|
+
['flip', WRAP_FLIP_FLAG],
|
|
3831
|
+
['partial', WRAP_PARTIAL_FLAG],
|
|
3832
|
+
['partialRight', WRAP_PARTIAL_RIGHT_FLAG],
|
|
3833
|
+
['rearg', WRAP_REARG_FLAG]
|
|
3834
|
+
];
|
|
3835
|
+
|
|
3836
|
+
/** `Object#toString` result references. */
|
|
3837
|
+
var argsTag = '[object Arguments]',
|
|
3838
|
+
arrayTag = '[object Array]',
|
|
3839
|
+
asyncTag = '[object AsyncFunction]',
|
|
3840
|
+
boolTag = '[object Boolean]',
|
|
3841
|
+
dateTag = '[object Date]',
|
|
3842
|
+
domExcTag = '[object DOMException]',
|
|
3843
|
+
errorTag = '[object Error]',
|
|
3844
|
+
funcTag = '[object Function]',
|
|
3845
|
+
genTag = '[object GeneratorFunction]',
|
|
3846
|
+
mapTag = '[object Map]',
|
|
3847
|
+
numberTag = '[object Number]',
|
|
3848
|
+
nullTag = '[object Null]',
|
|
3849
|
+
objectTag = '[object Object]',
|
|
3850
|
+
promiseTag = '[object Promise]',
|
|
3851
|
+
proxyTag = '[object Proxy]',
|
|
3852
|
+
regexpTag = '[object RegExp]',
|
|
3853
|
+
setTag = '[object Set]',
|
|
3854
|
+
stringTag = '[object String]',
|
|
3855
|
+
symbolTag = '[object Symbol]',
|
|
3856
|
+
undefinedTag = '[object Undefined]',
|
|
3857
|
+
weakMapTag = '[object WeakMap]',
|
|
3858
|
+
weakSetTag = '[object WeakSet]';
|
|
3859
|
+
|
|
3860
|
+
var arrayBufferTag = '[object ArrayBuffer]',
|
|
3861
|
+
dataViewTag = '[object DataView]',
|
|
3862
|
+
float32Tag = '[object Float32Array]',
|
|
3863
|
+
float64Tag = '[object Float64Array]',
|
|
3864
|
+
int8Tag = '[object Int8Array]',
|
|
3865
|
+
int16Tag = '[object Int16Array]',
|
|
3866
|
+
int32Tag = '[object Int32Array]',
|
|
3867
|
+
uint8Tag = '[object Uint8Array]',
|
|
3868
|
+
uint8ClampedTag = '[object Uint8ClampedArray]',
|
|
3869
|
+
uint16Tag = '[object Uint16Array]',
|
|
3870
|
+
uint32Tag = '[object Uint32Array]';
|
|
3871
|
+
|
|
3872
|
+
/** Used to match empty string literals in compiled template source. */
|
|
3873
|
+
var reEmptyStringLeading = /\b__p \+= '';/g,
|
|
3874
|
+
reEmptyStringMiddle = /\b(__p \+=) '' \+/g,
|
|
3875
|
+
reEmptyStringTrailing = /(__e\(.*?\)|\b__t\)) \+\n'';/g;
|
|
3876
|
+
|
|
3877
|
+
/** Used to match HTML entities and HTML characters. */
|
|
3878
|
+
var reEscapedHtml = /&(?:amp|lt|gt|quot|#39);/g,
|
|
3879
|
+
reUnescapedHtml = /[&<>"']/g,
|
|
3880
|
+
reHasEscapedHtml = RegExp(reEscapedHtml.source),
|
|
3881
|
+
reHasUnescapedHtml = RegExp(reUnescapedHtml.source);
|
|
3882
|
+
|
|
3883
|
+
/** Used to match template delimiters. */
|
|
3884
|
+
var reEscape = /<%-([\s\S]+?)%>/g,
|
|
3885
|
+
reEvaluate = /<%([\s\S]+?)%>/g,
|
|
3886
|
+
reInterpolate = /<%=([\s\S]+?)%>/g;
|
|
3887
|
+
|
|
3888
|
+
/** Used to match property names within property paths. */
|
|
3889
|
+
var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,
|
|
3890
|
+
reIsPlainProp = /^\w*$/,
|
|
3891
|
+
rePropName = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g;
|
|
3892
|
+
|
|
3893
|
+
/**
|
|
3894
|
+
* Used to match `RegExp`
|
|
3895
|
+
* [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).
|
|
3896
|
+
*/
|
|
3897
|
+
var reRegExpChar = /[\\^$.*+?()[\]{}|]/g,
|
|
3898
|
+
reHasRegExpChar = RegExp(reRegExpChar.source);
|
|
3899
|
+
|
|
3900
|
+
/** Used to match leading whitespace. */
|
|
3901
|
+
var reTrimStart = /^\s+/;
|
|
3902
|
+
|
|
3903
|
+
/** Used to match a single whitespace character. */
|
|
3904
|
+
var reWhitespace = /\s/;
|
|
3905
|
+
|
|
3906
|
+
/** Used to match wrap detail comments. */
|
|
3907
|
+
var reWrapComment = /\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,
|
|
3908
|
+
reWrapDetails = /\{\n\/\* \[wrapped with (.+)\] \*/,
|
|
3909
|
+
reSplitDetails = /,? & /;
|
|
3910
|
+
|
|
3911
|
+
/** Used to match words composed of alphanumeric characters. */
|
|
3912
|
+
var reAsciiWord = /[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;
|
|
3913
|
+
|
|
3914
|
+
/**
|
|
3915
|
+
* Used to validate the `validate` option in `_.template` variable.
|
|
3916
|
+
*
|
|
3917
|
+
* Forbids characters which could potentially change the meaning of the function argument definition:
|
|
3918
|
+
* - "()," (modification of function parameters)
|
|
3919
|
+
* - "=" (default value)
|
|
3920
|
+
* - "[]{}" (destructuring of function parameters)
|
|
3921
|
+
* - "/" (beginning of a comment)
|
|
3922
|
+
* - whitespace
|
|
3923
|
+
*/
|
|
3924
|
+
var reForbiddenIdentifierChars = /[()=,{}\[\]\/\s]/;
|
|
3925
|
+
|
|
3926
|
+
/** Used to match backslashes in property paths. */
|
|
3927
|
+
var reEscapeChar = /\\(\\)?/g;
|
|
3928
|
+
|
|
3929
|
+
/**
|
|
3930
|
+
* Used to match
|
|
3931
|
+
* [ES template delimiters](http://ecma-international.org/ecma-262/7.0/#sec-template-literal-lexical-components).
|
|
3932
|
+
*/
|
|
3933
|
+
var reEsTemplate = /\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g;
|
|
3934
|
+
|
|
3935
|
+
/** Used to match `RegExp` flags from their coerced string values. */
|
|
3936
|
+
var reFlags = /\w*$/;
|
|
3937
|
+
|
|
3938
|
+
/** Used to detect bad signed hexadecimal string values. */
|
|
3939
|
+
var reIsBadHex = /^[-+]0x[0-9a-f]+$/i;
|
|
3940
|
+
|
|
3941
|
+
/** Used to detect binary string values. */
|
|
3942
|
+
var reIsBinary = /^0b[01]+$/i;
|
|
3943
|
+
|
|
3944
|
+
/** Used to detect host constructors (Safari). */
|
|
3945
|
+
var reIsHostCtor = /^\[object .+?Constructor\]$/;
|
|
3021
3946
|
|
|
3022
3947
|
/** Used to detect octal string values. */
|
|
3023
3948
|
var reIsOctal = /^0o[0-7]+$/i;
|
|
@@ -20019,16 +20944,16 @@ Prism.languages.js = Prism.languages.javascript;
|
|
|
20019
20944
|
else {}
|
|
20020
20945
|
}.call(this));
|
|
20021
20946
|
|
|
20022
|
-
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(
|
|
20947
|
+
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(11), __webpack_require__(24)(module)))
|
|
20023
20948
|
|
|
20024
20949
|
/***/ }),
|
|
20025
|
-
/*
|
|
20950
|
+
/* 7 */
|
|
20026
20951
|
/***/ (function(module, exports) {
|
|
20027
20952
|
|
|
20028
20953
|
module.exports=/[!-#%-\*,-\/:;\?@\[-\]_\{\}\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061E\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u09FD\u0A76\u0AF0\u0C84\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166D\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E4E\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]|\uD800[\uDD00-\uDD02\uDF9F\uDFD0]|\uD801\uDD6F|\uD802[\uDC57\uDD1F\uDD3F\uDE50-\uDE58\uDE7F\uDEF0-\uDEF6\uDF39-\uDF3F\uDF99-\uDF9C]|\uD803[\uDF55-\uDF59]|\uD804[\uDC47-\uDC4D\uDCBB\uDCBC\uDCBE-\uDCC1\uDD40-\uDD43\uDD74\uDD75\uDDC5-\uDDC8\uDDCD\uDDDB\uDDDD-\uDDDF\uDE38-\uDE3D\uDEA9]|\uD805[\uDC4B-\uDC4F\uDC5B\uDC5D\uDCC6\uDDC1-\uDDD7\uDE41-\uDE43\uDE60-\uDE6C\uDF3C-\uDF3E]|\uD806[\uDC3B\uDE3F-\uDE46\uDE9A-\uDE9C\uDE9E-\uDEA2]|\uD807[\uDC41-\uDC45\uDC70\uDC71\uDEF7\uDEF8]|\uD809[\uDC70-\uDC74]|\uD81A[\uDE6E\uDE6F\uDEF5\uDF37-\uDF3B\uDF44]|\uD81B[\uDE97-\uDE9A]|\uD82F\uDC9F|\uD836[\uDE87-\uDE8B]|\uD83A[\uDD5E\uDD5F]/
|
|
20029
20954
|
|
|
20030
20955
|
/***/ }),
|
|
20031
|
-
/*
|
|
20956
|
+
/* 8 */
|
|
20032
20957
|
/***/ (function(module, exports, __webpack_require__) {
|
|
20033
20958
|
|
|
20034
20959
|
"use strict";
|
|
@@ -20387,7 +21312,7 @@ module.exports = Ruler;
|
|
|
20387
21312
|
|
|
20388
21313
|
|
|
20389
21314
|
/***/ }),
|
|
20390
|
-
/*
|
|
21315
|
+
/* 9 */
|
|
20391
21316
|
/***/ (function(module, exports, __webpack_require__) {
|
|
20392
21317
|
|
|
20393
21318
|
"use strict";
|
|
@@ -20595,26 +21520,26 @@ module.exports = Token;
|
|
|
20595
21520
|
|
|
20596
21521
|
|
|
20597
21522
|
/***/ }),
|
|
20598
|
-
/*
|
|
21523
|
+
/* 10 */
|
|
20599
21524
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
20600
21525
|
|
|
20601
21526
|
"use strict";
|
|
20602
21527
|
/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2);
|
|
20603
21528
|
/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
20604
|
-
/* harmony import */ var _node_modules_css_loader_dist_cjs_js_node_modules_prismjs_themes_prism_css__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
|
|
21529
|
+
/* harmony import */ var _node_modules_css_loader_dist_cjs_js_node_modules_prismjs_themes_prism_css__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23);
|
|
20605
21530
|
// Imports
|
|
20606
21531
|
|
|
20607
21532
|
|
|
20608
21533
|
var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(function(i){return i[1]});
|
|
20609
21534
|
___CSS_LOADER_EXPORT___.i(_node_modules_css_loader_dist_cjs_js_node_modules_prismjs_themes_prism_css__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"]);
|
|
20610
21535
|
// Module
|
|
20611
|
-
___CSS_LOADER_EXPORT___.push([module.i, ".typer-container[data-v-0a15f16e]{overflow-x:auto}.markdown-content[data-v-0a15f16e] ul{list-style-type:disc}.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h1,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h2,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h3,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h4,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h5,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h6,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] p,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] ol:last-child li,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] ul:last-child li,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h1,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h2,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h3,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h4,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h5,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h6,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] p,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] ol:last-child li,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] ul:last-child li{position:relative;overflow:hidden}.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h1:last-child:after,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h2:last-child:after,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h3:last-child:after,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h4:last-child:after,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h5:last-child:after,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h6:last-child:after,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] p:last-child:after,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] ol:last-child li:last-child:after,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] ul:last-child li:last-child:after,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h1:last-child:after,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h2:last-child:after,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h3:last-child:after,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h4:last-child:after,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h5:last-child:after,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h6:last-child:after,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] p:last-child:after,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] ol:last-child li:last-child:after,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] ul:last-child li:last-child:after{content
|
|
21536
|
+
___CSS_LOADER_EXPORT___.push([module.i, ".typer-container[data-v-0a15f16e]{overflow-x:auto}.markdown-content[data-v-0a15f16e] ul{list-style-type:disc}.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h1,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h2,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h3,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h4,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h5,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h6,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] p,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] ol:last-child li,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] ul:last-child li,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h1,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h2,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h3,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h4,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h5,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h6,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] p,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] ol:last-child li,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] ul:last-child li{position:relative;overflow:hidden}.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h1:last-child:after,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h2:last-child:after,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h3:last-child:after,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h4:last-child:after,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h5:last-child:after,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] h6:last-child:after,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] p:last-child:after,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] ol:last-child li:last-child:after,.typing-markdown-cursor-foggy.markdown-content[data-v-0a15f16e] ul:last-child li:last-child:after,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h1:last-child:after,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h2:last-child:after,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h3:last-child:after,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h4:last-child:after,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h5:last-child:after,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] h6:last-child:after,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] p:last-child:after,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] ol:last-child li:last-child:after,.typing-cursor-foggy.markdown-content[data-v-0a15f16e] ul:last-child li:last-child:after{content:\"\";width:var(--cursor-fog-width);height:1.5em;background:linear-gradient(90deg, transparent, var(--cursor-fog-bg-color));position:absolute;margin-left:calc(-1*var(--cursor-fog-width))}.typer-content.typing-cursor[data-v-0a15f16e]::after{content:var(--cursor-char);margin-left:2px;display:inline-block}.typer-content.typing-cursor-foggy[data-v-0a15f16e]{position:relative;overflow:hidden}.typer-content.typing-cursor-foggy[data-v-0a15f16e]:last-child:after{content:\"\";width:var(--cursor-fog-width);height:100%;background:linear-gradient(90deg, transparent, var(--cursor-fog-bg-color));position:absolute;margin-left:calc(-1*var(--cursor-fog-width))}", ""]);
|
|
20612
21537
|
// Exports
|
|
20613
21538
|
/* harmony default export */ __webpack_exports__["a"] = (___CSS_LOADER_EXPORT___);
|
|
20614
21539
|
|
|
20615
21540
|
|
|
20616
21541
|
/***/ }),
|
|
20617
|
-
/*
|
|
21542
|
+
/* 11 */
|
|
20618
21543
|
/***/ (function(module, exports) {
|
|
20619
21544
|
|
|
20620
21545
|
var g;
|
|
@@ -20640,7 +21565,7 @@ module.exports = g;
|
|
|
20640
21565
|
|
|
20641
21566
|
|
|
20642
21567
|
/***/ }),
|
|
20643
|
-
/*
|
|
21568
|
+
/* 12 */
|
|
20644
21569
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
20645
21570
|
|
|
20646
21571
|
"use strict";
|
|
@@ -20679,11 +21604,11 @@ render._withStripped = true;
|
|
|
20679
21604
|
// CONCATENATED MODULE: ./src/components/Typewriter/src/main.vue?vue&type=template&id=0a15f16e&scoped=true
|
|
20680
21605
|
|
|
20681
21606
|
// EXTERNAL MODULE: ./node_modules/dompurify/dist/purify.js
|
|
20682
|
-
var purify = __webpack_require__(
|
|
21607
|
+
var purify = __webpack_require__(21);
|
|
20683
21608
|
var purify_default = /*#__PURE__*/__webpack_require__.n(purify);
|
|
20684
21609
|
|
|
20685
21610
|
// EXTERNAL MODULE: ./node_modules/markdown-it/index.js
|
|
20686
|
-
var markdown_it = __webpack_require__(
|
|
21611
|
+
var markdown_it = __webpack_require__(22);
|
|
20687
21612
|
var markdown_it_default = /*#__PURE__*/__webpack_require__.n(markdown_it);
|
|
20688
21613
|
|
|
20689
21614
|
// EXTERNAL MODULE: ./node_modules/prismjs/prism.js
|
|
@@ -20876,7 +21801,7 @@ var injectStylesIntoStyleTag = __webpack_require__(3);
|
|
|
20876
21801
|
var injectStylesIntoStyleTag_default = /*#__PURE__*/__webpack_require__.n(injectStylesIntoStyleTag);
|
|
20877
21802
|
|
|
20878
21803
|
// EXTERNAL MODULE: ./node_modules/css-loader/dist/cjs.js!./node_modules/vue-loader/lib/loaders/stylePostLoader.js!./node_modules/sass-loader/dist/cjs.js!./node_modules/vue-loader/lib??vue-loader-options!./src/components/Typewriter/src/main.vue?vue&type=style&index=0&id=0a15f16e&prod&lang=scss&scoped=true
|
|
20879
|
-
var mainvue_type_style_index_0_id_0a15f16e_prod_lang_scss_scoped_true = __webpack_require__(
|
|
21804
|
+
var mainvue_type_style_index_0_id_0a15f16e_prod_lang_scss_scoped_true = __webpack_require__(10);
|
|
20880
21805
|
|
|
20881
21806
|
// CONCATENATED MODULE: ./node_modules/style-loader/dist/cjs.js!./node_modules/css-loader/dist/cjs.js!./node_modules/vue-loader/lib/loaders/stylePostLoader.js!./node_modules/sass-loader/dist/cjs.js!./node_modules/vue-loader/lib??vue-loader-options!./src/components/Typewriter/src/main.vue?vue&type=style&index=0&id=0a15f16e&prod&lang=scss&scoped=true
|
|
20882
21807
|
|
|
@@ -20928,7 +21853,7 @@ main.install = function (Vue) {
|
|
|
20928
21853
|
/* harmony default export */ var Typewriter = __webpack_exports__["default"] = (main);
|
|
20929
21854
|
|
|
20930
21855
|
/***/ }),
|
|
20931
|
-
/*
|
|
21856
|
+
/* 13 */
|
|
20932
21857
|
/***/ (function(module, exports, __webpack_require__) {
|
|
20933
21858
|
|
|
20934
21859
|
"use strict";
|
|
@@ -20941,7 +21866,7 @@ module.exports = __webpack_require__(30);
|
|
|
20941
21866
|
|
|
20942
21867
|
|
|
20943
21868
|
/***/ }),
|
|
20944
|
-
/*
|
|
21869
|
+
/* 14 */
|
|
20945
21870
|
/***/ (function(module, exports, __webpack_require__) {
|
|
20946
21871
|
|
|
20947
21872
|
"use strict";
|
|
@@ -20955,25 +21880,25 @@ module.exports.parse = __webpack_require__(34);
|
|
|
20955
21880
|
|
|
20956
21881
|
|
|
20957
21882
|
/***/ }),
|
|
20958
|
-
/*
|
|
21883
|
+
/* 15 */
|
|
20959
21884
|
/***/ (function(module, exports) {
|
|
20960
21885
|
|
|
20961
21886
|
module.exports=/[\0-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/
|
|
20962
21887
|
|
|
20963
21888
|
/***/ }),
|
|
20964
|
-
/*
|
|
21889
|
+
/* 16 */
|
|
20965
21890
|
/***/ (function(module, exports) {
|
|
20966
21891
|
|
|
20967
21892
|
module.exports=/[\0-\x1F\x7F-\x9F]/
|
|
20968
21893
|
|
|
20969
21894
|
/***/ }),
|
|
20970
|
-
/*
|
|
21895
|
+
/* 17 */
|
|
20971
21896
|
/***/ (function(module, exports) {
|
|
20972
21897
|
|
|
20973
21898
|
module.exports=/[ \xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000]/
|
|
20974
21899
|
|
|
20975
21900
|
/***/ }),
|
|
20976
|
-
/*
|
|
21901
|
+
/* 18 */
|
|
20977
21902
|
/***/ (function(module, exports, __webpack_require__) {
|
|
20978
21903
|
|
|
20979
21904
|
"use strict";
|
|
@@ -21008,7 +21933,7 @@ module.exports.HTML_OPEN_CLOSE_TAG_RE = HTML_OPEN_CLOSE_TAG_RE;
|
|
|
21008
21933
|
|
|
21009
21934
|
|
|
21010
21935
|
/***/ }),
|
|
21011
|
-
/*
|
|
21936
|
+
/* 19 */
|
|
21012
21937
|
/***/ (function(module, exports, __webpack_require__) {
|
|
21013
21938
|
|
|
21014
21939
|
"use strict";
|
|
@@ -21145,7 +22070,7 @@ module.exports.postProcess = function strikethrough(state) {
|
|
|
21145
22070
|
|
|
21146
22071
|
|
|
21147
22072
|
/***/ }),
|
|
21148
|
-
/*
|
|
22073
|
+
/* 20 */
|
|
21149
22074
|
/***/ (function(module, exports, __webpack_require__) {
|
|
21150
22075
|
|
|
21151
22076
|
"use strict";
|
|
@@ -21282,10 +22207,10 @@ module.exports.postProcess = function emphasis(state) {
|
|
|
21282
22207
|
|
|
21283
22208
|
|
|
21284
22209
|
/***/ }),
|
|
21285
|
-
/*
|
|
22210
|
+
/* 21 */
|
|
21286
22211
|
/***/ (function(module, exports, __webpack_require__) {
|
|
21287
22212
|
|
|
21288
|
-
/*! @license DOMPurify 3.2.
|
|
22213
|
+
/*! @license DOMPurify 3.2.5 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.2.5/LICENSE */
|
|
21289
22214
|
|
|
21290
22215
|
(function (global, factory) {
|
|
21291
22216
|
true ? module.exports = factory() :
|
|
@@ -21494,7 +22419,7 @@ module.exports.postProcess = function emphasis(state) {
|
|
|
21494
22419
|
const TMPLIT_EXPR = seal(/\$\{[\w\W]*/gm); // eslint-disable-line unicorn/better-regex
|
|
21495
22420
|
const DATA_ATTR = seal(/^data-[\-\w.\u00B7-\uFFFF]+$/); // eslint-disable-line no-useless-escape
|
|
21496
22421
|
const ARIA_ATTR = seal(/^aria-[\-\w]+$/); // eslint-disable-line no-useless-escape
|
|
21497
|
-
const IS_ALLOWED_URI = seal(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp
|
|
22422
|
+
const IS_ALLOWED_URI = seal(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i // eslint-disable-line no-useless-escape
|
|
21498
22423
|
);
|
|
21499
22424
|
const IS_SCRIPT_OR_DATA = seal(/^(?:\w+script|data):/i);
|
|
21500
22425
|
const ATTR_WHITESPACE = seal(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g // eslint-disable-line no-control-regex
|
|
@@ -21591,7 +22516,7 @@ module.exports.postProcess = function emphasis(state) {
|
|
|
21591
22516
|
function createDOMPurify() {
|
|
21592
22517
|
let window = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : getGlobal();
|
|
21593
22518
|
const DOMPurify = root => createDOMPurify(root);
|
|
21594
|
-
DOMPurify.version = '3.2.
|
|
22519
|
+
DOMPurify.version = '3.2.5';
|
|
21595
22520
|
DOMPurify.removed = [];
|
|
21596
22521
|
if (!window || !window.document || window.document.nodeType !== NODE_TYPE.document || !window.Element) {
|
|
21597
22522
|
// Not running in a browser, provide a factory function
|
|
@@ -21830,8 +22755,8 @@ module.exports.postProcess = function emphasis(state) {
|
|
|
21830
22755
|
URI_SAFE_ATTRIBUTES = objectHasOwnProperty(cfg, 'ADD_URI_SAFE_ATTR') ? addToSet(clone(DEFAULT_URI_SAFE_ATTRIBUTES), cfg.ADD_URI_SAFE_ATTR, transformCaseFunc) : DEFAULT_URI_SAFE_ATTRIBUTES;
|
|
21831
22756
|
DATA_URI_TAGS = objectHasOwnProperty(cfg, 'ADD_DATA_URI_TAGS') ? addToSet(clone(DEFAULT_DATA_URI_TAGS), cfg.ADD_DATA_URI_TAGS, transformCaseFunc) : DEFAULT_DATA_URI_TAGS;
|
|
21832
22757
|
FORBID_CONTENTS = objectHasOwnProperty(cfg, 'FORBID_CONTENTS') ? addToSet({}, cfg.FORBID_CONTENTS, transformCaseFunc) : DEFAULT_FORBID_CONTENTS;
|
|
21833
|
-
FORBID_TAGS = objectHasOwnProperty(cfg, 'FORBID_TAGS') ? addToSet({}, cfg.FORBID_TAGS, transformCaseFunc) :
|
|
21834
|
-
FORBID_ATTR = objectHasOwnProperty(cfg, 'FORBID_ATTR') ? addToSet({}, cfg.FORBID_ATTR, transformCaseFunc) :
|
|
22758
|
+
FORBID_TAGS = objectHasOwnProperty(cfg, 'FORBID_TAGS') ? addToSet({}, cfg.FORBID_TAGS, transformCaseFunc) : {};
|
|
22759
|
+
FORBID_ATTR = objectHasOwnProperty(cfg, 'FORBID_ATTR') ? addToSet({}, cfg.FORBID_ATTR, transformCaseFunc) : {};
|
|
21835
22760
|
USE_PROFILES = objectHasOwnProperty(cfg, 'USE_PROFILES') ? cfg.USE_PROFILES : false;
|
|
21836
22761
|
ALLOW_ARIA_ATTR = cfg.ALLOW_ARIA_ATTR !== false; // Default true
|
|
21837
22762
|
ALLOW_DATA_ATTR = cfg.ALLOW_DATA_ATTR !== false; // Default true
|
|
@@ -22196,7 +23121,7 @@ module.exports.postProcess = function emphasis(state) {
|
|
|
22196
23121
|
allowedTags: ALLOWED_TAGS
|
|
22197
23122
|
});
|
|
22198
23123
|
/* Detect mXSS attempts abusing namespace confusion */
|
|
22199
|
-
if (
|
|
23124
|
+
if (currentNode.hasChildNodes() && !_isNode(currentNode.firstElementChild) && regExpTest(/<[/\w!]/g, currentNode.innerHTML) && regExpTest(/<[/\w!]/g, currentNode.textContent)) {
|
|
22200
23125
|
_forceRemove(currentNode);
|
|
22201
23126
|
return true;
|
|
22202
23127
|
}
|
|
@@ -22348,8 +23273,7 @@ module.exports.postProcess = function emphasis(state) {
|
|
|
22348
23273
|
value: attrValue
|
|
22349
23274
|
} = attr;
|
|
22350
23275
|
const lcName = transformCaseFunc(name);
|
|
22351
|
-
|
|
22352
|
-
let value = name === 'value' ? initValue : stringTrim(initValue);
|
|
23276
|
+
let value = name === 'value' ? attrValue : stringTrim(attrValue);
|
|
22353
23277
|
/* Execute a hook if present */
|
|
22354
23278
|
hookEvent.attrName = lcName;
|
|
22355
23279
|
hookEvent.attrValue = value;
|
|
@@ -22375,9 +23299,10 @@ module.exports.postProcess = function emphasis(state) {
|
|
|
22375
23299
|
if (hookEvent.forceKeepAttr) {
|
|
22376
23300
|
continue;
|
|
22377
23301
|
}
|
|
23302
|
+
/* Remove attribute */
|
|
23303
|
+
_removeAttribute(name, currentNode);
|
|
22378
23304
|
/* Did the hooks approve of the attribute? */
|
|
22379
23305
|
if (!hookEvent.keepAttr) {
|
|
22380
|
-
_removeAttribute(name, currentNode);
|
|
22381
23306
|
continue;
|
|
22382
23307
|
}
|
|
22383
23308
|
/* Work around a security issue in jQuery 3.0 */
|
|
@@ -22394,7 +23319,6 @@ module.exports.postProcess = function emphasis(state) {
|
|
|
22394
23319
|
/* Is `value` valid for this attribute? */
|
|
22395
23320
|
const lcTag = transformCaseFunc(currentNode.nodeName);
|
|
22396
23321
|
if (!_isValidAttribute(lcTag, lcName, value)) {
|
|
22397
|
-
_removeAttribute(name, currentNode);
|
|
22398
23322
|
continue;
|
|
22399
23323
|
}
|
|
22400
23324
|
/* Handle attributes that require Trusted Types */
|
|
@@ -22415,1210 +23339,281 @@ module.exports.postProcess = function emphasis(state) {
|
|
|
22415
23339
|
}
|
|
22416
23340
|
}
|
|
22417
23341
|
/* Handle invalid data-* attribute set by try-catching it */
|
|
22418
|
-
|
|
22419
|
-
|
|
22420
|
-
|
|
22421
|
-
|
|
22422
|
-
|
|
22423
|
-
|
|
22424
|
-
currentNode.setAttribute(name, value);
|
|
22425
|
-
}
|
|
22426
|
-
if (_isClobbered(currentNode)) {
|
|
22427
|
-
_forceRemove(currentNode);
|
|
22428
|
-
} else {
|
|
22429
|
-
arrayPop(DOMPurify.removed);
|
|
22430
|
-
}
|
|
22431
|
-
} catch (_) {
|
|
22432
|
-
_removeAttribute(name, currentNode);
|
|
22433
|
-
}
|
|
22434
|
-
}
|
|
22435
|
-
}
|
|
22436
|
-
/* Execute a hook if present */
|
|
22437
|
-
_executeHooks(hooks.afterSanitizeAttributes, currentNode, null);
|
|
22438
|
-
};
|
|
22439
|
-
/**
|
|
22440
|
-
* _sanitizeShadowDOM
|
|
22441
|
-
*
|
|
22442
|
-
* @param fragment to iterate over recursively
|
|
22443
|
-
*/
|
|
22444
|
-
const _sanitizeShadowDOM = function _sanitizeShadowDOM(fragment) {
|
|
22445
|
-
let shadowNode = null;
|
|
22446
|
-
const shadowIterator = _createNodeIterator(fragment);
|
|
22447
|
-
/* Execute a hook if present */
|
|
22448
|
-
_executeHooks(hooks.beforeSanitizeShadowDOM, fragment, null);
|
|
22449
|
-
while (shadowNode = shadowIterator.nextNode()) {
|
|
22450
|
-
/* Execute a hook if present */
|
|
22451
|
-
_executeHooks(hooks.uponSanitizeShadowNode, shadowNode, null);
|
|
22452
|
-
/* Sanitize tags and elements */
|
|
22453
|
-
_sanitizeElements(shadowNode);
|
|
22454
|
-
/* Check attributes next */
|
|
22455
|
-
_sanitizeAttributes(shadowNode);
|
|
22456
|
-
/* Deep shadow DOM detected */
|
|
22457
|
-
if (shadowNode.content instanceof DocumentFragment) {
|
|
22458
|
-
_sanitizeShadowDOM(shadowNode.content);
|
|
22459
|
-
}
|
|
22460
|
-
}
|
|
22461
|
-
/* Execute a hook if present */
|
|
22462
|
-
_executeHooks(hooks.afterSanitizeShadowDOM, fragment, null);
|
|
22463
|
-
};
|
|
22464
|
-
// eslint-disable-next-line complexity
|
|
22465
|
-
DOMPurify.sanitize = function (dirty) {
|
|
22466
|
-
let cfg = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
22467
|
-
let body = null;
|
|
22468
|
-
let importedNode = null;
|
|
22469
|
-
let currentNode = null;
|
|
22470
|
-
let returnNode = null;
|
|
22471
|
-
/* Make sure we have a string to sanitize.
|
|
22472
|
-
DO NOT return early, as this will return the wrong type if
|
|
22473
|
-
the user has requested a DOM object rather than a string */
|
|
22474
|
-
IS_EMPTY_INPUT = !dirty;
|
|
22475
|
-
if (IS_EMPTY_INPUT) {
|
|
22476
|
-
dirty = '<!-->';
|
|
22477
|
-
}
|
|
22478
|
-
/* Stringify, in case dirty is an object */
|
|
22479
|
-
if (typeof dirty !== 'string' && !_isNode(dirty)) {
|
|
22480
|
-
if (typeof dirty.toString === 'function') {
|
|
22481
|
-
dirty = dirty.toString();
|
|
22482
|
-
if (typeof dirty !== 'string') {
|
|
22483
|
-
throw typeErrorCreate('dirty is not a string, aborting');
|
|
22484
|
-
}
|
|
22485
|
-
} else {
|
|
22486
|
-
throw typeErrorCreate('toString is not a function');
|
|
22487
|
-
}
|
|
22488
|
-
}
|
|
22489
|
-
/* Return dirty HTML if DOMPurify cannot run */
|
|
22490
|
-
if (!DOMPurify.isSupported) {
|
|
22491
|
-
return dirty;
|
|
22492
|
-
}
|
|
22493
|
-
/* Assign config vars */
|
|
22494
|
-
if (!SET_CONFIG) {
|
|
22495
|
-
_parseConfig(cfg);
|
|
22496
|
-
}
|
|
22497
|
-
/* Clean up removed elements */
|
|
22498
|
-
DOMPurify.removed = [];
|
|
22499
|
-
/* Check if dirty is correctly typed for IN_PLACE */
|
|
22500
|
-
if (typeof dirty === 'string') {
|
|
22501
|
-
IN_PLACE = false;
|
|
22502
|
-
}
|
|
22503
|
-
if (IN_PLACE) {
|
|
22504
|
-
/* Do some early pre-sanitization to avoid unsafe root nodes */
|
|
22505
|
-
if (dirty.nodeName) {
|
|
22506
|
-
const tagName = transformCaseFunc(dirty.nodeName);
|
|
22507
|
-
if (!ALLOWED_TAGS[tagName] || FORBID_TAGS[tagName]) {
|
|
22508
|
-
throw typeErrorCreate('root node is forbidden and cannot be sanitized in-place');
|
|
22509
|
-
}
|
|
22510
|
-
}
|
|
22511
|
-
} else if (dirty instanceof Node) {
|
|
22512
|
-
/* If dirty is a DOM element, append to an empty document to avoid
|
|
22513
|
-
elements being stripped by the parser */
|
|
22514
|
-
body = _initDocument('<!---->');
|
|
22515
|
-
importedNode = body.ownerDocument.importNode(dirty, true);
|
|
22516
|
-
if (importedNode.nodeType === NODE_TYPE.element && importedNode.nodeName === 'BODY') {
|
|
22517
|
-
/* Node is already a body, use as is */
|
|
22518
|
-
body = importedNode;
|
|
22519
|
-
} else if (importedNode.nodeName === 'HTML') {
|
|
22520
|
-
body = importedNode;
|
|
22521
|
-
} else {
|
|
22522
|
-
// eslint-disable-next-line unicorn/prefer-dom-node-append
|
|
22523
|
-
body.appendChild(importedNode);
|
|
22524
|
-
}
|
|
22525
|
-
} else {
|
|
22526
|
-
/* Exit directly if we have nothing to do */
|
|
22527
|
-
if (!RETURN_DOM && !SAFE_FOR_TEMPLATES && !WHOLE_DOCUMENT &&
|
|
22528
|
-
// eslint-disable-next-line unicorn/prefer-includes
|
|
22529
|
-
dirty.indexOf('<') === -1) {
|
|
22530
|
-
return trustedTypesPolicy && RETURN_TRUSTED_TYPE ? trustedTypesPolicy.createHTML(dirty) : dirty;
|
|
22531
|
-
}
|
|
22532
|
-
/* Initialize the document to work on */
|
|
22533
|
-
body = _initDocument(dirty);
|
|
22534
|
-
/* Check we have a DOM node from the data */
|
|
22535
|
-
if (!body) {
|
|
22536
|
-
return RETURN_DOM ? null : RETURN_TRUSTED_TYPE ? emptyHTML : '';
|
|
22537
|
-
}
|
|
22538
|
-
}
|
|
22539
|
-
/* Remove first element node (ours) if FORCE_BODY is set */
|
|
22540
|
-
if (body && FORCE_BODY) {
|
|
22541
|
-
_forceRemove(body.firstChild);
|
|
22542
|
-
}
|
|
22543
|
-
/* Get node iterator */
|
|
22544
|
-
const nodeIterator = _createNodeIterator(IN_PLACE ? dirty : body);
|
|
22545
|
-
/* Now start iterating over the created document */
|
|
22546
|
-
while (currentNode = nodeIterator.nextNode()) {
|
|
22547
|
-
/* Sanitize tags and elements */
|
|
22548
|
-
_sanitizeElements(currentNode);
|
|
22549
|
-
/* Check attributes next */
|
|
22550
|
-
_sanitizeAttributes(currentNode);
|
|
22551
|
-
/* Shadow DOM detected, sanitize it */
|
|
22552
|
-
if (currentNode.content instanceof DocumentFragment) {
|
|
22553
|
-
_sanitizeShadowDOM(currentNode.content);
|
|
22554
|
-
}
|
|
22555
|
-
}
|
|
22556
|
-
/* If we sanitized `dirty` in-place, return it. */
|
|
22557
|
-
if (IN_PLACE) {
|
|
22558
|
-
return dirty;
|
|
22559
|
-
}
|
|
22560
|
-
/* Return sanitized string or DOM */
|
|
22561
|
-
if (RETURN_DOM) {
|
|
22562
|
-
if (RETURN_DOM_FRAGMENT) {
|
|
22563
|
-
returnNode = createDocumentFragment.call(body.ownerDocument);
|
|
22564
|
-
while (body.firstChild) {
|
|
22565
|
-
// eslint-disable-next-line unicorn/prefer-dom-node-append
|
|
22566
|
-
returnNode.appendChild(body.firstChild);
|
|
22567
|
-
}
|
|
22568
|
-
} else {
|
|
22569
|
-
returnNode = body;
|
|
22570
|
-
}
|
|
22571
|
-
if (ALLOWED_ATTR.shadowroot || ALLOWED_ATTR.shadowrootmode) {
|
|
22572
|
-
/*
|
|
22573
|
-
AdoptNode() is not used because internal state is not reset
|
|
22574
|
-
(e.g. the past names map of a HTMLFormElement), this is safe
|
|
22575
|
-
in theory but we would rather not risk another attack vector.
|
|
22576
|
-
The state that is cloned by importNode() is explicitly defined
|
|
22577
|
-
by the specs.
|
|
22578
|
-
*/
|
|
22579
|
-
returnNode = importNode.call(originalDocument, returnNode, true);
|
|
22580
|
-
}
|
|
22581
|
-
return returnNode;
|
|
22582
|
-
}
|
|
22583
|
-
let serializedHTML = WHOLE_DOCUMENT ? body.outerHTML : body.innerHTML;
|
|
22584
|
-
/* Serialize doctype if allowed */
|
|
22585
|
-
if (WHOLE_DOCUMENT && ALLOWED_TAGS['!doctype'] && body.ownerDocument && body.ownerDocument.doctype && body.ownerDocument.doctype.name && regExpTest(DOCTYPE_NAME, body.ownerDocument.doctype.name)) {
|
|
22586
|
-
serializedHTML = '<!DOCTYPE ' + body.ownerDocument.doctype.name + '>\n' + serializedHTML;
|
|
22587
|
-
}
|
|
22588
|
-
/* Sanitize final string template-safe */
|
|
22589
|
-
if (SAFE_FOR_TEMPLATES) {
|
|
22590
|
-
arrayForEach([MUSTACHE_EXPR, ERB_EXPR, TMPLIT_EXPR], expr => {
|
|
22591
|
-
serializedHTML = stringReplace(serializedHTML, expr, ' ');
|
|
22592
|
-
});
|
|
22593
|
-
}
|
|
22594
|
-
return trustedTypesPolicy && RETURN_TRUSTED_TYPE ? trustedTypesPolicy.createHTML(serializedHTML) : serializedHTML;
|
|
22595
|
-
};
|
|
22596
|
-
DOMPurify.setConfig = function () {
|
|
22597
|
-
let cfg = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
22598
|
-
_parseConfig(cfg);
|
|
22599
|
-
SET_CONFIG = true;
|
|
22600
|
-
};
|
|
22601
|
-
DOMPurify.clearConfig = function () {
|
|
22602
|
-
CONFIG = null;
|
|
22603
|
-
SET_CONFIG = false;
|
|
22604
|
-
};
|
|
22605
|
-
DOMPurify.isValidAttribute = function (tag, attr, value) {
|
|
22606
|
-
/* Initialize shared config vars if necessary. */
|
|
22607
|
-
if (!CONFIG) {
|
|
22608
|
-
_parseConfig({});
|
|
22609
|
-
}
|
|
22610
|
-
const lcTag = transformCaseFunc(tag);
|
|
22611
|
-
const lcName = transformCaseFunc(attr);
|
|
22612
|
-
return _isValidAttribute(lcTag, lcName, value);
|
|
22613
|
-
};
|
|
22614
|
-
DOMPurify.addHook = function (entryPoint, hookFunction) {
|
|
22615
|
-
if (typeof hookFunction !== 'function') {
|
|
22616
|
-
return;
|
|
22617
|
-
}
|
|
22618
|
-
arrayPush(hooks[entryPoint], hookFunction);
|
|
22619
|
-
};
|
|
22620
|
-
DOMPurify.removeHook = function (entryPoint, hookFunction) {
|
|
22621
|
-
if (hookFunction !== undefined) {
|
|
22622
|
-
const index = arrayLastIndexOf(hooks[entryPoint], hookFunction);
|
|
22623
|
-
return index === -1 ? undefined : arraySplice(hooks[entryPoint], index, 1)[0];
|
|
22624
|
-
}
|
|
22625
|
-
return arrayPop(hooks[entryPoint]);
|
|
22626
|
-
};
|
|
22627
|
-
DOMPurify.removeHooks = function (entryPoint) {
|
|
22628
|
-
hooks[entryPoint] = [];
|
|
22629
|
-
};
|
|
22630
|
-
DOMPurify.removeAllHooks = function () {
|
|
22631
|
-
hooks = _createHooksMap();
|
|
22632
|
-
};
|
|
22633
|
-
return DOMPurify;
|
|
22634
|
-
}
|
|
22635
|
-
var purify = createDOMPurify();
|
|
22636
|
-
|
|
22637
|
-
return purify;
|
|
22638
|
-
|
|
22639
|
-
}));
|
|
22640
|
-
//# sourceMappingURL=purify.js.map
|
|
22641
|
-
|
|
22642
|
-
|
|
22643
|
-
/***/ }),
|
|
22644
|
-
/* 21 */
|
|
22645
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
22646
|
-
|
|
22647
|
-
"use strict";
|
|
22648
|
-
|
|
22649
|
-
|
|
22650
|
-
|
|
22651
|
-
module.exports = __webpack_require__(29);
|
|
22652
|
-
|
|
22653
|
-
|
|
22654
|
-
/***/ }),
|
|
22655
|
-
/* 22 */
|
|
22656
|
-
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
22657
|
-
|
|
22658
|
-
"use strict";
|
|
22659
|
-
/* harmony import */ var _css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2);
|
|
22660
|
-
/* harmony import */ var _css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
22661
|
-
// Imports
|
|
22662
|
-
|
|
22663
|
-
var ___CSS_LOADER_EXPORT___ = _css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(function(i){return i[1]});
|
|
22664
|
-
// Module
|
|
22665
|
-
___CSS_LOADER_EXPORT___.push([module.i, "/**\n * prism.js default theme for JavaScript, CSS and HTML\n * Based on dabblet (http://dabblet.com)\n * @author Lea Verou\n */\n\ncode[class*=\"language-\"],\npre[class*=\"language-\"] {\n\tcolor: black;\n\tbackground: none;\n\ttext-shadow: 0 1px white;\n\tfont-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace;\n\tfont-size: 1em;\n\ttext-align: left;\n\twhite-space: pre;\n\tword-spacing: normal;\n\tword-break: normal;\n\tword-wrap: normal;\n\tline-height: 1.5;\n\n\t-moz-tab-size: 4;\n\t-o-tab-size: 4;\n\ttab-size: 4;\n\n\t-webkit-hyphens: none;\n\t-moz-hyphens: none;\n\t-ms-hyphens: none;\n\thyphens: none;\n}\n\npre[class*=\"language-\"]::-moz-selection, pre[class*=\"language-\"] ::-moz-selection,\ncode[class*=\"language-\"]::-moz-selection, code[class*=\"language-\"] ::-moz-selection {\n\ttext-shadow: none;\n\tbackground: #b3d4fc;\n}\n\npre[class*=\"language-\"]::selection, pre[class*=\"language-\"] ::selection,\ncode[class*=\"language-\"]::selection, code[class*=\"language-\"] ::selection {\n\ttext-shadow: none;\n\tbackground: #b3d4fc;\n}\n\n@media print {\n\tcode[class*=\"language-\"],\n\tpre[class*=\"language-\"] {\n\t\ttext-shadow: none;\n\t}\n}\n\n/* Code blocks */\npre[class*=\"language-\"] {\n\tpadding: 1em;\n\tmargin: .5em 0;\n\toverflow: auto;\n}\n\n:not(pre) > code[class*=\"language-\"],\npre[class*=\"language-\"] {\n\tbackground: #f5f2f0;\n}\n\n/* Inline code */\n:not(pre) > code[class*=\"language-\"] {\n\tpadding: .1em;\n\tborder-radius: .3em;\n\twhite-space: normal;\n}\n\n.token.comment,\n.token.prolog,\n.token.doctype,\n.token.cdata {\n\tcolor: slategray;\n}\n\n.token.punctuation {\n\tcolor: #999;\n}\n\n.token.namespace {\n\topacity: .7;\n}\n\n.token.property,\n.token.tag,\n.token.boolean,\n.token.number,\n.token.constant,\n.token.symbol,\n.token.deleted {\n\tcolor: #905;\n}\n\n.token.selector,\n.token.attr-name,\n.token.string,\n.token.char,\n.token.builtin,\n.token.inserted {\n\tcolor: #690;\n}\n\n.token.operator,\n.token.entity,\n.token.url,\n.language-css .token.string,\n.style .token.string {\n\tcolor: #9a6e3a;\n\t/* This background color was intended by the author of this theme. */\n\tbackground: hsla(0, 0%, 100%, .5);\n}\n\n.token.atrule,\n.token.attr-value,\n.token.keyword {\n\tcolor: #07a;\n}\n\n.token.function,\n.token.class-name {\n\tcolor: #DD4A68;\n}\n\n.token.regex,\n.token.important,\n.token.variable {\n\tcolor: #e90;\n}\n\n.token.important,\n.token.bold {\n\tfont-weight: bold;\n}\n.token.italic {\n\tfont-style: italic;\n}\n\n.token.entity {\n\tcursor: help;\n}\n", ""]);
|
|
22666
|
-
// Exports
|
|
22667
|
-
/* harmony default export */ __webpack_exports__["a"] = (___CSS_LOADER_EXPORT___);
|
|
22668
|
-
|
|
22669
|
-
|
|
22670
|
-
/***/ }),
|
|
22671
|
-
/* 23 */
|
|
22672
|
-
/***/ (function(module, exports) {
|
|
22673
|
-
|
|
22674
|
-
module.exports = function(module) {
|
|
22675
|
-
if (!module.webpackPolyfill) {
|
|
22676
|
-
module.deprecate = function() {};
|
|
22677
|
-
module.paths = [];
|
|
22678
|
-
// module.parent = undefined by default
|
|
22679
|
-
if (!module.children) module.children = [];
|
|
22680
|
-
Object.defineProperty(module, "loaded", {
|
|
22681
|
-
enumerable: true,
|
|
22682
|
-
get: function() {
|
|
22683
|
-
return module.l;
|
|
22684
|
-
}
|
|
22685
|
-
});
|
|
22686
|
-
Object.defineProperty(module, "id", {
|
|
22687
|
-
enumerable: true,
|
|
22688
|
-
get: function() {
|
|
22689
|
-
return module.i;
|
|
22690
|
-
}
|
|
22691
|
-
});
|
|
22692
|
-
module.webpackPolyfill = 1;
|
|
22693
|
-
}
|
|
22694
|
-
return module;
|
|
22695
|
-
};
|
|
22696
|
-
|
|
22697
|
-
|
|
22698
|
-
/***/ }),
|
|
22699
|
-
/* 24 */
|
|
22700
|
-
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
22701
|
-
|
|
22702
|
-
"use strict";
|
|
22703
|
-
// ESM COMPAT FLAG
|
|
22704
|
-
__webpack_require__.r(__webpack_exports__);
|
|
22705
|
-
|
|
22706
|
-
// EXPORTS
|
|
22707
|
-
__webpack_require__.d(__webpack_exports__, "createSendUtils", function() { return /* reexport */ createSendUtils; });
|
|
22708
|
-
__webpack_require__.d(__webpack_exports__, "createStreamUtils", function() { return /* reexport */ createStreamUtils; });
|
|
22709
|
-
__webpack_require__.d(__webpack_exports__, "DEFAULT_KV_SEPARATOR", function() { return /* reexport */ DEFAULT_KV_SEPARATOR; });
|
|
22710
|
-
__webpack_require__.d(__webpack_exports__, "DEFAULT_PART_SEPARATOR", function() { return /* reexport */ DEFAULT_PART_SEPARATOR; });
|
|
22711
|
-
__webpack_require__.d(__webpack_exports__, "DEFAULT_STREAM_SEPARATOR", function() { return /* reexport */ DEFAULT_STREAM_SEPARATOR; });
|
|
22712
|
-
__webpack_require__.d(__webpack_exports__, "isValidString", function() { return /* reexport */ isValidString; });
|
|
22713
|
-
__webpack_require__.d(__webpack_exports__, "recordMixin", function() { return /* reexport */ recordMixin; });
|
|
22714
|
-
__webpack_require__.d(__webpack_exports__, "sendMixin", function() { return /* reexport */ sendMixin; });
|
|
22715
|
-
__webpack_require__.d(__webpack_exports__, "splitPart", function() { return /* reexport */ splitPart; });
|
|
22716
|
-
__webpack_require__.d(__webpack_exports__, "splitStream", function() { return /* reexport */ splitStream; });
|
|
22717
|
-
__webpack_require__.d(__webpack_exports__, "streamMixin", function() { return /* reexport */ streamMixin; });
|
|
22718
|
-
__webpack_require__.d(__webpack_exports__, "XRequest", function() { return /* reexport */ XRequest; });
|
|
22719
|
-
__webpack_require__.d(__webpack_exports__, "XStream", function() { return /* reexport */ XStream; });
|
|
22720
|
-
|
|
22721
|
-
// CONCATENATED MODULE: ./src/mixins/recordMixin.js
|
|
22722
|
-
/**
|
|
22723
|
-
* @description 提供语音识别的混入,允许语音输入并处理开始、结束、结果及错误等各种事件。
|
|
22724
|
-
*
|
|
22725
|
-
* @mixin recordMixin
|
|
22726
|
-
*/
|
|
22727
|
-
|
|
22728
|
-
/* harmony default export */ var recordMixin = ({
|
|
22729
|
-
data() {
|
|
22730
|
-
return {
|
|
22731
|
-
// 语音识别状态
|
|
22732
|
-
recordLoading: false,
|
|
22733
|
-
// 识别结果
|
|
22734
|
-
recordValue: '',
|
|
22735
|
-
// 识别实例
|
|
22736
|
-
recordRecognition: null,
|
|
22737
|
-
// 配置选项
|
|
22738
|
-
recordOptions: {
|
|
22739
|
-
onError: null,
|
|
22740
|
-
onStart: null,
|
|
22741
|
-
onEnd: null,
|
|
22742
|
-
onResult: null
|
|
22743
|
-
}
|
|
22744
|
-
};
|
|
22745
|
-
},
|
|
22746
|
-
methods: {
|
|
22747
|
-
/**
|
|
22748
|
-
* 初始化语音识别配置
|
|
22749
|
-
* @param {Object} options - 配置选项
|
|
22750
|
-
* @param {Function} [options.onError] - 错误回调
|
|
22751
|
-
* @param {Function} [options.onStart] - 开始回调
|
|
22752
|
-
* @param {Function} [options.onEnd] - 结束回调
|
|
22753
|
-
* @param {Function} [options.onResult] - 结果回调
|
|
22754
|
-
*/
|
|
22755
|
-
initRecord(options = {}) {
|
|
22756
|
-
this.recordOptions = {
|
|
22757
|
-
...this.recordOptions,
|
|
22758
|
-
...options
|
|
22759
|
-
};
|
|
22760
|
-
},
|
|
22761
|
-
/**
|
|
22762
|
-
* 开始语音识别
|
|
22763
|
-
*/
|
|
22764
|
-
startRecord() {
|
|
22765
|
-
if ('webkitSpeechRecognition' in window) {
|
|
22766
|
-
this.recordRecognition = new window.webkitSpeechRecognition();
|
|
22767
|
-
this.recordRecognition.continuous = true;
|
|
22768
|
-
this.recordRecognition.interimResults = true;
|
|
22769
|
-
this.recordRecognition.lang = 'zh-CN';
|
|
22770
|
-
this.recordRecognition.onstart = () => {
|
|
22771
|
-
this.recordLoading = true;
|
|
22772
|
-
this.recordValue = '';
|
|
22773
|
-
if (this.recordOptions.onStart) {
|
|
22774
|
-
this.recordOptions.onStart();
|
|
22775
|
-
}
|
|
22776
|
-
};
|
|
22777
|
-
this.recordRecognition.onend = () => {
|
|
22778
|
-
this.recordLoading = false;
|
|
22779
|
-
if (this.recordOptions.onEnd) {
|
|
22780
|
-
this.recordOptions.onEnd(this.recordValue);
|
|
22781
|
-
}
|
|
22782
|
-
};
|
|
22783
|
-
this.recordRecognition.onerror = e => {
|
|
22784
|
-
this.recordLoading = false;
|
|
22785
|
-
if (this.recordOptions.onError) {
|
|
22786
|
-
this.recordOptions.onError(e);
|
|
22787
|
-
}
|
|
22788
|
-
};
|
|
22789
|
-
this.recordRecognition.onresult = e => {
|
|
22790
|
-
let results = '';
|
|
22791
|
-
for (let i = 0; i <= e.resultIndex; i++) {
|
|
22792
|
-
results += e.results[i][0].transcript;
|
|
22793
|
-
}
|
|
22794
|
-
this.recordValue = results;
|
|
22795
|
-
if (this.recordOptions.onResult) {
|
|
22796
|
-
this.recordOptions.onResult(results);
|
|
22797
|
-
}
|
|
22798
|
-
};
|
|
22799
|
-
this.recordRecognition.start();
|
|
22800
|
-
} else {
|
|
22801
|
-
const error = {
|
|
22802
|
-
code: -1,
|
|
22803
|
-
message: 'The current browser does not support voice recognition'
|
|
22804
|
-
};
|
|
22805
|
-
if (this.recordOptions.onError) {
|
|
22806
|
-
this.recordOptions.onError(error);
|
|
22807
|
-
}
|
|
22808
|
-
}
|
|
22809
|
-
},
|
|
22810
|
-
/**
|
|
22811
|
-
* 停止语音识别
|
|
22812
|
-
*/
|
|
22813
|
-
stopRecord() {
|
|
22814
|
-
if (this.recordRecognition) {
|
|
22815
|
-
this.recordRecognition.stop();
|
|
22816
|
-
}
|
|
22817
|
-
},
|
|
22818
|
-
/**
|
|
22819
|
-
* 清理语音识别资源
|
|
22820
|
-
*/
|
|
22821
|
-
cleanupRecord() {
|
|
22822
|
-
this.stopRecord();
|
|
22823
|
-
this.recordRecognition = null;
|
|
22824
|
-
}
|
|
22825
|
-
},
|
|
22826
|
-
beforeDestroy() {
|
|
22827
|
-
this.cleanupRecord();
|
|
22828
|
-
}
|
|
22829
|
-
});
|
|
22830
|
-
// CONCATENATED MODULE: ./src/mixins/sendMixin.js
|
|
22831
|
-
/**
|
|
22832
|
-
* XRequest 类 - 用于处理 SSE 和 Fetch 请求
|
|
22833
|
-
*/
|
|
22834
|
-
class XRequest {
|
|
22835
|
-
constructor(options = {}) {
|
|
22836
|
-
const {
|
|
22837
|
-
baseURL,
|
|
22838
|
-
onAbort,
|
|
22839
|
-
onMessage,
|
|
22840
|
-
onError,
|
|
22841
|
-
baseOptions,
|
|
22842
|
-
transformer,
|
|
22843
|
-
type,
|
|
22844
|
-
onFinish,
|
|
22845
|
-
onOpen
|
|
22846
|
-
} = options;
|
|
22847
|
-
this._instance = null;
|
|
22848
|
-
this._transformer = transformer;
|
|
22849
|
-
this._baseURL = baseURL || '';
|
|
22850
|
-
this._baseOptions = baseOptions || {};
|
|
22851
|
-
this._onAbort = onAbort;
|
|
22852
|
-
this._onMessage = onMessage;
|
|
22853
|
-
this._onError = onError;
|
|
22854
|
-
this._onOpen = onOpen;
|
|
22855
|
-
this._type = type || 'sse';
|
|
22856
|
-
this._controller = null;
|
|
22857
|
-
this._onFinish = onFinish;
|
|
22858
|
-
this._messages = [];
|
|
22859
|
-
// 添加结束标志和超时控制
|
|
22860
|
-
this._isFinished = false;
|
|
22861
|
-
this._finishTimeout = null;
|
|
22862
|
-
|
|
22863
|
-
// 绑定方法上下文
|
|
22864
|
-
this.abort = this.abort.bind(this);
|
|
22865
|
-
this.send = this.send.bind(this);
|
|
22866
|
-
}
|
|
22867
|
-
_sendWithFetch(url, options = {}) {
|
|
22868
|
-
this._controller = new AbortController();
|
|
22869
|
-
const signal = this._controller.signal;
|
|
22870
|
-
const fetchOptions = {
|
|
22871
|
-
...options,
|
|
22872
|
-
signal
|
|
22873
|
-
};
|
|
22874
|
-
return fetch(this._baseURL + url, fetchOptions).then(res => res.body).then(async body => {
|
|
22875
|
-
if (!body) {
|
|
22876
|
-
return Promise.reject(new Error('Response body is null in stream mode'));
|
|
22877
|
-
}
|
|
22878
|
-
const reader = body.getReader();
|
|
22879
|
-
const decoder = new TextDecoder('utf-8');
|
|
22880
|
-
let done = false;
|
|
22881
|
-
while (!done) {
|
|
22882
|
-
const {
|
|
22883
|
-
value,
|
|
22884
|
-
done: streamDone
|
|
22885
|
-
} = await reader.read();
|
|
22886
|
-
done = streamDone;
|
|
22887
|
-
if (streamDone) {
|
|
22888
|
-
this._onFinish && this._onFinish(this._messages);
|
|
22889
|
-
return;
|
|
22890
|
-
}
|
|
22891
|
-
if (value) {
|
|
22892
|
-
const chunk = decoder.decode(value, {
|
|
22893
|
-
stream: true
|
|
22894
|
-
});
|
|
22895
|
-
const chunkUse = chunk.startsWith('data: ') ? chunk.slice(6) : chunk;
|
|
22896
|
-
try {
|
|
22897
|
-
const res = this._transformer ? this._transformer(chunkUse) : chunkUse;
|
|
22898
|
-
this._messages.push(res);
|
|
22899
|
-
this._onMessage && this._onMessage(res);
|
|
22900
|
-
} catch (error) {
|
|
22901
|
-
this._onError && this._onError(error);
|
|
22902
|
-
this._controller && this._controller.abort();
|
|
22903
|
-
return Promise.reject(error);
|
|
22904
|
-
}
|
|
22905
|
-
}
|
|
22906
|
-
}
|
|
22907
|
-
}).catch(err => {
|
|
22908
|
-
if (err.name === 'AbortError') {
|
|
22909
|
-
this._onAbort && this._onAbort(this._messages);
|
|
22910
|
-
return;
|
|
22911
|
-
}
|
|
22912
|
-
this._onError && this._onError(err);
|
|
22913
|
-
this._controller && this._controller.abort();
|
|
22914
|
-
});
|
|
22915
|
-
}
|
|
22916
|
-
_sendWithSSE(url, options = {}) {
|
|
22917
|
-
const es = new EventSource(this._baseURL + url, {
|
|
22918
|
-
...this._baseOptions,
|
|
22919
|
-
...options
|
|
22920
|
-
});
|
|
22921
|
-
es.onmessage = e => {
|
|
22922
|
-
// 检查是否是结束消息
|
|
22923
|
-
if (e.data === '[DONE]' || e.data === 'data: [DONE]') {
|
|
22924
|
-
this._isFinished = true;
|
|
22925
|
-
this._onFinish && this._onFinish(this._messages);
|
|
22926
|
-
this.abort();
|
|
22927
|
-
return;
|
|
22928
|
-
}
|
|
22929
|
-
const res = this._transformer ? this._transformer(e.data) : e;
|
|
22930
|
-
this._messages.push(res);
|
|
22931
|
-
this._onMessage && this._onMessage(res);
|
|
22932
|
-
|
|
22933
|
-
// 重置超时定时器
|
|
22934
|
-
if (this._finishTimeout) {
|
|
22935
|
-
clearTimeout(this._finishTimeout);
|
|
22936
|
-
}
|
|
22937
|
-
|
|
22938
|
-
// 设置超时检测:如果 10 秒内没有新消息,认为连接可能已结束
|
|
22939
|
-
this._finishTimeout = setTimeout(() => {
|
|
22940
|
-
if (!this._isFinished && es.readyState !== EventSource.CONNECTING) {
|
|
22941
|
-
this._isFinished = true;
|
|
22942
|
-
this._onFinish && this._onFinish(this._messages);
|
|
22943
|
-
this.abort();
|
|
22944
|
-
}
|
|
22945
|
-
}, 10000);
|
|
22946
|
-
};
|
|
22947
|
-
es.onopen = () => {
|
|
22948
|
-
this._onOpen && this._onOpen();
|
|
22949
|
-
};
|
|
22950
|
-
es.onerror = ev => {
|
|
22951
|
-
// 清除超时定时器
|
|
22952
|
-
if (this._finishTimeout) {
|
|
22953
|
-
clearTimeout(this._finishTimeout);
|
|
22954
|
-
this._finishTimeout = null;
|
|
22955
|
-
}
|
|
22956
|
-
|
|
22957
|
-
// 如果已经标记为结束,直接返回
|
|
22958
|
-
if (this._isFinished) {
|
|
22959
|
-
return;
|
|
22960
|
-
}
|
|
22961
|
-
|
|
22962
|
-
// 更可靠的结束检测逻辑
|
|
22963
|
-
if (es.readyState === EventSource.CLOSED || this._messages.length > 0 && es.readyState !== EventSource.CONNECTING) {
|
|
22964
|
-
// 有消息且连接状态不是正在连接,很可能是正常结束
|
|
22965
|
-
this._isFinished = true;
|
|
22966
|
-
this._onFinish && this._onFinish(this._messages);
|
|
22967
|
-
} else {
|
|
22968
|
-
// 真正的错误情况
|
|
22969
|
-
this._onError && this._onError(es, ev);
|
|
22970
|
-
}
|
|
22971
|
-
this.abort();
|
|
22972
|
-
};
|
|
22973
|
-
this._instance = es;
|
|
22974
|
-
return es;
|
|
22975
|
-
}
|
|
22976
|
-
send(url, options = {}) {
|
|
22977
|
-
switch (this._type) {
|
|
22978
|
-
case 'fetch':
|
|
22979
|
-
this._sendWithFetch(url, options);
|
|
22980
|
-
break;
|
|
22981
|
-
default:
|
|
22982
|
-
this._sendWithSSE(url, options);
|
|
22983
|
-
}
|
|
22984
|
-
return this;
|
|
22985
|
-
}
|
|
22986
|
-
abort() {
|
|
22987
|
-
// 清除超时定时器
|
|
22988
|
-
if (this._finishTimeout) {
|
|
22989
|
-
clearTimeout(this._finishTimeout);
|
|
22990
|
-
this._finishTimeout = null;
|
|
22991
|
-
}
|
|
22992
|
-
if (this._instance && this._instance.close) {
|
|
22993
|
-
this._instance.close();
|
|
22994
|
-
}
|
|
22995
|
-
this._instance = null;
|
|
22996
|
-
if (this._controller) {
|
|
22997
|
-
this._controller.abort();
|
|
22998
|
-
}
|
|
22999
|
-
this._controller = null;
|
|
23000
|
-
|
|
23001
|
-
// 只有在未正常结束时才调用 onAbort
|
|
23002
|
-
if (!this._isFinished) {
|
|
23003
|
-
this._onAbort && this._onAbort(this._messages);
|
|
23004
|
-
}
|
|
23005
|
-
this._messages = [];
|
|
23006
|
-
this._isFinished = false;
|
|
23007
|
-
}
|
|
23008
|
-
}
|
|
23009
|
-
|
|
23010
|
-
/**
|
|
23011
|
-
* sendMixin -
|
|
23012
|
-
* 用于处理发送操作管理请求状态的 mixin,支持可选的中止功能,同时支持 Promise 和 SSE(服务端事件)
|
|
23013
|
-
*/
|
|
23014
|
-
const sendMixin = {
|
|
23015
|
-
data() {
|
|
23016
|
-
return {
|
|
23017
|
-
loading: false,
|
|
23018
|
-
_sendPromise: null,
|
|
23019
|
-
_sendController: null
|
|
23020
|
-
};
|
|
23021
|
-
},
|
|
23022
|
-
methods: {
|
|
23023
|
-
/**
|
|
23024
|
-
* 初始化发送配置
|
|
23025
|
-
* @param {Object} options - 配置选项
|
|
23026
|
-
* @param {Function} options.onAbort - 中止回调
|
|
23027
|
-
* @param {Function} options.sendHandler - 发送处理器
|
|
23028
|
-
* @param {Function} options.abortHandler - 中止处理器
|
|
23029
|
-
* @param {Function} options.finishHandler - 完成处理器
|
|
23030
|
-
*/
|
|
23031
|
-
initSend(options = {}) {
|
|
23032
|
-
this._sendOptions = {
|
|
23033
|
-
onAbort: options.onAbort,
|
|
23034
|
-
sendHandler: options.sendHandler,
|
|
23035
|
-
abortHandler: options.abortHandler,
|
|
23036
|
-
finishHandler: options.finishHandler
|
|
23037
|
-
};
|
|
23038
|
-
},
|
|
23039
|
-
/**
|
|
23040
|
-
* 发送操作
|
|
23041
|
-
* @param {...any} args - 传递给 sendHandler 的参数
|
|
23042
|
-
*/
|
|
23043
|
-
handleSend(...args) {
|
|
23044
|
-
if (this.loading) {
|
|
23045
|
-
return;
|
|
23046
|
-
}
|
|
23047
|
-
if (this._sendOptions && this._sendOptions.sendHandler) {
|
|
23048
|
-
this._sendOptions.sendHandler(...args);
|
|
23049
|
-
}
|
|
23050
|
-
this.loading = true;
|
|
23051
|
-
},
|
|
23052
|
-
/**
|
|
23053
|
-
* 中止操作
|
|
23054
|
-
*/
|
|
23055
|
-
handleAbort() {
|
|
23056
|
-
this.loading = false;
|
|
23057
|
-
if (this._sendOptions && this._sendOptions.abortHandler) {
|
|
23058
|
-
this._sendOptions.abortHandler();
|
|
23059
|
-
}
|
|
23060
|
-
if (this._sendOptions && this._sendOptions.onAbort) {
|
|
23061
|
-
this._sendOptions.onAbort();
|
|
23062
|
-
}
|
|
23063
|
-
},
|
|
23064
|
-
/**
|
|
23065
|
-
* 完成操作
|
|
23066
|
-
*/
|
|
23067
|
-
handleFinish() {
|
|
23068
|
-
this.loading = false;
|
|
23069
|
-
if (this._sendOptions && this._sendOptions.finishHandler) {
|
|
23070
|
-
this._sendOptions.finishHandler();
|
|
23071
|
-
}
|
|
23072
|
-
},
|
|
23073
|
-
/**
|
|
23074
|
-
* 创建 XRequest 实例的便捷方法
|
|
23075
|
-
* @param {Object} options - XRequest 配置选项
|
|
23076
|
-
* @returns {XRequest} XRequest 实例
|
|
23077
|
-
*/
|
|
23078
|
-
createXRequest(options = {}) {
|
|
23079
|
-
return new XRequest({
|
|
23080
|
-
...options,
|
|
23081
|
-
onAbort: (...args) => {
|
|
23082
|
-
this.handleAbort();
|
|
23083
|
-
if (options.onAbort) {
|
|
23084
|
-
options.onAbort(...args);
|
|
23342
|
+
try {
|
|
23343
|
+
if (namespaceURI) {
|
|
23344
|
+
currentNode.setAttributeNS(namespaceURI, name, value);
|
|
23345
|
+
} else {
|
|
23346
|
+
/* Fallback to setAttribute() for browser-unrecognized namespaces e.g. "x-schema". */
|
|
23347
|
+
currentNode.setAttribute(name, value);
|
|
23085
23348
|
}
|
|
23086
|
-
|
|
23087
|
-
|
|
23088
|
-
|
|
23089
|
-
|
|
23090
|
-
options.onFinish(...args);
|
|
23349
|
+
if (_isClobbered(currentNode)) {
|
|
23350
|
+
_forceRemove(currentNode);
|
|
23351
|
+
} else {
|
|
23352
|
+
arrayPop(DOMPurify.removed);
|
|
23091
23353
|
}
|
|
23092
|
-
}
|
|
23093
|
-
});
|
|
23094
|
-
}
|
|
23095
|
-
},
|
|
23096
|
-
beforeDestroy() {
|
|
23097
|
-
// 组件销毁时清理资源
|
|
23098
|
-
if (this._sendController) {
|
|
23099
|
-
this._sendController.abort();
|
|
23100
|
-
}
|
|
23101
|
-
}
|
|
23102
|
-
};
|
|
23103
|
-
|
|
23104
|
-
/**
|
|
23105
|
-
* 工具函数版本 - 用于非组件场景
|
|
23106
|
-
* @param {Object} options - 配置选项
|
|
23107
|
-
* @returns {Object} 包含发送相关方法的对象
|
|
23108
|
-
*/
|
|
23109
|
-
function createSendUtils(options = {}) {
|
|
23110
|
-
const state = {
|
|
23111
|
-
loading: false
|
|
23112
|
-
};
|
|
23113
|
-
const handleSend = (...args) => {
|
|
23114
|
-
if (state.loading) {
|
|
23115
|
-
return;
|
|
23116
|
-
}
|
|
23117
|
-
if (options.sendHandler) {
|
|
23118
|
-
options.sendHandler(...args);
|
|
23119
|
-
}
|
|
23120
|
-
state.loading = true;
|
|
23121
|
-
};
|
|
23122
|
-
const handleAbort = () => {
|
|
23123
|
-
state.loading = false;
|
|
23124
|
-
if (options.abortHandler) {
|
|
23125
|
-
options.abortHandler();
|
|
23126
|
-
}
|
|
23127
|
-
if (options.onAbort) {
|
|
23128
|
-
options.onAbort();
|
|
23129
|
-
}
|
|
23130
|
-
};
|
|
23131
|
-
const handleFinish = () => {
|
|
23132
|
-
state.loading = false;
|
|
23133
|
-
if (options.finishHandler) {
|
|
23134
|
-
options.finishHandler();
|
|
23135
|
-
}
|
|
23136
|
-
};
|
|
23137
|
-
return {
|
|
23138
|
-
state,
|
|
23139
|
-
send: handleSend,
|
|
23140
|
-
abort: handleAbort,
|
|
23141
|
-
finish: handleFinish
|
|
23142
|
-
};
|
|
23143
|
-
}
|
|
23144
|
-
/* harmony default export */ var mixins_sendMixin = (sendMixin);
|
|
23145
|
-
// CONCATENATED MODULE: ./src/mixins/streamMixin.js
|
|
23146
|
-
/**
|
|
23147
|
-
* @fileoverview Vue2 流式数据处理 Mixin
|
|
23148
|
-
* 从 Vue3 useXStream hooks 转换而来,支持 SSE 数据解析和中断功能
|
|
23149
|
-
* @author Element UI X Team
|
|
23150
|
-
* @version 1.0.0
|
|
23151
|
-
*/
|
|
23152
|
-
|
|
23153
|
-
/**
|
|
23154
|
-
* 默认流分隔符
|
|
23155
|
-
* @type {string}
|
|
23156
|
-
* @constant
|
|
23157
|
-
*/
|
|
23158
|
-
const DEFAULT_STREAM_SEPARATOR = '\n\n';
|
|
23159
|
-
|
|
23160
|
-
/**
|
|
23161
|
-
* 默认部分分隔符
|
|
23162
|
-
* @type {string}
|
|
23163
|
-
* @constant
|
|
23164
|
-
*/
|
|
23165
|
-
const DEFAULT_PART_SEPARATOR = '\n';
|
|
23166
|
-
|
|
23167
|
-
/**
|
|
23168
|
-
* 默认键值分隔符
|
|
23169
|
-
* @type {string}
|
|
23170
|
-
* @constant
|
|
23171
|
-
*/
|
|
23172
|
-
const DEFAULT_KV_SEPARATOR = ':';
|
|
23173
|
-
|
|
23174
|
-
/**
|
|
23175
|
-
* SSE 字段类型定义
|
|
23176
|
-
* @typedef {'data'|'event'|'id'|'retry'} SSEFields
|
|
23177
|
-
*/
|
|
23178
|
-
|
|
23179
|
-
/**
|
|
23180
|
-
* SSE 输出对象类型
|
|
23181
|
-
* @typedef {Object} SSEOutput
|
|
23182
|
-
* @property {string} [data] - 数据字段
|
|
23183
|
-
* @property {string} [event] - 事件字段
|
|
23184
|
-
* @property {string} [id] - ID字段
|
|
23185
|
-
* @property {string} [retry] - 重试字段
|
|
23186
|
-
*/
|
|
23187
|
-
|
|
23188
|
-
/**
|
|
23189
|
-
* 流配置选项
|
|
23190
|
-
* @typedef {Object} XStreamOptions
|
|
23191
|
-
* @property {ReadableStream<Uint8Array>} readableStream - 可读流
|
|
23192
|
-
* @property {TransformStream<string, *>} [transformStream] - 可选的转换流
|
|
23193
|
-
*/
|
|
23194
|
-
|
|
23195
|
-
/**
|
|
23196
|
-
* 流状态对象
|
|
23197
|
-
* @typedef {Object} StreamState
|
|
23198
|
-
* @property {Array<*>} data - 流数据数组
|
|
23199
|
-
* @property {Error|null} error - 错误信息
|
|
23200
|
-
* @property {boolean} loading - 加载状态
|
|
23201
|
-
*/
|
|
23202
|
-
|
|
23203
|
-
/**
|
|
23204
|
-
* 流回调函数配置
|
|
23205
|
-
* @typedef {Object} StreamCallbacks
|
|
23206
|
-
* @property {function(*): void} [onData] - 数据回调函数
|
|
23207
|
-
* @property {function(Array<*>): void} [onComplete] - 完成回调函数
|
|
23208
|
-
* @property {function(Error): void} [onError] - 错误回调函数
|
|
23209
|
-
* @property {function(): void} [onCancel] - 取消回调函数
|
|
23210
|
-
* @property {function(): void} [onFinish] - 结束回调函数
|
|
23211
|
-
*/
|
|
23212
|
-
|
|
23213
|
-
/**
|
|
23214
|
-
* 流工具函数返回对象
|
|
23215
|
-
* @typedef {Object} StreamUtils
|
|
23216
|
-
* @property {StreamState} state - 流状态
|
|
23217
|
-
* @property {function(XStreamOptions): Promise<void>} startStream - 启动流处理
|
|
23218
|
-
* @property {function(): void} cancel - 取消流处理
|
|
23219
|
-
* @property {function(): void} reset - 重置流状态
|
|
23220
|
-
*/
|
|
23221
|
-
|
|
23222
|
-
/**
|
|
23223
|
-
* 验证字符串是否有效(非空且非空白)
|
|
23224
|
-
* @param {string} str - 待验证的字符串
|
|
23225
|
-
* @returns {boolean} 是否为有效字符串
|
|
23226
|
-
*/
|
|
23227
|
-
const isValidString = str => (str === null || str === undefined ? '' : str).trim() !== '';
|
|
23228
|
-
|
|
23229
|
-
/**
|
|
23230
|
-
* 创建流分割转换器
|
|
23231
|
-
* 按照默认分隔符分割流数据
|
|
23232
|
-
* @returns {TransformStream<string, string>} 流分割转换器
|
|
23233
|
-
*/
|
|
23234
|
-
function splitStream() {
|
|
23235
|
-
let buffer = '';
|
|
23236
|
-
return new TransformStream({
|
|
23237
|
-
/**
|
|
23238
|
-
* 转换函数
|
|
23239
|
-
* @param {string} chunk - 数据块
|
|
23240
|
-
* @param {TransformStreamDefaultController<string>} controller - 控制器
|
|
23241
|
-
*/
|
|
23242
|
-
transform(chunk, controller) {
|
|
23243
|
-
buffer += chunk;
|
|
23244
|
-
const parts = buffer.split(DEFAULT_STREAM_SEPARATOR);
|
|
23245
|
-
parts.slice(0, -1).forEach(part => {
|
|
23246
|
-
if (isValidString(part)) controller.enqueue(part);
|
|
23247
|
-
});
|
|
23248
|
-
buffer = parts[parts.length - 1];
|
|
23249
|
-
},
|
|
23250
|
-
/**
|
|
23251
|
-
* 刷新函数
|
|
23252
|
-
* @param {TransformStreamDefaultController<string>} controller - 控制器
|
|
23253
|
-
*/
|
|
23254
|
-
flush(controller) {
|
|
23255
|
-
if (isValidString(buffer)) controller.enqueue(buffer);
|
|
23256
|
-
}
|
|
23257
|
-
});
|
|
23258
|
-
}
|
|
23259
|
-
|
|
23260
|
-
/**
|
|
23261
|
-
* 创建 SSE 数据解析转换器
|
|
23262
|
-
* 将文本数据解析为 SSE 格式对象
|
|
23263
|
-
* @returns {TransformStream<string, SSEOutput>} SSE 解析转换器
|
|
23264
|
-
*/
|
|
23265
|
-
function splitPart() {
|
|
23266
|
-
return new TransformStream({
|
|
23267
|
-
/**
|
|
23268
|
-
* 转换函数
|
|
23269
|
-
* @param {string} partChunk - 数据块
|
|
23270
|
-
* @param {TransformStreamDefaultController<SSEOutput>} controller - 控制器
|
|
23271
|
-
*/
|
|
23272
|
-
transform(partChunk, controller) {
|
|
23273
|
-
const lines = partChunk.split(DEFAULT_PART_SEPARATOR);
|
|
23274
|
-
const sseEvent = lines.reduce((acc, line) => {
|
|
23275
|
-
const sepIndex = line.indexOf(DEFAULT_KV_SEPARATOR);
|
|
23276
|
-
if (sepIndex === -1) return acc;
|
|
23277
|
-
const key = line.slice(0, sepIndex);
|
|
23278
|
-
if (!isValidString(key)) return acc;
|
|
23279
|
-
const value = line.slice(sepIndex + 1);
|
|
23280
|
-
return {
|
|
23281
|
-
...acc,
|
|
23282
|
-
[key]: value
|
|
23283
|
-
};
|
|
23284
|
-
}, {});
|
|
23285
|
-
if (Object.keys(sseEvent).length > 0) controller.enqueue(sseEvent);
|
|
23286
|
-
}
|
|
23287
|
-
});
|
|
23288
|
-
}
|
|
23289
|
-
|
|
23290
|
-
/**
|
|
23291
|
-
* 核心流处理函数(支持中断)
|
|
23292
|
-
* @param {XStreamOptions} options - 配置选项
|
|
23293
|
-
* @param {ReadableStream<Uint8Array>} options.readableStream - 可读流
|
|
23294
|
-
* @param {TransformStream<string, *>} [options.transformStream] - 可选的转换流
|
|
23295
|
-
* @param {AbortSignal} [signal] - 中断信号
|
|
23296
|
-
* @returns {ReadableStream<*>} 处理后的流,支持异步迭代
|
|
23297
|
-
* @throws {TypeError} 当 readableStream 不是 ReadableStream 实例时抛出
|
|
23298
|
-
*/
|
|
23299
|
-
function XStream(options, signal) {
|
|
23300
|
-
const {
|
|
23301
|
-
readableStream,
|
|
23302
|
-
transformStream
|
|
23303
|
-
} = options;
|
|
23304
|
-
if (!(readableStream instanceof ReadableStream)) {
|
|
23305
|
-
throw new TypeError('options.readableStream 必须是 ReadableStream 的实例。');
|
|
23306
|
-
}
|
|
23307
|
-
const decoderStream = new TextDecoderStream();
|
|
23308
|
-
const processedStream = transformStream ? readableStream.pipeThrough(decoderStream).pipeThrough(transformStream) : readableStream.pipeThrough(decoderStream).pipeThrough(splitStream()).pipeThrough(splitPart());
|
|
23309
|
-
|
|
23310
|
-
// 为流添加异步迭代器并处理中断信号
|
|
23311
|
-
processedStream[Symbol.asyncIterator] = async function* () {
|
|
23312
|
-
const reader = this.getReader();
|
|
23313
|
-
this.reader = reader; // 保存读取器引用
|
|
23314
|
-
try {
|
|
23315
|
-
while (true) {
|
|
23316
|
-
if (signal && signal.aborted) {
|
|
23317
|
-
await reader.cancel(); // 主动取消 reader
|
|
23318
|
-
break;
|
|
23319
|
-
}
|
|
23320
|
-
const {
|
|
23321
|
-
done,
|
|
23322
|
-
value
|
|
23323
|
-
} = await reader.read();
|
|
23324
|
-
if (done) break;
|
|
23325
|
-
if (value) yield value;
|
|
23354
|
+
} catch (_) {}
|
|
23326
23355
|
}
|
|
23327
|
-
|
|
23328
|
-
|
|
23329
|
-
}
|
|
23330
|
-
};
|
|
23331
|
-
return processedStream;
|
|
23332
|
-
}
|
|
23333
|
-
|
|
23334
|
-
/**
|
|
23335
|
-
* streamMixin -
|
|
23336
|
-
* 用于处理流式数据的 mixin,支持 SSE 数据解析和中断功能
|
|
23337
|
-
* @namespace streamMixin
|
|
23338
|
-
* @type {Object}
|
|
23339
|
-
*/
|
|
23340
|
-
const streamMixin = {
|
|
23341
|
-
/**
|
|
23342
|
-
* 组件数据
|
|
23343
|
-
* @returns {Object} 响应式数据对象
|
|
23344
|
-
* @property {Array<*>} streamData - 流数据数组
|
|
23345
|
-
* @property {Error|null} streamError - 流错误信息
|
|
23346
|
-
* @property {boolean} streamLoading - 流处理状态
|
|
23347
|
-
* @property {AbortController|null} _abortController - 私有:中断控制器
|
|
23348
|
-
* @property {ReadableStream|null} _currentStream - 私有:当前流引用
|
|
23349
|
-
*/
|
|
23350
|
-
data() {
|
|
23351
|
-
return {
|
|
23352
|
-
streamData: [],
|
|
23353
|
-
streamError: null,
|
|
23354
|
-
streamLoading: false,
|
|
23355
|
-
_abortController: null,
|
|
23356
|
-
_currentStream: null
|
|
23356
|
+
/* Execute a hook if present */
|
|
23357
|
+
_executeHooks(hooks.afterSanitizeAttributes, currentNode, null);
|
|
23357
23358
|
};
|
|
23358
|
-
|
|
23359
|
-
|
|
23360
|
-
|
|
23361
|
-
*
|
|
23362
|
-
* @async
|
|
23363
|
-
* @param {XStreamOptions} options - 流配置选项
|
|
23364
|
-
* @param {ReadableStream<Uint8Array>} options.readableStream - 可读流
|
|
23365
|
-
* @param {TransformStream<string, *>} [options.transformStream] - 可选的转换流
|
|
23366
|
-
* @returns {Promise<void>} 流处理完成的 Promise
|
|
23367
|
-
* @fires streamMixin#stream-data - 收到新数据时触发
|
|
23368
|
-
* @fires streamMixin#stream-complete - 流完成时触发
|
|
23369
|
-
* @fires streamMixin#stream-error - 流错误时触发
|
|
23370
|
-
* @fires streamMixin#stream-finish - 流处理结束时触发
|
|
23371
|
-
* @example
|
|
23372
|
-
* // 基础使用
|
|
23373
|
-
* const response = await fetch('/api/stream')
|
|
23374
|
-
* await this.startStream({ readableStream: response.body })
|
|
23375
|
-
*
|
|
23376
|
-
* // 使用自定义转换流
|
|
23377
|
-
* const customTransform = new TransformStream({ ... })
|
|
23378
|
-
* await this.startStream({
|
|
23379
|
-
* readableStream: response.body,
|
|
23380
|
-
* transformStream: customTransform
|
|
23381
|
-
* })
|
|
23359
|
+
/**
|
|
23360
|
+
* _sanitizeShadowDOM
|
|
23361
|
+
*
|
|
23362
|
+
* @param fragment to iterate over recursively
|
|
23382
23363
|
*/
|
|
23383
|
-
|
|
23384
|
-
|
|
23385
|
-
|
|
23386
|
-
|
|
23387
|
-
|
|
23388
|
-
|
|
23389
|
-
|
|
23390
|
-
|
|
23391
|
-
|
|
23392
|
-
|
|
23393
|
-
|
|
23394
|
-
|
|
23395
|
-
|
|
23396
|
-
|
|
23397
|
-
|
|
23398
|
-
this.$emit('stream-data', item);
|
|
23364
|
+
const _sanitizeShadowDOM = function _sanitizeShadowDOM(fragment) {
|
|
23365
|
+
let shadowNode = null;
|
|
23366
|
+
const shadowIterator = _createNodeIterator(fragment);
|
|
23367
|
+
/* Execute a hook if present */
|
|
23368
|
+
_executeHooks(hooks.beforeSanitizeShadowDOM, fragment, null);
|
|
23369
|
+
while (shadowNode = shadowIterator.nextNode()) {
|
|
23370
|
+
/* Execute a hook if present */
|
|
23371
|
+
_executeHooks(hooks.uponSanitizeShadowNode, shadowNode, null);
|
|
23372
|
+
/* Sanitize tags and elements */
|
|
23373
|
+
_sanitizeElements(shadowNode);
|
|
23374
|
+
/* Check attributes next */
|
|
23375
|
+
_sanitizeAttributes(shadowNode);
|
|
23376
|
+
/* Deep shadow DOM detected */
|
|
23377
|
+
if (shadowNode.content instanceof DocumentFragment) {
|
|
23378
|
+
_sanitizeShadowDOM(shadowNode.content);
|
|
23399
23379
|
}
|
|
23400
|
-
|
|
23401
|
-
|
|
23402
|
-
|
|
23403
|
-
|
|
23404
|
-
|
|
23405
|
-
|
|
23406
|
-
|
|
23407
|
-
|
|
23408
|
-
|
|
23409
|
-
|
|
23410
|
-
|
|
23411
|
-
|
|
23412
|
-
|
|
23413
|
-
|
|
23414
|
-
|
|
23415
|
-
|
|
23380
|
+
}
|
|
23381
|
+
/* Execute a hook if present */
|
|
23382
|
+
_executeHooks(hooks.afterSanitizeShadowDOM, fragment, null);
|
|
23383
|
+
};
|
|
23384
|
+
// eslint-disable-next-line complexity
|
|
23385
|
+
DOMPurify.sanitize = function (dirty) {
|
|
23386
|
+
let cfg = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
23387
|
+
let body = null;
|
|
23388
|
+
let importedNode = null;
|
|
23389
|
+
let currentNode = null;
|
|
23390
|
+
let returnNode = null;
|
|
23391
|
+
/* Make sure we have a string to sanitize.
|
|
23392
|
+
DO NOT return early, as this will return the wrong type if
|
|
23393
|
+
the user has requested a DOM object rather than a string */
|
|
23394
|
+
IS_EMPTY_INPUT = !dirty;
|
|
23395
|
+
if (IS_EMPTY_INPUT) {
|
|
23396
|
+
dirty = '<!-->';
|
|
23397
|
+
}
|
|
23398
|
+
/* Stringify, in case dirty is an object */
|
|
23399
|
+
if (typeof dirty !== 'string' && !_isNode(dirty)) {
|
|
23400
|
+
if (typeof dirty.toString === 'function') {
|
|
23401
|
+
dirty = dirty.toString();
|
|
23402
|
+
if (typeof dirty !== 'string') {
|
|
23403
|
+
throw typeErrorCreate('dirty is not a string, aborting');
|
|
23404
|
+
}
|
|
23405
|
+
} else {
|
|
23406
|
+
throw typeErrorCreate('toString is not a function');
|
|
23416
23407
|
}
|
|
23417
|
-
} finally {
|
|
23418
|
-
this.streamLoading = false;
|
|
23419
|
-
this._currentStream = null; // 释放流引用
|
|
23420
|
-
this._abortController = null; // 释放控制器
|
|
23421
|
-
/**
|
|
23422
|
-
* 流处理结束事件
|
|
23423
|
-
* @event streamMixin#stream-finish
|
|
23424
|
-
*/
|
|
23425
|
-
this.$emit('stream-finish');
|
|
23426
23408
|
}
|
|
23427
|
-
|
|
23428
|
-
|
|
23429
|
-
|
|
23430
|
-
* @returns {void}
|
|
23431
|
-
* @fires streamMixin#stream-cancel - 流被中断时触发
|
|
23432
|
-
* @example
|
|
23433
|
-
* this.cancelStream()
|
|
23434
|
-
*/
|
|
23435
|
-
cancelStream() {
|
|
23436
|
-
if (this._abortController) {
|
|
23437
|
-
this._abortController.abort();
|
|
23438
|
-
/**
|
|
23439
|
-
* 流取消事件
|
|
23440
|
-
* @event streamMixin#stream-cancel
|
|
23441
|
-
*/
|
|
23442
|
-
this.$emit('stream-cancel');
|
|
23409
|
+
/* Return dirty HTML if DOMPurify cannot run */
|
|
23410
|
+
if (!DOMPurify.isSupported) {
|
|
23411
|
+
return dirty;
|
|
23443
23412
|
}
|
|
23444
|
-
|
|
23445
|
-
|
|
23446
|
-
|
|
23447
|
-
|
|
23448
|
-
|
|
23449
|
-
|
|
23450
|
-
|
|
23451
|
-
|
|
23452
|
-
|
|
23453
|
-
|
|
23454
|
-
|
|
23455
|
-
|
|
23456
|
-
|
|
23457
|
-
|
|
23458
|
-
|
|
23459
|
-
|
|
23460
|
-
|
|
23461
|
-
|
|
23462
|
-
|
|
23463
|
-
|
|
23464
|
-
|
|
23465
|
-
|
|
23466
|
-
|
|
23467
|
-
|
|
23468
|
-
|
|
23469
|
-
|
|
23470
|
-
|
|
23471
|
-
|
|
23472
|
-
|
|
23473
|
-
|
|
23474
|
-
|
|
23475
|
-
|
|
23476
|
-
|
|
23477
|
-
|
|
23478
|
-
|
|
23479
|
-
|
|
23480
|
-
|
|
23481
|
-
|
|
23482
|
-
|
|
23483
|
-
|
|
23484
|
-
|
|
23485
|
-
|
|
23486
|
-
|
|
23487
|
-
|
|
23488
|
-
* @param {StreamCallbacks} [callbacks={}] - 回调函数配置
|
|
23489
|
-
* @param {function(*): void} [callbacks.onData] - 数据回调函数
|
|
23490
|
-
* @param {function(Array<*>): void} [callbacks.onComplete] - 完成回调函数
|
|
23491
|
-
* @param {function(Error): void} [callbacks.onError] - 错误回调函数
|
|
23492
|
-
* @param {function(): void} [callbacks.onCancel] - 取消回调函数
|
|
23493
|
-
* @param {function(): void} [callbacks.onFinish] - 结束回调函数
|
|
23494
|
-
* @returns {StreamUtils} 包含流处理相关方法的对象
|
|
23495
|
-
* @example
|
|
23496
|
-
* // 基础使用
|
|
23497
|
-
* const streamUtils = createStreamUtils({
|
|
23498
|
-
* onData: (item) => console.log('数据:', item),
|
|
23499
|
-
* onComplete: (allData) => console.log('完成:', allData),
|
|
23500
|
-
* onError: (error) => console.error('错误:', error)
|
|
23501
|
-
* })
|
|
23502
|
-
*
|
|
23503
|
-
* const response = await fetch('/api/stream')
|
|
23504
|
-
* await streamUtils.startStream({ readableStream: response.body })
|
|
23505
|
-
*/
|
|
23506
|
-
function createStreamUtils(callbacks = {}) {
|
|
23507
|
-
/**
|
|
23508
|
-
* 流状态对象
|
|
23509
|
-
* @type {StreamState}
|
|
23510
|
-
*/
|
|
23511
|
-
const state = {
|
|
23512
|
-
data: [],
|
|
23513
|
-
error: null,
|
|
23514
|
-
loading: false
|
|
23515
|
-
};
|
|
23516
|
-
let abortController = null;
|
|
23517
|
-
let currentStream = null;
|
|
23518
|
-
|
|
23519
|
-
/**
|
|
23520
|
-
* 启动流处理
|
|
23521
|
-
* @async
|
|
23522
|
-
* @param {XStreamOptions} options - 流配置选项
|
|
23523
|
-
* @returns {Promise<void>} 流处理完成的 Promise
|
|
23524
|
-
*/
|
|
23525
|
-
const startStream = async options => {
|
|
23526
|
-
state.loading = true;
|
|
23527
|
-
state.error = null;
|
|
23528
|
-
state.data = [];
|
|
23529
|
-
abortController = new AbortController();
|
|
23530
|
-
currentStream = XStream(options, abortController.signal);
|
|
23531
|
-
try {
|
|
23532
|
-
for await (const item of currentStream) {
|
|
23533
|
-
state.data.push(item);
|
|
23534
|
-
if (callbacks.onData) {
|
|
23535
|
-
callbacks.onData(item);
|
|
23413
|
+
/* Assign config vars */
|
|
23414
|
+
if (!SET_CONFIG) {
|
|
23415
|
+
_parseConfig(cfg);
|
|
23416
|
+
}
|
|
23417
|
+
/* Clean up removed elements */
|
|
23418
|
+
DOMPurify.removed = [];
|
|
23419
|
+
/* Check if dirty is correctly typed for IN_PLACE */
|
|
23420
|
+
if (typeof dirty === 'string') {
|
|
23421
|
+
IN_PLACE = false;
|
|
23422
|
+
}
|
|
23423
|
+
if (IN_PLACE) {
|
|
23424
|
+
/* Do some early pre-sanitization to avoid unsafe root nodes */
|
|
23425
|
+
if (dirty.nodeName) {
|
|
23426
|
+
const tagName = transformCaseFunc(dirty.nodeName);
|
|
23427
|
+
if (!ALLOWED_TAGS[tagName] || FORBID_TAGS[tagName]) {
|
|
23428
|
+
throw typeErrorCreate('root node is forbidden and cannot be sanitized in-place');
|
|
23429
|
+
}
|
|
23430
|
+
}
|
|
23431
|
+
} else if (dirty instanceof Node) {
|
|
23432
|
+
/* If dirty is a DOM element, append to an empty document to avoid
|
|
23433
|
+
elements being stripped by the parser */
|
|
23434
|
+
body = _initDocument('<!---->');
|
|
23435
|
+
importedNode = body.ownerDocument.importNode(dirty, true);
|
|
23436
|
+
if (importedNode.nodeType === NODE_TYPE.element && importedNode.nodeName === 'BODY') {
|
|
23437
|
+
/* Node is already a body, use as is */
|
|
23438
|
+
body = importedNode;
|
|
23439
|
+
} else if (importedNode.nodeName === 'HTML') {
|
|
23440
|
+
body = importedNode;
|
|
23441
|
+
} else {
|
|
23442
|
+
// eslint-disable-next-line unicorn/prefer-dom-node-append
|
|
23443
|
+
body.appendChild(importedNode);
|
|
23444
|
+
}
|
|
23445
|
+
} else {
|
|
23446
|
+
/* Exit directly if we have nothing to do */
|
|
23447
|
+
if (!RETURN_DOM && !SAFE_FOR_TEMPLATES && !WHOLE_DOCUMENT &&
|
|
23448
|
+
// eslint-disable-next-line unicorn/prefer-includes
|
|
23449
|
+
dirty.indexOf('<') === -1) {
|
|
23450
|
+
return trustedTypesPolicy && RETURN_TRUSTED_TYPE ? trustedTypesPolicy.createHTML(dirty) : dirty;
|
|
23451
|
+
}
|
|
23452
|
+
/* Initialize the document to work on */
|
|
23453
|
+
body = _initDocument(dirty);
|
|
23454
|
+
/* Check we have a DOM node from the data */
|
|
23455
|
+
if (!body) {
|
|
23456
|
+
return RETURN_DOM ? null : RETURN_TRUSTED_TYPE ? emptyHTML : '';
|
|
23536
23457
|
}
|
|
23537
23458
|
}
|
|
23538
|
-
|
|
23539
|
-
|
|
23459
|
+
/* Remove first element node (ours) if FORCE_BODY is set */
|
|
23460
|
+
if (body && FORCE_BODY) {
|
|
23461
|
+
_forceRemove(body.firstChild);
|
|
23540
23462
|
}
|
|
23541
|
-
|
|
23542
|
-
|
|
23543
|
-
|
|
23544
|
-
|
|
23545
|
-
|
|
23463
|
+
/* Get node iterator */
|
|
23464
|
+
const nodeIterator = _createNodeIterator(IN_PLACE ? dirty : body);
|
|
23465
|
+
/* Now start iterating over the created document */
|
|
23466
|
+
while (currentNode = nodeIterator.nextNode()) {
|
|
23467
|
+
/* Sanitize tags and elements */
|
|
23468
|
+
_sanitizeElements(currentNode);
|
|
23469
|
+
/* Check attributes next */
|
|
23470
|
+
_sanitizeAttributes(currentNode);
|
|
23471
|
+
/* Shadow DOM detected, sanitize it */
|
|
23472
|
+
if (currentNode.content instanceof DocumentFragment) {
|
|
23473
|
+
_sanitizeShadowDOM(currentNode.content);
|
|
23546
23474
|
}
|
|
23547
23475
|
}
|
|
23548
|
-
|
|
23549
|
-
|
|
23550
|
-
|
|
23551
|
-
abortController = null;
|
|
23552
|
-
if (callbacks.onFinish) {
|
|
23553
|
-
callbacks.onFinish();
|
|
23476
|
+
/* If we sanitized `dirty` in-place, return it. */
|
|
23477
|
+
if (IN_PLACE) {
|
|
23478
|
+
return dirty;
|
|
23554
23479
|
}
|
|
23555
|
-
|
|
23556
|
-
|
|
23557
|
-
|
|
23558
|
-
|
|
23559
|
-
|
|
23560
|
-
|
|
23561
|
-
|
|
23562
|
-
|
|
23563
|
-
|
|
23564
|
-
|
|
23565
|
-
|
|
23566
|
-
|
|
23480
|
+
/* Return sanitized string or DOM */
|
|
23481
|
+
if (RETURN_DOM) {
|
|
23482
|
+
if (RETURN_DOM_FRAGMENT) {
|
|
23483
|
+
returnNode = createDocumentFragment.call(body.ownerDocument);
|
|
23484
|
+
while (body.firstChild) {
|
|
23485
|
+
// eslint-disable-next-line unicorn/prefer-dom-node-append
|
|
23486
|
+
returnNode.appendChild(body.firstChild);
|
|
23487
|
+
}
|
|
23488
|
+
} else {
|
|
23489
|
+
returnNode = body;
|
|
23490
|
+
}
|
|
23491
|
+
if (ALLOWED_ATTR.shadowroot || ALLOWED_ATTR.shadowrootmode) {
|
|
23492
|
+
/*
|
|
23493
|
+
AdoptNode() is not used because internal state is not reset
|
|
23494
|
+
(e.g. the past names map of a HTMLFormElement), this is safe
|
|
23495
|
+
in theory but we would rather not risk another attack vector.
|
|
23496
|
+
The state that is cloned by importNode() is explicitly defined
|
|
23497
|
+
by the specs.
|
|
23498
|
+
*/
|
|
23499
|
+
returnNode = importNode.call(originalDocument, returnNode, true);
|
|
23500
|
+
}
|
|
23501
|
+
return returnNode;
|
|
23567
23502
|
}
|
|
23568
|
-
|
|
23569
|
-
|
|
23503
|
+
let serializedHTML = WHOLE_DOCUMENT ? body.outerHTML : body.innerHTML;
|
|
23504
|
+
/* Serialize doctype if allowed */
|
|
23505
|
+
if (WHOLE_DOCUMENT && ALLOWED_TAGS['!doctype'] && body.ownerDocument && body.ownerDocument.doctype && body.ownerDocument.doctype.name && regExpTest(DOCTYPE_NAME, body.ownerDocument.doctype.name)) {
|
|
23506
|
+
serializedHTML = '<!DOCTYPE ' + body.ownerDocument.doctype.name + '>\n' + serializedHTML;
|
|
23507
|
+
}
|
|
23508
|
+
/* Sanitize final string template-safe */
|
|
23509
|
+
if (SAFE_FOR_TEMPLATES) {
|
|
23510
|
+
arrayForEach([MUSTACHE_EXPR, ERB_EXPR, TMPLIT_EXPR], expr => {
|
|
23511
|
+
serializedHTML = stringReplace(serializedHTML, expr, ' ');
|
|
23512
|
+
});
|
|
23513
|
+
}
|
|
23514
|
+
return trustedTypesPolicy && RETURN_TRUSTED_TYPE ? trustedTypesPolicy.createHTML(serializedHTML) : serializedHTML;
|
|
23515
|
+
};
|
|
23516
|
+
DOMPurify.setConfig = function () {
|
|
23517
|
+
let cfg = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
23518
|
+
_parseConfig(cfg);
|
|
23519
|
+
SET_CONFIG = true;
|
|
23520
|
+
};
|
|
23521
|
+
DOMPurify.clearConfig = function () {
|
|
23522
|
+
CONFIG = null;
|
|
23523
|
+
SET_CONFIG = false;
|
|
23524
|
+
};
|
|
23525
|
+
DOMPurify.isValidAttribute = function (tag, attr, value) {
|
|
23526
|
+
/* Initialize shared config vars if necessary. */
|
|
23527
|
+
if (!CONFIG) {
|
|
23528
|
+
_parseConfig({});
|
|
23529
|
+
}
|
|
23530
|
+
const lcTag = transformCaseFunc(tag);
|
|
23531
|
+
const lcName = transformCaseFunc(attr);
|
|
23532
|
+
return _isValidAttribute(lcTag, lcName, value);
|
|
23533
|
+
};
|
|
23534
|
+
DOMPurify.addHook = function (entryPoint, hookFunction) {
|
|
23535
|
+
if (typeof hookFunction !== 'function') {
|
|
23536
|
+
return;
|
|
23537
|
+
}
|
|
23538
|
+
arrayPush(hooks[entryPoint], hookFunction);
|
|
23539
|
+
};
|
|
23540
|
+
DOMPurify.removeHook = function (entryPoint, hookFunction) {
|
|
23541
|
+
if (hookFunction !== undefined) {
|
|
23542
|
+
const index = arrayLastIndexOf(hooks[entryPoint], hookFunction);
|
|
23543
|
+
return index === -1 ? undefined : arraySplice(hooks[entryPoint], index, 1)[0];
|
|
23544
|
+
}
|
|
23545
|
+
return arrayPop(hooks[entryPoint]);
|
|
23546
|
+
};
|
|
23547
|
+
DOMPurify.removeHooks = function (entryPoint) {
|
|
23548
|
+
hooks[entryPoint] = [];
|
|
23549
|
+
};
|
|
23550
|
+
DOMPurify.removeAllHooks = function () {
|
|
23551
|
+
hooks = _createHooksMap();
|
|
23552
|
+
};
|
|
23553
|
+
return DOMPurify;
|
|
23554
|
+
}
|
|
23555
|
+
var purify = createDOMPurify();
|
|
23570
23556
|
|
|
23571
|
-
|
|
23572
|
-
* 重置流状态
|
|
23573
|
-
* @returns {void}
|
|
23574
|
-
*/
|
|
23575
|
-
const reset = () => {
|
|
23576
|
-
state.data = [];
|
|
23577
|
-
state.error = null;
|
|
23578
|
-
state.loading = false;
|
|
23579
|
-
abortController = null;
|
|
23580
|
-
currentStream = null;
|
|
23581
|
-
};
|
|
23582
|
-
return {
|
|
23583
|
-
state,
|
|
23584
|
-
startStream,
|
|
23585
|
-
cancel,
|
|
23586
|
-
reset
|
|
23587
|
-
};
|
|
23588
|
-
}
|
|
23557
|
+
return purify;
|
|
23589
23558
|
|
|
23590
|
-
|
|
23559
|
+
}));
|
|
23560
|
+
//# sourceMappingURL=purify.js.map
|
|
23591
23561
|
|
|
23592
23562
|
|
|
23593
|
-
|
|
23594
|
-
|
|
23595
|
-
|
|
23596
|
-
*/
|
|
23597
|
-
/* harmony default export */ var mixins_streamMixin = (streamMixin);
|
|
23598
|
-
// CONCATENATED MODULE: ./src/mixins/index.js
|
|
23599
|
-
/**
|
|
23600
|
-
* Mixins 入口文件
|
|
23601
|
-
*/
|
|
23563
|
+
/***/ }),
|
|
23564
|
+
/* 22 */
|
|
23565
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
23602
23566
|
|
|
23567
|
+
"use strict";
|
|
23603
23568
|
|
|
23604
23569
|
|
|
23605
23570
|
|
|
23571
|
+
module.exports = __webpack_require__(29);
|
|
23572
|
+
|
|
23573
|
+
|
|
23574
|
+
/***/ }),
|
|
23575
|
+
/* 23 */
|
|
23576
|
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
23577
|
+
|
|
23578
|
+
"use strict";
|
|
23579
|
+
/* harmony import */ var _css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2);
|
|
23580
|
+
/* harmony import */ var _css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
23581
|
+
// Imports
|
|
23582
|
+
|
|
23583
|
+
var ___CSS_LOADER_EXPORT___ = _css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(function(i){return i[1]});
|
|
23584
|
+
// Module
|
|
23585
|
+
___CSS_LOADER_EXPORT___.push([module.i, "/**\n * prism.js default theme for JavaScript, CSS and HTML\n * Based on dabblet (http://dabblet.com)\n * @author Lea Verou\n */\n\ncode[class*=\"language-\"],\npre[class*=\"language-\"] {\n\tcolor: black;\n\tbackground: none;\n\ttext-shadow: 0 1px white;\n\tfont-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace;\n\tfont-size: 1em;\n\ttext-align: left;\n\twhite-space: pre;\n\tword-spacing: normal;\n\tword-break: normal;\n\tword-wrap: normal;\n\tline-height: 1.5;\n\n\t-moz-tab-size: 4;\n\t-o-tab-size: 4;\n\ttab-size: 4;\n\n\t-webkit-hyphens: none;\n\t-moz-hyphens: none;\n\t-ms-hyphens: none;\n\thyphens: none;\n}\n\npre[class*=\"language-\"]::-moz-selection, pre[class*=\"language-\"] ::-moz-selection,\ncode[class*=\"language-\"]::-moz-selection, code[class*=\"language-\"] ::-moz-selection {\n\ttext-shadow: none;\n\tbackground: #b3d4fc;\n}\n\npre[class*=\"language-\"]::selection, pre[class*=\"language-\"] ::selection,\ncode[class*=\"language-\"]::selection, code[class*=\"language-\"] ::selection {\n\ttext-shadow: none;\n\tbackground: #b3d4fc;\n}\n\n@media print {\n\tcode[class*=\"language-\"],\n\tpre[class*=\"language-\"] {\n\t\ttext-shadow: none;\n\t}\n}\n\n/* Code blocks */\npre[class*=\"language-\"] {\n\tpadding: 1em;\n\tmargin: .5em 0;\n\toverflow: auto;\n}\n\n:not(pre) > code[class*=\"language-\"],\npre[class*=\"language-\"] {\n\tbackground: #f5f2f0;\n}\n\n/* Inline code */\n:not(pre) > code[class*=\"language-\"] {\n\tpadding: .1em;\n\tborder-radius: .3em;\n\twhite-space: normal;\n}\n\n.token.comment,\n.token.prolog,\n.token.doctype,\n.token.cdata {\n\tcolor: slategray;\n}\n\n.token.punctuation {\n\tcolor: #999;\n}\n\n.token.namespace {\n\topacity: .7;\n}\n\n.token.property,\n.token.tag,\n.token.boolean,\n.token.number,\n.token.constant,\n.token.symbol,\n.token.deleted {\n\tcolor: #905;\n}\n\n.token.selector,\n.token.attr-name,\n.token.string,\n.token.char,\n.token.builtin,\n.token.inserted {\n\tcolor: #690;\n}\n\n.token.operator,\n.token.entity,\n.token.url,\n.language-css .token.string,\n.style .token.string {\n\tcolor: #9a6e3a;\n\t/* This background color was intended by the author of this theme. */\n\tbackground: hsla(0, 0%, 100%, .5);\n}\n\n.token.atrule,\n.token.attr-value,\n.token.keyword {\n\tcolor: #07a;\n}\n\n.token.function,\n.token.class-name {\n\tcolor: #DD4A68;\n}\n\n.token.regex,\n.token.important,\n.token.variable {\n\tcolor: #e90;\n}\n\n.token.important,\n.token.bold {\n\tfont-weight: bold;\n}\n.token.italic {\n\tfont-style: italic;\n}\n\n.token.entity {\n\tcursor: help;\n}\n", ""]);
|
|
23586
|
+
// Exports
|
|
23587
|
+
/* harmony default export */ __webpack_exports__["a"] = (___CSS_LOADER_EXPORT___);
|
|
23588
|
+
|
|
23589
|
+
|
|
23590
|
+
/***/ }),
|
|
23591
|
+
/* 24 */
|
|
23592
|
+
/***/ (function(module, exports) {
|
|
23593
|
+
|
|
23594
|
+
module.exports = function(module) {
|
|
23595
|
+
if (!module.webpackPolyfill) {
|
|
23596
|
+
module.deprecate = function() {};
|
|
23597
|
+
module.paths = [];
|
|
23598
|
+
// module.parent = undefined by default
|
|
23599
|
+
if (!module.children) module.children = [];
|
|
23600
|
+
Object.defineProperty(module, "loaded", {
|
|
23601
|
+
enumerable: true,
|
|
23602
|
+
get: function() {
|
|
23603
|
+
return module.l;
|
|
23604
|
+
}
|
|
23605
|
+
});
|
|
23606
|
+
Object.defineProperty(module, "id", {
|
|
23607
|
+
enumerable: true,
|
|
23608
|
+
get: function() {
|
|
23609
|
+
return module.i;
|
|
23610
|
+
}
|
|
23611
|
+
});
|
|
23612
|
+
module.webpackPolyfill = 1;
|
|
23613
|
+
}
|
|
23614
|
+
return module;
|
|
23615
|
+
};
|
|
23606
23616
|
|
|
23607
|
-
/* harmony default export */ var mixins = __webpack_exports__["default"] = ({
|
|
23608
|
-
recordMixin: recordMixin,
|
|
23609
|
-
sendMixin: sendMixin,
|
|
23610
|
-
XRequest: XRequest,
|
|
23611
|
-
createSendUtils: createSendUtils,
|
|
23612
|
-
streamMixin: streamMixin,
|
|
23613
|
-
createStreamUtils: createStreamUtils,
|
|
23614
|
-
XStream: XStream,
|
|
23615
|
-
splitStream: splitStream,
|
|
23616
|
-
splitPart: splitPart,
|
|
23617
|
-
isValidString: isValidString,
|
|
23618
|
-
DEFAULT_STREAM_SEPARATOR: DEFAULT_STREAM_SEPARATOR,
|
|
23619
|
-
DEFAULT_PART_SEPARATOR: DEFAULT_PART_SEPARATOR,
|
|
23620
|
-
DEFAULT_KV_SEPARATOR: DEFAULT_KV_SEPARATOR
|
|
23621
|
-
});
|
|
23622
23617
|
|
|
23623
23618
|
/***/ }),
|
|
23624
23619
|
/* 25 */
|
|
@@ -23631,7 +23626,7 @@ function createStreamUtils(callbacks = {}) {
|
|
|
23631
23626
|
|
|
23632
23627
|
var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(function(i){return i[1]});
|
|
23633
23628
|
// Module
|
|
23634
|
-
___CSS_LOADER_EXPORT___.push([module.i, ".el-x-filescard[data-v-10b2c201]{width:fit-content;padding:12px;display:flex;flex-wrap:nowrap;gap:8px;align-items:center;border-radius:8px;position:relative;background:rgba(0,0,0
|
|
23629
|
+
___CSS_LOADER_EXPORT___.push([module.i, ".el-x-filescard[data-v-10b2c201]{width:fit-content;padding:12px;display:flex;flex-wrap:nowrap;gap:8px;align-items:center;border-radius:8px;position:relative;background:rgba(0,0,0,.06);max-width:var(--elx-files-card-max-width)}.el-x-filescard .el-x-filescard-progress[data-v-10b2c201]{position:absolute;top:0;left:0;bottom:0;background:rgba(0,0,0,.08);border-radius:8px;transition:width .2s ease}.el-x-filescard .el-x-filescard-delete-icon[data-v-10b2c201]{position:absolute;top:-8px;right:-6px;cursor:pointer;color:rgba(0,0,0,.4);display:none}.el-x-filescard .el-x-filescard-delete-icon[data-v-10b2c201]:hover{color:#ff4d4f}.el-x-filescard:hover .el-x-filescard-delete-icon[data-v-10b2c201]{display:block}.el-x-filescard-square[data-v-10b2c201]{padding:0;margin:0}.el-x-filescard-icon[data-v-10b2c201]{flex:none;font-size:var(--elx-files-card-icon-size)}.el-x-filescard-img[data-v-10b2c201]{flex:none;width:var(--elx-files-card-icon-size);height:var(--elx-files-card-icon-size);border-radius:8px;object-fit:cover}.el-x-filescard-content[data-v-10b2c201]{flex:auto;min-width:0;display:flex;flex-direction:column;align-items:stretch;justify-content:space-between;height:100%}.el-x-filescard-content .el-x-filescard-name[data-v-10b2c201]{display:flex;flex-wrap:nowrap;max-width:100%;font-size:14px}.el-x-filescard-content .el-x-filescard-name .el-x-filescard-name-prefix[data-v-10b2c201]{flex:0 1 auto;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.el-x-filescard-content .el-x-filescard-name .el-x-filescard-name-suffix[data-v-10b2c201]{flex:none}.el-x-filescard-content .el-x-filescard-description[data-v-10b2c201]{flex:none;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:rgba(0,0,0,.4);font-size:12px}.el-x-filescard-content .el-x-filescard-description-error[data-v-10b2c201]{color:#ff4d4f}.image-preview-container[data-v-10b2c201]{position:relative;padding:0px;width:var(--elx-files-card-icon-size);height:var(--elx-files-card-icon-size);display:inline-block;border-radius:8px;overflow:hidden;transition:all .3s}.image-preview-container .preview-mask[data-v-10b2c201]{position:absolute;inset:0;width:100%;display:flex;justify-content:center;align-items:center;opacity:0;background:rgba(0,0,0,.65);color:#fff;font-size:10px;transition:opacity .3s}.image-preview-container .preview-mask .el-icon-view[data-v-10b2c201]{font-size:10px;margin-right:2px;display:flex;align-items:center;height:100%;margin-top:2px}.image-preview-container .preview-mask[data-v-10b2c201]:hover{opacity:1;transition:opacity .3s;cursor:pointer}.image-preview-container-square .preview-mask[data-v-10b2c201]{font-size:14px}.image-preview-container-square .preview-mask .el-icon-view[data-v-10b2c201]{font-size:12px}.preview-mask-loading[data-v-10b2c201]{position:absolute;inset:0;width:100%;display:flex;justify-content:center;align-items:center;background:rgba(0,0,0,.65);color:#fff;transition:all .3s}.preview-mask-loading .circle-progress[data-v-10b2c201]{width:100% !important;height:100% !important;display:flex;justify-content:center;align-items:center}.preview-mask-loading .circle-progress .el-progress-circle[data-v-10b2c201]{width:calc(100% - 12px) !important;height:calc(100% - 12px) !important}.preview-mask-loading .circle-progress .el-progress-circle svg>path[data-v-10b2c201]:nth-child(1){stroke:hsla(0,0%,100%,.2);stroke-width:8px}.preview-mask-loading .circle-progress .el-progress__text[data-v-10b2c201]{color:#fff;font-size:14px}.preview-mask-error[data-v-10b2c201]{position:absolute;inset:0;width:100%;display:flex;justify-content:center;align-items:center;background:rgba(0,0,0,.5);font-size:12px;transition:all .3s;color:#ff4d4f;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.el-image-viewer__progress[data-v-10b2c201]{display:none}.fade-enter-active[data-v-10b2c201],.fade-leave-active[data-v-10b2c201]{transition:opacity .3s}.fade-enter-from[data-v-10b2c201],.fade-leave-to[data-v-10b2c201]{opacity:0}", ""]);
|
|
23635
23630
|
// Exports
|
|
23636
23631
|
/* harmony default export */ __webpack_exports__["a"] = (___CSS_LOADER_EXPORT___);
|
|
23637
23632
|
|
|
@@ -23647,7 +23642,7 @@ ___CSS_LOADER_EXPORT___.push([module.i, ".el-x-filescard[data-v-10b2c201]{width:
|
|
|
23647
23642
|
|
|
23648
23643
|
var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(function(i){return i[1]});
|
|
23649
23644
|
// Module
|
|
23650
|
-
___CSS_LOADER_EXPORT___.push([module.i, "[data-v-716e941e]:root{--color-primary: #409EFF;--color-success: #67C23A;--color-warning: #E6A23C;--color-danger: #F56C6C;--color-info: #909399}.el-x-bubble[data-v-716e941e]{display:flex;gap:var(--el-x-bubble-avatar-placeholder-gap)}.el-x-bubble-avatar-size[data-v-716e941e] .el-avatar{width:var(--el-x-bubble-avatar-placeholder-width);height:var(--el-x-bubble-avatar-placeholder-height)}.el-x-bubble-avatar-placeholder[data-v-716e941e]{width:var(--el-x-bubble-avatar-placeholder-width);height:var(--el-x-bubble-avatar-placeholder-height)}.el-x-bubble-start .el-x-bubble-content-wrapper .el-x-bubble-content-corner[data-v-716e941e]{border-start-start-radius:
|
|
23645
|
+
___CSS_LOADER_EXPORT___.push([module.i, "[data-v-716e941e]:root{--color-primary: #409EFF;--color-success: #67C23A;--color-warning: #E6A23C;--color-danger: #F56C6C;--color-info: #909399}.el-x-bubble[data-v-716e941e]{display:flex;gap:var(--el-x-bubble-avatar-placeholder-gap)}.el-x-bubble-avatar-size[data-v-716e941e] .el-avatar{width:var(--el-x-bubble-avatar-placeholder-width);height:var(--el-x-bubble-avatar-placeholder-height)}.el-x-bubble-avatar-placeholder[data-v-716e941e]{width:var(--el-x-bubble-avatar-placeholder-width);height:var(--el-x-bubble-avatar-placeholder-height)}.el-x-bubble-start .el-x-bubble-content-wrapper .el-x-bubble-content-corner[data-v-716e941e]{border-start-start-radius:2px}.el-x-bubble-end[data-v-716e941e]{justify-content:end;flex-direction:row-reverse}.el-x-bubble-end .el-x-bubble-content-wrapper[data-v-716e941e]{align-items:flex-end}.el-x-bubble-end .el-x-bubble-content-wrapper .el-x-bubble-content-corner[data-v-716e941e]{border-start-end-radius:2px}.el-x-bubble-no-style .el-x-bubble-content-wrapper .el-x-bubble-content[data-v-716e941e]{background-color:rgba(0,0,0,0);padding:0}.el-x-bubble-content-wrapper[data-v-716e941e]{flex:auto;display:flex;flex-direction:column;align-items:flex-start;min-width:0;max-width:100%}.el-x-bubble-content-wrapper .el-x-bubble-header[data-v-716e941e],.el-x-bubble-content-wrapper .el-x-bubble-content[data-v-716e941e],.el-x-bubble-content-wrapper .el-x-bubble-footer[data-v-716e941e]{font-size:14px;color:#303133;line-height:24px}.el-x-bubble-content-wrapper .el-x-bubble-content[data-v-716e941e]{background-color:#edf2fc;padding:12px 18px;border-radius:8px;position:relative;box-sizing:border-box;min-width:0;max-width:var(--bubble-content-max-width);color:#303133;font-size:14px;line-height:24px;word-break:break-word}.el-x-bubble-content-wrapper .el-x-bubble-content .no-content[data-v-716e941e]{height:0}.el-x-bubble-content-wrapper .el-x-bubble-content-round[data-v-716e941e]{border-radius:20px}.el-x-bubble-content-wrapper .el-x-bubble-content-filled[data-v-716e941e]{background-color:#edf2fc}.el-x-bubble-content-wrapper .el-x-bubble-content-borderless[data-v-716e941e]{background-color:#edf2fc;border:1px solid #dcdfe6}.el-x-bubble-content-wrapper .el-x-bubble-content-outlined[data-v-716e941e]{background:none;border:1px solid #dcdfe6}.el-x-bubble-content-wrapper .el-x-bubble-content-shadow[data-v-716e941e]{background:none;box-shadow:0 2px 4px rgba(0,0,0,.12),0 0 6px rgba(0,0,0,.04)}.el-x-bubble-content-wrapper .el-x-bubble-content-loading[data-v-716e941e]{width:fit-content}.el-x-bubble-content-wrapper .el-x-bubble-content-loading .el-x-bubble-loading-wrap[data-v-716e941e]{display:flex;justify-content:center;align-items:center;gap:5px}.el-x-bubble-content-wrapper .el-x-bubble-content-loading .dot[data-v-716e941e]{width:5px;height:5px;background-color:#409eff;border-radius:50%;animation:wave-716e941e 1s infinite ease-in-out}@keyframes wave-716e941e{0%,100%{transform:translateY(-2px)}50%{transform:translateY(2px)}}.el-x-bubble-content-wrapper .el-x-bubble-footer[data-v-716e941e]{margin-top:8px}", ""]);
|
|
23651
23646
|
// Exports
|
|
23652
23647
|
/* harmony default export */ __webpack_exports__["a"] = (___CSS_LOADER_EXPORT___);
|
|
23653
23648
|
|
|
@@ -25649,7 +25644,7 @@ render._withStripped = true;
|
|
|
25649
25644
|
// CONCATENATED MODULE: ./src/components/Bubble/src/main.vue?vue&type=template&id=716e941e&scoped=true
|
|
25650
25645
|
|
|
25651
25646
|
// EXTERNAL MODULE: ./src/components/Typewriter/index.js + 7 modules
|
|
25652
|
-
var Typewriter = __webpack_require__(
|
|
25647
|
+
var Typewriter = __webpack_require__(12);
|
|
25653
25648
|
|
|
25654
25649
|
// CONCATENATED MODULE: ./node_modules/babel-loader/lib!./node_modules/vue-loader/lib??vue-loader-options!./src/components/Bubble/src/main.vue?vue&type=script&lang=js
|
|
25655
25650
|
|
|
@@ -25887,7 +25882,7 @@ var ParserCore = __webpack_require__(42);
|
|
|
25887
25882
|
var ParserBlock = __webpack_require__(50);
|
|
25888
25883
|
var ParserInline = __webpack_require__(64);
|
|
25889
25884
|
var LinkifyIt = __webpack_require__(77);
|
|
25890
|
-
var mdurl = __webpack_require__(
|
|
25885
|
+
var mdurl = __webpack_require__(14);
|
|
25891
25886
|
var punycode = __webpack_require__(79);
|
|
25892
25887
|
|
|
25893
25888
|
|
|
@@ -27057,11 +27052,11 @@ module.exports = urlParse;
|
|
|
27057
27052
|
"use strict";
|
|
27058
27053
|
|
|
27059
27054
|
|
|
27060
|
-
exports.Any = __webpack_require__(
|
|
27061
|
-
exports.Cc = __webpack_require__(
|
|
27055
|
+
exports.Any = __webpack_require__(15);
|
|
27056
|
+
exports.Cc = __webpack_require__(16);
|
|
27062
27057
|
exports.Cf = __webpack_require__(36);
|
|
27063
|
-
exports.P = __webpack_require__(
|
|
27064
|
-
exports.Z = __webpack_require__(
|
|
27058
|
+
exports.P = __webpack_require__(7);
|
|
27059
|
+
exports.Z = __webpack_require__(17);
|
|
27065
27060
|
|
|
27066
27061
|
|
|
27067
27062
|
/***/ }),
|
|
@@ -27652,7 +27647,7 @@ module.exports = Renderer;
|
|
|
27652
27647
|
|
|
27653
27648
|
|
|
27654
27649
|
|
|
27655
|
-
var Ruler = __webpack_require__(
|
|
27650
|
+
var Ruler = __webpack_require__(8);
|
|
27656
27651
|
|
|
27657
27652
|
|
|
27658
27653
|
var _rules = [
|
|
@@ -28245,7 +28240,7 @@ module.exports = function smartquotes(state) {
|
|
|
28245
28240
|
//
|
|
28246
28241
|
|
|
28247
28242
|
|
|
28248
|
-
var Token = __webpack_require__(
|
|
28243
|
+
var Token = __webpack_require__(9);
|
|
28249
28244
|
|
|
28250
28245
|
|
|
28251
28246
|
function StateCore(src, md, env) {
|
|
@@ -28276,7 +28271,7 @@ module.exports = StateCore;
|
|
|
28276
28271
|
|
|
28277
28272
|
|
|
28278
28273
|
|
|
28279
|
-
var Ruler = __webpack_require__(
|
|
28274
|
+
var Ruler = __webpack_require__(8);
|
|
28280
28275
|
|
|
28281
28276
|
|
|
28282
28277
|
var _rules = [
|
|
@@ -29696,7 +29691,7 @@ module.exports = function reference(state, startLine, _endLine, silent) {
|
|
|
29696
29691
|
|
|
29697
29692
|
|
|
29698
29693
|
var block_names = __webpack_require__(59);
|
|
29699
|
-
var HTML_OPEN_CLOSE_TAG_RE = __webpack_require__(
|
|
29694
|
+
var HTML_OPEN_CLOSE_TAG_RE = __webpack_require__(18).HTML_OPEN_CLOSE_TAG_RE;
|
|
29700
29695
|
|
|
29701
29696
|
// An array of opening and corresponding closing sequences for html tags,
|
|
29702
29697
|
// last argument defines whether it can terminate a paragraph or not
|
|
@@ -30063,7 +30058,7 @@ module.exports = function paragraph(state, startLine/*, endLine*/) {
|
|
|
30063
30058
|
|
|
30064
30059
|
|
|
30065
30060
|
|
|
30066
|
-
var Token = __webpack_require__(
|
|
30061
|
+
var Token = __webpack_require__(9);
|
|
30067
30062
|
var isSpace = __webpack_require__(1).isSpace;
|
|
30068
30063
|
|
|
30069
30064
|
|
|
@@ -30305,7 +30300,7 @@ module.exports = StateBlock;
|
|
|
30305
30300
|
|
|
30306
30301
|
|
|
30307
30302
|
|
|
30308
|
-
var Ruler = __webpack_require__(
|
|
30303
|
+
var Ruler = __webpack_require__(8);
|
|
30309
30304
|
|
|
30310
30305
|
|
|
30311
30306
|
////////////////////////////////////////////////////////////////////////////////
|
|
@@ -30316,8 +30311,8 @@ var _rules = [
|
|
|
30316
30311
|
[ 'newline', __webpack_require__(66) ],
|
|
30317
30312
|
[ 'escape', __webpack_require__(67) ],
|
|
30318
30313
|
[ 'backticks', __webpack_require__(68) ],
|
|
30319
|
-
[ 'strikethrough', __webpack_require__(
|
|
30320
|
-
[ 'emphasis', __webpack_require__(
|
|
30314
|
+
[ 'strikethrough', __webpack_require__(19).tokenize ],
|
|
30315
|
+
[ 'emphasis', __webpack_require__(20).tokenize ],
|
|
30321
30316
|
[ 'link', __webpack_require__(69) ],
|
|
30322
30317
|
[ 'image', __webpack_require__(70) ],
|
|
30323
30318
|
[ 'autolink', __webpack_require__(71) ],
|
|
@@ -30327,8 +30322,8 @@ var _rules = [
|
|
|
30327
30322
|
|
|
30328
30323
|
var _rules2 = [
|
|
30329
30324
|
[ 'balance_pairs', __webpack_require__(74) ],
|
|
30330
|
-
[ 'strikethrough', __webpack_require__(
|
|
30331
|
-
[ 'emphasis', __webpack_require__(
|
|
30325
|
+
[ 'strikethrough', __webpack_require__(19).postProcess ],
|
|
30326
|
+
[ 'emphasis', __webpack_require__(20).postProcess ],
|
|
30332
30327
|
[ 'text_collapse', __webpack_require__(75) ]
|
|
30333
30328
|
];
|
|
30334
30329
|
|
|
@@ -31161,7 +31156,7 @@ module.exports = function autolink(state, silent) {
|
|
|
31161
31156
|
|
|
31162
31157
|
|
|
31163
31158
|
|
|
31164
|
-
var HTML_TAG_RE = __webpack_require__(
|
|
31159
|
+
var HTML_TAG_RE = __webpack_require__(18).HTML_TAG_RE;
|
|
31165
31160
|
|
|
31166
31161
|
|
|
31167
31162
|
function isLetter(ch) {
|
|
@@ -31214,7 +31209,7 @@ module.exports = function html_inline(state, silent) {
|
|
|
31214
31209
|
|
|
31215
31210
|
|
|
31216
31211
|
|
|
31217
|
-
var entities = __webpack_require__(
|
|
31212
|
+
var entities = __webpack_require__(13);
|
|
31218
31213
|
var has = __webpack_require__(1).has;
|
|
31219
31214
|
var isValidEntityCode = __webpack_require__(1).isValidEntityCode;
|
|
31220
31215
|
var fromCodePoint = __webpack_require__(1).fromCodePoint;
|
|
@@ -31455,7 +31450,7 @@ module.exports = function text_collapse(state) {
|
|
|
31455
31450
|
|
|
31456
31451
|
|
|
31457
31452
|
|
|
31458
|
-
var Token = __webpack_require__(
|
|
31453
|
+
var Token = __webpack_require__(9);
|
|
31459
31454
|
var isWhiteSpace = __webpack_require__(1).isWhiteSpace;
|
|
31460
31455
|
var isPunctChar = __webpack_require__(1).isPunctChar;
|
|
31461
31456
|
var isMdAsciiPunct = __webpack_require__(1).isMdAsciiPunct;
|
|
@@ -32261,10 +32256,10 @@ module.exports = function (opts) {
|
|
|
32261
32256
|
var re = {};
|
|
32262
32257
|
|
|
32263
32258
|
// Use direct extract instead of `regenerate` to reduse browserified size
|
|
32264
|
-
re.src_Any = __webpack_require__(
|
|
32265
|
-
re.src_Cc = __webpack_require__(
|
|
32266
|
-
re.src_Z = __webpack_require__(
|
|
32267
|
-
re.src_P = __webpack_require__(
|
|
32259
|
+
re.src_Any = __webpack_require__(15).source;
|
|
32260
|
+
re.src_Cc = __webpack_require__(16).source;
|
|
32261
|
+
re.src_Z = __webpack_require__(17).source;
|
|
32262
|
+
re.src_P = __webpack_require__(7).source;
|
|
32268
32263
|
|
|
32269
32264
|
// \p{\Z\P\Cc\CF} (white spaces + control + format + punctuation)
|
|
32270
32265
|
re.src_ZPCc = [ re.src_Z, re.src_P, re.src_Cc ].join('|');
|
|
@@ -32961,7 +32956,7 @@ module.exports = function (opts) {
|
|
|
32961
32956
|
|
|
32962
32957
|
}(this));
|
|
32963
32958
|
|
|
32964
|
-
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(
|
|
32959
|
+
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(24)(module), __webpack_require__(11)))
|
|
32965
32960
|
|
|
32966
32961
|
/***/ }),
|
|
32967
32962
|
/* 80 */
|
|
@@ -33193,7 +33188,7 @@ module.exports = {
|
|
|
33193
33188
|
|
|
33194
33189
|
var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(function(i){return i[1]});
|
|
33195
33190
|
// Module
|
|
33196
|
-
___CSS_LOADER_EXPORT___.push([module.i, "[data-v-4f88f26a]:root{--color-primary: #409EFF;--color-success: #67C23A;--color-warning: #E6A23C;--color-danger: #F56C6C;--color-info: #909399}.card-motion-enter-active[data-v-4f88f26a],.card-motion-move[data-v-4f88f26a],.card-motion-leave-active[data-v-4f88f26a]{transition:all
|
|
33191
|
+
___CSS_LOADER_EXPORT___.push([module.i, "[data-v-4f88f26a]:root{--color-primary: #409EFF;--color-success: #67C23A;--color-warning: #E6A23C;--color-danger: #F56C6C;--color-info: #909399}.card-motion-enter-active[data-v-4f88f26a],.card-motion-move[data-v-4f88f26a],.card-motion-leave-active[data-v-4f88f26a]{transition:all .3s ease;opacity:1;transform:translateX(0)}.card-motion-enter[data-v-4f88f26a],.card-motion-leave-to[data-v-4f88f26a]{opacity:0;transform:translateX(-100%)}.card-motion-leave-active[data-v-4f88f26a]{transform:translateX(100%);opacity:0}.el-x-attachments-file-card-wrap[data-v-4f88f26a]{display:flex;height:100%;align-items:center}.el-x-attachments-upload-placeholder[data-v-4f88f26a]{display:inline-block;width:fit-content;align-self:center;margin:6px}.el-x-attachments-card[data-v-4f88f26a]{display:inline-block;vertical-align:top}.el-x-attachments-card-item[data-v-4f88f26a]{margin:6px}.el-x-attachments-prev-btn[data-v-4f88f26a],.el-x-attachments-next-btn[data-v-4f88f26a]{position:absolute;top:50%;transform:translateY(-50%);z-index:10;background-color:rgba(0,0,0,.3);color:#fff;border:none;padding:4px 0px;border-radius:3px;transition:background-color .3s ease}.el-x-attachments-prev-btn[data-v-4f88f26a]:hover,.el-x-attachments-next-btn[data-v-4f88f26a]:hover{background-color:rgba(0,0,0,.5)}.el-x-attachments-prev-btn[data-v-4f88f26a]:active,.el-x-attachments-next-btn[data-v-4f88f26a]:active{background-color:rgba(0,0,0,.7)}.el-x-attachments-prev-btn[data-v-4f88f26a]{left:8px;border-top-left-radius:0px;border-bottom-left-radius:0px}.el-x-attachments-next-btn[data-v-4f88f26a]{right:8px;border-top-right-radius:0px;border-bottom-right-radius:0px}.el-x-attachments-background[data-v-4f88f26a]{position:absolute;top:0;left:0;right:0;bottom:0;width:100%;pointer-events:none}.el-x-attachments-background-start[data-v-4f88f26a]{position:absolute;top:0;left:0;bottom:0;width:50px;background:linear-gradient(to right, rgba(255, 255, 255, 0.8), rgba(255, 255, 255, 0));z-index:5}.el-x-attachments-background-end[data-v-4f88f26a]{position:absolute;top:0;right:0;bottom:0;width:50px;background:linear-gradient(to left, rgba(255, 255, 255, 0.8), rgba(255, 255, 255, 0));z-index:5}.el-x-attachments-overflow-scrollX[data-v-4f88f26a]{height:100%;scrollbar-width:none}.el-x-attachments-overflow-scrollX[data-v-4f88f26a]::-webkit-scrollbar{display:none}.el-x-attachments-overflow-scrollY[data-v-4f88f26a]{width:100%;height:100%}.el-x-attachments-wrapper[data-v-4f88f26a]{position:relative;display:block}.el-x-attachments-upload-btn[data-v-4f88f26a]{display:flex}.el-x-attachments-upload-btn[data-v-4f88f26a] .el-upload{border:1px dashed #dcdfe6;border-radius:6px;cursor:pointer;position:relative;overflow:hidden;transition:all .3s cubic-bezier(0.645, 0.045, 0.355, 1);box-sizing:border-box;text-align:center}.el-x-attachments-upload-btn[data-v-4f88f26a] .el-upload:hover{border-color:#409eff}.el-x-attachments-upload-btn[data-v-4f88f26a] .el-upload:hover .uploader-icon{color:#409eff}.el-x-attachments-upload-btn .uploader-icon[data-v-4f88f26a]{font-size:28px;color:#8c939d;text-align:center;width:var(--el-x-attachments-upload-icon-size);height:var(--el-x-attachments-upload-icon-size);line-height:var(--el-x-attachments-upload-icon-size)}.el-x-attachments-upload-btn[data-v-4f88f26a] .el-upload-dragger{padding:0;width:auto !important;height:auto !important;background-color:rgba(0,0,0,0)}.el-x-attachments-upload-btn[data-v-4f88f26a] .el-upload-dragger:hover .el-icon{color:#409eff}.el-x-attachments-drop-area[data-v-4f88f26a]{position:absolute !important;top:0 !important;left:0 !important;width:calc(100% - 4px) !important;height:calc(100% - 4px) !important;border-radius:15px !important;border:2px dashed #409eff !important;z-index:9999 !important;display:flex !important;align-items:center !important;justify-content:center !important;flex-direction:column !important;background:rgba(225,225,225,.8) !important;backdrop-filter:blur(4px) !important;animation:dragAreaShow-4f88f26a .3s ease-in-out !important;pointer-events:none !important}.el-x-attachments-drop-area-icon[data-v-4f88f26a]{font-size:50px !important;color:#409eff !important;animation:bounce-4f88f26a 1s infinite alternate !important}.el-x-attachments-drop-area-text[data-v-4f88f26a]{font-size:16px !important;color:#409eff !important;margin-top:10px !important;text-align:center !important;width:100% !important;max-width:300px !important;font-weight:bold !important}@keyframes dragAreaShow-4f88f26a{from{opacity:0;transform:scale(0.9)}to{opacity:1;transform:scale(1)}}@keyframes bounce-4f88f26a{from{transform:translateY(0)}to{transform:translateY(-10px)}}", ""]);
|
|
33197
33192
|
// Exports
|
|
33198
33193
|
/* harmony default export */ __webpack_exports__["a"] = (___CSS_LOADER_EXPORT___);
|
|
33199
33194
|
|
|
@@ -33209,7 +33204,7 @@ ___CSS_LOADER_EXPORT___.push([module.i, "[data-v-4f88f26a]:root{--color-primary:
|
|
|
33209
33204
|
|
|
33210
33205
|
var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(function(i){return i[1]});
|
|
33211
33206
|
// Module
|
|
33212
|
-
___CSS_LOADER_EXPORT___.push([module.i, "[data-v-1c7b8442]:root{--color-primary: #409EFF;--color-success: #67C23A;--color-warning: #E6A23C;--color-danger: #F56C6C;--color-info: #909399}.el-x-bubble-list[data-v-1c7b8442]{display:flex;flex-direction:column;gap:16px;min-height:0;max-height:var(--el-x-bubble-list-max-height);overflow:auto;scroll-behavior:smooth;position:relative}.el-x-bubble-list[data-v-1c7b8442]::-webkit-scrollbar{width:6px;height:8px}.el-x-bubble-list[data-v-1c7b8442]::-webkit-scrollbar-thumb{background:
|
|
33207
|
+
___CSS_LOADER_EXPORT___.push([module.i, "[data-v-1c7b8442]:root{--color-primary: #409EFF;--color-success: #67C23A;--color-warning: #E6A23C;--color-danger: #F56C6C;--color-info: #909399}.el-x-bubble-list[data-v-1c7b8442]{display:flex;flex-direction:column;gap:16px;min-height:0;max-height:var(--el-x-bubble-list-max-height);overflow:auto;scroll-behavior:smooth;position:relative}.el-x-bubble-list[data-v-1c7b8442]::-webkit-scrollbar{width:6px;height:8px}.el-x-bubble-list[data-v-1c7b8442]::-webkit-scrollbar-thumb{background:rgba(0,0,0,0);background-color:rgba(0,0,0,.2);border-radius:10px;transition:background-color .2s ease-in-out}.el-x-bubble-list[data-v-1c7b8442]::-webkit-scrollbar-track{border-radius:10px;background:rgba(0,0,0,0)}.el-x-bubble-list[data-v-1c7b8442]:hover::-webkit-scrollbar-thumb{background:#c1c1c1}.el-x-bubble-list[data-v-1c7b8442]:hover::-webkit-scrollbar-thumb:hover{background:#a8a8a8}.el-x-bubble-list.always-scrollbar[data-v-1c7b8442]::-webkit-scrollbar-thumb{background:#c1c1c1}.el-x-bubble-list.always-scrollbar[data-v-1c7b8442]:hover::-webkit-scrollbar-thumb{background:#a8a8a8}@supports(scrollbar-color: auto){.el-x-bubble-list[data-v-1c7b8442]{scrollbar-color:rgba(0,0,0,0) rgba(0,0,0,0);scrollbar-width:thin}.el-x-bubble-list[data-v-1c7b8442]:hover{scrollbar-color:#c1c1c1 rgba(0,0,0,0)}.el-x-bubble-list.always-scrollbar[data-v-1c7b8442]{scrollbar-color:#c1c1c1 rgba(0,0,0,0)}}.el-x-bubble-list-default-back-button[data-v-1c7b8442]{position:sticky;user-select:none;cursor:pointer;width:40px;height:40px;padding:10px;box-sizing:border-box;display:flex;align-items:center;justify-content:center;background-color:#fff;border-radius:50%;box-shadow:0 0 4px 0 rgba(0,0,0,.02),0 6px 10px 0 rgba(47,53,64,.1);transition:all .3s ease;z-index:100}.el-x-bubble-list-default-back-button[data-v-1c7b8442]:hover{transform:translateY(-1px);box-shadow:0 4px 12px rgba(0,0,0,.15)}.el-x-bubble-list-default-back-button .el-x-bubble-list-back-to-bottom-icon[data-v-1c7b8442]{font-size:var(--el-x-bubble-list-btn-size);position:relative}.el-x-bubble-list-default-back-button .el-x-bubble-list-back-to-bottom-icon .back-to-bottom-loading-svg-bg[data-v-1c7b8442]{position:absolute;font-size:calc(var(--el-x-bubble-list-btn-size) + 26px);animation:is-loading-1c7b8442 1s infinite linear;width:40px;height:40px}@keyframes is-loading-1c7b8442{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}.el-x-bubble-list-default-back-button .back-to-bottom-loading-svg-bg[data-v-1c7b8442]{position:absolute;font-size:calc(var(--el-x-bubble-list-btn-size) + 26px);animation:is-loading-1c7b8442 1s infinite linear;width:40px;height:40px}@keyframes is-loading-1c7b8442{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}.el-x-bubble-list-back-to-bottom-solt[data-v-1c7b8442]{position:sticky;user-select:none;cursor:initial;width:fit-content;height:fit-content;padding:0;box-sizing:border-box;display:flex;align-items:center;justify-content:center;box-shadow:initial}.el-x-bubble-list-back-to-bottom-solt[data-v-1c7b8442]:hover{transform:translateY(0px);box-shadow:initial}", ""]);
|
|
33213
33208
|
// Exports
|
|
33214
33209
|
/* harmony default export */ __webpack_exports__["a"] = (___CSS_LOADER_EXPORT___);
|
|
33215
33210
|
|
|
@@ -33225,7 +33220,7 @@ ___CSS_LOADER_EXPORT___.push([module.i, "[data-v-1c7b8442]:root{--color-primary:
|
|
|
33225
33220
|
|
|
33226
33221
|
var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(function(i){return i[1]});
|
|
33227
33222
|
// Module
|
|
33228
|
-
___CSS_LOADER_EXPORT___.push([module.i, ".el-x-conversations-container{display:flex;flex-direction:column;height:100%;position:relative;width:fit-content;box-sizing:border-box;overflow:hidden;box-shadow:0 1px 3px rgba(0,0,0
|
|
33223
|
+
___CSS_LOADER_EXPORT___.push([module.i, ".el-x-conversations-container{display:flex;flex-direction:column;height:100%;position:relative;width:fit-content;box-sizing:border-box;overflow:hidden;box-shadow:0 1px 3px rgba(0,0,0,.1)}.el-x-conversations-list{list-style:none;margin:0;padding:0;flex:1;display:flex;flex-direction:column;box-sizing:border-box}.el-x-conversations-scroll-wrapper{flex:1;overflow:hidden;position:relative}.el-x-conversations-scroll-wrapper::after{content:\"\";position:absolute;top:0;right:0;width:8px;height:100%;background-color:rgba(0,0,0,0);pointer-events:none}.el-x-conversations-load-more{display:flex;width:calc(100% - 20px);padding:14px 10px;justify-content:center;align-items:center;font-size:12px;gap:3px;color:#909399;background-color:var(--conversation-list-auto-bg-color, #fff);margin-right:20px;border-radius:8px;height:auto;min-height:var(--conversation-label-height, 20px);box-sizing:border-box}.el-x-conversations-load-more-is-loading{margin-top:2px;animation:spinloading 2s linear infinite}@keyframes spinloading{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}.scroll-content{min-height:100%}.loading-more{text-align:center;padding:10px 0;color:#909399;font-size:14px}.el-x-conversation-group{position:relative}.el-x-conversation-group:last-child{margin-bottom:0}.el-x-conversation-group .el-x-conversation-group-title{font-size:14px;color:#909399;padding:8px 0;font-weight:500;margin-bottom:4px;border-radius:4px;border-top-left-radius:0px;border-top-right-radius:0px;width:calc(100% - 10px);box-sizing:border-box}.el-x-conversation-group .sticky-title{position:sticky;top:0;z-index:20;background-color:var(--conversation-list-auto-bg-color, #fff)}.el-x-conversation-group .active-sticky{z-index:10}.el-x-conversation-group .el-x-conversation-group-items{padding-top:0}.scroll-to-top-btn{position:absolute;right:16px;bottom:16px;z-index:99;opacity:.8;transition:opacity .3s}.scroll-to-top-btn:hover{opacity:1}.el-x-conversation-item{padding:14px 10px;margin-right:20px;border-radius:8px;cursor:pointer;transition:background-color .2s ease}.el-x-conversation-item+.el-x-conversation-item{margin-top:4px}.el-x-conversation-item.disabled{opacity:.5;cursor:not-allowed;color:#c0c4cc}.el-x-conversation-item.active{background-color:#f0f0f0}.el-x-conversation-item.hovered,.el-x-conversation-item:hover{background-color:#f0f0f0}.el-x-conversation-item.menu-opened{background-color:#f0f0f0}.el-x-conversation-content{display:flex;align-items:center;height:var(--conversation-label-height, 20px)}.el-x-conversation-content .el-x-conversation-prefix-icon{margin-right:8px;display:flex;justify-content:center;align-items:center}.el-x-conversation-content .el-x-conversation-content-main{flex:1;display:flex;align-items:center;position:relative;overflow:hidden}.el-x-conversation-content .el-x-conversation-label-container{flex:1;display:flex;justify-content:space-between;align-items:center;overflow:hidden}.el-x-conversation-content .el-x-conversation-label{font-size:14px;color:#303133;position:relative;white-space:nowrap}.el-x-conversation-content .el-x-conversation-label.text-gradient{mask-image:linear-gradient(to right, black 60%, transparent 100%);-webkit-mask-image:linear-gradient(to right, black 60%, transparent 100%)}.el-x-conversation-content .el-x-conversation-timestamp{font-size:14px;color:#909399;margin-left:8px}.el-x-conversation-content .el-x-conversation-suffix-icon{margin-left:8px;display:flex;justify-content:center;align-items:center}.el-x-conversation-content .el-x-conversation-dropdown-more{justify-self:center;height:100%;display:flex;align-items:center}.el-x-conversation-content .el-x-conversation-dropdown-more-icon{font-size:16px;padding:2px;border-radius:5px}.el-x-conversation-content .el-x-conversation-dropdown-more-icon:hover{background-color:#d3d3d3}.el-x-conversation-content .el-x-conversation-menu{margin-left:8px;display:flex;align-items:center;opacity:0;transition:opacity .2s ease}.hovered .el-x-conversation-content .el-x-conversation-menu,.active .el-x-conversation-content .el-x-conversation-menu{opacity:1}.el-x-conversation-dropdown-menu{max-height:300px;overflow-y:auto}.el-x-conversations-scrollbar{height:100%;overflow-y:auto}.el-x-conversations-scrollbar::-webkit-scrollbar{width:6px}.el-x-conversations-scrollbar::-webkit-scrollbar-thumb{background-color:rgba(0,0,0,0);border-radius:3px;transition:background-color .3s ease}.el-x-conversations-scrollbar::-webkit-scrollbar-track{background-color:rgba(0,0,0,0)}.el-x-conversations-scrollbar:hover::-webkit-scrollbar-thumb{background-color:#e0e0e0}@supports(scrollbar-width: thin){.el-x-conversations-scrollbar{scrollbar-width:thin;scrollbar-color:rgba(0,0,0,0) rgba(0,0,0,0)}.el-x-conversations-scrollbar:hover{scrollbar-color:#e0e0e0 rgba(0,0,0,0)}}", ""]);
|
|
33229
33224
|
// Exports
|
|
33230
33225
|
/* harmony default export */ __webpack_exports__["a"] = (___CSS_LOADER_EXPORT___);
|
|
33231
33226
|
|
|
@@ -33241,7 +33236,7 @@ ___CSS_LOADER_EXPORT___.push([module.i, ".el-x-conversations-container{display:f
|
|
|
33241
33236
|
|
|
33242
33237
|
var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(function(i){return i[1]});
|
|
33243
33238
|
// Module
|
|
33244
|
-
___CSS_LOADER_EXPORT___.push([module.i, "[data-v-ee2290d4]:root{--color-primary: #409EFF;--color-success: #67C23A;--color-warning: #E6A23C;--color-danger: #F56C6C;--color-info: #909399}.el-x-prompts[data-v-ee2290d4]{max-width:100%}.el-x-prompts[data-v-ee2290d4],.el-x-prompts *[data-v-ee2290d4]{box-sizing:border-box}.el-x-prompts.el-x-prompts-rtl[data-v-ee2290d4]{direction:rtl}.el-x-prompts .el-x-prompts-title[data-v-ee2290d4]{font-weight:normal;font-size:16px;color:#909399;margin-top:0;margin-bottom
|
|
33239
|
+
___CSS_LOADER_EXPORT___.push([module.i, "[data-v-ee2290d4]:root{--color-primary: #409EFF;--color-success: #67C23A;--color-warning: #E6A23C;--color-danger: #F56C6C;--color-info: #909399}.el-x-prompts[data-v-ee2290d4]{max-width:100%}.el-x-prompts[data-v-ee2290d4],.el-x-prompts *[data-v-ee2290d4]{box-sizing:border-box}.el-x-prompts.el-x-prompts-rtl[data-v-ee2290d4]{direction:rtl}.el-x-prompts .el-x-prompts-title[data-v-ee2290d4]{font-weight:normal;font-size:16px;color:#909399;margin-top:0;margin-bottom:.5em}.el-x-prompts .el-x-prompts-list[data-v-ee2290d4]{display:flex;gap:8px;overflow-x:auto;scrollbar-width:none;-ms-overflow-style:none;list-style:none;padding-left:0;margin:0;align-items:stretch}.el-x-prompts .el-x-prompts-list[data-v-ee2290d4]::-webkit-scrollbar{display:none}.el-x-prompts .el-x-prompts-list-wrap[data-v-ee2290d4]{flex-wrap:wrap}.el-x-prompts .el-x-prompts-list-vertical[data-v-ee2290d4]{flex-direction:column;align-items:flex-start}@media screen and (max-width: 768px){.el-x-prompts .el-x-prompts-list[data-v-ee2290d4]{flex-wrap:wrap;gap:8px}.el-x-prompts .el-x-prompts-list-wrap[data-v-ee2290d4]{justify-content:space-between}}.el-x-prompts .el-x-prompts-item[data-v-ee2290d4]{flex:none;display:flex;gap:4px;height:auto;padding:12px 18px;align-items:flex-start;justify-content:flex-start;background:#fff;border-radius:8px;transition:border all .3s cubic-bezier(0.645, 0.045, 0.355, 1),background all .3s cubic-bezier(0.645, 0.045, 0.355, 1);border:1px solid #ebeef5}@media screen and (max-width: 768px){.el-x-prompts .el-x-prompts-item[data-v-ee2290d4]{width:calc(50% - 4px);min-width:150px;padding:8px 12px}.el-x-prompts-list-wrap .el-x-prompts .el-x-prompts-item[data-v-ee2290d4]{width:calc(50% - 4px);margin-bottom:8px}.el-x-prompts-list-vertical .el-x-prompts .el-x-prompts-item[data-v-ee2290d4]{width:100%}}.el-x-prompts .el-x-prompts-item[data-v-ee2290d4]:not(.el-x-prompts-item-has-nest):hover{cursor:pointer;background:#f5f7fa}.el-x-prompts .el-x-prompts-item[data-v-ee2290d4]:not(.el-x-prompts-item-has-nest):active{background:rgb(235.9,245.3,255)}.el-x-prompts .el-x-prompts-item .el-x-prompts-content[data-v-ee2290d4]{flex:auto;min-width:0;display:flex;gap:4px;flex-direction:column;align-items:flex-start}@media screen and (max-width: 768px){.el-x-prompts .el-x-prompts-item .el-x-prompts-content[data-v-ee2290d4]{width:100%;gap:2px}}.el-x-prompts .el-x-prompts-item .el-x-prompts-icon[data-v-ee2290d4],.el-x-prompts .el-x-prompts-item .el-x-prompts-label[data-v-ee2290d4],.el-x-prompts .el-x-prompts-item .el-x-prompts-desc[data-v-ee2290d4]{margin:0;padding:0;font-size:14px;line-height:24px;text-align:start;white-space:normal}@media screen and (max-width: 768px){.el-x-prompts .el-x-prompts-item .el-x-prompts-icon[data-v-ee2290d4],.el-x-prompts .el-x-prompts-item .el-x-prompts-label[data-v-ee2290d4],.el-x-prompts .el-x-prompts-item .el-x-prompts-desc[data-v-ee2290d4]{font-size:14px;line-height:1.4;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}}.el-x-prompts .el-x-prompts-item .el-x-prompts-label[data-v-ee2290d4]{color:#303133;font-weight:500}.el-x-prompts .el-x-prompts-item .el-x-prompts-label+.el-x-prompts-desc[data-v-ee2290d4]{color:#909399}.el-x-prompts .el-x-prompts-item.el-x-prompts-item-disabled[data-v-ee2290d4]{pointer-events:none;background:#f5f7fa}.el-x-prompts .el-x-prompts-item.el-x-prompts-item-disabled .el-x-prompts-label[data-v-ee2290d4],.el-x-prompts .el-x-prompts-item.el-x-prompts-item-disabled .el-x-prompts-desc[data-v-ee2290d4]{color:#909399}.el-x-prompts .el-x-prompts-item-has-nest>.el-x-prompts-content>.el-x-prompts-label[data-v-ee2290d4]{font-size:18px;line-height:24px}.el-x-prompts.el-x-prompts-nested[data-v-ee2290d4]{margin-top:5px;align-self:stretch}.el-x-prompts.el-x-prompts-nested .el-x-prompts-list[data-v-ee2290d4]{align-items:stretch}.el-x-prompts.el-x-prompts-nested .el-x-prompts-item[data-v-ee2290d4]{border:0;background:#f5f7fa}", ""]);
|
|
33245
33240
|
// Exports
|
|
33246
33241
|
/* harmony default export */ __webpack_exports__["a"] = (___CSS_LOADER_EXPORT___);
|
|
33247
33242
|
|
|
@@ -33257,7 +33252,7 @@ ___CSS_LOADER_EXPORT___.push([module.i, "[data-v-ee2290d4]:root{--color-primary:
|
|
|
33257
33252
|
|
|
33258
33253
|
var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(function(i){return i[1]});
|
|
33259
33254
|
// Module
|
|
33260
|
-
___CSS_LOADER_EXPORT___.push([module.i, ".el-x-send-button .el-button .el-icon-brush[data-v-74c70621]{transform:rotate(180deg)}
|
|
33255
|
+
___CSS_LOADER_EXPORT___.push([module.i, ".el-x-send-button .el-button .el-icon-brush[data-v-74c70621]{transform:rotate(180deg)}", ""]);
|
|
33261
33256
|
// Exports
|
|
33262
33257
|
/* harmony default export */ __webpack_exports__["a"] = (___CSS_LOADER_EXPORT___);
|
|
33263
33258
|
|
|
@@ -33273,7 +33268,7 @@ ___CSS_LOADER_EXPORT___.push([module.i, ".el-x-send-button .el-button .el-icon-b
|
|
|
33273
33268
|
|
|
33274
33269
|
var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(function(i){return i[1]});
|
|
33275
33270
|
// Module
|
|
33276
|
-
___CSS_LOADER_EXPORT___.push([module.i, ".el-x-send-button[data-v-4d4a8cac]{height:32px}.el-x-send-button .el-button[data-v-4d4a8cac]{padding:0;width:32px;height:32px}.el-x-send-button .loading-svg[data-v-4d4a8cac]{color:#
|
|
33271
|
+
___CSS_LOADER_EXPORT___.push([module.i, ".el-x-send-button[data-v-4d4a8cac]{height:32px}.el-x-send-button .el-button[data-v-4d4a8cac]{padding:0;width:32px;height:32px}.el-x-send-button .loading-svg[data-v-4d4a8cac]{color:#409eff;width:100%}", ""]);
|
|
33277
33272
|
// Exports
|
|
33278
33273
|
/* harmony default export */ __webpack_exports__["a"] = (___CSS_LOADER_EXPORT___);
|
|
33279
33274
|
|
|
@@ -33289,7 +33284,7 @@ ___CSS_LOADER_EXPORT___.push([module.i, ".el-x-send-button[data-v-4d4a8cac]{heig
|
|
|
33289
33284
|
|
|
33290
33285
|
var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(function(i){return i[1]});
|
|
33291
33286
|
// Module
|
|
33292
|
-
___CSS_LOADER_EXPORT___.push([module.i, ".el-x-send-button .el-button[data-v-1d4ab0c1]{padding:0;width:32px;height:32px}.el-x-send-button .loading-svg[data-v-1d4ab0c1]{color:#
|
|
33287
|
+
___CSS_LOADER_EXPORT___.push([module.i, ".el-x-send-button .el-button[data-v-1d4ab0c1]{padding:0;width:32px;height:32px}.el-x-send-button .loading-svg[data-v-1d4ab0c1]{color:#409eff;width:16px}", ""]);
|
|
33293
33288
|
// Exports
|
|
33294
33289
|
/* harmony default export */ __webpack_exports__["a"] = (___CSS_LOADER_EXPORT___);
|
|
33295
33290
|
|
|
@@ -33305,7 +33300,7 @@ ___CSS_LOADER_EXPORT___.push([module.i, ".el-x-send-button .el-button[data-v-1d4
|
|
|
33305
33300
|
|
|
33306
33301
|
var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(function(i){return i[1]});
|
|
33307
33302
|
// Module
|
|
33308
|
-
___CSS_LOADER_EXPORT___.push([module.i, "[data-v-34a8749b]:root{--color-primary: #409EFF;--color-success: #67C23A;--color-warning: #E6A23C;--color-danger: #F56C6C;--color-info: #909399}[data-v-34a8749b]:root{--el-x-sender-trigger-popover-width: fit-content;--el-x-sender-trigger-popover-left: 0px}.el-x-sender[data-v-34a8749b]{width:100%;display:flex;flex-direction:column;position:relative;box-sizing:border-box;box-shadow:0 1px 2px 0 rgba(0,0,0
|
|
33303
|
+
___CSS_LOADER_EXPORT___.push([module.i, "[data-v-34a8749b]:root{--color-primary: #409EFF;--color-success: #67C23A;--color-warning: #E6A23C;--color-danger: #F56C6C;--color-info: #909399}[data-v-34a8749b]:root{--el-x-sender-trigger-popover-width: fit-content;--el-x-sender-trigger-popover-left: 0px}.el-x-sender[data-v-34a8749b]{width:100%;display:flex;flex-direction:column;position:relative;box-sizing:border-box;box-shadow:0 1px 2px 0 rgba(0,0,0,.03),0 1px 6px -1px rgba(0,0,0,.02),0 2px 4px 0 rgba(0,0,0,.02);transition:background .3s;border-radius:calc(4px*2);border-color:#dcdfe6;border-width:0;border-style:solid;transition:width 300ms}.el-x-sender[data-v-34a8749b]:after{content:\"\";position:absolute;inset:0;pointer-events:none;transition:border-color .3s;border-radius:inherit;border-style:inherit;border-color:inherit;border-width:1px}.el-x-sender[data-v-34a8749b]:focus-within{box-shadow:0 2px 4px rgba(0,0,0,.12),0 0 6px rgba(0,0,0,.04);border-color:#409eff}.el-x-sender[data-v-34a8749b]:focus-within::after{border-width:2px}.el-x-sender .el-x-sender-header-wrap[data-v-34a8749b]{display:flex;flex-direction:column;gap:8px;width:100%;margin:0;padding:0}.el-x-sender .slide-enter-active[data-v-34a8749b],.el-x-sender .slide-leave-active[data-v-34a8749b]{transition:height 300ms,opacity 300ms,border 300ms;overflow:hidden}.el-x-sender .slide-enter[data-v-34a8749b],.el-x-sender .slide-leave-to[data-v-34a8749b]{height:0;opacity:0}.el-x-sender .el-x-sender-header[data-v-34a8749b]{border-bottom-width:1px;border-bottom-style:solid;border-bottom-color:#dcdfe6}.el-x-sender .el-x-sender-content[data-v-34a8749b]{display:flex;gap:8px;width:100%;padding-block:12px;padding-inline-start:16px;padding-inline-end:12px;box-sizing:border-box;align-items:flex-end}.el-x-sender .el-x-sender-content .el-x-sender-prefix[data-v-34a8749b]{flex:none}.el-x-sender .el-x-sender-content .el-x-sender-input[data-v-34a8749b]{height:100%;display:flex;align-items:center;align-self:center}.el-x-sender .el-x-sender-content .el-x-sender-input[data-v-34a8749b] .el-textarea__inner{padding:0;margin:0;color:#303133;font-size:14px;line-height:24px;list-style:none;position:relative;display:inline-block;box-sizing:border-box;width:100%;min-width:0;max-width:100%;height:auto;min-height:auto !important;border-radius:0;border:none;flex:auto;align-self:center;vertical-align:bottom;resize:none;background-color:rgba(0,0,0,0);transition:all .3s,height 0s;box-shadow:none !important}.el-x-sender .el-x-sender-content .el-x-sender-action-list-presets[data-v-34a8749b]{display:flex;gap:8px;flex-direction:row-reverse}.el-x-sender .content-variant-updown[data-v-34a8749b]{display:flex;flex-direction:column;align-items:initial}.el-x-sender .content-variant-updown .el-x-sender-updown-wrap[data-v-34a8749b]{display:flex;justify-content:space-between;gap:8px}.el-x-sender .content-variant-updown .el-x-sender-updown-wrap .el-x-sender-prefix[data-v-34a8749b]{flex:initial}.el-x-sender .content-variant-updown .el-x-sender-updown-wrap .el-x-sender-action-list[data-v-34a8749b]{margin-left:auto}.el-x-sender .el-x-sender-footer[data-v-34a8749b]{border-top-width:1px;border-top-style:solid;border-top-color:#dcdfe6}.el-x-sender-disabled[data-v-34a8749b]{background-color:#f5f7fa;pointer-events:none}.el-x-sender-trigger-popover[data-v-34a8749b]{width:fit-content !important;margin-left:0px !important;max-width:calc(100% - 54px) !important;width:var(--el-x-sender-trigger-popover-width) !important;margin-left:var(--el-x-sender-trigger-popover-left) !important}", ""]);
|
|
33309
33304
|
// Exports
|
|
33310
33305
|
/* harmony default export */ __webpack_exports__["a"] = (___CSS_LOADER_EXPORT___);
|
|
33311
33306
|
|
|
@@ -33321,7 +33316,7 @@ ___CSS_LOADER_EXPORT___.push([module.i, "[data-v-34a8749b]:root{--color-primary:
|
|
|
33321
33316
|
|
|
33322
33317
|
var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(function(i){return i[1]});
|
|
33323
33318
|
// Module
|
|
33324
|
-
___CSS_LOADER_EXPORT___.push([module.i, ":root{--color-primary: #409EFF;--color-success: #67C23A;--color-warning: #E6A23C;--color-danger: #F56C6C;--color-info: #909399}.el-x-think{font-family:system-ui,
|
|
33319
|
+
___CSS_LOADER_EXPORT___.push([module.i, ":root{--color-primary: #409EFF;--color-success: #67C23A;--color-warning: #E6A23C;--color-danger: #F56C6C;--color-info: #909399}.el-x-think{font-family:system-ui,sans-serif;margin:0 auto}.el-x-think .trigger{display:flex;align-items:center;height:100%;width:var(--el-x-think-button-width);gap:8px;padding:8px 12px;border:1px solid #dcdfe6;border-radius:8px;background:#fff;cursor:pointer;margin-bottom:8px}.el-x-think .trigger .el-icon-center{height:100%;display:flex;align-items:center}.el-x-think .trigger .start-color{color:#e6a23c}.el-x-think .trigger .end-color{color:#67c23a}.el-x-think .trigger .is-loading{color:#409eff}.el-x-think .trigger .error-color{color:#f56c6c}.el-x-think .trigger:hover{background:#f8f8f8}.el-x-think .trigger.disabled{cursor:pointer}.el-x-think .trigger:disabled{cursor:not-allowed;opacity:.7}.el-x-think .status-icon{font-size:1.2em}.el-x-think .arrow{margin-left:auto;transition:transform var(--el-x-think-animation-duration)}.el-x-think .arrow.expanded{transform:rotate(180deg)}.el-x-think .slide-enter-active,.el-x-think .slide-leave-active{transition:height var(--el-x-think-animation-duration) ease-in-out,opacity var(--el-x-think-animation-duration) ease-in-out;overflow:hidden}.el-x-think .slide-enter,.el-x-think .slide-leave-to{height:0 !important;opacity:0}.el-x-think .content-wrapper{box-sizing:border-box;min-width:0}.el-x-think .content-wrapper.error-state{border-color:#ffd0d0;background:#fff0f0}.el-x-think .content pre{border:1px solid #dcdfe6;background:var(--el-x-think-content-wrapper-background-color);padding:8px 12px;border-radius:8px;max-width:var(--el-x-think-content-wrapper-width);font-size:14px;color:var(--el-x-think-content-wrapper-color);white-space:pre-wrap;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,sans-serif;margin:0;line-height:24px}.el-x-think .error-message{color:#f56c6c;height:fit-content;padding:8px;background:#ffeef0;border-radius:4px}.el-x-think .rotate-enter-active,.el-x-think .rotate-leave-active{transition:transform var(--el-x-think-animation-duration)}.el-x-think .rotate-enter,.el-x-think .rotate-leave-to{transform:rotate(0deg)}", ""]);
|
|
33325
33320
|
// Exports
|
|
33326
33321
|
/* harmony default export */ __webpack_exports__["a"] = (___CSS_LOADER_EXPORT___);
|
|
33327
33322
|
|
|
@@ -33337,7 +33332,7 @@ ___CSS_LOADER_EXPORT___.push([module.i, ":root{--color-primary: #409EFF;--color-
|
|
|
33337
33332
|
|
|
33338
33333
|
var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(function(i){return i[1]});
|
|
33339
33334
|
// Module
|
|
33340
|
-
___CSS_LOADER_EXPORT___.push([module.i, "[data-v-
|
|
33335
|
+
___CSS_LOADER_EXPORT___.push([module.i, "[data-v-673c6702]:root{--color-primary: #409EFF;--color-success: #67C23A;--color-warning: #E6A23C;--color-danger: #F56C6C;--color-info: #909399}.el-x-thinking[data-v-673c6702]{margin:0 auto}.trigger[data-v-673c6702]{display:flex;align-items:center;height:100%;width:var(--el-x-thinking-button-width);gap:4px;padding:8px 12px;border:1px solid #dcdfe6;border-radius:8px;background:#fff;cursor:pointer;margin-bottom:4px}.trigger .el-icon-center[data-v-673c6702]{height:100%;display:flex;align-items:center}.trigger .start-color[data-v-673c6702]{color:#e6a23c}.trigger .end-color[data-v-673c6702]{color:#67c23a}.trigger .is-loading[data-v-673c6702]{color:#409eff}.trigger .error-color[data-v-673c6702]{color:#f56c6c}.trigger[data-v-673c6702]:hover{background:#f5f7fa}.trigger.disabled[data-v-673c6702]{cursor:pointer}.trigger[data-v-673c6702]:disabled{cursor:not-allowed;opacity:.7}.status-icon[data-v-673c6702]{font-size:16px}.thinking-arrow[data-v-673c6702]{margin-left:auto;transition:transform var(--el-x-thinking-animation-duration)}.thinking-arrow.expanded[data-v-673c6702]{transform:rotate(180deg)}.slide-enter-active[data-v-673c6702],.slide-leave-active[data-v-673c6702]{height:max-content;transition:height var(--el-x-thinking-animation-duration) ease-in-out,opacity var(--el-x-thinking-animation-duration) ease-in-out;overflow:hidden}.slide-enter-from[data-v-673c6702],.slide-leave-to[data-v-673c6702]{height:0 !important;opacity:0}.content-wrapper[data-v-673c6702]{box-sizing:border-box;min-width:0}.content pre[data-v-673c6702]{border:1px solid #dcdfe6;background:var(--el-x-thinking-content-wrapper-background-color);padding:8px 12px;border-radius:8px;max-width:var(--el-x-thinking-content-wrapper-width);font-size:14px;color:var(--el-x-thinking-content-wrapper-color);white-space:pre-wrap;margin:0;line-height:24px}.error-state[data-v-673c6702]{border-color:rgb(254,240.3,240.3);background:rgb(254,240.3,240.3)}.error-message[data-v-673c6702]{color:#f56c6c;height:fit-content;padding:4px;background:rgb(254,240.3,240.3);border-radius:8px}", ""]);
|
|
33341
33336
|
// Exports
|
|
33342
33337
|
/* harmony default export */ __webpack_exports__["a"] = (___CSS_LOADER_EXPORT___);
|
|
33343
33338
|
|
|
@@ -33353,7 +33348,7 @@ ___CSS_LOADER_EXPORT___.push([module.i, "[data-v-6fb5dcd7]:root{--color-primary:
|
|
|
33353
33348
|
|
|
33354
33349
|
var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(function(i){return i[1]});
|
|
33355
33350
|
// Module
|
|
33356
|
-
___CSS_LOADER_EXPORT___.push([module.i, "[data-v-49e41fca]:root{--color-primary: #409EFF;--color-success: #67C23A;--color-warning: #E6A23C;--color-danger: #F56C6C;--color-info: #909399}.el-x-thoughtchain-item-dot[data-v-49e41fca]{display:flex;justify-content:center;align-items:center}.el-x-thoughtchain-item-dot .el-button[data-v-49e41fca]{cursor:default !important}.el-x-thoughtchain .el-collapse[data-v-49e41fca]{border:none}.el-x-thoughtchain .el-collapse .el-collapse-item__header[data-v-49e41fca]{height:20px;font-weight:normal}.el-x-thoughtchain .el-collapse .el-collapse-item__arrow[data-v-49e41fca]{margin:0 0 0 8px}.el-x-thoughtchain .el-collapse .el-collapse-item__header[data-v-49e41fca]{margin-bottom:5px}.el-x-thoughtchain .el-collapse .el-collapse-item__header[data-v-49e41fca],.el-x-thoughtchain .el-collapse .el-collapse-item__wrap[data-v-49e41fca]{border:none}.el-x-thoughtchain .el-collapse .el-collapse-item__content[data-v-49e41fca]{color:#909399;padding:0}.el-x-thoughtchain .el-timeline[data-v-49e41fca]{padding:10px 0 0 5px}.el-x-thoughtchain .el-timeline-item__timestamp[data-v-49e41fca]{color:#303133}.el-x-thoughtchain .el-timeline-item__content[data-v-49e41fca]{color:#909399}.el-x-thoughtchain .el-timeline-item[data-v-49e41fca]{list-style:none !important}.thought-chain-move[data-v-49e41fca],.thought-chain-enter-active[data-v-49e41fca],.thought-chain-leave-active[data-v-49e41fca]{transition:all
|
|
33351
|
+
___CSS_LOADER_EXPORT___.push([module.i, "[data-v-49e41fca]:root{--color-primary: #409EFF;--color-success: #67C23A;--color-warning: #E6A23C;--color-danger: #F56C6C;--color-info: #909399}.el-x-thoughtchain-item-dot[data-v-49e41fca]{display:flex;justify-content:center;align-items:center}.el-x-thoughtchain-item-dot .el-button[data-v-49e41fca]{cursor:default !important}.el-x-thoughtchain .el-collapse[data-v-49e41fca]{border:none}.el-x-thoughtchain .el-collapse .el-collapse-item__header[data-v-49e41fca]{height:20px;font-weight:normal}.el-x-thoughtchain .el-collapse .el-collapse-item__arrow[data-v-49e41fca]{margin:0 0 0 8px}.el-x-thoughtchain .el-collapse .el-collapse-item__header[data-v-49e41fca]{margin-bottom:5px}.el-x-thoughtchain .el-collapse .el-collapse-item__header[data-v-49e41fca],.el-x-thoughtchain .el-collapse .el-collapse-item__wrap[data-v-49e41fca]{border:none}.el-x-thoughtchain .el-collapse .el-collapse-item__content[data-v-49e41fca]{color:#909399;padding:0}.el-x-thoughtchain .el-timeline[data-v-49e41fca]{padding:10px 0 0 5px}.el-x-thoughtchain .el-timeline-item__timestamp[data-v-49e41fca]{color:#303133}.el-x-thoughtchain .el-timeline-item__content[data-v-49e41fca]{color:#909399}.el-x-thoughtchain .el-timeline-item[data-v-49e41fca]{list-style:none !important}.thought-chain-move[data-v-49e41fca],.thought-chain-enter-active[data-v-49e41fca],.thought-chain-leave-active[data-v-49e41fca]{transition:all .5s ease}.thought-chain-enter[data-v-49e41fca],.thought-chain-leave-to[data-v-49e41fca]{opacity:0;transform:translateY(10px) scaleY(0.9)}.thought-chain-leave-active[data-v-49e41fca]{position:absolute}.el-x-thoughtchain-loading[data-v-49e41fca]{animation:thoughtchain-rotating-49e41fca 1.5s linear infinite;transform-origin:center center;will-change:transform;backface-visibility:hidden;-webkit-font-smoothing:antialiased}@keyframes thoughtchain-rotating-49e41fca{0%{transform:rotate(0deg)}25%{transform:rotate(90deg)}50%{transform:rotate(180deg)}75%{transform:rotate(270deg)}100%{transform:rotate(360deg)}}", ""]);
|
|
33357
33352
|
// Exports
|
|
33358
33353
|
/* harmony default export */ __webpack_exports__["a"] = (___CSS_LOADER_EXPORT___);
|
|
33359
33354
|
|
|
@@ -33369,7 +33364,7 @@ ___CSS_LOADER_EXPORT___.push([module.i, "[data-v-49e41fca]:root{--color-primary:
|
|
|
33369
33364
|
|
|
33370
33365
|
var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_0___default()(function(i){return i[1]});
|
|
33371
33366
|
// Module
|
|
33372
|
-
___CSS_LOADER_EXPORT___.push([module.i, "[data-v-68cfb339]:root{--color-primary: #409EFF;--color-success: #67C23A;--color-warning: #E6A23C;--color-danger: #F56C6C;--color-info: #909399}.el-x-welcome[data-v-68cfb339]{--border-radius: 4px;--icon-size: 64px;--icon-size-small: 48px;--icon-size-mobile: 40px;--gap: 16px;--gap-small: 8px;--gap-mobile: 12px;--gap-small-mobile: 6px;--padding: 24px;--padding-mobile: 16px;--title-font-size: 16px;--title-font-size-mobile: 14px;--description-font-size: 14px;--description-font-size-mobile: 13px;--color-filled-bg: #e6f4ff;--color-filled-border: #91caff;--color-title: #303133;--color-description: #606266;display:flex;gap:var(--gap);padding:var(--padding);border-radius:var(--border-radius)}.el-x-welcome.el-x-welcome-filled[data-v-68cfb339]{background-color:var(--color-filled-bg);border:1px solid var(--color-filled-border)}.el-x-welcome.el-x-welcome-borderless[data-v-68cfb339]{border:none}.el-x-welcome.el-x-welcome-rtl[data-v-68cfb339]{direction:rtl}@media
|
|
33367
|
+
___CSS_LOADER_EXPORT___.push([module.i, "[data-v-68cfb339]:root{--color-primary: #409EFF;--color-success: #67C23A;--color-warning: #E6A23C;--color-danger: #F56C6C;--color-info: #909399}.el-x-welcome[data-v-68cfb339]{--border-radius: 4px;--icon-size: 64px;--icon-size-small: 48px;--icon-size-mobile: 40px;--gap: 16px;--gap-small: 8px;--gap-mobile: 12px;--gap-small-mobile: 6px;--padding: 24px;--padding-mobile: 16px;--title-font-size: 16px;--title-font-size-mobile: 14px;--description-font-size: 14px;--description-font-size-mobile: 13px;--color-filled-bg: #e6f4ff;--color-filled-border: #91caff;--color-title: #303133;--color-description: #606266;display:flex;gap:var(--gap);padding:var(--padding);border-radius:var(--border-radius)}.el-x-welcome.el-x-welcome-filled[data-v-68cfb339]{background-color:var(--color-filled-bg);border:1px solid var(--color-filled-border)}.el-x-welcome.el-x-welcome-borderless[data-v-68cfb339]{border:none}.el-x-welcome.el-x-welcome-rtl[data-v-68cfb339]{direction:rtl}@media(max-width: 768px){.el-x-welcome[data-v-68cfb339]{--gap: var(--gap-mobile);--gap-small: var(--gap-small-mobile);--padding: var(--padding-mobile);--title-font-size: var(--title-font-size-mobile);--description-font-size: var(--description-font-size-mobile);gap:var(--gap-mobile);padding:var(--padding-mobile)}}@media(max-width: 480px){.el-x-welcome[data-v-68cfb339]{--icon-size: var(--icon-size-mobile);--padding: 12px;--gap: 8px;--gap-small: 4px;flex-direction:column;align-items:center;text-align:center;padding:12px;gap:8px}.el-x-welcome.el-x-welcome-rtl[data-v-68cfb339]{direction:ltr}}@media(max-width: 320px){.el-x-welcome[data-v-68cfb339]{--padding: 8px;--gap: 6px;--icon-size: 32px;padding:8px;gap:6px}}.el-x-welcome-icon[data-v-68cfb339]{flex:0 0 auto;width:var(--icon-size);height:var(--icon-size);display:flex;align-items:center;justify-content:center;border-radius:calc(var(--border-radius)/2);overflow:hidden;font-size:24px}.el-x-welcome-icon .icon-image[data-v-68cfb339]{width:100%;height:100%;object-fit:contain;padding:4px}@media(max-width: 768px){.el-x-welcome-icon[data-v-68cfb339]{width:var(--icon-size-small);height:var(--icon-size-small);font-size:20px}}@media(max-width: 480px){.el-x-welcome-icon[data-v-68cfb339]{width:var(--icon-size-mobile);height:var(--icon-size-mobile);font-size:16px;margin-bottom:4px}.el-x-welcome-icon .icon-image[data-v-68cfb339]{padding:2px}}@media(max-width: 320px){.el-x-welcome-icon[data-v-68cfb339]{width:32px;height:32px;font-size:14px}}.content-wrapper[data-v-68cfb339]{flex:1;display:flex;flex-direction:column;gap:var(--gap-small)}@media(max-width: 480px){.content-wrapper[data-v-68cfb339]{align-items:center;text-align:center;width:100%;gap:var(--gap-small-mobile)}}.title-wrapper[data-v-68cfb339]{display:flex;justify-content:space-between;align-items:center;gap:var(--gap-small)}@media(max-width: 768px){.title-wrapper[data-v-68cfb339]{gap:var(--gap-small-mobile)}}@media(max-width: 480px){.title-wrapper[data-v-68cfb339]{flex-direction:column;align-items:center;gap:4px;width:100%}}@media(max-width: 320px){.title-wrapper[data-v-68cfb339]{gap:2px}}.el-x-welcome-title[data-v-68cfb339]{margin:0;font-size:var(--title-font-size);font-weight:600;color:var(--color-title);word-break:break-word}@media(max-width: 768px){.el-x-welcome-title[data-v-68cfb339]{font-size:var(--title-font-size-mobile)}}@media(max-width: 480px){.el-x-welcome-title[data-v-68cfb339]{font-size:14px;text-align:center;line-height:1.4}}@media(max-width: 320px){.el-x-welcome-title[data-v-68cfb339]{font-size:13px}}.el-x-welcome-extra[data-v-68cfb339]{flex-shrink:0;display:flex;align-items:center;gap:var(--gap-small)}.el-x-welcome-extra .el-dropdown[data-v-68cfb339],.el-x-welcome-extra .el-button[data-v-68cfb339],.el-x-welcome-extra .el-link[data-v-68cfb339]{flex-shrink:0}@media(max-width: 768px){.el-x-welcome-extra[data-v-68cfb339]{gap:var(--gap-small-mobile)}.el-x-welcome-extra .el-button[data-v-68cfb339]{font-size:12px;padding:6px 12px}}@media(max-width: 480px){.el-x-welcome-extra[data-v-68cfb339]{justify-content:center;flex-wrap:wrap;gap:4px}.el-x-welcome-extra .el-button[data-v-68cfb339]{font-size:12px;padding:4px 8px;min-height:28px}.el-x-welcome-extra .el-dropdown .el-button[data-v-68cfb339]{font-size:12px;padding:4px 8px}.el-x-welcome-extra .el-link[data-v-68cfb339]{font-size:12px}}@media(max-width: 320px){.el-x-welcome-extra .el-button[data-v-68cfb339]{font-size:11px;padding:3px 6px;min-height:24px}}.el-x-welcome-description[data-v-68cfb339]{margin:0;font-size:var(--description-font-size);color:var(--color-description);line-height:1.5;word-break:break-word}@media(max-width: 768px){.el-x-welcome-description[data-v-68cfb339]{font-size:var(--description-font-size-mobile);line-height:1.4}}@media(max-width: 480px){.el-x-welcome-description[data-v-68cfb339]{font-size:13px;line-height:1.4;text-align:center}}@media(max-width: 320px){.el-x-welcome-description[data-v-68cfb339]{font-size:12px;line-height:1.3}}", ""]);
|
|
33373
33368
|
// Exports
|
|
33374
33369
|
/* harmony default export */ __webpack_exports__["a"] = (___CSS_LOADER_EXPORT___);
|
|
33375
33370
|
|
|
@@ -35324,7 +35319,7 @@ var component = Object(componentNormalizer["a" /* default */])(
|
|
|
35324
35319
|
|
|
35325
35320
|
/* harmony default export */ var components_item = (component.exports);
|
|
35326
35321
|
// EXTERNAL MODULE: ./node_modules/lodash/lodash.js
|
|
35327
|
-
var lodash = __webpack_require__(
|
|
35322
|
+
var lodash = __webpack_require__(6);
|
|
35328
35323
|
|
|
35329
35324
|
// CONCATENATED MODULE: ./node_modules/babel-loader/lib!./node_modules/vue-loader/lib??vue-loader-options!./src/components/Conversations/src/main.vue?vue&type=script&lang=js
|
|
35330
35325
|
|
|
@@ -36954,71 +36949,71 @@ render._withStripped = true;
|
|
|
36954
36949
|
/* harmony default export */ var mainvue_type_script_lang_js = ({
|
|
36955
36950
|
name: 'ElXPrompts',
|
|
36956
36951
|
props: {
|
|
36957
|
-
/**
|
|
36958
|
-
* 包含多个提示项的列表
|
|
36952
|
+
/**
|
|
36953
|
+
* 包含多个提示项的列表
|
|
36959
36954
|
*/
|
|
36960
36955
|
items: {
|
|
36961
36956
|
type: Array,
|
|
36962
36957
|
default: () => []
|
|
36963
36958
|
},
|
|
36964
|
-
/**
|
|
36965
|
-
* 显示在提示列表顶部的标题
|
|
36959
|
+
/**
|
|
36960
|
+
* 显示在提示列表顶部的标题
|
|
36966
36961
|
*/
|
|
36967
36962
|
title: {
|
|
36968
36963
|
type: String,
|
|
36969
36964
|
default: ''
|
|
36970
36965
|
},
|
|
36971
|
-
/**
|
|
36972
|
-
* Item 提示项被点击时的回调函数
|
|
36966
|
+
/**
|
|
36967
|
+
* Item 提示项被点击时的回调函数
|
|
36973
36968
|
*/
|
|
36974
36969
|
onItemClick: {
|
|
36975
36970
|
type: Function,
|
|
36976
36971
|
default: null
|
|
36977
36972
|
},
|
|
36978
|
-
/**
|
|
36979
|
-
* 提示列表是否垂直排列
|
|
36973
|
+
/**
|
|
36974
|
+
* 提示列表是否垂直排列
|
|
36980
36975
|
*/
|
|
36981
36976
|
vertical: {
|
|
36982
36977
|
type: Boolean,
|
|
36983
36978
|
default: false
|
|
36984
36979
|
},
|
|
36985
|
-
/**
|
|
36986
|
-
* 提示列表是否换行
|
|
36980
|
+
/**
|
|
36981
|
+
* 提示列表是否换行
|
|
36987
36982
|
*/
|
|
36988
36983
|
wrap: {
|
|
36989
36984
|
type: Boolean,
|
|
36990
36985
|
default: false
|
|
36991
36986
|
},
|
|
36992
|
-
/**
|
|
36993
|
-
* 自定义样式,用于各个提示项的不同部分
|
|
36987
|
+
/**
|
|
36988
|
+
* 自定义样式,用于各个提示项的不同部分
|
|
36994
36989
|
*/
|
|
36995
36990
|
styles: {
|
|
36996
36991
|
type: Object,
|
|
36997
36992
|
default: () => ({})
|
|
36998
36993
|
},
|
|
36999
|
-
/**
|
|
37000
|
-
* 自定义样式类名,用于各个提示项的不同部分
|
|
36994
|
+
/**
|
|
36995
|
+
* 自定义样式类名,用于各个提示项的不同部分
|
|
37001
36996
|
*/
|
|
37002
36997
|
classNames: {
|
|
37003
36998
|
type: Object,
|
|
37004
36999
|
default: () => ({})
|
|
37005
37000
|
},
|
|
37006
|
-
/**
|
|
37007
|
-
* 根节点的样式类名
|
|
37001
|
+
/**
|
|
37002
|
+
* 根节点的样式类名
|
|
37008
37003
|
*/
|
|
37009
37004
|
rootClassName: {
|
|
37010
37005
|
type: String,
|
|
37011
37006
|
default: ''
|
|
37012
37007
|
},
|
|
37013
|
-
/**
|
|
37014
|
-
* 自定义样式
|
|
37008
|
+
/**
|
|
37009
|
+
* 自定义样式
|
|
37015
37010
|
*/
|
|
37016
37011
|
customStyle: {
|
|
37017
37012
|
type: Object,
|
|
37018
37013
|
default: () => ({})
|
|
37019
37014
|
},
|
|
37020
|
-
/**
|
|
37021
|
-
* 方向
|
|
37015
|
+
/**
|
|
37016
|
+
* 方向
|
|
37022
37017
|
*/
|
|
37023
37018
|
direction: {
|
|
37024
37019
|
type: String,
|
|
@@ -37374,7 +37369,7 @@ main.install = function (Vue) {
|
|
|
37374
37369
|
// ESM COMPAT FLAG
|
|
37375
37370
|
__webpack_require__.r(__webpack_exports__);
|
|
37376
37371
|
|
|
37377
|
-
// CONCATENATED MODULE: ./node_modules/babel-loader/lib!./node_modules/vue-loader/lib/loaders/templateLoader.js??ref--6!./node_modules/vue-loader/lib??vue-loader-options!./src/components/Thinking/src/main.vue?vue&type=template&id=
|
|
37372
|
+
// CONCATENATED MODULE: ./node_modules/babel-loader/lib!./node_modules/vue-loader/lib/loaders/templateLoader.js??ref--6!./node_modules/vue-loader/lib??vue-loader-options!./src/components/Thinking/src/main.vue?vue&type=template&id=673c6702&scoped=true
|
|
37378
37373
|
var render = function render() {
|
|
37379
37374
|
var _vm = this,
|
|
37380
37375
|
_c = _vm._self._c;
|
|
@@ -37423,7 +37418,7 @@ var render = function render() {
|
|
|
37423
37418
|
name: "rotate"
|
|
37424
37419
|
}
|
|
37425
37420
|
}, [!_vm.disabled ? _c("span", {
|
|
37426
|
-
staticClass: "arrow el-icon-center",
|
|
37421
|
+
staticClass: "thinking-arrow el-icon-center",
|
|
37427
37422
|
class: {
|
|
37428
37423
|
expanded: _vm.isExpanded
|
|
37429
37424
|
}
|
|
@@ -37463,7 +37458,7 @@ var render = function render() {
|
|
|
37463
37458
|
var staticRenderFns = [];
|
|
37464
37459
|
render._withStripped = true;
|
|
37465
37460
|
|
|
37466
|
-
// CONCATENATED MODULE: ./src/components/Thinking/src/main.vue?vue&type=template&id=
|
|
37461
|
+
// CONCATENATED MODULE: ./src/components/Thinking/src/main.vue?vue&type=template&id=673c6702&scoped=true
|
|
37467
37462
|
|
|
37468
37463
|
// CONCATENATED MODULE: ./node_modules/babel-loader/lib!./node_modules/vue-loader/lib??vue-loader-options!./src/components/Thinking/src/main.vue?vue&type=script&lang=js
|
|
37469
37464
|
/* harmony default export */ var mainvue_type_script_lang_js = ({
|
|
@@ -37561,10 +37556,10 @@ render._withStripped = true;
|
|
|
37561
37556
|
var injectStylesIntoStyleTag = __webpack_require__(3);
|
|
37562
37557
|
var injectStylesIntoStyleTag_default = /*#__PURE__*/__webpack_require__.n(injectStylesIntoStyleTag);
|
|
37563
37558
|
|
|
37564
|
-
// EXTERNAL MODULE: ./node_modules/css-loader/dist/cjs.js!./node_modules/vue-loader/lib/loaders/stylePostLoader.js!./node_modules/sass-loader/dist/cjs.js!./node_modules/vue-loader/lib??vue-loader-options!./src/components/Thinking/src/main.vue?vue&type=style&index=0&id=
|
|
37565
|
-
var
|
|
37559
|
+
// EXTERNAL MODULE: ./node_modules/css-loader/dist/cjs.js!./node_modules/vue-loader/lib/loaders/stylePostLoader.js!./node_modules/sass-loader/dist/cjs.js!./node_modules/vue-loader/lib??vue-loader-options!./src/components/Thinking/src/main.vue?vue&type=style&index=0&id=673c6702&prod&lang=scss&scoped=true
|
|
37560
|
+
var mainvue_type_style_index_0_id_673c6702_prod_lang_scss_scoped_true = __webpack_require__(94);
|
|
37566
37561
|
|
|
37567
|
-
// CONCATENATED MODULE: ./node_modules/style-loader/dist/cjs.js!./node_modules/css-loader/dist/cjs.js!./node_modules/vue-loader/lib/loaders/stylePostLoader.js!./node_modules/sass-loader/dist/cjs.js!./node_modules/vue-loader/lib??vue-loader-options!./src/components/Thinking/src/main.vue?vue&type=style&index=0&id=
|
|
37562
|
+
// CONCATENATED MODULE: ./node_modules/style-loader/dist/cjs.js!./node_modules/css-loader/dist/cjs.js!./node_modules/vue-loader/lib/loaders/stylePostLoader.js!./node_modules/sass-loader/dist/cjs.js!./node_modules/vue-loader/lib??vue-loader-options!./src/components/Thinking/src/main.vue?vue&type=style&index=0&id=673c6702&prod&lang=scss&scoped=true
|
|
37568
37563
|
|
|
37569
37564
|
|
|
37570
37565
|
|
|
@@ -37573,12 +37568,12 @@ var options = {};
|
|
|
37573
37568
|
options.insert = "head";
|
|
37574
37569
|
options.singleton = false;
|
|
37575
37570
|
|
|
37576
|
-
var update = injectStylesIntoStyleTag_default()(
|
|
37571
|
+
var update = injectStylesIntoStyleTag_default()(mainvue_type_style_index_0_id_673c6702_prod_lang_scss_scoped_true["a" /* default */], options);
|
|
37577
37572
|
|
|
37578
37573
|
|
|
37579
37574
|
|
|
37580
|
-
/* harmony default export */ var
|
|
37581
|
-
// CONCATENATED MODULE: ./src/components/Thinking/src/main.vue?vue&type=style&index=0&id=
|
|
37575
|
+
/* harmony default export */ var src_mainvue_type_style_index_0_id_673c6702_prod_lang_scss_scoped_true = (mainvue_type_style_index_0_id_673c6702_prod_lang_scss_scoped_true["a" /* default */].locals || {});
|
|
37576
|
+
// CONCATENATED MODULE: ./src/components/Thinking/src/main.vue?vue&type=style&index=0&id=673c6702&prod&lang=scss&scoped=true
|
|
37582
37577
|
|
|
37583
37578
|
// EXTERNAL MODULE: ./node_modules/vue-loader/lib/runtime/componentNormalizer.js
|
|
37584
37579
|
var componentNormalizer = __webpack_require__(0);
|
|
@@ -37598,7 +37593,7 @@ var component = Object(componentNormalizer["a" /* default */])(
|
|
|
37598
37593
|
staticRenderFns,
|
|
37599
37594
|
false,
|
|
37600
37595
|
null,
|
|
37601
|
-
"
|
|
37596
|
+
"673c6702",
|
|
37602
37597
|
null
|
|
37603
37598
|
|
|
37604
37599
|
)
|
|
@@ -37726,10 +37721,10 @@ render._withStripped = true;
|
|
|
37726
37721
|
// CONCATENATED MODULE: ./src/components/ThoughtChain/src/main.vue?vue&type=template&id=49e41fca&scoped=true
|
|
37727
37722
|
|
|
37728
37723
|
// EXTERNAL MODULE: ./node_modules/lodash/lodash.js
|
|
37729
|
-
var lodash = __webpack_require__(
|
|
37724
|
+
var lodash = __webpack_require__(6);
|
|
37730
37725
|
|
|
37731
37726
|
// EXTERNAL MODULE: ./src/components/Typewriter/index.js + 7 modules
|
|
37732
|
-
var Typewriter = __webpack_require__(
|
|
37727
|
+
var Typewriter = __webpack_require__(12);
|
|
37733
37728
|
|
|
37734
37729
|
// CONCATENATED MODULE: ./node_modules/babel-loader/lib!./node_modules/vue-loader/lib??vue-loader-options!./src/components/ThoughtChain/src/main.vue?vue&type=script&lang=js
|
|
37735
37730
|
|
|
@@ -38228,20 +38223,28 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
38228
38223
|
/* harmony import */ var _components_ThoughtChain_index_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(105);
|
|
38229
38224
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "ElXThoughtChain", function() { return _components_ThoughtChain_index_js__WEBPACK_IMPORTED_MODULE_9__["default"]; });
|
|
38230
38225
|
|
|
38231
|
-
/* harmony import */ var _components_Typewriter_index_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(
|
|
38226
|
+
/* harmony import */ var _components_Typewriter_index_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(12);
|
|
38232
38227
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "ElXTypewriter", function() { return _components_Typewriter_index_js__WEBPACK_IMPORTED_MODULE_10__["default"]; });
|
|
38233
38228
|
|
|
38234
38229
|
/* harmony import */ var _components_Welcome_index_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(106);
|
|
38235
38230
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "ElXWelcome", function() { return _components_Welcome_index_js__WEBPACK_IMPORTED_MODULE_11__["default"]; });
|
|
38236
38231
|
|
|
38237
|
-
/* harmony import */ var _mixins__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(
|
|
38232
|
+
/* harmony import */ var _mixins__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(5);
|
|
38238
38233
|
/* harmony reexport (module object) */ __webpack_require__.d(__webpack_exports__, "customMixins", function() { return _mixins__WEBPACK_IMPORTED_MODULE_12__; });
|
|
38239
|
-
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "
|
|
38234
|
+
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "createSendUtils", function() { return _mixins__WEBPACK_IMPORTED_MODULE_12__["createSendUtils"]; });
|
|
38240
38235
|
|
|
38241
|
-
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "
|
|
38236
|
+
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "createStreamUtils", function() { return _mixins__WEBPACK_IMPORTED_MODULE_12__["createStreamUtils"]; });
|
|
38242
38237
|
|
|
38243
38238
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "recordMixin", function() { return _mixins__WEBPACK_IMPORTED_MODULE_12__["recordMixin"]; });
|
|
38244
38239
|
|
|
38240
|
+
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "sendMixin", function() { return _mixins__WEBPACK_IMPORTED_MODULE_12__["sendMixin"]; });
|
|
38241
|
+
|
|
38242
|
+
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "streamMixin", function() { return _mixins__WEBPACK_IMPORTED_MODULE_12__["streamMixin"]; });
|
|
38243
|
+
|
|
38244
|
+
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "XRequest", function() { return _mixins__WEBPACK_IMPORTED_MODULE_12__["XRequest"]; });
|
|
38245
|
+
|
|
38246
|
+
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "XStream", function() { return _mixins__WEBPACK_IMPORTED_MODULE_12__["XStream"]; });
|
|
38247
|
+
|
|
38245
38248
|
|
|
38246
38249
|
|
|
38247
38250
|
|
|
@@ -38269,7 +38272,6 @@ const install = function (Vue) {
|
|
|
38269
38272
|
|
|
38270
38273
|
// 具名导出(按需引入)- Mixins
|
|
38271
38274
|
|
|
38272
|
-
|
|
38273
38275
|
// 默认导出(完整引入)
|
|
38274
38276
|
const ElementUIX = {
|
|
38275
38277
|
version: '1.0.0',
|
|
@@ -38286,6 +38288,10 @@ ElementUIX.customMixins = _mixins__WEBPACK_IMPORTED_MODULE_12__;
|
|
|
38286
38288
|
ElementUIX.streamMixin = _mixins__WEBPACK_IMPORTED_MODULE_12__["streamMixin"];
|
|
38287
38289
|
ElementUIX.sendMixin = _mixins__WEBPACK_IMPORTED_MODULE_12__["sendMixin"];
|
|
38288
38290
|
ElementUIX.recordMixin = _mixins__WEBPACK_IMPORTED_MODULE_12__["recordMixin"];
|
|
38291
|
+
ElementUIX.createStreamUtils = _mixins__WEBPACK_IMPORTED_MODULE_12__["createStreamUtils"];
|
|
38292
|
+
ElementUIX.createSendUtils = _mixins__WEBPACK_IMPORTED_MODULE_12__["createSendUtils"];
|
|
38293
|
+
ElementUIX.XRequest = _mixins__WEBPACK_IMPORTED_MODULE_12__["XRequest"];
|
|
38294
|
+
ElementUIX.XStream = _mixins__WEBPACK_IMPORTED_MODULE_12__["XStream"];
|
|
38289
38295
|
/* harmony default export */ __webpack_exports__["default"] = (ElementUIX);
|
|
38290
38296
|
|
|
38291
38297
|
/***/ })
|