OCA_Backend/api/node_modules/moment-timezone/builds/moment-timezone-with-data-10-year-range.min.js

1 line
42 KiB
JavaScript
Raw Normal View History

2022-01-22 13:36:44 +00:00
!function(a,i){"use strict";"object"==typeof module&&module.exports?module.exports=i(require("moment")):"function"==typeof define&&define.amd?define(["moment"],i):i(a.moment)}(this,function(c){"use strict";void 0===c.version&&c.default&&(c=c.default);var i,A={},n={},t={},s={},u={};c&&"string"==typeof c.version||y("Moment Timezone requires Moment.js. See https://momentjs.com/timezone/docs/#/use-it/browser/");var a=c.version.split("."),e=+a[0],r=+a[1];function m(a){return 96<a?a-87:64<a?a-29:a-48}function o(a){var i=0,e=a.split("."),r=e[0],o=e[1]||"",c=1,A=0,n=1;for(45===a.charCodeAt(0)&&(n=-(i=1));i<r.length;i++)A=60*A+m(r.charCodeAt(i));for(i=0;i<o.length;i++)c/=60,A+=m(o.charCodeAt(i))*c;return A*n}function f(a){for(var i=0;i<a.length;i++)a[i]=o(a[i])}function l(a,i){var e,r=[];for(e=0;e<i.length;e++)r[e]=a[i[e]];return r}function p(a){var i=a.split("|"),e=i[2].split(" "),r=i[3].split(""),o=i[4].split(" ");return f(e),f(r),f(o),function(a,i){for(var e=0;e<i;e++)a[e]=Math.round((a[e-1]||0)+6e4*a[e]);a[i-1]=1/0}(o,r.length),{name:i[0],abbrs:l(i[1].split(" "),r),offsets:l(e,r),untils:o,population:0|i[5]}}function M(a){a&&this._set(p(a))}function b(a,i){this.name=a,this.zones=i}function d(a){var i=a.toTimeString(),e=i.match(/\([a-z ]+\)/i);"GMT"===(e=e&&e[0]?(e=e[0].match(/[A-Z]/g))?e.join(""):void 0:(e=i.match(/[A-Z]{3,5}/g))?e[0]:void 0)&&(e=void 0),this.at=+a,this.abbr=e,this.offset=a.getTimezoneOffset()}function h(a){this.zone=a,this.offsetScore=0,this.abbrScore=0}function g(a,i){for(var e,r;r=6e4*((i.at-a.at)/12e4|0);)(e=new d(new Date(a.at+r))).offset===a.offset?a=e:i=e;return a}function E(a,i){return a.offsetScore!==i.offsetScore?a.offsetScore-i.offsetScore:a.abbrScore!==i.abbrScore?a.abbrScore-i.abbrScore:a.zone.population!==i.zone.population?i.zone.population-a.zone.population:i.zone.name.localeCompare(a.zone.name)}function z(a,i){var e,r;for(f(i),e=0;e<i.length;e++)r=i[e],u[r]=u[r]||{},u[r][a]=!0}function P(){try{var a=Intl.DateTimeFormat().resolvedOptions().timeZone;if(a&&3<a.length){var i=s[S(a)];if(i)return i;y("Moment Timezone found "+a+" from the Intl api, but did not have that data loaded.")}}catch(a){}var e,r,o,c=function(){var a,i,e,r=(new Date).getFullYear()-2,o=new d(new Date(r,0,1)),c=[o];for(e=1;e<48;e++)(i=new d(new Date(r,e,1))).offset!==o.offset&&(a=g(o,i),c.push(a),c.push(new d(new Date(a.at+6e4)))),o=i;for(e=0;e<4;e++)c.push(new d(new Date(r+e,0,1))),c.push(new d(new Date(r+e,6,1)));return c}(),A=c.length,n=function(a){var i,e,r,o=a.length,c={},A=[];for(i=0;i<o;i++)for(e in r=u[a[i].offset]||{})r.hasOwnProperty(e)&&(c[e]=!0);for(i in c)c.hasOwnProperty(i)&&A.push(s[i]);return A}(c),t=[];for(r=0;r<n.length;r++){for(e=new h(_(n[r]),A),o=0;o<A;o++)e.scoreOffsetAt(c[o]);t.push(e)}return t.sort(E),0<t.length?t[0].zone.name:void 0}function S(a){return(a||"").toLowerCase().replace(/\//g,"_")}function T(a){var i,e,r,o;for("string"==typeof a&&(a=[a]),i=0;i<a.length;i++)o=S(e=(r=a[i].split("|"))[0]),A[o]=a[i],s[o]=e,z(o,r[2].split(" "))}function _(a,i){a=S(a);var e,r=A[a];return r instanceof M?r:"string"==typeof r?(r=new M(r),A[a]=r):n[a]&&i!==_&&(e=_(n[a],_))?((r=A[a]=new M)._set(e),r.name=s[a],r):null}function k(a){var i,e,r,o;for("string"==typeof a&&(a=[a]),i=0;i<a.length;i++)r=S((e=a[i].split("|"))[0]),o=S(e[1]),n[r]=o,s[r]=e[0],n[o]=r,s[o]=e[1]}function B(a){T(a.zones),k(a.links),function(a){var i,e,r,o;if(a&&a.length)for(i=0;i<a.length;i++)e=(o=a[i].split("|"))[0].toUpperCase(),r=o[1].split(" "),t[e]=new b(e,r)}(a.countries),O.dataVersion=a.version}function C(a){var i="X"===a._f||"x"===a._f;return!(!a._a||void 0!==a._tzm||i)}function y(a){"undefined"!=typeof console&&"function"==typeof console.error&&console.error(a)}function O(a){var i=Array.prototype.slice.call(arguments,0,-1),e=arguments[arguments.length-1],r=_(e),o=c.utc.apply(null,i);return r&&!c.isMoment(a)&&C(o)&&o.add(r.parse(o),"minutes"),o.tz(e),o}(e<2||2==e&&r<6)&&y("Moment Timezone requires Moment.js >= 2.6.0. You are using Moment.js "+c.version+". See momentjs.com"),M.prototype={_set:function(a){this.name=a.name,this.abbrs=a.abbrs,this.u