@creopse/react 0.0.31 → 0.0.33

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.
@@ -13272,4124 +13272,6 @@ hooks.HTML5_FMT = {
13272
13272
  MONTH: "YYYY-MM"
13273
13273
  // <input type="month" />
13274
13274
  };
13275
- function commonjsRequire(path) {
13276
- throw new Error('Could not dynamically require "' + path + '". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.');
13277
- }
13278
- var fr$1 = { exports: {} };
13279
- var moment$1 = { exports: {} };
13280
- var moment = moment$1.exports;
13281
- var hasRequiredMoment;
13282
- function requireMoment() {
13283
- if (hasRequiredMoment) return moment$1.exports;
13284
- hasRequiredMoment = 1;
13285
- (function(module2, exports) {
13286
- (function(global2, factory2) {
13287
- module2.exports = factory2();
13288
- })(moment, function() {
13289
- var hookCallback2;
13290
- function hooks2() {
13291
- return hookCallback2.apply(null, arguments);
13292
- }
13293
- function setHookCallback2(callback) {
13294
- hookCallback2 = callback;
13295
- }
13296
- function isArray2(input) {
13297
- return input instanceof Array || Object.prototype.toString.call(input) === "[object Array]";
13298
- }
13299
- function isObject2(input) {
13300
- return input != null && Object.prototype.toString.call(input) === "[object Object]";
13301
- }
13302
- function hasOwnProp2(a2, b) {
13303
- return Object.prototype.hasOwnProperty.call(a2, b);
13304
- }
13305
- function isObjectEmpty2(obj) {
13306
- if (Object.getOwnPropertyNames) {
13307
- return Object.getOwnPropertyNames(obj).length === 0;
13308
- } else {
13309
- var k;
13310
- for (k in obj) {
13311
- if (hasOwnProp2(obj, k)) {
13312
- return false;
13313
- }
13314
- }
13315
- return true;
13316
- }
13317
- }
13318
- function isUndefined2(input) {
13319
- return input === void 0;
13320
- }
13321
- function isNumber2(input) {
13322
- return typeof input === "number" || Object.prototype.toString.call(input) === "[object Number]";
13323
- }
13324
- function isDate2(input) {
13325
- return input instanceof Date || Object.prototype.toString.call(input) === "[object Date]";
13326
- }
13327
- function map2(arr, fn) {
13328
- var res = [], i, arrLen = arr.length;
13329
- for (i = 0; i < arrLen; ++i) {
13330
- res.push(fn(arr[i], i));
13331
- }
13332
- return res;
13333
- }
13334
- function extend2(a2, b) {
13335
- for (var i in b) {
13336
- if (hasOwnProp2(b, i)) {
13337
- a2[i] = b[i];
13338
- }
13339
- }
13340
- if (hasOwnProp2(b, "toString")) {
13341
- a2.toString = b.toString;
13342
- }
13343
- if (hasOwnProp2(b, "valueOf")) {
13344
- a2.valueOf = b.valueOf;
13345
- }
13346
- return a2;
13347
- }
13348
- function createUTC2(input, format3, locale3, strict) {
13349
- return createLocalOrUTC2(input, format3, locale3, strict, true).utc();
13350
- }
13351
- function defaultParsingFlags2() {
13352
- return {
13353
- empty: false,
13354
- unusedTokens: [],
13355
- unusedInput: [],
13356
- overflow: -2,
13357
- charsLeftOver: 0,
13358
- nullInput: false,
13359
- invalidEra: null,
13360
- invalidMonth: null,
13361
- invalidFormat: false,
13362
- userInvalidated: false,
13363
- iso: false,
13364
- parsedDateParts: [],
13365
- era: null,
13366
- meridiem: null,
13367
- rfc2822: false,
13368
- weekdayMismatch: false
13369
- };
13370
- }
13371
- function getParsingFlags2(m) {
13372
- if (m._pf == null) {
13373
- m._pf = defaultParsingFlags2();
13374
- }
13375
- return m._pf;
13376
- }
13377
- var some2;
13378
- if (Array.prototype.some) {
13379
- some2 = Array.prototype.some;
13380
- } else {
13381
- some2 = function(fun) {
13382
- var t2 = Object(this), len = t2.length >>> 0, i;
13383
- for (i = 0; i < len; i++) {
13384
- if (i in t2 && fun.call(this, t2[i], i, t2)) {
13385
- return true;
13386
- }
13387
- }
13388
- return false;
13389
- };
13390
- }
13391
- function isValid2(m) {
13392
- var flags = null, parsedParts = false, isNowValid = m._d && !isNaN(m._d.getTime());
13393
- if (isNowValid) {
13394
- flags = getParsingFlags2(m);
13395
- parsedParts = some2.call(flags.parsedDateParts, function(i) {
13396
- return i != null;
13397
- });
13398
- isNowValid = flags.overflow < 0 && !flags.empty && !flags.invalidEra && !flags.invalidMonth && !flags.invalidWeekday && !flags.weekdayMismatch && !flags.nullInput && !flags.invalidFormat && !flags.userInvalidated && (!flags.meridiem || flags.meridiem && parsedParts);
13399
- if (m._strict) {
13400
- isNowValid = isNowValid && flags.charsLeftOver === 0 && flags.unusedTokens.length === 0 && flags.bigHour === void 0;
13401
- }
13402
- }
13403
- if (Object.isFrozen == null || !Object.isFrozen(m)) {
13404
- m._isValid = isNowValid;
13405
- } else {
13406
- return isNowValid;
13407
- }
13408
- return m._isValid;
13409
- }
13410
- function createInvalid2(flags) {
13411
- var m = createUTC2(NaN);
13412
- if (flags != null) {
13413
- extend2(getParsingFlags2(m), flags);
13414
- } else {
13415
- getParsingFlags2(m).userInvalidated = true;
13416
- }
13417
- return m;
13418
- }
13419
- var momentProperties2 = hooks2.momentProperties = [], updateInProgress2 = false;
13420
- function copyConfig2(to3, from3) {
13421
- var i, prop, val, momentPropertiesLen = momentProperties2.length;
13422
- if (!isUndefined2(from3._isAMomentObject)) {
13423
- to3._isAMomentObject = from3._isAMomentObject;
13424
- }
13425
- if (!isUndefined2(from3._i)) {
13426
- to3._i = from3._i;
13427
- }
13428
- if (!isUndefined2(from3._f)) {
13429
- to3._f = from3._f;
13430
- }
13431
- if (!isUndefined2(from3._l)) {
13432
- to3._l = from3._l;
13433
- }
13434
- if (!isUndefined2(from3._strict)) {
13435
- to3._strict = from3._strict;
13436
- }
13437
- if (!isUndefined2(from3._tzm)) {
13438
- to3._tzm = from3._tzm;
13439
- }
13440
- if (!isUndefined2(from3._isUTC)) {
13441
- to3._isUTC = from3._isUTC;
13442
- }
13443
- if (!isUndefined2(from3._offset)) {
13444
- to3._offset = from3._offset;
13445
- }
13446
- if (!isUndefined2(from3._pf)) {
13447
- to3._pf = getParsingFlags2(from3);
13448
- }
13449
- if (!isUndefined2(from3._locale)) {
13450
- to3._locale = from3._locale;
13451
- }
13452
- if (momentPropertiesLen > 0) {
13453
- for (i = 0; i < momentPropertiesLen; i++) {
13454
- prop = momentProperties2[i];
13455
- val = from3[prop];
13456
- if (!isUndefined2(val)) {
13457
- to3[prop] = val;
13458
- }
13459
- }
13460
- }
13461
- return to3;
13462
- }
13463
- function Moment2(config) {
13464
- copyConfig2(this, config);
13465
- this._d = new Date(config._d != null ? config._d.getTime() : NaN);
13466
- if (!this.isValid()) {
13467
- this._d = /* @__PURE__ */ new Date(NaN);
13468
- }
13469
- if (updateInProgress2 === false) {
13470
- updateInProgress2 = true;
13471
- hooks2.updateOffset(this);
13472
- updateInProgress2 = false;
13473
- }
13474
- }
13475
- function isMoment2(obj) {
13476
- return obj instanceof Moment2 || obj != null && obj._isAMomentObject != null;
13477
- }
13478
- function warn2(msg) {
13479
- if (hooks2.suppressDeprecationWarnings === false && typeof console !== "undefined" && console.warn) {
13480
- console.warn("Deprecation warning: " + msg);
13481
- }
13482
- }
13483
- function deprecate2(msg, fn) {
13484
- var firstTime = true;
13485
- return extend2(function() {
13486
- if (hooks2.deprecationHandler != null) {
13487
- hooks2.deprecationHandler(null, msg);
13488
- }
13489
- if (firstTime) {
13490
- var args = [], arg, i, key, argLen = arguments.length;
13491
- for (i = 0; i < argLen; i++) {
13492
- arg = "";
13493
- if (typeof arguments[i] === "object") {
13494
- arg += "\n[" + i + "] ";
13495
- for (key in arguments[0]) {
13496
- if (hasOwnProp2(arguments[0], key)) {
13497
- arg += key + ": " + arguments[0][key] + ", ";
13498
- }
13499
- }
13500
- arg = arg.slice(0, -2);
13501
- } else {
13502
- arg = arguments[i];
13503
- }
13504
- args.push(arg);
13505
- }
13506
- warn2(
13507
- msg + "\nArguments: " + Array.prototype.slice.call(args).join("") + "\n" + new Error().stack
13508
- );
13509
- firstTime = false;
13510
- }
13511
- return fn.apply(this, arguments);
13512
- }, fn);
13513
- }
13514
- var deprecations2 = {};
13515
- function deprecateSimple2(name, msg) {
13516
- if (hooks2.deprecationHandler != null) {
13517
- hooks2.deprecationHandler(name, msg);
13518
- }
13519
- if (!deprecations2[name]) {
13520
- warn2(msg);
13521
- deprecations2[name] = true;
13522
- }
13523
- }
13524
- hooks2.suppressDeprecationWarnings = false;
13525
- hooks2.deprecationHandler = null;
13526
- function isFunction2(input) {
13527
- return typeof Function !== "undefined" && input instanceof Function || Object.prototype.toString.call(input) === "[object Function]";
13528
- }
13529
- function set2(config) {
13530
- var prop, i;
13531
- for (i in config) {
13532
- if (hasOwnProp2(config, i)) {
13533
- prop = config[i];
13534
- if (isFunction2(prop)) {
13535
- this[i] = prop;
13536
- } else {
13537
- this["_" + i] = prop;
13538
- }
13539
- }
13540
- }
13541
- this._config = config;
13542
- this._dayOfMonthOrdinalParseLenient = new RegExp(
13543
- (this._dayOfMonthOrdinalParse.source || this._ordinalParse.source) + "|" + /\d{1,2}/.source
13544
- );
13545
- }
13546
- function mergeConfigs2(parentConfig, childConfig) {
13547
- var res = extend2({}, parentConfig), prop;
13548
- for (prop in childConfig) {
13549
- if (hasOwnProp2(childConfig, prop)) {
13550
- if (isObject2(parentConfig[prop]) && isObject2(childConfig[prop])) {
13551
- res[prop] = {};
13552
- extend2(res[prop], parentConfig[prop]);
13553
- extend2(res[prop], childConfig[prop]);
13554
- } else if (childConfig[prop] != null) {
13555
- res[prop] = childConfig[prop];
13556
- } else {
13557
- delete res[prop];
13558
- }
13559
- }
13560
- }
13561
- for (prop in parentConfig) {
13562
- if (hasOwnProp2(parentConfig, prop) && !hasOwnProp2(childConfig, prop) && isObject2(parentConfig[prop])) {
13563
- res[prop] = extend2({}, res[prop]);
13564
- }
13565
- }
13566
- return res;
13567
- }
13568
- function Locale2(config) {
13569
- if (config != null) {
13570
- this.set(config);
13571
- }
13572
- }
13573
- var keys2;
13574
- if (Object.keys) {
13575
- keys2 = Object.keys;
13576
- } else {
13577
- keys2 = function(obj) {
13578
- var i, res = [];
13579
- for (i in obj) {
13580
- if (hasOwnProp2(obj, i)) {
13581
- res.push(i);
13582
- }
13583
- }
13584
- return res;
13585
- };
13586
- }
13587
- var defaultCalendar2 = {
13588
- sameDay: "[Today at] LT",
13589
- nextDay: "[Tomorrow at] LT",
13590
- nextWeek: "dddd [at] LT",
13591
- lastDay: "[Yesterday at] LT",
13592
- lastWeek: "[Last] dddd [at] LT",
13593
- sameElse: "L"
13594
- };
13595
- function calendar2(key, mom, now3) {
13596
- var output = this._calendar[key] || this._calendar["sameElse"];
13597
- return isFunction2(output) ? output.call(mom, now3) : output;
13598
- }
13599
- function zeroFill2(number, targetLength, forceSign) {
13600
- var absNumber = "" + Math.abs(number), zerosToFill = targetLength - absNumber.length, sign3 = number >= 0;
13601
- return (sign3 ? forceSign ? "+" : "" : "-") + Math.pow(10, Math.max(0, zerosToFill)).toString().substr(1) + absNumber;
13602
- }
13603
- var formattingTokens2 = /(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g, localFormattingTokens2 = /(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g, formatFunctions2 = {}, formatTokenFunctions2 = {};
13604
- function addFormatToken2(token3, padded, ordinal3, callback) {
13605
- var func = callback;
13606
- if (typeof callback === "string") {
13607
- func = function() {
13608
- return this[callback]();
13609
- };
13610
- }
13611
- if (token3) {
13612
- formatTokenFunctions2[token3] = func;
13613
- }
13614
- if (padded) {
13615
- formatTokenFunctions2[padded[0]] = function() {
13616
- return zeroFill2(func.apply(this, arguments), padded[1], padded[2]);
13617
- };
13618
- }
13619
- if (ordinal3) {
13620
- formatTokenFunctions2[ordinal3] = function() {
13621
- return this.localeData().ordinal(
13622
- func.apply(this, arguments),
13623
- token3
13624
- );
13625
- };
13626
- }
13627
- }
13628
- function removeFormattingTokens2(input) {
13629
- if (input.match(/\[[\s\S]/)) {
13630
- return input.replace(/^\[|\]$/g, "");
13631
- }
13632
- return input.replace(/\\/g, "");
13633
- }
13634
- function makeFormatFunction2(format3) {
13635
- var array = format3.match(formattingTokens2), i, length;
13636
- for (i = 0, length = array.length; i < length; i++) {
13637
- if (formatTokenFunctions2[array[i]]) {
13638
- array[i] = formatTokenFunctions2[array[i]];
13639
- } else {
13640
- array[i] = removeFormattingTokens2(array[i]);
13641
- }
13642
- }
13643
- return function(mom) {
13644
- var output = "", i2;
13645
- for (i2 = 0; i2 < length; i2++) {
13646
- output += isFunction2(array[i2]) ? array[i2].call(mom, format3) : array[i2];
13647
- }
13648
- return output;
13649
- };
13650
- }
13651
- function formatMoment2(m, format3) {
13652
- if (!m.isValid()) {
13653
- return m.localeData().invalidDate();
13654
- }
13655
- format3 = expandFormat2(format3, m.localeData());
13656
- formatFunctions2[format3] = formatFunctions2[format3] || makeFormatFunction2(format3);
13657
- return formatFunctions2[format3](m);
13658
- }
13659
- function expandFormat2(format3, locale3) {
13660
- var i = 5;
13661
- function replaceLongDateFormatTokens(input) {
13662
- return locale3.longDateFormat(input) || input;
13663
- }
13664
- localFormattingTokens2.lastIndex = 0;
13665
- while (i >= 0 && localFormattingTokens2.test(format3)) {
13666
- format3 = format3.replace(
13667
- localFormattingTokens2,
13668
- replaceLongDateFormatTokens
13669
- );
13670
- localFormattingTokens2.lastIndex = 0;
13671
- i -= 1;
13672
- }
13673
- return format3;
13674
- }
13675
- var defaultLongDateFormat2 = {
13676
- LTS: "h:mm:ss A",
13677
- LT: "h:mm A",
13678
- L: "MM/DD/YYYY",
13679
- LL: "MMMM D, YYYY",
13680
- LLL: "MMMM D, YYYY h:mm A",
13681
- LLLL: "dddd, MMMM D, YYYY h:mm A"
13682
- };
13683
- function longDateFormat2(key) {
13684
- var format3 = this._longDateFormat[key], formatUpper = this._longDateFormat[key.toUpperCase()];
13685
- if (format3 || !formatUpper) {
13686
- return format3;
13687
- }
13688
- this._longDateFormat[key] = formatUpper.match(formattingTokens2).map(function(tok) {
13689
- if (tok === "MMMM" || tok === "MM" || tok === "DD" || tok === "dddd") {
13690
- return tok.slice(1);
13691
- }
13692
- return tok;
13693
- }).join("");
13694
- return this._longDateFormat[key];
13695
- }
13696
- var defaultInvalidDate2 = "Invalid date";
13697
- function invalidDate2() {
13698
- return this._invalidDate;
13699
- }
13700
- var defaultOrdinal2 = "%d", defaultDayOfMonthOrdinalParse2 = /\d{1,2}/;
13701
- function ordinal2(number) {
13702
- return this._ordinal.replace("%d", number);
13703
- }
13704
- var defaultRelativeTime2 = {
13705
- future: "in %s",
13706
- past: "%s ago",
13707
- s: "a few seconds",
13708
- ss: "%d seconds",
13709
- m: "a minute",
13710
- mm: "%d minutes",
13711
- h: "an hour",
13712
- hh: "%d hours",
13713
- d: "a day",
13714
- dd: "%d days",
13715
- w: "a week",
13716
- ww: "%d weeks",
13717
- M: "a month",
13718
- MM: "%d months",
13719
- y: "a year",
13720
- yy: "%d years"
13721
- };
13722
- function relativeTime2(number, withoutSuffix, string, isFuture) {
13723
- var output = this._relativeTime[string];
13724
- return isFunction2(output) ? output(number, withoutSuffix, string, isFuture) : output.replace(/%d/i, number);
13725
- }
13726
- function pastFuture2(diff3, output) {
13727
- var format3 = this._relativeTime[diff3 > 0 ? "future" : "past"];
13728
- return isFunction2(format3) ? format3(output) : format3.replace(/%s/i, output);
13729
- }
13730
- var aliases2 = {
13731
- D: "date",
13732
- dates: "date",
13733
- date: "date",
13734
- d: "day",
13735
- days: "day",
13736
- day: "day",
13737
- e: "weekday",
13738
- weekdays: "weekday",
13739
- weekday: "weekday",
13740
- E: "isoWeekday",
13741
- isoweekdays: "isoWeekday",
13742
- isoweekday: "isoWeekday",
13743
- DDD: "dayOfYear",
13744
- dayofyears: "dayOfYear",
13745
- dayofyear: "dayOfYear",
13746
- h: "hour",
13747
- hours: "hour",
13748
- hour: "hour",
13749
- ms: "millisecond",
13750
- milliseconds: "millisecond",
13751
- millisecond: "millisecond",
13752
- m: "minute",
13753
- minutes: "minute",
13754
- minute: "minute",
13755
- M: "month",
13756
- months: "month",
13757
- month: "month",
13758
- Q: "quarter",
13759
- quarters: "quarter",
13760
- quarter: "quarter",
13761
- s: "second",
13762
- seconds: "second",
13763
- second: "second",
13764
- gg: "weekYear",
13765
- weekyears: "weekYear",
13766
- weekyear: "weekYear",
13767
- GG: "isoWeekYear",
13768
- isoweekyears: "isoWeekYear",
13769
- isoweekyear: "isoWeekYear",
13770
- w: "week",
13771
- weeks: "week",
13772
- week: "week",
13773
- W: "isoWeek",
13774
- isoweeks: "isoWeek",
13775
- isoweek: "isoWeek",
13776
- y: "year",
13777
- years: "year",
13778
- year: "year"
13779
- };
13780
- function normalizeUnits2(units) {
13781
- return typeof units === "string" ? aliases2[units] || aliases2[units.toLowerCase()] : void 0;
13782
- }
13783
- function normalizeObjectUnits2(inputObject) {
13784
- var normalizedInput = {}, normalizedProp, prop;
13785
- for (prop in inputObject) {
13786
- if (hasOwnProp2(inputObject, prop)) {
13787
- normalizedProp = normalizeUnits2(prop);
13788
- if (normalizedProp) {
13789
- normalizedInput[normalizedProp] = inputObject[prop];
13790
- }
13791
- }
13792
- }
13793
- return normalizedInput;
13794
- }
13795
- var priorities2 = {
13796
- date: 9,
13797
- day: 11,
13798
- weekday: 11,
13799
- isoWeekday: 11,
13800
- dayOfYear: 4,
13801
- hour: 13,
13802
- millisecond: 16,
13803
- minute: 14,
13804
- month: 8,
13805
- quarter: 7,
13806
- second: 15,
13807
- weekYear: 1,
13808
- isoWeekYear: 1,
13809
- week: 5,
13810
- isoWeek: 5,
13811
- year: 1
13812
- };
13813
- function getPrioritizedUnits2(unitsObj) {
13814
- var units = [], u;
13815
- for (u in unitsObj) {
13816
- if (hasOwnProp2(unitsObj, u)) {
13817
- units.push({ unit: u, priority: priorities2[u] });
13818
- }
13819
- }
13820
- units.sort(function(a2, b) {
13821
- return a2.priority - b.priority;
13822
- });
13823
- return units;
13824
- }
13825
- var match12 = /\d/, match22 = /\d\d/, match32 = /\d{3}/, match42 = /\d{4}/, match62 = /[+-]?\d{6}/, match1to22 = /\d\d?/, match3to42 = /\d\d\d\d?/, match5to62 = /\d\d\d\d\d\d?/, match1to32 = /\d{1,3}/, match1to42 = /\d{1,4}/, match1to62 = /[+-]?\d{1,6}/, matchUnsigned2 = /\d+/, matchSigned2 = /[+-]?\d+/, matchOffset2 = /Z|[+-]\d\d:?\d\d/gi, matchShortOffset2 = /Z|[+-]\d\d(?::?\d\d)?/gi, matchTimestamp2 = /[+-]?\d+(\.\d{1,3})?/, matchWord2 = /[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i, match1to2NoLeadingZero2 = /^[1-9]\d?/, match1to2HasZero2 = /^([1-9]\d|\d)/, regexes2;
13826
- regexes2 = {};
13827
- function addRegexToken2(token3, regex, strictRegex) {
13828
- regexes2[token3] = isFunction2(regex) ? regex : function(isStrict, localeData3) {
13829
- return isStrict && strictRegex ? strictRegex : regex;
13830
- };
13831
- }
13832
- function getParseRegexForToken2(token3, config) {
13833
- if (!hasOwnProp2(regexes2, token3)) {
13834
- return new RegExp(unescapeFormat2(token3));
13835
- }
13836
- return regexes2[token3](config._strict, config._locale);
13837
- }
13838
- function unescapeFormat2(s2) {
13839
- return regexEscape2(
13840
- s2.replace("\\", "").replace(
13841
- /\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,
13842
- function(matched, p1, p2, p3, p4) {
13843
- return p1 || p2 || p3 || p4;
13844
- }
13845
- )
13846
- );
13847
- }
13848
- function regexEscape2(s2) {
13849
- return s2.replace(/[-\/\\^$*+?.()|[\]{}]/g, "\\$&");
13850
- }
13851
- function absFloor2(number) {
13852
- if (number < 0) {
13853
- return Math.ceil(number) || 0;
13854
- } else {
13855
- return Math.floor(number);
13856
- }
13857
- }
13858
- function toInt2(argumentForCoercion) {
13859
- var coercedNumber = +argumentForCoercion, value = 0;
13860
- if (coercedNumber !== 0 && isFinite(coercedNumber)) {
13861
- value = absFloor2(coercedNumber);
13862
- }
13863
- return value;
13864
- }
13865
- var tokens2 = {};
13866
- function addParseToken2(token3, callback) {
13867
- var i, func = callback, tokenLen;
13868
- if (typeof token3 === "string") {
13869
- token3 = [token3];
13870
- }
13871
- if (isNumber2(callback)) {
13872
- func = function(input, array) {
13873
- array[callback] = toInt2(input);
13874
- };
13875
- }
13876
- tokenLen = token3.length;
13877
- for (i = 0; i < tokenLen; i++) {
13878
- tokens2[token3[i]] = func;
13879
- }
13880
- }
13881
- function addWeekParseToken2(token3, callback) {
13882
- addParseToken2(token3, function(input, array, config, token4) {
13883
- config._w = config._w || {};
13884
- callback(input, config._w, config, token4);
13885
- });
13886
- }
13887
- function addTimeToArrayFromToken2(token3, input, config) {
13888
- if (input != null && hasOwnProp2(tokens2, token3)) {
13889
- tokens2[token3](input, config._a, config, token3);
13890
- }
13891
- }
13892
- function isLeapYear2(year) {
13893
- return year % 4 === 0 && year % 100 !== 0 || year % 400 === 0;
13894
- }
13895
- var YEAR2 = 0, MONTH2 = 1, DATE2 = 2, HOUR2 = 3, MINUTE2 = 4, SECOND2 = 5, MILLISECOND2 = 6, WEEK2 = 7, WEEKDAY2 = 8;
13896
- addFormatToken2("Y", 0, 0, function() {
13897
- var y = this.year();
13898
- return y <= 9999 ? zeroFill2(y, 4) : "+" + y;
13899
- });
13900
- addFormatToken2(0, ["YY", 2], 0, function() {
13901
- return this.year() % 100;
13902
- });
13903
- addFormatToken2(0, ["YYYY", 4], 0, "year");
13904
- addFormatToken2(0, ["YYYYY", 5], 0, "year");
13905
- addFormatToken2(0, ["YYYYYY", 6, true], 0, "year");
13906
- addRegexToken2("Y", matchSigned2);
13907
- addRegexToken2("YY", match1to22, match22);
13908
- addRegexToken2("YYYY", match1to42, match42);
13909
- addRegexToken2("YYYYY", match1to62, match62);
13910
- addRegexToken2("YYYYYY", match1to62, match62);
13911
- addParseToken2(["YYYYY", "YYYYYY"], YEAR2);
13912
- addParseToken2("YYYY", function(input, array) {
13913
- array[YEAR2] = input.length === 2 ? hooks2.parseTwoDigitYear(input) : toInt2(input);
13914
- });
13915
- addParseToken2("YY", function(input, array) {
13916
- array[YEAR2] = hooks2.parseTwoDigitYear(input);
13917
- });
13918
- addParseToken2("Y", function(input, array) {
13919
- array[YEAR2] = parseInt(input, 10);
13920
- });
13921
- function daysInYear2(year) {
13922
- return isLeapYear2(year) ? 366 : 365;
13923
- }
13924
- hooks2.parseTwoDigitYear = function(input) {
13925
- return toInt2(input) + (toInt2(input) > 68 ? 1900 : 2e3);
13926
- };
13927
- var getSetYear2 = makeGetSet2("FullYear", true);
13928
- function getIsLeapYear2() {
13929
- return isLeapYear2(this.year());
13930
- }
13931
- function makeGetSet2(unit, keepTime) {
13932
- return function(value) {
13933
- if (value != null) {
13934
- set$12(this, unit, value);
13935
- hooks2.updateOffset(this, keepTime);
13936
- return this;
13937
- } else {
13938
- return get2(this, unit);
13939
- }
13940
- };
13941
- }
13942
- function get2(mom, unit) {
13943
- if (!mom.isValid()) {
13944
- return NaN;
13945
- }
13946
- var d = mom._d, isUTC = mom._isUTC;
13947
- switch (unit) {
13948
- case "Milliseconds":
13949
- return isUTC ? d.getUTCMilliseconds() : d.getMilliseconds();
13950
- case "Seconds":
13951
- return isUTC ? d.getUTCSeconds() : d.getSeconds();
13952
- case "Minutes":
13953
- return isUTC ? d.getUTCMinutes() : d.getMinutes();
13954
- case "Hours":
13955
- return isUTC ? d.getUTCHours() : d.getHours();
13956
- case "Date":
13957
- return isUTC ? d.getUTCDate() : d.getDate();
13958
- case "Day":
13959
- return isUTC ? d.getUTCDay() : d.getDay();
13960
- case "Month":
13961
- return isUTC ? d.getUTCMonth() : d.getMonth();
13962
- case "FullYear":
13963
- return isUTC ? d.getUTCFullYear() : d.getFullYear();
13964
- default:
13965
- return NaN;
13966
- }
13967
- }
13968
- function set$12(mom, unit, value) {
13969
- var d, isUTC, year, month, date;
13970
- if (!mom.isValid() || isNaN(value)) {
13971
- return;
13972
- }
13973
- d = mom._d;
13974
- isUTC = mom._isUTC;
13975
- switch (unit) {
13976
- case "Milliseconds":
13977
- return void (isUTC ? d.setUTCMilliseconds(value) : d.setMilliseconds(value));
13978
- case "Seconds":
13979
- return void (isUTC ? d.setUTCSeconds(value) : d.setSeconds(value));
13980
- case "Minutes":
13981
- return void (isUTC ? d.setUTCMinutes(value) : d.setMinutes(value));
13982
- case "Hours":
13983
- return void (isUTC ? d.setUTCHours(value) : d.setHours(value));
13984
- case "Date":
13985
- return void (isUTC ? d.setUTCDate(value) : d.setDate(value));
13986
- // case 'Day': // Not real
13987
- // return void (isUTC ? d.setUTCDay(value) : d.setDay(value));
13988
- // case 'Month': // Not used because we need to pass two variables
13989
- // return void (isUTC ? d.setUTCMonth(value) : d.setMonth(value));
13990
- case "FullYear":
13991
- break;
13992
- // See below ...
13993
- default:
13994
- return;
13995
- }
13996
- year = value;
13997
- month = mom.month();
13998
- date = mom.date();
13999
- date = date === 29 && month === 1 && !isLeapYear2(year) ? 28 : date;
14000
- void (isUTC ? d.setUTCFullYear(year, month, date) : d.setFullYear(year, month, date));
14001
- }
14002
- function stringGet2(units) {
14003
- units = normalizeUnits2(units);
14004
- if (isFunction2(this[units])) {
14005
- return this[units]();
14006
- }
14007
- return this;
14008
- }
14009
- function stringSet2(units, value) {
14010
- if (typeof units === "object") {
14011
- units = normalizeObjectUnits2(units);
14012
- var prioritized = getPrioritizedUnits2(units), i, prioritizedLen = prioritized.length;
14013
- for (i = 0; i < prioritizedLen; i++) {
14014
- this[prioritized[i].unit](units[prioritized[i].unit]);
14015
- }
14016
- } else {
14017
- units = normalizeUnits2(units);
14018
- if (isFunction2(this[units])) {
14019
- return this[units](value);
14020
- }
14021
- }
14022
- return this;
14023
- }
14024
- function mod2(n, x) {
14025
- return (n % x + x) % x;
14026
- }
14027
- var indexOf2;
14028
- if (Array.prototype.indexOf) {
14029
- indexOf2 = Array.prototype.indexOf;
14030
- } else {
14031
- indexOf2 = function(o) {
14032
- var i;
14033
- for (i = 0; i < this.length; ++i) {
14034
- if (this[i] === o) {
14035
- return i;
14036
- }
14037
- }
14038
- return -1;
14039
- };
14040
- }
14041
- function daysInMonth2(year, month) {
14042
- if (isNaN(year) || isNaN(month)) {
14043
- return NaN;
14044
- }
14045
- var modMonth = mod2(month, 12);
14046
- year += (month - modMonth) / 12;
14047
- return modMonth === 1 ? isLeapYear2(year) ? 29 : 28 : 31 - modMonth % 7 % 2;
14048
- }
14049
- addFormatToken2("M", ["MM", 2], "Mo", function() {
14050
- return this.month() + 1;
14051
- });
14052
- addFormatToken2("MMM", 0, 0, function(format3) {
14053
- return this.localeData().monthsShort(this, format3);
14054
- });
14055
- addFormatToken2("MMMM", 0, 0, function(format3) {
14056
- return this.localeData().months(this, format3);
14057
- });
14058
- addRegexToken2("M", match1to22, match1to2NoLeadingZero2);
14059
- addRegexToken2("MM", match1to22, match22);
14060
- addRegexToken2("MMM", function(isStrict, locale3) {
14061
- return locale3.monthsShortRegex(isStrict);
14062
- });
14063
- addRegexToken2("MMMM", function(isStrict, locale3) {
14064
- return locale3.monthsRegex(isStrict);
14065
- });
14066
- addParseToken2(["M", "MM"], function(input, array) {
14067
- array[MONTH2] = toInt2(input) - 1;
14068
- });
14069
- addParseToken2(["MMM", "MMMM"], function(input, array, config, token3) {
14070
- var month = config._locale.monthsParse(input, token3, config._strict);
14071
- if (month != null) {
14072
- array[MONTH2] = month;
14073
- } else {
14074
- getParsingFlags2(config).invalidMonth = input;
14075
- }
14076
- });
14077
- var defaultLocaleMonths2 = "January_February_March_April_May_June_July_August_September_October_November_December".split(
14078
- "_"
14079
- ), defaultLocaleMonthsShort2 = "Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"), MONTHS_IN_FORMAT2 = /D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/, defaultMonthsShortRegex2 = matchWord2, defaultMonthsRegex2 = matchWord2;
14080
- function localeMonths2(m, format3) {
14081
- if (!m) {
14082
- return isArray2(this._months) ? this._months : this._months["standalone"];
14083
- }
14084
- return isArray2(this._months) ? this._months[m.month()] : this._months[(this._months.isFormat || MONTHS_IN_FORMAT2).test(format3) ? "format" : "standalone"][m.month()];
14085
- }
14086
- function localeMonthsShort2(m, format3) {
14087
- if (!m) {
14088
- return isArray2(this._monthsShort) ? this._monthsShort : this._monthsShort["standalone"];
14089
- }
14090
- return isArray2(this._monthsShort) ? this._monthsShort[m.month()] : this._monthsShort[MONTHS_IN_FORMAT2.test(format3) ? "format" : "standalone"][m.month()];
14091
- }
14092
- function handleStrictParse2(monthName, format3, strict) {
14093
- var i, ii, mom, llc = monthName.toLocaleLowerCase();
14094
- if (!this._monthsParse) {
14095
- this._monthsParse = [];
14096
- this._longMonthsParse = [];
14097
- this._shortMonthsParse = [];
14098
- for (i = 0; i < 12; ++i) {
14099
- mom = createUTC2([2e3, i]);
14100
- this._shortMonthsParse[i] = this.monthsShort(
14101
- mom,
14102
- ""
14103
- ).toLocaleLowerCase();
14104
- this._longMonthsParse[i] = this.months(mom, "").toLocaleLowerCase();
14105
- }
14106
- }
14107
- if (strict) {
14108
- if (format3 === "MMM") {
14109
- ii = indexOf2.call(this._shortMonthsParse, llc);
14110
- return ii !== -1 ? ii : null;
14111
- } else {
14112
- ii = indexOf2.call(this._longMonthsParse, llc);
14113
- return ii !== -1 ? ii : null;
14114
- }
14115
- } else {
14116
- if (format3 === "MMM") {
14117
- ii = indexOf2.call(this._shortMonthsParse, llc);
14118
- if (ii !== -1) {
14119
- return ii;
14120
- }
14121
- ii = indexOf2.call(this._longMonthsParse, llc);
14122
- return ii !== -1 ? ii : null;
14123
- } else {
14124
- ii = indexOf2.call(this._longMonthsParse, llc);
14125
- if (ii !== -1) {
14126
- return ii;
14127
- }
14128
- ii = indexOf2.call(this._shortMonthsParse, llc);
14129
- return ii !== -1 ? ii : null;
14130
- }
14131
- }
14132
- }
14133
- function localeMonthsParse2(monthName, format3, strict) {
14134
- var i, mom, regex;
14135
- if (this._monthsParseExact) {
14136
- return handleStrictParse2.call(this, monthName, format3, strict);
14137
- }
14138
- if (!this._monthsParse) {
14139
- this._monthsParse = [];
14140
- this._longMonthsParse = [];
14141
- this._shortMonthsParse = [];
14142
- }
14143
- for (i = 0; i < 12; i++) {
14144
- mom = createUTC2([2e3, i]);
14145
- if (strict && !this._longMonthsParse[i]) {
14146
- this._longMonthsParse[i] = new RegExp(
14147
- "^" + this.months(mom, "").replace(".", "") + "$",
14148
- "i"
14149
- );
14150
- this._shortMonthsParse[i] = new RegExp(
14151
- "^" + this.monthsShort(mom, "").replace(".", "") + "$",
14152
- "i"
14153
- );
14154
- }
14155
- if (!strict && !this._monthsParse[i]) {
14156
- regex = "^" + this.months(mom, "") + "|^" + this.monthsShort(mom, "");
14157
- this._monthsParse[i] = new RegExp(regex.replace(".", ""), "i");
14158
- }
14159
- if (strict && format3 === "MMMM" && this._longMonthsParse[i].test(monthName)) {
14160
- return i;
14161
- } else if (strict && format3 === "MMM" && this._shortMonthsParse[i].test(monthName)) {
14162
- return i;
14163
- } else if (!strict && this._monthsParse[i].test(monthName)) {
14164
- return i;
14165
- }
14166
- }
14167
- }
14168
- function setMonth2(mom, value) {
14169
- if (!mom.isValid()) {
14170
- return mom;
14171
- }
14172
- if (typeof value === "string") {
14173
- if (/^\d+$/.test(value)) {
14174
- value = toInt2(value);
14175
- } else {
14176
- value = mom.localeData().monthsParse(value);
14177
- if (!isNumber2(value)) {
14178
- return mom;
14179
- }
14180
- }
14181
- }
14182
- var month = value, date = mom.date();
14183
- date = date < 29 ? date : Math.min(date, daysInMonth2(mom.year(), month));
14184
- void (mom._isUTC ? mom._d.setUTCMonth(month, date) : mom._d.setMonth(month, date));
14185
- return mom;
14186
- }
14187
- function getSetMonth2(value) {
14188
- if (value != null) {
14189
- setMonth2(this, value);
14190
- hooks2.updateOffset(this, true);
14191
- return this;
14192
- } else {
14193
- return get2(this, "Month");
14194
- }
14195
- }
14196
- function getDaysInMonth2() {
14197
- return daysInMonth2(this.year(), this.month());
14198
- }
14199
- function monthsShortRegex2(isStrict) {
14200
- if (this._monthsParseExact) {
14201
- if (!hasOwnProp2(this, "_monthsRegex")) {
14202
- computeMonthsParse2.call(this);
14203
- }
14204
- if (isStrict) {
14205
- return this._monthsShortStrictRegex;
14206
- } else {
14207
- return this._monthsShortRegex;
14208
- }
14209
- } else {
14210
- if (!hasOwnProp2(this, "_monthsShortRegex")) {
14211
- this._monthsShortRegex = defaultMonthsShortRegex2;
14212
- }
14213
- return this._monthsShortStrictRegex && isStrict ? this._monthsShortStrictRegex : this._monthsShortRegex;
14214
- }
14215
- }
14216
- function monthsRegex2(isStrict) {
14217
- if (this._monthsParseExact) {
14218
- if (!hasOwnProp2(this, "_monthsRegex")) {
14219
- computeMonthsParse2.call(this);
14220
- }
14221
- if (isStrict) {
14222
- return this._monthsStrictRegex;
14223
- } else {
14224
- return this._monthsRegex;
14225
- }
14226
- } else {
14227
- if (!hasOwnProp2(this, "_monthsRegex")) {
14228
- this._monthsRegex = defaultMonthsRegex2;
14229
- }
14230
- return this._monthsStrictRegex && isStrict ? this._monthsStrictRegex : this._monthsRegex;
14231
- }
14232
- }
14233
- function computeMonthsParse2() {
14234
- function cmpLenRev(a2, b) {
14235
- return b.length - a2.length;
14236
- }
14237
- var shortPieces = [], longPieces = [], mixedPieces = [], i, mom, shortP, longP;
14238
- for (i = 0; i < 12; i++) {
14239
- mom = createUTC2([2e3, i]);
14240
- shortP = regexEscape2(this.monthsShort(mom, ""));
14241
- longP = regexEscape2(this.months(mom, ""));
14242
- shortPieces.push(shortP);
14243
- longPieces.push(longP);
14244
- mixedPieces.push(longP);
14245
- mixedPieces.push(shortP);
14246
- }
14247
- shortPieces.sort(cmpLenRev);
14248
- longPieces.sort(cmpLenRev);
14249
- mixedPieces.sort(cmpLenRev);
14250
- this._monthsRegex = new RegExp("^(" + mixedPieces.join("|") + ")", "i");
14251
- this._monthsShortRegex = this._monthsRegex;
14252
- this._monthsStrictRegex = new RegExp(
14253
- "^(" + longPieces.join("|") + ")",
14254
- "i"
14255
- );
14256
- this._monthsShortStrictRegex = new RegExp(
14257
- "^(" + shortPieces.join("|") + ")",
14258
- "i"
14259
- );
14260
- }
14261
- function createDate2(y, m, d, h, M, s2, ms) {
14262
- var date;
14263
- if (y < 100 && y >= 0) {
14264
- date = new Date(y + 400, m, d, h, M, s2, ms);
14265
- if (isFinite(date.getFullYear())) {
14266
- date.setFullYear(y);
14267
- }
14268
- } else {
14269
- date = new Date(y, m, d, h, M, s2, ms);
14270
- }
14271
- return date;
14272
- }
14273
- function createUTCDate2(y) {
14274
- var date, args;
14275
- if (y < 100 && y >= 0) {
14276
- args = Array.prototype.slice.call(arguments);
14277
- args[0] = y + 400;
14278
- date = new Date(Date.UTC.apply(null, args));
14279
- if (isFinite(date.getUTCFullYear())) {
14280
- date.setUTCFullYear(y);
14281
- }
14282
- } else {
14283
- date = new Date(Date.UTC.apply(null, arguments));
14284
- }
14285
- return date;
14286
- }
14287
- function firstWeekOffset2(year, dow, doy) {
14288
- var fwd = 7 + dow - doy, fwdlw = (7 + createUTCDate2(year, 0, fwd).getUTCDay() - dow) % 7;
14289
- return -fwdlw + fwd - 1;
14290
- }
14291
- function dayOfYearFromWeeks2(year, week, weekday, dow, doy) {
14292
- var localWeekday = (7 + weekday - dow) % 7, weekOffset = firstWeekOffset2(year, dow, doy), dayOfYear = 1 + 7 * (week - 1) + localWeekday + weekOffset, resYear, resDayOfYear;
14293
- if (dayOfYear <= 0) {
14294
- resYear = year - 1;
14295
- resDayOfYear = daysInYear2(resYear) + dayOfYear;
14296
- } else if (dayOfYear > daysInYear2(year)) {
14297
- resYear = year + 1;
14298
- resDayOfYear = dayOfYear - daysInYear2(year);
14299
- } else {
14300
- resYear = year;
14301
- resDayOfYear = dayOfYear;
14302
- }
14303
- return {
14304
- year: resYear,
14305
- dayOfYear: resDayOfYear
14306
- };
14307
- }
14308
- function weekOfYear2(mom, dow, doy) {
14309
- var weekOffset = firstWeekOffset2(mom.year(), dow, doy), week = Math.floor((mom.dayOfYear() - weekOffset - 1) / 7) + 1, resWeek, resYear;
14310
- if (week < 1) {
14311
- resYear = mom.year() - 1;
14312
- resWeek = week + weeksInYear2(resYear, dow, doy);
14313
- } else if (week > weeksInYear2(mom.year(), dow, doy)) {
14314
- resWeek = week - weeksInYear2(mom.year(), dow, doy);
14315
- resYear = mom.year() + 1;
14316
- } else {
14317
- resYear = mom.year();
14318
- resWeek = week;
14319
- }
14320
- return {
14321
- week: resWeek,
14322
- year: resYear
14323
- };
14324
- }
14325
- function weeksInYear2(year, dow, doy) {
14326
- var weekOffset = firstWeekOffset2(year, dow, doy), weekOffsetNext = firstWeekOffset2(year + 1, dow, doy);
14327
- return (daysInYear2(year) - weekOffset + weekOffsetNext) / 7;
14328
- }
14329
- addFormatToken2("w", ["ww", 2], "wo", "week");
14330
- addFormatToken2("W", ["WW", 2], "Wo", "isoWeek");
14331
- addRegexToken2("w", match1to22, match1to2NoLeadingZero2);
14332
- addRegexToken2("ww", match1to22, match22);
14333
- addRegexToken2("W", match1to22, match1to2NoLeadingZero2);
14334
- addRegexToken2("WW", match1to22, match22);
14335
- addWeekParseToken2(
14336
- ["w", "ww", "W", "WW"],
14337
- function(input, week, config, token3) {
14338
- week[token3.substr(0, 1)] = toInt2(input);
14339
- }
14340
- );
14341
- function localeWeek2(mom) {
14342
- return weekOfYear2(mom, this._week.dow, this._week.doy).week;
14343
- }
14344
- var defaultLocaleWeek2 = {
14345
- dow: 0,
14346
- // Sunday is the first day of the week.
14347
- doy: 6
14348
- // The week that contains Jan 6th is the first week of the year.
14349
- };
14350
- function localeFirstDayOfWeek2() {
14351
- return this._week.dow;
14352
- }
14353
- function localeFirstDayOfYear2() {
14354
- return this._week.doy;
14355
- }
14356
- function getSetWeek2(input) {
14357
- var week = this.localeData().week(this);
14358
- return input == null ? week : this.add((input - week) * 7, "d");
14359
- }
14360
- function getSetISOWeek2(input) {
14361
- var week = weekOfYear2(this, 1, 4).week;
14362
- return input == null ? week : this.add((input - week) * 7, "d");
14363
- }
14364
- addFormatToken2("d", 0, "do", "day");
14365
- addFormatToken2("dd", 0, 0, function(format3) {
14366
- return this.localeData().weekdaysMin(this, format3);
14367
- });
14368
- addFormatToken2("ddd", 0, 0, function(format3) {
14369
- return this.localeData().weekdaysShort(this, format3);
14370
- });
14371
- addFormatToken2("dddd", 0, 0, function(format3) {
14372
- return this.localeData().weekdays(this, format3);
14373
- });
14374
- addFormatToken2("e", 0, 0, "weekday");
14375
- addFormatToken2("E", 0, 0, "isoWeekday");
14376
- addRegexToken2("d", match1to22);
14377
- addRegexToken2("e", match1to22);
14378
- addRegexToken2("E", match1to22);
14379
- addRegexToken2("dd", function(isStrict, locale3) {
14380
- return locale3.weekdaysMinRegex(isStrict);
14381
- });
14382
- addRegexToken2("ddd", function(isStrict, locale3) {
14383
- return locale3.weekdaysShortRegex(isStrict);
14384
- });
14385
- addRegexToken2("dddd", function(isStrict, locale3) {
14386
- return locale3.weekdaysRegex(isStrict);
14387
- });
14388
- addWeekParseToken2(["dd", "ddd", "dddd"], function(input, week, config, token3) {
14389
- var weekday = config._locale.weekdaysParse(input, token3, config._strict);
14390
- if (weekday != null) {
14391
- week.d = weekday;
14392
- } else {
14393
- getParsingFlags2(config).invalidWeekday = input;
14394
- }
14395
- });
14396
- addWeekParseToken2(["d", "e", "E"], function(input, week, config, token3) {
14397
- week[token3] = toInt2(input);
14398
- });
14399
- function parseWeekday2(input, locale3) {
14400
- if (typeof input !== "string") {
14401
- return input;
14402
- }
14403
- if (!isNaN(input)) {
14404
- return parseInt(input, 10);
14405
- }
14406
- input = locale3.weekdaysParse(input);
14407
- if (typeof input === "number") {
14408
- return input;
14409
- }
14410
- return null;
14411
- }
14412
- function parseIsoWeekday2(input, locale3) {
14413
- if (typeof input === "string") {
14414
- return locale3.weekdaysParse(input) % 7 || 7;
14415
- }
14416
- return isNaN(input) ? null : input;
14417
- }
14418
- function shiftWeekdays2(ws, n) {
14419
- return ws.slice(n, 7).concat(ws.slice(0, n));
14420
- }
14421
- var defaultLocaleWeekdays2 = "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), defaultLocaleWeekdaysShort2 = "Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"), defaultLocaleWeekdaysMin2 = "Su_Mo_Tu_We_Th_Fr_Sa".split("_"), defaultWeekdaysRegex2 = matchWord2, defaultWeekdaysShortRegex2 = matchWord2, defaultWeekdaysMinRegex2 = matchWord2;
14422
- function localeWeekdays2(m, format3) {
14423
- var weekdays = isArray2(this._weekdays) ? this._weekdays : this._weekdays[m && m !== true && this._weekdays.isFormat.test(format3) ? "format" : "standalone"];
14424
- return m === true ? shiftWeekdays2(weekdays, this._week.dow) : m ? weekdays[m.day()] : weekdays;
14425
- }
14426
- function localeWeekdaysShort2(m) {
14427
- return m === true ? shiftWeekdays2(this._weekdaysShort, this._week.dow) : m ? this._weekdaysShort[m.day()] : this._weekdaysShort;
14428
- }
14429
- function localeWeekdaysMin2(m) {
14430
- return m === true ? shiftWeekdays2(this._weekdaysMin, this._week.dow) : m ? this._weekdaysMin[m.day()] : this._weekdaysMin;
14431
- }
14432
- function handleStrictParse$12(weekdayName, format3, strict) {
14433
- var i, ii, mom, llc = weekdayName.toLocaleLowerCase();
14434
- if (!this._weekdaysParse) {
14435
- this._weekdaysParse = [];
14436
- this._shortWeekdaysParse = [];
14437
- this._minWeekdaysParse = [];
14438
- for (i = 0; i < 7; ++i) {
14439
- mom = createUTC2([2e3, 1]).day(i);
14440
- this._minWeekdaysParse[i] = this.weekdaysMin(
14441
- mom,
14442
- ""
14443
- ).toLocaleLowerCase();
14444
- this._shortWeekdaysParse[i] = this.weekdaysShort(
14445
- mom,
14446
- ""
14447
- ).toLocaleLowerCase();
14448
- this._weekdaysParse[i] = this.weekdays(mom, "").toLocaleLowerCase();
14449
- }
14450
- }
14451
- if (strict) {
14452
- if (format3 === "dddd") {
14453
- ii = indexOf2.call(this._weekdaysParse, llc);
14454
- return ii !== -1 ? ii : null;
14455
- } else if (format3 === "ddd") {
14456
- ii = indexOf2.call(this._shortWeekdaysParse, llc);
14457
- return ii !== -1 ? ii : null;
14458
- } else {
14459
- ii = indexOf2.call(this._minWeekdaysParse, llc);
14460
- return ii !== -1 ? ii : null;
14461
- }
14462
- } else {
14463
- if (format3 === "dddd") {
14464
- ii = indexOf2.call(this._weekdaysParse, llc);
14465
- if (ii !== -1) {
14466
- return ii;
14467
- }
14468
- ii = indexOf2.call(this._shortWeekdaysParse, llc);
14469
- if (ii !== -1) {
14470
- return ii;
14471
- }
14472
- ii = indexOf2.call(this._minWeekdaysParse, llc);
14473
- return ii !== -1 ? ii : null;
14474
- } else if (format3 === "ddd") {
14475
- ii = indexOf2.call(this._shortWeekdaysParse, llc);
14476
- if (ii !== -1) {
14477
- return ii;
14478
- }
14479
- ii = indexOf2.call(this._weekdaysParse, llc);
14480
- if (ii !== -1) {
14481
- return ii;
14482
- }
14483
- ii = indexOf2.call(this._minWeekdaysParse, llc);
14484
- return ii !== -1 ? ii : null;
14485
- } else {
14486
- ii = indexOf2.call(this._minWeekdaysParse, llc);
14487
- if (ii !== -1) {
14488
- return ii;
14489
- }
14490
- ii = indexOf2.call(this._weekdaysParse, llc);
14491
- if (ii !== -1) {
14492
- return ii;
14493
- }
14494
- ii = indexOf2.call(this._shortWeekdaysParse, llc);
14495
- return ii !== -1 ? ii : null;
14496
- }
14497
- }
14498
- }
14499
- function localeWeekdaysParse2(weekdayName, format3, strict) {
14500
- var i, mom, regex;
14501
- if (this._weekdaysParseExact) {
14502
- return handleStrictParse$12.call(this, weekdayName, format3, strict);
14503
- }
14504
- if (!this._weekdaysParse) {
14505
- this._weekdaysParse = [];
14506
- this._minWeekdaysParse = [];
14507
- this._shortWeekdaysParse = [];
14508
- this._fullWeekdaysParse = [];
14509
- }
14510
- for (i = 0; i < 7; i++) {
14511
- mom = createUTC2([2e3, 1]).day(i);
14512
- if (strict && !this._fullWeekdaysParse[i]) {
14513
- this._fullWeekdaysParse[i] = new RegExp(
14514
- "^" + this.weekdays(mom, "").replace(".", "\\.?") + "$",
14515
- "i"
14516
- );
14517
- this._shortWeekdaysParse[i] = new RegExp(
14518
- "^" + this.weekdaysShort(mom, "").replace(".", "\\.?") + "$",
14519
- "i"
14520
- );
14521
- this._minWeekdaysParse[i] = new RegExp(
14522
- "^" + this.weekdaysMin(mom, "").replace(".", "\\.?") + "$",
14523
- "i"
14524
- );
14525
- }
14526
- if (!this._weekdaysParse[i]) {
14527
- regex = "^" + this.weekdays(mom, "") + "|^" + this.weekdaysShort(mom, "") + "|^" + this.weekdaysMin(mom, "");
14528
- this._weekdaysParse[i] = new RegExp(regex.replace(".", ""), "i");
14529
- }
14530
- if (strict && format3 === "dddd" && this._fullWeekdaysParse[i].test(weekdayName)) {
14531
- return i;
14532
- } else if (strict && format3 === "ddd" && this._shortWeekdaysParse[i].test(weekdayName)) {
14533
- return i;
14534
- } else if (strict && format3 === "dd" && this._minWeekdaysParse[i].test(weekdayName)) {
14535
- return i;
14536
- } else if (!strict && this._weekdaysParse[i].test(weekdayName)) {
14537
- return i;
14538
- }
14539
- }
14540
- }
14541
- function getSetDayOfWeek2(input) {
14542
- if (!this.isValid()) {
14543
- return input != null ? this : NaN;
14544
- }
14545
- var day = get2(this, "Day");
14546
- if (input != null) {
14547
- input = parseWeekday2(input, this.localeData());
14548
- return this.add(input - day, "d");
14549
- } else {
14550
- return day;
14551
- }
14552
- }
14553
- function getSetLocaleDayOfWeek2(input) {
14554
- if (!this.isValid()) {
14555
- return input != null ? this : NaN;
14556
- }
14557
- var weekday = (this.day() + 7 - this.localeData()._week.dow) % 7;
14558
- return input == null ? weekday : this.add(input - weekday, "d");
14559
- }
14560
- function getSetISODayOfWeek2(input) {
14561
- if (!this.isValid()) {
14562
- return input != null ? this : NaN;
14563
- }
14564
- if (input != null) {
14565
- var weekday = parseIsoWeekday2(input, this.localeData());
14566
- return this.day(this.day() % 7 ? weekday : weekday - 7);
14567
- } else {
14568
- return this.day() || 7;
14569
- }
14570
- }
14571
- function weekdaysRegex2(isStrict) {
14572
- if (this._weekdaysParseExact) {
14573
- if (!hasOwnProp2(this, "_weekdaysRegex")) {
14574
- computeWeekdaysParse2.call(this);
14575
- }
14576
- if (isStrict) {
14577
- return this._weekdaysStrictRegex;
14578
- } else {
14579
- return this._weekdaysRegex;
14580
- }
14581
- } else {
14582
- if (!hasOwnProp2(this, "_weekdaysRegex")) {
14583
- this._weekdaysRegex = defaultWeekdaysRegex2;
14584
- }
14585
- return this._weekdaysStrictRegex && isStrict ? this._weekdaysStrictRegex : this._weekdaysRegex;
14586
- }
14587
- }
14588
- function weekdaysShortRegex2(isStrict) {
14589
- if (this._weekdaysParseExact) {
14590
- if (!hasOwnProp2(this, "_weekdaysRegex")) {
14591
- computeWeekdaysParse2.call(this);
14592
- }
14593
- if (isStrict) {
14594
- return this._weekdaysShortStrictRegex;
14595
- } else {
14596
- return this._weekdaysShortRegex;
14597
- }
14598
- } else {
14599
- if (!hasOwnProp2(this, "_weekdaysShortRegex")) {
14600
- this._weekdaysShortRegex = defaultWeekdaysShortRegex2;
14601
- }
14602
- return this._weekdaysShortStrictRegex && isStrict ? this._weekdaysShortStrictRegex : this._weekdaysShortRegex;
14603
- }
14604
- }
14605
- function weekdaysMinRegex2(isStrict) {
14606
- if (this._weekdaysParseExact) {
14607
- if (!hasOwnProp2(this, "_weekdaysRegex")) {
14608
- computeWeekdaysParse2.call(this);
14609
- }
14610
- if (isStrict) {
14611
- return this._weekdaysMinStrictRegex;
14612
- } else {
14613
- return this._weekdaysMinRegex;
14614
- }
14615
- } else {
14616
- if (!hasOwnProp2(this, "_weekdaysMinRegex")) {
14617
- this._weekdaysMinRegex = defaultWeekdaysMinRegex2;
14618
- }
14619
- return this._weekdaysMinStrictRegex && isStrict ? this._weekdaysMinStrictRegex : this._weekdaysMinRegex;
14620
- }
14621
- }
14622
- function computeWeekdaysParse2() {
14623
- function cmpLenRev(a2, b) {
14624
- return b.length - a2.length;
14625
- }
14626
- var minPieces = [], shortPieces = [], longPieces = [], mixedPieces = [], i, mom, minp, shortp, longp;
14627
- for (i = 0; i < 7; i++) {
14628
- mom = createUTC2([2e3, 1]).day(i);
14629
- minp = regexEscape2(this.weekdaysMin(mom, ""));
14630
- shortp = regexEscape2(this.weekdaysShort(mom, ""));
14631
- longp = regexEscape2(this.weekdays(mom, ""));
14632
- minPieces.push(minp);
14633
- shortPieces.push(shortp);
14634
- longPieces.push(longp);
14635
- mixedPieces.push(minp);
14636
- mixedPieces.push(shortp);
14637
- mixedPieces.push(longp);
14638
- }
14639
- minPieces.sort(cmpLenRev);
14640
- shortPieces.sort(cmpLenRev);
14641
- longPieces.sort(cmpLenRev);
14642
- mixedPieces.sort(cmpLenRev);
14643
- this._weekdaysRegex = new RegExp("^(" + mixedPieces.join("|") + ")", "i");
14644
- this._weekdaysShortRegex = this._weekdaysRegex;
14645
- this._weekdaysMinRegex = this._weekdaysRegex;
14646
- this._weekdaysStrictRegex = new RegExp(
14647
- "^(" + longPieces.join("|") + ")",
14648
- "i"
14649
- );
14650
- this._weekdaysShortStrictRegex = new RegExp(
14651
- "^(" + shortPieces.join("|") + ")",
14652
- "i"
14653
- );
14654
- this._weekdaysMinStrictRegex = new RegExp(
14655
- "^(" + minPieces.join("|") + ")",
14656
- "i"
14657
- );
14658
- }
14659
- function hFormat2() {
14660
- return this.hours() % 12 || 12;
14661
- }
14662
- function kFormat2() {
14663
- return this.hours() || 24;
14664
- }
14665
- addFormatToken2("H", ["HH", 2], 0, "hour");
14666
- addFormatToken2("h", ["hh", 2], 0, hFormat2);
14667
- addFormatToken2("k", ["kk", 2], 0, kFormat2);
14668
- addFormatToken2("hmm", 0, 0, function() {
14669
- return "" + hFormat2.apply(this) + zeroFill2(this.minutes(), 2);
14670
- });
14671
- addFormatToken2("hmmss", 0, 0, function() {
14672
- return "" + hFormat2.apply(this) + zeroFill2(this.minutes(), 2) + zeroFill2(this.seconds(), 2);
14673
- });
14674
- addFormatToken2("Hmm", 0, 0, function() {
14675
- return "" + this.hours() + zeroFill2(this.minutes(), 2);
14676
- });
14677
- addFormatToken2("Hmmss", 0, 0, function() {
14678
- return "" + this.hours() + zeroFill2(this.minutes(), 2) + zeroFill2(this.seconds(), 2);
14679
- });
14680
- function meridiem2(token3, lowercase) {
14681
- addFormatToken2(token3, 0, 0, function() {
14682
- return this.localeData().meridiem(
14683
- this.hours(),
14684
- this.minutes(),
14685
- lowercase
14686
- );
14687
- });
14688
- }
14689
- meridiem2("a", true);
14690
- meridiem2("A", false);
14691
- function matchMeridiem2(isStrict, locale3) {
14692
- return locale3._meridiemParse;
14693
- }
14694
- addRegexToken2("a", matchMeridiem2);
14695
- addRegexToken2("A", matchMeridiem2);
14696
- addRegexToken2("H", match1to22, match1to2HasZero2);
14697
- addRegexToken2("h", match1to22, match1to2NoLeadingZero2);
14698
- addRegexToken2("k", match1to22, match1to2NoLeadingZero2);
14699
- addRegexToken2("HH", match1to22, match22);
14700
- addRegexToken2("hh", match1to22, match22);
14701
- addRegexToken2("kk", match1to22, match22);
14702
- addRegexToken2("hmm", match3to42);
14703
- addRegexToken2("hmmss", match5to62);
14704
- addRegexToken2("Hmm", match3to42);
14705
- addRegexToken2("Hmmss", match5to62);
14706
- addParseToken2(["H", "HH"], HOUR2);
14707
- addParseToken2(["k", "kk"], function(input, array, config) {
14708
- var kInput = toInt2(input);
14709
- array[HOUR2] = kInput === 24 ? 0 : kInput;
14710
- });
14711
- addParseToken2(["a", "A"], function(input, array, config) {
14712
- config._isPm = config._locale.isPM(input);
14713
- config._meridiem = input;
14714
- });
14715
- addParseToken2(["h", "hh"], function(input, array, config) {
14716
- array[HOUR2] = toInt2(input);
14717
- getParsingFlags2(config).bigHour = true;
14718
- });
14719
- addParseToken2("hmm", function(input, array, config) {
14720
- var pos = input.length - 2;
14721
- array[HOUR2] = toInt2(input.substr(0, pos));
14722
- array[MINUTE2] = toInt2(input.substr(pos));
14723
- getParsingFlags2(config).bigHour = true;
14724
- });
14725
- addParseToken2("hmmss", function(input, array, config) {
14726
- var pos1 = input.length - 4, pos2 = input.length - 2;
14727
- array[HOUR2] = toInt2(input.substr(0, pos1));
14728
- array[MINUTE2] = toInt2(input.substr(pos1, 2));
14729
- array[SECOND2] = toInt2(input.substr(pos2));
14730
- getParsingFlags2(config).bigHour = true;
14731
- });
14732
- addParseToken2("Hmm", function(input, array, config) {
14733
- var pos = input.length - 2;
14734
- array[HOUR2] = toInt2(input.substr(0, pos));
14735
- array[MINUTE2] = toInt2(input.substr(pos));
14736
- });
14737
- addParseToken2("Hmmss", function(input, array, config) {
14738
- var pos1 = input.length - 4, pos2 = input.length - 2;
14739
- array[HOUR2] = toInt2(input.substr(0, pos1));
14740
- array[MINUTE2] = toInt2(input.substr(pos1, 2));
14741
- array[SECOND2] = toInt2(input.substr(pos2));
14742
- });
14743
- function localeIsPM2(input) {
14744
- return (input + "").toLowerCase().charAt(0) === "p";
14745
- }
14746
- var defaultLocaleMeridiemParse2 = /[ap]\.?m?\.?/i, getSetHour2 = makeGetSet2("Hours", true);
14747
- function localeMeridiem2(hours3, minutes3, isLower) {
14748
- if (hours3 > 11) {
14749
- return isLower ? "pm" : "PM";
14750
- } else {
14751
- return isLower ? "am" : "AM";
14752
- }
14753
- }
14754
- var baseConfig2 = {
14755
- calendar: defaultCalendar2,
14756
- longDateFormat: defaultLongDateFormat2,
14757
- invalidDate: defaultInvalidDate2,
14758
- ordinal: defaultOrdinal2,
14759
- dayOfMonthOrdinalParse: defaultDayOfMonthOrdinalParse2,
14760
- relativeTime: defaultRelativeTime2,
14761
- months: defaultLocaleMonths2,
14762
- monthsShort: defaultLocaleMonthsShort2,
14763
- week: defaultLocaleWeek2,
14764
- weekdays: defaultLocaleWeekdays2,
14765
- weekdaysMin: defaultLocaleWeekdaysMin2,
14766
- weekdaysShort: defaultLocaleWeekdaysShort2,
14767
- meridiemParse: defaultLocaleMeridiemParse2
14768
- };
14769
- var locales2 = {}, localeFamilies2 = {}, globalLocale2;
14770
- function commonPrefix2(arr1, arr2) {
14771
- var i, minl = Math.min(arr1.length, arr2.length);
14772
- for (i = 0; i < minl; i += 1) {
14773
- if (arr1[i] !== arr2[i]) {
14774
- return i;
14775
- }
14776
- }
14777
- return minl;
14778
- }
14779
- function normalizeLocale2(key) {
14780
- return key ? key.toLowerCase().replace("_", "-") : key;
14781
- }
14782
- function chooseLocale2(names) {
14783
- var i = 0, j, next, locale3, split;
14784
- while (i < names.length) {
14785
- split = normalizeLocale2(names[i]).split("-");
14786
- j = split.length;
14787
- next = normalizeLocale2(names[i + 1]);
14788
- next = next ? next.split("-") : null;
14789
- while (j > 0) {
14790
- locale3 = loadLocale2(split.slice(0, j).join("-"));
14791
- if (locale3) {
14792
- return locale3;
14793
- }
14794
- if (next && next.length >= j && commonPrefix2(split, next) >= j - 1) {
14795
- break;
14796
- }
14797
- j--;
14798
- }
14799
- i++;
14800
- }
14801
- return globalLocale2;
14802
- }
14803
- function isLocaleNameSane2(name) {
14804
- return !!(name && name.match("^[^/\\\\]*$"));
14805
- }
14806
- function loadLocale2(name) {
14807
- var oldLocale = null, aliasedRequire;
14808
- if (locales2[name] === void 0 && true && module2 && module2.exports && isLocaleNameSane2(name)) {
14809
- try {
14810
- oldLocale = globalLocale2._abbr;
14811
- aliasedRequire = commonjsRequire;
14812
- aliasedRequire("./locale/" + name);
14813
- getSetGlobalLocale2(oldLocale);
14814
- } catch (e2) {
14815
- locales2[name] = null;
14816
- }
14817
- }
14818
- return locales2[name];
14819
- }
14820
- function getSetGlobalLocale2(key, values) {
14821
- var data;
14822
- if (key) {
14823
- if (isUndefined2(values)) {
14824
- data = getLocale2(key);
14825
- } else {
14826
- data = defineLocale2(key, values);
14827
- }
14828
- if (data) {
14829
- globalLocale2 = data;
14830
- } else {
14831
- if (typeof console !== "undefined" && console.warn) {
14832
- console.warn(
14833
- "Locale " + key + " not found. Did you forget to load it?"
14834
- );
14835
- }
14836
- }
14837
- }
14838
- return globalLocale2._abbr;
14839
- }
14840
- function defineLocale2(name, config) {
14841
- if (config !== null) {
14842
- var locale3, parentConfig = baseConfig2;
14843
- config.abbr = name;
14844
- if (locales2[name] != null) {
14845
- deprecateSimple2(
14846
- "defineLocaleOverride",
14847
- "use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."
14848
- );
14849
- parentConfig = locales2[name]._config;
14850
- } else if (config.parentLocale != null) {
14851
- if (locales2[config.parentLocale] != null) {
14852
- parentConfig = locales2[config.parentLocale]._config;
14853
- } else {
14854
- locale3 = loadLocale2(config.parentLocale);
14855
- if (locale3 != null) {
14856
- parentConfig = locale3._config;
14857
- } else {
14858
- if (!localeFamilies2[config.parentLocale]) {
14859
- localeFamilies2[config.parentLocale] = [];
14860
- }
14861
- localeFamilies2[config.parentLocale].push({
14862
- name,
14863
- config
14864
- });
14865
- return null;
14866
- }
14867
- }
14868
- }
14869
- locales2[name] = new Locale2(mergeConfigs2(parentConfig, config));
14870
- if (localeFamilies2[name]) {
14871
- localeFamilies2[name].forEach(function(x) {
14872
- defineLocale2(x.name, x.config);
14873
- });
14874
- }
14875
- getSetGlobalLocale2(name);
14876
- return locales2[name];
14877
- } else {
14878
- delete locales2[name];
14879
- return null;
14880
- }
14881
- }
14882
- function updateLocale2(name, config) {
14883
- if (config != null) {
14884
- var locale3, tmpLocale, parentConfig = baseConfig2;
14885
- if (locales2[name] != null && locales2[name].parentLocale != null) {
14886
- locales2[name].set(mergeConfigs2(locales2[name]._config, config));
14887
- } else {
14888
- tmpLocale = loadLocale2(name);
14889
- if (tmpLocale != null) {
14890
- parentConfig = tmpLocale._config;
14891
- }
14892
- config = mergeConfigs2(parentConfig, config);
14893
- if (tmpLocale == null) {
14894
- config.abbr = name;
14895
- }
14896
- locale3 = new Locale2(config);
14897
- locale3.parentLocale = locales2[name];
14898
- locales2[name] = locale3;
14899
- }
14900
- getSetGlobalLocale2(name);
14901
- } else {
14902
- if (locales2[name] != null) {
14903
- if (locales2[name].parentLocale != null) {
14904
- locales2[name] = locales2[name].parentLocale;
14905
- if (name === getSetGlobalLocale2()) {
14906
- getSetGlobalLocale2(name);
14907
- }
14908
- } else if (locales2[name] != null) {
14909
- delete locales2[name];
14910
- }
14911
- }
14912
- }
14913
- return locales2[name];
14914
- }
14915
- function getLocale2(key) {
14916
- var locale3;
14917
- if (key && key._locale && key._locale._abbr) {
14918
- key = key._locale._abbr;
14919
- }
14920
- if (!key) {
14921
- return globalLocale2;
14922
- }
14923
- if (!isArray2(key)) {
14924
- locale3 = loadLocale2(key);
14925
- if (locale3) {
14926
- return locale3;
14927
- }
14928
- key = [key];
14929
- }
14930
- return chooseLocale2(key);
14931
- }
14932
- function listLocales2() {
14933
- return keys2(locales2);
14934
- }
14935
- function checkOverflow2(m) {
14936
- var overflow, a2 = m._a;
14937
- if (a2 && getParsingFlags2(m).overflow === -2) {
14938
- overflow = a2[MONTH2] < 0 || a2[MONTH2] > 11 ? MONTH2 : a2[DATE2] < 1 || a2[DATE2] > daysInMonth2(a2[YEAR2], a2[MONTH2]) ? DATE2 : a2[HOUR2] < 0 || a2[HOUR2] > 24 || a2[HOUR2] === 24 && (a2[MINUTE2] !== 0 || a2[SECOND2] !== 0 || a2[MILLISECOND2] !== 0) ? HOUR2 : a2[MINUTE2] < 0 || a2[MINUTE2] > 59 ? MINUTE2 : a2[SECOND2] < 0 || a2[SECOND2] > 59 ? SECOND2 : a2[MILLISECOND2] < 0 || a2[MILLISECOND2] > 999 ? MILLISECOND2 : -1;
14939
- if (getParsingFlags2(m)._overflowDayOfYear && (overflow < YEAR2 || overflow > DATE2)) {
14940
- overflow = DATE2;
14941
- }
14942
- if (getParsingFlags2(m)._overflowWeeks && overflow === -1) {
14943
- overflow = WEEK2;
14944
- }
14945
- if (getParsingFlags2(m)._overflowWeekday && overflow === -1) {
14946
- overflow = WEEKDAY2;
14947
- }
14948
- getParsingFlags2(m).overflow = overflow;
14949
- }
14950
- return m;
14951
- }
14952
- var extendedIsoRegex2 = /^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/, basicIsoRegex2 = /^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d|))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/, tzRegex2 = /Z|[+-]\d\d(?::?\d\d)?/, isoDates2 = [
14953
- ["YYYYYY-MM-DD", /[+-]\d{6}-\d\d-\d\d/],
14954
- ["YYYY-MM-DD", /\d{4}-\d\d-\d\d/],
14955
- ["GGGG-[W]WW-E", /\d{4}-W\d\d-\d/],
14956
- ["GGGG-[W]WW", /\d{4}-W\d\d/, false],
14957
- ["YYYY-DDD", /\d{4}-\d{3}/],
14958
- ["YYYY-MM", /\d{4}-\d\d/, false],
14959
- ["YYYYYYMMDD", /[+-]\d{10}/],
14960
- ["YYYYMMDD", /\d{8}/],
14961
- ["GGGG[W]WWE", /\d{4}W\d{3}/],
14962
- ["GGGG[W]WW", /\d{4}W\d{2}/, false],
14963
- ["YYYYDDD", /\d{7}/],
14964
- ["YYYYMM", /\d{6}/, false],
14965
- ["YYYY", /\d{4}/, false]
14966
- ], isoTimes2 = [
14967
- ["HH:mm:ss.SSSS", /\d\d:\d\d:\d\d\.\d+/],
14968
- ["HH:mm:ss,SSSS", /\d\d:\d\d:\d\d,\d+/],
14969
- ["HH:mm:ss", /\d\d:\d\d:\d\d/],
14970
- ["HH:mm", /\d\d:\d\d/],
14971
- ["HHmmss.SSSS", /\d\d\d\d\d\d\.\d+/],
14972
- ["HHmmss,SSSS", /\d\d\d\d\d\d,\d+/],
14973
- ["HHmmss", /\d\d\d\d\d\d/],
14974
- ["HHmm", /\d\d\d\d/],
14975
- ["HH", /\d\d/]
14976
- ], aspNetJsonRegex2 = /^\/?Date\((-?\d+)/i, rfc28222 = /^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/, obsOffsets2 = {
14977
- UT: 0,
14978
- GMT: 0,
14979
- EDT: -4 * 60,
14980
- EST: -5 * 60,
14981
- CDT: -5 * 60,
14982
- CST: -6 * 60,
14983
- MDT: -6 * 60,
14984
- MST: -7 * 60,
14985
- PDT: -7 * 60,
14986
- PST: -8 * 60
14987
- };
14988
- function configFromISO2(config) {
14989
- var i, l, string = config._i, match = extendedIsoRegex2.exec(string) || basicIsoRegex2.exec(string), allowTime, dateFormat, timeFormat, tzFormat, isoDatesLen = isoDates2.length, isoTimesLen = isoTimes2.length;
14990
- if (match) {
14991
- getParsingFlags2(config).iso = true;
14992
- for (i = 0, l = isoDatesLen; i < l; i++) {
14993
- if (isoDates2[i][1].exec(match[1])) {
14994
- dateFormat = isoDates2[i][0];
14995
- allowTime = isoDates2[i][2] !== false;
14996
- break;
14997
- }
14998
- }
14999
- if (dateFormat == null) {
15000
- config._isValid = false;
15001
- return;
15002
- }
15003
- if (match[3]) {
15004
- for (i = 0, l = isoTimesLen; i < l; i++) {
15005
- if (isoTimes2[i][1].exec(match[3])) {
15006
- timeFormat = (match[2] || " ") + isoTimes2[i][0];
15007
- break;
15008
- }
15009
- }
15010
- if (timeFormat == null) {
15011
- config._isValid = false;
15012
- return;
15013
- }
15014
- }
15015
- if (!allowTime && timeFormat != null) {
15016
- config._isValid = false;
15017
- return;
15018
- }
15019
- if (match[4]) {
15020
- if (tzRegex2.exec(match[4])) {
15021
- tzFormat = "Z";
15022
- } else {
15023
- config._isValid = false;
15024
- return;
15025
- }
15026
- }
15027
- config._f = dateFormat + (timeFormat || "") + (tzFormat || "");
15028
- configFromStringAndFormat2(config);
15029
- } else {
15030
- config._isValid = false;
15031
- }
15032
- }
15033
- function extractFromRFC2822Strings2(yearStr, monthStr, dayStr, hourStr, minuteStr, secondStr) {
15034
- var result = [
15035
- untruncateYear2(yearStr),
15036
- defaultLocaleMonthsShort2.indexOf(monthStr),
15037
- parseInt(dayStr, 10),
15038
- parseInt(hourStr, 10),
15039
- parseInt(minuteStr, 10)
15040
- ];
15041
- if (secondStr) {
15042
- result.push(parseInt(secondStr, 10));
15043
- }
15044
- return result;
15045
- }
15046
- function untruncateYear2(yearStr) {
15047
- var year = parseInt(yearStr, 10);
15048
- if (year <= 49) {
15049
- return 2e3 + year;
15050
- } else if (year <= 999) {
15051
- return 1900 + year;
15052
- }
15053
- return year;
15054
- }
15055
- function preprocessRFC28222(s2) {
15056
- return s2.replace(/\([^()]*\)|[\n\t]/g, " ").replace(/(\s\s+)/g, " ").replace(/^\s\s*/, "").replace(/\s\s*$/, "");
15057
- }
15058
- function checkWeekday2(weekdayStr, parsedInput, config) {
15059
- if (weekdayStr) {
15060
- var weekdayProvided = defaultLocaleWeekdaysShort2.indexOf(weekdayStr), weekdayActual = new Date(
15061
- parsedInput[0],
15062
- parsedInput[1],
15063
- parsedInput[2]
15064
- ).getDay();
15065
- if (weekdayProvided !== weekdayActual) {
15066
- getParsingFlags2(config).weekdayMismatch = true;
15067
- config._isValid = false;
15068
- return false;
15069
- }
15070
- }
15071
- return true;
15072
- }
15073
- function calculateOffset2(obsOffset, militaryOffset, numOffset) {
15074
- if (obsOffset) {
15075
- return obsOffsets2[obsOffset];
15076
- } else if (militaryOffset) {
15077
- return 0;
15078
- } else {
15079
- var hm = parseInt(numOffset, 10), m = hm % 100, h = (hm - m) / 100;
15080
- return h * 60 + m;
15081
- }
15082
- }
15083
- function configFromRFC28222(config) {
15084
- var match = rfc28222.exec(preprocessRFC28222(config._i)), parsedArray;
15085
- if (match) {
15086
- parsedArray = extractFromRFC2822Strings2(
15087
- match[4],
15088
- match[3],
15089
- match[2],
15090
- match[5],
15091
- match[6],
15092
- match[7]
15093
- );
15094
- if (!checkWeekday2(match[1], parsedArray, config)) {
15095
- return;
15096
- }
15097
- config._a = parsedArray;
15098
- config._tzm = calculateOffset2(match[8], match[9], match[10]);
15099
- config._d = createUTCDate2.apply(null, config._a);
15100
- config._d.setUTCMinutes(config._d.getUTCMinutes() - config._tzm);
15101
- getParsingFlags2(config).rfc2822 = true;
15102
- } else {
15103
- config._isValid = false;
15104
- }
15105
- }
15106
- function configFromString2(config) {
15107
- var matched = aspNetJsonRegex2.exec(config._i);
15108
- if (matched !== null) {
15109
- config._d = /* @__PURE__ */ new Date(+matched[1]);
15110
- return;
15111
- }
15112
- configFromISO2(config);
15113
- if (config._isValid === false) {
15114
- delete config._isValid;
15115
- } else {
15116
- return;
15117
- }
15118
- configFromRFC28222(config);
15119
- if (config._isValid === false) {
15120
- delete config._isValid;
15121
- } else {
15122
- return;
15123
- }
15124
- if (config._strict) {
15125
- config._isValid = false;
15126
- } else {
15127
- hooks2.createFromInputFallback(config);
15128
- }
15129
- }
15130
- hooks2.createFromInputFallback = deprecate2(
15131
- "value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are discouraged. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.",
15132
- function(config) {
15133
- config._d = /* @__PURE__ */ new Date(config._i + (config._useUTC ? " UTC" : ""));
15134
- }
15135
- );
15136
- function defaults2(a2, b, c) {
15137
- if (a2 != null) {
15138
- return a2;
15139
- }
15140
- if (b != null) {
15141
- return b;
15142
- }
15143
- return c;
15144
- }
15145
- function currentDateArray2(config) {
15146
- var nowValue = new Date(hooks2.now());
15147
- if (config._useUTC) {
15148
- return [
15149
- nowValue.getUTCFullYear(),
15150
- nowValue.getUTCMonth(),
15151
- nowValue.getUTCDate()
15152
- ];
15153
- }
15154
- return [nowValue.getFullYear(), nowValue.getMonth(), nowValue.getDate()];
15155
- }
15156
- function configFromArray2(config) {
15157
- var i, date, input = [], currentDate, expectedWeekday, yearToUse;
15158
- if (config._d) {
15159
- return;
15160
- }
15161
- currentDate = currentDateArray2(config);
15162
- if (config._w && config._a[DATE2] == null && config._a[MONTH2] == null) {
15163
- dayOfYearFromWeekInfo2(config);
15164
- }
15165
- if (config._dayOfYear != null) {
15166
- yearToUse = defaults2(config._a[YEAR2], currentDate[YEAR2]);
15167
- if (config._dayOfYear > daysInYear2(yearToUse) || config._dayOfYear === 0) {
15168
- getParsingFlags2(config)._overflowDayOfYear = true;
15169
- }
15170
- date = createUTCDate2(yearToUse, 0, config._dayOfYear);
15171
- config._a[MONTH2] = date.getUTCMonth();
15172
- config._a[DATE2] = date.getUTCDate();
15173
- }
15174
- for (i = 0; i < 3 && config._a[i] == null; ++i) {
15175
- config._a[i] = input[i] = currentDate[i];
15176
- }
15177
- for (; i < 7; i++) {
15178
- config._a[i] = input[i] = config._a[i] == null ? i === 2 ? 1 : 0 : config._a[i];
15179
- }
15180
- if (config._a[HOUR2] === 24 && config._a[MINUTE2] === 0 && config._a[SECOND2] === 0 && config._a[MILLISECOND2] === 0) {
15181
- config._nextDay = true;
15182
- config._a[HOUR2] = 0;
15183
- }
15184
- config._d = (config._useUTC ? createUTCDate2 : createDate2).apply(
15185
- null,
15186
- input
15187
- );
15188
- expectedWeekday = config._useUTC ? config._d.getUTCDay() : config._d.getDay();
15189
- if (config._tzm != null) {
15190
- config._d.setUTCMinutes(config._d.getUTCMinutes() - config._tzm);
15191
- }
15192
- if (config._nextDay) {
15193
- config._a[HOUR2] = 24;
15194
- }
15195
- if (config._w && typeof config._w.d !== "undefined" && config._w.d !== expectedWeekday) {
15196
- getParsingFlags2(config).weekdayMismatch = true;
15197
- }
15198
- }
15199
- function dayOfYearFromWeekInfo2(config) {
15200
- var w, weekYear, week, weekday, dow, doy, temp, weekdayOverflow, curWeek;
15201
- w = config._w;
15202
- if (w.GG != null || w.W != null || w.E != null) {
15203
- dow = 1;
15204
- doy = 4;
15205
- weekYear = defaults2(
15206
- w.GG,
15207
- config._a[YEAR2],
15208
- weekOfYear2(createLocal2(), 1, 4).year
15209
- );
15210
- week = defaults2(w.W, 1);
15211
- weekday = defaults2(w.E, 1);
15212
- if (weekday < 1 || weekday > 7) {
15213
- weekdayOverflow = true;
15214
- }
15215
- } else {
15216
- dow = config._locale._week.dow;
15217
- doy = config._locale._week.doy;
15218
- curWeek = weekOfYear2(createLocal2(), dow, doy);
15219
- weekYear = defaults2(w.gg, config._a[YEAR2], curWeek.year);
15220
- week = defaults2(w.w, curWeek.week);
15221
- if (w.d != null) {
15222
- weekday = w.d;
15223
- if (weekday < 0 || weekday > 6) {
15224
- weekdayOverflow = true;
15225
- }
15226
- } else if (w.e != null) {
15227
- weekday = w.e + dow;
15228
- if (w.e < 0 || w.e > 6) {
15229
- weekdayOverflow = true;
15230
- }
15231
- } else {
15232
- weekday = dow;
15233
- }
15234
- }
15235
- if (week < 1 || week > weeksInYear2(weekYear, dow, doy)) {
15236
- getParsingFlags2(config)._overflowWeeks = true;
15237
- } else if (weekdayOverflow != null) {
15238
- getParsingFlags2(config)._overflowWeekday = true;
15239
- } else {
15240
- temp = dayOfYearFromWeeks2(weekYear, week, weekday, dow, doy);
15241
- config._a[YEAR2] = temp.year;
15242
- config._dayOfYear = temp.dayOfYear;
15243
- }
15244
- }
15245
- hooks2.ISO_8601 = function() {
15246
- };
15247
- hooks2.RFC_2822 = function() {
15248
- };
15249
- function configFromStringAndFormat2(config) {
15250
- if (config._f === hooks2.ISO_8601) {
15251
- configFromISO2(config);
15252
- return;
15253
- }
15254
- if (config._f === hooks2.RFC_2822) {
15255
- configFromRFC28222(config);
15256
- return;
15257
- }
15258
- config._a = [];
15259
- getParsingFlags2(config).empty = true;
15260
- var string = "" + config._i, i, parsedInput, tokens3, token3, skipped, stringLength = string.length, totalParsedInputLength = 0, era, tokenLen;
15261
- tokens3 = expandFormat2(config._f, config._locale).match(formattingTokens2) || [];
15262
- tokenLen = tokens3.length;
15263
- for (i = 0; i < tokenLen; i++) {
15264
- token3 = tokens3[i];
15265
- parsedInput = (string.match(getParseRegexForToken2(token3, config)) || [])[0];
15266
- if (parsedInput) {
15267
- skipped = string.substr(0, string.indexOf(parsedInput));
15268
- if (skipped.length > 0) {
15269
- getParsingFlags2(config).unusedInput.push(skipped);
15270
- }
15271
- string = string.slice(
15272
- string.indexOf(parsedInput) + parsedInput.length
15273
- );
15274
- totalParsedInputLength += parsedInput.length;
15275
- }
15276
- if (formatTokenFunctions2[token3]) {
15277
- if (parsedInput) {
15278
- getParsingFlags2(config).empty = false;
15279
- } else {
15280
- getParsingFlags2(config).unusedTokens.push(token3);
15281
- }
15282
- addTimeToArrayFromToken2(token3, parsedInput, config);
15283
- } else if (config._strict && !parsedInput) {
15284
- getParsingFlags2(config).unusedTokens.push(token3);
15285
- }
15286
- }
15287
- getParsingFlags2(config).charsLeftOver = stringLength - totalParsedInputLength;
15288
- if (string.length > 0) {
15289
- getParsingFlags2(config).unusedInput.push(string);
15290
- }
15291
- if (config._a[HOUR2] <= 12 && getParsingFlags2(config).bigHour === true && config._a[HOUR2] > 0) {
15292
- getParsingFlags2(config).bigHour = void 0;
15293
- }
15294
- getParsingFlags2(config).parsedDateParts = config._a.slice(0);
15295
- getParsingFlags2(config).meridiem = config._meridiem;
15296
- config._a[HOUR2] = meridiemFixWrap2(
15297
- config._locale,
15298
- config._a[HOUR2],
15299
- config._meridiem
15300
- );
15301
- era = getParsingFlags2(config).era;
15302
- if (era !== null) {
15303
- config._a[YEAR2] = config._locale.erasConvertYear(era, config._a[YEAR2]);
15304
- }
15305
- configFromArray2(config);
15306
- checkOverflow2(config);
15307
- }
15308
- function meridiemFixWrap2(locale3, hour, meridiem3) {
15309
- var isPm;
15310
- if (meridiem3 == null) {
15311
- return hour;
15312
- }
15313
- if (locale3.meridiemHour != null) {
15314
- return locale3.meridiemHour(hour, meridiem3);
15315
- } else if (locale3.isPM != null) {
15316
- isPm = locale3.isPM(meridiem3);
15317
- if (isPm && hour < 12) {
15318
- hour += 12;
15319
- }
15320
- if (!isPm && hour === 12) {
15321
- hour = 0;
15322
- }
15323
- return hour;
15324
- } else {
15325
- return hour;
15326
- }
15327
- }
15328
- function configFromStringAndArray2(config) {
15329
- var tempConfig, bestMoment, scoreToBeat, i, currentScore, validFormatFound, bestFormatIsValid = false, configfLen = config._f.length;
15330
- if (configfLen === 0) {
15331
- getParsingFlags2(config).invalidFormat = true;
15332
- config._d = /* @__PURE__ */ new Date(NaN);
15333
- return;
15334
- }
15335
- for (i = 0; i < configfLen; i++) {
15336
- currentScore = 0;
15337
- validFormatFound = false;
15338
- tempConfig = copyConfig2({}, config);
15339
- if (config._useUTC != null) {
15340
- tempConfig._useUTC = config._useUTC;
15341
- }
15342
- tempConfig._f = config._f[i];
15343
- configFromStringAndFormat2(tempConfig);
15344
- if (isValid2(tempConfig)) {
15345
- validFormatFound = true;
15346
- }
15347
- currentScore += getParsingFlags2(tempConfig).charsLeftOver;
15348
- currentScore += getParsingFlags2(tempConfig).unusedTokens.length * 10;
15349
- getParsingFlags2(tempConfig).score = currentScore;
15350
- if (!bestFormatIsValid) {
15351
- if (scoreToBeat == null || currentScore < scoreToBeat || validFormatFound) {
15352
- scoreToBeat = currentScore;
15353
- bestMoment = tempConfig;
15354
- if (validFormatFound) {
15355
- bestFormatIsValid = true;
15356
- }
15357
- }
15358
- } else {
15359
- if (currentScore < scoreToBeat) {
15360
- scoreToBeat = currentScore;
15361
- bestMoment = tempConfig;
15362
- }
15363
- }
15364
- }
15365
- extend2(config, bestMoment || tempConfig);
15366
- }
15367
- function configFromObject2(config) {
15368
- if (config._d) {
15369
- return;
15370
- }
15371
- var i = normalizeObjectUnits2(config._i), dayOrDate = i.day === void 0 ? i.date : i.day;
15372
- config._a = map2(
15373
- [i.year, i.month, dayOrDate, i.hour, i.minute, i.second, i.millisecond],
15374
- function(obj) {
15375
- return obj && parseInt(obj, 10);
15376
- }
15377
- );
15378
- configFromArray2(config);
15379
- }
15380
- function createFromConfig2(config) {
15381
- var res = new Moment2(checkOverflow2(prepareConfig2(config)));
15382
- if (res._nextDay) {
15383
- res.add(1, "d");
15384
- res._nextDay = void 0;
15385
- }
15386
- return res;
15387
- }
15388
- function prepareConfig2(config) {
15389
- var input = config._i, format3 = config._f;
15390
- config._locale = config._locale || getLocale2(config._l);
15391
- if (input === null || format3 === void 0 && input === "") {
15392
- return createInvalid2({ nullInput: true });
15393
- }
15394
- if (typeof input === "string") {
15395
- config._i = input = config._locale.preparse(input);
15396
- }
15397
- if (isMoment2(input)) {
15398
- return new Moment2(checkOverflow2(input));
15399
- } else if (isDate2(input)) {
15400
- config._d = input;
15401
- } else if (isArray2(format3)) {
15402
- configFromStringAndArray2(config);
15403
- } else if (format3) {
15404
- configFromStringAndFormat2(config);
15405
- } else {
15406
- configFromInput2(config);
15407
- }
15408
- if (!isValid2(config)) {
15409
- config._d = null;
15410
- }
15411
- return config;
15412
- }
15413
- function configFromInput2(config) {
15414
- var input = config._i;
15415
- if (isUndefined2(input)) {
15416
- config._d = new Date(hooks2.now());
15417
- } else if (isDate2(input)) {
15418
- config._d = new Date(input.valueOf());
15419
- } else if (typeof input === "string") {
15420
- configFromString2(config);
15421
- } else if (isArray2(input)) {
15422
- config._a = map2(input.slice(0), function(obj) {
15423
- return parseInt(obj, 10);
15424
- });
15425
- configFromArray2(config);
15426
- } else if (isObject2(input)) {
15427
- configFromObject2(config);
15428
- } else if (isNumber2(input)) {
15429
- config._d = new Date(input);
15430
- } else {
15431
- hooks2.createFromInputFallback(config);
15432
- }
15433
- }
15434
- function createLocalOrUTC2(input, format3, locale3, strict, isUTC) {
15435
- var c = {};
15436
- if (format3 === true || format3 === false) {
15437
- strict = format3;
15438
- format3 = void 0;
15439
- }
15440
- if (locale3 === true || locale3 === false) {
15441
- strict = locale3;
15442
- locale3 = void 0;
15443
- }
15444
- if (isObject2(input) && isObjectEmpty2(input) || isArray2(input) && input.length === 0) {
15445
- input = void 0;
15446
- }
15447
- c._isAMomentObject = true;
15448
- c._useUTC = c._isUTC = isUTC;
15449
- c._l = locale3;
15450
- c._i = input;
15451
- c._f = format3;
15452
- c._strict = strict;
15453
- return createFromConfig2(c);
15454
- }
15455
- function createLocal2(input, format3, locale3, strict) {
15456
- return createLocalOrUTC2(input, format3, locale3, strict, false);
15457
- }
15458
- var prototypeMin2 = deprecate2(
15459
- "moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",
15460
- function() {
15461
- var other = createLocal2.apply(null, arguments);
15462
- if (this.isValid() && other.isValid()) {
15463
- return other < this ? this : other;
15464
- } else {
15465
- return createInvalid2();
15466
- }
15467
- }
15468
- ), prototypeMax2 = deprecate2(
15469
- "moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",
15470
- function() {
15471
- var other = createLocal2.apply(null, arguments);
15472
- if (this.isValid() && other.isValid()) {
15473
- return other > this ? this : other;
15474
- } else {
15475
- return createInvalid2();
15476
- }
15477
- }
15478
- );
15479
- function pickBy2(fn, moments) {
15480
- var res, i;
15481
- if (moments.length === 1 && isArray2(moments[0])) {
15482
- moments = moments[0];
15483
- }
15484
- if (!moments.length) {
15485
- return createLocal2();
15486
- }
15487
- res = moments[0];
15488
- for (i = 1; i < moments.length; ++i) {
15489
- if (!moments[i].isValid() || moments[i][fn](res)) {
15490
- res = moments[i];
15491
- }
15492
- }
15493
- return res;
15494
- }
15495
- function min2() {
15496
- var args = [].slice.call(arguments, 0);
15497
- return pickBy2("isBefore", args);
15498
- }
15499
- function max2() {
15500
- var args = [].slice.call(arguments, 0);
15501
- return pickBy2("isAfter", args);
15502
- }
15503
- var now2 = function() {
15504
- return Date.now ? Date.now() : +/* @__PURE__ */ new Date();
15505
- };
15506
- var ordering2 = [
15507
- "year",
15508
- "quarter",
15509
- "month",
15510
- "week",
15511
- "day",
15512
- "hour",
15513
- "minute",
15514
- "second",
15515
- "millisecond"
15516
- ];
15517
- function isDurationValid2(m) {
15518
- var key, unitHasDecimal = false, i, orderLen = ordering2.length;
15519
- for (key in m) {
15520
- if (hasOwnProp2(m, key) && !(indexOf2.call(ordering2, key) !== -1 && (m[key] == null || !isNaN(m[key])))) {
15521
- return false;
15522
- }
15523
- }
15524
- for (i = 0; i < orderLen; ++i) {
15525
- if (m[ordering2[i]]) {
15526
- if (unitHasDecimal) {
15527
- return false;
15528
- }
15529
- if (parseFloat(m[ordering2[i]]) !== toInt2(m[ordering2[i]])) {
15530
- unitHasDecimal = true;
15531
- }
15532
- }
15533
- }
15534
- return true;
15535
- }
15536
- function isValid$12() {
15537
- return this._isValid;
15538
- }
15539
- function createInvalid$12() {
15540
- return createDuration2(NaN);
15541
- }
15542
- function Duration2(duration) {
15543
- var normalizedInput = normalizeObjectUnits2(duration), years3 = normalizedInput.year || 0, quarters = normalizedInput.quarter || 0, months3 = normalizedInput.month || 0, weeks3 = normalizedInput.week || normalizedInput.isoWeek || 0, days3 = normalizedInput.day || 0, hours3 = normalizedInput.hour || 0, minutes3 = normalizedInput.minute || 0, seconds3 = normalizedInput.second || 0, milliseconds3 = normalizedInput.millisecond || 0;
15544
- this._isValid = isDurationValid2(normalizedInput);
15545
- this._milliseconds = +milliseconds3 + seconds3 * 1e3 + // 1000
15546
- minutes3 * 6e4 + // 1000 * 60
15547
- hours3 * 1e3 * 60 * 60;
15548
- this._days = +days3 + weeks3 * 7;
15549
- this._months = +months3 + quarters * 3 + years3 * 12;
15550
- this._data = {};
15551
- this._locale = getLocale2();
15552
- this._bubble();
15553
- }
15554
- function isDuration2(obj) {
15555
- return obj instanceof Duration2;
15556
- }
15557
- function absRound2(number) {
15558
- if (number < 0) {
15559
- return Math.round(-1 * number) * -1;
15560
- } else {
15561
- return Math.round(number);
15562
- }
15563
- }
15564
- function compareArrays2(array1, array2, dontConvert) {
15565
- var len = Math.min(array1.length, array2.length), lengthDiff = Math.abs(array1.length - array2.length), diffs = 0, i;
15566
- for (i = 0; i < len; i++) {
15567
- if (toInt2(array1[i]) !== toInt2(array2[i])) {
15568
- diffs++;
15569
- }
15570
- }
15571
- return diffs + lengthDiff;
15572
- }
15573
- function offset2(token3, separator) {
15574
- addFormatToken2(token3, 0, 0, function() {
15575
- var offset3 = this.utcOffset(), sign3 = "+";
15576
- if (offset3 < 0) {
15577
- offset3 = -offset3;
15578
- sign3 = "-";
15579
- }
15580
- return sign3 + zeroFill2(~~(offset3 / 60), 2) + separator + zeroFill2(~~offset3 % 60, 2);
15581
- });
15582
- }
15583
- offset2("Z", ":");
15584
- offset2("ZZ", "");
15585
- addRegexToken2("Z", matchShortOffset2);
15586
- addRegexToken2("ZZ", matchShortOffset2);
15587
- addParseToken2(["Z", "ZZ"], function(input, array, config) {
15588
- config._useUTC = true;
15589
- config._tzm = offsetFromString2(matchShortOffset2, input);
15590
- });
15591
- var chunkOffset2 = /([\+\-]|\d\d)/gi;
15592
- function offsetFromString2(matcher, string) {
15593
- var matches = (string || "").match(matcher), chunk, parts, minutes3;
15594
- if (matches === null) {
15595
- return null;
15596
- }
15597
- chunk = matches[matches.length - 1] || [];
15598
- parts = (chunk + "").match(chunkOffset2) || ["-", 0, 0];
15599
- minutes3 = +(parts[1] * 60) + toInt2(parts[2]);
15600
- return minutes3 === 0 ? 0 : parts[0] === "+" ? minutes3 : -minutes3;
15601
- }
15602
- function cloneWithOffset2(input, model) {
15603
- var res, diff3;
15604
- if (model._isUTC) {
15605
- res = model.clone();
15606
- diff3 = (isMoment2(input) || isDate2(input) ? input.valueOf() : createLocal2(input).valueOf()) - res.valueOf();
15607
- res._d.setTime(res._d.valueOf() + diff3);
15608
- hooks2.updateOffset(res, false);
15609
- return res;
15610
- } else {
15611
- return createLocal2(input).local();
15612
- }
15613
- }
15614
- function getDateOffset2(m) {
15615
- return -Math.round(m._d.getTimezoneOffset());
15616
- }
15617
- hooks2.updateOffset = function() {
15618
- };
15619
- function getSetOffset2(input, keepLocalTime, keepMinutes) {
15620
- var offset3 = this._offset || 0, localAdjust;
15621
- if (!this.isValid()) {
15622
- return input != null ? this : NaN;
15623
- }
15624
- if (input != null) {
15625
- if (typeof input === "string") {
15626
- input = offsetFromString2(matchShortOffset2, input);
15627
- if (input === null) {
15628
- return this;
15629
- }
15630
- } else if (Math.abs(input) < 16 && !keepMinutes) {
15631
- input = input * 60;
15632
- }
15633
- if (!this._isUTC && keepLocalTime) {
15634
- localAdjust = getDateOffset2(this);
15635
- }
15636
- this._offset = input;
15637
- this._isUTC = true;
15638
- if (localAdjust != null) {
15639
- this.add(localAdjust, "m");
15640
- }
15641
- if (offset3 !== input) {
15642
- if (!keepLocalTime || this._changeInProgress) {
15643
- addSubtract2(
15644
- this,
15645
- createDuration2(input - offset3, "m"),
15646
- 1,
15647
- false
15648
- );
15649
- } else if (!this._changeInProgress) {
15650
- this._changeInProgress = true;
15651
- hooks2.updateOffset(this, true);
15652
- this._changeInProgress = null;
15653
- }
15654
- }
15655
- return this;
15656
- } else {
15657
- return this._isUTC ? offset3 : getDateOffset2(this);
15658
- }
15659
- }
15660
- function getSetZone2(input, keepLocalTime) {
15661
- if (input != null) {
15662
- if (typeof input !== "string") {
15663
- input = -input;
15664
- }
15665
- this.utcOffset(input, keepLocalTime);
15666
- return this;
15667
- } else {
15668
- return -this.utcOffset();
15669
- }
15670
- }
15671
- function setOffsetToUTC2(keepLocalTime) {
15672
- return this.utcOffset(0, keepLocalTime);
15673
- }
15674
- function setOffsetToLocal2(keepLocalTime) {
15675
- if (this._isUTC) {
15676
- this.utcOffset(0, keepLocalTime);
15677
- this._isUTC = false;
15678
- if (keepLocalTime) {
15679
- this.subtract(getDateOffset2(this), "m");
15680
- }
15681
- }
15682
- return this;
15683
- }
15684
- function setOffsetToParsedOffset2() {
15685
- if (this._tzm != null) {
15686
- this.utcOffset(this._tzm, false, true);
15687
- } else if (typeof this._i === "string") {
15688
- var tZone = offsetFromString2(matchOffset2, this._i);
15689
- if (tZone != null) {
15690
- this.utcOffset(tZone);
15691
- } else {
15692
- this.utcOffset(0, true);
15693
- }
15694
- }
15695
- return this;
15696
- }
15697
- function hasAlignedHourOffset2(input) {
15698
- if (!this.isValid()) {
15699
- return false;
15700
- }
15701
- input = input ? createLocal2(input).utcOffset() : 0;
15702
- return (this.utcOffset() - input) % 60 === 0;
15703
- }
15704
- function isDaylightSavingTime2() {
15705
- return this.utcOffset() > this.clone().month(0).utcOffset() || this.utcOffset() > this.clone().month(5).utcOffset();
15706
- }
15707
- function isDaylightSavingTimeShifted2() {
15708
- if (!isUndefined2(this._isDSTShifted)) {
15709
- return this._isDSTShifted;
15710
- }
15711
- var c = {}, other;
15712
- copyConfig2(c, this);
15713
- c = prepareConfig2(c);
15714
- if (c._a) {
15715
- other = c._isUTC ? createUTC2(c._a) : createLocal2(c._a);
15716
- this._isDSTShifted = this.isValid() && compareArrays2(c._a, other.toArray()) > 0;
15717
- } else {
15718
- this._isDSTShifted = false;
15719
- }
15720
- return this._isDSTShifted;
15721
- }
15722
- function isLocal2() {
15723
- return this.isValid() ? !this._isUTC : false;
15724
- }
15725
- function isUtcOffset2() {
15726
- return this.isValid() ? this._isUTC : false;
15727
- }
15728
- function isUtc2() {
15729
- return this.isValid() ? this._isUTC && this._offset === 0 : false;
15730
- }
15731
- var aspNetRegex2 = /^(-|\+)?(?:(\d*)[. ])?(\d+):(\d+)(?::(\d+)(\.\d*)?)?$/, isoRegex2 = /^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;
15732
- function createDuration2(input, key) {
15733
- var duration = input, match = null, sign3, ret, diffRes;
15734
- if (isDuration2(input)) {
15735
- duration = {
15736
- ms: input._milliseconds,
15737
- d: input._days,
15738
- M: input._months
15739
- };
15740
- } else if (isNumber2(input) || !isNaN(+input)) {
15741
- duration = {};
15742
- if (key) {
15743
- duration[key] = +input;
15744
- } else {
15745
- duration.milliseconds = +input;
15746
- }
15747
- } else if (match = aspNetRegex2.exec(input)) {
15748
- sign3 = match[1] === "-" ? -1 : 1;
15749
- duration = {
15750
- y: 0,
15751
- d: toInt2(match[DATE2]) * sign3,
15752
- h: toInt2(match[HOUR2]) * sign3,
15753
- m: toInt2(match[MINUTE2]) * sign3,
15754
- s: toInt2(match[SECOND2]) * sign3,
15755
- ms: toInt2(absRound2(match[MILLISECOND2] * 1e3)) * sign3
15756
- // the millisecond decimal point is included in the match
15757
- };
15758
- } else if (match = isoRegex2.exec(input)) {
15759
- sign3 = match[1] === "-" ? -1 : 1;
15760
- duration = {
15761
- y: parseIso2(match[2], sign3),
15762
- M: parseIso2(match[3], sign3),
15763
- w: parseIso2(match[4], sign3),
15764
- d: parseIso2(match[5], sign3),
15765
- h: parseIso2(match[6], sign3),
15766
- m: parseIso2(match[7], sign3),
15767
- s: parseIso2(match[8], sign3)
15768
- };
15769
- } else if (duration == null) {
15770
- duration = {};
15771
- } else if (typeof duration === "object" && ("from" in duration || "to" in duration)) {
15772
- diffRes = momentsDifference2(
15773
- createLocal2(duration.from),
15774
- createLocal2(duration.to)
15775
- );
15776
- duration = {};
15777
- duration.ms = diffRes.milliseconds;
15778
- duration.M = diffRes.months;
15779
- }
15780
- ret = new Duration2(duration);
15781
- if (isDuration2(input) && hasOwnProp2(input, "_locale")) {
15782
- ret._locale = input._locale;
15783
- }
15784
- if (isDuration2(input) && hasOwnProp2(input, "_isValid")) {
15785
- ret._isValid = input._isValid;
15786
- }
15787
- return ret;
15788
- }
15789
- createDuration2.fn = Duration2.prototype;
15790
- createDuration2.invalid = createInvalid$12;
15791
- function parseIso2(inp, sign3) {
15792
- var res = inp && parseFloat(inp.replace(",", "."));
15793
- return (isNaN(res) ? 0 : res) * sign3;
15794
- }
15795
- function positiveMomentsDifference2(base, other) {
15796
- var res = {};
15797
- res.months = other.month() - base.month() + (other.year() - base.year()) * 12;
15798
- if (base.clone().add(res.months, "M").isAfter(other)) {
15799
- --res.months;
15800
- }
15801
- res.milliseconds = +other - +base.clone().add(res.months, "M");
15802
- return res;
15803
- }
15804
- function momentsDifference2(base, other) {
15805
- var res;
15806
- if (!(base.isValid() && other.isValid())) {
15807
- return { milliseconds: 0, months: 0 };
15808
- }
15809
- other = cloneWithOffset2(other, base);
15810
- if (base.isBefore(other)) {
15811
- res = positiveMomentsDifference2(base, other);
15812
- } else {
15813
- res = positiveMomentsDifference2(other, base);
15814
- res.milliseconds = -res.milliseconds;
15815
- res.months = -res.months;
15816
- }
15817
- return res;
15818
- }
15819
- function createAdder2(direction, name) {
15820
- return function(val, period) {
15821
- var dur, tmp;
15822
- if (period !== null && !isNaN(+period)) {
15823
- deprecateSimple2(
15824
- name,
15825
- "moment()." + name + "(period, number) is deprecated. Please use moment()." + name + "(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."
15826
- );
15827
- tmp = val;
15828
- val = period;
15829
- period = tmp;
15830
- }
15831
- dur = createDuration2(val, period);
15832
- addSubtract2(this, dur, direction);
15833
- return this;
15834
- };
15835
- }
15836
- function addSubtract2(mom, duration, isAdding, updateOffset) {
15837
- var milliseconds3 = duration._milliseconds, days3 = absRound2(duration._days), months3 = absRound2(duration._months);
15838
- if (!mom.isValid()) {
15839
- return;
15840
- }
15841
- updateOffset = updateOffset == null ? true : updateOffset;
15842
- if (months3) {
15843
- setMonth2(mom, get2(mom, "Month") + months3 * isAdding);
15844
- }
15845
- if (days3) {
15846
- set$12(mom, "Date", get2(mom, "Date") + days3 * isAdding);
15847
- }
15848
- if (milliseconds3) {
15849
- mom._d.setTime(mom._d.valueOf() + milliseconds3 * isAdding);
15850
- }
15851
- if (updateOffset) {
15852
- hooks2.updateOffset(mom, days3 || months3);
15853
- }
15854
- }
15855
- var add2 = createAdder2(1, "add"), subtract2 = createAdder2(-1, "subtract");
15856
- function isString2(input) {
15857
- return typeof input === "string" || input instanceof String;
15858
- }
15859
- function isMomentInput2(input) {
15860
- return isMoment2(input) || isDate2(input) || isString2(input) || isNumber2(input) || isNumberOrStringArray2(input) || isMomentInputObject2(input) || input === null || input === void 0;
15861
- }
15862
- function isMomentInputObject2(input) {
15863
- var objectTest = isObject2(input) && !isObjectEmpty2(input), propertyTest = false, properties = [
15864
- "years",
15865
- "year",
15866
- "y",
15867
- "months",
15868
- "month",
15869
- "M",
15870
- "days",
15871
- "day",
15872
- "d",
15873
- "dates",
15874
- "date",
15875
- "D",
15876
- "hours",
15877
- "hour",
15878
- "h",
15879
- "minutes",
15880
- "minute",
15881
- "m",
15882
- "seconds",
15883
- "second",
15884
- "s",
15885
- "milliseconds",
15886
- "millisecond",
15887
- "ms"
15888
- ], i, property, propertyLen = properties.length;
15889
- for (i = 0; i < propertyLen; i += 1) {
15890
- property = properties[i];
15891
- propertyTest = propertyTest || hasOwnProp2(input, property);
15892
- }
15893
- return objectTest && propertyTest;
15894
- }
15895
- function isNumberOrStringArray2(input) {
15896
- var arrayTest = isArray2(input), dataTypeTest = false;
15897
- if (arrayTest) {
15898
- dataTypeTest = input.filter(function(item) {
15899
- return !isNumber2(item) && isString2(input);
15900
- }).length === 0;
15901
- }
15902
- return arrayTest && dataTypeTest;
15903
- }
15904
- function isCalendarSpec2(input) {
15905
- var objectTest = isObject2(input) && !isObjectEmpty2(input), propertyTest = false, properties = [
15906
- "sameDay",
15907
- "nextDay",
15908
- "lastDay",
15909
- "nextWeek",
15910
- "lastWeek",
15911
- "sameElse"
15912
- ], i, property;
15913
- for (i = 0; i < properties.length; i += 1) {
15914
- property = properties[i];
15915
- propertyTest = propertyTest || hasOwnProp2(input, property);
15916
- }
15917
- return objectTest && propertyTest;
15918
- }
15919
- function getCalendarFormat2(myMoment, now3) {
15920
- var diff3 = myMoment.diff(now3, "days", true);
15921
- return diff3 < -6 ? "sameElse" : diff3 < -1 ? "lastWeek" : diff3 < 0 ? "lastDay" : diff3 < 1 ? "sameDay" : diff3 < 2 ? "nextDay" : diff3 < 7 ? "nextWeek" : "sameElse";
15922
- }
15923
- function calendar$12(time, formats) {
15924
- if (arguments.length === 1) {
15925
- if (!arguments[0]) {
15926
- time = void 0;
15927
- formats = void 0;
15928
- } else if (isMomentInput2(arguments[0])) {
15929
- time = arguments[0];
15930
- formats = void 0;
15931
- } else if (isCalendarSpec2(arguments[0])) {
15932
- formats = arguments[0];
15933
- time = void 0;
15934
- }
15935
- }
15936
- var now3 = time || createLocal2(), sod = cloneWithOffset2(now3, this).startOf("day"), format3 = hooks2.calendarFormat(this, sod) || "sameElse", output = formats && (isFunction2(formats[format3]) ? formats[format3].call(this, now3) : formats[format3]);
15937
- return this.format(
15938
- output || this.localeData().calendar(format3, this, createLocal2(now3))
15939
- );
15940
- }
15941
- function clone2() {
15942
- return new Moment2(this);
15943
- }
15944
- function isAfter2(input, units) {
15945
- var localInput = isMoment2(input) ? input : createLocal2(input);
15946
- if (!(this.isValid() && localInput.isValid())) {
15947
- return false;
15948
- }
15949
- units = normalizeUnits2(units) || "millisecond";
15950
- if (units === "millisecond") {
15951
- return this.valueOf() > localInput.valueOf();
15952
- } else {
15953
- return localInput.valueOf() < this.clone().startOf(units).valueOf();
15954
- }
15955
- }
15956
- function isBefore2(input, units) {
15957
- var localInput = isMoment2(input) ? input : createLocal2(input);
15958
- if (!(this.isValid() && localInput.isValid())) {
15959
- return false;
15960
- }
15961
- units = normalizeUnits2(units) || "millisecond";
15962
- if (units === "millisecond") {
15963
- return this.valueOf() < localInput.valueOf();
15964
- } else {
15965
- return this.clone().endOf(units).valueOf() < localInput.valueOf();
15966
- }
15967
- }
15968
- function isBetween2(from3, to3, units, inclusivity) {
15969
- var localFrom = isMoment2(from3) ? from3 : createLocal2(from3), localTo = isMoment2(to3) ? to3 : createLocal2(to3);
15970
- if (!(this.isValid() && localFrom.isValid() && localTo.isValid())) {
15971
- return false;
15972
- }
15973
- inclusivity = inclusivity || "()";
15974
- return (inclusivity[0] === "(" ? this.isAfter(localFrom, units) : !this.isBefore(localFrom, units)) && (inclusivity[1] === ")" ? this.isBefore(localTo, units) : !this.isAfter(localTo, units));
15975
- }
15976
- function isSame2(input, units) {
15977
- var localInput = isMoment2(input) ? input : createLocal2(input), inputMs;
15978
- if (!(this.isValid() && localInput.isValid())) {
15979
- return false;
15980
- }
15981
- units = normalizeUnits2(units) || "millisecond";
15982
- if (units === "millisecond") {
15983
- return this.valueOf() === localInput.valueOf();
15984
- } else {
15985
- inputMs = localInput.valueOf();
15986
- return this.clone().startOf(units).valueOf() <= inputMs && inputMs <= this.clone().endOf(units).valueOf();
15987
- }
15988
- }
15989
- function isSameOrAfter2(input, units) {
15990
- return this.isSame(input, units) || this.isAfter(input, units);
15991
- }
15992
- function isSameOrBefore2(input, units) {
15993
- return this.isSame(input, units) || this.isBefore(input, units);
15994
- }
15995
- function diff2(input, units, asFloat) {
15996
- var that, zoneDelta, output;
15997
- if (!this.isValid()) {
15998
- return NaN;
15999
- }
16000
- that = cloneWithOffset2(input, this);
16001
- if (!that.isValid()) {
16002
- return NaN;
16003
- }
16004
- zoneDelta = (that.utcOffset() - this.utcOffset()) * 6e4;
16005
- units = normalizeUnits2(units);
16006
- switch (units) {
16007
- case "year":
16008
- output = monthDiff2(this, that) / 12;
16009
- break;
16010
- case "month":
16011
- output = monthDiff2(this, that);
16012
- break;
16013
- case "quarter":
16014
- output = monthDiff2(this, that) / 3;
16015
- break;
16016
- case "second":
16017
- output = (this - that) / 1e3;
16018
- break;
16019
- // 1000
16020
- case "minute":
16021
- output = (this - that) / 6e4;
16022
- break;
16023
- // 1000 * 60
16024
- case "hour":
16025
- output = (this - that) / 36e5;
16026
- break;
16027
- // 1000 * 60 * 60
16028
- case "day":
16029
- output = (this - that - zoneDelta) / 864e5;
16030
- break;
16031
- // 1000 * 60 * 60 * 24, negate dst
16032
- case "week":
16033
- output = (this - that - zoneDelta) / 6048e5;
16034
- break;
16035
- // 1000 * 60 * 60 * 24 * 7, negate dst
16036
- default:
16037
- output = this - that;
16038
- }
16039
- return asFloat ? output : absFloor2(output);
16040
- }
16041
- function monthDiff2(a2, b) {
16042
- if (a2.date() < b.date()) {
16043
- return -monthDiff2(b, a2);
16044
- }
16045
- var wholeMonthDiff = (b.year() - a2.year()) * 12 + (b.month() - a2.month()), anchor = a2.clone().add(wholeMonthDiff, "months"), anchor2, adjust;
16046
- if (b - anchor < 0) {
16047
- anchor2 = a2.clone().add(wholeMonthDiff - 1, "months");
16048
- adjust = (b - anchor) / (anchor - anchor2);
16049
- } else {
16050
- anchor2 = a2.clone().add(wholeMonthDiff + 1, "months");
16051
- adjust = (b - anchor) / (anchor2 - anchor);
16052
- }
16053
- return -(wholeMonthDiff + adjust) || 0;
16054
- }
16055
- hooks2.defaultFormat = "YYYY-MM-DDTHH:mm:ssZ";
16056
- hooks2.defaultFormatUtc = "YYYY-MM-DDTHH:mm:ss[Z]";
16057
- function toString3() {
16058
- return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ");
16059
- }
16060
- function toISOString2(keepOffset) {
16061
- if (!this.isValid()) {
16062
- return null;
16063
- }
16064
- var utc = keepOffset !== true, m = utc ? this.clone().utc() : this;
16065
- if (m.year() < 0 || m.year() > 9999) {
16066
- return formatMoment2(
16067
- m,
16068
- utc ? "YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]" : "YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"
16069
- );
16070
- }
16071
- if (isFunction2(Date.prototype.toISOString)) {
16072
- if (utc) {
16073
- return this.toDate().toISOString();
16074
- } else {
16075
- return new Date(this.valueOf() + this.utcOffset() * 60 * 1e3).toISOString().replace("Z", formatMoment2(m, "Z"));
16076
- }
16077
- }
16078
- return formatMoment2(
16079
- m,
16080
- utc ? "YYYY-MM-DD[T]HH:mm:ss.SSS[Z]" : "YYYY-MM-DD[T]HH:mm:ss.SSSZ"
16081
- );
16082
- }
16083
- function inspect2() {
16084
- if (!this.isValid()) {
16085
- return "moment.invalid(/* " + this._i + " */)";
16086
- }
16087
- var func = "moment", zone = "", prefix, year, datetime, suffix;
16088
- if (!this.isLocal()) {
16089
- func = this.utcOffset() === 0 ? "moment.utc" : "moment.parseZone";
16090
- zone = "Z";
16091
- }
16092
- prefix = "[" + func + '("]';
16093
- year = 0 <= this.year() && this.year() <= 9999 ? "YYYY" : "YYYYYY";
16094
- datetime = "-MM-DD[T]HH:mm:ss.SSS";
16095
- suffix = zone + '[")]';
16096
- return this.format(prefix + year + datetime + suffix);
16097
- }
16098
- function format2(inputString) {
16099
- if (!inputString) {
16100
- inputString = this.isUtc() ? hooks2.defaultFormatUtc : hooks2.defaultFormat;
16101
- }
16102
- var output = formatMoment2(this, inputString);
16103
- return this.localeData().postformat(output);
16104
- }
16105
- function from2(time, withoutSuffix) {
16106
- if (this.isValid() && (isMoment2(time) && time.isValid() || createLocal2(time).isValid())) {
16107
- return createDuration2({ to: this, from: time }).locale(this.locale()).humanize(!withoutSuffix);
16108
- } else {
16109
- return this.localeData().invalidDate();
16110
- }
16111
- }
16112
- function fromNow2(withoutSuffix) {
16113
- return this.from(createLocal2(), withoutSuffix);
16114
- }
16115
- function to2(time, withoutSuffix) {
16116
- if (this.isValid() && (isMoment2(time) && time.isValid() || createLocal2(time).isValid())) {
16117
- return createDuration2({ from: this, to: time }).locale(this.locale()).humanize(!withoutSuffix);
16118
- } else {
16119
- return this.localeData().invalidDate();
16120
- }
16121
- }
16122
- function toNow2(withoutSuffix) {
16123
- return this.to(createLocal2(), withoutSuffix);
16124
- }
16125
- function locale2(key) {
16126
- var newLocaleData;
16127
- if (key === void 0) {
16128
- return this._locale._abbr;
16129
- } else {
16130
- newLocaleData = getLocale2(key);
16131
- if (newLocaleData != null) {
16132
- this._locale = newLocaleData;
16133
- }
16134
- return this;
16135
- }
16136
- }
16137
- var lang2 = deprecate2(
16138
- "moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",
16139
- function(key) {
16140
- if (key === void 0) {
16141
- return this.localeData();
16142
- } else {
16143
- return this.locale(key);
16144
- }
16145
- }
16146
- );
16147
- function localeData2() {
16148
- return this._locale;
16149
- }
16150
- var MS_PER_SECOND2 = 1e3, MS_PER_MINUTE2 = 60 * MS_PER_SECOND2, MS_PER_HOUR2 = 60 * MS_PER_MINUTE2, MS_PER_400_YEARS2 = (365 * 400 + 97) * 24 * MS_PER_HOUR2;
16151
- function mod$12(dividend, divisor) {
16152
- return (dividend % divisor + divisor) % divisor;
16153
- }
16154
- function localStartOfDate2(y, m, d) {
16155
- if (y < 100 && y >= 0) {
16156
- return new Date(y + 400, m, d) - MS_PER_400_YEARS2;
16157
- } else {
16158
- return new Date(y, m, d).valueOf();
16159
- }
16160
- }
16161
- function utcStartOfDate2(y, m, d) {
16162
- if (y < 100 && y >= 0) {
16163
- return Date.UTC(y + 400, m, d) - MS_PER_400_YEARS2;
16164
- } else {
16165
- return Date.UTC(y, m, d);
16166
- }
16167
- }
16168
- function startOf2(units) {
16169
- var time, startOfDate;
16170
- units = normalizeUnits2(units);
16171
- if (units === void 0 || units === "millisecond" || !this.isValid()) {
16172
- return this;
16173
- }
16174
- startOfDate = this._isUTC ? utcStartOfDate2 : localStartOfDate2;
16175
- switch (units) {
16176
- case "year":
16177
- time = startOfDate(this.year(), 0, 1);
16178
- break;
16179
- case "quarter":
16180
- time = startOfDate(
16181
- this.year(),
16182
- this.month() - this.month() % 3,
16183
- 1
16184
- );
16185
- break;
16186
- case "month":
16187
- time = startOfDate(this.year(), this.month(), 1);
16188
- break;
16189
- case "week":
16190
- time = startOfDate(
16191
- this.year(),
16192
- this.month(),
16193
- this.date() - this.weekday()
16194
- );
16195
- break;
16196
- case "isoWeek":
16197
- time = startOfDate(
16198
- this.year(),
16199
- this.month(),
16200
- this.date() - (this.isoWeekday() - 1)
16201
- );
16202
- break;
16203
- case "day":
16204
- case "date":
16205
- time = startOfDate(this.year(), this.month(), this.date());
16206
- break;
16207
- case "hour":
16208
- time = this._d.valueOf();
16209
- time -= mod$12(
16210
- time + (this._isUTC ? 0 : this.utcOffset() * MS_PER_MINUTE2),
16211
- MS_PER_HOUR2
16212
- );
16213
- break;
16214
- case "minute":
16215
- time = this._d.valueOf();
16216
- time -= mod$12(time, MS_PER_MINUTE2);
16217
- break;
16218
- case "second":
16219
- time = this._d.valueOf();
16220
- time -= mod$12(time, MS_PER_SECOND2);
16221
- break;
16222
- }
16223
- this._d.setTime(time);
16224
- hooks2.updateOffset(this, true);
16225
- return this;
16226
- }
16227
- function endOf2(units) {
16228
- var time, startOfDate;
16229
- units = normalizeUnits2(units);
16230
- if (units === void 0 || units === "millisecond" || !this.isValid()) {
16231
- return this;
16232
- }
16233
- startOfDate = this._isUTC ? utcStartOfDate2 : localStartOfDate2;
16234
- switch (units) {
16235
- case "year":
16236
- time = startOfDate(this.year() + 1, 0, 1) - 1;
16237
- break;
16238
- case "quarter":
16239
- time = startOfDate(
16240
- this.year(),
16241
- this.month() - this.month() % 3 + 3,
16242
- 1
16243
- ) - 1;
16244
- break;
16245
- case "month":
16246
- time = startOfDate(this.year(), this.month() + 1, 1) - 1;
16247
- break;
16248
- case "week":
16249
- time = startOfDate(
16250
- this.year(),
16251
- this.month(),
16252
- this.date() - this.weekday() + 7
16253
- ) - 1;
16254
- break;
16255
- case "isoWeek":
16256
- time = startOfDate(
16257
- this.year(),
16258
- this.month(),
16259
- this.date() - (this.isoWeekday() - 1) + 7
16260
- ) - 1;
16261
- break;
16262
- case "day":
16263
- case "date":
16264
- time = startOfDate(this.year(), this.month(), this.date() + 1) - 1;
16265
- break;
16266
- case "hour":
16267
- time = this._d.valueOf();
16268
- time += MS_PER_HOUR2 - mod$12(
16269
- time + (this._isUTC ? 0 : this.utcOffset() * MS_PER_MINUTE2),
16270
- MS_PER_HOUR2
16271
- ) - 1;
16272
- break;
16273
- case "minute":
16274
- time = this._d.valueOf();
16275
- time += MS_PER_MINUTE2 - mod$12(time, MS_PER_MINUTE2) - 1;
16276
- break;
16277
- case "second":
16278
- time = this._d.valueOf();
16279
- time += MS_PER_SECOND2 - mod$12(time, MS_PER_SECOND2) - 1;
16280
- break;
16281
- }
16282
- this._d.setTime(time);
16283
- hooks2.updateOffset(this, true);
16284
- return this;
16285
- }
16286
- function valueOf2() {
16287
- return this._d.valueOf() - (this._offset || 0) * 6e4;
16288
- }
16289
- function unix2() {
16290
- return Math.floor(this.valueOf() / 1e3);
16291
- }
16292
- function toDate2() {
16293
- return new Date(this.valueOf());
16294
- }
16295
- function toArray2() {
16296
- var m = this;
16297
- return [
16298
- m.year(),
16299
- m.month(),
16300
- m.date(),
16301
- m.hour(),
16302
- m.minute(),
16303
- m.second(),
16304
- m.millisecond()
16305
- ];
16306
- }
16307
- function toObject2() {
16308
- var m = this;
16309
- return {
16310
- years: m.year(),
16311
- months: m.month(),
16312
- date: m.date(),
16313
- hours: m.hours(),
16314
- minutes: m.minutes(),
16315
- seconds: m.seconds(),
16316
- milliseconds: m.milliseconds()
16317
- };
16318
- }
16319
- function toJSON3() {
16320
- return this.isValid() ? this.toISOString() : null;
16321
- }
16322
- function isValid$22() {
16323
- return isValid2(this);
16324
- }
16325
- function parsingFlags2() {
16326
- return extend2({}, getParsingFlags2(this));
16327
- }
16328
- function invalidAt2() {
16329
- return getParsingFlags2(this).overflow;
16330
- }
16331
- function creationData2() {
16332
- return {
16333
- input: this._i,
16334
- format: this._f,
16335
- locale: this._locale,
16336
- isUTC: this._isUTC,
16337
- strict: this._strict
16338
- };
16339
- }
16340
- addFormatToken2("N", 0, 0, "eraAbbr");
16341
- addFormatToken2("NN", 0, 0, "eraAbbr");
16342
- addFormatToken2("NNN", 0, 0, "eraAbbr");
16343
- addFormatToken2("NNNN", 0, 0, "eraName");
16344
- addFormatToken2("NNNNN", 0, 0, "eraNarrow");
16345
- addFormatToken2("y", ["y", 1], "yo", "eraYear");
16346
- addFormatToken2("y", ["yy", 2], 0, "eraYear");
16347
- addFormatToken2("y", ["yyy", 3], 0, "eraYear");
16348
- addFormatToken2("y", ["yyyy", 4], 0, "eraYear");
16349
- addRegexToken2("N", matchEraAbbr2);
16350
- addRegexToken2("NN", matchEraAbbr2);
16351
- addRegexToken2("NNN", matchEraAbbr2);
16352
- addRegexToken2("NNNN", matchEraName2);
16353
- addRegexToken2("NNNNN", matchEraNarrow2);
16354
- addParseToken2(
16355
- ["N", "NN", "NNN", "NNNN", "NNNNN"],
16356
- function(input, array, config, token3) {
16357
- var era = config._locale.erasParse(input, token3, config._strict);
16358
- if (era) {
16359
- getParsingFlags2(config).era = era;
16360
- } else {
16361
- getParsingFlags2(config).invalidEra = input;
16362
- }
16363
- }
16364
- );
16365
- addRegexToken2("y", matchUnsigned2);
16366
- addRegexToken2("yy", matchUnsigned2);
16367
- addRegexToken2("yyy", matchUnsigned2);
16368
- addRegexToken2("yyyy", matchUnsigned2);
16369
- addRegexToken2("yo", matchEraYearOrdinal2);
16370
- addParseToken2(["y", "yy", "yyy", "yyyy"], YEAR2);
16371
- addParseToken2(["yo"], function(input, array, config, token3) {
16372
- var match;
16373
- if (config._locale._eraYearOrdinalRegex) {
16374
- match = input.match(config._locale._eraYearOrdinalRegex);
16375
- }
16376
- if (config._locale.eraYearOrdinalParse) {
16377
- array[YEAR2] = config._locale.eraYearOrdinalParse(input, match);
16378
- } else {
16379
- array[YEAR2] = parseInt(input, 10);
16380
- }
16381
- });
16382
- function localeEras2(m, format3) {
16383
- var i, l, date, eras = this._eras || getLocale2("en")._eras;
16384
- for (i = 0, l = eras.length; i < l; ++i) {
16385
- switch (typeof eras[i].since) {
16386
- case "string":
16387
- date = hooks2(eras[i].since).startOf("day");
16388
- eras[i].since = date.valueOf();
16389
- break;
16390
- }
16391
- switch (typeof eras[i].until) {
16392
- case "undefined":
16393
- eras[i].until = Infinity;
16394
- break;
16395
- case "string":
16396
- date = hooks2(eras[i].until).startOf("day").valueOf();
16397
- eras[i].until = date.valueOf();
16398
- break;
16399
- }
16400
- }
16401
- return eras;
16402
- }
16403
- function localeErasParse2(eraName, format3, strict) {
16404
- var i, l, eras = this.eras(), name, abbr, narrow;
16405
- eraName = eraName.toUpperCase();
16406
- for (i = 0, l = eras.length; i < l; ++i) {
16407
- name = eras[i].name.toUpperCase();
16408
- abbr = eras[i].abbr.toUpperCase();
16409
- narrow = eras[i].narrow.toUpperCase();
16410
- if (strict) {
16411
- switch (format3) {
16412
- case "N":
16413
- case "NN":
16414
- case "NNN":
16415
- if (abbr === eraName) {
16416
- return eras[i];
16417
- }
16418
- break;
16419
- case "NNNN":
16420
- if (name === eraName) {
16421
- return eras[i];
16422
- }
16423
- break;
16424
- case "NNNNN":
16425
- if (narrow === eraName) {
16426
- return eras[i];
16427
- }
16428
- break;
16429
- }
16430
- } else if ([name, abbr, narrow].indexOf(eraName) >= 0) {
16431
- return eras[i];
16432
- }
16433
- }
16434
- }
16435
- function localeErasConvertYear2(era, year) {
16436
- var dir = era.since <= era.until ? 1 : -1;
16437
- if (year === void 0) {
16438
- return hooks2(era.since).year();
16439
- } else {
16440
- return hooks2(era.since).year() + (year - era.offset) * dir;
16441
- }
16442
- }
16443
- function getEraName2() {
16444
- var i, l, val, eras = this.localeData().eras();
16445
- for (i = 0, l = eras.length; i < l; ++i) {
16446
- val = this.clone().startOf("day").valueOf();
16447
- if (eras[i].since <= val && val <= eras[i].until) {
16448
- return eras[i].name;
16449
- }
16450
- if (eras[i].until <= val && val <= eras[i].since) {
16451
- return eras[i].name;
16452
- }
16453
- }
16454
- return "";
16455
- }
16456
- function getEraNarrow2() {
16457
- var i, l, val, eras = this.localeData().eras();
16458
- for (i = 0, l = eras.length; i < l; ++i) {
16459
- val = this.clone().startOf("day").valueOf();
16460
- if (eras[i].since <= val && val <= eras[i].until) {
16461
- return eras[i].narrow;
16462
- }
16463
- if (eras[i].until <= val && val <= eras[i].since) {
16464
- return eras[i].narrow;
16465
- }
16466
- }
16467
- return "";
16468
- }
16469
- function getEraAbbr2() {
16470
- var i, l, val, eras = this.localeData().eras();
16471
- for (i = 0, l = eras.length; i < l; ++i) {
16472
- val = this.clone().startOf("day").valueOf();
16473
- if (eras[i].since <= val && val <= eras[i].until) {
16474
- return eras[i].abbr;
16475
- }
16476
- if (eras[i].until <= val && val <= eras[i].since) {
16477
- return eras[i].abbr;
16478
- }
16479
- }
16480
- return "";
16481
- }
16482
- function getEraYear2() {
16483
- var i, l, dir, val, eras = this.localeData().eras();
16484
- for (i = 0, l = eras.length; i < l; ++i) {
16485
- dir = eras[i].since <= eras[i].until ? 1 : -1;
16486
- val = this.clone().startOf("day").valueOf();
16487
- if (eras[i].since <= val && val <= eras[i].until || eras[i].until <= val && val <= eras[i].since) {
16488
- return (this.year() - hooks2(eras[i].since).year()) * dir + eras[i].offset;
16489
- }
16490
- }
16491
- return this.year();
16492
- }
16493
- function erasNameRegex2(isStrict) {
16494
- if (!hasOwnProp2(this, "_erasNameRegex")) {
16495
- computeErasParse2.call(this);
16496
- }
16497
- return isStrict ? this._erasNameRegex : this._erasRegex;
16498
- }
16499
- function erasAbbrRegex2(isStrict) {
16500
- if (!hasOwnProp2(this, "_erasAbbrRegex")) {
16501
- computeErasParse2.call(this);
16502
- }
16503
- return isStrict ? this._erasAbbrRegex : this._erasRegex;
16504
- }
16505
- function erasNarrowRegex2(isStrict) {
16506
- if (!hasOwnProp2(this, "_erasNarrowRegex")) {
16507
- computeErasParse2.call(this);
16508
- }
16509
- return isStrict ? this._erasNarrowRegex : this._erasRegex;
16510
- }
16511
- function matchEraAbbr2(isStrict, locale3) {
16512
- return locale3.erasAbbrRegex(isStrict);
16513
- }
16514
- function matchEraName2(isStrict, locale3) {
16515
- return locale3.erasNameRegex(isStrict);
16516
- }
16517
- function matchEraNarrow2(isStrict, locale3) {
16518
- return locale3.erasNarrowRegex(isStrict);
16519
- }
16520
- function matchEraYearOrdinal2(isStrict, locale3) {
16521
- return locale3._eraYearOrdinalRegex || matchUnsigned2;
16522
- }
16523
- function computeErasParse2() {
16524
- var abbrPieces = [], namePieces = [], narrowPieces = [], mixedPieces = [], i, l, erasName, erasAbbr, erasNarrow, eras = this.eras();
16525
- for (i = 0, l = eras.length; i < l; ++i) {
16526
- erasName = regexEscape2(eras[i].name);
16527
- erasAbbr = regexEscape2(eras[i].abbr);
16528
- erasNarrow = regexEscape2(eras[i].narrow);
16529
- namePieces.push(erasName);
16530
- abbrPieces.push(erasAbbr);
16531
- narrowPieces.push(erasNarrow);
16532
- mixedPieces.push(erasName);
16533
- mixedPieces.push(erasAbbr);
16534
- mixedPieces.push(erasNarrow);
16535
- }
16536
- this._erasRegex = new RegExp("^(" + mixedPieces.join("|") + ")", "i");
16537
- this._erasNameRegex = new RegExp("^(" + namePieces.join("|") + ")", "i");
16538
- this._erasAbbrRegex = new RegExp("^(" + abbrPieces.join("|") + ")", "i");
16539
- this._erasNarrowRegex = new RegExp(
16540
- "^(" + narrowPieces.join("|") + ")",
16541
- "i"
16542
- );
16543
- }
16544
- addFormatToken2(0, ["gg", 2], 0, function() {
16545
- return this.weekYear() % 100;
16546
- });
16547
- addFormatToken2(0, ["GG", 2], 0, function() {
16548
- return this.isoWeekYear() % 100;
16549
- });
16550
- function addWeekYearFormatToken2(token3, getter) {
16551
- addFormatToken2(0, [token3, token3.length], 0, getter);
16552
- }
16553
- addWeekYearFormatToken2("gggg", "weekYear");
16554
- addWeekYearFormatToken2("ggggg", "weekYear");
16555
- addWeekYearFormatToken2("GGGG", "isoWeekYear");
16556
- addWeekYearFormatToken2("GGGGG", "isoWeekYear");
16557
- addRegexToken2("G", matchSigned2);
16558
- addRegexToken2("g", matchSigned2);
16559
- addRegexToken2("GG", match1to22, match22);
16560
- addRegexToken2("gg", match1to22, match22);
16561
- addRegexToken2("GGGG", match1to42, match42);
16562
- addRegexToken2("gggg", match1to42, match42);
16563
- addRegexToken2("GGGGG", match1to62, match62);
16564
- addRegexToken2("ggggg", match1to62, match62);
16565
- addWeekParseToken2(
16566
- ["gggg", "ggggg", "GGGG", "GGGGG"],
16567
- function(input, week, config, token3) {
16568
- week[token3.substr(0, 2)] = toInt2(input);
16569
- }
16570
- );
16571
- addWeekParseToken2(["gg", "GG"], function(input, week, config, token3) {
16572
- week[token3] = hooks2.parseTwoDigitYear(input);
16573
- });
16574
- function getSetWeekYear2(input) {
16575
- return getSetWeekYearHelper2.call(
16576
- this,
16577
- input,
16578
- this.week(),
16579
- this.weekday() + this.localeData()._week.dow,
16580
- this.localeData()._week.dow,
16581
- this.localeData()._week.doy
16582
- );
16583
- }
16584
- function getSetISOWeekYear2(input) {
16585
- return getSetWeekYearHelper2.call(
16586
- this,
16587
- input,
16588
- this.isoWeek(),
16589
- this.isoWeekday(),
16590
- 1,
16591
- 4
16592
- );
16593
- }
16594
- function getISOWeeksInYear2() {
16595
- return weeksInYear2(this.year(), 1, 4);
16596
- }
16597
- function getISOWeeksInISOWeekYear2() {
16598
- return weeksInYear2(this.isoWeekYear(), 1, 4);
16599
- }
16600
- function getWeeksInYear2() {
16601
- var weekInfo = this.localeData()._week;
16602
- return weeksInYear2(this.year(), weekInfo.dow, weekInfo.doy);
16603
- }
16604
- function getWeeksInWeekYear2() {
16605
- var weekInfo = this.localeData()._week;
16606
- return weeksInYear2(this.weekYear(), weekInfo.dow, weekInfo.doy);
16607
- }
16608
- function getSetWeekYearHelper2(input, week, weekday, dow, doy) {
16609
- var weeksTarget;
16610
- if (input == null) {
16611
- return weekOfYear2(this, dow, doy).year;
16612
- } else {
16613
- weeksTarget = weeksInYear2(input, dow, doy);
16614
- if (week > weeksTarget) {
16615
- week = weeksTarget;
16616
- }
16617
- return setWeekAll2.call(this, input, week, weekday, dow, doy);
16618
- }
16619
- }
16620
- function setWeekAll2(weekYear, week, weekday, dow, doy) {
16621
- var dayOfYearData = dayOfYearFromWeeks2(weekYear, week, weekday, dow, doy), date = createUTCDate2(dayOfYearData.year, 0, dayOfYearData.dayOfYear);
16622
- this.year(date.getUTCFullYear());
16623
- this.month(date.getUTCMonth());
16624
- this.date(date.getUTCDate());
16625
- return this;
16626
- }
16627
- addFormatToken2("Q", 0, "Qo", "quarter");
16628
- addRegexToken2("Q", match12);
16629
- addParseToken2("Q", function(input, array) {
16630
- array[MONTH2] = (toInt2(input) - 1) * 3;
16631
- });
16632
- function getSetQuarter2(input) {
16633
- return input == null ? Math.ceil((this.month() + 1) / 3) : this.month((input - 1) * 3 + this.month() % 3);
16634
- }
16635
- addFormatToken2("D", ["DD", 2], "Do", "date");
16636
- addRegexToken2("D", match1to22, match1to2NoLeadingZero2);
16637
- addRegexToken2("DD", match1to22, match22);
16638
- addRegexToken2("Do", function(isStrict, locale3) {
16639
- return isStrict ? locale3._dayOfMonthOrdinalParse || locale3._ordinalParse : locale3._dayOfMonthOrdinalParseLenient;
16640
- });
16641
- addParseToken2(["D", "DD"], DATE2);
16642
- addParseToken2("Do", function(input, array) {
16643
- array[DATE2] = toInt2(input.match(match1to22)[0]);
16644
- });
16645
- var getSetDayOfMonth2 = makeGetSet2("Date", true);
16646
- addFormatToken2("DDD", ["DDDD", 3], "DDDo", "dayOfYear");
16647
- addRegexToken2("DDD", match1to32);
16648
- addRegexToken2("DDDD", match32);
16649
- addParseToken2(["DDD", "DDDD"], function(input, array, config) {
16650
- config._dayOfYear = toInt2(input);
16651
- });
16652
- function getSetDayOfYear2(input) {
16653
- var dayOfYear = Math.round(
16654
- (this.clone().startOf("day") - this.clone().startOf("year")) / 864e5
16655
- ) + 1;
16656
- return input == null ? dayOfYear : this.add(input - dayOfYear, "d");
16657
- }
16658
- addFormatToken2("m", ["mm", 2], 0, "minute");
16659
- addRegexToken2("m", match1to22, match1to2HasZero2);
16660
- addRegexToken2("mm", match1to22, match22);
16661
- addParseToken2(["m", "mm"], MINUTE2);
16662
- var getSetMinute2 = makeGetSet2("Minutes", false);
16663
- addFormatToken2("s", ["ss", 2], 0, "second");
16664
- addRegexToken2("s", match1to22, match1to2HasZero2);
16665
- addRegexToken2("ss", match1to22, match22);
16666
- addParseToken2(["s", "ss"], SECOND2);
16667
- var getSetSecond2 = makeGetSet2("Seconds", false);
16668
- addFormatToken2("S", 0, 0, function() {
16669
- return ~~(this.millisecond() / 100);
16670
- });
16671
- addFormatToken2(0, ["SS", 2], 0, function() {
16672
- return ~~(this.millisecond() / 10);
16673
- });
16674
- addFormatToken2(0, ["SSS", 3], 0, "millisecond");
16675
- addFormatToken2(0, ["SSSS", 4], 0, function() {
16676
- return this.millisecond() * 10;
16677
- });
16678
- addFormatToken2(0, ["SSSSS", 5], 0, function() {
16679
- return this.millisecond() * 100;
16680
- });
16681
- addFormatToken2(0, ["SSSSSS", 6], 0, function() {
16682
- return this.millisecond() * 1e3;
16683
- });
16684
- addFormatToken2(0, ["SSSSSSS", 7], 0, function() {
16685
- return this.millisecond() * 1e4;
16686
- });
16687
- addFormatToken2(0, ["SSSSSSSS", 8], 0, function() {
16688
- return this.millisecond() * 1e5;
16689
- });
16690
- addFormatToken2(0, ["SSSSSSSSS", 9], 0, function() {
16691
- return this.millisecond() * 1e6;
16692
- });
16693
- addRegexToken2("S", match1to32, match12);
16694
- addRegexToken2("SS", match1to32, match22);
16695
- addRegexToken2("SSS", match1to32, match32);
16696
- var token2, getSetMillisecond2;
16697
- for (token2 = "SSSS"; token2.length <= 9; token2 += "S") {
16698
- addRegexToken2(token2, matchUnsigned2);
16699
- }
16700
- function parseMs2(input, array) {
16701
- array[MILLISECOND2] = toInt2(("0." + input) * 1e3);
16702
- }
16703
- for (token2 = "S"; token2.length <= 9; token2 += "S") {
16704
- addParseToken2(token2, parseMs2);
16705
- }
16706
- getSetMillisecond2 = makeGetSet2("Milliseconds", false);
16707
- addFormatToken2("z", 0, 0, "zoneAbbr");
16708
- addFormatToken2("zz", 0, 0, "zoneName");
16709
- function getZoneAbbr2() {
16710
- return this._isUTC ? "UTC" : "";
16711
- }
16712
- function getZoneName2() {
16713
- return this._isUTC ? "Coordinated Universal Time" : "";
16714
- }
16715
- var proto2 = Moment2.prototype;
16716
- proto2.add = add2;
16717
- proto2.calendar = calendar$12;
16718
- proto2.clone = clone2;
16719
- proto2.diff = diff2;
16720
- proto2.endOf = endOf2;
16721
- proto2.format = format2;
16722
- proto2.from = from2;
16723
- proto2.fromNow = fromNow2;
16724
- proto2.to = to2;
16725
- proto2.toNow = toNow2;
16726
- proto2.get = stringGet2;
16727
- proto2.invalidAt = invalidAt2;
16728
- proto2.isAfter = isAfter2;
16729
- proto2.isBefore = isBefore2;
16730
- proto2.isBetween = isBetween2;
16731
- proto2.isSame = isSame2;
16732
- proto2.isSameOrAfter = isSameOrAfter2;
16733
- proto2.isSameOrBefore = isSameOrBefore2;
16734
- proto2.isValid = isValid$22;
16735
- proto2.lang = lang2;
16736
- proto2.locale = locale2;
16737
- proto2.localeData = localeData2;
16738
- proto2.max = prototypeMax2;
16739
- proto2.min = prototypeMin2;
16740
- proto2.parsingFlags = parsingFlags2;
16741
- proto2.set = stringSet2;
16742
- proto2.startOf = startOf2;
16743
- proto2.subtract = subtract2;
16744
- proto2.toArray = toArray2;
16745
- proto2.toObject = toObject2;
16746
- proto2.toDate = toDate2;
16747
- proto2.toISOString = toISOString2;
16748
- proto2.inspect = inspect2;
16749
- if (typeof Symbol !== "undefined" && Symbol.for != null) {
16750
- proto2[Symbol.for("nodejs.util.inspect.custom")] = function() {
16751
- return "Moment<" + this.format() + ">";
16752
- };
16753
- }
16754
- proto2.toJSON = toJSON3;
16755
- proto2.toString = toString3;
16756
- proto2.unix = unix2;
16757
- proto2.valueOf = valueOf2;
16758
- proto2.creationData = creationData2;
16759
- proto2.eraName = getEraName2;
16760
- proto2.eraNarrow = getEraNarrow2;
16761
- proto2.eraAbbr = getEraAbbr2;
16762
- proto2.eraYear = getEraYear2;
16763
- proto2.year = getSetYear2;
16764
- proto2.isLeapYear = getIsLeapYear2;
16765
- proto2.weekYear = getSetWeekYear2;
16766
- proto2.isoWeekYear = getSetISOWeekYear2;
16767
- proto2.quarter = proto2.quarters = getSetQuarter2;
16768
- proto2.month = getSetMonth2;
16769
- proto2.daysInMonth = getDaysInMonth2;
16770
- proto2.week = proto2.weeks = getSetWeek2;
16771
- proto2.isoWeek = proto2.isoWeeks = getSetISOWeek2;
16772
- proto2.weeksInYear = getWeeksInYear2;
16773
- proto2.weeksInWeekYear = getWeeksInWeekYear2;
16774
- proto2.isoWeeksInYear = getISOWeeksInYear2;
16775
- proto2.isoWeeksInISOWeekYear = getISOWeeksInISOWeekYear2;
16776
- proto2.date = getSetDayOfMonth2;
16777
- proto2.day = proto2.days = getSetDayOfWeek2;
16778
- proto2.weekday = getSetLocaleDayOfWeek2;
16779
- proto2.isoWeekday = getSetISODayOfWeek2;
16780
- proto2.dayOfYear = getSetDayOfYear2;
16781
- proto2.hour = proto2.hours = getSetHour2;
16782
- proto2.minute = proto2.minutes = getSetMinute2;
16783
- proto2.second = proto2.seconds = getSetSecond2;
16784
- proto2.millisecond = proto2.milliseconds = getSetMillisecond2;
16785
- proto2.utcOffset = getSetOffset2;
16786
- proto2.utc = setOffsetToUTC2;
16787
- proto2.local = setOffsetToLocal2;
16788
- proto2.parseZone = setOffsetToParsedOffset2;
16789
- proto2.hasAlignedHourOffset = hasAlignedHourOffset2;
16790
- proto2.isDST = isDaylightSavingTime2;
16791
- proto2.isLocal = isLocal2;
16792
- proto2.isUtcOffset = isUtcOffset2;
16793
- proto2.isUtc = isUtc2;
16794
- proto2.isUTC = isUtc2;
16795
- proto2.zoneAbbr = getZoneAbbr2;
16796
- proto2.zoneName = getZoneName2;
16797
- proto2.dates = deprecate2(
16798
- "dates accessor is deprecated. Use date instead.",
16799
- getSetDayOfMonth2
16800
- );
16801
- proto2.months = deprecate2(
16802
- "months accessor is deprecated. Use month instead",
16803
- getSetMonth2
16804
- );
16805
- proto2.years = deprecate2(
16806
- "years accessor is deprecated. Use year instead",
16807
- getSetYear2
16808
- );
16809
- proto2.zone = deprecate2(
16810
- "moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",
16811
- getSetZone2
16812
- );
16813
- proto2.isDSTShifted = deprecate2(
16814
- "isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",
16815
- isDaylightSavingTimeShifted2
16816
- );
16817
- function createUnix2(input) {
16818
- return createLocal2(input * 1e3);
16819
- }
16820
- function createInZone2() {
16821
- return createLocal2.apply(null, arguments).parseZone();
16822
- }
16823
- function preParsePostFormat2(string) {
16824
- return string;
16825
- }
16826
- var proto$12 = Locale2.prototype;
16827
- proto$12.calendar = calendar2;
16828
- proto$12.longDateFormat = longDateFormat2;
16829
- proto$12.invalidDate = invalidDate2;
16830
- proto$12.ordinal = ordinal2;
16831
- proto$12.preparse = preParsePostFormat2;
16832
- proto$12.postformat = preParsePostFormat2;
16833
- proto$12.relativeTime = relativeTime2;
16834
- proto$12.pastFuture = pastFuture2;
16835
- proto$12.set = set2;
16836
- proto$12.eras = localeEras2;
16837
- proto$12.erasParse = localeErasParse2;
16838
- proto$12.erasConvertYear = localeErasConvertYear2;
16839
- proto$12.erasAbbrRegex = erasAbbrRegex2;
16840
- proto$12.erasNameRegex = erasNameRegex2;
16841
- proto$12.erasNarrowRegex = erasNarrowRegex2;
16842
- proto$12.months = localeMonths2;
16843
- proto$12.monthsShort = localeMonthsShort2;
16844
- proto$12.monthsParse = localeMonthsParse2;
16845
- proto$12.monthsRegex = monthsRegex2;
16846
- proto$12.monthsShortRegex = monthsShortRegex2;
16847
- proto$12.week = localeWeek2;
16848
- proto$12.firstDayOfYear = localeFirstDayOfYear2;
16849
- proto$12.firstDayOfWeek = localeFirstDayOfWeek2;
16850
- proto$12.weekdays = localeWeekdays2;
16851
- proto$12.weekdaysMin = localeWeekdaysMin2;
16852
- proto$12.weekdaysShort = localeWeekdaysShort2;
16853
- proto$12.weekdaysParse = localeWeekdaysParse2;
16854
- proto$12.weekdaysRegex = weekdaysRegex2;
16855
- proto$12.weekdaysShortRegex = weekdaysShortRegex2;
16856
- proto$12.weekdaysMinRegex = weekdaysMinRegex2;
16857
- proto$12.isPM = localeIsPM2;
16858
- proto$12.meridiem = localeMeridiem2;
16859
- function get$12(format3, index, field, setter) {
16860
- var locale3 = getLocale2(), utc = createUTC2().set(setter, index);
16861
- return locale3[field](utc, format3);
16862
- }
16863
- function listMonthsImpl2(format3, index, field) {
16864
- if (isNumber2(format3)) {
16865
- index = format3;
16866
- format3 = void 0;
16867
- }
16868
- format3 = format3 || "";
16869
- if (index != null) {
16870
- return get$12(format3, index, field, "month");
16871
- }
16872
- var i, out = [];
16873
- for (i = 0; i < 12; i++) {
16874
- out[i] = get$12(format3, i, field, "month");
16875
- }
16876
- return out;
16877
- }
16878
- function listWeekdaysImpl2(localeSorted, format3, index, field) {
16879
- if (typeof localeSorted === "boolean") {
16880
- if (isNumber2(format3)) {
16881
- index = format3;
16882
- format3 = void 0;
16883
- }
16884
- format3 = format3 || "";
16885
- } else {
16886
- format3 = localeSorted;
16887
- index = format3;
16888
- localeSorted = false;
16889
- if (isNumber2(format3)) {
16890
- index = format3;
16891
- format3 = void 0;
16892
- }
16893
- format3 = format3 || "";
16894
- }
16895
- var locale3 = getLocale2(), shift = localeSorted ? locale3._week.dow : 0, i, out = [];
16896
- if (index != null) {
16897
- return get$12(format3, (index + shift) % 7, field, "day");
16898
- }
16899
- for (i = 0; i < 7; i++) {
16900
- out[i] = get$12(format3, (i + shift) % 7, field, "day");
16901
- }
16902
- return out;
16903
- }
16904
- function listMonths2(format3, index) {
16905
- return listMonthsImpl2(format3, index, "months");
16906
- }
16907
- function listMonthsShort2(format3, index) {
16908
- return listMonthsImpl2(format3, index, "monthsShort");
16909
- }
16910
- function listWeekdays2(localeSorted, format3, index) {
16911
- return listWeekdaysImpl2(localeSorted, format3, index, "weekdays");
16912
- }
16913
- function listWeekdaysShort2(localeSorted, format3, index) {
16914
- return listWeekdaysImpl2(localeSorted, format3, index, "weekdaysShort");
16915
- }
16916
- function listWeekdaysMin2(localeSorted, format3, index) {
16917
- return listWeekdaysImpl2(localeSorted, format3, index, "weekdaysMin");
16918
- }
16919
- getSetGlobalLocale2("en", {
16920
- eras: [
16921
- {
16922
- since: "0001-01-01",
16923
- until: Infinity,
16924
- offset: 1,
16925
- name: "Anno Domini",
16926
- narrow: "AD",
16927
- abbr: "AD"
16928
- },
16929
- {
16930
- since: "0000-12-31",
16931
- until: -Infinity,
16932
- offset: 1,
16933
- name: "Before Christ",
16934
- narrow: "BC",
16935
- abbr: "BC"
16936
- }
16937
- ],
16938
- dayOfMonthOrdinalParse: /\d{1,2}(th|st|nd|rd)/,
16939
- ordinal: function(number) {
16940
- var b = number % 10, output = toInt2(number % 100 / 10) === 1 ? "th" : b === 1 ? "st" : b === 2 ? "nd" : b === 3 ? "rd" : "th";
16941
- return number + output;
16942
- }
16943
- });
16944
- hooks2.lang = deprecate2(
16945
- "moment.lang is deprecated. Use moment.locale instead.",
16946
- getSetGlobalLocale2
16947
- );
16948
- hooks2.langData = deprecate2(
16949
- "moment.langData is deprecated. Use moment.localeData instead.",
16950
- getLocale2
16951
- );
16952
- var mathAbs2 = Math.abs;
16953
- function abs2() {
16954
- var data = this._data;
16955
- this._milliseconds = mathAbs2(this._milliseconds);
16956
- this._days = mathAbs2(this._days);
16957
- this._months = mathAbs2(this._months);
16958
- data.milliseconds = mathAbs2(data.milliseconds);
16959
- data.seconds = mathAbs2(data.seconds);
16960
- data.minutes = mathAbs2(data.minutes);
16961
- data.hours = mathAbs2(data.hours);
16962
- data.months = mathAbs2(data.months);
16963
- data.years = mathAbs2(data.years);
16964
- return this;
16965
- }
16966
- function addSubtract$12(duration, input, value, direction) {
16967
- var other = createDuration2(input, value);
16968
- duration._milliseconds += direction * other._milliseconds;
16969
- duration._days += direction * other._days;
16970
- duration._months += direction * other._months;
16971
- return duration._bubble();
16972
- }
16973
- function add$12(input, value) {
16974
- return addSubtract$12(this, input, value, 1);
16975
- }
16976
- function subtract$12(input, value) {
16977
- return addSubtract$12(this, input, value, -1);
16978
- }
16979
- function absCeil2(number) {
16980
- if (number < 0) {
16981
- return Math.floor(number);
16982
- } else {
16983
- return Math.ceil(number);
16984
- }
16985
- }
16986
- function bubble2() {
16987
- var milliseconds3 = this._milliseconds, days3 = this._days, months3 = this._months, data = this._data, seconds3, minutes3, hours3, years3, monthsFromDays;
16988
- if (!(milliseconds3 >= 0 && days3 >= 0 && months3 >= 0 || milliseconds3 <= 0 && days3 <= 0 && months3 <= 0)) {
16989
- milliseconds3 += absCeil2(monthsToDays2(months3) + days3) * 864e5;
16990
- days3 = 0;
16991
- months3 = 0;
16992
- }
16993
- data.milliseconds = milliseconds3 % 1e3;
16994
- seconds3 = absFloor2(milliseconds3 / 1e3);
16995
- data.seconds = seconds3 % 60;
16996
- minutes3 = absFloor2(seconds3 / 60);
16997
- data.minutes = minutes3 % 60;
16998
- hours3 = absFloor2(minutes3 / 60);
16999
- data.hours = hours3 % 24;
17000
- days3 += absFloor2(hours3 / 24);
17001
- monthsFromDays = absFloor2(daysToMonths2(days3));
17002
- months3 += monthsFromDays;
17003
- days3 -= absCeil2(monthsToDays2(monthsFromDays));
17004
- years3 = absFloor2(months3 / 12);
17005
- months3 %= 12;
17006
- data.days = days3;
17007
- data.months = months3;
17008
- data.years = years3;
17009
- return this;
17010
- }
17011
- function daysToMonths2(days3) {
17012
- return days3 * 4800 / 146097;
17013
- }
17014
- function monthsToDays2(months3) {
17015
- return months3 * 146097 / 4800;
17016
- }
17017
- function as2(units) {
17018
- if (!this.isValid()) {
17019
- return NaN;
17020
- }
17021
- var days3, months3, milliseconds3 = this._milliseconds;
17022
- units = normalizeUnits2(units);
17023
- if (units === "month" || units === "quarter" || units === "year") {
17024
- days3 = this._days + milliseconds3 / 864e5;
17025
- months3 = this._months + daysToMonths2(days3);
17026
- switch (units) {
17027
- case "month":
17028
- return months3;
17029
- case "quarter":
17030
- return months3 / 3;
17031
- case "year":
17032
- return months3 / 12;
17033
- }
17034
- } else {
17035
- days3 = this._days + Math.round(monthsToDays2(this._months));
17036
- switch (units) {
17037
- case "week":
17038
- return days3 / 7 + milliseconds3 / 6048e5;
17039
- case "day":
17040
- return days3 + milliseconds3 / 864e5;
17041
- case "hour":
17042
- return days3 * 24 + milliseconds3 / 36e5;
17043
- case "minute":
17044
- return days3 * 1440 + milliseconds3 / 6e4;
17045
- case "second":
17046
- return days3 * 86400 + milliseconds3 / 1e3;
17047
- // Math.floor prevents floating point math errors here
17048
- case "millisecond":
17049
- return Math.floor(days3 * 864e5) + milliseconds3;
17050
- default:
17051
- throw new Error("Unknown unit " + units);
17052
- }
17053
- }
17054
- }
17055
- function makeAs2(alias) {
17056
- return function() {
17057
- return this.as(alias);
17058
- };
17059
- }
17060
- var asMilliseconds2 = makeAs2("ms"), asSeconds2 = makeAs2("s"), asMinutes2 = makeAs2("m"), asHours2 = makeAs2("h"), asDays2 = makeAs2("d"), asWeeks2 = makeAs2("w"), asMonths2 = makeAs2("M"), asQuarters2 = makeAs2("Q"), asYears2 = makeAs2("y"), valueOf$12 = asMilliseconds2;
17061
- function clone$12() {
17062
- return createDuration2(this);
17063
- }
17064
- function get$22(units) {
17065
- units = normalizeUnits2(units);
17066
- return this.isValid() ? this[units + "s"]() : NaN;
17067
- }
17068
- function makeGetter2(name) {
17069
- return function() {
17070
- return this.isValid() ? this._data[name] : NaN;
17071
- };
17072
- }
17073
- var milliseconds2 = makeGetter2("milliseconds"), seconds2 = makeGetter2("seconds"), minutes2 = makeGetter2("minutes"), hours2 = makeGetter2("hours"), days2 = makeGetter2("days"), months2 = makeGetter2("months"), years2 = makeGetter2("years");
17074
- function weeks2() {
17075
- return absFloor2(this.days() / 7);
17076
- }
17077
- var round2 = Math.round, thresholds2 = {
17078
- ss: 44,
17079
- // a few seconds to seconds
17080
- s: 45,
17081
- // seconds to minute
17082
- m: 45,
17083
- // minutes to hour
17084
- h: 22,
17085
- // hours to day
17086
- d: 26,
17087
- // days to month/week
17088
- w: null,
17089
- // weeks to month
17090
- M: 11
17091
- // months to year
17092
- };
17093
- function substituteTimeAgo2(string, number, withoutSuffix, isFuture, locale3) {
17094
- return locale3.relativeTime(number || 1, !!withoutSuffix, string, isFuture);
17095
- }
17096
- function relativeTime$12(posNegDuration, withoutSuffix, thresholds3, locale3) {
17097
- var duration = createDuration2(posNegDuration).abs(), seconds3 = round2(duration.as("s")), minutes3 = round2(duration.as("m")), hours3 = round2(duration.as("h")), days3 = round2(duration.as("d")), months3 = round2(duration.as("M")), weeks3 = round2(duration.as("w")), years3 = round2(duration.as("y")), a2 = seconds3 <= thresholds3.ss && ["s", seconds3] || seconds3 < thresholds3.s && ["ss", seconds3] || minutes3 <= 1 && ["m"] || minutes3 < thresholds3.m && ["mm", minutes3] || hours3 <= 1 && ["h"] || hours3 < thresholds3.h && ["hh", hours3] || days3 <= 1 && ["d"] || days3 < thresholds3.d && ["dd", days3];
17098
- if (thresholds3.w != null) {
17099
- a2 = a2 || weeks3 <= 1 && ["w"] || weeks3 < thresholds3.w && ["ww", weeks3];
17100
- }
17101
- a2 = a2 || months3 <= 1 && ["M"] || months3 < thresholds3.M && ["MM", months3] || years3 <= 1 && ["y"] || ["yy", years3];
17102
- a2[2] = withoutSuffix;
17103
- a2[3] = +posNegDuration > 0;
17104
- a2[4] = locale3;
17105
- return substituteTimeAgo2.apply(null, a2);
17106
- }
17107
- function getSetRelativeTimeRounding2(roundingFunction) {
17108
- if (roundingFunction === void 0) {
17109
- return round2;
17110
- }
17111
- if (typeof roundingFunction === "function") {
17112
- round2 = roundingFunction;
17113
- return true;
17114
- }
17115
- return false;
17116
- }
17117
- function getSetRelativeTimeThreshold2(threshold, limit) {
17118
- if (thresholds2[threshold] === void 0) {
17119
- return false;
17120
- }
17121
- if (limit === void 0) {
17122
- return thresholds2[threshold];
17123
- }
17124
- thresholds2[threshold] = limit;
17125
- if (threshold === "s") {
17126
- thresholds2.ss = limit - 1;
17127
- }
17128
- return true;
17129
- }
17130
- function humanize2(argWithSuffix, argThresholds) {
17131
- if (!this.isValid()) {
17132
- return this.localeData().invalidDate();
17133
- }
17134
- var withSuffix = false, th = thresholds2, locale3, output;
17135
- if (typeof argWithSuffix === "object") {
17136
- argThresholds = argWithSuffix;
17137
- argWithSuffix = false;
17138
- }
17139
- if (typeof argWithSuffix === "boolean") {
17140
- withSuffix = argWithSuffix;
17141
- }
17142
- if (typeof argThresholds === "object") {
17143
- th = Object.assign({}, thresholds2, argThresholds);
17144
- if (argThresholds.s != null && argThresholds.ss == null) {
17145
- th.ss = argThresholds.s - 1;
17146
- }
17147
- }
17148
- locale3 = this.localeData();
17149
- output = relativeTime$12(this, !withSuffix, th, locale3);
17150
- if (withSuffix) {
17151
- output = locale3.pastFuture(+this, output);
17152
- }
17153
- return locale3.postformat(output);
17154
- }
17155
- var abs$12 = Math.abs;
17156
- function sign2(x) {
17157
- return (x > 0) - (x < 0) || +x;
17158
- }
17159
- function toISOString$12() {
17160
- if (!this.isValid()) {
17161
- return this.localeData().invalidDate();
17162
- }
17163
- var seconds3 = abs$12(this._milliseconds) / 1e3, days3 = abs$12(this._days), months3 = abs$12(this._months), minutes3, hours3, years3, s2, total = this.asSeconds(), totalSign, ymSign, daysSign, hmsSign;
17164
- if (!total) {
17165
- return "P0D";
17166
- }
17167
- minutes3 = absFloor2(seconds3 / 60);
17168
- hours3 = absFloor2(minutes3 / 60);
17169
- seconds3 %= 60;
17170
- minutes3 %= 60;
17171
- years3 = absFloor2(months3 / 12);
17172
- months3 %= 12;
17173
- s2 = seconds3 ? seconds3.toFixed(3).replace(/\.?0+$/, "") : "";
17174
- totalSign = total < 0 ? "-" : "";
17175
- ymSign = sign2(this._months) !== sign2(total) ? "-" : "";
17176
- daysSign = sign2(this._days) !== sign2(total) ? "-" : "";
17177
- hmsSign = sign2(this._milliseconds) !== sign2(total) ? "-" : "";
17178
- return totalSign + "P" + (years3 ? ymSign + years3 + "Y" : "") + (months3 ? ymSign + months3 + "M" : "") + (days3 ? daysSign + days3 + "D" : "") + (hours3 || minutes3 || seconds3 ? "T" : "") + (hours3 ? hmsSign + hours3 + "H" : "") + (minutes3 ? hmsSign + minutes3 + "M" : "") + (seconds3 ? hmsSign + s2 + "S" : "");
17179
- }
17180
- var proto$22 = Duration2.prototype;
17181
- proto$22.isValid = isValid$12;
17182
- proto$22.abs = abs2;
17183
- proto$22.add = add$12;
17184
- proto$22.subtract = subtract$12;
17185
- proto$22.as = as2;
17186
- proto$22.asMilliseconds = asMilliseconds2;
17187
- proto$22.asSeconds = asSeconds2;
17188
- proto$22.asMinutes = asMinutes2;
17189
- proto$22.asHours = asHours2;
17190
- proto$22.asDays = asDays2;
17191
- proto$22.asWeeks = asWeeks2;
17192
- proto$22.asMonths = asMonths2;
17193
- proto$22.asQuarters = asQuarters2;
17194
- proto$22.asYears = asYears2;
17195
- proto$22.valueOf = valueOf$12;
17196
- proto$22._bubble = bubble2;
17197
- proto$22.clone = clone$12;
17198
- proto$22.get = get$22;
17199
- proto$22.milliseconds = milliseconds2;
17200
- proto$22.seconds = seconds2;
17201
- proto$22.minutes = minutes2;
17202
- proto$22.hours = hours2;
17203
- proto$22.days = days2;
17204
- proto$22.weeks = weeks2;
17205
- proto$22.months = months2;
17206
- proto$22.years = years2;
17207
- proto$22.humanize = humanize2;
17208
- proto$22.toISOString = toISOString$12;
17209
- proto$22.toString = toISOString$12;
17210
- proto$22.toJSON = toISOString$12;
17211
- proto$22.locale = locale2;
17212
- proto$22.localeData = localeData2;
17213
- proto$22.toIsoString = deprecate2(
17214
- "toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",
17215
- toISOString$12
17216
- );
17217
- proto$22.lang = lang2;
17218
- addFormatToken2("X", 0, 0, "unix");
17219
- addFormatToken2("x", 0, 0, "valueOf");
17220
- addRegexToken2("x", matchSigned2);
17221
- addRegexToken2("X", matchTimestamp2);
17222
- addParseToken2("X", function(input, array, config) {
17223
- config._d = new Date(parseFloat(input) * 1e3);
17224
- });
17225
- addParseToken2("x", function(input, array, config) {
17226
- config._d = new Date(toInt2(input));
17227
- });
17228
- //! moment.js
17229
- hooks2.version = "2.30.1";
17230
- setHookCallback2(createLocal2);
17231
- hooks2.fn = proto2;
17232
- hooks2.min = min2;
17233
- hooks2.max = max2;
17234
- hooks2.now = now2;
17235
- hooks2.utc = createUTC2;
17236
- hooks2.unix = createUnix2;
17237
- hooks2.months = listMonths2;
17238
- hooks2.isDate = isDate2;
17239
- hooks2.locale = getSetGlobalLocale2;
17240
- hooks2.invalid = createInvalid2;
17241
- hooks2.duration = createDuration2;
17242
- hooks2.isMoment = isMoment2;
17243
- hooks2.weekdays = listWeekdays2;
17244
- hooks2.parseZone = createInZone2;
17245
- hooks2.localeData = getLocale2;
17246
- hooks2.isDuration = isDuration2;
17247
- hooks2.monthsShort = listMonthsShort2;
17248
- hooks2.weekdaysMin = listWeekdaysMin2;
17249
- hooks2.defineLocale = defineLocale2;
17250
- hooks2.updateLocale = updateLocale2;
17251
- hooks2.locales = listLocales2;
17252
- hooks2.weekdaysShort = listWeekdaysShort2;
17253
- hooks2.normalizeUnits = normalizeUnits2;
17254
- hooks2.relativeTimeRounding = getSetRelativeTimeRounding2;
17255
- hooks2.relativeTimeThreshold = getSetRelativeTimeThreshold2;
17256
- hooks2.calendarFormat = getCalendarFormat2;
17257
- hooks2.prototype = proto2;
17258
- hooks2.HTML5_FMT = {
17259
- DATETIME_LOCAL: "YYYY-MM-DDTHH:mm",
17260
- // <input type="datetime-local" />
17261
- DATETIME_LOCAL_SECONDS: "YYYY-MM-DDTHH:mm:ss",
17262
- // <input type="datetime-local" step="1" />
17263
- DATETIME_LOCAL_MS: "YYYY-MM-DDTHH:mm:ss.SSS",
17264
- // <input type="datetime-local" step="0.001" />
17265
- DATE: "YYYY-MM-DD",
17266
- // <input type="date" />
17267
- TIME: "HH:mm",
17268
- // <input type="time" />
17269
- TIME_SECONDS: "HH:mm:ss",
17270
- // <input type="time" step="1" />
17271
- TIME_MS: "HH:mm:ss.SSS",
17272
- // <input type="time" step="0.001" />
17273
- WEEK: "GGGG-[W]WW",
17274
- // <input type="week" />
17275
- MONTH: "YYYY-MM"
17276
- // <input type="month" />
17277
- };
17278
- return hooks2;
17279
- });
17280
- })(moment$1);
17281
- return moment$1.exports;
17282
- }
17283
- var fr = fr$1.exports;
17284
- var hasRequiredFr;
17285
- function requireFr() {
17286
- if (hasRequiredFr) return fr$1.exports;
17287
- hasRequiredFr = 1;
17288
- (function(module2, exports) {
17289
- (function(global2, factory2) {
17290
- typeof commonjsRequire === "function" ? factory2(requireMoment()) : factory2(global2.moment);
17291
- })(fr, function(moment2) {
17292
- //! moment.js locale configuration
17293
- var monthsStrictRegex = /^(janvier|février|mars|avril|mai|juin|juillet|août|septembre|octobre|novembre|décembre)/i, monthsShortStrictRegex = /(janv\.?|févr\.?|mars|avr\.?|mai|juin|juil\.?|août|sept\.?|oct\.?|nov\.?|déc\.?)/i, monthsRegex2 = /(janv\.?|févr\.?|mars|avr\.?|mai|juin|juil\.?|août|sept\.?|oct\.?|nov\.?|déc\.?|janvier|février|mars|avril|mai|juin|juillet|août|septembre|octobre|novembre|décembre)/i, monthsParse = [
17294
- /^janv/i,
17295
- /^févr/i,
17296
- /^mars/i,
17297
- /^avr/i,
17298
- /^mai/i,
17299
- /^juin/i,
17300
- /^juil/i,
17301
- /^août/i,
17302
- /^sept/i,
17303
- /^oct/i,
17304
- /^nov/i,
17305
- /^déc/i
17306
- ];
17307
- var fr2 = moment2.defineLocale("fr", {
17308
- months: "janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre".split(
17309
- "_"
17310
- ),
17311
- monthsShort: "janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.".split(
17312
- "_"
17313
- ),
17314
- monthsRegex: monthsRegex2,
17315
- monthsShortRegex: monthsRegex2,
17316
- monthsStrictRegex,
17317
- monthsShortStrictRegex,
17318
- monthsParse,
17319
- longMonthsParse: monthsParse,
17320
- shortMonthsParse: monthsParse,
17321
- weekdays: "dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"),
17322
- weekdaysShort: "dim._lun._mar._mer._jeu._ven._sam.".split("_"),
17323
- weekdaysMin: "di_lu_ma_me_je_ve_sa".split("_"),
17324
- weekdaysParseExact: true,
17325
- longDateFormat: {
17326
- LT: "HH:mm",
17327
- LTS: "HH:mm:ss",
17328
- L: "DD/MM/YYYY",
17329
- LL: "D MMMM YYYY",
17330
- LLL: "D MMMM YYYY HH:mm",
17331
- LLLL: "dddd D MMMM YYYY HH:mm"
17332
- },
17333
- calendar: {
17334
- sameDay: "[Aujourd’hui à] LT",
17335
- nextDay: "[Demain à] LT",
17336
- nextWeek: "dddd [à] LT",
17337
- lastDay: "[Hier à] LT",
17338
- lastWeek: "dddd [dernier à] LT",
17339
- sameElse: "L"
17340
- },
17341
- relativeTime: {
17342
- future: "dans %s",
17343
- past: "il y a %s",
17344
- s: "quelques secondes",
17345
- ss: "%d secondes",
17346
- m: "une minute",
17347
- mm: "%d minutes",
17348
- h: "une heure",
17349
- hh: "%d heures",
17350
- d: "un jour",
17351
- dd: "%d jours",
17352
- w: "une semaine",
17353
- ww: "%d semaines",
17354
- M: "un mois",
17355
- MM: "%d mois",
17356
- y: "un an",
17357
- yy: "%d ans"
17358
- },
17359
- dayOfMonthOrdinalParse: /\d{1,2}(er|)/,
17360
- ordinal: function(number, period) {
17361
- switch (period) {
17362
- // TODO: Return 'e' when day of month > 1. Move this case inside
17363
- // block for masculine words below.
17364
- // See https://github.com/moment/moment/issues/3375
17365
- case "D":
17366
- return number + (number === 1 ? "er" : "");
17367
- // Words with masculine grammatical gender: mois, trimestre, jour
17368
- default:
17369
- case "M":
17370
- case "Q":
17371
- case "DDD":
17372
- case "d":
17373
- return number + (number === 1 ? "er" : "e");
17374
- // Words with feminine grammatical gender: semaine
17375
- case "w":
17376
- case "W":
17377
- return number + (number === 1 ? "re" : "e");
17378
- }
17379
- },
17380
- week: {
17381
- dow: 1,
17382
- // Monday is the first day of the week.
17383
- doy: 4
17384
- // The week that contains Jan 4th is the first week of the year.
17385
- }
17386
- });
17387
- return fr2;
17388
- });
17389
- })();
17390
- return fr$1.exports;
17391
- }
17392
- requireFr();
17393
13275
  function removeTrailingSlash(path) {
17394
13276
  if (path.length > 1 && path.charAt(path.length - 1) === "/") {
17395
13277
  return path.substring(0, path.length - 1);