1 | var vendor_library, =
|
2 | (function(modules) {
|
3 |
|
4 | var installedModules = {};
|
5 |
|
6 |
|
7 | function __webpack_require__(moduleId) {
|
8 |
|
9 |
|
10 | if(installedModules[moduleId]) {
|
11 | return installedModules[moduleId].exports;
|
12 | }
|
13 |
|
14 | var module = installedModules[moduleId] = {
|
15 | i: moduleId,
|
16 | l: false,
|
17 | exports: {}
|
18 | };
|
19 |
|
20 |
|
21 | modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
|
22 |
|
23 |
|
24 | module.l = true;
|
25 |
|
26 |
|
27 | return module.exports;
|
28 | }
|
29 |
|
30 |
|
31 |
|
32 | __webpack_require__.m = modules;
|
33 |
|
34 |
|
35 | __webpack_require__.c = installedModules;
|
36 |
|
37 |
|
38 | __webpack_require__.d = function(exports, name, getter) {
|
39 | if(!__webpack_require__.o(exports, name)) {
|
40 | Object.defineProperty(exports, name, {
|
41 | configurable: false,
|
42 | enumerable: true,
|
43 | get: getter
|
44 | /******/ });
|
45 | /******/ }
|
46 | /******/ };
|
47 | /******/
|
48 | /******/ // define __esModule on exports
|
49 | /******/ __webpack_require__.r = function(exports) {
|
50 | Object.defineProperty(exports, '__esModule', { value: true });
|
51 | };
|
52 |
|
53 |
|
54 | __webpack_require__.n = function(module) {
|
55 | var getter = module && module.__esModule ?
|
56 | function getDefault() { return module['default']; } :
|
57 | function getModuleExports() { return module; };
|
58 | __webpack_require__.d(getter, 'a', getter);
|
59 | return getter;
|
60 | };
|
61 |
|
62 |
|
63 | __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
64 |
|
65 |
|
66 | __webpack_require__.p = "";
|
67 |
|
68 |
|
69 |
|
70 | return __webpack_require__(__webpack_require__.s = 0);
|
71 | })
|
72 |
|
73 | ([
|
74 |
|
75 | (function(module, exports, __webpack_require__) {
|
76 |
|
77 | module.exports = __webpack_require__;
|
78 |
|
79 | }),
|
80 |
|
81 | (function(module, exports, __webpack_require__) {
|
82 |
|
83 | module.exports = __webpack_require__(2);
|
84 |
|
85 | }),
|
86 |
|
87 | (function(module, exports, __webpack_require__) {
|
88 |
|
89 | "use strict";
|
90 |
|
91 |
|
92 | var utils = __webpack_require__(3);
|
93 | var bind = __webpack_require__(4);
|
94 | var Axios = __webpack_require__(6);
|
95 | var defaults = __webpack_require__(7);
|
96 |
|
97 |
|
98 |
|
99 |
|
100 |
|
101 |
|
102 |
|
103 | function createInstance(defaultConfig) {
|
104 | var context = new Axios(defaultConfig);
|
105 | var instance = bind(Axios.prototype.request, context);
|
106 |
|
107 |
|
108 | utils.extend(instance, Axios.prototype, context);
|
109 |
|
110 |
|
111 | utils.extend(instance, context);
|
112 |
|
113 | return instance;
|
114 | }
|
115 |
|
116 |
|
117 | var axios = createInstance(defaults);
|
118 |
|
119 |
|
120 | axios.Axios = Axios;
|
121 |
|
122 |
|
123 | axios.create = function create(instanceConfig) {
|
124 | return createInstance(utils.merge(defaults, instanceConfig));
|
125 | };
|
126 |
|
127 |
|
128 | axios.Cancel = __webpack_require__(25);
|
129 | axios.CancelToken = __webpack_require__(26);
|
130 | axios.isCancel = __webpack_require__(22);
|
131 |
|
132 |
|
133 | axios.all = function all(promises) {
|
134 | return Promise.all(promises);
|
135 | };
|
136 | axios.spread = __webpack_require__(27);
|
137 |
|
138 | module.exports = axios;
|
139 |
|
140 |
|
141 | module.exports.default = axios;
|
142 |
|
143 |
|
144 | }),
|
145 |
|
146 | (function(module, exports, __webpack_require__) {
|
147 |
|
148 | "use strict";
|
149 |
|
150 |
|
151 | var bind = __webpack_require__(4);
|
152 | var isBuffer = __webpack_require__(5);
|
153 |
|
154 |
|
155 |
|
156 |
|
157 |
|
158 | var toString = Object.prototype.toString;
|
159 |
|
160 |
|
161 |
|
162 |
|
163 |
|
164 |
|
165 |
|
166 | function isArray(val) {
|
167 | return toString.call(val) === '[object Array]';
|
168 | }
|
169 |
|
170 |
|
171 |
|
172 |
|
173 |
|
174 |
|
175 |
|
176 | function isArrayBuffer(val) {
|
177 | return toString.call(val) === '[object ArrayBuffer]';
|
178 | }
|
179 |
|
180 |
|
181 |
|
182 |
|
183 |
|
184 |
|
185 |
|
186 | function isFormData(val) {
|
187 | return (typeof FormData !== 'undefined') && (val instanceof FormData);
|
188 | }
|
189 |
|
190 |
|
191 |
|
192 |
|
193 |
|
194 |
|
195 |
|
196 | function isArrayBufferView(val) {
|
197 | var result;
|
198 | if ((typeof ArrayBuffer !== 'undefined') && (ArrayBuffer.isView)) {
|
199 | result = ArrayBuffer.isView(val);
|
200 | } else {
|
201 | result = (val) && (val.buffer) && (val.buffer instanceof ArrayBuffer);
|
202 | }
|
203 | return result;
|
204 | }
|
205 |
|
206 |
|
207 |
|
208 |
|
209 |
|
210 |
|
211 |
|
212 | function isString(val) {
|
213 | return typeof val === 'string';
|
214 | }
|
215 |
|
216 |
|
217 |
|
218 |
|
219 |
|
220 |
|
221 |
|
222 | function isNumber(val) {
|
223 | return typeof val === 'number';
|
224 | }
|
225 |
|
226 |
|
227 |
|
228 |
|
229 |
|
230 |
|
231 |
|
232 | function isUndefined(val) {
|
233 | return typeof val === 'undefined';
|
234 | }
|
235 |
|
236 |
|
237 |
|
238 |
|
239 |
|
240 |
|
241 |
|
242 | function isObject(val) {
|
243 | return val !== null && typeof val === 'object';
|
244 | }
|
245 |
|
246 |
|
247 |
|
248 |
|
249 |
|
250 |
|
251 |
|
252 | function isDate(val) {
|
253 | return toString.call(val) === '[object Date]';
|
254 | }
|
255 |
|
256 |
|
257 |
|
258 |
|
259 |
|
260 |
|
261 |
|
262 | function isFile(val) {
|
263 | return toString.call(val) === '[object File]';
|
264 | }
|
265 |
|
266 |
|
267 |
|
268 |
|
269 |
|
270 |
|
271 |
|
272 | function isBlob(val) {
|
273 | return toString.call(val) === '[object Blob]';
|
274 | }
|
275 |
|
276 |
|
277 |
|
278 |
|
279 |
|
280 |
|
281 |
|
282 | function isFunction(val) {
|
283 | return toString.call(val) === '[object Function]';
|
284 | }
|
285 |
|
286 |
|
287 |
|
288 |
|
289 |
|
290 |
|
291 |
|
292 | function isStream(val) {
|
293 | return isObject(val) && isFunction(val.pipe);
|
294 | }
|
295 |
|
296 |
|
297 |
|
298 |
|
299 |
|
300 |
|
301 |
|
302 | function isURLSearchParams(val) {
|
303 | return typeof URLSearchParams !== 'undefined' && val instanceof URLSearchParams;
|
304 | }
|
305 |
|
306 |
|
307 |
|
308 |
|
309 |
|
310 |
|
311 |
|
312 | function trim(str) {
|
313 | return str.replace(/^\s*/, '').replace(/\s*$/, '');
|
314 | }
|
315 |
|
316 |
|
317 |
|
318 |
|
319 |
|
320 |
|
321 |
|
322 |
|
323 |
|
324 |
|
325 |
|
326 |
|
327 |
|
328 |
|
329 | function isStandardBrowserEnv() {
|
330 | if (typeof navigator !== 'undefined' && navigator.product === 'ReactNative') {
|
331 | return false;
|
332 | }
|
333 | return (
|
334 | typeof window !== 'undefined' &&
|
335 | typeof document !== 'undefined'
|
336 | );
|
337 | }
|
338 |
|
339 |
|
340 |
|
341 |
|
342 |
|
343 |
|
344 |
|
345 |
|
346 |
|
347 |
|
348 |
|
349 |
|
350 |
|
351 | function forEach(obj, fn) {
|
352 |
|
353 | if (obj === null || typeof obj === 'undefined') {
|
354 | return;
|
355 | }
|
356 |
|
357 |
|
358 | if (typeof obj !== 'object') {
|
359 |
|
360 | obj = [obj];
|
361 | }
|
362 |
|
363 | if (isArray(obj)) {
|
364 |
|
365 | for (var i = 0, l = obj.length; i < l; i++) {
|
366 | fn.call(null, obj[i], i, obj);
|
367 | }
|
368 | } else {
|
369 |
|
370 | for (var key in obj) {
|
371 | if (Object.prototype.hasOwnProperty.call(obj, key)) {
|
372 | fn.call(null, obj[key], key, obj);
|
373 | }
|
374 | }
|
375 | }
|
376 | }
|
377 |
|
378 |
|
379 |
|
380 |
|
381 |
|
382 |
|
383 |
|
384 |
|
385 |
|
386 |
|
387 |
|
388 |
|
389 |
|
390 |
|
391 |
|
392 |
|
393 |
|
394 |
|
395 | function merge(/* obj1, obj2, obj3, ... */) {
|
396 | var result = {};
|
397 | function assignValue(val, key) {
|
398 | if (typeof result[key] === 'object' && typeof val === 'object') {
|
399 | result[key] = merge(result[key], val);
|
400 | } else {
|
401 | result[key] = val;
|
402 | }
|
403 | }
|
404 |
|
405 | for (var i = 0, l = arguments.length; i < l; i++) {
|
406 | forEach(arguments[i], assignValue);
|
407 | }
|
408 | return result;
|
409 | }
|
410 |
|
411 |
|
412 |
|
413 |
|
414 |
|
415 |
|
416 |
|
417 |
|
418 |
|
419 | function extend(a, b, thisArg) {
|
420 | forEach(b, function assignValue(val, key) {
|
421 | if (thisArg && typeof val === 'function') {
|
422 | a[key] = bind(val, thisArg);
|
423 | } else {
|
424 | a[key] = val;
|
425 | }
|
426 | });
|
427 | return a;
|
428 | }
|
429 |
|
430 | module.exports = {
|
431 | isArray: isArray,
|
432 | isArrayBuffer: isArrayBuffer,
|
433 | isBuffer: isBuffer,
|
434 | isFormData: isFormData,
|
435 | isArrayBufferView: isArrayBufferView,
|
436 | isString: isString,
|
437 | isNumber: isNumber,
|
438 | isObject: isObject,
|
439 | isUndefined: isUndefined,
|
440 | isDate: isDate,
|
441 | isFile: isFile,
|
442 | isBlob: isBlob,
|
443 | isFunction: isFunction,
|
444 | isStream: isStream,
|
445 | isURLSearchParams: isURLSearchParams,
|
446 | isStandardBrowserEnv: isStandardBrowserEnv,
|
447 | forEach: forEach,
|
448 | merge: merge,
|
449 | extend: extend,
|
450 | trim: trim
|
451 | };
|
452 |
|
453 |
|
454 | }),
|
455 |
|
456 | (function(module, exports, __webpack_require__) {
|
457 |
|
458 | "use strict";
|
459 |
|
460 |
|
461 | module.exports = function bind(fn, thisArg) {
|
462 | return function wrap() {
|
463 | var args = new Array(arguments.length);
|
464 | for (var i = 0; i < args.length; i++) {
|
465 | args[i] = arguments[i];
|
466 | }
|
467 | return fn.apply(thisArg, args);
|
468 | };
|
469 | };
|
470 |
|
471 |
|
472 | }),
|
473 |
|
474 | (function(module, exports) {
|
475 |
|
476 |
|
477 |
|
478 |
|
479 |
|
480 |
|
481 |
|
482 |
|
483 |
|
484 |
|
485 | module.exports = function (obj) {
|
486 | return obj != null && (isBuffer(obj) || isSlowBuffer(obj) || !!obj._isBuffer)
|
487 | }
|
488 |
|
489 | function isBuffer (obj) {
|
490 | return !!obj.constructor && typeof obj.constructor.isBuffer === 'function' && obj.constructor.isBuffer(obj)
|
491 | }
|
492 |
|
493 |
|
494 | function isSlowBuffer (obj) {
|
495 | return typeof obj.readFloatLE === 'function' && typeof obj.slice === 'function' && isBuffer(obj.slice(0, 0))
|
496 | }
|
497 |
|
498 |
|
499 | }),
|
500 |
|
501 | (function(module, exports, __webpack_require__) {
|
502 |
|
503 | "use strict";
|
504 |
|
505 |
|
506 | var defaults = __webpack_require__(7);
|
507 | var utils = __webpack_require__(3);
|
508 | var InterceptorManager = __webpack_require__(19);
|
509 | var dispatchRequest = __webpack_require__(20);
|
510 |
|
511 |
|
512 |
|
513 |
|
514 |
|
515 |
|
516 | function Axios(instanceConfig) {
|
517 | this.defaults = instanceConfig;
|
518 | this.interceptors = {
|
519 | request: new InterceptorManager(),
|
520 | response: new InterceptorManager()
|
521 | };
|
522 | }
|
523 |
|
524 |
|
525 |
|
526 |
|
527 |
|
528 |
|
529 | Axios.prototype.request = function request(config) {
|
530 |
|
531 |
|
532 | if (typeof config === 'string') {
|
533 | config = utils.merge({
|
534 | url: arguments[0]
|
535 | }, arguments[1]);
|
536 | }
|
537 |
|
538 | config = utils.merge(defaults, {method: 'get'}, this.defaults, config);
|
539 | config.method = config.method.toLowerCase();
|
540 |
|
541 |
|
542 | var chain = [dispatchRequest, undefined];
|
543 | var promise = Promise.resolve(config);
|
544 |
|
545 | this.interceptors.request.forEach(function unshiftRequestInterceptors(interceptor) {
|
546 | chain.unshift(interceptor.fulfilled, interceptor.rejected);
|
547 | });
|
548 |
|
549 | this.interceptors.response.forEach(function pushResponseInterceptors(interceptor) {
|
550 | chain.push(interceptor.fulfilled, interceptor.rejected);
|
551 | });
|
552 |
|
553 | while (chain.length) {
|
554 | promise = promise.then(chain.shift(), chain.shift());
|
555 | }
|
556 |
|
557 | return promise;
|
558 | };
|
559 |
|
560 |
|
561 | utils.forEach(['delete', 'get', 'head', 'options'], function forEachMethodNoData(method) {
|
562 |
|
563 | Axios.prototype[method] = function(url, config) {
|
564 | return this.request(utils.merge(config || {}, {
|
565 | method: method,
|
566 | url: url
|
567 | }));
|
568 | };
|
569 | });
|
570 |
|
571 | utils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) {
|
572 |
|
573 | Axios.prototype[method] = function(url, data, config) {
|
574 | return this.request(utils.merge(config || {}, {
|
575 | method: method,
|
576 | url: url,
|
577 | data: data
|
578 | }));
|
579 | };
|
580 | });
|
581 |
|
582 | module.exports = Axios;
|
583 |
|
584 |
|
585 | }),
|
586 |
|
587 | (function(module, exports, __webpack_require__) {
|
588 |
|
589 | "use strict";
|
590 | (function(process) {
|
591 |
|
592 | var utils = __webpack_require__(3);
|
593 | var normalizeHeaderName = __webpack_require__(9);
|
594 |
|
595 | var DEFAULT_CONTENT_TYPE = {
|
596 | 'Content-Type': 'application/x-www-form-urlencoded'
|
597 | };
|
598 |
|
599 | function setContentTypeIfUnset(headers, value) {
|
600 | if (!utils.isUndefined(headers) && utils.isUndefined(headers['Content-Type'])) {
|
601 | headers['Content-Type'] = value;
|
602 | }
|
603 | }
|
604 |
|
605 | function getDefaultAdapter() {
|
606 | var adapter;
|
607 | if (typeof XMLHttpRequest !== 'undefined') {
|
608 |
|
609 | adapter = __webpack_require__(10);
|
610 | } else if (typeof process !== 'undefined') {
|
611 |
|
612 | adapter = __webpack_require__(10);
|
613 | }
|
614 | return adapter;
|
615 | }
|
616 |
|
617 | var defaults = {
|
618 | adapter: getDefaultAdapter(),
|
619 |
|
620 | transformRequest: [function transformRequest(data, headers) {
|
621 | normalizeHeaderName(headers, 'Content-Type');
|
622 | if (utils.isFormData(data) ||
|
623 | utils.isArrayBuffer(data) ||
|
624 | utils.isBuffer(data) ||
|
625 | utils.isStream(data) ||
|
626 | utils.isFile(data) ||
|
627 | utils.isBlob(data)
|
628 | ) {
|
629 | return data;
|
630 | }
|
631 | if (utils.isArrayBufferView(data)) {
|
632 | return data.buffer;
|
633 | }
|
634 | if (utils.isURLSearchParams(data)) {
|
635 | setContentTypeIfUnset(headers, 'application/x-www-form-urlencoded;charset=utf-8');
|
636 | return data.toString();
|
637 | }
|
638 | if (utils.isObject(data)) {
|
639 | setContentTypeIfUnset(headers, 'application/json;charset=utf-8');
|
640 | return JSON.stringify(data);
|
641 | }
|
642 | return data;
|
643 | }],
|
644 |
|
645 | transformResponse: [function transformResponse(data) {
|
646 |
|
647 | if (typeof data === 'string') {
|
648 | try {
|
649 | data = JSON.parse(data);
|
650 | } catch (e) { }
|
651 | }
|
652 | return data;
|
653 | }],
|
654 |
|
655 | |
656 |
|
657 |
|
658 |
|
659 | timeout: 0,
|
660 |
|
661 | xsrfCookieName: 'XSRF-TOKEN',
|
662 | xsrfHeaderName: 'X-XSRF-TOKEN',
|
663 |
|
664 | maxContentLength: -1,
|
665 |
|
666 | validateStatus: function validateStatus(status) {
|
667 | return status >= 200 && status < 300;
|
668 | }
|
669 | };
|
670 |
|
671 | defaults.headers = {
|
672 | common: {
|
673 | 'Accept': 'application/json, text/plain, */*'
|
674 | }
|
675 | };
|
676 |
|
677 | utils.forEach(['delete', 'get', 'head'], function forEachMethodNoData(method) {
|
678 | defaults.headers[method] = {};
|
679 | });
|
680 |
|
681 | utils.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) {
|
682 | defaults.headers[method] = utils.merge(DEFAULT_CONTENT_TYPE);
|
683 | });
|
684 |
|
685 | module.exports = defaults;
|
686 |
|
687 | }.call(this, __webpack_require__(8)))
|
688 |
|
689 | }),
|
690 |
|
691 | (function(module, exports) {
|
692 |
|
693 |
|
694 | var process = module.exports = {};
|
695 |
|
696 |
|
697 |
|
698 |
|
699 |
|
700 |
|
701 | var cachedSetTimeout;
|
702 | var cachedClearTimeout;
|
703 |
|
704 | function defaultSetTimout() {
|
705 | throw new Error('setTimeout has not been defined');
|
706 | }
|
707 | function defaultClearTimeout () {
|
708 | throw new Error('clearTimeout has not been defined');
|
709 | }
|
710 | (function () {
|
711 | try {
|
712 | if (typeof setTimeout === 'function') {
|
713 | cachedSetTimeout = setTimeout;
|
714 | } else {
|
715 | cachedSetTimeout = defaultSetTimout;
|
716 | }
|
717 | } catch (e) {
|
718 | cachedSetTimeout = defaultSetTimout;
|
719 | }
|
720 | try {
|
721 | if (typeof clearTimeout === 'function') {
|
722 | cachedClearTimeout = clearTimeout;
|
723 | } else {
|
724 | cachedClearTimeout = defaultClearTimeout;
|
725 | }
|
726 | } catch (e) {
|
727 | cachedClearTimeout = defaultClearTimeout;
|
728 | }
|
729 | } ())
|
730 | function runTimeout(fun) {
|
731 | if (cachedSetTimeout === setTimeout) {
|
732 |
|
733 | return setTimeout(fun, 0);
|
734 | }
|
735 |
|
736 | if ((cachedSetTimeout === defaultSetTimout || !cachedSetTimeout) && setTimeout) {
|
737 | cachedSetTimeout = setTimeout;
|
738 | return setTimeout(fun, 0);
|
739 | }
|
740 | try {
|
741 |
|
742 | return cachedSetTimeout(fun, 0);
|
743 | } catch(e){
|
744 | try {
|
745 |
|
746 | return cachedSetTimeout.call(null, fun, 0);
|
747 | } catch(e){
|
748 |
|
749 | return cachedSetTimeout.call(this, fun, 0);
|
750 | }
|
751 | }
|
752 |
|
753 |
|
754 | }
|
755 | function runClearTimeout(marker) {
|
756 | if (cachedClearTimeout === clearTimeout) {
|
757 |
|
758 | return clearTimeout(marker);
|
759 | }
|
760 |
|
761 | if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) {
|
762 | cachedClearTimeout = clearTimeout;
|
763 | return clearTimeout(marker);
|
764 | }
|
765 | try {
|
766 |
|
767 | return cachedClearTimeout(marker);
|
768 | } catch (e){
|
769 | try {
|
770 |
|
771 | return cachedClearTimeout.call(null, marker);
|
772 | } catch (e){
|
773 |
|
774 |
|
775 | return cachedClearTimeout.call(this, marker);
|
776 | }
|
777 | }
|
778 |
|
779 |
|
780 |
|
781 | }
|
782 | var queue = [];
|
783 | var draining = false;
|
784 | var currentQueue;
|
785 | var queueIndex = -1;
|
786 |
|
787 | function cleanUpNextTick() {
|
788 | if (!draining || !currentQueue) {
|
789 | return;
|
790 | }
|
791 | draining = false;
|
792 | if (currentQueue.length) {
|
793 | queue = currentQueue.concat(queue);
|
794 | } else {
|
795 | queueIndex = -1;
|
796 | }
|
797 | if (queue.length) {
|
798 | drainQueue();
|
799 | }
|
800 | }
|
801 |
|
802 | function drainQueue() {
|
803 | if (draining) {
|
804 | return;
|
805 | }
|
806 | var timeout = runTimeout(cleanUpNextTick);
|
807 | draining = true;
|
808 |
|
809 | var len = queue.length;
|
810 | while(len) {
|
811 | currentQueue = queue;
|
812 | queue = [];
|
813 | while (++queueIndex < len) {
|
814 | if (currentQueue) {
|
815 | currentQueue[queueIndex].run();
|
816 | }
|
817 | }
|
818 | queueIndex = -1;
|
819 | len = queue.length;
|
820 | }
|
821 | currentQueue = null;
|
822 | draining = false;
|
823 | runClearTimeout(timeout);
|
824 | }
|
825 |
|
826 | process.nextTick = function (fun) {
|
827 | var args = new Array(arguments.length - 1);
|
828 | if (arguments.length > 1) {
|
829 | for (var i = 1; i < arguments.length; i++) {
|
830 | args[i - 1] = arguments[i];
|
831 | }
|
832 | }
|
833 | queue.push(new Item(fun, args));
|
834 | if (queue.length === 1 && !draining) {
|
835 | runTimeout(drainQueue);
|
836 | }
|
837 | };
|
838 |
|
839 |
|
840 | function Item(fun, array) {
|
841 | this.fun = fun;
|
842 | this.array = array;
|
843 | }
|
844 | Item.prototype.run = function () {
|
845 | this.fun.apply(null, this.array);
|
846 | };
|
847 | process.title = 'browser';
|
848 | process.browser = true;
|
849 | process.env = {};
|
850 | process.argv = [];
|
851 | process.version = '';
|
852 | process.versions = {};
|
853 |
|
854 | function noop() {}
|
855 |
|
856 | process.on = noop;
|
857 | process.addListener = noop;
|
858 | process.once = noop;
|
859 | process.off = noop;
|
860 | process.removeListener = noop;
|
861 | process.removeAllListeners = noop;
|
862 | process.emit = noop;
|
863 | process.prependListener = noop;
|
864 | process.prependOnceListener = noop;
|
865 |
|
866 | process.listeners = function (name) { return [] }
|
867 |
|
868 | process.binding = function (name) {
|
869 | throw new Error('process.binding is not supported');
|
870 | };
|
871 |
|
872 | process.cwd = function () { return '/' };
|
873 | process.chdir = function (dir) {
|
874 | throw new Error('process.chdir is not supported');
|
875 | };
|
876 | process.umask = function() { return 0; };
|
877 |
|
878 |
|
879 | }),
|
880 |
|
881 | (function(module, exports, __webpack_require__) {
|
882 |
|
883 | "use strict";
|
884 |
|
885 |
|
886 | var utils = __webpack_require__(3);
|
887 |
|
888 | module.exports = function normalizeHeaderName(headers, normalizedName) {
|
889 | utils.forEach(headers, function processHeader(value, name) {
|
890 | if (name !== normalizedName && name.toUpperCase() === normalizedName.toUpperCase()) {
|
891 | headers[normalizedName] = value;
|
892 | delete headers[name];
|
893 | }
|
894 | });
|
895 | };
|
896 |
|
897 |
|
898 | }),
|
899 |
|
900 | (function(module, exports, __webpack_require__) {
|
901 |
|
902 | "use strict";
|
903 |
|
904 |
|
905 | var utils = __webpack_require__(3);
|
906 | var settle = __webpack_require__(11);
|
907 | var buildURL = __webpack_require__(14);
|
908 | var parseHeaders = __webpack_require__(15);
|
909 | var isURLSameOrigin = __webpack_require__(16);
|
910 | var createError = __webpack_require__(12);
|
911 | var btoa = (typeof window !== 'undefined' && window.btoa && window.btoa.bind(window)) || __webpack_require__(17);
|
912 |
|
913 | module.exports = function xhrAdapter(config) {
|
914 | return new Promise(function dispatchXhrRequest(resolve, reject) {
|
915 | var requestData = config.data;
|
916 | var requestHeaders = config.headers;
|
917 |
|
918 | if (utils.isFormData(requestData)) {
|
919 | delete requestHeaders['Content-Type'];
|
920 | }
|
921 |
|
922 | var request = new XMLHttpRequest();
|
923 | var loadEvent = 'onreadystatechange';
|
924 | var xDomain = false;
|
925 |
|
926 |
|
927 |
|
928 |
|
929 | if ("none" !== 'test' &&
|
930 | typeof window !== 'undefined' &&
|
931 | window.XDomainRequest && !('withCredentials' in request) &&
|
932 | !isURLSameOrigin(config.url)) {
|
933 | request = new window.XDomainRequest();
|
934 | loadEvent = 'onload';
|
935 | xDomain = true;
|
936 | request.onprogress = function handleProgress() {};
|
937 | request.ontimeout = function handleTimeout() {};
|
938 | }
|
939 |
|
940 |
|
941 | if (config.auth) {
|
942 | var username = config.auth.username || '';
|
943 | var password = config.auth.password || '';
|
944 | requestHeaders.Authorization = 'Basic ' + btoa(username + ':' + password);
|
945 | }
|
946 |
|
947 | request.open(config.method.toUpperCase(), buildURL(config.url, config.params, config.paramsSerializer), true);
|
948 |
|
949 |
|
950 | request.timeout = config.timeout;
|
951 |
|
952 |
|
953 | request[loadEvent] = function handleLoad() {
|
954 | if (!request || (request.readyState !== 4 && !xDomain)) {
|
955 | return;
|
956 | }
|
957 |
|
958 |
|
959 |
|
960 |
|
961 |
|
962 | if (request.status === 0 && !(request.responseURL && request.responseURL.indexOf('file:') === 0)) {
|
963 | return;
|
964 | }
|
965 |
|
966 |
|
967 | var responseHeaders = 'getAllResponseHeaders' in request ? parseHeaders(request.getAllResponseHeaders()) : null;
|
968 | var responseData = !config.responseType || config.responseType === 'text' ? request.responseText : request.response;
|
969 | var response = {
|
970 | data: responseData,
|
971 |
|
972 | status: request.status === 1223 ? 204 : request.status,
|
973 | statusText: request.status === 1223 ? 'No Content' : request.statusText,
|
974 | headers: responseHeaders,
|
975 | config: config,
|
976 | request: request
|
977 | };
|
978 |
|
979 | settle(resolve, reject, response);
|
980 |
|
981 |
|
982 | request = null;
|
983 | };
|
984 |
|
985 |
|
986 | request.onerror = function handleError() {
|
987 |
|
988 |
|
989 | reject(createError('Network Error', config, null, request));
|
990 |
|
991 |
|
992 | request = null;
|
993 | };
|
994 |
|
995 |
|
996 | request.ontimeout = function handleTimeout() {
|
997 | reject(createError('timeout of ' + config.timeout + 'ms exceeded', config, 'ECONNABORTED',
|
998 | request));
|
999 |
|
1000 |
|
1001 | request = null;
|
1002 | };
|
1003 |
|
1004 |
|
1005 |
|
1006 |
|
1007 | if (utils.isStandardBrowserEnv()) {
|
1008 | var cookies = __webpack_require__(18);
|
1009 |
|
1010 |
|
1011 | var xsrfValue = (config.withCredentials || isURLSameOrigin(config.url)) && config.xsrfCookieName ?
|
1012 | cookies.read(config.xsrfCookieName) :
|
1013 | undefined;
|
1014 |
|
1015 | if (xsrfValue) {
|
1016 | requestHeaders[config.xsrfHeaderName] = xsrfValue;
|
1017 | }
|
1018 | }
|
1019 |
|
1020 |
|
1021 | if ('setRequestHeader' in request) {
|
1022 | utils.forEach(requestHeaders, function setRequestHeader(val, key) {
|
1023 | if (typeof requestData === 'undefined' && key.toLowerCase() === 'content-type') {
|
1024 |
|
1025 | delete requestHeaders[key];
|
1026 | } else {
|
1027 |
|
1028 | request.setRequestHeader(key, val);
|
1029 | }
|
1030 | });
|
1031 | }
|
1032 |
|
1033 |
|
1034 | if (config.withCredentials) {
|
1035 | request.withCredentials = true;
|
1036 | }
|
1037 |
|
1038 |
|
1039 | if (config.responseType) {
|
1040 | try {
|
1041 | request.responseType = config.responseType;
|
1042 | } catch (e) {
|
1043 |
|
1044 |
|
1045 | if (config.responseType !== 'json') {
|
1046 | throw e;
|
1047 | }
|
1048 | }
|
1049 | }
|
1050 |
|
1051 |
|
1052 | if (typeof config.onDownloadProgress === 'function') {
|
1053 | request.addEventListener('progress', config.onDownloadProgress);
|
1054 | }
|
1055 |
|
1056 |
|
1057 | if (typeof config.onUploadProgress === 'function' && request.upload) {
|
1058 | request.upload.addEventListener('progress', config.onUploadProgress);
|
1059 | }
|
1060 |
|
1061 | if (config.cancelToken) {
|
1062 |
|
1063 | config.cancelToken.promise.then(function onCanceled(cancel) {
|
1064 | if (!request) {
|
1065 | return;
|
1066 | }
|
1067 |
|
1068 | request.abort();
|
1069 | reject(cancel);
|
1070 |
|
1071 | request = null;
|
1072 | });
|
1073 | }
|
1074 |
|
1075 | if (requestData === undefined) {
|
1076 | requestData = null;
|
1077 | }
|
1078 |
|
1079 |
|
1080 | request.send(requestData);
|
1081 | });
|
1082 | };
|
1083 |
|
1084 |
|
1085 | }),
|
1086 |
|
1087 | (function(module, exports, __webpack_require__) {
|
1088 |
|
1089 | "use strict";
|
1090 |
|
1091 |
|
1092 | var createError = __webpack_require__(12);
|
1093 |
|
1094 |
|
1095 |
|
1096 |
|
1097 |
|
1098 |
|
1099 |
|
1100 |
|
1101 | module.exports = function settle(resolve, reject, response) {
|
1102 | var validateStatus = response.config.validateStatus;
|
1103 |
|
1104 | if (!response.status || !validateStatus || validateStatus(response.status)) {
|
1105 | resolve(response);
|
1106 | } else {
|
1107 | reject(createError(
|
1108 | 'Request failed with status code ' + response.status,
|
1109 | response.config,
|
1110 | null,
|
1111 | response.request,
|
1112 | response
|
1113 | ));
|
1114 | }
|
1115 | };
|
1116 |
|
1117 |
|
1118 | }),
|
1119 |
|
1120 | (function(module, exports, __webpack_require__) {
|
1121 |
|
1122 | "use strict";
|
1123 |
|
1124 |
|
1125 | var enhanceError = __webpack_require__(13);
|
1126 |
|
1127 |
|
1128 |
|
1129 |
|
1130 |
|
1131 |
|
1132 |
|
1133 |
|
1134 |
|
1135 |
|
1136 |
|
1137 | module.exports = function createError(message, config, code, request, response) {
|
1138 | var error = new Error(message);
|
1139 | return enhanceError(error, config, code, request, response);
|
1140 | };
|
1141 |
|
1142 |
|
1143 | }),
|
1144 |
|
1145 | (function(module, exports, __webpack_require__) {
|
1146 |
|
1147 | "use strict";
|
1148 |
|
1149 |
|
1150 |
|
1151 |
|
1152 |
|
1153 |
|
1154 |
|
1155 |
|
1156 |
|
1157 |
|
1158 |
|
1159 |
|
1160 | module.exports = function enhanceError(error, config, code, request, response) {
|
1161 | error.config = config;
|
1162 | if (code) {
|
1163 | error.code = code;
|
1164 | }
|
1165 | error.request = request;
|
1166 | error.response = response;
|
1167 | return error;
|
1168 | };
|
1169 |
|
1170 |
|
1171 | }),
|
1172 |
|
1173 | (function(module, exports, __webpack_require__) {
|
1174 |
|
1175 | "use strict";
|
1176 |
|
1177 |
|
1178 | var utils = __webpack_require__(3);
|
1179 |
|
1180 | function encode(val) {
|
1181 | return encodeURIComponent(val).
|
1182 | replace(/%40/gi, '@').
|
1183 | replace(/%3A/gi, ':').
|
1184 | replace(/%24/g, '$').
|
1185 | replace(/%2C/gi, ',').
|
1186 | replace(/%20/g, '+').
|
1187 | replace(/%5B/gi, '[').
|
1188 | replace(/%5D/gi, ']');
|
1189 | }
|
1190 |
|
1191 |
|
1192 |
|
1193 |
|
1194 |
|
1195 |
|
1196 |
|
1197 |
|
1198 | module.exports = function buildURL(url, params, paramsSerializer) {
|
1199 |
|
1200 | if (!params) {
|
1201 | return url;
|
1202 | }
|
1203 |
|
1204 | var serializedParams;
|
1205 | if (paramsSerializer) {
|
1206 | serializedParams = paramsSerializer(params);
|
1207 | } else if (utils.isURLSearchParams(params)) {
|
1208 | serializedParams = params.toString();
|
1209 | } else {
|
1210 | var parts = [];
|
1211 |
|
1212 | utils.forEach(params, function serialize(val, key) {
|
1213 | if (val === null || typeof val === 'undefined') {
|
1214 | return;
|
1215 | }
|
1216 |
|
1217 | if (utils.isArray(val)) {
|
1218 | key = key + '[]';
|
1219 | } else {
|
1220 | val = [val];
|
1221 | }
|
1222 |
|
1223 | utils.forEach(val, function parseValue(v) {
|
1224 | if (utils.isDate(v)) {
|
1225 | v = v.toISOString();
|
1226 | } else if (utils.isObject(v)) {
|
1227 | v = JSON.stringify(v);
|
1228 | }
|
1229 | parts.push(encode(key) + '=' + encode(v));
|
1230 | });
|
1231 | });
|
1232 |
|
1233 | serializedParams = parts.join('&');
|
1234 | }
|
1235 |
|
1236 | if (serializedParams) {
|
1237 | url += (url.indexOf('?') === -1 ? '?' : '&') + serializedParams;
|
1238 | }
|
1239 |
|
1240 | return url;
|
1241 | };
|
1242 |
|
1243 |
|
1244 | }),
|
1245 |
|
1246 | (function(module, exports, __webpack_require__) {
|
1247 |
|
1248 | "use strict";
|
1249 |
|
1250 |
|
1251 | var utils = __webpack_require__(3);
|
1252 |
|
1253 |
|
1254 |
|
1255 | var ignoreDuplicateOf = [
|
1256 | 'age', 'authorization', 'content-length', 'content-type', 'etag',
|
1257 | 'expires', 'from', 'host', 'if-modified-since', 'if-unmodified-since',
|
1258 | 'last-modified', 'location', 'max-forwards', 'proxy-authorization',
|
1259 | 'referer', 'retry-after', 'user-agent'
|
1260 | ];
|
1261 |
|
1262 |
|
1263 |
|
1264 |
|
1265 |
|
1266 |
|
1267 |
|
1268 |
|
1269 |
|
1270 |
|
1271 |
|
1272 |
|
1273 |
|
1274 |
|
1275 | module.exports = function parseHeaders(headers) {
|
1276 | var parsed = {};
|
1277 | var key;
|
1278 | var val;
|
1279 | var i;
|
1280 |
|
1281 | if (!headers) { return parsed; }
|
1282 |
|
1283 | utils.forEach(headers.split('\n'), function parser(line) {
|
1284 | i = line.indexOf(':');
|
1285 | key = utils.trim(line.substr(0, i)).toLowerCase();
|
1286 | val = utils.trim(line.substr(i + 1));
|
1287 |
|
1288 | if (key) {
|
1289 | if (parsed[key] && ignoreDuplicateOf.indexOf(key) >= 0) {
|
1290 | return;
|
1291 | }
|
1292 | if (key === 'set-cookie') {
|
1293 | parsed[key] = (parsed[key] ? parsed[key] : []).concat([val]);
|
1294 | } else {
|
1295 | parsed[key] = parsed[key] ? parsed[key] + ', ' + val : val;
|
1296 | }
|
1297 | }
|
1298 | });
|
1299 |
|
1300 | return parsed;
|
1301 | };
|
1302 |
|
1303 |
|
1304 | }),
|
1305 |
|
1306 | (function(module, exports, __webpack_require__) {
|
1307 |
|
1308 | "use strict";
|
1309 |
|
1310 |
|
1311 | var utils = __webpack_require__(3);
|
1312 |
|
1313 | module.exports = (
|
1314 | utils.isStandardBrowserEnv() ?
|
1315 |
|
1316 |
|
1317 |
|
1318 | (function standardBrowserEnv() {
|
1319 | var msie = /(msie|trident)/i.test(navigator.userAgent);
|
1320 | var urlParsingNode = document.createElement('a');
|
1321 | var originURL;
|
1322 |
|
1323 | |
1324 |
|
1325 |
|
1326 |
|
1327 |
|
1328 |
|
1329 | function resolveURL(url) {
|
1330 | var href = url;
|
1331 |
|
1332 | if (msie) {
|
1333 |
|
1334 | urlParsingNode.setAttribute('href', href);
|
1335 | href = urlParsingNode.href;
|
1336 | }
|
1337 |
|
1338 | urlParsingNode.setAttribute('href', href);
|
1339 |
|
1340 |
|
1341 | return {
|
1342 | href: urlParsingNode.href,
|
1343 | protocol: urlParsingNode.protocol ? urlParsingNode.protocol.replace(/:$/, '') : '',
|
1344 | host: urlParsingNode.host,
|
1345 | search: urlParsingNode.search ? urlParsingNode.search.replace(/^\?/, '') : '',
|
1346 | hash: urlParsingNode.hash ? urlParsingNode.hash.replace(/^#/, '') : '',
|
1347 | hostname: urlParsingNode.hostname,
|
1348 | port: urlParsingNode.port,
|
1349 | pathname: (urlParsingNode.pathname.charAt(0) === '/') ?
|
1350 | urlParsingNode.pathname :
|
1351 | '/' + urlParsingNode.pathname
|
1352 | };
|
1353 | }
|
1354 |
|
1355 | originURL = resolveURL(window.location.href);
|
1356 |
|
1357 | |
1358 |
|
1359 |
|
1360 |
|
1361 |
|
1362 |
|
1363 | return function isURLSameOrigin(requestURL) {
|
1364 | var parsed = (utils.isString(requestURL)) ? resolveURL(requestURL) : requestURL;
|
1365 | return (parsed.protocol === originURL.protocol &&
|
1366 | parsed.host === originURL.host);
|
1367 | };
|
1368 | })() :
|
1369 |
|
1370 |
|
1371 | (function nonStandardBrowserEnv() {
|
1372 | return function isURLSameOrigin() {
|
1373 | return true;
|
1374 | };
|
1375 | })()
|
1376 | );
|
1377 |
|
1378 |
|
1379 | }),
|
1380 |
|
1381 | (function(module, exports, __webpack_require__) {
|
1382 |
|
1383 | "use strict";
|
1384 |
|
1385 |
|
1386 |
|
1387 |
|
1388 | var chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=';
|
1389 |
|
1390 | function E() {
|
1391 | this.message = 'String contains an invalid character';
|
1392 | }
|
1393 | E.prototype = new Error;
|
1394 | E.prototype.code = 5;
|
1395 | E.prototype.name = 'InvalidCharacterError';
|
1396 |
|
1397 | function btoa(input) {
|
1398 | var str = String(input);
|
1399 | var output = '';
|
1400 | for (
|
1401 |
|
1402 | var block, charCode, idx = 0, map = chars;
|
1403 |
|
1404 |
|
1405 |
|
1406 | str.charAt(idx | 0) || (map = '=', idx % 1);
|
1407 |
|
1408 | output += map.charAt(63 & block >> 8 - idx % 1 * 8)
|
1409 | ) {
|
1410 | charCode = str.charCodeAt(idx += 3 / 4);
|
1411 | if (charCode > 0xFF) {
|
1412 | throw new E();
|
1413 | }
|
1414 | block = block << 8 | charCode;
|
1415 | }
|
1416 | return output;
|
1417 | }
|
1418 |
|
1419 | module.exports = btoa;
|
1420 |
|
1421 |
|
1422 | }),
|
1423 |
|
1424 | (function(module, exports, __webpack_require__) {
|
1425 |
|
1426 | "use strict";
|
1427 |
|
1428 |
|
1429 | var utils = __webpack_require__(3);
|
1430 |
|
1431 | module.exports = (
|
1432 | utils.isStandardBrowserEnv() ?
|
1433 |
|
1434 |
|
1435 | (function standardBrowserEnv() {
|
1436 | return {
|
1437 | write: function write(name, value, expires, path, domain, secure) {
|
1438 | var cookie = [];
|
1439 | cookie.push(name + '=' + encodeURIComponent(value));
|
1440 |
|
1441 | if (utils.isNumber(expires)) {
|
1442 | cookie.push('expires=' + new Date(expires).toGMTString());
|
1443 | }
|
1444 |
|
1445 | if (utils.isString(path)) {
|
1446 | cookie.push('path=' + path);
|
1447 | }
|
1448 |
|
1449 | if (utils.isString(domain)) {
|
1450 | cookie.push('domain=' + domain);
|
1451 | }
|
1452 |
|
1453 | if (secure === true) {
|
1454 | cookie.push('secure');
|
1455 | }
|
1456 |
|
1457 | document.cookie = cookie.join('; ');
|
1458 | },
|
1459 |
|
1460 | read: function read(name) {
|
1461 | var match = document.cookie.match(new RegExp('(^|;\\s*)(' + name + ')=([^;]*)'));
|
1462 | return (match ? decodeURIComponent(match[3]) : null);
|
1463 | },
|
1464 |
|
1465 | remove: function remove(name) {
|
1466 | this.write(name, '', Date.now() - 86400000);
|
1467 | }
|
1468 | };
|
1469 | })() :
|
1470 |
|
1471 |
|
1472 | (function nonStandardBrowserEnv() {
|
1473 | return {
|
1474 | write: function write() {},
|
1475 | read: function read() { return null; },
|
1476 | remove: function remove() {}
|
1477 | };
|
1478 | })()
|
1479 | );
|
1480 |
|
1481 |
|
1482 | }),
|
1483 |
|
1484 | (function(module, exports, __webpack_require__) {
|
1485 |
|
1486 | "use strict";
|
1487 |
|
1488 |
|
1489 | var utils = __webpack_require__(3);
|
1490 |
|
1491 | function InterceptorManager() {
|
1492 | this.handlers = [];
|
1493 | }
|
1494 |
|
1495 |
|
1496 |
|
1497 |
|
1498 |
|
1499 |
|
1500 |
|
1501 |
|
1502 |
|
1503 | InterceptorManager.prototype.use = function use(fulfilled, rejected) {
|
1504 | this.handlers.push({
|
1505 | fulfilled: fulfilled,
|
1506 | rejected: rejected
|
1507 | });
|
1508 | return this.handlers.length - 1;
|
1509 | };
|
1510 |
|
1511 |
|
1512 |
|
1513 |
|
1514 |
|
1515 |
|
1516 | InterceptorManager.prototype.eject = function eject(id) {
|
1517 | if (this.handlers[id]) {
|
1518 | this.handlers[id] = null;
|
1519 | }
|
1520 | };
|
1521 |
|
1522 |
|
1523 |
|
1524 |
|
1525 |
|
1526 |
|
1527 |
|
1528 |
|
1529 |
|
1530 | InterceptorManager.prototype.forEach = function forEach(fn) {
|
1531 | utils.forEach(this.handlers, function forEachHandler(h) {
|
1532 | if (h !== null) {
|
1533 | fn(h);
|
1534 | }
|
1535 | });
|
1536 | };
|
1537 |
|
1538 | module.exports = InterceptorManager;
|
1539 |
|
1540 |
|
1541 | }),
|
1542 |
|
1543 | (function(module, exports, __webpack_require__) {
|
1544 |
|
1545 | "use strict";
|
1546 |
|
1547 |
|
1548 | var utils = __webpack_require__(3);
|
1549 | var transformData = __webpack_require__(21);
|
1550 | var isCancel = __webpack_require__(22);
|
1551 | var defaults = __webpack_require__(7);
|
1552 | var isAbsoluteURL = __webpack_require__(23);
|
1553 | var combineURLs = __webpack_require__(24);
|
1554 |
|
1555 |
|
1556 |
|
1557 |
|
1558 | function throwIfCancellationRequested(config) {
|
1559 | if (config.cancelToken) {
|
1560 | config.cancelToken.throwIfRequested();
|
1561 | }
|
1562 | }
|
1563 |
|
1564 |
|
1565 |
|
1566 |
|
1567 |
|
1568 |
|
1569 |
|
1570 | module.exports = function dispatchRequest(config) {
|
1571 | throwIfCancellationRequested(config);
|
1572 |
|
1573 |
|
1574 | if (config.baseURL && !isAbsoluteURL(config.url)) {
|
1575 | config.url = combineURLs(config.baseURL, config.url);
|
1576 | }
|
1577 |
|
1578 |
|
1579 | config.headers = config.headers || {};
|
1580 |
|
1581 |
|
1582 | config.data = transformData(
|
1583 | config.data,
|
1584 | config.headers,
|
1585 | config.transformRequest
|
1586 | );
|
1587 |
|
1588 |
|
1589 | config.headers = utils.merge(
|
1590 | config.headers.common || {},
|
1591 | config.headers[config.method] || {},
|
1592 | config.headers || {}
|
1593 | );
|
1594 |
|
1595 | utils.forEach(
|
1596 | ['delete', 'get', 'head', 'post', 'put', 'patch', 'common'],
|
1597 | function cleanHeaderConfig(method) {
|
1598 | delete config.headers[method];
|
1599 | }
|
1600 | );
|
1601 |
|
1602 | var adapter = config.adapter || defaults.adapter;
|
1603 |
|
1604 | return adapter(config).then(function onAdapterResolution(response) {
|
1605 | throwIfCancellationRequested(config);
|
1606 |
|
1607 |
|
1608 | response.data = transformData(
|
1609 | response.data,
|
1610 | response.headers,
|
1611 | config.transformResponse
|
1612 | );
|
1613 |
|
1614 | return response;
|
1615 | }, function onAdapterRejection(reason) {
|
1616 | if (!isCancel(reason)) {
|
1617 | throwIfCancellationRequested(config);
|
1618 |
|
1619 |
|
1620 | if (reason && reason.response) {
|
1621 | reason.response.data = transformData(
|
1622 | reason.response.data,
|
1623 | reason.response.headers,
|
1624 | config.transformResponse
|
1625 | );
|
1626 | }
|
1627 | }
|
1628 |
|
1629 | return Promise.reject(reason);
|
1630 | });
|
1631 | };
|
1632 |
|
1633 |
|
1634 | }),
|
1635 |
|
1636 | (function(module, exports, __webpack_require__) {
|
1637 |
|
1638 | "use strict";
|
1639 |
|
1640 |
|
1641 | var utils = __webpack_require__(3);
|
1642 |
|
1643 |
|
1644 |
|
1645 |
|
1646 |
|
1647 |
|
1648 |
|
1649 |
|
1650 |
|
1651 | module.exports = function transformData(data, headers, fns) {
|
1652 |
|
1653 | utils.forEach(fns, function transform(fn) {
|
1654 | data = fn(data, headers);
|
1655 | });
|
1656 |
|
1657 | return data;
|
1658 | };
|
1659 |
|
1660 |
|
1661 | }),
|
1662 |
|
1663 | (function(module, exports, __webpack_require__) {
|
1664 |
|
1665 | "use strict";
|
1666 |
|
1667 |
|
1668 | module.exports = function isCancel(value) {
|
1669 | return !!(value && value.__CANCEL__);
|
1670 | };
|
1671 |
|
1672 |
|
1673 | }),
|
1674 |
|
1675 | (function(module, exports, __webpack_require__) {
|
1676 |
|
1677 | "use strict";
|
1678 |
|
1679 |
|
1680 |
|
1681 |
|
1682 |
|
1683 |
|
1684 |
|
1685 |
|
1686 | module.exports = function isAbsoluteURL(url) {
|
1687 |
|
1688 |
|
1689 |
|
1690 | return /^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(url);
|
1691 | };
|
1692 |
|
1693 |
|
1694 | }),
|
1695 |
|
1696 | (function(module, exports, __webpack_require__) {
|
1697 |
|
1698 | "use strict";
|
1699 |
|
1700 |
|
1701 |
|
1702 |
|
1703 |
|
1704 |
|
1705 |
|
1706 |
|
1707 |
|
1708 | module.exports = function combineURLs(baseURL, relativeURL) {
|
1709 | return relativeURL
|
1710 | ? baseURL.replace(/\/+$/, '') + '/' + relativeURL.replace(/^\/+/, '')
|
1711 | : baseURL;
|
1712 | };
|
1713 |
|
1714 |
|
1715 | }),
|
1716 |
|
1717 | (function(module, exports, __webpack_require__) {
|
1718 |
|
1719 | "use strict";
|
1720 |
|
1721 |
|
1722 |
|
1723 |
|
1724 |
|
1725 |
|
1726 |
|
1727 |
|
1728 | function Cancel(message) {
|
1729 | this.message = message;
|
1730 | }
|
1731 |
|
1732 | Cancel.prototype.toString = function toString() {
|
1733 | return 'Cancel' + (this.message ? ': ' + this.message : '');
|
1734 | };
|
1735 |
|
1736 | Cancel.prototype.__CANCEL__ = true;
|
1737 |
|
1738 | module.exports = Cancel;
|
1739 |
|
1740 |
|
1741 | }),
|
1742 |
|
1743 | (function(module, exports, __webpack_require__) {
|
1744 |
|
1745 | "use strict";
|
1746 |
|
1747 |
|
1748 | var Cancel = __webpack_require__(25);
|
1749 |
|
1750 |
|
1751 |
|
1752 |
|
1753 |
|
1754 |
|
1755 |
|
1756 | function CancelToken(executor) {
|
1757 | if (typeof executor !== 'function') {
|
1758 | throw new TypeError('executor must be a function.');
|
1759 | }
|
1760 |
|
1761 | var resolvePromise;
|
1762 | this.promise = new Promise(function promiseExecutor(resolve) {
|
1763 | resolvePromise = resolve;
|
1764 | });
|
1765 |
|
1766 | var token = this;
|
1767 | executor(function cancel(message) {
|
1768 | if (token.reason) {
|
1769 |
|
1770 | return;
|
1771 | }
|
1772 |
|
1773 | token.reason = new Cancel(message);
|
1774 | resolvePromise(token.reason);
|
1775 | });
|
1776 | }
|
1777 |
|
1778 |
|
1779 |
|
1780 |
|
1781 | CancelToken.prototype.throwIfRequested = function throwIfRequested() {
|
1782 | if (this.reason) {
|
1783 | throw this.reason;
|
1784 | }
|
1785 | };
|
1786 |
|
1787 |
|
1788 |
|
1789 |
|
1790 |
|
1791 | CancelToken.source = function source() {
|
1792 | var cancel;
|
1793 | var token = new CancelToken(function executor(c) {
|
1794 | cancel = c;
|
1795 | });
|
1796 | return {
|
1797 | token: token,
|
1798 | cancel: cancel
|
1799 | };
|
1800 | };
|
1801 |
|
1802 | module.exports = CancelToken;
|
1803 |
|
1804 |
|
1805 | }),
|
1806 |
|
1807 | (function(module, exports, __webpack_require__) {
|
1808 |
|
1809 | "use strict";
|
1810 |
|
1811 |
|
1812 |
|
1813 |
|
1814 |
|
1815 |
|
1816 |
|
1817 |
|
1818 |
|
1819 |
|
1820 |
|
1821 |
|
1822 |
|
1823 |
|
1824 |
|
1825 |
|
1826 |
|
1827 |
|
1828 |
|
1829 |
|
1830 |
|
1831 |
|
1832 | module.exports = function spread(callback) {
|
1833 | return function wrap(arr) {
|
1834 | return callback.apply(null, arr);
|
1835 | };
|
1836 | };
|
1837 |
|
1838 |
|
1839 | })
|
1840 | ]); |
\ | No newline at end of file |