xianniu-ui 0.5.1 → 0.5.2-beta.1

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.
Files changed (35) hide show
  1. package/lib/static/css/chunk-elementUI.0b417c2d.css +1 -0
  2. package/lib/static/css/xianniu-ui.umd.5be6bd50.css +1 -0
  3. package/lib/static/css/xianniu-ui.umd.min.5be6bd50.css +1 -0
  4. package/lib/static/fonts/element-icons.535877f5.woff +0 -0
  5. package/lib/static/fonts/element-icons.732389de.ttf +0 -0
  6. package/lib/xianniu-ui.common.chunk-elementUI.js +1680 -0
  7. package/lib/xianniu-ui.common.chunk-libs~253ae210.js +2594 -0
  8. package/lib/xianniu-ui.common.chunk-libs~31ecd969.js +1250 -0
  9. package/lib/xianniu-ui.common.chunk-libs~93acefaf.js +3328 -0
  10. package/lib/xianniu-ui.common.chunk-libs~af0f4b76.js +17212 -0
  11. package/lib/xianniu-ui.common.chunk-libs~d939e436.js +2292 -0
  12. package/lib/xianniu-ui.common.chunk-libs~dfe5688e.js +4924 -0
  13. package/lib/xianniu-ui.common.js +55 -122634
  14. package/lib/xianniu-ui.common.xianniu-ui.common.js +17174 -0
  15. package/lib/xianniu-ui.umd.chunk-elementUI.js +1680 -0
  16. package/lib/xianniu-ui.umd.chunk-libs~253ae210.js +2594 -0
  17. package/lib/xianniu-ui.umd.chunk-libs~31ecd969.js +1250 -0
  18. package/lib/xianniu-ui.umd.chunk-libs~93acefaf.js +3328 -0
  19. package/lib/xianniu-ui.umd.chunk-libs~af0f4b76.js +17212 -0
  20. package/lib/xianniu-ui.umd.chunk-libs~d939e436.js +2292 -0
  21. package/lib/xianniu-ui.umd.chunk-libs~dfe5688e.js +4924 -0
  22. package/lib/xianniu-ui.umd.js +56 -122645
  23. package/lib/xianniu-ui.umd.min.chunk-elementUI.js +1 -0
  24. package/lib/xianniu-ui.umd.min.chunk-libs~253ae210.js +1 -0
  25. package/lib/xianniu-ui.umd.min.chunk-libs~31ecd969.js +1 -0
  26. package/lib/xianniu-ui.umd.min.chunk-libs~93acefaf.js +1 -0
  27. package/lib/xianniu-ui.umd.min.chunk-libs~af0f4b76.js +9 -0
  28. package/lib/xianniu-ui.umd.min.chunk-libs~d939e436.js +1 -0
  29. package/lib/xianniu-ui.umd.min.chunk-libs~dfe5688e.js +8 -0
  30. package/lib/xianniu-ui.umd.min.js +1 -39
  31. package/lib/xianniu-ui.umd.min.xianniu-ui.umd.min.js +1 -0
  32. package/lib/xianniu-ui.umd.xianniu-ui.umd.js +17184 -0
  33. package/package.json +1 -1
  34. package/packages/search/main.vue +1 -1
  35. /package/lib/{xianniu-ui.css → static/css/xianniu-ui.common.5be6bd50.css} +0 -0
@@ -0,0 +1,1250 @@
1
+ ((typeof self !== 'undefined' ? self : this)["webpackJsonpxianniu_ui"] = (typeof self !== 'undefined' ? self : this)["webpackJsonpxianniu_ui"] || []).push([[2],{
2
+
3
+ /***/ "3dd2":
4
+ /***/ (function(module, exports, __webpack_require__) {
5
+
6
+ !function(t,e){ true?module.exports=e():undefined}(this,(function(){"use strict";var t=1e3,e=6e4,n=36e5,r="millisecond",i="second",s="minute",u="hour",a="day",o="week",f="month",h="quarter",c="year",d="date",l="Invalid Date",$=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,y=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,M={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(t){var e=["th","st","nd","rd"],n=t%100;return"["+t+(e[(n-20)%10]||e[n]||e[0])+"]"}},m=function(t,e,n){var r=String(t);return!r||r.length>=e?t:""+Array(e+1-r.length).join(n)+t},v={s:m,z:function(t){var e=-t.utcOffset(),n=Math.abs(e),r=Math.floor(n/60),i=n%60;return(e<=0?"+":"-")+m(r,2,"0")+":"+m(i,2,"0")},m:function t(e,n){if(e.date()<n.date())return-t(n,e);var r=12*(n.year()-e.year())+(n.month()-e.month()),i=e.clone().add(r,f),s=n-i<0,u=e.clone().add(r+(s?-1:1),f);return+(-(r+(n-i)/(s?i-u:u-i))||0)},a:function(t){return t<0?Math.ceil(t)||0:Math.floor(t)},p:function(t){return{M:f,y:c,w:o,d:a,D:d,h:u,m:s,s:i,ms:r,Q:h}[t]||String(t||"").toLowerCase().replace(/s$/,"")},u:function(t){return void 0===t}},g="en",D={};D[g]=M;var p=function(t){return t instanceof _},S=function t(e,n,r){var i;if(!e)return g;if("string"==typeof e){var s=e.toLowerCase();D[s]&&(i=s),n&&(D[s]=n,i=s);var u=e.split("-");if(!i&&u.length>1)return t(u[0])}else{var a=e.name;D[a]=e,i=a}return!r&&i&&(g=i),i||!r&&g},w=function(t,e){if(p(t))return t.clone();var n="object"==typeof e?e:{};return n.date=t,n.args=arguments,new _(n)},O=v;O.l=S,O.i=p,O.w=function(t,e){return w(t,{locale:e.$L,utc:e.$u,x:e.$x,$offset:e.$offset})};var _=function(){function M(t){this.$L=S(t.locale,null,!0),this.parse(t)}var m=M.prototype;return m.parse=function(t){this.$d=function(t){var e=t.date,n=t.utc;if(null===e)return new Date(NaN);if(O.u(e))return new Date;if(e instanceof Date)return new Date(e);if("string"==typeof e&&!/Z$/i.test(e)){var r=e.match($);if(r){var i=r[2]-1||0,s=(r[7]||"0").substring(0,3);return n?new Date(Date.UTC(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,s)):new Date(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,s)}}return new Date(e)}(t),this.$x=t.x||{},this.init()},m.init=function(){var t=this.$d;this.$y=t.getFullYear(),this.$M=t.getMonth(),this.$D=t.getDate(),this.$W=t.getDay(),this.$H=t.getHours(),this.$m=t.getMinutes(),this.$s=t.getSeconds(),this.$ms=t.getMilliseconds()},m.$utils=function(){return O},m.isValid=function(){return!(this.$d.toString()===l)},m.isSame=function(t,e){var n=w(t);return this.startOf(e)<=n&&n<=this.endOf(e)},m.isAfter=function(t,e){return w(t)<this.startOf(e)},m.isBefore=function(t,e){return this.endOf(e)<w(t)},m.$g=function(t,e,n){return O.u(t)?this[e]:this.set(n,t)},m.unix=function(){return Math.floor(this.valueOf()/1e3)},m.valueOf=function(){return this.$d.getTime()},m.startOf=function(t,e){var n=this,r=!!O.u(e)||e,h=O.p(t),l=function(t,e){var i=O.w(n.$u?Date.UTC(n.$y,e,t):new Date(n.$y,e,t),n);return r?i:i.endOf(a)},$=function(t,e){return O.w(n.toDate()[t].apply(n.toDate("s"),(r?[0,0,0,0]:[23,59,59,999]).slice(e)),n)},y=this.$W,M=this.$M,m=this.$D,v="set"+(this.$u?"UTC":"");switch(h){case c:return r?l(1,0):l(31,11);case f:return r?l(1,M):l(0,M+1);case o:var g=this.$locale().weekStart||0,D=(y<g?y+7:y)-g;return l(r?m-D:m+(6-D),M);case a:case d:return $(v+"Hours",0);case u:return $(v+"Minutes",1);case s:return $(v+"Seconds",2);case i:return $(v+"Milliseconds",3);default:return this.clone()}},m.endOf=function(t){return this.startOf(t,!1)},m.$set=function(t,e){var n,o=O.p(t),h="set"+(this.$u?"UTC":""),l=(n={},n[a]=h+"Date",n[d]=h+"Date",n[f]=h+"Month",n[c]=h+"FullYear",n[u]=h+"Hours",n[s]=h+"Minutes",n[i]=h+"Seconds",n[r]=h+"Milliseconds",n)[o],$=o===a?this.$D+(e-this.$W):e;if(o===f||o===c){var y=this.clone().set(d,1);y.$d[l]($),y.init(),this.$d=y.set(d,Math.min(this.$D,y.daysInMonth())).$d}else l&&this.$d[l]($);return this.init(),this},m.set=function(t,e){return this.clone().$set(t,e)},m.get=function(t){return this[O.p(t)]()},m.add=function(r,h){var d,l=this;r=Number(r);var $=O.p(h),y=function(t){var e=w(l);return O.w(e.date(e.date()+Math.round(t*r)),l)};if($===f)return this.set(f,this.$M+r);if($===c)return this.set(c,this.$y+r);if($===a)return y(1);if($===o)return y(7);var M=(d={},d[s]=e,d[u]=n,d[i]=t,d)[$]||1,m=this.$d.getTime()+r*M;return O.w(m,this)},m.subtract=function(t,e){return this.add(-1*t,e)},m.format=function(t){var e=this,n=this.$locale();if(!this.isValid())return n.invalidDate||l;var r=t||"YYYY-MM-DDTHH:mm:ssZ",i=O.z(this),s=this.$H,u=this.$m,a=this.$M,o=n.weekdays,f=n.months,h=function(t,n,i,s){return t&&(t[n]||t(e,r))||i[n].slice(0,s)},c=function(t){return O.s(s%12||12,t,"0")},d=n.meridiem||function(t,e,n){var r=t<12?"AM":"PM";return n?r.toLowerCase():r},$={YY:String(this.$y).slice(-2),YYYY:this.$y,M:a+1,MM:O.s(a+1,2,"0"),MMM:h(n.monthsShort,a,f,3),MMMM:h(f,a),D:this.$D,DD:O.s(this.$D,2,"0"),d:String(this.$W),dd:h(n.weekdaysMin,this.$W,o,2),ddd:h(n.weekdaysShort,this.$W,o,3),dddd:o[this.$W],H:String(s),HH:O.s(s,2,"0"),h:c(1),hh:c(2),a:d(s,u,!0),A:d(s,u,!1),m:String(u),mm:O.s(u,2,"0"),s:String(this.$s),ss:O.s(this.$s,2,"0"),SSS:O.s(this.$ms,3,"0"),Z:i};return r.replace(y,(function(t,e){return e||$[t]||i.replace(":","")}))},m.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},m.diff=function(r,d,l){var $,y=O.p(d),M=w(r),m=(M.utcOffset()-this.utcOffset())*e,v=this-M,g=O.m(this,M);return g=($={},$[c]=g/12,$[f]=g,$[h]=g/3,$[o]=(v-m)/6048e5,$[a]=(v-m)/864e5,$[u]=v/n,$[s]=v/e,$[i]=v/t,$)[y]||v,l?g:O.a(g)},m.daysInMonth=function(){return this.endOf(f).$D},m.$locale=function(){return D[this.$L]},m.locale=function(t,e){if(!t)return this.$L;var n=this.clone(),r=S(t,e,!0);return r&&(n.$L=r),n},m.clone=function(){return O.w(this.$d,this)},m.toDate=function(){return new Date(this.valueOf())},m.toJSON=function(){return this.isValid()?this.toISOString():null},m.toISOString=function(){return this.$d.toISOString()},m.toString=function(){return this.$d.toUTCString()},M}(),T=_.prototype;return w.prototype=T,[["$ms",r],["$s",i],["$m",s],["$H",u],["$W",a],["$M",f],["$y",c],["$D",d]].forEach((function(t){T[t[1]]=function(e){return this.$g(e,t[0],t[1])}})),w.extend=function(t,e){return t.$i||(t(e,_,w),t.$i=!0),w},w.locale=S,w.isDayjs=p,w.unix=function(t){return w(1e3*t)},w.en=D[g],w.Ls=D,w.p={},w}));
7
+
8
+ /***/ }),
9
+
10
+ /***/ "62e4":
11
+ /***/ (function(module, exports) {
12
+
13
+ module.exports = function(module) {
14
+ if (!module.webpackPolyfill) {
15
+ module.deprecate = function() {};
16
+ module.paths = [];
17
+ // module.parent = undefined by default
18
+ if (!module.children) module.children = [];
19
+ Object.defineProperty(module, "loaded", {
20
+ enumerable: true,
21
+ get: function() {
22
+ return module.l;
23
+ }
24
+ });
25
+ Object.defineProperty(module, "id", {
26
+ enumerable: true,
27
+ get: function() {
28
+ return module.i;
29
+ }
30
+ });
31
+ module.webpackPolyfill = 1;
32
+ }
33
+ return module;
34
+ };
35
+
36
+
37
+ /***/ }),
38
+
39
+ /***/ "96cf":
40
+ /***/ (function(module, exports, __webpack_require__) {
41
+
42
+ /**
43
+ * Copyright (c) 2014-present, Facebook, Inc.
44
+ *
45
+ * This source code is licensed under the MIT license found in the
46
+ * LICENSE file in the root directory of this source tree.
47
+ */
48
+
49
+ var runtime = (function (exports) {
50
+ "use strict";
51
+
52
+ var Op = Object.prototype;
53
+ var hasOwn = Op.hasOwnProperty;
54
+ var undefined; // More compressible than void 0.
55
+ var $Symbol = typeof Symbol === "function" ? Symbol : {};
56
+ var iteratorSymbol = $Symbol.iterator || "@@iterator";
57
+ var asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator";
58
+ var toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag";
59
+
60
+ function define(obj, key, value) {
61
+ Object.defineProperty(obj, key, {
62
+ value: value,
63
+ enumerable: true,
64
+ configurable: true,
65
+ writable: true
66
+ });
67
+ return obj[key];
68
+ }
69
+ try {
70
+ // IE 8 has a broken Object.defineProperty that only works on DOM objects.
71
+ define({}, "");
72
+ } catch (err) {
73
+ define = function(obj, key, value) {
74
+ return obj[key] = value;
75
+ };
76
+ }
77
+
78
+ function wrap(innerFn, outerFn, self, tryLocsList) {
79
+ // If outerFn provided and outerFn.prototype is a Generator, then outerFn.prototype instanceof Generator.
80
+ var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator;
81
+ var generator = Object.create(protoGenerator.prototype);
82
+ var context = new Context(tryLocsList || []);
83
+
84
+ // The ._invoke method unifies the implementations of the .next,
85
+ // .throw, and .return methods.
86
+ generator._invoke = makeInvokeMethod(innerFn, self, context);
87
+
88
+ return generator;
89
+ }
90
+ exports.wrap = wrap;
91
+
92
+ // Try/catch helper to minimize deoptimizations. Returns a completion
93
+ // record like context.tryEntries[i].completion. This interface could
94
+ // have been (and was previously) designed to take a closure to be
95
+ // invoked without arguments, but in all the cases we care about we
96
+ // already have an existing method we want to call, so there's no need
97
+ // to create a new function object. We can even get away with assuming
98
+ // the method takes exactly one argument, since that happens to be true
99
+ // in every case, so we don't have to touch the arguments object. The
100
+ // only additional allocation required is the completion record, which
101
+ // has a stable shape and so hopefully should be cheap to allocate.
102
+ function tryCatch(fn, obj, arg) {
103
+ try {
104
+ return { type: "normal", arg: fn.call(obj, arg) };
105
+ } catch (err) {
106
+ return { type: "throw", arg: err };
107
+ }
108
+ }
109
+
110
+ var GenStateSuspendedStart = "suspendedStart";
111
+ var GenStateSuspendedYield = "suspendedYield";
112
+ var GenStateExecuting = "executing";
113
+ var GenStateCompleted = "completed";
114
+
115
+ // Returning this object from the innerFn has the same effect as
116
+ // breaking out of the dispatch switch statement.
117
+ var ContinueSentinel = {};
118
+
119
+ // Dummy constructor functions that we use as the .constructor and
120
+ // .constructor.prototype properties for functions that return Generator
121
+ // objects. For full spec compliance, you may wish to configure your
122
+ // minifier not to mangle the names of these two functions.
123
+ function Generator() {}
124
+ function GeneratorFunction() {}
125
+ function GeneratorFunctionPrototype() {}
126
+
127
+ // This is a polyfill for %IteratorPrototype% for environments that
128
+ // don't natively support it.
129
+ var IteratorPrototype = {};
130
+ define(IteratorPrototype, iteratorSymbol, function () {
131
+ return this;
132
+ });
133
+
134
+ var getProto = Object.getPrototypeOf;
135
+ var NativeIteratorPrototype = getProto && getProto(getProto(values([])));
136
+ if (NativeIteratorPrototype &&
137
+ NativeIteratorPrototype !== Op &&
138
+ hasOwn.call(NativeIteratorPrototype, iteratorSymbol)) {
139
+ // This environment has a native %IteratorPrototype%; use it instead
140
+ // of the polyfill.
141
+ IteratorPrototype = NativeIteratorPrototype;
142
+ }
143
+
144
+ var Gp = GeneratorFunctionPrototype.prototype =
145
+ Generator.prototype = Object.create(IteratorPrototype);
146
+ GeneratorFunction.prototype = GeneratorFunctionPrototype;
147
+ define(Gp, "constructor", GeneratorFunctionPrototype);
148
+ define(GeneratorFunctionPrototype, "constructor", GeneratorFunction);
149
+ GeneratorFunction.displayName = define(
150
+ GeneratorFunctionPrototype,
151
+ toStringTagSymbol,
152
+ "GeneratorFunction"
153
+ );
154
+
155
+ // Helper for defining the .next, .throw, and .return methods of the
156
+ // Iterator interface in terms of a single ._invoke method.
157
+ function defineIteratorMethods(prototype) {
158
+ ["next", "throw", "return"].forEach(function(method) {
159
+ define(prototype, method, function(arg) {
160
+ return this._invoke(method, arg);
161
+ });
162
+ });
163
+ }
164
+
165
+ exports.isGeneratorFunction = function(genFun) {
166
+ var ctor = typeof genFun === "function" && genFun.constructor;
167
+ return ctor
168
+ ? ctor === GeneratorFunction ||
169
+ // For the native GeneratorFunction constructor, the best we can
170
+ // do is to check its .name property.
171
+ (ctor.displayName || ctor.name) === "GeneratorFunction"
172
+ : false;
173
+ };
174
+
175
+ exports.mark = function(genFun) {
176
+ if (Object.setPrototypeOf) {
177
+ Object.setPrototypeOf(genFun, GeneratorFunctionPrototype);
178
+ } else {
179
+ genFun.__proto__ = GeneratorFunctionPrototype;
180
+ define(genFun, toStringTagSymbol, "GeneratorFunction");
181
+ }
182
+ genFun.prototype = Object.create(Gp);
183
+ return genFun;
184
+ };
185
+
186
+ // Within the body of any async function, `await x` is transformed to
187
+ // `yield regeneratorRuntime.awrap(x)`, so that the runtime can test
188
+ // `hasOwn.call(value, "__await")` to determine if the yielded value is
189
+ // meant to be awaited.
190
+ exports.awrap = function(arg) {
191
+ return { __await: arg };
192
+ };
193
+
194
+ function AsyncIterator(generator, PromiseImpl) {
195
+ function invoke(method, arg, resolve, reject) {
196
+ var record = tryCatch(generator[method], generator, arg);
197
+ if (record.type === "throw") {
198
+ reject(record.arg);
199
+ } else {
200
+ var result = record.arg;
201
+ var value = result.value;
202
+ if (value &&
203
+ typeof value === "object" &&
204
+ hasOwn.call(value, "__await")) {
205
+ return PromiseImpl.resolve(value.__await).then(function(value) {
206
+ invoke("next", value, resolve, reject);
207
+ }, function(err) {
208
+ invoke("throw", err, resolve, reject);
209
+ });
210
+ }
211
+
212
+ return PromiseImpl.resolve(value).then(function(unwrapped) {
213
+ // When a yielded Promise is resolved, its final value becomes
214
+ // the .value of the Promise<{value,done}> result for the
215
+ // current iteration.
216
+ result.value = unwrapped;
217
+ resolve(result);
218
+ }, function(error) {
219
+ // If a rejected Promise was yielded, throw the rejection back
220
+ // into the async generator function so it can be handled there.
221
+ return invoke("throw", error, resolve, reject);
222
+ });
223
+ }
224
+ }
225
+
226
+ var previousPromise;
227
+
228
+ function enqueue(method, arg) {
229
+ function callInvokeWithMethodAndArg() {
230
+ return new PromiseImpl(function(resolve, reject) {
231
+ invoke(method, arg, resolve, reject);
232
+ });
233
+ }
234
+
235
+ return previousPromise =
236
+ // If enqueue has been called before, then we want to wait until
237
+ // all previous Promises have been resolved before calling invoke,
238
+ // so that results are always delivered in the correct order. If
239
+ // enqueue has not been called before, then it is important to
240
+ // call invoke immediately, without waiting on a callback to fire,
241
+ // so that the async generator function has the opportunity to do
242
+ // any necessary setup in a predictable way. This predictability
243
+ // is why the Promise constructor synchronously invokes its
244
+ // executor callback, and why async functions synchronously
245
+ // execute code before the first await. Since we implement simple
246
+ // async functions in terms of async generators, it is especially
247
+ // important to get this right, even though it requires care.
248
+ previousPromise ? previousPromise.then(
249
+ callInvokeWithMethodAndArg,
250
+ // Avoid propagating failures to Promises returned by later
251
+ // invocations of the iterator.
252
+ callInvokeWithMethodAndArg
253
+ ) : callInvokeWithMethodAndArg();
254
+ }
255
+
256
+ // Define the unified helper method that is used to implement .next,
257
+ // .throw, and .return (see defineIteratorMethods).
258
+ this._invoke = enqueue;
259
+ }
260
+
261
+ defineIteratorMethods(AsyncIterator.prototype);
262
+ define(AsyncIterator.prototype, asyncIteratorSymbol, function () {
263
+ return this;
264
+ });
265
+ exports.AsyncIterator = AsyncIterator;
266
+
267
+ // Note that simple async functions are implemented on top of
268
+ // AsyncIterator objects; they just return a Promise for the value of
269
+ // the final result produced by the iterator.
270
+ exports.async = function(innerFn, outerFn, self, tryLocsList, PromiseImpl) {
271
+ if (PromiseImpl === void 0) PromiseImpl = Promise;
272
+
273
+ var iter = new AsyncIterator(
274
+ wrap(innerFn, outerFn, self, tryLocsList),
275
+ PromiseImpl
276
+ );
277
+
278
+ return exports.isGeneratorFunction(outerFn)
279
+ ? iter // If outerFn is a generator, return the full iterator.
280
+ : iter.next().then(function(result) {
281
+ return result.done ? result.value : iter.next();
282
+ });
283
+ };
284
+
285
+ function makeInvokeMethod(innerFn, self, context) {
286
+ var state = GenStateSuspendedStart;
287
+
288
+ return function invoke(method, arg) {
289
+ if (state === GenStateExecuting) {
290
+ throw new Error("Generator is already running");
291
+ }
292
+
293
+ if (state === GenStateCompleted) {
294
+ if (method === "throw") {
295
+ throw arg;
296
+ }
297
+
298
+ // Be forgiving, per 25.3.3.3.3 of the spec:
299
+ // https://people.mozilla.org/~jorendorff/es6-draft.html#sec-generatorresume
300
+ return doneResult();
301
+ }
302
+
303
+ context.method = method;
304
+ context.arg = arg;
305
+
306
+ while (true) {
307
+ var delegate = context.delegate;
308
+ if (delegate) {
309
+ var delegateResult = maybeInvokeDelegate(delegate, context);
310
+ if (delegateResult) {
311
+ if (delegateResult === ContinueSentinel) continue;
312
+ return delegateResult;
313
+ }
314
+ }
315
+
316
+ if (context.method === "next") {
317
+ // Setting context._sent for legacy support of Babel's
318
+ // function.sent implementation.
319
+ context.sent = context._sent = context.arg;
320
+
321
+ } else if (context.method === "throw") {
322
+ if (state === GenStateSuspendedStart) {
323
+ state = GenStateCompleted;
324
+ throw context.arg;
325
+ }
326
+
327
+ context.dispatchException(context.arg);
328
+
329
+ } else if (context.method === "return") {
330
+ context.abrupt("return", context.arg);
331
+ }
332
+
333
+ state = GenStateExecuting;
334
+
335
+ var record = tryCatch(innerFn, self, context);
336
+ if (record.type === "normal") {
337
+ // If an exception is thrown from innerFn, we leave state ===
338
+ // GenStateExecuting and loop back for another invocation.
339
+ state = context.done
340
+ ? GenStateCompleted
341
+ : GenStateSuspendedYield;
342
+
343
+ if (record.arg === ContinueSentinel) {
344
+ continue;
345
+ }
346
+
347
+ return {
348
+ value: record.arg,
349
+ done: context.done
350
+ };
351
+
352
+ } else if (record.type === "throw") {
353
+ state = GenStateCompleted;
354
+ // Dispatch the exception by looping back around to the
355
+ // context.dispatchException(context.arg) call above.
356
+ context.method = "throw";
357
+ context.arg = record.arg;
358
+ }
359
+ }
360
+ };
361
+ }
362
+
363
+ // Call delegate.iterator[context.method](context.arg) and handle the
364
+ // result, either by returning a { value, done } result from the
365
+ // delegate iterator, or by modifying context.method and context.arg,
366
+ // setting context.delegate to null, and returning the ContinueSentinel.
367
+ function maybeInvokeDelegate(delegate, context) {
368
+ var method = delegate.iterator[context.method];
369
+ if (method === undefined) {
370
+ // A .throw or .return when the delegate iterator has no .throw
371
+ // method always terminates the yield* loop.
372
+ context.delegate = null;
373
+
374
+ if (context.method === "throw") {
375
+ // Note: ["return"] must be used for ES3 parsing compatibility.
376
+ if (delegate.iterator["return"]) {
377
+ // If the delegate iterator has a return method, give it a
378
+ // chance to clean up.
379
+ context.method = "return";
380
+ context.arg = undefined;
381
+ maybeInvokeDelegate(delegate, context);
382
+
383
+ if (context.method === "throw") {
384
+ // If maybeInvokeDelegate(context) changed context.method from
385
+ // "return" to "throw", let that override the TypeError below.
386
+ return ContinueSentinel;
387
+ }
388
+ }
389
+
390
+ context.method = "throw";
391
+ context.arg = new TypeError(
392
+ "The iterator does not provide a 'throw' method");
393
+ }
394
+
395
+ return ContinueSentinel;
396
+ }
397
+
398
+ var record = tryCatch(method, delegate.iterator, context.arg);
399
+
400
+ if (record.type === "throw") {
401
+ context.method = "throw";
402
+ context.arg = record.arg;
403
+ context.delegate = null;
404
+ return ContinueSentinel;
405
+ }
406
+
407
+ var info = record.arg;
408
+
409
+ if (! info) {
410
+ context.method = "throw";
411
+ context.arg = new TypeError("iterator result is not an object");
412
+ context.delegate = null;
413
+ return ContinueSentinel;
414
+ }
415
+
416
+ if (info.done) {
417
+ // Assign the result of the finished delegate to the temporary
418
+ // variable specified by delegate.resultName (see delegateYield).
419
+ context[delegate.resultName] = info.value;
420
+
421
+ // Resume execution at the desired location (see delegateYield).
422
+ context.next = delegate.nextLoc;
423
+
424
+ // If context.method was "throw" but the delegate handled the
425
+ // exception, let the outer generator proceed normally. If
426
+ // context.method was "next", forget context.arg since it has been
427
+ // "consumed" by the delegate iterator. If context.method was
428
+ // "return", allow the original .return call to continue in the
429
+ // outer generator.
430
+ if (context.method !== "return") {
431
+ context.method = "next";
432
+ context.arg = undefined;
433
+ }
434
+
435
+ } else {
436
+ // Re-yield the result returned by the delegate method.
437
+ return info;
438
+ }
439
+
440
+ // The delegate iterator is finished, so forget it and continue with
441
+ // the outer generator.
442
+ context.delegate = null;
443
+ return ContinueSentinel;
444
+ }
445
+
446
+ // Define Generator.prototype.{next,throw,return} in terms of the
447
+ // unified ._invoke helper method.
448
+ defineIteratorMethods(Gp);
449
+
450
+ define(Gp, toStringTagSymbol, "Generator");
451
+
452
+ // A Generator should always return itself as the iterator object when the
453
+ // @@iterator function is called on it. Some browsers' implementations of the
454
+ // iterator prototype chain incorrectly implement this, causing the Generator
455
+ // object to not be returned from this call. This ensures that doesn't happen.
456
+ // See https://github.com/facebook/regenerator/issues/274 for more details.
457
+ define(Gp, iteratorSymbol, function() {
458
+ return this;
459
+ });
460
+
461
+ define(Gp, "toString", function() {
462
+ return "[object Generator]";
463
+ });
464
+
465
+ function pushTryEntry(locs) {
466
+ var entry = { tryLoc: locs[0] };
467
+
468
+ if (1 in locs) {
469
+ entry.catchLoc = locs[1];
470
+ }
471
+
472
+ if (2 in locs) {
473
+ entry.finallyLoc = locs[2];
474
+ entry.afterLoc = locs[3];
475
+ }
476
+
477
+ this.tryEntries.push(entry);
478
+ }
479
+
480
+ function resetTryEntry(entry) {
481
+ var record = entry.completion || {};
482
+ record.type = "normal";
483
+ delete record.arg;
484
+ entry.completion = record;
485
+ }
486
+
487
+ function Context(tryLocsList) {
488
+ // The root entry object (effectively a try statement without a catch
489
+ // or a finally block) gives us a place to store values thrown from
490
+ // locations where there is no enclosing try statement.
491
+ this.tryEntries = [{ tryLoc: "root" }];
492
+ tryLocsList.forEach(pushTryEntry, this);
493
+ this.reset(true);
494
+ }
495
+
496
+ exports.keys = function(object) {
497
+ var keys = [];
498
+ for (var key in object) {
499
+ keys.push(key);
500
+ }
501
+ keys.reverse();
502
+
503
+ // Rather than returning an object with a next method, we keep
504
+ // things simple and return the next function itself.
505
+ return function next() {
506
+ while (keys.length) {
507
+ var key = keys.pop();
508
+ if (key in object) {
509
+ next.value = key;
510
+ next.done = false;
511
+ return next;
512
+ }
513
+ }
514
+
515
+ // To avoid creating an additional object, we just hang the .value
516
+ // and .done properties off the next function object itself. This
517
+ // also ensures that the minifier will not anonymize the function.
518
+ next.done = true;
519
+ return next;
520
+ };
521
+ };
522
+
523
+ function values(iterable) {
524
+ if (iterable) {
525
+ var iteratorMethod = iterable[iteratorSymbol];
526
+ if (iteratorMethod) {
527
+ return iteratorMethod.call(iterable);
528
+ }
529
+
530
+ if (typeof iterable.next === "function") {
531
+ return iterable;
532
+ }
533
+
534
+ if (!isNaN(iterable.length)) {
535
+ var i = -1, next = function next() {
536
+ while (++i < iterable.length) {
537
+ if (hasOwn.call(iterable, i)) {
538
+ next.value = iterable[i];
539
+ next.done = false;
540
+ return next;
541
+ }
542
+ }
543
+
544
+ next.value = undefined;
545
+ next.done = true;
546
+
547
+ return next;
548
+ };
549
+
550
+ return next.next = next;
551
+ }
552
+ }
553
+
554
+ // Return an iterator with no values.
555
+ return { next: doneResult };
556
+ }
557
+ exports.values = values;
558
+
559
+ function doneResult() {
560
+ return { value: undefined, done: true };
561
+ }
562
+
563
+ Context.prototype = {
564
+ constructor: Context,
565
+
566
+ reset: function(skipTempReset) {
567
+ this.prev = 0;
568
+ this.next = 0;
569
+ // Resetting context._sent for legacy support of Babel's
570
+ // function.sent implementation.
571
+ this.sent = this._sent = undefined;
572
+ this.done = false;
573
+ this.delegate = null;
574
+
575
+ this.method = "next";
576
+ this.arg = undefined;
577
+
578
+ this.tryEntries.forEach(resetTryEntry);
579
+
580
+ if (!skipTempReset) {
581
+ for (var name in this) {
582
+ // Not sure about the optimal order of these conditions:
583
+ if (name.charAt(0) === "t" &&
584
+ hasOwn.call(this, name) &&
585
+ !isNaN(+name.slice(1))) {
586
+ this[name] = undefined;
587
+ }
588
+ }
589
+ }
590
+ },
591
+
592
+ stop: function() {
593
+ this.done = true;
594
+
595
+ var rootEntry = this.tryEntries[0];
596
+ var rootRecord = rootEntry.completion;
597
+ if (rootRecord.type === "throw") {
598
+ throw rootRecord.arg;
599
+ }
600
+
601
+ return this.rval;
602
+ },
603
+
604
+ dispatchException: function(exception) {
605
+ if (this.done) {
606
+ throw exception;
607
+ }
608
+
609
+ var context = this;
610
+ function handle(loc, caught) {
611
+ record.type = "throw";
612
+ record.arg = exception;
613
+ context.next = loc;
614
+
615
+ if (caught) {
616
+ // If the dispatched exception was caught by a catch block,
617
+ // then let that catch block handle the exception normally.
618
+ context.method = "next";
619
+ context.arg = undefined;
620
+ }
621
+
622
+ return !! caught;
623
+ }
624
+
625
+ for (var i = this.tryEntries.length - 1; i >= 0; --i) {
626
+ var entry = this.tryEntries[i];
627
+ var record = entry.completion;
628
+
629
+ if (entry.tryLoc === "root") {
630
+ // Exception thrown outside of any try block that could handle
631
+ // it, so set the completion value of the entire function to
632
+ // throw the exception.
633
+ return handle("end");
634
+ }
635
+
636
+ if (entry.tryLoc <= this.prev) {
637
+ var hasCatch = hasOwn.call(entry, "catchLoc");
638
+ var hasFinally = hasOwn.call(entry, "finallyLoc");
639
+
640
+ if (hasCatch && hasFinally) {
641
+ if (this.prev < entry.catchLoc) {
642
+ return handle(entry.catchLoc, true);
643
+ } else if (this.prev < entry.finallyLoc) {
644
+ return handle(entry.finallyLoc);
645
+ }
646
+
647
+ } else if (hasCatch) {
648
+ if (this.prev < entry.catchLoc) {
649
+ return handle(entry.catchLoc, true);
650
+ }
651
+
652
+ } else if (hasFinally) {
653
+ if (this.prev < entry.finallyLoc) {
654
+ return handle(entry.finallyLoc);
655
+ }
656
+
657
+ } else {
658
+ throw new Error("try statement without catch or finally");
659
+ }
660
+ }
661
+ }
662
+ },
663
+
664
+ abrupt: function(type, arg) {
665
+ for (var i = this.tryEntries.length - 1; i >= 0; --i) {
666
+ var entry = this.tryEntries[i];
667
+ if (entry.tryLoc <= this.prev &&
668
+ hasOwn.call(entry, "finallyLoc") &&
669
+ this.prev < entry.finallyLoc) {
670
+ var finallyEntry = entry;
671
+ break;
672
+ }
673
+ }
674
+
675
+ if (finallyEntry &&
676
+ (type === "break" ||
677
+ type === "continue") &&
678
+ finallyEntry.tryLoc <= arg &&
679
+ arg <= finallyEntry.finallyLoc) {
680
+ // Ignore the finally entry if control is not jumping to a
681
+ // location outside the try/catch block.
682
+ finallyEntry = null;
683
+ }
684
+
685
+ var record = finallyEntry ? finallyEntry.completion : {};
686
+ record.type = type;
687
+ record.arg = arg;
688
+
689
+ if (finallyEntry) {
690
+ this.method = "next";
691
+ this.next = finallyEntry.finallyLoc;
692
+ return ContinueSentinel;
693
+ }
694
+
695
+ return this.complete(record);
696
+ },
697
+
698
+ complete: function(record, afterLoc) {
699
+ if (record.type === "throw") {
700
+ throw record.arg;
701
+ }
702
+
703
+ if (record.type === "break" ||
704
+ record.type === "continue") {
705
+ this.next = record.arg;
706
+ } else if (record.type === "return") {
707
+ this.rval = this.arg = record.arg;
708
+ this.method = "return";
709
+ this.next = "end";
710
+ } else if (record.type === "normal" && afterLoc) {
711
+ this.next = afterLoc;
712
+ }
713
+
714
+ return ContinueSentinel;
715
+ },
716
+
717
+ finish: function(finallyLoc) {
718
+ for (var i = this.tryEntries.length - 1; i >= 0; --i) {
719
+ var entry = this.tryEntries[i];
720
+ if (entry.finallyLoc === finallyLoc) {
721
+ this.complete(entry.completion, entry.afterLoc);
722
+ resetTryEntry(entry);
723
+ return ContinueSentinel;
724
+ }
725
+ }
726
+ },
727
+
728
+ "catch": function(tryLoc) {
729
+ for (var i = this.tryEntries.length - 1; i >= 0; --i) {
730
+ var entry = this.tryEntries[i];
731
+ if (entry.tryLoc === tryLoc) {
732
+ var record = entry.completion;
733
+ if (record.type === "throw") {
734
+ var thrown = record.arg;
735
+ resetTryEntry(entry);
736
+ }
737
+ return thrown;
738
+ }
739
+ }
740
+
741
+ // The context.catch method must only be called with a location
742
+ // argument that corresponds to a known catch block.
743
+ throw new Error("illegal catch attempt");
744
+ },
745
+
746
+ delegateYield: function(iterable, resultName, nextLoc) {
747
+ this.delegate = {
748
+ iterator: values(iterable),
749
+ resultName: resultName,
750
+ nextLoc: nextLoc
751
+ };
752
+
753
+ if (this.method === "next") {
754
+ // Deliberately forget the last sent value so that we don't
755
+ // accidentally pass it on to the delegate.
756
+ this.arg = undefined;
757
+ }
758
+
759
+ return ContinueSentinel;
760
+ }
761
+ };
762
+
763
+ // Regardless of whether this script is executing as a CommonJS module
764
+ // or not, return the runtime object so that we can declare the variable
765
+ // regeneratorRuntime in the outer scope, which allows this module to be
766
+ // injected easily by `bin/regenerator --include-runtime script.js`.
767
+ return exports;
768
+
769
+ }(
770
+ // If this script is executing as a CommonJS module, use module.exports
771
+ // as the regeneratorRuntime namespace. Otherwise create a new empty
772
+ // object. Either way, the resulting object will be used to initialize
773
+ // the regeneratorRuntime variable at the top of this file.
774
+ true ? module.exports : undefined
775
+ ));
776
+
777
+ try {
778
+ regeneratorRuntime = runtime;
779
+ } catch (accidentalStrictMode) {
780
+ // This module should not be running in strict mode, so the above
781
+ // assignment should always work unless something is misconfigured. Just
782
+ // in case runtime.js accidentally runs in strict mode, in modern engines
783
+ // we can explicitly access globalThis. In older engines we can escape
784
+ // strict mode using a global Function call. This could conceivably fail
785
+ // if a Content Security Policy forbids using Function, but in that case
786
+ // the proper solution is to fix the accidental strict mode problem. If
787
+ // you've misconfigured your bundler to force strict mode and applied a
788
+ // CSP to forbid Function, and you're not willing to fix either of those
789
+ // problems, please detail your unique predicament in a GitHub issue.
790
+ if (typeof globalThis === "object") {
791
+ globalThis.regeneratorRuntime = runtime;
792
+ } else {
793
+ Function("r", "regeneratorRuntime = r")(runtime);
794
+ }
795
+ }
796
+
797
+
798
+ /***/ }),
799
+
800
+ /***/ "aaa0":
801
+ /***/ (function(module, __webpack_exports__, __webpack_require__) {
802
+
803
+ "use strict";
804
+ /**
805
+ * good-storage v1.1.1
806
+ * (c) 2020 ustbhuangyi
807
+ */
808
+ var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
809
+
810
+ /**
811
+ * 本地存储实现,封装localStorage和sessionStorage
812
+ */
813
+ var isServer = typeof window === 'undefined';
814
+
815
+ var store = {
816
+ /* eslint-disable no-undef */
817
+ version: '1.1.1',
818
+ storage: !isServer ? window.localStorage : null,
819
+ session: {
820
+ storage: !isServer ? window.sessionStorage : null
821
+ }
822
+ };
823
+
824
+ var api = {
825
+ set: function set(key, val) {
826
+ if (this.disabled) {
827
+ return;
828
+ }
829
+ if (val === undefined) {
830
+ return this.remove(key);
831
+ }
832
+ this.storage.setItem(key, serialize(val));
833
+ return val;
834
+ },
835
+ get: function get(key, def) {
836
+ if (this.disabled) {
837
+ return def;
838
+ }
839
+ var val = deserialize(this.storage.getItem(key));
840
+ return val === undefined ? def : val;
841
+ },
842
+ has: function has(key) {
843
+ return this.get(key) !== undefined;
844
+ },
845
+ remove: function remove(key) {
846
+ if (this.disabled) {
847
+ return;
848
+ }
849
+ this.storage.removeItem(key);
850
+ },
851
+ clear: function clear() {
852
+ if (this.disabled) {
853
+ return;
854
+ }
855
+ this.storage.clear();
856
+ },
857
+ getAll: function getAll() {
858
+ if (this.disabled) {
859
+ return null;
860
+ }
861
+ var ret = {};
862
+ this.forEach(function (key, val) {
863
+ ret[key] = val;
864
+ });
865
+ return ret;
866
+ },
867
+ forEach: function forEach(callback) {
868
+ if (this.disabled) {
869
+ return;
870
+ }
871
+ for (var i = 0; i < this.storage.length; i++) {
872
+ var key = this.storage.key(i);
873
+ callback(key, this.get(key));
874
+ }
875
+ }
876
+ };
877
+
878
+ _extends(store, api);
879
+
880
+ _extends(store.session, api);
881
+
882
+ function serialize(val) {
883
+ return JSON.stringify(val);
884
+ }
885
+
886
+ function deserialize(val) {
887
+ if (typeof val !== 'string') {
888
+ return undefined;
889
+ }
890
+ try {
891
+ return JSON.parse(val);
892
+ } catch (e) {
893
+ return val || undefined;
894
+ }
895
+ }
896
+
897
+ try {
898
+ var testKey = '__storejs__';
899
+ store.set(testKey, testKey);
900
+ if (store.get(testKey) !== testKey) {
901
+ store.disabled = true;
902
+ }
903
+ store.remove(testKey);
904
+ } catch (e) {
905
+ store.disabled = true;
906
+ }
907
+
908
+ /* harmony default export */ __webpack_exports__["a"] = (store);
909
+
910
+
911
+ /***/ }),
912
+
913
+ /***/ "c8ba":
914
+ /***/ (function(module, exports) {
915
+
916
+ var g;
917
+
918
+ // This works in non-strict mode
919
+ g = (function() {
920
+ return this;
921
+ })();
922
+
923
+ try {
924
+ // This works if eval is allowed (see CSP)
925
+ g = g || new Function("return this")();
926
+ } catch (e) {
927
+ // This works if the window reference is available
928
+ if (typeof window === "object") g = window;
929
+ }
930
+
931
+ // g can still be undefined, but nothing to do about it...
932
+ // We return undefined, instead of nothing here, so it's
933
+ // easier to handle this case. if(!global) { ...}
934
+
935
+ module.exports = g;
936
+
937
+
938
+ /***/ }),
939
+
940
+ /***/ "df7c":
941
+ /***/ (function(module, exports, __webpack_require__) {
942
+
943
+ /* WEBPACK VAR INJECTION */(function(process) {// .dirname, .basename, and .extname methods are extracted from Node.js v8.11.1,
944
+ // backported and transplited with Babel, with backwards-compat fixes
945
+
946
+ // Copyright Joyent, Inc. and other Node contributors.
947
+ //
948
+ // Permission is hereby granted, free of charge, to any person obtaining a
949
+ // copy of this software and associated documentation files (the
950
+ // "Software"), to deal in the Software without restriction, including
951
+ // without limitation the rights to use, copy, modify, merge, publish,
952
+ // distribute, sublicense, and/or sell copies of the Software, and to permit
953
+ // persons to whom the Software is furnished to do so, subject to the
954
+ // following conditions:
955
+ //
956
+ // The above copyright notice and this permission notice shall be included
957
+ // in all copies or substantial portions of the Software.
958
+ //
959
+ // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
960
+ // OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
961
+ // MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
962
+ // NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
963
+ // DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
964
+ // OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
965
+ // USE OR OTHER DEALINGS IN THE SOFTWARE.
966
+
967
+ // resolves . and .. elements in a path array with directory names there
968
+ // must be no slashes, empty elements, or device names (c:\) in the array
969
+ // (so also no leading and trailing slashes - it does not distinguish
970
+ // relative and absolute paths)
971
+ function normalizeArray(parts, allowAboveRoot) {
972
+ // if the path tries to go above the root, `up` ends up > 0
973
+ var up = 0;
974
+ for (var i = parts.length - 1; i >= 0; i--) {
975
+ var last = parts[i];
976
+ if (last === '.') {
977
+ parts.splice(i, 1);
978
+ } else if (last === '..') {
979
+ parts.splice(i, 1);
980
+ up++;
981
+ } else if (up) {
982
+ parts.splice(i, 1);
983
+ up--;
984
+ }
985
+ }
986
+
987
+ // if the path is allowed to go above the root, restore leading ..s
988
+ if (allowAboveRoot) {
989
+ for (; up--; up) {
990
+ parts.unshift('..');
991
+ }
992
+ }
993
+
994
+ return parts;
995
+ }
996
+
997
+ // path.resolve([from ...], to)
998
+ // posix version
999
+ exports.resolve = function() {
1000
+ var resolvedPath = '',
1001
+ resolvedAbsolute = false;
1002
+
1003
+ for (var i = arguments.length - 1; i >= -1 && !resolvedAbsolute; i--) {
1004
+ var path = (i >= 0) ? arguments[i] : process.cwd();
1005
+
1006
+ // Skip empty and invalid entries
1007
+ if (typeof path !== 'string') {
1008
+ throw new TypeError('Arguments to path.resolve must be strings');
1009
+ } else if (!path) {
1010
+ continue;
1011
+ }
1012
+
1013
+ resolvedPath = path + '/' + resolvedPath;
1014
+ resolvedAbsolute = path.charAt(0) === '/';
1015
+ }
1016
+
1017
+ // At this point the path should be resolved to a full absolute path, but
1018
+ // handle relative paths to be safe (might happen when process.cwd() fails)
1019
+
1020
+ // Normalize the path
1021
+ resolvedPath = normalizeArray(filter(resolvedPath.split('/'), function(p) {
1022
+ return !!p;
1023
+ }), !resolvedAbsolute).join('/');
1024
+
1025
+ return ((resolvedAbsolute ? '/' : '') + resolvedPath) || '.';
1026
+ };
1027
+
1028
+ // path.normalize(path)
1029
+ // posix version
1030
+ exports.normalize = function(path) {
1031
+ var isAbsolute = exports.isAbsolute(path),
1032
+ trailingSlash = substr(path, -1) === '/';
1033
+
1034
+ // Normalize the path
1035
+ path = normalizeArray(filter(path.split('/'), function(p) {
1036
+ return !!p;
1037
+ }), !isAbsolute).join('/');
1038
+
1039
+ if (!path && !isAbsolute) {
1040
+ path = '.';
1041
+ }
1042
+ if (path && trailingSlash) {
1043
+ path += '/';
1044
+ }
1045
+
1046
+ return (isAbsolute ? '/' : '') + path;
1047
+ };
1048
+
1049
+ // posix version
1050
+ exports.isAbsolute = function(path) {
1051
+ return path.charAt(0) === '/';
1052
+ };
1053
+
1054
+ // posix version
1055
+ exports.join = function() {
1056
+ var paths = Array.prototype.slice.call(arguments, 0);
1057
+ return exports.normalize(filter(paths, function(p, index) {
1058
+ if (typeof p !== 'string') {
1059
+ throw new TypeError('Arguments to path.join must be strings');
1060
+ }
1061
+ return p;
1062
+ }).join('/'));
1063
+ };
1064
+
1065
+
1066
+ // path.relative(from, to)
1067
+ // posix version
1068
+ exports.relative = function(from, to) {
1069
+ from = exports.resolve(from).substr(1);
1070
+ to = exports.resolve(to).substr(1);
1071
+
1072
+ function trim(arr) {
1073
+ var start = 0;
1074
+ for (; start < arr.length; start++) {
1075
+ if (arr[start] !== '') break;
1076
+ }
1077
+
1078
+ var end = arr.length - 1;
1079
+ for (; end >= 0; end--) {
1080
+ if (arr[end] !== '') break;
1081
+ }
1082
+
1083
+ if (start > end) return [];
1084
+ return arr.slice(start, end - start + 1);
1085
+ }
1086
+
1087
+ var fromParts = trim(from.split('/'));
1088
+ var toParts = trim(to.split('/'));
1089
+
1090
+ var length = Math.min(fromParts.length, toParts.length);
1091
+ var samePartsLength = length;
1092
+ for (var i = 0; i < length; i++) {
1093
+ if (fromParts[i] !== toParts[i]) {
1094
+ samePartsLength = i;
1095
+ break;
1096
+ }
1097
+ }
1098
+
1099
+ var outputParts = [];
1100
+ for (var i = samePartsLength; i < fromParts.length; i++) {
1101
+ outputParts.push('..');
1102
+ }
1103
+
1104
+ outputParts = outputParts.concat(toParts.slice(samePartsLength));
1105
+
1106
+ return outputParts.join('/');
1107
+ };
1108
+
1109
+ exports.sep = '/';
1110
+ exports.delimiter = ':';
1111
+
1112
+ exports.dirname = function (path) {
1113
+ if (typeof path !== 'string') path = path + '';
1114
+ if (path.length === 0) return '.';
1115
+ var code = path.charCodeAt(0);
1116
+ var hasRoot = code === 47 /*/*/;
1117
+ var end = -1;
1118
+ var matchedSlash = true;
1119
+ for (var i = path.length - 1; i >= 1; --i) {
1120
+ code = path.charCodeAt(i);
1121
+ if (code === 47 /*/*/) {
1122
+ if (!matchedSlash) {
1123
+ end = i;
1124
+ break;
1125
+ }
1126
+ } else {
1127
+ // We saw the first non-path separator
1128
+ matchedSlash = false;
1129
+ }
1130
+ }
1131
+
1132
+ if (end === -1) return hasRoot ? '/' : '.';
1133
+ if (hasRoot && end === 1) {
1134
+ // return '//';
1135
+ // Backwards-compat fix:
1136
+ return '/';
1137
+ }
1138
+ return path.slice(0, end);
1139
+ };
1140
+
1141
+ function basename(path) {
1142
+ if (typeof path !== 'string') path = path + '';
1143
+
1144
+ var start = 0;
1145
+ var end = -1;
1146
+ var matchedSlash = true;
1147
+ var i;
1148
+
1149
+ for (i = path.length - 1; i >= 0; --i) {
1150
+ if (path.charCodeAt(i) === 47 /*/*/) {
1151
+ // If we reached a path separator that was not part of a set of path
1152
+ // separators at the end of the string, stop now
1153
+ if (!matchedSlash) {
1154
+ start = i + 1;
1155
+ break;
1156
+ }
1157
+ } else if (end === -1) {
1158
+ // We saw the first non-path separator, mark this as the end of our
1159
+ // path component
1160
+ matchedSlash = false;
1161
+ end = i + 1;
1162
+ }
1163
+ }
1164
+
1165
+ if (end === -1) return '';
1166
+ return path.slice(start, end);
1167
+ }
1168
+
1169
+ // Uses a mixed approach for backwards-compatibility, as ext behavior changed
1170
+ // in new Node.js versions, so only basename() above is backported here
1171
+ exports.basename = function (path, ext) {
1172
+ var f = basename(path);
1173
+ if (ext && f.substr(-1 * ext.length) === ext) {
1174
+ f = f.substr(0, f.length - ext.length);
1175
+ }
1176
+ return f;
1177
+ };
1178
+
1179
+ exports.extname = function (path) {
1180
+ if (typeof path !== 'string') path = path + '';
1181
+ var startDot = -1;
1182
+ var startPart = 0;
1183
+ var end = -1;
1184
+ var matchedSlash = true;
1185
+ // Track the state of characters (if any) we see before our first dot and
1186
+ // after any path separator we find
1187
+ var preDotState = 0;
1188
+ for (var i = path.length - 1; i >= 0; --i) {
1189
+ var code = path.charCodeAt(i);
1190
+ if (code === 47 /*/*/) {
1191
+ // If we reached a path separator that was not part of a set of path
1192
+ // separators at the end of the string, stop now
1193
+ if (!matchedSlash) {
1194
+ startPart = i + 1;
1195
+ break;
1196
+ }
1197
+ continue;
1198
+ }
1199
+ if (end === -1) {
1200
+ // We saw the first non-path separator, mark this as the end of our
1201
+ // extension
1202
+ matchedSlash = false;
1203
+ end = i + 1;
1204
+ }
1205
+ if (code === 46 /*.*/) {
1206
+ // If this is our first dot, mark it as the start of our extension
1207
+ if (startDot === -1)
1208
+ startDot = i;
1209
+ else if (preDotState !== 1)
1210
+ preDotState = 1;
1211
+ } else if (startDot !== -1) {
1212
+ // We saw a non-dot and non-path separator before our dot, so we should
1213
+ // have a good chance at having a non-empty extension
1214
+ preDotState = -1;
1215
+ }
1216
+ }
1217
+
1218
+ if (startDot === -1 || end === -1 ||
1219
+ // We saw a non-dot character immediately before the dot
1220
+ preDotState === 0 ||
1221
+ // The (right-most) trimmed path component is exactly '..'
1222
+ preDotState === 1 && startDot === end - 1 && startDot === startPart + 1) {
1223
+ return '';
1224
+ }
1225
+ return path.slice(startDot, end);
1226
+ };
1227
+
1228
+ function filter (xs, f) {
1229
+ if (xs.filter) return xs.filter(f);
1230
+ var res = [];
1231
+ for (var i = 0; i < xs.length; i++) {
1232
+ if (f(xs[i], i, xs)) res.push(xs[i]);
1233
+ }
1234
+ return res;
1235
+ }
1236
+
1237
+ // String.prototype.substr - negative index don't work in IE8
1238
+ var substr = 'ab'.substr(-1) === 'b'
1239
+ ? function (str, start, len) { return str.substr(start, len) }
1240
+ : function (str, start, len) {
1241
+ if (start < 0) start = str.length + start;
1242
+ return str.substr(start, len);
1243
+ }
1244
+ ;
1245
+
1246
+ /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__("4362")))
1247
+
1248
+ /***/ })
1249
+
1250
+ }]);