diff --git a/README.md b/README.md index 08470aa6a..5d54b3d46 100644 --- a/README.md +++ b/README.md @@ -482,6 +482,7 @@ _(all match methods use the [match-syntax](https://docs.compromise.cool/compromi - **[.verbs().toFutureTense()](https://observablehq.com/@spencermountain/verbs)** - `'walked' → 'will walk'` - **[.verbs().toInfinitive()](https://observablehq.com/@spencermountain/verbs)** - `'walks' → 'walk'` - **[.verbs().toGerund()](https://observablehq.com/@spencermountain/verbs)** - `'walks' → 'walking'` + - **[.verbs().toParticiple()](https://observablehq.com/@spencermountain/verbs)** - `'drive' → 'driven'` - otherwise simple-past ('walked') - **[.verbs().toNegative()](https://observablehq.com/@spencermountain/verbs)** - `'went' → 'did not go'` - **[.verbs().toPositive()](https://observablehq.com/@spencermountain/verbs)** - `"didn't study" → 'studied'` - **[.verbs().isNegative()](https://observablehq.com/@spencermountain/verbs)** - return verbs with 'not' diff --git a/bugs.js b/bugs.js new file mode 100644 index 000000000..006f4a492 --- /dev/null +++ b/bugs.js @@ -0,0 +1,40 @@ +// let doc = nlp('i am being driven') +// let doc = nlp('i should be driven') +// let doc = nlp('i should have been driven') +// doc.verbs().toParticiple() +// doc.verbs().toPastTense() +// doc.debug() +// console.log(doc.verbs(0).conjugate()) +// doc.sentences().toFutureTense().debug() + +// console.log(nlp('next week').dates().json()) +// nlp('you are John, Lisa, Fred').match('#FirstName{1,2}').debug() + +// let doc = nlp('i could study').debug() +// doc.verbs().toParticiple() +// doc.sentences().toPastTense() +// console.log(doc.text()) +// i thought he really could have. + +// let doc = nlp('i did really walk') +// doc.sentences().toPresentTense() +// console.log(doc.text()) + +// nlp('lowered according').debug() +// nlp('it bristles outwards, brushlike.').debug() +// nlp('red-shouldered').debug() +// nlp('age of it').debug() +// nlp('so well that').debug() +// nlp('is off-white').debug() +// nlp('polyunsaturated').debug() +// nlp('favoured treat').debug() + +/* + Snowboarding is a winter sport. [snowboarding = subject] + I love snowboarding. [snowboarding = object ] + I am excited by snowboarding. [snowboarding = object of a preposition] + One popular sport is snowboarding. [snowboarding = subject complement] + Right now, the athlete is snowboarding. [is snowboarding = present continuous] + He was snowboarding yesterday afternoon. [was snowboarding = past continuous] + Tomorrow, my friends and I are going to be snowboarding. [are going to be snowboarding = future +*/ diff --git a/builds/compromise-tokenize.js b/builds/compromise-tokenize.js index fcd203643..39c82cd01 100644 --- a/builds/compromise-tokenize.js +++ b/builds/compromise-tokenize.js @@ -1 +1 @@ -!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t="undefined"!=typeof globalThis?globalThis:t||self).nlp=e()}(this,(function(){"use strict";function t(e){return(t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(e)}function e(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function r(t,e){for(var r=0;rt.length)&&(e=t.length);for(var r=0,n=new Array(e);rn[e].lineage.length?1:n[t].isA.length>n[e].isA.length?-1:0:0:1}))},R={text:!0,tags:!0,implicit:!0,whitespace:!0,clean:!1,id:!1,index:!1,offset:!1,bestTag:!1},U={json:function(t,e){t=t||{};var r={};return(t=Object.assign({},R,t)).text&&(r.text=this.text),t.normal&&(r.normal=this.normal),t.tags&&(r.tags=Object.keys(this.tags)),t.clean&&(r.clean=this.clean),(t.id||t.offset)&&(r.id=this.id),t.implicit&&null!==this.implicit&&(r.implicit=this.implicit),t.whitespace&&(r.pre=this.pre,r.post=this.post),t.bestTag&&(r.bestTag=_(this,e)[0]),r}},H=Object.assign({},$,V,q,z,U);function G(){return"undefined"!=typeof window&&window.document}var Q=function(t,e){for(t=t.toString();t.length0&&void 0!==arguments[0]?arguments[0]:"";e(this,t),r=String(r);var n=T(r);this.text=n.text||"",this.clean=n.clean,this.reduced=n.reduced,this.root=null,this.implicit=null,this.pre=n.pre||"",this.post=n.post||"",this.tags={},this.prev=null,this.next=null,this.id=f(n.clean),this.isA="Term",n.alias&&(this.alias=n.alias)}return n(t,[{key:"set",value:function(t){var e=T(t);return this.text=e.text,this.clean=e.clean,this}}]),t}();ot.prototype.clone=function(){var t=new ot(this.text);return t.pre=this.pre,t.post=this.post,t.tags=Object.assign({},this.tags),t},Object.assign(ot.prototype,H),Object.assign(ot.prototype,it);var st=ot,at={terms:function(t){if(0===this.length)return[];if(this.cache.terms)return void 0!==t?this.cache.terms[t]:this.cache.terms;for(var e=[this.pool.get(this.start)],r=0;r0&&void 0!==arguments[0]?arguments[0]:{},e=arguments.length>1?arguments[1]:void 0,r=arguments.length>2?arguments[2]:void 0;"string"==typeof t&&(t="normal"===t?{whitespace:!0,unicode:!0,lowercase:!0,punctuation:!0,acronyms:!0,abbreviations:!0,implicit:!0,normal:!0}:"clean"===t?{titlecase:!1,lowercase:!0,punctuation:!0,whitespace:!0,unicode:!0,implicit:!0}:"reduced"===t?{titlecase:!1,lowercase:!0,punctuation:!1,whitespace:!0,unicode:!0,implicit:!0,reduced:!0}:"root"===t?{titlecase:!1,lowercase:!0,punctuation:!0,whitespace:!0,unicode:!0,implicit:!0,root:!0}:{});var n=this.terms(),i=!1;n[0]&&null===n[0].prev&&null===n[n.length-1].next&&(i=!0);var o=n.reduce((function(o,s,a){t.last=r&&a===n.length-1;var u=!0,c=!0;return!1===i&&(0===a&&e&&(u=!1),a===n.length-1&&r&&(c=!1)),o+s.textOut(t,u,c)}),"");return!0===i&&r&&(o=ut(o)),!0===t.trim&&(o=o.trim()),o}},ht={trim:function(){var t=this.terms();if(t.length>0){t[0].pre=t[0].pre.replace(/^\s+/,"");var e=t[t.length-1];e.post=e.post.replace(/\s+$/,"")}return this}},lt=/[.?!]\s*$/,ft=function(t,e){e[0].pre=t[0].pre;var r,n,i=t[t.length-1],o=e[e.length-1];o.post=(r=i.post,n=o.post,lt.test(n)?n+r.match(/\s*$/):r),i.post="",""===i.post&&(i.post+=" ")},pt=function(t,e,r){var n=t.terms(),i=e.terms();ft(n,i),function(t,e,r){var n=t[t.length-1],i=e[e.length-1],o=n.next;(n.next=e[0].id,i.next=o,o)&&(r.get(o).prev=i.id);var s=t[0].id;s&&(e[0].prev=s)}(n,i,t.pool);var o,s=[t],a=t.start,u=[r];return(u=u.concat(r.parents())).forEach((function(t){var e=t.list.filter((function(t){return t.hasId(a)}));s=s.concat(e)})),(s=(o=s).filter((function(t,e){return o.indexOf(t)===e}))).forEach((function(t){t.length+=e.length})),t.cache={},t},dt=/ /,vt=function(t,e,r){var n=t.start,i=e.terms();!function(t){var e=t[t.length-1];!1===dt.test(e.post)&&(e.post+=" ")}(i),function(t,e,r){var n=r[r.length-1];n.next=t.start;var i=t.pool,o=i.get(t.start);o.prev&&(i.get(o.prev).next=e.start);r[0].prev=t.terms(0).prev,t.terms(0).prev=n.id}(t,e,i);var o,s=[t],a=[r];return(a=a.concat(r.parents())).forEach((function(t){var r=t.list.filter((function(t){return t.hasId(n)||t.hasId(e.start)}));s=s.concat(r)})),(s=(o=s).filter((function(t,e){return o.indexOf(t)===e}))).forEach((function(t){t.length+=e.length,t.start===n&&(t.start=e.start),t.cache={}})),t},mt=function(t,e){var r=e.pool(),n=t.terms(),i=r.get(n[0].prev)||{},o=r.get(n[n.length-1].next)||{};n[0].implicit&&i.implicit&&(i.set(i.implicit),i.post+=" "),function(t,e,r,n){var i=t.parents();i.push(t),i.forEach((function(t){var i=t.list.find((function(t){return t.hasId(e)}));i&&(i.length-=r,i.start===e&&(i.start=n.id),i.cache={})})),t.list=t.list.filter((function(t){return!(!t.start||!t.length)}))}(e,t.start,t.length,o),i&&(i.next=o.id),o&&(o.prev=i.id)},gt={append:function(t,e){return pt(this,t,e),this},prepend:function(t,e){return vt(this,t,e),this},delete:function(t){return mt(this,t),this},replace:function(t,e){var r=this.length;pt(this,t,e);var n=this.buildFrom(this.start,this.length);n.length=r,mt(n,e)},splitOn:function(t){var e=this.terms(),r={before:null,match:null,after:null},n=e.findIndex((function(e){return e.id===t.start}));if(-1===n)return r;var i=e.slice(0,n);i.length>0&&(r.before=this.buildFrom(i[0].id,i.length));var o=e.slice(n,n+t.length);o.length>0&&(r.match=this.buildFrom(o[0].id,o.length));var s=e.slice(n+t.length,e.length);return s.length>0&&(r.after=this.buildFrom(s[0].id,s.length,this.pool)),r}},bt={json:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=arguments.length>1?arguments[1]:void 0,r={};return t.text&&(r.text=this.text()),t.normal&&(r.normal=this.text("normal")),t.clean&&(r.clean=this.text("clean")),t.reduced&&(r.reduced=this.text("reduced")),t.root&&(r.root=this.text("root")),t.trim&&(r.text&&(r.text=r.text.trim()),r.normal&&(r.normal=r.normal.trim()),r.reduced&&(r.reduced=r.reduced.trim())),t.terms&&(!0===t.terms&&(t.terms={}),r.terms=this.terms().map((function(r){return r.json(t.terms,e)}))),r}},yt={lookAhead:function(t){t||(t=".*");var e=this.pool,r=[],n=this.terms();return function t(n){var i=e.get(n);i&&(r.push(i),i.prev&&t(i.next))}(n[n.length-1].next),0===r.length?[]:this.buildFrom(r[0].id,r.length).match(t)},lookBehind:function(t){t||(t=".*");var e=this.pool,r=[];return function t(n){var i=e.get(n);i&&(r.push(i),i.prev&&t(i.prev))}(e.get(this.start).prev),0===r.length?[]:this.buildFrom(r[r.length-1].id,r.length).match(t)}},At=Object.assign({},at,ct,ht,gt,bt,yt),wt=function(t,e){if(0===e.length)return!0;for(var r=0;r0)return!0;if(!0===n.anything&&!0===n.negative)return!0}return!1},xt=function(t,e,r,n,i,o){for(var s=e;es)return[!1,null];if(!0===u.end&&r+s!==n)return[!1,null]}if(c){var d=Pt(i,h,t,p,u.named);s>1&&u.greedy?d.length+=s-p:d.length++}}else if(!0!==u.optional){if(!(t[s].isImplicit()&&e[a-1]&&t[s+1]&&t[s+1].doesMatch(u,r+s,n)))return[!1,null];s+=2}}else{var v=jt(t,s,e[a+1],u,r);if(void 0!==u.min&&v-su.max){s+=u.max;continue}if(null===v)return[!1,null];c&&(Pt(i,h,t,s,u.named).length=v-s),s=v}}return[t.slice(0,s),i]},Ot=function(t,e,r){if(!r||0===r.length)return r;if(e.some((function(t){return t.end}))){var n=t[t.length-1];r=r.filter((function(t){return-1!==t.match.indexOf(n)}))}return r},Ct=/\{([0-9]+,?[0-9]*)\}/,kt=/&&/,Ft=new RegExp(/^<(\S+)>/),Tt=function(t){return t[t.length-1]},Nt=function(t){return t[0]},$t=function(t){return t.substr(1)},Vt=function(t){return t.substr(0,t.length-1)},St=function(t){return t=$t(t),t=Vt(t)},Bt=function t(e){for(var r,n={},i=0;i<2;i+=1){if("$"===Tt(e)&&(n.end=!0,e=Vt(e)),"^"===Nt(e)&&(n.start=!0,e=$t(e)),("["===Nt(e)||"]"===Tt(e))&&(n.named=!0,"["===Nt(e)?n.groupType="]"===Tt(e)?"single":"start":n.groupType="end",e=(e=e.replace(/^\[/,"")).replace(/\]$/,""),"<"===Nt(e))){var o=Ft.exec(e);o.length>=2&&(n.named=o[1],e=e.replace(o[0],""))}if("+"===Tt(e)&&(n.greedy=!0,e=Vt(e)),"*"!==e&&"*"===Tt(e)&&"\\*"!==e&&(n.greedy=!0,e=Vt(e)),"?"===Tt(e)&&(n.optional=!0,e=Vt(e)),"!"===Nt(e)&&(n.negative=!0,e=$t(e)),"("===Nt(e)&&")"===Tt(e)){kt.test(e)?(n.choices=e.split(kt),n.operator="and"):(n.choices=e.split("|"),n.operator="or"),n.choices[0]=$t(n.choices[0]);var s=n.choices.length-1;n.choices[s]=Vt(n.choices[s]),n.choices=n.choices.map((function(t){return t.trim()})),n.choices=n.choices.filter((function(t){return t})),n.choices=n.choices.map(t),e=""}if("/"===Nt(e)&&"/"===Tt(e))return e=St(e),n.regex=new RegExp(e),n;if("~"===Nt(e)&&"~"===Tt(e))return e=St(e),n.soft=!0,n.word=e,n}return!0===Ct.test(e)&&(e=e.replace(Ct,(function(t,e){var r=e.split(/,/g);return 1===r.length?(n.min=Number(r[0]),n.max=Number(r[0])):(n.min=Number(r[0]),n.max=Number(r[1]||999)),n.greedy=!0,""}))),"#"===Nt(e)?(n.tag=$t(e),n.tag=(r=n.tag).charAt(0).toUpperCase()+r.substr(1),n):"@"===Nt(e)?(n.method=$t(e),n):"."===e?(n.anything=!0,n):"*"===e?(n.anything=!0,n.greedy=!0,n.optional=!0,n):(e&&(e=(e=e.replace("\\*","*")).replace("\\.","."),n.word=e.toLowerCase()),n)},It=function(t){return t.filter((function(t){return t.groupType})).length>0&&(t=function(t){for(var e,r,n=!1,i=-1,o=0;o)?\(.*?\)[?+*]*\]?\$?)/);return e=e.map((function(t){return t.trim()}))}(e);return r=(r=function(t){var e=[];return t.forEach((function(t){if(/^[[^_/]?\(/.test(t[0]))e.push(t);else{var r=t.split(" ");r=r.filter((function(t){return t})),e=e.concat(r)}})),e}(r)).map(Bt),r=It(r)},qt=function(t,e){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if("string"==typeof e&&(e=Dt(e)),!0===wt(t,e))return[];var n=e.filter((function(t){return!0!==t.optional})).length,i=t.terms(),o=[];if(!0===e[0].start){var s=Et(i,e,0,i.length),a=c(s,2),u=a[0],h=a[1];return!1!==u&&u.length>0&&(u=u.filter((function(t){return t})),o.push({match:u,groups:h})),Ot(i,e,o)}for(var l=0;li.length);l+=1){var f=Et(i.slice(l),e,l,i.length),p=c(f,2),d=p[0],v=p[1];if(!1!==d&&d.length>0&&(l+=d.length-1,d=d.filter((function(t){return t})),o.push({match:d,groups:v}),!0===r))return Ot(i,e,o)}return Ot(i,e,o)},Mt=function(t,e){var r={};qt(t,e).forEach((function(t){t.match.forEach((function(t){r[t.id]=!0}))}));var n=t.terms(),i=[],o=[];return n.forEach((function(t){!0!==r[t.id]?o.push(t):o.length>0&&(i.push(o),o=[])})),o.length>0&&i.push(o),i},Lt={match:function(t){var e=this,r=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=qt(this,t,r);return n=n.map((function(t){var r=t.match,n=t.groups,i=e.buildFrom(r[0].id,r.length,n);return i.cache.terms=r,i}))},has:function(t){return qt(this,t,!0).length>0},not:function(t){var e=this,r=Mt(this,t);return r=r.map((function(t){return e.buildFrom(t[0].id,t.length)}))},canBe:function(t,e){for(var r=this,n=[],i=this.terms(),o=!1,s=0;s0})).map((function(t){return r.buildFrom(t[0].id,t.length)}))}},zt=function t(r,n,i){e(this,t),this.start=r,this.length=n,this.isA="Phrase",Object.defineProperty(this,"pool",{enumerable:!1,writable:!0,value:i}),Object.defineProperty(this,"cache",{enumerable:!1,writable:!0,value:{}}),Object.defineProperty(this,"groups",{enumerable:!1,writable:!0,value:{}})};zt.prototype.buildFrom=function(t,e,r){var n=new zt(t,e,this.pool);return r&&Object.keys(r).length>0?n.groups=r:n.groups=this.groups,n},Object.assign(zt.prototype,Lt),Object.assign(zt.prototype,At);var Wt={term:"terms"};Object.keys(Wt).forEach((function(t){return zt.prototype[t]=zt.prototype[Wt[t]]}));var _t=zt,Rt=function(){function t(){var r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};e(this,t),Object.defineProperty(this,"words",{enumerable:!1,value:r})}return n(t,[{key:"add",value:function(t){return this.words[t.id]=t,this}},{key:"get",value:function(t){return this.words[t]}},{key:"remove",value:function(t){delete this.words[t]}},{key:"merge",value:function(t){return Object.assign(this.words,t.words),this}},{key:"stats",value:function(){return{words:Object.keys(this.words).length}}}]),t}();Rt.prototype.clone=function(){var t=this,e=Object.keys(this.words).reduce((function(e,r){var n=t.words[r].clone();return e[n.id]=n,e}),{});return new Rt(e)};var Ut=Rt,Ht=function(t){t.forEach((function(e,r){r>0&&(e.prev=t[r-1].id),t[r+1]&&(e.next=t[r+1].id)}))},Gt=/(\S.+?[.!?\u203D\u2E18\u203C\u2047-\u2049])(?=\s+|$)/g,Qt=/\S/,Zt=/[ .][A-Z]\.? *$/i,Jt=/(?:\u2026|\.{2,}) *$/,Yt=/((?:\r?\n|\r)+)/,Kt=/[a-z0-9\u00C0-\u00FF\u00a9|\u00ae|[\u2000-\u3300]|\ud83c[\ud000-\udfff]|\ud83d[\ud000-\udfff]|\ud83e[\ud000-\udfff]/i,Xt=/^\s+/,te=function(t,e){if(!0===Zt.test(t))return!1;if(!0===Jt.test(t))return!1;if(!1===Kt.test(t))return!1;var r=t.replace(/[.!?\u203D\u2E18\u203C\u2047-\u2049] *$/,"").split(" "),n=r[r.length-1].toLowerCase();return!e.hasOwnProperty(n)},ee=function(t,e){var r=e.cache.abbreviations;t=t||"";var n=[],i=[];if(!(t=String(t))||"string"!=typeof t||!1===Qt.test(t))return n;for(var o=function(t){for(var e=[],r=t.split(Yt),n=0;n0&&(n.push(c),i[u]="")}if(0===n.length)return[t];for(var h=1;h0?(e[e.length-1]+=o,e.push(a)):e.push(o+a),o=""):o+=a}return o&&(0===e.length&&(e[0]=""),e[e.length-1]+=o),e=(e=function(t){for(var e=1;e0&&void 0!==arguments[0]?arguments[0]:"",e=arguments.length>1?arguments[1]:void 0,r=arguments.length>2?arguments[2]:void 0,n=null;"string"!=typeof t&&("number"==typeof t?t=String(t):he(t)&&(n=t)),n=(n=n||ee(t,e)).map((function(t){return ce(t)})),r=r||new Ut;var i=n.map((function(t){t=t.map((function(t){var e=new st(t);return r.add(e),e})),Ht(t);var e=new _t(t[0].id,t.length,r);return e.cache.terms=t,e}));return i},fe=function(t,e){var r=new Ut;return t.map((function(t,n){var i=t.terms.map((function(i,o){var s=new st(i.text);return s.pre=void 0!==i.pre?i.pre:"",void 0===i.post&&(i.post=" ",o>=t.terms.length-1&&(i.post=". ",n>=t.terms.length-1&&(i.post="."))),s.post=void 0!==i.post?i.post:" ",i.tags&&i.tags.forEach((function(t){return s.tag(t,"",e)})),r.add(s),s}));return Ht(i),new _t(i[0].id,i.length,r)}))},pe={},de=["Person","Place","Organization"],ve={Noun:{notA:["Verb","Adjective","Adverb"]},Singular:{isA:"Noun",notA:"Plural"},ProperNoun:{isA:"Noun"},Person:{isA:["ProperNoun","Singular"],notA:["Place","Organization","Date"]},FirstName:{isA:"Person"},MaleName:{isA:"FirstName",notA:["FemaleName","LastName"]},FemaleName:{isA:"FirstName",notA:["MaleName","LastName"]},LastName:{isA:"Person",notA:["FirstName"]},NickName:{isA:"Person",notA:["FirstName","LastName"]},Honorific:{isA:"Noun",notA:["FirstName","LastName","Value"]},Place:{isA:"Singular",notA:["Person","Organization"]},Country:{isA:["Place","ProperNoun"],notA:["City"]},City:{isA:["Place","ProperNoun"],notA:["Country"]},Region:{isA:["Place","ProperNoun"]},Address:{isA:"Place"},Organization:{isA:["Singular","ProperNoun"],notA:["Person","Place"]},SportsTeam:{isA:"Organization"},School:{isA:"Organization"},Company:{isA:"Organization"},Plural:{isA:"Noun",notA:["Singular"]},Uncountable:{isA:"Noun"},Pronoun:{isA:"Noun",notA:de},Actor:{isA:"Noun",notA:de},Activity:{isA:"Noun",notA:["Person","Place"]},Unit:{isA:"Noun",notA:de},Demonym:{isA:["Noun","ProperNoun"],notA:de},Possessive:{isA:"Noun"}},me={Verb:{notA:["Noun","Adjective","Adverb","Value"]},PresentTense:{isA:"Verb",notA:["PastTense","Copula","FutureTense"]},Infinitive:{isA:"PresentTense",notA:["PastTense","Gerund"]},Gerund:{isA:"PresentTense",notA:["PastTense","Copula","FutureTense"]},PastTense:{isA:"Verb",notA:["FutureTense"]},FutureTense:{isA:"Verb"},Copula:{isA:"Verb"},Modal:{isA:"Verb",notA:["Infinitive"]},PerfectTense:{isA:"Verb",notA:"Gerund"},Pluperfect:{isA:"Verb"},Participle:{isA:"Verb"},PhrasalVerb:{isA:"Verb"},Particle:{isA:"PhrasalVerb"}},ge={Value:{notA:["Verb","Adjective","Adverb"]},Ordinal:{isA:"Value",notA:["Cardinal"]},Cardinal:{isA:"Value",notA:["Ordinal"]},RomanNumeral:{isA:"Cardinal",notA:["Ordinal","TextValue"]},TextValue:{isA:"Value",notA:["NumericValue"]},NumericValue:{isA:"Value",notA:["TextValue"]},Money:{isA:"Cardinal"},Percent:{isA:"Value"}},be=["Noun","Verb","Adjective","Adverb","Value","QuestionWord"],ye={Adjective:{notA:["Noun","Verb","Adverb","Value"]},Comparable:{isA:["Adjective"]},Comparative:{isA:["Adjective"]},Superlative:{isA:["Adjective"],notA:["Comparative"]},NumberRange:{isA:["Contraction"]},Adverb:{notA:["Noun","Verb","Adjective","Value"]},Date:{notA:["Verb","Conjunction","Adverb","Preposition","Adjective"]},Month:{isA:["Date","Singular"],notA:["Year","WeekDay","Time"]},WeekDay:{isA:["Date","Noun"]},Time:{isA:["Date"],notA:["Value"]},Determiner:{notA:be},Conjunction:{notA:be},Preposition:{notA:be},QuestionWord:{notA:["Determiner"]},Currency:{},Expression:{notA:["Noun","Adjective","Verb","Adverb"]},Abbreviation:{},Url:{notA:["HashTag","PhoneNumber","Verb","Adjective","Value","AtMention","Email"]},PhoneNumber:{notA:["HashTag","Verb","Adjective","Value","AtMention","Email"]},HashTag:{},AtMention:{isA:["Noun"],notA:["HashTag","Verb","Adjective","Value","Email"]},Emoji:{notA:["HashTag","Verb","Adjective","Value","AtMention"]},Emoticon:{notA:["HashTag","Verb","Adjective","Value","AtMention"]},Email:{notA:["HashTag","Verb","Adjective","Value","AtMention"]},Auxiliary:{notA:["Noun","Adjective","Value"]},Acronym:{notA:["Plural","RomanNumeral"]},Negative:{notA:["Noun","Adjective","Value"]},Condition:{notA:["Verb","Adjective","Noun","Value"]}},Ae={Noun:"blue",Verb:"green",Negative:"green",Date:"red",Value:"red",Adjective:"magenta",Preposition:"cyan",Conjunction:"cyan",Determiner:"cyan",Adverb:"cyan"},we=function(t){return Object.keys(t).forEach((function(e){t[e].color?t[e].color=t[e].color:Ae[e]?t[e].color=Ae[e]:t[e].isA.some((function(r){return!!Ae[r]&&(t[e].color=Ae[r],!0)}))})),t},xe=function(t){return Object.keys(t).forEach((function(e){for(var r=t[e],n=r.isA.length,i=0;i1&&(r.hasCompound[o[0]]=!0),"Singular"===e){var s=i.toPlural(t,r);n[s]=n[s]||"Plural"}if("Infinitive"===e)for(var a=i.conjugate(t,r),u=Object.keys(a),c=0;c1?i[o]&&"."!==i[o]&&r.tag(i[o],n,e.world):r.tag(t,n,e.world)}))}))},Re={tag:function(t,e){return t?(_e(t,this,!1,e),this):this},tagSafe:function(t,e){return t?(_e(t,this,!0,e),this):this},unTag:function(t,e){var r=this;return this.list.forEach((function(n){n.terms().forEach((function(n){return n.unTag(t,e,r.world)}))})),this},canBe:function(t){if(!t)return this;var e=this.world,r=this.list.reduce((function(r,n){return r.concat(n.canBe(t,e))}),[]);return this.buildFrom(r)}},Ue={map:function(e){var r=this;if(!e)return this;var n=this.list.map((function(t,n){var i=r.buildFrom([t]);i.from=null;var o=e(i,n);return o&&o.list&&o.list[0]?o.list[0]:o}));return 0===(n=n.filter((function(t){return t}))).length?this.buildFrom(n):"object"!==t(n[0])||"Phrase"!==n[0].isA?n:this.buildFrom(n)},forEach:function(t,e){var r=this;return t?(this.list.forEach((function(n,i){var o=r.buildFrom([n]);!0===e&&(o.from=null),t(o,i)})),this):this},filter:function(t){var e=this;if(!t)return this;var r=this.list.filter((function(r,n){var i=e.buildFrom([r]);return i.from=null,t(i,n)}));return this.buildFrom(r)},find:function(t){var e=this;if(!t)return this;var r=this.list.find((function(r,n){var i=e.buildFrom([r]);return i.from=null,t(i,n)}));return r?this.buildFrom([r]):void 0},some:function(t){var e=this;return t?this.list.some((function(r,n){var i=e.buildFrom([r]);return i.from=null,t(i,n)})):this},random:function(t){if(!this.found)return this;var e=Math.floor(Math.random()*this.list.length);if(void 0===t){var r=[this.list[e]];return this.buildFrom(r)}return e+t>this.length&&(e=(e=this.length-t)<0?0:e),this.slice(e,e+t)}},He=function(t){return t.split(/[ -]/g)},Ge=function(t,e,r){for(var n=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],r={};return t.forEach((function(t,n){var i=!0;void 0!==e[n]&&(i=e[n]),t=(t=(t||"").toLowerCase()).replace(/[,;.!?]+$/,"");var o=He(t).map((function(t){return t.trim()}));r[o[0]]=r[o[0]]||{},1===o.length?r[o[0]].value=i:(r[o[0]].more=r[o[0]].more||[],r[o[0]].more.push({rest:o.slice(1),value:i}))})),r}(t,e),i=[],o=function(t){for(var e=r.list[t],o=e.terms().map((function(t){return t.reduced})),s=function(t){void 0!==n[o[t]]&&(void 0!==n[o[t]].more&&n[o[t]].more.forEach((function(r){void 0!==o[t+r.rest.length]&&(!0===r.rest.every((function(e,r){return e===o[t+r+1]}))&&i.push({id:e.terms()[t].id,value:r.value,length:r.rest.length+1}))})),void 0!==n[o[t]].value&&i.push({id:e.terms()[t].id,value:n[o[t]].value,length:1}))},a=0;a1&&void 0!==arguments[1]?arguments[1]:{};return e?(!0===n&&(n={keepTags:!0}),!1===n&&(n={keepTags:!1}),n=n||{},this.uncache(),this.list.forEach((function(i){var o,s=e;if("function"==typeof e&&(s=e(i)),s&&"object"===t(s)&&"Doc"===s.isA)o=s.list,r.pool().merge(s.pool());else{if("string"!=typeof s)return;!1!==n.keepCase&&i.terms(0).isTitleCase()&&(s=Je(s)),o=le(s,r.world,r.pool());var a=r.buildFrom(o);a.tagger(),o=a.list}if(!0===n.keepTags){var u=i.json({terms:{tags:!0}}).terms;o[0].terms().forEach((function(t,e){u[e]&&t.tagSafe(u[e].tags,"keptTag",r.world)}))}i.replace(o[0],r)})),this):this.delete()},replace:function(t,e,r){return void 0===e?this.replaceWith(t,r):(this.match(t).replaceWith(e,r),this)}},Ke=N((function(t,e){e.append=function(t){var e=this;return t?(this.uncache(),this.list.forEach((function(r){var n=le(t,e.world,e.pool())[0];e.buildFrom([n]).tagger(),r.append(n,e)})),this):this},e.insertAfter=e.append,e.insertAt=e.append,e.prepend=function(t){var e=this;return t?(this.uncache(),this.list.forEach((function(r){var n=le(t,e.world,e.pool())[0];e.buildFrom([n]).tagger(),r.prepend(n,e)})),this):this},e.insertBefore=e.prepend,e.concat=function(){this.uncache();for(var t=this.list.slice(0),e=0;e0&&void 0!==arguments[0]?arguments[0]:{};if("number"==typeof e&&this.list[e])return this.list[e].json(r);!0===(e=n(e)).root&&this.list.forEach((function(e){e.terms().forEach((function(e){null===e.root&&e.setRoot(t.world)}))}));var i=this.list.map((function(r){return r.json(e,t.world)}));if((e.terms.offset||e.offset||e.terms.index||e.index)&&er(this,i,e),e.frequency||e.freq||e.count){var o={};this.list.forEach((function(t){var e=t.text("reduced");o[e]=o[e]||0,o[e]+=1})),this.list.forEach((function(t,e){i[e].count=o[t.text("reduced")]}))}if(e.unique){var s={};i=i.filter((function(t){return!0!==s[t.reduced]&&(s[t.reduced]=!0,!0)}))}return i},e.data=e.json})),nr=N((function(t){var e=function(t,e){for(t=t.toString();t.lengthe.count?-1:t.countn?1:0},length:function(t,e){var r=t.text().trim().length,n=e.text().trim().length;return rn?-1:0},wordCount:function(t,e){var r=t.wordCount(),n=e.wordCount();return rn?-1:0}};sr.alphabetical=sr.alpha,sr.wordcount=sr.wordCount;var ar={index:!0,sequence:!0,seq:!0,sequential:!0,chron:!0,chronological:!0},ur={sort:function(t){return"freq"===(t=t||"alpha")||"frequency"===t||"topk"===t?(r={},n={case:!0,punctuation:!1,whitespace:!0,unicode:!0},(e=this).list.forEach((function(t){var e=t.text(n);r[e]=r[e]||0,r[e]+=1})),e.list.sort((function(t,e){var i=r[t.text(n)],o=r[e.text(n)];return io?-1:0})),e):ar.hasOwnProperty(t)?function(t){var e={};return t.json({terms:{offset:!0}}).forEach((function(t){e[t.terms[0].id]=t.terms[0].offset.start})),t.list=t.list.sort((function(t,r){return e[t.start]>e[r.start]?1:e[t.start]0){i+=s;continue}}if(void 0===r[o]||!0!==r.hasOwnProperty(o))if(o===t[i].reduced||!0!==r.hasOwnProperty(t[i].reduced)){if(!0===Or.test(o)){var a=o.replace(Or,"");!0===r.hasOwnProperty(a)&&t[i].tag(r[a],"noprefix-lexicon",e)}}else t[i].tag(r[t[i].reduced],"lexicon",e);else t[i].tag(r[o],"lexicon",e)}return t},Fr=function(t){var e=t.termList();return kr(e,t.world),t},Tr=function(t){var r=function(t){i(o,t);var r=u(o);function o(){return e(this,o),r.apply(this,arguments)}return n(o,[{key:"stripPeriods",value:function(){return this.termList().forEach((function(t){!0===t.tags.Abbreviation&&t.next&&(t.post=t.post.replace(/^\./,""));var e=t.text.replace(/\./,"");t.set(e)})),this}},{key:"addPeriods",value:function(){return this.termList().forEach((function(t){t.post=t.post.replace(/^\./,""),t.post="."+t.post})),this}}]),o}(t);return r.prototype.unwrap=r.prototype.stripPeriods,t.prototype.abbreviations=function(t){var e=this.match("#Abbreviation");return"number"==typeof t&&(e=e.get(t)),new r(e.list,this,this.world)},t},Nr=/\./,$r=function(t){var r=function(t){i(o,t);var r=u(o);function o(){return e(this,o),r.apply(this,arguments)}return n(o,[{key:"stripPeriods",value:function(){return this.termList().forEach((function(t){var e=t.text.replace(/\./g,"");t.set(e)})),this}},{key:"addPeriods",value:function(){return this.termList().forEach((function(t){var e=t.text.replace(/\./g,"");e=e.split("").join("."),!1===Nr.test(t.post)&&(e+="."),t.set(e)})),this}}]),o}(t);return r.prototype.unwrap=r.prototype.stripPeriods,r.prototype.strip=r.prototype.stripPeriods,t.prototype.acronyms=function(t){var e=this.match("#Acronym");return"number"==typeof t&&(e=e.get(t)),new r(e.list,this,this.world)},t},Vr=function(t){return t.prototype.clauses=function(e){var r=this.if("@hasComma").notIf("@hasComma @hasComma").notIf("@hasComma . .? (and|or) .").notIf("(#City && @hasComma) #Country").notIf("(#Date && @hasComma) #Year").notIf("@hasComma (too|also)$").match("@hasComma"),n=this.splitAfter(r),i=n.quotations(),o=(n=n.splitOn(i)).parentheses(),s=(n=n.splitOn(o)).if("#Copula #Adjective #Conjunction (#Pronoun|#Determiner) #Verb").match("#Conjunction"),a=(n=n.splitBefore(s)).if("if .{2,9} then .").match("then"),u=(n=(n=(n=(n=(n=(n=n.splitBefore(a)).splitBefore("as well as .")).splitBefore("such as .")).splitBefore("in addition to .")).splitAfter("@hasSemicolon")).splitAfter("@hasDash")).filter((function(t){return t.wordCount()>5&&t.match("#Verb+").length>=2}));if(u.found){var c=u.splitAfter("#Noun .* #Verb .* #Noun+");n=n.splitOn(c.eq(0))}return"number"==typeof e&&(n=n.get(e)),new t(n.list,this,this.world)},t},Sr=function(t){var r=function(t){i(o,t);var r=u(o);function o(t,n,i){var s;return e(this,o),(s=r.call(this,t,n,i)).contracted=null,s}return n(o,[{key:"expand",value:function(){return this.list.forEach((function(t){var e=t.terms(),r=e[0].isTitleCase();e.forEach((function(t,r){t.set(t.implicit||t.text),t.implicit=void 0,r0}}),Object.defineProperty(this,"length",{get:function(){return o.list.length}}),Object.defineProperty(this,"isA",{get:function(){return"Doc"}})}return n(t,[{key:"tagger",value:function(){return Fr(this)}},{key:"pool",value:function(){return this.list.length>0?this.list[0].pool:this.all().list[0].pool}}]),t}();fn.prototype.buildFrom=function(t){return t=t.map((function(t){return t.clone(!0)})),new fn(t,this,this.world)},fn.prototype.fromText=function(t){var e=le(t,this.world,this.pool());return this.buildFrom(e)},Object.assign(fn.prototype,ln.misc),Object.assign(fn.prototype,ln.selections),hn(fn);var pn={untag:"unTag",and:"match",notIf:"ifNo",only:"if",onlyIf:"if"};Object.keys(pn).forEach((function(t){return fn.prototype[t]=fn.prototype[pn[t]]}));var dn=fn;return function t(e){var r=e,n=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",e=arguments.length>1?arguments[1]:void 0;e&&r.addWords(e);var n=le(t,r),i=new dn(n,null,r);return i.tagger(),i};return n.tokenize=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",e=arguments.length>1?arguments[1]:void 0,n=r;e&&((n=n.clone()).words={},n.addWords(e));var i=le(t,n),o=new dn(i,null,n);return e&&Fr(o),o},n.extend=function(t){return t(dn,r,this,_t,st,Ut),this},n.fromJSON=function(t){var e=fe(t,r);return new dn(e,null,r)},n.clone=function(){return t(r.clone())},n.verbose=function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return r.verbose(t),this},n.world=function(){return r},n.version="13.3.2",n.import=n.load,n}(new qe)})); +!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t="undefined"!=typeof globalThis?globalThis:t||self).nlp=e()}(this,(function(){"use strict";function t(e){return(t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(e)}function e(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function r(t,e){for(var r=0;rt.length)&&(e=t.length);for(var r=0,n=new Array(e);rn[e].lineage.length?1:n[t].isA.length>n[e].isA.length?-1:0:0:1}))},R={text:!0,tags:!0,implicit:!0,whitespace:!0,clean:!1,id:!1,index:!1,offset:!1,bestTag:!1},U={json:function(t,e){t=t||{};var r={};return(t=Object.assign({},R,t)).text&&(r.text=this.text),t.normal&&(r.normal=this.normal),t.tags&&(r.tags=Object.keys(this.tags)),t.clean&&(r.clean=this.clean),(t.id||t.offset)&&(r.id=this.id),t.implicit&&null!==this.implicit&&(r.implicit=this.implicit),t.whitespace&&(r.pre=this.pre,r.post=this.post),t.bestTag&&(r.bestTag=_(this,e)[0]),r}},H=Object.assign({},$,V,M,z,U);function G(){return"undefined"!=typeof window&&window.document}var Q=function(t,e){for(t=t.toString();t.length0&&void 0!==arguments[0]?arguments[0]:"";e(this,t),r=String(r);var n=T(r);this.text=n.text||"",this.clean=n.clean,this.reduced=n.reduced,this.root=null,this.implicit=null,this.pre=n.pre||"",this.post=n.post||"",this.tags={},this.prev=null,this.next=null,this.id=f(n.clean),this.isA="Term",n.alias&&(this.alias=n.alias)}return n(t,[{key:"set",value:function(t){var e=T(t);return this.text=e.text,this.clean=e.clean,this}}]),t}();ot.prototype.clone=function(){var t=new ot(this.text);return t.pre=this.pre,t.post=this.post,t.clean=this.clean,t.reduced=this.reduced,t.root=this.root,t.implicit=this.implicit,t.tags=Object.assign({},this.tags),t},Object.assign(ot.prototype,H),Object.assign(ot.prototype,it);var st=ot,at={terms:function(t){if(0===this.length)return[];if(this.cache.terms)return void 0!==t?this.cache.terms[t]:this.cache.terms;for(var e=[this.pool.get(this.start)],r=0;r0&&void 0!==arguments[0]?arguments[0]:{},e=arguments.length>1?arguments[1]:void 0,r=arguments.length>2?arguments[2]:void 0;"string"==typeof t&&(t="normal"===t?{whitespace:!0,unicode:!0,lowercase:!0,punctuation:!0,acronyms:!0,abbreviations:!0,implicit:!0,normal:!0}:"clean"===t?{titlecase:!1,lowercase:!0,punctuation:!0,whitespace:!0,unicode:!0,implicit:!0}:"reduced"===t?{titlecase:!1,lowercase:!0,punctuation:!1,whitespace:!0,unicode:!0,implicit:!0,reduced:!0}:"root"===t?{titlecase:!1,lowercase:!0,punctuation:!0,whitespace:!0,unicode:!0,implicit:!0,root:!0}:{});var n=this.terms(),i=!1;n[0]&&null===n[0].prev&&null===n[n.length-1].next&&(i=!0);var o=n.reduce((function(o,s,a){t.last=r&&a===n.length-1;var u=!0,c=!0;return!1===i&&(0===a&&e&&(u=!1),a===n.length-1&&r&&(c=!1)),o+s.textOut(t,u,c)}),"");return!0===i&&r&&(o=ut(o)),!0===t.trim&&(o=o.trim()),o}},ht={trim:function(){var t=this.terms();if(t.length>0){t[0].pre=t[0].pre.replace(/^\s+/,"");var e=t[t.length-1];e.post=e.post.replace(/\s+$/,"")}return this}},lt=/[.?!]\s*$/,ft=function(t,e){e[0].pre=t[0].pre;var r,n,i=t[t.length-1],o=e[e.length-1];o.post=(r=i.post,n=o.post,lt.test(n)?n+r.match(/\s*$/):r),i.post="",""===i.post&&(i.post+=" ")},pt=function(t,e,r){var n=t.terms(),i=e.terms();ft(n,i),function(t,e,r){var n=t[t.length-1],i=e[e.length-1],o=n.next;n.next=e[0].id,i.next=o,o&&(r.get(o).prev=i.id);var s=t[0].id;s&&(e[0].prev=s)}(n,i,t.pool);var o,s=[t],a=t.start,u=[r];return(u=u.concat(r.parents())).forEach((function(t){var e=t.list.filter((function(t){return t.hasId(a)}));s=s.concat(e)})),(s=(o=s).filter((function(t,e){return o.indexOf(t)===e}))).forEach((function(t){t.length+=e.length})),t.cache={},t},dt=/ /,vt=function(t,e,r){var n=t.start,i=e.terms();!function(t){var e=t[t.length-1];!1===dt.test(e.post)&&(e.post+=" ")}(i),function(t,e,r){var n=r[r.length-1];n.next=t.start;var i=t.pool,o=i.get(t.start);o.prev&&(i.get(o.prev).next=e.start),r[0].prev=t.terms(0).prev,t.terms(0).prev=n.id}(t,e,i);var o,s=[t],a=[r];return(a=a.concat(r.parents())).forEach((function(t){var r=t.list.filter((function(t){return t.hasId(n)||t.hasId(e.start)}));s=s.concat(r)})),(s=(o=s).filter((function(t,e){return o.indexOf(t)===e}))).forEach((function(t){t.length+=e.length,t.start===n&&(t.start=e.start),t.cache={}})),t},mt=function(t,e){var r=e.pool(),n=t.terms(),i=r.get(n[0].prev)||{},o=r.get(n[n.length-1].next)||{};n[0].implicit&&i.implicit&&(i.set(i.implicit),i.post+=" "),function(t,e,r,n){var i=t.parents();i.push(t),i.forEach((function(t){var i=t.list.find((function(t){return t.hasId(e)}));i&&(i.length-=r,i.start===e&&(i.start=n.id),i.cache={})})),t.list=t.list.filter((function(t){return!(!t.start||!t.length)}))}(e,t.start,t.length,o),i&&(i.next=o.id),o&&(o.prev=i.id)},gt={append:function(t,e){return pt(this,t,e),this},prepend:function(t,e){return vt(this,t,e),this},delete:function(t){return mt(this,t),this},replace:function(t,e){var r=this.length;pt(this,t,e);var n=this.buildFrom(this.start,this.length);n.length=r,mt(n,e)},splitOn:function(t){var e=this.terms(),r={before:null,match:null,after:null},n=e.findIndex((function(e){return e.id===t.start}));if(-1===n)return r;var i=e.slice(0,n);i.length>0&&(r.before=this.buildFrom(i[0].id,i.length));var o=e.slice(n,n+t.length);o.length>0&&(r.match=this.buildFrom(o[0].id,o.length));var s=e.slice(n+t.length,e.length);return s.length>0&&(r.after=this.buildFrom(s[0].id,s.length,this.pool)),r}},bt={json:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=arguments.length>1?arguments[1]:void 0,r={};return t.text&&(r.text=this.text()),t.normal&&(r.normal=this.text("normal")),t.clean&&(r.clean=this.text("clean")),t.reduced&&(r.reduced=this.text("reduced")),t.root&&(r.root=this.text("root")),t.trim&&(r.text&&(r.text=r.text.trim()),r.normal&&(r.normal=r.normal.trim()),r.reduced&&(r.reduced=r.reduced.trim())),t.terms&&(!0===t.terms&&(t.terms={}),r.terms=this.terms().map((function(r){return r.json(t.terms,e)}))),r}},yt={lookAhead:function(t){t||(t=".*");var e=this.pool,r=[],n=this.terms();return function t(n){var i=e.get(n);i&&(r.push(i),i.prev&&t(i.next))}(n[n.length-1].next),0===r.length?[]:this.buildFrom(r[0].id,r.length).match(t)},lookBehind:function(t){t||(t=".*");var e=this.pool,r=[];return function t(n){var i=e.get(n);i&&(r.push(i),i.prev&&t(i.prev))}(e.get(this.start).prev),0===r.length?[]:this.buildFrom(r[r.length-1].id,r.length).match(t)}},At=Object.assign({},at,ct,ht,gt,bt,yt),wt=function(t,e){if(0===e.length)return!0;for(var r=0;r0)return!0;if(!0===n.anything&&!0===n.negative)return!0}return!1},xt=function(t,e,r,n,i,o){for(var s=e;es)return[!1,null];if(!0===u.end&&r+s!==n)return[!1,null]}if(c){var d=jt(i,h,t,p,u.named);s>1&&u.greedy?d.length+=s-p:d.length++}}else if(!0!==u.optional){if(!(t[s].isImplicit()&&e[a-1]&&t[s+1]&&t[s+1].doesMatch(u,r+s,n)))return[!1,null];s+=2}}else{var v=Pt(t,s,e[a+1],u,r);if(void 0!==u.min&&v-su.max){s+=u.max;continue}if(null===v)return[!1,null];c&&(jt(i,h,t,s,u.named).length=v-s),s=v}}return[t.slice(0,s),i]},Ot=function(t,e,r){if(!r||0===r.length)return r;if(e.some((function(t){return t.end}))){var n=t[t.length-1];r=r.filter((function(t){return-1!==t.match.indexOf(n)}))}return r},Ct=/\{([0-9]+,?[0-9]*)\}/,kt=/&&/,Ft=new RegExp(/^<(\S+)>/),Tt=function(t){return t[t.length-1]},Nt=function(t){return t[0]},$t=function(t){return t.substr(1)},Vt=function(t){return t.substr(0,t.length-1)},St=function(t){return t=$t(t),t=Vt(t)},Bt=function t(e){for(var r,n={},i=0;i<2;i+=1){if("$"===Tt(e)&&(n.end=!0,e=Vt(e)),"^"===Nt(e)&&(n.start=!0,e=$t(e)),("["===Nt(e)||"]"===Tt(e))&&(n.named=!0,"["===Nt(e)?n.groupType="]"===Tt(e)?"single":"start":n.groupType="end",e=(e=e.replace(/^\[/,"")).replace(/\]$/,""),"<"===Nt(e))){var o=Ft.exec(e);o.length>=2&&(n.named=o[1],e=e.replace(o[0],""))}if("+"===Tt(e)&&(n.greedy=!0,e=Vt(e)),"*"!==e&&"*"===Tt(e)&&"\\*"!==e&&(n.greedy=!0,e=Vt(e)),"?"===Tt(e)&&(n.optional=!0,e=Vt(e)),"!"===Nt(e)&&(n.negative=!0,e=$t(e)),"("===Nt(e)&&")"===Tt(e)){kt.test(e)?(n.choices=e.split(kt),n.operator="and"):(n.choices=e.split("|"),n.operator="or"),n.choices[0]=$t(n.choices[0]);var s=n.choices.length-1;n.choices[s]=Vt(n.choices[s]),n.choices=n.choices.map((function(t){return t.trim()})),n.choices=n.choices.filter((function(t){return t})),n.choices=n.choices.map(t),e=""}if("/"===Nt(e)&&"/"===Tt(e))return e=St(e),n.regex=new RegExp(e),n;if("~"===Nt(e)&&"~"===Tt(e))return e=St(e),n.soft=!0,n.word=e,n}return!0===Ct.test(e)&&(e=e.replace(Ct,(function(t,e){var r=e.split(/,/g);return 1===r.length?(n.min=Number(r[0]),n.max=Number(r[0])):(n.min=Number(r[0]),n.max=Number(r[1]||999)),n.greedy=!0,""}))),"#"===Nt(e)?(n.tag=$t(e),n.tag=(r=n.tag).charAt(0).toUpperCase()+r.substr(1),n):"@"===Nt(e)?(n.method=$t(e),n):"."===e?(n.anything=!0,n):"*"===e?(n.anything=!0,n.greedy=!0,n.optional=!0,n):(e&&(e=(e=e.replace("\\*","*")).replace("\\.","."),n.word=e.toLowerCase()),n)},It=function(t){return t.filter((function(t){return t.groupType})).length>0&&(t=function(t){for(var e,r,n=!1,i=-1,o=0;o)?\(.*?\)[?+*]*\]?\$?)/);return e.map((function(t){return t.trim()}))}(e);return r=(r=function(t){var e=[];return t.forEach((function(t){if(/^[[^_/]?\(/.test(t[0]))e.push(t);else{var r=t.split(" ");r=r.filter((function(t){return t})),e=e.concat(r)}})),e}(r)).map(Bt),r=It(r)},Mt=function(t,e){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if("string"==typeof e&&(e=Dt(e)),!0===wt(t,e))return[];var n=e.filter((function(t){return!0!==t.optional})).length,i=t.terms(),o=[];if(!0===e[0].start){var s=Et(i,e,0,i.length),a=c(s,2),u=a[0],h=a[1];return!1!==u&&u.length>0&&(u=u.filter((function(t){return t})),o.push({match:u,groups:h})),Ot(i,e,o)}for(var l=0;li.length);l+=1){var f=Et(i.slice(l),e,l,i.length),p=c(f,2),d=p[0],v=p[1];if(!1!==d&&d.length>0&&(l+=d.length-1,d=d.filter((function(t){return t})),o.push({match:d,groups:v}),!0===r))return Ot(i,e,o)}return Ot(i,e,o)},qt=function(t,e){var r={};Mt(t,e).forEach((function(t){t.match.forEach((function(t){r[t.id]=!0}))}));var n=t.terms(),i=[],o=[];return n.forEach((function(t){!0!==r[t.id]?o.push(t):o.length>0&&(i.push(o),o=[])})),o.length>0&&i.push(o),i},Lt={match:function(t){var e=this,r=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=Mt(this,t,r);return n=n.map((function(t){var r=t.match,n=t.groups,i=e.buildFrom(r[0].id,r.length,n);return i.cache.terms=r,i}))},has:function(t){return Mt(this,t,!0).length>0},not:function(t){var e=this,r=qt(this,t);return r=r.map((function(t){return e.buildFrom(t[0].id,t.length)}))},canBe:function(t,e){for(var r=this,n=[],i=this.terms(),o=!1,s=0;s0})).map((function(t){return r.buildFrom(t[0].id,t.length)}))}},zt=function t(r,n,i){e(this,t),this.start=r,this.length=n,this.isA="Phrase",Object.defineProperty(this,"pool",{enumerable:!1,writable:!0,value:i}),Object.defineProperty(this,"cache",{enumerable:!1,writable:!0,value:{}}),Object.defineProperty(this,"groups",{enumerable:!1,writable:!0,value:{}})};zt.prototype.buildFrom=function(t,e,r){var n=new zt(t,e,this.pool);return r&&Object.keys(r).length>0?n.groups=r:n.groups=this.groups,n},Object.assign(zt.prototype,Lt),Object.assign(zt.prototype,At);var Wt={term:"terms"};Object.keys(Wt).forEach((function(t){return zt.prototype[t]=zt.prototype[Wt[t]]}));var _t=zt,Rt=function(){function t(){var r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};e(this,t),Object.defineProperty(this,"words",{enumerable:!1,value:r})}return n(t,[{key:"add",value:function(t){return this.words[t.id]=t,this}},{key:"get",value:function(t){return this.words[t]}},{key:"remove",value:function(t){delete this.words[t]}},{key:"merge",value:function(t){return Object.assign(this.words,t.words),this}},{key:"stats",value:function(){return{words:Object.keys(this.words).length}}}]),t}();Rt.prototype.clone=function(){var t=this,e=Object.keys(this.words).reduce((function(e,r){var n=t.words[r].clone();return e[n.id]=n,e}),{});return new Rt(e)};var Ut=Rt,Ht=function(t){t.forEach((function(e,r){r>0&&(e.prev=t[r-1].id),t[r+1]&&(e.next=t[r+1].id)}))},Gt=/(\S.+?[.!?\u203D\u2E18\u203C\u2047-\u2049])(?=\s+|$)/g,Qt=/\S/,Zt=/[ .][A-Z]\.? *$/i,Jt=/(?:\u2026|\.{2,}) *$/,Yt=/((?:\r?\n|\r)+)/,Kt=/[a-z0-9\u00C0-\u00FF\u00a9|\u00ae|[\u2000-\u3300]|\ud83c[\ud000-\udfff]|\ud83d[\ud000-\udfff]|\ud83e[\ud000-\udfff]/i,Xt=/^\s+/,te=function(t,e){if(!0===Zt.test(t))return!1;if(!0===Jt.test(t))return!1;if(!1===Kt.test(t))return!1;var r=t.replace(/[.!?\u203D\u2E18\u203C\u2047-\u2049] *$/,"").split(" "),n=r[r.length-1].toLowerCase();return!e.hasOwnProperty(n)},ee=function(t,e){var r=e.cache.abbreviations;t=t||"";var n=[],i=[];if(!(t=String(t))||"string"!=typeof t||!1===Qt.test(t))return n;for(var o=function(t){for(var e=[],r=t.split(Yt),n=0;n0&&(n.push(c),i[u]="")}if(0===n.length)return[t];for(var h=1;h0?(e[e.length-1]+=o,e.push(a)):e.push(o+a),o=""):o+=a}return o&&(0===e.length&&(e[0]=""),e[e.length-1]+=o),e=(e=function(t){for(var e=1;e0&&void 0!==arguments[0]?arguments[0]:"",e=arguments.length>1?arguments[1]:void 0,r=arguments.length>2?arguments[2]:void 0,n=null;"string"!=typeof t&&("number"==typeof t?t=String(t):he(t)&&(n=t)),n=(n=n||ee(t,e)).map((function(t){return ce(t)})),r=r||new Ut;var i=n.map((function(t){t=t.map((function(t){var e=new st(t);return r.add(e),e})),Ht(t);var e=new _t(t[0].id,t.length,r);return e.cache.terms=t,e}));return i},fe=function(t,e){var r=new Ut;return t.map((function(t,n){var i=t.terms.map((function(i,o){var s=new st(i.text);return s.pre=void 0!==i.pre?i.pre:"",void 0===i.post&&(i.post=" ",o>=t.terms.length-1&&(i.post=". ",n>=t.terms.length-1&&(i.post="."))),s.post=void 0!==i.post?i.post:" ",i.tags&&i.tags.forEach((function(t){return s.tag(t,"",e)})),r.add(s),s}));return Ht(i),new _t(i[0].id,i.length,r)}))},pe={},de=["Person","Place","Organization"],ve={Noun:{notA:["Verb","Adjective","Adverb"]},Singular:{isA:"Noun",notA:"Plural"},ProperNoun:{isA:"Noun"},Person:{isA:["ProperNoun","Singular"],notA:["Place","Organization","Date"]},FirstName:{isA:"Person"},MaleName:{isA:"FirstName",notA:["FemaleName","LastName"]},FemaleName:{isA:"FirstName",notA:["MaleName","LastName"]},LastName:{isA:"Person",notA:["FirstName"]},NickName:{isA:"Person",notA:["FirstName","LastName"]},Honorific:{isA:"Noun",notA:["FirstName","LastName","Value"]},Place:{isA:"Singular",notA:["Person","Organization"]},Country:{isA:["Place","ProperNoun"],notA:["City"]},City:{isA:["Place","ProperNoun"],notA:["Country"]},Region:{isA:["Place","ProperNoun"]},Address:{isA:"Place"},Organization:{isA:["Singular","ProperNoun"],notA:["Person","Place"]},SportsTeam:{isA:"Organization"},School:{isA:"Organization"},Company:{isA:"Organization"},Plural:{isA:"Noun",notA:["Singular"]},Uncountable:{isA:"Noun"},Pronoun:{isA:"Noun",notA:de},Actor:{isA:"Noun",notA:de},Activity:{isA:"Noun",notA:["Person","Place"]},Unit:{isA:"Noun",notA:de},Demonym:{isA:["Noun","ProperNoun"],notA:de},Possessive:{isA:"Noun"}},me={Verb:{notA:["Noun","Adjective","Adverb","Value"]},PresentTense:{isA:"Verb",notA:["PastTense","Copula","FutureTense"]},Infinitive:{isA:"PresentTense",notA:["PastTense","Gerund"]},Gerund:{isA:"PresentTense",notA:["PastTense","Copula","FutureTense"]},PastTense:{isA:"Verb",notA:["FutureTense"]},FutureTense:{isA:"Verb"},Copula:{isA:"Verb"},Modal:{isA:"Verb",notA:["Infinitive"]},PerfectTense:{isA:"Verb",notA:"Gerund"},Pluperfect:{isA:"Verb"},Participle:{isA:"Verb"},PhrasalVerb:{isA:"Verb"},Particle:{isA:"PhrasalVerb"}},ge={Value:{notA:["Verb","Adjective","Adverb"]},Ordinal:{isA:"Value",notA:["Cardinal"]},Cardinal:{isA:"Value",notA:["Ordinal"]},RomanNumeral:{isA:"Cardinal",notA:["Ordinal","TextValue"]},TextValue:{isA:"Value",notA:["NumericValue"]},NumericValue:{isA:"Value",notA:["TextValue"]},Money:{isA:"Cardinal"},Percent:{isA:"Value"}},be=["Noun","Verb","Adjective","Adverb","Value","QuestionWord"],ye={Adjective:{notA:["Noun","Verb","Adverb","Value"]},Comparable:{isA:["Adjective"]},Comparative:{isA:["Adjective"]},Superlative:{isA:["Adjective"],notA:["Comparative"]},NumberRange:{isA:["Contraction"]},Adverb:{notA:["Noun","Verb","Adjective","Value"]},Date:{notA:["Verb","Conjunction","Adverb","Preposition","Adjective"]},Month:{isA:["Date","Singular"],notA:["Year","WeekDay","Time"]},WeekDay:{isA:["Date","Noun"]},Time:{isA:["Date"],notA:["Value"]},Determiner:{notA:be},Conjunction:{notA:be},Preposition:{notA:be},QuestionWord:{notA:["Determiner"]},Currency:{},Expression:{notA:["Noun","Adjective","Verb","Adverb"]},Abbreviation:{},Url:{notA:["HashTag","PhoneNumber","Verb","Adjective","Value","AtMention","Email"]},PhoneNumber:{notA:["HashTag","Verb","Adjective","Value","AtMention","Email"]},HashTag:{},AtMention:{isA:["Noun"],notA:["HashTag","Verb","Adjective","Value","Email"]},Emoji:{notA:["HashTag","Verb","Adjective","Value","AtMention"]},Emoticon:{notA:["HashTag","Verb","Adjective","Value","AtMention"]},Email:{notA:["HashTag","Verb","Adjective","Value","AtMention"]},Auxiliary:{notA:["Noun","Adjective","Value"]},Acronym:{notA:["Plural","RomanNumeral"]},Negative:{notA:["Noun","Adjective","Value"]},Condition:{notA:["Verb","Adjective","Noun","Value"]}},Ae={Noun:"blue",Verb:"green",Negative:"green",Date:"red",Value:"red",Adjective:"magenta",Preposition:"cyan",Conjunction:"cyan",Determiner:"cyan",Adverb:"cyan"},we=function(t){return Object.keys(t).forEach((function(e){t[e].color?t[e].color=t[e].color:Ae[e]?t[e].color=Ae[e]:t[e].isA.some((function(r){return!!Ae[r]&&(t[e].color=Ae[r],!0)}))})),t},xe=function(t){return Object.keys(t).forEach((function(e){for(var r=t[e],n=r.isA.length,i=0;i1&&(r.hasCompound[o[0]]=!0),"Singular"===e){var s=i.toPlural(t,r);n[s]=n[s]||"Plural"}if("Infinitive"===e)for(var a=i.conjugate(t,r),u=Object.keys(a),c=0;c1?i[o]&&"."!==i[o]&&r.tag(i[o],n,e.world):r.tag(t,n,e.world)}))}))},Re={tag:function(t,e){return t?(_e(t,this,!1,e),this):this},tagSafe:function(t,e){return t?(_e(t,this,!0,e),this):this},unTag:function(t,e){var r=this;return this.list.forEach((function(n){n.terms().forEach((function(n){return n.unTag(t,e,r.world)}))})),this},canBe:function(t){if(!t)return this;var e=this.world,r=this.list.reduce((function(r,n){return r.concat(n.canBe(t,e))}),[]);return this.buildFrom(r)}},Ue={map:function(e){var r=this;if(!e)return this;var n=this.list.map((function(t,n){var i=r.buildFrom([t]);i.from=null;var o=e(i,n);return o&&o.list&&o.list[0]?o.list[0]:o}));return 0===(n=n.filter((function(t){return t}))).length?this.buildFrom(n):"object"!==t(n[0])||"Phrase"!==n[0].isA?n:this.buildFrom(n)},forEach:function(t,e){var r=this;return t?(this.list.forEach((function(n,i){var o=r.buildFrom([n]);!0===e&&(o.from=null),t(o,i)})),this):this},filter:function(t){var e=this;if(!t)return this;var r=this.list.filter((function(r,n){var i=e.buildFrom([r]);return i.from=null,t(i,n)}));return this.buildFrom(r)},find:function(t){var e=this;if(!t)return this;var r=this.list.find((function(r,n){var i=e.buildFrom([r]);return i.from=null,t(i,n)}));return r?this.buildFrom([r]):void 0},some:function(t){var e=this;return t?this.list.some((function(r,n){var i=e.buildFrom([r]);return i.from=null,t(i,n)})):this},random:function(t){if(!this.found)return this;var e=Math.floor(Math.random()*this.list.length);if(void 0===t){var r=[this.list[e]];return this.buildFrom(r)}return e+t>this.length&&(e=(e=this.length-t)<0?0:e),this.slice(e,e+t)}},He=function(t){return t.split(/[ -]/g)},Ge=function(t,e,r){for(var n=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],r={};return t.forEach((function(t,n){var i=!0;void 0!==e[n]&&(i=e[n]),t=(t=(t||"").toLowerCase()).replace(/[,;.!?]+$/,"");var o=He(t).map((function(t){return t.trim()}));r[o[0]]=r[o[0]]||{},1===o.length?r[o[0]].value=i:(r[o[0]].more=r[o[0]].more||[],r[o[0]].more.push({rest:o.slice(1),value:i}))})),r}(t,e),i=[],o=function(t){for(var e=r.list[t],o=e.terms().map((function(t){return t.reduced})),s=function(t){void 0!==n[o[t]]&&(void 0!==n[o[t]].more&&n[o[t]].more.forEach((function(r){void 0!==o[t+r.rest.length]&&(!0===r.rest.every((function(e,r){return e===o[t+r+1]}))&&i.push({id:e.terms()[t].id,value:r.value,length:r.rest.length+1}))})),void 0!==n[o[t]].value&&i.push({id:e.terms()[t].id,value:n[o[t]].value,length:1}))},a=0;a1&&void 0!==arguments[1]?arguments[1]:{};return e?(!0===n&&(n={keepTags:!0}),!1===n&&(n={keepTags:!1}),n=n||{},this.uncache(),this.list.forEach((function(i){var o,s=e;if("function"==typeof e&&(s=e(i)),s&&"object"===t(s)&&"Doc"===s.isA)o=s.list,r.pool().merge(s.pool());else{if("string"!=typeof s)return;!1!==n.keepCase&&i.terms(0).isTitleCase()&&(s=Je(s)),o=le(s,r.world,r.pool());var a=r.buildFrom(o);a.tagger(),o=a.list}if(!0===n.keepTags){var u=i.json({terms:{tags:!0}}).terms;o[0].terms().forEach((function(t,e){u[e]&&t.tagSafe(u[e].tags,"keptTag",r.world)}))}i.replace(o[0],r)})),this):this.delete()},replace:function(t,e,r){return void 0===e?this.replaceWith(t,r):(this.match(t).replaceWith(e,r),this)}},Ke=N((function(t,e){var r=function(t,e){var r=le(t,e.world)[0],n=e.buildFrom([r]);return n.tagger(),e.list=n.list,e};e.append=function(t){var e=this;return t?this.found?(this.uncache(),this.list.forEach((function(r){var n=le(t,e.world,e.pool())[0];e.buildFrom([n]).tagger(),r.append(n,e)})),this):r(t,this):this},e.insertAfter=e.append,e.insertAt=e.append,e.prepend=function(t){var e=this;return t?this.found?(this.uncache(),this.list.forEach((function(r){var n=le(t,e.world,e.pool())[0];e.buildFrom([n]).tagger(),r.prepend(n,e)})),this):r(t,this):this},e.insertBefore=e.prepend,e.concat=function(){this.uncache();for(var t=this.list.slice(0),e=0;e0&&void 0!==arguments[0]?arguments[0]:{};if("number"==typeof e&&this.list[e])return this.list[e].json(r);!0===(e=n(e)).root&&this.list.forEach((function(e){e.terms().forEach((function(e){null===e.root&&e.setRoot(t.world)}))}));var i=this.list.map((function(r){return r.json(e,t.world)}));if((e.terms.offset||e.offset||e.terms.index||e.index)&&er(this,i,e),e.frequency||e.freq||e.count){var o={};this.list.forEach((function(t){var e=t.text("reduced");o[e]=o[e]||0,o[e]+=1})),this.list.forEach((function(t,e){i[e].count=o[t.text("reduced")]}))}if(e.unique){var s={};i=i.filter((function(t){return!0!==s[t.reduced]&&(s[t.reduced]=!0,!0)}))}return i},e.data=e.json})),nr=N((function(t){var e="",r=function(t,e){for(t=t.toString();t.lengthe.count?-1:t.countn?1:0},length:function(t,e){var r=t.text().trim().length,n=e.text().trim().length;return rn?-1:0},wordCount:function(t,e){var r=t.wordCount(),n=e.wordCount();return rn?-1:0}};sr.alphabetical=sr.alpha,sr.wordcount=sr.wordCount;var ar={index:!0,sequence:!0,seq:!0,sequential:!0,chron:!0,chronological:!0},ur={sort:function(t){return"freq"===(t=t||"alpha")||"frequency"===t||"topk"===t?(r={},n={case:!0,punctuation:!1,whitespace:!0,unicode:!0},(e=this).list.forEach((function(t){var e=t.text(n);r[e]=r[e]||0,r[e]+=1})),e.list.sort((function(t,e){var i=r[t.text(n)],o=r[e.text(n)];return io?-1:0})),e):ar.hasOwnProperty(t)?function(t){var e={};return t.json({terms:{offset:!0}}).forEach((function(t){e[t.terms[0].id]=t.terms[0].offset.start})),t.list=t.list.sort((function(t,r){return e[t.start]>e[r.start]?1:e[t.start]0){i+=s;continue}}if(void 0===r[o]||!0!==r.hasOwnProperty(o))if(o===t[i].reduced||!0!==r.hasOwnProperty(t[i].reduced)){if(!0===Or.test(o)){var a=o.replace(Or,"");!0===r.hasOwnProperty(a)&&t[i].tag(r[a],"noprefix-lexicon",e)}}else t[i].tag(r[t[i].reduced],"lexicon",e);else t[i].tag(r[o],"lexicon",e)}return t},Fr=function(t){var e=t.termList();return kr(e,t.world),t},Tr=function(t){var r=function(t){i(o,t);var r=u(o);function o(){return e(this,o),r.apply(this,arguments)}return n(o,[{key:"stripPeriods",value:function(){return this.termList().forEach((function(t){!0===t.tags.Abbreviation&&t.next&&(t.post=t.post.replace(/^\./,""));var e=t.text.replace(/\./,"");t.set(e)})),this}},{key:"addPeriods",value:function(){return this.termList().forEach((function(t){t.post=t.post.replace(/^\./,""),t.post="."+t.post})),this}}]),o}(t);return r.prototype.unwrap=r.prototype.stripPeriods,t.prototype.abbreviations=function(t){var e=this.match("#Abbreviation");return"number"==typeof t&&(e=e.get(t)),new r(e.list,this,this.world)},t},Nr=/\./,$r=function(t){var r=function(t){i(o,t);var r=u(o);function o(){return e(this,o),r.apply(this,arguments)}return n(o,[{key:"stripPeriods",value:function(){return this.termList().forEach((function(t){var e=t.text.replace(/\./g,"");t.set(e)})),this}},{key:"addPeriods",value:function(){return this.termList().forEach((function(t){var e=t.text.replace(/\./g,"");e=e.split("").join("."),!1===Nr.test(t.post)&&(e+="."),t.set(e)})),this}}]),o}(t);return r.prototype.unwrap=r.prototype.stripPeriods,r.prototype.strip=r.prototype.stripPeriods,t.prototype.acronyms=function(t){var e=this.match("#Acronym");return"number"==typeof t&&(e=e.get(t)),new r(e.list,this,this.world)},t},Vr=function(t){return t.prototype.clauses=function(e){var r=this.if("@hasComma").notIf("@hasComma @hasComma").notIf("@hasComma . .? (and|or) .").notIf("(#City && @hasComma) #Country").notIf("(#Date && @hasComma) #Year").notIf("@hasComma (too|also)$").match("@hasComma"),n=this.splitAfter(r),i=n.quotations(),o=(n=n.splitOn(i)).parentheses(),s=(n=n.splitOn(o)).if("#Copula #Adjective #Conjunction (#Pronoun|#Determiner) #Verb").match("#Conjunction"),a=(n=n.splitBefore(s)).if("if .{2,9} then .").match("then"),u=(n=(n=(n=(n=(n=(n=n.splitBefore(a)).splitBefore("as well as .")).splitBefore("such as .")).splitBefore("in addition to .")).splitAfter("@hasSemicolon")).splitAfter("@hasDash")).filter((function(t){return t.wordCount()>5&&t.match("#Verb+").length>=2}));if(u.found){var c=u.splitAfter("#Noun .* #Verb .* #Noun+");n=n.splitOn(c.eq(0))}return"number"==typeof e&&(n=n.get(e)),new t(n.list,this,this.world)},t},Sr=function(t){var r=function(t){i(o,t);var r=u(o);function o(t,n,i){var s;return e(this,o),(s=r.call(this,t,n,i)).contracted=null,s}return n(o,[{key:"expand",value:function(){return this.list.forEach((function(t){var e=t.terms(),r=e[0].isTitleCase();e.forEach((function(t,r){t.set(t.implicit||t.text),t.implicit=void 0,r0}}),Object.defineProperty(this,"length",{get:function(){return o.list.length}}),Object.defineProperty(this,"isA",{get:function(){return"Doc"}})}return n(t,[{key:"tagger",value:function(){return Fr(this)}},{key:"pool",value:function(){return this.list.length>0?this.list[0].pool:this.all().list[0].pool}}]),t}();mn.prototype.buildFrom=function(t){return t=t.map((function(t){return t.clone(!0)})),new mn(t,this,this.world)},mn.prototype.fromText=function(t){var e=le(t,this.world,this.pool());return this.buildFrom(e)},Object.assign(mn.prototype,vn.misc),Object.assign(mn.prototype,vn.selections),dn(mn);var gn={untag:"unTag",and:"match",notIf:"ifNo",only:"if",onlyIf:"if"};Object.keys(gn).forEach((function(t){return mn.prototype[t]=mn.prototype[gn[t]]}));var bn=mn;return function t(e){var r=e,n=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",e=arguments.length>1?arguments[1]:void 0;e&&r.addWords(e);var n=le(t,r),i=new bn(n,null,r);return i.tagger(),i};return n.tokenize=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",e=arguments.length>1?arguments[1]:void 0,n=r;e&&((n=n.clone()).words={},n.addWords(e));var i=le(t,n),o=new bn(i,null,n);return e&&Fr(o),o},n.extend=function(t){return t(bn,r,this,_t,st,Ut),this},n.fromJSON=function(t){var e=fe(t,r);return new bn(e,null,r)},n.clone=function(){return t(r.clone())},n.verbose=function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return r.verbose(t),this},n.world=function(){return r},n.version="13.4.0",n.import=n.load,n}(new Me)})); diff --git a/builds/compromise.js b/builds/compromise.js index 5856e4552..f2e52a4aa 100644 --- a/builds/compromise.js +++ b/builds/compromise.js @@ -1,4 +1,4 @@ -/* compromise 13.3.2 MIT */ +/* compromise 13.4.0 MIT */ (function (global, factory) { typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() : typeof define === 'function' && define.amd ? define(factory) : @@ -1277,6 +1277,10 @@ var term = new Term(this.text); term.pre = this.pre; term.post = this.post; + term.clean = this.clean; + term.reduced = this.reduced; + term.root = this.root; + term.implicit = this.implicit; term.tags = Object.assign({}, this.tags); //use the old id, so it can be matched with .match(doc) // term.id = this.id @@ -1347,7 +1351,8 @@ var terms = this.terms(); var newTerms = terms.map(function (t) { return t.clone(); - }); //connect these new ids up + }); // console.log(newTerms) + //connect these new ids up newTerms.forEach(function (t, i) { //add it to the pool.. @@ -3435,7 +3440,7 @@ var fromJSON_1 = fromJSON; - var _version = '13.3.2'; + var _version = '13.4.0'; var _data = { "Comparative": "true¦better", @@ -3445,14 +3450,14 @@ "Noun": "true¦a5b4c2f1here,ie,lit,m0no doubt,pd,tce;a,d;t,y;a,ca,o0;l,rp;a,l;d,l,rc", "Copula": "true¦a1is,w0;as,ere;m,re", "PastTense": "true¦be3came,d2had,lied,meant,sa2taken,w0;as,e0;nt,re;id;en,gan", - "Condition": "true¦if,unless", + "Condition": "true¦if,lest,unless", "Gerund": "true¦accord0be0develop0go0result0stain0;ing", "Negative": "true¦n0;ever,o0;!n,t", "QuestionWord": "true¦how3wh0;at,e1ich,o0y;!m,se;n,re; come,'s", "Plural": "true¦records", "Conjunction": "true¦&,aEbAcuz,how8in caDno7o6p4supposing,t1vers5wh0yet;eth8ile;h0o;eref9o0;!uC;l0rovided that;us;r,therwi6; matt1r;!ev0;er;e0ut;cau1f0;ore;se;lthou1nd,s 0;far as,if;gh", "Pronoun": "true¦'em,elle,h4i3me,ourselves,she5th1us,we,you0;!rself;e0ou;m,y;!l,t;e0im;!'s", - "Singular": "true¦0:0X;1:10;a0Wb0Kc0Bd04e02fXgShOici1jel0kitty,lNmJnIoHpDquestion mark,rBs7t4u2womW;nc0Rs 2;doll0Dst0F; rex,a3h2ic,ragedy,v show;ere,i1;l0x return;ist0Pky,omeone,t2uper bowl,yst0W;ep3ri1u2;de0Pff;faMmoM;al0i1o2;om,se;a4i0Jl05r3u2;dLrpoD;erogaVobl0O;rt,te0I;bjSceGthers;othi1umb0E;a4ee04o2;del,m2nopo0th0C;!my;n,yf0;i0unch;ead start,o2;l0me3u2;se;! run;adf0entlem5irlZlaci04od,rand3u2;l0y; slam,fa2mo2;th01;an;a5ella,ly,ol0r3un2;di1;iTo2;ntiWsN;mi0thV;conomy,gg,ner5veWx2;ampQecu7;ad7e4innSo2ragonf0ude;cumentFg2i0l0or;gy;ath,t2;ec2;tive;!dy;a8eili1h6i4o2redit card;ttage,u2;riJsin;ty,vil w2;ar;andeliGocol2;ate;n2rD;ary;aAel0lesHo6r4u2;n2tterf0;ti1;eakfast,o2;!th8;dy,tt4y2;!fri2;end;le;nki1r2;ri2;er;d4l0noma0u2;nt;ly; homin4verti2;si1;ng;em", + "Singular": "true¦0:0Z;1:12;a0Yb0Mc0Dd06e04fZgUhQiPjel0kitty,lOmKnJoIpEquestion mark,rCs7t4u2womY;nc0Ts 2;doll0Fst0H; rex,a3h2ic,ragedy,v show;ere,i1;l0x return;i5ky,omeone,t2uper bowl,yst0Y;ep3ri1u2;de0Rff;faOmoO;st0Nze;al0i1o2;om,se;a4i0Kl06r3u2;dMrpoE;erogaWobl0P;rt,te0J;bjTceHthers;othi1umb0F;a4ee05o2;del,m2nopo0th0D;!my;n,yf0;i0unch;ci1nsect;ead start,o2;l0me3u2;se;! run;adf0entlem5irlZlaci04od,rand3u2;l0y; slam,fa2mo2;th01;an;a5ella,ly,ol0r3un2;di1;iTo2;ntiWsN;mi0thV;conomy,gg,ner5veWx2;ampQecu7;ad7e4innSo2ragonf0ude;cumentFg2i0l0or;gy;ath,t2;ec2;tive;!dy;a8eili1h6i4o2redit card;ttage,u2;riJsin;ty,vil w2;ar;andeliGocol2;ate;n2rD;ary;aAel0lesHo6r4u2;n2tterf0;ti1;eakfast,o2;!th8;dy,tt4y2;!fri2;end;le;nki1r2;ri2;er;d4l0noma0u2;nt;ly; homin4verti2;si1;ng;em", "Actor": "true¦aJbGcFdCengineIfAgardenIh9instructPjournalLlawyIm8nurse,opeOp5r3s1t0;echnCherapK;ailNcientJoldiGu0;pervKrgeon;e0oofE;ceptionGsearC;hotographClumbColi1r0sychologF;actitionBogrammB;cem6t5;echanic,inist9us4;airdress8ousekeep8;arm7ire0;fight6m2;eputy,iet0;ici0;an;arpent2lerk;ricklay1ut0;ch0;er;ccoun6d2ge7r0ssis6ttenda7;chitect,t0;ist;minist1v0;is1;rat0;or;ta0;nt", "Honorific": "true¦a03b00cSdReQfiLgKhon,jr,king,lJmEoDp8queen,r4s0taoiseach,vice7;e1fc,gt,ir,r,u0;ltTpt,rg;c0nDrgeaL;ond liJretary;abbi,e0;ar1pAs,v0;!erend; admirY;astPhd,r0vt;esideEi1of0;!essN;me mini5nce0;!ss;fficOp,rd;a3essrs,i2lle,me,r1s0;!tr;!s;stK;gistrate,j,r6yF;i3lb,t;en,ov;eld mar3rst l0;ady,i0;eutena0;nt;shG;sq,xcellency;et,oct6r,utchess;apt6hance4mdr,o0pl;lonel,m2ngress0unci3;m0wom0;an;dr,mand5;ll0;or;!ain;ldg,rig0;!adi0;er;d0sst,tty,yatullah;j,m0v;!ir0;al", "SportsTeam": "true¦0:1A;1:1H;2:1G;a1Eb16c0Td0Kfc dallas,g0Ihouston 0Hindiana0Gjacksonville jagua0k0El0Bm01newToQpJqueens parkIreal salt lake,sAt5utah jazz,vancouver whitecaps,w3yW;ashington 3est ham0Rh10;natio1Oredski2wizar0W;ampa bay 6e5o3;ronto 3ttenham hotspur;blue ja0Mrapto0;nnessee tita2xasC;buccanee0ra0K;a7eattle 5heffield0Kporting kansas0Wt3;. louis 3oke0V;c1Frams;marine0s3;eah15ounG;cramento Rn 3;antonio spu0diego 3francisco gJjose earthquak1;char08paA; ran07;a8h5ittsburgh 4ortland t3;imbe0rail blaze0;pirat1steele0;il3oenix su2;adelphia 3li1;eagl1philNunE;dr1;akland 3klahoma city thunder,rlando magic;athle0Mrai3;de0; 3castle01;england 7orleans 6york 3;city fc,g4je0FknXme0Fred bul0Yy3;anke1;ian0D;pelica2sain0C;patrio0Brevolut3;ion;anchester Be9i3ontreal impact;ami 7lwaukee b6nnesota 3;t4u0Fvi3;kings;imberwolv1wi2;rewe0uc0K;dolphi2heat,marli2;mphis grizz3ts;li1;cXu08;a4eicesterVos angeles 3;clippe0dodDla9; galaxy,ke0;ansas city 3nE;chiefs,roya0E; pace0polis colU;astr06dynamo,rockeTtexa2;olden state warrio0reen bay pac3;ke0;.c.Aallas 7e3i05od5;nver 5troit 3;lio2pisto2ti3;ge0;broncZnuggeM;cowbo4maver3;ic00;ys; uQ;arCelKh8incinnati 6leveland 5ol3;orado r3umbus crew sc;api5ocki1;brow2cavalie0india2;bengaWre3;ds;arlotte horAicago 3;b4cubs,fire,wh3;iteB;ea0ulR;diff3olina panthe0; c3;ity;altimore 9lackburn rove0oston 5rooklyn 3uffalo bilN;ne3;ts;cel4red3; sox;tics;rs;oriol1rave2;rizona Ast8tlanta 3;brav1falco2h4u3;nited;aw9;ns;es;on villa,r3;os;c5di3;amondbac3;ks;ardi3;na3;ls", @@ -3464,14 +3469,14 @@ "Possessive": "true¦anyAh5its,m3noCo1sometBthe0yo1;ir1mselves;ur0;!s;i8y0;!se4;er1i0;mse2s;!s0;!e0;lf;o1t0;hing;ne", "Currency": "true¦$,aud,bScQdLeurKfJgbp,hkd,iIjpy,kGlEp8r7s3usd,x2y1z0¢,£,¥,ден,лв,руб,฿,₡,₨,€,₭,﷼;lotySł;en,uanR;af,of;h0t5;e0il5;k0q0;elM;iel,oubleLp,upeeL;e2ound st0;er0;lingI;n0soH;ceGn0;ies,y;e0i8;i,mpi7;n,r0wanzaCyatC;!onaBw;ls,nr;ori7ranc9;!o8;en3i2kk,o0;b0ll2;ra5;me4n0rham4;ar3;ad,e0ny;nt1;aht,itcoin0;!s", "City": "true¦a2Wb26c1Wd1Re1Qf1Og1Ih1Ai18jakar2Hk0Zl0Tm0Gn0Co0ApZquiYrVsLtCuBv8w3y1z0;agreb,uri1Z;ang1Te0okohama;katerin1Hrev34;ars3e2i0rocl3;ckl0Vn0;nipeg,terth0W;llingt1Oxford;aw;a1i0;en2Hlni2Z;lenc2Uncouv0Gr2G;lan bat0Dtrecht;a6bilisi,e5he4i3o2rondheim,u0;nVr0;in,ku;kyo,ronIulouC;anj23l13miso2Jra2A; haJssaloni0X;gucigalpa,hr2Ol av0L;i0llinn,mpe2Bngi07rtu;chu22n2MpT;a3e2h1kopje,t0ydney;ockholm,uttga12;angh1Fenzh1X;o0KvZ;int peters0Ul3n0ppo1F; 0ti1B;jo0salv2;se;v0z0Q;adU;eykjavik,i1o0;me,sario,t25;ga,o de janei17;to;a8e6h5i4o2r0ueb1Qyongya1N;a0etor24;gue;rt0zn24; elizabe3o;ls1Grae24;iladelph1Znom pe07oenix;r0tah tik19;th;lerJr0tr10;is;dessa,s0ttawa;a1Hlo;a2ew 0is;delTtaip0york;ei;goya,nt0Upl0Uv1R;a5e4i3o1u0;mb0Lni0I;nt0scH;evideo,real;l1Mn01skolc;dellín,lbour0S;drid,l5n3r0;ib1se0;ille;or;chest0dalWi0Z;er;mo;a4i1o0vAy01;nd00s angel0F;ege,ma0nz,sbZverpo1;!ss0;ol; pla0Iusan0F;a5hark4i3laipeda,o1rak0uala lump2;ow;be,pavog0sice;ur;ev,ng8;iv;b3mpa0Kndy,ohsiu0Hra0un03;c0j;hi;ncheMstanb0̇zmir;ul;a5e3o0; chi mi1ms,u0;stI;nh;lsin0rakliG;ki;ifa,m0noi,va0A;bu0SiltD;alw4dan3en2hent,iza,othen1raz,ua0;dalaj0Gngzhou;bu0P;eUoa;sk;ay;es,rankfu0;rt;dmont4indhovU;a1ha01oha,u0;blRrb0Eshanbe;e0kar,masc0FugavpiJ;gu,je0;on;a7ebu,h2o0raioJuriti01;lo0nstanJpenhagNrk;gFmbo;enn3i1ristchur0;ch;ang m1c0ttagoL;ago;ai;i0lgary,pe town,rac4;ro;aHeBirminghWogoAr5u0;char3dap3enos air2r0sZ;g0sa;as;es;est;a2isba1usse0;ls;ne;silPtisla0;va;ta;i3lgrade,r0;g1l0n;in;en;ji0rut;ng;ku,n3r0sel;celo1ranquil0;la;na;g1ja lu0;ka;alo0kok;re;aBb9hmedabad,l7m4n2qa1sh0thens,uckland;dod,gabat;ba;k0twerp;ara;m5s0;terd0;am;exandr0maty;ia;idj0u dhabi;an;lbo1rh0;us;rg", - "Abbreviation": "true¦a0Tb0Qc0Kd0Ie0Ff0Cg0Ah08i06j04k02l00mRnOoNpIqHrFs9t6u5v2w0yb,µg;is0r,y0L;!c;a,b,e1i0ol,s,t;tro,vo;r,t;niv,safa,t;b1ce,d,e0sp;l,mp,nn,x;!l,sp;ask,e3fc,gt,i2q1r,s,t,u0;pt,rg;! ft;r,tu;c,nVp0;!t;b,d,e0;pSs,v;t,ue;a,d,enn3hd,l,p,r1s0t,vt;!a,eud;ef,o0;b,f,n;!a;ct,kla,nt,p,rd,z;e0ov;b0e;!r;a7b,d,essrs,g,i4l3m2p1rHs0t;!tr;h,s;!e;!le;!n1s0;c,ter;!n;!j,r,sc;at,b,it,lb,m,ng,t0x;!d;an6b,g,m0;!ph;an,d,r,u0;l,n;a,da,e,n0;c,f;g,on,r0wy,z;!s;a0b,en,ov;!l;e1ig,l0m,r,t,y;! oz,a;b,m;a,g,ng,s1tc,x0;!p;p,q,t;ak,e0g,ist,l,m,r;c,f,pt,t;a3ca,g,l,m2o0pl,res,t,yn;!l0mdr,nn,rp;!o;!dr;!l0pt;!if;a,c,l1r0;ig,os;!dg,vd;d4l3p2r1ss0tty,ug,ve;n,t;c,iz;prox,r,t;!ta;!j,m,v", + "Abbreviation": "true¦a0Tb0Qc0Kd0Ie0Ff0Cg0Ah08i06j04k02l00mRnOoNpIqHrFs9t6u5v2w0yb,µg;is0r,y0L;!c;a,b,e1i0ol,s,t;tro,vo;r,t;niv,safa,t;b1ce,d,e0sp;l,mp,nn,x;!l,sp;ask,e3fc,gt,i2q1r,s,t,u0;pt,rg;! ft;r,tu;c,nVp0;!t;b,d,e0;pSs,v;t,ue;a,d,enn3hd,l,p,r1s0t,vt;!eud;ef,o0;b,f,n;!a;ct,kla,nt,p,rd,z;e0ov;b0e;!r;a7b,d,essrs,g,i4l3m2p1rHs0t;!tr;h,s;!e;!le;!n1s0;c,ter;!n;!j,r,sc;at,b,it,lb,m,ng,t0x;!d;an6b,g,m0;!ph;an,d,r,u0;l,n;a,da,e,n0;c,f;g,on,r0wy,z;!s;a0b,en,ov;!l;e1ig,l0m,r,t,y;! oz,a;b,m;a,g,ng,s1tc,x0;!p;p,q,t;ak,e0g,ist,l,m,r;c,f,pt,t;a3ca,g,l,m2o0pl,res,t,yn;!l0mdr,nn,rp;!o;!dr;!l0pt;!if;a,c,l1r0;ig,os;!dg,vd;d4l3p2r1ss0tty,ug,ve;n,t;c,iz;prox,r,t;!ta;!j,m,v", "Country": "true¦0:38;1:2L;a2Wb2Dc21d1Xe1Rf1Lg1Bh19i13j11k0Zl0Um0Gn05om3CpZqat1JrXsKtCu6v4wal3yemTz2;a24imbabwe;es,lis and futu2X;a2enezue31ietnam;nuatu,tican city;.5gTkraiZnited 3ruXs2zbeE;a,sr;arab emirat0Kkingdom,states2;! of am2X;k.,s.2; 27a.;a7haBimor-les0Bo6rinidad4u2;nis0rk2valu;ey,me2Xs and caic1T; and 2-2;toba1J;go,kel0Ynga;iw2Vji2nz2R;ki2T;aCcotl1eBi8lov7o5pa2Bri lanka,u4w2yr0;az2ed9itzerl1;il1;d2Qriname;lomon1Vmal0uth 2;afr2IkLsud2O;ak0en0;erra leoEn2;gapo1Wt maart2;en;negKrb0ychellY;int 2moa,n marino,udi arab0;hele24luc0mart1Z;epublic of ir0Com2Cuss0w2;an25;a3eHhilippinTitcairn1Ko2uerto riM;l1rtugE;ki2Bl3nama,pua new0Tra2;gu6;au,esti2;ne;aAe8i6or2;folk1Gth3w2;ay; k2ern mariana1B;or0M;caragua,ger2ue;!ia;p2ther18w zeal1;al;mib0u2;ru;a6exi5icro09o2yanm04;ldova,n2roc4zamb9;a3gol0t2;enegro,serrat;co;c9dagascZl6r4urit3yot2;te;an0i14;shall0Vtin2;ique;a3div2i,ta;es;wi,ys0;ao,ed00;a5e4i2uxembourg;b2echtenste10thu1E;er0ya;ban0Gsotho;os,tv0;azakh1De2iriba02osovo,uwait,yrgyz1D;eling0Jnya;a2erF;ma15p1B;c6nd5r3s2taly,vory coast;le of m19rael;a2el1;n,q;ia,oI;el1;aiSon2ungary;dur0Mg kong;aAermany,ha0Pibralt9re7u2;a5ern4inea2ya0O;!-biss2;au;sey;deloupe,m,tema0P;e2na0M;ce,nl1;ar;bTmb0;a6i5r2;ance,ench 2;guia0Dpoly2;nes0;ji,nl1;lklandTroeT;ast tim6cu5gypt,l salv5ngl1quatorial3ritr4st2thiop0;on0; guin2;ea;ad2;or;enmark,jibou4ominica3r con2;go;!n B;ti;aAentral african 9h7o4roat0u3yprQzech2; 8ia;ba,racao;c3lo2morPngo-brazzaville,okFsta r03te d'ivoiK;mb0;osD;i2ristmasF;le,na;republic;m2naTpe verde,yman9;bod0ero2;on;aFeChut00o8r4u2;lgar0r2;kina faso,ma,undi;azil,itish 2unei;virgin2; is2;lands;liv0nai4snia and herzegoviGtswaGuvet2; isl1;and;re;l2n7rmuF;ar2gium,ize;us;h3ngladesh,rbad2;os;am3ra2;in;as;fghaFlCmAn5r3ustr2zerbaijH;al0ia;genti2men0uba;na;dorra,g4t2;arct6igua and barbu2;da;o2uil2;la;er2;ica;b2ger0;an0;ia;ni2;st2;an", "Region": "true¦0:1U;a20b1Sc1Id1Des1Cf19g13h10i0Xj0Vk0Tl0Qm0FnZoXpSqPrMsDtAut9v6w3y1zacatec22;o05u1;cat18kZ;a1est vi4isconsin,yomi14;rwick0shington1;! dc;er2i1;rgin1S;acruz,mont;ah,tar pradesh;a2e1laxca1DuscaA;nnessee,x1R;bas0Kmaulip1QsmJ;a6i4o2taf0Ou1ylh13;ffVrr00s0Y;me10no1Auth 1;cSdR;ber1Ic1naloa;hu0Sily;n2skatchew0Rxo1;ny; luis potosi,ta catari1I;a1hode7;j1ngp02;asth0Mshahi;inghai,u1;e1intana roo;bec,ensWreta0E;ara4e2rince edward1; isU;i,nnsylv1rnambu02;an14;!na;axa0Ndisha,h1klaho1Bntar1reg4x04;io;ayarit,eBo3u1;evo le1nav0L;on;r1tt0Rva scot0X;f6mandy,th1; 1ampton0;c3d2yo1;rk0;ako0Y;aroli0V;olk;bras0Xva01w1; 2foundland1;! and labrador;brunswick,hamp0jers1mexiJyork state;ey;a6i2o1;nta0Nrelos;ch3dlanBn2ss1;issippi,ouri;as geraGneso0M;igQoacQ;dhya,harasht04ine,ni3r1ssachusetts;anhao,y1;land;p1toba;ur;anca0e1incoln0ouis8;e1iH;ds;a1entucky,hul0A;ns08rnata0Dshmir;alis1iangxi;co;daho,llino2nd1owa;ia05;is;a2ert1idalEunA;ford0;mp0waii;ansu,eorgWlou5u1;an2erre1izhou,jarat;ro;ajuato,gdo1;ng;cester0;lori2uji1;an;da;sex;e4o2uran1;go;rs1;et;lawaErby0;a8ea7hi6o1umbrH;ahui4l3nnectic2rsi1ventry;ca;ut;iMorado;la;apEhuahua;ra;l8m1;bridge0peche;a5r4uck1;ingham0;shi1;re;emen,itish columb3;h2ja cal1sque,var2;iforn1;ia;guascalientes,l4r1;izo2kans1;as;na;a2ber1;ta;ba2s1;ka;ma", "FemaleName": "true¦0:FY;1:G2;2:FR;3:FD;4:FC;5:FS;6:ER;7:EP;8:GF;9:EZ;A:GB;B:E5;C:G8;D:FO;E:FL;F:EG;aE2bD4cB8dAIe9Gf91g8Hh83i7Sj6Uk60l4Om38n2To2Qp2Fqu2Er1Os0Qt04ursu6vUwOyLzG;aJeHoG;e,la,ra;lGna;da,ma;da,ra;as7EeHol1TvG;et7onB9;le0sen3;an9endBNhiB4iG;lInG;if3AniGo0;e,f39;a,helmi0lGma;a,ow;aMeJiG;cHviG;an9XenG1;kCZtor3;da,l8Vnus,rG;a,nGoniD2;a,iDC;leGnesEC;nDLrG;i1y;aSePhNiMoJrGu6y4;acG3iGu0E;c3na,sG;h9Mta;nHrG;a,i;i9Jya;a5IffaCGna,s5;al3eGomasi0;a,l8Go6Xres1;g7Uo6WrHssG;!a,ie;eFi,ri8;bNliMmKnIrHs5tGwa0;ia0um;a,yn;iGya;a,ka,s5;a4e4iGmCAra;!ka;a,t5;at5it5;a05carlet2Ye04hUiSkye,oQtMuHyG;bFJlvi1;e,sHzG;an2Tet7ie,y;anGi8;!a,e,nG;aEe;aIeG;fGl3DphG;an2;cF8r6;f3nGphi1;d4ia,ja,ya;er4lv3mon1nGobh75;dy;aKeGirlBLo0y6;ba,e0i6lIrG;iGrBPyl;!d70;ia,lBV;ki4nIrHu0w0yG;la,na;i,leAon,ron;a,da,ia,nGon;a,on;l5Yre0;bMdLi9lKmIndHrGs5vannaE;aEi0;ra,y;aGi4;nt5ra;lBNome;e,ie;in1ri0;a02eXhViToHuG;by,thBK;bQcPlOnNsHwe0xG;an94ie,y;aHeGie,lC;ann8ll1marBFtB;!lGnn1;iGyn;e,nG;a,d7W;da,i,na;an9;hel53io;bin,erByn;a,cGkki,na,ta;helBZki;ea,iannDXoG;da,n12;an0bIgi0i0nGta,y0;aGee;!e,ta;a,eG;cARkaE;chGe,i0mo0n5EquCDvDy0;aCCelGi9;!e,le;een2ia0;aMeLhJoIrG;iGudenAW;scil1Uyamva9;lly,rt3;ilome0oebe,ylG;is,lis;arl,ggy,nelope,r6t4;ige,m0Fn4Oo6rvaBBtHulG;a,et7in1;ricGsy,tA8;a,e,ia;ctav3deHfAWlGphAW;a,ga,iv3;l3t7;aQePiJoGy6;eHrG;aEeDma;ll1mi;aKcIkGla,na,s5ta;iGki;!ta;hoB2k8BolG;a,eBH;!mh;l7Tna,risF;dIi5PnHo23taG;li1s5;cy,et7;eAiCO;a01ckenz2eViLoIrignayani,uriBGyG;a,rG;a,na,tAS;i4ll9XnG;a,iG;ca,ka,qB4;a,chOkaNlJmi,nIrGtzi;aGiam;!n9;a,dy,erva,h,n2;a,dIi9JlG;iGy;cent,e;red;!e6;ae6el3G;ag4KgKi,lHrG;edi61isFyl;an2iGliF;nGsAM;a,da;!an,han;b08c9Ed06e,g04i03l01nZrKtJuHv6Sx87yGz2;a,bell,ra;de,rG;a,eD;h75il9t2;a,cSgOiJjor2l6In2s5tIyG;!aGbe5QjaAlou;m,n9S;a,ha,i0;!aIbALeHja,lCna,sGt53;!a,ol,sa;!l06;!h,m,nG;!a,e,n1;arIeHie,oGr3Kueri7;!t;!ry;et3IiB;elGi61y;a,l1;dGon,ue6;akranBy;iGlo36;a,ka,n9;a,re,s2;daGg2;!l2W;alCd2elGge,isBGon0;eiAin1yn;el,le;a0Ie08iWoQuKyG;d3la,nG;!a,dHe9SnGsAQ;!a,e9R;a,sAO;aB1cJelIiFlHna,pGz;e,iB;a,u;a,la;iGy;a2Ae,l25n9;is,l1GrHtt2uG;el6is1;aIeHi8na,rG;a6Zi8;lei,n1tB;!in1;aQbPd3lLnIsHv3zG;!a,be4Ket7z2;a,et7;a,dG;a,sGy;ay,ey,i,y;a,iaIlG;iGy;a8Ge;!n4F;b7Terty;!n5R;aNda,e0iLla,nKoIslARtGx2;iGt2;c3t3;la,nGra;a,ie,o4;a,or1;a,gh,laG;!ni;!h,nG;a,d4e,n4N;cNdon7Si6kes5na,rMtKurIvHxGy6;mi;ern1in3;a,eGie,yn;l,n;as5is5oG;nya,ya;a,isF;ey,ie,y;aZeUhadija,iMoLrIyG;lGra;a,ee,ie;istGy5B;a,en,iGy;!e,n48;ri,urtn9A;aMerLl99mIrGzzy;a,stG;en,in;!berlG;eGi,y;e,y;a,stD;!na,ra;el6PiJlInHrG;a,i,ri;d4na;ey,i,l9Qs2y;ra,s5;c8Wi5XlOma6nyakumari,rMss5LtJviByG;!e,lG;a,eG;e,i78;a5EeHhGi3PlCri0y;ar5Cer5Cie,leDr9Fy;!lyn73;a,en,iGl4Uyn;!ma,n31sF;ei72i,l2;a04eVilToMuG;anKdJliGst56;aHeGsF;!nAt0W;!n8X;i2Ry;a,iB;!anLcelCd5Vel71han6IlJni,sHva0yG;a,ce;eGie;fi0lCph4X;eGie;en,n1;!a,e,n36;!i10lG;!i0Z;anLle0nIrHsG;i5Qsi5Q;i,ri;!a,el6Pif1RnG;a,et7iGy;!e,f1P;a,e72iHnG;a,e71iG;e,n1;cLd1mi,nHqueliAsmin2Uvie4yAzG;min8;a8eHiG;ce,e,n1s;!lGsFt06;e,le;inHk2lCquelG;in1yn;da,ta;lPmNnMo0rLsHvaG;!na;aHiGob6U;do4;!belGdo4;!a,e,l2G;en1i0ma;a,di4es,gr5R;el9ogG;en1;a,eAia0o0se;aNeKilHoGyacin1N;ll2rten1H;aHdGlaH;a,egard;ry;ath0WiHlGnrietBrmiAst0W;en24ga;di;il75lKnJrGtt2yl75z6D;iGmo4Fri4G;etG;!te;aEnaE;ey,l2;aYeTiOlMold12rIwG;enGyne18;!dolC;acHetGisel9;a,chD;e,ieG;!la;adys,enGor3yn1Y;a,da,na;aJgi,lHna,ov71selG;a,e,le;da,liG;an;!n0;mYnIorgHrG;ald35i,m2Stru73;et7i5T;a,eGna;s1Nvieve;briel3Fil,le,rnet,yle;aReOio0loMrG;anHe9iG;da,e9;!cG;esHiGoi0G;n1s3V;!ca;!rG;a,en43;lHrnG;!an9;ec3ic3;rHtiGy8;ma;ah,rah;d0FileDkBl00mUn4ArRsMtLuKvG;aIelHiG;e,ta;in0Ayn;!ngel2H;geni1la,ni3R;h52ta;meral9peranJtG;eHhGrel6;er;l2Pr;za;iGma,nest29yn;cGka,n;a,ka;eJilImG;aGie,y;!liA;ee,i1y;lGrald;da,y;aTeRiMlLma,no4oJsIvG;a,iG;na,ra;a,ie;iGuiG;se;a,en,ie,y;a0c3da,nJsGzaH;aGe;!beG;th;!a,or;anor,nG;!a;in1na;en,iGna,wi0;e,th;aWeKiJoGul2U;lor51miniq3Yn30rGtt2;a,eDis,la,othGthy;ea,y;an09naEonAx2;anPbOde,eNiLja,lImetr3nGsir4U;a,iG;ce,se;a,iHla,orGphiA;es,is;a,l5J;dGrdG;re;!d4Mna;!b2CoraEra;a,d4nG;!a,e;hl3i0mMnKphn1rHvi1WyG;le,na;a,by,cHia,lG;a,en1;ey,ie;a,et7iG;!ca,el1Aka;arGia;is;a0Qe0Mh04i02lUoJrHynG;di,th3;istGy04;al,i0;lOnLrHurG;tn1D;aId28iGn28riA;!nG;a,e,n1;!l1S;n2sG;tanGuelo;ce,za;eGleD;en,t7;aIeoHotG;il4B;!pat4;ir8rIudG;et7iG;a,ne;a,e,iG;ce,sX;a4er4ndG;i,y;aPeMloe,rG;isHyG;stal;sy,tG;aHen,iGy;!an1e,n1;!l;lseHrG;!i8yl;a,y;nLrG;isJlHmG;aiA;a,eGot7;n1t7;!sa;d4el1PtG;al,el1O;cHlG;es7i3F;el3ilG;e,ia,y;iYlXmilWndVrNsLtGy6;aJeIhGri0;erGleDrCy;in1;ri0;li0ri0;a2GsG;a2Fie;a,iMlKmeIolHrG;ie,ol;!e,in1yn;lGn;!a,la;a,eGie,y;ne,y;na,sF;a0Di0D;a,e,l1;isBl2;tlG;in,yn;arb0CeYianXlVoTrG;andRePiIoHyG;an0nn;nwCok8;an2NdgKg0ItG;n27tG;!aHnG;ey,i,y;ny;etG;!t8;an0e,nG;da,na;i8y;bbi8nG;iBn2;ancGossom,ythe;a,he;ca;aRcky,lin9niBrNssMtIulaEvG;!erlG;ey,y;hHsy,tG;e,i0Zy8;!anG;ie,y;!ie;nGt5yl;adHiG;ce;et7iA;!triG;ce,z;a4ie,ra;aliy29b24d1Lg1Hi19l0Sm0Nn01rWsNthe0uJvIyG;anGes5;a,na;a,r25;drIgusHrG;el3;ti0;a,ey,i,y;hHtrG;id;aKlGt1P;eHi8yG;!n;e,iGy;gh;!nG;ti;iIleHpiB;ta;en,n1t7;an19elG;le;aYdWeUgQiOja,nHtoGya;inet7n3;!aJeHiGmI;e,ka;!mGt7;ar2;!belHliFmT;sa;!le;ka,sGta;a,sa;elGie;a,iG;a,ca,n1qG;ue;!t7;te;je6rea;la;!bHmGstas3;ar3;el;aIberHel3iGy;e,na;!ly;l3n9;da;aTba,eNiKlIma,yG;a,c3sG;a,on,sa;iGys0J;e,s0I;a,cHna,sGza;a,ha,on,sa;e,ia;c3is5jaIna,ssaIxG;aGia;!nd4;nd4;ra;ia;i0nHyG;ah,na;a,is,naE;c5da,leDmLnslKsG;haElG;inGyW;g,n;!h;ey;ee;en;at5g2nG;es;ie;ha;aVdiSelLrG;eIiG;anLenG;a,e,ne;an0;na;aKeJiHyG;nn;a,n1;a,e;!ne;!iG;de;e,lCsG;on;yn;!lG;iAyn;ne;agaJbHiG;!gaI;ey,i8y;!e;il;ah", "Place": "true¦a07b05cZdYeXfVgRhQiOjfk,kMlKmHneEoDp9que,rd,s8t5u4v3w0yyz;is1y0;!o;!c;a,t;pYsafa,t;e1he 0;bronx,hamptons;nn,x;ask,fo,oho,t,under6yd;a2e1h0;l,x;k,nnK;!cifX;kla,nt;b1w eng0;land;!r;a1co,i0t,uc;dKnn;libu,nhattS;a0gw,hr;s,x;an0ul;!s;a0cn,da,ndianMst;!x;arlem,kg,nd,wy;a2re0;at 0enwich;britain,lak6;!y village;co,l0ra;!a;urope,verglad2;ak,en,fw,ist,own4xb;al4dg,gk,hina3l2o1r0t;es;lo,nn;!t;town;!if;cn,e0kk,lvd,rooklyn;l air,verly hills;frica,lta,m5ntarct2r1sia,tl0ve;!ant1;ct0iz;ic0; oce0;an;ericas,s", "WeekDay": "true¦fri2mon2s1t0wednesd3;hurs1ues1;aturd1und1;!d0;ay0;!s", "Month": "true¦aBdec9feb7j2mar,nov9oct1sep0;!t8;!o8;an3u0;l1n0;!e;!y;!u1;!ru0;ary;!em0;ber;pr1ug0;!ust;!il", - "Date": "true¦t0weekend,yesterd2;mr2o0;d0morrow;ay;!w", + "Date": "true¦ago,t0weekend,yesterd2;mr2o0;d0morrow;ay;!w", "FirstName": "true¦aEblair,cCdevBj8k6lashawn,m3nelly,quinn,re2sh0;ay,e0iloh;a,lby;g1ne;ar1el,org0;an;ion,lo;as8e0r9;ls7nyatta,rry;am0ess1ude;ie,m0;ie;an,on;as0heyenne;ey,sidy;lex1ndra,ubr0;ey;is", "LastName": "true¦0:34;1:3B;2:39;3:2Y;4:2E;5:30;a3Bb31c2Od2Ee2Bf25g1Zh1Pi1Kj1Ek17l0Zm0Nn0Jo0Gp05rYsMtHvFwCxBy8zh6;a6ou,u;ng,o;a6eun2Uoshi1Kun;ma6ng;da,guc1Zmo27sh21zaR;iao,u;a7eb0il6o3right,u;li3Bs2;gn0lk0ng,tanabe;a6ivaldi;ssilj37zqu1;a9h8i2Go7r6sui,urn0;an,ynisJ;lst0Prr1Uth;at1Uomps2;kah0Vnaka,ylor;aEchDeChimizu,iBmiAo9t7u6zabo;ar1lliv2AzuE;a6ein0;l23rm0;sa,u3;rn4th;lva,mmo24ngh;mjon4rrano;midt,neid0ulz;ito,n7sa6to;ki;ch1dLtos,z;amBeag1Zi9o7u6;bio,iz,sD;b6dri1MgIj0Tme24osevelt,ssi,ux;erts,ins2;c6ve0F;ci,hards2;ir1os;aEeAh8ic6ow20ut1N;as6hl0;so;a6illips;m,n1T;ders5et8r7t6;e0Nr4;ez,ry;ers;h21rk0t6vl4;el,te0J;baBg0Blivei01r6;t6w1O;ega,iz;a6eils2guy5ix2owak,ym1E;gy,ka6var1K;ji6muW;ma;aEeCiBo8u6;ll0n6rr0Bssolini,ñ6;oz;lina,oKr6zart;al0Me6r0U;au,no;hhail4ll0;rci0ssi6y0;!er;eWmmad4r6tsu07;in6tin1;!o;aCe8i6op1uo;!n6u;coln,dholm;fe7n0Qr6w0J;oy;bv6v6;re;mmy,rs5u;aBennedy,imuAle0Lo8u7wo6;k,n;mar,znets4;bay6vacs;asY;ra;hn,rl9to,ur,zl4;aAen9ha3imen1o6u3;h6nYu3;an6ns2;ss2;ki0Es5;cks2nsse0D;glesi9ke8noue,shik7to,vano6;u,v;awa;da;as;aBe8itchcock,o7u6;!a3b0ghNynh;a3ffmann,rvat;mingw7nde6rN;rs2;ay;ns5rrQs7y6;asDes;an4hi6;moJ;a9il,o8r7u6;o,tierr1;ayli3ub0;m1nzal1;nd6o,rcia;hi;erAis9lor8o7uj6;ita;st0urni0;es;ch0;nand1;d7insteHsposi6vaL;to;is2wards;aCeBi9omin8u6;bo6rand;is;gu1;az,mitr4;ov;lgado,vi;nkula,rw7vi6;es,s;in;aFhBlarkAo6;h5l6op0rbyn,x;em7li6;ns;an;!e;an8e7iu,o6ristens5u3we;i,ng,u3w,y;!n,on6u3;!g;mpb7rt0st6;ro;ell;aBe8ha3lanco,oyko,r6yrne;ooks,yant;ng;ck7ethov5nnett;en;er,ham;ch,h8iley,rn6;es,i0;er;k,ng;dDl9nd6;ers6rA;en,on,s2;on;eks7iy8var1;ez;ej6;ev;ams", "MaleName": "true¦0:CE;1:BL;2:C2;3:BT;4:B5;5:BZ;6:AT;7:9V;8:BD;9:AX;A:AO;aB4bA8c97d87e7Gf6Yg6Gh5Wi5Ij4Lk4Bl3Rm2Pn2Eo28p22qu20r1As0Qt06u05v00wNxavi3yGzB;aBor0;cBh8Ine;hCkB;!aB1;ar51eB0;ass2i,oCuB;sDu25;nEsDusB;oBsC;uf;ef;at0g;aJeHiCoByaAP;lfgang,odrow;lBn1O;bDey,frBJlB;aA5iB;am,e,s;e89ur;i,nde7sB;!l6t1;de,lCrr5yB;l1ne;lBt3;a93y;aEern1iBladimir;cCha0kt5CnceBrg9Bva0;!nt;ente,t5A;lentin49n8Yughn;lyss4Msm0;aTeOhKiIoErCyB;!l3ro8s1;av9QeBist0oy,um0;nt9Iv54y;bDd7XmBny;!as,mBoharu;aAYie,y;i83y;mBt9;!my,othy;adDeoCia7DomB;!as;!do7M;!de9;dErB;en8HrB;an8GeBy;ll,n8F;!dy;dgh,ic9Tnn3req,ts45;aRcotPeNhJiHoFpenc3tBur1Oylve8Hzym1;anDeBua7B;f0phAFvBwa7A;e57ie;!islaw,l6;lom1nA3uB;leyma8ta;dBl7Jm1;!n6;aDeB;lBrm0;d1t1;h6Sne,qu0Uun,wn,y8;aBbasti0k1Xl41rg40th,ymo9I;m9n;!tB;!ie,y;lCmBnti21q4Iul;!mAu4;ik,vato6V;aWeShe92iOoFuCyB;an,ou;b6LdCf9pe6QssB;!elAI;ol2Uy;an,bIcHdGel,geFh0landA9mEnDry,sCyB;!ce;coe,s;!a95nA;an,eo;l3Jr;e4Qg3n6olfo,ri68;co,ky;bAe9U;cBl6;ar5Oc5NhCkBo;!ey,ie,y;a85ie;gCid,ub5x,yBza;ansh,nS;g8WiB;na8Ss;ch5Yfa4lDmCndBpha4sh6Uul,ymo70;al9Yol2By;i9Ion;f,ph;ent2inB;cy,t1;aFeDhilCier62ol,reB;st1;!ip,lip;d9Brcy,tB;ar,e2V;b3Sdra6Ft44ul;ctav2Vliv3m96rFsCtBum8Uw5;is,to;aCc8SvB;al52;ma;i,l49vJ;athJeHiDoB;aBel,l0ma0r2X;h,m;cCg4i3IkB;h6Uola;hol5XkBol5X;!ol5W;al,d,il,ls1vB;il50;anBy;!a4i4;aWeTiKoFuCyB;l21r1;hamCr5ZstaB;fa,p4G;ed,mF;dibo,e,hamDis1XntCsBussa;es,he;e,y;ad,ed,mB;ad,ed;cGgu4kElDnCtchB;!e7;a78ik;house,o03t1;e,olB;aj;ah,hBk6;a4eB;al,l;hClv2rB;le,ri7v2;di,met;ck,hNlLmOnu4rHs1tDuricCxB;!imilian8Cwe7;e,io;eo,hCi52tB;!eo,hew,ia;eBis;us,w;cDio,k86lCqu6Gsha7tBv2;i2Hy;in,on;!el,oKus;achBcolm,ik;ai,y;amBdi,moud;adB;ou;aReNiMlo2RoIuCyB;le,nd1;cEiDkBth3;aBe;!s;gi,s;as,iaB;no;g0nn6RrenDuBwe7;!iB;e,s;!zo;am,on4;a7Bevi,la4SnDoBst3vi;!nB;!a60el;!ny;mCnBr67ur4Twr4T;ce,d1;ar,o4N;aIeDhaled,iBrist4Vu48y3B;er0p,rB;by,k,ollos;en0iEnBrmit,v2;!dCnBt5C;e0Yy;a7ri4N;r,th;na68rBthem;im,l;aYeQiOoDuB;an,liBst2;an,o,us;aqu2eJhnInGrEsB;eChBi7Bue;!ua;!ph;dBge;an,i,on;!aBny;h,s,th4X;!ath4Wie,nA;!l,sBy;ph;an,e,mB;!mA;d,ffGrDsB;sBus;!e;a5JemCmai8oBry;me,ni0O;i6Uy;!e58rB;ey,y;cHd5kGmFrDsCvi3yB;!d5s1;on,p3;ed,od,rBv4M;e4Zod;al,es,is1;e,ob,ub;k,ob,quB;es;aNbrahMchika,gKkeJlija,nuIrGsDtBv0;ai,sB;uki;aBha0i6Fma4sac;ac,iaB;h,s;a,vinBw2;!g;k,nngu52;!r;nacBor;io;im;in,n;aJeFina4VoDuByd56;be25gBmber4CsD;h,o;m3ra33sBwa3X;se2;aDctCitCn4ErB;be20m0;or;th;bKlJmza,nIo,rDsCyB;a43d5;an,s0;lEo4FrDuBv6;hi40ki,tB;a,o;is1y;an,ey;k,s;!im;ib;aQeMiLlenKoIrEuB;illerCsB;!tavo;mo;aDegBov3;!g,orB;io,y;dy,h57nt;nzaBrd1;lo;!n;lbe4Qno,ovan4R;ne,oDrB;aBry;ld,rd4U;ffr6rge;bri4l5rBv2;la1Zr3Eth,y;aReNiLlJorr0IrB;anDedBitz;!dAeBri24;ri23;cDkB;!ie,lB;in,yn;esJisB;!co,zek;etch3oB;yd;d4lBonn;ip;deriDliCng,rnB;an01;pe,x;co;bi0di;arZdUfrTit0lNmGnFo2rCsteb0th0uge8vBym5zra;an,ere2V;gi,iCnBrol,v2w2;est45ie;c07k;och,rique,zo;aGerFiCmB;aFe2P;lCrB;!h0;!io;s1y;nu4;be09d1iEliDmCt1viBwood;n,s;er,o;ot1Ts;!as,j43sB;ha;a2en;!dAg32mEuCwB;a25in;arB;do;o0Su0S;l,nB;est;aYeOiLoErDuCwByl0;ay8ight;a8dl6nc0st2;ag0ew;minFnDri0ugCyB;le;!l03;!a29nBov0;e7ie,y;go,icB;!k;armuCeBll1on,rk;go;id;anIj0lbeHmetri9nFon,rEsDvCwBxt3;ay8ey;en,in;hawn,mo08;ek,ri0F;is,nBv3;is,y;rt;!dB;re;lKmInHrDvB;e,iB;!d;en,iDne7rByl;eBin,yl;l2Vn;n,o,us;!e,i4ny;iBon;an,en,on;e,lB;as;a06e04hWiar0lLoGrEuCyrB;il,us;rtB;!is;aBistobal;ig;dy,lEnCrB;ey,neli9y;or,rB;ad;by,e,in,l2t1;aGeDiByI;fBnt;fo0Ct1;meCt9velaB;nd;nt;rDuCyB;!t1;de;enB;ce;aFeErisCuB;ck;!tB;i0oph3;st3;d,rlBs;eBie;s,y;cBdric,s11;il;lEmer1rB;ey,lCro7y;ll;!os,t1;eb,v2;ar02eUilTlaSoPrCuByr1;ddy,rtI;aJeEiDuCyB;an,ce,on;ce,no;an,ce;nCtB;!t;dCtB;!on;an,on;dCndB;en,on;!foBl6y;rd;bCrByd;is;!by;i8ke;al,lA;nFrBshoi;at,nCtB;!r10;aBie;rd0S;!edict,iCjam2nA;ie,y;to;n6rBt;eBy;tt;ey;ar0Xb0Nd0Jgust2hm0Gid5ja0ElZmXnPputsiOrFsaEuCveBya0ziz;ry;gust9st2;us;hi;aIchHi4jun,maFnDon,tBy0;hBu06;ur;av,oB;ld;an,nd0A;el;ie;ta;aq;dGgel05tB;hoEoB;i8nB;!i02y;ne;ny;reBy;!as,s,w;ir,mBos;ar;an,beOd5eIfFi,lEonDphonHt1vB;aMin;on;so,zo;an,en;onCrB;edP;so;c,jaEksandDssaExB;!and3;er;ar,er;ndB;ro;rtH;ni;en;ad,eB;d,t;in;aColfBri0vik;!o;mBn;!a;dFeEraCuB;!bakr,lfazl;hBm;am;!l;allEel,oulaye,ulB;!lCrahm0;an;ah,o;ah;av,on", @@ -7220,12 +7225,28 @@ }; var _02Insert = createCommonjsModule(function (module, exports) { + // if it's empty, just create the phrase + var makeNew = function makeNew(str, doc) { + var phrase = _01Tokenizer(str, doc.world)[0]; //assume it's one sentence, for now + + var tmpDoc = doc.buildFrom([phrase]); + tmpDoc.tagger(); + doc.list = tmpDoc.list; + return doc; + }; /** add these new terms to the end*/ + + exports.append = function (str) { var _this = this; if (!str) { return this; + } // if it's empty, just create the phrase + + + if (!this.found) { + return makeNew(str, this); } // clear the cache @@ -7254,6 +7275,11 @@ if (!str) { return this; + } // if it's empty, just create the phrase + + + if (!this.found) { + return makeNew(str, this); } // clear the cache @@ -7408,14 +7434,17 @@ // console.log(t.post) // return n // }, 0) - // offset information for the entire doc starts at the first term, and - // is as long as the whole text (note that there may be an issue where - // leading punctuation is counted in the doc text length, but is - // *excluded* from the term[0] start position) - - o.offset = Object.assign({}, o.terms[0].offset, { + // The offset information for the entire doc starts at (or just before) + // the first term, and is as long as the whole text. The code originally + // copied the entire offset value from terms[0], but since we're now + // overriding 2 of the three fields, it's cleaner to just create an all- + // new object and not pretend it's "just" the same as terms[0]. + + o.offset = { + index: o.terms[0].offset.index, + start: o.terms[0].offset.start - o.text.indexOf(o.terms[0].text), length: o.text.length - }); + }; }); } }; @@ -8897,6 +8926,7 @@ [/^[a-z0-9]*? o\'?clock$/, 'Time'], //3 oclock [/^[0-9]{1,4}-[0-9]{1,2}-[0-9]{1,4}$/, 'Date'], // 03-02-89 [/^[0-9]{1,4}\/[0-9]{1,2}\/[0-9]{1,4}$/, 'Date'], // 03/02/89 + [/^[0-9]{1,4}-[a-z]{2,9}-[0-9]{1,4}$/i, 'Date'], // 03-March-89 //names [/^ma?c\'.*/, 'LastName'], //mc'adams [/^o\'[drlkn].*/, 'LastName'], //o'douggan @@ -9114,6 +9144,7 @@ gone: Adj$1, ices: Plrl, ints: Plrl, + ines: Plrl, ions: Plrl, less: Avb, llen: Adj$1, @@ -10519,13 +10550,13 @@ { match: "#Adverb [(march|may)]", group: 0, - tag: 'Infinitive', + tag: 'Verb', reason: 'quickly-march' }, //march quickly { - match: "(march|may) [#Adverb]", + match: "[(march|may)] #Adverb", group: 0, - tag: 'Infinitive', + tag: 'Verb', reason: 'march-quickly' }, //5th of March { @@ -10663,9 +10694,15 @@ match: '#Place+ #Possessive', tag: 'Possessive', reason: 'place-possessive' + }, // assign all tasks + { + match: '#Verb (all|every|each|most|some|no) [#PresentTense]', + group: 0, + tag: 'Noun', + reason: 'all-presentTense' }, //big dreams, critical thinking { - match: '#Adjective [#PresentTense]', + match: '(#Adjective && !all) [#PresentTense]', group: 0, tag: 'Noun', reason: 'adj-presentTense' @@ -11075,7 +11112,7 @@ reason: 'magnitude-and-value' }, //'a/an' can mean 1 - "a hour" { - match: '[(a|an)] (#Duration|hundred|thousand|million|billion|trillion)', + match: '!once [(a|an)] (#Duration|hundred|thousand|million|billion|trillion)', group: 0, tag: 'Value', reason: 'a-is-one' @@ -11110,7 +11147,7 @@ reason: 'had-walked' }, //would walk { - match: "[(#Modal|did) (#Adverb|not)+?] #Verb", + match: "[#Adverb+? (#Modal|did)+ (#Adverb|not)+?] #Verb", group: 0, tag: 'Auxiliary', reason: 'modal-verb' @@ -11144,12 +11181,6 @@ group: 0, tag: 'Auxiliary', reason: 'had-walked' - }, //would walk - { - match: "[(#Modal|did) (#Adverb|not)+?] #Verb", - group: 0, - tag: 'Auxiliary', - reason: 'modal-verb' }, // will walk { match: '[(do|does|will|have|had)] (not|#Adverb)? #Verb', @@ -11182,7 +11213,7 @@ reason: 'had-been' }, // was being driven { - match: '[being] #Participle', + match: '[(be|being|been)] #Participle', group: 0, tag: 'Auxiliary', reason: 'being-foo' @@ -11608,7 +11639,7 @@ group: 0, tag: 'Person', reason: 'ambig-active-for' - }, // may waits for + }, // may waits to { match: "[".concat(months, "] #PresentTense to"), group: 0, @@ -12971,7 +13002,12 @@ if (parsed.auxiliary.found) { - parsed.auxiliary.eq(0).append('not'); + parsed.auxiliary.eq(0).append('not'); // 'would not have' ➔ 'would not have' + + if (parsed.auxiliary.has('#Modal have not')) { + parsed.auxiliary.replace('have not', 'not have'); + } + return; } // is walking -> is not walking @@ -13033,11 +13069,11 @@ // 'really' negative: vb.match('#Negative'), // 'not' - auxiliary: vb.match('#Auxiliary').not('(#Negative|#Adverb)'), + auxiliary: vb.match('#Auxiliary+').not('(#Negative|#Adverb)'), // 'will' of 'will go' particle: vb.match('#Particle'), // 'up' of 'pull up' - verb: vb.match('#Verb').not('(#Adverb|#Negative|#Auxiliary|#Particle)') + verb: vb.match('#Verb+').not('(#Adverb|#Negative|#Auxiliary|#Particle)') }; // fallback, if no verb found if (!parsed.verb.found) { @@ -13116,11 +13152,34 @@ var toBe_1 = toBe; + // 'may/could/should' -> 'may/could/should have' + var doModal = function doModal(parsed) { + var str = parsed.verb.text(); + var res = { + PastTense: str + ' have', + PresentTense: str, + FutureTense: str, + Infinitive: str // Gerund: , + // Actor: '', + // PerfectTense: '', + // Pluperfect: '', + + }; + return res; + }; + + var doModal_1 = doModal; + var conjugate$2 = function conjugate(parsed, world) { var verb = parsed.verb; //special handling of 'is', 'will be', etc. if (verb.has('#Copula') || verb.out('normal') === 'be' && parsed.auxiliary.has('will')) { return toBe_1(parsed); + } // special handling of 'he could.' + + + if (verb.has('#Modal')) { + return doModal_1(parsed); } var hasHyphen = parsed.verb.termList(0).hasHyphen(); @@ -13140,23 +13199,16 @@ return forms[k] += space + particle; }); } //put the adverb at the end? - - - if (parsed.adverb.found) { - var adverb = parsed.adverb.text(); - - var _space = hasHyphen === true ? '-' : ' '; - - if (parsed.adverbAfter === true) { - Object.keys(forms).forEach(function (k) { - return forms[k] += _space + adverb; - }); - } else { - Object.keys(forms).forEach(function (k) { - return forms[k] = adverb + _space + forms[k]; - }); - } - } //apply negative + // if (parsed.adverb.found) { + // let adverb = parsed.adverb.text() + // let space = hasHyphen === true ? '-' : ' ' + // if (parsed.adverbAfter === true) { + // Object.keys(forms).forEach(k => (forms[k] += space + adverb)) + // } else { + // Object.keys(forms).forEach(k => (forms[k] = adverb + space + forms[k])) + // } + // } + //apply negative var isNegative = parsed.negative.found; @@ -13185,6 +13237,82 @@ var conjugate_1$1 = conjugate$2; + // if something is 'modal-ish' we are forced to use past-participle + // ('i could drove' is wrong) + + var useParticiple = function useParticiple(parsed) { + if (parsed.auxiliary.has('(could|should|would|may|can|must)')) { + return true; + } + + if (parsed.auxiliary.has('am .+? being')) { + return true; + } + + if (parsed.auxiliary.has('had .+? been')) { + return true; + } + + return false; + }; // conjugate 'drive' ➔ 'have driven' + + + var toParticiple = function toParticiple(parsed, world) { + //is it already a participle? + if (parsed.auxiliary.has('(have|had)') && parsed.verb.has('#Participle')) { + return; + } // try to swap the main verb to its participle form + + + var obj = conjugate_1$1(parsed, world); + var str = obj.Participle || obj.PastTense; + + if (str) { + parsed.verb.replaceWith(str, false); + } // 'am being driven' ➔ 'have been driven' + + + if (parsed.auxiliary.has('am .+? being')) { + parsed.auxiliary.remove('am'); + parsed.auxiliary.replace('being', 'have been'); + } // add a 'have' + + + if (!parsed.auxiliary.has('have')) { + parsed.auxiliary.append('have'); + } // tag it as a participle + + + parsed.verb.tag('Participle', 'toParticiple'); // turn 'i can swim' to -> 'i could swim' + + parsed.auxiliary.replace('can', 'could'); //'must be' ➔ 'must have been' + + parsed.auxiliary.replace('be have', 'have been'); //'not have' ➔ 'have not' + + parsed.auxiliary.replace('not have', 'have not'); // ensure all new words are tagged right + + parsed.auxiliary.tag('Auxiliary'); + }; + + var participle = { + useParticiple: useParticiple, + toParticiple: toParticiple + }; + + var _toParticiple = participle.toParticiple, + useParticiple$1 = participle.useParticiple; // remove any tense-information in auxiliary verbs + + var makeNeutral = function makeNeutral(parsed) { + //remove tense-info from auxiliaries + parsed.auxiliary.remove('(will|are|am|being)'); + parsed.auxiliary.remove('(did|does)'); + parsed.auxiliary.remove('(had|has|have)'); //our conjugation includes the 'not' and the phrasal-verb particle + + parsed.particle.remove(); + parsed.negative.remove(); + return parsed; + }; + var methods$7 = { /** overload the original json with verb information */ json: function json(options) { @@ -13254,6 +13382,7 @@ return this.buildFrom(list); }, + /// Verb Inflection /**return verbs like 'we walk' and not 'spencer walks' */ isPlural: function isPlural() { @@ -13284,8 +13413,9 @@ }); return this.buildFrom(list); }, + /// Conjugation - /** */ + /** return all forms of this verb */ conjugate: function conjugate() { var _this4 = this; @@ -13300,23 +13430,30 @@ return result; }, - /** */ + /** walk ➔ walked*/ toPastTense: function toPastTense() { var _this5 = this; this.forEach(function (vb) { - var parsed = parse$2(vb); + var parsed = parse$2(vb); // should we support 'would swim' ➔ 'would have swam' + + if (useParticiple$1(parsed)) { + _toParticiple(parsed, _this5.world); + + return; + } var str = conjugate_1$1(parsed, _this5.world).PastTense; if (str) { - vb.replaceWith(str, false); // vb.tag('PastTense') + parsed = makeNeutral(parsed); + parsed.verb.replaceWith(str, false); // vb.tag('PastTense') } }); return this; }, - /** */ + /** walk ➔ walks */ toPresentTense: function toPresentTense() { var _this6 = this; @@ -13332,31 +13469,53 @@ } if (str) { - vb.replaceWith(str, false); - vb.tag('PresentTense'); + //awkward support for present-participle form + // -- should we support 'have been swimming' ➔ 'am swimming' + if (parsed.auxiliary.has('(have|had) been')) { + parsed.auxiliary.replace('(have|had) been', 'am being'); + + if (obj.Particle) { + str = obj.Particle || obj.PastTense; + } + + return; + } + + parsed.verb.replaceWith(str, false); + parsed.verb.tag('PresentTense'); + parsed = makeNeutral(parsed); // avoid 'he would walks' + + parsed.auxiliary.remove('#Modal'); } }); return this; }, - /** */ + /** walk ➔ will walk*/ toFutureTense: function toFutureTense() { var _this7 = this; this.forEach(function (vb) { - var parsed = parse$2(vb); + var parsed = parse$2(vb); // 'i should drive' is already future-enough + + if (useParticiple$1(parsed)) { + return; + } var str = conjugate_1$1(parsed, _this7.world).FutureTense; if (str) { - vb.replaceWith(str, false); - vb.tag('FutureTense'); + parsed = makeNeutral(parsed); // avoid 'he would will go' + + parsed.auxiliary.remove('#Modal'); + parsed.verb.replaceWith(str, false); + parsed.verb.tag('FutureTense'); } }); return this; }, - /** */ + /** walks ➔ walk */ toInfinitive: function toInfinitive() { var _this8 = this; @@ -13373,7 +13532,7 @@ return this; }, - /** */ + /** walk ➔ walking */ toGerund: function toGerund() { var _this9 = this; @@ -13390,6 +13549,26 @@ return this; }, + /** drive ➔ driven - naked past-participle if it exists, otherwise past-tense */ + toParticiple: function toParticiple() { + var _this10 = this; + + this.forEach(function (vb) { + var parsed = parse$2(vb); + var noAux = !parsed.auxiliary.found; + + _toParticiple(parsed, _this10.world); // dirty trick to ensure our new auxiliary is found + + + if (noAux) { + parsed.verb.prepend(parsed.auxiliary.text()); + parsed.auxiliary.remove(); + } + }); + return this; + }, + /// Negation + /** return only verbs with 'not'*/ isNegative: function isNegative() { return this["if"]('#Negative'); @@ -13402,10 +13581,10 @@ /** add a 'not' to these verbs */ toNegative: function toNegative() { - var _this10 = this; + var _this11 = this; this.list.forEach(function (p) { - var doc = _this10.buildFrom([p]); + var doc = _this11.buildFrom([p]); var parsed = parse$2(doc); diff --git a/builds/compromise.min.js b/builds/compromise.min.js index e03bf7af1..08d737a60 100644 --- a/builds/compromise.min.js +++ b/builds/compromise.min.js @@ -1 +1 @@ -!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).nlp=t()}(this,(function(){"use strict";function e(t){return(e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(t)}function t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){for(var r=0;re.length)&&(t=e.length);for(var r=0,n=new Array(t);rn[t].lineage.length?1:n[e].isA.length>n[t].isA.length?-1:0:0:1}))},J={text:!0,tags:!0,implicit:!0,whitespace:!0,clean:!1,id:!1,index:!1,offset:!1,bestTag:!1},q={json:function(e,t){e=e||{};var r={};return(e=Object.assign({},J,e)).text&&(r.text=this.text),e.normal&&(r.normal=this.normal),e.tags&&(r.tags=Object.keys(this.tags)),e.clean&&(r.clean=this.clean),(e.id||e.offset)&&(r.id=this.id),e.implicit&&null!==this.implicit&&(r.implicit=this.implicit),e.whitespace&&(r.pre=this.pre,r.post=this.post),e.bestTag&&(r.bestTag=_(this,t)[0]),r}},K=Object.assign({},N,F,V,S,q);function R(){return"undefined"!=typeof window&&window.document}var W=function(e,t){for(e=e.toString();e.length0&&void 0!==arguments[0]?arguments[0]:"";t(this,e),r=String(r);var n=x(r);this.text=n.text||"",this.clean=n.clean,this.reduced=n.reduced,this.root=null,this.implicit=null,this.pre=n.pre||"",this.post=n.post||"",this.tags={},this.prev=null,this.next=null,this.id=d(n.clean),this.isA="Term",n.alias&&(this.alias=n.alias)}return n(e,[{key:"set",value:function(e){var t=x(e);return this.text=t.text,this.clean=t.clean,this}}]),e}();ie.prototype.clone=function(){var e=new ie(this.text);return e.pre=this.pre,e.post=this.post,e.tags=Object.assign({},this.tags),e},Object.assign(ie.prototype,K),Object.assign(ie.prototype,ae);var oe=ie,se={terms:function(e){if(0===this.length)return[];if(this.cache.terms)return void 0!==e?this.cache.terms[e]:this.cache.terms;for(var t=[this.pool.get(this.start)],r=0;r0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0,r=arguments.length>2?arguments[2]:void 0;"string"==typeof e&&(e="normal"===e?{whitespace:!0,unicode:!0,lowercase:!0,punctuation:!0,acronyms:!0,abbreviations:!0,implicit:!0,normal:!0}:"clean"===e?{titlecase:!1,lowercase:!0,punctuation:!0,whitespace:!0,unicode:!0,implicit:!0}:"reduced"===e?{titlecase:!1,lowercase:!0,punctuation:!1,whitespace:!0,unicode:!0,implicit:!0,reduced:!0}:"root"===e?{titlecase:!1,lowercase:!0,punctuation:!0,whitespace:!0,unicode:!0,implicit:!0,root:!0}:{});var n=this.terms(),a=!1;n[0]&&null===n[0].prev&&null===n[n.length-1].next&&(a=!0);var i=n.reduce((function(i,o,s){e.last=r&&s===n.length-1;var u=!0,l=!0;return!1===a&&(0===s&&t&&(u=!1),s===n.length-1&&r&&(l=!1)),i+o.textOut(e,u,l)}),"");return!0===a&&r&&(i=ue(i)),!0===e.trim&&(i=i.trim()),i}},ce={trim:function(){var e=this.terms();if(e.length>0){e[0].pre=e[0].pre.replace(/^\s+/,"");var t=e[e.length-1];t.post=t.post.replace(/\s+$/,"")}return this}},he=/[.?!]\s*$/,de=function(e,t){t[0].pre=e[0].pre;var r,n,a=e[e.length-1],i=t[t.length-1];i.post=(r=a.post,n=i.post,he.test(n)?n+r.match(/\s*$/):r),a.post="",""===a.post&&(a.post+=" ")},pe=function(e,t,r){var n=e.terms(),a=t.terms();de(n,a),function(e,t,r){var n=e[e.length-1],a=t[t.length-1],i=n.next;(n.next=t[0].id,a.next=i,i)&&(r.get(i).prev=a.id);var o=e[0].id;o&&(t[0].prev=o)}(n,a,e.pool);var i=[e],o=e.start,s=[r];return(s=s.concat(r.parents())).forEach((function(e){var t=e.list.filter((function(e){return e.hasId(o)}));i=i.concat(t)})),(i=function(e){return e.filter((function(t,r){return e.indexOf(t)===r}))}(i)).forEach((function(e){e.length+=t.length})),e.cache={},e},ge=/ /,fe=function(e,t,r){var n=e.start,a=t.terms();!function(e){var t=e[e.length-1];!1===ge.test(t.post)&&(t.post+=" ")}(a),function(e,t,r){var n=r[r.length-1];n.next=e.start;var a=e.pool,i=a.get(e.start);i.prev&&(a.get(i.prev).next=t.start);r[0].prev=e.terms(0).prev,e.terms(0).prev=n.id}(e,t,a);var i=[e],o=[r];return(o=o.concat(r.parents())).forEach((function(e){var r=e.list.filter((function(e){return e.hasId(n)||e.hasId(t.start)}));i=i.concat(r)})),(i=function(e){return e.filter((function(t,r){return e.indexOf(t)===r}))}(i)).forEach((function(e){e.length+=t.length,e.start===n&&(e.start=t.start),e.cache={}})),e},me=function(e,t){var r=t.pool(),n=e.terms(),a=r.get(n[0].prev)||{},i=r.get(n[n.length-1].next)||{};n[0].implicit&&a.implicit&&(a.set(a.implicit),a.post+=" "),function(e,t,r,n){var a=e.parents();a.push(e),a.forEach((function(e){var a=e.list.find((function(e){return e.hasId(t)}));a&&(a.length-=r,a.start===t&&(a.start=n.id),a.cache={})})),e.list=e.list.filter((function(e){return!(!e.start||!e.length)}))}(t,e.start,e.length,i),a&&(a.next=i.id),i&&(i.prev=a.id)},ve={append:function(e,t){return pe(this,e,t),this},prepend:function(e,t){return fe(this,e,t),this},delete:function(e){return me(this,e),this},replace:function(e,t){var r=this.length;pe(this,e,t);var n=this.buildFrom(this.start,this.length);n.length=r,me(n,t)},splitOn:function(e){var t=this.terms(),r={before:null,match:null,after:null},n=t.findIndex((function(t){return t.id===e.start}));if(-1===n)return r;var a=t.slice(0,n);a.length>0&&(r.before=this.buildFrom(a[0].id,a.length));var i=t.slice(n,n+e.length);i.length>0&&(r.match=this.buildFrom(i[0].id,i.length));var o=t.slice(n+e.length,t.length);return o.length>0&&(r.after=this.buildFrom(o[0].id,o.length,this.pool)),r}},be={json:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0,r={};return e.text&&(r.text=this.text()),e.normal&&(r.normal=this.text("normal")),e.clean&&(r.clean=this.text("clean")),e.reduced&&(r.reduced=this.text("reduced")),e.root&&(r.root=this.text("root")),e.trim&&(r.text&&(r.text=r.text.trim()),r.normal&&(r.normal=r.normal.trim()),r.reduced&&(r.reduced=r.reduced.trim())),e.terms&&(!0===e.terms&&(e.terms={}),r.terms=this.terms().map((function(r){return r.json(e.terms,t)}))),r}},ye={lookAhead:function(e){e||(e=".*");var t=this.pool,r=[],n=this.terms();return function e(n){var a=t.get(n);a&&(r.push(a),a.prev&&e(a.next))}(n[n.length-1].next),0===r.length?[]:this.buildFrom(r[0].id,r.length).match(e)},lookBehind:function(e){e||(e=".*");var t=this.pool,r=[];return function e(n){var a=t.get(n);a&&(r.push(a),a.prev&&e(a.prev))}(t.get(this.start).prev),0===r.length?[]:this.buildFrom(r[r.length-1].id,r.length).match(e)}},we=Object.assign({},se,le,ce,ve,be,ye),ke=function(e,t){if(0===t.length)return!0;for(var r=0;r0)return!0;if(!0===n.anything&&!0===n.negative)return!0}return!1},Ae=function(e,t,r,n,a,i){for(var o=t;to)return[!1,null];if(!0===u.end&&r+o!==n)return[!1,null]}if(l){var g=Be(a,c,e,p,u.named);o>1&&u.greedy?g.length+=o-p:g.length++}}else if(!0!==u.optional){if(!(e[o].isImplicit()&&t[s-1]&&e[o+1]&&e[o+1].doesMatch(u,r+o,n)))return[!1,null];o+=2}}else{var f=$e(e,o,t[s+1],u,r);if(void 0!==u.min&&f-ou.max){o+=u.max;continue}if(null===f)return[!1,null];l&&(Be(a,c,e,o,u.named).length=f-o),o=f}}return[e.slice(0,o),a]},Ge=function(e,t,r){if(!r||0===r.length)return r;if(t.some((function(e){return e.end}))){var n=e[e.length-1];r=r.filter((function(e){return-1!==e.match.indexOf(n)}))}return r},Ce=/\{([0-9]+,?[0-9]*)\}/,De=/&&/,je=new RegExp(/^<(\S+)>/),xe=function(e){return e[e.length-1]},Ee=function(e){return e[0]},Ne=function(e){return e.substr(1)},Fe=function(e){return e.substr(0,e.length-1)},Oe=function(e){return e=Ne(e),e=Fe(e)},ze=function e(t){for(var r,n={},a=0;a<2;a+=1){if("$"===xe(t)&&(n.end=!0,t=Fe(t)),"^"===Ee(t)&&(n.start=!0,t=Ne(t)),("["===Ee(t)||"]"===xe(t))&&(n.named=!0,"["===Ee(t)?n.groupType="]"===xe(t)?"single":"start":n.groupType="end",t=(t=t.replace(/^\[/,"")).replace(/\]$/,""),"<"===Ee(t))){var i=je.exec(t);i.length>=2&&(n.named=i[1],t=t.replace(i[0],""))}if("+"===xe(t)&&(n.greedy=!0,t=Fe(t)),"*"!==t&&"*"===xe(t)&&"\\*"!==t&&(n.greedy=!0,t=Fe(t)),"?"===xe(t)&&(n.optional=!0,t=Fe(t)),"!"===Ee(t)&&(n.negative=!0,t=Ne(t)),"("===Ee(t)&&")"===xe(t)){De.test(t)?(n.choices=t.split(De),n.operator="and"):(n.choices=t.split("|"),n.operator="or"),n.choices[0]=Ne(n.choices[0]);var o=n.choices.length-1;n.choices[o]=Fe(n.choices[o]),n.choices=n.choices.map((function(e){return e.trim()})),n.choices=n.choices.filter((function(e){return e})),n.choices=n.choices.map(e),t=""}if("/"===Ee(t)&&"/"===xe(t))return t=Oe(t),n.regex=new RegExp(t),n;if("~"===Ee(t)&&"~"===xe(t))return t=Oe(t),n.soft=!0,n.word=t,n}return!0===Ce.test(t)&&(t=t.replace(Ce,(function(e,t){var r=t.split(/,/g);return 1===r.length?(n.min=Number(r[0]),n.max=Number(r[0])):(n.min=Number(r[0]),n.max=Number(r[1]||999)),n.greedy=!0,""}))),"#"===Ee(t)?(n.tag=Ne(t),n.tag=(r=n.tag).charAt(0).toUpperCase()+r.substr(1),n):"@"===Ee(t)?(n.method=Ne(t),n):"."===t?(n.anything=!0,n):"*"===t?(n.anything=!0,n.greedy=!0,n.optional=!0,n):(t&&(t=(t=t.replace("\\*","*")).replace("\\.","."),n.word=t.toLowerCase()),n)},Te=function(e){return e.filter((function(e){return e.groupType})).length>0&&(e=function(e){for(var t,r,n=!1,a=-1,i=0;i)?\(.*?\)[?+*]*\]?\$?)/);return t=t.map((function(e){return e.trim()}))}(t);return r=(r=function(e){var t=[];return e.forEach((function(e){if(/^[[^_/]?\(/.test(e[0]))t.push(e);else{var r=e.split(" ");r=r.filter((function(e){return e})),t=t.concat(r)}})),t}(r)).map(ze),r=Te(r)},Ve=function(e,t){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if("string"==typeof t&&(t=He(t)),!0===ke(e,t))return[];var n=t.filter((function(e){return!0!==e.optional})).length,a=e.terms(),i=[];if(!0===t[0].start){var o=Pe(a,t,0,a.length),s=l(o,2),u=s[0],c=s[1];return!1!==u&&u.length>0&&(u=u.filter((function(e){return e})),i.push({match:u,groups:c})),Ge(a,t,i)}for(var h=0;ha.length);h+=1){var d=Pe(a.slice(h),t,h,a.length),p=l(d,2),g=p[0],f=p[1];if(!1!==g&&g.length>0&&(h+=g.length-1,g=g.filter((function(e){return e})),i.push({match:g,groups:f}),!0===r))return Ge(a,t,i)}return Ge(a,t,i)},Ie=function(e,t){var r={};Ve(e,t).forEach((function(e){e.match.forEach((function(e){r[e.id]=!0}))}));var n=e.terms(),a=[],i=[];return n.forEach((function(e){!0!==r[e.id]?i.push(e):i.length>0&&(a.push(i),i=[])})),i.length>0&&a.push(i),a},Me={match:function(e){var t=this,r=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=Ve(this,e,r);return n=n.map((function(e){var r=e.match,n=e.groups,a=t.buildFrom(r[0].id,r.length,n);return a.cache.terms=r,a}))},has:function(e){return Ve(this,e,!0).length>0},not:function(e){var t=this,r=Ie(this,e);return r=r.map((function(e){return t.buildFrom(e[0].id,e.length)}))},canBe:function(e,t){for(var r=this,n=[],a=this.terms(),i=!1,o=0;o0})).map((function(e){return r.buildFrom(e[0].id,e.length)}))}},Se=function e(r,n,a){t(this,e),this.start=r,this.length=n,this.isA="Phrase",Object.defineProperty(this,"pool",{enumerable:!1,writable:!0,value:a}),Object.defineProperty(this,"cache",{enumerable:!1,writable:!0,value:{}}),Object.defineProperty(this,"groups",{enumerable:!1,writable:!0,value:{}})};Se.prototype.buildFrom=function(e,t,r){var n=new Se(e,t,this.pool);return r&&Object.keys(r).length>0?n.groups=r:n.groups=this.groups,n},Object.assign(Se.prototype,Me),Object.assign(Se.prototype,we);var Le={term:"terms"};Object.keys(Le).forEach((function(e){return Se.prototype[e]=Se.prototype[Le[e]]}));var _e=Se,Je=function(){function e(){var r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};t(this,e),Object.defineProperty(this,"words",{enumerable:!1,value:r})}return n(e,[{key:"add",value:function(e){return this.words[e.id]=e,this}},{key:"get",value:function(e){return this.words[e]}},{key:"remove",value:function(e){delete this.words[e]}},{key:"merge",value:function(e){return Object.assign(this.words,e.words),this}},{key:"stats",value:function(){return{words:Object.keys(this.words).length}}}]),e}();Je.prototype.clone=function(){var e=this,t=Object.keys(this.words).reduce((function(t,r){var n=e.words[r].clone();return t[n.id]=n,t}),{});return new Je(t)};for(var qe=Je,Ke=function(e){e.forEach((function(t,r){r>0&&(t.prev=e[r-1].id),e[r+1]&&(t.next=e[r+1].id)}))},Re=/(\S.+?[.!?\u203D\u2E18\u203C\u2047-\u2049])(?=\s+|$)/g,We=/\S/,Ue=/[ .][A-Z]\.? *$/i,Qe=/(?:\u2026|\.{2,}) *$/,Ze=/((?:\r?\n|\r)+)/,Xe=/[a-z0-9\u00C0-\u00FF\u00a9|\u00ae|[\u2000-\u3300]|\ud83c[\ud000-\udfff]|\ud83d[\ud000-\udfff]|\ud83e[\ud000-\udfff]/i,Ye=/^\s+/,et=function(e,t){if(!0===Ue.test(e))return!1;if(!0===Qe.test(e))return!1;if(!1===Xe.test(e))return!1;var r=e.replace(/[.!?\u203D\u2E18\u203C\u2047-\u2049] *$/,"").split(" "),n=r[r.length-1].toLowerCase();return!t.hasOwnProperty(n)},tt=function(e,t){var r=t.cache.abbreviations;e=e||"";var n=[],a=[];if(!(e=String(e))||"string"!=typeof e||!1===We.test(e))return n;for(var i=function(e){for(var t=[],r=e.split(Ze),n=0;n0&&(n.push(l),a[u]="")}if(0===n.length)return[e];for(var c=1;c0?(t[t.length-1]+=i,t.push(s)):t.push(i+s),i=""):i+=s}return i&&(0===t.length&&(t[0]=""),t[t.length-1]+=i),t=(t=function(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1?arguments[1]:void 0,r=arguments.length>2?arguments[2]:void 0,n=null;"string"!=typeof e&&("number"==typeof e?e=String(e):ct(e)&&(n=e)),n=(n=n||tt(e,t)).map((function(e){return lt(e)})),r=r||new qe;var a=n.map((function(e){e=e.map((function(e){var t=new oe(e);return r.add(t),t})),Ke(e);var t=new _e(e[0].id,e.length,r);return t.cache.terms=e,t}));return a},dt=function(e,t){var r=new qe;return e.map((function(e,n){var a=e.terms.map((function(a,i){var o=new oe(a.text);return o.pre=void 0!==a.pre?a.pre:"",void 0===a.post&&(a.post=" ",i>=e.terms.length-1&&(a.post=". ",n>=e.terms.length-1&&(a.post="."))),o.post=void 0!==a.post?a.post:" ",a.tags&&a.tags.forEach((function(e){return o.tag(e,"",t)})),r.add(o),o}));return Ke(a),new _e(a[0].id,a.length,r)}))},pt={Comparative:"true¦better",Superlative:"true¦earlier",PresentTense:"true¦is,sounds",Value:"true¦a few",Noun:"true¦a5b4c2f1here,ie,lit,m0no doubt,pd,tce;a,d;t,y;a,ca,o0;l,rp;a,l;d,l,rc",Copula:"true¦a1is,w0;as,ere;m,re",PastTense:"true¦be3came,d2had,lied,meant,sa2taken,w0;as,e0;nt,re;id;en,gan",Condition:"true¦if,unless",Gerund:"true¦accord0be0develop0go0result0stain0;ing",Negative:"true¦n0;ever,o0;!n,t",QuestionWord:"true¦how3wh0;at,e1ich,o0y;!m,se;n,re; come,'s",Plural:"true¦records",Conjunction:"true¦&,aEbAcuz,how8in caDno7o6p4supposing,t1vers5wh0yet;eth8ile;h0o;eref9o0;!uC;l0rovided that;us;r,therwi6; matt1r;!ev0;er;e0ut;cau1f0;ore;se;lthou1nd,s 0;far as,if;gh",Pronoun:"true¦'em,elle,h4i3me,ourselves,she5th1us,we,you0;!rself;e0ou;m,y;!l,t;e0im;!'s",Singular:"true¦0:0X;1:10;a0Wb0Kc0Bd04e02fXgShOici1jel0kitty,lNmJnIoHpDquestion mark,rBs7t4u2womW;nc0Rs 2;doll0Dst0F; rex,a3h2ic,ragedy,v show;ere,i1;l0x return;ist0Pky,omeone,t2uper bowl,yst0W;ep3ri1u2;de0Pff;faMmoM;al0i1o2;om,se;a4i0Jl05r3u2;dLrpoD;erogaVobl0O;rt,te0I;bjSceGthers;othi1umb0E;a4ee04o2;del,m2nopo0th0C;!my;n,yf0;i0unch;ead start,o2;l0me3u2;se;! run;adf0entlem5irlZlaci04od,rand3u2;l0y; slam,fa2mo2;th01;an;a5ella,ly,ol0r3un2;di1;iTo2;ntiWsN;mi0thV;conomy,gg,ner5veWx2;ampQecu7;ad7e4innSo2ragonf0ude;cumentFg2i0l0or;gy;ath,t2;ec2;tive;!dy;a8eili1h6i4o2redit card;ttage,u2;riJsin;ty,vil w2;ar;andeliGocol2;ate;n2rD;ary;aAel0lesHo6r4u2;n2tterf0;ti1;eakfast,o2;!th8;dy,tt4y2;!fri2;end;le;nki1r2;ri2;er;d4l0noma0u2;nt;ly; homin4verti2;si1;ng;em",Actor:"true¦aJbGcFdCengineIfAgardenIh9instructPjournalLlawyIm8nurse,opeOp5r3s1t0;echnCherapK;ailNcientJoldiGu0;pervKrgeon;e0oofE;ceptionGsearC;hotographClumbColi1r0sychologF;actitionBogrammB;cem6t5;echanic,inist9us4;airdress8ousekeep8;arm7ire0;fight6m2;eputy,iet0;ici0;an;arpent2lerk;ricklay1ut0;ch0;er;ccoun6d2ge7r0ssis6ttenda7;chitect,t0;ist;minist1v0;is1;rat0;or;ta0;nt",Honorific:"true¦a03b00cSdReQfiLgKhon,jr,king,lJmEoDp8queen,r4s0taoiseach,vice7;e1fc,gt,ir,r,u0;ltTpt,rg;c0nDrgeaL;ond liJretary;abbi,e0;ar1pAs,v0;!erend; admirY;astPhd,r0vt;esideEi1of0;!essN;me mini5nce0;!ss;fficOp,rd;a3essrs,i2lle,me,r1s0;!tr;!s;stK;gistrate,j,r6yF;i3lb,t;en,ov;eld mar3rst l0;ady,i0;eutena0;nt;shG;sq,xcellency;et,oct6r,utchess;apt6hance4mdr,o0pl;lonel,m2ngress0unci3;m0wom0;an;dr,mand5;ll0;or;!ain;ldg,rig0;!adi0;er;d0sst,tty,yatullah;j,m0v;!ir0;al",SportsTeam:"true¦0:1A;1:1H;2:1G;a1Eb16c0Td0Kfc dallas,g0Ihouston 0Hindiana0Gjacksonville jagua0k0El0Bm01newToQpJqueens parkIreal salt lake,sAt5utah jazz,vancouver whitecaps,w3yW;ashington 3est ham0Rh10;natio1Oredski2wizar0W;ampa bay 6e5o3;ronto 3ttenham hotspur;blue ja0Mrapto0;nnessee tita2xasC;buccanee0ra0K;a7eattle 5heffield0Kporting kansas0Wt3;. louis 3oke0V;c1Frams;marine0s3;eah15ounG;cramento Rn 3;antonio spu0diego 3francisco gJjose earthquak1;char08paA; ran07;a8h5ittsburgh 4ortland t3;imbe0rail blaze0;pirat1steele0;il3oenix su2;adelphia 3li1;eagl1philNunE;dr1;akland 3klahoma city thunder,rlando magic;athle0Mrai3;de0; 3castle01;england 7orleans 6york 3;city fc,g4je0FknXme0Fred bul0Yy3;anke1;ian0D;pelica2sain0C;patrio0Brevolut3;ion;anchester Be9i3ontreal impact;ami 7lwaukee b6nnesota 3;t4u0Fvi3;kings;imberwolv1wi2;rewe0uc0K;dolphi2heat,marli2;mphis grizz3ts;li1;cXu08;a4eicesterVos angeles 3;clippe0dodDla9; galaxy,ke0;ansas city 3nE;chiefs,roya0E; pace0polis colU;astr06dynamo,rockeTtexa2;olden state warrio0reen bay pac3;ke0;.c.Aallas 7e3i05od5;nver 5troit 3;lio2pisto2ti3;ge0;broncZnuggeM;cowbo4maver3;ic00;ys; uQ;arCelKh8incinnati 6leveland 5ol3;orado r3umbus crew sc;api5ocki1;brow2cavalie0india2;bengaWre3;ds;arlotte horAicago 3;b4cubs,fire,wh3;iteB;ea0ulR;diff3olina panthe0; c3;ity;altimore 9lackburn rove0oston 5rooklyn 3uffalo bilN;ne3;ts;cel4red3; sox;tics;rs;oriol1rave2;rizona Ast8tlanta 3;brav1falco2h4u3;nited;aw9;ns;es;on villa,r3;os;c5di3;amondbac3;ks;ardi3;na3;ls",Uncountable:"true¦a1Ib1Ac11d0Ye0Rf0Lg0Hh0Ci08j07knowled1Hl02mUnews,oTpQrLsAt5vi4w0;a2ea05i1oo0;d,l;ldlife,ne;rmth,t17;neg0Yol06tae;e3h2oothpaste,r0una;affPou0;ble,sers,t;ermod1Eund12;a,nnis;a8cene04eri0Oh7il6kittl0Onow,o5p3t1u0;g0Rnshi0H;ati1De0;am,el;ace16e0;ci0Jed;ap,cc0U;k,v0T;eep,ingl0G;d04fe10l0nd;m0St;a3e1ic0;e,ke0D;c0laxa09search;ogni08rea08;bi09in;aJe1hys10last5o0ressV;lit0Zrk,w0J;a0Vtrol;bstetr0Xil,xygen;a5e3ilk,o2u0;mps,s0;ic;nGo0A;a0chan0S;slZt;chine0il,themat0Q; learn05ry;aught08e2i1ogi0Nu0;ck,g0C;ce,ghtn02ngui0LteratH;a0isG;th04;ewel7usti0G;ce,mp0nformaOtself;a0ortan0E;ti0;en0C;a3isto2o0;ck0mework,n0spitali06;ey;ry;ir,libut,ppi7;en01o1r0um,ymna08;a6ound;l0ssip;d,f;i4lour,o1urnit0;ure;od,rgive0uriNwl;ne0;ss;c6sh;conomZduca5lectr4n2quip3thZvery0;body,o0thE;ne;joy0tertain0;ment;iciNonU;tiF;ar1iabet0raugh1;es;ts;a7elcius,h3ivPl2o0urrency;al,ld w0nfusiAttA;ar;assMoth2;aos,e0;e1w0;ing;se;r4sh;a4eef,i1lood,owls,read,utt0;er;lliar1s0;on;ds;g0ss;ga0;ge;c6dvi5ero3ir2mnes1rt,thl0;et7;ty;craft;b4d0naut4;ynam3;ce;id,ou0;st0;ics",Infinitive:"true¦0:6K;1:6Y;2:57;3:6W;4:6V;5:5Z;6:67;7:6U;8:6Q;9:6I;A:6S;B:6P;C:6Z;D:6D;E:56;F:5P;a6Cb61c52d4Ae3Uf3Hg3Bh34i2Rj2Pk2Nl2Fm25n22o1Xp1Iques3Ir0Qs05tXuSvOwHyG;awn,ield;aJe1Yhist6iIoGre65;nd0rG;k,ry;pe,sh,th0;lk,nHrGsh,tDve;n,raC;d0t;aIiGo7;eGsB;!w;l6Cry;nHpGr4se;gra4Mli3Z;dGi7lo5Spub3O;erGo;mi58w1I;aMeLhKoJrHuGwi8;ne,rn;aGe0Mi5Nu8y;de,in,nsf0p,v5F;r2XuD;ank,reat2N;nd,st;lk,rg1Ps7;aZcWeVhTi4Akip,lSmRnee3Jo4YpQtJuGwitD;bmBck,ff0gge8ppHrGspe5;ge,pri1rou4Vvi3;ly,o34;aLeKoJrHuG;dy,mb6;aEeGi3;ngth2Dss,tD;p,re;m,p;in,ke,r0Qy;laFoil,rink6;e1Xi6o3H;am,ip;a2iv0oG;ck,ut;arDem,le5n1r3tt6;aHo2rG;atDew;le,re;il,ve;a05eIisk,oHuG;in,le,sh;am,ll;a01cZdu9fYgXje5lUmTnt,pQquPsKtJvGwa5O;eGiew,o34;al,l,rG;se,t;aEi2u40;eJi8oItG;!o2rG;i5uc1Y;l3rt;mb6nt,r3;e8i2;air,eHlGo3ZreseC;a9y;at;aEemb0i3Vo3;aHeGi3y;a1nt;te,x;a56r0I;act1Wer,le5u1;a11ei3k5IoGyc6;gni2Anci6rd;ch,li29s5G;i1nG;ge,k;aTerSiRlOoMrIuG;b1Zll,mp,rGsh;cha1s4J;ai1eIiCoG;cGdu9greAhibBmi1te8vi2T;eAlaim;di5pa2ss,veC;iCp,rtr3ZsGur;e,t;aHuG;g,n4;n,y;ck,le;fo30mBsi8;ck,iCrt4Fss,u1;bJccur,ff0pera7utweIverGwe;co40lap,ta20u1wG;helm;igh;ser3taE;eHotG;e,i9;ed,gle5;aLeKiIoHuG;ltip3Crd0;nit11ve;nGrr10;d,g6us;asu2lt,n0Nr4;intaEna4rHtG;ch,t0;ch,kGry;et;aLeKiIoGu1B;aGck,ok,ve;d,n;ft,ke,mBnGst2Wve;e,k;a2Dc0Et;b0Nck,uG;gh,nD;iGno2Z;ck,ll,ss;am,oEuG;d4mp;gno2mQnGss3C;cOdica7flu0MhNsKtIvG;eGol3;nt,st;erGrodu9;a5fe2;i8tG;aGru5;ll;abBibB;lu1Er1C;agi22pG;lemeCo20ro3;aKeIi2oHuG;nt,rry;n02pe,st;aGlp;d,t;nd6ppGrm,te;en;aKloAove1MrIuG;arGeAi13;ant33d;aGip,umb6;b,sp;in,th0ze;aQeaPiNlLoIracHuncG;ti3D;tu2;cus,lHrG;ce,eca8m,s2V;d,l1Z;aFoG;at,od,w;gu2lGniFx;e,l;r,tu2;il,vG;or;a13cho,le5mSnPstNvalua7xG;a0AcLerKi8pGte17;a16eHi2laEoGreA;rt,se;ct,riG;en9;ci1t;el,han4;abGima7;liF;ab6couXdHfor9ga4han9j03riDsu2t0vG;isi2Qy;!u2;body,er4pG;hasiGow0;ze;a06eUiLoKrHuG;mp;aHeAiG;ft;g,in;d4ubt;ff0p,re5sHvG;iYor9;aKcHliGmiApl16tinguiF;ke;oGuA;uGv0;ra4;gr1TppG;ear,ro3;cNem,fLliv0ma0Dny,pKsHterG;mi0E;cribe,er3iHtrG;oy;gn,re;a09e08i5osB;eGi09y;at,ct;iIlHrG;ea1;a2i05;de;ma4n9re,te;a0Ae09h06i7l04oJrG;aHeGoAuFy;a7dB;ck,ve;llZmSnHok,py,uGv0;gh,nt;cePdu5fMsKtIvG;eGin9;rt,y;aEin0SrG;a8ibu7ol;iGtitu7;d0st;iHoGroC;rm;gu2rm;rn;biLfoKmaJpG;a2laE;in;re;nd;rt;ne;ap1e5;aGip,o1;im,w;aHeG;at,ck,w;llen4n4r4se;a1nt0;ll,ncIrGt0u1;eGry;!en;el;aPeMloLoJruFuG;lGry;ly;sh;a8mb,o8rrGth0un9;ow;ck;ar,lHnefBtrG;ay;ie3ong;ng,se;band0Jc0Bd06ffo05gr04id,l01mu1nYppTrQsKttGvoid,waB;acIeHra5;ct;m0Fnd;h,k;k,sG;eIiHocia7uG;me;gn,st;mb6rt;le;chHgGri3;ue;!i3;eaJlIroG;aDve;ch;aud,y;l,r;noun9sw0tG;icipa7;ce;lHt0;er;e4ow;ee;rd;aRdIju8mBoR;it;st;!reA;ss;cJhie3knowled4tiva7;te;ge;ve;eIouCu1;se;nt;pt;on",Unit:"true¦0:19;a14b12c0Od0Ne0Lf0Gg0Ch09in0Hjoule0k02l00mNnMoLpIqHsqCt7volts,w6y4z3°2µ1;g,s;c,f,n;b,e2;a0Nb,d0Dears old,o1;tt0H;att0b;able4b3d,e2on1sp;!ne0;a2r0D;!l,sp;spo04; ft,uare 1;c0Id0Hf3i0Fkilo0Jm1ya0E;e0Mil1;e0li0H;eet0o0D;t,uart0;ascals,e2i1ou0Pt;c0Mnt0;rcent,t02;hms,uYz;an0JewtT;/s,b,e9g,i3l,m2p1²,³;h,s;!²;!/h,cro5l1;e1li08;! pFs1²;! 1;anEpD;g06s0B;gQter1;! 2s1;! 1;per second;b,i00m,u1x;men0x0;b,elvin0g,ilo2m1nR;!/h,ph,²;byZgXmeter1;! p2s1;! p1;er1; hour;e1g,r0z;ct1rtz0;aXogQ;al2b,igAra1;in0m0;!l1;on0;a4emtPl2t1;²,³; oz,uid ou1;nce0;hrenheit0rad0;b,x1;abyH;eciCg,l,mA;arat0eAg,m9oulomb0u1;bic 1p0;c5d4fo3i2meAya1;rd0;nch0;ot0;eci2;enti1;me4;!²,³;lsius0nti1;g2li1me1;ter0;ram0;bl,y1;te0;c4tt1;os1;eco1;nd0;re0;!s",Organization:"true¦0:46;a3Ab2Qc2Ad21e1Xf1Tg1Lh1Gi1Dj19k17l13m0Sn0Go0Dp07qu06rZsStFuBv8w3y1;amaha,m0Xou1w0X;gov,tu2S;a3e1orld trade organizati41;lls fargo,st1;fie22inghou16;l1rner br3D;-m11gree31l street journ25m11;an halNeriz3Wisa,o1;dafo2Gl1;kswagLvo;bs,kip,n2ps,s1;a tod2Rps;es35i1;lev2Xted natio2Uv; mobi2Kaco bePd bMeAgi frida9h3im horto2Tmz,o1witt2W;shiba,y1;ota,s r Y;e 1in lizzy;b3carpen33daily ma2Xguess w2holli0rolling st1Ms1w2;mashing pumpki2Ouprem0;ho;ea1lack eyed pe3Fyrds;ch bo1tl0;ys;l2s1;co,la m12;efoni07us;a6e4ieme2Gnp,o2pice gir5ta1ubaru;rbucks,to2N;ny,undgard1;en;a2Rx pisto1;ls;few25insbu26msu1X;.e.m.,adiohead,b6e3oyal 1yan2X;b1dutch she4;ank;/max,aders dige1Ed 1vl32;bu1c1Uhot chili peppe2Klobst28;ll;c,s;ant2Vizno2F;an5bs,e3fiz24hilip morrBi2r1;emier27octer & gamb1Rudenti14;nk floyd,zza hut;psi28tro1uge08;br2Qchina,n2Q; 2ason1Xda2G;ld navy,pec,range juli2xf1;am;us;a9b8e5fl,h4i3o1sa,wa;kia,tre dame,vart1;is;ke,ntendo,ss0K;l,s;c,st1Etflix,w1; 1sweek;kids on the block,york08;a,c;nd1Us2t1;ional aca2Fo,we0Q;a,cYd0O;aAcdonald9e5i3lb,o1tv,yspace;b1Nnsanto,ody blu0t1;ley crue,or0O;crosoft,t1;as,subisO;dica3rcedes2talli1;ca;!-benz;id,re;'s,s;c's milk,tt13z1Y;'ore09a3e1g,ittle caesa1Ktd;novo,x1;is,mark; pres5-z-boy,bour party;atv,fc,kk,m1od1K;art;iffy lu0Lo3pmorgan1sa;! cha1;se;hnson & johns1Sy d1R;bm,hop,n1tv;c,g,te1;l,rpol; & m,asbro,ewlett-packaTi3o1sbc,yundai;me dep1n1J;ot;tac1zbollah;hi;eneral 6hq,l5mb,o2reen d0Iu1;cci,ns n ros0;ldman sachs,o1;dye1g0B;ar;axo smith kliZencore;electr0Im1;oto0V;a3bi,da,edex,i1leetwood mac,oGrito-l0A;at,nancial1restoV; tim0;cebook,nnie mae;b06sa,u3xxon1; m1m1;ob0H;!rosceptics;aiml0Ae5isney,o3u1;nkin donuts,po0Wran dur1;an;j,w j1;on0;a,f leppa3ll,p2r spiegZstiny's chi1;ld;eche mode,t;rd;aEbc,hBi9nn,o3r1;aigsli5eedence clearwater reviv1ossra05;al;!ca c5l4m1o0Ast05;ca2p1;aq;st;dplMgate;ola;a,sco1tigroup;! systems;ev2i1;ck fil-a,na daily;r0Hy;dbury,pital o1rl's jr;ne;aGbc,eCfAl6mw,ni,o2p,r1;exiteeWos;ei3mbardiJston 1;glo1pizza;be;ng;ack & deckFo2ue c1;roX;ckbuster video,omingda1;le; g1g1;oodriN;cht3e ge0n & jer2rkshire hathaw1;ay;ryH;el;nana republ3s1xt5y5;f,kin robbi1;ns;ic;bXcSdidRerosmith,ig,lLmFnheuser-busEol,ppleAr7s3t&t,v2y1;er;is,on;hland2s1;n,ociated F; o1;il;by4g2m1;co;os; compu2bee1;'s;te1;rs;ch;c,d,erican3t1;!r1;ak; ex1;pre1;ss; 4catel2t1;air;!-luce1;nt;jazeera,qae1;da;as;/dc,a3er,t1;ivisi1;on;demy of scienc0;es;ba,c",Demonym:"true¦0:16;1:13;a0Wb0Nc0Cd0Ae09f07g04h02iYjVkTlPmLnIomHpDqatari,rBs7t5u4v3wel0Rz2;am0Fimbabwe0;enezuel0ietnam0H;g9krai1;aiwThai,rinida0Iu2;ni0Qrkmen;a4cot0Ke3ingapoOlovak,oma0Tpa05udRw2y0X;edi0Kiss;negal0Br08;mo0uU;o6us0Lw2;and0;a3eru0Hhilipp0Po2;li0Ertugu06;kist3lesti1na2raguay0;ma1;ani;amiZi2orweP;caragu0geri2;an,en;a3ex0Mo2;ngo0Erocc0;cedo1la2;gasy,y08;a4eb9i2;b2thua1;e0Dy0;o,t02;azakh,eny0o2uwaiti;re0;a2orda1;ma0Bp2;anN;celandic,nd4r2sraeli,ta02vo06;a2iT;ni0qi;i0oneV;aiDin2ondur0unN;di;amDe2hanai0reek,uatemal0;or2rm0;gi0;i2ren7;lipino,n4;cuadoVgyp6ngliJsto1thiopi0urope0;a2ominXut4;niH;a9h6o4roa3ub0ze2;ch;ti0;lom2ngol5;bi0;a6i2;le0n2;ese;lifor1m2na3;bo2eroo1;di0;angladeshi,el8o6r3ul2;gaG;aziBi2;ti2;sh;li2s1;vi0;aru2gi0;si0;fAl7merBngol0r5si0us2;sie,tr2;a2i0;li0;gent2me1;ine;ba1ge2;ri0;ni0;gh0r2;ic0;an",Possessive:"true¦anyAh5its,m3noCo1sometBthe0yo1;ir1mselves;ur0;!s;i8y0;!se4;er1i0;mse2s;!s0;!e0;lf;o1t0;hing;ne",Currency:"true¦$,aud,bScQdLeurKfJgbp,hkd,iIjpy,kGlEp8r7s3usd,x2y1z0¢,£,¥,ден,лв,руб,฿,₡,₨,€,₭,﷼;lotySł;en,uanR;af,of;h0t5;e0il5;k0q0;elM;iel,oubleLp,upeeL;e2ound st0;er0;lingI;n0soH;ceGn0;ies,y;e0i8;i,mpi7;n,r0wanzaCyatC;!onaBw;ls,nr;ori7ranc9;!o8;en3i2kk,o0;b0ll2;ra5;me4n0rham4;ar3;ad,e0ny;nt1;aht,itcoin0;!s",City:"true¦a2Wb26c1Wd1Re1Qf1Og1Ih1Ai18jakar2Hk0Zl0Tm0Gn0Co0ApZquiYrVsLtCuBv8w3y1z0;agreb,uri1Z;ang1Te0okohama;katerin1Hrev34;ars3e2i0rocl3;ckl0Vn0;nipeg,terth0W;llingt1Oxford;aw;a1i0;en2Hlni2Z;lenc2Uncouv0Gr2G;lan bat0Dtrecht;a6bilisi,e5he4i3o2rondheim,u0;nVr0;in,ku;kyo,ronIulouC;anj23l13miso2Jra2A; haJssaloni0X;gucigalpa,hr2Ol av0L;i0llinn,mpe2Bngi07rtu;chu22n2MpT;a3e2h1kopje,t0ydney;ockholm,uttga12;angh1Fenzh1X;o0KvZ;int peters0Ul3n0ppo1F; 0ti1B;jo0salv2;se;v0z0Q;adU;eykjavik,i1o0;me,sario,t25;ga,o de janei17;to;a8e6h5i4o2r0ueb1Qyongya1N;a0etor24;gue;rt0zn24; elizabe3o;ls1Grae24;iladelph1Znom pe07oenix;r0tah tik19;th;lerJr0tr10;is;dessa,s0ttawa;a1Hlo;a2ew 0is;delTtaip0york;ei;goya,nt0Upl0Uv1R;a5e4i3o1u0;mb0Lni0I;nt0scH;evideo,real;l1Mn01skolc;dellín,lbour0S;drid,l5n3r0;ib1se0;ille;or;chest0dalWi0Z;er;mo;a4i1o0vAy01;nd00s angel0F;ege,ma0nz,sbZverpo1;!ss0;ol; pla0Iusan0F;a5hark4i3laipeda,o1rak0uala lump2;ow;be,pavog0sice;ur;ev,ng8;iv;b3mpa0Kndy,ohsiu0Hra0un03;c0j;hi;ncheMstanb0̇zmir;ul;a5e3o0; chi mi1ms,u0;stI;nh;lsin0rakliG;ki;ifa,m0noi,va0A;bu0SiltD;alw4dan3en2hent,iza,othen1raz,ua0;dalaj0Gngzhou;bu0P;eUoa;sk;ay;es,rankfu0;rt;dmont4indhovU;a1ha01oha,u0;blRrb0Eshanbe;e0kar,masc0FugavpiJ;gu,je0;on;a7ebu,h2o0raioJuriti01;lo0nstanJpenhagNrk;gFmbo;enn3i1ristchur0;ch;ang m1c0ttagoL;ago;ai;i0lgary,pe town,rac4;ro;aHeBirminghWogoAr5u0;char3dap3enos air2r0sZ;g0sa;as;es;est;a2isba1usse0;ls;ne;silPtisla0;va;ta;i3lgrade,r0;g1l0n;in;en;ji0rut;ng;ku,n3r0sel;celo1ranquil0;la;na;g1ja lu0;ka;alo0kok;re;aBb9hmedabad,l7m4n2qa1sh0thens,uckland;dod,gabat;ba;k0twerp;ara;m5s0;terd0;am;exandr0maty;ia;idj0u dhabi;an;lbo1rh0;us;rg",Abbreviation:"true¦a0Tb0Qc0Kd0Ie0Ff0Cg0Ah08i06j04k02l00mRnOoNpIqHrFs9t6u5v2w0yb,µg;is0r,y0L;!c;a,b,e1i0ol,s,t;tro,vo;r,t;niv,safa,t;b1ce,d,e0sp;l,mp,nn,x;!l,sp;ask,e3fc,gt,i2q1r,s,t,u0;pt,rg;! ft;r,tu;c,nVp0;!t;b,d,e0;pSs,v;t,ue;a,d,enn3hd,l,p,r1s0t,vt;!a,eud;ef,o0;b,f,n;!a;ct,kla,nt,p,rd,z;e0ov;b0e;!r;a7b,d,essrs,g,i4l3m2p1rHs0t;!tr;h,s;!e;!le;!n1s0;c,ter;!n;!j,r,sc;at,b,it,lb,m,ng,t0x;!d;an6b,g,m0;!ph;an,d,r,u0;l,n;a,da,e,n0;c,f;g,on,r0wy,z;!s;a0b,en,ov;!l;e1ig,l0m,r,t,y;! oz,a;b,m;a,g,ng,s1tc,x0;!p;p,q,t;ak,e0g,ist,l,m,r;c,f,pt,t;a3ca,g,l,m2o0pl,res,t,yn;!l0mdr,nn,rp;!o;!dr;!l0pt;!if;a,c,l1r0;ig,os;!dg,vd;d4l3p2r1ss0tty,ug,ve;n,t;c,iz;prox,r,t;!ta;!j,m,v",Country:"true¦0:38;1:2L;a2Wb2Dc21d1Xe1Rf1Lg1Bh19i13j11k0Zl0Um0Gn05om3CpZqat1JrXsKtCu6v4wal3yemTz2;a24imbabwe;es,lis and futu2X;a2enezue31ietnam;nuatu,tican city;.5gTkraiZnited 3ruXs2zbeE;a,sr;arab emirat0Kkingdom,states2;! of am2X;k.,s.2; 27a.;a7haBimor-les0Bo6rinidad4u2;nis0rk2valu;ey,me2Xs and caic1T; and 2-2;toba1J;go,kel0Ynga;iw2Vji2nz2R;ki2T;aCcotl1eBi8lov7o5pa2Bri lanka,u4w2yr0;az2ed9itzerl1;il1;d2Qriname;lomon1Vmal0uth 2;afr2IkLsud2O;ak0en0;erra leoEn2;gapo1Wt maart2;en;negKrb0ychellY;int 2moa,n marino,udi arab0;hele24luc0mart1Z;epublic of ir0Com2Cuss0w2;an25;a3eHhilippinTitcairn1Ko2uerto riM;l1rtugE;ki2Bl3nama,pua new0Tra2;gu6;au,esti2;ne;aAe8i6or2;folk1Gth3w2;ay; k2ern mariana1B;or0M;caragua,ger2ue;!ia;p2ther18w zeal1;al;mib0u2;ru;a6exi5icro09o2yanm04;ldova,n2roc4zamb9;a3gol0t2;enegro,serrat;co;c9dagascZl6r4urit3yot2;te;an0i14;shall0Vtin2;ique;a3div2i,ta;es;wi,ys0;ao,ed00;a5e4i2uxembourg;b2echtenste10thu1E;er0ya;ban0Gsotho;os,tv0;azakh1De2iriba02osovo,uwait,yrgyz1D;eling0Jnya;a2erF;ma15p1B;c6nd5r3s2taly,vory coast;le of m19rael;a2el1;n,q;ia,oI;el1;aiSon2ungary;dur0Mg kong;aAermany,ha0Pibralt9re7u2;a5ern4inea2ya0O;!-biss2;au;sey;deloupe,m,tema0P;e2na0M;ce,nl1;ar;bTmb0;a6i5r2;ance,ench 2;guia0Dpoly2;nes0;ji,nl1;lklandTroeT;ast tim6cu5gypt,l salv5ngl1quatorial3ritr4st2thiop0;on0; guin2;ea;ad2;or;enmark,jibou4ominica3r con2;go;!n B;ti;aAentral african 9h7o4roat0u3yprQzech2; 8ia;ba,racao;c3lo2morPngo-brazzaville,okFsta r03te d'ivoiK;mb0;osD;i2ristmasF;le,na;republic;m2naTpe verde,yman9;bod0ero2;on;aFeChut00o8r4u2;lgar0r2;kina faso,ma,undi;azil,itish 2unei;virgin2; is2;lands;liv0nai4snia and herzegoviGtswaGuvet2; isl1;and;re;l2n7rmuF;ar2gium,ize;us;h3ngladesh,rbad2;os;am3ra2;in;as;fghaFlCmAn5r3ustr2zerbaijH;al0ia;genti2men0uba;na;dorra,g4t2;arct6igua and barbu2;da;o2uil2;la;er2;ica;b2ger0;an0;ia;ni2;st2;an",Region:"true¦0:1U;a20b1Sc1Id1Des1Cf19g13h10i0Xj0Vk0Tl0Qm0FnZoXpSqPrMsDtAut9v6w3y1zacatec22;o05u1;cat18kZ;a1est vi4isconsin,yomi14;rwick0shington1;! dc;er2i1;rgin1S;acruz,mont;ah,tar pradesh;a2e1laxca1DuscaA;nnessee,x1R;bas0Kmaulip1QsmJ;a6i4o2taf0Ou1ylh13;ffVrr00s0Y;me10no1Auth 1;cSdR;ber1Ic1naloa;hu0Sily;n2skatchew0Rxo1;ny; luis potosi,ta catari1I;a1hode7;j1ngp02;asth0Mshahi;inghai,u1;e1intana roo;bec,ensWreta0E;ara4e2rince edward1; isU;i,nnsylv1rnambu02;an14;!na;axa0Ndisha,h1klaho1Bntar1reg4x04;io;ayarit,eBo3u1;evo le1nav0L;on;r1tt0Rva scot0X;f6mandy,th1; 1ampton0;c3d2yo1;rk0;ako0Y;aroli0V;olk;bras0Xva01w1; 2foundland1;! and labrador;brunswick,hamp0jers1mexiJyork state;ey;a6i2o1;nta0Nrelos;ch3dlanBn2ss1;issippi,ouri;as geraGneso0M;igQoacQ;dhya,harasht04ine,ni3r1ssachusetts;anhao,y1;land;p1toba;ur;anca0e1incoln0ouis8;e1iH;ds;a1entucky,hul0A;ns08rnata0Dshmir;alis1iangxi;co;daho,llino2nd1owa;ia05;is;a2ert1idalEunA;ford0;mp0waii;ansu,eorgWlou5u1;an2erre1izhou,jarat;ro;ajuato,gdo1;ng;cester0;lori2uji1;an;da;sex;e4o2uran1;go;rs1;et;lawaErby0;a8ea7hi6o1umbrH;ahui4l3nnectic2rsi1ventry;ca;ut;iMorado;la;apEhuahua;ra;l8m1;bridge0peche;a5r4uck1;ingham0;shi1;re;emen,itish columb3;h2ja cal1sque,var2;iforn1;ia;guascalientes,l4r1;izo2kans1;as;na;a2ber1;ta;ba2s1;ka;ma",FemaleName:"true¦0:FY;1:G2;2:FR;3:FD;4:FC;5:FS;6:ER;7:EP;8:GF;9:EZ;A:GB;B:E5;C:G8;D:FO;E:FL;F:EG;aE2bD4cB8dAIe9Gf91g8Hh83i7Sj6Uk60l4Om38n2To2Qp2Fqu2Er1Os0Qt04ursu6vUwOyLzG;aJeHoG;e,la,ra;lGna;da,ma;da,ra;as7EeHol1TvG;et7onB9;le0sen3;an9endBNhiB4iG;lInG;if3AniGo0;e,f39;a,helmi0lGma;a,ow;aMeJiG;cHviG;an9XenG1;kCZtor3;da,l8Vnus,rG;a,nGoniD2;a,iDC;leGnesEC;nDLrG;i1y;aSePhNiMoJrGu6y4;acG3iGu0E;c3na,sG;h9Mta;nHrG;a,i;i9Jya;a5IffaCGna,s5;al3eGomasi0;a,l8Go6Xres1;g7Uo6WrHssG;!a,ie;eFi,ri8;bNliMmKnIrHs5tGwa0;ia0um;a,yn;iGya;a,ka,s5;a4e4iGmCAra;!ka;a,t5;at5it5;a05carlet2Ye04hUiSkye,oQtMuHyG;bFJlvi1;e,sHzG;an2Tet7ie,y;anGi8;!a,e,nG;aEe;aIeG;fGl3DphG;an2;cF8r6;f3nGphi1;d4ia,ja,ya;er4lv3mon1nGobh75;dy;aKeGirlBLo0y6;ba,e0i6lIrG;iGrBPyl;!d70;ia,lBV;ki4nIrHu0w0yG;la,na;i,leAon,ron;a,da,ia,nGon;a,on;l5Yre0;bMdLi9lKmIndHrGs5vannaE;aEi0;ra,y;aGi4;nt5ra;lBNome;e,ie;in1ri0;a02eXhViToHuG;by,thBK;bQcPlOnNsHwe0xG;an94ie,y;aHeGie,lC;ann8ll1marBFtB;!lGnn1;iGyn;e,nG;a,d7W;da,i,na;an9;hel53io;bin,erByn;a,cGkki,na,ta;helBZki;ea,iannDXoG;da,n12;an0bIgi0i0nGta,y0;aGee;!e,ta;a,eG;cARkaE;chGe,i0mo0n5EquCDvDy0;aCCelGi9;!e,le;een2ia0;aMeLhJoIrG;iGudenAW;scil1Uyamva9;lly,rt3;ilome0oebe,ylG;is,lis;arl,ggy,nelope,r6t4;ige,m0Fn4Oo6rvaBBtHulG;a,et7in1;ricGsy,tA8;a,e,ia;ctav3deHfAWlGphAW;a,ga,iv3;l3t7;aQePiJoGy6;eHrG;aEeDma;ll1mi;aKcIkGla,na,s5ta;iGki;!ta;hoB2k8BolG;a,eBH;!mh;l7Tna,risF;dIi5PnHo23taG;li1s5;cy,et7;eAiCO;a01ckenz2eViLoIrignayani,uriBGyG;a,rG;a,na,tAS;i4ll9XnG;a,iG;ca,ka,qB4;a,chOkaNlJmi,nIrGtzi;aGiam;!n9;a,dy,erva,h,n2;a,dIi9JlG;iGy;cent,e;red;!e6;ae6el3G;ag4KgKi,lHrG;edi61isFyl;an2iGliF;nGsAM;a,da;!an,han;b08c9Ed06e,g04i03l01nZrKtJuHv6Sx87yGz2;a,bell,ra;de,rG;a,eD;h75il9t2;a,cSgOiJjor2l6In2s5tIyG;!aGbe5QjaAlou;m,n9S;a,ha,i0;!aIbALeHja,lCna,sGt53;!a,ol,sa;!l06;!h,m,nG;!a,e,n1;arIeHie,oGr3Kueri7;!t;!ry;et3IiB;elGi61y;a,l1;dGon,ue6;akranBy;iGlo36;a,ka,n9;a,re,s2;daGg2;!l2W;alCd2elGge,isBGon0;eiAin1yn;el,le;a0Ie08iWoQuKyG;d3la,nG;!a,dHe9SnGsAQ;!a,e9R;a,sAO;aB1cJelIiFlHna,pGz;e,iB;a,u;a,la;iGy;a2Ae,l25n9;is,l1GrHtt2uG;el6is1;aIeHi8na,rG;a6Zi8;lei,n1tB;!in1;aQbPd3lLnIsHv3zG;!a,be4Ket7z2;a,et7;a,dG;a,sGy;ay,ey,i,y;a,iaIlG;iGy;a8Ge;!n4F;b7Terty;!n5R;aNda,e0iLla,nKoIslARtGx2;iGt2;c3t3;la,nGra;a,ie,o4;a,or1;a,gh,laG;!ni;!h,nG;a,d4e,n4N;cNdon7Si6kes5na,rMtKurIvHxGy6;mi;ern1in3;a,eGie,yn;l,n;as5is5oG;nya,ya;a,isF;ey,ie,y;aZeUhadija,iMoLrIyG;lGra;a,ee,ie;istGy5B;a,en,iGy;!e,n48;ri,urtn9A;aMerLl99mIrGzzy;a,stG;en,in;!berlG;eGi,y;e,y;a,stD;!na,ra;el6PiJlInHrG;a,i,ri;d4na;ey,i,l9Qs2y;ra,s5;c8Wi5XlOma6nyakumari,rMss5LtJviByG;!e,lG;a,eG;e,i78;a5EeHhGi3PlCri0y;ar5Cer5Cie,leDr9Fy;!lyn73;a,en,iGl4Uyn;!ma,n31sF;ei72i,l2;a04eVilToMuG;anKdJliGst56;aHeGsF;!nAt0W;!n8X;i2Ry;a,iB;!anLcelCd5Vel71han6IlJni,sHva0yG;a,ce;eGie;fi0lCph4X;eGie;en,n1;!a,e,n36;!i10lG;!i0Z;anLle0nIrHsG;i5Qsi5Q;i,ri;!a,el6Pif1RnG;a,et7iGy;!e,f1P;a,e72iHnG;a,e71iG;e,n1;cLd1mi,nHqueliAsmin2Uvie4yAzG;min8;a8eHiG;ce,e,n1s;!lGsFt06;e,le;inHk2lCquelG;in1yn;da,ta;lPmNnMo0rLsHvaG;!na;aHiGob6U;do4;!belGdo4;!a,e,l2G;en1i0ma;a,di4es,gr5R;el9ogG;en1;a,eAia0o0se;aNeKilHoGyacin1N;ll2rten1H;aHdGlaH;a,egard;ry;ath0WiHlGnrietBrmiAst0W;en24ga;di;il75lKnJrGtt2yl75z6D;iGmo4Fri4G;etG;!te;aEnaE;ey,l2;aYeTiOlMold12rIwG;enGyne18;!dolC;acHetGisel9;a,chD;e,ieG;!la;adys,enGor3yn1Y;a,da,na;aJgi,lHna,ov71selG;a,e,le;da,liG;an;!n0;mYnIorgHrG;ald35i,m2Stru73;et7i5T;a,eGna;s1Nvieve;briel3Fil,le,rnet,yle;aReOio0loMrG;anHe9iG;da,e9;!cG;esHiGoi0G;n1s3V;!ca;!rG;a,en43;lHrnG;!an9;ec3ic3;rHtiGy8;ma;ah,rah;d0FileDkBl00mUn4ArRsMtLuKvG;aIelHiG;e,ta;in0Ayn;!ngel2H;geni1la,ni3R;h52ta;meral9peranJtG;eHhGrel6;er;l2Pr;za;iGma,nest29yn;cGka,n;a,ka;eJilImG;aGie,y;!liA;ee,i1y;lGrald;da,y;aTeRiMlLma,no4oJsIvG;a,iG;na,ra;a,ie;iGuiG;se;a,en,ie,y;a0c3da,nJsGzaH;aGe;!beG;th;!a,or;anor,nG;!a;in1na;en,iGna,wi0;e,th;aWeKiJoGul2U;lor51miniq3Yn30rGtt2;a,eDis,la,othGthy;ea,y;an09naEonAx2;anPbOde,eNiLja,lImetr3nGsir4U;a,iG;ce,se;a,iHla,orGphiA;es,is;a,l5J;dGrdG;re;!d4Mna;!b2CoraEra;a,d4nG;!a,e;hl3i0mMnKphn1rHvi1WyG;le,na;a,by,cHia,lG;a,en1;ey,ie;a,et7iG;!ca,el1Aka;arGia;is;a0Qe0Mh04i02lUoJrHynG;di,th3;istGy04;al,i0;lOnLrHurG;tn1D;aId28iGn28riA;!nG;a,e,n1;!l1S;n2sG;tanGuelo;ce,za;eGleD;en,t7;aIeoHotG;il4B;!pat4;ir8rIudG;et7iG;a,ne;a,e,iG;ce,sX;a4er4ndG;i,y;aPeMloe,rG;isHyG;stal;sy,tG;aHen,iGy;!an1e,n1;!l;lseHrG;!i8yl;a,y;nLrG;isJlHmG;aiA;a,eGot7;n1t7;!sa;d4el1PtG;al,el1O;cHlG;es7i3F;el3ilG;e,ia,y;iYlXmilWndVrNsLtGy6;aJeIhGri0;erGleDrCy;in1;ri0;li0ri0;a2GsG;a2Fie;a,iMlKmeIolHrG;ie,ol;!e,in1yn;lGn;!a,la;a,eGie,y;ne,y;na,sF;a0Di0D;a,e,l1;isBl2;tlG;in,yn;arb0CeYianXlVoTrG;andRePiIoHyG;an0nn;nwCok8;an2NdgKg0ItG;n27tG;!aHnG;ey,i,y;ny;etG;!t8;an0e,nG;da,na;i8y;bbi8nG;iBn2;ancGossom,ythe;a,he;ca;aRcky,lin9niBrNssMtIulaEvG;!erlG;ey,y;hHsy,tG;e,i0Zy8;!anG;ie,y;!ie;nGt5yl;adHiG;ce;et7iA;!triG;ce,z;a4ie,ra;aliy29b24d1Lg1Hi19l0Sm0Nn01rWsNthe0uJvIyG;anGes5;a,na;a,r25;drIgusHrG;el3;ti0;a,ey,i,y;hHtrG;id;aKlGt1P;eHi8yG;!n;e,iGy;gh;!nG;ti;iIleHpiB;ta;en,n1t7;an19elG;le;aYdWeUgQiOja,nHtoGya;inet7n3;!aJeHiGmI;e,ka;!mGt7;ar2;!belHliFmT;sa;!le;ka,sGta;a,sa;elGie;a,iG;a,ca,n1qG;ue;!t7;te;je6rea;la;!bHmGstas3;ar3;el;aIberHel3iGy;e,na;!ly;l3n9;da;aTba,eNiKlIma,yG;a,c3sG;a,on,sa;iGys0J;e,s0I;a,cHna,sGza;a,ha,on,sa;e,ia;c3is5jaIna,ssaIxG;aGia;!nd4;nd4;ra;ia;i0nHyG;ah,na;a,is,naE;c5da,leDmLnslKsG;haElG;inGyW;g,n;!h;ey;ee;en;at5g2nG;es;ie;ha;aVdiSelLrG;eIiG;anLenG;a,e,ne;an0;na;aKeJiHyG;nn;a,n1;a,e;!ne;!iG;de;e,lCsG;on;yn;!lG;iAyn;ne;agaJbHiG;!gaI;ey,i8y;!e;il;ah",Place:"true¦a07b05cZdYeXfVgRhQiOjfk,kMlKmHneEoDp9que,rd,s8t5u4v3w0yyz;is1y0;!o;!c;a,t;pYsafa,t;e1he 0;bronx,hamptons;nn,x;ask,fo,oho,t,under6yd;a2e1h0;l,x;k,nnK;!cifX;kla,nt;b1w eng0;land;!r;a1co,i0t,uc;dKnn;libu,nhattS;a0gw,hr;s,x;an0ul;!s;a0cn,da,ndianMst;!x;arlem,kg,nd,wy;a2re0;at 0enwich;britain,lak6;!y village;co,l0ra;!a;urope,verglad2;ak,en,fw,ist,own4xb;al4dg,gk,hina3l2o1r0t;es;lo,nn;!t;town;!if;cn,e0kk,lvd,rooklyn;l air,verly hills;frica,lta,m5ntarct2r1sia,tl0ve;!ant1;ct0iz;ic0; oce0;an;ericas,s",WeekDay:"true¦fri2mon2s1t0wednesd3;hurs1ues1;aturd1und1;!d0;ay0;!s",Month:"true¦aBdec9feb7j2mar,nov9oct1sep0;!t8;!o8;an3u0;l1n0;!e;!y;!u1;!ru0;ary;!em0;ber;pr1ug0;!ust;!il",Date:"true¦t0weekend,yesterd2;mr2o0;d0morrow;ay;!w",FirstName:"true¦aEblair,cCdevBj8k6lashawn,m3nelly,quinn,re2sh0;ay,e0iloh;a,lby;g1ne;ar1el,org0;an;ion,lo;as8e0r9;ls7nyatta,rry;am0ess1ude;ie,m0;ie;an,on;as0heyenne;ey,sidy;lex1ndra,ubr0;ey;is",LastName:"true¦0:34;1:3B;2:39;3:2Y;4:2E;5:30;a3Bb31c2Od2Ee2Bf25g1Zh1Pi1Kj1Ek17l0Zm0Nn0Jo0Gp05rYsMtHvFwCxBy8zh6;a6ou,u;ng,o;a6eun2Uoshi1Kun;ma6ng;da,guc1Zmo27sh21zaR;iao,u;a7eb0il6o3right,u;li3Bs2;gn0lk0ng,tanabe;a6ivaldi;ssilj37zqu1;a9h8i2Go7r6sui,urn0;an,ynisJ;lst0Prr1Uth;at1Uomps2;kah0Vnaka,ylor;aEchDeChimizu,iBmiAo9t7u6zabo;ar1lliv2AzuE;a6ein0;l23rm0;sa,u3;rn4th;lva,mmo24ngh;mjon4rrano;midt,neid0ulz;ito,n7sa6to;ki;ch1dLtos,z;amBeag1Zi9o7u6;bio,iz,sD;b6dri1MgIj0Tme24osevelt,ssi,ux;erts,ins2;c6ve0F;ci,hards2;ir1os;aEeAh8ic6ow20ut1N;as6hl0;so;a6illips;m,n1T;ders5et8r7t6;e0Nr4;ez,ry;ers;h21rk0t6vl4;el,te0J;baBg0Blivei01r6;t6w1O;ega,iz;a6eils2guy5ix2owak,ym1E;gy,ka6var1K;ji6muW;ma;aEeCiBo8u6;ll0n6rr0Bssolini,ñ6;oz;lina,oKr6zart;al0Me6r0U;au,no;hhail4ll0;rci0ssi6y0;!er;eWmmad4r6tsu07;in6tin1;!o;aCe8i6op1uo;!n6u;coln,dholm;fe7n0Qr6w0J;oy;bv6v6;re;mmy,rs5u;aBennedy,imuAle0Lo8u7wo6;k,n;mar,znets4;bay6vacs;asY;ra;hn,rl9to,ur,zl4;aAen9ha3imen1o6u3;h6nYu3;an6ns2;ss2;ki0Es5;cks2nsse0D;glesi9ke8noue,shik7to,vano6;u,v;awa;da;as;aBe8itchcock,o7u6;!a3b0ghNynh;a3ffmann,rvat;mingw7nde6rN;rs2;ay;ns5rrQs7y6;asDes;an4hi6;moJ;a9il,o8r7u6;o,tierr1;ayli3ub0;m1nzal1;nd6o,rcia;hi;erAis9lor8o7uj6;ita;st0urni0;es;ch0;nand1;d7insteHsposi6vaL;to;is2wards;aCeBi9omin8u6;bo6rand;is;gu1;az,mitr4;ov;lgado,vi;nkula,rw7vi6;es,s;in;aFhBlarkAo6;h5l6op0rbyn,x;em7li6;ns;an;!e;an8e7iu,o6ristens5u3we;i,ng,u3w,y;!n,on6u3;!g;mpb7rt0st6;ro;ell;aBe8ha3lanco,oyko,r6yrne;ooks,yant;ng;ck7ethov5nnett;en;er,ham;ch,h8iley,rn6;es,i0;er;k,ng;dDl9nd6;ers6rA;en,on,s2;on;eks7iy8var1;ez;ej6;ev;ams",MaleName:"true¦0:CE;1:BL;2:C2;3:BT;4:B5;5:BZ;6:AT;7:9V;8:BD;9:AX;A:AO;aB4bA8c97d87e7Gf6Yg6Gh5Wi5Ij4Lk4Bl3Rm2Pn2Eo28p22qu20r1As0Qt06u05v00wNxavi3yGzB;aBor0;cBh8Ine;hCkB;!aB1;ar51eB0;ass2i,oCuB;sDu25;nEsDusB;oBsC;uf;ef;at0g;aJeHiCoByaAP;lfgang,odrow;lBn1O;bDey,frBJlB;aA5iB;am,e,s;e89ur;i,nde7sB;!l6t1;de,lCrr5yB;l1ne;lBt3;a93y;aEern1iBladimir;cCha0kt5CnceBrg9Bva0;!nt;ente,t5A;lentin49n8Yughn;lyss4Msm0;aTeOhKiIoErCyB;!l3ro8s1;av9QeBist0oy,um0;nt9Iv54y;bDd7XmBny;!as,mBoharu;aAYie,y;i83y;mBt9;!my,othy;adDeoCia7DomB;!as;!do7M;!de9;dErB;en8HrB;an8GeBy;ll,n8F;!dy;dgh,ic9Tnn3req,ts45;aRcotPeNhJiHoFpenc3tBur1Oylve8Hzym1;anDeBua7B;f0phAFvBwa7A;e57ie;!islaw,l6;lom1nA3uB;leyma8ta;dBl7Jm1;!n6;aDeB;lBrm0;d1t1;h6Sne,qu0Uun,wn,y8;aBbasti0k1Xl41rg40th,ymo9I;m9n;!tB;!ie,y;lCmBnti21q4Iul;!mAu4;ik,vato6V;aWeShe92iOoFuCyB;an,ou;b6LdCf9pe6QssB;!elAI;ol2Uy;an,bIcHdGel,geFh0landA9mEnDry,sCyB;!ce;coe,s;!a95nA;an,eo;l3Jr;e4Qg3n6olfo,ri68;co,ky;bAe9U;cBl6;ar5Oc5NhCkBo;!ey,ie,y;a85ie;gCid,ub5x,yBza;ansh,nS;g8WiB;na8Ss;ch5Yfa4lDmCndBpha4sh6Uul,ymo70;al9Yol2By;i9Ion;f,ph;ent2inB;cy,t1;aFeDhilCier62ol,reB;st1;!ip,lip;d9Brcy,tB;ar,e2V;b3Sdra6Ft44ul;ctav2Vliv3m96rFsCtBum8Uw5;is,to;aCc8SvB;al52;ma;i,l49vJ;athJeHiDoB;aBel,l0ma0r2X;h,m;cCg4i3IkB;h6Uola;hol5XkBol5X;!ol5W;al,d,il,ls1vB;il50;anBy;!a4i4;aWeTiKoFuCyB;l21r1;hamCr5ZstaB;fa,p4G;ed,mF;dibo,e,hamDis1XntCsBussa;es,he;e,y;ad,ed,mB;ad,ed;cGgu4kElDnCtchB;!e7;a78ik;house,o03t1;e,olB;aj;ah,hBk6;a4eB;al,l;hClv2rB;le,ri7v2;di,met;ck,hNlLmOnu4rHs1tDuricCxB;!imilian8Cwe7;e,io;eo,hCi52tB;!eo,hew,ia;eBis;us,w;cDio,k86lCqu6Gsha7tBv2;i2Hy;in,on;!el,oKus;achBcolm,ik;ai,y;amBdi,moud;adB;ou;aReNiMlo2RoIuCyB;le,nd1;cEiDkBth3;aBe;!s;gi,s;as,iaB;no;g0nn6RrenDuBwe7;!iB;e,s;!zo;am,on4;a7Bevi,la4SnDoBst3vi;!nB;!a60el;!ny;mCnBr67ur4Twr4T;ce,d1;ar,o4N;aIeDhaled,iBrist4Vu48y3B;er0p,rB;by,k,ollos;en0iEnBrmit,v2;!dCnBt5C;e0Yy;a7ri4N;r,th;na68rBthem;im,l;aYeQiOoDuB;an,liBst2;an,o,us;aqu2eJhnInGrEsB;eChBi7Bue;!ua;!ph;dBge;an,i,on;!aBny;h,s,th4X;!ath4Wie,nA;!l,sBy;ph;an,e,mB;!mA;d,ffGrDsB;sBus;!e;a5JemCmai8oBry;me,ni0O;i6Uy;!e58rB;ey,y;cHd5kGmFrDsCvi3yB;!d5s1;on,p3;ed,od,rBv4M;e4Zod;al,es,is1;e,ob,ub;k,ob,quB;es;aNbrahMchika,gKkeJlija,nuIrGsDtBv0;ai,sB;uki;aBha0i6Fma4sac;ac,iaB;h,s;a,vinBw2;!g;k,nngu52;!r;nacBor;io;im;in,n;aJeFina4VoDuByd56;be25gBmber4CsD;h,o;m3ra33sBwa3X;se2;aDctCitCn4ErB;be20m0;or;th;bKlJmza,nIo,rDsCyB;a43d5;an,s0;lEo4FrDuBv6;hi40ki,tB;a,o;is1y;an,ey;k,s;!im;ib;aQeMiLlenKoIrEuB;illerCsB;!tavo;mo;aDegBov3;!g,orB;io,y;dy,h57nt;nzaBrd1;lo;!n;lbe4Qno,ovan4R;ne,oDrB;aBry;ld,rd4U;ffr6rge;bri4l5rBv2;la1Zr3Eth,y;aReNiLlJorr0IrB;anDedBitz;!dAeBri24;ri23;cDkB;!ie,lB;in,yn;esJisB;!co,zek;etch3oB;yd;d4lBonn;ip;deriDliCng,rnB;an01;pe,x;co;bi0di;arZdUfrTit0lNmGnFo2rCsteb0th0uge8vBym5zra;an,ere2V;gi,iCnBrol,v2w2;est45ie;c07k;och,rique,zo;aGerFiCmB;aFe2P;lCrB;!h0;!io;s1y;nu4;be09d1iEliDmCt1viBwood;n,s;er,o;ot1Ts;!as,j43sB;ha;a2en;!dAg32mEuCwB;a25in;arB;do;o0Su0S;l,nB;est;aYeOiLoErDuCwByl0;ay8ight;a8dl6nc0st2;ag0ew;minFnDri0ugCyB;le;!l03;!a29nBov0;e7ie,y;go,icB;!k;armuCeBll1on,rk;go;id;anIj0lbeHmetri9nFon,rEsDvCwBxt3;ay8ey;en,in;hawn,mo08;ek,ri0F;is,nBv3;is,y;rt;!dB;re;lKmInHrDvB;e,iB;!d;en,iDne7rByl;eBin,yl;l2Vn;n,o,us;!e,i4ny;iBon;an,en,on;e,lB;as;a06e04hWiar0lLoGrEuCyrB;il,us;rtB;!is;aBistobal;ig;dy,lEnCrB;ey,neli9y;or,rB;ad;by,e,in,l2t1;aGeDiByI;fBnt;fo0Ct1;meCt9velaB;nd;nt;rDuCyB;!t1;de;enB;ce;aFeErisCuB;ck;!tB;i0oph3;st3;d,rlBs;eBie;s,y;cBdric,s11;il;lEmer1rB;ey,lCro7y;ll;!os,t1;eb,v2;ar02eUilTlaSoPrCuByr1;ddy,rtI;aJeEiDuCyB;an,ce,on;ce,no;an,ce;nCtB;!t;dCtB;!on;an,on;dCndB;en,on;!foBl6y;rd;bCrByd;is;!by;i8ke;al,lA;nFrBshoi;at,nCtB;!r10;aBie;rd0S;!edict,iCjam2nA;ie,y;to;n6rBt;eBy;tt;ey;ar0Xb0Nd0Jgust2hm0Gid5ja0ElZmXnPputsiOrFsaEuCveBya0ziz;ry;gust9st2;us;hi;aIchHi4jun,maFnDon,tBy0;hBu06;ur;av,oB;ld;an,nd0A;el;ie;ta;aq;dGgel05tB;hoEoB;i8nB;!i02y;ne;ny;reBy;!as,s,w;ir,mBos;ar;an,beOd5eIfFi,lEonDphonHt1vB;aMin;on;so,zo;an,en;onCrB;edP;so;c,jaEksandDssaExB;!and3;er;ar,er;ndB;ro;rtH;ni;en;ad,eB;d,t;in;aColfBri0vik;!o;mBn;!a;dFeEraCuB;!bakr,lfazl;hBm;am;!l;allEel,oulaye,ulB;!lCrahm0;an;ah,o;ah;av,on",Person:"true¦ashton kutchSbRcMdKeIgastNhGinez,jEkDleCmBnettJoAp8r4s3t2v0;a0irgin maG;lentino rossi,n go3;heresa may,iger woods,yra banks;addam hussain,carlett johanssJlobodan milosevic,uB;ay romano,eese witherspoIo1ush limbau0;gh;d stewart,nald0;inho,o;a0ipJ;lmIris hiltD;prah winfrFra;essiaen,itt romnEubarek;bron james,e;anye west,iefer sutherland,obe bryant;aime,effers8k rowli0;ng;alle ber0itlBulk hogan;ry;ff0meril lagasse,zekiel;ie;a0enzel washingt2ick wolf;lt1nte;ar1lint0ruz;on;dinal wols1son0;! palm2;ey;arack obama,rock;er",Verb:"true¦awak9born,cannot,fr8g7h5k3le2m1s0wors9;e8h3;ake sure,sg;ngth6ss6;eep tabs,n0;own;as0e2;!t2;iv1onna;ight0;en",PhrasalVerb:"true¦0:72;1:6Q;2:7E;3:74;4:6J;5:7H;6:76;7:6P;8:6C;9:6D;A:5I;B:71;C:70;a7Hb63c5Dd5Ae58f46g3Oh38iron0j34k2Zl2Km2Bn29o27p1Pr1Es09tQuOvacuum 1wGyammerCzD;eroAip EonD;e0k0;by,up;aJeGhFiEorDrit53;d 1k2R;mp0n4Ape0r8s8;eel Bip 7L;aEiD;gh 06rd0;n Br 3D;it 5Kk8lk6rm 0Qsh 74t67v4P;rgeCsD;e 9herA;aRePhNiJoHrFuDype 0N;ckArn D;d2in,o3Gup;ade YiDot0y 28;ckle68p 7A;ne67p Ds4D;d2o6Lup;ck FdEe Dgh5Tme0p o0Dre0;aw3ba4d2in,up;e5Ky 1;by,o6V;ink Drow 5V;ba4ov7up;aDe 4Ill4O;m 1r W;ckCke Elk D;ov7u4O;aDba4d2in,o31up;ba4ft7p4Tw3;a0Gc0Fe09h05i02lYmXnWoVpSquare RtJuHwD;earFiD;ngEtch D;aw3ba4o6P; by;ck Dit 1m 1ss0;in,up;aIe0RiHoFrD;aigh1MiD;ke 5Yn2Y;p Drm1P;by,in,o6B;n2Zr 1tc3I;c2Ymp0nd Dr6Hve6y 1;ba4d2up;d2o67up;ar2Vell0ill4UlErDurC;ingCuc8;a33it 3U;be4Crt0;ap 4Eow B;ash 4Zoke0;eep EiDow 9;c3Np 1;in,oD;ff,v7;gn Eng2Zt Dz8;d2o5up;in,o5up;aFoDu4F;ot Dut0w 5X;aw3ba4f37o5R;c2FdeAk4Sve6;e Hll0nd GtD; Dtl43;d2in,o5upD;!on;aw3ba4d2in,o1Yup;o5to;al4Lout0rap4L;il6v8;at0eKiJoGuD;b 4Ele0n Dstl8;aDba4d2in53o3Gt30u3E;c1Xw3;ot EuD;g2Knd6;a1Xf2Ro5;ng 4Op6;aDel6inAnt0;c4Yd D;o2Tu0C;aQePiOlMoKrHsyc2AuD;ll Ft D;aDba4d2in,o1Ht34up;p39w3;ap38d2in,o5t32up;attleCess EiGoD;p 1;ah1Hon;iDp 53re3Mur45wer 53;nt0;ay3ZuD;gAmp 9;ck 53g0leCn 9p3W;el 47ncilA;c3Pir 2In0ss FtEy D;ba4o4R; d2c1Y;aw3ba4o12;pDw3K;e3Jt B;arrow3Terd0oD;d6te3S;aJeHiGoEuD;ddl8ll37;c17p 1uth6ve D;al3Bd2in,o5up;ss0x 1;asur8lt 9ss D;a1Aup;ke Dn 9r30s1Lx0;do,o3Yup;aPeNiIoDuck0;a17c37g GoDse0;k Dse35;aft7ba4d2forw2Bin3Wov7uD;nd7p;in,o0J;e GghtFnEsDv1T;ten 4D;e 1k 1; 1e2Y;ar43d2;av1Ht 2YvelD; o3L;p 1sh DtchCugh6y1U;in3Lo5;eEick6nock D;d2o3H;eDyA;l2Hp D;aw3ba4d2fSin,o05to,up;aFoEuD;ic8mpA;ke2St2W;c31zz 1;aPeKiHoEuD;nker2Ts0U;lDneArse2O;d De 1;ba4d2fast,oZup;de Et D;ba4on,up;aw3o5;aDlp0;d Fl22r Dt 1;fDof;rom;in,oRu1A;cZm 1nDve it,ze1Y;d Dg 27kerF;d2in,o5;aReLive Jloss1VoFrEunD; f0M;in39ow 23; Dof 0U;aEb17it,oDr35t0Ou12;ff,n,v7;bo5ft7hJw3;aw3ba4d2in,oDup,w3;ff,n,ut;a17ek0t D;aEb11d2oDr2Zup;ff,n,ut,v7;cEhDl1Pr2Xt,w3;ead;ross;d aEnD;g 1;bo5;a08e01iRlNoJrFuD;cDel 1;k 1;eEighten DownCy 1;aw3o2L;eDshe1G; 1z8;lFol D;aDwi19;bo5r2I;d 9;aEeDip0;sh0;g 9ke0mDrD;e 2K;gLlJnHrFsEzzD;le0;h 2H;e Dm 1;aw3ba4up;d0isD;h 1;e Dl 11;aw3fI;ht ba4ure0;eInEsD;s 1;cFd D;fDo1X;or;e B;dQl 1;cHll Drm0t0O;apYbFd2in,oEtD;hrough;ff,ut,v7;a4ehi1S;e E;at0dge0nd Dy8;o1Mup;o09rD;ess 9op D;aw3bNin,o15;aShPlean 9oDross But 0T;me FoEuntD; o1M;k 1l6;aJbIforGin,oFtEuD;nd7;ogeth7;ut,v7;th,wD;ard;a4y;pDr19w3;art;eDipA;ck BeD;r 1;lJncel0rGsFtch EveA; in;o16up;h Bt6;ry EvD;e V;aw3o12;l Dm02;aDba4d2o10up;r0Vw3;a0He08l01oSrHuD;bbleFcklTilZlEndlTrn 05tDy 10zz6;t B;k 9; ov7;anMeaKiDush6;ghHng D;aEba4d2forDin,o5up;th;bo5lDr0Lw3;ong;teD;n 1;k D;d2in,o5up;ch0;arKgJil 9n8oGssFttlEunce Dx B;aw3ba4;e 9; ar0B;k Bt 1;e 1;d2up; d2;d 1;aIeed0oDurt0;cFw D;aw3ba4d2o5up;ck;k D;in,oK;ck0nk0st6; oJaGef 1nd D;d2ov7up;er;up;r0t D;d2in,oDup;ff,ut;ff,nD;to;ck Jil0nFrgEsD;h B;ainCe B;g BkC; on;in,o5; o5;aw3d2o5up;ay;cMdIsk Fuction6; oD;ff;arDo5;ouD;nd;d D;d2oDup;ff,n;own;t D;o5up;ut",Modal:"true¦c5lets,m4ought3sh1w0;ill,o5;a0o4;ll,nt;! to;ay,ight,ust;an,o0;uld",Adjective:"true¦0:73;1:7I;2:7O;3:7H;4:7A;5:5B;6:4R;7:49;8:48;9:7F;A:60;a6Eb60c5Md52e4Pf45g3Xh3Mi31j2Zk2Yl2Nm2Cn23o1Np16quack,r0Ws0Ct05uMvJwByear5;arp0eFholeEiDoB;man5oBu67;d69zy;despr6Zs5B;!sa7;eClBste22;co1El o4H;!k5;aCiBola47;b7Nce versa,ol50;ca2gabo5Ynilla;ltSnFpCrb55su4tterB;!mo6U; f30b1KpCsBti1D;ca7et,ide dItairs;er,i3J;aLbeco6Lconvin23deIeHfair,ivers4knGprecedUrEsCwB;iel1Writt5U;i1RuB;pervis0specti3;eBu5;cognHgul6Bl6B;own;ndi3v5Oxpect0;cid0rB;!grou5JsB;iz0tood;b7ppeaHssu6AuthorB;iz0;i20ra;aFeDhough4KoCrB;i1oubl0;geth6p,rp6B;en5LlBm4Vrr2Q;li3;boo,lBn;ent0;aTcSeQhPiNmug,nobbi3AoLpKqueami3AtFuBymb5Y;bDi gener50pBrprisi3;erBre0H;! dup6b,i25;du0seq4P;anda6OeEi0LrBy34;aightBip0; fBfB;or56;adfa5Wreotyp0;a4Uec2Cir1Flend5Wot on; call0le,mb6phist1TrBu0Tvi3X;d5Ury;gnifica2nB;ce4Qg7;am2Le6ocki3ut;cBda1em5lfi2Uni1Spa63re8;o1Cr3R;at53ient24reec53;cr0me,ns serif;aIeEiCoB;bu5Ktt4PuOy4;ghtBv4;!-25fA;ar,bel,condi1du5Xfres4XlDpublic3RsBtard0;is43oB;lu1na2;e1Auc41;b5EciB;al,st;aMeKicayu8lac5Copuli5BrCuB;bl54mp0;eFiCoB;!b06fu5Cmi2Xp6;mCor,sBva1;ti8;a4Re;ci58mB;a0EiB;er,um;ac1WrBti1;fe9ma2Pplexi3v2Z;rBst;allelDtB;-tiBi4;me;!ed;bMffKkJld fashion0nIpHrg1Dth6utGvB;al,erB;!aDniCt,wB;eiBrouB;ght;ll;do0Rer,g2Hsi41;en,posi1; boa5Ag2Fli8;!ay; gua58bBli8;eat;eDsB;cBer0Dole1;e8u3F;d2Ose;ak0eIiHoBua4J;nFrCtB;ab7;thB;!eB;rn;chala2descri4Ustop;ght5;arby,cessa3Sighbor5xt;aJeHiEoBultip7;bi7derClBnth5ot,st;dy;a1n;nBx0;iaBor;tu2Y;di49naBre;ci3;cBgenta,in,jZkeshift,le,mmoth,ny,sculi8;ab2Uho;aKeFiCoBu0Z;uti0Yvi3;mCteraB;l,te;it0;ftEgBth4;al,eCitiB;ma1;nda38;!-08;ngu3Lst,tt6;ap1Oind5no06;agg0uB;niKstifi0veni7;de4gno46lleg4mOnDpso 1RrB;a1releB;va2; JaIbr0corHdFfluenPiPnEsDtB;a9en3GoxB;ic31;a8i2N;a1er,oce2;iCoB;or;re9;deq3Eppr2T;fBsitu,vitro;ro2;mFpB;arDerfe9oBrop6;li1rtB;a2ed;ti4;eBi0M;d2Ln30;aGelFiDoBumdr36;ne2Uok0rrBs03ur5;if2N;ghfalut1KspB;an2L;liVpfA;lEnDrB;d01roB;wi3;dy,gi3;f,low0;ainfAener2Eiga1YlHoGraDuB;ilBng ho;ty;cCtB;efAis;efA;ne,od;ea28ob4;aQeKinJlIoDrB;a1PeBoz1G;e28q0YtfA;oDrB; keeps,eBm6tuna1;g00ign;liB;sh;ag2Uue2;al,i1;dFmCrB;ti7;a7ini8;ne;le; up;bl0i2l20r Cux,voB;ri1uri1;oBreac1A;ff;aJfficie2lImiHnFre9there4veExB;a9cess,pe1JtraCuB;be2Gl0D;!va19;n,ryday; Bcouragi3ti0M;rou1sui1;ne2;abo1YdMe14i1;g6sB;t,ygB;oi3;er;aReJiDoBrea11ue;mina2ne,ubB;le,tfA;dact16fficu1JsCvB;er1F;creDeas0gruntl0hone1AordCtB;a2ress0;er5;et; HadpGfFgene1KliDrang0spe1KtCvoB;ut;ail0ermin0;be1Hca1ghB;tfA;ia2;an;facto;i5magBngeroVs0E;ed,i3;ly;ertaNhief,ivil,oDrB;aBowd0u0D;mp0vYz0;loJmHnCoi3rrBve0K;e9u1D;cre1grEsDtB;emBra0B;po09;ta2;ue2;mer04pleB;te,x;ni4ss4;in;aLeHizarGlFoCrB;and new,isk,okL;gCna fiSttom,urgeoB;is;us;ank,iE;re;autifAhiClov0nBst,yoC;eRt;nd;ul;ckCnkru0SrrB;en;!wards; priori,b0Ic0Fd05fra04g00hZlUma01ntiquTppQrKsIttracti02utheHvEwB;aCkB;wa0P;ke,re;ant garCerB;age;de;ntQ;leep,tonisB;hi3;ab,bitEroDtiB;fiB;ci4;ga2;raB;ry;are2etiLrB;oprB;ia1;at0;arEcohCeBiIl,oof;rt;olB;ic;mi3;ead;ainDgressiConiB;zi3;ve;st;id; IeGuFvB;aCerB;se;nc0;ed;lt;pt,qB;ua1;hoc,infinitB;um;cuCtu4u1;al;ra1;erLlKoIruHsCuB;nda2;e2oCtra9;ct;lu1rbi3;ng;te;pt;aBve;rd;aze,e;ra2;nt",Comparable:"true¦0:3Z;1:4G;2:43;3:49;4:3V;5:2W;a4Mb42c3Md3Be33f2Pg2Dh22i1Tj1Sk1Pl1Hm1Bn15o13p0Tqu0Rr0IsRtKuIvFw7y6za11;ell25ou3;aBe9hi1Wi7r6;o3y;ck0Mde,l6n1ry,se;d,y;a6i4Kt;k,ry;n1Rr6sI;m,y;a7e6ulgar;nge4rda2xi3;gue,in,st;g0n6pco3Kse4;like0ti1;aAen9hi8i7ough,r6;anqu2Oen1ue;dy,g3Sme0ny,r09;ck,n,rs2P;d40se;ll,me,rt,s6wd45;te4;aVcarUeThRiQkin0FlMmKoHpGqua1FtAu7w6;eet,ift;b7dd13per0Gr6;e,re2H;sta2Ft5;aAe9iff,r7u6;pXr1;a6ict,o3;ig3Fn0U;a1ep,rn;le,rk;e22i3Fright0;ci28ft,l7o6re,ur;n,thi3;emn,id;a6el0ooth;ll,rt;e8i6ow,y;ck,g35m6;!y;ek,nd3D;ck,l0mp5;a6iTort,rill,y;dy,ll0Xrp;cu0Rve0Rxy;ce,ed,y;d,fe,int0l1Vv14;aBe9i8o6ude;mantic,o1Isy,u6;gh,nd;ch,pe,tzy;a6d,mo0H;dy,l;gg7ndom,p6re,w;id;ed;ai2i6;ck,et;aEhoDi1QlCoBr8u6;ny,r6;e,p5;egna2ic7o6;fouYud;ey,k0;li04or,te1B;ain,easa2;ny;in4le;dd,f6i0ld,ranQ;fi10;aAe8i7o6;b5isy,rm15sy;ce,mb5;a6w;r,t;ive,rr01;aAe8ild,o7u6;nda19te;ist,o1;a6ek,llX;n,s0ty;d,tuQ;aBeAi9o6ucky;f0Un7o1Du6ve0w17y0T;d,sy;e0g;g1Tke0tt5ve0;an,wd;me,r6te;ge;e7i6;nd;en;ol0ui1P;cy,ll,n6;sBt6;e6ima8;llege2r6;es7media6;te;ti3;ecu6ta2;re;aEeBiAo8u6;ge,m6ng1R;b5id;ll6me0t;ow;gh,l0;a6f04sita2;dy,v6;en0y;nd1Hppy,r6te4;d,sh;aGenFhDiClBoofy,r6;a9e8is0o6ue1E;o6ss;vy;at,en,y;nd,y;ad,ib,ooI;a2d1;a6o6;st0;t5uiY;u1y;aIeeb5iDlat,oAr8u6;ll,n6r14;!ny;aHe6iend0;e,sh;a7r6ul;get4mG;my;erce8n6rm,t;an6e;ciC;! ;le;ir,ke,n0Fr,st,t,ulA;aAerie,mp9sse7v6xtre0Q;il;nti6;al;ty;r7s6;tern,y;ly,th0;aFeCi9r7u6;ll,mb;u6y;nk;r7vi6;ne;e,ty;a6ep,nD;d6f,r;!ly;mp,pp03rk;aHhDlAo8r7u6;dd0r0te;isp,uel;ar6ld,mmon,ol,st0ward0zy;se;e6ou1;a6vW;n,r;ar8e6il0;ap,e6;sy;mi3;gey,lm8r6;e4i3;ful;!i3;aNiLlIoEr8u6;r0sy;ly;aAi7o6;ad,wn;ef,g7llia2;nt;ht;sh,ve;ld,r7un6;cy;ed,i3;ng;a7o6ue;nd,o1;ck,nd;g,tt6;er;d,ld,w1;dy;bsu9ng8we6;so6;me;ry;rd",TextValue:"true¦bOeJfDhundredNmOninAone,qu8s6t0zeroN;enMh3rNw0;e0o;l0ntD;fHve;ir0ousandKree;d,t6;e0ix8;cond,pt1ven7xt1;adr0int0;illionD;e0th;!t0;e9ie8y;i3o0;rt1ur0;!t2;ie4y;ft0rst,ve;e3h,ie2y;ight0lev2;!e1h,ie0y;th;en0;!th;illion0;!s,th",Ordinal:"true¦bGeDf9hundredHmGnin7qu6s4t0zeroH;enGh1rFwe0;lfFn9;ir0ousandE;d,t4;e0ixt9;cond,ptAvent8xtA;adr9int9;et0th;e6ie8;i2o0;r0urt3;tie5;ft1rst;ight0lev1;e0h,ie2;en1;illion0;th",Cardinal:"true¦bHeEf8hundred,mHnineAone,qu6s4t0zero;en,h2rGw0;e0o;lve,n8;irt9ousandEree;e0ix5;pt1ven4xt1;adr0int0;illion;i3o0;r1ur0;!t2;ty;ft0ve;e2y;ight0lev1;!e0y;en;illion0;!s",Expression:"true¦a02b01dXeVfuck,gShLlImHnGoDpBshAtsk,u7voi04w3y0;a1eLu0;ck,p;!a,hoo,y;h1ow,t0;af,f;e0oa;e,w;gh,h0;! 0h,m;huh,oh;eesh,hh,it;ff,hew,l0sst;ease,z;h1o0w,y;h,o,ps;!h;ah,ope;eh,mm;m1ol0;!s;ao,fao;a4e2i,mm,oly1urr0;ah;! mo6;e,ll0y;!o;ha0i;!ha;ah,ee,o0rr;l0odbye;ly;e0h,t cetera,ww;k,p;'oh,a0uh;m0ng;mit,n0;!it;ah,oo,ye; 1h0rgh;!em;la",Adverb:"true¦a07by 05d01eYfShQinPjustOkinda,mMnJoEpCquite,r9s5t2up1very,w0Bye0;p,s; to,wards5;h1o0wiO;o,t6ward;en,us;everal,o0uch;!me1rt0; of;hXtimes,w07;a1e0;alS;ndomRthN;ar excellDer0oint blank; Mhaps;f3n0;ce0ly;! 0;ag00moU; courHten;ewJo0; longEt 0;onHwithstanding;aybe,eanwhiAore0;!ovB;! aboS;deed,steT;en0;ce;or2u0;l9rther0;!moH; 0ev3;examp0good,suF;le;n mas1v0;er;se;e0irect1; 1finite0;ly;ju7trop;far,n0;ow; CbroBd nauseam,gAl5ny2part,side,t 0w3;be5l0mo5wor5;arge,ea4;mo1w0;ay;re;l 1mo0one,ready,so,ways;st;b1t0;hat;ut;ain;ad;lot,posteriori",Preposition:"true¦'o,-,aKbHcGdFexcept,fEinDmidPnotwithstandiQoBpRqua,sAt6u3vi2w0;/o,hereMith0;!in,oQ;a,s-a-vis;n1p0;!on;like,til;h0ill,owards;an,r0;ough0u;!oI;ans,ince,o that;',f0n1ut;!f;!to;or,rom;espite,own,u3;hez,irca;ar1e0oAy;low,sides,tween;ri6;',bo7cross,ft6lo5m3propos,round,s1t0;!op;! long 0;as;id0ong0;!st;ng;er;ut",Determiner:"true¦aAboth,d8e5few,l3mu7neiCown,plenty,some,th2various,wh0;at0ich0;evB;at,e3is,ose;a,e0;!ast,s;a1i6l0nough,very;!se;ch;e0u;!s;!n0;!o0y;th0;er"},gt=["Person","Place","Organization"],ft={Noun:{notA:["Verb","Adjective","Adverb"]},Singular:{isA:"Noun",notA:"Plural"},ProperNoun:{isA:"Noun"},Person:{isA:["ProperNoun","Singular"],notA:["Place","Organization","Date"]},FirstName:{isA:"Person"},MaleName:{isA:"FirstName",notA:["FemaleName","LastName"]},FemaleName:{isA:"FirstName",notA:["MaleName","LastName"]},LastName:{isA:"Person",notA:["FirstName"]},NickName:{isA:"Person",notA:["FirstName","LastName"]},Honorific:{isA:"Noun",notA:["FirstName","LastName","Value"]},Place:{isA:"Singular",notA:["Person","Organization"]},Country:{isA:["Place","ProperNoun"],notA:["City"]},City:{isA:["Place","ProperNoun"],notA:["Country"]},Region:{isA:["Place","ProperNoun"]},Address:{isA:"Place"},Organization:{isA:["Singular","ProperNoun"],notA:["Person","Place"]},SportsTeam:{isA:"Organization"},School:{isA:"Organization"},Company:{isA:"Organization"},Plural:{isA:"Noun",notA:["Singular"]},Uncountable:{isA:"Noun"},Pronoun:{isA:"Noun",notA:gt},Actor:{isA:"Noun",notA:gt},Activity:{isA:"Noun",notA:["Person","Place"]},Unit:{isA:"Noun",notA:gt},Demonym:{isA:["Noun","ProperNoun"],notA:gt},Possessive:{isA:"Noun"}},mt={Verb:{notA:["Noun","Adjective","Adverb","Value"]},PresentTense:{isA:"Verb",notA:["PastTense","Copula","FutureTense"]},Infinitive:{isA:"PresentTense",notA:["PastTense","Gerund"]},Gerund:{isA:"PresentTense",notA:["PastTense","Copula","FutureTense"]},PastTense:{isA:"Verb",notA:["FutureTense"]},FutureTense:{isA:"Verb"},Copula:{isA:"Verb"},Modal:{isA:"Verb",notA:["Infinitive"]},PerfectTense:{isA:"Verb",notA:"Gerund"},Pluperfect:{isA:"Verb"},Participle:{isA:"Verb"},PhrasalVerb:{isA:"Verb"},Particle:{isA:"PhrasalVerb"}},vt={Value:{notA:["Verb","Adjective","Adverb"]},Ordinal:{isA:"Value",notA:["Cardinal"]},Cardinal:{isA:"Value",notA:["Ordinal"]},RomanNumeral:{isA:"Cardinal",notA:["Ordinal","TextValue"]},TextValue:{isA:"Value",notA:["NumericValue"]},NumericValue:{isA:"Value",notA:["TextValue"]},Money:{isA:"Cardinal"},Percent:{isA:"Value"}},bt=["Noun","Verb","Adjective","Adverb","Value","QuestionWord"],yt={Adjective:{notA:["Noun","Verb","Adverb","Value"]},Comparable:{isA:["Adjective"]},Comparative:{isA:["Adjective"]},Superlative:{isA:["Adjective"],notA:["Comparative"]},NumberRange:{isA:["Contraction"]},Adverb:{notA:["Noun","Verb","Adjective","Value"]},Date:{notA:["Verb","Conjunction","Adverb","Preposition","Adjective"]},Month:{isA:["Date","Singular"],notA:["Year","WeekDay","Time"]},WeekDay:{isA:["Date","Noun"]},Time:{isA:["Date"],notA:["Value"]},Determiner:{notA:bt},Conjunction:{notA:bt},Preposition:{notA:bt},QuestionWord:{notA:["Determiner"]},Currency:{},Expression:{notA:["Noun","Adjective","Verb","Adverb"]},Abbreviation:{},Url:{notA:["HashTag","PhoneNumber","Verb","Adjective","Value","AtMention","Email"]},PhoneNumber:{notA:["HashTag","Verb","Adjective","Value","AtMention","Email"]},HashTag:{},AtMention:{isA:["Noun"],notA:["HashTag","Verb","Adjective","Value","Email"]},Emoji:{notA:["HashTag","Verb","Adjective","Value","AtMention"]},Emoticon:{notA:["HashTag","Verb","Adjective","Value","AtMention"]},Email:{notA:["HashTag","Verb","Adjective","Value","AtMention"]},Auxiliary:{notA:["Noun","Adjective","Value"]},Acronym:{notA:["Plural","RomanNumeral"]},Negative:{notA:["Noun","Adjective","Value"]},Condition:{notA:["Verb","Adjective","Noun","Value"]}},wt={Noun:"blue",Verb:"green",Negative:"green",Date:"red",Value:"red",Adjective:"magenta",Preposition:"cyan",Conjunction:"cyan",Determiner:"cyan",Adverb:"cyan"},kt=function(e){return Object.keys(e).forEach((function(t){e[t].color?e[t].color=e[t].color:wt[t]?e[t].color=wt[t]:e[t].isA.some((function(r){return!!wt[r]&&(e[t].color=wt[r],!0)}))})),e},At=function(e){return Object.keys(e).forEach((function(t){for(var r=e[t],n=r.isA.length,a=0;a=0;i--,a*=36){var o=e.charCodeAt(i)-48;o>10&&(o-=7),t+=o*a}return t},Et=function(e,t,r){var n=xt(t);return n1&&(r.hasCompound[i[0]]=!0),"Singular"===t){var o=a.toPlural(e,r);n[o]=n[o]||"Plural"}if("Infinitive"===t)for(var s=a.conjugate(e,r),u=Object.keys(s),l=0;l0&&void 0!==arguments[0]?arguments[0]:"",t=e[e.length-1];if(!0===qt.hasOwnProperty(t))for(var r=0;r0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1?arguments[1]:void 0,r={};return t&&t.irregulars&&!0===t.irregulars.verbs.hasOwnProperty(e)&&(r=Object.assign({},t.irregulars.verbs[e])),void 0===(r=Object.assign({},Wt(e),r)).Gerund&&(r.Gerund=Qt.Gerund(e)),void 0===r.PastTense&&(r.PastTense=Qt.PastTense(e)),void 0===r.PresentTense&&(r.PresentTense=Qt.PresentTense(e)),r},Xt=[/ght$/,/nge$/,/ough$/,/ain$/,/uel$/,/[au]ll$/,/ow$/,/oud$/,/...p$/],Yt=[/ary$/],er={nice:"nicest",late:"latest",hard:"hardest",inner:"innermost",outer:"outermost",far:"furthest",worse:"worst",bad:"worst",good:"best",big:"biggest",large:"largest"},tr=[{reg:/y$/i,repl:"iest"},{reg:/([aeiou])t$/i,repl:"$1ttest"},{reg:/([aeou])de$/i,repl:"$1dest"},{reg:/nge$/i,repl:"ngest"},{reg:/([aeiou])te$/i,repl:"$1test"}],rr=[/ght$/,/nge$/,/ough$/,/ain$/,/uel$/,/[au]ll$/,/ow$/,/old$/,/oud$/,/e[ae]p$/],nr=[/ary$/,/ous$/],ar={grey:"greyer",gray:"grayer",green:"greener",yellow:"yellower",red:"redder",good:"better",well:"better",bad:"worse",sad:"sadder",big:"bigger"},ir=[{reg:/y$/i,repl:"ier"},{reg:/([aeiou])t$/i,repl:"$1tter"},{reg:/([aeou])de$/i,repl:"$1der"},{reg:/nge$/i,repl:"nger"}],or={toSuperlative:function(e){if(er.hasOwnProperty(e))return er[e];for(var t=0;t0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1?arguments[1]:void 0,r=t.irregulars.nouns;if(r.hasOwnProperty(e))return r[e];var n=cr(e);return null!==n?n:lr.test(e)?e+"es":e+"s"},dr=[[/([^v])ies$/i,"$1y"],[/ises$/i,"isis"],[/(kn|[^o]l|w)ives$/i,"$1ife"],[/^((?:ca|e|ha|(?:our|them|your)?se|she|wo)l|lea|loa|shea|thie)ves$/i,"$1f"],[/^(dwar|handkerchie|hoo|scar|whar)ves$/i,"$1f"],[/(antenn|formul|nebul|vertebr|vit)ae$/i,"$1a"],[/(octop|vir|radi|nucle|fung|cact|stimul)(i)$/i,"$1us"],[/(buffal|tomat|tornad)(oes)$/i,"$1o"],[/(eas)es$/i,"$1e"],[/(..[aeiou]s)es$/i,"$1"],[/(vert|ind|cort)(ices)$/i,"$1ex"],[/(matr|append)(ices)$/i,"$1ix"],[/(x|ch|ss|sh|z|o)es$/i,"$1"],[/men$/i,"man"],[/(n)ews$/i,"$1ews"],[/([ti])a$/i,"$1um"],[/([^aeiouy]|qu)ies$/i,"$1y"],[/(s)eries$/i,"$1eries"],[/(m)ovies$/i,"$1ovie"],[/([m|l])ice$/i,"$1ouse"],[/(cris|ax|test)es$/i,"$1is"],[/(alias|status)es$/i,"$1"],[/(ss)$/i,"$1"],[/(ics)$/i,"$1"],[/s$/i,""]],pr=function(e,t){var r,n=t.irregulars.nouns,a=(r=n,Object.keys(r).reduce((function(e,t){return e[r[t]]=t,e}),{}));if(a.hasOwnProperty(e))return a[e];for(var i=0;i1?a[i]&&"."!==a[i]&&r.tag(a[i],n,t.world):r.tag(e,n,t.world)}))}))},Dr={tag:function(e,t){return e?(Cr(e,this,!1,t),this):this},tagSafe:function(e,t){return e?(Cr(e,this,!0,t),this):this},unTag:function(e,t){var r=this;return this.list.forEach((function(n){n.terms().forEach((function(n){return n.unTag(e,t,r.world)}))})),this},canBe:function(e){if(!e)return this;var t=this.world,r=this.list.reduce((function(r,n){return r.concat(n.canBe(e,t))}),[]);return this.buildFrom(r)}},jr={map:function(t){var r=this;if(!t)return this;var n=this.list.map((function(e,n){var a=r.buildFrom([e]);a.from=null;var i=t(a,n);return i&&i.list&&i.list[0]?i.list[0]:i}));return 0===(n=n.filter((function(e){return e}))).length?this.buildFrom(n):"object"!==e(n[0])||"Phrase"!==n[0].isA?n:this.buildFrom(n)},forEach:function(e,t){var r=this;return e?(this.list.forEach((function(n,a){var i=r.buildFrom([n]);!0===t&&(i.from=null),e(i,a)})),this):this},filter:function(e){var t=this;if(!e)return this;var r=this.list.filter((function(r,n){var a=t.buildFrom([r]);return a.from=null,e(a,n)}));return this.buildFrom(r)},find:function(e){var t=this;if(!e)return this;var r=this.list.find((function(r,n){var a=t.buildFrom([r]);return a.from=null,e(a,n)}));return r?this.buildFrom([r]):void 0},some:function(e){var t=this;return e?this.list.some((function(r,n){var a=t.buildFrom([r]);return a.from=null,e(a,n)})):this},random:function(e){if(!this.found)return this;var t=Math.floor(Math.random()*this.list.length);if(void 0===e){var r=[this.list[t]];return this.buildFrom(r)}return t+e>this.length&&(t=(t=this.length-e)<0?0:t),this.slice(t,t+e)}},xr=function(e){return e.split(/[ -]/g)},Er=function(e,t,r){for(var n=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],r={};return e.forEach((function(e,n){var a=!0;void 0!==t[n]&&(a=t[n]),e=(e=(e||"").toLowerCase()).replace(/[,;.!?]+$/,"");var i=xr(e).map((function(e){return e.trim()}));r[i[0]]=r[i[0]]||{},1===i.length?r[i[0]].value=a:(r[i[0]].more=r[i[0]].more||[],r[i[0]].more.push({rest:i.slice(1),value:a}))})),r}(e,t),a=[],i=function(e){for(var t=r.list[e],i=t.terms().map((function(e){return e.reduced})),o=function(e){void 0!==n[i[e]]&&(void 0!==n[i[e]].more&&n[i[e]].more.forEach((function(r){void 0!==i[e+r.rest.length]&&(!0===r.rest.every((function(t,r){return t===i[e+r+1]}))&&a.push({id:t.terms()[e].id,value:r.value,length:r.rest.length+1}))})),void 0!==n[i[e]].value&&a.push({id:t.terms()[e].id,value:n[i[e]].value,length:1}))},s=0;s1&&void 0!==arguments[1]?arguments[1]:{};return t?(!0===n&&(n={keepTags:!0}),!1===n&&(n={keepTags:!1}),n=n||{},this.uncache(),this.list.forEach((function(a){var i,o=t;if("function"==typeof t&&(o=t(a)),o&&"object"===e(o)&&"Doc"===o.isA)i=o.list,r.pool().merge(o.pool());else{if("string"!=typeof o)return;!1!==n.keepCase&&a.terms(0).isTitleCase()&&(o=Or(o)),i=ht(o,r.world,r.pool());var s=r.buildFrom(i);s.tagger(),i=s.list}if(!0===n.keepTags){var u=a.json({terms:{tags:!0}}).terms;i[0].terms().forEach((function(e,t){u[t]&&e.tagSafe(u[t].tags,"keptTag",r.world)}))}a.replace(i[0],r)})),this):this.delete()},replace:function(e,t,r){return void 0===t?this.replaceWith(e,r):(this.match(e).replaceWith(t,r),this)}},Tr=E((function(e,t){t.append=function(e){var t=this;return e?(this.uncache(),this.list.forEach((function(r){var n=ht(e,t.world,t.pool())[0];t.buildFrom([n]).tagger(),r.append(n,t)})),this):this},t.insertAfter=t.append,t.insertAt=t.append,t.prepend=function(e){var t=this;return e?(this.uncache(),this.list.forEach((function(r){var n=ht(e,t.world,t.pool())[0];t.buildFrom([n]).tagger(),r.prepend(n,t)})),this):this},t.insertBefore=t.prepend,t.concat=function(){this.uncache();for(var e=this.list.slice(0),t=0;t0&&void 0!==arguments[0]?arguments[0]:{};if("number"==typeof t&&this.list[t])return this.list[t].json(r);!0===(t=n(t)).root&&this.list.forEach((function(t){t.terms().forEach((function(t){null===t.root&&t.setRoot(e.world)}))}));var a=this.list.map((function(r){return r.json(t,e.world)}));if((t.terms.offset||t.offset||t.terms.index||t.index)&&Ir(this,a,t),t.frequency||t.freq||t.count){var i={};this.list.forEach((function(e){var t=e.text("reduced");i[t]=i[t]||0,i[t]+=1})),this.list.forEach((function(e,t){a[t].count=i[e.text("reduced")]}))}if(t.unique){var o={};a=a.filter((function(e){return!0!==o[e.reduced]&&(o[e.reduced]=!0,!0)}))}return a},t.data=t.json})),Sr=E((function(e){var t=function(e,t){for(e=e.toString();e.lengtht.count?-1:e.countn?1:0},length:function(e,t){var r=e.text().trim().length,n=t.text().trim().length;return rn?-1:0},wordCount:function(e,t){var r=e.wordCount(),n=t.wordCount();return rn?-1:0}};Jr.alphabetical=Jr.alpha,Jr.wordcount=Jr.wordCount;var qr={index:!0,sequence:!0,seq:!0,sequential:!0,chron:!0,chronological:!0},Kr={sort:function(e){return"freq"===(e=e||"alpha")||"frequency"===e||"topk"===e?(r={},n={case:!0,punctuation:!1,whitespace:!0,unicode:!0},(t=this).list.forEach((function(e){var t=e.text(n);r[t]=r[t]||0,r[t]+=1})),t.list.sort((function(e,t){var a=r[e.text(n)],i=r[t.text(n)];return ai?-1:0})),t):qr.hasOwnProperty(e)?function(e){var t={};return e.json({terms:{offset:!0}}).forEach((function(e){t[e.terms[0].id]=e.terms[0].offset.start})),e.list=e.list.sort((function(e,r){return t[e.start]>t[r.start]?1:t[e.start]0){a+=o;continue}}if(void 0===r[i]||!0!==r.hasOwnProperty(i))if(i===e[a].reduced||!0!==r.hasOwnProperty(e[a].reduced)){if(!0===hn.test(i)){var s=i.replace(hn,"");!0===r.hasOwnProperty(s)&&e[a].tag(r[s],"noprefix-lexicon",t)}}else e[a].tag(r[e[a].reduced],"lexicon",t);else e[a].tag(r[i],"lexicon",t)}return e},gn=/[\'‘’‛‵′`´]$/,fn=/^(m|k|cm|km|m)\/(s|h|hr)$/,mn=[[/^[\w\.]+@[\w\.]+\.[a-z]{2,3}$/,"Email"],[/^#[a-z0-9_\u00C0-\u00FF]{2,}$/,"HashTag"],[/^@\w{2,}$/,"AtMention"],[/^(https?:\/\/|www\.)\w+\.[a-z]{2,3}/,"Url"],[/^[\w./]+\.(com|net|gov|org|ly|edu|info|biz|ru|jp|de|in|uk|br)/,"Url"],[/^[012]?[0-9](:[0-5][0-9])(:[0-5][0-9])$/,"Time"],[/^[012]?[0-9](:[0-5][0-9])?(:[0-5][0-9])? ?(am|pm)$/,"Time"],[/^[012]?[0-9](:[0-5][0-9])(:[0-5][0-9])? ?(am|pm)?$/,"Time"],[/^[PMCE]ST$/,"Time"],[/^utc ?[+-]?[0-9]+?$/,"Time"],[/^[a-z0-9]*? o\'?clock$/,"Time"],[/^[0-9]{1,4}-[0-9]{1,2}-[0-9]{1,4}$/,"Date"],[/^[0-9]{1,4}\/[0-9]{1,2}\/[0-9]{1,4}$/,"Date"],[/^ma?c\'.*/,"LastName"],[/^o\'[drlkn].*/,"LastName"],[/^ma?cd[aeiou]/,"LastName"],[/^(lol)+[sz]$/,"Expression"],[/^woo+a*?h?$/,"Expression"],[/^(un|de|re)\\-[a-z\u00C0-\u00FF]{2}/,"Verb"],[/^[0-9]{1,4}\.[0-9]{1,2}\.[0-9]{1,4}$/,"Date"],[/^[0-9]{3}-[0-9]{4}$/,"PhoneNumber"],[/^(\+?[0-9][ -])?[0-9]{3}[ -]?[0-9]{3}-[0-9]{4}$/,"PhoneNumber"],[/^[-+]?[\$\xA2-\xA5\u058F\u060B\u09F2\u09F3\u09FB\u0AF1\u0BF9\u0E3F\u17DB\u20A0-\u20BD\uA838\uFDFC\uFE69\uFF04\uFFE0\uFFE1\uFFE5\uFFE6][-+]?[0-9]+(,[0-9]{3})*(\.[0-9]+)?(k|m|b|bn)?\+?$/,["Money","Value"]],[/^[-+]?[0-9]+(,[0-9]{3})*(\.[0-9]+)?[\$\xA2-\xA5\u058F\u060B\u09F2\u09F3\u09FB\u0AF1\u0BF9\u0E3F\u17DB\u20A0-\u20BD\uA838\uFDFC\uFE69\uFF04\uFFE0\uFFE1\uFFE5\uFFE6]\+?$/,["Money","Value"]],[/^[-+]?[0-9]([0-9,.])+?(usd|eur|jpy|gbp|cad|aud|chf|cny|hkd|nzd|kr|rub)$/i,["Money","Value"]],[/^[-+]?[0-9]+(,[0-9]{3})*(\.[0-9]+)?\+?$/,["Cardinal","NumericValue"]],[/^[-+]?[0-9]+(,[0-9]{3})*(\.[0-9]+)?(st|nd|rd|th)$/,["Ordinal","NumericValue"]],[/^\.[0-9]+\+?$/,["Cardinal","NumericValue"]],[/^[-+]?[0-9]+(,[0-9]{3})*(\.[0-9]+)?%\+?$/,["Percent","Cardinal","NumericValue"]],[/^\.[0-9]+%$/,["Percent","Cardinal","NumericValue"]],[/^[0-9]{1,4}\/[0-9]{1,4}$/,"Fraction"],[/^[0-9.]{1,2}[-–][0-9]{1,2}$/,["Value","NumberRange"]],[/^[0-9.]{1,4}(st|nd|rd|th)?[-–][0-9\.]{1,4}(st|nd|rd|th)?$/,"NumberRange"],[/^[0-9.]+([a-z]{1,4})$/,"Value"]],vn=/^[IVXLCDM]{2,}$/,bn=/^M{0,4}(CM|CD|D?C{0,3})(XC|XL|L?X{0,3})(IX|IV|V?I{0,3})$/,yn="Adjective",wn="Infinitive",kn="PresentTense",An="Singular",$n="PastTense",Bn="Expression",Pn="LastName",Gn={a:[[/.[aeiou]na$/,"Noun"],[/.[oau][wvl]ska$/,Pn],[/.[^aeiou]ica$/,An],[/^([hyj]a)+$/,Bn]],c:[[/.[^aeiou]ic$/,yn]],d:[[/[aeiou](pp|ll|ss|ff|gg|tt|rr|bb|nn|mm)ed$/,$n],[/.[aeo]{2}[bdgmnprvz]ed$/,$n],[/.[aeiou][sg]hed$/,$n],[/.[aeiou]red$/,$n],[/.[aeiou]r?ried$/,$n],[/.[bcdgtr]led$/,$n],[/.[aoui]f?led$/,$n],[/.[iao]sed$/,$n],[/[aeiou]n?[cs]ed$/,$n],[/[aeiou][rl]?[mnf]ed$/,$n],[/[aeiou][ns]?c?ked$/,$n],[/[aeiou][nl]?ged$/,$n],[/.[tdbwxz]ed$/,$n],[/[^aeiou][aeiou][tvx]ed$/,$n],[/.[cdlmnprstv]ied$/,$n],[/[^aeiou]ard$/,An],[/[aeiou][^aeiou]id$/,yn],[/.[vrl]id$/,yn]],e:[[/.[lnr]ize$/,wn],[/.[^aeiou]ise$/,wn],[/.[aeiou]te$/,wn],[/.[^aeiou][ai]ble$/,yn],[/.[^aeiou]eable$/,yn],[/.[ts]ive$/,yn]],h:[[/.[^aeiouf]ish$/,yn],[/.v[iy]ch$/,Pn],[/^ug?h+$/,Bn],[/^uh[ -]?oh$/,Bn]],i:[[/.[oau][wvl]ski$/,Pn]],k:[[/^(k){2}$/,Bn]],l:[[/.[gl]ial$/,yn],[/.[^aeiou]ful$/,yn],[/.[nrtumcd]al$/,yn],[/.[^aeiou][ei]al$/,yn]],m:[[/.[^aeiou]ium$/,An],[/[^aeiou]ism$/,An],[/^h*u*m+$/,Bn],[/^\d+ ?[ap]m$/,"Date"]],n:[[/.[lsrnpb]ian$/,yn],[/[^aeiou]ician$/,"Actor"],[/[aeiou][ktrp]in$/,"Gerund"]],o:[[/^no+$/,Bn],[/^(yo)+$/,Bn],[/^woo+[pt]?$/,Bn]],r:[[/.[bdfklmst]ler$/,"Noun"],[/.[ilk]er$/,"Comparative"],[/[aeiou][pns]er$/,An],[/[^i]fer$/,wn],[/.[^aeiou][ao]pher$/,"Actor"]],t:[[/.[di]est$/,"Superlative"],[/.[icldtgrv]ent$/,yn],[/[aeiou].*ist$/,yn],[/^[a-z]et$/,"Verb"]],s:[[/.[rln]ates$/,kn],[/.[^z]ens$/,"Verb"],[/.[lstrn]us$/,An],[/.[aeiou]sks$/,kn],[/.[aeiou]kes$/,kn],[/[aeiou][^aeiou]is$/,An],[/[a-z]\'s$/,"Noun"],[/^yes+$/,Bn]],v:[[/.[^aeiou][ai][kln]ov$/,Pn]],y:[[/.[cts]hy$/,yn],[/.[st]ty$/,yn],[/.[gk]y$/,yn],[/.[tnl]ary$/,yn],[/.[oe]ry$/,An],[/[rdntkbhs]ly$/,"Adverb"],[/...lly$/,"Adverb"],[/[bszmp]{2}y$/,yn],[/.(gg|bb|zz)ly$/,yn],[/.[aeiou]my$/,yn],[/[ea]{2}zy$/,yn],[/.[^aeiou]ity$/,An]]},Cn="Adjective",Dn="Infinitive",jn="PresentTense",xn="Singular",En="PastTense",Nn="Adverb",Fn="Plural",On="Verb",zn="LastName",Tn=[null,null,{ea:xn,ia:"Noun",ic:Cn,ly:Nn,"'n":On,"'t":On},{oed:En,ued:En,xed:En," so":Nn,"'ll":"Modal","'re":"Copula",azy:Cn,end:On,ped:En,ffy:Cn,ify:Dn,ing:"Gerund",ize:Dn,lar:Cn,mum:Cn,nes:jn,nny:Cn,oid:Cn,ous:Cn,que:Cn,rmy:Cn,rol:xn,sis:xn,zes:jn},{amed:En,aped:En,ched:En,lked:En,nded:En,cted:En,dged:En,akis:zn,cede:Dn,chuk:zn,czyk:zn,ects:jn,ends:On,enko:zn,ette:xn,fies:jn,fore:Nn,gate:Dn,gone:Cn,ices:Fn,ints:Fn,ions:Fn,less:Nn,llen:Cn,made:Cn,nsen:zn,oses:jn,ould:"Modal",some:Cn,sson:zn,tage:Dn,teen:"Value",tion:xn,tive:Cn,tors:"Noun",vice:xn},{tized:En,urned:En,eased:En,ances:Fn,bound:Cn,ettes:Fn,fully:Nn,ishes:jn,ities:Fn,marek:zn,nssen:zn,ology:"Noun",ports:Fn,rough:Cn,tches:jn,tieth:"Ordinal",tures:Fn,wards:Nn,where:Nn},{auskas:zn,keeper:"Actor",logist:"Actor",teenth:"Value"},{opoulos:zn,borough:"Place",sdottir:zn}],Hn={":(":!0,":)":!0,":P":!0,":p":!0,":O":!0,":3":!0,":|":!0,":/":!0,":\\":!0,":$":!0,":*":!0,":@":!0,":-(":!0,":-)":!0,":-P":!0,":-p":!0,":-O":!0,":-3":!0,":-|":!0,":-/":!0,":-\\":!0,":-$":!0,":-*":!0,":-@":!0,":^(":!0,":^)":!0,":^P":!0,":^p":!0,":^O":!0,":^3":!0,":^|":!0,":^/":!0,":^\\":!0,":^$":!0,":^*":!0,":^@":!0,"):":!0,"(:":!0,"$:":!0,"*:":!0,")-:":!0,"(-:":!0,"$-:":!0,"*-:":!0,")^:":!0,"(^:":!0,"$^:":!0,"*^:":!0,"<3":!0,"2){var a=n.clean[n.clean.length-2];if("s"===a)return void n.tag(["Possessive","Noun"],"end-tick",r);"n"===a&&n.tag(["Gerund"],"chillin",r)}fn.test(n.text)&&n.tag("Unit","per-sec",r)},regex:function(e,t){for(var r=e.text,n=0;n=2&&vn.test(r)&&bn.test(r)&&e.tag("RomanNumeral","xvii",t)},suffix:function(e,t){!function(e,t){var r=e.clean.length,n=7;r<=n&&(n=r-1);for(var a=n;a>1;a-=1){var i=e.clean.substr(r-a,r);if(!0===Tn[i.length].hasOwnProperty(i)){var o=Tn[i.length][i];e.tagSafe(o,"suffix -"+i,t);break}}}(e,t),function(e,t){var r=e.clean,n=r[r.length-1];if(!0===Gn.hasOwnProperty(n))for(var a=Gn[n],i=0;i35)))}(n=(n=n.trim()).replace(/[.!?,]$/,""))&&(e.tag("Emoji","comma-emoji",t),e.text=n,e.pre=e.pre.replace(":",""),e.post=e.post.replace(":","")),e.text.match(Vn)&&(e.tag("Emoji","unicode-emoji",t),e.text=n),!0===(r=(r=n).replace(/^[:;]/,":"),Hn.hasOwnProperty(r))&&(e.tag("Emoticon","emoticon-emoji",t),e.text=n)}},Mn=function(e,t){var r=e.world;In.lexicon(t,r);for(var n=0;n3&&void 0!==r[n]&&!0===r.hasOwnProperty(n)&&e.tag(r[n],"stem-"+n,t)}}))},Zn={isSingular:[/(ax|test)is$/i,/(octop|vir|radi|nucle|fung|cact|stimul)us$/i,/(octop|vir)i$/i,/(rl)f$/i,/(alias|status)$/i,/(bu)s$/i,/(al|ad|at|er|et|ed|ad)o$/i,/(ti)um$/i,/(ti)a$/i,/sis$/i,/(?:(^f)fe|(lr)f)$/i,/hive$/i,/s[aeiou]+ns$/i,/(^aeiouy|qu)y$/i,/(x|ch|ss|sh|z)$/i,/(matr|vert|ind|cort)(ix|ex)$/i,/(m|l)ouse$/i,/(m|l)ice$/i,/(antenn|formul|nebul|vertebr|vit)a$/i,/.sis$/i,/^(?!talis|.*hu)(.*)man$/i],isPlural:[/(^v)ies$/i,/ises$/i,/ives$/i,/(antenn|formul|nebul|vertebr|vit)ae$/i,/(octop|vir|radi|nucle|fung|cact|stimul)i$/i,/(buffal|tomat|tornad)oes$/i,/(analy|ba|diagno|parenthe|progno|synop|the)ses$/i,/(vert|ind|cort)ices$/i,/(matr|append)ices$/i,/(x|ch|ss|sh|s|z|o)es$/i,/is$/i,/men$/i,/news$/i,/.tia$/i,/(^f)ves$/i,/(lr)ves$/i,/(^aeiouy|qu)ies$/i,/(m|l)ice$/i,/(cris|ax|test)es$/i,/(alias|status)es$/i,/ics$/i]},Xn=["Uncountable","Pronoun","Place","Value","Person","Month","WeekDay","Holiday"],Yn=[/ss$/,/sis$/,/[^aeiou][uo]s$/,/'s$/],ea=[/i$/,/ae$/],ta=function(e,t){if(e.tags.Noun&&!e.tags.Acronym){var r=e.clean;if(e.tags.Singular||e.tags.Plural)return;if(r.length<=3)return void e.tag("Singular","short-singular",t);if(Xn.find((function(t){return e.tags[t]})))return;if(Zn.isPlural.find((function(e){return e.test(r)})))return void e.tag("Plural","plural-rules",t);if(Zn.isSingular.find((function(e){return e.test(r)})))return void e.tag("Singular","singular-rules",t);if(!0===/s$/.test(r)){if(Yn.find((function(e){return e.test(r)})))return;return void e.tag("Plural","plural-fallback",t)}if(ea.find((function(e){return e.test(r)})))return;e.tag("Singular","singular-fallback",t)}},ra=["academy","administration","agence","agences","agencies","agency","airlines","airways","army","assoc","associates","association","assurance","authority","autorite","aviation","bank","banque","board","boys","brands","brewery","brotherhood","brothers","building society","bureau","cafe","caisse","capital","care","cathedral","center","central bank","centre","chemicals","choir","chronicle","church","circus","clinic","clinique","club","co","coalition","coffee","collective","college","commission","committee","communications","community","company","comprehensive","computers","confederation","conference","conseil","consulting","containers","corporation","corps","corp","council","crew","daily news","data","departement","department","department store","departments","design","development","directorate","division","drilling","education","eglise","electric","electricity","energy","ensemble","enterprise","enterprises","entertainment","estate","etat","evening news","faculty","federation","financial","fm","foundation","fund","gas","gazette","girls","government","group","guild","health authority","herald","holdings","hospital","hotel","hotels","inc","industries","institut","institute","institute of technology","institutes","insurance","international","interstate","investment","investments","investors","journal","laboratory","labs","liberation army","limited","local authority","local health authority","machines","magazine","management","marine","marketing","markets","media","memorial","mercantile exchange","ministere","ministry","military","mobile","motor","motors","musee","museum","news","news service","observatory","office","oil","optical","orchestra","organization","partners","partnership","people's party","petrol","petroleum","pharmacare","pharmaceutical","pharmaceuticals","pizza","plc","police","polytechnic","post","power","press","productions","quartet","radio","regional authority","regional health authority","reserve","resources","restaurant","restaurants","savings","school","securities","service","services","social club","societe","society","sons","standard","state police","state university","stock exchange","subcommittee","syndicat","systems","telecommunications","telegraph","television","times","tribunal","tv","union","university","utilities","workers"].reduce((function(e,t){return e[t]="Noun",e}),{}),na=function(e){return!!e.tags.Noun&&(!(e.tags.Pronoun||e.tags.Comma||e.tags.Possessive)&&!!(e.tags.Organization||e.tags.Acronym||e.tags.Place||e.titleCase()))},aa=/^[A-Z]('s|,)?$/,ia=/([A-Z]\.){2}[A-Z]?/i,oa={I:!0,A:!0},sa={neighbours:Jn,case:Rn,stem:Qn,plural:ta,organizations:function(e,t){for(var r=0;r0?Ra=Ra.concat(t):Ra.push(e)})),Ra.forEach((function(e){var t,r,n;return e.required=(t=e.reg,r=[],n=[],t.forEach((function(e){!0!==e.optional&&!0!==e.negative&&(void 0!==e.tag&&r.push(e.tag),void 0!==e.word&&n.push(e.word))})),{tags:Fa(r),words:Fa(n)}),e}));var Wa=Ra,Ua=function(e){Wa.forEach((function(t){var r=[];t.required.words.forEach((function(t){r.push(e._cache.words[t]||[])})),t.required.tags.forEach((function(t){r.push(e._cache.tags[t]||[])}));var n=function(e){if(0===e.length)return[];var t={};e.forEach((function(e){e=Fa(e);for(var r=0;r5&&e.match("#Verb+").length>=2}));if(u.found){var l=u.splitAfter("#Noun .* #Verb .* #Noun+");n=n.splitOn(l.eq(0))}return"number"==typeof t&&(n=n.get(t)),new e(n.list,this,this.world)},e},ri=function(e){var r=function(e){a(i,e);var r=u(i);function i(e,n,a){var o;return t(this,i),(o=r.call(this,e,n,a)).contracted=null,o}return n(i,[{key:"expand",value:function(){return this.list.forEach((function(e){var t=e.terms(),r=t[0].isTitleCase();t.forEach((function(e,r){e.set(e.implicit||e.text),e.implicit=void 0,r0}}),Object.defineProperty(this,"length",{get:function(){return i.list.length}}),Object.defineProperty(this,"isA",{get:function(){return"Doc"}})}return n(e,[{key:"tagger",value:function(){return Za(this)}},{key:"pool",value:function(){return this.list.length>0?this.list[0].pool:this.all().list[0].pool}}]),e}();Fi.prototype.buildFrom=function(e){return e=e.map((function(e){return e.clone(!0)})),new Fi(e,this,this.world)},Fi.prototype.fromText=function(e){var t=ht(e,this.world,this.pool());return this.buildFrom(t)},Object.assign(Fi.prototype,Ni.misc),Object.assign(Fi.prototype,Ni.selections),Ei(Fi);var Oi={untag:"unTag",and:"match",notIf:"ifNo",only:"if",onlyIf:"if"};Object.keys(Oi).forEach((function(e){return Fi.prototype[e]=Fi.prototype[Oi[e]]}));var zi=Fi,Ti=function(e){var t=e.termList();return pn(t,e.world),e};return function e(t){var r=t,n=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1?arguments[1]:void 0;t&&r.addWords(t);var n=ht(e,r),a=new zi(n,null,r);return a.tagger(),a};return n.tokenize=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1?arguments[1]:void 0,n=r;t&&((n=n.clone()).words={},n.addWords(t));var a=ht(e,n),i=new zi(a,null,n);return t&&Ti(i),i},n.extend=function(e){return e(zi,r,this,_e,oe,qe),this},n.fromJSON=function(e){var t=dt(e,r);return new zi(t,null,r)},n.clone=function(){return e(r.clone())},n.verbose=function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return r.verbose(e),this},n.world=function(){return r},n.version="13.3.2",n.import=n.load,n}(new Ar)})); +!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).nlp=t()}(this,(function(){"use strict";function e(t){return(e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(t)}function t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){for(var r=0;re.length)&&(t=e.length);for(var r=0,n=new Array(t);rn[t].lineage.length?1:n[e].isA.length>n[t].isA.length?-1:0:0:1}))},J={text:!0,tags:!0,implicit:!0,whitespace:!0,clean:!1,id:!1,index:!1,offset:!1,bestTag:!1},q={json:function(e,t){e=e||{};var r={};return(e=Object.assign({},J,e)).text&&(r.text=this.text),e.normal&&(r.normal=this.normal),e.tags&&(r.tags=Object.keys(this.tags)),e.clean&&(r.clean=this.clean),(e.id||e.offset)&&(r.id=this.id),e.implicit&&null!==this.implicit&&(r.implicit=this.implicit),e.whitespace&&(r.pre=this.pre,r.post=this.post),e.bestTag&&(r.bestTag=_(this,t)[0]),r}},K=Object.assign({},N,F,V,S,q);function R(){return"undefined"!=typeof window&&window.document}var W=function(e,t){for(e=e.toString();e.length0&&void 0!==arguments[0]?arguments[0]:"";t(this,e),r=String(r);var n=j(r);this.text=n.text||"",this.clean=n.clean,this.reduced=n.reduced,this.root=null,this.implicit=null,this.pre=n.pre||"",this.post=n.post||"",this.tags={},this.prev=null,this.next=null,this.id=d(n.clean),this.isA="Term",n.alias&&(this.alias=n.alias)}return n(e,[{key:"set",value:function(e){var t=j(e);return this.text=t.text,this.clean=t.clean,this}}]),e}();ie.prototype.clone=function(){var e=new ie(this.text);return e.pre=this.pre,e.post=this.post,e.clean=this.clean,e.reduced=this.reduced,e.root=this.root,e.implicit=this.implicit,e.tags=Object.assign({},this.tags),e},Object.assign(ie.prototype,K),Object.assign(ie.prototype,ae);var oe=ie,se={terms:function(e){if(0===this.length)return[];if(this.cache.terms)return void 0!==e?this.cache.terms[e]:this.cache.terms;for(var t=[this.pool.get(this.start)],r=0;r0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0,r=arguments.length>2?arguments[2]:void 0;"string"==typeof e&&(e="normal"===e?{whitespace:!0,unicode:!0,lowercase:!0,punctuation:!0,acronyms:!0,abbreviations:!0,implicit:!0,normal:!0}:"clean"===e?{titlecase:!1,lowercase:!0,punctuation:!0,whitespace:!0,unicode:!0,implicit:!0}:"reduced"===e?{titlecase:!1,lowercase:!0,punctuation:!1,whitespace:!0,unicode:!0,implicit:!0,reduced:!0}:"root"===e?{titlecase:!1,lowercase:!0,punctuation:!0,whitespace:!0,unicode:!0,implicit:!0,root:!0}:{});var n=this.terms(),a=!1;n[0]&&null===n[0].prev&&null===n[n.length-1].next&&(a=!0);var i=n.reduce((function(i,o,s){e.last=r&&s===n.length-1;var u=!0,l=!0;return!1===a&&(0===s&&t&&(u=!1),s===n.length-1&&r&&(l=!1)),i+o.textOut(e,u,l)}),"");return!0===a&&r&&(i=ue(i)),!0===e.trim&&(i=i.trim()),i}},ce={trim:function(){var e=this.terms();if(e.length>0){e[0].pre=e[0].pre.replace(/^\s+/,"");var t=e[e.length-1];t.post=t.post.replace(/\s+$/,"")}return this}},he=/[.?!]\s*$/,de=function(e,t){t[0].pre=e[0].pre;var r,n,a=e[e.length-1],i=t[t.length-1];i.post=(r=a.post,n=i.post,he.test(n)?n+r.match(/\s*$/):r),a.post="",""===a.post&&(a.post+=" ")},pe=function(e,t,r){var n=e.terms(),a=t.terms();de(n,a),function(e,t,r){var n=e[e.length-1],a=t[t.length-1],i=n.next;n.next=t[0].id,a.next=i,i&&(r.get(i).prev=a.id);var o=e[0].id;o&&(t[0].prev=o)}(n,a,e.pool);var i=[e],o=e.start,s=[r];return(s=s.concat(r.parents())).forEach((function(e){var t=e.list.filter((function(e){return e.hasId(o)}));i=i.concat(t)})),(i=function(e){return e.filter((function(t,r){return e.indexOf(t)===r}))}(i)).forEach((function(e){e.length+=t.length})),e.cache={},e},ge=/ /,fe=function(e,t,r){var n=e.start,a=t.terms();!function(e){var t=e[e.length-1];!1===ge.test(t.post)&&(t.post+=" ")}(a),function(e,t,r){var n=r[r.length-1];n.next=e.start;var a=e.pool,i=a.get(e.start);i.prev&&(a.get(i.prev).next=t.start),r[0].prev=e.terms(0).prev,e.terms(0).prev=n.id}(e,t,a);var i=[e],o=[r];return(o=o.concat(r.parents())).forEach((function(e){var r=e.list.filter((function(e){return e.hasId(n)||e.hasId(t.start)}));i=i.concat(r)})),(i=function(e){return e.filter((function(t,r){return e.indexOf(t)===r}))}(i)).forEach((function(e){e.length+=t.length,e.start===n&&(e.start=t.start),e.cache={}})),e},me=function(e,t){var r=t.pool(),n=e.terms(),a=r.get(n[0].prev)||{},i=r.get(n[n.length-1].next)||{};n[0].implicit&&a.implicit&&(a.set(a.implicit),a.post+=" "),function(e,t,r,n){var a=e.parents();a.push(e),a.forEach((function(e){var a=e.list.find((function(e){return e.hasId(t)}));a&&(a.length-=r,a.start===t&&(a.start=n.id),a.cache={})})),e.list=e.list.filter((function(e){return!(!e.start||!e.length)}))}(t,e.start,e.length,i),a&&(a.next=i.id),i&&(i.prev=a.id)},ve={append:function(e,t){return pe(this,e,t),this},prepend:function(e,t){return fe(this,e,t),this},delete:function(e){return me(this,e),this},replace:function(e,t){var r=this.length;pe(this,e,t);var n=this.buildFrom(this.start,this.length);n.length=r,me(n,t)},splitOn:function(e){var t=this.terms(),r={before:null,match:null,after:null},n=t.findIndex((function(t){return t.id===e.start}));if(-1===n)return r;var a=t.slice(0,n);a.length>0&&(r.before=this.buildFrom(a[0].id,a.length));var i=t.slice(n,n+e.length);i.length>0&&(r.match=this.buildFrom(i[0].id,i.length));var o=t.slice(n+e.length,t.length);return o.length>0&&(r.after=this.buildFrom(o[0].id,o.length,this.pool)),r}},be={json:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0,r={};return e.text&&(r.text=this.text()),e.normal&&(r.normal=this.text("normal")),e.clean&&(r.clean=this.text("clean")),e.reduced&&(r.reduced=this.text("reduced")),e.root&&(r.root=this.text("root")),e.trim&&(r.text&&(r.text=r.text.trim()),r.normal&&(r.normal=r.normal.trim()),r.reduced&&(r.reduced=r.reduced.trim())),e.terms&&(!0===e.terms&&(e.terms={}),r.terms=this.terms().map((function(r){return r.json(e.terms,t)}))),r}},ye={lookAhead:function(e){e||(e=".*");var t=this.pool,r=[],n=this.terms();return function e(n){var a=t.get(n);a&&(r.push(a),a.prev&&e(a.next))}(n[n.length-1].next),0===r.length?[]:this.buildFrom(r[0].id,r.length).match(e)},lookBehind:function(e){e||(e=".*");var t=this.pool,r=[];return function e(n){var a=t.get(n);a&&(r.push(a),a.prev&&e(a.prev))}(t.get(this.start).prev),0===r.length?[]:this.buildFrom(r[r.length-1].id,r.length).match(e)}},we=Object.assign({},se,le,ce,ve,be,ye),ke=function(e,t){if(0===t.length)return!0;for(var r=0;r0)return!0;if(!0===n.anything&&!0===n.negative)return!0}return!1},Ae=function(e,t,r,n,a,i){for(var o=t;to)return[!1,null];if(!0===u.end&&r+o!==n)return[!1,null]}if(l){var g=Pe(a,c,e,p,u.named);o>1&&u.greedy?g.length+=o-p:g.length++}}else if(!0!==u.optional){if(!(e[o].isImplicit()&&t[s-1]&&e[o+1]&&e[o+1].doesMatch(u,r+o,n)))return[!1,null];o+=2}}else{var f=$e(e,o,t[s+1],u,r);if(void 0!==u.min&&f-ou.max){o+=u.max;continue}if(null===f)return[!1,null];l&&(Pe(a,c,e,o,u.named).length=f-o),o=f}}return[e.slice(0,o),a]},Ge=function(e,t,r){if(!r||0===r.length)return r;if(t.some((function(e){return e.end}))){var n=e[e.length-1];r=r.filter((function(e){return-1!==e.match.indexOf(n)}))}return r},xe=/\{([0-9]+,?[0-9]*)\}/,Ce=/&&/,De=new RegExp(/^<(\S+)>/),je=function(e){return e[e.length-1]},Ee=function(e){return e[0]},Ne=function(e){return e.substr(1)},Fe=function(e){return e.substr(0,e.length-1)},Oe=function(e){return e=Ne(e),e=Fe(e)},Te=function e(t){for(var r,n={},a=0;a<2;a+=1){if("$"===je(t)&&(n.end=!0,t=Fe(t)),"^"===Ee(t)&&(n.start=!0,t=Ne(t)),("["===Ee(t)||"]"===je(t))&&(n.named=!0,"["===Ee(t)?n.groupType="]"===je(t)?"single":"start":n.groupType="end",t=(t=t.replace(/^\[/,"")).replace(/\]$/,""),"<"===Ee(t))){var i=De.exec(t);i.length>=2&&(n.named=i[1],t=t.replace(i[0],""))}if("+"===je(t)&&(n.greedy=!0,t=Fe(t)),"*"!==t&&"*"===je(t)&&"\\*"!==t&&(n.greedy=!0,t=Fe(t)),"?"===je(t)&&(n.optional=!0,t=Fe(t)),"!"===Ee(t)&&(n.negative=!0,t=Ne(t)),"("===Ee(t)&&")"===je(t)){Ce.test(t)?(n.choices=t.split(Ce),n.operator="and"):(n.choices=t.split("|"),n.operator="or"),n.choices[0]=Ne(n.choices[0]);var o=n.choices.length-1;n.choices[o]=Fe(n.choices[o]),n.choices=n.choices.map((function(e){return e.trim()})),n.choices=n.choices.filter((function(e){return e})),n.choices=n.choices.map(e),t=""}if("/"===Ee(t)&&"/"===je(t))return t=Oe(t),n.regex=new RegExp(t),n;if("~"===Ee(t)&&"~"===je(t))return t=Oe(t),n.soft=!0,n.word=t,n}return!0===xe.test(t)&&(t=t.replace(xe,(function(e,t){var r=t.split(/,/g);return 1===r.length?(n.min=Number(r[0]),n.max=Number(r[0])):(n.min=Number(r[0]),n.max=Number(r[1]||999)),n.greedy=!0,""}))),"#"===Ee(t)?(n.tag=Ne(t),n.tag=(r=n.tag).charAt(0).toUpperCase()+r.substr(1),n):"@"===Ee(t)?(n.method=Ne(t),n):"."===t?(n.anything=!0,n):"*"===t?(n.anything=!0,n.greedy=!0,n.optional=!0,n):(t&&(t=(t=t.replace("\\*","*")).replace("\\.","."),n.word=t.toLowerCase()),n)},ze=function(e){return e.filter((function(e){return e.groupType})).length>0&&(e=function(e){for(var t,r,n=!1,a=-1,i=0;i)?\(.*?\)[?+*]*\]?\$?)/);return t.map((function(e){return e.trim()}))}(t);return r=(r=function(e){var t=[];return e.forEach((function(e){if(/^[[^_/]?\(/.test(e[0]))t.push(e);else{var r=e.split(" ");r=r.filter((function(e){return e})),t=t.concat(r)}})),t}(r)).map(Te),r=ze(r)},Ve=function(e,t){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if("string"==typeof t&&(t=He(t)),!0===ke(e,t))return[];var n=t.filter((function(e){return!0!==e.optional})).length,a=e.terms(),i=[];if(!0===t[0].start){var o=Be(a,t,0,a.length),s=l(o,2),u=s[0],c=s[1];return!1!==u&&u.length>0&&(u=u.filter((function(e){return e})),i.push({match:u,groups:c})),Ge(a,t,i)}for(var h=0;ha.length);h+=1){var d=Be(a.slice(h),t,h,a.length),p=l(d,2),g=p[0],f=p[1];if(!1!==g&&g.length>0&&(h+=g.length-1,g=g.filter((function(e){return e})),i.push({match:g,groups:f}),!0===r))return Ge(a,t,i)}return Ge(a,t,i)},Ie=function(e,t){var r={};Ve(e,t).forEach((function(e){e.match.forEach((function(e){r[e.id]=!0}))}));var n=e.terms(),a=[],i=[];return n.forEach((function(e){!0!==r[e.id]?i.push(e):i.length>0&&(a.push(i),i=[])})),i.length>0&&a.push(i),a},Me={match:function(e){var t=this,r=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=Ve(this,e,r);return n=n.map((function(e){var r=e.match,n=e.groups,a=t.buildFrom(r[0].id,r.length,n);return a.cache.terms=r,a}))},has:function(e){return Ve(this,e,!0).length>0},not:function(e){var t=this,r=Ie(this,e);return r=r.map((function(e){return t.buildFrom(e[0].id,e.length)}))},canBe:function(e,t){for(var r=this,n=[],a=this.terms(),i=!1,o=0;o0})).map((function(e){return r.buildFrom(e[0].id,e.length)}))}},Se=function e(r,n,a){t(this,e),this.start=r,this.length=n,this.isA="Phrase",Object.defineProperty(this,"pool",{enumerable:!1,writable:!0,value:a}),Object.defineProperty(this,"cache",{enumerable:!1,writable:!0,value:{}}),Object.defineProperty(this,"groups",{enumerable:!1,writable:!0,value:{}})};Se.prototype.buildFrom=function(e,t,r){var n=new Se(e,t,this.pool);return r&&Object.keys(r).length>0?n.groups=r:n.groups=this.groups,n},Object.assign(Se.prototype,Me),Object.assign(Se.prototype,we);var Le={term:"terms"};Object.keys(Le).forEach((function(e){return Se.prototype[e]=Se.prototype[Le[e]]}));var _e=Se,Je=function(){function e(){var r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};t(this,e),Object.defineProperty(this,"words",{enumerable:!1,value:r})}return n(e,[{key:"add",value:function(e){return this.words[e.id]=e,this}},{key:"get",value:function(e){return this.words[e]}},{key:"remove",value:function(e){delete this.words[e]}},{key:"merge",value:function(e){return Object.assign(this.words,e.words),this}},{key:"stats",value:function(){return{words:Object.keys(this.words).length}}}]),e}();Je.prototype.clone=function(){var e=this,t=Object.keys(this.words).reduce((function(t,r){var n=e.words[r].clone();return t[n.id]=n,t}),{});return new Je(t)};for(var qe=Je,Ke=function(e){e.forEach((function(t,r){r>0&&(t.prev=e[r-1].id),e[r+1]&&(t.next=e[r+1].id)}))},Re=/(\S.+?[.!?\u203D\u2E18\u203C\u2047-\u2049])(?=\s+|$)/g,We=/\S/,Ue=/[ .][A-Z]\.? *$/i,Qe=/(?:\u2026|\.{2,}) *$/,Ze=/((?:\r?\n|\r)+)/,Xe=/[a-z0-9\u00C0-\u00FF\u00a9|\u00ae|[\u2000-\u3300]|\ud83c[\ud000-\udfff]|\ud83d[\ud000-\udfff]|\ud83e[\ud000-\udfff]/i,Ye=/^\s+/,et=function(e,t){if(!0===Ue.test(e))return!1;if(!0===Qe.test(e))return!1;if(!1===Xe.test(e))return!1;var r=e.replace(/[.!?\u203D\u2E18\u203C\u2047-\u2049] *$/,"").split(" "),n=r[r.length-1].toLowerCase();return!t.hasOwnProperty(n)},tt=function(e,t){var r=t.cache.abbreviations;e=e||"";var n=[],a=[];if(!(e=String(e))||"string"!=typeof e||!1===We.test(e))return n;for(var i=function(e){for(var t=[],r=e.split(Ze),n=0;n0&&(n.push(l),a[u]="")}if(0===n.length)return[e];for(var c=1;c0?(t[t.length-1]+=i,t.push(s)):t.push(i+s),i=""):i+=s}return i&&(0===t.length&&(t[0]=""),t[t.length-1]+=i),t=(t=function(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1?arguments[1]:void 0,r=arguments.length>2?arguments[2]:void 0,n=null;"string"!=typeof e&&("number"==typeof e?e=String(e):ct(e)&&(n=e)),n=(n=n||tt(e,t)).map((function(e){return lt(e)})),r=r||new qe;var a=n.map((function(e){e=e.map((function(e){var t=new oe(e);return r.add(t),t})),Ke(e);var t=new _e(e[0].id,e.length,r);return t.cache.terms=e,t}));return a},dt=function(e,t){var r=new qe;return e.map((function(e,n){var a=e.terms.map((function(a,i){var o=new oe(a.text);return o.pre=void 0!==a.pre?a.pre:"",void 0===a.post&&(a.post=" ",i>=e.terms.length-1&&(a.post=". ",n>=e.terms.length-1&&(a.post="."))),o.post=void 0!==a.post?a.post:" ",a.tags&&a.tags.forEach((function(e){return o.tag(e,"",t)})),r.add(o),o}));return Ke(a),new _e(a[0].id,a.length,r)}))},pt={Comparative:"true¦better",Superlative:"true¦earlier",PresentTense:"true¦is,sounds",Value:"true¦a few",Noun:"true¦a5b4c2f1here,ie,lit,m0no doubt,pd,tce;a,d;t,y;a,ca,o0;l,rp;a,l;d,l,rc",Copula:"true¦a1is,w0;as,ere;m,re",PastTense:"true¦be3came,d2had,lied,meant,sa2taken,w0;as,e0;nt,re;id;en,gan",Condition:"true¦if,lest,unless",Gerund:"true¦accord0be0develop0go0result0stain0;ing",Negative:"true¦n0;ever,o0;!n,t",QuestionWord:"true¦how3wh0;at,e1ich,o0y;!m,se;n,re; come,'s",Plural:"true¦records",Conjunction:"true¦&,aEbAcuz,how8in caDno7o6p4supposing,t1vers5wh0yet;eth8ile;h0o;eref9o0;!uC;l0rovided that;us;r,therwi6; matt1r;!ev0;er;e0ut;cau1f0;ore;se;lthou1nd,s 0;far as,if;gh",Pronoun:"true¦'em,elle,h4i3me,ourselves,she5th1us,we,you0;!rself;e0ou;m,y;!l,t;e0im;!'s",Singular:"true¦0:0Z;1:12;a0Yb0Mc0Dd06e04fZgUhQiPjel0kitty,lOmKnJoIpEquestion mark,rCs7t4u2womY;nc0Ts 2;doll0Fst0H; rex,a3h2ic,ragedy,v show;ere,i1;l0x return;i5ky,omeone,t2uper bowl,yst0Y;ep3ri1u2;de0Rff;faOmoO;st0Nze;al0i1o2;om,se;a4i0Kl06r3u2;dMrpoE;erogaWobl0P;rt,te0J;bjTceHthers;othi1umb0F;a4ee05o2;del,m2nopo0th0D;!my;n,yf0;i0unch;ci1nsect;ead start,o2;l0me3u2;se;! run;adf0entlem5irlZlaci04od,rand3u2;l0y; slam,fa2mo2;th01;an;a5ella,ly,ol0r3un2;di1;iTo2;ntiWsN;mi0thV;conomy,gg,ner5veWx2;ampQecu7;ad7e4innSo2ragonf0ude;cumentFg2i0l0or;gy;ath,t2;ec2;tive;!dy;a8eili1h6i4o2redit card;ttage,u2;riJsin;ty,vil w2;ar;andeliGocol2;ate;n2rD;ary;aAel0lesHo6r4u2;n2tterf0;ti1;eakfast,o2;!th8;dy,tt4y2;!fri2;end;le;nki1r2;ri2;er;d4l0noma0u2;nt;ly; homin4verti2;si1;ng;em",Actor:"true¦aJbGcFdCengineIfAgardenIh9instructPjournalLlawyIm8nurse,opeOp5r3s1t0;echnCherapK;ailNcientJoldiGu0;pervKrgeon;e0oofE;ceptionGsearC;hotographClumbColi1r0sychologF;actitionBogrammB;cem6t5;echanic,inist9us4;airdress8ousekeep8;arm7ire0;fight6m2;eputy,iet0;ici0;an;arpent2lerk;ricklay1ut0;ch0;er;ccoun6d2ge7r0ssis6ttenda7;chitect,t0;ist;minist1v0;is1;rat0;or;ta0;nt",Honorific:"true¦a03b00cSdReQfiLgKhon,jr,king,lJmEoDp8queen,r4s0taoiseach,vice7;e1fc,gt,ir,r,u0;ltTpt,rg;c0nDrgeaL;ond liJretary;abbi,e0;ar1pAs,v0;!erend; admirY;astPhd,r0vt;esideEi1of0;!essN;me mini5nce0;!ss;fficOp,rd;a3essrs,i2lle,me,r1s0;!tr;!s;stK;gistrate,j,r6yF;i3lb,t;en,ov;eld mar3rst l0;ady,i0;eutena0;nt;shG;sq,xcellency;et,oct6r,utchess;apt6hance4mdr,o0pl;lonel,m2ngress0unci3;m0wom0;an;dr,mand5;ll0;or;!ain;ldg,rig0;!adi0;er;d0sst,tty,yatullah;j,m0v;!ir0;al",SportsTeam:"true¦0:1A;1:1H;2:1G;a1Eb16c0Td0Kfc dallas,g0Ihouston 0Hindiana0Gjacksonville jagua0k0El0Bm01newToQpJqueens parkIreal salt lake,sAt5utah jazz,vancouver whitecaps,w3yW;ashington 3est ham0Rh10;natio1Oredski2wizar0W;ampa bay 6e5o3;ronto 3ttenham hotspur;blue ja0Mrapto0;nnessee tita2xasC;buccanee0ra0K;a7eattle 5heffield0Kporting kansas0Wt3;. louis 3oke0V;c1Frams;marine0s3;eah15ounG;cramento Rn 3;antonio spu0diego 3francisco gJjose earthquak1;char08paA; ran07;a8h5ittsburgh 4ortland t3;imbe0rail blaze0;pirat1steele0;il3oenix su2;adelphia 3li1;eagl1philNunE;dr1;akland 3klahoma city thunder,rlando magic;athle0Mrai3;de0; 3castle01;england 7orleans 6york 3;city fc,g4je0FknXme0Fred bul0Yy3;anke1;ian0D;pelica2sain0C;patrio0Brevolut3;ion;anchester Be9i3ontreal impact;ami 7lwaukee b6nnesota 3;t4u0Fvi3;kings;imberwolv1wi2;rewe0uc0K;dolphi2heat,marli2;mphis grizz3ts;li1;cXu08;a4eicesterVos angeles 3;clippe0dodDla9; galaxy,ke0;ansas city 3nE;chiefs,roya0E; pace0polis colU;astr06dynamo,rockeTtexa2;olden state warrio0reen bay pac3;ke0;.c.Aallas 7e3i05od5;nver 5troit 3;lio2pisto2ti3;ge0;broncZnuggeM;cowbo4maver3;ic00;ys; uQ;arCelKh8incinnati 6leveland 5ol3;orado r3umbus crew sc;api5ocki1;brow2cavalie0india2;bengaWre3;ds;arlotte horAicago 3;b4cubs,fire,wh3;iteB;ea0ulR;diff3olina panthe0; c3;ity;altimore 9lackburn rove0oston 5rooklyn 3uffalo bilN;ne3;ts;cel4red3; sox;tics;rs;oriol1rave2;rizona Ast8tlanta 3;brav1falco2h4u3;nited;aw9;ns;es;on villa,r3;os;c5di3;amondbac3;ks;ardi3;na3;ls",Uncountable:"true¦a1Ib1Ac11d0Ye0Rf0Lg0Hh0Ci08j07knowled1Hl02mUnews,oTpQrLsAt5vi4w0;a2ea05i1oo0;d,l;ldlife,ne;rmth,t17;neg0Yol06tae;e3h2oothpaste,r0una;affPou0;ble,sers,t;ermod1Eund12;a,nnis;a8cene04eri0Oh7il6kittl0Onow,o5p3t1u0;g0Rnshi0H;ati1De0;am,el;ace16e0;ci0Jed;ap,cc0U;k,v0T;eep,ingl0G;d04fe10l0nd;m0St;a3e1ic0;e,ke0D;c0laxa09search;ogni08rea08;bi09in;aJe1hys10last5o0ressV;lit0Zrk,w0J;a0Vtrol;bstetr0Xil,xygen;a5e3ilk,o2u0;mps,s0;ic;nGo0A;a0chan0S;slZt;chine0il,themat0Q; learn05ry;aught08e2i1ogi0Nu0;ck,g0C;ce,ghtn02ngui0LteratH;a0isG;th04;ewel7usti0G;ce,mp0nformaOtself;a0ortan0E;ti0;en0C;a3isto2o0;ck0mework,n0spitali06;ey;ry;ir,libut,ppi7;en01o1r0um,ymna08;a6ound;l0ssip;d,f;i4lour,o1urnit0;ure;od,rgive0uriNwl;ne0;ss;c6sh;conomZduca5lectr4n2quip3thZvery0;body,o0thE;ne;joy0tertain0;ment;iciNonU;tiF;ar1iabet0raugh1;es;ts;a7elcius,h3ivPl2o0urrency;al,ld w0nfusiAttA;ar;assMoth2;aos,e0;e1w0;ing;se;r4sh;a4eef,i1lood,owls,read,utt0;er;lliar1s0;on;ds;g0ss;ga0;ge;c6dvi5ero3ir2mnes1rt,thl0;et7;ty;craft;b4d0naut4;ynam3;ce;id,ou0;st0;ics",Infinitive:"true¦0:6K;1:6Y;2:57;3:6W;4:6V;5:5Z;6:67;7:6U;8:6Q;9:6I;A:6S;B:6P;C:6Z;D:6D;E:56;F:5P;a6Cb61c52d4Ae3Uf3Hg3Bh34i2Rj2Pk2Nl2Fm25n22o1Xp1Iques3Ir0Qs05tXuSvOwHyG;awn,ield;aJe1Yhist6iIoGre65;nd0rG;k,ry;pe,sh,th0;lk,nHrGsh,tDve;n,raC;d0t;aIiGo7;eGsB;!w;l6Cry;nHpGr4se;gra4Mli3Z;dGi7lo5Spub3O;erGo;mi58w1I;aMeLhKoJrHuGwi8;ne,rn;aGe0Mi5Nu8y;de,in,nsf0p,v5F;r2XuD;ank,reat2N;nd,st;lk,rg1Ps7;aZcWeVhTi4Akip,lSmRnee3Jo4YpQtJuGwitD;bmBck,ff0gge8ppHrGspe5;ge,pri1rou4Vvi3;ly,o34;aLeKoJrHuG;dy,mb6;aEeGi3;ngth2Dss,tD;p,re;m,p;in,ke,r0Qy;laFoil,rink6;e1Xi6o3H;am,ip;a2iv0oG;ck,ut;arDem,le5n1r3tt6;aHo2rG;atDew;le,re;il,ve;a05eIisk,oHuG;in,le,sh;am,ll;a01cZdu9fYgXje5lUmTnt,pQquPsKtJvGwa5O;eGiew,o34;al,l,rG;se,t;aEi2u40;eJi8oItG;!o2rG;i5uc1Y;l3rt;mb6nt,r3;e8i2;air,eHlGo3ZreseC;a9y;at;aEemb0i3Vo3;aHeGi3y;a1nt;te,x;a56r0I;act1Wer,le5u1;a11ei3k5IoGyc6;gni2Anci6rd;ch,li29s5G;i1nG;ge,k;aTerSiRlOoMrIuG;b1Zll,mp,rGsh;cha1s4J;ai1eIiCoG;cGdu9greAhibBmi1te8vi2T;eAlaim;di5pa2ss,veC;iCp,rtr3ZsGur;e,t;aHuG;g,n4;n,y;ck,le;fo30mBsi8;ck,iCrt4Fss,u1;bJccur,ff0pera7utweIverGwe;co40lap,ta20u1wG;helm;igh;ser3taE;eHotG;e,i9;ed,gle5;aLeKiIoHuG;ltip3Crd0;nit11ve;nGrr10;d,g6us;asu2lt,n0Nr4;intaEna4rHtG;ch,t0;ch,kGry;et;aLeKiIoGu1B;aGck,ok,ve;d,n;ft,ke,mBnGst2Wve;e,k;a2Dc0Et;b0Nck,uG;gh,nD;iGno2Z;ck,ll,ss;am,oEuG;d4mp;gno2mQnGss3C;cOdica7flu0MhNsKtIvG;eGol3;nt,st;erGrodu9;a5fe2;i8tG;aGru5;ll;abBibB;lu1Er1C;agi22pG;lemeCo20ro3;aKeIi2oHuG;nt,rry;n02pe,st;aGlp;d,t;nd6ppGrm,te;en;aKloAove1MrIuG;arGeAi13;ant33d;aGip,umb6;b,sp;in,th0ze;aQeaPiNlLoIracHuncG;ti3D;tu2;cus,lHrG;ce,eca8m,s2V;d,l1Z;aFoG;at,od,w;gu2lGniFx;e,l;r,tu2;il,vG;or;a13cho,le5mSnPstNvalua7xG;a0AcLerKi8pGte17;a16eHi2laEoGreA;rt,se;ct,riG;en9;ci1t;el,han4;abGima7;liF;ab6couXdHfor9ga4han9j03riDsu2t0vG;isi2Qy;!u2;body,er4pG;hasiGow0;ze;a06eUiLoKrHuG;mp;aHeAiG;ft;g,in;d4ubt;ff0p,re5sHvG;iYor9;aKcHliGmiApl16tinguiF;ke;oGuA;uGv0;ra4;gr1TppG;ear,ro3;cNem,fLliv0ma0Dny,pKsHterG;mi0E;cribe,er3iHtrG;oy;gn,re;a09e08i5osB;eGi09y;at,ct;iIlHrG;ea1;a2i05;de;ma4n9re,te;a0Ae09h06i7l04oJrG;aHeGoAuFy;a7dB;ck,ve;llZmSnHok,py,uGv0;gh,nt;cePdu5fMsKtIvG;eGin9;rt,y;aEin0SrG;a8ibu7ol;iGtitu7;d0st;iHoGroC;rm;gu2rm;rn;biLfoKmaJpG;a2laE;in;re;nd;rt;ne;ap1e5;aGip,o1;im,w;aHeG;at,ck,w;llen4n4r4se;a1nt0;ll,ncIrGt0u1;eGry;!en;el;aPeMloLoJruFuG;lGry;ly;sh;a8mb,o8rrGth0un9;ow;ck;ar,lHnefBtrG;ay;ie3ong;ng,se;band0Jc0Bd06ffo05gr04id,l01mu1nYppTrQsKttGvoid,waB;acIeHra5;ct;m0Fnd;h,k;k,sG;eIiHocia7uG;me;gn,st;mb6rt;le;chHgGri3;ue;!i3;eaJlIroG;aDve;ch;aud,y;l,r;noun9sw0tG;icipa7;ce;lHt0;er;e4ow;ee;rd;aRdIju8mBoR;it;st;!reA;ss;cJhie3knowled4tiva7;te;ge;ve;eIouCu1;se;nt;pt;on",Unit:"true¦0:19;a14b12c0Od0Ne0Lf0Gg0Ch09in0Hjoule0k02l00mNnMoLpIqHsqCt7volts,w6y4z3°2µ1;g,s;c,f,n;b,e2;a0Nb,d0Dears old,o1;tt0H;att0b;able4b3d,e2on1sp;!ne0;a2r0D;!l,sp;spo04; ft,uare 1;c0Id0Hf3i0Fkilo0Jm1ya0E;e0Mil1;e0li0H;eet0o0D;t,uart0;ascals,e2i1ou0Pt;c0Mnt0;rcent,t02;hms,uYz;an0JewtT;/s,b,e9g,i3l,m2p1²,³;h,s;!²;!/h,cro5l1;e1li08;! pFs1²;! 1;anEpD;g06s0B;gQter1;! 2s1;! 1;per second;b,i00m,u1x;men0x0;b,elvin0g,ilo2m1nR;!/h,ph,²;byZgXmeter1;! p2s1;! p1;er1; hour;e1g,r0z;ct1rtz0;aXogQ;al2b,igAra1;in0m0;!l1;on0;a4emtPl2t1;²,³; oz,uid ou1;nce0;hrenheit0rad0;b,x1;abyH;eciCg,l,mA;arat0eAg,m9oulomb0u1;bic 1p0;c5d4fo3i2meAya1;rd0;nch0;ot0;eci2;enti1;me4;!²,³;lsius0nti1;g2li1me1;ter0;ram0;bl,y1;te0;c4tt1;os1;eco1;nd0;re0;!s",Organization:"true¦0:46;a3Ab2Qc2Ad21e1Xf1Tg1Lh1Gi1Dj19k17l13m0Sn0Go0Dp07qu06rZsStFuBv8w3y1;amaha,m0Xou1w0X;gov,tu2S;a3e1orld trade organizati41;lls fargo,st1;fie22inghou16;l1rner br3D;-m11gree31l street journ25m11;an halNeriz3Wisa,o1;dafo2Gl1;kswagLvo;bs,kip,n2ps,s1;a tod2Rps;es35i1;lev2Xted natio2Uv; mobi2Kaco bePd bMeAgi frida9h3im horto2Tmz,o1witt2W;shiba,y1;ota,s r Y;e 1in lizzy;b3carpen33daily ma2Xguess w2holli0rolling st1Ms1w2;mashing pumpki2Ouprem0;ho;ea1lack eyed pe3Fyrds;ch bo1tl0;ys;l2s1;co,la m12;efoni07us;a6e4ieme2Gnp,o2pice gir5ta1ubaru;rbucks,to2N;ny,undgard1;en;a2Rx pisto1;ls;few25insbu26msu1X;.e.m.,adiohead,b6e3oyal 1yan2X;b1dutch she4;ank;/max,aders dige1Ed 1vl32;bu1c1Uhot chili peppe2Klobst28;ll;c,s;ant2Vizno2F;an5bs,e3fiz24hilip morrBi2r1;emier27octer & gamb1Rudenti14;nk floyd,zza hut;psi28tro1uge08;br2Qchina,n2Q; 2ason1Xda2G;ld navy,pec,range juli2xf1;am;us;a9b8e5fl,h4i3o1sa,wa;kia,tre dame,vart1;is;ke,ntendo,ss0K;l,s;c,st1Etflix,w1; 1sweek;kids on the block,york08;a,c;nd1Us2t1;ional aca2Fo,we0Q;a,cYd0O;aAcdonald9e5i3lb,o1tv,yspace;b1Nnsanto,ody blu0t1;ley crue,or0O;crosoft,t1;as,subisO;dica3rcedes2talli1;ca;!-benz;id,re;'s,s;c's milk,tt13z1Y;'ore09a3e1g,ittle caesa1Ktd;novo,x1;is,mark; pres5-z-boy,bour party;atv,fc,kk,m1od1K;art;iffy lu0Lo3pmorgan1sa;! cha1;se;hnson & johns1Sy d1R;bm,hop,n1tv;c,g,te1;l,rpol; & m,asbro,ewlett-packaTi3o1sbc,yundai;me dep1n1J;ot;tac1zbollah;hi;eneral 6hq,l5mb,o2reen d0Iu1;cci,ns n ros0;ldman sachs,o1;dye1g0B;ar;axo smith kliZencore;electr0Im1;oto0V;a3bi,da,edex,i1leetwood mac,oGrito-l0A;at,nancial1restoV; tim0;cebook,nnie mae;b06sa,u3xxon1; m1m1;ob0H;!rosceptics;aiml0Ae5isney,o3u1;nkin donuts,po0Wran dur1;an;j,w j1;on0;a,f leppa3ll,p2r spiegZstiny's chi1;ld;eche mode,t;rd;aEbc,hBi9nn,o3r1;aigsli5eedence clearwater reviv1ossra05;al;!ca c5l4m1o0Ast05;ca2p1;aq;st;dplMgate;ola;a,sco1tigroup;! systems;ev2i1;ck fil-a,na daily;r0Hy;dbury,pital o1rl's jr;ne;aGbc,eCfAl6mw,ni,o2p,r1;exiteeWos;ei3mbardiJston 1;glo1pizza;be;ng;ack & deckFo2ue c1;roX;ckbuster video,omingda1;le; g1g1;oodriN;cht3e ge0n & jer2rkshire hathaw1;ay;ryH;el;nana republ3s1xt5y5;f,kin robbi1;ns;ic;bXcSdidRerosmith,ig,lLmFnheuser-busEol,ppleAr7s3t&t,v2y1;er;is,on;hland2s1;n,ociated F; o1;il;by4g2m1;co;os; compu2bee1;'s;te1;rs;ch;c,d,erican3t1;!r1;ak; ex1;pre1;ss; 4catel2t1;air;!-luce1;nt;jazeera,qae1;da;as;/dc,a3er,t1;ivisi1;on;demy of scienc0;es;ba,c",Demonym:"true¦0:16;1:13;a0Wb0Nc0Cd0Ae09f07g04h02iYjVkTlPmLnIomHpDqatari,rBs7t5u4v3wel0Rz2;am0Fimbabwe0;enezuel0ietnam0H;g9krai1;aiwThai,rinida0Iu2;ni0Qrkmen;a4cot0Ke3ingapoOlovak,oma0Tpa05udRw2y0X;edi0Kiss;negal0Br08;mo0uU;o6us0Lw2;and0;a3eru0Hhilipp0Po2;li0Ertugu06;kist3lesti1na2raguay0;ma1;ani;amiZi2orweP;caragu0geri2;an,en;a3ex0Mo2;ngo0Erocc0;cedo1la2;gasy,y08;a4eb9i2;b2thua1;e0Dy0;o,t02;azakh,eny0o2uwaiti;re0;a2orda1;ma0Bp2;anN;celandic,nd4r2sraeli,ta02vo06;a2iT;ni0qi;i0oneV;aiDin2ondur0unN;di;amDe2hanai0reek,uatemal0;or2rm0;gi0;i2ren7;lipino,n4;cuadoVgyp6ngliJsto1thiopi0urope0;a2ominXut4;niH;a9h6o4roa3ub0ze2;ch;ti0;lom2ngol5;bi0;a6i2;le0n2;ese;lifor1m2na3;bo2eroo1;di0;angladeshi,el8o6r3ul2;gaG;aziBi2;ti2;sh;li2s1;vi0;aru2gi0;si0;fAl7merBngol0r5si0us2;sie,tr2;a2i0;li0;gent2me1;ine;ba1ge2;ri0;ni0;gh0r2;ic0;an",Possessive:"true¦anyAh5its,m3noCo1sometBthe0yo1;ir1mselves;ur0;!s;i8y0;!se4;er1i0;mse2s;!s0;!e0;lf;o1t0;hing;ne",Currency:"true¦$,aud,bScQdLeurKfJgbp,hkd,iIjpy,kGlEp8r7s3usd,x2y1z0¢,£,¥,ден,лв,руб,฿,₡,₨,€,₭,﷼;lotySł;en,uanR;af,of;h0t5;e0il5;k0q0;elM;iel,oubleLp,upeeL;e2ound st0;er0;lingI;n0soH;ceGn0;ies,y;e0i8;i,mpi7;n,r0wanzaCyatC;!onaBw;ls,nr;ori7ranc9;!o8;en3i2kk,o0;b0ll2;ra5;me4n0rham4;ar3;ad,e0ny;nt1;aht,itcoin0;!s",City:"true¦a2Wb26c1Wd1Re1Qf1Og1Ih1Ai18jakar2Hk0Zl0Tm0Gn0Co0ApZquiYrVsLtCuBv8w3y1z0;agreb,uri1Z;ang1Te0okohama;katerin1Hrev34;ars3e2i0rocl3;ckl0Vn0;nipeg,terth0W;llingt1Oxford;aw;a1i0;en2Hlni2Z;lenc2Uncouv0Gr2G;lan bat0Dtrecht;a6bilisi,e5he4i3o2rondheim,u0;nVr0;in,ku;kyo,ronIulouC;anj23l13miso2Jra2A; haJssaloni0X;gucigalpa,hr2Ol av0L;i0llinn,mpe2Bngi07rtu;chu22n2MpT;a3e2h1kopje,t0ydney;ockholm,uttga12;angh1Fenzh1X;o0KvZ;int peters0Ul3n0ppo1F; 0ti1B;jo0salv2;se;v0z0Q;adU;eykjavik,i1o0;me,sario,t25;ga,o de janei17;to;a8e6h5i4o2r0ueb1Qyongya1N;a0etor24;gue;rt0zn24; elizabe3o;ls1Grae24;iladelph1Znom pe07oenix;r0tah tik19;th;lerJr0tr10;is;dessa,s0ttawa;a1Hlo;a2ew 0is;delTtaip0york;ei;goya,nt0Upl0Uv1R;a5e4i3o1u0;mb0Lni0I;nt0scH;evideo,real;l1Mn01skolc;dellín,lbour0S;drid,l5n3r0;ib1se0;ille;or;chest0dalWi0Z;er;mo;a4i1o0vAy01;nd00s angel0F;ege,ma0nz,sbZverpo1;!ss0;ol; pla0Iusan0F;a5hark4i3laipeda,o1rak0uala lump2;ow;be,pavog0sice;ur;ev,ng8;iv;b3mpa0Kndy,ohsiu0Hra0un03;c0j;hi;ncheMstanb0̇zmir;ul;a5e3o0; chi mi1ms,u0;stI;nh;lsin0rakliG;ki;ifa,m0noi,va0A;bu0SiltD;alw4dan3en2hent,iza,othen1raz,ua0;dalaj0Gngzhou;bu0P;eUoa;sk;ay;es,rankfu0;rt;dmont4indhovU;a1ha01oha,u0;blRrb0Eshanbe;e0kar,masc0FugavpiJ;gu,je0;on;a7ebu,h2o0raioJuriti01;lo0nstanJpenhagNrk;gFmbo;enn3i1ristchur0;ch;ang m1c0ttagoL;ago;ai;i0lgary,pe town,rac4;ro;aHeBirminghWogoAr5u0;char3dap3enos air2r0sZ;g0sa;as;es;est;a2isba1usse0;ls;ne;silPtisla0;va;ta;i3lgrade,r0;g1l0n;in;en;ji0rut;ng;ku,n3r0sel;celo1ranquil0;la;na;g1ja lu0;ka;alo0kok;re;aBb9hmedabad,l7m4n2qa1sh0thens,uckland;dod,gabat;ba;k0twerp;ara;m5s0;terd0;am;exandr0maty;ia;idj0u dhabi;an;lbo1rh0;us;rg",Abbreviation:"true¦a0Tb0Qc0Kd0Ie0Ff0Cg0Ah08i06j04k02l00mRnOoNpIqHrFs9t6u5v2w0yb,µg;is0r,y0L;!c;a,b,e1i0ol,s,t;tro,vo;r,t;niv,safa,t;b1ce,d,e0sp;l,mp,nn,x;!l,sp;ask,e3fc,gt,i2q1r,s,t,u0;pt,rg;! ft;r,tu;c,nVp0;!t;b,d,e0;pSs,v;t,ue;a,d,enn3hd,l,p,r1s0t,vt;!eud;ef,o0;b,f,n;!a;ct,kla,nt,p,rd,z;e0ov;b0e;!r;a7b,d,essrs,g,i4l3m2p1rHs0t;!tr;h,s;!e;!le;!n1s0;c,ter;!n;!j,r,sc;at,b,it,lb,m,ng,t0x;!d;an6b,g,m0;!ph;an,d,r,u0;l,n;a,da,e,n0;c,f;g,on,r0wy,z;!s;a0b,en,ov;!l;e1ig,l0m,r,t,y;! oz,a;b,m;a,g,ng,s1tc,x0;!p;p,q,t;ak,e0g,ist,l,m,r;c,f,pt,t;a3ca,g,l,m2o0pl,res,t,yn;!l0mdr,nn,rp;!o;!dr;!l0pt;!if;a,c,l1r0;ig,os;!dg,vd;d4l3p2r1ss0tty,ug,ve;n,t;c,iz;prox,r,t;!ta;!j,m,v",Country:"true¦0:38;1:2L;a2Wb2Dc21d1Xe1Rf1Lg1Bh19i13j11k0Zl0Um0Gn05om3CpZqat1JrXsKtCu6v4wal3yemTz2;a24imbabwe;es,lis and futu2X;a2enezue31ietnam;nuatu,tican city;.5gTkraiZnited 3ruXs2zbeE;a,sr;arab emirat0Kkingdom,states2;! of am2X;k.,s.2; 27a.;a7haBimor-les0Bo6rinidad4u2;nis0rk2valu;ey,me2Xs and caic1T; and 2-2;toba1J;go,kel0Ynga;iw2Vji2nz2R;ki2T;aCcotl1eBi8lov7o5pa2Bri lanka,u4w2yr0;az2ed9itzerl1;il1;d2Qriname;lomon1Vmal0uth 2;afr2IkLsud2O;ak0en0;erra leoEn2;gapo1Wt maart2;en;negKrb0ychellY;int 2moa,n marino,udi arab0;hele24luc0mart1Z;epublic of ir0Com2Cuss0w2;an25;a3eHhilippinTitcairn1Ko2uerto riM;l1rtugE;ki2Bl3nama,pua new0Tra2;gu6;au,esti2;ne;aAe8i6or2;folk1Gth3w2;ay; k2ern mariana1B;or0M;caragua,ger2ue;!ia;p2ther18w zeal1;al;mib0u2;ru;a6exi5icro09o2yanm04;ldova,n2roc4zamb9;a3gol0t2;enegro,serrat;co;c9dagascZl6r4urit3yot2;te;an0i14;shall0Vtin2;ique;a3div2i,ta;es;wi,ys0;ao,ed00;a5e4i2uxembourg;b2echtenste10thu1E;er0ya;ban0Gsotho;os,tv0;azakh1De2iriba02osovo,uwait,yrgyz1D;eling0Jnya;a2erF;ma15p1B;c6nd5r3s2taly,vory coast;le of m19rael;a2el1;n,q;ia,oI;el1;aiSon2ungary;dur0Mg kong;aAermany,ha0Pibralt9re7u2;a5ern4inea2ya0O;!-biss2;au;sey;deloupe,m,tema0P;e2na0M;ce,nl1;ar;bTmb0;a6i5r2;ance,ench 2;guia0Dpoly2;nes0;ji,nl1;lklandTroeT;ast tim6cu5gypt,l salv5ngl1quatorial3ritr4st2thiop0;on0; guin2;ea;ad2;or;enmark,jibou4ominica3r con2;go;!n B;ti;aAentral african 9h7o4roat0u3yprQzech2; 8ia;ba,racao;c3lo2morPngo-brazzaville,okFsta r03te d'ivoiK;mb0;osD;i2ristmasF;le,na;republic;m2naTpe verde,yman9;bod0ero2;on;aFeChut00o8r4u2;lgar0r2;kina faso,ma,undi;azil,itish 2unei;virgin2; is2;lands;liv0nai4snia and herzegoviGtswaGuvet2; isl1;and;re;l2n7rmuF;ar2gium,ize;us;h3ngladesh,rbad2;os;am3ra2;in;as;fghaFlCmAn5r3ustr2zerbaijH;al0ia;genti2men0uba;na;dorra,g4t2;arct6igua and barbu2;da;o2uil2;la;er2;ica;b2ger0;an0;ia;ni2;st2;an",Region:"true¦0:1U;a20b1Sc1Id1Des1Cf19g13h10i0Xj0Vk0Tl0Qm0FnZoXpSqPrMsDtAut9v6w3y1zacatec22;o05u1;cat18kZ;a1est vi4isconsin,yomi14;rwick0shington1;! dc;er2i1;rgin1S;acruz,mont;ah,tar pradesh;a2e1laxca1DuscaA;nnessee,x1R;bas0Kmaulip1QsmJ;a6i4o2taf0Ou1ylh13;ffVrr00s0Y;me10no1Auth 1;cSdR;ber1Ic1naloa;hu0Sily;n2skatchew0Rxo1;ny; luis potosi,ta catari1I;a1hode7;j1ngp02;asth0Mshahi;inghai,u1;e1intana roo;bec,ensWreta0E;ara4e2rince edward1; isU;i,nnsylv1rnambu02;an14;!na;axa0Ndisha,h1klaho1Bntar1reg4x04;io;ayarit,eBo3u1;evo le1nav0L;on;r1tt0Rva scot0X;f6mandy,th1; 1ampton0;c3d2yo1;rk0;ako0Y;aroli0V;olk;bras0Xva01w1; 2foundland1;! and labrador;brunswick,hamp0jers1mexiJyork state;ey;a6i2o1;nta0Nrelos;ch3dlanBn2ss1;issippi,ouri;as geraGneso0M;igQoacQ;dhya,harasht04ine,ni3r1ssachusetts;anhao,y1;land;p1toba;ur;anca0e1incoln0ouis8;e1iH;ds;a1entucky,hul0A;ns08rnata0Dshmir;alis1iangxi;co;daho,llino2nd1owa;ia05;is;a2ert1idalEunA;ford0;mp0waii;ansu,eorgWlou5u1;an2erre1izhou,jarat;ro;ajuato,gdo1;ng;cester0;lori2uji1;an;da;sex;e4o2uran1;go;rs1;et;lawaErby0;a8ea7hi6o1umbrH;ahui4l3nnectic2rsi1ventry;ca;ut;iMorado;la;apEhuahua;ra;l8m1;bridge0peche;a5r4uck1;ingham0;shi1;re;emen,itish columb3;h2ja cal1sque,var2;iforn1;ia;guascalientes,l4r1;izo2kans1;as;na;a2ber1;ta;ba2s1;ka;ma",FemaleName:"true¦0:FY;1:G2;2:FR;3:FD;4:FC;5:FS;6:ER;7:EP;8:GF;9:EZ;A:GB;B:E5;C:G8;D:FO;E:FL;F:EG;aE2bD4cB8dAIe9Gf91g8Hh83i7Sj6Uk60l4Om38n2To2Qp2Fqu2Er1Os0Qt04ursu6vUwOyLzG;aJeHoG;e,la,ra;lGna;da,ma;da,ra;as7EeHol1TvG;et7onB9;le0sen3;an9endBNhiB4iG;lInG;if3AniGo0;e,f39;a,helmi0lGma;a,ow;aMeJiG;cHviG;an9XenG1;kCZtor3;da,l8Vnus,rG;a,nGoniD2;a,iDC;leGnesEC;nDLrG;i1y;aSePhNiMoJrGu6y4;acG3iGu0E;c3na,sG;h9Mta;nHrG;a,i;i9Jya;a5IffaCGna,s5;al3eGomasi0;a,l8Go6Xres1;g7Uo6WrHssG;!a,ie;eFi,ri8;bNliMmKnIrHs5tGwa0;ia0um;a,yn;iGya;a,ka,s5;a4e4iGmCAra;!ka;a,t5;at5it5;a05carlet2Ye04hUiSkye,oQtMuHyG;bFJlvi1;e,sHzG;an2Tet7ie,y;anGi8;!a,e,nG;aEe;aIeG;fGl3DphG;an2;cF8r6;f3nGphi1;d4ia,ja,ya;er4lv3mon1nGobh75;dy;aKeGirlBLo0y6;ba,e0i6lIrG;iGrBPyl;!d70;ia,lBV;ki4nIrHu0w0yG;la,na;i,leAon,ron;a,da,ia,nGon;a,on;l5Yre0;bMdLi9lKmIndHrGs5vannaE;aEi0;ra,y;aGi4;nt5ra;lBNome;e,ie;in1ri0;a02eXhViToHuG;by,thBK;bQcPlOnNsHwe0xG;an94ie,y;aHeGie,lC;ann8ll1marBFtB;!lGnn1;iGyn;e,nG;a,d7W;da,i,na;an9;hel53io;bin,erByn;a,cGkki,na,ta;helBZki;ea,iannDXoG;da,n12;an0bIgi0i0nGta,y0;aGee;!e,ta;a,eG;cARkaE;chGe,i0mo0n5EquCDvDy0;aCCelGi9;!e,le;een2ia0;aMeLhJoIrG;iGudenAW;scil1Uyamva9;lly,rt3;ilome0oebe,ylG;is,lis;arl,ggy,nelope,r6t4;ige,m0Fn4Oo6rvaBBtHulG;a,et7in1;ricGsy,tA8;a,e,ia;ctav3deHfAWlGphAW;a,ga,iv3;l3t7;aQePiJoGy6;eHrG;aEeDma;ll1mi;aKcIkGla,na,s5ta;iGki;!ta;hoB2k8BolG;a,eBH;!mh;l7Tna,risF;dIi5PnHo23taG;li1s5;cy,et7;eAiCO;a01ckenz2eViLoIrignayani,uriBGyG;a,rG;a,na,tAS;i4ll9XnG;a,iG;ca,ka,qB4;a,chOkaNlJmi,nIrGtzi;aGiam;!n9;a,dy,erva,h,n2;a,dIi9JlG;iGy;cent,e;red;!e6;ae6el3G;ag4KgKi,lHrG;edi61isFyl;an2iGliF;nGsAM;a,da;!an,han;b08c9Ed06e,g04i03l01nZrKtJuHv6Sx87yGz2;a,bell,ra;de,rG;a,eD;h75il9t2;a,cSgOiJjor2l6In2s5tIyG;!aGbe5QjaAlou;m,n9S;a,ha,i0;!aIbALeHja,lCna,sGt53;!a,ol,sa;!l06;!h,m,nG;!a,e,n1;arIeHie,oGr3Kueri7;!t;!ry;et3IiB;elGi61y;a,l1;dGon,ue6;akranBy;iGlo36;a,ka,n9;a,re,s2;daGg2;!l2W;alCd2elGge,isBGon0;eiAin1yn;el,le;a0Ie08iWoQuKyG;d3la,nG;!a,dHe9SnGsAQ;!a,e9R;a,sAO;aB1cJelIiFlHna,pGz;e,iB;a,u;a,la;iGy;a2Ae,l25n9;is,l1GrHtt2uG;el6is1;aIeHi8na,rG;a6Zi8;lei,n1tB;!in1;aQbPd3lLnIsHv3zG;!a,be4Ket7z2;a,et7;a,dG;a,sGy;ay,ey,i,y;a,iaIlG;iGy;a8Ge;!n4F;b7Terty;!n5R;aNda,e0iLla,nKoIslARtGx2;iGt2;c3t3;la,nGra;a,ie,o4;a,or1;a,gh,laG;!ni;!h,nG;a,d4e,n4N;cNdon7Si6kes5na,rMtKurIvHxGy6;mi;ern1in3;a,eGie,yn;l,n;as5is5oG;nya,ya;a,isF;ey,ie,y;aZeUhadija,iMoLrIyG;lGra;a,ee,ie;istGy5B;a,en,iGy;!e,n48;ri,urtn9A;aMerLl99mIrGzzy;a,stG;en,in;!berlG;eGi,y;e,y;a,stD;!na,ra;el6PiJlInHrG;a,i,ri;d4na;ey,i,l9Qs2y;ra,s5;c8Wi5XlOma6nyakumari,rMss5LtJviByG;!e,lG;a,eG;e,i78;a5EeHhGi3PlCri0y;ar5Cer5Cie,leDr9Fy;!lyn73;a,en,iGl4Uyn;!ma,n31sF;ei72i,l2;a04eVilToMuG;anKdJliGst56;aHeGsF;!nAt0W;!n8X;i2Ry;a,iB;!anLcelCd5Vel71han6IlJni,sHva0yG;a,ce;eGie;fi0lCph4X;eGie;en,n1;!a,e,n36;!i10lG;!i0Z;anLle0nIrHsG;i5Qsi5Q;i,ri;!a,el6Pif1RnG;a,et7iGy;!e,f1P;a,e72iHnG;a,e71iG;e,n1;cLd1mi,nHqueliAsmin2Uvie4yAzG;min8;a8eHiG;ce,e,n1s;!lGsFt06;e,le;inHk2lCquelG;in1yn;da,ta;lPmNnMo0rLsHvaG;!na;aHiGob6U;do4;!belGdo4;!a,e,l2G;en1i0ma;a,di4es,gr5R;el9ogG;en1;a,eAia0o0se;aNeKilHoGyacin1N;ll2rten1H;aHdGlaH;a,egard;ry;ath0WiHlGnrietBrmiAst0W;en24ga;di;il75lKnJrGtt2yl75z6D;iGmo4Fri4G;etG;!te;aEnaE;ey,l2;aYeTiOlMold12rIwG;enGyne18;!dolC;acHetGisel9;a,chD;e,ieG;!la;adys,enGor3yn1Y;a,da,na;aJgi,lHna,ov71selG;a,e,le;da,liG;an;!n0;mYnIorgHrG;ald35i,m2Stru73;et7i5T;a,eGna;s1Nvieve;briel3Fil,le,rnet,yle;aReOio0loMrG;anHe9iG;da,e9;!cG;esHiGoi0G;n1s3V;!ca;!rG;a,en43;lHrnG;!an9;ec3ic3;rHtiGy8;ma;ah,rah;d0FileDkBl00mUn4ArRsMtLuKvG;aIelHiG;e,ta;in0Ayn;!ngel2H;geni1la,ni3R;h52ta;meral9peranJtG;eHhGrel6;er;l2Pr;za;iGma,nest29yn;cGka,n;a,ka;eJilImG;aGie,y;!liA;ee,i1y;lGrald;da,y;aTeRiMlLma,no4oJsIvG;a,iG;na,ra;a,ie;iGuiG;se;a,en,ie,y;a0c3da,nJsGzaH;aGe;!beG;th;!a,or;anor,nG;!a;in1na;en,iGna,wi0;e,th;aWeKiJoGul2U;lor51miniq3Yn30rGtt2;a,eDis,la,othGthy;ea,y;an09naEonAx2;anPbOde,eNiLja,lImetr3nGsir4U;a,iG;ce,se;a,iHla,orGphiA;es,is;a,l5J;dGrdG;re;!d4Mna;!b2CoraEra;a,d4nG;!a,e;hl3i0mMnKphn1rHvi1WyG;le,na;a,by,cHia,lG;a,en1;ey,ie;a,et7iG;!ca,el1Aka;arGia;is;a0Qe0Mh04i02lUoJrHynG;di,th3;istGy04;al,i0;lOnLrHurG;tn1D;aId28iGn28riA;!nG;a,e,n1;!l1S;n2sG;tanGuelo;ce,za;eGleD;en,t7;aIeoHotG;il4B;!pat4;ir8rIudG;et7iG;a,ne;a,e,iG;ce,sX;a4er4ndG;i,y;aPeMloe,rG;isHyG;stal;sy,tG;aHen,iGy;!an1e,n1;!l;lseHrG;!i8yl;a,y;nLrG;isJlHmG;aiA;a,eGot7;n1t7;!sa;d4el1PtG;al,el1O;cHlG;es7i3F;el3ilG;e,ia,y;iYlXmilWndVrNsLtGy6;aJeIhGri0;erGleDrCy;in1;ri0;li0ri0;a2GsG;a2Fie;a,iMlKmeIolHrG;ie,ol;!e,in1yn;lGn;!a,la;a,eGie,y;ne,y;na,sF;a0Di0D;a,e,l1;isBl2;tlG;in,yn;arb0CeYianXlVoTrG;andRePiIoHyG;an0nn;nwCok8;an2NdgKg0ItG;n27tG;!aHnG;ey,i,y;ny;etG;!t8;an0e,nG;da,na;i8y;bbi8nG;iBn2;ancGossom,ythe;a,he;ca;aRcky,lin9niBrNssMtIulaEvG;!erlG;ey,y;hHsy,tG;e,i0Zy8;!anG;ie,y;!ie;nGt5yl;adHiG;ce;et7iA;!triG;ce,z;a4ie,ra;aliy29b24d1Lg1Hi19l0Sm0Nn01rWsNthe0uJvIyG;anGes5;a,na;a,r25;drIgusHrG;el3;ti0;a,ey,i,y;hHtrG;id;aKlGt1P;eHi8yG;!n;e,iGy;gh;!nG;ti;iIleHpiB;ta;en,n1t7;an19elG;le;aYdWeUgQiOja,nHtoGya;inet7n3;!aJeHiGmI;e,ka;!mGt7;ar2;!belHliFmT;sa;!le;ka,sGta;a,sa;elGie;a,iG;a,ca,n1qG;ue;!t7;te;je6rea;la;!bHmGstas3;ar3;el;aIberHel3iGy;e,na;!ly;l3n9;da;aTba,eNiKlIma,yG;a,c3sG;a,on,sa;iGys0J;e,s0I;a,cHna,sGza;a,ha,on,sa;e,ia;c3is5jaIna,ssaIxG;aGia;!nd4;nd4;ra;ia;i0nHyG;ah,na;a,is,naE;c5da,leDmLnslKsG;haElG;inGyW;g,n;!h;ey;ee;en;at5g2nG;es;ie;ha;aVdiSelLrG;eIiG;anLenG;a,e,ne;an0;na;aKeJiHyG;nn;a,n1;a,e;!ne;!iG;de;e,lCsG;on;yn;!lG;iAyn;ne;agaJbHiG;!gaI;ey,i8y;!e;il;ah",Place:"true¦a07b05cZdYeXfVgRhQiOjfk,kMlKmHneEoDp9que,rd,s8t5u4v3w0yyz;is1y0;!o;!c;a,t;pYsafa,t;e1he 0;bronx,hamptons;nn,x;ask,fo,oho,t,under6yd;a2e1h0;l,x;k,nnK;!cifX;kla,nt;b1w eng0;land;!r;a1co,i0t,uc;dKnn;libu,nhattS;a0gw,hr;s,x;an0ul;!s;a0cn,da,ndianMst;!x;arlem,kg,nd,wy;a2re0;at 0enwich;britain,lak6;!y village;co,l0ra;!a;urope,verglad2;ak,en,fw,ist,own4xb;al4dg,gk,hina3l2o1r0t;es;lo,nn;!t;town;!if;cn,e0kk,lvd,rooklyn;l air,verly hills;frica,lta,m5ntarct2r1sia,tl0ve;!ant1;ct0iz;ic0; oce0;an;ericas,s",WeekDay:"true¦fri2mon2s1t0wednesd3;hurs1ues1;aturd1und1;!d0;ay0;!s",Month:"true¦aBdec9feb7j2mar,nov9oct1sep0;!t8;!o8;an3u0;l1n0;!e;!y;!u1;!ru0;ary;!em0;ber;pr1ug0;!ust;!il",Date:"true¦ago,t0weekend,yesterd2;mr2o0;d0morrow;ay;!w",FirstName:"true¦aEblair,cCdevBj8k6lashawn,m3nelly,quinn,re2sh0;ay,e0iloh;a,lby;g1ne;ar1el,org0;an;ion,lo;as8e0r9;ls7nyatta,rry;am0ess1ude;ie,m0;ie;an,on;as0heyenne;ey,sidy;lex1ndra,ubr0;ey;is",LastName:"true¦0:34;1:3B;2:39;3:2Y;4:2E;5:30;a3Bb31c2Od2Ee2Bf25g1Zh1Pi1Kj1Ek17l0Zm0Nn0Jo0Gp05rYsMtHvFwCxBy8zh6;a6ou,u;ng,o;a6eun2Uoshi1Kun;ma6ng;da,guc1Zmo27sh21zaR;iao,u;a7eb0il6o3right,u;li3Bs2;gn0lk0ng,tanabe;a6ivaldi;ssilj37zqu1;a9h8i2Go7r6sui,urn0;an,ynisJ;lst0Prr1Uth;at1Uomps2;kah0Vnaka,ylor;aEchDeChimizu,iBmiAo9t7u6zabo;ar1lliv2AzuE;a6ein0;l23rm0;sa,u3;rn4th;lva,mmo24ngh;mjon4rrano;midt,neid0ulz;ito,n7sa6to;ki;ch1dLtos,z;amBeag1Zi9o7u6;bio,iz,sD;b6dri1MgIj0Tme24osevelt,ssi,ux;erts,ins2;c6ve0F;ci,hards2;ir1os;aEeAh8ic6ow20ut1N;as6hl0;so;a6illips;m,n1T;ders5et8r7t6;e0Nr4;ez,ry;ers;h21rk0t6vl4;el,te0J;baBg0Blivei01r6;t6w1O;ega,iz;a6eils2guy5ix2owak,ym1E;gy,ka6var1K;ji6muW;ma;aEeCiBo8u6;ll0n6rr0Bssolini,ñ6;oz;lina,oKr6zart;al0Me6r0U;au,no;hhail4ll0;rci0ssi6y0;!er;eWmmad4r6tsu07;in6tin1;!o;aCe8i6op1uo;!n6u;coln,dholm;fe7n0Qr6w0J;oy;bv6v6;re;mmy,rs5u;aBennedy,imuAle0Lo8u7wo6;k,n;mar,znets4;bay6vacs;asY;ra;hn,rl9to,ur,zl4;aAen9ha3imen1o6u3;h6nYu3;an6ns2;ss2;ki0Es5;cks2nsse0D;glesi9ke8noue,shik7to,vano6;u,v;awa;da;as;aBe8itchcock,o7u6;!a3b0ghNynh;a3ffmann,rvat;mingw7nde6rN;rs2;ay;ns5rrQs7y6;asDes;an4hi6;moJ;a9il,o8r7u6;o,tierr1;ayli3ub0;m1nzal1;nd6o,rcia;hi;erAis9lor8o7uj6;ita;st0urni0;es;ch0;nand1;d7insteHsposi6vaL;to;is2wards;aCeBi9omin8u6;bo6rand;is;gu1;az,mitr4;ov;lgado,vi;nkula,rw7vi6;es,s;in;aFhBlarkAo6;h5l6op0rbyn,x;em7li6;ns;an;!e;an8e7iu,o6ristens5u3we;i,ng,u3w,y;!n,on6u3;!g;mpb7rt0st6;ro;ell;aBe8ha3lanco,oyko,r6yrne;ooks,yant;ng;ck7ethov5nnett;en;er,ham;ch,h8iley,rn6;es,i0;er;k,ng;dDl9nd6;ers6rA;en,on,s2;on;eks7iy8var1;ez;ej6;ev;ams",MaleName:"true¦0:CE;1:BL;2:C2;3:BT;4:B5;5:BZ;6:AT;7:9V;8:BD;9:AX;A:AO;aB4bA8c97d87e7Gf6Yg6Gh5Wi5Ij4Lk4Bl3Rm2Pn2Eo28p22qu20r1As0Qt06u05v00wNxavi3yGzB;aBor0;cBh8Ine;hCkB;!aB1;ar51eB0;ass2i,oCuB;sDu25;nEsDusB;oBsC;uf;ef;at0g;aJeHiCoByaAP;lfgang,odrow;lBn1O;bDey,frBJlB;aA5iB;am,e,s;e89ur;i,nde7sB;!l6t1;de,lCrr5yB;l1ne;lBt3;a93y;aEern1iBladimir;cCha0kt5CnceBrg9Bva0;!nt;ente,t5A;lentin49n8Yughn;lyss4Msm0;aTeOhKiIoErCyB;!l3ro8s1;av9QeBist0oy,um0;nt9Iv54y;bDd7XmBny;!as,mBoharu;aAYie,y;i83y;mBt9;!my,othy;adDeoCia7DomB;!as;!do7M;!de9;dErB;en8HrB;an8GeBy;ll,n8F;!dy;dgh,ic9Tnn3req,ts45;aRcotPeNhJiHoFpenc3tBur1Oylve8Hzym1;anDeBua7B;f0phAFvBwa7A;e57ie;!islaw,l6;lom1nA3uB;leyma8ta;dBl7Jm1;!n6;aDeB;lBrm0;d1t1;h6Sne,qu0Uun,wn,y8;aBbasti0k1Xl41rg40th,ymo9I;m9n;!tB;!ie,y;lCmBnti21q4Iul;!mAu4;ik,vato6V;aWeShe92iOoFuCyB;an,ou;b6LdCf9pe6QssB;!elAI;ol2Uy;an,bIcHdGel,geFh0landA9mEnDry,sCyB;!ce;coe,s;!a95nA;an,eo;l3Jr;e4Qg3n6olfo,ri68;co,ky;bAe9U;cBl6;ar5Oc5NhCkBo;!ey,ie,y;a85ie;gCid,ub5x,yBza;ansh,nS;g8WiB;na8Ss;ch5Yfa4lDmCndBpha4sh6Uul,ymo70;al9Yol2By;i9Ion;f,ph;ent2inB;cy,t1;aFeDhilCier62ol,reB;st1;!ip,lip;d9Brcy,tB;ar,e2V;b3Sdra6Ft44ul;ctav2Vliv3m96rFsCtBum8Uw5;is,to;aCc8SvB;al52;ma;i,l49vJ;athJeHiDoB;aBel,l0ma0r2X;h,m;cCg4i3IkB;h6Uola;hol5XkBol5X;!ol5W;al,d,il,ls1vB;il50;anBy;!a4i4;aWeTiKoFuCyB;l21r1;hamCr5ZstaB;fa,p4G;ed,mF;dibo,e,hamDis1XntCsBussa;es,he;e,y;ad,ed,mB;ad,ed;cGgu4kElDnCtchB;!e7;a78ik;house,o03t1;e,olB;aj;ah,hBk6;a4eB;al,l;hClv2rB;le,ri7v2;di,met;ck,hNlLmOnu4rHs1tDuricCxB;!imilian8Cwe7;e,io;eo,hCi52tB;!eo,hew,ia;eBis;us,w;cDio,k86lCqu6Gsha7tBv2;i2Hy;in,on;!el,oKus;achBcolm,ik;ai,y;amBdi,moud;adB;ou;aReNiMlo2RoIuCyB;le,nd1;cEiDkBth3;aBe;!s;gi,s;as,iaB;no;g0nn6RrenDuBwe7;!iB;e,s;!zo;am,on4;a7Bevi,la4SnDoBst3vi;!nB;!a60el;!ny;mCnBr67ur4Twr4T;ce,d1;ar,o4N;aIeDhaled,iBrist4Vu48y3B;er0p,rB;by,k,ollos;en0iEnBrmit,v2;!dCnBt5C;e0Yy;a7ri4N;r,th;na68rBthem;im,l;aYeQiOoDuB;an,liBst2;an,o,us;aqu2eJhnInGrEsB;eChBi7Bue;!ua;!ph;dBge;an,i,on;!aBny;h,s,th4X;!ath4Wie,nA;!l,sBy;ph;an,e,mB;!mA;d,ffGrDsB;sBus;!e;a5JemCmai8oBry;me,ni0O;i6Uy;!e58rB;ey,y;cHd5kGmFrDsCvi3yB;!d5s1;on,p3;ed,od,rBv4M;e4Zod;al,es,is1;e,ob,ub;k,ob,quB;es;aNbrahMchika,gKkeJlija,nuIrGsDtBv0;ai,sB;uki;aBha0i6Fma4sac;ac,iaB;h,s;a,vinBw2;!g;k,nngu52;!r;nacBor;io;im;in,n;aJeFina4VoDuByd56;be25gBmber4CsD;h,o;m3ra33sBwa3X;se2;aDctCitCn4ErB;be20m0;or;th;bKlJmza,nIo,rDsCyB;a43d5;an,s0;lEo4FrDuBv6;hi40ki,tB;a,o;is1y;an,ey;k,s;!im;ib;aQeMiLlenKoIrEuB;illerCsB;!tavo;mo;aDegBov3;!g,orB;io,y;dy,h57nt;nzaBrd1;lo;!n;lbe4Qno,ovan4R;ne,oDrB;aBry;ld,rd4U;ffr6rge;bri4l5rBv2;la1Zr3Eth,y;aReNiLlJorr0IrB;anDedBitz;!dAeBri24;ri23;cDkB;!ie,lB;in,yn;esJisB;!co,zek;etch3oB;yd;d4lBonn;ip;deriDliCng,rnB;an01;pe,x;co;bi0di;arZdUfrTit0lNmGnFo2rCsteb0th0uge8vBym5zra;an,ere2V;gi,iCnBrol,v2w2;est45ie;c07k;och,rique,zo;aGerFiCmB;aFe2P;lCrB;!h0;!io;s1y;nu4;be09d1iEliDmCt1viBwood;n,s;er,o;ot1Ts;!as,j43sB;ha;a2en;!dAg32mEuCwB;a25in;arB;do;o0Su0S;l,nB;est;aYeOiLoErDuCwByl0;ay8ight;a8dl6nc0st2;ag0ew;minFnDri0ugCyB;le;!l03;!a29nBov0;e7ie,y;go,icB;!k;armuCeBll1on,rk;go;id;anIj0lbeHmetri9nFon,rEsDvCwBxt3;ay8ey;en,in;hawn,mo08;ek,ri0F;is,nBv3;is,y;rt;!dB;re;lKmInHrDvB;e,iB;!d;en,iDne7rByl;eBin,yl;l2Vn;n,o,us;!e,i4ny;iBon;an,en,on;e,lB;as;a06e04hWiar0lLoGrEuCyrB;il,us;rtB;!is;aBistobal;ig;dy,lEnCrB;ey,neli9y;or,rB;ad;by,e,in,l2t1;aGeDiByI;fBnt;fo0Ct1;meCt9velaB;nd;nt;rDuCyB;!t1;de;enB;ce;aFeErisCuB;ck;!tB;i0oph3;st3;d,rlBs;eBie;s,y;cBdric,s11;il;lEmer1rB;ey,lCro7y;ll;!os,t1;eb,v2;ar02eUilTlaSoPrCuByr1;ddy,rtI;aJeEiDuCyB;an,ce,on;ce,no;an,ce;nCtB;!t;dCtB;!on;an,on;dCndB;en,on;!foBl6y;rd;bCrByd;is;!by;i8ke;al,lA;nFrBshoi;at,nCtB;!r10;aBie;rd0S;!edict,iCjam2nA;ie,y;to;n6rBt;eBy;tt;ey;ar0Xb0Nd0Jgust2hm0Gid5ja0ElZmXnPputsiOrFsaEuCveBya0ziz;ry;gust9st2;us;hi;aIchHi4jun,maFnDon,tBy0;hBu06;ur;av,oB;ld;an,nd0A;el;ie;ta;aq;dGgel05tB;hoEoB;i8nB;!i02y;ne;ny;reBy;!as,s,w;ir,mBos;ar;an,beOd5eIfFi,lEonDphonHt1vB;aMin;on;so,zo;an,en;onCrB;edP;so;c,jaEksandDssaExB;!and3;er;ar,er;ndB;ro;rtH;ni;en;ad,eB;d,t;in;aColfBri0vik;!o;mBn;!a;dFeEraCuB;!bakr,lfazl;hBm;am;!l;allEel,oulaye,ulB;!lCrahm0;an;ah,o;ah;av,on",Person:"true¦ashton kutchSbRcMdKeIgastNhGinez,jEkDleCmBnettJoAp8r4s3t2v0;a0irgin maG;lentino rossi,n go3;heresa may,iger woods,yra banks;addam hussain,carlett johanssJlobodan milosevic,uB;ay romano,eese witherspoIo1ush limbau0;gh;d stewart,nald0;inho,o;a0ipJ;lmIris hiltD;prah winfrFra;essiaen,itt romnEubarek;bron james,e;anye west,iefer sutherland,obe bryant;aime,effers8k rowli0;ng;alle ber0itlBulk hogan;ry;ff0meril lagasse,zekiel;ie;a0enzel washingt2ick wolf;lt1nte;ar1lint0ruz;on;dinal wols1son0;! palm2;ey;arack obama,rock;er",Verb:"true¦awak9born,cannot,fr8g7h5k3le2m1s0wors9;e8h3;ake sure,sg;ngth6ss6;eep tabs,n0;own;as0e2;!t2;iv1onna;ight0;en",PhrasalVerb:"true¦0:72;1:6Q;2:7E;3:74;4:6J;5:7H;6:76;7:6P;8:6C;9:6D;A:5I;B:71;C:70;a7Hb63c5Dd5Ae58f46g3Oh38iron0j34k2Zl2Km2Bn29o27p1Pr1Es09tQuOvacuum 1wGyammerCzD;eroAip EonD;e0k0;by,up;aJeGhFiEorDrit53;d 1k2R;mp0n4Ape0r8s8;eel Bip 7L;aEiD;gh 06rd0;n Br 3D;it 5Kk8lk6rm 0Qsh 74t67v4P;rgeCsD;e 9herA;aRePhNiJoHrFuDype 0N;ckArn D;d2in,o3Gup;ade YiDot0y 28;ckle68p 7A;ne67p Ds4D;d2o6Lup;ck FdEe Dgh5Tme0p o0Dre0;aw3ba4d2in,up;e5Ky 1;by,o6V;ink Drow 5V;ba4ov7up;aDe 4Ill4O;m 1r W;ckCke Elk D;ov7u4O;aDba4d2in,o31up;ba4ft7p4Tw3;a0Gc0Fe09h05i02lYmXnWoVpSquare RtJuHwD;earFiD;ngEtch D;aw3ba4o6P; by;ck Dit 1m 1ss0;in,up;aIe0RiHoFrD;aigh1MiD;ke 5Yn2Y;p Drm1P;by,in,o6B;n2Zr 1tc3I;c2Ymp0nd Dr6Hve6y 1;ba4d2up;d2o67up;ar2Vell0ill4UlErDurC;ingCuc8;a33it 3U;be4Crt0;ap 4Eow B;ash 4Zoke0;eep EiDow 9;c3Np 1;in,oD;ff,v7;gn Eng2Zt Dz8;d2o5up;in,o5up;aFoDu4F;ot Dut0w 5X;aw3ba4f37o5R;c2FdeAk4Sve6;e Hll0nd GtD; Dtl43;d2in,o5upD;!on;aw3ba4d2in,o1Yup;o5to;al4Lout0rap4L;il6v8;at0eKiJoGuD;b 4Ele0n Dstl8;aDba4d2in53o3Gt30u3E;c1Xw3;ot EuD;g2Knd6;a1Xf2Ro5;ng 4Op6;aDel6inAnt0;c4Yd D;o2Tu0C;aQePiOlMoKrHsyc2AuD;ll Ft D;aDba4d2in,o1Ht34up;p39w3;ap38d2in,o5t32up;attleCess EiGoD;p 1;ah1Hon;iDp 53re3Mur45wer 53;nt0;ay3ZuD;gAmp 9;ck 53g0leCn 9p3W;el 47ncilA;c3Pir 2In0ss FtEy D;ba4o4R; d2c1Y;aw3ba4o12;pDw3K;e3Jt B;arrow3Terd0oD;d6te3S;aJeHiGoEuD;ddl8ll37;c17p 1uth6ve D;al3Bd2in,o5up;ss0x 1;asur8lt 9ss D;a1Aup;ke Dn 9r30s1Lx0;do,o3Yup;aPeNiIoDuck0;a17c37g GoDse0;k Dse35;aft7ba4d2forw2Bin3Wov7uD;nd7p;in,o0J;e GghtFnEsDv1T;ten 4D;e 1k 1; 1e2Y;ar43d2;av1Ht 2YvelD; o3L;p 1sh DtchCugh6y1U;in3Lo5;eEick6nock D;d2o3H;eDyA;l2Hp D;aw3ba4d2fSin,o05to,up;aFoEuD;ic8mpA;ke2St2W;c31zz 1;aPeKiHoEuD;nker2Ts0U;lDneArse2O;d De 1;ba4d2fast,oZup;de Et D;ba4on,up;aw3o5;aDlp0;d Fl22r Dt 1;fDof;rom;in,oRu1A;cZm 1nDve it,ze1Y;d Dg 27kerF;d2in,o5;aReLive Jloss1VoFrEunD; f0M;in39ow 23; Dof 0U;aEb17it,oDr35t0Ou12;ff,n,v7;bo5ft7hJw3;aw3ba4d2in,oDup,w3;ff,n,ut;a17ek0t D;aEb11d2oDr2Zup;ff,n,ut,v7;cEhDl1Pr2Xt,w3;ead;ross;d aEnD;g 1;bo5;a08e01iRlNoJrFuD;cDel 1;k 1;eEighten DownCy 1;aw3o2L;eDshe1G; 1z8;lFol D;aDwi19;bo5r2I;d 9;aEeDip0;sh0;g 9ke0mDrD;e 2K;gLlJnHrFsEzzD;le0;h 2H;e Dm 1;aw3ba4up;d0isD;h 1;e Dl 11;aw3fI;ht ba4ure0;eInEsD;s 1;cFd D;fDo1X;or;e B;dQl 1;cHll Drm0t0O;apYbFd2in,oEtD;hrough;ff,ut,v7;a4ehi1S;e E;at0dge0nd Dy8;o1Mup;o09rD;ess 9op D;aw3bNin,o15;aShPlean 9oDross But 0T;me FoEuntD; o1M;k 1l6;aJbIforGin,oFtEuD;nd7;ogeth7;ut,v7;th,wD;ard;a4y;pDr19w3;art;eDipA;ck BeD;r 1;lJncel0rGsFtch EveA; in;o16up;h Bt6;ry EvD;e V;aw3o12;l Dm02;aDba4d2o10up;r0Vw3;a0He08l01oSrHuD;bbleFcklTilZlEndlTrn 05tDy 10zz6;t B;k 9; ov7;anMeaKiDush6;ghHng D;aEba4d2forDin,o5up;th;bo5lDr0Lw3;ong;teD;n 1;k D;d2in,o5up;ch0;arKgJil 9n8oGssFttlEunce Dx B;aw3ba4;e 9; ar0B;k Bt 1;e 1;d2up; d2;d 1;aIeed0oDurt0;cFw D;aw3ba4d2o5up;ck;k D;in,oK;ck0nk0st6; oJaGef 1nd D;d2ov7up;er;up;r0t D;d2in,oDup;ff,ut;ff,nD;to;ck Jil0nFrgEsD;h B;ainCe B;g BkC; on;in,o5; o5;aw3d2o5up;ay;cMdIsk Fuction6; oD;ff;arDo5;ouD;nd;d D;d2oDup;ff,n;own;t D;o5up;ut",Modal:"true¦c5lets,m4ought3sh1w0;ill,o5;a0o4;ll,nt;! to;ay,ight,ust;an,o0;uld",Adjective:"true¦0:73;1:7I;2:7O;3:7H;4:7A;5:5B;6:4R;7:49;8:48;9:7F;A:60;a6Eb60c5Md52e4Pf45g3Xh3Mi31j2Zk2Yl2Nm2Cn23o1Np16quack,r0Ws0Ct05uMvJwByear5;arp0eFholeEiDoB;man5oBu67;d69zy;despr6Zs5B;!sa7;eClBste22;co1El o4H;!k5;aCiBola47;b7Nce versa,ol50;ca2gabo5Ynilla;ltSnFpCrb55su4tterB;!mo6U; f30b1KpCsBti1D;ca7et,ide dItairs;er,i3J;aLbeco6Lconvin23deIeHfair,ivers4knGprecedUrEsCwB;iel1Writt5U;i1RuB;pervis0specti3;eBu5;cognHgul6Bl6B;own;ndi3v5Oxpect0;cid0rB;!grou5JsB;iz0tood;b7ppeaHssu6AuthorB;iz0;i20ra;aFeDhough4KoCrB;i1oubl0;geth6p,rp6B;en5LlBm4Vrr2Q;li3;boo,lBn;ent0;aTcSeQhPiNmug,nobbi3AoLpKqueami3AtFuBymb5Y;bDi gener50pBrprisi3;erBre0H;! dup6b,i25;du0seq4P;anda6OeEi0LrBy34;aightBip0; fBfB;or56;adfa5Wreotyp0;a4Uec2Cir1Flend5Wot on; call0le,mb6phist1TrBu0Tvi3X;d5Ury;gnifica2nB;ce4Qg7;am2Le6ocki3ut;cBda1em5lfi2Uni1Spa63re8;o1Cr3R;at53ient24reec53;cr0me,ns serif;aIeEiCoB;bu5Ktt4PuOy4;ghtBv4;!-25fA;ar,bel,condi1du5Xfres4XlDpublic3RsBtard0;is43oB;lu1na2;e1Auc41;b5EciB;al,st;aMeKicayu8lac5Copuli5BrCuB;bl54mp0;eFiCoB;!b06fu5Cmi2Xp6;mCor,sBva1;ti8;a4Re;ci58mB;a0EiB;er,um;ac1WrBti1;fe9ma2Pplexi3v2Z;rBst;allelDtB;-tiBi4;me;!ed;bMffKkJld fashion0nIpHrg1Dth6utGvB;al,erB;!aDniCt,wB;eiBrouB;ght;ll;do0Rer,g2Hsi41;en,posi1; boa5Ag2Fli8;!ay; gua58bBli8;eat;eDsB;cBer0Dole1;e8u3F;d2Ose;ak0eIiHoBua4J;nFrCtB;ab7;thB;!eB;rn;chala2descri4Ustop;ght5;arby,cessa3Sighbor5xt;aJeHiEoBultip7;bi7derClBnth5ot,st;dy;a1n;nBx0;iaBor;tu2Y;di49naBre;ci3;cBgenta,in,jZkeshift,le,mmoth,ny,sculi8;ab2Uho;aKeFiCoBu0Z;uti0Yvi3;mCteraB;l,te;it0;ftEgBth4;al,eCitiB;ma1;nda38;!-08;ngu3Lst,tt6;ap1Oind5no06;agg0uB;niKstifi0veni7;de4gno46lleg4mOnDpso 1RrB;a1releB;va2; JaIbr0corHdFfluenPiPnEsDtB;a9en3GoxB;ic31;a8i2N;a1er,oce2;iCoB;or;re9;deq3Eppr2T;fBsitu,vitro;ro2;mFpB;arDerfe9oBrop6;li1rtB;a2ed;ti4;eBi0M;d2Ln30;aGelFiDoBumdr36;ne2Uok0rrBs03ur5;if2N;ghfalut1KspB;an2L;liVpfA;lEnDrB;d01roB;wi3;dy,gi3;f,low0;ainfAener2Eiga1YlHoGraDuB;ilBng ho;ty;cCtB;efAis;efA;ne,od;ea28ob4;aQeKinJlIoDrB;a1PeBoz1G;e28q0YtfA;oDrB; keeps,eBm6tuna1;g00ign;liB;sh;ag2Uue2;al,i1;dFmCrB;ti7;a7ini8;ne;le; up;bl0i2l20r Cux,voB;ri1uri1;oBreac1A;ff;aJfficie2lImiHnFre9there4veExB;a9cess,pe1JtraCuB;be2Gl0D;!va19;n,ryday; Bcouragi3ti0M;rou1sui1;ne2;abo1YdMe14i1;g6sB;t,ygB;oi3;er;aReJiDoBrea11ue;mina2ne,ubB;le,tfA;dact16fficu1JsCvB;er1F;creDeas0gruntl0hone1AordCtB;a2ress0;er5;et; HadpGfFgene1KliDrang0spe1KtCvoB;ut;ail0ermin0;be1Hca1ghB;tfA;ia2;an;facto;i5magBngeroVs0E;ed,i3;ly;ertaNhief,ivil,oDrB;aBowd0u0D;mp0vYz0;loJmHnCoi3rrBve0K;e9u1D;cre1grEsDtB;emBra0B;po09;ta2;ue2;mer04pleB;te,x;ni4ss4;in;aLeHizarGlFoCrB;and new,isk,okL;gCna fiSttom,urgeoB;is;us;ank,iE;re;autifAhiClov0nBst,yoC;eRt;nd;ul;ckCnkru0SrrB;en;!wards; priori,b0Ic0Fd05fra04g00hZlUma01ntiquTppQrKsIttracti02utheHvEwB;aCkB;wa0P;ke,re;ant garCerB;age;de;ntQ;leep,tonisB;hi3;ab,bitEroDtiB;fiB;ci4;ga2;raB;ry;are2etiLrB;oprB;ia1;at0;arEcohCeBiIl,oof;rt;olB;ic;mi3;ead;ainDgressiConiB;zi3;ve;st;id; IeGuFvB;aCerB;se;nc0;ed;lt;pt,qB;ua1;hoc,infinitB;um;cuCtu4u1;al;ra1;erLlKoIruHsCuB;nda2;e2oCtra9;ct;lu1rbi3;ng;te;pt;aBve;rd;aze,e;ra2;nt",Comparable:"true¦0:3Z;1:4G;2:43;3:49;4:3V;5:2W;a4Mb42c3Md3Be33f2Pg2Dh22i1Tj1Sk1Pl1Hm1Bn15o13p0Tqu0Rr0IsRtKuIvFw7y6za11;ell25ou3;aBe9hi1Wi7r6;o3y;ck0Mde,l6n1ry,se;d,y;a6i4Kt;k,ry;n1Rr6sI;m,y;a7e6ulgar;nge4rda2xi3;gue,in,st;g0n6pco3Kse4;like0ti1;aAen9hi8i7ough,r6;anqu2Oen1ue;dy,g3Sme0ny,r09;ck,n,rs2P;d40se;ll,me,rt,s6wd45;te4;aVcarUeThRiQkin0FlMmKoHpGqua1FtAu7w6;eet,ift;b7dd13per0Gr6;e,re2H;sta2Ft5;aAe9iff,r7u6;pXr1;a6ict,o3;ig3Fn0U;a1ep,rn;le,rk;e22i3Fright0;ci28ft,l7o6re,ur;n,thi3;emn,id;a6el0ooth;ll,rt;e8i6ow,y;ck,g35m6;!y;ek,nd3D;ck,l0mp5;a6iTort,rill,y;dy,ll0Xrp;cu0Rve0Rxy;ce,ed,y;d,fe,int0l1Vv14;aBe9i8o6ude;mantic,o1Isy,u6;gh,nd;ch,pe,tzy;a6d,mo0H;dy,l;gg7ndom,p6re,w;id;ed;ai2i6;ck,et;aEhoDi1QlCoBr8u6;ny,r6;e,p5;egna2ic7o6;fouYud;ey,k0;li04or,te1B;ain,easa2;ny;in4le;dd,f6i0ld,ranQ;fi10;aAe8i7o6;b5isy,rm15sy;ce,mb5;a6w;r,t;ive,rr01;aAe8ild,o7u6;nda19te;ist,o1;a6ek,llX;n,s0ty;d,tuQ;aBeAi9o6ucky;f0Un7o1Du6ve0w17y0T;d,sy;e0g;g1Tke0tt5ve0;an,wd;me,r6te;ge;e7i6;nd;en;ol0ui1P;cy,ll,n6;sBt6;e6ima8;llege2r6;es7media6;te;ti3;ecu6ta2;re;aEeBiAo8u6;ge,m6ng1R;b5id;ll6me0t;ow;gh,l0;a6f04sita2;dy,v6;en0y;nd1Hppy,r6te4;d,sh;aGenFhDiClBoofy,r6;a9e8is0o6ue1E;o6ss;vy;at,en,y;nd,y;ad,ib,ooI;a2d1;a6o6;st0;t5uiY;u1y;aIeeb5iDlat,oAr8u6;ll,n6r14;!ny;aHe6iend0;e,sh;a7r6ul;get4mG;my;erce8n6rm,t;an6e;ciC;! ;le;ir,ke,n0Fr,st,t,ulA;aAerie,mp9sse7v6xtre0Q;il;nti6;al;ty;r7s6;tern,y;ly,th0;aFeCi9r7u6;ll,mb;u6y;nk;r7vi6;ne;e,ty;a6ep,nD;d6f,r;!ly;mp,pp03rk;aHhDlAo8r7u6;dd0r0te;isp,uel;ar6ld,mmon,ol,st0ward0zy;se;e6ou1;a6vW;n,r;ar8e6il0;ap,e6;sy;mi3;gey,lm8r6;e4i3;ful;!i3;aNiLlIoEr8u6;r0sy;ly;aAi7o6;ad,wn;ef,g7llia2;nt;ht;sh,ve;ld,r7un6;cy;ed,i3;ng;a7o6ue;nd,o1;ck,nd;g,tt6;er;d,ld,w1;dy;bsu9ng8we6;so6;me;ry;rd",TextValue:"true¦bOeJfDhundredNmOninAone,qu8s6t0zeroN;enMh3rNw0;e0o;l0ntD;fHve;ir0ousandKree;d,t6;e0ix8;cond,pt1ven7xt1;adr0int0;illionD;e0th;!t0;e9ie8y;i3o0;rt1ur0;!t2;ie4y;ft0rst,ve;e3h,ie2y;ight0lev2;!e1h,ie0y;th;en0;!th;illion0;!s,th",Ordinal:"true¦bGeDf9hundredHmGnin7qu6s4t0zeroH;enGh1rFwe0;lfFn9;ir0ousandE;d,t4;e0ixt9;cond,ptAvent8xtA;adr9int9;et0th;e6ie8;i2o0;r0urt3;tie5;ft1rst;ight0lev1;e0h,ie2;en1;illion0;th",Cardinal:"true¦bHeEf8hundred,mHnineAone,qu6s4t0zero;en,h2rGw0;e0o;lve,n8;irt9ousandEree;e0ix5;pt1ven4xt1;adr0int0;illion;i3o0;r1ur0;!t2;ty;ft0ve;e2y;ight0lev1;!e0y;en;illion0;!s",Expression:"true¦a02b01dXeVfuck,gShLlImHnGoDpBshAtsk,u7voi04w3y0;a1eLu0;ck,p;!a,hoo,y;h1ow,t0;af,f;e0oa;e,w;gh,h0;! 0h,m;huh,oh;eesh,hh,it;ff,hew,l0sst;ease,z;h1o0w,y;h,o,ps;!h;ah,ope;eh,mm;m1ol0;!s;ao,fao;a4e2i,mm,oly1urr0;ah;! mo6;e,ll0y;!o;ha0i;!ha;ah,ee,o0rr;l0odbye;ly;e0h,t cetera,ww;k,p;'oh,a0uh;m0ng;mit,n0;!it;ah,oo,ye; 1h0rgh;!em;la",Adverb:"true¦a07by 05d01eYfShQinPjustOkinda,mMnJoEpCquite,r9s5t2up1very,w0Bye0;p,s; to,wards5;h1o0wiO;o,t6ward;en,us;everal,o0uch;!me1rt0; of;hXtimes,w07;a1e0;alS;ndomRthN;ar excellDer0oint blank; Mhaps;f3n0;ce0ly;! 0;ag00moU; courHten;ewJo0; longEt 0;onHwithstanding;aybe,eanwhiAore0;!ovB;! aboS;deed,steT;en0;ce;or2u0;l9rther0;!moH; 0ev3;examp0good,suF;le;n mas1v0;er;se;e0irect1; 1finite0;ly;ju7trop;far,n0;ow; CbroBd nauseam,gAl5ny2part,side,t 0w3;be5l0mo5wor5;arge,ea4;mo1w0;ay;re;l 1mo0one,ready,so,ways;st;b1t0;hat;ut;ain;ad;lot,posteriori",Preposition:"true¦'o,-,aKbHcGdFexcept,fEinDmidPnotwithstandiQoBpRqua,sAt6u3vi2w0;/o,hereMith0;!in,oQ;a,s-a-vis;n1p0;!on;like,til;h0ill,owards;an,r0;ough0u;!oI;ans,ince,o that;',f0n1ut;!f;!to;or,rom;espite,own,u3;hez,irca;ar1e0oAy;low,sides,tween;ri6;',bo7cross,ft6lo5m3propos,round,s1t0;!op;! long 0;as;id0ong0;!st;ng;er;ut",Determiner:"true¦aAboth,d8e5few,l3mu7neiCown,plenty,some,th2various,wh0;at0ich0;evB;at,e3is,ose;a,e0;!ast,s;a1i6l0nough,very;!se;ch;e0u;!s;!n0;!o0y;th0;er"},gt=["Person","Place","Organization"],ft={Noun:{notA:["Verb","Adjective","Adverb"]},Singular:{isA:"Noun",notA:"Plural"},ProperNoun:{isA:"Noun"},Person:{isA:["ProperNoun","Singular"],notA:["Place","Organization","Date"]},FirstName:{isA:"Person"},MaleName:{isA:"FirstName",notA:["FemaleName","LastName"]},FemaleName:{isA:"FirstName",notA:["MaleName","LastName"]},LastName:{isA:"Person",notA:["FirstName"]},NickName:{isA:"Person",notA:["FirstName","LastName"]},Honorific:{isA:"Noun",notA:["FirstName","LastName","Value"]},Place:{isA:"Singular",notA:["Person","Organization"]},Country:{isA:["Place","ProperNoun"],notA:["City"]},City:{isA:["Place","ProperNoun"],notA:["Country"]},Region:{isA:["Place","ProperNoun"]},Address:{isA:"Place"},Organization:{isA:["Singular","ProperNoun"],notA:["Person","Place"]},SportsTeam:{isA:"Organization"},School:{isA:"Organization"},Company:{isA:"Organization"},Plural:{isA:"Noun",notA:["Singular"]},Uncountable:{isA:"Noun"},Pronoun:{isA:"Noun",notA:gt},Actor:{isA:"Noun",notA:gt},Activity:{isA:"Noun",notA:["Person","Place"]},Unit:{isA:"Noun",notA:gt},Demonym:{isA:["Noun","ProperNoun"],notA:gt},Possessive:{isA:"Noun"}},mt={Verb:{notA:["Noun","Adjective","Adverb","Value"]},PresentTense:{isA:"Verb",notA:["PastTense","Copula","FutureTense"]},Infinitive:{isA:"PresentTense",notA:["PastTense","Gerund"]},Gerund:{isA:"PresentTense",notA:["PastTense","Copula","FutureTense"]},PastTense:{isA:"Verb",notA:["FutureTense"]},FutureTense:{isA:"Verb"},Copula:{isA:"Verb"},Modal:{isA:"Verb",notA:["Infinitive"]},PerfectTense:{isA:"Verb",notA:"Gerund"},Pluperfect:{isA:"Verb"},Participle:{isA:"Verb"},PhrasalVerb:{isA:"Verb"},Particle:{isA:"PhrasalVerb"}},vt={Value:{notA:["Verb","Adjective","Adverb"]},Ordinal:{isA:"Value",notA:["Cardinal"]},Cardinal:{isA:"Value",notA:["Ordinal"]},RomanNumeral:{isA:"Cardinal",notA:["Ordinal","TextValue"]},TextValue:{isA:"Value",notA:["NumericValue"]},NumericValue:{isA:"Value",notA:["TextValue"]},Money:{isA:"Cardinal"},Percent:{isA:"Value"}},bt=["Noun","Verb","Adjective","Adverb","Value","QuestionWord"],yt={Adjective:{notA:["Noun","Verb","Adverb","Value"]},Comparable:{isA:["Adjective"]},Comparative:{isA:["Adjective"]},Superlative:{isA:["Adjective"],notA:["Comparative"]},NumberRange:{isA:["Contraction"]},Adverb:{notA:["Noun","Verb","Adjective","Value"]},Date:{notA:["Verb","Conjunction","Adverb","Preposition","Adjective"]},Month:{isA:["Date","Singular"],notA:["Year","WeekDay","Time"]},WeekDay:{isA:["Date","Noun"]},Time:{isA:["Date"],notA:["Value"]},Determiner:{notA:bt},Conjunction:{notA:bt},Preposition:{notA:bt},QuestionWord:{notA:["Determiner"]},Currency:{},Expression:{notA:["Noun","Adjective","Verb","Adverb"]},Abbreviation:{},Url:{notA:["HashTag","PhoneNumber","Verb","Adjective","Value","AtMention","Email"]},PhoneNumber:{notA:["HashTag","Verb","Adjective","Value","AtMention","Email"]},HashTag:{},AtMention:{isA:["Noun"],notA:["HashTag","Verb","Adjective","Value","Email"]},Emoji:{notA:["HashTag","Verb","Adjective","Value","AtMention"]},Emoticon:{notA:["HashTag","Verb","Adjective","Value","AtMention"]},Email:{notA:["HashTag","Verb","Adjective","Value","AtMention"]},Auxiliary:{notA:["Noun","Adjective","Value"]},Acronym:{notA:["Plural","RomanNumeral"]},Negative:{notA:["Noun","Adjective","Value"]},Condition:{notA:["Verb","Adjective","Noun","Value"]}},wt={Noun:"blue",Verb:"green",Negative:"green",Date:"red",Value:"red",Adjective:"magenta",Preposition:"cyan",Conjunction:"cyan",Determiner:"cyan",Adverb:"cyan"},kt=function(e){return Object.keys(e).forEach((function(t){e[t].color?e[t].color=e[t].color:wt[t]?e[t].color=wt[t]:e[t].isA.some((function(r){return!!wt[r]&&(e[t].color=wt[r],!0)}))})),e},At=function(e){return Object.keys(e).forEach((function(t){for(var r=e[t],n=r.isA.length,a=0;a=0;i--,a*=36){var o=e.charCodeAt(i)-48;o>10&&(o-=7),t+=o*a}return t},Et=function(e,t,r){var n=jt(t);return n1&&(r.hasCompound[i[0]]=!0),"Singular"===t){var o=a.toPlural(e,r);n[o]=n[o]||"Plural"}if("Infinitive"===t)for(var s=a.conjugate(e,r),u=Object.keys(s),l=0;l0&&void 0!==arguments[0]?arguments[0]:"",t=e[e.length-1];if(!0===qt.hasOwnProperty(t))for(var r=0;r0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1?arguments[1]:void 0,r={};return t&&t.irregulars&&!0===t.irregulars.verbs.hasOwnProperty(e)&&(r=Object.assign({},t.irregulars.verbs[e])),void 0===(r=Object.assign({},Wt(e),r)).Gerund&&(r.Gerund=Qt.Gerund(e)),void 0===r.PastTense&&(r.PastTense=Qt.PastTense(e)),void 0===r.PresentTense&&(r.PresentTense=Qt.PresentTense(e)),r},Xt=[/ght$/,/nge$/,/ough$/,/ain$/,/uel$/,/[au]ll$/,/ow$/,/oud$/,/...p$/],Yt=[/ary$/],er={nice:"nicest",late:"latest",hard:"hardest",inner:"innermost",outer:"outermost",far:"furthest",worse:"worst",bad:"worst",good:"best",big:"biggest",large:"largest"},tr=[{reg:/y$/i,repl:"iest"},{reg:/([aeiou])t$/i,repl:"$1ttest"},{reg:/([aeou])de$/i,repl:"$1dest"},{reg:/nge$/i,repl:"ngest"},{reg:/([aeiou])te$/i,repl:"$1test"}],rr=[/ght$/,/nge$/,/ough$/,/ain$/,/uel$/,/[au]ll$/,/ow$/,/old$/,/oud$/,/e[ae]p$/],nr=[/ary$/,/ous$/],ar={grey:"greyer",gray:"grayer",green:"greener",yellow:"yellower",red:"redder",good:"better",well:"better",bad:"worse",sad:"sadder",big:"bigger"},ir=[{reg:/y$/i,repl:"ier"},{reg:/([aeiou])t$/i,repl:"$1tter"},{reg:/([aeou])de$/i,repl:"$1der"},{reg:/nge$/i,repl:"nger"}],or={toSuperlative:function(e){if(er.hasOwnProperty(e))return er[e];for(var t=0;t0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1?arguments[1]:void 0,r=t.irregulars.nouns;if(r.hasOwnProperty(e))return r[e];var n=cr(e);return null!==n?n:lr.test(e)?e+"es":e+"s"},dr=[[/([^v])ies$/i,"$1y"],[/ises$/i,"isis"],[/(kn|[^o]l|w)ives$/i,"$1ife"],[/^((?:ca|e|ha|(?:our|them|your)?se|she|wo)l|lea|loa|shea|thie)ves$/i,"$1f"],[/^(dwar|handkerchie|hoo|scar|whar)ves$/i,"$1f"],[/(antenn|formul|nebul|vertebr|vit)ae$/i,"$1a"],[/(octop|vir|radi|nucle|fung|cact|stimul)(i)$/i,"$1us"],[/(buffal|tomat|tornad)(oes)$/i,"$1o"],[/(eas)es$/i,"$1e"],[/(..[aeiou]s)es$/i,"$1"],[/(vert|ind|cort)(ices)$/i,"$1ex"],[/(matr|append)(ices)$/i,"$1ix"],[/(x|ch|ss|sh|z|o)es$/i,"$1"],[/men$/i,"man"],[/(n)ews$/i,"$1ews"],[/([ti])a$/i,"$1um"],[/([^aeiouy]|qu)ies$/i,"$1y"],[/(s)eries$/i,"$1eries"],[/(m)ovies$/i,"$1ovie"],[/([m|l])ice$/i,"$1ouse"],[/(cris|ax|test)es$/i,"$1is"],[/(alias|status)es$/i,"$1"],[/(ss)$/i,"$1"],[/(ics)$/i,"$1"],[/s$/i,""]],pr=function(e,t){var r,n=t.irregulars.nouns,a=(r=n,Object.keys(r).reduce((function(e,t){return e[r[t]]=t,e}),{}));if(a.hasOwnProperty(e))return a[e];for(var i=0;i1?a[i]&&"."!==a[i]&&r.tag(a[i],n,t.world):r.tag(e,n,t.world)}))}))},Cr={tag:function(e,t){return e?(xr(e,this,!1,t),this):this},tagSafe:function(e,t){return e?(xr(e,this,!0,t),this):this},unTag:function(e,t){var r=this;return this.list.forEach((function(n){n.terms().forEach((function(n){return n.unTag(e,t,r.world)}))})),this},canBe:function(e){if(!e)return this;var t=this.world,r=this.list.reduce((function(r,n){return r.concat(n.canBe(e,t))}),[]);return this.buildFrom(r)}},Dr={map:function(t){var r=this;if(!t)return this;var n=this.list.map((function(e,n){var a=r.buildFrom([e]);a.from=null;var i=t(a,n);return i&&i.list&&i.list[0]?i.list[0]:i}));return 0===(n=n.filter((function(e){return e}))).length?this.buildFrom(n):"object"!==e(n[0])||"Phrase"!==n[0].isA?n:this.buildFrom(n)},forEach:function(e,t){var r=this;return e?(this.list.forEach((function(n,a){var i=r.buildFrom([n]);!0===t&&(i.from=null),e(i,a)})),this):this},filter:function(e){var t=this;if(!e)return this;var r=this.list.filter((function(r,n){var a=t.buildFrom([r]);return a.from=null,e(a,n)}));return this.buildFrom(r)},find:function(e){var t=this;if(!e)return this;var r=this.list.find((function(r,n){var a=t.buildFrom([r]);return a.from=null,e(a,n)}));return r?this.buildFrom([r]):void 0},some:function(e){var t=this;return e?this.list.some((function(r,n){var a=t.buildFrom([r]);return a.from=null,e(a,n)})):this},random:function(e){if(!this.found)return this;var t=Math.floor(Math.random()*this.list.length);if(void 0===e){var r=[this.list[t]];return this.buildFrom(r)}return t+e>this.length&&(t=(t=this.length-e)<0?0:t),this.slice(t,t+e)}},jr=function(e){return e.split(/[ -]/g)},Er=function(e,t,r){for(var n=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],r={};return e.forEach((function(e,n){var a=!0;void 0!==t[n]&&(a=t[n]),e=(e=(e||"").toLowerCase()).replace(/[,;.!?]+$/,"");var i=jr(e).map((function(e){return e.trim()}));r[i[0]]=r[i[0]]||{},1===i.length?r[i[0]].value=a:(r[i[0]].more=r[i[0]].more||[],r[i[0]].more.push({rest:i.slice(1),value:a}))})),r}(e,t),a=[],i=function(e){for(var t=r.list[e],i=t.terms().map((function(e){return e.reduced})),o=function(e){void 0!==n[i[e]]&&(void 0!==n[i[e]].more&&n[i[e]].more.forEach((function(r){void 0!==i[e+r.rest.length]&&(!0===r.rest.every((function(t,r){return t===i[e+r+1]}))&&a.push({id:t.terms()[e].id,value:r.value,length:r.rest.length+1}))})),void 0!==n[i[e]].value&&a.push({id:t.terms()[e].id,value:n[i[e]].value,length:1}))},s=0;s1&&void 0!==arguments[1]?arguments[1]:{};return t?(!0===n&&(n={keepTags:!0}),!1===n&&(n={keepTags:!1}),n=n||{},this.uncache(),this.list.forEach((function(a){var i,o=t;if("function"==typeof t&&(o=t(a)),o&&"object"===e(o)&&"Doc"===o.isA)i=o.list,r.pool().merge(o.pool());else{if("string"!=typeof o)return;!1!==n.keepCase&&a.terms(0).isTitleCase()&&(o=Or(o)),i=ht(o,r.world,r.pool());var s=r.buildFrom(i);s.tagger(),i=s.list}if(!0===n.keepTags){var u=a.json({terms:{tags:!0}}).terms;i[0].terms().forEach((function(e,t){u[t]&&e.tagSafe(u[t].tags,"keptTag",r.world)}))}a.replace(i[0],r)})),this):this.delete()},replace:function(e,t,r){return void 0===t?this.replaceWith(e,r):(this.match(e).replaceWith(t,r),this)}},zr=E((function(e,t){var r=function(e,t){var r=ht(e,t.world)[0],n=t.buildFrom([r]);return n.tagger(),t.list=n.list,t};t.append=function(e){var t=this;return e?this.found?(this.uncache(),this.list.forEach((function(r){var n=ht(e,t.world,t.pool())[0];t.buildFrom([n]).tagger(),r.append(n,t)})),this):r(e,this):this},t.insertAfter=t.append,t.insertAt=t.append,t.prepend=function(e){var t=this;return e?this.found?(this.uncache(),this.list.forEach((function(r){var n=ht(e,t.world,t.pool())[0];t.buildFrom([n]).tagger(),r.prepend(n,t)})),this):r(e,this):this},t.insertBefore=t.prepend,t.concat=function(){this.uncache();for(var e=this.list.slice(0),t=0;t0&&void 0!==arguments[0]?arguments[0]:{};if("number"==typeof t&&this.list[t])return this.list[t].json(r);!0===(t=n(t)).root&&this.list.forEach((function(t){t.terms().forEach((function(t){null===t.root&&t.setRoot(e.world)}))}));var a=this.list.map((function(r){return r.json(t,e.world)}));if((t.terms.offset||t.offset||t.terms.index||t.index)&&Ir(this,a,t),t.frequency||t.freq||t.count){var i={};this.list.forEach((function(e){var t=e.text("reduced");i[t]=i[t]||0,i[t]+=1})),this.list.forEach((function(e,t){a[t].count=i[e.text("reduced")]}))}if(t.unique){var o={};a=a.filter((function(e){return!0!==o[e.reduced]&&(o[e.reduced]=!0,!0)}))}return a},t.data=t.json})),Sr=E((function(e){var t="",r=function(e,t){for(e=e.toString();e.lengtht.count?-1:e.countn?1:0},length:function(e,t){var r=e.text().trim().length,n=t.text().trim().length;return rn?-1:0},wordCount:function(e,t){var r=e.wordCount(),n=t.wordCount();return rn?-1:0}};Jr.alphabetical=Jr.alpha,Jr.wordcount=Jr.wordCount;var qr={index:!0,sequence:!0,seq:!0,sequential:!0,chron:!0,chronological:!0},Kr={sort:function(e){return"freq"===(e=e||"alpha")||"frequency"===e||"topk"===e?(r={},n={case:!0,punctuation:!1,whitespace:!0,unicode:!0},(t=this).list.forEach((function(e){var t=e.text(n);r[t]=r[t]||0,r[t]+=1})),t.list.sort((function(e,t){var a=r[e.text(n)],i=r[t.text(n)];return ai?-1:0})),t):qr.hasOwnProperty(e)?function(e){var t={};return e.json({terms:{offset:!0}}).forEach((function(e){t[e.terms[0].id]=e.terms[0].offset.start})),e.list=e.list.sort((function(e,r){return t[e.start]>t[r.start]?1:t[e.start]0){a+=o;continue}}if(void 0===r[i]||!0!==r.hasOwnProperty(i))if(i===e[a].reduced||!0!==r.hasOwnProperty(e[a].reduced)){if(!0===hn.test(i)){var s=i.replace(hn,"");!0===r.hasOwnProperty(s)&&e[a].tag(r[s],"noprefix-lexicon",t)}}else e[a].tag(r[e[a].reduced],"lexicon",t);else e[a].tag(r[i],"lexicon",t)}return e},gn=/[\'‘’‛‵′`´]$/,fn=/^(m|k|cm|km|m)\/(s|h|hr)$/,mn=[[/^[\w\.]+@[\w\.]+\.[a-z]{2,3}$/,"Email"],[/^#[a-z0-9_\u00C0-\u00FF]{2,}$/,"HashTag"],[/^@\w{2,}$/,"AtMention"],[/^(https?:\/\/|www\.)\w+\.[a-z]{2,3}/,"Url"],[/^[\w./]+\.(com|net|gov|org|ly|edu|info|biz|ru|jp|de|in|uk|br)/,"Url"],[/^[012]?[0-9](:[0-5][0-9])(:[0-5][0-9])$/,"Time"],[/^[012]?[0-9](:[0-5][0-9])?(:[0-5][0-9])? ?(am|pm)$/,"Time"],[/^[012]?[0-9](:[0-5][0-9])(:[0-5][0-9])? ?(am|pm)?$/,"Time"],[/^[PMCE]ST$/,"Time"],[/^utc ?[+-]?[0-9]+?$/,"Time"],[/^[a-z0-9]*? o\'?clock$/,"Time"],[/^[0-9]{1,4}-[0-9]{1,2}-[0-9]{1,4}$/,"Date"],[/^[0-9]{1,4}\/[0-9]{1,2}\/[0-9]{1,4}$/,"Date"],[/^[0-9]{1,4}-[a-z]{2,9}-[0-9]{1,4}$/i,"Date"],[/^ma?c\'.*/,"LastName"],[/^o\'[drlkn].*/,"LastName"],[/^ma?cd[aeiou]/,"LastName"],[/^(lol)+[sz]$/,"Expression"],[/^woo+a*?h?$/,"Expression"],[/^(un|de|re)\\-[a-z\u00C0-\u00FF]{2}/,"Verb"],[/^[0-9]{1,4}\.[0-9]{1,2}\.[0-9]{1,4}$/,"Date"],[/^[0-9]{3}-[0-9]{4}$/,"PhoneNumber"],[/^(\+?[0-9][ -])?[0-9]{3}[ -]?[0-9]{3}-[0-9]{4}$/,"PhoneNumber"],[/^[-+]?[\$\xA2-\xA5\u058F\u060B\u09F2\u09F3\u09FB\u0AF1\u0BF9\u0E3F\u17DB\u20A0-\u20BD\uA838\uFDFC\uFE69\uFF04\uFFE0\uFFE1\uFFE5\uFFE6][-+]?[0-9]+(,[0-9]{3})*(\.[0-9]+)?(k|m|b|bn)?\+?$/,["Money","Value"]],[/^[-+]?[0-9]+(,[0-9]{3})*(\.[0-9]+)?[\$\xA2-\xA5\u058F\u060B\u09F2\u09F3\u09FB\u0AF1\u0BF9\u0E3F\u17DB\u20A0-\u20BD\uA838\uFDFC\uFE69\uFF04\uFFE0\uFFE1\uFFE5\uFFE6]\+?$/,["Money","Value"]],[/^[-+]?[0-9]([0-9,.])+?(usd|eur|jpy|gbp|cad|aud|chf|cny|hkd|nzd|kr|rub)$/i,["Money","Value"]],[/^[-+]?[0-9]+(,[0-9]{3})*(\.[0-9]+)?\+?$/,["Cardinal","NumericValue"]],[/^[-+]?[0-9]+(,[0-9]{3})*(\.[0-9]+)?(st|nd|rd|th)$/,["Ordinal","NumericValue"]],[/^\.[0-9]+\+?$/,["Cardinal","NumericValue"]],[/^[-+]?[0-9]+(,[0-9]{3})*(\.[0-9]+)?%\+?$/,["Percent","Cardinal","NumericValue"]],[/^\.[0-9]+%$/,["Percent","Cardinal","NumericValue"]],[/^[0-9]{1,4}\/[0-9]{1,4}$/,"Fraction"],[/^[0-9.]{1,2}[-–][0-9]{1,2}$/,["Value","NumberRange"]],[/^[0-9.]{1,4}(st|nd|rd|th)?[-–][0-9\.]{1,4}(st|nd|rd|th)?$/,"NumberRange"],[/^[0-9.]+([a-z]{1,4})$/,"Value"]],vn=/^[IVXLCDM]{2,}$/,bn=/^M{0,4}(CM|CD|D?C{0,3})(XC|XL|L?X{0,3})(IX|IV|V?I{0,3})$/,yn="Adjective",wn="Infinitive",kn="PresentTense",An="Singular",$n="PastTense",Pn="Adverb",Bn="Expression",Gn="Actor",xn="Verb",Cn="Noun",Dn="LastName",jn={a:[[/.[aeiou]na$/,Cn],[/.[oau][wvl]ska$/,Dn],[/.[^aeiou]ica$/,An],[/^([hyj]a)+$/,Bn]],c:[[/.[^aeiou]ic$/,yn]],d:[[/[aeiou](pp|ll|ss|ff|gg|tt|rr|bb|nn|mm)ed$/,$n],[/.[aeo]{2}[bdgmnprvz]ed$/,$n],[/.[aeiou][sg]hed$/,$n],[/.[aeiou]red$/,$n],[/.[aeiou]r?ried$/,$n],[/.[bcdgtr]led$/,$n],[/.[aoui]f?led$/,$n],[/.[iao]sed$/,$n],[/[aeiou]n?[cs]ed$/,$n],[/[aeiou][rl]?[mnf]ed$/,$n],[/[aeiou][ns]?c?ked$/,$n],[/[aeiou][nl]?ged$/,$n],[/.[tdbwxz]ed$/,$n],[/[^aeiou][aeiou][tvx]ed$/,$n],[/.[cdlmnprstv]ied$/,$n],[/[^aeiou]ard$/,An],[/[aeiou][^aeiou]id$/,yn],[/.[vrl]id$/,yn]],e:[[/.[lnr]ize$/,wn],[/.[^aeiou]ise$/,wn],[/.[aeiou]te$/,wn],[/.[^aeiou][ai]ble$/,yn],[/.[^aeiou]eable$/,yn],[/.[ts]ive$/,yn]],h:[[/.[^aeiouf]ish$/,yn],[/.v[iy]ch$/,Dn],[/^ug?h+$/,Bn],[/^uh[ -]?oh$/,Bn]],i:[[/.[oau][wvl]ski$/,Dn]],k:[[/^(k){2}$/,Bn]],l:[[/.[gl]ial$/,yn],[/.[^aeiou]ful$/,yn],[/.[nrtumcd]al$/,yn],[/.[^aeiou][ei]al$/,yn]],m:[[/.[^aeiou]ium$/,An],[/[^aeiou]ism$/,An],[/^h*u*m+$/,Bn],[/^\d+ ?[ap]m$/,"Date"]],n:[[/.[lsrnpb]ian$/,yn],[/[^aeiou]ician$/,Gn],[/[aeiou][ktrp]in$/,"Gerund"]],o:[[/^no+$/,Bn],[/^(yo)+$/,Bn],[/^woo+[pt]?$/,Bn]],r:[[/.[bdfklmst]ler$/,"Noun"],[/.[ilk]er$/,"Comparative"],[/[aeiou][pns]er$/,An],[/[^i]fer$/,wn],[/.[^aeiou][ao]pher$/,Gn]],t:[[/.[di]est$/,"Superlative"],[/.[icldtgrv]ent$/,yn],[/[aeiou].*ist$/,yn],[/^[a-z]et$/,xn]],s:[[/.[rln]ates$/,kn],[/.[^z]ens$/,xn],[/.[lstrn]us$/,An],[/.[aeiou]sks$/,kn],[/.[aeiou]kes$/,kn],[/[aeiou][^aeiou]is$/,An],[/[a-z]\'s$/,Cn],[/^yes+$/,Bn]],v:[[/.[^aeiou][ai][kln]ov$/,Dn]],y:[[/.[cts]hy$/,yn],[/.[st]ty$/,yn],[/.[gk]y$/,yn],[/.[tnl]ary$/,yn],[/.[oe]ry$/,An],[/[rdntkbhs]ly$/,Pn],[/...lly$/,Pn],[/[bszmp]{2}y$/,yn],[/.(gg|bb|zz)ly$/,yn],[/.[aeiou]my$/,yn],[/[ea]{2}zy$/,yn],[/.[^aeiou]ity$/,An]]},En="Adjective",Nn="Infinitive",Fn="PresentTense",On="Singular",Tn="PastTense",zn="Adverb",Hn="Plural",Vn="Actor",In="Verb",Mn="Noun",Sn="LastName",Ln="Modal",_n=[null,null,{ea:On,ia:Mn,ic:En,ly:zn,"'n":In,"'t":In},{oed:Tn,ued:Tn,xed:Tn," so":zn,"'ll":Ln,"'re":"Copula",azy:En,end:In,ped:Tn,ffy:En,ify:Nn,ing:"Gerund",ize:Nn,lar:En,mum:En,nes:Fn,nny:En,oid:En,ous:En,que:En,rmy:En,rol:On,sis:On,zes:Fn},{amed:Tn,aped:Tn,ched:Tn,lked:Tn,nded:Tn,cted:Tn,dged:Tn,akis:Sn,cede:Nn,chuk:Sn,czyk:Sn,ects:Fn,ends:In,enko:Sn,ette:On,fies:Fn,fore:zn,gate:Nn,gone:En,ices:Hn,ints:Hn,ines:Hn,ions:Hn,less:zn,llen:En,made:En,nsen:Sn,oses:Fn,ould:Ln,some:En,sson:Sn,tage:Nn,teen:"Value",tion:On,tive:En,tors:Mn,vice:On},{tized:Tn,urned:Tn,eased:Tn,ances:Hn,bound:En,ettes:Hn,fully:zn,ishes:Fn,ities:Hn,marek:Sn,nssen:Sn,ology:Mn,ports:Hn,rough:En,tches:Fn,tieth:"Ordinal",tures:Hn,wards:zn,where:zn},{auskas:Sn,keeper:Vn,logist:Vn,teenth:"Value"},{opoulos:Sn,borough:"Place",sdottir:Sn}],Jn={":(":!0,":)":!0,":P":!0,":p":!0,":O":!0,":3":!0,":|":!0,":/":!0,":\\":!0,":$":!0,":*":!0,":@":!0,":-(":!0,":-)":!0,":-P":!0,":-p":!0,":-O":!0,":-3":!0,":-|":!0,":-/":!0,":-\\":!0,":-$":!0,":-*":!0,":-@":!0,":^(":!0,":^)":!0,":^P":!0,":^p":!0,":^O":!0,":^3":!0,":^|":!0,":^/":!0,":^\\":!0,":^$":!0,":^*":!0,":^@":!0,"):":!0,"(:":!0,"$:":!0,"*:":!0,")-:":!0,"(-:":!0,"$-:":!0,"*-:":!0,")^:":!0,"(^:":!0,"$^:":!0,"*^:":!0,"<3":!0,"2){var a=n.clean[n.clean.length-2];if("s"===a)return void n.tag(["Possessive","Noun"],"end-tick",r);"n"===a&&n.tag(["Gerund"],"chillin",r)}fn.test(n.text)&&n.tag("Unit","per-sec",r)},regex:function(e,t){for(var r=e.text,n=0;n=2&&vn.test(r)&&bn.test(r)&&e.tag("RomanNumeral","xvii",t)},suffix:function(e,t){!function(e,t){var r=e.clean.length,n=7;r<=n&&(n=r-1);for(var a=n;a>1;a-=1){var i=e.clean.substr(r-a,r);if(!0===_n[i.length].hasOwnProperty(i)){var o=_n[i.length][i];e.tagSafe(o,"suffix -"+i,t);break}}}(e,t),function(e,t){var r=e.clean,n=r[r.length-1];if(!0===jn.hasOwnProperty(n))for(var a=jn[n],i=0;i35)}(n=(n=n.trim()).replace(/[.!?,]$/,""))&&(e.tag("Emoji","comma-emoji",t),e.text=n,e.pre=e.pre.replace(":",""),e.post=e.post.replace(":","")),e.text.match(qn)&&(e.tag("Emoji","unicode-emoji",t),e.text=n),!0===(r=(r=n).replace(/^[:;]/,":"),Jn.hasOwnProperty(r))&&(e.tag("Emoticon","emoticon-emoji",t),e.text=n)}},Rn=function(e,t){var r=e.world;Kn.lexicon(t,r);for(var n=0;n3&&void 0!==r[n]&&!0===r.hasOwnProperty(n)&&e.tag(r[n],"stem-"+n,t)}}))},aa={isSingular:[/(ax|test)is$/i,/(octop|vir|radi|nucle|fung|cact|stimul)us$/i,/(octop|vir)i$/i,/(rl)f$/i,/(alias|status)$/i,/(bu)s$/i,/(al|ad|at|er|et|ed|ad)o$/i,/(ti)um$/i,/(ti)a$/i,/sis$/i,/(?:(^f)fe|(lr)f)$/i,/hive$/i,/s[aeiou]+ns$/i,/(^aeiouy|qu)y$/i,/(x|ch|ss|sh|z)$/i,/(matr|vert|ind|cort)(ix|ex)$/i,/(m|l)ouse$/i,/(m|l)ice$/i,/(antenn|formul|nebul|vertebr|vit)a$/i,/.sis$/i,/^(?!talis|.*hu)(.*)man$/i],isPlural:[/(^v)ies$/i,/ises$/i,/ives$/i,/(antenn|formul|nebul|vertebr|vit)ae$/i,/(octop|vir|radi|nucle|fung|cact|stimul)i$/i,/(buffal|tomat|tornad)oes$/i,/(analy|ba|diagno|parenthe|progno|synop|the)ses$/i,/(vert|ind|cort)ices$/i,/(matr|append)ices$/i,/(x|ch|ss|sh|s|z|o)es$/i,/is$/i,/men$/i,/news$/i,/.tia$/i,/(^f)ves$/i,/(lr)ves$/i,/(^aeiouy|qu)ies$/i,/(m|l)ice$/i,/(cris|ax|test)es$/i,/(alias|status)es$/i,/ics$/i]},ia=["Uncountable","Pronoun","Place","Value","Person","Month","WeekDay","Holiday"],oa=[/ss$/,/sis$/,/[^aeiou][uo]s$/,/'s$/],sa=[/i$/,/ae$/],ua=function(e,t){if(e.tags.Noun&&!e.tags.Acronym){var r=e.clean;if(e.tags.Singular||e.tags.Plural)return;if(r.length<=3)return void e.tag("Singular","short-singular",t);if(ia.find((function(t){return e.tags[t]})))return;if(aa.isPlural.find((function(e){return e.test(r)})))return void e.tag("Plural","plural-rules",t);if(aa.isSingular.find((function(e){return e.test(r)})))return void e.tag("Singular","singular-rules",t);if(!0===/s$/.test(r)){if(oa.find((function(e){return e.test(r)})))return;return void e.tag("Plural","plural-fallback",t)}if(sa.find((function(e){return e.test(r)})))return;e.tag("Singular","singular-fallback",t)}},la=["academy","administration","agence","agences","agencies","agency","airlines","airways","army","assoc","associates","association","assurance","authority","autorite","aviation","bank","banque","board","boys","brands","brewery","brotherhood","brothers","building society","bureau","cafe","caisse","capital","care","cathedral","center","central bank","centre","chemicals","choir","chronicle","church","circus","clinic","clinique","club","co","coalition","coffee","collective","college","commission","committee","communications","community","company","comprehensive","computers","confederation","conference","conseil","consulting","containers","corporation","corps","corp","council","crew","daily news","data","departement","department","department store","departments","design","development","directorate","division","drilling","education","eglise","electric","electricity","energy","ensemble","enterprise","enterprises","entertainment","estate","etat","evening news","faculty","federation","financial","fm","foundation","fund","gas","gazette","girls","government","group","guild","health authority","herald","holdings","hospital","hotel","hotels","inc","industries","institut","institute","institute of technology","institutes","insurance","international","interstate","investment","investments","investors","journal","laboratory","labs","liberation army","limited","local authority","local health authority","machines","magazine","management","marine","marketing","markets","media","memorial","mercantile exchange","ministere","ministry","military","mobile","motor","motors","musee","museum","news","news service","observatory","office","oil","optical","orchestra","organization","partners","partnership","people's party","petrol","petroleum","pharmacare","pharmaceutical","pharmaceuticals","pizza","plc","police","polytechnic","post","power","press","productions","quartet","radio","regional authority","regional health authority","reserve","resources","restaurant","restaurants","savings","school","securities","service","services","social club","societe","society","sons","standard","state police","state university","stock exchange","subcommittee","syndicat","systems","telecommunications","telegraph","television","times","tribunal","tv","union","university","utilities","workers"].reduce((function(e,t){return e[t]="Noun",e}),{}),ca=function(e){return!!e.tags.Noun&&(!(e.tags.Pronoun||e.tags.Comma||e.tags.Possessive)&&!!(e.tags.Organization||e.tags.Acronym||e.tags.Place||e.titleCase()))},ha=/^[A-Z]('s|,)?$/,da=/([A-Z]\.){2}[A-Z]?/i,pa={I:!0,A:!0},ga={neighbours:Zn,case:ea,stem:na,plural:ua,organizations:function(e,t){for(var r=0;r0?ei=ei.concat(t):ei.push(e)})),ei.forEach((function(e){var t,r,n;return e.required=(t=e.reg,r=[],n=[],t.forEach((function(e){!0!==e.optional&&!0!==e.negative&&(void 0!==e.tag&&r.push(e.tag),void 0!==e.word&&n.push(e.word))})),{tags:Ma(r),words:Ma(n)}),e}));var ti=ei,ri=function(e){ti.forEach((function(t){var r=[];t.required.words.forEach((function(t){r.push(e._cache.words[t]||[])})),t.required.tags.forEach((function(t){r.push(e._cache.tags[t]||[])}));var n=function(e){if(0===e.length)return[];var t={};e.forEach((function(e){e=Ma(e);for(var r=0;r5&&e.match("#Verb+").length>=2}));if(u.found){var l=u.splitAfter("#Noun .* #Verb .* #Noun+");n=n.splitOn(l.eq(0))}return"number"==typeof t&&(n=n.get(t)),new e(n.list,this,this.world)},e},li=function(e){var r=function(e){a(i,e);var r=u(i);function i(e,n,a){var o;return t(this,i),(o=r.call(this,e,n,a)).contracted=null,o}return n(i,[{key:"expand",value:function(){return this.list.forEach((function(e){var t=e.terms(),r=t[0].isTitleCase();t.forEach((function(e,r){e.set(e.implicit||e.text),e.implicit=void 0,r0}}),Object.defineProperty(this,"length",{get:function(){return i.list.length}}),Object.defineProperty(this,"isA",{get:function(){return"Doc"}})}return n(e,[{key:"tagger",value:function(){return ai(this)}},{key:"pool",value:function(){return this.list.length>0?this.list[0].pool:this.all().list[0].pool}}]),e}();Ji.prototype.buildFrom=function(e){return e=e.map((function(e){return e.clone(!0)})),new Ji(e,this,this.world)},Ji.prototype.fromText=function(e){var t=ht(e,this.world,this.pool());return this.buildFrom(t)},Object.assign(Ji.prototype,_i.misc),Object.assign(Ji.prototype,_i.selections),Li(Ji);var qi={untag:"unTag",and:"match",notIf:"ifNo",only:"if",onlyIf:"if"};Object.keys(qi).forEach((function(e){return Ji.prototype[e]=Ji.prototype[qi[e]]}));var Ki=Ji,Ri=function(e){var t=e.termList();return pn(t,e.world),e};return function e(t){var r=t,n=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1?arguments[1]:void 0;t&&r.addWords(t);var n=ht(e,r),a=new Ki(n,null,r);return a.tagger(),a};return n.tokenize=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1?arguments[1]:void 0,n=r;t&&((n=n.clone()).words={},n.addWords(t));var a=ht(e,n),i=new Ki(a,null,n);return t&&Ri(i),i},n.extend=function(e){return e(Ki,r,this,_e,oe,qe),this},n.fromJSON=function(e){var t=dt(e,r);return new Ki(t,null,r)},n.clone=function(){return e(r.clone())},n.verbose=function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return r.verbose(e),this},n.world=function(){return r},n.version="13.4.0",n.import=n.load,n}(new Ar)})); diff --git a/builds/compromise.mjs b/builds/compromise.mjs index 3c46ee4f6..4bb2009cd 100644 --- a/builds/compromise.mjs +++ b/builds/compromise.mjs @@ -1,4 +1,4 @@ -/* compromise 13.3.2 MIT */ +/* compromise 13.4.0 MIT */ function _typeof(obj) { "@babel/helpers - typeof"; @@ -1271,6 +1271,10 @@ Term.prototype.clone = function () { var term = new Term(this.text); term.pre = this.pre; term.post = this.post; + term.clean = this.clean; + term.reduced = this.reduced; + term.root = this.root; + term.implicit = this.implicit; term.tags = Object.assign({}, this.tags); //use the old id, so it can be matched with .match(doc) // term.id = this.id @@ -1341,7 +1345,8 @@ var clone = function clone(isShallow) { var terms = this.terms(); var newTerms = terms.map(function (t) { return t.clone(); - }); //connect these new ids up + }); // console.log(newTerms) + //connect these new ids up newTerms.forEach(function (t, i) { //add it to the pool.. @@ -3429,7 +3434,7 @@ var fromJSON = function fromJSON(json, world) { var fromJSON_1 = fromJSON; -var _version = '13.3.2'; +var _version = '13.4.0'; var _data = { "Comparative": "true¦better", @@ -3439,14 +3444,14 @@ var _data = { "Noun": "true¦a5b4c2f1here,ie,lit,m0no doubt,pd,tce;a,d;t,y;a,ca,o0;l,rp;a,l;d,l,rc", "Copula": "true¦a1is,w0;as,ere;m,re", "PastTense": "true¦be3came,d2had,lied,meant,sa2taken,w0;as,e0;nt,re;id;en,gan", - "Condition": "true¦if,unless", + "Condition": "true¦if,lest,unless", "Gerund": "true¦accord0be0develop0go0result0stain0;ing", "Negative": "true¦n0;ever,o0;!n,t", "QuestionWord": "true¦how3wh0;at,e1ich,o0y;!m,se;n,re; come,'s", "Plural": "true¦records", "Conjunction": "true¦&,aEbAcuz,how8in caDno7o6p4supposing,t1vers5wh0yet;eth8ile;h0o;eref9o0;!uC;l0rovided that;us;r,therwi6; matt1r;!ev0;er;e0ut;cau1f0;ore;se;lthou1nd,s 0;far as,if;gh", "Pronoun": "true¦'em,elle,h4i3me,ourselves,she5th1us,we,you0;!rself;e0ou;m,y;!l,t;e0im;!'s", - "Singular": "true¦0:0X;1:10;a0Wb0Kc0Bd04e02fXgShOici1jel0kitty,lNmJnIoHpDquestion mark,rBs7t4u2womW;nc0Rs 2;doll0Dst0F; rex,a3h2ic,ragedy,v show;ere,i1;l0x return;ist0Pky,omeone,t2uper bowl,yst0W;ep3ri1u2;de0Pff;faMmoM;al0i1o2;om,se;a4i0Jl05r3u2;dLrpoD;erogaVobl0O;rt,te0I;bjSceGthers;othi1umb0E;a4ee04o2;del,m2nopo0th0C;!my;n,yf0;i0unch;ead start,o2;l0me3u2;se;! run;adf0entlem5irlZlaci04od,rand3u2;l0y; slam,fa2mo2;th01;an;a5ella,ly,ol0r3un2;di1;iTo2;ntiWsN;mi0thV;conomy,gg,ner5veWx2;ampQecu7;ad7e4innSo2ragonf0ude;cumentFg2i0l0or;gy;ath,t2;ec2;tive;!dy;a8eili1h6i4o2redit card;ttage,u2;riJsin;ty,vil w2;ar;andeliGocol2;ate;n2rD;ary;aAel0lesHo6r4u2;n2tterf0;ti1;eakfast,o2;!th8;dy,tt4y2;!fri2;end;le;nki1r2;ri2;er;d4l0noma0u2;nt;ly; homin4verti2;si1;ng;em", + "Singular": "true¦0:0Z;1:12;a0Yb0Mc0Dd06e04fZgUhQiPjel0kitty,lOmKnJoIpEquestion mark,rCs7t4u2womY;nc0Ts 2;doll0Fst0H; rex,a3h2ic,ragedy,v show;ere,i1;l0x return;i5ky,omeone,t2uper bowl,yst0Y;ep3ri1u2;de0Rff;faOmoO;st0Nze;al0i1o2;om,se;a4i0Kl06r3u2;dMrpoE;erogaWobl0P;rt,te0J;bjTceHthers;othi1umb0F;a4ee05o2;del,m2nopo0th0D;!my;n,yf0;i0unch;ci1nsect;ead start,o2;l0me3u2;se;! run;adf0entlem5irlZlaci04od,rand3u2;l0y; slam,fa2mo2;th01;an;a5ella,ly,ol0r3un2;di1;iTo2;ntiWsN;mi0thV;conomy,gg,ner5veWx2;ampQecu7;ad7e4innSo2ragonf0ude;cumentFg2i0l0or;gy;ath,t2;ec2;tive;!dy;a8eili1h6i4o2redit card;ttage,u2;riJsin;ty,vil w2;ar;andeliGocol2;ate;n2rD;ary;aAel0lesHo6r4u2;n2tterf0;ti1;eakfast,o2;!th8;dy,tt4y2;!fri2;end;le;nki1r2;ri2;er;d4l0noma0u2;nt;ly; homin4verti2;si1;ng;em", "Actor": "true¦aJbGcFdCengineIfAgardenIh9instructPjournalLlawyIm8nurse,opeOp5r3s1t0;echnCherapK;ailNcientJoldiGu0;pervKrgeon;e0oofE;ceptionGsearC;hotographClumbColi1r0sychologF;actitionBogrammB;cem6t5;echanic,inist9us4;airdress8ousekeep8;arm7ire0;fight6m2;eputy,iet0;ici0;an;arpent2lerk;ricklay1ut0;ch0;er;ccoun6d2ge7r0ssis6ttenda7;chitect,t0;ist;minist1v0;is1;rat0;or;ta0;nt", "Honorific": "true¦a03b00cSdReQfiLgKhon,jr,king,lJmEoDp8queen,r4s0taoiseach,vice7;e1fc,gt,ir,r,u0;ltTpt,rg;c0nDrgeaL;ond liJretary;abbi,e0;ar1pAs,v0;!erend; admirY;astPhd,r0vt;esideEi1of0;!essN;me mini5nce0;!ss;fficOp,rd;a3essrs,i2lle,me,r1s0;!tr;!s;stK;gistrate,j,r6yF;i3lb,t;en,ov;eld mar3rst l0;ady,i0;eutena0;nt;shG;sq,xcellency;et,oct6r,utchess;apt6hance4mdr,o0pl;lonel,m2ngress0unci3;m0wom0;an;dr,mand5;ll0;or;!ain;ldg,rig0;!adi0;er;d0sst,tty,yatullah;j,m0v;!ir0;al", "SportsTeam": "true¦0:1A;1:1H;2:1G;a1Eb16c0Td0Kfc dallas,g0Ihouston 0Hindiana0Gjacksonville jagua0k0El0Bm01newToQpJqueens parkIreal salt lake,sAt5utah jazz,vancouver whitecaps,w3yW;ashington 3est ham0Rh10;natio1Oredski2wizar0W;ampa bay 6e5o3;ronto 3ttenham hotspur;blue ja0Mrapto0;nnessee tita2xasC;buccanee0ra0K;a7eattle 5heffield0Kporting kansas0Wt3;. louis 3oke0V;c1Frams;marine0s3;eah15ounG;cramento Rn 3;antonio spu0diego 3francisco gJjose earthquak1;char08paA; ran07;a8h5ittsburgh 4ortland t3;imbe0rail blaze0;pirat1steele0;il3oenix su2;adelphia 3li1;eagl1philNunE;dr1;akland 3klahoma city thunder,rlando magic;athle0Mrai3;de0; 3castle01;england 7orleans 6york 3;city fc,g4je0FknXme0Fred bul0Yy3;anke1;ian0D;pelica2sain0C;patrio0Brevolut3;ion;anchester Be9i3ontreal impact;ami 7lwaukee b6nnesota 3;t4u0Fvi3;kings;imberwolv1wi2;rewe0uc0K;dolphi2heat,marli2;mphis grizz3ts;li1;cXu08;a4eicesterVos angeles 3;clippe0dodDla9; galaxy,ke0;ansas city 3nE;chiefs,roya0E; pace0polis colU;astr06dynamo,rockeTtexa2;olden state warrio0reen bay pac3;ke0;.c.Aallas 7e3i05od5;nver 5troit 3;lio2pisto2ti3;ge0;broncZnuggeM;cowbo4maver3;ic00;ys; uQ;arCelKh8incinnati 6leveland 5ol3;orado r3umbus crew sc;api5ocki1;brow2cavalie0india2;bengaWre3;ds;arlotte horAicago 3;b4cubs,fire,wh3;iteB;ea0ulR;diff3olina panthe0; c3;ity;altimore 9lackburn rove0oston 5rooklyn 3uffalo bilN;ne3;ts;cel4red3; sox;tics;rs;oriol1rave2;rizona Ast8tlanta 3;brav1falco2h4u3;nited;aw9;ns;es;on villa,r3;os;c5di3;amondbac3;ks;ardi3;na3;ls", @@ -3458,14 +3463,14 @@ var _data = { "Possessive": "true¦anyAh5its,m3noCo1sometBthe0yo1;ir1mselves;ur0;!s;i8y0;!se4;er1i0;mse2s;!s0;!e0;lf;o1t0;hing;ne", "Currency": "true¦$,aud,bScQdLeurKfJgbp,hkd,iIjpy,kGlEp8r7s3usd,x2y1z0¢,£,¥,ден,лв,руб,฿,₡,₨,€,₭,﷼;lotySł;en,uanR;af,of;h0t5;e0il5;k0q0;elM;iel,oubleLp,upeeL;e2ound st0;er0;lingI;n0soH;ceGn0;ies,y;e0i8;i,mpi7;n,r0wanzaCyatC;!onaBw;ls,nr;ori7ranc9;!o8;en3i2kk,o0;b0ll2;ra5;me4n0rham4;ar3;ad,e0ny;nt1;aht,itcoin0;!s", "City": "true¦a2Wb26c1Wd1Re1Qf1Og1Ih1Ai18jakar2Hk0Zl0Tm0Gn0Co0ApZquiYrVsLtCuBv8w3y1z0;agreb,uri1Z;ang1Te0okohama;katerin1Hrev34;ars3e2i0rocl3;ckl0Vn0;nipeg,terth0W;llingt1Oxford;aw;a1i0;en2Hlni2Z;lenc2Uncouv0Gr2G;lan bat0Dtrecht;a6bilisi,e5he4i3o2rondheim,u0;nVr0;in,ku;kyo,ronIulouC;anj23l13miso2Jra2A; haJssaloni0X;gucigalpa,hr2Ol av0L;i0llinn,mpe2Bngi07rtu;chu22n2MpT;a3e2h1kopje,t0ydney;ockholm,uttga12;angh1Fenzh1X;o0KvZ;int peters0Ul3n0ppo1F; 0ti1B;jo0salv2;se;v0z0Q;adU;eykjavik,i1o0;me,sario,t25;ga,o de janei17;to;a8e6h5i4o2r0ueb1Qyongya1N;a0etor24;gue;rt0zn24; elizabe3o;ls1Grae24;iladelph1Znom pe07oenix;r0tah tik19;th;lerJr0tr10;is;dessa,s0ttawa;a1Hlo;a2ew 0is;delTtaip0york;ei;goya,nt0Upl0Uv1R;a5e4i3o1u0;mb0Lni0I;nt0scH;evideo,real;l1Mn01skolc;dellín,lbour0S;drid,l5n3r0;ib1se0;ille;or;chest0dalWi0Z;er;mo;a4i1o0vAy01;nd00s angel0F;ege,ma0nz,sbZverpo1;!ss0;ol; pla0Iusan0F;a5hark4i3laipeda,o1rak0uala lump2;ow;be,pavog0sice;ur;ev,ng8;iv;b3mpa0Kndy,ohsiu0Hra0un03;c0j;hi;ncheMstanb0̇zmir;ul;a5e3o0; chi mi1ms,u0;stI;nh;lsin0rakliG;ki;ifa,m0noi,va0A;bu0SiltD;alw4dan3en2hent,iza,othen1raz,ua0;dalaj0Gngzhou;bu0P;eUoa;sk;ay;es,rankfu0;rt;dmont4indhovU;a1ha01oha,u0;blRrb0Eshanbe;e0kar,masc0FugavpiJ;gu,je0;on;a7ebu,h2o0raioJuriti01;lo0nstanJpenhagNrk;gFmbo;enn3i1ristchur0;ch;ang m1c0ttagoL;ago;ai;i0lgary,pe town,rac4;ro;aHeBirminghWogoAr5u0;char3dap3enos air2r0sZ;g0sa;as;es;est;a2isba1usse0;ls;ne;silPtisla0;va;ta;i3lgrade,r0;g1l0n;in;en;ji0rut;ng;ku,n3r0sel;celo1ranquil0;la;na;g1ja lu0;ka;alo0kok;re;aBb9hmedabad,l7m4n2qa1sh0thens,uckland;dod,gabat;ba;k0twerp;ara;m5s0;terd0;am;exandr0maty;ia;idj0u dhabi;an;lbo1rh0;us;rg", - "Abbreviation": "true¦a0Tb0Qc0Kd0Ie0Ff0Cg0Ah08i06j04k02l00mRnOoNpIqHrFs9t6u5v2w0yb,µg;is0r,y0L;!c;a,b,e1i0ol,s,t;tro,vo;r,t;niv,safa,t;b1ce,d,e0sp;l,mp,nn,x;!l,sp;ask,e3fc,gt,i2q1r,s,t,u0;pt,rg;! ft;r,tu;c,nVp0;!t;b,d,e0;pSs,v;t,ue;a,d,enn3hd,l,p,r1s0t,vt;!a,eud;ef,o0;b,f,n;!a;ct,kla,nt,p,rd,z;e0ov;b0e;!r;a7b,d,essrs,g,i4l3m2p1rHs0t;!tr;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al3yemTz2;a24imbabwe;es,lis and futu2X;a2enezue31ietnam;nuatu,tican city;.5gTkraiZnited 3ruXs2zbeE;a,sr;arab emirat0Kkingdom,states2;! of am2X;k.,s.2; 27a.;a7haBimor-les0Bo6rinidad4u2;nis0rk2valu;ey,me2Xs and caic1T; and 2-2;toba1J;go,kel0Ynga;iw2Vji2nz2R;ki2T;aCcotl1eBi8lov7o5pa2Bri lanka,u4w2yr0;az2ed9itzerl1;il1;d2Qriname;lomon1Vmal0uth 2;afr2IkLsud2O;ak0en0;erra leoEn2;gapo1Wt maart2;en;negKrb0ychellY;int 2moa,n marino,udi arab0;hele24luc0mart1Z;epublic of ir0Com2Cuss0w2;an25;a3eHhilippinTitcairn1Ko2uerto riM;l1rtugE;ki2Bl3nama,pua new0Tra2;gu6;au,esti2;ne;aAe8i6or2;folk1Gth3w2;ay; k2ern mariana1B;or0M;caragua,ger2ue;!ia;p2ther18w zeal1;al;mib0u2;ru;a6exi5icro09o2yanm04;ldova,n2roc4zamb9;a3gol0t2;enegro,serrat;co;c9dagascZl6r4urit3yot2;te;an0i14;shall0Vtin2;ique;a3div2i,ta;es;wi,ys0;ao,ed00;a5e4i2uxembourg;b2echtenste10thu1E;er0ya;ban0Gsotho;os,tv0;azakh1De2iriba02osovo,uwait,yrgyz1D;eling0Jnya;a2erF;ma15p1B;c6nd5r3s2taly,vory coast;le of m19rael;a2el1;n,q;ia,oI;el1;aiSon2ungary;dur0Mg kong;aAermany,ha0Pibralt9re7u2;a5ern4inea2ya0O;!-biss2;au;sey;deloupe,m,tema0P;e2na0M;ce,nl1;ar;bTmb0;a6i5r2;ance,ench 2;guia0Dpoly2;nes0;ji,nl1;lklandTroeT;ast tim6cu5gypt,l salv5ngl1quatorial3ritr4st2thiop0;on0; guin2;ea;ad2;or;enmark,jibou4ominica3r con2;go;!n B;ti;aAentral african 9h7o4roat0u3yprQzech2; 8ia;ba,racao;c3lo2morPngo-brazzaville,okFsta r03te d'ivoiK;mb0;osD;i2ristmasF;le,na;republic;m2naTpe verde,yman9;bod0ero2;on;aFeChut00o8r4u2;lgar0r2;kina faso,ma,undi;azil,itish 2unei;virgin2; is2;lands;liv0nai4snia and herzegoviGtswaGuvet2; isl1;and;re;l2n7rmuF;ar2gium,ize;us;h3ngladesh,rbad2;os;am3ra2;in;as;fghaFlCmAn5r3ustr2zerbaijH;al0ia;genti2men0uba;na;dorra,g4t2;arct6igua and barbu2;da;o2uil2;la;er2;ica;b2ger0;an0;ia;ni2;st2;an", "Region": "true¦0:1U;a20b1Sc1Id1Des1Cf19g13h10i0Xj0Vk0Tl0Qm0FnZoXpSqPrMsDtAut9v6w3y1zacatec22;o05u1;cat18kZ;a1est vi4isconsin,yomi14;rwick0shington1;! dc;er2i1;rgin1S;acruz,mont;ah,tar pradesh;a2e1laxca1DuscaA;nnessee,x1R;bas0Kmaulip1QsmJ;a6i4o2taf0Ou1ylh13;ffVrr00s0Y;me10no1Auth 1;cSdR;ber1Ic1naloa;hu0Sily;n2skatchew0Rxo1;ny; luis potosi,ta catari1I;a1hode7;j1ngp02;asth0Mshahi;inghai,u1;e1intana roo;bec,ensWreta0E;ara4e2rince edward1; isU;i,nnsylv1rnambu02;an14;!na;axa0Ndisha,h1klaho1Bntar1reg4x04;io;ayarit,eBo3u1;evo le1nav0L;on;r1tt0Rva scot0X;f6mandy,th1; 1ampton0;c3d2yo1;rk0;ako0Y;aroli0V;olk;bras0Xva01w1; 2foundland1;! and labrador;brunswick,hamp0jers1mexiJyork state;ey;a6i2o1;nta0Nrelos;ch3dlanBn2ss1;issippi,ouri;as geraGneso0M;igQoacQ;dhya,harasht04ine,ni3r1ssachusetts;anhao,y1;land;p1toba;ur;anca0e1incoln0ouis8;e1iH;ds;a1entucky,hul0A;ns08rnata0Dshmir;alis1iangxi;co;daho,llino2nd1owa;ia05;is;a2ert1idalEunA;ford0;mp0waii;ansu,eorgWlou5u1;an2erre1izhou,jarat;ro;ajuato,gdo1;ng;cester0;lori2uji1;an;da;sex;e4o2uran1;go;rs1;et;lawaErby0;a8ea7hi6o1umbrH;ahui4l3nnectic2rsi1ventry;ca;ut;iMorado;la;apEhuahua;ra;l8m1;bridge0peche;a5r4uck1;ingham0;shi1;re;emen,itish columb3;h2ja cal1sque,var2;iforn1;ia;guascalientes,l4r1;izo2kans1;as;na;a2ber1;ta;ba2s1;ka;ma", "FemaleName": "true¦0:FY;1:G2;2:FR;3:FD;4:FC;5:FS;6:ER;7:EP;8:GF;9:EZ;A:GB;B:E5;C:G8;D:FO;E:FL;F:EG;aE2bD4cB8dAIe9Gf91g8Hh83i7Sj6Uk60l4Om38n2To2Qp2Fqu2Er1Os0Qt04ursu6vUwOyLzG;aJeHoG;e,la,ra;lGna;da,ma;da,ra;as7EeHol1TvG;et7onB9;le0sen3;an9endBNhiB4iG;lInG;if3AniGo0;e,f39;a,helmi0lGma;a,ow;aMeJiG;cHviG;an9XenG1;kCZtor3;da,l8Vnus,rG;a,nGoniD2;a,iDC;leGnesEC;nDLrG;i1y;aSePhNiMoJrGu6y4;acG3iGu0E;c3na,sG;h9Mta;nHrG;a,i;i9Jya;a5IffaCGna,s5;al3eGomasi0;a,l8Go6Xres1;g7Uo6WrHssG;!a,ie;eFi,ri8;bNliMmKnIrHs5tGwa0;ia0um;a,yn;iGya;a,ka,s5;a4e4iGmCAra;!ka;a,t5;at5it5;a05carlet2Ye04hUiSkye,oQtMuHyG;bFJlvi1;e,sHzG;an2Tet7ie,y;anGi8;!a,e,nG;aEe;aIeG;fGl3DphG;an2;cF8r6;f3nGphi1;d4ia,ja,ya;er4lv3mon1nGobh75;dy;aKeGirlBLo0y6;ba,e0i6lIrG;iGrBPyl;!d70;ia,lBV;ki4nIrHu0w0yG;la,na;i,leAon,ron;a,da,ia,nGon;a,on;l5Yre0;bMdLi9lKmIndHrGs5vannaE;aEi0;ra,y;aGi4;nt5ra;lBNome;e,ie;in1ri0;a02eXhViToHuG;by,thBK;bQcPlOnNsHwe0xG;an94ie,y;aHeGie,lC;ann8ll1marBFtB;!lGnn1;iGyn;e,nG;a,d7W;da,i,na;an9;hel53io;bin,erByn;a,cGkki,na,ta;helBZki;ea,iannDXoG;da,n12;an0bIgi0i0nGta,y0;aGee;!e,ta;a,eG;cARkaE;chGe,i0mo0n5EquCDvDy0;aCCelGi9;!e,le;een2ia0;aMeLhJoIrG;iGudenAW;scil1Uyamva9;lly,rt3;ilome0oebe,ylG;is,lis;arl,ggy,nelope,r6t4;ige,m0Fn4Oo6rvaBBtHulG;a,et7in1;ricGsy,tA8;a,e,ia;ctav3deHfAWlGphAW;a,ga,iv3;l3t7;aQePiJoGy6;eHrG;aEeDma;ll1mi;aKcIkGla,na,s5ta;iGki;!ta;hoB2k8BolG;a,eBH;!mh;l7Tna,risF;dIi5PnHo23taG;li1s5;cy,et7;eAiCO;a01ckenz2eViLoIrignayani,uriBGyG;a,rG;a,na,tAS;i4ll9XnG;a,iG;ca,ka,qB4;a,chOkaNlJmi,nIrGtzi;aGiam;!n9;a,dy,erva,h,n2;a,dIi9JlG;iGy;cent,e;red;!e6;ae6el3G;ag4KgKi,lHrG;edi61isFyl;an2iGliF;nGsAM;a,da;!an,han;b08c9Ed06e,g04i03l01nZrKtJuHv6Sx87yGz2;a,bell,ra;de,rG;a,eD;h75il9t2;a,cSgOiJjor2l6In2s5tIyG;!aGbe5QjaAlou;m,n9S;a,ha,i0;!aIbALeHja,lCna,sGt53;!a,ol,sa;!l06;!h,m,nG;!a,e,n1;arIeHie,oGr3Kueri7;!t;!ry;et3IiB;elGi61y;a,l1;dGon,ue6;akranBy;iGlo36;a,ka,n9;a,re,s2;daGg2;!l2W;alCd2elGge,isBGon0;eiAin1yn;el,le;a0Ie08iWoQuKyG;d3la,nG;!a,dHe9SnGsAQ;!a,e9R;a,sAO;aB1cJelIiFlHna,pGz;e,iB;a,u;a,la;iGy;a2Ae,l25n9;is,l1GrHtt2uG;el6is1;aIeHi8na,rG;a6Zi8;lei,n1tB;!in1;aQbPd3lLnIsHv3zG;!a,be4Ket7z2;a,et7;a,dG;a,sGy;ay,ey,i,y;a,iaIlG;iGy;a8Ge;!n4F;b7Terty;!n5R;aNda,e0iLla,nKoIslARtGx2;iGt2;c3t3;la,nGra;a,ie,o4;a,or1;a,gh,laG;!ni;!h,nG;a,d4e,n4N;cNdon7Si6kes5na,rMtKurIvHxGy6;mi;ern1in3;a,eGie,yn;l,n;as5is5oG;nya,ya;a,isF;ey,ie,y;aZeUhadija,iMoLrIyG;lGra;a,ee,ie;istGy5B;a,en,iGy;!e,n48;ri,urtn9A;aMerLl99mIrGzzy;a,stG;en,in;!berlG;eGi,y;e,y;a,stD;!na,ra;el6PiJlInHrG;a,i,ri;d4na;ey,i,l9Qs2y;ra,s5;c8Wi5XlOma6nyakumari,rMss5LtJviByG;!e,lG;a,eG;e,i78;a5EeHhGi3PlCri0y;ar5Cer5Cie,leDr9Fy;!lyn73;a,en,iGl4Uyn;!ma,n31sF;ei72i,l2;a04eVilToMuG;anKdJliGst56;aHeGsF;!nAt0W;!n8X;i2Ry;a,iB;!anLcelCd5Vel71han6IlJni,sHva0yG;a,ce;eGie;fi0lCph4X;eGie;en,n1;!a,e,n36;!i10lG;!i0Z;anLle0nIrHsG;i5Qsi5Q;i,ri;!a,el6Pif1RnG;a,et7iGy;!e,f1P;a,e72iHnG;a,e71iG;e,n1;cLd1mi,nHqueliAsmin2Uvie4yAzG;min8;a8eHiG;ce,e,n1s;!lGsFt06;e,le;inHk2lCquelG;in1yn;da,ta;lPmNnMo0rLsHvaG;!na;aHiGob6U;do4;!belGdo4;!a,e,l2G;en1i0ma;a,di4es,gr5R;el9ogG;en1;a,eAia0o0se;aNeKilHoGyacin1N;ll2rten1H;aHdGlaH;a,egard;ry;ath0WiHlGnrietBrmiAst0W;en24ga;di;il75lKnJrGtt2yl75z6D;iGmo4Fri4G;etG;!te;aEnaE;ey,l2;aYeTiOlMold12rIwG;enGyne18;!dolC;acHetGisel9;a,chD;e,ieG;!la;adys,enGor3yn1Y;a,da,na;aJgi,lHna,ov71selG;a,e,le;da,liG;an;!n0;mYnIorgHrG;ald35i,m2Stru73;et7i5T;a,eGna;s1Nvieve;briel3Fil,le,rnet,yle;aReOio0loMrG;anHe9iG;da,e9;!cG;esHiGoi0G;n1s3V;!ca;!rG;a,en43;lHrnG;!an9;ec3ic3;rHtiGy8;ma;ah,rah;d0FileDkBl00mUn4ArRsMtLuKvG;aIelHiG;e,ta;in0Ayn;!ngel2H;geni1la,ni3R;h52ta;meral9peranJtG;eHhGrel6;er;l2Pr;za;iGma,nest29yn;cGka,n;a,ka;eJilImG;aGie,y;!liA;ee,i1y;lGrald;da,y;aTeRiMlLma,no4oJsIvG;a,iG;na,ra;a,ie;iGuiG;se;a,en,ie,y;a0c3da,nJsGzaH;aGe;!beG;th;!a,or;anor,nG;!a;in1na;en,iGna,wi0;e,th;aWeKiJoGul2U;lor51miniq3Yn30rGtt2;a,eDis,la,othGthy;ea,y;an09naEonAx2;anPbOde,eNiLja,lImetr3nGsir4U;a,iG;ce,se;a,iHla,orGphiA;es,is;a,l5J;dGrdG;re;!d4Mna;!b2CoraEra;a,d4nG;!a,e;hl3i0mMnKphn1rHvi1WyG;le,na;a,by,cHia,lG;a,en1;ey,ie;a,et7iG;!ca,el1Aka;arGia;is;a0Qe0Mh04i02lUoJrHynG;di,th3;istGy04;al,i0;lOnLrHurG;tn1D;aId28iGn28riA;!nG;a,e,n1;!l1S;n2sG;tanGuelo;ce,za;eGleD;en,t7;aIeoHotG;il4B;!pat4;ir8rIudG;et7iG;a,ne;a,e,iG;ce,sX;a4er4ndG;i,y;aPeMloe,rG;isHyG;stal;sy,tG;aHen,iGy;!an1e,n1;!l;lseHrG;!i8yl;a,y;nLrG;isJlHmG;aiA;a,eGot7;n1t7;!sa;d4el1PtG;al,el1O;cHlG;es7i3F;el3ilG;e,ia,y;iYlXmilWndVrNsLtGy6;aJeIhGri0;erGleDrCy;in1;ri0;li0ri0;a2GsG;a2Fie;a,iMlKmeIolHrG;ie,ol;!e,in1yn;lGn;!a,la;a,eGie,y;ne,y;na,sF;a0Di0D;a,e,l1;isBl2;tlG;in,yn;arb0CeYianXlVoTrG;andRePiIoHyG;an0nn;nwCok8;an2NdgKg0ItG;n27tG;!aHnG;ey,i,y;ny;etG;!t8;an0e,nG;da,na;i8y;bbi8nG;iBn2;ancGossom,ythe;a,he;ca;aRcky,lin9niBrNssMtIulaEvG;!erlG;ey,y;hHsy,tG;e,i0Zy8;!anG;ie,y;!ie;nGt5yl;adHiG;ce;et7iA;!triG;ce,z;a4ie,ra;aliy29b24d1Lg1Hi19l0Sm0Nn01rWsNthe0uJvIyG;anGes5;a,na;a,r25;drIgusHrG;el3;ti0;a,ey,i,y;hHtrG;id;aKlGt1P;eHi8yG;!n;e,iGy;gh;!nG;ti;iIleHpiB;ta;en,n1t7;an19elG;le;aYdWeUgQiOja,nHtoGya;inet7n3;!aJeHiGmI;e,ka;!mGt7;ar2;!belHliFmT;sa;!le;ka,sGta;a,sa;elGie;a,iG;a,ca,n1qG;ue;!t7;te;je6rea;la;!bHmGstas3;ar3;el;aIberHel3iGy;e,na;!ly;l3n9;da;aTba,eNiKlIma,yG;a,c3sG;a,on,sa;iGys0J;e,s0I;a,cHna,sGza;a,ha,on,sa;e,ia;c3is5jaIna,ssaIxG;aGia;!nd4;nd4;ra;ia;i0nHyG;ah,na;a,is,naE;c5da,leDmLnslKsG;haElG;inGyW;g,n;!h;ey;ee;en;at5g2nG;es;ie;ha;aVdiSelLrG;eIiG;anLenG;a,e,ne;an0;na;aKeJiHyG;nn;a,n1;a,e;!ne;!iG;de;e,lCsG;on;yn;!lG;iAyn;ne;agaJbHiG;!gaI;ey,i8y;!e;il;ah", "Place": "true¦a07b05cZdYeXfVgRhQiOjfk,kMlKmHneEoDp9que,rd,s8t5u4v3w0yyz;is1y0;!o;!c;a,t;pYsafa,t;e1he 0;bronx,hamptons;nn,x;ask,fo,oho,t,under6yd;a2e1h0;l,x;k,nnK;!cifX;kla,nt;b1w eng0;land;!r;a1co,i0t,uc;dKnn;libu,nhattS;a0gw,hr;s,x;an0ul;!s;a0cn,da,ndianMst;!x;arlem,kg,nd,wy;a2re0;at 0enwich;britain,lak6;!y village;co,l0ra;!a;urope,verglad2;ak,en,fw,ist,own4xb;al4dg,gk,hina3l2o1r0t;es;lo,nn;!t;town;!if;cn,e0kk,lvd,rooklyn;l air,verly hills;frica,lta,m5ntarct2r1sia,tl0ve;!ant1;ct0iz;ic0; oce0;an;ericas,s", "WeekDay": "true¦fri2mon2s1t0wednesd3;hurs1ues1;aturd1und1;!d0;ay0;!s", "Month": "true¦aBdec9feb7j2mar,nov9oct1sep0;!t8;!o8;an3u0;l1n0;!e;!y;!u1;!ru0;ary;!em0;ber;pr1ug0;!ust;!il", - "Date": "true¦t0weekend,yesterd2;mr2o0;d0morrow;ay;!w", + "Date": "true¦ago,t0weekend,yesterd2;mr2o0;d0morrow;ay;!w", "FirstName": "true¦aEblair,cCdevBj8k6lashawn,m3nelly,quinn,re2sh0;ay,e0iloh;a,lby;g1ne;ar1el,org0;an;ion,lo;as8e0r9;ls7nyatta,rry;am0ess1ude;ie,m0;ie;an,on;as0heyenne;ey,sidy;lex1ndra,ubr0;ey;is", "LastName": "true¦0:34;1:3B;2:39;3:2Y;4:2E;5:30;a3Bb31c2Od2Ee2Bf25g1Zh1Pi1Kj1Ek17l0Zm0Nn0Jo0Gp05rYsMtHvFwCxBy8zh6;a6ou,u;ng,o;a6eun2Uoshi1Kun;ma6ng;da,guc1Zmo27sh21zaR;iao,u;a7eb0il6o3right,u;li3Bs2;gn0lk0ng,tanabe;a6ivaldi;ssilj37zqu1;a9h8i2Go7r6sui,urn0;an,ynisJ;lst0Prr1Uth;at1Uomps2;kah0Vnaka,ylor;aEchDeChimizu,iBmiAo9t7u6zabo;ar1lliv2AzuE;a6ein0;l23rm0;sa,u3;rn4th;lva,mmo24ngh;mjon4rrano;midt,neid0ulz;ito,n7sa6to;ki;ch1dLtos,z;amBeag1Zi9o7u6;bio,iz,sD;b6dri1MgIj0Tme24osevelt,ssi,ux;erts,ins2;c6ve0F;ci,hards2;ir1os;aEeAh8ic6ow20ut1N;as6hl0;so;a6illips;m,n1T;ders5et8r7t6;e0Nr4;ez,ry;ers;h21rk0t6vl4;el,te0J;baBg0Blivei01r6;t6w1O;ega,iz;a6eils2guy5ix2owak,ym1E;gy,ka6var1K;ji6muW;ma;aEeCiBo8u6;ll0n6rr0Bssolini,ñ6;oz;lina,oKr6zart;al0Me6r0U;au,no;hhail4ll0;rci0ssi6y0;!er;eWmmad4r6tsu07;in6tin1;!o;aCe8i6op1uo;!n6u;coln,dholm;fe7n0Qr6w0J;oy;bv6v6;re;mmy,rs5u;aBennedy,imuAle0Lo8u7wo6;k,n;mar,znets4;bay6vacs;asY;ra;hn,rl9to,ur,zl4;aAen9ha3imen1o6u3;h6nYu3;an6ns2;ss2;ki0Es5;cks2nsse0D;glesi9ke8noue,shik7to,vano6;u,v;awa;da;as;aBe8itchcock,o7u6;!a3b0ghNynh;a3ffmann,rvat;mingw7nde6rN;rs2;ay;ns5rrQs7y6;asDes;an4hi6;moJ;a9il,o8r7u6;o,tierr1;ayli3ub0;m1nzal1;nd6o,rcia;hi;erAis9lor8o7uj6;ita;st0urni0;es;ch0;nand1;d7insteHsposi6vaL;to;is2wards;aCeBi9omin8u6;bo6rand;is;gu1;az,mitr4;ov;lgado,vi;nkula,rw7vi6;es,s;in;aFhBlarkAo6;h5l6op0rbyn,x;em7li6;ns;an;!e;an8e7iu,o6ristens5u3we;i,ng,u3w,y;!n,on6u3;!g;mpb7rt0st6;ro;ell;aBe8ha3lanco,oyko,r6yrne;ooks,yant;ng;ck7ethov5nnett;en;er,ham;ch,h8iley,rn6;es,i0;er;k,ng;dDl9nd6;ers6rA;en,on,s2;on;eks7iy8var1;ez;ej6;ev;ams", "MaleName": "true¦0:CE;1:BL;2:C2;3:BT;4:B5;5:BZ;6:AT;7:9V;8:BD;9:AX;A:AO;aB4bA8c97d87e7Gf6Yg6Gh5Wi5Ij4Lk4Bl3Rm2Pn2Eo28p22qu20r1As0Qt06u05v00wNxavi3yGzB;aBor0;cBh8Ine;hCkB;!aB1;ar51eB0;ass2i,oCuB;sDu25;nEsDusB;oBsC;uf;ef;at0g;aJeHiCoByaAP;lfgang,odrow;lBn1O;bDey,frBJlB;aA5iB;am,e,s;e89ur;i,nde7sB;!l6t1;de,lCrr5yB;l1ne;lBt3;a93y;aEern1iBladimir;cCha0kt5CnceBrg9Bva0;!nt;ente,t5A;lentin49n8Yughn;lyss4Msm0;aTeOhKiIoErCyB;!l3ro8s1;av9QeBist0oy,um0;nt9Iv54y;bDd7XmBny;!as,mBoharu;aAYie,y;i83y;mBt9;!my,othy;adDeoCia7DomB;!as;!do7M;!de9;dErB;en8HrB;an8GeBy;ll,n8F;!dy;dgh,ic9Tnn3req,ts45;aRcotPeNhJiHoFpenc3tBur1Oylve8Hzym1;anDeBua7B;f0phAFvBwa7A;e57ie;!islaw,l6;lom1nA3uB;leyma8ta;dBl7Jm1;!n6;aDeB;lBrm0;d1t1;h6Sne,qu0Uun,wn,y8;aBbasti0k1Xl41rg40th,ymo9I;m9n;!tB;!ie,y;lCmBnti21q4Iul;!mAu4;ik,vato6V;aWeShe92iOoFuCyB;an,ou;b6LdCf9pe6QssB;!elAI;ol2Uy;an,bIcHdGel,geFh0landA9mEnDry,sCyB;!ce;coe,s;!a95nA;an,eo;l3Jr;e4Qg3n6olfo,ri68;co,ky;bAe9U;cBl6;ar5Oc5NhCkBo;!ey,ie,y;a85ie;gCid,ub5x,yBza;ansh,nS;g8WiB;na8Ss;ch5Yfa4lDmCndBpha4sh6Uul,ymo70;al9Yol2By;i9Ion;f,ph;ent2inB;cy,t1;aFeDhilCier62ol,reB;st1;!ip,lip;d9Brcy,tB;ar,e2V;b3Sdra6Ft44ul;ctav2Vliv3m96rFsCtBum8Uw5;is,to;aCc8SvB;al52;ma;i,l49vJ;athJeHiDoB;aBel,l0ma0r2X;h,m;cCg4i3IkB;h6Uola;hol5XkBol5X;!ol5W;al,d,il,ls1vB;il50;anBy;!a4i4;aWeTiKoFuCyB;l21r1;hamCr5ZstaB;fa,p4G;ed,mF;dibo,e,hamDis1XntCsBussa;es,he;e,y;ad,ed,mB;ad,ed;cGgu4kElDnCtchB;!e7;a78ik;house,o03t1;e,olB;aj;ah,hBk6;a4eB;al,l;hClv2rB;le,ri7v2;di,met;ck,hNlLmOnu4rHs1tDuricCxB;!imilian8Cwe7;e,io;eo,hCi52tB;!eo,hew,ia;eBis;us,w;cDio,k86lCqu6Gsha7tBv2;i2Hy;in,on;!el,oKus;achBcolm,ik;ai,y;amBdi,moud;adB;ou;aReNiMlo2RoIuCyB;le,nd1;cEiDkBth3;aBe;!s;gi,s;as,iaB;no;g0nn6RrenDuBwe7;!iB;e,s;!zo;am,on4;a7Bevi,la4SnDoBst3vi;!nB;!a60el;!ny;mCnBr67ur4Twr4T;ce,d1;ar,o4N;aIeDhaled,iBrist4Vu48y3B;er0p,rB;by,k,ollos;en0iEnBrmit,v2;!dCnBt5C;e0Yy;a7ri4N;r,th;na68rBthem;im,l;aYeQiOoDuB;an,liBst2;an,o,us;aqu2eJhnInGrEsB;eChBi7Bue;!ua;!ph;dBge;an,i,on;!aBny;h,s,th4X;!ath4Wie,nA;!l,sBy;ph;an,e,mB;!mA;d,ffGrDsB;sBus;!e;a5JemCmai8oBry;me,ni0O;i6Uy;!e58rB;ey,y;cHd5kGmFrDsCvi3yB;!d5s1;on,p3;ed,od,rBv4M;e4Zod;al,es,is1;e,ob,ub;k,ob,quB;es;aNbrahMchika,gKkeJlija,nuIrGsDtBv0;ai,sB;uki;aBha0i6Fma4sac;ac,iaB;h,s;a,vinBw2;!g;k,nngu52;!r;nacBor;io;im;in,n;aJeFina4VoDuByd56;be25gBmber4CsD;h,o;m3ra33sBwa3X;se2;aDctCitCn4ErB;be20m0;or;th;bKlJmza,nIo,rDsCyB;a43d5;an,s0;lEo4FrDuBv6;hi40ki,tB;a,o;is1y;an,ey;k,s;!im;ib;aQeMiLlenKoIrEuB;illerCsB;!tavo;mo;aDegBov3;!g,orB;io,y;dy,h57nt;nzaBrd1;lo;!n;lbe4Qno,ovan4R;ne,oDrB;aBry;ld,rd4U;ffr6rge;bri4l5rBv2;la1Zr3Eth,y;aReNiLlJorr0IrB;anDedBitz;!dAeBri24;ri23;cDkB;!ie,lB;in,yn;esJisB;!co,zek;etch3oB;yd;d4lBonn;ip;deriDliCng,rnB;an01;pe,x;co;bi0di;arZdUfrTit0lNmGnFo2rCsteb0th0uge8vBym5zra;an,ere2V;gi,iCnBrol,v2w2;est45ie;c07k;och,rique,zo;aGerFiCmB;aFe2P;lCrB;!h0;!io;s1y;nu4;be09d1iEliDmCt1viBwood;n,s;er,o;ot1Ts;!as,j43sB;ha;a2en;!dAg32mEuCwB;a25in;arB;do;o0Su0S;l,nB;est;aYeOiLoErDuCwByl0;ay8ight;a8dl6nc0st2;ag0ew;minFnDri0ugCyB;le;!l03;!a29nBov0;e7ie,y;go,icB;!k;armuCeBll1on,rk;go;id;anIj0lbeHmetri9nFon,rEsDvCwBxt3;ay8ey;en,in;hawn,mo08;ek,ri0F;is,nBv3;is,y;rt;!dB;re;lKmInHrDvB;e,iB;!d;en,iDne7rByl;eBin,yl;l2Vn;n,o,us;!e,i4ny;iBon;an,en,on;e,lB;as;a06e04hWiar0lLoGrEuCyrB;il,us;rtB;!is;aBistobal;ig;dy,lEnCrB;ey,neli9y;or,rB;ad;by,e,in,l2t1;aGeDiByI;fBnt;fo0Ct1;meCt9velaB;nd;nt;rDuCyB;!t1;de;enB;ce;aFeErisCuB;ck;!tB;i0oph3;st3;d,rlBs;eBie;s,y;cBdric,s11;il;lEmer1rB;ey,lCro7y;ll;!os,t1;eb,v2;ar02eUilTlaSoPrCuByr1;ddy,rtI;aJeEiDuCyB;an,ce,on;ce,no;an,ce;nCtB;!t;dCtB;!on;an,on;dCndB;en,on;!foBl6y;rd;bCrByd;is;!by;i8ke;al,lA;nFrBshoi;at,nCtB;!r10;aBie;rd0S;!edict,iCjam2nA;ie,y;to;n6rBt;eBy;tt;ey;ar0Xb0Nd0Jgust2hm0Gid5ja0ElZmXnPputsiOrFsaEuCveBya0ziz;ry;gust9st2;us;hi;aIchHi4jun,maFnDon,tBy0;hBu06;ur;av,oB;ld;an,nd0A;el;ie;ta;aq;dGgel05tB;hoEoB;i8nB;!i02y;ne;ny;reBy;!as,s,w;ir,mBos;ar;an,beOd5eIfFi,lEonDphonHt1vB;aMin;on;so,zo;an,en;onCrB;edP;so;c,jaEksandDssaExB;!and3;er;ar,er;ndB;ro;rtH;ni;en;ad,eB;d,t;in;aColfBri0vik;!o;mBn;!a;dFeEraCuB;!bakr,lfazl;hBm;am;!l;allEel,oulaye,ulB;!lCrahm0;an;ah,o;ah;av,on", @@ -7214,12 +7219,28 @@ var _01Replace = { }; var _02Insert = createCommonjsModule(function (module, exports) { + // if it's empty, just create the phrase + var makeNew = function makeNew(str, doc) { + var phrase = _01Tokenizer(str, doc.world)[0]; //assume it's one sentence, for now + + var tmpDoc = doc.buildFrom([phrase]); + tmpDoc.tagger(); + doc.list = tmpDoc.list; + return doc; + }; /** add these new terms to the end*/ + + exports.append = function (str) { var _this = this; if (!str) { return this; + } // if it's empty, just create the phrase + + + if (!this.found) { + return makeNew(str, this); } // clear the cache @@ -7248,6 +7269,11 @@ var _02Insert = createCommonjsModule(function (module, exports) { if (!str) { return this; + } // if it's empty, just create the phrase + + + if (!this.found) { + return makeNew(str, this); } // clear the cache @@ -7402,14 +7428,17 @@ var calcOffset = function calcOffset(doc, result, options) { // console.log(t.post) // return n // }, 0) - // offset information for the entire doc starts at the first term, and - // is as long as the whole text (note that there may be an issue where - // leading punctuation is counted in the doc text length, but is - // *excluded* from the term[0] start position) - - o.offset = Object.assign({}, o.terms[0].offset, { + // The offset information for the entire doc starts at (or just before) + // the first term, and is as long as the whole text. The code originally + // copied the entire offset value from terms[0], but since we're now + // overriding 2 of the three fields, it's cleaner to just create an all- + // new object and not pretend it's "just" the same as terms[0]. + + o.offset = { + index: o.terms[0].offset.index, + start: o.terms[0].offset.start - o.text.indexOf(o.terms[0].text), length: o.text.length - }); + }; }); } }; @@ -8891,6 +8920,7 @@ var startsWith = [//web tags [/^[a-z0-9]*? o\'?clock$/, 'Time'], //3 oclock [/^[0-9]{1,4}-[0-9]{1,2}-[0-9]{1,4}$/, 'Date'], // 03-02-89 [/^[0-9]{1,4}\/[0-9]{1,2}\/[0-9]{1,4}$/, 'Date'], // 03/02/89 +[/^[0-9]{1,4}-[a-z]{2,9}-[0-9]{1,4}$/i, 'Date'], // 03-March-89 //names [/^ma?c\'.*/, 'LastName'], //mc'adams [/^o\'[drlkn].*/, 'LastName'], //o'douggan @@ -9108,6 +9138,7 @@ null, //1 gone: Adj$1, ices: Plrl, ints: Plrl, + ines: Plrl, ions: Plrl, less: Avb, llen: Adj$1, @@ -10513,13 +10544,13 @@ var list$1 = [// ==== Holiday ==== { match: "#Adverb [(march|may)]", group: 0, - tag: 'Infinitive', + tag: 'Verb', reason: 'quickly-march' }, //march quickly { - match: "(march|may) [#Adverb]", + match: "[(march|may)] #Adverb", group: 0, - tag: 'Infinitive', + tag: 'Verb', reason: 'march-quickly' }, //5th of March { @@ -10657,9 +10688,15 @@ var _03Noun = [// ==== Plural ==== match: '#Place+ #Possessive', tag: 'Possessive', reason: 'place-possessive' +}, // assign all tasks +{ + match: '#Verb (all|every|each|most|some|no) [#PresentTense]', + group: 0, + tag: 'Noun', + reason: 'all-presentTense' }, //big dreams, critical thinking { - match: '#Adjective [#PresentTense]', + match: '(#Adjective && !all) [#PresentTense]', group: 0, tag: 'Noun', reason: 'adj-presentTense' @@ -11069,7 +11106,7 @@ var _06Value = [// ==== PhoneNumber ==== reason: 'magnitude-and-value' }, //'a/an' can mean 1 - "a hour" { - match: '[(a|an)] (#Duration|hundred|thousand|million|billion|trillion)', + match: '!once [(a|an)] (#Duration|hundred|thousand|million|billion|trillion)', group: 0, tag: 'Value', reason: 'a-is-one' @@ -11104,7 +11141,7 @@ var list$3 = [// ==== Tense ==== reason: 'had-walked' }, //would walk { - match: "[(#Modal|did) (#Adverb|not)+?] #Verb", + match: "[#Adverb+? (#Modal|did)+ (#Adverb|not)+?] #Verb", group: 0, tag: 'Auxiliary', reason: 'modal-verb' @@ -11138,12 +11175,6 @@ var list$3 = [// ==== Tense ==== group: 0, tag: 'Auxiliary', reason: 'had-walked' -}, //would walk -{ - match: "[(#Modal|did) (#Adverb|not)+?] #Verb", - group: 0, - tag: 'Auxiliary', - reason: 'modal-verb' }, // will walk { match: '[(do|does|will|have|had)] (not|#Adverb)? #Verb', @@ -11176,7 +11207,7 @@ var list$3 = [// ==== Tense ==== reason: 'had-been' }, // was being driven { - match: '[being] #Participle', + match: '[(be|being|been)] #Participle', group: 0, tag: 'Auxiliary', reason: 'being-foo' @@ -11602,7 +11633,7 @@ var list$5 = [// ==== Honorific ==== group: 0, tag: 'Person', reason: 'ambig-active-for' -}, // may waits for +}, // may waits to { match: "[".concat(months, "] #PresentTense to"), group: 0, @@ -12965,7 +12996,12 @@ var toNegative = function toNegative(parsed, world) { if (parsed.auxiliary.found) { - parsed.auxiliary.eq(0).append('not'); + parsed.auxiliary.eq(0).append('not'); // 'would not have' ➔ 'would not have' + + if (parsed.auxiliary.has('#Modal have not')) { + parsed.auxiliary.replace('have not', 'not have'); + } + return; } // is walking -> is not walking @@ -13027,11 +13063,11 @@ var parseVerb = function parseVerb(vb) { // 'really' negative: vb.match('#Negative'), // 'not' - auxiliary: vb.match('#Auxiliary').not('(#Negative|#Adverb)'), + auxiliary: vb.match('#Auxiliary+').not('(#Negative|#Adverb)'), // 'will' of 'will go' particle: vb.match('#Particle'), // 'up' of 'pull up' - verb: vb.match('#Verb').not('(#Adverb|#Negative|#Auxiliary|#Particle)') + verb: vb.match('#Verb+').not('(#Adverb|#Negative|#Auxiliary|#Particle)') }; // fallback, if no verb found if (!parsed.verb.found) { @@ -13110,11 +13146,34 @@ var toBe = function toBe(parsed) { var toBe_1 = toBe; +// 'may/could/should' -> 'may/could/should have' +var doModal = function doModal(parsed) { + var str = parsed.verb.text(); + var res = { + PastTense: str + ' have', + PresentTense: str, + FutureTense: str, + Infinitive: str // Gerund: , + // Actor: '', + // PerfectTense: '', + // Pluperfect: '', + + }; + return res; +}; + +var doModal_1 = doModal; + var conjugate$2 = function conjugate(parsed, world) { var verb = parsed.verb; //special handling of 'is', 'will be', etc. if (verb.has('#Copula') || verb.out('normal') === 'be' && parsed.auxiliary.has('will')) { return toBe_1(parsed); + } // special handling of 'he could.' + + + if (verb.has('#Modal')) { + return doModal_1(parsed); } var hasHyphen = parsed.verb.termList(0).hasHyphen(); @@ -13134,23 +13193,16 @@ var conjugate$2 = function conjugate(parsed, world) { return forms[k] += space + particle; }); } //put the adverb at the end? - - - if (parsed.adverb.found) { - var adverb = parsed.adverb.text(); - - var _space = hasHyphen === true ? '-' : ' '; - - if (parsed.adverbAfter === true) { - Object.keys(forms).forEach(function (k) { - return forms[k] += _space + adverb; - }); - } else { - Object.keys(forms).forEach(function (k) { - return forms[k] = adverb + _space + forms[k]; - }); - } - } //apply negative + // if (parsed.adverb.found) { + // let adverb = parsed.adverb.text() + // let space = hasHyphen === true ? '-' : ' ' + // if (parsed.adverbAfter === true) { + // Object.keys(forms).forEach(k => (forms[k] += space + adverb)) + // } else { + // Object.keys(forms).forEach(k => (forms[k] = adverb + space + forms[k])) + // } + // } + //apply negative var isNegative = parsed.negative.found; @@ -13179,6 +13231,82 @@ var conjugate$2 = function conjugate(parsed, world) { var conjugate_1$1 = conjugate$2; +// if something is 'modal-ish' we are forced to use past-participle +// ('i could drove' is wrong) + +var useParticiple = function useParticiple(parsed) { + if (parsed.auxiliary.has('(could|should|would|may|can|must)')) { + return true; + } + + if (parsed.auxiliary.has('am .+? being')) { + return true; + } + + if (parsed.auxiliary.has('had .+? been')) { + return true; + } + + return false; +}; // conjugate 'drive' ➔ 'have driven' + + +var toParticiple = function toParticiple(parsed, world) { + //is it already a participle? + if (parsed.auxiliary.has('(have|had)') && parsed.verb.has('#Participle')) { + return; + } // try to swap the main verb to its participle form + + + var obj = conjugate_1$1(parsed, world); + var str = obj.Participle || obj.PastTense; + + if (str) { + parsed.verb.replaceWith(str, false); + } // 'am being driven' ➔ 'have been driven' + + + if (parsed.auxiliary.has('am .+? being')) { + parsed.auxiliary.remove('am'); + parsed.auxiliary.replace('being', 'have been'); + } // add a 'have' + + + if (!parsed.auxiliary.has('have')) { + parsed.auxiliary.append('have'); + } // tag it as a participle + + + parsed.verb.tag('Participle', 'toParticiple'); // turn 'i can swim' to -> 'i could swim' + + parsed.auxiliary.replace('can', 'could'); //'must be' ➔ 'must have been' + + parsed.auxiliary.replace('be have', 'have been'); //'not have' ➔ 'have not' + + parsed.auxiliary.replace('not have', 'have not'); // ensure all new words are tagged right + + parsed.auxiliary.tag('Auxiliary'); +}; + +var participle = { + useParticiple: useParticiple, + toParticiple: toParticiple +}; + +var _toParticiple = participle.toParticiple, + useParticiple$1 = participle.useParticiple; // remove any tense-information in auxiliary verbs + +var makeNeutral = function makeNeutral(parsed) { + //remove tense-info from auxiliaries + parsed.auxiliary.remove('(will|are|am|being)'); + parsed.auxiliary.remove('(did|does)'); + parsed.auxiliary.remove('(had|has|have)'); //our conjugation includes the 'not' and the phrasal-verb particle + + parsed.particle.remove(); + parsed.negative.remove(); + return parsed; +}; + var methods$7 = { /** overload the original json with verb information */ json: function json(options) { @@ -13248,6 +13376,7 @@ var methods$7 = { return this.buildFrom(list); }, + /// Verb Inflection /**return verbs like 'we walk' and not 'spencer walks' */ isPlural: function isPlural() { @@ -13278,8 +13407,9 @@ var methods$7 = { }); return this.buildFrom(list); }, + /// Conjugation - /** */ + /** return all forms of this verb */ conjugate: function conjugate() { var _this4 = this; @@ -13294,23 +13424,30 @@ var methods$7 = { return result; }, - /** */ + /** walk ➔ walked*/ toPastTense: function toPastTense() { var _this5 = this; this.forEach(function (vb) { - var parsed = parse$2(vb); + var parsed = parse$2(vb); // should we support 'would swim' ➔ 'would have swam' + + if (useParticiple$1(parsed)) { + _toParticiple(parsed, _this5.world); + + return; + } var str = conjugate_1$1(parsed, _this5.world).PastTense; if (str) { - vb.replaceWith(str, false); // vb.tag('PastTense') + parsed = makeNeutral(parsed); + parsed.verb.replaceWith(str, false); // vb.tag('PastTense') } }); return this; }, - /** */ + /** walk ➔ walks */ toPresentTense: function toPresentTense() { var _this6 = this; @@ -13326,31 +13463,53 @@ var methods$7 = { } if (str) { - vb.replaceWith(str, false); - vb.tag('PresentTense'); + //awkward support for present-participle form + // -- should we support 'have been swimming' ➔ 'am swimming' + if (parsed.auxiliary.has('(have|had) been')) { + parsed.auxiliary.replace('(have|had) been', 'am being'); + + if (obj.Particle) { + str = obj.Particle || obj.PastTense; + } + + return; + } + + parsed.verb.replaceWith(str, false); + parsed.verb.tag('PresentTense'); + parsed = makeNeutral(parsed); // avoid 'he would walks' + + parsed.auxiliary.remove('#Modal'); } }); return this; }, - /** */ + /** walk ➔ will walk*/ toFutureTense: function toFutureTense() { var _this7 = this; this.forEach(function (vb) { - var parsed = parse$2(vb); + var parsed = parse$2(vb); // 'i should drive' is already future-enough + + if (useParticiple$1(parsed)) { + return; + } var str = conjugate_1$1(parsed, _this7.world).FutureTense; if (str) { - vb.replaceWith(str, false); - vb.tag('FutureTense'); + parsed = makeNeutral(parsed); // avoid 'he would will go' + + parsed.auxiliary.remove('#Modal'); + parsed.verb.replaceWith(str, false); + parsed.verb.tag('FutureTense'); } }); return this; }, - /** */ + /** walks ➔ walk */ toInfinitive: function toInfinitive() { var _this8 = this; @@ -13367,7 +13526,7 @@ var methods$7 = { return this; }, - /** */ + /** walk ➔ walking */ toGerund: function toGerund() { var _this9 = this; @@ -13384,6 +13543,26 @@ var methods$7 = { return this; }, + /** drive ➔ driven - naked past-participle if it exists, otherwise past-tense */ + toParticiple: function toParticiple() { + var _this10 = this; + + this.forEach(function (vb) { + var parsed = parse$2(vb); + var noAux = !parsed.auxiliary.found; + + _toParticiple(parsed, _this10.world); // dirty trick to ensure our new auxiliary is found + + + if (noAux) { + parsed.verb.prepend(parsed.auxiliary.text()); + parsed.auxiliary.remove(); + } + }); + return this; + }, + /// Negation + /** return only verbs with 'not'*/ isNegative: function isNegative() { return this["if"]('#Negative'); @@ -13396,10 +13575,10 @@ var methods$7 = { /** add a 'not' to these verbs */ toNegative: function toNegative() { - var _this10 = this; + var _this11 = this; this.list.forEach(function (p) { - var doc = _this10.buildFrom([p]); + var doc = _this11.buildFrom([p]); var parsed = parse$2(doc); diff --git a/changelog.md b/changelog.md index 5bf13f39e..275b8c362 100644 --- a/changelog.md +++ b/changelog.md @@ -10,7 +10,15 @@ While all _Major_ releases should be reviewed, our only two _large_ releases are #### [Unreleased] --move (some) contractions into tokenizer? +#### 13.4.0 + +- **[change]** stop including adverbs and some auxiliaries in `.conjugate()` results +- **[change]** .append() and .prepend() on an empty doc now creates a new doc +- **[new]** add `verbs().toParticiple()` method (add to observables/verb) +- **[new]** add `sentences().toParticiple()` method (add to observables/verb) +- **[fix]** some verb-tagging issues +- **[fix]** contractions issue in `.clone()` +- **[fix]** try harder to retain modal-verbs in conjugation - 'i should drive' no-longer becomes 'i will drive' #### 13.3.2 diff --git a/data/abbreviations/misc.js b/data/abbreviations/misc.js index 9330e834c..9fb3bcda1 100644 --- a/data/abbreviations/misc.js +++ b/data/abbreviations/misc.js @@ -19,7 +19,7 @@ module.exports = [ 'lat', //latitude 'lng', //longitude 'vol', //volume - 'psa', //psalms + // 'psa', //psalms 'fm', //not am 'def', //definition 'misc', diff --git a/data/dates/dates.js b/data/dates/dates.js index 6128c1e08..3660482d5 100644 --- a/data/dates/dates.js +++ b/data/dates/dates.js @@ -1,2 +1,2 @@ // uncontroversial date words -module.exports = ['today', 'tomorrow', 'tmr', 'tmrw', 'yesterday', 'weekend'] +module.exports = ['today', 'tomorrow', 'tmr', 'tmrw', 'yesterday', 'weekend', 'ago'] diff --git a/data/misc.js b/data/misc.js index 0b7dc9ee3..c511650cc 100644 --- a/data/misc.js +++ b/data/misc.js @@ -16,6 +16,7 @@ module.exports = { if: 'Condition', unless: 'Condition', + lest: 'Condition', said: 'PastTense', had: 'PastTense', diff --git a/data/nouns/singulars.js b/data/nouns/singulars.js index 0d4d44289..9da273f7e 100644 --- a/data/nouns/singulars.js +++ b/data/nouns/singulars.js @@ -32,6 +32,7 @@ module.exports = [ 'home run', 'home', 'house', + 'insect', 'lunch', 'meeting', 'model', @@ -47,6 +48,7 @@ module.exports = [ 'question mark', 'room', 'rose', + 'size', 'sky', 'student', 'stuff', diff --git a/package-lock.json b/package-lock.json index 6081b2316..1de6a040d 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,16 +1,16 @@ { "name": "compromise", - "version": "13.3.1", + "version": "13.4.0", "lockfileVersion": 1, "requires": true, "dependencies": { "@babel/code-frame": { - "version": "7.10.1", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.10.1.tgz", - "integrity": "sha512-IGhtTmpjGbYzcEDOw7DcQtbQSXcG9ftmAXtWTu9V936vDye4xjjekktFAtgZsWpzTj/X01jocB46mTywm/4SZw==", + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.10.4.tgz", + "integrity": "sha512-vG6SvB6oYEhvgisZNFRmRCUkLz11c7rp+tbNTynGqc6mS1d5ATd/sGyV6W0KZZnXRKMTzZDRgQT3Ou9jhpAfUg==", "dev": true, "requires": { - "@babel/highlight": "^7.10.1" + "@babel/highlight": "^7.10.4" } }, "@babel/compat-data": { @@ -25,19 +25,19 @@ } }, "@babel/core": { - "version": "7.11.1", - "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.11.1.tgz", - "integrity": "sha512-XqF7F6FWQdKGGWAzGELL+aCO1p+lRY5Tj5/tbT3St1G8NaH70jhhDIKknIZaDans0OQBG5wRAldROLHSt44BgQ==", + "version": "7.11.6", + "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.11.6.tgz", + "integrity": "sha512-Wpcv03AGnmkgm6uS6k8iwhIwTrcP0m17TL1n1sy7qD0qelDu4XNeW0dN0mHfa+Gei211yDaLoEe/VlbXQzM4Bg==", "dev": true, "requires": { "@babel/code-frame": "^7.10.4", - "@babel/generator": "^7.11.0", + "@babel/generator": "^7.11.6", "@babel/helper-module-transforms": "^7.11.0", "@babel/helpers": "^7.10.4", - "@babel/parser": "^7.11.1", + "@babel/parser": "^7.11.5", "@babel/template": "^7.10.4", - "@babel/traverse": "^7.11.0", - "@babel/types": "^7.11.0", + "@babel/traverse": "^7.11.5", + "@babel/types": "^7.11.5", "convert-source-map": "^1.7.0", "debug": "^4.1.0", "gensync": "^1.0.0-beta.1", @@ -48,36 +48,16 @@ "source-map": "^0.5.0" }, "dependencies": { - "@babel/code-frame": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.10.4.tgz", - "integrity": "sha512-vG6SvB6oYEhvgisZNFRmRCUkLz11c7rp+tbNTynGqc6mS1d5ATd/sGyV6W0KZZnXRKMTzZDRgQT3Ou9jhpAfUg==", - "dev": true, - "requires": { - "@babel/highlight": "^7.10.4" - } - }, "@babel/helper-validator-identifier": { "version": "7.10.4", "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.10.4.tgz", "integrity": "sha512-3U9y+43hz7ZM+rzG24Qe2mufW5KhvFg/NhnNph+i9mgCtdTCtMJuI1TMkrIUiK7Ix4PYlRF9I5dhqaLYA/ADXw==", "dev": true }, - "@babel/highlight": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.10.4.tgz", - "integrity": "sha512-i6rgnR/YgPEQzZZnbTHHuZdlE8qyoBNalD6F+q4vAFlcMEcqmkoG+mPqJYJCo63qPf74+Y1UZsl3l6f7/RIkmA==", - "dev": true, - "requires": { - "@babel/helper-validator-identifier": "^7.10.4", - "chalk": "^2.0.0", - "js-tokens": "^4.0.0" - } - }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -86,20 +66,20 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } }, "@babel/generator": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.11.0.tgz", - "integrity": "sha512-fEm3Uzw7Mc9Xi//qU20cBKatTfs2aOtKqmvy/Vm7RkJEGFQ4xc9myCfbXxqK//ZS8MR/ciOHw6meGASJuKmDfQ==", + "version": "7.11.6", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.11.6.tgz", + "integrity": "sha512-DWtQ1PV3r+cLbySoHrwn9RWEgKMBLLma4OBQloPRyDYvc5msJM9kvTLo1YnlJd1P/ZuKbdli3ijr5q3FvAF3uA==", "dev": true, "requires": { - "@babel/types": "^7.11.0", + "@babel/types": "^7.11.5", "jsesc": "^2.5.1", "source-map": "^0.5.0" }, @@ -111,9 +91,9 @@ "dev": true }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -122,9 +102,9 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } @@ -145,9 +125,9 @@ "dev": true }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -156,9 +136,9 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } @@ -180,9 +160,9 @@ "dev": true }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -191,9 +171,9 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } @@ -254,9 +234,9 @@ "dev": true }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -265,20 +245,19 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } }, "@babel/helper-explode-assignable-expression": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.10.4.tgz", - "integrity": "sha512-4K71RyRQNPRrR85sr5QY4X3VwG4wtVoXZB9+L3r1Gp38DhELyHCtovqydRi7c1Ovb17eRGiQ/FD5s8JdU0Uy5A==", + "version": "7.11.4", + "resolved": "https://registry.npmjs.org/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.11.4.tgz", + "integrity": "sha512-ux9hm3zR4WV1Y3xXxXkdG/0gxF9nvI0YVmKVhvK9AfMoaQkemL3sJpXw+Xbz65azo8qJiEz2XVDUpK3KYhH3ZQ==", "dev": true, "requires": { - "@babel/traverse": "^7.10.4", "@babel/types": "^7.10.4" }, "dependencies": { @@ -289,9 +268,9 @@ "dev": true }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -300,9 +279,9 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } @@ -325,9 +304,9 @@ "dev": true }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -336,9 +315,9 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } @@ -359,9 +338,9 @@ "dev": true }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -370,9 +349,9 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } @@ -393,9 +372,9 @@ "dev": true }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -404,9 +383,9 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } @@ -427,9 +406,9 @@ "dev": true }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -438,9 +417,9 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } @@ -485,9 +464,9 @@ "dev": true }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -496,9 +475,9 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } @@ -519,9 +498,9 @@ "dev": true }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -530,9 +509,9 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } @@ -553,23 +532,22 @@ }, "dependencies": { "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } }, "@babel/helper-remap-async-to-generator": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.10.4.tgz", - "integrity": "sha512-86Lsr6NNw3qTNl+TBcF1oRZMaVzJtbWTyTko+CQL/tvNvcGYEFKbLXDPxtW0HKk3McNOk4KzY55itGWCAGK5tg==", + "version": "7.11.4", + "resolved": "https://registry.npmjs.org/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.11.4.tgz", + "integrity": "sha512-tR5vJ/vBa9wFy3m5LLv2faapJLnDFxNWff2SAYkSE4rLUdbp7CdObYFgI7wK4T/Mj4UzpjPwzR8Pzmr5m7MHGA==", "dev": true, "requires": { "@babel/helper-annotate-as-pure": "^7.10.4", "@babel/helper-wrap-function": "^7.10.4", "@babel/template": "^7.10.4", - "@babel/traverse": "^7.10.4", "@babel/types": "^7.10.4" }, "dependencies": { @@ -580,9 +558,9 @@ "dev": true }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -591,9 +569,9 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } @@ -617,9 +595,9 @@ "dev": true }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -628,9 +606,9 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } @@ -652,9 +630,9 @@ "dev": true }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -663,9 +641,9 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } @@ -686,9 +664,9 @@ "dev": true }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -697,9 +675,9 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } @@ -720,9 +698,9 @@ "dev": true }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -731,9 +709,9 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } @@ -763,9 +741,9 @@ "dev": true }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -774,9 +752,9 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } @@ -799,9 +777,9 @@ "dev": true }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -810,36 +788,36 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } }, "@babel/highlight": { - "version": "7.10.1", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.10.1.tgz", - "integrity": "sha512-8rMof+gVP8mxYZApLF/JgNDAkdKa+aJt3ZYxF8z6+j/hpeXL7iMsKCPHa2jNMHu/qqBwzQF4OHNoYi8dMA/rYg==", + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.10.4.tgz", + "integrity": "sha512-i6rgnR/YgPEQzZZnbTHHuZdlE8qyoBNalD6F+q4vAFlcMEcqmkoG+mPqJYJCo63qPf74+Y1UZsl3l6f7/RIkmA==", "dev": true, "requires": { - "@babel/helper-validator-identifier": "^7.10.1", + "@babel/helper-validator-identifier": "^7.10.4", "chalk": "^2.0.0", "js-tokens": "^4.0.0" }, "dependencies": { "@babel/helper-validator-identifier": { - "version": "7.10.1", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.10.1.tgz", - "integrity": "sha512-5vW/JXLALhczRCWP0PnFDMCJAchlBvM7f4uk/jXritBnIa6E1KmqmtrS3yn1LAnxFBypQ3eneLuXjsnfQsgILw==", + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.10.4.tgz", + "integrity": "sha512-3U9y+43hz7ZM+rzG24Qe2mufW5KhvFg/NhnNph+i9mgCtdTCtMJuI1TMkrIUiK7Ix4PYlRF9I5dhqaLYA/ADXw==", "dev": true } } }, "@babel/parser": { - "version": "7.11.2", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.11.2.tgz", - "integrity": "sha512-Vuj/+7vLo6l1Vi7uuO+1ngCDNeVmNbTngcJFKCR/oEtz8tKz0CJxZEGmPt9KcIloZhOZ3Zit6xbpXT2MDlS9Vw==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.11.5.tgz", + "integrity": "sha512-X9rD8qqm695vgmeaQ4fvz/o3+Wk4ZzQvSHkDBgpYKxpD4qTAUm88ZKtHkVqIOsYFFbIQ6wQYhC6q7pjqVK0E0Q==", "dev": true }, "@babel/plugin-proposal-async-generator-functions": { @@ -1119,9 +1097,9 @@ "dev": true }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -1130,9 +1108,9 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } @@ -1433,9 +1411,9 @@ } }, "@babel/preset-env": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/preset-env/-/preset-env-7.11.0.tgz", - "integrity": "sha512-2u1/k7rG/gTh02dylX2kL3S0IJNF+J6bfDSp4DI2Ma8QN6Y9x9pmAax59fsCk6QUQG0yqH47yJWA+u1I1LccAg==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/preset-env/-/preset-env-7.11.5.tgz", + "integrity": "sha512-kXqmW1jVcnB2cdueV+fyBM8estd5mlNfaQi6lwLgRwCby4edpavgbFhiBNjmWA3JpB/yZGSISa7Srf+TwxDQoA==", "dev": true, "requires": { "@babel/compat-data": "^7.11.0", @@ -1500,7 +1478,7 @@ "@babel/plugin-transform-unicode-escapes": "^7.10.4", "@babel/plugin-transform-unicode-regex": "^7.10.4", "@babel/preset-modules": "^0.1.3", - "@babel/types": "^7.11.0", + "@babel/types": "^7.11.5", "browserslist": "^4.12.0", "core-js-compat": "^3.6.2", "invariant": "^2.2.2", @@ -1524,9 +1502,9 @@ "dev": true }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -1535,17 +1513,17 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } }, "@babel/preset-modules": { - "version": "0.1.3", - "resolved": "https://registry.npmjs.org/@babel/preset-modules/-/preset-modules-0.1.3.tgz", - "integrity": "sha512-Ra3JXOHBq2xd56xSF7lMKXdjBn3T772Y1Wet3yWnkDly9zHvJki029tAFzvAAK5cf4YV3yoxuP61crYRol6SVg==", + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/@babel/preset-modules/-/preset-modules-0.1.4.tgz", + "integrity": "sha512-J36NhwnfdzpmH41M1DrnkkgAqhZaqr/NBdPfQ677mLzlaXo+oDiv1deyCDtgAhz8p328otdob0Du7+xgHGZbKg==", "dev": true, "requires": { "@babel/helper-plugin-utils": "^7.0.0", @@ -1575,36 +1553,16 @@ "@babel/types": "^7.10.4" }, "dependencies": { - "@babel/code-frame": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.10.4.tgz", - "integrity": "sha512-vG6SvB6oYEhvgisZNFRmRCUkLz11c7rp+tbNTynGqc6mS1d5ATd/sGyV6W0KZZnXRKMTzZDRgQT3Ou9jhpAfUg==", - "dev": true, - "requires": { - "@babel/highlight": "^7.10.4" - } - }, "@babel/helper-validator-identifier": { "version": "7.10.4", "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.10.4.tgz", "integrity": "sha512-3U9y+43hz7ZM+rzG24Qe2mufW5KhvFg/NhnNph+i9mgCtdTCtMJuI1TMkrIUiK7Ix4PYlRF9I5dhqaLYA/ADXw==", "dev": true }, - "@babel/highlight": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.10.4.tgz", - "integrity": "sha512-i6rgnR/YgPEQzZZnbTHHuZdlE8qyoBNalD6F+q4vAFlcMEcqmkoG+mPqJYJCo63qPf74+Y1UZsl3l6f7/RIkmA==", - "dev": true, - "requires": { - "@babel/helper-validator-identifier": "^7.10.4", - "chalk": "^2.0.0", - "js-tokens": "^4.0.0" - } - }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -1613,60 +1571,40 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } }, "@babel/traverse": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.11.0.tgz", - "integrity": "sha512-ZB2V+LskoWKNpMq6E5UUCrjtDUh5IOTAyIl0dTjIEoXum/iKWkoIEKIRDnUucO6f+2FzNkE0oD4RLKoPIufDtg==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.11.5.tgz", + "integrity": "sha512-EjiPXt+r7LiCZXEfRpSJd+jUMnBd4/9OUv7Nx3+0u9+eimMwJmG0Q98lw4/289JCoxSE8OolDMNZaaF/JZ69WQ==", "dev": true, "requires": { "@babel/code-frame": "^7.10.4", - "@babel/generator": "^7.11.0", + "@babel/generator": "^7.11.5", "@babel/helper-function-name": "^7.10.4", "@babel/helper-split-export-declaration": "^7.11.0", - "@babel/parser": "^7.11.0", - "@babel/types": "^7.11.0", + "@babel/parser": "^7.11.5", + "@babel/types": "^7.11.5", "debug": "^4.1.0", "globals": "^11.1.0", "lodash": "^4.17.19" }, "dependencies": { - "@babel/code-frame": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.10.4.tgz", - "integrity": "sha512-vG6SvB6oYEhvgisZNFRmRCUkLz11c7rp+tbNTynGqc6mS1d5ATd/sGyV6W0KZZnXRKMTzZDRgQT3Ou9jhpAfUg==", - "dev": true, - "requires": { - "@babel/highlight": "^7.10.4" - } - }, "@babel/helper-validator-identifier": { "version": "7.10.4", "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.10.4.tgz", "integrity": "sha512-3U9y+43hz7ZM+rzG24Qe2mufW5KhvFg/NhnNph+i9mgCtdTCtMJuI1TMkrIUiK7Ix4PYlRF9I5dhqaLYA/ADXw==", "dev": true }, - "@babel/highlight": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.10.4.tgz", - "integrity": "sha512-i6rgnR/YgPEQzZZnbTHHuZdlE8qyoBNalD6F+q4vAFlcMEcqmkoG+mPqJYJCo63qPf74+Y1UZsl3l6f7/RIkmA==", - "dev": true, - "requires": { - "@babel/helper-validator-identifier": "^7.10.4", - "chalk": "^2.0.0", - "js-tokens": "^4.0.0" - } - }, "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "version": "7.11.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.5.tgz", + "integrity": "sha512-bvM7Qz6eKnJVFIn+1LPtjlBFPVN5jNDc1XmN15vWe7Q3DPBufWWsLiIvUu7xW87uTG6QoggpIDnUgLQvPheU+Q==", "dev": true, "requires": { "@babel/helper-validator-identifier": "^7.10.4", @@ -1675,9 +1613,9 @@ } }, "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", + "version": "4.17.20", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", + "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "dev": true } } @@ -1703,18 +1641,26 @@ } }, "@rollup/plugin-commonjs": { - "version": "14.0.0", - "resolved": "https://registry.npmjs.org/@rollup/plugin-commonjs/-/plugin-commonjs-14.0.0.tgz", - "integrity": "sha512-+PSmD9ePwTAeU106i9FRdc+Zb3XUWyW26mo5Atr2mk82hor8+nPwkztEjFo8/B1fJKfaQDg9aM2bzQkjhi7zOw==", + "version": "15.0.0", + "resolved": "https://registry.npmjs.org/@rollup/plugin-commonjs/-/plugin-commonjs-15.0.0.tgz", + "integrity": "sha512-8uAdikHqVyrT32w1zB9VhW6uGwGjhKgnDNP4pQJsjdnyF4FgCj6/bmv24c7v2CuKhq32CcyCwRzMPEElaKkn0w==", "dev": true, "requires": { - "@rollup/pluginutils": "^3.0.8", + "@rollup/pluginutils": "^3.1.0", "commondir": "^1.0.1", - "estree-walker": "^1.0.1", - "glob": "^7.1.2", - "is-reference": "^1.1.2", - "magic-string": "^0.25.2", - "resolve": "^1.11.0" + "estree-walker": "^2.0.1", + "glob": "^7.1.6", + "is-reference": "^1.2.1", + "magic-string": "^0.25.7", + "resolve": "^1.17.0" + }, + "dependencies": { + "estree-walker": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-2.0.1.tgz", + "integrity": "sha512-tF0hv+Yi2Ot1cwj9eYHtxC0jB9bmjacjQs6ZBTj82H8JwUywFuc+7E83NWfNMwHXZc11mjfFcVXPe9gEP4B8dg==", + "dev": true + } } }, "@rollup/plugin-json": { @@ -1727,15 +1673,14 @@ } }, "@rollup/plugin-node-resolve": { - "version": "8.4.0", - "resolved": "https://registry.npmjs.org/@rollup/plugin-node-resolve/-/plugin-node-resolve-8.4.0.tgz", - "integrity": "sha512-LFqKdRLn0ShtQyf6SBYO69bGE1upV6wUhBX0vFOUnLAyzx5cwp8svA0eHUnu8+YU57XOkrMtfG63QOpQx25pHQ==", + "version": "9.0.0", + "resolved": "https://registry.npmjs.org/@rollup/plugin-node-resolve/-/plugin-node-resolve-9.0.0.tgz", + "integrity": "sha512-gPz+utFHLRrd41WMP13Jq5mqqzHL3OXrfj3/MkSyB6UBIcuNt9j60GCbarzMzdf1VHFpOxfQh/ez7wyadLMqkg==", "dev": true, "requires": { "@rollup/pluginutils": "^3.1.0", "@types/resolve": "1.17.1", "builtin-modules": "^3.1.0", - "deep-freeze": "^0.0.1", "deepmerge": "^4.2.2", "is-module": "^1.0.0", "resolve": "^1.17.0" @@ -1759,9 +1704,9 @@ "dev": true }, "@types/node": { - "version": "14.0.27", - "resolved": "https://registry.npmjs.org/@types/node/-/node-14.0.27.tgz", - "integrity": "sha512-kVrqXhbclHNHGu9ztnAwSncIgJv/FaxmzXJvGXNdcCpV1b8u1/Mi6z6m0vwy0LzKeXFTPLH0NzwmoJ3fNCIq0g==", + "version": "14.6.4", + "resolved": "https://registry.npmjs.org/@types/node/-/node-14.6.4.tgz", + "integrity": "sha512-Wk7nG1JSaMfMpoMJDKUsWYugliB2Vy55pdjLpmLixeyMi7HizW2I/9QoxsPCkXl3dO+ZOVqPumKaDUv5zJu2uQ==", "dev": true }, "@types/resolve": { @@ -1858,15 +1803,15 @@ } }, "browserslist": { - "version": "4.14.0", - "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.14.0.tgz", - "integrity": "sha512-pUsXKAF2lVwhmtpeA3LJrZ76jXuusrNyhduuQs7CDFf9foT4Y38aQOserd2lMe5DSSrjf3fx34oHwryuvxAUgQ==", + "version": "4.14.2", + "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.14.2.tgz", + "integrity": "sha512-HI4lPveGKUR0x2StIz+2FXfDk9SfVMrxn6PLh1JeGUwcuoDkdKZebWiyLRJ68iIPDpMI4JLVDf7S7XzslgWOhw==", "dev": true, "requires": { - "caniuse-lite": "^1.0.30001111", - "electron-to-chromium": "^1.3.523", + "caniuse-lite": "^1.0.30001125", + "electron-to-chromium": "^1.3.564", "escalade": "^3.0.2", - "node-releases": "^1.1.60" + "node-releases": "^1.1.61" } }, "buffer-from": { @@ -1888,9 +1833,9 @@ "dev": true }, "caniuse-lite": { - "version": "1.0.30001112", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001112.tgz", - "integrity": "sha512-J05RTQlqsatidif/38aN3PGULCLrg8OYQOlJUKbeYVzC2mGZkZLIztwRlB3MtrfLmawUmjFlNJvy/uhwniIe1Q==", + "version": "1.0.30001125", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001125.tgz", + "integrity": "sha512-9f+r7BW8Qli917mU3j0fUaTweT3f3vnX/Lcs+1C73V+RADmFme+Ih0Br8vONQi3X0lseOe6ZHfsZLCA8MSjxUA==", "dev": true }, "chalk": { @@ -2031,12 +1976,6 @@ } } }, - "deep-freeze": { - "version": "0.0.1", - "resolved": "https://registry.npmjs.org/deep-freeze/-/deep-freeze-0.0.1.tgz", - "integrity": "sha1-OgsABd4YZygZ39OM0x+RF5yJPoQ=", - "dev": true - }, "deepmerge": { "version": "4.2.2", "resolved": "https://registry.npmjs.org/deepmerge/-/deepmerge-4.2.2.tgz", @@ -2079,9 +2018,9 @@ "integrity": "sha512-9xUSSj7qcUxz+0r4X3+bwUNttEfGfK5AH+LVa1aTpqdAfrN5VhROYCfcF+up4hp5OL7IUKcZJJrzAGipQRDoiQ==" }, "electron-to-chromium": { - "version": "1.3.524", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.3.524.tgz", - "integrity": "sha512-ZUvklIBkfXQyA6IeiEss1nfKRICcdB5afAGZAaPGaExdfrkpUu/WWVO+X7QpNnphaVMllXnAcvKnVPdyM+DCPQ==", + "version": "1.3.564", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.3.564.tgz", + "integrity": "sha512-fNaYN3EtKQWLQsrKXui8mzcryJXuA0LbCLoizeX6oayG2emBaS5MauKjCPAvc29NEY4FpLHIUWiP+Y0Bfrs5dg==", "dev": true }, "es-abstract": { @@ -2439,11 +2378,12 @@ "dev": true }, "jest-worker": { - "version": "26.0.0", - "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-26.0.0.tgz", - "integrity": "sha512-pPaYa2+JnwmiZjK9x7p9BoZht+47ecFCDFA/CJxspHzeDvQcfVBLWzCiWyo+EGrSiQMWZtCFo9iSvMZnAAo8vw==", + "version": "26.3.0", + "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-26.3.0.tgz", + "integrity": "sha512-Vmpn2F6IASefL+DVBhPzI2J9/GJUsqzomdeN+P+dK8/jKxbh8R3BtFnx3FIta7wYlPU62cpJMJQo4kuOowcMnw==", "dev": true, "requires": { + "@types/node": "*", "merge-stream": "^2.0.0", "supports-color": "^7.0.0" }, @@ -2455,9 +2395,9 @@ "dev": true }, "supports-color": { - "version": "7.1.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.1.0.tgz", - "integrity": "sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g==", + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, "requires": { "has-flag": "^4.0.0" @@ -2553,9 +2493,9 @@ "dev": true }, "node-releases": { - "version": "1.1.60", - "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-1.1.60.tgz", - "integrity": "sha512-gsO4vjEdQaTusZAEebUWp2a5d7dF5DYoIpDG7WySnk7BuZDW+GPpHXoXXuYawRBr/9t5q54tirPz79kFIWg4dA==", + "version": "1.1.61", + "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-1.1.61.tgz", + "integrity": "sha512-DD5vebQLg8jLCOzwupn954fbIiZht05DAZs0k2u8NStSe6h9XdsuIQL8hSRKYiU8WUQRznmSDrKGbv3ObOmC7g==", "dev": true }, "normalize-path": { @@ -2754,9 +2694,9 @@ } }, "rollup": { - "version": "2.23.0", - "resolved": "https://registry.npmjs.org/rollup/-/rollup-2.23.0.tgz", - "integrity": "sha512-vLNmZFUGVwrnqNAJ/BvuLk1MtWzu4IuoqsH9UWK5AIdO3rt8/CSiJNvPvCIvfzrbNsqKbNzPAG1V2O4eTe2XZg==", + "version": "2.26.11", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-2.26.11.tgz", + "integrity": "sha512-xyfxxhsE6hW57xhfL1I+ixH8l2bdoIMaAecdQiWF3N7IgJEMu99JG+daBiSZQjnBpzFxa0/xZm+3pbCdAQehHw==", "dev": true, "requires": { "fsevents": "~2.1.2" @@ -2779,15 +2719,15 @@ "dev": true }, "rollup-plugin-terser": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/rollup-plugin-terser/-/rollup-plugin-terser-6.1.0.tgz", - "integrity": "sha512-4fB3M9nuoWxrwm39habpd4hvrbrde2W2GG4zEGPQg1YITNkM3Tqur5jSuXlWNzbv/2aMLJ+dZJaySc3GCD8oDw==", + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/rollup-plugin-terser/-/rollup-plugin-terser-7.0.2.tgz", + "integrity": "sha512-w3iIaU4OxcF52UUXiZNsNeuXIMDvFrr+ZXK6bFZ0Q60qyVfq4uLptoS4bbq3paG3x216eQllFZX7zt6TIImguQ==", "dev": true, "requires": { - "@babel/code-frame": "^7.8.3", - "jest-worker": "^26.0.0", - "serialize-javascript": "^3.0.0", - "terser": "^4.7.0" + "@babel/code-frame": "^7.10.4", + "jest-worker": "^26.2.1", + "serialize-javascript": "^4.0.0", + "terser": "^5.0.0" } }, "rollup-pluginutils": { @@ -2820,9 +2760,9 @@ "dev": true }, "serialize-javascript": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-3.1.0.tgz", - "integrity": "sha512-JIJT1DGiWmIKhzRsG91aS6Ze4sFUrYbltlkg2onR5OrnNM02Kl/hnY/T4FN2omvyeBbQmMJv+K4cPOpGzOTFBg==", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-4.0.0.tgz", + "integrity": "sha512-GaNA54380uFefWghODBWEGisLZFj00nS5ACs6yHa9nLqlLpVLO8ChDGeKRjZnV4Nh4n0Qi7nhYZD/9fCPzEqkw==", "dev": true, "requires": { "randombytes": "^2.1.0" @@ -3044,9 +2984,9 @@ } }, "terser": { - "version": "4.7.0", - "resolved": "https://registry.npmjs.org/terser/-/terser-4.7.0.tgz", - "integrity": "sha512-Lfb0RiZcjRDXCC3OSHJpEkxJ9Qeqs6mp2v4jf2MHfy8vGERmVDuvjXdd/EnP5Deme5F2yBRBymKmKHCBg2echw==", + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/terser/-/terser-5.3.0.tgz", + "integrity": "sha512-XTT3D3AwxC54KywJijmY2mxZ8nJiEjBHVYzq8l9OaYuRFWeQNBwvipuzzYEP4e+/AVcd1hqG/CqgsdIRyT45Fg==", "dev": true, "requires": { "commander": "^2.20.0", diff --git a/package.json b/package.json index 5cd8095c5..c4fec5b85 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "author": "Spencer Kelly (http://spencermounta.in)", "name": "compromise", "description": "modest natural language processing", - "version": "13.3.2", + "version": "13.4.0", "main": "./builds/compromise.js", "unpkg": "./builds/compromise.min.js", "module": "./builds/compromise.mjs", @@ -54,19 +54,19 @@ "efrt-unpack": "2.2.0" }, "devDependencies": { - "@babel/core": "7.11.1", - "@babel/preset-env": "7.11.0", - "@rollup/plugin-alias": "3.1.1", - "@rollup/plugin-commonjs": "14.0.0", - "@rollup/plugin-json": "4.1.0", - "@rollup/plugin-node-resolve": "8.4.0", "amble": "1.1.0", "efrt": "2.2.2", - "rollup": "2.23.0", + "shelljs": "0.8.4", + "@babel/core": "7.11.6", + "@babel/preset-env": "7.11.5", + "rollup": "2.26.11", + "@rollup/plugin-alias": "3.1.1", + "@rollup/plugin-commonjs": "15.0.0", + "@rollup/plugin-json": "4.1.0", + "@rollup/plugin-node-resolve": "9.0.0", "rollup-plugin-babel": "4.4.0", "rollup-plugin-filesize-check": "0.0.1", - "rollup-plugin-terser": "6.1.0", - "shelljs": "0.8.4", + "rollup-plugin-terser": "7.0.2", "tap-dancer": "0.2.0", "tape": "5.0.1" }, diff --git a/plugins/dates/builds/compromise-dates.js b/plugins/dates/builds/compromise-dates.js index 0acf523c1..6c99d2a51 100644 --- a/plugins/dates/builds/compromise-dates.js +++ b/plugins/dates/builds/compromise-dates.js @@ -1,4 +1,4 @@ -/* compromise-dates 1.0.0 MIT */ +/* compromise-dates 1.1.0 MIT */ (function (global, factory) { typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() : typeof define === 'function' && define.amd ? define(factory) : @@ -297,6 +297,9 @@ var here = 'date-values'; // var values = function values(doc) { + // a year ago + doc.match('!once [a] #Duration', 0).replaceWith('1').tag('Cardinal', here); + if (doc.has('#Value')) { //june 5 to 7th doc.match('#Month #Value to #Value of? #Year?').tag('Date', here); //5 to 7th june @@ -414,8 +417,8 @@ var shiftTagger = function shiftTagger(doc) { if (doc.has('#Date')) { - //two weeks before - doc.match('#Cardinal #Duration (before|after)').tag('#DateShift', here$4); // in two weeks + //'two days before'/ 'nine weeks frow now' + doc.match('#Cardinal #Duration (before|after|ago|from)').tag('#DateShift', here$4); // in two weeks doc.match('in #Cardinal #Duration').tag('#DateShift', here$4); //two weeks and three days before @@ -557,7 +560,7 @@ } }; - /* spencermountain/spacetime 6.6.0 Apache 2.0 */ + /* spencermountain/spacetime 6.6.3 Apache 2.0 */ function createCommonjsModule(fn, module) { return module = { exports: {} @@ -1098,12 +1101,20 @@ var diff = n - current; s.epoch += milliseconds[unit] * diff; //DST edge-case: if we are going many days, be a little conservative + // console.log(unit, diff) - if (unit === 'day' && Math.abs(diff) > 28) { + if (unit === 'day') { + // s.epoch -= ms.minute //but don't push it over a month - if (n < 28) { + if (Math.abs(diff) > 28 && n < 28) { s.epoch += milliseconds.hour; } + } // 1st time: oops, did we change previous unit? revert it. + + + if (previous !== null && startUnit !== s.d[previous]()) { + // console.warn('spacetime warning: missed setting ' + unit) + s.epoch = original; // s.epoch += ms[unit] * diff * 0.89 // maybe try and make it close...? } //repair it if we've gone too far or something //(go by half-steps, just in case) @@ -1116,14 +1127,12 @@ while (s.d[fn]() > n) { s.epoch -= halfStep; - } //oops, did we change previous unit? revert it. + } // 2nd time: did we change previous unit? revert it. if (previous !== null && startUnit !== s.d[previous]()) { // console.warn('spacetime warning: missed setting ' + unit) - s.epoch = original; // i mean, but make it close... - - s.epoch += milliseconds[unit] * diff * 0.89; // i guess? + s.epoch = original; } }; //find the desired date by a increment/check while loop @@ -1239,8 +1248,7 @@ } return; - } // console.log(k, n) - + } units[k].walkTo(s, n); } @@ -1704,41 +1712,51 @@ return s; } }]; - var strParse = strFmt; + var strParse = strFmt; // pull in 'today' data for the baseline moment + + var getNow = function getNow(s) { + s.epoch = Date.now(); + Object.keys(s._today || {}).forEach(function (k) { + if (typeof s[k] === 'function') { + s = s[k](s._today[k]); + } + }); + return s; + }; + var dates = { now: function now(s) { - s.epoch = Date.now(); - return s; - }, - tonight: function tonight(s) { - s.epoch = Date.now(); - s = s.hour(18); - return s; + return getNow(s); }, today: function today(s) { - s.epoch = Date.now(); + return getNow(s); + }, + tonight: function tonight(s) { + s = getNow(s); + s = s.hour(18); //6pm + return s; }, tomorrow: function tomorrow(s) { - s.epoch = Date.now(); + s = getNow(s); s = s.add(1, 'day'); s = s.startOf('day'); return s; }, yesterday: function yesterday(s) { - s.epoch = Date.now(); + s = getNow(s); s = s.subtract(1, 'day'); s = s.startOf('day'); return s; }, christmas: function christmas(s) { - var year = new Date().getFullYear(); + var year = getNow(s).year(); s = s.set([year, 11, 25, 18, 0, 0]); // Dec 25 return s; }, 'new years': function newYears(s) { - var year = new Date().getFullYear(); + var year = getNow(s).year(); s = s.set([year, 11, 31, 18, 0, 0]); // Dec 31 return s; @@ -1815,9 +1833,18 @@ } //set tmp time - s.epoch = Date.now(); + s.epoch = Date.now(); // overwrite tmp time with 'today' value, if exists + + if (s._today && fns.isObject(s._today) && Object.keys(s._today).length > 0) { + var res = handleObject(s, today, defaults); + + if (res.isValid()) { + s.epoch = res.epoch; + } + } // null input means 'now' - if (input === null || input === undefined) { + + if (input === null || input === undefined || input === '') { return s; //k, we're good. } //support input of Date() object @@ -1866,10 +1893,10 @@ var m = input.match(strParse[i].reg); if (m) { - var res = strParse[i].parse(s, m, givenTz); + var _res = strParse[i].parse(s, m, givenTz); - if (res !== null) { - return res; + if (_res !== null) { + return _res; } } } @@ -2173,7 +2200,7 @@ fmt = fmt.toLowerCase().trim(); if (format.hasOwnProperty(fmt)) { - return String(format[fmt](s) || ''); + return String(format[fmt](s)); } return ''; @@ -3277,6 +3304,8 @@ methods$1.each = methods$1.every; var methods_1 = methods$1; //these methods wrap around them. + var isLeapYear$1 = fns.isLeapYear; + var validate = function validate(n) { //handle number as a string if (typeof n === 'string') { @@ -3319,7 +3348,14 @@ var old = s.clone(); var diff = s.minute() - n; var shift = diff * milliseconds.minute; - s.epoch -= shift; + s.epoch -= shift; // check against a screw-up + // if (old.hour() != s.hour()) { + // walkTo(old, { + // minute: n + // }) + // return old.epoch + // } + confirm(s, old, 'second'); return s.epoch; }, @@ -3388,7 +3424,12 @@ n = validate(n); //avoid setting february 31st if (n > 28) { - var max = monthLengths_1[s.month()]; + var month = s.month(); + var max = monthLengths_1[month]; // support leap day in february + + if (month === 1 && n === 29 && isLeapYear$1(s.year())) { + max = 29; + } if (n > max) { n = max; @@ -4055,10 +4096,10 @@ }; var query = addMethods; - var isLeapYear$1 = fns.isLeapYear; + var isLeapYear$2 = fns.isLeapYear; var getMonthLength = function getMonthLength(month, year) { - if (month === 1 && isLeapYear$1(year)) { + if (month === 1 && isLeapYear$2(year)) { return 29; } @@ -4089,7 +4130,8 @@ } return want; - }; + }; // briefly support day=-2 (this does not need to be perfect.) + var rollDaysDown = function rollDaysDown(want, old, sum) { want.year = old.year(); @@ -4546,7 +4588,7 @@ }; var whereIts_1 = whereIts; - var _version = '6.6.0'; + var _version = '6.6.3'; var main$1 = function main(input, tz, options) { return new spacetime(input, tz, options); @@ -4890,7 +4932,7 @@ 'isra and miraj', 'lailat al-qadr', 'eid al-fitr', 'id al-Fitr', 'eid ul-Fitr', 'ramadan', 'eid al-adha', 'muharram', 'the prophets birthday', 'ostara', 'march equinox', 'vernal equinox', 'litha', 'june solistice', 'summer solistice', 'mabon', 'september equinox', 'fall equinox', 'autumnal equinox', 'yule', 'december solstice', 'winter solstice', // Additional important holidays 'chinese new year', 'diwali']; - var times = ['noon', 'midnight', 'now', 'morning', 'tonight', 'evening', 'afternoon', 'night', 'breakfast time', 'lunchtime', 'dinnertime', 'ago', 'sometime', 'eod', 'oclock', 'oclock', 'all day', 'at night']; + var times = ['noon', 'midnight', 'now', 'morning', 'tonight', 'evening', 'afternoon', 'night', 'breakfast time', 'lunchtime', 'dinnertime', 'sometime', 'eod', 'oclock', 'oclock', 'all day', 'at night']; var lex = {}; var data$1 = [[dates$1, '#Date'], [durations, '#Duration'], [holidays, '#Holiday'], [times, '#Time'], [Object.keys(_timezones), '#Timezone']]; @@ -4952,9 +4994,9 @@ result[unit] = num; } } - }); //is it 2 weeks before? → -2 + }); //is it 2 weeks ago? → -2 - if (m.has('before$') === true) { + if (m.has('(before|ago)$') === true) { Object.keys(result).forEach(function (k) { return result[k] *= -1; }); @@ -4967,6 +5009,20 @@ var _01Shift = parseShift; + var hardCoded = { + daybreak: '7:00am', + //ergh + breakfast: '8:00am', + morning: '9:00am', + noon: '12:00pm', + afternoon: '2:00pm', + lunchtime: '12:00pm', + evening: '6:00pm', + dinnertime: '6:00pm', + night: '8:00pm', + midnight: '12:00am' + }; + var halfPast = function halfPast(m, s) { var hour = m.match('#Cardinal$').text('reduced'); var term = m.match('(half|quarter|25|15|10|5)'); @@ -5005,7 +5061,14 @@ time = time.not('(at|by|for|before|sharp)'); time = time.not('on the dot'); var s = spacetime$2.now(context.timezone); - var now = s.clone(); // '5 oclock' + var now = s.clone(); // check for known-times (like 'today') + + var timeStr = time.text('reduced'); + + if (hardCoded.hasOwnProperty(timeStr)) { + return hardCoded[timeStr]; + } // '5 oclock' + var m = time.match('^#Cardinal oclock (am|pm)?'); @@ -5356,6 +5419,7 @@ _this5 = _super5.call(this, input, unit, context); _this5.unit = 'week'; + _this5.d = spacetime$2(context.today, context.timezone); _this5.d = _this5.d.day(input); _this5.weekDay = _this5.d.dayName(); //assume a wednesday in the future @@ -5969,27 +6033,28 @@ var Unit$2 = _units.Unit, Day$1 = _units.Day, - CalendarDate$2 = _units.CalendarDate; + CalendarDate$2 = _units.CalendarDate, + Month$1 = _units.Month; var knownWord = { today: function today(context) { return new Day$1(context.today, null, context); }, yesterday: function yesterday(context) { - new Day$1(context.today.minus(1, 'day'), null, context); + return new Day$1(context.today.minus(1, 'day'), null, context); }, tomorrow: function tomorrow(context) { - new Day$1(context.today.plus(1, 'day'), null, context); + return new Day$1(context.today.plus(1, 'day'), null, context); } }; // parse things like 'june 5th 2019' // most of this is done in spacetime var parseExplicit = function parseExplicit(doc, context) { - var impliedYear = context.today.year(); // 'fifth of june' + var impliedYear = context.today.year(); // 'fifth of june 1992' - var m = doc.match('[#Value] of [#Month] [#Year?]'); // 'june the fifth' + var m = doc.match('[#Value] of? [#Month] [#Year]'); // 'june the fifth 1992' if (!m.found) { - m = doc.match('[#Month] the [#Value] [#Year?]'); + m = doc.match('[#Month] the? [#Value] [#Year]'); } if (m.found) { @@ -6004,28 +6069,87 @@ if (_d.d.isValid() === true) { return _d; } - } + } //no-dates + // 'march 1992' + + + m = doc.match('[#Month] of? [#Year]'); if (m.found) { var _obj = { month: m.groups('month').text(), - date: m.groups('date').text(), - year: context.today.year() + year: m.groups('year').text() || impliedYear }; - var _d2 = new CalendarDate$2(_obj, null, context); + var _d2 = new Month$1(_obj, null, context); if (_d2.d.isValid() === true) { return _d2; } + } //no-years + // 'fifth of june' + + + m = doc.match('[#Value] of? [#Month]'); // 'june the fifth' + + if (!m.found) { + m = doc.match('[#Month] the? [#Value]'); + } // support 'dec 5th' + + + if (m.found) { + var _obj2 = { + month: m.groups('month').text(), + date: m.groups('date').text(), + year: context.today.year() + }; + + var _d3 = new CalendarDate$2(_obj2, null, context); + + if (_d3.d.isValid() === true) { + return _d3; + } + } // support 'december' + + + if (doc.has('#Month')) { + var _obj3 = { + month: doc.match('#Month').text(), + date: 1, + //assume 1st + year: context.today.year() + }; + + var _d4 = new CalendarDate$2(_obj3, null, context); + + if (_d4.d.isValid() === true) { + return _d4; + } + } // support date-only 'the 21st' + + + m = doc.match('the [#Value]'); + + if (m.found) { + var _obj4 = { + month: context.today.month(), + date: m.groups('date').text(), + year: context.today.year() + }; + + var _d5 = new CalendarDate$2(_obj4, null, context); + + if (_d5.d.isValid() === true) { + return _d5; + } } var str = doc.text('reduced'); // today, yesterday, tomorrow if (knownWord.hasOwnProperty(str) === true) { - var _d3 = knownWord[str](context); + var _d6 = knownWord[str](context); - return _d3; + return _d6; } // punt it to spacetime, for the heavy-lifting @@ -6082,6 +6206,16 @@ d = d || steps.explicit(doc, context); + if ((typeof process === "undefined" ? "undefined" : _typeof(process)) !== undefined && process && process.env.DEBUG) { + console.log('\n\n=-=-=-=-=-=Date-=-=-=-=-=-=-'); + console.log(" shift: ".concat(JSON.stringify(shift))); + console.log(" rel: ".concat(rel || '-')); + console.log(" time: ".concat(time || '-')); + console.log("\n str: '".concat(doc.text(), "'")); + console.log('\n ', d); + console.log('=-=-=-=-=-=-=-=-=-=-=-=-=-=-\n\n'); + } + if (!d) { return null; } // // apply relative @@ -6306,7 +6440,7 @@ var d = _03ParseDate(doc, context); return { start: d, - end: null + end: d.clone().end() }; }; diff --git a/plugins/dates/builds/compromise-dates.js.map b/plugins/dates/builds/compromise-dates.js.map index 8b9538518..0e733d230 100644 --- a/plugins/dates/builds/compromise-dates.js.map +++ b/plugins/dates/builds/compromise-dates.js.map @@ -1 +1 @@ -{"version":3,"file":"compromise-dates.js","sources":["../src/01-tag/00-basic.js","../src/01-tag/01-values.js","../src/01-tag/02-dates.js","../src/01-tag/03-sections.js","../src/01-tag/04-time.js","../src/01-tag/05-shifts.js","../src/01-tag/06-fixup.js","../src/01-tag/index.js","../src/data/_tags.js","../node_modules/spacetime/builds/spacetime.mjs","../src/data/_timezones.js","../src/data/words/dates.js","../src/data/words/durations.js","../src/data/words/holidays.js","../src/data/words/times.js","../src/data/words/index.js","../src/02-getDate/00-normalize.js","../src/03-parseDate/sections/01-shift.js","../src/03-parseDate/sections/02-time.js","../src/03-parseDate/sections/03-relative.js","../src/03-parseDate/sections/04-timezone.js","../src/03-parseDate/Unit.js","../src/03-parseDate/_units.js","../src/03-parseDate/steps/00-implied.js","../src/03-parseDate/steps/01-duration.js","../node_modules/spacetime-holiday/builds/spacetime-holiday.js","../src/03-parseDate/steps/02-holidays.js","../src/03-parseDate/steps/03-explicit.js","../src/03-parseDate/index.js","../src/02-getDate/01-parse-range.js","../src/02-getDate/index.js","../src/data/_abbrevs.js","../src/methods.js","../src/index.js"],"sourcesContent":["//ambiguous 'may' and 'march'\nconst preps = '(in|by|before|during|on|until|after|of|within|all)' //6\nconst thisNext = '(last|next|this|previous|current|upcoming|coming)' //2\nconst sections = '(start|end|middle|starting|ending|midpoint|beginning)' //2\nconst seasons = '(spring|summer|winter|fall|autumn)'\n\n//ensure a year is approximately typical for common years\n//please change in one thousand years\nconst tagYear = (m, reason) => {\n if (m.found !== true) {\n return\n }\n let term = m.termList()[0]\n if (term) {\n let num = parseInt(term.clean, 10)\n if (num && num > 1000 && num < 3000) {\n m.tag('Year', reason)\n }\n }\n}\n//same, but for less-confident values\nconst tagYearSafe = (m, reason) => {\n if (m.found !== true) {\n return\n }\n let term = m.termList()[0]\n if (term) {\n let num = parseInt(term.clean, 10)\n if (num && num > 1900 && num < 2030) {\n m.tag('Year', reason)\n }\n }\n}\n\nconst fixDates = function(doc) {\n doc.match('in the (night|evening|morning|afternoon|day|daytime)').tag('Time', 'in-the-night')\n doc.match('(#Value|#Time) (am|pm)').tag('Time', 'value-ampm')\n\n //months:\n let month = doc.if('#Month')\n if (month.found === true) {\n //June 5-7th\n month.match(`#Month #Date+`).tag('Date', 'correction-numberRange')\n //5th of March\n month.match('#Value of #Month').tag('Date', 'value-of-month')\n //5 March\n month.match('#Cardinal #Month').tag('Date', 'cardinal-month')\n //march 5 to 7\n month.match('#Month #Value to #Value').tag('Date', 'value-to-value')\n //march the 12th\n month.match('#Month the #Value').tag('Date', 'month-the-value')\n }\n\n //months:\n let val = doc.if('#Value')\n if (val.found === true) {\n //june 7\n val\n .match('(#WeekDay|#Month) #Value')\n .ifNo('#Money')\n .tag('Date', 'date-value')\n\n //7 june\n val\n .match('#Value (#WeekDay|#Month)')\n .ifNo('#Money')\n .tag('Date', 'value-date')\n\n //may twenty five\n val\n .match('#TextValue #TextValue')\n .if('#Date')\n .tag('#Date', 'textvalue-date')\n\n //eg 'year'\n let duration = val.if('#Duration')\n if (duration.found === true) {\n //for 4 months\n duration.match('for #Value #Duration').tag('Date', 'for-x-duration')\n //two days before\n duration.match('#Value #Duration #Conjunction').tag('Date', 'val-duration-conjunction')\n //for four days\n duration.match(`${preps}? #Value #Duration`).tag('Date', 'value-duration')\n //two years old\n duration.match('#Value #Duration old').unTag('Date', 'val-years-old')\n }\n }\n\n //seasons\n let season = doc.if(seasons)\n if (season.found === true) {\n season.match(`${preps}? ${thisNext} ${seasons}`).tag('Date', 'thisNext-season')\n season.match(`the? ${sections} of ${seasons}`).tag('Date', 'section-season')\n season.match(`${seasons} ${preps}? #Cardinal`).tag('Date', 'season-year')\n }\n\n //rest-dates\n let date = doc.if('#Date')\n if (date.found === true) {\n //june the 5th\n date.match('#Date the? #Ordinal').tag('Date', 'correction')\n //last month\n date.match(`${thisNext} #Date`).tag('Date', 'thisNext')\n //by 5 March\n date.match('due? (by|before|after|until) #Date').tag('Date', 'by')\n //next feb\n date.match('(last|next|this|previous|current|upcoming|coming|the) #Date').tag('Date', 'next-feb')\n //start of june\n date.match(`the? ${sections} of #Date`).tag('Date', 'section-of')\n //fifth week in 1998\n date.match('#Ordinal #Duration in #Date').tag('Date', 'duration-in')\n //early in june\n date.match('(early|late) (at|in)? the? #Date').tag('Time', 'early-evening')\n //tomorrow before 3\n date\n .match('#Date (by|before|after|at|@|about) #Cardinal')\n .not('^#Date')\n .tag('Time', 'date-before-Cardinal')\n //saturday am\n date\n .match('#Date [(am|pm)]', 0)\n .unTag('Verb')\n .unTag('Copula')\n .tag('Time', 'date-am')\n //feb to june\n date\n .match('#Date (#Preposition|to) #Date')\n .ifNo('#Duration')\n .tag('Date', 'date-prep-date')\n }\n\n //year/cardinal tagging\n let cardinal = doc.if('#Cardinal')\n if (cardinal.found === true) {\n let v = cardinal.match(`#Date #Value [#Cardinal]`, 0)\n tagYear(v, 'date-value-year')\n //scoops up a bunch\n v = cardinal.match(`#Date+ [#Cardinal]`, 0)\n tagYear(v, 'date-year')\n //feb 8 2018\n v = cardinal.match(`#Month #Value [#Cardinal]`, 0)\n tagYear(v, 'month-value-year')\n //feb 8 to 10th 2018\n v = cardinal.match(`#Month #Value to #Value [#Cardinal]`, 0)\n tagYear(v, 'month-range-year')\n //in 1998\n v = cardinal.match(`(in|of|by|during|before|starting|ending|for|year) [#Cardinal]`, 0)\n tagYear(v, 'in-year')\n //q2 2009\n v = cardinal.match('(q1|q2|q3|q4) [#Cardinal]', 0)\n tagYear(v, 'in-year')\n //2nd quarter 2009\n v = cardinal.match('#Ordinal quarter [#Cardinal]', 0)\n tagYear(v, 'in-year')\n //in the year 1998\n v = cardinal.match('the year [#Cardinal]', 0)\n tagYear(v, 'in-year')\n //it was 1998\n v = cardinal.match('it (is|was) [#Cardinal]', 0)\n tagYearSafe(v, 'in-year')\n }\n\n let time = doc.if('#Time')\n if (time.found === true) {\n //by 6pm\n time.match('(by|before|after|at|@|about) #Time').tag('Time', 'preposition-time')\n //7 7pm\n time\n .match('#Cardinal #Time')\n .not('#Year')\n .tag('Time', 'value-time')\n //2pm est\n time.match('#Time [(eastern|pacific|central|mountain)]', 0).tag('Date', 'timezone')\n //6pm est\n time.match('#Time [(est|pst|gmt)]', 0).tag('Date', 'timezone abbr')\n }\n\n return doc\n}\nmodule.exports = fixDates\n","const here = 'date-values'\n//\nconst values = function(doc) {\n if (doc.has('#Value')) {\n //june 5 to 7th\n doc.match('#Month #Value to #Value of? #Year?').tag('Date', here);\n //5 to 7th june\n doc.match('#Value to #Value of? #Month #Year?').tag('Date', here);\n //third week of may\n doc.match('#Value #Duration of #Date').tag('Date', here);\n //two days after\n doc.match('#Value+ #Duration (after|before|into|later|afterwards|ago)?').tag('Date', here);\n //two days\n doc.match('#Value #Date').tag('Date', here);\n //june 5th\n doc.match('#Date #Value').tag('Date', here);\n //tuesday at 5\n doc.match('#Date #Preposition #Value').tag('Date', here);\n //tomorrow before 3\n doc.match('#Date (after|before|during|on|in) #Value').tag('Date', here);\n //a year and a half\n doc.match('#Value (year|month|week|day) and a half').tag('Date', here);\n //5 and a half years\n doc.match('#Value and a half (years|months|weeks|days)').tag('Date', here);\n //on the fifth\n doc.match('on the #Ordinal').tag('Date', here);\n }\n return doc\n}\nmodule.exports = values\n","const here = 'date-tagger'\n//\nconst dateTagger = function(doc) {\n\n doc.match('(spring|summer|winter|fall|autumn|springtime|wintertime|summertime)').match('#Noun').tag('Season', here)\n doc.match('(q1|q2|q3|q4)').tag('FinancialQuarter', here)\n doc.match('(this|next|last|current) quarter').tag('FinancialQuarter', here)\n doc.match('(this|next|last|current) season').tag('Season', here)\n\n if (doc.has('#Date')) {\n //friday to sunday\n doc.match('#Date #Preposition #Date').tag('Date', here);\n //once a day..\n doc.match('(once|twice) (a|an|each) #Date').tag('Date', here);\n //TODO:fixme\n doc.match('(by|until|on|in|at|during|over|every|each|due) the? #Date').tag('Date', here);\n //tuesday\n doc.match('#Date+').tag('Date', here);\n //by June\n doc.match('(by|until|on|in|at|during|over|every|each|due) the? #Date').tag('Date', here);\n //a year after..\n doc.match('a #Duration').tag('Date', here);\n //between x and y\n doc.match('(between|from) #Date').tag('Date', here);\n doc.match('(to|until|upto) #Date').tag('Date', here);\n doc.match('#Date and #Date').tag('Date', here);\n //during this june\n doc.match('(by|until|after|before|during|on|in|following) (next|this|last)? (#Date|#Date)').tag('Date', here);\n //day after next\n doc.match('the? #Date after next one?').tag('Date', here);\n //approximately...\n doc.match('(about|approx|approximately|around) #Date').tag('Date', here);\n }\n return doc\n}\nmodule.exports = dateTagger\n","const here = 'section-tagger'\n//\nconst sectionTagger = function(doc) {\n if (doc.has('#Date')) {\n // //next september\n doc.match('this? (last|next|past|this|previous|current|upcoming|coming|the) #Date').tag('Date', here);\n //starting this june\n doc.match('(starting|beginning|ending) #Date').tag('Date', here);\n //start of june\n doc.match('the? (start|end|middle|beginning) of (last|next|this|the) (#Date|#Date)').tag('Date', here);\n //this coming june\n doc.match('(the|this) #Date').tag('Date', here);\n }\n return doc\n}\nmodule.exports = sectionTagger\n","const here = 'time-tagger'\n\n//\nconst timeTagger = function (doc) {\n // quarter to seven (not march 5 to 7)\n if (doc.has('#Cardinal') && !doc.has('#Month')) {\n doc.match('(half|quarter|25|15|10|5) (past|after|to) #Cardinal').tag('Time', here)\n }\n //timezone\n if (doc.has('#Date')) {\n //eastern daylight time\n doc.match('#Noun (standard|daylight|central|mountain)? time').tag('Timezone', here)\n //utc+5\n doc.match('/^utc[+-][0-9]/').tag('Timezone', here)\n doc.match('/^gmt[+-][0-9]/').tag('Timezone', here)\n\n doc.match('(in|for|by|near|at) #Timezone').tag('Timezone', here)\n\n // https://raw.githubusercontent.com/davispuh/TimezoneParser/master/data/abbreviations.yml\n // let abbr =\n // '(acdt|acst|ace|dmt|ist|tse|addt|adt|aedt|aest|ahdt|ahst|akdt|akst|amt|nst|apt|awt|gmt|awdt|awst|bdst|bst|bdt|nwt|bmt|wet|bost|cddt|cdt|cet|cmt|cpt|cst|cwt|chst|gst|eat|eddt|edt|eest|eet|emt|ept|ewt|est|ffmt|fmt|hdt|hst|hkst|hkt|hmt|iddt|idt|jmt|imt|jdt|jst|kdt|kst|kmt|lst|mddt|mdst|msd|msk|mdt|mmt|mpt|pdt|pst|mst|mwt|nddt|ndt|npt|nzdt|nzmt|nzst|pddt|pkst|pkt|plmt|pmmt|pmt|ppmt|ppt|pwt|qmt|rmt|sast|sdmt|set|sjmt|smt|sst|tbmt|tmt|utc|wast|wemt|wib|wit|wita|wmt|yddt|ydt|ypt|ywt|yst)'\n // doc.match(abbr).tag('Timezone', here)\n }\n return doc\n}\nmodule.exports = timeTagger\n","const here = 'shift-tagger'\n//\nconst shiftTagger = function(doc) {\n if (doc.has('#Date')) {\n //two weeks before\n doc.match('#Cardinal #Duration (before|after)').tag('#DateShift', here)\n // in two weeks\n doc.match('in #Cardinal #Duration').tag('#DateShift', here)\n //two weeks and three days before\n doc.match('#Cardinal #Duration and? #DateShift').tag('#DateShift', here)\n doc.match('#DateShift and #Cardinal #Duration').tag('#DateShift', here)\n // doc.match('#Cardinal #Duration and? #DateShift').tag('#DateShift', here)\n }\n return doc\n}\nmodule.exports = shiftTagger\n","const here = 'fix-tagger'\n//\nconst fixUp = function (doc) {\n //fixups\n if (doc.has('#Date')) {\n //first day by monday\n let oops = doc.match('#Date+ by #Date+')\n if (oops.found && !oops.has('^due')) {\n oops.match('^#Date+').unTag('Date', 'by-monday')\n }\n\n let d = doc.match('#Date+')\n //'spa day'\n d.match('^day$').unTag('Date', 'spa-day')\n // tomorrow's meeting\n d.match('(in|of|by|for)? (#Possessive && #Date)').unTag('Date', 'tomorrows meeting')\n\n let knownDate = '(yesterday|today|tomorrow)'\n if (d.has(knownDate)) {\n //yesterday 7\n d.match(`${knownDate} [#Value]$`).unTag('Date', 'yesterday-7')\n //7 yesterday\n d.match(`^[#Value] ${knownDate}$`, 0).unTag('Date', '7 yesterday')\n //friday yesterday\n d.match(`#WeekDay+ ${knownDate}$`).unTag('Date').lastTerm().tag('Date', 'fri-yesterday')\n\n // yesterday yesterday\n // d.match(`${knownDate}+ ${knownDate}$`)\n // .unTag('Date')\n // .lastTerm()\n // .tag('Date', here)\n d.match(`(this|last|next) #Date ${knownDate}$`).unTag('Date').lastTerm().tag('Date', 'this month yesterday')\n }\n //tomorrow on 5\n d.match(`on #Cardinal$`).unTag('Date', here)\n //this tomorrow\n d.match(`this tomorrow`).terms(0).unTag('Date', 'this-tomorrow')\n //q2 2019\n d.match(`(q1|q2|q3|q4) #Year`).tag('Date', here)\n //5 tuesday\n // d.match(`^#Value #WeekDay`).terms(0).unTag('Date');\n //5 next week\n d.match(`^#Value (this|next|last)`).terms(0).unTag('Date', here)\n\n if (d.has('(last|this|next)')) {\n //this month 7\n d.match(`(last|this|next) #Duration #Value`).terms(2).unTag('Date', here)\n //7 this month\n d.match(`!#Month #Value (last|this|next) #Date`).terms(0).unTag('Date', here)\n }\n //january 5 5\n if (d.has('(#Year|#Time|#TextValue|#NumberRange)') === false) {\n d.match('(#Month|#WeekDay) #Value #Value').terms(2).unTag('Date', here)\n }\n //between june\n if (d.has('^between') && !d.has('and .')) {\n d.unTag('Date', here)\n }\n //june june\n if (d.has('#Month #Month') && !d.has('@hasHyphen') && !d.has('@hasComma')) {\n d.match('#Month').lastTerm().unTag('Date', 'month-month')\n }\n // log the hours\n if (d.has('(minutes|seconds|weeks|hours|days|months)') && !d.has('#Value #Duration')) {\n d.match('(minutes|seconds|weeks|hours|days|months)').unTag('#Date', 'log-hours')\n }\n // about thanksgiving\n if (d.has('about #Holiday')) {\n d.match('about').unTag('#Date', 'about-thanksgiving')\n }\n // dangling date-chunks\n // if (d.has('!#Date (in|of|by|for) !#Date')) {\n // d.unTag('Date', 'dangling-date')\n // }\n }\n return doc\n}\nmodule.exports = fixUp\n","const methods = [\n require('./00-basic'),\n require('./01-values'),\n require('./02-dates'),\n require('./03-sections'),\n require('./04-time'),\n require('./05-shifts'),\n require('./06-fixup'),\n]\n// run each of the taggers\nconst tagDate = function (doc) {\n methods.forEach((fn) => fn(doc))\n return doc\n}\nmodule.exports = tagDate\n","module.exports = {\n FinancialQuarter: {\n isA: 'Date',\n },\n // 'summer'\n Season: {\n isA: 'Date',\n },\n // '1982'\n Year: {\n isA: ['Date'],\n notA: 'RomanNumeral',\n },\n // 'months'\n Duration: {\n isA: ['Date', 'Noun'],\n },\n // 'easter'\n Holiday: {\n isA: ['Date', 'Noun'],\n },\n // 'PST'\n Timezone: {\n isA: ['Date', 'Noun'],\n },\n // 'two weeks before'\n DateShift: {\n isA: ['Date'],\n },\n}\n","/* spencermountain/spacetime 6.6.0 Apache 2.0 */\nfunction createCommonjsModule(fn, module) {\n\treturn module = { exports: {} }, fn(module, module.exports), module.exports;\n}\n\nfunction getCjsExportFromNamespace (n) {\n\treturn n && n['default'] || n;\n}\n\nvar fns = createCommonjsModule(function (module, exports) {\n //git:blame @JuliasCaesar https://www.timeanddate.com/date/leapyear.html\n exports.isLeapYear = function (year) {\n return year % 4 === 0 && year % 100 !== 0 || year % 400 === 0;\n }; // unsurprisingly-nasty `typeof date` call\n\n\n exports.isDate = function (d) {\n return Object.prototype.toString.call(d) === '[object Date]' && !isNaN(d.valueOf());\n };\n\n exports.isArray = function (input) {\n return Object.prototype.toString.call(input) === '[object Array]';\n };\n\n exports.isObject = function (input) {\n return Object.prototype.toString.call(input) === '[object Object]';\n };\n\n exports.zeroPad = function (str) {\n var len = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 2;\n var pad = '0';\n str = str + '';\n return str.length >= len ? str : new Array(len - str.length + 1).join(pad) + str;\n };\n\n exports.titleCase = function (str) {\n if (!str) {\n return '';\n }\n\n return str[0].toUpperCase() + str.substr(1);\n };\n\n exports.ordinal = function (i) {\n var j = i % 10;\n var k = i % 100;\n\n if (j === 1 && k !== 11) {\n return i + 'st';\n }\n\n if (j === 2 && k !== 12) {\n return i + 'nd';\n }\n\n if (j === 3 && k !== 13) {\n return i + 'rd';\n }\n\n return i + 'th';\n }; //strip 'st' off '1st'..\n\n\n exports.toCardinal = function (str) {\n str = String(str);\n str = str.replace(/([0-9])(st|nd|rd|th)$/i, '$1');\n return parseInt(str, 10);\n }; //used mostly for cleanup of unit names, like 'months'\n\n\n exports.normalize = function () {\n var str = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';\n str = str.toLowerCase().trim();\n str = str.replace(/ies$/, 'y'); //'centuries'\n\n str = str.replace(/s$/, '');\n str = str.replace(/-/g, '');\n\n if (str === 'day') {\n return 'date';\n }\n\n return str;\n };\n\n exports.getEpoch = function (tmp) {\n //support epoch\n if (typeof tmp === 'number') {\n return tmp;\n } //suport date objects\n\n\n if (exports.isDate(tmp)) {\n return tmp.getTime();\n }\n\n if (tmp.epoch) {\n return tmp.epoch;\n }\n\n return null;\n }; //make sure this input is a spacetime obj\n\n\n exports.beADate = function (d, s) {\n if (exports.isObject(d) === false) {\n return s.clone().set(d);\n }\n\n return d;\n };\n\n exports.formatTimezone = function (offset) {\n var delimiter = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';\n var absOffset = Math.abs(offset);\n var sign = offset > 0 ? '+' : '-';\n return \"\".concat(sign).concat(exports.zeroPad(absOffset)).concat(delimiter, \"00\");\n };\n});\nvar fns_1 = fns.isLeapYear;\nvar fns_2 = fns.isDate;\nvar fns_3 = fns.isArray;\nvar fns_4 = fns.isObject;\nvar fns_5 = fns.zeroPad;\nvar fns_6 = fns.titleCase;\nvar fns_7 = fns.ordinal;\nvar fns_8 = fns.toCardinal;\nvar fns_9 = fns.normalize;\nvar fns_10 = fns.getEpoch;\nvar fns_11 = fns.beADate;\nvar fns_12 = fns.formatTimezone;\n\nvar zeroPad = fns.zeroPad;\n\nvar serialize = function serialize(d) {\n return zeroPad(d.getMonth() + 1) + '/' + zeroPad(d.getDate()) + ':' + zeroPad(d.getHours());\n}; // a timezone will begin with a specific offset in january\n// then some will switch to something else between november-march\n\n\nvar shouldChange = function shouldChange(epoch, start, end, defaultOffset) {\n //note: this has a cray order-of-operations issue\n //we can't get the date, without knowing the timezone, and vice-versa\n //it's possible that we can miss a dst-change by a few hours.\n var d = new Date(epoch); //(try to mediate this a little?)\n\n var bias = d.getTimezoneOffset() || 0;\n var shift = bias + defaultOffset * 60; //in minutes\n\n shift = shift * 60 * 1000; //in ms\n\n d = new Date(epoch + shift);\n var current = serialize(d); //eg. is it after ~november?\n\n if (current >= start) {\n //eg. is it before ~march~ too?\n if (current < end) {\n return true;\n }\n }\n\n return false;\n};\n\nvar summerTime = shouldChange;\n\n// it reproduces some things in ./index.js, but speeds up spacetime considerably\n\nvar quickOffset = function quickOffset(s) {\n var zones = s.timezones;\n var obj = zones[s.tz];\n\n if (obj === undefined) {\n console.warn(\"Warning: couldn't find timezone \" + s.tz);\n return 0;\n }\n\n if (obj.dst === undefined) {\n return obj.offset;\n } //get our two possible offsets\n\n\n var jul = obj.offset;\n var dec = obj.offset + 1; // assume it's the same for now\n\n if (obj.hem === 'n') {\n dec = jul - 1;\n }\n\n var split = obj.dst.split('->');\n var inSummer = summerTime(s.epoch, split[0], split[1], jul);\n\n if (inSummer === true) {\n return jul;\n }\n\n return dec;\n};\n\nvar quick = quickOffset;\n\nvar _build = {\n\t\"9|s\": \"2/dili,2/jayapura\",\n\t\"9|n\": \"2/chita,2/khandyga,2/pyongyang,2/seoul,2/tokyo,11/palau\",\n\t\"9.5|s|04/05:03->10/04:02\": \"4/adelaide,4/broken_hill,4/south,4/yancowinna\",\n\t\"9.5|s\": \"4/darwin,4/north\",\n\t\"8|s\": \"12/casey,2/kuala_lumpur,2/makassar,2/singapore,4/perth,4/west\",\n\t\"8|n|03/25:03->09/29:23\": \"2/ulan_bator\",\n\t\"8|n\": \"2/brunei,2/choibalsan,2/chongqing,2/chungking,2/harbin,2/hong_kong,2/irkutsk,2/kuching,2/macao,2/macau,2/manila,2/shanghai,2/taipei,2/ujung_pandang,2/ulaanbaatar\",\n\t\"8.75|s\": \"4/eucla\",\n\t\"7|s\": \"12/davis,2/jakarta,9/christmas\",\n\t\"7|n\": \"2/bangkok,2/barnaul,2/ho_chi_minh,2/hovd,2/krasnoyarsk,2/novokuznetsk,2/novosibirsk,2/phnom_penh,2/pontianak,2/saigon,2/tomsk,2/vientiane\",\n\t\"6|s\": \"12/vostok\",\n\t\"6|n\": \"2/almaty,2/bishkek,2/dacca,2/dhaka,2/kashgar,2/omsk,2/qyzylorda,2/thimbu,2/thimphu,2/urumqi,9/chagos\",\n\t\"6.5|n\": \"2/rangoon,2/yangon,9/cocos\",\n\t\"5|s\": \"12/mawson,9/kerguelen\",\n\t\"5|n\": \"2/aqtau,2/aqtobe,2/ashgabat,2/ashkhabad,2/atyrau,2/baku,2/dushanbe,2/karachi,2/oral,2/samarkand,2/tashkent,2/yekaterinburg,9/maldives\",\n\t\"5.75|n\": \"2/kathmandu,2/katmandu\",\n\t\"5.5|n\": \"2/calcutta,2/colombo,2/kolkata\",\n\t\"4|s\": \"9/reunion\",\n\t\"4|n\": \"2/dubai,2/muscat,2/tbilisi,2/yerevan,8/astrakhan,8/samara,8/saratov,8/ulyanovsk,8/volgograd,2/volgograd,9/mahe,9/mauritius\",\n\t\"4.5|n|03/21:00->09/20:24\": \"2/tehran\",\n\t\"4.5|n\": \"2/kabul\",\n\t\"3|s\": \"12/syowa,9/antananarivo\",\n\t\"3|n|03/29:03->10/25:04\": \"2/famagusta,2/nicosia,8/athens,8/bucharest,8/helsinki,8/kiev,8/mariehamn,8/nicosia,8/riga,8/sofia,8/tallinn,8/uzhgorod,8/vilnius,8/zaporozhye\",\n\t\"3|n|03/29:02->10/25:03\": \"8/chisinau,8/tiraspol\",\n\t\"3|n|03/29:00->10/24:24\": \"2/beirut\",\n\t\"3|n|03/27:02->10/25:02\": \"2/jerusalem,2/tel_aviv\",\n\t\"3|n|03/27:00->10/31:01\": \"2/gaza,2/hebron\",\n\t\"3|n|03/27:00->10/30:01\": \"2/amman\",\n\t\"3|n|03/27:00->10/29:24\": \"2/damascus\",\n\t\"3|n\": \"0/addis_ababa,0/asmara,0/asmera,0/dar_es_salaam,0/djibouti,0/juba,0/kampala,0/mogadishu,0/nairobi,2/aden,2/baghdad,2/bahrain,2/istanbul,2/kuwait,2/qatar,2/riyadh,8/istanbul,8/kirov,8/minsk,8/moscow,8/simferopol,9/comoro,9/mayotte\",\n\t\"2|s|03/29:02->10/25:02\": \"12/troll\",\n\t\"2|s\": \"0/gaborone,0/harare,0/johannesburg,0/lubumbashi,0/lusaka,0/maputo,0/maseru,0/mbabane\",\n\t\"2|n|03/29:02->10/25:03\": \"0/ceuta,arctic/longyearbyen,3/jan_mayen,8/amsterdam,8/andorra,8/belgrade,8/berlin,8/bratislava,8/brussels,8/budapest,8/busingen,8/copenhagen,8/gibraltar,8/ljubljana,8/luxembourg,8/madrid,8/malta,8/monaco,8/oslo,8/paris,8/podgorica,8/prague,8/rome,8/san_marino,8/sarajevo,8/skopje,8/stockholm,8/tirane,8/vaduz,8/vatican,8/vienna,8/warsaw,8/zagreb,8/zurich\",\n\t\"2|n\": \"0/blantyre,0/bujumbura,0/cairo,0/khartoum,0/kigali,0/tripoli,8/kaliningrad\",\n\t\"1|s|04/02:01->09/03:03\": \"0/windhoek\",\n\t\"1|s\": \"0/kinshasa,0/luanda\",\n\t\"1|n|04/19:03->05/31:02\": \"0/casablanca,0/el_aaiun\",\n\t\"1|n|03/29:01->10/25:02\": \"3/canary,3/faeroe,3/faroe,3/madeira,8/belfast,8/dublin,8/guernsey,8/isle_of_man,8/jersey,8/lisbon,8/london\",\n\t\"1|n\": \"0/algiers,0/bangui,0/brazzaville,0/douala,0/lagos,0/libreville,0/malabo,0/ndjamena,0/niamey,0/porto-novo,0/tunis\",\n\t\"14|n\": \"11/kiritimati\",\n\t\"13|s|04/05:04->09/27:03\": \"11/apia\",\n\t\"13|s|01/15:02->11/05:03\": \"11/tongatapu\",\n\t\"13|n\": \"11/enderbury,11/fakaofo\",\n\t\"12|s|04/05:03->09/27:02\": \"12/mcmurdo,12/south_pole,11/auckland\",\n\t\"12|s|01/12:03->11/08:02\": \"11/fiji\",\n\t\"12|n\": \"2/anadyr,2/kamchatka,2/srednekolymsk,11/funafuti,11/kwajalein,11/majuro,11/nauru,11/tarawa,11/wake,11/wallis\",\n\t\"12.75|s|04/05:03->04/05:02\": \"11/chatham\",\n\t\"11|s\": \"12/macquarie,11/bougainville\",\n\t\"11|n\": \"2/magadan,2/sakhalin,11/efate,11/guadalcanal,11/kosrae,11/noumea,11/pohnpei,11/ponape\",\n\t\"11.5|n|04/05:03->10/04:02\": \"11/norfolk\",\n\t\"10|s|04/05:03->10/04:02\": \"4/act,4/canberra,4/currie,4/hobart,4/melbourne,4/nsw,4/sydney,4/tasmania,4/victoria\",\n\t\"10|s\": \"12/dumontdurville,4/brisbane,4/lindeman,4/queensland\",\n\t\"10|n\": \"2/ust-nera,2/vladivostok,2/yakutsk,11/chuuk,11/guam,11/port_moresby,11/saipan,11/truk,11/yap\",\n\t\"10.5|s|04/05:01->10/04:02\": \"4/lhi,4/lord_howe\",\n\t\"0|n|03/29:00->10/25:01\": \"1/scoresbysund,3/azores\",\n\t\"0|n\": \"0/abidjan,0/accra,0/bamako,0/banjul,0/bissau,0/conakry,0/dakar,0/freetown,0/lome,0/monrovia,0/nouakchott,0/ouagadougou,0/sao_tome,0/timbuktu,1/danmarkshavn,3/reykjavik,3/st_helena,13/gmt,13/gmt+0,13/gmt-0,13/gmt0,13/greenwich,13/utc,13/universal,13/zulu\",\n\t\"-9|n|03/08:02->11/01:02\": \"1/adak,1/atka\",\n\t\"-9|n\": \"11/gambier\",\n\t\"-9.5|n\": \"11/marquesas\",\n\t\"-8|n|03/08:02->11/01:02\": \"1/anchorage,1/juneau,1/metlakatla,1/nome,1/sitka,1/yakutat\",\n\t\"-8|n\": \"11/pitcairn\",\n\t\"-7|n|03/08:02->11/01:02\": \"1/dawson,1/ensenada,1/los_angeles,1/santa_isabel,1/tijuana,1/vancouver,1/whitehorse,6/pacific,6/yukon,10/bajanorte\",\n\t\"-7|n\": \"1/creston,1/dawson_creek,1/hermosillo,1/phoenix\",\n\t\"-6|s|04/04:22->09/05:22\": \"7/easterisland,11/easter\",\n\t\"-6|n|04/05:02->10/25:02\": \"1/chihuahua,1/mazatlan,10/bajasur\",\n\t\"-6|n|03/08:02->11/01:02\": \"1/boise,1/cambridge_bay,1/denver,1/edmonton,1/inuvik,1/ojinaga,1/shiprock,1/yellowknife,6/mountain\",\n\t\"-6|n\": \"1/belize,1/costa_rica,1/el_salvador,1/guatemala,1/managua,1/regina,1/swift_current,1/tegucigalpa,6/east-saskatchewan,6/saskatchewan,11/galapagos\",\n\t\"-5|s\": \"1/lima,1/rio_branco,5/acre\",\n\t\"-5|n|04/05:02->10/25:02\": \"1/bahia_banderas,1/merida,1/mexico_city,1/monterrey,10/general\",\n\t\"-5|n|03/12:03->11/05:01\": \"1/north_dakota\",\n\t\"-5|n|03/08:02->11/01:02\": \"1/chicago,1/knox_in,1/matamoros,1/menominee,1/rainy_river,1/rankin_inlet,1/resolute,1/winnipeg,6/central\",\n\t\"-5|n\": \"1/atikokan,1/bogota,1/cancun,1/cayman,1/coral_harbour,1/eirunepe,1/guayaquil,1/jamaica,1/panama,1/porto_acre\",\n\t\"-4|s|05/13:23->08/13:01\": \"12/palmer\",\n\t\"-4|s|04/04:24->09/06:00\": \"1/santiago,7/continental\",\n\t\"-4|s|03/21:24->10/04:00\": \"1/asuncion\",\n\t\"-4|s|02/16:24->11/03:00\": \"1/campo_grande,1/cuiaba\",\n\t\"-4|s\": \"1/la_paz,1/manaus,5/west\",\n\t\"-4|n|03/12:03->11/05:01\": \"1/indiana,1/kentucky\",\n\t\"-4|n|03/08:02->11/01:02\": \"1/detroit,1/fort_wayne,1/grand_turk,1/indianapolis,1/iqaluit,1/louisville,1/montreal,1/nassau,1/new_york,1/nipigon,1/pangnirtung,1/port-au-prince,1/thunder_bay,1/toronto,6/eastern\",\n\t\"-4|n|03/08:00->11/01:01\": \"1/havana\",\n\t\"-4|n\": \"1/anguilla,1/antigua,1/aruba,1/barbados,1/blanc-sablon,1/boa_vista,1/caracas,1/curacao,1/dominica,1/grenada,1/guadeloupe,1/guyana,1/kralendijk,1/lower_princes,1/marigot,1/martinique,1/montserrat,1/port_of_spain,1/porto_velho,1/puerto_rico,1/santo_domingo,1/st_barthelemy,1/st_kitts,1/st_lucia,1/st_thomas,1/st_vincent,1/tortola,1/virgin\",\n\t\"-3|s\": \"1/argentina,1/buenos_aires,1/cordoba,1/fortaleza,1/montevideo,1/punta_arenas,1/sao_paulo,12/rothera,3/stanley,5/east\",\n\t\"-3|n|03/08:02->11/01:02\": \"1/glace_bay,1/goose_bay,1/halifax,1/moncton,1/thule,3/bermuda,6/atlantic\",\n\t\"-3|n\": \"1/araguaina,1/bahia,1/belem,1/catamarca,1/cayenne,1/jujuy,1/maceio,1/mendoza,1/paramaribo,1/recife,1/rosario,1/santarem\",\n\t\"-2|s\": \"5/denoronha\",\n\t\"-2|n|03/28:22->10/24:23\": \"1/godthab\",\n\t\"-2|n|03/08:02->11/01:02\": \"1/miquelon\",\n\t\"-2|n\": \"1/noronha,3/south_georgia\",\n\t\"-2.5|n|03/08:02->11/01:02\": \"1/st_johns,6/newfoundland\",\n\t\"-1|n\": \"3/cape_verde\",\n\t\"-11|n\": \"11/midway,11/niue,11/pago_pago,11/samoa\",\n\t\"-10|n\": \"11/honolulu,11/johnston,11/rarotonga,11/tahiti\"\n};\n\nvar _build$1 = /*#__PURE__*/Object.freeze({\n\t__proto__: null,\n\t'default': _build\n});\n\n//prefixes for iana names..\nvar _prefixes = ['africa', 'america', 'asia', 'atlantic', 'australia', 'brazil', 'canada', 'chile', 'europe', 'indian', 'mexico', 'pacific', 'antarctica', 'etc'];\n\nvar data = getCjsExportFromNamespace(_build$1);\n\nvar all = {};\nObject.keys(data).forEach(function (k) {\n var split = k.split('|');\n var obj = {\n offset: Number(split[0]),\n hem: split[1]\n };\n\n if (split[2]) {\n obj.dst = split[2];\n }\n\n var names = data[k].split(',');\n names.forEach(function (str) {\n str = str.replace(/(^[0-9]+)\\//, function (before, num) {\n num = Number(num);\n return _prefixes[num] + '/';\n });\n all[str] = obj;\n });\n});\nall['utc'] = {\n offset: 0,\n hem: 'n' //(sorry)\n\n}; //add etc/gmt+n\n\nfor (var i = -14; i <= 14; i += 0.5) {\n var num = i;\n\n if (num > 0) {\n num = '+' + num;\n }\n\n var name = 'etc/gmt' + num;\n all[name] = {\n offset: i * -1,\n //they're negative!\n hem: 'n' //(sorry)\n\n };\n name = 'utc/gmt' + num; //this one too, why not.\n\n all[name] = {\n offset: i * -1,\n hem: 'n'\n };\n} // console.log(all)\n// console.log(Object.keys(all).length)\n\n\nvar unpack = all;\n\n//find the implicit iana code for this machine.\n//safely query the Intl object\n//based on - https://bitbucket.org/pellepim/jstimezonedetect/src\nvar fallbackTZ = 'utc'; //\n//this Intl object is not supported often, yet\n\nvar safeIntl = function safeIntl() {\n if (typeof Intl === 'undefined' || typeof Intl.DateTimeFormat === 'undefined') {\n return null;\n }\n\n var format = Intl.DateTimeFormat();\n\n if (typeof format === 'undefined' || typeof format.resolvedOptions === 'undefined') {\n return null;\n }\n\n var timezone = format.resolvedOptions().timeZone;\n\n if (!timezone) {\n return null;\n }\n\n return timezone.toLowerCase();\n};\n\nvar guessTz = function guessTz() {\n var timezone = safeIntl();\n\n if (timezone === null) {\n return fallbackTZ;\n }\n\n return timezone;\n}; //do it once per computer\n\n\nvar guessTz_1 = guessTz;\n\nvar isOffset = /(\\-?[0-9]+)h(rs)?/i;\nvar isNumber = /(\\-?[0-9]+)/;\nvar utcOffset = /utc([\\-+]?[0-9]+)/i;\nvar gmtOffset = /gmt([\\-+]?[0-9]+)/i;\n\nvar toIana = function toIana(num) {\n num = Number(num);\n\n if (num > -13 && num < 13) {\n num = num * -1; //it's opposite!\n\n num = (num > 0 ? '+' : '') + num; //add plus sign\n\n return 'etc/gmt' + num;\n }\n\n return null;\n};\n\nvar parseOffset = function parseOffset(tz) {\n // '+5hrs'\n var m = tz.match(isOffset);\n\n if (m !== null) {\n return toIana(m[1]);\n } // 'utc+5'\n\n\n m = tz.match(utcOffset);\n\n if (m !== null) {\n return toIana(m[1]);\n } // 'GMT-5' (not opposite)\n\n\n m = tz.match(gmtOffset);\n\n if (m !== null) {\n var num = Number(m[1]) * -1;\n return toIana(num);\n } // '+5'\n\n\n m = tz.match(isNumber);\n\n if (m !== null) {\n return toIana(m[1]);\n }\n\n return null;\n};\n\nvar parseOffset_1 = parseOffset;\n\nvar local = guessTz_1(); //add all the city names by themselves\n\nvar cities = Object.keys(unpack).reduce(function (h, k) {\n var city = k.split('/')[1] || '';\n city = city.replace(/_/g, ' ');\n h[city] = k;\n return h;\n}, {}); //try to match these against iana form\n\nvar normalize = function normalize(tz) {\n tz = tz.replace(/ time/g, '');\n tz = tz.replace(/ (standard|daylight|summer)/g, '');\n tz = tz.replace(/\\b(east|west|north|south)ern/g, '$1');\n tz = tz.replace(/\\b(africa|america|australia)n/g, '$1');\n tz = tz.replace(/\\beuropean/g, 'europe');\n tz = tz.replace(/\\islands/g, 'island');\n return tz;\n}; // try our best to reconcile the timzone to this given string\n\n\nvar lookupTz = function lookupTz(str, zones) {\n if (!str) {\n return local;\n }\n\n var tz = str.trim();\n var split = str.split('/'); //support long timezones like 'America/Argentina/Rio_Gallegos'\n\n if (split.length > 2 && zones.hasOwnProperty(tz) === false) {\n tz = split[0] + '/' + split[1];\n }\n\n tz = tz.toLowerCase();\n\n if (zones.hasOwnProperty(tz) === true) {\n return tz;\n } //lookup more loosely..\n\n\n tz = normalize(tz);\n\n if (zones.hasOwnProperty(tz) === true) {\n return tz;\n } //try city-names\n\n\n if (cities.hasOwnProperty(tz) === true) {\n return cities[tz];\n } // //try to parse '-5h'\n\n\n if (/[0-9]/.test(tz) === true) {\n var id = parseOffset_1(tz);\n\n if (id) {\n return id;\n }\n }\n\n throw new Error(\"Spacetime: Cannot find timezone named: '\" + str + \"'. Please enter an IANA timezone id.\");\n};\n\nvar find = lookupTz;\n\nvar o = {\n millisecond: 1\n};\no.second = 1000;\no.minute = 60000;\no.hour = 3.6e6; // dst is supported post-hoc\n\no.day = 8.64e7; //\n\no.date = o.day;\no.month = 8.64e7 * 29.5; //(average)\n\no.week = 6.048e8;\no.year = 3.154e10; // leap-years are supported post-hoc\n//add plurals\n\nObject.keys(o).forEach(function (k) {\n o[k + 's'] = o[k];\n});\nvar milliseconds = o;\n\nvar walk = function walk(s, n, fn, unit, previous) {\n var current = s.d[fn]();\n\n if (current === n) {\n return; //already there\n }\n\n var startUnit = previous === null ? null : s.d[previous]();\n var original = s.epoch; //try to get it as close as we can\n\n var diff = n - current;\n s.epoch += milliseconds[unit] * diff; //DST edge-case: if we are going many days, be a little conservative\n\n if (unit === 'day' && Math.abs(diff) > 28) {\n //but don't push it over a month\n if (n < 28) {\n s.epoch += milliseconds.hour;\n }\n } //repair it if we've gone too far or something\n //(go by half-steps, just in case)\n\n\n var halfStep = milliseconds[unit] / 2;\n\n while (s.d[fn]() < n) {\n s.epoch += halfStep;\n }\n\n while (s.d[fn]() > n) {\n s.epoch -= halfStep;\n } //oops, did we change previous unit? revert it.\n\n\n if (previous !== null && startUnit !== s.d[previous]()) {\n // console.warn('spacetime warning: missed setting ' + unit)\n s.epoch = original; // i mean, but make it close...\n\n s.epoch += milliseconds[unit] * diff * 0.89; // i guess?\n }\n}; //find the desired date by a increment/check while loop\n\n\nvar units = {\n year: {\n valid: function valid(n) {\n return n > -4000 && n < 4000;\n },\n walkTo: function walkTo(s, n) {\n return walk(s, n, 'getFullYear', 'year', null);\n }\n },\n month: {\n valid: function valid(n) {\n return n >= 0 && n <= 11;\n },\n walkTo: function walkTo(s, n) {\n var d = s.d;\n var current = d.getMonth();\n var original = s.epoch;\n var startUnit = d.getFullYear();\n\n if (current === n) {\n return;\n } //try to get it as close as we can..\n\n\n var diff = n - current;\n s.epoch += milliseconds.day * (diff * 28); //special case\n //oops, did we change the year? revert it.\n\n if (startUnit !== s.d.getFullYear()) {\n s.epoch = original;\n } //incriment by day\n\n\n while (s.d.getMonth() < n) {\n s.epoch += milliseconds.day;\n }\n\n while (s.d.getMonth() > n) {\n s.epoch -= milliseconds.day;\n }\n }\n },\n date: {\n valid: function valid(n) {\n return n > 0 && n <= 31;\n },\n walkTo: function walkTo(s, n) {\n return walk(s, n, 'getDate', 'day', 'getMonth');\n }\n },\n hour: {\n valid: function valid(n) {\n return n >= 0 && n < 24;\n },\n walkTo: function walkTo(s, n) {\n return walk(s, n, 'getHours', 'hour', 'getDate');\n }\n },\n minute: {\n valid: function valid(n) {\n return n >= 0 && n < 60;\n },\n walkTo: function walkTo(s, n) {\n return walk(s, n, 'getMinutes', 'minute', 'getHours');\n }\n },\n second: {\n valid: function valid(n) {\n return n >= 0 && n < 60;\n },\n walkTo: function walkTo(s, n) {\n //do this one directly\n s.epoch = s.seconds(n).epoch;\n }\n },\n millisecond: {\n valid: function valid(n) {\n return n >= 0 && n < 1000;\n },\n walkTo: function walkTo(s, n) {\n //do this one directly\n s.epoch = s.milliseconds(n).epoch;\n }\n }\n};\n\nvar walkTo = function walkTo(s, wants) {\n var keys = Object.keys(units);\n var old = s.clone();\n\n for (var i = 0; i < keys.length; i++) {\n var k = keys[i];\n var n = wants[k];\n\n if (n === undefined) {\n n = old[k]();\n }\n\n if (typeof n === 'string') {\n n = parseInt(n, 10);\n } //make-sure it's valid\n\n\n if (!units[k].valid(n)) {\n s.epoch = null;\n\n if (s.silent === false) {\n console.warn('invalid ' + k + ': ' + n);\n }\n\n return;\n } // console.log(k, n)\n\n\n units[k].walkTo(s, n);\n }\n\n return;\n};\n\nvar walk_1 = walkTo;\n\nvar shortMonths = ['jan', 'feb', 'mar', 'apr', 'may', 'jun', 'jul', 'aug', 'sept', 'oct', 'nov', 'dec'];\nvar longMonths = ['january', 'february', 'march', 'april', 'may', 'june', 'july', 'august', 'september', 'october', 'november', 'december'];\n\nfunction buildMapping() {\n var obj = {\n sep: 8 //support this format\n\n };\n\n for (var i = 0; i < shortMonths.length; i++) {\n obj[shortMonths[i]] = i;\n }\n\n for (var _i = 0; _i < longMonths.length; _i++) {\n obj[longMonths[_i]] = _i;\n }\n\n return obj;\n}\n\nvar months = {\n \"short\": function short() {\n return shortMonths;\n },\n \"long\": function long() {\n return longMonths;\n },\n mapping: function mapping() {\n return buildMapping();\n },\n set: function set(i18n) {\n shortMonths = i18n[\"short\"] || shortMonths;\n longMonths = i18n[\"long\"] || longMonths;\n }\n};\n\n//pull-apart ISO offsets, like \"+0100\"\nvar parseOffset$1 = function parseOffset(s, offset) {\n if (!offset) {\n return s;\n } //this is a fancy-move\n\n\n if (offset === 'Z') {\n offset = '+0000';\n } // according to ISO8601, tz could be hh:mm, hhmm or hh\n // so need few more steps before the calculation.\n\n\n var num = 0; // for (+-)hh:mm\n\n if (/^[\\+-]?[0-9]{2}:[0-9]{2}$/.test(offset)) {\n //support \"+01:00\"\n if (/:00/.test(offset) === true) {\n offset = offset.replace(/:00/, '');\n } //support \"+01:30\"\n\n\n if (/:30/.test(offset) === true) {\n offset = offset.replace(/:30/, '.5');\n }\n } // for (+-)hhmm\n\n\n if (/^[\\+-]?[0-9]{4}$/.test(offset)) {\n offset = offset.replace(/30$/, '.5');\n }\n\n num = parseFloat(offset); //divide by 100 or 10 - , \"+0100\", \"+01\"\n\n if (Math.abs(num) > 100) {\n num = num / 100;\n } //okay, try to match it to a utc timezone\n //remember - this is opposite! a -5 offset maps to Etc/GMT+5 ¯\\_(:/)_/¯\n //https://askubuntu.com/questions/519550/why-is-the-8-timezone-called-gmt-8-in-the-filesystem\n\n\n num *= -1;\n\n if (num >= 0) {\n num = '+' + num;\n }\n\n var tz = 'etc/gmt' + num;\n var zones = s.timezones;\n\n if (zones[tz]) {\n // log a warning if we're over-writing a given timezone?\n // console.log('changing timezone to: ' + tz)\n s.tz = tz;\n }\n\n return s;\n};\n\nvar parseOffset_1$1 = parseOffset$1;\n\nvar parseTime = function parseTime(s) {\n var str = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';\n str = str.replace(/^\\s+/, '').toLowerCase(); //trim\n //formal time formats - 04:30.23\n\n var arr = str.match(/([0-9]{1,2}):([0-9]{1,2}):?([0-9]{1,2})?[:\\.]?([0-9]{1,4})?/);\n\n if (arr !== null) {\n //validate it a little\n var h = Number(arr[1]);\n\n if (h < 0 || h > 24) {\n return s.startOf('day');\n }\n\n var m = Number(arr[2]); //don't accept '5:3pm'\n\n if (arr[2].length < 2 || m < 0 || m > 59) {\n return s.startOf('day');\n }\n\n s = s.hour(h);\n s = s.minute(m);\n s = s.seconds(arr[3] || 0);\n s = s.millisecond(arr[4] || 0); //parse-out am/pm\n\n var ampm = str.match(/[\\b0-9](am|pm)\\b/);\n\n if (ampm !== null && ampm[1]) {\n s = s.ampm(ampm[1]);\n }\n\n return s;\n } //try an informal form - 5pm (no minutes)\n\n\n arr = str.match(/([0-9]+) ?(am|pm)/);\n\n if (arr !== null && arr[1]) {\n var _h = Number(arr[1]); //validate it a little..\n\n\n if (_h > 12 || _h < 1) {\n return s.startOf('day');\n }\n\n s = s.hour(arr[1] || 0);\n s = s.ampm(arr[2]);\n s = s.startOf('hour');\n return s;\n } //no time info found, use start-of-day\n\n\n s = s.startOf('day');\n return s;\n};\n\nvar parseTime_1 = parseTime;\n\nvar monthLengths = [31, // January - 31 days\n28, // February - 28 days in a common year and 29 days in leap years\n31, // March - 31 days\n30, // April - 30 days\n31, // May - 31 days\n30, // June - 30 days\n31, // July - 31 days\n31, // August - 31 days\n30, // September - 30 days\n31, // October - 31 days\n30, // November - 30 days\n31 // December - 31 days\n];\nvar monthLengths_1 = monthLengths; // 28 - feb\n\nvar isLeapYear = fns.isLeapYear; //given a month, return whether day number exists in it\n\nvar hasDate = function hasDate(obj) {\n //invalid values\n if (monthLengths_1.hasOwnProperty(obj.month) !== true) {\n return false;\n } //support leap-year in february\n\n\n if (obj.month === 1) {\n if (isLeapYear(obj.year) && obj.date <= 29) {\n return true;\n } else {\n return obj.date <= 28;\n }\n } //is this date too-big for this month?\n\n\n var max = monthLengths_1[obj.month] || 0;\n\n if (obj.date <= max) {\n return true;\n }\n\n return false;\n};\n\nvar hasDate_1 = hasDate;\n\nvar months$1 = months.mapping();\n\nvar parseYear = function parseYear() {\n var str = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';\n var today = arguments.length > 1 ? arguments[1] : undefined;\n var year = parseInt(str.trim(), 10); // use a given year from options.today\n\n if (!year && today) {\n year = today.year;\n } // fallback to this year\n\n\n year = year || new Date().getFullYear();\n return year;\n};\n\nvar strFmt = [//iso-this 1998-05-30T22:00:00:000Z, iso-that 2017-04-03T08:00:00-0700\n{\n reg: /^(\\-?0?0?[0-9]{3,4})-([0-9]{1,2})-([0-9]{1,2})[T| ]([0-9.:]+)(Z|[0-9\\-\\+:]+)?$/,\n parse: function parse(s, arr, givenTz, options) {\n var month = parseInt(arr[2], 10) - 1;\n var obj = {\n year: arr[1],\n month: month,\n date: arr[3]\n };\n\n if (hasDate_1(obj) === false) {\n s.epoch = null;\n return s;\n }\n\n parseOffset_1$1(s, arr[5]);\n walk_1(s, obj);\n s = parseTime_1(s, arr[4]);\n return s;\n }\n}, //iso \"2015-03-25\" or \"2015/03/25\" or \"2015/03/25 12:26:14 PM\"\n{\n reg: /^([0-9]{4})[\\-\\/]([0-9]{1,2})[\\-\\/]([0-9]{1,2}),?( [0-9]{1,2}:[0-9]{2}:?[0-9]{0,2}? ?(am|pm|gmt))?$/i,\n parse: function parse(s, arr) {\n var obj = {\n year: arr[1],\n month: parseInt(arr[2], 10) - 1,\n date: parseInt(arr[3], 10)\n };\n\n if (obj.month >= 12) {\n //support yyyy/dd/mm (weird, but ok)\n obj.date = parseInt(arr[2], 10);\n obj.month = parseInt(arr[3], 10) - 1;\n }\n\n if (hasDate_1(obj) === false) {\n s.epoch = null;\n return s;\n }\n\n walk_1(s, obj);\n s = parseTime_1(s, arr[4]);\n return s;\n }\n}, //mm/dd/yyyy - uk/canada \"6/28/2019, 12:26:14 PM\"\n{\n reg: /^([0-9]{1,2})[\\-\\/]([0-9]{1,2})[\\-\\/]?([0-9]{4})?,?( [0-9]{1,2}:[0-9]{2}:?[0-9]{0,2}? ?(am|pm|gmt))?$/i,\n parse: function parse(s, arr) {\n var month = parseInt(arr[1], 10) - 1;\n var date = parseInt(arr[2], 10); //support dd/mm/yyy\n\n if (s.british || month >= 12) {\n date = parseInt(arr[1], 10);\n month = parseInt(arr[2], 10) - 1;\n }\n\n var year = arr[3] || new Date().getFullYear();\n var obj = {\n year: year,\n month: month,\n date: date\n };\n\n if (hasDate_1(obj) === false) {\n s.epoch = null;\n return s;\n }\n\n walk_1(s, obj);\n s = parseTime_1(s, arr[4]);\n return s;\n }\n}, //common british format - \"25-feb-2015\"\n{\n reg: /^([0-9]{1,2})[\\-\\/]([a-z]+)[\\-\\/]?([0-9]{4})?$/i,\n parse: function parse(s, arr) {\n var month = months$1[arr[2].toLowerCase()];\n var year = parseYear(arr[3], s._today);\n var obj = {\n year: year,\n month: month,\n date: fns.toCardinal(arr[1] || '')\n };\n\n if (hasDate_1(obj) === false) {\n s.epoch = null;\n return s;\n }\n\n walk_1(s, obj);\n s = parseTime_1(s, arr[4]);\n return s;\n }\n}, //Long \"Mar 25 2015\"\n//February 22, 2017 15:30:00\n{\n reg: /^([a-z]+) ([0-9]{1,2}(?:st|nd|rd|th)?),?( [0-9]{4})?( ([0-9:]+( ?am| ?pm| ?gmt)?))?$/i,\n parse: function parse(s, arr) {\n var month = months$1[arr[1].toLowerCase()];\n var year = parseYear(arr[3], s._today);\n var obj = {\n year: year,\n month: month,\n date: fns.toCardinal(arr[2] || '')\n };\n\n if (hasDate_1(obj) === false) {\n s.epoch = null;\n return s;\n }\n\n walk_1(s, obj);\n s = parseTime_1(s, arr[4]);\n return s;\n }\n}, //February 2017 (implied date)\n{\n reg: /^([a-z]+) ([0-9]{4})$/i,\n parse: function parse(s, arr) {\n var month = months$1[arr[1].toLowerCase()];\n var year = parseYear(arr[2], s._today);\n var obj = {\n year: year,\n month: month,\n date: s._today.date || 1\n };\n\n if (hasDate_1(obj) === false) {\n s.epoch = null;\n return s;\n }\n\n walk_1(s, obj);\n s = parseTime_1(s, arr[4]);\n return s;\n }\n}, //Long \"25 Mar 2015\"\n{\n reg: /^([0-9]{1,2}(?:st|nd|rd|th)?) ([a-z]+),?( [0-9]{4})?,? ?([0-9]{1,2}:[0-9]{2}:?[0-9]{0,2}? ?(am|pm|gmt))?$/i,\n parse: function parse(s, arr) {\n var month = months$1[arr[2].toLowerCase()];\n\n if (!month) {\n return null;\n }\n\n var year = parseYear(arr[3], s._today);\n var obj = {\n year: year,\n month: month,\n date: fns.toCardinal(arr[1])\n };\n\n if (hasDate_1(obj) === false) {\n s.epoch = null;\n return s;\n }\n\n walk_1(s, obj);\n s = parseTime_1(s, arr[4]);\n return s;\n }\n}, {\n // '200bc'\n reg: /^[0-9,]+ ?b\\.?c\\.?$/i,\n parse: function parse(s, arr) {\n var str = arr[0] || ''; //make negative-year\n\n str = str.replace(/^([0-9,]+) ?b\\.?c\\.?$/i, '-$1'); //remove commas\n\n str = str.replace(/,/g, '');\n var year = parseInt(str.trim(), 10);\n var d = new Date();\n var obj = {\n year: year,\n month: d.getMonth(),\n date: d.getDate()\n };\n\n if (hasDate_1(obj) === false) {\n s.epoch = null;\n return s;\n }\n\n walk_1(s, obj);\n s = parseTime_1(s);\n return s;\n }\n}, {\n // '200ad'\n reg: /^[0-9,]+ ?(a\\.?d\\.?|c\\.?e\\.?)$/i,\n parse: function parse(s, arr) {\n var str = arr[0] || ''; //remove commas\n\n str = str.replace(/,/g, '');\n var year = parseInt(str.trim(), 10);\n var d = new Date();\n var obj = {\n year: year,\n month: d.getMonth(),\n date: d.getDate()\n };\n\n if (hasDate_1(obj) === false) {\n s.epoch = null;\n return s;\n }\n\n walk_1(s, obj);\n s = parseTime_1(s);\n return s;\n }\n}, {\n // '1992'\n reg: /^[0-9]{4}( ?a\\.?d\\.?)?$/i,\n parse: function parse(s, arr) {\n var today = s._today;\n var year = parseYear(arr[0], today);\n var d = new Date(); // using today's date, but a new month is awkward.\n\n if (today.month && !today.date) {\n today.date = 1;\n }\n\n var obj = {\n year: year,\n month: today.month || d.getMonth(),\n date: today.date || d.getDate()\n };\n\n if (hasDate_1(obj) === false) {\n s.epoch = null;\n return s;\n }\n\n walk_1(s, obj);\n s = parseTime_1(s);\n return s;\n }\n}];\nvar strParse = strFmt;\n\nvar dates = {\n now: function now(s) {\n s.epoch = Date.now();\n return s;\n },\n tonight: function tonight(s) {\n s.epoch = Date.now();\n s = s.hour(18);\n return s;\n },\n today: function today(s) {\n s.epoch = Date.now();\n return s;\n },\n tomorrow: function tomorrow(s) {\n s.epoch = Date.now();\n s = s.add(1, 'day');\n s = s.startOf('day');\n return s;\n },\n yesterday: function yesterday(s) {\n s.epoch = Date.now();\n s = s.subtract(1, 'day');\n s = s.startOf('day');\n return s;\n },\n christmas: function christmas(s) {\n var year = new Date().getFullYear();\n s = s.set([year, 11, 25, 18, 0, 0]); // Dec 25\n\n return s;\n },\n 'new years': function newYears(s) {\n var year = new Date().getFullYear();\n s = s.set([year, 11, 31, 18, 0, 0]); // Dec 31\n\n return s;\n }\n};\ndates['new years eve'] = dates['new years'];\nvar namedDates = dates;\n\n// - can't use built-in js parser ;(\n//=========================================\n// ISO Date\t \"2015-03-25\"\n// Short Date\t\"03/25/2015\" or \"2015/03/25\"\n// Long Date\t\"Mar 25 2015\" or \"25 Mar 2015\"\n// Full Date\t\"Wednesday March 25 2015\"\n//=========================================\n//-- also -\n// if the given epoch is really small, they've probably given seconds and not milliseconds\n// anything below this number is likely (but not necessarily) a mistaken input.\n// this may seem like an arbitrary number, but it's 'within jan 1970'\n// this is only really ambiguous until 2054 or so\n\nvar minimumEpoch = 2500000000;\nvar defaults = {\n year: new Date().getFullYear(),\n month: 0,\n date: 1\n}; //support [2016, 03, 01] format\n\nvar handleArray = function handleArray(s, arr, today) {\n var order = ['year', 'month', 'date', 'hour', 'minute', 'second', 'millisecond'];\n\n for (var i = 0; i < order.length; i++) {\n var num = arr[i] || today[order[i]] || defaults[order[i]] || 0;\n s = s[order[i]](num);\n }\n\n return s;\n}; //support {year:2016, month:3} format\n\n\nvar handleObject = function handleObject(s, obj, today) {\n obj = Object.assign({}, defaults, today, obj);\n var keys = Object.keys(obj);\n\n for (var i = 0; i < keys.length; i++) {\n var unit = keys[i]; //make sure we have this method\n\n if (s[unit] === undefined || typeof s[unit] !== 'function') {\n continue;\n } //make sure the value is a number\n\n\n if (obj[unit] === null || obj[unit] === undefined || obj[unit] === '') {\n continue;\n }\n\n var num = obj[unit] || today[unit] || defaults[unit] || 0;\n s = s[unit](num);\n }\n\n return s;\n}; //find the epoch from different input styles\n\n\nvar parseInput = function parseInput(s, input, givenTz) {\n var today = s._today || defaults; //if we've been given a epoch number, it's easy\n\n if (typeof input === 'number') {\n if (input > 0 && input < minimumEpoch && s.silent === false) {\n console.warn(' - Warning: You are setting the date to January 1970.');\n console.warn(' - did input seconds instead of milliseconds?');\n }\n\n s.epoch = input;\n return s;\n } //set tmp time\n\n\n s.epoch = Date.now();\n\n if (input === null || input === undefined) {\n return s; //k, we're good.\n } //support input of Date() object\n\n\n if (fns.isDate(input) === true) {\n s.epoch = input.getTime();\n return s;\n } //support [2016, 03, 01] format\n\n\n if (fns.isArray(input) === true) {\n s = handleArray(s, input, today);\n return s;\n } //support {year:2016, month:3} format\n\n\n if (fns.isObject(input) === true) {\n //support spacetime object as input\n if (input.epoch) {\n s.epoch = input.epoch;\n s.tz = input.tz;\n return s;\n }\n\n s = handleObject(s, input, today);\n return s;\n } //input as a string..\n\n\n if (typeof input !== 'string') {\n return s;\n } //little cleanup..\n\n\n input = input.replace(/\\b(mon|tues|wed|wednes|thu|thurs|fri|sat|satur|sun)(day)?\\b/i, '');\n input = input.replace(/,/g, '');\n input = input.replace(/ +/g, ' ').trim(); //try some known-words, like 'now'\n\n if (namedDates.hasOwnProperty(input) === true) {\n s = namedDates[input](s);\n return s;\n } //try each text-parse template, use the first good result\n\n\n for (var i = 0; i < strParse.length; i++) {\n var m = input.match(strParse[i].reg);\n\n if (m) {\n var res = strParse[i].parse(s, m, givenTz);\n\n if (res !== null) {\n return res;\n }\n }\n }\n\n if (s.silent === false) {\n console.warn(\"Warning: couldn't parse date-string: '\" + input + \"'\");\n }\n\n s.epoch = null;\n return s;\n};\n\nvar input = parseInput;\n\nvar shortDays = ['sun', 'mon', 'tue', 'wed', 'thu', 'fri', 'sat'];\nvar longDays = ['sunday', 'monday', 'tuesday', 'wednesday', 'thursday', 'friday', 'saturday'];\nvar days = {\n \"short\": function short() {\n return shortDays;\n },\n \"long\": function long() {\n return longDays;\n },\n set: function set(i18n) {\n shortDays = i18n[\"short\"] || shortDays;\n longDays = i18n[\"long\"] || longDays;\n }\n};\n\n// it's kind of nuts how involved this is\n// \"+01:00\", \"+0100\", or simply \"+01\"\n\nvar isoOffset = function isoOffset(s) {\n var offset = s.timezone().current.offset;\n var isNegative = offset < 0;\n var minute = '00'; //handle 5.5 → '5:30'\n\n if (Math.abs(offset % 1) === 0.5) {\n minute = '30';\n\n if (offset >= 0) {\n offset = Math.floor(offset);\n } else {\n offset = Math.ceil(offset);\n }\n }\n\n if (isNegative) {\n //handle negative sign\n offset *= -1;\n offset = fns.zeroPad(offset, 2);\n offset = '-' + offset;\n } else {\n offset = fns.zeroPad(offset, 2);\n offset = '+' + offset;\n }\n\n offset = offset + ':' + minute; //'Z' means 00\n\n if (offset === '+00:00') {\n offset = 'Z';\n }\n\n return offset;\n};\n\nvar _offset = isoOffset;\n\nvar format = {\n day: function day(s) {\n return fns.titleCase(s.dayName());\n },\n 'day-short': function dayShort(s) {\n return fns.titleCase(days[\"short\"]()[s.day()]);\n },\n 'day-number': function dayNumber(s) {\n return s.day();\n },\n 'day-ordinal': function dayOrdinal(s) {\n return fns.ordinal(s.day());\n },\n 'day-pad': function dayPad(s) {\n return fns.zeroPad(s.day());\n },\n date: function date(s) {\n return s.date();\n },\n 'date-ordinal': function dateOrdinal(s) {\n return fns.ordinal(s.date());\n },\n 'date-pad': function datePad(s) {\n return fns.zeroPad(s.date());\n },\n month: function month(s) {\n return fns.titleCase(s.monthName());\n },\n 'month-short': function monthShort(s) {\n return fns.titleCase(months[\"short\"]()[s.month()]);\n },\n 'month-number': function monthNumber(s) {\n return s.month();\n },\n 'month-ordinal': function monthOrdinal(s) {\n return fns.ordinal(s.month());\n },\n 'month-pad': function monthPad(s) {\n return fns.zeroPad(s.month());\n },\n 'iso-month': function isoMonth(s) {\n return fns.zeroPad(s.month() + 1);\n },\n //1-based months\n year: function year(s) {\n var year = s.year();\n\n if (year > 0) {\n return year;\n }\n\n year = Math.abs(year);\n return year + ' BC';\n },\n 'year-short': function yearShort(s) {\n var year = s.year();\n\n if (year > 0) {\n return \"'\".concat(String(s.year()).substr(2, 4));\n }\n\n year = Math.abs(year);\n return year + ' BC';\n },\n 'iso-year': function isoYear(s) {\n var year = s.year();\n var isNegative = year < 0;\n var str = fns.zeroPad(Math.abs(year), 4); //0-padded\n\n if (isNegative) {\n //negative years are for some reason 6-digits ('-00008')\n str = fns.zeroPad(str, 6);\n str = '-' + str;\n }\n\n return str;\n },\n time: function time(s) {\n return s.time();\n },\n 'time-24': function time24(s) {\n return \"\".concat(s.hour24(), \":\").concat(fns.zeroPad(s.minute()));\n },\n hour: function hour(s) {\n return s.hour12();\n },\n 'hour-pad': function hourPad(s) {\n return fns.zeroPad(s.hour12());\n },\n 'hour-24': function hour24(s) {\n return s.hour24();\n },\n 'hour-24-pad': function hour24Pad(s) {\n return fns.zeroPad(s.hour24());\n },\n minute: function minute(s) {\n return s.minute();\n },\n 'minute-pad': function minutePad(s) {\n return fns.zeroPad(s.minute());\n },\n second: function second(s) {\n return s.second();\n },\n 'second-pad': function secondPad(s) {\n return fns.zeroPad(s.second());\n },\n ampm: function ampm(s) {\n return s.ampm();\n },\n quarter: function quarter(s) {\n return 'Q' + s.quarter();\n },\n season: function season(s) {\n return s.season();\n },\n era: function era(s) {\n return s.era();\n },\n json: function json(s) {\n return s.json();\n },\n timezone: function timezone(s) {\n return s.timezone().name;\n },\n offset: function offset(s) {\n return _offset(s);\n },\n numeric: function numeric(s) {\n return \"\".concat(s.year(), \"/\").concat(fns.zeroPad(s.month() + 1), \"/\").concat(fns.zeroPad(s.date()));\n },\n // yyyy/mm/dd\n 'numeric-us': function numericUs(s) {\n return \"\".concat(fns.zeroPad(s.month() + 1), \"/\").concat(fns.zeroPad(s.date()), \"/\").concat(s.year());\n },\n // mm/dd/yyyy\n 'numeric-uk': function numericUk(s) {\n return \"\".concat(fns.zeroPad(s.date()), \"/\").concat(fns.zeroPad(s.month() + 1), \"/\").concat(s.year());\n },\n //dd/mm/yyyy\n 'mm/dd': function mmDd(s) {\n return \"\".concat(fns.zeroPad(s.month() + 1), \"/\").concat(fns.zeroPad(s.date()));\n },\n //mm/dd\n // ... https://en.wikipedia.org/wiki/ISO_8601 ;(((\n iso: function iso(s) {\n var year = s.format('iso-year');\n var month = fns.zeroPad(s.month() + 1); //1-based months\n\n var date = fns.zeroPad(s.date());\n var hour = fns.zeroPad(s.h24());\n var minute = fns.zeroPad(s.minute());\n var second = fns.zeroPad(s.second());\n var ms = fns.zeroPad(s.millisecond(), 3);\n var offset = _offset(s);\n return \"\".concat(year, \"-\").concat(month, \"-\").concat(date, \"T\").concat(hour, \":\").concat(minute, \":\").concat(second, \".\").concat(ms).concat(offset); //2018-03-09T08:50:00.000-05:00\n },\n 'iso-short': function isoShort(s) {\n var month = fns.zeroPad(s.month() + 1); //1-based months\n\n var date = fns.zeroPad(s.date());\n return \"\".concat(s.year(), \"-\").concat(month, \"-\").concat(date); //2017-02-15\n },\n 'iso-utc': function isoUtc(s) {\n return new Date(s.epoch).toISOString(); //2017-03-08T19:45:28.367Z\n },\n //i made these up\n nice: function nice(s) {\n return \"\".concat(months[\"short\"]()[s.month()], \" \").concat(fns.ordinal(s.date()), \", \").concat(s.time());\n },\n 'nice-year': function niceYear(s) {\n return \"\".concat(months[\"short\"]()[s.month()], \" \").concat(fns.ordinal(s.date()), \", \").concat(s.year());\n },\n 'nice-day': function niceDay(s) {\n return \"\".concat(days[\"short\"]()[s.day()], \" \").concat(fns.titleCase(months[\"short\"]()[s.month()]), \" \").concat(fns.ordinal(s.date()));\n },\n 'nice-full': function niceFull(s) {\n return \"\".concat(s.dayName(), \" \").concat(fns.titleCase(s.monthName()), \" \").concat(fns.ordinal(s.date()), \", \").concat(s.time());\n }\n}; //aliases\n\nvar aliases = {\n 'day-name': 'day',\n 'month-name': 'month',\n 'iso 8601': 'iso',\n 'time-h24': 'time-24',\n 'time-12': 'time',\n 'time-h12': 'time',\n tz: 'timezone',\n 'day-num': 'day-number',\n 'month-num': 'month-number',\n 'month-iso': 'iso-month',\n 'year-iso': 'iso-year',\n 'nice-short': 'nice',\n mdy: 'numeric-us',\n dmy: 'numeric-uk',\n ymd: 'numeric',\n 'yyyy/mm/dd': 'numeric',\n 'mm/dd/yyyy': 'numeric-us',\n 'dd/mm/yyyy': 'numeric-us',\n 'little-endian': 'numeric-uk',\n 'big-endian': 'numeric',\n 'day-nice': 'nice-day'\n};\nObject.keys(aliases).forEach(function (k) {\n return format[k] = format[aliases[k]];\n});\n\nvar printFormat = function printFormat(s) {\n var str = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';\n\n //don't print anything if it's an invalid date\n if (s.isValid() !== true) {\n return '';\n } //support .format('month')\n\n\n if (format.hasOwnProperty(str)) {\n var out = format[str](s) || '';\n\n if (str !== 'json') {\n out = String(out);\n\n if (str !== 'ampm') {\n out = fns.titleCase(out);\n }\n }\n\n return out;\n } //support '{hour}:{minute}' notation\n\n\n if (str.indexOf('{') !== -1) {\n var sections = /\\{(.+?)\\}/g;\n str = str.replace(sections, function (_, fmt) {\n fmt = fmt.toLowerCase().trim();\n\n if (format.hasOwnProperty(fmt)) {\n return String(format[fmt](s) || '');\n }\n\n return '';\n });\n return str;\n }\n\n return s.format('iso-short');\n};\n\nvar format_1 = printFormat;\n\nvar pad = fns.zeroPad;\nvar formatTimezone = fns.formatTimezone; //parse this insane unix-time-templating thing, from the 19th century\n//http://unicode.org/reports/tr35/tr35-25.html#Date_Format_Patterns\n//time-symbols we support\n\nvar mapping = {\n G: function G(s) {\n return s.era();\n },\n GG: function GG(s) {\n return s.era();\n },\n GGG: function GGG(s) {\n return s.era();\n },\n GGGG: function GGGG(s) {\n return s.era() === 'AD' ? 'Anno Domini' : 'Before Christ';\n },\n //year\n y: function y(s) {\n return s.year();\n },\n yy: function yy(s) {\n //last two chars\n return parseInt(String(s.year()).substr(2, 4), 10);\n },\n yyy: function yyy(s) {\n return s.year();\n },\n yyyy: function yyyy(s) {\n return s.year();\n },\n yyyyy: function yyyyy(s) {\n return '0' + s.year();\n },\n // u: (s) => {},//extended non-gregorian years\n //quarter\n Q: function Q(s) {\n return s.quarter();\n },\n QQ: function QQ(s) {\n return s.quarter();\n },\n QQQ: function QQQ(s) {\n return s.quarter();\n },\n QQQQ: function QQQQ(s) {\n return s.quarter();\n },\n //month\n M: function M(s) {\n return s.month() + 1;\n },\n MM: function MM(s) {\n return pad(s.month() + 1);\n },\n MMM: function MMM(s) {\n return s.format('month-short');\n },\n MMMM: function MMMM(s) {\n return s.format('month');\n },\n //week\n w: function w(s) {\n return s.week();\n },\n ww: function ww(s) {\n return pad(s.week());\n },\n //week of month\n // W: (s) => s.week(),\n //date of month\n d: function d(s) {\n return s.date();\n },\n dd: function dd(s) {\n return pad(s.date());\n },\n //date of year\n D: function D(s) {\n return s.dayOfYear();\n },\n DD: function DD(s) {\n return pad(s.dayOfYear());\n },\n DDD: function DDD(s) {\n return pad(s.dayOfYear(), 3);\n },\n // F: (s) => {},//date of week in month\n // g: (s) => {},//modified julian day\n //day\n E: function E(s) {\n return s.format('day-short');\n },\n EE: function EE(s) {\n return s.format('day-short');\n },\n EEE: function EEE(s) {\n return s.format('day-short');\n },\n EEEE: function EEEE(s) {\n return s.format('day');\n },\n EEEEE: function EEEEE(s) {\n return s.format('day')[0];\n },\n e: function e(s) {\n return s.day();\n },\n ee: function ee(s) {\n return s.day();\n },\n eee: function eee(s) {\n return s.format('day-short');\n },\n eeee: function eeee(s) {\n return s.format('day');\n },\n eeeee: function eeeee(s) {\n return s.format('day')[0];\n },\n //am/pm\n a: function a(s) {\n return s.ampm().toUpperCase();\n },\n aa: function aa(s) {\n return s.ampm().toUpperCase();\n },\n aaa: function aaa(s) {\n return s.ampm().toUpperCase();\n },\n aaaa: function aaaa(s) {\n return s.ampm().toUpperCase();\n },\n //hour\n h: function h(s) {\n return s.h12();\n },\n hh: function hh(s) {\n return pad(s.h12());\n },\n H: function H(s) {\n return s.hour();\n },\n HH: function HH(s) {\n return pad(s.hour());\n },\n // j: (s) => {},//weird hour format\n m: function m(s) {\n return s.minute();\n },\n mm: function mm(s) {\n return pad(s.minute());\n },\n s: function s(_s) {\n return _s.second();\n },\n ss: function ss(s) {\n return pad(s.second());\n },\n //milliseconds in the day\n A: function A(s) {\n return s.epoch - s.startOf('day').epoch;\n },\n //timezone\n z: function z(s) {\n return s.timezone().name;\n },\n zz: function zz(s) {\n return s.timezone().name;\n },\n zzz: function zzz(s) {\n return s.timezone().name;\n },\n zzzz: function zzzz(s) {\n return s.timezone().name;\n },\n Z: function Z(s) {\n return formatTimezone(s.timezone().current.offset);\n },\n ZZ: function ZZ(s) {\n return formatTimezone(s.timezone().current.offset);\n },\n ZZZ: function ZZZ(s) {\n return formatTimezone(s.timezone().current.offset);\n },\n ZZZZ: function ZZZZ(s) {\n return formatTimezone(s.timezone().current.offset, ':');\n }\n};\n\nvar addAlias = function addAlias(_char, to, n) {\n var name = _char;\n var toName = to;\n\n for (var i = 0; i < n; i += 1) {\n mapping[name] = mapping[toName];\n name += _char;\n toName += to;\n }\n};\n\naddAlias('q', 'Q', 4);\naddAlias('L', 'M', 4);\naddAlias('Y', 'y', 4);\naddAlias('c', 'e', 4);\naddAlias('k', 'H', 2);\naddAlias('K', 'h', 2);\naddAlias('S', 's', 2);\naddAlias('v', 'z', 4);\naddAlias('V', 'Z', 4);\n\nvar unixFmt = function unixFmt(s, str) {\n var chars = str.split(''); //combine consecutive chars, like 'yyyy' as one.\n\n var arr = [chars[0]];\n var quoteOn = false;\n\n for (var i = 1; i < chars.length; i += 1) {\n //support quoted substrings\n if (chars[i] === \"'\") {\n quoteOn = !quoteOn; //support '', meaning one tick\n\n if (quoteOn === true && chars[i + 1] && chars[i + 1] === \"'\") {\n quoteOn = true;\n } else {\n continue;\n }\n } //merge it with the last one\n\n\n if (quoteOn === true || chars[i] === arr[arr.length - 1][0]) {\n arr[arr.length - 1] += chars[i];\n } else {\n arr.push(chars[i]);\n }\n }\n\n return arr.reduce(function (txt, c) {\n if (mapping[c] !== undefined) {\n txt += mapping[c](s) || '';\n } else {\n txt += c;\n }\n\n return txt;\n }, '');\n};\n\nvar unixFmt_1 = unixFmt;\n\nvar units$1 = ['year', 'season', 'quarter', 'month', 'week', 'day', 'quarterHour', 'hour', 'minute'];\n\nvar doUnit = function doUnit(s, k) {\n var start = s.clone().startOf(k);\n var end = s.clone().endOf(k);\n var duration = end.epoch - start.epoch;\n var percent = (s.epoch - start.epoch) / duration;\n return parseFloat(percent.toFixed(2));\n}; //how far it is along, from 0-1\n\n\nvar progress = function progress(s, unit) {\n if (unit) {\n unit = fns.normalize(unit);\n return doUnit(s, unit);\n }\n\n var obj = {};\n units$1.forEach(function (k) {\n obj[k] = doUnit(s, k);\n });\n return obj;\n};\n\nvar progress_1 = progress;\n\nvar nearest = function nearest(s, unit) {\n //how far have we gone?\n var prog = s.progress();\n unit = fns.normalize(unit); //fix camel-case for this one\n\n if (unit === 'quarterhour') {\n unit = 'quarterHour';\n }\n\n if (prog[unit] !== undefined) {\n // go forward one?\n if (prog[unit] > 0.5) {\n s = s.add(1, unit);\n } // go to start\n\n\n s = s.startOf(unit);\n } else if (s.silent === false) {\n console.warn(\"no known unit '\" + unit + \"'\");\n }\n\n return s;\n};\n\nvar nearest_1 = nearest;\n\n//increment until dates are the same\nvar climb = function climb(a, b, unit) {\n var i = 0;\n a = a.clone();\n\n while (a.isBefore(b)) {\n //do proper, expensive increment to catch all-the-tricks\n a = a.add(1, unit);\n i += 1;\n } //oops, we went too-far..\n\n\n if (a.isAfter(b, unit)) {\n i -= 1;\n }\n\n return i;\n}; // do a thurough +=1 on the unit, until they match\n// for speed-reasons, only used on day, month, week.\n\n\nvar diffOne = function diffOne(a, b, unit) {\n if (a.isBefore(b)) {\n return climb(a, b, unit);\n } else {\n return climb(b, a, unit) * -1; //reverse it\n }\n};\n\nvar one = diffOne;\n\n// 2020 - 2019 may be 1 year, or 0 years\n// - '1 year difference' means 366 days during a leap year\n\nvar fastYear = function fastYear(a, b) {\n var years = b.year() - a.year(); // should we decrement it by 1?\n\n a = a.year(b.year());\n\n if (a.isAfter(b)) {\n years -= 1;\n }\n\n return years;\n}; // use a waterfall-method for computing a diff of any 'pre-knowable' units\n// compute years, then compute months, etc..\n// ... then ms-math for any very-small units\n\n\nvar diff = function diff(a, b) {\n // an hour is always the same # of milliseconds\n // so these units can be 'pre-calculated'\n var msDiff = b.epoch - a.epoch;\n var obj = {\n milliseconds: msDiff,\n seconds: parseInt(msDiff / 1000, 10)\n };\n obj.minutes = parseInt(obj.seconds / 60, 10);\n obj.hours = parseInt(obj.minutes / 60, 10); //do the year\n\n var tmp = a.clone();\n obj.years = fastYear(tmp, b);\n tmp = a.add(obj.years, 'year'); //there's always 12 months in a year...\n\n obj.months = obj.years * 12;\n tmp = a.add(obj.months, 'month');\n obj.months += one(tmp, b, 'month'); // there's always atleast 52 weeks in a year..\n // (month * 4) isn't as close\n\n obj.weeks = obj.years * 52;\n tmp = a.add(obj.weeks, 'week');\n obj.weeks += one(tmp, b, 'week'); // there's always atleast 7 days in a week\n\n obj.days = obj.weeks * 7;\n tmp = a.add(obj.days, 'day');\n obj.days += one(tmp, b, 'day');\n return obj;\n};\n\nvar waterfall = diff;\n\nvar reverseDiff = function reverseDiff(obj) {\n Object.keys(obj).forEach(function (k) {\n obj[k] *= -1;\n });\n return obj;\n}; // this method counts a total # of each unit, between a, b.\n// '1 month' means 28 days in february\n// '1 year' means 366 days in a leap year\n\n\nvar main = function main(a, b, unit) {\n b = fns.beADate(b, a); //reverse values, if necessary\n\n var reversed = false;\n\n if (a.isAfter(b)) {\n var tmp = a;\n a = b;\n b = tmp;\n reversed = true;\n } //compute them all (i know!)\n\n\n var obj = waterfall(a, b);\n\n if (reversed) {\n obj = reverseDiff(obj);\n } //return just the requested unit\n\n\n if (unit) {\n //make sure it's plural-form\n unit = fns.normalize(unit);\n\n if (/s$/.test(unit) !== true) {\n unit += 's';\n }\n\n if (unit === 'dates') {\n unit = 'days';\n }\n\n return obj[unit];\n }\n\n return obj;\n};\n\nvar diff$1 = main;\n\n//our conceptual 'break-points' for each unit\n\nvar qualifiers = {\n months: {\n almost: 10,\n over: 4\n },\n days: {\n almost: 25,\n over: 10\n },\n hours: {\n almost: 20,\n over: 8\n },\n minutes: {\n almost: 50,\n over: 20\n },\n seconds: {\n almost: 50,\n over: 20\n }\n}; //get number of hours/minutes... between the two dates\n\nfunction getDiff(a, b) {\n var isBefore = a.isBefore(b);\n var later = isBefore ? b : a;\n var earlier = isBefore ? a : b;\n earlier = earlier.clone();\n var diff = {\n years: 0,\n months: 0,\n days: 0,\n hours: 0,\n minutes: 0,\n seconds: 0\n };\n Object.keys(diff).forEach(function (unit) {\n if (earlier.isSame(later, unit)) {\n return;\n }\n\n var max = earlier.diff(later, unit);\n earlier = earlier.add(max, unit);\n diff[unit] = max;\n }); //reverse it, if necessary\n\n if (isBefore) {\n Object.keys(diff).forEach(function (u) {\n if (diff[u] !== 0) {\n diff[u] *= -1;\n }\n });\n }\n\n return diff;\n} // Expects a plural unit arg\n\n\nfunction pluralize(value, unit) {\n if (value === 1) {\n unit = unit.slice(0, -1);\n }\n\n return value + ' ' + unit;\n} //create the human-readable diff between the two dates\n\n\nvar since = function since(start, end) {\n end = fns.beADate(end, start);\n var diff = getDiff(start, end);\n var isNow = Object.keys(diff).every(function (u) {\n return !diff[u];\n });\n\n if (isNow === true) {\n return {\n diff: diff,\n rounded: 'now',\n qualified: 'now',\n precise: 'now'\n };\n }\n\n var rounded;\n var qualified;\n var precise;\n var englishValues = []; //go through each value and create its text-representation\n\n Object.keys(diff).forEach(function (unit, i, units) {\n var value = Math.abs(diff[unit]);\n\n if (value === 0) {\n return;\n }\n\n var englishValue = pluralize(value, unit);\n englishValues.push(englishValue);\n\n if (!rounded) {\n rounded = qualified = englishValue;\n\n if (i > 4) {\n return;\n } //is it a 'almost' something, etc?\n\n\n var nextUnit = units[i + 1];\n var nextValue = Math.abs(diff[nextUnit]);\n\n if (nextValue > qualifiers[nextUnit].almost) {\n rounded = pluralize(value + 1, unit);\n qualified = 'almost ' + rounded;\n } else if (nextValue > qualifiers[nextUnit].over) qualified = 'over ' + englishValue;\n }\n }); //make them into a string\n\n precise = englishValues.splice(0, 2).join(', '); //handle before/after logic\n\n if (start.isAfter(end) === true) {\n rounded += ' ago';\n qualified += ' ago';\n precise += ' ago';\n } else {\n rounded = 'in ' + rounded;\n qualified = 'in ' + qualified;\n precise = 'in ' + precise;\n }\n\n return {\n diff: diff,\n rounded: rounded,\n qualified: qualified,\n precise: precise\n };\n};\n\nvar since_1 = since;\n\n//https://www.timeanddate.com/calendar/aboutseasons.html\n// Spring - from March 1 to May 31;\n// Summer - from June 1 to August 31;\n// Fall (autumn) - from September 1 to November 30; and,\n// Winter - from December 1 to February 28 (February 29 in a leap year).\nvar seasons = {\n north: [['spring', 2, 1], //spring march 1\n ['summer', 5, 1], //june 1\n ['fall', 8, 1], //sept 1\n ['autumn', 8, 1], //sept 1\n ['winter', 11, 1] //dec 1\n ],\n south: [['fall', 2, 1], //march 1\n ['autumn', 2, 1], //march 1\n ['winter', 5, 1], //june 1\n ['spring', 8, 1], //sept 1\n ['summer', 11, 1] //dec 1\n ]\n};\n\nvar quarters = [null, [0, 1], //jan 1\n[3, 1], //apr 1\n[6, 1], //july 1\n[9, 1] //oct 1\n];\n\nvar units$2 = {\n minute: function minute(s) {\n walk_1(s, {\n second: 0,\n millisecond: 0\n });\n return s;\n },\n quarterhour: function quarterhour(s) {\n var minute = s.minutes();\n\n if (minute >= 45) {\n s = s.minutes(45);\n } else if (minute >= 30) {\n s = s.minutes(30);\n } else if (minute >= 15) {\n s = s.minutes(15);\n } else {\n s = s.minutes(0);\n }\n\n walk_1(s, {\n second: 0,\n millisecond: 0\n });\n return s;\n },\n hour: function hour(s) {\n walk_1(s, {\n minute: 0,\n second: 0,\n millisecond: 0\n });\n return s;\n },\n day: function day(s) {\n walk_1(s, {\n hour: 0,\n minute: 0,\n second: 0,\n millisecond: 0\n });\n return s;\n },\n week: function week(s) {\n var original = s.clone();\n s = s.day(s._weekStart); //monday\n\n if (s.isAfter(original)) {\n s = s.subtract(1, 'week');\n }\n\n walk_1(s, {\n hour: 0,\n minute: 0,\n second: 0,\n millisecond: 0\n });\n return s;\n },\n month: function month(s) {\n walk_1(s, {\n date: 1,\n hour: 0,\n minute: 0,\n second: 0,\n millisecond: 0\n });\n return s;\n },\n quarter: function quarter(s) {\n var q = s.quarter();\n\n if (quarters[q]) {\n walk_1(s, {\n month: quarters[q][0],\n date: quarters[q][1],\n hour: 0,\n minute: 0,\n second: 0,\n millisecond: 0\n });\n }\n\n return s;\n },\n season: function season(s) {\n var current = s.season();\n var hem = 'north';\n\n if (s.hemisphere() === 'South') {\n hem = 'south';\n }\n\n for (var i = 0; i < seasons[hem].length; i++) {\n if (seasons[hem][i][0] === current) {\n //winter goes between years\n var year = s.year();\n\n if (current === 'winter' && s.month() < 3) {\n year -= 1;\n }\n\n walk_1(s, {\n year: year,\n month: seasons[hem][i][1],\n date: seasons[hem][i][2],\n hour: 0,\n minute: 0,\n second: 0,\n millisecond: 0\n });\n return s;\n }\n }\n\n return s;\n },\n year: function year(s) {\n walk_1(s, {\n month: 0,\n date: 1,\n hour: 0,\n minute: 0,\n second: 0,\n millisecond: 0\n });\n return s;\n },\n decade: function decade(s) {\n s = s.startOf('year');\n var year = s.year();\n var decade = parseInt(year / 10, 10) * 10;\n s = s.year(decade);\n return s;\n },\n century: function century(s) {\n s = s.startOf('year');\n var year = s.year(); // near 0AD goes '-1 | +1'\n\n var decade = parseInt(year / 100, 10) * 100;\n s = s.year(decade);\n return s;\n }\n};\nunits$2.date = units$2.day;\n\nvar startOf = function startOf(a, unit) {\n var s = a.clone();\n unit = fns.normalize(unit);\n\n if (units$2[unit]) {\n return units$2[unit](s);\n }\n\n if (unit === 'summer' || unit === 'winter') {\n s = s.season(unit);\n return units$2.season(s);\n }\n\n return s;\n}; //piggy-backs off startOf\n\n\nvar endOf = function endOf(a, unit) {\n var s = a.clone();\n unit = fns.normalize(unit);\n\n if (units$2[unit]) {\n s = units$2[unit](s);\n s = s.add(1, unit);\n s = s.subtract(1, 'milliseconds');\n return s;\n }\n\n return s;\n};\n\nvar startOf_1 = {\n startOf: startOf,\n endOf: endOf\n};\n\nvar isDay = function isDay(unit) {\n if (days[\"short\"]().find(function (s) {\n return s === unit;\n })) {\n return true;\n }\n\n if (days[\"long\"]().find(function (s) {\n return s === unit;\n })) {\n return true;\n }\n\n return false;\n}; // return a list of the weeks/months/days between a -> b\n// returns spacetime objects in the timezone of the input\n\n\nvar every = function every(start) {\n var unit = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';\n var end = arguments.length > 2 ? arguments[2] : undefined;\n\n if (!unit || !end) {\n return [];\n } //cleanup unit param\n\n\n unit = fns.normalize(unit); //cleanup to param\n\n end = start.clone().set(end); //swap them, if they're backwards\n\n if (start.isAfter(end)) {\n var tmp = start;\n start = end;\n end = tmp;\n } //support 'every wednesday'\n\n\n var d = start.clone();\n\n if (isDay(unit)) {\n d = d.next(unit);\n unit = 'week';\n } else {\n d = d.next(unit);\n } //okay, actually start doing it\n\n\n var result = [];\n\n while (d.isBefore(end)) {\n result.push(d);\n d = d.add(1, unit);\n }\n\n return result;\n};\n\nvar every_1 = every;\n\nvar parseDst = function parseDst(dst) {\n if (!dst) {\n return [];\n }\n\n return dst.split('->');\n};\n\nvar titleCase = function titleCase(str) {\n str = str[0].toUpperCase() + str.substr(1);\n str = str.replace(/\\/gmt/, '/GMT');\n str = str.replace(/[\\/_]([a-z])/gi, function (s) {\n return s.toUpperCase();\n });\n return str;\n}; //get metadata about this timezone\n\n\nvar timezone = function timezone(s) {\n var zones = s.timezones;\n var tz = s.tz;\n\n if (zones.hasOwnProperty(tz) === false) {\n tz = find(s.tz, zones);\n }\n\n if (tz === null) {\n if (s.silent === false) {\n console.warn(\"Warn: could not find given or local timezone - '\" + s.tz + \"'\");\n }\n\n return {\n current: {\n epochShift: 0\n }\n };\n }\n\n var found = zones[tz];\n var result = {\n name: titleCase(tz),\n hasDst: Boolean(found.dst),\n default_offset: found.offset,\n //do north-hemisphere version as default (sorry!)\n hemisphere: found.hem === 's' ? 'South' : 'North',\n current: {}\n };\n\n if (result.hasDst) {\n var arr = parseDst(found.dst);\n result.change = {\n start: arr[0],\n back: arr[1]\n };\n } //find the offsets for summer/winter times\n //(these variable names are north-centric)\n\n\n var summer = found.offset; // (july)\n\n var winter = summer; // (january) assume it's the same for now\n\n if (result.hasDst === true) {\n if (result.hemisphere === 'North') {\n winter = summer - 1;\n } else {\n //southern hemisphere\n winter = found.offset + 1;\n }\n } //find out which offset to use right now\n //use 'summer' time july-time\n\n\n if (result.hasDst === false) {\n result.current.offset = summer;\n result.current.isDST = false;\n } else if (summerTime(s.epoch, result.change.start, result.change.back, summer) === true) {\n result.current.offset = summer;\n result.current.isDST = result.hemisphere === 'North'; //dst 'on' in winter in north\n } else {\n //use 'winter' january-time\n result.current.offset = winter;\n result.current.isDST = result.hemisphere === 'South'; //dst 'on' in summer in south\n }\n\n return result;\n};\n\nvar timezone_1 = timezone;\n\nvar units$3 = ['century', 'decade', 'year', 'month', 'date', 'day', 'hour', 'minute', 'second', 'millisecond']; //the spacetime instance methods (also, the API)\n\nvar methods = {\n set: function set(input$1, tz) {\n var s = this.clone();\n s = input(s, input$1, null);\n\n if (tz) {\n this.tz = find(tz);\n }\n\n return s;\n },\n timezone: function timezone() {\n return timezone_1(this);\n },\n isDST: function isDST() {\n return timezone_1(this).current.isDST;\n },\n hasDST: function hasDST() {\n return timezone_1(this).hasDst;\n },\n offset: function offset() {\n return timezone_1(this).current.offset * 60;\n },\n hemisphere: function hemisphere() {\n return timezone_1(this).hemisphere;\n },\n format: function format(fmt) {\n return format_1(this, fmt);\n },\n unixFmt: function unixFmt(fmt) {\n return unixFmt_1(this, fmt);\n },\n startOf: function startOf(unit) {\n return startOf_1.startOf(this, unit);\n },\n endOf: function endOf(unit) {\n return startOf_1.endOf(this, unit);\n },\n leapYear: function leapYear() {\n var year = this.year();\n return fns.isLeapYear(year);\n },\n progress: function progress(unit) {\n return progress_1(this, unit);\n },\n nearest: function nearest(unit) {\n return nearest_1(this, unit);\n },\n diff: function diff(d, unit) {\n return diff$1(this, d, unit);\n },\n since: function since(d) {\n if (!d) {\n d = this.clone().set();\n }\n\n return since_1(this, d);\n },\n next: function next(unit) {\n var s = this.add(1, unit);\n return s.startOf(unit);\n },\n //the start of the previous year/week/century\n last: function last(unit) {\n var s = this.subtract(1, unit);\n return s.startOf(unit);\n },\n isValid: function isValid() {\n //null/undefined epochs\n if (!this.epoch && this.epoch !== 0) {\n return false;\n }\n\n return !isNaN(this.d.getTime());\n },\n //travel to this timezone\n \"goto\": function goto(tz) {\n var s = this.clone();\n s.tz = find(tz, s.timezones); //science!\n\n return s;\n },\n //get each week/month/day between a -> b\n every: function every(unit, to) {\n return every_1(this, unit, to);\n },\n isAwake: function isAwake() {\n var hour = this.hour(); //10pm -> 8am\n\n if (hour < 8 || hour > 22) {\n return false;\n }\n\n return true;\n },\n isAsleep: function isAsleep() {\n return !this.isAwake();\n },\n //pretty-printing\n log: function log() {\n console.log('');\n console.log(format_1(this, 'nice-short'));\n return this;\n },\n logYear: function logYear() {\n console.log('');\n console.log(format_1(this, 'full-short'));\n return this;\n },\n json: function json() {\n var _this = this;\n\n return units$3.reduce(function (h, unit) {\n h[unit] = _this[unit]();\n return h;\n }, {});\n },\n debug: function debug() {\n var tz = this.timezone();\n var date = this.format('MM') + ' ' + this.format('date-ordinal') + ' ' + this.year();\n date += '\\n - ' + this.format('time');\n console.log('\\n\\n', date + '\\n - ' + tz.name + ' (' + tz.current.offset + ')');\n return this;\n },\n //alias of 'since' but opposite - like moment.js\n from: function from(d) {\n d = this.clone().set(d);\n return d.since(this);\n },\n fromNow: function fromNow() {\n var d = this.clone().set(Date.now());\n return d.since(this);\n },\n weekStart: function weekStart(input) {\n //accept a number directly\n if (typeof input === 'number') {\n this._weekStart = input;\n return this;\n }\n\n if (typeof input === 'string') {\n // accept 'wednesday'\n input = input.toLowerCase().trim();\n var num = days[\"short\"]().indexOf(input);\n\n if (num === -1) {\n num = days[\"long\"]().indexOf(input);\n }\n\n if (num === -1) {\n num = 1; //go back to default\n }\n\n this._weekStart = num;\n } else {\n console.warn('Spacetime Error: Cannot understand .weekStart() input:', input);\n }\n\n return this;\n }\n}; // aliases\n\nmethods.inDST = methods.isDST;\nmethods.round = methods.nearest;\nmethods.each = methods.every;\nvar methods_1 = methods;\n\n//these methods wrap around them.\n\nvar validate = function validate(n) {\n //handle number as a string\n if (typeof n === 'string') {\n n = parseInt(n, 10);\n }\n\n return n;\n};\n\nvar order = ['year', 'month', 'date', 'hour', 'minute', 'second', 'millisecond']; //reduce hostile micro-changes when moving dates by millisecond\n\nvar confirm = function confirm(s, tmp, unit) {\n var n = order.indexOf(unit);\n var arr = order.slice(n, order.length);\n\n for (var i = 0; i < arr.length; i++) {\n var want = tmp[arr[i]]();\n s[arr[i]](want);\n }\n\n return s;\n};\n\nvar set = {\n milliseconds: function milliseconds(s, n) {\n n = validate(n);\n var current = s.millisecond();\n var diff = current - n; //milliseconds to shift by\n\n return s.epoch - diff;\n },\n seconds: function seconds(s, n) {\n n = validate(n);\n var diff = s.second() - n;\n var shift = diff * milliseconds.second;\n return s.epoch - shift;\n },\n minutes: function minutes(s, n) {\n n = validate(n);\n var old = s.clone();\n var diff = s.minute() - n;\n var shift = diff * milliseconds.minute;\n s.epoch -= shift;\n confirm(s, old, 'second');\n return s.epoch;\n },\n hours: function hours(s, n) {\n n = validate(n);\n\n if (n >= 24) {\n n = 24;\n } else if (n < 0) {\n n = 0;\n }\n\n var old = s.clone();\n var diff = s.hour() - n;\n var shift = diff * milliseconds.hour;\n s.epoch -= shift;\n walk_1(s, {\n hour: n\n });\n confirm(s, old, 'minute');\n return s.epoch;\n },\n //support setting time by '4:25pm' - this isn't very-well developed..\n time: function time(s, str) {\n var m = str.match(/([0-9]{1,2}):([0-9]{1,2})(am|pm)?/);\n\n if (!m) {\n //fallback to support just '2am'\n m = str.match(/([0-9]{1,2})(am|pm)/);\n\n if (!m) {\n return s.epoch;\n }\n\n m.splice(2, 0, '0'); //add implicit 0 minutes\n }\n\n var h24 = false;\n var hour = parseInt(m[1], 10);\n var minute = parseInt(m[2], 10);\n\n if (hour > 12) {\n h24 = true;\n } //make the hour into proper 24h time\n\n\n if (h24 === false) {\n if (m[3] === 'am' && hour === 12) {\n //12am is midnight\n hour = 0;\n }\n\n if (m[3] === 'pm' && hour < 12) {\n //12pm is noon\n hour += 12;\n }\n }\n\n s = s.hour(hour);\n s = s.minute(minute);\n s = s.second(0);\n s = s.millisecond(0);\n return s.epoch;\n },\n date: function date(s, n) {\n n = validate(n); //avoid setting february 31st\n\n if (n > 28) {\n var max = monthLengths_1[s.month()];\n\n if (n > max) {\n n = max;\n }\n } //avoid setting < 0\n\n\n if (n <= 0) {\n n = 1;\n }\n\n walk_1(s, {\n date: n\n });\n return s.epoch;\n },\n //this one's tricky\n month: function month(s, n) {\n if (typeof n === 'string') {\n n = months.mapping()[n.toLowerCase()];\n }\n\n n = validate(n); //don't go past december\n\n if (n >= 12) {\n n = 11;\n }\n\n if (n <= 0) {\n n = 0;\n }\n\n var date = s.date(); //there's no 30th of february, etc.\n\n if (date > monthLengths_1[n]) {\n //make it as close as we can..\n date = monthLengths_1[n];\n }\n\n walk_1(s, {\n month: n,\n date: date\n });\n return s.epoch;\n },\n year: function year(s, n) {\n n = validate(n);\n walk_1(s, {\n year: n\n });\n return s.epoch;\n },\n dayOfYear: function dayOfYear(s, n) {\n n = validate(n);\n var old = s.clone();\n n -= 1; //days are 1-based\n\n if (n <= 0) {\n n = 0;\n } else if (n >= 365) {\n n = 364;\n }\n\n s = s.startOf('year');\n s = s.add(n, 'day');\n confirm(s, old, 'hour');\n return s.epoch;\n }\n};\n\nvar methods$1 = {\n millisecond: function millisecond(num) {\n if (num !== undefined) {\n var s = this.clone();\n s.epoch = set.milliseconds(s, num);\n return s;\n }\n\n return this.d.getMilliseconds();\n },\n second: function second(num) {\n if (num !== undefined) {\n var s = this.clone();\n s.epoch = set.seconds(s, num);\n return s;\n }\n\n return this.d.getSeconds();\n },\n minute: function minute(num) {\n if (num !== undefined) {\n var s = this.clone();\n s.epoch = set.minutes(s, num);\n return s;\n }\n\n return this.d.getMinutes();\n },\n hour: function hour(num) {\n var d = this.d;\n\n if (num !== undefined) {\n var s = this.clone();\n s.epoch = set.hours(s, num);\n return s;\n }\n\n return d.getHours();\n },\n //'3:30' is 3.5\n hourFloat: function hourFloat(num) {\n if (num !== undefined) {\n var s = this.clone();\n\n var _minute = num % 1;\n\n _minute = _minute * 60;\n\n var _hour = parseInt(num, 10);\n\n s.epoch = set.hours(s, _hour);\n s.epoch = set.minutes(s, _minute);\n return s;\n }\n\n var d = this.d;\n var hour = d.getHours();\n var minute = d.getMinutes();\n minute = minute / 60;\n return hour + minute;\n },\n // hour in 12h format\n hour12: function hour12(str) {\n var d = this.d;\n\n if (str !== undefined) {\n var s = this.clone();\n str = '' + str;\n var m = str.match(/^([0-9]+)(am|pm)$/);\n\n if (m) {\n var hour = parseInt(m[1], 10);\n\n if (m[2] === 'pm') {\n hour += 12;\n }\n\n s.epoch = set.hours(s, hour);\n }\n\n return s;\n } //get the hour\n\n\n var hour12 = d.getHours();\n\n if (hour12 > 12) {\n hour12 = hour12 - 12;\n }\n\n if (hour12 === 0) {\n hour12 = 12;\n }\n\n return hour12;\n },\n //some ambiguity here with 12/24h\n time: function time(str) {\n if (str !== undefined) {\n var s = this.clone();\n s.epoch = set.time(s, str);\n return s;\n }\n\n return \"\".concat(this.h12(), \":\").concat(fns.zeroPad(this.minute())).concat(this.ampm());\n },\n // either 'am' or 'pm'\n ampm: function ampm(input) {\n var which = 'am';\n var hour = this.hour();\n\n if (hour >= 12) {\n which = 'pm';\n }\n\n if (typeof input !== 'string') {\n return which;\n } //okay, we're doing a setter\n\n\n var s = this.clone();\n input = input.toLowerCase().trim(); //ampm should never change the day\n // - so use `.hour(n)` instead of `.minus(12,'hour')`\n\n if (hour >= 12 && input === 'am') {\n //noon is 12pm\n hour -= 12;\n return s.hour(hour);\n }\n\n if (hour < 12 && input === 'pm') {\n hour += 12;\n return s.hour(hour);\n }\n\n return s;\n },\n //some hard-coded times of day, like 'noon'\n dayTime: function dayTime(str) {\n if (str !== undefined) {\n var times = {\n morning: '7:00am',\n breakfast: '7:00am',\n noon: '12:00am',\n lunch: '12:00pm',\n afternoon: '2:00pm',\n evening: '6:00pm',\n dinner: '6:00pm',\n night: '11:00pm',\n midnight: '23:59pm'\n };\n var s = this.clone();\n str = str || '';\n str = str.toLowerCase();\n\n if (times.hasOwnProperty(str) === true) {\n s = s.time(times[str]);\n }\n\n return s;\n }\n\n var h = this.hour();\n\n if (h < 6) {\n return 'night';\n }\n\n if (h < 12) {\n //until noon\n return 'morning';\n }\n\n if (h < 17) {\n //until 5pm\n return 'afternoon';\n }\n\n if (h < 22) {\n //until 10pm\n return 'evening';\n }\n\n return 'night';\n },\n //parse a proper iso string\n iso: function iso(num) {\n if (num !== undefined) {\n return this.set(num);\n }\n\n return this.format('iso');\n }\n};\nvar _01Time = methods$1;\n\nvar methods$2 = {\n // # day in the month\n date: function date(num) {\n if (num !== undefined) {\n var s = this.clone();\n s.epoch = set.date(s, num);\n return s;\n }\n\n return this.d.getDate();\n },\n //like 'wednesday' (hard!)\n day: function day(input) {\n if (input === undefined) {\n return this.d.getDay();\n }\n\n var original = this.clone();\n var want = input; // accept 'wednesday'\n\n if (typeof input === 'string') {\n input = input.toLowerCase();\n want = days[\"short\"]().indexOf(input);\n\n if (want === -1) {\n want = days[\"long\"]().indexOf(input);\n }\n } //move approx\n\n\n var day = this.d.getDay();\n var diff = day - want;\n var s = this.subtract(diff * 24, 'hours'); //tighten it back up\n\n walk_1(s, {\n hour: original.hour(),\n minute: original.minute(),\n second: original.second()\n });\n return s;\n },\n //these are helpful name-wrappers\n dayName: function dayName(input) {\n if (input === undefined) {\n return days[\"long\"]()[this.day()];\n }\n\n var s = this.clone();\n s = s.day(input);\n return s;\n },\n //either name or number\n month: function month(input) {\n if (input !== undefined) {\n var s = this.clone();\n s.epoch = set.month(s, input);\n return s;\n }\n\n return this.d.getMonth();\n }\n};\nvar _02Date = methods$2;\n\nvar clearMinutes = function clearMinutes(s) {\n s = s.minute(0);\n s = s.second(0);\n s = s.millisecond(1);\n return s;\n};\n\nvar methods$3 = {\n // day 0-366\n dayOfYear: function dayOfYear(num) {\n if (num !== undefined) {\n var s = this.clone();\n s.epoch = set.dayOfYear(s, num);\n return s;\n } //days since newyears - jan 1st is 1, jan 2nd is 2...\n\n\n var sum = 0;\n var month = this.d.getMonth();\n var tmp; //count the num days in each month\n\n for (var i = 1; i <= month; i++) {\n tmp = new Date();\n tmp.setDate(1);\n tmp.setFullYear(this.d.getFullYear()); //the year matters, because leap-years\n\n tmp.setHours(1);\n tmp.setMinutes(1);\n tmp.setMonth(i);\n tmp.setHours(-2); //the last day of the month\n\n sum += tmp.getDate();\n }\n\n return sum + this.d.getDate();\n },\n //since the start of the year\n week: function week(num) {\n // week-setter\n if (num !== undefined) {\n var s = this.clone();\n s = s.month(0);\n s = s.date(1);\n s = s.day('monday');\n s = clearMinutes(s); //don't go into last-year\n\n if (s.monthName() === 'december') {\n s = s.add(1, 'week');\n }\n\n num -= 1; //1-based\n\n s = s.add(num, 'weeks');\n return s;\n } //find-out which week it is\n\n\n var tmp = this.clone();\n tmp = tmp.month(0);\n tmp = tmp.date(1);\n tmp = clearMinutes(tmp);\n tmp = tmp.day('monday'); //don't go into last-year\n\n if (tmp.monthName() === 'december') {\n tmp = tmp.add(1, 'week');\n } // is first monday the 1st?\n\n\n var toAdd = 1;\n\n if (tmp.date() === 1) {\n toAdd = 0;\n }\n\n tmp = tmp.minus(1, 'second');\n var thisOne = this.epoch; //if the week technically hasn't started yet\n\n if (tmp.epoch > thisOne) {\n return 1;\n } //speed it up, if we can\n\n\n var i = 0;\n var skipWeeks = this.month() * 4;\n tmp.epoch += milliseconds.week * skipWeeks;\n i += skipWeeks;\n\n for (; i < 52; i++) {\n if (tmp.epoch > thisOne) {\n return i + toAdd;\n }\n\n tmp = tmp.add(1, 'week');\n }\n\n return 52;\n },\n //'january'\n monthName: function monthName(input) {\n if (input === undefined) {\n return months[\"long\"]()[this.month()];\n }\n\n var s = this.clone();\n s = s.month(input);\n return s;\n },\n //q1, q2, q3, q4\n quarter: function quarter(num) {\n if (num !== undefined) {\n if (typeof num === 'string') {\n num = num.replace(/^q/i, '');\n num = parseInt(num, 10);\n }\n\n if (quarters[num]) {\n var s = this.clone();\n var _month = quarters[num][0];\n s = s.month(_month);\n s = s.date(1);\n s = s.startOf('day');\n return s;\n }\n }\n\n var month = this.d.getMonth();\n\n for (var i = 1; i < quarters.length; i++) {\n if (month < quarters[i][0]) {\n return i - 1;\n }\n }\n\n return 4;\n },\n //spring, summer, winter, fall\n season: function season(input) {\n var hem = 'north';\n\n if (this.hemisphere() === 'South') {\n hem = 'south';\n }\n\n if (input !== undefined) {\n var s = this.clone();\n\n for (var i = 0; i < seasons[hem].length; i++) {\n if (input === seasons[hem][i][0]) {\n s = s.month(seasons[hem][i][1]);\n s = s.date(1);\n s = s.startOf('day');\n }\n }\n\n return s;\n }\n\n var month = this.d.getMonth();\n\n for (var _i = 0; _i < seasons[hem].length - 1; _i++) {\n if (month >= seasons[hem][_i][1] && month < seasons[hem][_i + 1][1]) {\n return seasons[hem][_i][0];\n }\n }\n\n return 'winter';\n },\n //the year number\n year: function year(num) {\n if (num !== undefined) {\n var s = this.clone();\n s.epoch = set.year(s, num);\n return s;\n }\n\n return this.d.getFullYear();\n },\n //bc/ad years\n era: function era(str) {\n if (str !== undefined) {\n var s = this.clone();\n str = str.toLowerCase(); //TODO: there is no year-0AD i think. may have off-by-1 error here\n\n var year = s.d.getFullYear(); //make '1992' into 1992bc..\n\n if (str === 'bc' && year > 0) {\n s.epoch = set.year(s, year * -1);\n } //make '1992bc' into '1992'\n\n\n if (str === 'ad' && year < 0) {\n s.epoch = set.year(s, year * -1);\n }\n\n return s;\n }\n\n if (this.d.getFullYear() < 0) {\n return 'BC';\n }\n\n return 'AD';\n },\n // 2019 -> 2010\n decade: function decade(input) {\n if (input !== undefined) {\n input = String(input);\n input = input.replace(/([0-9])'?s$/, '$1'); //1950's\n\n input = input.replace(/([0-9])(th|rd|st|nd)/, '$1'); //fix ordinals\n\n if (!input) {\n console.warn('Spacetime: Invalid decade input');\n return this;\n } // assume 20th century?? for '70s'.\n\n\n if (input.length === 2 && /[0-9][0-9]/.test(input)) {\n input = '19' + input;\n }\n\n var year = Number(input);\n\n if (isNaN(year)) {\n return this;\n } // round it down to the decade\n\n\n year = Math.floor(year / 10) * 10;\n return this.year(year); //.startOf('decade')\n }\n\n return this.startOf('decade').year();\n },\n // 1950 -> 19+1\n century: function century(input) {\n if (input !== undefined) {\n if (typeof input === 'string') {\n input = input.replace(/([0-9])(th|rd|st|nd)/, '$1'); //fix ordinals\n\n input = input.replace(/([0-9]+) ?(b\\.?c\\.?|a\\.?d\\.?)/i, function (a, b, c) {\n if (c.match(/b\\.?c\\.?/i)) {\n b = '-' + b;\n }\n\n return b;\n });\n input = input.replace(/c$/, ''); //20thC\n }\n\n var year = Number(input);\n\n if (isNaN(input)) {\n console.warn('Spacetime: Invalid century input');\n return this;\n } // there is no century 0\n\n\n if (year === 0) {\n year = 1;\n }\n\n if (year >= 0) {\n year = (year - 1) * 100;\n } else {\n year = (year + 1) * 100;\n }\n\n return this.year(year);\n } // century getter\n\n\n var num = this.startOf('century').year();\n num = Math.floor(num / 100);\n\n if (num < 0) {\n return num - 1;\n }\n\n return num + 1;\n },\n // 2019 -> 2+1\n millenium: function millenium(input) {\n if (input !== undefined) {\n if (typeof input === 'string') {\n input = input.replace(/([0-9])(th|rd|st|nd)/, '$1'); //fix ordinals\n\n input = Number(input);\n\n if (isNaN(input)) {\n console.warn('Spacetime: Invalid millenium input');\n return this;\n }\n }\n\n if (input > 0) {\n input -= 1;\n }\n\n var year = input * 1000; // there is no year 0\n\n if (year === 0) {\n year = 1;\n }\n\n return this.year(year);\n } // get the current millenium\n\n\n var num = Math.floor(this.year() / 1000);\n\n if (num >= 0) {\n num += 1;\n }\n\n return num;\n }\n};\nvar _03Year = methods$3;\n\nvar methods$4 = Object.assign({}, _01Time, _02Date, _03Year); //aliases\n\nmethods$4.milliseconds = methods$4.millisecond;\nmethods$4.seconds = methods$4.second;\nmethods$4.minutes = methods$4.minute;\nmethods$4.hours = methods$4.hour;\nmethods$4.hour24 = methods$4.hour;\nmethods$4.h12 = methods$4.hour12;\nmethods$4.h24 = methods$4.hour24;\nmethods$4.days = methods$4.day;\n\nvar addMethods = function addMethods(Space) {\n //hook the methods into prototype\n Object.keys(methods$4).forEach(function (k) {\n Space.prototype[k] = methods$4[k];\n });\n};\n\nvar query = addMethods;\n\nvar isLeapYear$1 = fns.isLeapYear;\n\nvar getMonthLength = function getMonthLength(month, year) {\n if (month === 1 && isLeapYear$1(year)) {\n return 29;\n }\n\n return monthLengths_1[month];\n}; //month is the one thing we 'model/compute'\n//- because ms-shifting can be off by enough\n\n\nvar rollMonth = function rollMonth(want, old) {\n //increment year\n if (want.month > 0) {\n var years = parseInt(want.month / 12, 10);\n want.year = old.year() + years;\n want.month = want.month % 12;\n } else if (want.month < 0) {\n //decrement year\n var _years = Math.floor(Math.abs(want.month) / 13, 10);\n\n _years = Math.abs(_years) + 1;\n want.year = old.year() - _years; //ignore extras\n\n want.month = want.month % 12;\n want.month = want.month + 12;\n\n if (want.month === 12) {\n want.month = 0;\n }\n }\n\n return want;\n};\n\nvar rollDaysDown = function rollDaysDown(want, old, sum) {\n want.year = old.year();\n want.month = old.month();\n var date = old.date();\n want.date = date - Math.abs(sum);\n\n while (want.date < 1) {\n want.month -= 1;\n\n if (want.month < 0) {\n want.month = 11;\n want.year -= 1;\n }\n\n var max = getMonthLength(want.month, want.year);\n want.date += max;\n }\n\n return want;\n}; // briefly support day=33 (this does not need to be perfect.)\n\n\nvar rollDaysUp = function rollDaysUp(want, old, sum) {\n var year = old.year();\n var month = old.month();\n var max = getMonthLength(month, year);\n\n while (sum > max) {\n sum -= max;\n month += 1;\n\n if (month >= 12) {\n month -= 12;\n year += 1;\n }\n\n max = getMonthLength(month, year);\n }\n\n want.month = month;\n want.date = sum;\n return want;\n};\n\nvar _model = {\n months: rollMonth,\n days: rollDaysUp,\n daysBack: rollDaysDown\n};\n\n// but briefly:\n// millisecond-math, and some post-processing covers most-things\n// we 'model' the calendar here only a little bit\n// and that usually works-out...\n\nvar order$1 = ['millisecond', 'second', 'minute', 'hour', 'date', 'month'];\nvar keep = {\n second: order$1.slice(0, 1),\n minute: order$1.slice(0, 2),\n quarterhour: order$1.slice(0, 2),\n hour: order$1.slice(0, 3),\n date: order$1.slice(0, 4),\n month: order$1.slice(0, 4),\n quarter: order$1.slice(0, 4),\n season: order$1.slice(0, 4),\n year: order$1,\n decade: order$1,\n century: order$1\n};\nkeep.week = keep.hour;\nkeep.season = keep.date;\nkeep.quarter = keep.date; // Units need to be dst adjuested\n\nvar dstAwareUnits = {\n year: true,\n quarter: true,\n season: true,\n month: true,\n week: true,\n day: true\n};\nvar keepDate = {\n month: true,\n quarter: true,\n season: true,\n year: true\n};\n\nvar addMethods$1 = function addMethods(SpaceTime) {\n SpaceTime.prototype.add = function (num, unit) {\n var s = this.clone();\n\n if (!unit || num === 0) {\n return s; //don't bother\n }\n\n var old = this.clone();\n unit = fns.normalize(unit); //move forward by the estimated milliseconds (rough)\n\n if (milliseconds[unit]) {\n s.epoch += milliseconds[unit] * num;\n } else if (unit === 'week') {\n s.epoch += milliseconds.day * (num * 7);\n } else if (unit === 'quarter' || unit === 'season') {\n s.epoch += milliseconds.month * (num * 4);\n } else if (unit === 'season') {\n s.epoch += milliseconds.month * (num * 4);\n } else if (unit === 'quarterhour') {\n s.epoch += milliseconds.minute * 15 * num;\n } //now ensure our milliseconds/etc are in-line\n\n\n var want = {};\n\n if (keep[unit]) {\n keep[unit].forEach(function (u) {\n want[u] = old[u]();\n });\n }\n\n if (dstAwareUnits[unit]) {\n var diff = old.timezone().current.offset - s.timezone().current.offset;\n s.epoch += diff * 3600 * 1000;\n } //ensure month/year has ticked-over\n\n\n if (unit === 'month') {\n want.month = old.month() + num; //month is the one unit we 'model' directly\n\n want = _model.months(want, old);\n } //support coercing a week, too\n\n\n if (unit === 'week') {\n var sum = old.date() + num * 7;\n\n if (sum <= 28 && sum > 1) {\n want.date = sum;\n }\n } //support 25-hour day-changes on dst-changes\n else if (unit === 'date') {\n if (num < 0) {\n want = _model.daysBack(want, old, num);\n } else {\n //specify a naive date number, if it's easy to do...\n var _sum = old.date() + num; // ok, model this one too\n\n\n want = _model.days(want, old, _sum);\n } //manually punt it if we haven't moved at all..\n\n\n if (num !== 0 && old.isSame(s, 'day')) {\n want.date = old.date() + num;\n }\n } //ensure year has changed (leap-years)\n else if (unit === 'year' && s.year() === old.year()) {\n s.epoch += milliseconds.week;\n } //these are easier\n else if (unit === 'decade') {\n want.year = s.year() + 10;\n } else if (unit === 'century') {\n want.year = s.year() + 100;\n } //keep current date, unless the month doesn't have it.\n\n\n if (keepDate[unit]) {\n var max = monthLengths_1[want.month];\n want.date = old.date();\n\n if (want.date > max) {\n want.date = max;\n }\n }\n\n walk_1(s, want);\n return s;\n }; //subtract is only add *-1\n\n\n SpaceTime.prototype.subtract = function (num, unit) {\n var s = this.clone();\n return s.add(num * -1, unit);\n }; //add aliases\n\n\n SpaceTime.prototype.minus = SpaceTime.prototype.subtract;\n SpaceTime.prototype.plus = SpaceTime.prototype.add;\n};\n\nvar add = addMethods$1;\n\n//make a string, for easy comparison between dates\nvar print = {\n millisecond: function millisecond(s) {\n return s.epoch;\n },\n second: function second(s) {\n return [s.year(), s.month(), s.date(), s.hour(), s.minute(), s.second()].join('-');\n },\n minute: function minute(s) {\n return [s.year(), s.month(), s.date(), s.hour(), s.minute()].join('-');\n },\n hour: function hour(s) {\n return [s.year(), s.month(), s.date(), s.hour()].join('-');\n },\n day: function day(s) {\n return [s.year(), s.month(), s.date()].join('-');\n },\n week: function week(s) {\n return [s.year(), s.week()].join('-');\n },\n month: function month(s) {\n return [s.year(), s.month()].join('-');\n },\n quarter: function quarter(s) {\n return [s.year(), s.quarter()].join('-');\n },\n year: function year(s) {\n return s.year();\n }\n};\nprint.date = print.day;\n\nvar addMethods$2 = function addMethods(SpaceTime) {\n SpaceTime.prototype.isSame = function (b, unit) {\n var a = this;\n\n if (!unit) {\n return null;\n }\n\n if (typeof b === 'string' || typeof b === 'number') {\n b = new SpaceTime(b, this.timezone.name);\n } //support 'seconds' aswell as 'second'\n\n\n unit = unit.replace(/s$/, '');\n\n if (print[unit]) {\n return print[unit](a) === print[unit](b);\n }\n\n return null;\n };\n};\n\nvar same = addMethods$2;\n\nvar addMethods$3 = function addMethods(SpaceTime) {\n var methods = {\n isAfter: function isAfter(d) {\n d = fns.beADate(d, this);\n var epoch = fns.getEpoch(d);\n\n if (epoch === null) {\n return null;\n }\n\n return this.epoch > epoch;\n },\n isBefore: function isBefore(d) {\n d = fns.beADate(d, this);\n var epoch = fns.getEpoch(d);\n\n if (epoch === null) {\n return null;\n }\n\n return this.epoch < epoch;\n },\n isEqual: function isEqual(d) {\n d = fns.beADate(d, this);\n var epoch = fns.getEpoch(d);\n\n if (epoch === null) {\n return null;\n }\n\n return this.epoch === epoch;\n },\n isBetween: function isBetween(start, end) {\n var isInclusive = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;\n start = fns.beADate(start, this);\n end = fns.beADate(end, this);\n var startEpoch = fns.getEpoch(start);\n\n if (startEpoch === null) {\n return null;\n }\n\n var endEpoch = fns.getEpoch(end);\n\n if (endEpoch === null) {\n return null;\n }\n\n if (isInclusive) {\n return this.isBetween(start, end) || this.isEqual(start) || this.isEqual(end);\n }\n\n return startEpoch < this.epoch && this.epoch < endEpoch;\n }\n }; //hook them into proto\n\n Object.keys(methods).forEach(function (k) {\n SpaceTime.prototype[k] = methods[k];\n });\n};\n\nvar compare = addMethods$3;\n\nvar addMethods$4 = function addMethods(SpaceTime) {\n var methods = {\n i18n: function i18n(data) {\n //change the day names\n if (fns.isObject(data.days)) {\n days.set(data.days);\n } //change the month names\n\n\n if (fns.isObject(data.months)) {\n months.set(data.months);\n }\n }\n }; //hook them into proto\n\n Object.keys(methods).forEach(function (k) {\n SpaceTime.prototype[k] = methods[k];\n });\n};\n\nvar i18n = addMethods$4;\n\nvar timezones = unpack; //fake timezone-support, for fakers (es5 class)\n\nvar SpaceTime = function SpaceTime(input$1, tz) {\n var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};\n //the holy moment\n this.epoch = null; //the shift for the given timezone\n\n this.tz = find(tz, timezones); //whether to output warnings to console\n\n this.silent = options.silent || true; // favour british interpretation of 02/02/2018, etc\n\n this.british = options.dmy || options.british; //does the week start on sunday, or monday:\n\n this._weekStart = 1; //default to monday\n\n if (options.weekStart !== undefined) {\n this._weekStart = options.weekStart;\n } // the reference today date object, (for testing)\n\n\n this._today = {};\n\n if (options.today !== undefined) {\n this._today = options.today;\n } //add getter/setters\n\n\n Object.defineProperty(this, 'd', {\n //return a js date object\n get: function get() {\n var offset = quick(this); //every computer is somewhere- get this computer's built-in offset\n\n var bias = new Date(this.epoch).getTimezoneOffset() || 0; //movement\n\n var shift = bias + offset * 60; //in minutes\n\n shift = shift * 60 * 1000; //in ms\n //remove this computer's offset\n\n var epoch = this.epoch + shift;\n var d = new Date(epoch);\n return d;\n }\n }); //add this data on the object, to allow adding new timezones\n\n Object.defineProperty(this, 'timezones', {\n get: function get() {\n return timezones;\n },\n set: function set(obj) {\n timezones = obj;\n return obj;\n }\n }); //parse the various formats\n\n var tmp = input(this, input$1, tz);\n this.epoch = tmp.epoch;\n}; //(add instance methods to prototype)\n\n\nObject.keys(methods_1).forEach(function (k) {\n SpaceTime.prototype[k] = methods_1[k];\n}); // ¯\\_(ツ)_/¯\n\nSpaceTime.prototype.clone = function () {\n return new SpaceTime(this.epoch, this.tz, {\n silent: this.silent,\n weekStart: this._weekStart,\n today: this._today\n });\n}; //return native date object at the same epoch\n\n\nSpaceTime.prototype.toLocalDate = function () {\n return new Date(this.epoch);\n}; //append more methods\n\n\nquery(SpaceTime);\nadd(SpaceTime);\nsame(SpaceTime);\ncompare(SpaceTime);\ni18n(SpaceTime);\nvar spacetime = SpaceTime;\n\nvar whereIts = function whereIts(a, b) {\n var start = new spacetime(null);\n var end = new spacetime(null);\n start = start.time(a); //if b is undefined, use as 'within one hour'\n\n if (b) {\n end = end.time(b);\n } else {\n end = start.add(59, 'minutes');\n }\n\n var startHour = start.hour();\n var endHour = end.hour();\n var tzs = Object.keys(start.timezones).filter(function (tz) {\n if (tz.indexOf('/') === -1) {\n return false;\n }\n\n var m = new spacetime(null, tz);\n var hour = m.hour(); //do 'calendar-compare' not real-time-compare\n\n if (hour >= startHour && hour <= endHour) {\n //test minutes too, if applicable\n if (hour === startHour && m.minute() < start.minute()) {\n return false;\n }\n\n if (hour === endHour && m.minute() > end.minute()) {\n return false;\n }\n\n return true;\n }\n\n return false;\n });\n return tzs;\n};\n\nvar whereIts_1 = whereIts;\n\nvar _version = '6.6.0';\n\nvar main$1 = function main(input, tz, options) {\n return new spacetime(input, tz, options);\n}; // set all properties of a given 'today' object\n\n\nvar setToday = function setToday(s) {\n var today = s._today || {};\n Object.keys(today).forEach(function (k) {\n s = s[k](today[k]);\n });\n return s;\n}; //some helper functions on the main method\n\n\nmain$1.now = function (tz, options) {\n var s = new spacetime(new Date().getTime(), tz, options);\n s = setToday(s);\n return s;\n};\n\nmain$1.today = function (tz, options) {\n var s = new spacetime(new Date().getTime(), tz, options);\n s = setToday(s);\n return s.startOf('day');\n};\n\nmain$1.tomorrow = function (tz, options) {\n var s = new spacetime(new Date().getTime(), tz, options);\n s = setToday(s);\n return s.add(1, 'day').startOf('day');\n};\n\nmain$1.yesterday = function (tz, options) {\n var s = new spacetime(new Date().getTime(), tz, options);\n s = setToday(s);\n return s.subtract(1, 'day').startOf('day');\n};\n\nmain$1.extend = function (obj) {\n Object.keys(obj).forEach(function (k) {\n spacetime.prototype[k] = obj[k];\n });\n return this;\n}; //find tz by time\n\n\nmain$1.whereIts = whereIts_1;\nmain$1.version = _version; //aliases:\n\nmain$1.plugin = main$1.extend;\nvar src = main$1;\n\nexport default src;\n","// some opinionated-but-common-sense timezone abbreviations\n// these timezone abbreviations are wholly made-up by me, Spencer Kelly, with no expertise in geography\n// generated humbly from https://github.com/spencermountain/spacetime-informal\nconst spacetime = require('spacetime')\n\nconst america = 'America/'\nconst asia = 'Asia/'\nconst europe = 'Europe/'\nconst africa = 'Africa/'\nconst aus = 'Australia/'\nconst pac = 'Pacific/'\n\nconst informal = {\n //europe\n 'british summer time': europe + 'London',\n bst: europe + 'London',\n 'british time': europe + 'London',\n 'britain time': europe + 'London',\n 'irish summer time': europe + 'Dublin',\n 'irish time': europe + 'Dublin',\n ireland: europe + 'Dublin',\n 'central european time': europe + 'Berlin',\n cet: europe + 'Berlin',\n 'central european summer time': europe + 'Berlin',\n cest: europe + 'Berlin',\n 'central europe': europe + 'Berlin',\n 'eastern european time': europe + 'Riga',\n eet: europe + 'Riga',\n 'eastern european summer time': europe + 'Riga',\n eest: europe + 'Riga',\n 'eastern europe time': europe + 'Riga',\n 'western european time': europe + 'Lisbon',\n // wet: europe+'Lisbon',\n 'western european summer time': europe + 'Lisbon',\n // west: europe+'Lisbon',\n 'western europe': europe + 'Lisbon',\n 'turkey standard time': europe + 'Istanbul',\n trt: europe + 'Istanbul',\n 'turkish time': europe + 'Istanbul',\n\n //africa\n etc: africa + 'Freetown',\n utc: africa + 'Freetown',\n 'greenwich standard time': africa + 'Freetown',\n gmt: africa + 'Freetown',\n 'east africa time': africa + 'Nairobi',\n // eat: africa+'Nairobi',\n 'east african time': africa + 'Nairobi',\n 'eastern africa time': africa + 'Nairobi',\n 'central africa time': africa + 'Khartoum',\n // cat: africa+'Khartoum',\n 'central african time': africa + 'Khartoum',\n 'south africa standard time': africa + 'Johannesburg',\n sast: africa + 'Johannesburg',\n 'southern africa': africa + 'Johannesburg',\n 'south african': africa + 'Johannesburg',\n 'west africa standard time': africa + 'Lagos',\n // wat: africa+'Lagos',\n 'western africa time': africa + 'Lagos',\n 'west african time': africa + 'Lagos',\n\n 'australian central standard time': aus + 'Adelaide',\n acst: aus + 'Adelaide',\n 'australian central daylight time': aus + 'Adelaide',\n acdt: aus + 'Adelaide',\n 'australia central': aus + 'Adelaide',\n 'australian eastern standard time': aus + 'Brisbane',\n aest: aus + 'Brisbane',\n 'australian eastern daylight time': aus + 'Brisbane',\n aedt: aus + 'Brisbane',\n 'australia east': aus + 'Brisbane',\n 'australian western standard time': aus + 'Perth',\n awst: aus + 'Perth',\n 'australian western daylight time': aus + 'Perth',\n awdt: aus + 'Perth',\n 'australia west': aus + 'Perth',\n 'australian central western standard time': aus + 'Eucla',\n acwst: aus + 'Eucla',\n 'australia central west': aus + 'Eucla',\n 'lord howe standard time': aus + 'Lord_Howe',\n lhst: aus + 'Lord_Howe',\n 'lord howe daylight time': aus + 'Lord_Howe',\n lhdt: aus + 'Lord_Howe',\n 'russian standard time': europe + 'Moscow',\n msk: europe + 'Moscow',\n russian: europe + 'Moscow',\n\n //america\n 'central standard time': america + 'Chicago',\n 'central time': america + 'Chicago',\n cst: america + 'Havana',\n 'central daylight time': america + 'Chicago',\n cdt: america + 'Havana',\n 'mountain standard time': america + 'Denver',\n 'mountain time': america + 'Denver',\n mst: america + 'Denver',\n 'mountain daylight time': america + 'Denver',\n mdt: america + 'Denver',\n 'atlantic standard time': america + 'Halifax',\n 'atlantic time': america + 'Halifax',\n ast: asia + 'Baghdad',\n 'atlantic daylight time': america + 'Halifax',\n adt: america + 'Halifax',\n 'eastern standard time': america + 'New_York',\n 'eastern time': america + 'New_York',\n est: america + 'New_York',\n 'eastern daylight time': america + 'New_York',\n edt: america + 'New_York',\n 'pacific time': america + 'Los_Angeles',\n 'pacific standard time': america + 'Los_Angeles',\n pst: america + 'Los_Angeles',\n 'pacific daylight time': america + 'Los_Angeles',\n pdt: america + 'Los_Angeles',\n 'alaskan standard time': america + 'Anchorage',\n 'alaskan time': america + 'Anchorage',\n ahst: america + 'Anchorage',\n 'alaskan daylight time': america + 'Anchorage',\n ahdt: america + 'Anchorage',\n 'hawaiian standard time': pac + 'Honolulu',\n 'hawaiian time': pac + 'Honolulu',\n hst: pac + 'Honolulu',\n 'aleutian time': pac + 'Honolulu',\n 'hawaii time': pac + 'Honolulu',\n 'newfoundland standard time': america + 'St_Johns',\n 'newfoundland time': america + 'St_Johns',\n nst: america + 'St_Johns',\n 'newfoundland daylight time': america + 'St_Johns',\n ndt: america + 'St_Johns',\n 'brazil time': america + 'Sao_Paulo',\n brt: america + 'Sao_Paulo',\n brasília: america + 'Sao_Paulo',\n brasilia: america + 'Sao_Paulo',\n 'brazilian time': america + 'Sao_Paulo',\n 'argentina time': america + 'Buenos_Aires',\n // art: a+'Buenos_Aires',\n 'argentinian time': america + 'Buenos_Aires',\n 'amazon time': america + 'Manaus',\n amt: america + 'Manaus',\n 'amazonian time': america + 'Manaus',\n 'easter island standard time': 'Chile/Easterisland',\n east: 'Chile/Easterisland',\n 'easter island summer time': 'Chile/Easterisland',\n easst: 'Chile/Easterisland',\n 'venezuelan standard time': america + 'Caracas',\n 'venezuelan time': america + 'Caracas',\n vet: america + 'Caracas',\n 'venezuela time': america + 'Caracas',\n 'paraguay time': america + 'Asuncion',\n pyt: america + 'Asuncion',\n 'paraguay summer time': america + 'Asuncion',\n pyst: america + 'Asuncion',\n 'cuba standard time': america + 'Havana',\n 'cuba time': america + 'Havana',\n 'cuba daylight time': america + 'Havana',\n 'cuban time': america + 'Havana',\n 'bolivia time': america + 'La_Paz',\n // bot: a+'La_Paz',\n 'bolivian time': america + 'La_Paz',\n 'colombia time': america + 'Bogota',\n cot: america + 'Bogota',\n 'colombian time': america + 'Bogota',\n 'acre time': america + 'Eirunepe',\n // act: a+'Eirunepe',\n 'peru time': america + 'Lima',\n // pet: a+'Lima',\n 'chile standard time': america + 'Punta_Arenas',\n 'chile time': america + 'Punta_Arenas',\n clst: america + 'Punta_Arenas',\n 'chile summer time': america + 'Punta_Arenas',\n cldt: america + 'Punta_Arenas',\n 'uruguay time': america + 'Montevideo',\n uyt: america + 'Montevideo',\n\n //asia\n ist: asia + 'Jerusalem',\n 'arabic standard time': asia + 'Baghdad',\n 'arabic time': asia + 'Baghdad',\n 'arab time': asia + 'Baghdad',\n 'iran standard time': asia + 'Tehran',\n 'iran time': asia + 'Tehran',\n irst: asia + 'Tehran',\n 'iran daylight time': asia + 'Tehran',\n irdt: asia + 'Tehran',\n iranian: asia + 'Tehran',\n 'pakistan standard time': asia + 'Karachi',\n 'pakistan time': asia + 'Karachi',\n pkt: asia + 'Karachi',\n 'india standard time': asia + 'Kolkata',\n 'indian time': asia + 'Kolkata',\n 'indochina time': asia + 'Bangkok',\n ict: asia + 'Bangkok',\n 'south east asia': asia + 'Bangkok',\n 'china standard time': asia + 'Shanghai',\n ct: asia + 'Shanghai',\n 'chinese time': asia + 'Shanghai',\n 'alma-ata time': asia + 'Almaty',\n almt: asia + 'Almaty',\n 'oral time': asia + 'Oral',\n 'orat time': asia + 'Oral',\n 'yakutsk time': asia + 'Yakutsk',\n yakt: asia + 'Yakutsk',\n 'gulf standard time': asia + 'Dubai',\n 'gulf time': asia + 'Dubai',\n gst: asia + 'Dubai',\n uae: asia + 'Dubai',\n 'hong kong time': asia + 'Hong_Kong',\n hkt: asia + 'Hong_Kong',\n 'western indonesian time': asia + 'Jakarta',\n wib: asia + 'Jakarta',\n 'indonesia time': asia + 'Jakarta',\n 'central indonesian time': asia + 'Makassar',\n wita: asia + 'Makassar',\n 'israel daylight time': asia + 'Jerusalem',\n idt: asia + 'Jerusalem',\n 'israel standard time': asia + 'Jerusalem',\n 'israel time': asia + 'Jerusalem',\n israeli: asia + 'Jerusalem',\n 'krasnoyarsk time': asia + 'Krasnoyarsk',\n krat: asia + 'Krasnoyarsk',\n 'malaysia time': asia + 'Kuala_Lumpur',\n myt: asia + 'Kuala_Lumpur',\n 'singapore time': asia + 'Singapore',\n sgt: asia + 'Singapore',\n 'korea standard time': asia + 'Seoul',\n 'korea time': asia + 'Seoul',\n kst: asia + 'Seoul',\n 'korean time': asia + 'Seoul',\n 'uzbekistan time': asia + 'Samarkand',\n uzt: asia + 'Samarkand',\n 'vladivostok time': asia + 'Vladivostok',\n vlat: asia + 'Vladivostok',\n\n //indian\n 'maldives time': 'Indian/Maldives',\n mvt: 'Indian/Maldives',\n 'mauritius time': 'Indian/Mauritius',\n mut: 'Indian/Mauritius',\n\n // pacific\n 'marshall islands time': pac + 'Kwajalein',\n mht: pac + 'Kwajalein',\n 'samoa standard time': pac + 'Midway',\n sst: pac + 'Midway',\n 'somoan time': pac + 'Midway',\n 'chamorro standard time': pac + 'Guam',\n chst: pac + 'Guam',\n 'papua new guinea time': pac + 'Bougainville',\n pgt: pac + 'Bougainville',\n}\n\n//add the official iana zonefile names\nlet iana = spacetime().timezones\nlet formal = Object.keys(iana).reduce((h, k) => {\n h[k] = k\n return h\n}, {})\nmodule.exports = Object.assign({}, informal, formal)\n","module.exports = [\n 'weekday',\n\n 'summer',\n 'winter',\n 'autumn',\n\n 'some day',\n 'one day',\n 'all day',\n 'some point',\n\n 'eod',\n 'eom',\n 'standard time',\n 'daylight time',\n]\n","module.exports = [\n 'centuries',\n 'century',\n 'day',\n 'days',\n 'decade',\n 'decades',\n 'hour',\n 'hours',\n 'millisecond',\n 'milliseconds',\n 'minute',\n 'minutes',\n 'month',\n 'months',\n 'seconds',\n 'week',\n 'weeks',\n 'year',\n 'years',\n]\n","module.exports = [\n 'all hallows eve',\n 'all saints day',\n 'all sts day',\n 'april fools',\n 'armistice day',\n 'australia day',\n 'bastille day',\n 'boxing day',\n 'canada day',\n 'christmas eve',\n 'christmas',\n 'cinco de mayo',\n 'day of the dead',\n 'dia de muertos',\n 'dieciseis de septiembre',\n 'emancipation day',\n 'grito de dolores',\n 'groundhog day',\n 'halloween',\n 'harvey milk day',\n 'inauguration day',\n 'independence day',\n 'independents day',\n 'juneteenth',\n 'labour day',\n 'national freedom day',\n 'national nurses day',\n 'new years eve',\n 'new years',\n 'purple heart day',\n 'rememberance day',\n 'rosa parks day',\n 'saint andrews day',\n 'saint patricks day',\n 'saint stephens day',\n 'saint valentines day',\n 'st andrews day',\n 'st patricks day',\n 'st stephens day',\n 'st valentines day ',\n 'valentines day',\n 'valentines',\n 'veterans day',\n 'victoria day',\n 'womens equality day',\n 'xmas',\n // Fixed religious and cultural holidays\n // Catholic + Christian\n 'epiphany',\n 'orthodox christmas day',\n 'orthodox new year',\n 'assumption of mary',\n 'all souls day',\n 'feast of the immaculate conception',\n 'feast of our lady of guadalupe',\n\n // Kwanzaa\n 'kwanzaa',\n // Pagan / metal 🤘\n 'imbolc',\n 'beltaine',\n 'lughnassadh',\n 'samhain',\n 'martin luther king day',\n 'mlk day',\n 'presidents day',\n 'mardi gras',\n 'tax day',\n 'commonwealth day',\n 'mothers day',\n 'memorial day',\n 'fathers day',\n 'columbus day',\n 'indigenous peoples day',\n 'canadian thanksgiving',\n 'election day',\n 'thanksgiving',\n 't-day',\n 'turkey day',\n 'black friday',\n 'cyber monday',\n // Astronomical religious and cultural holidays\n 'ash wednesday',\n 'palm sunday',\n 'maundy thursday',\n 'good friday',\n 'holy saturday',\n 'easter',\n 'easter sunday',\n 'easter monday',\n 'orthodox good friday',\n 'orthodox holy saturday',\n 'orthodox easter',\n 'orthodox easter monday',\n 'ascension day',\n 'pentecost',\n 'whitsunday',\n 'whit sunday',\n 'whit monday',\n 'trinity sunday',\n 'corpus christi',\n 'advent',\n // Jewish\n 'tu bishvat',\n 'tu bshevat',\n 'purim',\n 'passover',\n 'yom hashoah',\n 'lag baomer',\n 'shavuot',\n 'tisha bav',\n 'rosh hashana',\n 'yom kippur',\n 'sukkot',\n 'shmini atzeret',\n 'simchat torah',\n 'chanukah',\n 'hanukkah',\n // Muslim\n 'isra and miraj',\n 'lailat al-qadr',\n 'eid al-fitr',\n 'id al-Fitr',\n 'eid ul-Fitr',\n 'ramadan',\n 'eid al-adha',\n 'muharram',\n 'the prophets birthday',\n 'ostara',\n 'march equinox',\n 'vernal equinox',\n 'litha',\n 'june solistice',\n 'summer solistice',\n 'mabon',\n 'september equinox',\n 'fall equinox',\n 'autumnal equinox',\n 'yule',\n 'december solstice',\n 'winter solstice',\n // Additional important holidays\n 'chinese new year',\n 'diwali',\n]\n","module.exports = [\n 'noon',\n 'midnight',\n 'now',\n 'morning',\n 'tonight',\n 'evening',\n 'afternoon',\n 'night',\n 'breakfast time',\n 'lunchtime',\n 'dinnertime',\n 'ago',\n 'sometime',\n 'eod',\n 'oclock',\n 'oclock',\n 'all day',\n 'at night',\n]\n","let lex = {}\nconst timezones = require('../_timezones')\n\nconst data = [\n [require('./dates'), '#Date'],\n [require('./durations'), '#Duration'],\n [require('./holidays'), '#Holiday'],\n [require('./times'), '#Time'],\n [Object.keys(timezones), '#Timezone'],\n]\ndata.forEach(a => {\n for (let i = 0; i < a[0].length; i++) {\n lex[a[0][i]] = a[1]\n }\n})\n\nmodule.exports = lex\n","const normalize = function(doc) {\n doc = doc.clone()\n\n if (!doc.numbers) {\n console.warn(\"Compromise: compromise-dates cannot find plugin dependency 'compromise-number'\")\n } else {\n // convert 'two' to 2\n let num = doc.numbers()\n num.toNumber()\n num.toCardinal()\n }\n // remove adverbs\n doc.adverbs().remove()\n return doc\n}\nmodule.exports = normalize\n","const knownUnits = {\n second: true,\n minute: true,\n hour: true,\n day: true,\n week: true,\n month: true,\n season: true,\n quarter: true,\n year: true,\n}\n\n//turn '5 weeks before' to {weeks:5}\nconst parseShift = function(doc) {\n let result = {}\n let m = doc.match('#DateShift+')\n if (m.found === false) {\n return result\n }\n m.match('#Cardinal #Duration').forEach(ts => {\n let num = ts.match('#Cardinal').text('normal')\n num = parseFloat(num)\n if (num && typeof num === 'number') {\n let unit = ts.match('#Duration').text('normal')\n unit = unit.replace(/s$/, '')\n if (unit && knownUnits.hasOwnProperty(unit)) {\n result[unit] = num\n }\n }\n })\n //is it 2 weeks before? → -2\n if (m.has('before$') === true) {\n Object.keys(result).forEach(k => (result[k] *= -1))\n }\n // finally, remove it from our text\n doc.remove('#DateShift')\n return result\n}\nmodule.exports = parseShift\n","const spacetime = require('spacetime')\n//hmmm: 'june 5th between 9 and 10am'\n\nconst halfPast = function(m, s) {\n let hour = m.match('#Cardinal$').text('reduced')\n\n let term = m.match('(half|quarter|25|15|10|5)')\n let mins = term.text('reduced')\n if (term.has('half')) {\n mins = '30'\n }\n if (term.has('quarter')) {\n mins = '15'\n }\n let behind = m.has('to')\n // apply it\n s = s.hour(hour)\n s = s.startOf('hour')\n if (behind) {\n s = s.subtract(mins, 'minutes')\n } else {\n s = s.add(mins, 'minutes')\n }\n return s\n}\n\nconst parseTime = function(doc, context) {\n let time = doc.match('(at|by|for|before)? #Time+')\n if (time.found) {\n doc.remove(time)\n }\n // get the main part of the time\n time = time.not('(at|by|for|before|sharp)')\n time = time.not('on the dot')\n let s = spacetime.now(context.timezone)\n let now = s.clone()\n\n // '5 oclock'\n let m = time.match('^#Cardinal oclock (am|pm)?')\n if (m.found) {\n m = m.not('oclock')\n s = s.hour(m.text('reduced'))\n if (s.isValid() && !s.isEqual(now)) {\n return s.time()\n }\n }\n\n // 'quarter to two'\n m = time.match('(half|quarter|25|15|10|5) (past|after|to) #Cardinal')\n if (m.found) {\n s = halfPast(m, s)\n if (s.isValid() && !s.isEqual(now)) {\n return s.time()\n }\n }\n // parse random a time like '4:54pm'\n let str = time.text('reduced')\n s = s.time(str)\n if (s.isValid() && !s.isEqual(now)) {\n return s.time()\n }\n return null\n}\nmodule.exports = parseTime\n","// interpret 'this halloween' or 'next june'\nconst parseRelative = function(doc) {\n let rel = null\n if (doc.has('^this? (next|upcoming)')) {\n rel = 'next'\n }\n if (doc.has('^this? (last|previous)')) {\n rel = 'last'\n }\n if (doc.has('^(this|current)')) {\n rel = 'this'\n }\n // finally, remove it from our text\n doc.remove('^(this|current|next|upcoming|last|previous)')\n return rel\n}\nmodule.exports = parseRelative\n","const informal = require('../../data/_timezones')\n\nconst isOffset = /(\\-?[0-9]+)h(rs)?/i\nconst isNumber = /(\\-?[0-9]+)/\nconst utcOffset = /utc([\\-+]?[0-9]+)/i\nconst gmtOffset = /gmt([\\-+]?[0-9]+)/i\n\nconst toIana = function(num) {\n num = Number(num)\n if (num > -13 && num < 13) {\n num = num * -1 //it's opposite!\n num = (num > 0 ? '+' : '') + num //add plus sign\n return 'Etc/GMT' + num\n }\n return null\n}\n\nconst parseOffset = function(tz) {\n // '+5hrs'\n let m = tz.match(isOffset)\n if (m !== null) {\n return toIana(m[1])\n }\n // 'utc+5'\n m = tz.match(utcOffset)\n if (m !== null) {\n return toIana(m[1])\n }\n // 'GMT-5' (not opposite)\n m = tz.match(gmtOffset)\n if (m !== null) {\n let num = Number(m[1]) * -1\n return toIana(num)\n }\n // '+5'\n m = tz.match(isNumber)\n if (m !== null) {\n return toIana(m[1])\n }\n return null\n}\n\nconst parseTimezone = function(doc) {\n let m = doc.match('#Timezone+')\n //remove prepositions\n m = m.remove('(in|for|by|near|at)')\n let str = m.text('reduced')\n\n // remove it from our doc, either way\n doc.remove('#Timezone+')\n\n // check our list of informal tz names\n if (informal.hasOwnProperty(str)) {\n return informal[str]\n }\n let tz = parseOffset(str)\n if (tz) {\n return tz\n }\n\n return null\n}\nmodule.exports = parseTimezone\n","const spacetime = require('spacetime')\n\nclass Unit {\n constructor(input, unit, context) {\n this.unit = unit || 'day'\n context = context || {}\n let today = {}\n if (context.today) {\n today = {\n date: context.today.date(),\n month: context.today.month(),\n year: context.today.year(),\n }\n }\n // set it to the beginning of the given unit\n let d = spacetime(input, context.timezone, { today: today })\n\n // set to beginning\n if (d.isValid()) {\n d = d.startOf(this.unit)\n }\n Object.defineProperty(this, 'd', {\n enumerable: false,\n writable: true,\n value: d,\n })\n Object.defineProperty(this, 'context', {\n enumerable: false,\n writable: true,\n value: context,\n })\n }\n // make a new one\n clone() {\n let d = new Unit(this.d, this.unit, this.context)\n return d\n }\n log() {\n console.log('--')\n this.d.log()\n console.log('\\n')\n return this\n }\n applyShift(obj = {}) {\n Object.keys(obj).forEach((k) => {\n this.d = this.d.add(obj[k], k)\n })\n return this\n }\n applyTime(str) {\n if (str) {\n this.d = this.d.time(str)\n } else {\n this.d = this.d.startOf('day') //zero-out time\n }\n return this\n }\n format(fmt) {\n return this.d.format(fmt)\n }\n start() {\n this.d = this.d.startOf(this.unit)\n return this\n }\n end() {\n this.d = this.d.endOf(this.unit)\n return this\n }\n // 'before 2019'\n before() {\n this.d = spacetime.now(this.context.timezone, { today: this.context.today }) // ???\n return this\n }\n // 'after 2019'\n after() {\n this.d = this.d.add(1, this.unit)\n this.d = this.d.startOf(this.unit)\n return this\n }\n // tricky: 'next june' 'next tuesday'\n next() {\n this.d = this.d.add(1, this.unit)\n this.d = this.d.startOf(this.unit)\n return this\n }\n // tricky: 'last june' 'last tuesday'\n last() {\n this.d = this.d.minus(1, this.unit)\n this.d = this.d.startOf(this.unit)\n return this\n }\n}\nmodule.exports = Unit\n","const spacetime = require('spacetime')\nconst Unit = require('./Unit')\n\nclass Day extends Unit {\n constructor(input, unit, context) {\n super(input, unit, context)\n this.unit = 'day'\n }\n}\nclass Month extends Unit {\n constructor(input, unit, context) {\n super(input, unit, context)\n this.unit = 'month'\n }\n}\nclass Quarter extends Unit {\n constructor(input, unit, context) {\n super(input, unit, context)\n this.unit = 'quarter'\n }\n}\nclass Year extends Unit {\n constructor(input, unit, context) {\n super(input, unit, context)\n this.unit = 'year'\n }\n}\nclass WeekDay extends Unit {\n constructor(input, unit, context) {\n super(input, unit, context)\n this.unit = 'week'\n this.d = this.d.day(input)\n this.weekDay = this.d.dayName()\n //assume a wednesday in the future\n if (this.d.date() < spacetime.now(context.timezone).date()) {\n this.d = this.d.add(7, 'days')\n }\n }\n next() {\n this.d = this.d.add(7, 'days')\n this.d = this.d.day(this.weekDay)\n return this\n }\n last() {\n this.d = this.d.minus(7, 'days')\n this.d = this.d.day(this.weekDay)\n return this\n }\n}\n// like 'feb 2'\nclass CalendarDate extends Unit {\n constructor(input, unit, context) {\n super(input, unit, context)\n this.unit = 'day'\n }\n next() {\n this.d = this.d.add(1, 'year')\n return this\n }\n last() {\n this.d = this.d.minus(1, 'year')\n return this\n }\n}\n\nmodule.exports = {\n Unit: Unit,\n Day: Day,\n Month: Month,\n Quarter: Quarter,\n Year: Year,\n WeekDay: WeekDay,\n CalendarDate: CalendarDate,\n}\n","const { Unit } = require('../_units')\n\nconst onlySection = function(doc, context, section) {\n let d = null\n if (doc.found === false) {\n // do we have just a time?\n if (section.time !== null) {\n d = new Unit(context.today, null, context) // choose today\n }\n //do we just have a shift?\n if (Object.keys(section.shift).length > 0) {\n d = new Unit(context.today, null, context) // choose today\n }\n }\n return d\n}\nmodule.exports = onlySection\n","const units = require('../_units')\nconst mapping = {\n week: units.Week,\n month: units.Month,\n quarter: units.Quarter,\n year: units.Year,\n season: units.Season,\n}\n\n// when a unit of time is spoken of as 'this month' - instead of 'february'\nconst namedUnit = function(doc, context) {\n //this month, last quarter, next year\n let m = doc.match('(weekday|week|month|quarter|season|year)')\n if (m.found === true) {\n let str = m.lastTerm().text('reduced')\n if (mapping.hasOwnProperty(str)) {\n let Model = mapping[str]\n if (!Model) {\n return null\n }\n let unit = new Model(null, str, context)\n return unit\n }\n }\n\n //try this version - 'next friday, last thursday'\n m = doc.match('(monday|tuesday|wednesday|thursday|friday|saturday|sunday)')\n if (m.found === true) {\n let str = m.lastTerm().text('reduced')\n let unit = new units.WeekDay(str, null, context)\n return unit\n }\n return null\n}\nmodule.exports = namedUnit\n","(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('spacetime')) :\n typeof define === 'function' && define.amd ? define(['spacetime'], factory) :\n (global = global || self, global.spacetimeHoliday = factory(global.spacetime));\n}(this, function (spacetime) { 'use strict';\n\n spacetime = spacetime && spacetime.hasOwnProperty('default') ? spacetime['default'] : spacetime;\n\n //yep,\n var jan = 'january';\n var feb = 'february';\n var mar = 'march';\n var apr = 'april';\n var may = 'may';\n var jun = 'june';\n var jul = 'july';\n var aug = 'august';\n var sep = 'september';\n var oct = 'october';\n var nov = 'november';\n var dec = 'december';\n var fixedHolidays = {\n 'new years eve': [dec, 31],\n 'new years': [jan, 1],\n 'new years day': [jan, 1],\n 'inauguration day': [jan, 20],\n 'australia day': [jan, 26],\n 'national freedom day': [feb, 1],\n 'groundhog day': [feb, 2],\n 'rosa parks day': [feb, 4],\n 'valentines day': [feb, 14],\n 'saint valentines day': [feb, 14],\n 'st valentines day ': [feb, 14],\n 'saint patricks day': [mar, 17],\n 'st patricks day': [mar, 17],\n 'april fools': [apr, 1],\n 'april fools day': [apr, 1],\n 'emancipation day': [apr, 16],\n 'tax day': [apr, 15],\n //US\n 'labour day': [may, 1],\n 'cinco de mayo': [may, 5],\n 'national nurses day': [may, 6],\n 'harvey milk day': [may, 22],\n 'victoria day': [may, 24],\n juneteenth: [jun, 19],\n 'canada day': [jul, 1],\n 'independence day': [jul, 4],\n 'independents day': [jul, 4],\n 'bastille day': [jul, 14],\n 'purple heart day': [aug, 7],\n 'womens equality day': [aug, 26],\n '16 de septiembre': [sep, 16],\n 'dieciseis de septiembre': [sep, 16],\n 'grito de dolores': [sep, 16],\n halloween: [oct, 31],\n 'all hallows eve': [oct, 31],\n 'day of the dead': [oct, 31],\n // Ranged holiday [nov, 2],\n 'dia de muertos': [oct, 31],\n // Ranged holiday [nov, 2],\n 'veterans day': [nov, 11],\n 'st andrews day': [nov, 30],\n 'saint andrews day': [nov, 30],\n 'all saints day': [nov, 1],\n 'all sts day': [nov, 1],\n 'armistice day': [nov, 11],\n 'rememberance day': [nov, 11],\n 'christmas eve': [dec, 24],\n christmas: [dec, 25],\n xmas: [dec, 25],\n 'boxing day': [dec, 26],\n 'st stephens day': [dec, 26],\n 'saint stephens day': [dec, 26],\n // Fixed religious and cultural holidays\n // Catholic + Christian\n epiphany: [jan, 6],\n 'orthodox christmas day': [jan, 7],\n 'orthodox new year': [jan, 14],\n 'assumption of mary': [aug, 15],\n 'all souls day': [nov, 2],\n 'feast of the immaculate conception': [dec, 8],\n 'feast of our lady of guadalupe': [dec, 12],\n // Kwanzaa\n kwanzaa: [dec, 26],\n // Ranged holiday [jan, 1],\n // Pagan / metal 🤘\n imbolc: [feb, 2],\n beltaine: [may, 1],\n lughnassadh: [aug, 1],\n samhain: [oct, 31]\n };\n\n var fixedDates = function fixedDates(str, normal, year) {\n if (fixedHolidays.hasOwnProperty(str) || fixedHolidays.hasOwnProperty(normal)) {\n var arr = fixedHolidays[str] || fixedHolidays[normal] || [];\n var s = spacetime.now();\n s = s.year(year);\n s = s.startOf('year');\n s = s.month(arr[0]);\n s = s.date(arr[1]);\n\n if (s.isValid()) {\n return s;\n }\n }\n\n return null;\n };\n\n var _01FixedDates = fixedDates;\n\n //these are holidays on the 'nth weekday of month'\n var jan$1 = 'january';\n var feb$1 = 'february';\n var mar$1 = 'march'; // const apr = 'april'\n\n var may$1 = 'may';\n var jun$1 = 'june'; // const jul = 'july'\n // const aug = 'august'\n\n var sep$1 = 'september';\n var oct$1 = 'october';\n var nov$1 = 'november'; // const dec = 'december'\n\n var mon = 'monday'; // const tues = 'tuesday'\n // const wed = 'wednesday'\n\n var thurs = 'thursday';\n var fri = 'friday'; // const sat = 'saturday'\n\n var sun = 'sunday';\n var holidays = {\n 'martin luther king day': [3, mon, jan$1],\n //[third monday in january],\n 'presidents day': [3, mon, feb$1],\n //[third monday in february],\n 'commonwealth day': [2, mon, mar$1],\n //[second monday in march],\n 'mothers day': [2, sun, may$1],\n //[second Sunday in May],\n 'fathers day': [3, sun, jun$1],\n //[third Sunday in June],\n 'labor day': [1, mon, sep$1],\n //[first monday in september],\n 'columbus day': [2, mon, oct$1],\n //[second monday in october],\n 'canadian thanksgiving': [2, mon, oct$1],\n //[second monday in october],\n thanksgiving: [4, thurs, nov$1],\n // [fourth Thursday in November],\n 'black friday': [4, fri, nov$1] //[fourth friday in november],\n // 'memorial day': [may], //[last monday in may],\n // 'us election': [nov], // [Tuesday following the first Monday in November],\n // 'cyber monday': [nov]\n // 'advent': [] // fourth Sunday before Christmas\n\n }; // add aliases\n\n holidays['turday day'] = holidays.thanksgiving;\n holidays['indigenous peoples day'] = holidays['columbus day'];\n holidays['mlk day'] = holidays['martin luther king day'];\n var calendarHolidays = holidays;\n\n var fixedDates$1 = function fixedDates(str, normal, year) {\n if (calendarHolidays.hasOwnProperty(str) || calendarHolidays.hasOwnProperty(normal)) {\n var arr = calendarHolidays[str] || calendarHolidays[normal] || [];\n var s = spacetime.now();\n s = s.year(year); // [3rd, 'monday', 'january']\n\n s = s.month(arr[2]);\n s = s.startOf('month'); // make it january\n\n var month = s.month(); // make it the 1st monday\n\n s = s.day(arr[1]);\n\n if (s.month() !== month) {\n s = s.add(1, 'week');\n } // make it nth monday\n\n\n if (arr[0] > 1) {\n s = s.add(arr[0] - 1, 'week');\n }\n\n if (s.isValid()) {\n return s;\n }\n }\n\n return null;\n };\n\n var _02NthWeekday = fixedDates$1;\n\n // https://www.timeanddate.com/calendar/determining-easter-date.html\n var dates = {\n easter: 0,\n 'ash wednesday': -46,\n // (46 days before easter)\n 'palm sunday': 7,\n // (1 week before easter)\n 'maundy thursday': -3,\n // (3 days before easter)\n 'good friday': -2,\n // (2 days before easter)\n 'holy saturday': -1,\n // (1 days before easter)\n 'easter saturday': -1,\n // (1 day before easter)\n 'easter monday': 1,\n // (1 day after easter)\n 'ascension day': 39,\n // (39 days after easter)\n 'whit sunday': 49,\n // / pentecost (49 days after easter)\n 'whit monday': 50,\n // (50 days after easter)\n 'trinity sunday': 65,\n // (56 days after easter)\n 'corpus christi': 60,\n // (60 days after easter)\n 'mardi gras': -47 //(47 days before easter)\n\n };\n dates['easter sunday'] = dates.easter;\n dates['pentecost'] = dates['whit sunday'];\n dates['whitsun'] = dates['whit sunday'];\n var easterHolidays = dates;\n\n // by John Dyer\n // based on the algorithm by Oudin (1940) from http://www.tondering.dk/claus/cal/easter.php\n var calcEaster = function calcEaster(year) {\n var f = Math.floor,\n // Golden Number - 1\n G = year % 19,\n C = f(year / 100),\n // related to Epact\n H = (C - f(C / 4) - f((8 * C + 13) / 25) + 19 * G + 15) % 30,\n // number of days from 21 March to the Paschal full moon\n I = H - f(H / 28) * (1 - f(29 / (H + 1)) * f((21 - G) / 11)),\n // weekday for the Paschal full moon\n J = (year + f(year / 4) + I + 2 - C + f(C / 4)) % 7,\n // number of days from 21 March to the Sunday on or before the Paschal full moon\n L = I - J,\n month = 3 + f((L + 40) / 44),\n date = L + 28 - 31 * f(month / 4);\n month = month === 4 ? 'April' : 'March';\n return month + ' ' + date;\n };\n\n var calcEaster_1 = calcEaster;\n\n var easterDates = function easterDates(str, normal, year) {\n if (easterHolidays.hasOwnProperty(str) || easterHolidays.hasOwnProperty(normal)) {\n var days = easterHolidays[str] || easterHolidays[normal] || [];\n var date = calcEaster_1(year);\n\n if (!date) {\n return null; //no easter for this year\n }\n\n var e = spacetime(date);\n e = e.year(year);\n var s = e.add(days, 'day');\n\n if (s.isValid()) {\n return s;\n }\n }\n\n return null;\n };\n\n var _03EasterDates = easterDates;\n\n // http://www.astropixels.com/ephemeris/soleq2001.html\n // years 2000-2100\n var exceptions = {\n spring: [2003, 2007, 2044, 2048, 2052, 2056, 2060, 2064, 2068, 2072, 2076, 2077, 2080, 2081, 2084, 2085, 2088, 2089, 2092, 2093, 2096, 2097],\n summer: [2021, 2016, 2020, 2024, 2028, 2032, 2036, 2040, 2041, 2044, 2045, 2048, 2049, 2052, 2053, 2056, 2057, 2060, 2061, 2064, 2065, 2068, 2069, 2070, 2072, 2073, 2074, 2076, 2077, 2078, 2080, 2081, 2082, 2084, 2085, 2086, 2088, 2089, 2090, 2092, 2093, 2094, 2096, 2097, 2098, 2099],\n fall: [2002, 2003, 2004, 2006, 2007, 2010, 2011, 2014, 2015, 2018, 2019, 2022, 2023, 2026, 2027, 2031, 2035, 2039, 2043, 2047, 2051, 2055, 2059, 2092, 2096],\n winter: [2002, 2003, 2006, 2007, 2011, 2015, 2019, 2023, 2027, 2031, 2035, 2039, 2043, 2080, 2084, 2088, 2092, 2096]\n };\n var winter20th = [2080, 2084, 2088, 2092, 2096];\n\n var calcSeasons = function calcSeasons(year) {\n // most common defaults\n var res = {\n spring: 'March 20 ' + year,\n summer: 'June 21 ' + year,\n fall: 'Sept 22 ' + year,\n winter: 'Dec 21 ' + year\n };\n\n if (exceptions.spring.indexOf(year) !== -1) {\n res.spring = 'March 19 ' + year;\n }\n\n if (exceptions.summer.indexOf(year) !== -1) {\n res.summer = 'June 20 ' + year;\n }\n\n if (exceptions.fall.indexOf(year) !== -1) {\n res.fall = 'Sept 21 ' + year;\n } // winter can be 20th, 21st, or 22nd\n\n\n if (exceptions.winter.indexOf(year) !== -1) {\n res.winter = 'Dec 22 ' + year;\n }\n\n if (winter20th.indexOf(year) !== -1) {\n res.winter = 'Dec 20 ' + year;\n }\n\n return res;\n };\n\n var seasons = calcSeasons;\n\n // these are properly calculated in ./lib/seasons\n var dates$1 = {\n 'spring equinox': 'spring',\n 'summer solistice': 'summer',\n 'fall equinox': 'fall',\n 'winter solstice': 'winter'\n }; // aliases\n\n dates$1['march equinox'] = dates$1['spring equinox'];\n dates$1['vernal equinox'] = dates$1['spring equinox'];\n dates$1['ostara'] = dates$1['spring equinox'];\n dates$1['june solstice'] = dates$1['summer solistice'];\n dates$1['litha'] = dates$1['summer solistice'];\n dates$1['autumn equinox'] = dates$1['fall equinox'];\n dates$1['autumnal equinox'] = dates$1['fall equinox'];\n dates$1['september equinox'] = dates$1['fall equinox'];\n dates$1['sept equinox'] = dates$1['fall equinox'];\n dates$1['mabon'] = dates$1['fall equinox'];\n dates$1['december solstice'] = dates$1['winter solistice'];\n dates$1['dec solstice'] = dates$1['winter solistice'];\n dates$1['yule'] = dates$1['winter solistice'];\n var astroHolidays = dates$1;\n\n var astroDates = function astroDates(str, normal, year) {\n if (astroHolidays.hasOwnProperty(str) || astroHolidays.hasOwnProperty(normal)) {\n var season = astroHolidays[str] || astroHolidays[normal];\n var seasons$1 = seasons(year);\n\n if (!season || !seasons$1 || !seasons$1[season]) {\n return null; // couldn't figure it out\n }\n\n var s = spacetime(seasons$1[season]);\n\n if (s.isValid()) {\n return s;\n }\n }\n\n return null;\n };\n\n var _04Astronomical = astroDates;\n\n var dates$2 = {\n // Muslim holidays\n 'isra and miraj': 'april 13',\n 'lailat al-qadr': 'june 10',\n 'eid al-fitr': 'june 15',\n 'id al-Fitr': 'june 15',\n 'eid ul-Fitr': 'june 15',\n ramadan: 'may 16',\n // Range holiday\n 'eid al-adha': 'sep 22',\n muharram: 'sep 12',\n 'prophets birthday': 'nov 21'\n };\n var lunarHolidays = dates$2;\n\n var dayDiff = -10.64;\n\n var lunarDates = function lunarDates(str, normal, year) {\n if (lunarHolidays.hasOwnProperty(str) || lunarHolidays.hasOwnProperty(normal)) {\n var date = lunarHolidays[str] || lunarHolidays[normal] || [];\n\n if (!date) {\n return null;\n } // start at 2018\n\n\n var s = spacetime(date + ' 2018');\n var diff = year - 2018;\n var toAdd = diff * dayDiff;\n s = s.add(toAdd, 'day');\n s = s.startOf('day'); // now set the correct year\n\n s = s.year(year);\n\n if (s.isValid()) {\n return s;\n }\n }\n\n return null;\n };\n\n var _05LunarDates = lunarDates;\n\n var nowYear = spacetime.now().year();\n\n var spacetimeHoliday = function spacetimeHoliday(str, year) {\n year = year || nowYear;\n str = str || '';\n str = String(str);\n str = str.trim().toLowerCase();\n str = str.replace(/'s/, 's'); // 'mother's day'\n\n var normal = str.replace(/ day$/, '');\n normal = normal.replace(/^the /, '');\n normal = normal.replace(/^orthodox /, ''); //orthodox good friday\n // try easier, unmoving holidays\n\n var s = _01FixedDates(str, normal, year);\n\n if (s !== null) {\n return s;\n } // try 'nth monday' holidays\n\n\n s = _02NthWeekday(str, normal, year);\n\n if (s !== null) {\n return s;\n } // easter-based holidays\n\n\n s = _03EasterDates(str, normal, year);\n\n if (s !== null) {\n return s;\n } // solar-based holidays\n\n\n s = _04Astronomical(str, normal, year);\n\n if (s !== null) {\n return s;\n } // mostly muslim holidays\n\n\n s = _05LunarDates(str, normal, year);\n\n if (s !== null) {\n return s;\n }\n\n return null;\n };\n\n var src = spacetimeHoliday;\n\n return src;\n\n}));\n//# sourceMappingURL=spacetime-holiday.js.map\n","const { CalendarDate } = require('../_units')\nconst spacetimeHoliday = require('spacetime-holiday')\n\nconst parseHoliday = function(doc, context) {\n let d = null\n let str = doc.match('#Holiday+').text('reduced')\n let year = 2020 //change me!\n let s = spacetimeHoliday(str, year)\n if (s !== null) {\n d = new CalendarDate(s, null, context)\n }\n return d\n}\nmodule.exports = parseHoliday\n","const { Unit, Day, CalendarDate } = require('../_units')\n\nconst knownWord = {\n today: (context) => new Day(context.today, null, context),\n yesterday: (context) => {\n new Day(context.today.minus(1, 'day'), null, context)\n },\n tomorrow: (context) => {\n new Day(context.today.plus(1, 'day'), null, context)\n },\n}\n\n// parse things like 'june 5th 2019'\n// most of this is done in spacetime\nconst parseExplicit = function (doc, context) {\n let impliedYear = context.today.year()\n // 'fifth of june'\n let m = doc.match('[#Value] of [#Month] [#Year?]')\n // 'june the fifth'\n if (!m.found) {\n m = doc.match('[#Month] the [#Value] [#Year?]')\n }\n if (m.found) {\n let obj = {\n month: m.groups('month').text(),\n date: m.groups('date').text(),\n year: m.groups('year').text() || impliedYear,\n }\n let d = new CalendarDate(obj, null, context)\n if (d.d.isValid() === true) {\n return d\n }\n }\n\n if (m.found) {\n let obj = {\n month: m.groups('month').text(),\n date: m.groups('date').text(),\n year: context.today.year(),\n }\n let d = new CalendarDate(obj, null, context)\n if (d.d.isValid() === true) {\n return d\n }\n }\n\n let str = doc.text('reduced')\n // today, yesterday, tomorrow\n if (knownWord.hasOwnProperty(str) === true) {\n let d = knownWord[str](context)\n return d\n }\n // punt it to spacetime, for the heavy-lifting\n let d = new Unit(str, null, context)\n // did we find a date?\n if (d.d.isValid() === false) {\n return null\n }\n return d\n}\nmodule.exports = parseExplicit\n","const section = {\n shift: require('./sections/01-shift'),\n time: require('./sections/02-time'),\n relative: require('./sections/03-relative'),\n timezone: require('./sections/04-timezone'),\n}\n\nconst steps = {\n implied: require('./steps/00-implied'),\n duration: require('./steps/01-duration'),\n holiday: require('./steps/02-holidays'),\n explicit: require('./steps/03-explicit'),\n}\n\nconst parseDate = function (doc, context) {\n //parse-out any sections\n let shift = section.shift(doc)\n let tz = section.timezone(doc)\n let time = section.time(doc, context)\n let rel = section.relative(doc)\n //set our new timezone\n if (tz) {\n context = Object.assign({}, context, { timezone: tz })\n let iso = context.today.format('iso-short')\n context.today = context.today.goto(context.timezone).set(iso)\n }\n let d = null\n\n //'in two days'\n d = d || steps.implied(doc, context, { shift, time, rel })\n // 'this month'\n d = d || steps.duration(doc, context)\n // 'this haloween'\n d = d || steps.holiday(doc, context)\n // 'this june 2nd'\n d = d || steps.explicit(doc, context)\n if (!d) {\n return null\n }\n\n // // apply relative\n if (rel === 'last') {\n d.last()\n }\n if (rel === 'next') {\n d.next()\n }\n // apply shift\n if (shift) {\n d.applyShift(shift)\n }\n\n // apply time\n d.applyTime(time)\n\n return d\n}\nmodule.exports = parseDate\n","const parseDate = require('../03-parseDate')\nconst Unit = require('../03-parseDate/Unit')\n\nconst punt = function (unit, context) {\n unit = unit.applyShift(context.casual_duration)\n return unit\n}\n\n//\nconst logic = function (doc, context) {\n // two explicit dates - 'between friday and sunday'\n let m = doc.match('between [*] and [*]')\n if (m.found) {\n let start = m.groups('start')\n start = parseDate(start, context)\n let end = m.groups('end')\n end = parseDate(end, context)\n if (start) {\n return {\n start: start,\n end: end,\n }\n }\n }\n\n // two months, no year - 'june 5 to june 7'\n m = doc.match('[#Month #Value] to [#Month #Value] [#Year?]')\n if (m.found) {\n let res = m.groups()\n let start = res.from\n if (res.year) {\n start = start.concat(res.year)\n }\n start = parseDate(start, context)\n if (start) {\n let end = res.to\n if (res.year) {\n end = end.concat(res.year)\n }\n end = parseDate(end, context)\n return {\n start: start,\n end: end,\n }\n }\n }\n // one month, one year, first form - 'january 5 to 7 1998'\n m = doc.match('[#Month] [#Value] to [#Value] of? [#Year]')\n if (m.found) {\n let res = m.groups()\n let start = res.month.concat(res.from, res.year)\n start = parseDate(start, context)\n if (start) {\n let end = res.month.concat(res.to, res.year)\n end = parseDate(end, context)\n return {\n start: start,\n end: end,\n }\n }\n }\n // one month, one year, second form - '5 to 7 of january 1998'\n m = doc.match('[#Value] to [#Value of? #Month of? #Year]')\n if (m.found) {\n let to = m.groups('to')\n to = parseDate(to, context)\n if (to) {\n let fromDate = m.groups('to')\n let from = to.clone()\n from.d = from.d.date(fromDate.text('normal'))\n return {\n start: from,\n end: to,\n }\n }\n }\n // one month, no year - '5 to 7 of january'\n m = doc.match('[#Value] to [#Value of? #Month]')\n if (m.found) {\n let to = m.groups('to')\n to = parseDate(to, context)\n if (to) {\n let fromDate = m.groups('from')\n let from = to.clone()\n from.d = from.d.date(fromDate.text('normal'))\n return {\n start: from,\n end: to,\n }\n }\n }\n // one month, no year - 'january 5 to 7'\n m = doc.match('[#Month #Value] to [#Value]')\n if (m.found) {\n let from = m.groups('from')\n from = parseDate(from, context)\n if (from) {\n let toDate = m.groups('to')\n let to = from.clone()\n to.d = to.d.date(toDate.text('normal'))\n return {\n start: from,\n end: to,\n }\n }\n }\n // 'from A to B'\n m = doc.match('from? [*] (to|@hasHyphen|until|upto) [*]')\n if (m.found) {\n let from = m.groups('from')\n let to = m.groups('to')\n from = parseDate(from, context)\n to = parseDate(to, context)\n if (from && to) {\n return {\n start: from,\n end: to,\n }\n }\n }\n // 'before june'\n m = doc.match('^due (by|before|on|in)? [*]', 0)\n if (m.found) {\n let d = parseDate(m, context)\n if (d) {\n const today = new Unit(context.today, null, context)\n return {\n start: today,\n end: punt(d.clone(), context),\n }\n }\n }\n // 'after june'\n m = doc.match('^(after|following|from) [*]', 0)\n if (m.found) {\n let d = parseDate(m, context)\n if (d) {\n return {\n start: d,\n end: punt(d.clone(), context),\n }\n }\n }\n // 'in june'\n m = doc.match('^(on|during|in) [*]', 0)\n if (m.found) {\n let d = parseDate(m, context)\n if (d) {\n return {\n start: d,\n end: d.clone().end(),\n }\n }\n }\n //else, try whole thing\n let d = parseDate(doc, context)\n return {\n start: d,\n end: null,\n }\n}\nmodule.exports = logic\n","const spacetime = require('spacetime')\nconst normalize = require('./00-normalize')\nconst parseRanges = require('./01-parse-range')\n\nconst getDate = function (doc, context) {\n // validate context a bit\n context = context || {}\n\n context.timezone = context.timezone || 'ETC/UTC'\n context.today = spacetime(context.today || null, context.timezone)\n //turn 'five' into 5..\n doc = normalize(doc)\n //interpret 'between [A] and [B]'...\n return parseRanges(doc, context)\n}\nmodule.exports = getDate\n","let arr = [\n ['mon', 'monday'],\n ['tue', 'tuesday'],\n ['tues', 'tuesday'],\n ['wed', 'wednesday'],\n ['thu', 'thursday'],\n ['thurs', 'thursday'],\n ['fri', 'friday'],\n ['sat', 'saturday'],\n ['sun', 'sunday'],\n\n ['jan', 'january'],\n ['feb', 'february'],\n ['mar', 'march'],\n ['apr', 'april'],\n ['jun', 'june'],\n ['jul', 'july'],\n ['aug', 'august'],\n ['sep', 'september'],\n ['sept', 'september'],\n ['oct', 'october'],\n ['nov', 'november'],\n ['dec', 'december'],\n]\n\narr = arr.map(a => {\n return { short: a[0], long: a[1] }\n})\n\nmodule.exports = arr\n","const parse = require('./02-getDate')\nconst abbrevs = require('./data/_abbrevs')\n\nmodule.exports = {\n /** overload the original json with noun information */\n json: function (options) {\n let n = null\n if (typeof options === 'number') {\n n = options\n options = null\n }\n options = options || { terms: false }\n let res = []\n let format = options.format || 'iso'\n this.forEach((doc) => {\n let json = doc.json(options)[0]\n let obj = parse(doc, this.context)\n let start = obj.start ? obj.start.format(format) : null\n let end = obj.end ? obj.end.format(format) : null\n // set iso strings to json result\n json.date = {\n start: start,\n end: end,\n }\n // add duration\n if (start && end) {\n json.date.duration = obj.start.d.diff(obj.end.d)\n // we don't need these\n delete json.date.duration.milliseconds\n delete json.date.duration.seconds\n }\n res.push(json)\n })\n if (n !== null) {\n return res[n]\n }\n return res\n },\n\n /** render all dates according to a specific format */\n format: function (fmt) {\n this.forEach((doc) => {\n let obj = parse(doc, this.context)\n let str = ''\n if (obj.start) {\n str = obj.start.format(fmt)\n if (obj.end) {\n let end = obj.start.format(fmt)\n if (str !== end) {\n str += ' to ' + end\n }\n }\n doc.replaceWith(str, { keepTags: true, keepCase: false })\n }\n })\n return this\n },\n /** replace 'Fri' with 'Friday', etc*/\n toLongForm: function () {\n abbrevs.forEach((a) => {\n this.replace(a.short, a.long, true)\n })\n return this\n },\n /** replace 'Friday' with 'Fri', etc*/\n toShortForm: function () {\n abbrevs.forEach((a) => {\n this.replace(a.long, a.short, true)\n })\n return this\n },\n}\n","const tagger = require('./01-tag')\nconst tags = require('./data/_tags')\nconst words = require('./data/words')\nconst methods = require('./methods')\nconst spacetime = require('spacetime')\n\nconst addMethods = function (Doc, world) {\n // our new tags\n world.addTags(tags)\n // add info for the date plugin\n world.addWords(words)\n // run our tagger\n world.postProcess(tagger)\n\n /** */\n class Dates extends Doc {\n constructor(list, from, w) {\n super(list, from, w)\n this.context = {\n casual_duration: { weeks: 2 },\n }\n }\n }\n //add-in methods\n Object.assign(Dates.prototype, methods)\n\n Doc.prototype.dates = function (n) {\n let context = {}\n if (n && typeof n === 'object') {\n context = n\n n = null\n }\n let r = this.clauses()\n let dates = r.match('#Date+')\n if (typeof n === 'number') {\n dates = dates.get(n)\n }\n if (typeof n === 'number') {\n dates = dates.get(n)\n }\n let d = new Dates(dates.list, this, this.world)\n if (context.today) {\n context.today = spacetime(context.today, context.timezone)\n }\n d.context = context\n return d\n }\n}\n\nmodule.exports = addMethods\n"],"names":["preps","thisNext","sections","seasons","tagYear","m","reason","found","term","termList","num","parseInt","clean","tag","tagYearSafe","fixDates","doc","match","month","val","ifNo","duration","unTag","season","date","not","cardinal","v","time","here","values","has","dateTagger","sectionTagger","timeTagger","shiftTagger","fixUp","oops","d","knownDate","lastTerm","terms","methods","require$$0","require$$1","require$$2","require$$3","require$$4","require$$5","require$$6","tagDate","forEach","fn","FinancialQuarter","isA","Season","Year","notA","Duration","Holiday","Timezone","DateShift","createCommonjsModule","module","exports","getCjsExportFromNamespace","n","fns","isLeapYear","year","isDate","Object","prototype","toString","call","isNaN","valueOf","isArray","input","isObject","zeroPad","str","len","arguments","length","undefined","pad","Array","join","titleCase","toUpperCase","substr","ordinal","i","j","k","toCardinal","String","replace","normalize","toLowerCase","trim","getEpoch","tmp","getTime","epoch","beADate","s","clone","set","formatTimezone","offset","delimiter","absOffset","Math","abs","sign","concat","fns_1","fns_2","fns_3","fns_4","fns_5","fns_6","fns_7","fns_8","fns_9","fns_10","fns_11","fns_12","serialize","getMonth","getDate","getHours","shouldChange","start","end","defaultOffset","Date","bias","getTimezoneOffset","shift","current","summerTime","quickOffset","zones","timezones","obj","tz","console","warn","dst","jul","dec","hem","split","inSummer","quick","_build","_build$1","freeze","__proto__","_prefixes","data","all","keys","Number","names","before","name","unpack","fallbackTZ","safeIntl","Intl","DateTimeFormat","format","resolvedOptions","timezone","timeZone","guessTz","guessTz_1","isOffset","isNumber","utcOffset","gmtOffset","toIana","parseOffset","parseOffset_1","local","cities","reduce","h","city","lookupTz","hasOwnProperty","test","id","Error","find","o","millisecond","second","minute","hour","day","week","milliseconds","walk","unit","previous","startUnit","original","diff","halfStep","units","valid","walkTo","getFullYear","seconds","wants","old","silent","walk_1","shortMonths","longMonths","buildMapping","sep","_i","months","short","long","mapping","i18n","parseOffset$1","parseFloat","parseOffset_1$1","parseTime","arr","startOf","ampm","_h","parseTime_1","monthLengths","monthLengths_1","hasDate","max","hasDate_1","months$1","parseYear","today","strFmt","reg","parse","givenTz","options","british","_today","strParse","dates","now","tonight","tomorrow","add","yesterday","subtract","christmas","newYears","namedDates","minimumEpoch","defaults","handleArray","order","handleObject","assign","parseInput","res","shortDays","longDays","days","isoOffset","isNegative","floor","ceil","_offset","dayName","dayShort","dayNumber","dayOrdinal","dayPad","dateOrdinal","datePad","monthName","monthShort","monthNumber","monthOrdinal","monthPad","isoMonth","yearShort","isoYear","time24","hour24","hour12","hourPad","hour24Pad","minutePad","secondPad","quarter","era","json","numeric","numericUs","numericUk","mmDd","iso","h24","ms","isoShort","isoUtc","toISOString","nice","niceYear","niceDay","niceFull","aliases","mdy","dmy","ymd","printFormat","isValid","out","indexOf","_","fmt","format_1","G","GG","GGG","GGGG","y","yy","yyy","yyyy","yyyyy","Q","QQ","QQQ","QQQQ","M","MM","MMM","MMMM","w","ww","dd","D","dayOfYear","DD","DDD","E","EE","EEE","EEEE","EEEEE","e","ee","eee","eeee","eeeee","a","aa","aaa","aaaa","h12","hh","H","HH","mm","_s","ss","A","z","zz","zzz","zzzz","Z","ZZ","ZZZ","ZZZZ","addAlias","_char","to","toName","unixFmt","chars","quoteOn","push","txt","c","unixFmt_1","units$1","doUnit","endOf","percent","toFixed","progress","progress_1","nearest","prog","nearest_1","climb","b","isBefore","isAfter","diffOne","one","fastYear","years","msDiff","minutes","hours","weeks","waterfall","reverseDiff","main","reversed","diff$1","qualifiers","almost","over","getDiff","later","earlier","isSame","u","pluralize","value","slice","since","isNow","every","rounded","qualified","precise","englishValues","englishValue","nextUnit","nextValue","splice","since_1","north","south","quarters","units$2","quarterhour","_weekStart","q","hemisphere","decade","century","startOf_1","isDay","next","result","every_1","parseDst","epochShift","hasDst","Boolean","default_offset","change","back","summer","winter","isDST","timezone_1","units$3","input$1","hasDST","leapYear","last","goto","isAwake","isAsleep","log","logYear","_this","debug","from","fromNow","weekStart","inDST","round","each","methods_1","validate","confirm","want","methods$1","getMilliseconds","getSeconds","getMinutes","hourFloat","_minute","_hour","which","dayTime","times","morning","breakfast","noon","lunch","afternoon","evening","dinner","night","midnight","_01Time","methods$2","getDay","_02Date","clearMinutes","methods$3","sum","setDate","setFullYear","setHours","setMinutes","setMonth","toAdd","minus","thisOne","skipWeeks","_month","millenium","_03Year","methods$4","addMethods","Space","query","isLeapYear$1","getMonthLength","rollMonth","_years","rollDaysDown","rollDaysUp","_model","daysBack","order$1","keep","dstAwareUnits","keepDate","addMethods$1","SpaceTime","_sum","plus","print","addMethods$2","same","addMethods$3","isEqual","isBetween","isInclusive","startEpoch","endEpoch","compare","addMethods$4","defineProperty","get","toLocalDate","spacetime","whereIts","startHour","endHour","tzs","filter","whereIts_1","_version","main$1","setToday","extend","version","plugin","src","america","asia","europe","africa","aus","pac","informal","bst","ireland","cet","cest","eet","eest","trt","etc","utc","gmt","sast","acst","acdt","aest","aedt","awst","awdt","acwst","lhst","lhdt","msk","russian","cst","cdt","mst","mdt","ast","adt","est","edt","pst","pdt","ahst","ahdt","hst","nst","ndt","brt","brasília","brasilia","amt","east","easst","vet","pyt","pyst","cot","clst","cldt","uyt","ist","irst","irdt","iranian","pkt","ict","ct","almt","yakt","gst","uae","hkt","wib","wita","idt","israeli","krat","myt","sgt","kst","uzt","vlat","mvt","mut","mht","sst","chst","pgt","iana","formal","lex","numbers","toNumber","adverbs","remove","knownUnits","parseShift","ts","text","halfPast","mins","behind","context","parseRelative","rel","parseTimezone","Unit","enumerable","writable","Day","Month","Quarter","WeekDay","weekDay","CalendarDate","onlySection","section","Week","namedUnit","Model","define","feb","apr","nov","parseHoliday","spacetimeHoliday","knownWord","parseExplicit","impliedYear","groups","relative","steps","implied","holiday","explicit","require$$7","parseDate","applyShift","applyTime","punt","casual_duration","logic","fromDate","toDate","parseRanges","map","replaceWith","keepTags","keepCase","toLongForm","abbrevs","toShortForm","Doc","world","addTags","tags","addWords","words","postProcess","tagger","Dates","list","r","clauses"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAAA;EACA,IAAMA,KAAK,GAAG,oDAAd;;EACA,IAAMC,QAAQ,GAAG,mDAAjB;;EACA,IAAMC,QAAQ,GAAG,uDAAjB;;EACA,IAAMC,OAAO,GAAG,oCAAhB;EAGA;;EACA,IAAMC,OAAO,GAAG,SAAVA,OAAU,CAACC,CAAD,EAAIC,MAAJ,EAAe;EAC7B,MAAID,CAAC,CAACE,KAAF,KAAY,IAAhB,EAAsB;EACpB;EACD;;EACD,MAAIC,IAAI,GAAGH,CAAC,CAACI,QAAF,GAAa,CAAb,CAAX;;EACA,MAAID,IAAJ,EAAU;EACR,QAAIE,GAAG,GAAGC,QAAQ,CAACH,IAAI,CAACI,KAAN,EAAa,EAAb,CAAlB;;EACA,QAAIF,GAAG,IAAIA,GAAG,GAAG,IAAb,IAAqBA,GAAG,GAAG,IAA/B,EAAqC;EACnCL,MAAAA,CAAC,CAACQ,GAAF,CAAM,MAAN,EAAcP,MAAd;EACD;EACF;EACF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rB,KAAJ,CAAUle,KAAK,CAACme,IAAhB,EAAsB,IAAtB,EAA4B,KAAKR,KAAjC,CAAR;;EACA,QAAInD,OAAO,CAACjb,KAAZ,EAAmB;EACjBib,MAAAA,OAAO,CAACjb,KAAR,GAAgBgU,WAAS,CAACiH,OAAO,CAACjb,KAAT,EAAgBib,OAAO,CAACzf,QAAxB,CAAzB;EACD;;EACD3I,IAAAA,CAAC,CAACooB,OAAF,GAAYA,OAAZ;EACA,WAAOpoB,CAAP;EACD,GApBD;EAqBD,CAzCD;;WA2Cc,GAAGkf;;;;;;;;"} \ No newline at end of file +{"version":3,"file":"compromise-dates.js","sources":["../src/01-tag/00-basic.js","../src/01-tag/01-values.js","../src/01-tag/02-dates.js","../src/01-tag/03-sections.js","../src/01-tag/04-time.js","../src/01-tag/05-shifts.js","../src/01-tag/06-fixup.js","../src/01-tag/index.js","../src/data/_tags.js","../node_modules/spacetime/builds/spacetime.mjs","../src/data/_timezones.js","../src/data/words/dates.js","../src/data/words/durations.js","../src/data/words/holidays.js","../src/data/words/times.js","../src/data/words/index.js","../src/02-getDate/00-normalize.js","../src/03-parseDate/sections/01-shift.js","../src/03-parseDate/sections/02-time.js","../src/03-parseDate/sections/03-relative.js","../src/03-parseDate/sections/04-timezone.js","../src/03-parseDate/Unit.js","../src/03-parseDate/_units.js","../src/03-parseDate/steps/00-implied.js","../src/03-parseDate/steps/01-duration.js","../node_modules/spacetime-holiday/builds/spacetime-holiday.js","../src/03-parseDate/steps/02-holidays.js","../src/03-parseDate/steps/03-explicit.js","../src/03-parseDate/index.js","../src/02-getDate/01-parse-range.js","../src/02-getDate/index.js","../src/data/_abbrevs.js","../src/methods.js","../src/index.js"],"sourcesContent":["//ambiguous 'may' and 'march'\nconst preps = '(in|by|before|during|on|until|after|of|within|all)' //6\nconst thisNext = '(last|next|this|previous|current|upcoming|coming)' //2\nconst sections = '(start|end|middle|starting|ending|midpoint|beginning)' //2\nconst seasons = '(spring|summer|winter|fall|autumn)'\n\n//ensure a year is approximately typical for common years\n//please change in one thousand years\nconst tagYear = (m, reason) => {\n if (m.found !== true) {\n return\n }\n let term = m.termList()[0]\n if (term) {\n let num = parseInt(term.clean, 10)\n if (num && num > 1000 && num < 3000) {\n m.tag('Year', reason)\n }\n }\n}\n//same, but for less-confident values\nconst tagYearSafe = (m, reason) => {\n if (m.found !== true) {\n return\n }\n let term = m.termList()[0]\n if (term) {\n let num = parseInt(term.clean, 10)\n if (num && num > 1900 && num < 2030) {\n m.tag('Year', reason)\n }\n }\n}\n\nconst fixDates = function (doc) {\n doc.match('in the (night|evening|morning|afternoon|day|daytime)').tag('Time', 'in-the-night')\n doc.match('(#Value|#Time) (am|pm)').tag('Time', 'value-ampm')\n\n //months:\n let month = doc.if('#Month')\n if (month.found === true) {\n //June 5-7th\n month.match(`#Month #Date+`).tag('Date', 'correction-numberRange')\n //5th of March\n month.match('#Value of #Month').tag('Date', 'value-of-month')\n //5 March\n month.match('#Cardinal #Month').tag('Date', 'cardinal-month')\n //march 5 to 7\n month.match('#Month #Value to #Value').tag('Date', 'value-to-value')\n //march the 12th\n month.match('#Month the #Value').tag('Date', 'month-the-value')\n }\n\n //months:\n let val = doc.if('#Value')\n if (val.found === true) {\n //june 7\n val.match('(#WeekDay|#Month) #Value').ifNo('#Money').tag('Date', 'date-value')\n\n //7 june\n val.match('#Value (#WeekDay|#Month)').ifNo('#Money').tag('Date', 'value-date')\n\n //may twenty five\n val.match('#TextValue #TextValue').if('#Date').tag('#Date', 'textvalue-date')\n\n //eg 'year'\n let duration = val.if('#Duration')\n if (duration.found === true) {\n //for 4 months\n duration.match('for #Value #Duration').tag('Date', 'for-x-duration')\n //two days before\n duration.match('#Value #Duration #Conjunction').tag('Date', 'val-duration-conjunction')\n //for four days\n duration.match(`${preps}? #Value #Duration`).tag('Date', 'value-duration')\n //two years old\n duration.match('#Value #Duration old').unTag('Date', 'val-years-old')\n }\n }\n\n //seasons\n let season = doc.if(seasons)\n if (season.found === true) {\n season.match(`${preps}? ${thisNext} ${seasons}`).tag('Date', 'thisNext-season')\n season.match(`the? ${sections} of ${seasons}`).tag('Date', 'section-season')\n season.match(`${seasons} ${preps}? #Cardinal`).tag('Date', 'season-year')\n }\n\n //rest-dates\n let date = doc.if('#Date')\n if (date.found === true) {\n //june the 5th\n date.match('#Date the? #Ordinal').tag('Date', 'correction')\n //last month\n date.match(`${thisNext} #Date`).tag('Date', 'thisNext')\n //by 5 March\n date.match('due? (by|before|after|until) #Date').tag('Date', 'by')\n //next feb\n date.match('(last|next|this|previous|current|upcoming|coming|the) #Date').tag('Date', 'next-feb')\n //start of june\n date.match(`the? ${sections} of #Date`).tag('Date', 'section-of')\n //fifth week in 1998\n date.match('#Ordinal #Duration in #Date').tag('Date', 'duration-in')\n //early in june\n date.match('(early|late) (at|in)? the? #Date').tag('Time', 'early-evening')\n //tomorrow before 3\n date.match('#Date (by|before|after|at|@|about) #Cardinal').not('^#Date').tag('Time', 'date-before-Cardinal')\n //saturday am\n date.match('#Date [(am|pm)]', 0).unTag('Verb').unTag('Copula').tag('Time', 'date-am')\n //feb to june\n date.match('#Date (#Preposition|to) #Date').ifNo('#Duration').tag('Date', 'date-prep-date')\n }\n\n //year/cardinal tagging\n let cardinal = doc.if('#Cardinal')\n if (cardinal.found === true) {\n let v = cardinal.match(`#Date #Value [#Cardinal]`, 0)\n tagYear(v, 'date-value-year')\n //scoops up a bunch\n v = cardinal.match(`#Date+ [#Cardinal]`, 0)\n tagYear(v, 'date-year')\n //feb 8 2018\n v = cardinal.match(`#Month #Value [#Cardinal]`, 0)\n tagYear(v, 'month-value-year')\n //feb 8 to 10th 2018\n v = cardinal.match(`#Month #Value to #Value [#Cardinal]`, 0)\n tagYear(v, 'month-range-year')\n //in 1998\n v = cardinal.match(`(in|of|by|during|before|starting|ending|for|year) [#Cardinal]`, 0)\n tagYear(v, 'in-year')\n //q2 2009\n v = cardinal.match('(q1|q2|q3|q4) [#Cardinal]', 0)\n tagYear(v, 'in-year')\n //2nd quarter 2009\n v = cardinal.match('#Ordinal quarter [#Cardinal]', 0)\n tagYear(v, 'in-year')\n //in the year 1998\n v = cardinal.match('the year [#Cardinal]', 0)\n tagYear(v, 'in-year')\n //it was 1998\n v = cardinal.match('it (is|was) [#Cardinal]', 0)\n tagYearSafe(v, 'in-year')\n }\n\n let time = doc.if('#Time')\n if (time.found === true) {\n //by 6pm\n time.match('(by|before|after|at|@|about) #Time').tag('Time', 'preposition-time')\n //7 7pm\n time.match('#Cardinal #Time').not('#Year').tag('Time', 'value-time')\n //2pm est\n time.match('#Time [(eastern|pacific|central|mountain)]', 0).tag('Date', 'timezone')\n //6pm est\n time.match('#Time [(est|pst|gmt)]', 0).tag('Date', 'timezone abbr')\n }\n\n return doc\n}\nmodule.exports = fixDates\n","const here = 'date-values'\n//\nconst values = function (doc) {\n // a year ago\n doc.match('!once [a] #Duration', 0).replaceWith('1').tag('Cardinal', here)\n if (doc.has('#Value')) {\n //june 5 to 7th\n doc.match('#Month #Value to #Value of? #Year?').tag('Date', here)\n //5 to 7th june\n doc.match('#Value to #Value of? #Month #Year?').tag('Date', here)\n //third week of may\n doc.match('#Value #Duration of #Date').tag('Date', here)\n //two days after\n doc.match('#Value+ #Duration (after|before|into|later|afterwards|ago)?').tag('Date', here)\n //two days\n doc.match('#Value #Date').tag('Date', here)\n //june 5th\n doc.match('#Date #Value').tag('Date', here)\n //tuesday at 5\n doc.match('#Date #Preposition #Value').tag('Date', here)\n //tomorrow before 3\n doc.match('#Date (after|before|during|on|in) #Value').tag('Date', here)\n //a year and a half\n doc.match('#Value (year|month|week|day) and a half').tag('Date', here)\n //5 and a half years\n doc.match('#Value and a half (years|months|weeks|days)').tag('Date', here)\n //on the fifth\n doc.match('on the #Ordinal').tag('Date', here)\n }\n return doc\n}\nmodule.exports = values\n","const here = 'date-tagger'\n//\nconst dateTagger = function(doc) {\n\n doc.match('(spring|summer|winter|fall|autumn|springtime|wintertime|summertime)').match('#Noun').tag('Season', here)\n doc.match('(q1|q2|q3|q4)').tag('FinancialQuarter', here)\n doc.match('(this|next|last|current) quarter').tag('FinancialQuarter', here)\n doc.match('(this|next|last|current) season').tag('Season', here)\n\n if (doc.has('#Date')) {\n //friday to sunday\n doc.match('#Date #Preposition #Date').tag('Date', here);\n //once a day..\n doc.match('(once|twice) (a|an|each) #Date').tag('Date', here);\n //TODO:fixme\n doc.match('(by|until|on|in|at|during|over|every|each|due) the? #Date').tag('Date', here);\n //tuesday\n doc.match('#Date+').tag('Date', here);\n //by June\n doc.match('(by|until|on|in|at|during|over|every|each|due) the? #Date').tag('Date', here);\n //a year after..\n doc.match('a #Duration').tag('Date', here);\n //between x and y\n doc.match('(between|from) #Date').tag('Date', here);\n doc.match('(to|until|upto) #Date').tag('Date', here);\n doc.match('#Date and #Date').tag('Date', here);\n //during this june\n doc.match('(by|until|after|before|during|on|in|following) (next|this|last)? (#Date|#Date)').tag('Date', here);\n //day after next\n doc.match('the? #Date after next one?').tag('Date', here);\n //approximately...\n doc.match('(about|approx|approximately|around) #Date').tag('Date', here);\n }\n return doc\n}\nmodule.exports = dateTagger\n","const here = 'section-tagger'\n//\nconst sectionTagger = function(doc) {\n if (doc.has('#Date')) {\n // //next september\n doc.match('this? (last|next|past|this|previous|current|upcoming|coming|the) #Date').tag('Date', here);\n //starting this june\n doc.match('(starting|beginning|ending) #Date').tag('Date', here);\n //start of june\n doc.match('the? (start|end|middle|beginning) of (last|next|this|the) (#Date|#Date)').tag('Date', here);\n //this coming june\n doc.match('(the|this) #Date').tag('Date', here);\n }\n return doc\n}\nmodule.exports = sectionTagger\n","const here = 'time-tagger'\n\n//\nconst timeTagger = function (doc) {\n // quarter to seven (not march 5 to 7)\n if (doc.has('#Cardinal') && !doc.has('#Month')) {\n doc.match('(half|quarter|25|15|10|5) (past|after|to) #Cardinal').tag('Time', here)\n }\n //timezone\n if (doc.has('#Date')) {\n //eastern daylight time\n doc.match('#Noun (standard|daylight|central|mountain)? time').tag('Timezone', here)\n //utc+5\n doc.match('/^utc[+-][0-9]/').tag('Timezone', here)\n doc.match('/^gmt[+-][0-9]/').tag('Timezone', here)\n\n doc.match('(in|for|by|near|at) #Timezone').tag('Timezone', here)\n\n // https://raw.githubusercontent.com/davispuh/TimezoneParser/master/data/abbreviations.yml\n // let abbr =\n // '(acdt|acst|ace|dmt|ist|tse|addt|adt|aedt|aest|ahdt|ahst|akdt|akst|amt|nst|apt|awt|gmt|awdt|awst|bdst|bst|bdt|nwt|bmt|wet|bost|cddt|cdt|cet|cmt|cpt|cst|cwt|chst|gst|eat|eddt|edt|eest|eet|emt|ept|ewt|est|ffmt|fmt|hdt|hst|hkst|hkt|hmt|iddt|idt|jmt|imt|jdt|jst|kdt|kst|kmt|lst|mddt|mdst|msd|msk|mdt|mmt|mpt|pdt|pst|mst|mwt|nddt|ndt|npt|nzdt|nzmt|nzst|pddt|pkst|pkt|plmt|pmmt|pmt|ppmt|ppt|pwt|qmt|rmt|sast|sdmt|set|sjmt|smt|sst|tbmt|tmt|utc|wast|wemt|wib|wit|wita|wmt|yddt|ydt|ypt|ywt|yst)'\n // doc.match(abbr).tag('Timezone', here)\n }\n return doc\n}\nmodule.exports = timeTagger\n","const here = 'shift-tagger'\n//\nconst shiftTagger = function (doc) {\n if (doc.has('#Date')) {\n //'two days before'/ 'nine weeks frow now'\n doc.match('#Cardinal #Duration (before|after|ago|from)').tag('#DateShift', here)\n // in two weeks\n doc.match('in #Cardinal #Duration').tag('#DateShift', here)\n //two weeks and three days before\n doc.match('#Cardinal #Duration and? #DateShift').tag('#DateShift', here)\n doc.match('#DateShift and #Cardinal #Duration').tag('#DateShift', here)\n // doc.match('#Cardinal #Duration and? #DateShift').tag('#DateShift', here)\n }\n return doc\n}\nmodule.exports = shiftTagger\n","const here = 'fix-tagger'\n//\nconst fixUp = function (doc) {\n //fixups\n if (doc.has('#Date')) {\n //first day by monday\n let oops = doc.match('#Date+ by #Date+')\n if (oops.found && !oops.has('^due')) {\n oops.match('^#Date+').unTag('Date', 'by-monday')\n }\n\n let d = doc.match('#Date+')\n //'spa day'\n d.match('^day$').unTag('Date', 'spa-day')\n // tomorrow's meeting\n d.match('(in|of|by|for)? (#Possessive && #Date)').unTag('Date', 'tomorrows meeting')\n\n let knownDate = '(yesterday|today|tomorrow)'\n if (d.has(knownDate)) {\n //yesterday 7\n d.match(`${knownDate} [#Value]$`).unTag('Date', 'yesterday-7')\n //7 yesterday\n d.match(`^[#Value] ${knownDate}$`, 0).unTag('Date', '7 yesterday')\n //friday yesterday\n d.match(`#WeekDay+ ${knownDate}$`).unTag('Date').lastTerm().tag('Date', 'fri-yesterday')\n\n // yesterday yesterday\n // d.match(`${knownDate}+ ${knownDate}$`)\n // .unTag('Date')\n // .lastTerm()\n // .tag('Date', here)\n d.match(`(this|last|next) #Date ${knownDate}$`).unTag('Date').lastTerm().tag('Date', 'this month yesterday')\n }\n //tomorrow on 5\n d.match(`on #Cardinal$`).unTag('Date', here)\n //this tomorrow\n d.match(`this tomorrow`).terms(0).unTag('Date', 'this-tomorrow')\n //q2 2019\n d.match(`(q1|q2|q3|q4) #Year`).tag('Date', here)\n //5 tuesday\n // d.match(`^#Value #WeekDay`).terms(0).unTag('Date');\n //5 next week\n d.match(`^#Value (this|next|last)`).terms(0).unTag('Date', here)\n\n if (d.has('(last|this|next)')) {\n //this month 7\n d.match(`(last|this|next) #Duration #Value`).terms(2).unTag('Date', here)\n //7 this month\n d.match(`!#Month #Value (last|this|next) #Date`).terms(0).unTag('Date', here)\n }\n //january 5 5\n if (d.has('(#Year|#Time|#TextValue|#NumberRange)') === false) {\n d.match('(#Month|#WeekDay) #Value #Value').terms(2).unTag('Date', here)\n }\n //between june\n if (d.has('^between') && !d.has('and .')) {\n d.unTag('Date', here)\n }\n //june june\n if (d.has('#Month #Month') && !d.has('@hasHyphen') && !d.has('@hasComma')) {\n d.match('#Month').lastTerm().unTag('Date', 'month-month')\n }\n // log the hours\n if (d.has('(minutes|seconds|weeks|hours|days|months)') && !d.has('#Value #Duration')) {\n d.match('(minutes|seconds|weeks|hours|days|months)').unTag('#Date', 'log-hours')\n }\n // about thanksgiving\n if (d.has('about #Holiday')) {\n d.match('about').unTag('#Date', 'about-thanksgiving')\n }\n // dangling date-chunks\n // if (d.has('!#Date (in|of|by|for) !#Date')) {\n // d.unTag('Date', 'dangling-date')\n // }\n }\n return doc\n}\nmodule.exports = fixUp\n","const methods = [\n require('./00-basic'),\n require('./01-values'),\n require('./02-dates'),\n require('./03-sections'),\n require('./04-time'),\n require('./05-shifts'),\n require('./06-fixup'),\n]\n// run each of the taggers\nconst tagDate = function (doc) {\n methods.forEach((fn) => fn(doc))\n return doc\n}\nmodule.exports = tagDate\n","module.exports = {\n FinancialQuarter: {\n isA: 'Date',\n },\n // 'summer'\n Season: {\n isA: 'Date',\n },\n // '1982'\n Year: {\n isA: ['Date'],\n notA: 'RomanNumeral',\n },\n // 'months'\n Duration: {\n isA: ['Date', 'Noun'],\n },\n // 'easter'\n Holiday: {\n isA: ['Date', 'Noun'],\n },\n // 'PST'\n Timezone: {\n isA: ['Date', 'Noun'],\n },\n // 'two weeks before'\n DateShift: {\n isA: ['Date'],\n },\n}\n","/* spencermountain/spacetime 6.6.3 Apache 2.0 */\nfunction createCommonjsModule(fn, module) {\n\treturn module = { exports: {} }, fn(module, module.exports), module.exports;\n}\n\nfunction getCjsExportFromNamespace (n) {\n\treturn n && n['default'] || n;\n}\n\nvar fns = createCommonjsModule(function (module, exports) {\n //git:blame @JuliasCaesar https://www.timeanddate.com/date/leapyear.html\n exports.isLeapYear = function (year) {\n return year % 4 === 0 && year % 100 !== 0 || year % 400 === 0;\n }; // unsurprisingly-nasty `typeof date` call\n\n\n exports.isDate = function (d) {\n return Object.prototype.toString.call(d) === '[object Date]' && !isNaN(d.valueOf());\n };\n\n exports.isArray = function (input) {\n return Object.prototype.toString.call(input) === '[object Array]';\n };\n\n exports.isObject = function (input) {\n return Object.prototype.toString.call(input) === '[object Object]';\n };\n\n exports.zeroPad = function (str) {\n var len = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 2;\n var pad = '0';\n str = str + '';\n return str.length >= len ? str : new Array(len - str.length + 1).join(pad) + str;\n };\n\n exports.titleCase = function (str) {\n if (!str) {\n return '';\n }\n\n return str[0].toUpperCase() + str.substr(1);\n };\n\n exports.ordinal = function (i) {\n var j = i % 10;\n var k = i % 100;\n\n if (j === 1 && k !== 11) {\n return i + 'st';\n }\n\n if (j === 2 && k !== 12) {\n return i + 'nd';\n }\n\n if (j === 3 && k !== 13) {\n return i + 'rd';\n }\n\n return i + 'th';\n }; //strip 'st' off '1st'..\n\n\n exports.toCardinal = function (str) {\n str = String(str);\n str = str.replace(/([0-9])(st|nd|rd|th)$/i, '$1');\n return parseInt(str, 10);\n }; //used mostly for cleanup of unit names, like 'months'\n\n\n exports.normalize = function () {\n var str = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';\n str = str.toLowerCase().trim();\n str = str.replace(/ies$/, 'y'); //'centuries'\n\n str = str.replace(/s$/, '');\n str = str.replace(/-/g, '');\n\n if (str === 'day') {\n return 'date';\n }\n\n return str;\n };\n\n exports.getEpoch = function (tmp) {\n //support epoch\n if (typeof tmp === 'number') {\n return tmp;\n } //suport date objects\n\n\n if (exports.isDate(tmp)) {\n return tmp.getTime();\n }\n\n if (tmp.epoch) {\n return tmp.epoch;\n }\n\n return null;\n }; //make sure this input is a spacetime obj\n\n\n exports.beADate = function (d, s) {\n if (exports.isObject(d) === false) {\n return s.clone().set(d);\n }\n\n return d;\n };\n\n exports.formatTimezone = function (offset) {\n var delimiter = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';\n var absOffset = Math.abs(offset);\n var sign = offset > 0 ? '+' : '-';\n return \"\".concat(sign).concat(exports.zeroPad(absOffset)).concat(delimiter, \"00\");\n };\n});\nvar fns_1 = fns.isLeapYear;\nvar fns_2 = fns.isDate;\nvar fns_3 = fns.isArray;\nvar fns_4 = fns.isObject;\nvar fns_5 = fns.zeroPad;\nvar fns_6 = fns.titleCase;\nvar fns_7 = fns.ordinal;\nvar fns_8 = fns.toCardinal;\nvar fns_9 = fns.normalize;\nvar fns_10 = fns.getEpoch;\nvar fns_11 = fns.beADate;\nvar fns_12 = fns.formatTimezone;\n\nvar zeroPad = fns.zeroPad;\n\nvar serialize = function serialize(d) {\n return zeroPad(d.getMonth() + 1) + '/' + zeroPad(d.getDate()) + ':' + zeroPad(d.getHours());\n}; // a timezone will begin with a specific offset in january\n// then some will switch to something else between november-march\n\n\nvar shouldChange = function shouldChange(epoch, start, end, defaultOffset) {\n //note: this has a cray order-of-operations issue\n //we can't get the date, without knowing the timezone, and vice-versa\n //it's possible that we can miss a dst-change by a few hours.\n var d = new Date(epoch); //(try to mediate this a little?)\n\n var bias = d.getTimezoneOffset() || 0;\n var shift = bias + defaultOffset * 60; //in minutes\n\n shift = shift * 60 * 1000; //in ms\n\n d = new Date(epoch + shift);\n var current = serialize(d); //eg. is it after ~november?\n\n if (current >= start) {\n //eg. is it before ~march~ too?\n if (current < end) {\n return true;\n }\n }\n\n return false;\n};\n\nvar summerTime = shouldChange;\n\n// it reproduces some things in ./index.js, but speeds up spacetime considerably\n\nvar quickOffset = function quickOffset(s) {\n var zones = s.timezones;\n var obj = zones[s.tz];\n\n if (obj === undefined) {\n console.warn(\"Warning: couldn't find timezone \" + s.tz);\n return 0;\n }\n\n if (obj.dst === undefined) {\n return obj.offset;\n } //get our two possible offsets\n\n\n var jul = obj.offset;\n var dec = obj.offset + 1; // assume it's the same for now\n\n if (obj.hem === 'n') {\n dec = jul - 1;\n }\n\n var split = obj.dst.split('->');\n var inSummer = summerTime(s.epoch, split[0], split[1], jul);\n\n if (inSummer === true) {\n return jul;\n }\n\n return dec;\n};\n\nvar quick = quickOffset;\n\nvar _build = {\n\t\"9|s\": \"2/dili,2/jayapura\",\n\t\"9|n\": \"2/chita,2/khandyga,2/pyongyang,2/seoul,2/tokyo,11/palau\",\n\t\"9.5|s|04/05:03->10/04:02\": \"4/adelaide,4/broken_hill,4/south,4/yancowinna\",\n\t\"9.5|s\": \"4/darwin,4/north\",\n\t\"8|s\": \"12/casey,2/kuala_lumpur,2/makassar,2/singapore,4/perth,4/west\",\n\t\"8|n|03/25:03->09/29:23\": \"2/ulan_bator\",\n\t\"8|n\": \"2/brunei,2/choibalsan,2/chongqing,2/chungking,2/harbin,2/hong_kong,2/irkutsk,2/kuching,2/macao,2/macau,2/manila,2/shanghai,2/taipei,2/ujung_pandang,2/ulaanbaatar\",\n\t\"8.75|s\": \"4/eucla\",\n\t\"7|s\": \"12/davis,2/jakarta,9/christmas\",\n\t\"7|n\": \"2/bangkok,2/barnaul,2/ho_chi_minh,2/hovd,2/krasnoyarsk,2/novokuznetsk,2/novosibirsk,2/phnom_penh,2/pontianak,2/saigon,2/tomsk,2/vientiane\",\n\t\"6|s\": \"12/vostok\",\n\t\"6|n\": \"2/almaty,2/bishkek,2/dacca,2/dhaka,2/kashgar,2/omsk,2/qyzylorda,2/thimbu,2/thimphu,2/urumqi,9/chagos\",\n\t\"6.5|n\": \"2/rangoon,2/yangon,9/cocos\",\n\t\"5|s\": \"12/mawson,9/kerguelen\",\n\t\"5|n\": \"2/aqtau,2/aqtobe,2/ashgabat,2/ashkhabad,2/atyrau,2/baku,2/dushanbe,2/karachi,2/oral,2/samarkand,2/tashkent,2/yekaterinburg,9/maldives\",\n\t\"5.75|n\": \"2/kathmandu,2/katmandu\",\n\t\"5.5|n\": \"2/calcutta,2/colombo,2/kolkata\",\n\t\"4|s\": \"9/reunion\",\n\t\"4|n\": \"2/dubai,2/muscat,2/tbilisi,2/yerevan,8/astrakhan,8/samara,8/saratov,8/ulyanovsk,8/volgograd,2/volgograd,9/mahe,9/mauritius\",\n\t\"4.5|n|03/21:00->09/20:24\": \"2/tehran\",\n\t\"4.5|n\": \"2/kabul\",\n\t\"3|s\": \"12/syowa,9/antananarivo\",\n\t\"3|n|03/29:03->10/25:04\": \"2/famagusta,2/nicosia,8/athens,8/bucharest,8/helsinki,8/kiev,8/mariehamn,8/nicosia,8/riga,8/sofia,8/tallinn,8/uzhgorod,8/vilnius,8/zaporozhye\",\n\t\"3|n|03/29:02->10/25:03\": \"8/chisinau,8/tiraspol\",\n\t\"3|n|03/29:00->10/24:24\": \"2/beirut\",\n\t\"3|n|03/27:02->10/25:02\": \"2/jerusalem,2/tel_aviv\",\n\t\"3|n|03/27:00->10/31:01\": \"2/gaza,2/hebron\",\n\t\"3|n|03/27:00->10/30:01\": \"2/amman\",\n\t\"3|n|03/27:00->10/29:24\": \"2/damascus\",\n\t\"3|n\": \"0/addis_ababa,0/asmara,0/asmera,0/dar_es_salaam,0/djibouti,0/juba,0/kampala,0/mogadishu,0/nairobi,2/aden,2/baghdad,2/bahrain,2/istanbul,2/kuwait,2/qatar,2/riyadh,8/istanbul,8/kirov,8/minsk,8/moscow,8/simferopol,9/comoro,9/mayotte\",\n\t\"2|s|03/29:02->10/25:02\": \"12/troll\",\n\t\"2|s\": \"0/gaborone,0/harare,0/johannesburg,0/lubumbashi,0/lusaka,0/maputo,0/maseru,0/mbabane\",\n\t\"2|n|03/29:02->10/25:03\": \"0/ceuta,arctic/longyearbyen,3/jan_mayen,8/amsterdam,8/andorra,8/belgrade,8/berlin,8/bratislava,8/brussels,8/budapest,8/busingen,8/copenhagen,8/gibraltar,8/ljubljana,8/luxembourg,8/madrid,8/malta,8/monaco,8/oslo,8/paris,8/podgorica,8/prague,8/rome,8/san_marino,8/sarajevo,8/skopje,8/stockholm,8/tirane,8/vaduz,8/vatican,8/vienna,8/warsaw,8/zagreb,8/zurich\",\n\t\"2|n\": \"0/blantyre,0/bujumbura,0/cairo,0/khartoum,0/kigali,0/tripoli,8/kaliningrad\",\n\t\"1|s|04/02:01->09/03:03\": \"0/windhoek\",\n\t\"1|s\": \"0/kinshasa,0/luanda\",\n\t\"1|n|04/19:03->05/31:02\": \"0/casablanca,0/el_aaiun\",\n\t\"1|n|03/29:01->10/25:02\": \"3/canary,3/faeroe,3/faroe,3/madeira,8/belfast,8/dublin,8/guernsey,8/isle_of_man,8/jersey,8/lisbon,8/london\",\n\t\"1|n\": \"0/algiers,0/bangui,0/brazzaville,0/douala,0/lagos,0/libreville,0/malabo,0/ndjamena,0/niamey,0/porto-novo,0/tunis\",\n\t\"14|n\": \"11/kiritimati\",\n\t\"13|s|04/05:04->09/27:03\": \"11/apia\",\n\t\"13|s|01/15:02->11/05:03\": \"11/tongatapu\",\n\t\"13|n\": \"11/enderbury,11/fakaofo\",\n\t\"12|s|04/05:03->09/27:02\": \"12/mcmurdo,12/south_pole,11/auckland\",\n\t\"12|s|01/12:03->11/08:02\": \"11/fiji\",\n\t\"12|n\": \"2/anadyr,2/kamchatka,2/srednekolymsk,11/funafuti,11/kwajalein,11/majuro,11/nauru,11/tarawa,11/wake,11/wallis\",\n\t\"12.75|s|04/05:03->04/05:02\": \"11/chatham\",\n\t\"11|s\": \"12/macquarie,11/bougainville\",\n\t\"11|n\": \"2/magadan,2/sakhalin,11/efate,11/guadalcanal,11/kosrae,11/noumea,11/pohnpei,11/ponape\",\n\t\"11.5|n|04/05:03->10/04:02\": \"11/norfolk\",\n\t\"10|s|04/05:03->10/04:02\": \"4/act,4/canberra,4/currie,4/hobart,4/melbourne,4/nsw,4/sydney,4/tasmania,4/victoria\",\n\t\"10|s\": \"12/dumontdurville,4/brisbane,4/lindeman,4/queensland\",\n\t\"10|n\": \"2/ust-nera,2/vladivostok,2/yakutsk,11/chuuk,11/guam,11/port_moresby,11/saipan,11/truk,11/yap\",\n\t\"10.5|s|04/05:01->10/04:02\": \"4/lhi,4/lord_howe\",\n\t\"0|n|03/29:00->10/25:01\": \"1/scoresbysund,3/azores\",\n\t\"0|n\": \"0/abidjan,0/accra,0/bamako,0/banjul,0/bissau,0/conakry,0/dakar,0/freetown,0/lome,0/monrovia,0/nouakchott,0/ouagadougou,0/sao_tome,0/timbuktu,1/danmarkshavn,3/reykjavik,3/st_helena,13/gmt,13/gmt+0,13/gmt-0,13/gmt0,13/greenwich,13/utc,13/universal,13/zulu\",\n\t\"-9|n|03/08:02->11/01:02\": \"1/adak,1/atka\",\n\t\"-9|n\": \"11/gambier\",\n\t\"-9.5|n\": \"11/marquesas\",\n\t\"-8|n|03/08:02->11/01:02\": \"1/anchorage,1/juneau,1/metlakatla,1/nome,1/sitka,1/yakutat\",\n\t\"-8|n\": \"11/pitcairn\",\n\t\"-7|n|03/08:02->11/01:02\": \"1/dawson,1/ensenada,1/los_angeles,1/santa_isabel,1/tijuana,1/vancouver,1/whitehorse,6/pacific,6/yukon,10/bajanorte\",\n\t\"-7|n\": \"1/creston,1/dawson_creek,1/hermosillo,1/phoenix\",\n\t\"-6|s|04/04:22->09/05:22\": \"7/easterisland,11/easter\",\n\t\"-6|n|04/05:02->10/25:02\": \"1/chihuahua,1/mazatlan,10/bajasur\",\n\t\"-6|n|03/08:02->11/01:02\": \"1/boise,1/cambridge_bay,1/denver,1/edmonton,1/inuvik,1/ojinaga,1/shiprock,1/yellowknife,6/mountain\",\n\t\"-6|n\": \"1/belize,1/costa_rica,1/el_salvador,1/guatemala,1/managua,1/regina,1/swift_current,1/tegucigalpa,6/east-saskatchewan,6/saskatchewan,11/galapagos\",\n\t\"-5|s\": \"1/lima,1/rio_branco,5/acre\",\n\t\"-5|n|04/05:02->10/25:02\": \"1/bahia_banderas,1/merida,1/mexico_city,1/monterrey,10/general\",\n\t\"-5|n|03/12:03->11/05:01\": \"1/north_dakota\",\n\t\"-5|n|03/08:02->11/01:02\": \"1/chicago,1/knox_in,1/matamoros,1/menominee,1/rainy_river,1/rankin_inlet,1/resolute,1/winnipeg,6/central\",\n\t\"-5|n\": \"1/atikokan,1/bogota,1/cancun,1/cayman,1/coral_harbour,1/eirunepe,1/guayaquil,1/jamaica,1/panama,1/porto_acre\",\n\t\"-4|s|05/13:23->08/13:01\": \"12/palmer\",\n\t\"-4|s|04/04:24->09/06:00\": \"1/santiago,7/continental\",\n\t\"-4|s|03/21:24->10/04:00\": \"1/asuncion\",\n\t\"-4|s|02/16:24->11/03:00\": \"1/campo_grande,1/cuiaba\",\n\t\"-4|s\": \"1/la_paz,1/manaus,5/west\",\n\t\"-4|n|03/12:03->11/05:01\": \"1/indiana,1/kentucky\",\n\t\"-4|n|03/08:02->11/01:02\": \"1/detroit,1/fort_wayne,1/grand_turk,1/indianapolis,1/iqaluit,1/louisville,1/montreal,1/nassau,1/new_york,1/nipigon,1/pangnirtung,1/port-au-prince,1/thunder_bay,1/toronto,6/eastern\",\n\t\"-4|n|03/08:00->11/01:01\": \"1/havana\",\n\t\"-4|n\": \"1/anguilla,1/antigua,1/aruba,1/barbados,1/blanc-sablon,1/boa_vista,1/caracas,1/curacao,1/dominica,1/grenada,1/guadeloupe,1/guyana,1/kralendijk,1/lower_princes,1/marigot,1/martinique,1/montserrat,1/port_of_spain,1/porto_velho,1/puerto_rico,1/santo_domingo,1/st_barthelemy,1/st_kitts,1/st_lucia,1/st_thomas,1/st_vincent,1/tortola,1/virgin\",\n\t\"-3|s\": \"1/argentina,1/buenos_aires,1/cordoba,1/fortaleza,1/montevideo,1/punta_arenas,1/sao_paulo,12/rothera,3/stanley,5/east\",\n\t\"-3|n|03/08:02->11/01:02\": \"1/glace_bay,1/goose_bay,1/halifax,1/moncton,1/thule,3/bermuda,6/atlantic\",\n\t\"-3|n\": \"1/araguaina,1/bahia,1/belem,1/catamarca,1/cayenne,1/jujuy,1/maceio,1/mendoza,1/paramaribo,1/recife,1/rosario,1/santarem\",\n\t\"-2|s\": \"5/denoronha\",\n\t\"-2|n|03/28:22->10/24:23\": \"1/godthab\",\n\t\"-2|n|03/08:02->11/01:02\": \"1/miquelon\",\n\t\"-2|n\": \"1/noronha,3/south_georgia\",\n\t\"-2.5|n|03/08:02->11/01:02\": \"1/st_johns,6/newfoundland\",\n\t\"-1|n\": \"3/cape_verde\",\n\t\"-11|n\": \"11/midway,11/niue,11/pago_pago,11/samoa\",\n\t\"-10|n\": \"11/honolulu,11/johnston,11/rarotonga,11/tahiti\"\n};\n\nvar _build$1 = /*#__PURE__*/Object.freeze({\n\t__proto__: null,\n\t'default': _build\n});\n\n//prefixes for iana names..\nvar _prefixes = ['africa', 'america', 'asia', 'atlantic', 'australia', 'brazil', 'canada', 'chile', 'europe', 'indian', 'mexico', 'pacific', 'antarctica', 'etc'];\n\nvar data = getCjsExportFromNamespace(_build$1);\n\nvar all = {};\nObject.keys(data).forEach(function (k) {\n var split = k.split('|');\n var obj = {\n offset: Number(split[0]),\n hem: split[1]\n };\n\n if (split[2]) {\n obj.dst = split[2];\n }\n\n var names = data[k].split(',');\n names.forEach(function (str) {\n str = str.replace(/(^[0-9]+)\\//, function (before, num) {\n num = Number(num);\n return _prefixes[num] + '/';\n });\n all[str] = obj;\n });\n});\nall['utc'] = {\n offset: 0,\n hem: 'n' //(sorry)\n\n}; //add etc/gmt+n\n\nfor (var i = -14; i <= 14; i += 0.5) {\n var num = i;\n\n if (num > 0) {\n num = '+' + num;\n }\n\n var name = 'etc/gmt' + num;\n all[name] = {\n offset: i * -1,\n //they're negative!\n hem: 'n' //(sorry)\n\n };\n name = 'utc/gmt' + num; //this one too, why not.\n\n all[name] = {\n offset: i * -1,\n hem: 'n'\n };\n} // console.log(all)\n// console.log(Object.keys(all).length)\n\n\nvar unpack = all;\n\n//find the implicit iana code for this machine.\n//safely query the Intl object\n//based on - https://bitbucket.org/pellepim/jstimezonedetect/src\nvar fallbackTZ = 'utc'; //\n//this Intl object is not supported often, yet\n\nvar safeIntl = function safeIntl() {\n if (typeof Intl === 'undefined' || typeof Intl.DateTimeFormat === 'undefined') {\n return null;\n }\n\n var format = Intl.DateTimeFormat();\n\n if (typeof format === 'undefined' || typeof format.resolvedOptions === 'undefined') {\n return null;\n }\n\n var timezone = format.resolvedOptions().timeZone;\n\n if (!timezone) {\n return null;\n }\n\n return timezone.toLowerCase();\n};\n\nvar guessTz = function guessTz() {\n var timezone = safeIntl();\n\n if (timezone === null) {\n return fallbackTZ;\n }\n\n return timezone;\n}; //do it once per computer\n\n\nvar guessTz_1 = guessTz;\n\nvar isOffset = /(\\-?[0-9]+)h(rs)?/i;\nvar isNumber = /(\\-?[0-9]+)/;\nvar utcOffset = /utc([\\-+]?[0-9]+)/i;\nvar gmtOffset = /gmt([\\-+]?[0-9]+)/i;\n\nvar toIana = function toIana(num) {\n num = Number(num);\n\n if (num > -13 && num < 13) {\n num = num * -1; //it's opposite!\n\n num = (num > 0 ? '+' : '') + num; //add plus sign\n\n return 'etc/gmt' + num;\n }\n\n return null;\n};\n\nvar parseOffset = function parseOffset(tz) {\n // '+5hrs'\n var m = tz.match(isOffset);\n\n if (m !== null) {\n return toIana(m[1]);\n } // 'utc+5'\n\n\n m = tz.match(utcOffset);\n\n if (m !== null) {\n return toIana(m[1]);\n } // 'GMT-5' (not opposite)\n\n\n m = tz.match(gmtOffset);\n\n if (m !== null) {\n var num = Number(m[1]) * -1;\n return toIana(num);\n } // '+5'\n\n\n m = tz.match(isNumber);\n\n if (m !== null) {\n return toIana(m[1]);\n }\n\n return null;\n};\n\nvar parseOffset_1 = parseOffset;\n\nvar local = guessTz_1(); //add all the city names by themselves\n\nvar cities = Object.keys(unpack).reduce(function (h, k) {\n var city = k.split('/')[1] || '';\n city = city.replace(/_/g, ' ');\n h[city] = k;\n return h;\n}, {}); //try to match these against iana form\n\nvar normalize = function normalize(tz) {\n tz = tz.replace(/ time/g, '');\n tz = tz.replace(/ (standard|daylight|summer)/g, '');\n tz = tz.replace(/\\b(east|west|north|south)ern/g, '$1');\n tz = tz.replace(/\\b(africa|america|australia)n/g, '$1');\n tz = tz.replace(/\\beuropean/g, 'europe');\n tz = tz.replace(/\\islands/g, 'island');\n return tz;\n}; // try our best to reconcile the timzone to this given string\n\n\nvar lookupTz = function lookupTz(str, zones) {\n if (!str) {\n return local;\n }\n\n var tz = str.trim();\n var split = str.split('/'); //support long timezones like 'America/Argentina/Rio_Gallegos'\n\n if (split.length > 2 && zones.hasOwnProperty(tz) === false) {\n tz = split[0] + '/' + split[1];\n }\n\n tz = tz.toLowerCase();\n\n if (zones.hasOwnProperty(tz) === true) {\n return tz;\n } //lookup more loosely..\n\n\n tz = normalize(tz);\n\n if (zones.hasOwnProperty(tz) === true) {\n return tz;\n } //try city-names\n\n\n if (cities.hasOwnProperty(tz) === true) {\n return cities[tz];\n } // //try to parse '-5h'\n\n\n if (/[0-9]/.test(tz) === true) {\n var id = parseOffset_1(tz);\n\n if (id) {\n return id;\n }\n }\n\n throw new Error(\"Spacetime: Cannot find timezone named: '\" + str + \"'. Please enter an IANA timezone id.\");\n};\n\nvar find = lookupTz;\n\nvar o = {\n millisecond: 1\n};\no.second = 1000;\no.minute = 60000;\no.hour = 3.6e6; // dst is supported post-hoc\n\no.day = 8.64e7; //\n\no.date = o.day;\no.month = 8.64e7 * 29.5; //(average)\n\no.week = 6.048e8;\no.year = 3.154e10; // leap-years are supported post-hoc\n//add plurals\n\nObject.keys(o).forEach(function (k) {\n o[k + 's'] = o[k];\n});\nvar milliseconds = o;\n\nvar walk = function walk(s, n, fn, unit, previous) {\n var current = s.d[fn]();\n\n if (current === n) {\n return; //already there\n }\n\n var startUnit = previous === null ? null : s.d[previous]();\n var original = s.epoch; //try to get it as close as we can\n\n var diff = n - current;\n s.epoch += milliseconds[unit] * diff; //DST edge-case: if we are going many days, be a little conservative\n // console.log(unit, diff)\n\n if (unit === 'day') {\n // s.epoch -= ms.minute\n //but don't push it over a month\n if (Math.abs(diff) > 28 && n < 28) {\n s.epoch += milliseconds.hour;\n }\n } // 1st time: oops, did we change previous unit? revert it.\n\n\n if (previous !== null && startUnit !== s.d[previous]()) {\n // console.warn('spacetime warning: missed setting ' + unit)\n s.epoch = original; // s.epoch += ms[unit] * diff * 0.89 // maybe try and make it close...?\n } //repair it if we've gone too far or something\n //(go by half-steps, just in case)\n\n\n var halfStep = milliseconds[unit] / 2;\n\n while (s.d[fn]() < n) {\n s.epoch += halfStep;\n }\n\n while (s.d[fn]() > n) {\n s.epoch -= halfStep;\n } // 2nd time: did we change previous unit? revert it.\n\n\n if (previous !== null && startUnit !== s.d[previous]()) {\n // console.warn('spacetime warning: missed setting ' + unit)\n s.epoch = original;\n }\n}; //find the desired date by a increment/check while loop\n\n\nvar units = {\n year: {\n valid: function valid(n) {\n return n > -4000 && n < 4000;\n },\n walkTo: function walkTo(s, n) {\n return walk(s, n, 'getFullYear', 'year', null);\n }\n },\n month: {\n valid: function valid(n) {\n return n >= 0 && n <= 11;\n },\n walkTo: function walkTo(s, n) {\n var d = s.d;\n var current = d.getMonth();\n var original = s.epoch;\n var startUnit = d.getFullYear();\n\n if (current === n) {\n return;\n } //try to get it as close as we can..\n\n\n var diff = n - current;\n s.epoch += milliseconds.day * (diff * 28); //special case\n //oops, did we change the year? revert it.\n\n if (startUnit !== s.d.getFullYear()) {\n s.epoch = original;\n } //incriment by day\n\n\n while (s.d.getMonth() < n) {\n s.epoch += milliseconds.day;\n }\n\n while (s.d.getMonth() > n) {\n s.epoch -= milliseconds.day;\n }\n }\n },\n date: {\n valid: function valid(n) {\n return n > 0 && n <= 31;\n },\n walkTo: function walkTo(s, n) {\n return walk(s, n, 'getDate', 'day', 'getMonth');\n }\n },\n hour: {\n valid: function valid(n) {\n return n >= 0 && n < 24;\n },\n walkTo: function walkTo(s, n) {\n return walk(s, n, 'getHours', 'hour', 'getDate');\n }\n },\n minute: {\n valid: function valid(n) {\n return n >= 0 && n < 60;\n },\n walkTo: function walkTo(s, n) {\n return walk(s, n, 'getMinutes', 'minute', 'getHours');\n }\n },\n second: {\n valid: function valid(n) {\n return n >= 0 && n < 60;\n },\n walkTo: function walkTo(s, n) {\n //do this one directly\n s.epoch = s.seconds(n).epoch;\n }\n },\n millisecond: {\n valid: function valid(n) {\n return n >= 0 && n < 1000;\n },\n walkTo: function walkTo(s, n) {\n //do this one directly\n s.epoch = s.milliseconds(n).epoch;\n }\n }\n};\n\nvar walkTo = function walkTo(s, wants) {\n var keys = Object.keys(units);\n var old = s.clone();\n\n for (var i = 0; i < keys.length; i++) {\n var k = keys[i];\n var n = wants[k];\n\n if (n === undefined) {\n n = old[k]();\n }\n\n if (typeof n === 'string') {\n n = parseInt(n, 10);\n } //make-sure it's valid\n\n\n if (!units[k].valid(n)) {\n s.epoch = null;\n\n if (s.silent === false) {\n console.warn('invalid ' + k + ': ' + n);\n }\n\n return;\n }\n\n units[k].walkTo(s, n);\n }\n\n return;\n};\n\nvar walk_1 = walkTo;\n\nvar shortMonths = ['jan', 'feb', 'mar', 'apr', 'may', 'jun', 'jul', 'aug', 'sept', 'oct', 'nov', 'dec'];\nvar longMonths = ['january', 'february', 'march', 'april', 'may', 'june', 'july', 'august', 'september', 'october', 'november', 'december'];\n\nfunction buildMapping() {\n var obj = {\n sep: 8 //support this format\n\n };\n\n for (var i = 0; i < shortMonths.length; i++) {\n obj[shortMonths[i]] = i;\n }\n\n for (var _i = 0; _i < longMonths.length; _i++) {\n obj[longMonths[_i]] = _i;\n }\n\n return obj;\n}\n\nvar months = {\n \"short\": function short() {\n return shortMonths;\n },\n \"long\": function long() {\n return longMonths;\n },\n mapping: function mapping() {\n return buildMapping();\n },\n set: function set(i18n) {\n shortMonths = i18n[\"short\"] || shortMonths;\n longMonths = i18n[\"long\"] || longMonths;\n }\n};\n\n//pull-apart ISO offsets, like \"+0100\"\nvar parseOffset$1 = function parseOffset(s, offset) {\n if (!offset) {\n return s;\n } //this is a fancy-move\n\n\n if (offset === 'Z') {\n offset = '+0000';\n } // according to ISO8601, tz could be hh:mm, hhmm or hh\n // so need few more steps before the calculation.\n\n\n var num = 0; // for (+-)hh:mm\n\n if (/^[\\+-]?[0-9]{2}:[0-9]{2}$/.test(offset)) {\n //support \"+01:00\"\n if (/:00/.test(offset) === true) {\n offset = offset.replace(/:00/, '');\n } //support \"+01:30\"\n\n\n if (/:30/.test(offset) === true) {\n offset = offset.replace(/:30/, '.5');\n }\n } // for (+-)hhmm\n\n\n if (/^[\\+-]?[0-9]{4}$/.test(offset)) {\n offset = offset.replace(/30$/, '.5');\n }\n\n num = parseFloat(offset); //divide by 100 or 10 - , \"+0100\", \"+01\"\n\n if (Math.abs(num) > 100) {\n num = num / 100;\n } //okay, try to match it to a utc timezone\n //remember - this is opposite! a -5 offset maps to Etc/GMT+5 ¯\\_(:/)_/¯\n //https://askubuntu.com/questions/519550/why-is-the-8-timezone-called-gmt-8-in-the-filesystem\n\n\n num *= -1;\n\n if (num >= 0) {\n num = '+' + num;\n }\n\n var tz = 'etc/gmt' + num;\n var zones = s.timezones;\n\n if (zones[tz]) {\n // log a warning if we're over-writing a given timezone?\n // console.log('changing timezone to: ' + tz)\n s.tz = tz;\n }\n\n return s;\n};\n\nvar parseOffset_1$1 = parseOffset$1;\n\nvar parseTime = function parseTime(s) {\n var str = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';\n str = str.replace(/^\\s+/, '').toLowerCase(); //trim\n //formal time formats - 04:30.23\n\n var arr = str.match(/([0-9]{1,2}):([0-9]{1,2}):?([0-9]{1,2})?[:\\.]?([0-9]{1,4})?/);\n\n if (arr !== null) {\n //validate it a little\n var h = Number(arr[1]);\n\n if (h < 0 || h > 24) {\n return s.startOf('day');\n }\n\n var m = Number(arr[2]); //don't accept '5:3pm'\n\n if (arr[2].length < 2 || m < 0 || m > 59) {\n return s.startOf('day');\n }\n\n s = s.hour(h);\n s = s.minute(m);\n s = s.seconds(arr[3] || 0);\n s = s.millisecond(arr[4] || 0); //parse-out am/pm\n\n var ampm = str.match(/[\\b0-9](am|pm)\\b/);\n\n if (ampm !== null && ampm[1]) {\n s = s.ampm(ampm[1]);\n }\n\n return s;\n } //try an informal form - 5pm (no minutes)\n\n\n arr = str.match(/([0-9]+) ?(am|pm)/);\n\n if (arr !== null && arr[1]) {\n var _h = Number(arr[1]); //validate it a little..\n\n\n if (_h > 12 || _h < 1) {\n return s.startOf('day');\n }\n\n s = s.hour(arr[1] || 0);\n s = s.ampm(arr[2]);\n s = s.startOf('hour');\n return s;\n } //no time info found, use start-of-day\n\n\n s = s.startOf('day');\n return s;\n};\n\nvar parseTime_1 = parseTime;\n\nvar monthLengths = [31, // January - 31 days\n28, // February - 28 days in a common year and 29 days in leap years\n31, // March - 31 days\n30, // April - 30 days\n31, // May - 31 days\n30, // June - 30 days\n31, // July - 31 days\n31, // August - 31 days\n30, // September - 30 days\n31, // October - 31 days\n30, // November - 30 days\n31 // December - 31 days\n];\nvar monthLengths_1 = monthLengths; // 28 - feb\n\nvar isLeapYear = fns.isLeapYear; //given a month, return whether day number exists in it\n\nvar hasDate = function hasDate(obj) {\n //invalid values\n if (monthLengths_1.hasOwnProperty(obj.month) !== true) {\n return false;\n } //support leap-year in february\n\n\n if (obj.month === 1) {\n if (isLeapYear(obj.year) && obj.date <= 29) {\n return true;\n } else {\n return obj.date <= 28;\n }\n } //is this date too-big for this month?\n\n\n var max = monthLengths_1[obj.month] || 0;\n\n if (obj.date <= max) {\n return true;\n }\n\n return false;\n};\n\nvar hasDate_1 = hasDate;\n\nvar months$1 = months.mapping();\n\nvar parseYear = function parseYear() {\n var str = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';\n var today = arguments.length > 1 ? arguments[1] : undefined;\n var year = parseInt(str.trim(), 10); // use a given year from options.today\n\n if (!year && today) {\n year = today.year;\n } // fallback to this year\n\n\n year = year || new Date().getFullYear();\n return year;\n};\n\nvar strFmt = [//iso-this 1998-05-30T22:00:00:000Z, iso-that 2017-04-03T08:00:00-0700\n{\n reg: /^(\\-?0?0?[0-9]{3,4})-([0-9]{1,2})-([0-9]{1,2})[T| ]([0-9.:]+)(Z|[0-9\\-\\+:]+)?$/,\n parse: function parse(s, arr, givenTz, options) {\n var month = parseInt(arr[2], 10) - 1;\n var obj = {\n year: arr[1],\n month: month,\n date: arr[3]\n };\n\n if (hasDate_1(obj) === false) {\n s.epoch = null;\n return s;\n }\n\n parseOffset_1$1(s, arr[5]);\n walk_1(s, obj);\n s = parseTime_1(s, arr[4]);\n return s;\n }\n}, //iso \"2015-03-25\" or \"2015/03/25\" or \"2015/03/25 12:26:14 PM\"\n{\n reg: /^([0-9]{4})[\\-\\/]([0-9]{1,2})[\\-\\/]([0-9]{1,2}),?( [0-9]{1,2}:[0-9]{2}:?[0-9]{0,2}? ?(am|pm|gmt))?$/i,\n parse: function parse(s, arr) {\n var obj = {\n year: arr[1],\n month: parseInt(arr[2], 10) - 1,\n date: parseInt(arr[3], 10)\n };\n\n if (obj.month >= 12) {\n //support yyyy/dd/mm (weird, but ok)\n obj.date = parseInt(arr[2], 10);\n obj.month = parseInt(arr[3], 10) - 1;\n }\n\n if (hasDate_1(obj) === false) {\n s.epoch = null;\n return s;\n }\n\n walk_1(s, obj);\n s = parseTime_1(s, arr[4]);\n return s;\n }\n}, //mm/dd/yyyy - uk/canada \"6/28/2019, 12:26:14 PM\"\n{\n reg: /^([0-9]{1,2})[\\-\\/]([0-9]{1,2})[\\-\\/]?([0-9]{4})?,?( [0-9]{1,2}:[0-9]{2}:?[0-9]{0,2}? ?(am|pm|gmt))?$/i,\n parse: function parse(s, arr) {\n var month = parseInt(arr[1], 10) - 1;\n var date = parseInt(arr[2], 10); //support dd/mm/yyy\n\n if (s.british || month >= 12) {\n date = parseInt(arr[1], 10);\n month = parseInt(arr[2], 10) - 1;\n }\n\n var year = arr[3] || new Date().getFullYear();\n var obj = {\n year: year,\n month: month,\n date: date\n };\n\n if (hasDate_1(obj) === false) {\n s.epoch = null;\n return s;\n }\n\n walk_1(s, obj);\n s = parseTime_1(s, arr[4]);\n return s;\n }\n}, //common british format - \"25-feb-2015\"\n{\n reg: /^([0-9]{1,2})[\\-\\/]([a-z]+)[\\-\\/]?([0-9]{4})?$/i,\n parse: function parse(s, arr) {\n var month = months$1[arr[2].toLowerCase()];\n var year = parseYear(arr[3], s._today);\n var obj = {\n year: year,\n month: month,\n date: fns.toCardinal(arr[1] || '')\n };\n\n if (hasDate_1(obj) === false) {\n s.epoch = null;\n return s;\n }\n\n walk_1(s, obj);\n s = parseTime_1(s, arr[4]);\n return s;\n }\n}, //Long \"Mar 25 2015\"\n//February 22, 2017 15:30:00\n{\n reg: /^([a-z]+) ([0-9]{1,2}(?:st|nd|rd|th)?),?( [0-9]{4})?( ([0-9:]+( ?am| ?pm| ?gmt)?))?$/i,\n parse: function parse(s, arr) {\n var month = months$1[arr[1].toLowerCase()];\n var year = parseYear(arr[3], s._today);\n var obj = {\n year: year,\n month: month,\n date: fns.toCardinal(arr[2] || '')\n };\n\n if (hasDate_1(obj) === false) {\n s.epoch = null;\n return s;\n }\n\n walk_1(s, obj);\n s = parseTime_1(s, arr[4]);\n return s;\n }\n}, //February 2017 (implied date)\n{\n reg: /^([a-z]+) ([0-9]{4})$/i,\n parse: function parse(s, arr) {\n var month = months$1[arr[1].toLowerCase()];\n var year = parseYear(arr[2], s._today);\n var obj = {\n year: year,\n month: month,\n date: s._today.date || 1\n };\n\n if (hasDate_1(obj) === false) {\n s.epoch = null;\n return s;\n }\n\n walk_1(s, obj);\n s = parseTime_1(s, arr[4]);\n return s;\n }\n}, //Long \"25 Mar 2015\"\n{\n reg: /^([0-9]{1,2}(?:st|nd|rd|th)?) ([a-z]+),?( [0-9]{4})?,? ?([0-9]{1,2}:[0-9]{2}:?[0-9]{0,2}? ?(am|pm|gmt))?$/i,\n parse: function parse(s, arr) {\n var month = months$1[arr[2].toLowerCase()];\n\n if (!month) {\n return null;\n }\n\n var year = parseYear(arr[3], s._today);\n var obj = {\n year: year,\n month: month,\n date: fns.toCardinal(arr[1])\n };\n\n if (hasDate_1(obj) === false) {\n s.epoch = null;\n return s;\n }\n\n walk_1(s, obj);\n s = parseTime_1(s, arr[4]);\n return s;\n }\n}, {\n // '200bc'\n reg: /^[0-9,]+ ?b\\.?c\\.?$/i,\n parse: function parse(s, arr) {\n var str = arr[0] || ''; //make negative-year\n\n str = str.replace(/^([0-9,]+) ?b\\.?c\\.?$/i, '-$1'); //remove commas\n\n str = str.replace(/,/g, '');\n var year = parseInt(str.trim(), 10);\n var d = new Date();\n var obj = {\n year: year,\n month: d.getMonth(),\n date: d.getDate()\n };\n\n if (hasDate_1(obj) === false) {\n s.epoch = null;\n return s;\n }\n\n walk_1(s, obj);\n s = parseTime_1(s);\n return s;\n }\n}, {\n // '200ad'\n reg: /^[0-9,]+ ?(a\\.?d\\.?|c\\.?e\\.?)$/i,\n parse: function parse(s, arr) {\n var str = arr[0] || ''; //remove commas\n\n str = str.replace(/,/g, '');\n var year = parseInt(str.trim(), 10);\n var d = new Date();\n var obj = {\n year: year,\n month: d.getMonth(),\n date: d.getDate()\n };\n\n if (hasDate_1(obj) === false) {\n s.epoch = null;\n return s;\n }\n\n walk_1(s, obj);\n s = parseTime_1(s);\n return s;\n }\n}, {\n // '1992'\n reg: /^[0-9]{4}( ?a\\.?d\\.?)?$/i,\n parse: function parse(s, arr) {\n var today = s._today;\n var year = parseYear(arr[0], today);\n var d = new Date(); // using today's date, but a new month is awkward.\n\n if (today.month && !today.date) {\n today.date = 1;\n }\n\n var obj = {\n year: year,\n month: today.month || d.getMonth(),\n date: today.date || d.getDate()\n };\n\n if (hasDate_1(obj) === false) {\n s.epoch = null;\n return s;\n }\n\n walk_1(s, obj);\n s = parseTime_1(s);\n return s;\n }\n}];\nvar strParse = strFmt;\n\n// pull in 'today' data for the baseline moment\nvar getNow = function getNow(s) {\n s.epoch = Date.now();\n Object.keys(s._today || {}).forEach(function (k) {\n if (typeof s[k] === 'function') {\n s = s[k](s._today[k]);\n }\n });\n return s;\n};\n\nvar dates = {\n now: function now(s) {\n return getNow(s);\n },\n today: function today(s) {\n return getNow(s);\n },\n tonight: function tonight(s) {\n s = getNow(s);\n s = s.hour(18); //6pm\n\n return s;\n },\n tomorrow: function tomorrow(s) {\n s = getNow(s);\n s = s.add(1, 'day');\n s = s.startOf('day');\n return s;\n },\n yesterday: function yesterday(s) {\n s = getNow(s);\n s = s.subtract(1, 'day');\n s = s.startOf('day');\n return s;\n },\n christmas: function christmas(s) {\n var year = getNow(s).year();\n s = s.set([year, 11, 25, 18, 0, 0]); // Dec 25\n\n return s;\n },\n 'new years': function newYears(s) {\n var year = getNow(s).year();\n s = s.set([year, 11, 31, 18, 0, 0]); // Dec 31\n\n return s;\n }\n};\ndates['new years eve'] = dates['new years'];\nvar namedDates = dates;\n\n// - can't use built-in js parser ;(\n//=========================================\n// ISO Date\t \"2015-03-25\"\n// Short Date\t\"03/25/2015\" or \"2015/03/25\"\n// Long Date\t\"Mar 25 2015\" or \"25 Mar 2015\"\n// Full Date\t\"Wednesday March 25 2015\"\n//=========================================\n//-- also -\n// if the given epoch is really small, they've probably given seconds and not milliseconds\n// anything below this number is likely (but not necessarily) a mistaken input.\n// this may seem like an arbitrary number, but it's 'within jan 1970'\n// this is only really ambiguous until 2054 or so\n\nvar minimumEpoch = 2500000000;\nvar defaults = {\n year: new Date().getFullYear(),\n month: 0,\n date: 1\n}; //support [2016, 03, 01] format\n\nvar handleArray = function handleArray(s, arr, today) {\n var order = ['year', 'month', 'date', 'hour', 'minute', 'second', 'millisecond'];\n\n for (var i = 0; i < order.length; i++) {\n var num = arr[i] || today[order[i]] || defaults[order[i]] || 0;\n s = s[order[i]](num);\n }\n\n return s;\n}; //support {year:2016, month:3} format\n\n\nvar handleObject = function handleObject(s, obj, today) {\n obj = Object.assign({}, defaults, today, obj);\n var keys = Object.keys(obj);\n\n for (var i = 0; i < keys.length; i++) {\n var unit = keys[i]; //make sure we have this method\n\n if (s[unit] === undefined || typeof s[unit] !== 'function') {\n continue;\n } //make sure the value is a number\n\n\n if (obj[unit] === null || obj[unit] === undefined || obj[unit] === '') {\n continue;\n }\n\n var num = obj[unit] || today[unit] || defaults[unit] || 0;\n s = s[unit](num);\n }\n\n return s;\n}; //find the epoch from different input styles\n\n\nvar parseInput = function parseInput(s, input, givenTz) {\n var today = s._today || defaults; //if we've been given a epoch number, it's easy\n\n if (typeof input === 'number') {\n if (input > 0 && input < minimumEpoch && s.silent === false) {\n console.warn(' - Warning: You are setting the date to January 1970.');\n console.warn(' - did input seconds instead of milliseconds?');\n }\n\n s.epoch = input;\n return s;\n } //set tmp time\n\n\n s.epoch = Date.now(); // overwrite tmp time with 'today' value, if exists\n\n if (s._today && fns.isObject(s._today) && Object.keys(s._today).length > 0) {\n var res = handleObject(s, today, defaults);\n\n if (res.isValid()) {\n s.epoch = res.epoch;\n }\n } // null input means 'now'\n\n\n if (input === null || input === undefined || input === '') {\n return s; //k, we're good.\n } //support input of Date() object\n\n\n if (fns.isDate(input) === true) {\n s.epoch = input.getTime();\n return s;\n } //support [2016, 03, 01] format\n\n\n if (fns.isArray(input) === true) {\n s = handleArray(s, input, today);\n return s;\n } //support {year:2016, month:3} format\n\n\n if (fns.isObject(input) === true) {\n //support spacetime object as input\n if (input.epoch) {\n s.epoch = input.epoch;\n s.tz = input.tz;\n return s;\n }\n\n s = handleObject(s, input, today);\n return s;\n } //input as a string..\n\n\n if (typeof input !== 'string') {\n return s;\n } //little cleanup..\n\n\n input = input.replace(/\\b(mon|tues|wed|wednes|thu|thurs|fri|sat|satur|sun)(day)?\\b/i, '');\n input = input.replace(/,/g, '');\n input = input.replace(/ +/g, ' ').trim(); //try some known-words, like 'now'\n\n if (namedDates.hasOwnProperty(input) === true) {\n s = namedDates[input](s);\n return s;\n } //try each text-parse template, use the first good result\n\n\n for (var i = 0; i < strParse.length; i++) {\n var m = input.match(strParse[i].reg);\n\n if (m) {\n var _res = strParse[i].parse(s, m, givenTz);\n\n if (_res !== null) {\n return _res;\n }\n }\n }\n\n if (s.silent === false) {\n console.warn(\"Warning: couldn't parse date-string: '\" + input + \"'\");\n }\n\n s.epoch = null;\n return s;\n};\n\nvar input = parseInput;\n\nvar shortDays = ['sun', 'mon', 'tue', 'wed', 'thu', 'fri', 'sat'];\nvar longDays = ['sunday', 'monday', 'tuesday', 'wednesday', 'thursday', 'friday', 'saturday'];\nvar days = {\n \"short\": function short() {\n return shortDays;\n },\n \"long\": function long() {\n return longDays;\n },\n set: function set(i18n) {\n shortDays = i18n[\"short\"] || shortDays;\n longDays = i18n[\"long\"] || longDays;\n }\n};\n\n// it's kind of nuts how involved this is\n// \"+01:00\", \"+0100\", or simply \"+01\"\n\nvar isoOffset = function isoOffset(s) {\n var offset = s.timezone().current.offset;\n var isNegative = offset < 0;\n var minute = '00'; //handle 5.5 → '5:30'\n\n if (Math.abs(offset % 1) === 0.5) {\n minute = '30';\n\n if (offset >= 0) {\n offset = Math.floor(offset);\n } else {\n offset = Math.ceil(offset);\n }\n }\n\n if (isNegative) {\n //handle negative sign\n offset *= -1;\n offset = fns.zeroPad(offset, 2);\n offset = '-' + offset;\n } else {\n offset = fns.zeroPad(offset, 2);\n offset = '+' + offset;\n }\n\n offset = offset + ':' + minute; //'Z' means 00\n\n if (offset === '+00:00') {\n offset = 'Z';\n }\n\n return offset;\n};\n\nvar _offset = isoOffset;\n\nvar format = {\n day: function day(s) {\n return fns.titleCase(s.dayName());\n },\n 'day-short': function dayShort(s) {\n return fns.titleCase(days[\"short\"]()[s.day()]);\n },\n 'day-number': function dayNumber(s) {\n return s.day();\n },\n 'day-ordinal': function dayOrdinal(s) {\n return fns.ordinal(s.day());\n },\n 'day-pad': function dayPad(s) {\n return fns.zeroPad(s.day());\n },\n date: function date(s) {\n return s.date();\n },\n 'date-ordinal': function dateOrdinal(s) {\n return fns.ordinal(s.date());\n },\n 'date-pad': function datePad(s) {\n return fns.zeroPad(s.date());\n },\n month: function month(s) {\n return fns.titleCase(s.monthName());\n },\n 'month-short': function monthShort(s) {\n return fns.titleCase(months[\"short\"]()[s.month()]);\n },\n 'month-number': function monthNumber(s) {\n return s.month();\n },\n 'month-ordinal': function monthOrdinal(s) {\n return fns.ordinal(s.month());\n },\n 'month-pad': function monthPad(s) {\n return fns.zeroPad(s.month());\n },\n 'iso-month': function isoMonth(s) {\n return fns.zeroPad(s.month() + 1);\n },\n //1-based months\n year: function year(s) {\n var year = s.year();\n\n if (year > 0) {\n return year;\n }\n\n year = Math.abs(year);\n return year + ' BC';\n },\n 'year-short': function yearShort(s) {\n var year = s.year();\n\n if (year > 0) {\n return \"'\".concat(String(s.year()).substr(2, 4));\n }\n\n year = Math.abs(year);\n return year + ' BC';\n },\n 'iso-year': function isoYear(s) {\n var year = s.year();\n var isNegative = year < 0;\n var str = fns.zeroPad(Math.abs(year), 4); //0-padded\n\n if (isNegative) {\n //negative years are for some reason 6-digits ('-00008')\n str = fns.zeroPad(str, 6);\n str = '-' + str;\n }\n\n return str;\n },\n time: function time(s) {\n return s.time();\n },\n 'time-24': function time24(s) {\n return \"\".concat(s.hour24(), \":\").concat(fns.zeroPad(s.minute()));\n },\n hour: function hour(s) {\n return s.hour12();\n },\n 'hour-pad': function hourPad(s) {\n return fns.zeroPad(s.hour12());\n },\n 'hour-24': function hour24(s) {\n return s.hour24();\n },\n 'hour-24-pad': function hour24Pad(s) {\n return fns.zeroPad(s.hour24());\n },\n minute: function minute(s) {\n return s.minute();\n },\n 'minute-pad': function minutePad(s) {\n return fns.zeroPad(s.minute());\n },\n second: function second(s) {\n return s.second();\n },\n 'second-pad': function secondPad(s) {\n return fns.zeroPad(s.second());\n },\n ampm: function ampm(s) {\n return s.ampm();\n },\n quarter: function quarter(s) {\n return 'Q' + s.quarter();\n },\n season: function season(s) {\n return s.season();\n },\n era: function era(s) {\n return s.era();\n },\n json: function json(s) {\n return s.json();\n },\n timezone: function timezone(s) {\n return s.timezone().name;\n },\n offset: function offset(s) {\n return _offset(s);\n },\n numeric: function numeric(s) {\n return \"\".concat(s.year(), \"/\").concat(fns.zeroPad(s.month() + 1), \"/\").concat(fns.zeroPad(s.date()));\n },\n // yyyy/mm/dd\n 'numeric-us': function numericUs(s) {\n return \"\".concat(fns.zeroPad(s.month() + 1), \"/\").concat(fns.zeroPad(s.date()), \"/\").concat(s.year());\n },\n // mm/dd/yyyy\n 'numeric-uk': function numericUk(s) {\n return \"\".concat(fns.zeroPad(s.date()), \"/\").concat(fns.zeroPad(s.month() + 1), \"/\").concat(s.year());\n },\n //dd/mm/yyyy\n 'mm/dd': function mmDd(s) {\n return \"\".concat(fns.zeroPad(s.month() + 1), \"/\").concat(fns.zeroPad(s.date()));\n },\n //mm/dd\n // ... https://en.wikipedia.org/wiki/ISO_8601 ;(((\n iso: function iso(s) {\n var year = s.format('iso-year');\n var month = fns.zeroPad(s.month() + 1); //1-based months\n\n var date = fns.zeroPad(s.date());\n var hour = fns.zeroPad(s.h24());\n var minute = fns.zeroPad(s.minute());\n var second = fns.zeroPad(s.second());\n var ms = fns.zeroPad(s.millisecond(), 3);\n var offset = _offset(s);\n return \"\".concat(year, \"-\").concat(month, \"-\").concat(date, \"T\").concat(hour, \":\").concat(minute, \":\").concat(second, \".\").concat(ms).concat(offset); //2018-03-09T08:50:00.000-05:00\n },\n 'iso-short': function isoShort(s) {\n var month = fns.zeroPad(s.month() + 1); //1-based months\n\n var date = fns.zeroPad(s.date());\n return \"\".concat(s.year(), \"-\").concat(month, \"-\").concat(date); //2017-02-15\n },\n 'iso-utc': function isoUtc(s) {\n return new Date(s.epoch).toISOString(); //2017-03-08T19:45:28.367Z\n },\n //i made these up\n nice: function nice(s) {\n return \"\".concat(months[\"short\"]()[s.month()], \" \").concat(fns.ordinal(s.date()), \", \").concat(s.time());\n },\n 'nice-year': function niceYear(s) {\n return \"\".concat(months[\"short\"]()[s.month()], \" \").concat(fns.ordinal(s.date()), \", \").concat(s.year());\n },\n 'nice-day': function niceDay(s) {\n return \"\".concat(days[\"short\"]()[s.day()], \" \").concat(fns.titleCase(months[\"short\"]()[s.month()]), \" \").concat(fns.ordinal(s.date()));\n },\n 'nice-full': function niceFull(s) {\n return \"\".concat(s.dayName(), \" \").concat(fns.titleCase(s.monthName()), \" \").concat(fns.ordinal(s.date()), \", \").concat(s.time());\n }\n}; //aliases\n\nvar aliases = {\n 'day-name': 'day',\n 'month-name': 'month',\n 'iso 8601': 'iso',\n 'time-h24': 'time-24',\n 'time-12': 'time',\n 'time-h12': 'time',\n tz: 'timezone',\n 'day-num': 'day-number',\n 'month-num': 'month-number',\n 'month-iso': 'iso-month',\n 'year-iso': 'iso-year',\n 'nice-short': 'nice',\n mdy: 'numeric-us',\n dmy: 'numeric-uk',\n ymd: 'numeric',\n 'yyyy/mm/dd': 'numeric',\n 'mm/dd/yyyy': 'numeric-us',\n 'dd/mm/yyyy': 'numeric-us',\n 'little-endian': 'numeric-uk',\n 'big-endian': 'numeric',\n 'day-nice': 'nice-day'\n};\nObject.keys(aliases).forEach(function (k) {\n return format[k] = format[aliases[k]];\n});\n\nvar printFormat = function printFormat(s) {\n var str = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';\n\n //don't print anything if it's an invalid date\n if (s.isValid() !== true) {\n return '';\n } //support .format('month')\n\n\n if (format.hasOwnProperty(str)) {\n var out = format[str](s) || '';\n\n if (str !== 'json') {\n out = String(out);\n\n if (str !== 'ampm') {\n out = fns.titleCase(out);\n }\n }\n\n return out;\n } //support '{hour}:{minute}' notation\n\n\n if (str.indexOf('{') !== -1) {\n var sections = /\\{(.+?)\\}/g;\n str = str.replace(sections, function (_, fmt) {\n fmt = fmt.toLowerCase().trim();\n\n if (format.hasOwnProperty(fmt)) {\n return String(format[fmt](s));\n }\n\n return '';\n });\n return str;\n }\n\n return s.format('iso-short');\n};\n\nvar format_1 = printFormat;\n\nvar pad = fns.zeroPad;\nvar formatTimezone = fns.formatTimezone; //parse this insane unix-time-templating thing, from the 19th century\n//http://unicode.org/reports/tr35/tr35-25.html#Date_Format_Patterns\n//time-symbols we support\n\nvar mapping = {\n G: function G(s) {\n return s.era();\n },\n GG: function GG(s) {\n return s.era();\n },\n GGG: function GGG(s) {\n return s.era();\n },\n GGGG: function GGGG(s) {\n return s.era() === 'AD' ? 'Anno Domini' : 'Before Christ';\n },\n //year\n y: function y(s) {\n return s.year();\n },\n yy: function yy(s) {\n //last two chars\n return parseInt(String(s.year()).substr(2, 4), 10);\n },\n yyy: function yyy(s) {\n return s.year();\n },\n yyyy: function yyyy(s) {\n return s.year();\n },\n yyyyy: function yyyyy(s) {\n return '0' + s.year();\n },\n // u: (s) => {},//extended non-gregorian years\n //quarter\n Q: function Q(s) {\n return s.quarter();\n },\n QQ: function QQ(s) {\n return s.quarter();\n },\n QQQ: function QQQ(s) {\n return s.quarter();\n },\n QQQQ: function QQQQ(s) {\n return s.quarter();\n },\n //month\n M: function M(s) {\n return s.month() + 1;\n },\n MM: function MM(s) {\n return pad(s.month() + 1);\n },\n MMM: function MMM(s) {\n return s.format('month-short');\n },\n MMMM: function MMMM(s) {\n return s.format('month');\n },\n //week\n w: function w(s) {\n return s.week();\n },\n ww: function ww(s) {\n return pad(s.week());\n },\n //week of month\n // W: (s) => s.week(),\n //date of month\n d: function d(s) {\n return s.date();\n },\n dd: function dd(s) {\n return pad(s.date());\n },\n //date of year\n D: function D(s) {\n return s.dayOfYear();\n },\n DD: function DD(s) {\n return pad(s.dayOfYear());\n },\n DDD: function DDD(s) {\n return pad(s.dayOfYear(), 3);\n },\n // F: (s) => {},//date of week in month\n // g: (s) => {},//modified julian day\n //day\n E: function E(s) {\n return s.format('day-short');\n },\n EE: function EE(s) {\n return s.format('day-short');\n },\n EEE: function EEE(s) {\n return s.format('day-short');\n },\n EEEE: function EEEE(s) {\n return s.format('day');\n },\n EEEEE: function EEEEE(s) {\n return s.format('day')[0];\n },\n e: function e(s) {\n return s.day();\n },\n ee: function ee(s) {\n return s.day();\n },\n eee: function eee(s) {\n return s.format('day-short');\n },\n eeee: function eeee(s) {\n return s.format('day');\n },\n eeeee: function eeeee(s) {\n return s.format('day')[0];\n },\n //am/pm\n a: function a(s) {\n return s.ampm().toUpperCase();\n },\n aa: function aa(s) {\n return s.ampm().toUpperCase();\n },\n aaa: function aaa(s) {\n return s.ampm().toUpperCase();\n },\n aaaa: function aaaa(s) {\n return s.ampm().toUpperCase();\n },\n //hour\n h: function h(s) {\n return s.h12();\n },\n hh: function hh(s) {\n return pad(s.h12());\n },\n H: function H(s) {\n return s.hour();\n },\n HH: function HH(s) {\n return pad(s.hour());\n },\n // j: (s) => {},//weird hour format\n m: function m(s) {\n return s.minute();\n },\n mm: function mm(s) {\n return pad(s.minute());\n },\n s: function s(_s) {\n return _s.second();\n },\n ss: function ss(s) {\n return pad(s.second());\n },\n //milliseconds in the day\n A: function A(s) {\n return s.epoch - s.startOf('day').epoch;\n },\n //timezone\n z: function z(s) {\n return s.timezone().name;\n },\n zz: function zz(s) {\n return s.timezone().name;\n },\n zzz: function zzz(s) {\n return s.timezone().name;\n },\n zzzz: function zzzz(s) {\n return s.timezone().name;\n },\n Z: function Z(s) {\n return formatTimezone(s.timezone().current.offset);\n },\n ZZ: function ZZ(s) {\n return formatTimezone(s.timezone().current.offset);\n },\n ZZZ: function ZZZ(s) {\n return formatTimezone(s.timezone().current.offset);\n },\n ZZZZ: function ZZZZ(s) {\n return formatTimezone(s.timezone().current.offset, ':');\n }\n};\n\nvar addAlias = function addAlias(_char, to, n) {\n var name = _char;\n var toName = to;\n\n for (var i = 0; i < n; i += 1) {\n mapping[name] = mapping[toName];\n name += _char;\n toName += to;\n }\n};\n\naddAlias('q', 'Q', 4);\naddAlias('L', 'M', 4);\naddAlias('Y', 'y', 4);\naddAlias('c', 'e', 4);\naddAlias('k', 'H', 2);\naddAlias('K', 'h', 2);\naddAlias('S', 's', 2);\naddAlias('v', 'z', 4);\naddAlias('V', 'Z', 4);\n\nvar unixFmt = function unixFmt(s, str) {\n var chars = str.split(''); //combine consecutive chars, like 'yyyy' as one.\n\n var arr = [chars[0]];\n var quoteOn = false;\n\n for (var i = 1; i < chars.length; i += 1) {\n //support quoted substrings\n if (chars[i] === \"'\") {\n quoteOn = !quoteOn; //support '', meaning one tick\n\n if (quoteOn === true && chars[i + 1] && chars[i + 1] === \"'\") {\n quoteOn = true;\n } else {\n continue;\n }\n } //merge it with the last one\n\n\n if (quoteOn === true || chars[i] === arr[arr.length - 1][0]) {\n arr[arr.length - 1] += chars[i];\n } else {\n arr.push(chars[i]);\n }\n }\n\n return arr.reduce(function (txt, c) {\n if (mapping[c] !== undefined) {\n txt += mapping[c](s) || '';\n } else {\n txt += c;\n }\n\n return txt;\n }, '');\n};\n\nvar unixFmt_1 = unixFmt;\n\nvar units$1 = ['year', 'season', 'quarter', 'month', 'week', 'day', 'quarterHour', 'hour', 'minute'];\n\nvar doUnit = function doUnit(s, k) {\n var start = s.clone().startOf(k);\n var end = s.clone().endOf(k);\n var duration = end.epoch - start.epoch;\n var percent = (s.epoch - start.epoch) / duration;\n return parseFloat(percent.toFixed(2));\n}; //how far it is along, from 0-1\n\n\nvar progress = function progress(s, unit) {\n if (unit) {\n unit = fns.normalize(unit);\n return doUnit(s, unit);\n }\n\n var obj = {};\n units$1.forEach(function (k) {\n obj[k] = doUnit(s, k);\n });\n return obj;\n};\n\nvar progress_1 = progress;\n\nvar nearest = function nearest(s, unit) {\n //how far have we gone?\n var prog = s.progress();\n unit = fns.normalize(unit); //fix camel-case for this one\n\n if (unit === 'quarterhour') {\n unit = 'quarterHour';\n }\n\n if (prog[unit] !== undefined) {\n // go forward one?\n if (prog[unit] > 0.5) {\n s = s.add(1, unit);\n } // go to start\n\n\n s = s.startOf(unit);\n } else if (s.silent === false) {\n console.warn(\"no known unit '\" + unit + \"'\");\n }\n\n return s;\n};\n\nvar nearest_1 = nearest;\n\n//increment until dates are the same\nvar climb = function climb(a, b, unit) {\n var i = 0;\n a = a.clone();\n\n while (a.isBefore(b)) {\n //do proper, expensive increment to catch all-the-tricks\n a = a.add(1, unit);\n i += 1;\n } //oops, we went too-far..\n\n\n if (a.isAfter(b, unit)) {\n i -= 1;\n }\n\n return i;\n}; // do a thurough +=1 on the unit, until they match\n// for speed-reasons, only used on day, month, week.\n\n\nvar diffOne = function diffOne(a, b, unit) {\n if (a.isBefore(b)) {\n return climb(a, b, unit);\n } else {\n return climb(b, a, unit) * -1; //reverse it\n }\n};\n\nvar one = diffOne;\n\n// 2020 - 2019 may be 1 year, or 0 years\n// - '1 year difference' means 366 days during a leap year\n\nvar fastYear = function fastYear(a, b) {\n var years = b.year() - a.year(); // should we decrement it by 1?\n\n a = a.year(b.year());\n\n if (a.isAfter(b)) {\n years -= 1;\n }\n\n return years;\n}; // use a waterfall-method for computing a diff of any 'pre-knowable' units\n// compute years, then compute months, etc..\n// ... then ms-math for any very-small units\n\n\nvar diff = function diff(a, b) {\n // an hour is always the same # of milliseconds\n // so these units can be 'pre-calculated'\n var msDiff = b.epoch - a.epoch;\n var obj = {\n milliseconds: msDiff,\n seconds: parseInt(msDiff / 1000, 10)\n };\n obj.minutes = parseInt(obj.seconds / 60, 10);\n obj.hours = parseInt(obj.minutes / 60, 10); //do the year\n\n var tmp = a.clone();\n obj.years = fastYear(tmp, b);\n tmp = a.add(obj.years, 'year'); //there's always 12 months in a year...\n\n obj.months = obj.years * 12;\n tmp = a.add(obj.months, 'month');\n obj.months += one(tmp, b, 'month'); // there's always atleast 52 weeks in a year..\n // (month * 4) isn't as close\n\n obj.weeks = obj.years * 52;\n tmp = a.add(obj.weeks, 'week');\n obj.weeks += one(tmp, b, 'week'); // there's always atleast 7 days in a week\n\n obj.days = obj.weeks * 7;\n tmp = a.add(obj.days, 'day');\n obj.days += one(tmp, b, 'day');\n return obj;\n};\n\nvar waterfall = diff;\n\nvar reverseDiff = function reverseDiff(obj) {\n Object.keys(obj).forEach(function (k) {\n obj[k] *= -1;\n });\n return obj;\n}; // this method counts a total # of each unit, between a, b.\n// '1 month' means 28 days in february\n// '1 year' means 366 days in a leap year\n\n\nvar main = function main(a, b, unit) {\n b = fns.beADate(b, a); //reverse values, if necessary\n\n var reversed = false;\n\n if (a.isAfter(b)) {\n var tmp = a;\n a = b;\n b = tmp;\n reversed = true;\n } //compute them all (i know!)\n\n\n var obj = waterfall(a, b);\n\n if (reversed) {\n obj = reverseDiff(obj);\n } //return just the requested unit\n\n\n if (unit) {\n //make sure it's plural-form\n unit = fns.normalize(unit);\n\n if (/s$/.test(unit) !== true) {\n unit += 's';\n }\n\n if (unit === 'dates') {\n unit = 'days';\n }\n\n return obj[unit];\n }\n\n return obj;\n};\n\nvar diff$1 = main;\n\n//our conceptual 'break-points' for each unit\n\nvar qualifiers = {\n months: {\n almost: 10,\n over: 4\n },\n days: {\n almost: 25,\n over: 10\n },\n hours: {\n almost: 20,\n over: 8\n },\n minutes: {\n almost: 50,\n over: 20\n },\n seconds: {\n almost: 50,\n over: 20\n }\n}; //get number of hours/minutes... between the two dates\n\nfunction getDiff(a, b) {\n var isBefore = a.isBefore(b);\n var later = isBefore ? b : a;\n var earlier = isBefore ? a : b;\n earlier = earlier.clone();\n var diff = {\n years: 0,\n months: 0,\n days: 0,\n hours: 0,\n minutes: 0,\n seconds: 0\n };\n Object.keys(diff).forEach(function (unit) {\n if (earlier.isSame(later, unit)) {\n return;\n }\n\n var max = earlier.diff(later, unit);\n earlier = earlier.add(max, unit);\n diff[unit] = max;\n }); //reverse it, if necessary\n\n if (isBefore) {\n Object.keys(diff).forEach(function (u) {\n if (diff[u] !== 0) {\n diff[u] *= -1;\n }\n });\n }\n\n return diff;\n} // Expects a plural unit arg\n\n\nfunction pluralize(value, unit) {\n if (value === 1) {\n unit = unit.slice(0, -1);\n }\n\n return value + ' ' + unit;\n} //create the human-readable diff between the two dates\n\n\nvar since = function since(start, end) {\n end = fns.beADate(end, start);\n var diff = getDiff(start, end);\n var isNow = Object.keys(diff).every(function (u) {\n return !diff[u];\n });\n\n if (isNow === true) {\n return {\n diff: diff,\n rounded: 'now',\n qualified: 'now',\n precise: 'now'\n };\n }\n\n var rounded;\n var qualified;\n var precise;\n var englishValues = []; //go through each value and create its text-representation\n\n Object.keys(diff).forEach(function (unit, i, units) {\n var value = Math.abs(diff[unit]);\n\n if (value === 0) {\n return;\n }\n\n var englishValue = pluralize(value, unit);\n englishValues.push(englishValue);\n\n if (!rounded) {\n rounded = qualified = englishValue;\n\n if (i > 4) {\n return;\n } //is it a 'almost' something, etc?\n\n\n var nextUnit = units[i + 1];\n var nextValue = Math.abs(diff[nextUnit]);\n\n if (nextValue > qualifiers[nextUnit].almost) {\n rounded = pluralize(value + 1, unit);\n qualified = 'almost ' + rounded;\n } else if (nextValue > qualifiers[nextUnit].over) qualified = 'over ' + englishValue;\n }\n }); //make them into a string\n\n precise = englishValues.splice(0, 2).join(', '); //handle before/after logic\n\n if (start.isAfter(end) === true) {\n rounded += ' ago';\n qualified += ' ago';\n precise += ' ago';\n } else {\n rounded = 'in ' + rounded;\n qualified = 'in ' + qualified;\n precise = 'in ' + precise;\n }\n\n return {\n diff: diff,\n rounded: rounded,\n qualified: qualified,\n precise: precise\n };\n};\n\nvar since_1 = since;\n\n//https://www.timeanddate.com/calendar/aboutseasons.html\n// Spring - from March 1 to May 31;\n// Summer - from June 1 to August 31;\n// Fall (autumn) - from September 1 to November 30; and,\n// Winter - from December 1 to February 28 (February 29 in a leap year).\nvar seasons = {\n north: [['spring', 2, 1], //spring march 1\n ['summer', 5, 1], //june 1\n ['fall', 8, 1], //sept 1\n ['autumn', 8, 1], //sept 1\n ['winter', 11, 1] //dec 1\n ],\n south: [['fall', 2, 1], //march 1\n ['autumn', 2, 1], //march 1\n ['winter', 5, 1], //june 1\n ['spring', 8, 1], //sept 1\n ['summer', 11, 1] //dec 1\n ]\n};\n\nvar quarters = [null, [0, 1], //jan 1\n[3, 1], //apr 1\n[6, 1], //july 1\n[9, 1] //oct 1\n];\n\nvar units$2 = {\n minute: function minute(s) {\n walk_1(s, {\n second: 0,\n millisecond: 0\n });\n return s;\n },\n quarterhour: function quarterhour(s) {\n var minute = s.minutes();\n\n if (minute >= 45) {\n s = s.minutes(45);\n } else if (minute >= 30) {\n s = s.minutes(30);\n } else if (minute >= 15) {\n s = s.minutes(15);\n } else {\n s = s.minutes(0);\n }\n\n walk_1(s, {\n second: 0,\n millisecond: 0\n });\n return s;\n },\n hour: function hour(s) {\n walk_1(s, {\n minute: 0,\n second: 0,\n millisecond: 0\n });\n return s;\n },\n day: function day(s) {\n walk_1(s, {\n hour: 0,\n minute: 0,\n second: 0,\n millisecond: 0\n });\n return s;\n },\n week: function week(s) {\n var original = s.clone();\n s = s.day(s._weekStart); //monday\n\n if (s.isAfter(original)) {\n s = s.subtract(1, 'week');\n }\n\n walk_1(s, {\n hour: 0,\n minute: 0,\n second: 0,\n millisecond: 0\n });\n return s;\n },\n month: function month(s) {\n walk_1(s, {\n date: 1,\n hour: 0,\n minute: 0,\n second: 0,\n millisecond: 0\n });\n return s;\n },\n quarter: function quarter(s) {\n var q = s.quarter();\n\n if (quarters[q]) {\n walk_1(s, {\n month: quarters[q][0],\n date: quarters[q][1],\n hour: 0,\n minute: 0,\n second: 0,\n millisecond: 0\n });\n }\n\n return s;\n },\n season: function season(s) {\n var current = s.season();\n var hem = 'north';\n\n if (s.hemisphere() === 'South') {\n hem = 'south';\n }\n\n for (var i = 0; i < seasons[hem].length; i++) {\n if (seasons[hem][i][0] === current) {\n //winter goes between years\n var year = s.year();\n\n if (current === 'winter' && s.month() < 3) {\n year -= 1;\n }\n\n walk_1(s, {\n year: year,\n month: seasons[hem][i][1],\n date: seasons[hem][i][2],\n hour: 0,\n minute: 0,\n second: 0,\n millisecond: 0\n });\n return s;\n }\n }\n\n return s;\n },\n year: function year(s) {\n walk_1(s, {\n month: 0,\n date: 1,\n hour: 0,\n minute: 0,\n second: 0,\n millisecond: 0\n });\n return s;\n },\n decade: function decade(s) {\n s = s.startOf('year');\n var year = s.year();\n var decade = parseInt(year / 10, 10) * 10;\n s = s.year(decade);\n return s;\n },\n century: function century(s) {\n s = s.startOf('year');\n var year = s.year(); // near 0AD goes '-1 | +1'\n\n var decade = parseInt(year / 100, 10) * 100;\n s = s.year(decade);\n return s;\n }\n};\nunits$2.date = units$2.day;\n\nvar startOf = function startOf(a, unit) {\n var s = a.clone();\n unit = fns.normalize(unit);\n\n if (units$2[unit]) {\n return units$2[unit](s);\n }\n\n if (unit === 'summer' || unit === 'winter') {\n s = s.season(unit);\n return units$2.season(s);\n }\n\n return s;\n}; //piggy-backs off startOf\n\n\nvar endOf = function endOf(a, unit) {\n var s = a.clone();\n unit = fns.normalize(unit);\n\n if (units$2[unit]) {\n s = units$2[unit](s);\n s = s.add(1, unit);\n s = s.subtract(1, 'milliseconds');\n return s;\n }\n\n return s;\n};\n\nvar startOf_1 = {\n startOf: startOf,\n endOf: endOf\n};\n\nvar isDay = function isDay(unit) {\n if (days[\"short\"]().find(function (s) {\n return s === unit;\n })) {\n return true;\n }\n\n if (days[\"long\"]().find(function (s) {\n return s === unit;\n })) {\n return true;\n }\n\n return false;\n}; // return a list of the weeks/months/days between a -> b\n// returns spacetime objects in the timezone of the input\n\n\nvar every = function every(start) {\n var unit = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';\n var end = arguments.length > 2 ? arguments[2] : undefined;\n\n if (!unit || !end) {\n return [];\n } //cleanup unit param\n\n\n unit = fns.normalize(unit); //cleanup to param\n\n end = start.clone().set(end); //swap them, if they're backwards\n\n if (start.isAfter(end)) {\n var tmp = start;\n start = end;\n end = tmp;\n } //support 'every wednesday'\n\n\n var d = start.clone();\n\n if (isDay(unit)) {\n d = d.next(unit);\n unit = 'week';\n } else {\n d = d.next(unit);\n } //okay, actually start doing it\n\n\n var result = [];\n\n while (d.isBefore(end)) {\n result.push(d);\n d = d.add(1, unit);\n }\n\n return result;\n};\n\nvar every_1 = every;\n\nvar parseDst = function parseDst(dst) {\n if (!dst) {\n return [];\n }\n\n return dst.split('->');\n};\n\nvar titleCase = function titleCase(str) {\n str = str[0].toUpperCase() + str.substr(1);\n str = str.replace(/\\/gmt/, '/GMT');\n str = str.replace(/[\\/_]([a-z])/gi, function (s) {\n return s.toUpperCase();\n });\n return str;\n}; //get metadata about this timezone\n\n\nvar timezone = function timezone(s) {\n var zones = s.timezones;\n var tz = s.tz;\n\n if (zones.hasOwnProperty(tz) === false) {\n tz = find(s.tz, zones);\n }\n\n if (tz === null) {\n if (s.silent === false) {\n console.warn(\"Warn: could not find given or local timezone - '\" + s.tz + \"'\");\n }\n\n return {\n current: {\n epochShift: 0\n }\n };\n }\n\n var found = zones[tz];\n var result = {\n name: titleCase(tz),\n hasDst: Boolean(found.dst),\n default_offset: found.offset,\n //do north-hemisphere version as default (sorry!)\n hemisphere: found.hem === 's' ? 'South' : 'North',\n current: {}\n };\n\n if (result.hasDst) {\n var arr = parseDst(found.dst);\n result.change = {\n start: arr[0],\n back: arr[1]\n };\n } //find the offsets for summer/winter times\n //(these variable names are north-centric)\n\n\n var summer = found.offset; // (july)\n\n var winter = summer; // (january) assume it's the same for now\n\n if (result.hasDst === true) {\n if (result.hemisphere === 'North') {\n winter = summer - 1;\n } else {\n //southern hemisphere\n winter = found.offset + 1;\n }\n } //find out which offset to use right now\n //use 'summer' time july-time\n\n\n if (result.hasDst === false) {\n result.current.offset = summer;\n result.current.isDST = false;\n } else if (summerTime(s.epoch, result.change.start, result.change.back, summer) === true) {\n result.current.offset = summer;\n result.current.isDST = result.hemisphere === 'North'; //dst 'on' in winter in north\n } else {\n //use 'winter' january-time\n result.current.offset = winter;\n result.current.isDST = result.hemisphere === 'South'; //dst 'on' in summer in south\n }\n\n return result;\n};\n\nvar timezone_1 = timezone;\n\nvar units$3 = ['century', 'decade', 'year', 'month', 'date', 'day', 'hour', 'minute', 'second', 'millisecond']; //the spacetime instance methods (also, the API)\n\nvar methods = {\n set: function set(input$1, tz) {\n var s = this.clone();\n s = input(s, input$1, null);\n\n if (tz) {\n this.tz = find(tz);\n }\n\n return s;\n },\n timezone: function timezone() {\n return timezone_1(this);\n },\n isDST: function isDST() {\n return timezone_1(this).current.isDST;\n },\n hasDST: function hasDST() {\n return timezone_1(this).hasDst;\n },\n offset: function offset() {\n return timezone_1(this).current.offset * 60;\n },\n hemisphere: function hemisphere() {\n return timezone_1(this).hemisphere;\n },\n format: function format(fmt) {\n return format_1(this, fmt);\n },\n unixFmt: function unixFmt(fmt) {\n return unixFmt_1(this, fmt);\n },\n startOf: function startOf(unit) {\n return startOf_1.startOf(this, unit);\n },\n endOf: function endOf(unit) {\n return startOf_1.endOf(this, unit);\n },\n leapYear: function leapYear() {\n var year = this.year();\n return fns.isLeapYear(year);\n },\n progress: function progress(unit) {\n return progress_1(this, unit);\n },\n nearest: function nearest(unit) {\n return nearest_1(this, unit);\n },\n diff: function diff(d, unit) {\n return diff$1(this, d, unit);\n },\n since: function since(d) {\n if (!d) {\n d = this.clone().set();\n }\n\n return since_1(this, d);\n },\n next: function next(unit) {\n var s = this.add(1, unit);\n return s.startOf(unit);\n },\n //the start of the previous year/week/century\n last: function last(unit) {\n var s = this.subtract(1, unit);\n return s.startOf(unit);\n },\n isValid: function isValid() {\n //null/undefined epochs\n if (!this.epoch && this.epoch !== 0) {\n return false;\n }\n\n return !isNaN(this.d.getTime());\n },\n //travel to this timezone\n \"goto\": function goto(tz) {\n var s = this.clone();\n s.tz = find(tz, s.timezones); //science!\n\n return s;\n },\n //get each week/month/day between a -> b\n every: function every(unit, to) {\n return every_1(this, unit, to);\n },\n isAwake: function isAwake() {\n var hour = this.hour(); //10pm -> 8am\n\n if (hour < 8 || hour > 22) {\n return false;\n }\n\n return true;\n },\n isAsleep: function isAsleep() {\n return !this.isAwake();\n },\n //pretty-printing\n log: function log() {\n console.log('');\n console.log(format_1(this, 'nice-short'));\n return this;\n },\n logYear: function logYear() {\n console.log('');\n console.log(format_1(this, 'full-short'));\n return this;\n },\n json: function json() {\n var _this = this;\n\n return units$3.reduce(function (h, unit) {\n h[unit] = _this[unit]();\n return h;\n }, {});\n },\n debug: function debug() {\n var tz = this.timezone();\n var date = this.format('MM') + ' ' + this.format('date-ordinal') + ' ' + this.year();\n date += '\\n - ' + this.format('time');\n console.log('\\n\\n', date + '\\n - ' + tz.name + ' (' + tz.current.offset + ')');\n return this;\n },\n //alias of 'since' but opposite - like moment.js\n from: function from(d) {\n d = this.clone().set(d);\n return d.since(this);\n },\n fromNow: function fromNow() {\n var d = this.clone().set(Date.now());\n return d.since(this);\n },\n weekStart: function weekStart(input) {\n //accept a number directly\n if (typeof input === 'number') {\n this._weekStart = input;\n return this;\n }\n\n if (typeof input === 'string') {\n // accept 'wednesday'\n input = input.toLowerCase().trim();\n var num = days[\"short\"]().indexOf(input);\n\n if (num === -1) {\n num = days[\"long\"]().indexOf(input);\n }\n\n if (num === -1) {\n num = 1; //go back to default\n }\n\n this._weekStart = num;\n } else {\n console.warn('Spacetime Error: Cannot understand .weekStart() input:', input);\n }\n\n return this;\n }\n}; // aliases\n\nmethods.inDST = methods.isDST;\nmethods.round = methods.nearest;\nmethods.each = methods.every;\nvar methods_1 = methods;\n\n//these methods wrap around them.\n\nvar isLeapYear$1 = fns.isLeapYear;\n\nvar validate = function validate(n) {\n //handle number as a string\n if (typeof n === 'string') {\n n = parseInt(n, 10);\n }\n\n return n;\n};\n\nvar order = ['year', 'month', 'date', 'hour', 'minute', 'second', 'millisecond']; //reduce hostile micro-changes when moving dates by millisecond\n\nvar confirm = function confirm(s, tmp, unit) {\n var n = order.indexOf(unit);\n var arr = order.slice(n, order.length);\n\n for (var i = 0; i < arr.length; i++) {\n var want = tmp[arr[i]]();\n s[arr[i]](want);\n }\n\n return s;\n};\n\nvar set = {\n milliseconds: function milliseconds(s, n) {\n n = validate(n);\n var current = s.millisecond();\n var diff = current - n; //milliseconds to shift by\n\n return s.epoch - diff;\n },\n seconds: function seconds(s, n) {\n n = validate(n);\n var diff = s.second() - n;\n var shift = diff * milliseconds.second;\n return s.epoch - shift;\n },\n minutes: function minutes(s, n) {\n n = validate(n);\n var old = s.clone();\n var diff = s.minute() - n;\n var shift = diff * milliseconds.minute;\n s.epoch -= shift; // check against a screw-up\n // if (old.hour() != s.hour()) {\n // walkTo(old, {\n // minute: n\n // })\n // return old.epoch\n // }\n\n confirm(s, old, 'second');\n return s.epoch;\n },\n hours: function hours(s, n) {\n n = validate(n);\n\n if (n >= 24) {\n n = 24;\n } else if (n < 0) {\n n = 0;\n }\n\n var old = s.clone();\n var diff = s.hour() - n;\n var shift = diff * milliseconds.hour;\n s.epoch -= shift;\n walk_1(s, {\n hour: n\n });\n confirm(s, old, 'minute');\n return s.epoch;\n },\n //support setting time by '4:25pm' - this isn't very-well developed..\n time: function time(s, str) {\n var m = str.match(/([0-9]{1,2}):([0-9]{1,2})(am|pm)?/);\n\n if (!m) {\n //fallback to support just '2am'\n m = str.match(/([0-9]{1,2})(am|pm)/);\n\n if (!m) {\n return s.epoch;\n }\n\n m.splice(2, 0, '0'); //add implicit 0 minutes\n }\n\n var h24 = false;\n var hour = parseInt(m[1], 10);\n var minute = parseInt(m[2], 10);\n\n if (hour > 12) {\n h24 = true;\n } //make the hour into proper 24h time\n\n\n if (h24 === false) {\n if (m[3] === 'am' && hour === 12) {\n //12am is midnight\n hour = 0;\n }\n\n if (m[3] === 'pm' && hour < 12) {\n //12pm is noon\n hour += 12;\n }\n }\n\n s = s.hour(hour);\n s = s.minute(minute);\n s = s.second(0);\n s = s.millisecond(0);\n return s.epoch;\n },\n date: function date(s, n) {\n n = validate(n); //avoid setting february 31st\n\n if (n > 28) {\n var month = s.month();\n var max = monthLengths_1[month]; // support leap day in february\n\n if (month === 1 && n === 29 && isLeapYear$1(s.year())) {\n max = 29;\n }\n\n if (n > max) {\n n = max;\n }\n } //avoid setting < 0\n\n\n if (n <= 0) {\n n = 1;\n }\n\n walk_1(s, {\n date: n\n });\n return s.epoch;\n },\n //this one's tricky\n month: function month(s, n) {\n if (typeof n === 'string') {\n n = months.mapping()[n.toLowerCase()];\n }\n\n n = validate(n); //don't go past december\n\n if (n >= 12) {\n n = 11;\n }\n\n if (n <= 0) {\n n = 0;\n }\n\n var date = s.date(); //there's no 30th of february, etc.\n\n if (date > monthLengths_1[n]) {\n //make it as close as we can..\n date = monthLengths_1[n];\n }\n\n walk_1(s, {\n month: n,\n date: date\n });\n return s.epoch;\n },\n year: function year(s, n) {\n n = validate(n);\n walk_1(s, {\n year: n\n });\n return s.epoch;\n },\n dayOfYear: function dayOfYear(s, n) {\n n = validate(n);\n var old = s.clone();\n n -= 1; //days are 1-based\n\n if (n <= 0) {\n n = 0;\n } else if (n >= 365) {\n n = 364;\n }\n\n s = s.startOf('year');\n s = s.add(n, 'day');\n confirm(s, old, 'hour');\n return s.epoch;\n }\n};\n\nvar methods$1 = {\n millisecond: function millisecond(num) {\n if (num !== undefined) {\n var s = this.clone();\n s.epoch = set.milliseconds(s, num);\n return s;\n }\n\n return this.d.getMilliseconds();\n },\n second: function second(num) {\n if (num !== undefined) {\n var s = this.clone();\n s.epoch = set.seconds(s, num);\n return s;\n }\n\n return this.d.getSeconds();\n },\n minute: function minute(num) {\n if (num !== undefined) {\n var s = this.clone();\n s.epoch = set.minutes(s, num);\n return s;\n }\n\n return this.d.getMinutes();\n },\n hour: function hour(num) {\n var d = this.d;\n\n if (num !== undefined) {\n var s = this.clone();\n s.epoch = set.hours(s, num);\n return s;\n }\n\n return d.getHours();\n },\n //'3:30' is 3.5\n hourFloat: function hourFloat(num) {\n if (num !== undefined) {\n var s = this.clone();\n\n var _minute = num % 1;\n\n _minute = _minute * 60;\n\n var _hour = parseInt(num, 10);\n\n s.epoch = set.hours(s, _hour);\n s.epoch = set.minutes(s, _minute);\n return s;\n }\n\n var d = this.d;\n var hour = d.getHours();\n var minute = d.getMinutes();\n minute = minute / 60;\n return hour + minute;\n },\n // hour in 12h format\n hour12: function hour12(str) {\n var d = this.d;\n\n if (str !== undefined) {\n var s = this.clone();\n str = '' + str;\n var m = str.match(/^([0-9]+)(am|pm)$/);\n\n if (m) {\n var hour = parseInt(m[1], 10);\n\n if (m[2] === 'pm') {\n hour += 12;\n }\n\n s.epoch = set.hours(s, hour);\n }\n\n return s;\n } //get the hour\n\n\n var hour12 = d.getHours();\n\n if (hour12 > 12) {\n hour12 = hour12 - 12;\n }\n\n if (hour12 === 0) {\n hour12 = 12;\n }\n\n return hour12;\n },\n //some ambiguity here with 12/24h\n time: function time(str) {\n if (str !== undefined) {\n var s = this.clone();\n s.epoch = set.time(s, str);\n return s;\n }\n\n return \"\".concat(this.h12(), \":\").concat(fns.zeroPad(this.minute())).concat(this.ampm());\n },\n // either 'am' or 'pm'\n ampm: function ampm(input) {\n var which = 'am';\n var hour = this.hour();\n\n if (hour >= 12) {\n which = 'pm';\n }\n\n if (typeof input !== 'string') {\n return which;\n } //okay, we're doing a setter\n\n\n var s = this.clone();\n input = input.toLowerCase().trim(); //ampm should never change the day\n // - so use `.hour(n)` instead of `.minus(12,'hour')`\n\n if (hour >= 12 && input === 'am') {\n //noon is 12pm\n hour -= 12;\n return s.hour(hour);\n }\n\n if (hour < 12 && input === 'pm') {\n hour += 12;\n return s.hour(hour);\n }\n\n return s;\n },\n //some hard-coded times of day, like 'noon'\n dayTime: function dayTime(str) {\n if (str !== undefined) {\n var times = {\n morning: '7:00am',\n breakfast: '7:00am',\n noon: '12:00am',\n lunch: '12:00pm',\n afternoon: '2:00pm',\n evening: '6:00pm',\n dinner: '6:00pm',\n night: '11:00pm',\n midnight: '23:59pm'\n };\n var s = this.clone();\n str = str || '';\n str = str.toLowerCase();\n\n if (times.hasOwnProperty(str) === true) {\n s = s.time(times[str]);\n }\n\n return s;\n }\n\n var h = this.hour();\n\n if (h < 6) {\n return 'night';\n }\n\n if (h < 12) {\n //until noon\n return 'morning';\n }\n\n if (h < 17) {\n //until 5pm\n return 'afternoon';\n }\n\n if (h < 22) {\n //until 10pm\n return 'evening';\n }\n\n return 'night';\n },\n //parse a proper iso string\n iso: function iso(num) {\n if (num !== undefined) {\n return this.set(num);\n }\n\n return this.format('iso');\n }\n};\nvar _01Time = methods$1;\n\nvar methods$2 = {\n // # day in the month\n date: function date(num) {\n if (num !== undefined) {\n var s = this.clone();\n s.epoch = set.date(s, num);\n return s;\n }\n\n return this.d.getDate();\n },\n //like 'wednesday' (hard!)\n day: function day(input) {\n if (input === undefined) {\n return this.d.getDay();\n }\n\n var original = this.clone();\n var want = input; // accept 'wednesday'\n\n if (typeof input === 'string') {\n input = input.toLowerCase();\n want = days[\"short\"]().indexOf(input);\n\n if (want === -1) {\n want = days[\"long\"]().indexOf(input);\n }\n } //move approx\n\n\n var day = this.d.getDay();\n var diff = day - want;\n var s = this.subtract(diff * 24, 'hours'); //tighten it back up\n\n walk_1(s, {\n hour: original.hour(),\n minute: original.minute(),\n second: original.second()\n });\n return s;\n },\n //these are helpful name-wrappers\n dayName: function dayName(input) {\n if (input === undefined) {\n return days[\"long\"]()[this.day()];\n }\n\n var s = this.clone();\n s = s.day(input);\n return s;\n },\n //either name or number\n month: function month(input) {\n if (input !== undefined) {\n var s = this.clone();\n s.epoch = set.month(s, input);\n return s;\n }\n\n return this.d.getMonth();\n }\n};\nvar _02Date = methods$2;\n\nvar clearMinutes = function clearMinutes(s) {\n s = s.minute(0);\n s = s.second(0);\n s = s.millisecond(1);\n return s;\n};\n\nvar methods$3 = {\n // day 0-366\n dayOfYear: function dayOfYear(num) {\n if (num !== undefined) {\n var s = this.clone();\n s.epoch = set.dayOfYear(s, num);\n return s;\n } //days since newyears - jan 1st is 1, jan 2nd is 2...\n\n\n var sum = 0;\n var month = this.d.getMonth();\n var tmp; //count the num days in each month\n\n for (var i = 1; i <= month; i++) {\n tmp = new Date();\n tmp.setDate(1);\n tmp.setFullYear(this.d.getFullYear()); //the year matters, because leap-years\n\n tmp.setHours(1);\n tmp.setMinutes(1);\n tmp.setMonth(i);\n tmp.setHours(-2); //the last day of the month\n\n sum += tmp.getDate();\n }\n\n return sum + this.d.getDate();\n },\n //since the start of the year\n week: function week(num) {\n // week-setter\n if (num !== undefined) {\n var s = this.clone();\n s = s.month(0);\n s = s.date(1);\n s = s.day('monday');\n s = clearMinutes(s); //don't go into last-year\n\n if (s.monthName() === 'december') {\n s = s.add(1, 'week');\n }\n\n num -= 1; //1-based\n\n s = s.add(num, 'weeks');\n return s;\n } //find-out which week it is\n\n\n var tmp = this.clone();\n tmp = tmp.month(0);\n tmp = tmp.date(1);\n tmp = clearMinutes(tmp);\n tmp = tmp.day('monday'); //don't go into last-year\n\n if (tmp.monthName() === 'december') {\n tmp = tmp.add(1, 'week');\n } // is first monday the 1st?\n\n\n var toAdd = 1;\n\n if (tmp.date() === 1) {\n toAdd = 0;\n }\n\n tmp = tmp.minus(1, 'second');\n var thisOne = this.epoch; //if the week technically hasn't started yet\n\n if (tmp.epoch > thisOne) {\n return 1;\n } //speed it up, if we can\n\n\n var i = 0;\n var skipWeeks = this.month() * 4;\n tmp.epoch += milliseconds.week * skipWeeks;\n i += skipWeeks;\n\n for (; i < 52; i++) {\n if (tmp.epoch > thisOne) {\n return i + toAdd;\n }\n\n tmp = tmp.add(1, 'week');\n }\n\n return 52;\n },\n //'january'\n monthName: function monthName(input) {\n if (input === undefined) {\n return months[\"long\"]()[this.month()];\n }\n\n var s = this.clone();\n s = s.month(input);\n return s;\n },\n //q1, q2, q3, q4\n quarter: function quarter(num) {\n if (num !== undefined) {\n if (typeof num === 'string') {\n num = num.replace(/^q/i, '');\n num = parseInt(num, 10);\n }\n\n if (quarters[num]) {\n var s = this.clone();\n var _month = quarters[num][0];\n s = s.month(_month);\n s = s.date(1);\n s = s.startOf('day');\n return s;\n }\n }\n\n var month = this.d.getMonth();\n\n for (var i = 1; i < quarters.length; i++) {\n if (month < quarters[i][0]) {\n return i - 1;\n }\n }\n\n return 4;\n },\n //spring, summer, winter, fall\n season: function season(input) {\n var hem = 'north';\n\n if (this.hemisphere() === 'South') {\n hem = 'south';\n }\n\n if (input !== undefined) {\n var s = this.clone();\n\n for (var i = 0; i < seasons[hem].length; i++) {\n if (input === seasons[hem][i][0]) {\n s = s.month(seasons[hem][i][1]);\n s = s.date(1);\n s = s.startOf('day');\n }\n }\n\n return s;\n }\n\n var month = this.d.getMonth();\n\n for (var _i = 0; _i < seasons[hem].length - 1; _i++) {\n if (month >= seasons[hem][_i][1] && month < seasons[hem][_i + 1][1]) {\n return seasons[hem][_i][0];\n }\n }\n\n return 'winter';\n },\n //the year number\n year: function year(num) {\n if (num !== undefined) {\n var s = this.clone();\n s.epoch = set.year(s, num);\n return s;\n }\n\n return this.d.getFullYear();\n },\n //bc/ad years\n era: function era(str) {\n if (str !== undefined) {\n var s = this.clone();\n str = str.toLowerCase(); //TODO: there is no year-0AD i think. may have off-by-1 error here\n\n var year = s.d.getFullYear(); //make '1992' into 1992bc..\n\n if (str === 'bc' && year > 0) {\n s.epoch = set.year(s, year * -1);\n } //make '1992bc' into '1992'\n\n\n if (str === 'ad' && year < 0) {\n s.epoch = set.year(s, year * -1);\n }\n\n return s;\n }\n\n if (this.d.getFullYear() < 0) {\n return 'BC';\n }\n\n return 'AD';\n },\n // 2019 -> 2010\n decade: function decade(input) {\n if (input !== undefined) {\n input = String(input);\n input = input.replace(/([0-9])'?s$/, '$1'); //1950's\n\n input = input.replace(/([0-9])(th|rd|st|nd)/, '$1'); //fix ordinals\n\n if (!input) {\n console.warn('Spacetime: Invalid decade input');\n return this;\n } // assume 20th century?? for '70s'.\n\n\n if (input.length === 2 && /[0-9][0-9]/.test(input)) {\n input = '19' + input;\n }\n\n var year = Number(input);\n\n if (isNaN(year)) {\n return this;\n } // round it down to the decade\n\n\n year = Math.floor(year / 10) * 10;\n return this.year(year); //.startOf('decade')\n }\n\n return this.startOf('decade').year();\n },\n // 1950 -> 19+1\n century: function century(input) {\n if (input !== undefined) {\n if (typeof input === 'string') {\n input = input.replace(/([0-9])(th|rd|st|nd)/, '$1'); //fix ordinals\n\n input = input.replace(/([0-9]+) ?(b\\.?c\\.?|a\\.?d\\.?)/i, function (a, b, c) {\n if (c.match(/b\\.?c\\.?/i)) {\n b = '-' + b;\n }\n\n return b;\n });\n input = input.replace(/c$/, ''); //20thC\n }\n\n var year = Number(input);\n\n if (isNaN(input)) {\n console.warn('Spacetime: Invalid century input');\n return this;\n } // there is no century 0\n\n\n if (year === 0) {\n year = 1;\n }\n\n if (year >= 0) {\n year = (year - 1) * 100;\n } else {\n year = (year + 1) * 100;\n }\n\n return this.year(year);\n } // century getter\n\n\n var num = this.startOf('century').year();\n num = Math.floor(num / 100);\n\n if (num < 0) {\n return num - 1;\n }\n\n return num + 1;\n },\n // 2019 -> 2+1\n millenium: function millenium(input) {\n if (input !== undefined) {\n if (typeof input === 'string') {\n input = input.replace(/([0-9])(th|rd|st|nd)/, '$1'); //fix ordinals\n\n input = Number(input);\n\n if (isNaN(input)) {\n console.warn('Spacetime: Invalid millenium input');\n return this;\n }\n }\n\n if (input > 0) {\n input -= 1;\n }\n\n var year = input * 1000; // there is no year 0\n\n if (year === 0) {\n year = 1;\n }\n\n return this.year(year);\n } // get the current millenium\n\n\n var num = Math.floor(this.year() / 1000);\n\n if (num >= 0) {\n num += 1;\n }\n\n return num;\n }\n};\nvar _03Year = methods$3;\n\nvar methods$4 = Object.assign({}, _01Time, _02Date, _03Year); //aliases\n\nmethods$4.milliseconds = methods$4.millisecond;\nmethods$4.seconds = methods$4.second;\nmethods$4.minutes = methods$4.minute;\nmethods$4.hours = methods$4.hour;\nmethods$4.hour24 = methods$4.hour;\nmethods$4.h12 = methods$4.hour12;\nmethods$4.h24 = methods$4.hour24;\nmethods$4.days = methods$4.day;\n\nvar addMethods = function addMethods(Space) {\n //hook the methods into prototype\n Object.keys(methods$4).forEach(function (k) {\n Space.prototype[k] = methods$4[k];\n });\n};\n\nvar query = addMethods;\n\nvar isLeapYear$2 = fns.isLeapYear;\n\nvar getMonthLength = function getMonthLength(month, year) {\n if (month === 1 && isLeapYear$2(year)) {\n return 29;\n }\n\n return monthLengths_1[month];\n}; //month is the one thing we 'model/compute'\n//- because ms-shifting can be off by enough\n\n\nvar rollMonth = function rollMonth(want, old) {\n //increment year\n if (want.month > 0) {\n var years = parseInt(want.month / 12, 10);\n want.year = old.year() + years;\n want.month = want.month % 12;\n } else if (want.month < 0) {\n //decrement year\n var _years = Math.floor(Math.abs(want.month) / 13, 10);\n\n _years = Math.abs(_years) + 1;\n want.year = old.year() - _years; //ignore extras\n\n want.month = want.month % 12;\n want.month = want.month + 12;\n\n if (want.month === 12) {\n want.month = 0;\n }\n }\n\n return want;\n}; // briefly support day=-2 (this does not need to be perfect.)\n\n\nvar rollDaysDown = function rollDaysDown(want, old, sum) {\n want.year = old.year();\n want.month = old.month();\n var date = old.date();\n want.date = date - Math.abs(sum);\n\n while (want.date < 1) {\n want.month -= 1;\n\n if (want.month < 0) {\n want.month = 11;\n want.year -= 1;\n }\n\n var max = getMonthLength(want.month, want.year);\n want.date += max;\n }\n\n return want;\n}; // briefly support day=33 (this does not need to be perfect.)\n\n\nvar rollDaysUp = function rollDaysUp(want, old, sum) {\n var year = old.year();\n var month = old.month();\n var max = getMonthLength(month, year);\n\n while (sum > max) {\n sum -= max;\n month += 1;\n\n if (month >= 12) {\n month -= 12;\n year += 1;\n }\n\n max = getMonthLength(month, year);\n }\n\n want.month = month;\n want.date = sum;\n return want;\n};\n\nvar _model = {\n months: rollMonth,\n days: rollDaysUp,\n daysBack: rollDaysDown\n};\n\n// but briefly:\n// millisecond-math, and some post-processing covers most-things\n// we 'model' the calendar here only a little bit\n// and that usually works-out...\n\nvar order$1 = ['millisecond', 'second', 'minute', 'hour', 'date', 'month'];\nvar keep = {\n second: order$1.slice(0, 1),\n minute: order$1.slice(0, 2),\n quarterhour: order$1.slice(0, 2),\n hour: order$1.slice(0, 3),\n date: order$1.slice(0, 4),\n month: order$1.slice(0, 4),\n quarter: order$1.slice(0, 4),\n season: order$1.slice(0, 4),\n year: order$1,\n decade: order$1,\n century: order$1\n};\nkeep.week = keep.hour;\nkeep.season = keep.date;\nkeep.quarter = keep.date; // Units need to be dst adjuested\n\nvar dstAwareUnits = {\n year: true,\n quarter: true,\n season: true,\n month: true,\n week: true,\n day: true\n};\nvar keepDate = {\n month: true,\n quarter: true,\n season: true,\n year: true\n};\n\nvar addMethods$1 = function addMethods(SpaceTime) {\n SpaceTime.prototype.add = function (num, unit) {\n var s = this.clone();\n\n if (!unit || num === 0) {\n return s; //don't bother\n }\n\n var old = this.clone();\n unit = fns.normalize(unit); //move forward by the estimated milliseconds (rough)\n\n if (milliseconds[unit]) {\n s.epoch += milliseconds[unit] * num;\n } else if (unit === 'week') {\n s.epoch += milliseconds.day * (num * 7);\n } else if (unit === 'quarter' || unit === 'season') {\n s.epoch += milliseconds.month * (num * 4);\n } else if (unit === 'season') {\n s.epoch += milliseconds.month * (num * 4);\n } else if (unit === 'quarterhour') {\n s.epoch += milliseconds.minute * 15 * num;\n } //now ensure our milliseconds/etc are in-line\n\n\n var want = {};\n\n if (keep[unit]) {\n keep[unit].forEach(function (u) {\n want[u] = old[u]();\n });\n }\n\n if (dstAwareUnits[unit]) {\n var diff = old.timezone().current.offset - s.timezone().current.offset;\n s.epoch += diff * 3600 * 1000;\n } //ensure month/year has ticked-over\n\n\n if (unit === 'month') {\n want.month = old.month() + num; //month is the one unit we 'model' directly\n\n want = _model.months(want, old);\n } //support coercing a week, too\n\n\n if (unit === 'week') {\n var sum = old.date() + num * 7;\n\n if (sum <= 28 && sum > 1) {\n want.date = sum;\n }\n } //support 25-hour day-changes on dst-changes\n else if (unit === 'date') {\n if (num < 0) {\n want = _model.daysBack(want, old, num);\n } else {\n //specify a naive date number, if it's easy to do...\n var _sum = old.date() + num; // ok, model this one too\n\n\n want = _model.days(want, old, _sum);\n } //manually punt it if we haven't moved at all..\n\n\n if (num !== 0 && old.isSame(s, 'day')) {\n want.date = old.date() + num;\n }\n } //ensure year has changed (leap-years)\n else if (unit === 'year' && s.year() === old.year()) {\n s.epoch += milliseconds.week;\n } //these are easier\n else if (unit === 'decade') {\n want.year = s.year() + 10;\n } else if (unit === 'century') {\n want.year = s.year() + 100;\n } //keep current date, unless the month doesn't have it.\n\n\n if (keepDate[unit]) {\n var max = monthLengths_1[want.month];\n want.date = old.date();\n\n if (want.date > max) {\n want.date = max;\n }\n }\n\n walk_1(s, want);\n return s;\n }; //subtract is only add *-1\n\n\n SpaceTime.prototype.subtract = function (num, unit) {\n var s = this.clone();\n return s.add(num * -1, unit);\n }; //add aliases\n\n\n SpaceTime.prototype.minus = SpaceTime.prototype.subtract;\n SpaceTime.prototype.plus = SpaceTime.prototype.add;\n};\n\nvar add = addMethods$1;\n\n//make a string, for easy comparison between dates\nvar print = {\n millisecond: function millisecond(s) {\n return s.epoch;\n },\n second: function second(s) {\n return [s.year(), s.month(), s.date(), s.hour(), s.minute(), s.second()].join('-');\n },\n minute: function minute(s) {\n return [s.year(), s.month(), s.date(), s.hour(), s.minute()].join('-');\n },\n hour: function hour(s) {\n return [s.year(), s.month(), s.date(), s.hour()].join('-');\n },\n day: function day(s) {\n return [s.year(), s.month(), s.date()].join('-');\n },\n week: function week(s) {\n return [s.year(), s.week()].join('-');\n },\n month: function month(s) {\n return [s.year(), s.month()].join('-');\n },\n quarter: function quarter(s) {\n return [s.year(), s.quarter()].join('-');\n },\n year: function year(s) {\n return s.year();\n }\n};\nprint.date = print.day;\n\nvar addMethods$2 = function addMethods(SpaceTime) {\n SpaceTime.prototype.isSame = function (b, unit) {\n var a = this;\n\n if (!unit) {\n return null;\n }\n\n if (typeof b === 'string' || typeof b === 'number') {\n b = new SpaceTime(b, this.timezone.name);\n } //support 'seconds' aswell as 'second'\n\n\n unit = unit.replace(/s$/, '');\n\n if (print[unit]) {\n return print[unit](a) === print[unit](b);\n }\n\n return null;\n };\n};\n\nvar same = addMethods$2;\n\nvar addMethods$3 = function addMethods(SpaceTime) {\n var methods = {\n isAfter: function isAfter(d) {\n d = fns.beADate(d, this);\n var epoch = fns.getEpoch(d);\n\n if (epoch === null) {\n return null;\n }\n\n return this.epoch > epoch;\n },\n isBefore: function isBefore(d) {\n d = fns.beADate(d, this);\n var epoch = fns.getEpoch(d);\n\n if (epoch === null) {\n return null;\n }\n\n return this.epoch < epoch;\n },\n isEqual: function isEqual(d) {\n d = fns.beADate(d, this);\n var epoch = fns.getEpoch(d);\n\n if (epoch === null) {\n return null;\n }\n\n return this.epoch === epoch;\n },\n isBetween: function isBetween(start, end) {\n var isInclusive = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;\n start = fns.beADate(start, this);\n end = fns.beADate(end, this);\n var startEpoch = fns.getEpoch(start);\n\n if (startEpoch === null) {\n return null;\n }\n\n var endEpoch = fns.getEpoch(end);\n\n if (endEpoch === null) {\n return null;\n }\n\n if (isInclusive) {\n return this.isBetween(start, end) || this.isEqual(start) || this.isEqual(end);\n }\n\n return startEpoch < this.epoch && this.epoch < endEpoch;\n }\n }; //hook them into proto\n\n Object.keys(methods).forEach(function (k) {\n SpaceTime.prototype[k] = methods[k];\n });\n};\n\nvar compare = addMethods$3;\n\nvar addMethods$4 = function addMethods(SpaceTime) {\n var methods = {\n i18n: function i18n(data) {\n //change the day names\n if (fns.isObject(data.days)) {\n days.set(data.days);\n } //change the month names\n\n\n if (fns.isObject(data.months)) {\n months.set(data.months);\n }\n }\n }; //hook them into proto\n\n Object.keys(methods).forEach(function (k) {\n SpaceTime.prototype[k] = methods[k];\n });\n};\n\nvar i18n = addMethods$4;\n\nvar timezones = unpack; //fake timezone-support, for fakers (es5 class)\n\nvar SpaceTime = function SpaceTime(input$1, tz) {\n var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};\n //the holy moment\n this.epoch = null; //the shift for the given timezone\n\n this.tz = find(tz, timezones); //whether to output warnings to console\n\n this.silent = options.silent || true; // favour british interpretation of 02/02/2018, etc\n\n this.british = options.dmy || options.british; //does the week start on sunday, or monday:\n\n this._weekStart = 1; //default to monday\n\n if (options.weekStart !== undefined) {\n this._weekStart = options.weekStart;\n } // the reference today date object, (for testing)\n\n\n this._today = {};\n\n if (options.today !== undefined) {\n this._today = options.today;\n } //add getter/setters\n\n\n Object.defineProperty(this, 'd', {\n //return a js date object\n get: function get() {\n var offset = quick(this); //every computer is somewhere- get this computer's built-in offset\n\n var bias = new Date(this.epoch).getTimezoneOffset() || 0; //movement\n\n var shift = bias + offset * 60; //in minutes\n\n shift = shift * 60 * 1000; //in ms\n //remove this computer's offset\n\n var epoch = this.epoch + shift;\n var d = new Date(epoch);\n return d;\n }\n }); //add this data on the object, to allow adding new timezones\n\n Object.defineProperty(this, 'timezones', {\n get: function get() {\n return timezones;\n },\n set: function set(obj) {\n timezones = obj;\n return obj;\n }\n }); //parse the various formats\n\n var tmp = input(this, input$1, tz);\n this.epoch = tmp.epoch;\n}; //(add instance methods to prototype)\n\n\nObject.keys(methods_1).forEach(function (k) {\n SpaceTime.prototype[k] = methods_1[k];\n}); // ¯\\_(ツ)_/¯\n\nSpaceTime.prototype.clone = function () {\n return new SpaceTime(this.epoch, this.tz, {\n silent: this.silent,\n weekStart: this._weekStart,\n today: this._today\n });\n}; //return native date object at the same epoch\n\n\nSpaceTime.prototype.toLocalDate = function () {\n return new Date(this.epoch);\n}; //append more methods\n\n\nquery(SpaceTime);\nadd(SpaceTime);\nsame(SpaceTime);\ncompare(SpaceTime);\ni18n(SpaceTime);\nvar spacetime = SpaceTime;\n\nvar whereIts = function whereIts(a, b) {\n var start = new spacetime(null);\n var end = new spacetime(null);\n start = start.time(a); //if b is undefined, use as 'within one hour'\n\n if (b) {\n end = end.time(b);\n } else {\n end = start.add(59, 'minutes');\n }\n\n var startHour = start.hour();\n var endHour = end.hour();\n var tzs = Object.keys(start.timezones).filter(function (tz) {\n if (tz.indexOf('/') === -1) {\n return false;\n }\n\n var m = new spacetime(null, tz);\n var hour = m.hour(); //do 'calendar-compare' not real-time-compare\n\n if (hour >= startHour && hour <= endHour) {\n //test minutes too, if applicable\n if (hour === startHour && m.minute() < start.minute()) {\n return false;\n }\n\n if (hour === endHour && m.minute() > end.minute()) {\n return false;\n }\n\n return true;\n }\n\n return false;\n });\n return tzs;\n};\n\nvar whereIts_1 = whereIts;\n\nvar _version = '6.6.3';\n\nvar main$1 = function main(input, tz, options) {\n return new spacetime(input, tz, options);\n}; // set all properties of a given 'today' object\n\n\nvar setToday = function setToday(s) {\n var today = s._today || {};\n Object.keys(today).forEach(function (k) {\n s = s[k](today[k]);\n });\n return s;\n}; //some helper functions on the main method\n\n\nmain$1.now = function (tz, options) {\n var s = new spacetime(new Date().getTime(), tz, options);\n s = setToday(s);\n return s;\n};\n\nmain$1.today = function (tz, options) {\n var s = new spacetime(new Date().getTime(), tz, options);\n s = setToday(s);\n return s.startOf('day');\n};\n\nmain$1.tomorrow = function (tz, options) {\n var s = new spacetime(new Date().getTime(), tz, options);\n s = setToday(s);\n return s.add(1, 'day').startOf('day');\n};\n\nmain$1.yesterday = function (tz, options) {\n var s = new spacetime(new Date().getTime(), tz, options);\n s = setToday(s);\n return s.subtract(1, 'day').startOf('day');\n};\n\nmain$1.extend = function (obj) {\n Object.keys(obj).forEach(function (k) {\n spacetime.prototype[k] = obj[k];\n });\n return this;\n}; //find tz by time\n\n\nmain$1.whereIts = whereIts_1;\nmain$1.version = _version; //aliases:\n\nmain$1.plugin = main$1.extend;\nvar src = main$1;\n\nexport default src;\n","// some opinionated-but-common-sense timezone abbreviations\n// these timezone abbreviations are wholly made-up by me, Spencer Kelly, with no expertise in geography\n// generated humbly from https://github.com/spencermountain/spacetime-informal\nconst spacetime = require('spacetime')\n\nconst america = 'America/'\nconst asia = 'Asia/'\nconst europe = 'Europe/'\nconst africa = 'Africa/'\nconst aus = 'Australia/'\nconst pac = 'Pacific/'\n\nconst informal = {\n //europe\n 'british summer time': europe + 'London',\n bst: europe + 'London',\n 'british time': europe + 'London',\n 'britain time': europe + 'London',\n 'irish summer time': europe + 'Dublin',\n 'irish time': europe + 'Dublin',\n ireland: europe + 'Dublin',\n 'central european time': europe + 'Berlin',\n cet: europe + 'Berlin',\n 'central european summer time': europe + 'Berlin',\n cest: europe + 'Berlin',\n 'central europe': europe + 'Berlin',\n 'eastern european time': europe + 'Riga',\n eet: europe + 'Riga',\n 'eastern european summer time': europe + 'Riga',\n eest: europe + 'Riga',\n 'eastern europe time': europe + 'Riga',\n 'western european time': europe + 'Lisbon',\n // wet: europe+'Lisbon',\n 'western european summer time': europe + 'Lisbon',\n // west: europe+'Lisbon',\n 'western europe': europe + 'Lisbon',\n 'turkey standard time': europe + 'Istanbul',\n trt: europe + 'Istanbul',\n 'turkish time': europe + 'Istanbul',\n\n //africa\n etc: africa + 'Freetown',\n utc: africa + 'Freetown',\n 'greenwich standard time': africa + 'Freetown',\n gmt: africa + 'Freetown',\n 'east africa time': africa + 'Nairobi',\n // eat: africa+'Nairobi',\n 'east african time': africa + 'Nairobi',\n 'eastern africa time': africa + 'Nairobi',\n 'central africa time': africa + 'Khartoum',\n // cat: africa+'Khartoum',\n 'central african time': africa + 'Khartoum',\n 'south africa standard time': africa + 'Johannesburg',\n sast: africa + 'Johannesburg',\n 'southern africa': africa + 'Johannesburg',\n 'south african': africa + 'Johannesburg',\n 'west africa standard time': africa + 'Lagos',\n // wat: africa+'Lagos',\n 'western africa time': africa + 'Lagos',\n 'west african time': africa + 'Lagos',\n\n 'australian central standard time': aus + 'Adelaide',\n acst: aus + 'Adelaide',\n 'australian central daylight time': aus + 'Adelaide',\n acdt: aus + 'Adelaide',\n 'australia central': aus + 'Adelaide',\n 'australian eastern standard time': aus + 'Brisbane',\n aest: aus + 'Brisbane',\n 'australian eastern daylight time': aus + 'Brisbane',\n aedt: aus + 'Brisbane',\n 'australia east': aus + 'Brisbane',\n 'australian western standard time': aus + 'Perth',\n awst: aus + 'Perth',\n 'australian western daylight time': aus + 'Perth',\n awdt: aus + 'Perth',\n 'australia west': aus + 'Perth',\n 'australian central western standard time': aus + 'Eucla',\n acwst: aus + 'Eucla',\n 'australia central west': aus + 'Eucla',\n 'lord howe standard time': aus + 'Lord_Howe',\n lhst: aus + 'Lord_Howe',\n 'lord howe daylight time': aus + 'Lord_Howe',\n lhdt: aus + 'Lord_Howe',\n 'russian standard time': europe + 'Moscow',\n msk: europe + 'Moscow',\n russian: europe + 'Moscow',\n\n //america\n 'central standard time': america + 'Chicago',\n 'central time': america + 'Chicago',\n cst: america + 'Havana',\n 'central daylight time': america + 'Chicago',\n cdt: america + 'Havana',\n 'mountain standard time': america + 'Denver',\n 'mountain time': america + 'Denver',\n mst: america + 'Denver',\n 'mountain daylight time': america + 'Denver',\n mdt: america + 'Denver',\n 'atlantic standard time': america + 'Halifax',\n 'atlantic time': america + 'Halifax',\n ast: asia + 'Baghdad',\n 'atlantic daylight time': america + 'Halifax',\n adt: america + 'Halifax',\n 'eastern standard time': america + 'New_York',\n 'eastern time': america + 'New_York',\n est: america + 'New_York',\n 'eastern daylight time': america + 'New_York',\n edt: america + 'New_York',\n 'pacific time': america + 'Los_Angeles',\n 'pacific standard time': america + 'Los_Angeles',\n pst: america + 'Los_Angeles',\n 'pacific daylight time': america + 'Los_Angeles',\n pdt: america + 'Los_Angeles',\n 'alaskan standard time': america + 'Anchorage',\n 'alaskan time': america + 'Anchorage',\n ahst: america + 'Anchorage',\n 'alaskan daylight time': america + 'Anchorage',\n ahdt: america + 'Anchorage',\n 'hawaiian standard time': pac + 'Honolulu',\n 'hawaiian time': pac + 'Honolulu',\n hst: pac + 'Honolulu',\n 'aleutian time': pac + 'Honolulu',\n 'hawaii time': pac + 'Honolulu',\n 'newfoundland standard time': america + 'St_Johns',\n 'newfoundland time': america + 'St_Johns',\n nst: america + 'St_Johns',\n 'newfoundland daylight time': america + 'St_Johns',\n ndt: america + 'St_Johns',\n 'brazil time': america + 'Sao_Paulo',\n brt: america + 'Sao_Paulo',\n brasília: america + 'Sao_Paulo',\n brasilia: america + 'Sao_Paulo',\n 'brazilian time': america + 'Sao_Paulo',\n 'argentina time': america + 'Buenos_Aires',\n // art: a+'Buenos_Aires',\n 'argentinian time': america + 'Buenos_Aires',\n 'amazon time': america + 'Manaus',\n amt: america + 'Manaus',\n 'amazonian time': america + 'Manaus',\n 'easter island standard time': 'Chile/Easterisland',\n east: 'Chile/Easterisland',\n 'easter island summer time': 'Chile/Easterisland',\n easst: 'Chile/Easterisland',\n 'venezuelan standard time': america + 'Caracas',\n 'venezuelan time': america + 'Caracas',\n vet: america + 'Caracas',\n 'venezuela time': america + 'Caracas',\n 'paraguay time': america + 'Asuncion',\n pyt: america + 'Asuncion',\n 'paraguay summer time': america + 'Asuncion',\n pyst: america + 'Asuncion',\n 'cuba standard time': america + 'Havana',\n 'cuba time': america + 'Havana',\n 'cuba daylight time': america + 'Havana',\n 'cuban time': america + 'Havana',\n 'bolivia time': america + 'La_Paz',\n // bot: a+'La_Paz',\n 'bolivian time': america + 'La_Paz',\n 'colombia time': america + 'Bogota',\n cot: america + 'Bogota',\n 'colombian time': america + 'Bogota',\n 'acre time': america + 'Eirunepe',\n // act: a+'Eirunepe',\n 'peru time': america + 'Lima',\n // pet: a+'Lima',\n 'chile standard time': america + 'Punta_Arenas',\n 'chile time': america + 'Punta_Arenas',\n clst: america + 'Punta_Arenas',\n 'chile summer time': america + 'Punta_Arenas',\n cldt: america + 'Punta_Arenas',\n 'uruguay time': america + 'Montevideo',\n uyt: america + 'Montevideo',\n\n //asia\n ist: asia + 'Jerusalem',\n 'arabic standard time': asia + 'Baghdad',\n 'arabic time': asia + 'Baghdad',\n 'arab time': asia + 'Baghdad',\n 'iran standard time': asia + 'Tehran',\n 'iran time': asia + 'Tehran',\n irst: asia + 'Tehran',\n 'iran daylight time': asia + 'Tehran',\n irdt: asia + 'Tehran',\n iranian: asia + 'Tehran',\n 'pakistan standard time': asia + 'Karachi',\n 'pakistan time': asia + 'Karachi',\n pkt: asia + 'Karachi',\n 'india standard time': asia + 'Kolkata',\n 'indian time': asia + 'Kolkata',\n 'indochina time': asia + 'Bangkok',\n ict: asia + 'Bangkok',\n 'south east asia': asia + 'Bangkok',\n 'china standard time': asia + 'Shanghai',\n ct: asia + 'Shanghai',\n 'chinese time': asia + 'Shanghai',\n 'alma-ata time': asia + 'Almaty',\n almt: asia + 'Almaty',\n 'oral time': asia + 'Oral',\n 'orat time': asia + 'Oral',\n 'yakutsk time': asia + 'Yakutsk',\n yakt: asia + 'Yakutsk',\n 'gulf standard time': asia + 'Dubai',\n 'gulf time': asia + 'Dubai',\n gst: asia + 'Dubai',\n uae: asia + 'Dubai',\n 'hong kong time': asia + 'Hong_Kong',\n hkt: asia + 'Hong_Kong',\n 'western indonesian time': asia + 'Jakarta',\n wib: asia + 'Jakarta',\n 'indonesia time': asia + 'Jakarta',\n 'central indonesian time': asia + 'Makassar',\n wita: asia + 'Makassar',\n 'israel daylight time': asia + 'Jerusalem',\n idt: asia + 'Jerusalem',\n 'israel standard time': asia + 'Jerusalem',\n 'israel time': asia + 'Jerusalem',\n israeli: asia + 'Jerusalem',\n 'krasnoyarsk time': asia + 'Krasnoyarsk',\n krat: asia + 'Krasnoyarsk',\n 'malaysia time': asia + 'Kuala_Lumpur',\n myt: asia + 'Kuala_Lumpur',\n 'singapore time': asia + 'Singapore',\n sgt: asia + 'Singapore',\n 'korea standard time': asia + 'Seoul',\n 'korea time': asia + 'Seoul',\n kst: asia + 'Seoul',\n 'korean time': asia + 'Seoul',\n 'uzbekistan time': asia + 'Samarkand',\n uzt: asia + 'Samarkand',\n 'vladivostok time': asia + 'Vladivostok',\n vlat: asia + 'Vladivostok',\n\n //indian\n 'maldives time': 'Indian/Maldives',\n mvt: 'Indian/Maldives',\n 'mauritius time': 'Indian/Mauritius',\n mut: 'Indian/Mauritius',\n\n // pacific\n 'marshall islands time': pac + 'Kwajalein',\n mht: pac + 'Kwajalein',\n 'samoa standard time': pac + 'Midway',\n sst: pac + 'Midway',\n 'somoan time': pac + 'Midway',\n 'chamorro standard time': pac + 'Guam',\n chst: pac + 'Guam',\n 'papua new guinea time': pac + 'Bougainville',\n pgt: pac + 'Bougainville',\n}\n\n//add the official iana zonefile names\nlet iana = spacetime().timezones\nlet formal = Object.keys(iana).reduce((h, k) => {\n h[k] = k\n return h\n}, {})\nmodule.exports = Object.assign({}, informal, formal)\n","module.exports = [\n 'weekday',\n\n 'summer',\n 'winter',\n 'autumn',\n\n 'some day',\n 'one day',\n 'all day',\n 'some point',\n\n 'eod',\n 'eom',\n 'standard time',\n 'daylight time',\n]\n","module.exports = [\n 'centuries',\n 'century',\n 'day',\n 'days',\n 'decade',\n 'decades',\n 'hour',\n 'hours',\n 'millisecond',\n 'milliseconds',\n 'minute',\n 'minutes',\n 'month',\n 'months',\n 'seconds',\n 'week',\n 'weeks',\n 'year',\n 'years',\n]\n","module.exports = [\n 'all hallows eve',\n 'all saints day',\n 'all sts day',\n 'april fools',\n 'armistice day',\n 'australia day',\n 'bastille day',\n 'boxing day',\n 'canada day',\n 'christmas eve',\n 'christmas',\n 'cinco de mayo',\n 'day of the dead',\n 'dia de muertos',\n 'dieciseis de septiembre',\n 'emancipation day',\n 'grito de dolores',\n 'groundhog day',\n 'halloween',\n 'harvey milk day',\n 'inauguration day',\n 'independence day',\n 'independents day',\n 'juneteenth',\n 'labour day',\n 'national freedom day',\n 'national nurses day',\n 'new years eve',\n 'new years',\n 'purple heart day',\n 'rememberance day',\n 'rosa parks day',\n 'saint andrews day',\n 'saint patricks day',\n 'saint stephens day',\n 'saint valentines day',\n 'st andrews day',\n 'st patricks day',\n 'st stephens day',\n 'st valentines day ',\n 'valentines day',\n 'valentines',\n 'veterans day',\n 'victoria day',\n 'womens equality day',\n 'xmas',\n // Fixed religious and cultural holidays\n // Catholic + Christian\n 'epiphany',\n 'orthodox christmas day',\n 'orthodox new year',\n 'assumption of mary',\n 'all souls day',\n 'feast of the immaculate conception',\n 'feast of our lady of guadalupe',\n\n // Kwanzaa\n 'kwanzaa',\n // Pagan / metal 🤘\n 'imbolc',\n 'beltaine',\n 'lughnassadh',\n 'samhain',\n 'martin luther king day',\n 'mlk day',\n 'presidents day',\n 'mardi gras',\n 'tax day',\n 'commonwealth day',\n 'mothers day',\n 'memorial day',\n 'fathers day',\n 'columbus day',\n 'indigenous peoples day',\n 'canadian thanksgiving',\n 'election day',\n 'thanksgiving',\n 't-day',\n 'turkey day',\n 'black friday',\n 'cyber monday',\n // Astronomical religious and cultural holidays\n 'ash wednesday',\n 'palm sunday',\n 'maundy thursday',\n 'good friday',\n 'holy saturday',\n 'easter',\n 'easter sunday',\n 'easter monday',\n 'orthodox good friday',\n 'orthodox holy saturday',\n 'orthodox easter',\n 'orthodox easter monday',\n 'ascension day',\n 'pentecost',\n 'whitsunday',\n 'whit sunday',\n 'whit monday',\n 'trinity sunday',\n 'corpus christi',\n 'advent',\n // Jewish\n 'tu bishvat',\n 'tu bshevat',\n 'purim',\n 'passover',\n 'yom hashoah',\n 'lag baomer',\n 'shavuot',\n 'tisha bav',\n 'rosh hashana',\n 'yom kippur',\n 'sukkot',\n 'shmini atzeret',\n 'simchat torah',\n 'chanukah',\n 'hanukkah',\n // Muslim\n 'isra and miraj',\n 'lailat al-qadr',\n 'eid al-fitr',\n 'id al-Fitr',\n 'eid ul-Fitr',\n 'ramadan',\n 'eid al-adha',\n 'muharram',\n 'the prophets birthday',\n 'ostara',\n 'march equinox',\n 'vernal equinox',\n 'litha',\n 'june solistice',\n 'summer solistice',\n 'mabon',\n 'september equinox',\n 'fall equinox',\n 'autumnal equinox',\n 'yule',\n 'december solstice',\n 'winter solstice',\n // Additional important holidays\n 'chinese new year',\n 'diwali',\n]\n","module.exports = [\n 'noon',\n 'midnight',\n 'now',\n 'morning',\n 'tonight',\n 'evening',\n 'afternoon',\n 'night',\n 'breakfast time',\n 'lunchtime',\n 'dinnertime',\n 'sometime',\n 'eod',\n 'oclock',\n 'oclock',\n 'all day',\n 'at night',\n]\n","let lex = {}\nconst timezones = require('../_timezones')\n\nconst data = [\n [require('./dates'), '#Date'],\n [require('./durations'), '#Duration'],\n [require('./holidays'), '#Holiday'],\n [require('./times'), '#Time'],\n [Object.keys(timezones), '#Timezone'],\n]\ndata.forEach(a => {\n for (let i = 0; i < a[0].length; i++) {\n lex[a[0][i]] = a[1]\n }\n})\n\nmodule.exports = lex\n","const normalize = function(doc) {\n doc = doc.clone()\n\n if (!doc.numbers) {\n console.warn(\"Compromise: compromise-dates cannot find plugin dependency 'compromise-number'\")\n } else {\n // convert 'two' to 2\n let num = doc.numbers()\n num.toNumber()\n num.toCardinal()\n }\n // remove adverbs\n doc.adverbs().remove()\n return doc\n}\nmodule.exports = normalize\n","const knownUnits = {\n second: true,\n minute: true,\n hour: true,\n day: true,\n week: true,\n month: true,\n season: true,\n quarter: true,\n year: true,\n}\n\n//turn '5 weeks before' to {weeks:5}\nconst parseShift = function (doc) {\n let result = {}\n let m = doc.match('#DateShift+')\n if (m.found === false) {\n return result\n }\n m.match('#Cardinal #Duration').forEach((ts) => {\n let num = ts.match('#Cardinal').text('normal')\n num = parseFloat(num)\n if (num && typeof num === 'number') {\n let unit = ts.match('#Duration').text('normal')\n unit = unit.replace(/s$/, '')\n if (unit && knownUnits.hasOwnProperty(unit)) {\n result[unit] = num\n }\n }\n })\n //is it 2 weeks ago? → -2\n if (m.has('(before|ago)$') === true) {\n Object.keys(result).forEach((k) => (result[k] *= -1))\n }\n // finally, remove it from our text\n doc.remove('#DateShift')\n return result\n}\nmodule.exports = parseShift\n","const spacetime = require('spacetime')\n\nconst hardCoded = {\n daybreak: '7:00am', //ergh\n breakfast: '8:00am',\n morning: '9:00am',\n noon: '12:00pm',\n afternoon: '2:00pm',\n lunchtime: '12:00pm',\n evening: '6:00pm',\n dinnertime: '6:00pm',\n night: '8:00pm',\n midnight: '12:00am',\n}\n\nconst halfPast = function (m, s) {\n let hour = m.match('#Cardinal$').text('reduced')\n\n let term = m.match('(half|quarter|25|15|10|5)')\n let mins = term.text('reduced')\n if (term.has('half')) {\n mins = '30'\n }\n if (term.has('quarter')) {\n mins = '15'\n }\n let behind = m.has('to')\n // apply it\n s = s.hour(hour)\n s = s.startOf('hour')\n if (behind) {\n s = s.subtract(mins, 'minutes')\n } else {\n s = s.add(mins, 'minutes')\n }\n return s\n}\n\nconst parseTime = function (doc, context) {\n let time = doc.match('(at|by|for|before)? #Time+')\n if (time.found) {\n doc.remove(time)\n }\n // get the main part of the time\n time = time.not('(at|by|for|before|sharp)')\n time = time.not('on the dot')\n let s = spacetime.now(context.timezone)\n let now = s.clone()\n\n // check for known-times (like 'today')\n let timeStr = time.text('reduced')\n if (hardCoded.hasOwnProperty(timeStr)) {\n return hardCoded[timeStr]\n }\n\n // '5 oclock'\n let m = time.match('^#Cardinal oclock (am|pm)?')\n if (m.found) {\n m = m.not('oclock')\n s = s.hour(m.text('reduced'))\n if (s.isValid() && !s.isEqual(now)) {\n return s.time()\n }\n }\n\n // 'quarter to two'\n m = time.match('(half|quarter|25|15|10|5) (past|after|to) #Cardinal')\n if (m.found) {\n s = halfPast(m, s)\n if (s.isValid() && !s.isEqual(now)) {\n return s.time()\n }\n }\n // parse random a time like '4:54pm'\n let str = time.text('reduced')\n s = s.time(str)\n if (s.isValid() && !s.isEqual(now)) {\n return s.time()\n }\n return null\n}\nmodule.exports = parseTime\n","// interpret 'this halloween' or 'next june'\nconst parseRelative = function(doc) {\n let rel = null\n if (doc.has('^this? (next|upcoming)')) {\n rel = 'next'\n }\n if (doc.has('^this? (last|previous)')) {\n rel = 'last'\n }\n if (doc.has('^(this|current)')) {\n rel = 'this'\n }\n // finally, remove it from our text\n doc.remove('^(this|current|next|upcoming|last|previous)')\n return rel\n}\nmodule.exports = parseRelative\n","const informal = require('../../data/_timezones')\n\nconst isOffset = /(\\-?[0-9]+)h(rs)?/i\nconst isNumber = /(\\-?[0-9]+)/\nconst utcOffset = /utc([\\-+]?[0-9]+)/i\nconst gmtOffset = /gmt([\\-+]?[0-9]+)/i\n\nconst toIana = function(num) {\n num = Number(num)\n if (num > -13 && num < 13) {\n num = num * -1 //it's opposite!\n num = (num > 0 ? '+' : '') + num //add plus sign\n return 'Etc/GMT' + num\n }\n return null\n}\n\nconst parseOffset = function(tz) {\n // '+5hrs'\n let m = tz.match(isOffset)\n if (m !== null) {\n return toIana(m[1])\n }\n // 'utc+5'\n m = tz.match(utcOffset)\n if (m !== null) {\n return toIana(m[1])\n }\n // 'GMT-5' (not opposite)\n m = tz.match(gmtOffset)\n if (m !== null) {\n let num = Number(m[1]) * -1\n return toIana(num)\n }\n // '+5'\n m = tz.match(isNumber)\n if (m !== null) {\n return toIana(m[1])\n }\n return null\n}\n\nconst parseTimezone = function(doc) {\n let m = doc.match('#Timezone+')\n //remove prepositions\n m = m.remove('(in|for|by|near|at)')\n let str = m.text('reduced')\n\n // remove it from our doc, either way\n doc.remove('#Timezone+')\n\n // check our list of informal tz names\n if (informal.hasOwnProperty(str)) {\n return informal[str]\n }\n let tz = parseOffset(str)\n if (tz) {\n return tz\n }\n\n return null\n}\nmodule.exports = parseTimezone\n","const spacetime = require('spacetime')\n\nclass Unit {\n constructor(input, unit, context) {\n this.unit = unit || 'day'\n context = context || {}\n let today = {}\n if (context.today) {\n today = {\n date: context.today.date(),\n month: context.today.month(),\n year: context.today.year(),\n }\n }\n // set it to the beginning of the given unit\n let d = spacetime(input, context.timezone, { today: today })\n\n // set to beginning\n if (d.isValid()) {\n d = d.startOf(this.unit)\n }\n Object.defineProperty(this, 'd', {\n enumerable: false,\n writable: true,\n value: d,\n })\n Object.defineProperty(this, 'context', {\n enumerable: false,\n writable: true,\n value: context,\n })\n }\n // make a new one\n clone() {\n let d = new Unit(this.d, this.unit, this.context)\n return d\n }\n log() {\n console.log('--')\n this.d.log()\n console.log('\\n')\n return this\n }\n applyShift(obj = {}) {\n Object.keys(obj).forEach((k) => {\n this.d = this.d.add(obj[k], k)\n })\n return this\n }\n applyTime(str) {\n if (str) {\n this.d = this.d.time(str)\n } else {\n this.d = this.d.startOf('day') //zero-out time\n }\n return this\n }\n format(fmt) {\n return this.d.format(fmt)\n }\n start() {\n this.d = this.d.startOf(this.unit)\n return this\n }\n end() {\n this.d = this.d.endOf(this.unit)\n return this\n }\n // 'before 2019'\n before() {\n this.d = spacetime.now(this.context.timezone, { today: this.context.today }) // ???\n return this\n }\n // 'after 2019'\n after() {\n this.d = this.d.add(1, this.unit)\n this.d = this.d.startOf(this.unit)\n return this\n }\n // tricky: 'next june' 'next tuesday'\n next() {\n this.d = this.d.add(1, this.unit)\n this.d = this.d.startOf(this.unit)\n return this\n }\n // tricky: 'last june' 'last tuesday'\n last() {\n this.d = this.d.minus(1, this.unit)\n this.d = this.d.startOf(this.unit)\n return this\n }\n}\nmodule.exports = Unit\n","const spacetime = require('spacetime')\nconst Unit = require('./Unit')\n\nclass Day extends Unit {\n constructor(input, unit, context) {\n super(input, unit, context)\n this.unit = 'day'\n }\n}\nclass Month extends Unit {\n constructor(input, unit, context) {\n super(input, unit, context)\n this.unit = 'month'\n }\n}\nclass Quarter extends Unit {\n constructor(input, unit, context) {\n super(input, unit, context)\n this.unit = 'quarter'\n }\n}\nclass Year extends Unit {\n constructor(input, unit, context) {\n super(input, unit, context)\n this.unit = 'year'\n }\n}\nclass WeekDay extends Unit {\n constructor(input, unit, context) {\n super(input, unit, context)\n this.unit = 'week'\n this.d = spacetime(context.today, context.timezone)\n this.d = this.d.day(input)\n this.weekDay = this.d.dayName()\n //assume a wednesday in the future\n if (this.d.date() < spacetime.now(context.timezone).date()) {\n this.d = this.d.add(7, 'days')\n }\n }\n next() {\n this.d = this.d.add(7, 'days')\n this.d = this.d.day(this.weekDay)\n return this\n }\n last() {\n this.d = this.d.minus(7, 'days')\n this.d = this.d.day(this.weekDay)\n return this\n }\n}\n// like 'feb 2'\nclass CalendarDate extends Unit {\n constructor(input, unit, context) {\n super(input, unit, context)\n this.unit = 'day'\n }\n next() {\n this.d = this.d.add(1, 'year')\n return this\n }\n last() {\n this.d = this.d.minus(1, 'year')\n return this\n }\n}\n\nmodule.exports = {\n Unit: Unit,\n Day: Day,\n Month: Month,\n Quarter: Quarter,\n Year: Year,\n WeekDay: WeekDay,\n CalendarDate: CalendarDate,\n}\n","const { Unit } = require('../_units')\n\nconst onlySection = function(doc, context, section) {\n let d = null\n if (doc.found === false) {\n // do we have just a time?\n if (section.time !== null) {\n d = new Unit(context.today, null, context) // choose today\n }\n //do we just have a shift?\n if (Object.keys(section.shift).length > 0) {\n d = new Unit(context.today, null, context) // choose today\n }\n }\n return d\n}\nmodule.exports = onlySection\n","const units = require('../_units')\nconst mapping = {\n week: units.Week,\n month: units.Month,\n quarter: units.Quarter,\n year: units.Year,\n season: units.Season,\n}\n\n// when a unit of time is spoken of as 'this month' - instead of 'february'\nconst namedUnit = function (doc, context) {\n //this month, last quarter, next year\n let m = doc.match('(weekday|week|month|quarter|season|year)')\n if (m.found === true) {\n let str = m.lastTerm().text('reduced')\n if (mapping.hasOwnProperty(str)) {\n let Model = mapping[str]\n if (!Model) {\n return null\n }\n let unit = new Model(null, str, context)\n return unit\n }\n }\n\n //try this version - 'next friday, last thursday'\n m = doc.match('(monday|tuesday|wednesday|thursday|friday|saturday|sunday)')\n if (m.found === true) {\n let str = m.lastTerm().text('reduced')\n let unit = new units.WeekDay(str, null, context)\n return unit\n }\n return null\n}\nmodule.exports = namedUnit\n","(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('spacetime')) :\n typeof define === 'function' && define.amd ? define(['spacetime'], factory) :\n (global = global || self, global.spacetimeHoliday = factory(global.spacetime));\n}(this, function (spacetime) { 'use strict';\n\n spacetime = spacetime && spacetime.hasOwnProperty('default') ? spacetime['default'] : spacetime;\n\n //yep,\n var jan = 'january';\n var feb = 'february';\n var mar = 'march';\n var apr = 'april';\n var may = 'may';\n var jun = 'june';\n var jul = 'july';\n var aug = 'august';\n var sep = 'september';\n var oct = 'october';\n var nov = 'november';\n var dec = 'december';\n var fixedHolidays = {\n 'new years eve': [dec, 31],\n 'new years': [jan, 1],\n 'new years day': [jan, 1],\n 'inauguration day': [jan, 20],\n 'australia day': [jan, 26],\n 'national freedom day': [feb, 1],\n 'groundhog day': [feb, 2],\n 'rosa parks day': [feb, 4],\n 'valentines day': [feb, 14],\n 'saint valentines day': [feb, 14],\n 'st valentines day ': [feb, 14],\n 'saint patricks day': [mar, 17],\n 'st patricks day': [mar, 17],\n 'april fools': [apr, 1],\n 'april fools day': [apr, 1],\n 'emancipation day': [apr, 16],\n 'tax day': [apr, 15],\n //US\n 'labour day': [may, 1],\n 'cinco de mayo': [may, 5],\n 'national nurses day': [may, 6],\n 'harvey milk day': [may, 22],\n 'victoria day': [may, 24],\n juneteenth: [jun, 19],\n 'canada day': [jul, 1],\n 'independence day': [jul, 4],\n 'independents day': [jul, 4],\n 'bastille day': [jul, 14],\n 'purple heart day': [aug, 7],\n 'womens equality day': [aug, 26],\n '16 de septiembre': [sep, 16],\n 'dieciseis de septiembre': [sep, 16],\n 'grito de dolores': [sep, 16],\n halloween: [oct, 31],\n 'all hallows eve': [oct, 31],\n 'day of the dead': [oct, 31],\n // Ranged holiday [nov, 2],\n 'dia de muertos': [oct, 31],\n // Ranged holiday [nov, 2],\n 'veterans day': [nov, 11],\n 'st andrews day': [nov, 30],\n 'saint andrews day': [nov, 30],\n 'all saints day': [nov, 1],\n 'all sts day': [nov, 1],\n 'armistice day': [nov, 11],\n 'rememberance day': [nov, 11],\n 'christmas eve': [dec, 24],\n christmas: [dec, 25],\n xmas: [dec, 25],\n 'boxing day': [dec, 26],\n 'st stephens day': [dec, 26],\n 'saint stephens day': [dec, 26],\n // Fixed religious and cultural holidays\n // Catholic + Christian\n epiphany: [jan, 6],\n 'orthodox christmas day': [jan, 7],\n 'orthodox new year': [jan, 14],\n 'assumption of mary': [aug, 15],\n 'all souls day': [nov, 2],\n 'feast of the immaculate conception': [dec, 8],\n 'feast of our lady of guadalupe': [dec, 12],\n // Kwanzaa\n kwanzaa: [dec, 26],\n // Ranged holiday [jan, 1],\n // Pagan / metal 🤘\n imbolc: [feb, 2],\n beltaine: [may, 1],\n lughnassadh: [aug, 1],\n samhain: [oct, 31]\n };\n\n var fixedDates = function fixedDates(str, normal, year) {\n if (fixedHolidays.hasOwnProperty(str) || fixedHolidays.hasOwnProperty(normal)) {\n var arr = fixedHolidays[str] || fixedHolidays[normal] || [];\n var s = spacetime.now();\n s = s.year(year);\n s = s.startOf('year');\n s = s.month(arr[0]);\n s = s.date(arr[1]);\n\n if (s.isValid()) {\n return s;\n }\n }\n\n return null;\n };\n\n var _01FixedDates = fixedDates;\n\n //these are holidays on the 'nth weekday of month'\n var jan$1 = 'january';\n var feb$1 = 'february';\n var mar$1 = 'march'; // const apr = 'april'\n\n var may$1 = 'may';\n var jun$1 = 'june'; // const jul = 'july'\n // const aug = 'august'\n\n var sep$1 = 'september';\n var oct$1 = 'october';\n var nov$1 = 'november'; // const dec = 'december'\n\n var mon = 'monday'; // const tues = 'tuesday'\n // const wed = 'wednesday'\n\n var thurs = 'thursday';\n var fri = 'friday'; // const sat = 'saturday'\n\n var sun = 'sunday';\n var holidays = {\n 'martin luther king day': [3, mon, jan$1],\n //[third monday in january],\n 'presidents day': [3, mon, feb$1],\n //[third monday in february],\n 'commonwealth day': [2, mon, mar$1],\n //[second monday in march],\n 'mothers day': [2, sun, may$1],\n //[second Sunday in May],\n 'fathers day': [3, sun, jun$1],\n //[third Sunday in June],\n 'labor day': [1, mon, sep$1],\n //[first monday in september],\n 'columbus day': [2, mon, oct$1],\n //[second monday in october],\n 'canadian thanksgiving': [2, mon, oct$1],\n //[second monday in october],\n thanksgiving: [4, thurs, nov$1],\n // [fourth Thursday in November],\n 'black friday': [4, fri, nov$1] //[fourth friday in november],\n // 'memorial day': [may], //[last monday in may],\n // 'us election': [nov], // [Tuesday following the first Monday in November],\n // 'cyber monday': [nov]\n // 'advent': [] // fourth Sunday before Christmas\n\n }; // add aliases\n\n holidays['turday day'] = holidays.thanksgiving;\n holidays['indigenous peoples day'] = holidays['columbus day'];\n holidays['mlk day'] = holidays['martin luther king day'];\n var calendarHolidays = holidays;\n\n var fixedDates$1 = function fixedDates(str, normal, year) {\n if (calendarHolidays.hasOwnProperty(str) || calendarHolidays.hasOwnProperty(normal)) {\n var arr = calendarHolidays[str] || calendarHolidays[normal] || [];\n var s = spacetime.now();\n s = s.year(year); // [3rd, 'monday', 'january']\n\n s = s.month(arr[2]);\n s = s.startOf('month'); // make it january\n\n var month = s.month(); // make it the 1st monday\n\n s = s.day(arr[1]);\n\n if (s.month() !== month) {\n s = s.add(1, 'week');\n } // make it nth monday\n\n\n if (arr[0] > 1) {\n s = s.add(arr[0] - 1, 'week');\n }\n\n if (s.isValid()) {\n return s;\n }\n }\n\n return null;\n };\n\n var _02NthWeekday = fixedDates$1;\n\n // https://www.timeanddate.com/calendar/determining-easter-date.html\n var dates = {\n easter: 0,\n 'ash wednesday': -46,\n // (46 days before easter)\n 'palm sunday': 7,\n // (1 week before easter)\n 'maundy thursday': -3,\n // (3 days before easter)\n 'good friday': -2,\n // (2 days before easter)\n 'holy saturday': -1,\n // (1 days before easter)\n 'easter saturday': -1,\n // (1 day before easter)\n 'easter monday': 1,\n // (1 day after easter)\n 'ascension day': 39,\n // (39 days after easter)\n 'whit sunday': 49,\n // / pentecost (49 days after easter)\n 'whit monday': 50,\n // (50 days after easter)\n 'trinity sunday': 65,\n // (56 days after easter)\n 'corpus christi': 60,\n // (60 days after easter)\n 'mardi gras': -47 //(47 days before easter)\n\n };\n dates['easter sunday'] = dates.easter;\n dates['pentecost'] = dates['whit sunday'];\n dates['whitsun'] = dates['whit sunday'];\n var easterHolidays = dates;\n\n // by John Dyer\n // based on the algorithm by Oudin (1940) from http://www.tondering.dk/claus/cal/easter.php\n var calcEaster = function calcEaster(year) {\n var f = Math.floor,\n // Golden Number - 1\n G = year % 19,\n C = f(year / 100),\n // related to Epact\n H = (C - f(C / 4) - f((8 * C + 13) / 25) + 19 * G + 15) % 30,\n // number of days from 21 March to the Paschal full moon\n I = H - f(H / 28) * (1 - f(29 / (H + 1)) * f((21 - G) / 11)),\n // weekday for the Paschal full moon\n J = (year + f(year / 4) + I + 2 - C + f(C / 4)) % 7,\n // number of days from 21 March to the Sunday on or before the Paschal full moon\n L = I - J,\n month = 3 + f((L + 40) / 44),\n date = L + 28 - 31 * f(month / 4);\n month = month === 4 ? 'April' : 'March';\n return month + ' ' + date;\n };\n\n var calcEaster_1 = calcEaster;\n\n var easterDates = function easterDates(str, normal, year) {\n if (easterHolidays.hasOwnProperty(str) || easterHolidays.hasOwnProperty(normal)) {\n var days = easterHolidays[str] || easterHolidays[normal] || [];\n var date = calcEaster_1(year);\n\n if (!date) {\n return null; //no easter for this year\n }\n\n var e = spacetime(date);\n e = e.year(year);\n var s = e.add(days, 'day');\n\n if (s.isValid()) {\n return s;\n }\n }\n\n return null;\n };\n\n var _03EasterDates = easterDates;\n\n // http://www.astropixels.com/ephemeris/soleq2001.html\n // years 2000-2100\n var exceptions = {\n spring: [2003, 2007, 2044, 2048, 2052, 2056, 2060, 2064, 2068, 2072, 2076, 2077, 2080, 2081, 2084, 2085, 2088, 2089, 2092, 2093, 2096, 2097],\n summer: [2021, 2016, 2020, 2024, 2028, 2032, 2036, 2040, 2041, 2044, 2045, 2048, 2049, 2052, 2053, 2056, 2057, 2060, 2061, 2064, 2065, 2068, 2069, 2070, 2072, 2073, 2074, 2076, 2077, 2078, 2080, 2081, 2082, 2084, 2085, 2086, 2088, 2089, 2090, 2092, 2093, 2094, 2096, 2097, 2098, 2099],\n fall: [2002, 2003, 2004, 2006, 2007, 2010, 2011, 2014, 2015, 2018, 2019, 2022, 2023, 2026, 2027, 2031, 2035, 2039, 2043, 2047, 2051, 2055, 2059, 2092, 2096],\n winter: [2002, 2003, 2006, 2007, 2011, 2015, 2019, 2023, 2027, 2031, 2035, 2039, 2043, 2080, 2084, 2088, 2092, 2096]\n };\n var winter20th = [2080, 2084, 2088, 2092, 2096];\n\n var calcSeasons = function calcSeasons(year) {\n // most common defaults\n var res = {\n spring: 'March 20 ' + year,\n summer: 'June 21 ' + year,\n fall: 'Sept 22 ' + year,\n winter: 'Dec 21 ' + year\n };\n\n if (exceptions.spring.indexOf(year) !== -1) {\n res.spring = 'March 19 ' + year;\n }\n\n if (exceptions.summer.indexOf(year) !== -1) {\n res.summer = 'June 20 ' + year;\n }\n\n if (exceptions.fall.indexOf(year) !== -1) {\n res.fall = 'Sept 21 ' + year;\n } // winter can be 20th, 21st, or 22nd\n\n\n if (exceptions.winter.indexOf(year) !== -1) {\n res.winter = 'Dec 22 ' + year;\n }\n\n if (winter20th.indexOf(year) !== -1) {\n res.winter = 'Dec 20 ' + year;\n }\n\n return res;\n };\n\n var seasons = calcSeasons;\n\n // these are properly calculated in ./lib/seasons\n var dates$1 = {\n 'spring equinox': 'spring',\n 'summer solistice': 'summer',\n 'fall equinox': 'fall',\n 'winter solstice': 'winter'\n }; // aliases\n\n dates$1['march equinox'] = dates$1['spring equinox'];\n dates$1['vernal equinox'] = dates$1['spring equinox'];\n dates$1['ostara'] = dates$1['spring equinox'];\n dates$1['june solstice'] = dates$1['summer solistice'];\n dates$1['litha'] = dates$1['summer solistice'];\n dates$1['autumn equinox'] = dates$1['fall equinox'];\n dates$1['autumnal equinox'] = dates$1['fall equinox'];\n dates$1['september equinox'] = dates$1['fall equinox'];\n dates$1['sept equinox'] = dates$1['fall equinox'];\n dates$1['mabon'] = dates$1['fall equinox'];\n dates$1['december solstice'] = dates$1['winter solistice'];\n dates$1['dec solstice'] = dates$1['winter solistice'];\n dates$1['yule'] = dates$1['winter solistice'];\n var astroHolidays = dates$1;\n\n var astroDates = function astroDates(str, normal, year) {\n if (astroHolidays.hasOwnProperty(str) || astroHolidays.hasOwnProperty(normal)) {\n var season = astroHolidays[str] || astroHolidays[normal];\n var seasons$1 = seasons(year);\n\n if (!season || !seasons$1 || !seasons$1[season]) {\n return null; // couldn't figure it out\n }\n\n var s = spacetime(seasons$1[season]);\n\n if (s.isValid()) {\n return s;\n }\n }\n\n return null;\n };\n\n var _04Astronomical = astroDates;\n\n var dates$2 = {\n // Muslim holidays\n 'isra and miraj': 'april 13',\n 'lailat al-qadr': 'june 10',\n 'eid al-fitr': 'june 15',\n 'id al-Fitr': 'june 15',\n 'eid ul-Fitr': 'june 15',\n ramadan: 'may 16',\n // Range holiday\n 'eid al-adha': 'sep 22',\n muharram: 'sep 12',\n 'prophets birthday': 'nov 21'\n };\n var lunarHolidays = dates$2;\n\n var dayDiff = -10.64;\n\n var lunarDates = function lunarDates(str, normal, year) {\n if (lunarHolidays.hasOwnProperty(str) || lunarHolidays.hasOwnProperty(normal)) {\n var date = lunarHolidays[str] || lunarHolidays[normal] || [];\n\n if (!date) {\n return null;\n } // start at 2018\n\n\n var s = spacetime(date + ' 2018');\n var diff = year - 2018;\n var toAdd = diff * dayDiff;\n s = s.add(toAdd, 'day');\n s = s.startOf('day'); // now set the correct year\n\n s = s.year(year);\n\n if (s.isValid()) {\n return s;\n }\n }\n\n return null;\n };\n\n var _05LunarDates = lunarDates;\n\n var nowYear = spacetime.now().year();\n\n var spacetimeHoliday = function spacetimeHoliday(str, year) {\n year = year || nowYear;\n str = str || '';\n str = String(str);\n str = str.trim().toLowerCase();\n str = str.replace(/'s/, 's'); // 'mother's day'\n\n var normal = str.replace(/ day$/, '');\n normal = normal.replace(/^the /, '');\n normal = normal.replace(/^orthodox /, ''); //orthodox good friday\n // try easier, unmoving holidays\n\n var s = _01FixedDates(str, normal, year);\n\n if (s !== null) {\n return s;\n } // try 'nth monday' holidays\n\n\n s = _02NthWeekday(str, normal, year);\n\n if (s !== null) {\n return s;\n } // easter-based holidays\n\n\n s = _03EasterDates(str, normal, year);\n\n if (s !== null) {\n return s;\n } // solar-based holidays\n\n\n s = _04Astronomical(str, normal, year);\n\n if (s !== null) {\n return s;\n } // mostly muslim holidays\n\n\n s = _05LunarDates(str, normal, year);\n\n if (s !== null) {\n return s;\n }\n\n return null;\n };\n\n var src = spacetimeHoliday;\n\n return src;\n\n}));\n//# sourceMappingURL=spacetime-holiday.js.map\n","const { CalendarDate } = require('../_units')\nconst spacetimeHoliday = require('spacetime-holiday')\n\nconst parseHoliday = function(doc, context) {\n let d = null\n let str = doc.match('#Holiday+').text('reduced')\n let year = 2020 //change me!\n let s = spacetimeHoliday(str, year)\n if (s !== null) {\n d = new CalendarDate(s, null, context)\n }\n return d\n}\nmodule.exports = parseHoliday\n","const { Unit, Day, CalendarDate, Month } = require('../_units')\nconst tryHere = require('../../../../../src/Phrase/match/03-tryMatch')\n\nconst knownWord = {\n today: (context) => {\n return new Day(context.today, null, context)\n },\n yesterday: (context) => {\n return new Day(context.today.minus(1, 'day'), null, context)\n },\n tomorrow: (context) => {\n return new Day(context.today.plus(1, 'day'), null, context)\n },\n}\n\n// parse things like 'june 5th 2019'\n// most of this is done in spacetime\nconst parseExplicit = function (doc, context) {\n let impliedYear = context.today.year()\n\n // 'fifth of june 1992'\n let m = doc.match('[#Value] of? [#Month] [#Year]')\n // 'june the fifth 1992'\n if (!m.found) {\n m = doc.match('[#Month] the? [#Value] [#Year]')\n }\n if (m.found) {\n let obj = {\n month: m.groups('month').text(),\n date: m.groups('date').text(),\n year: m.groups('year').text() || impliedYear,\n }\n let d = new CalendarDate(obj, null, context)\n if (d.d.isValid() === true) {\n return d\n }\n }\n\n //no-dates\n // 'march 1992'\n m = doc.match('[#Month] of? [#Year]')\n if (m.found) {\n let obj = {\n month: m.groups('month').text(),\n year: m.groups('year').text() || impliedYear,\n }\n let d = new Month(obj, null, context)\n if (d.d.isValid() === true) {\n return d\n }\n }\n //no-years\n // 'fifth of june'\n m = doc.match('[#Value] of? [#Month]')\n // 'june the fifth'\n if (!m.found) {\n m = doc.match('[#Month] the? [#Value]')\n }\n // support 'dec 5th'\n if (m.found) {\n let obj = {\n month: m.groups('month').text(),\n date: m.groups('date').text(),\n year: context.today.year(),\n }\n let d = new CalendarDate(obj, null, context)\n if (d.d.isValid() === true) {\n return d\n }\n }\n // support 'december'\n if (doc.has('#Month')) {\n let obj = {\n month: doc.match('#Month').text(),\n date: 1, //assume 1st\n year: context.today.year(),\n }\n let d = new CalendarDate(obj, null, context)\n if (d.d.isValid() === true) {\n return d\n }\n }\n\n // support date-only 'the 21st'\n m = doc.match('the [#Value]')\n if (m.found) {\n let obj = {\n month: context.today.month(),\n date: m.groups('date').text(),\n year: context.today.year(),\n }\n let d = new CalendarDate(obj, null, context)\n if (d.d.isValid() === true) {\n return d\n }\n }\n let str = doc.text('reduced')\n // today, yesterday, tomorrow\n if (knownWord.hasOwnProperty(str) === true) {\n let d = knownWord[str](context)\n return d\n }\n // punt it to spacetime, for the heavy-lifting\n let d = new Unit(str, null, context)\n // did we find a date?\n if (d.d.isValid() === false) {\n return null\n }\n return d\n}\nmodule.exports = parseExplicit\n","const section = {\n shift: require('./sections/01-shift'),\n time: require('./sections/02-time'),\n relative: require('./sections/03-relative'),\n timezone: require('./sections/04-timezone'),\n}\n\nconst steps = {\n implied: require('./steps/00-implied'),\n duration: require('./steps/01-duration'),\n holiday: require('./steps/02-holidays'),\n explicit: require('./steps/03-explicit'),\n}\n\nconst parseDate = function (doc, context) {\n //parse-out any sections\n let shift = section.shift(doc)\n let tz = section.timezone(doc)\n let time = section.time(doc, context)\n let rel = section.relative(doc)\n //set our new timezone\n if (tz) {\n context = Object.assign({}, context, { timezone: tz })\n let iso = context.today.format('iso-short')\n context.today = context.today.goto(context.timezone).set(iso)\n }\n let d = null\n\n //'in two days'\n d = d || steps.implied(doc, context, { shift, time, rel })\n // 'this month'\n d = d || steps.duration(doc, context)\n // 'this haloween'\n d = d || steps.holiday(doc, context)\n // 'this june 2nd'\n d = d || steps.explicit(doc, context)\n\n if (typeof process !== undefined && process && process.env.DEBUG) {\n console.log('\\n\\n=-=-=-=-=-=Date-=-=-=-=-=-=-')\n console.log(` shift: ${JSON.stringify(shift)}`)\n console.log(` rel: ${rel || '-'}`)\n console.log(` time: ${time || '-'}`)\n console.log(`\\n str: '${doc.text()}'`)\n console.log('\\n ', d)\n console.log('=-=-=-=-=-=-=-=-=-=-=-=-=-=-\\n\\n')\n }\n\n if (!d) {\n return null\n }\n\n // // apply relative\n if (rel === 'last') {\n d.last()\n }\n if (rel === 'next') {\n d.next()\n }\n // apply shift\n if (shift) {\n d.applyShift(shift)\n }\n\n // apply time\n d.applyTime(time)\n\n return d\n}\nmodule.exports = parseDate\n","const parseDate = require('../03-parseDate')\nconst Unit = require('../03-parseDate/Unit')\n\nconst punt = function (unit, context) {\n unit = unit.applyShift(context.casual_duration)\n return unit\n}\n\n//\nconst logic = function (doc, context) {\n // two explicit dates - 'between friday and sunday'\n let m = doc.match('between [*] and [*]')\n if (m.found) {\n let start = m.groups('start')\n start = parseDate(start, context)\n let end = m.groups('end')\n end = parseDate(end, context)\n if (start) {\n return {\n start: start,\n end: end,\n }\n }\n }\n\n // two months, no year - 'june 5 to june 7'\n m = doc.match('[#Month #Value] to [#Month #Value] [#Year?]')\n if (m.found) {\n let res = m.groups()\n let start = res.from\n if (res.year) {\n start = start.concat(res.year)\n }\n start = parseDate(start, context)\n if (start) {\n let end = res.to\n if (res.year) {\n end = end.concat(res.year)\n }\n end = parseDate(end, context)\n return {\n start: start,\n end: end,\n }\n }\n }\n // one month, one year, first form - 'january 5 to 7 1998'\n m = doc.match('[#Month] [#Value] to [#Value] of? [#Year]')\n if (m.found) {\n let res = m.groups()\n let start = res.month.concat(res.from, res.year)\n start = parseDate(start, context)\n if (start) {\n let end = res.month.concat(res.to, res.year)\n end = parseDate(end, context)\n return {\n start: start,\n end: end,\n }\n }\n }\n // one month, one year, second form - '5 to 7 of january 1998'\n m = doc.match('[#Value] to [#Value of? #Month of? #Year]')\n if (m.found) {\n let to = m.groups('to')\n to = parseDate(to, context)\n if (to) {\n let fromDate = m.groups('to')\n let from = to.clone()\n from.d = from.d.date(fromDate.text('normal'))\n return {\n start: from,\n end: to,\n }\n }\n }\n // one month, no year - '5 to 7 of january'\n m = doc.match('[#Value] to [#Value of? #Month]')\n if (m.found) {\n let to = m.groups('to')\n to = parseDate(to, context)\n if (to) {\n let fromDate = m.groups('from')\n let from = to.clone()\n from.d = from.d.date(fromDate.text('normal'))\n return {\n start: from,\n end: to,\n }\n }\n }\n // one month, no year - 'january 5 to 7'\n m = doc.match('[#Month #Value] to [#Value]')\n if (m.found) {\n let from = m.groups('from')\n from = parseDate(from, context)\n if (from) {\n let toDate = m.groups('to')\n let to = from.clone()\n to.d = to.d.date(toDate.text('normal'))\n return {\n start: from,\n end: to,\n }\n }\n }\n // 'from A to B'\n m = doc.match('from? [*] (to|@hasHyphen|until|upto) [*]')\n if (m.found) {\n let from = m.groups('from')\n let to = m.groups('to')\n from = parseDate(from, context)\n to = parseDate(to, context)\n if (from && to) {\n return {\n start: from,\n end: to,\n }\n }\n }\n // 'before june'\n m = doc.match('^due (by|before|on|in)? [*]', 0)\n if (m.found) {\n let d = parseDate(m, context)\n if (d) {\n const today = new Unit(context.today, null, context)\n return {\n start: today,\n end: punt(d.clone(), context),\n }\n }\n }\n // 'after june'\n m = doc.match('^(after|following|from) [*]', 0)\n if (m.found) {\n let d = parseDate(m, context)\n if (d) {\n return {\n start: d,\n end: punt(d.clone(), context),\n }\n }\n }\n // 'in june'\n m = doc.match('^(on|during|in) [*]', 0)\n if (m.found) {\n let d = parseDate(m, context)\n if (d) {\n return {\n start: d,\n end: d.clone().end(),\n }\n }\n }\n //else, try whole thing\n let d = parseDate(doc, context)\n return {\n start: d,\n end: d.clone().end(),\n }\n}\nmodule.exports = logic\n","const spacetime = require('spacetime')\nconst normalize = require('./00-normalize')\nconst parseRanges = require('./01-parse-range')\n\nconst getDate = function (doc, context) {\n // validate context a bit\n context = context || {}\n\n context.timezone = context.timezone || 'ETC/UTC'\n context.today = spacetime(context.today || null, context.timezone)\n //turn 'five' into 5..\n doc = normalize(doc)\n //interpret 'between [A] and [B]'...\n return parseRanges(doc, context)\n}\nmodule.exports = getDate\n","let arr = [\n ['mon', 'monday'],\n ['tue', 'tuesday'],\n ['tues', 'tuesday'],\n ['wed', 'wednesday'],\n ['thu', 'thursday'],\n ['thurs', 'thursday'],\n ['fri', 'friday'],\n ['sat', 'saturday'],\n ['sun', 'sunday'],\n\n ['jan', 'january'],\n ['feb', 'february'],\n ['mar', 'march'],\n ['apr', 'april'],\n ['jun', 'june'],\n ['jul', 'july'],\n ['aug', 'august'],\n ['sep', 'september'],\n ['sept', 'september'],\n ['oct', 'october'],\n ['nov', 'november'],\n ['dec', 'december'],\n]\n\narr = arr.map(a => {\n return { short: a[0], long: a[1] }\n})\n\nmodule.exports = arr\n","const parse = require('./02-getDate')\nconst abbrevs = require('./data/_abbrevs')\n\nmodule.exports = {\n /** overload the original json with noun information */\n json: function (options) {\n let n = null\n if (typeof options === 'number') {\n n = options\n options = null\n }\n options = options || { terms: false }\n let res = []\n let format = options.format || 'iso'\n this.forEach((doc) => {\n let json = doc.json(options)[0]\n let obj = parse(doc, this.context)\n let start = obj.start ? obj.start.format(format) : null\n let end = obj.end ? obj.end.format(format) : null\n // set iso strings to json result\n json.date = {\n start: start,\n end: end,\n }\n // add duration\n if (start && end) {\n json.date.duration = obj.start.d.diff(obj.end.d)\n // we don't need these\n delete json.date.duration.milliseconds\n delete json.date.duration.seconds\n }\n res.push(json)\n })\n if (n !== null) {\n return res[n]\n }\n return res\n },\n\n /** render all dates according to a specific format */\n format: function (fmt) {\n this.forEach((doc) => {\n let obj = parse(doc, this.context)\n let str = ''\n if (obj.start) {\n str = obj.start.format(fmt)\n if (obj.end) {\n let end = obj.start.format(fmt)\n if (str !== end) {\n str += ' to ' + end\n }\n }\n doc.replaceWith(str, { keepTags: true, keepCase: false })\n }\n })\n return this\n },\n /** replace 'Fri' with 'Friday', etc*/\n toLongForm: function () {\n abbrevs.forEach((a) => {\n this.replace(a.short, a.long, true)\n })\n return this\n },\n /** replace 'Friday' with 'Fri', etc*/\n toShortForm: function () {\n abbrevs.forEach((a) => {\n this.replace(a.long, a.short, true)\n })\n return this\n },\n}\n","const tagger = require('./01-tag')\nconst tags = require('./data/_tags')\nconst words = require('./data/words')\nconst methods = require('./methods')\nconst spacetime = require('spacetime')\n\nconst addMethods = function (Doc, world) {\n // our new tags\n world.addTags(tags)\n // add info for the date plugin\n world.addWords(words)\n // run our tagger\n world.postProcess(tagger)\n\n /** */\n class Dates extends Doc {\n constructor(list, from, w) {\n super(list, from, w)\n this.context = {\n casual_duration: { weeks: 2 },\n }\n }\n }\n //add-in methods\n Object.assign(Dates.prototype, methods)\n\n Doc.prototype.dates = function (n) {\n let context = {}\n if (n && typeof n === 'object') {\n context = n\n n = null\n }\n let r = this.clauses()\n let dates = r.match('#Date+')\n if (typeof n === 'number') {\n dates = dates.get(n)\n }\n if (typeof n === 'number') {\n dates = dates.get(n)\n }\n let d = new Dates(dates.list, this, this.world)\n if (context.today) {\n context.today = spacetime(context.today, context.timezone)\n }\n d.context = context\n return d\n }\n}\n\nmodule.exports = addMethods\n"],"names":["preps","thisNext","sections","seasons","tagYear","m","reason","found","term","termList","num","parseInt","clean","tag","tagYearSafe","fixDates","doc","match","month","val","ifNo","duration","unTag","season","date","not","cardinal","v","time","here","values","replaceWith","has","dateTagger","sectionTagger","timeTagger","shiftTagger","fixUp","oops","d","knownDate","lastTerm","terms","methods","require$$0","require$$1","require$$2","require$$3","require$$4","require$$5","require$$6","tagDate","forEach","fn","FinancialQuarter","isA","Season","Year","notA","Duration","Holiday","Timezone","DateShift","createCommonjsModule","module","exports","getCjsExportFromNamespace","n","fns","isLeapYear","year","isDate","Object","prototype","toString","call","isNaN","valueOf","isArray","input","isObject","zeroPad","str","len","arguments","length","undefined","pad","Array","join","titleCase","toUpperCase","substr","ordinal","i","j","k","toCardinal","String","replace","normalize","toLowerCase","trim","getEpoch","tmp","getTime","epoch","beADate","s","clone","set","formatTimezone","offset","delimiter","absOffset","Math","abs","sign","concat","fns_1","fns_2","fns_3","fns_4","fns_5","fns_6","fns_7","fns_8","fns_9","fns_10","fns_11","fns_12","serialize","getMonth","getDate","getHours","shouldChange","start","end","defaultOffset","Date","bias","getTimezoneOffset","shift","current","summerTime","quickOffset","zones","timezones","obj","tz","console","warn","dst","jul","dec","hem","split","inSummer","quick","_build","_build$1","freeze","__proto__","_prefixes","data","all","keys","Number","names","before","name","unpack","fallbackTZ","safeIntl","Intl","DateTimeFormat","format","resolvedOptions","timezone","timeZone","guessTz","guessTz_1","isOffset","isNumber","utcOffset","gmtOffset","toIana","parseOffset","parseOffset_1","local","cities","reduce","h","city","lookupTz","hasOwnProperty","test","id","Error","find","o","millisecond","second","minute","hour","day","week","milliseconds","walk","unit","previous","startUnit","original","diff","halfStep","units","valid","walkTo","getFullYear","seconds","wants","old","silent","walk_1","shortMonths","longMonths","buildMapping","sep","_i","months","short","long","mapping","i18n","parseOffset$1","parseFloat","parseOffset_1$1","parseTime","arr","startOf","ampm","_h","parseTime_1","monthLengths","monthLengths_1","hasDate","max","hasDate_1","months$1","parseYear","today","strFmt","reg","parse","givenTz","options","british","_today","strParse","getNow","now","dates","tonight","tomorrow","add","yesterday","subtract","christmas","newYears","namedDates","minimumEpoch","defaults","handleArray","order","handleObject","assign","parseInput","res","isValid","_res","shortDays","longDays","days","isoOffset","isNegative","floor","ceil","_offset","dayName","dayShort","dayNumber","dayOrdinal","dayPad","dateOrdinal","datePad","monthName","monthShort","monthNumber","monthOrdinal","monthPad","isoMonth","yearShort","isoYear","time24","hour24","hour12","hourPad","hour24Pad","minutePad","secondPad","quarter","era","json","numeric","numericUs","numericUk","mmDd","iso","h24","ms","isoShort","isoUtc","toISOString","nice","niceYear","niceDay","niceFull","aliases","mdy","dmy","ymd","printFormat","out","indexOf","_","fmt","format_1","G","GG","GGG","GGGG","y","yy","yyy","yyyy","yyyyy","Q","QQ","QQQ","QQQQ","M","MM","MMM","MMMM","w","ww","dd","D","dayOfYear","DD","DDD","E","EE","EEE","EEEE","EEEEE","e","ee","eee","eeee","eeeee","a","aa","aaa","aaaa","h12","hh","H","HH","mm","_s","ss","A","z","zz","zzz","zzzz","Z","ZZ","ZZZ","ZZZZ","addAlias","_char","to","toName","unixFmt","chars","quoteOn","push","txt","c","unixFmt_1","units$1","doUnit","endOf","percent","toFixed","progress","progress_1","nearest","prog","nearest_1","climb","b","isBefore","isAfter","diffOne","one","fastYear","years","msDiff","minutes","hours","weeks","waterfall","reverseDiff","main","reversed","diff$1","qualifiers","almost","over","getDiff","later","earlier","isSame","u","pluralize","value","slice","since","isNow","every","rounded","qualified","precise","englishValues","englishValue","nextUnit","nextValue","splice","since_1","north","south","quarters","units$2","quarterhour","_weekStart","q","hemisphere","decade","century","startOf_1","isDay","next","result","every_1","parseDst","epochShift","hasDst","Boolean","default_offset","change","back","summer","winter","isDST","timezone_1","units$3","input$1","hasDST","leapYear","last","goto","isAwake","isAsleep","log","logYear","_this","debug","from","fromNow","weekStart","inDST","round","each","methods_1","isLeapYear$1","validate","confirm","want","methods$1","getMilliseconds","getSeconds","getMinutes","hourFloat","_minute","_hour","which","dayTime","times","morning","breakfast","noon","lunch","afternoon","evening","dinner","night","midnight","_01Time","methods$2","getDay","_02Date","clearMinutes","methods$3","sum","setDate","setFullYear","setHours","setMinutes","setMonth","toAdd","minus","thisOne","skipWeeks","_month","millenium","_03Year","methods$4","addMethods","Space","query","isLeapYear$2","getMonthLength","rollMonth","_years","rollDaysDown","rollDaysUp","_model","daysBack","order$1","keep","dstAwareUnits","keepDate","addMethods$1","SpaceTime","_sum","plus","print","addMethods$2","same","addMethods$3","isEqual","isBetween","isInclusive","startEpoch","endEpoch","compare","addMethods$4","defineProperty","get","toLocalDate","spacetime","whereIts","startHour","endHour","tzs","filter","whereIts_1","_version","main$1","setToday","extend","version","plugin","src","america","asia","europe","africa","aus","pac","informal","bst","ireland","cet","cest","eet","eest","trt","etc","utc","gmt","sast","acst","acdt","aest","aedt","awst","awdt","acwst","lhst","lhdt","msk","russian","cst","cdt","mst","mdt","ast","adt","est","edt","pst","pdt","ahst","ahdt","hst","nst","ndt","brt","brasília","brasilia","amt","east","easst","vet","pyt","pyst","cot","clst","cldt","uyt","ist","irst","irdt","iranian","pkt","ict","ct","almt","yakt","gst","uae","hkt","wib","wita","idt","israeli","krat","myt","sgt","kst","uzt","vlat","mvt","mut","mht","sst","chst","pgt","iana","formal","lex","numbers","toNumber","adverbs","remove","knownUnits","parseShift","ts","text","hardCoded","daybreak","lunchtime","dinnertime","halfPast","mins","behind","context","timeStr","parseRelative","rel","parseTimezone","Unit","enumerable","writable","Day","Month","Quarter","WeekDay","weekDay","CalendarDate","onlySection","section","Week","namedUnit","Model","define","feb","apr","nov","parseHoliday","spacetimeHoliday","knownWord","parseExplicit","impliedYear","groups","relative","steps","implied","holiday","explicit","require$$7","parseDate","process","env","DEBUG","JSON","stringify","applyShift","applyTime","punt","casual_duration","logic","fromDate","toDate","parseRanges","map","keepTags","keepCase","toLongForm","abbrevs","toShortForm","Doc","world","addTags","tags","addWords","words","postProcess","tagger","Dates","list","r","clauses"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAAA;EACA,IAAMA,KAAK,GAAG,oDAAd;;EACA,IA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EACD;;EACD,QAAI,OAAOA,CAAP,KAAa,QAAjB,EAA2B;EACzBkM,MAAAA,KAAK,GAAGA,KAAK,CAACsT,GAAN,CAAUxf,CAAV,CAAR;EACD;;EACD,QAAI5B,CAAC,GAAG,IAAI0sB,KAAJ,CAAU5e,KAAK,CAAC6e,IAAhB,EAAsB,IAAtB,EAA4B,KAAKR,KAAjC,CAAR;;EACA,QAAIxD,OAAO,CAACxb,KAAZ,EAAmB;EACjBwb,MAAAA,OAAO,CAACxb,KAAR,GAAgBmU,WAAS,CAACqH,OAAO,CAACxb,KAAT,EAAgBwb,OAAO,CAAChgB,QAAxB,CAAzB;EACD;;EACD3I,IAAAA,CAAC,CAAC2oB,OAAF,GAAYA,OAAZ;EACA,WAAO3oB,CAAP;EACD,GApBD;EAqBD,CAzCD;;WA2Cc,GAAGqf;;;;;;;;"} \ No newline at end of file diff --git a/plugins/dates/builds/compromise-dates.min.js b/plugins/dates/builds/compromise-dates.min.js index 4b371701d..b7b921fef 100644 --- a/plugins/dates/builds/compromise-dates.min.js +++ b/plugins/dates/builds/compromise-dates.min.js @@ -1 +1 @@ -!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t=t||self).compromiseDates=e()}(this,(function(){"use strict";function t(e){return(t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(e)}function e(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function a(t,e){for(var a=0;a1e3&&n<3e3&&t.tag("Year",e)}}},f="date-values",y="date-tagger",p="section-tagger",g="time-tagger",v="shift-tagger",b="fix-tagger",w=[function(t){t.match("in the (night|evening|morning|afternoon|day|daytime)").tag("Time","in-the-night"),t.match("(#Value|#Time) (am|pm)").tag("Time","value-ampm");var e=t.if("#Month");!0===e.found&&(e.match("#Month #Date+").tag("Date","correction-numberRange"),e.match("#Value of #Month").tag("Date","value-of-month"),e.match("#Cardinal #Month").tag("Date","cardinal-month"),e.match("#Month #Value to #Value").tag("Date","value-to-value"),e.match("#Month the #Value").tag("Date","month-the-value"));var a=t.if("#Value");if(!0===a.found){a.match("(#WeekDay|#Month) #Value").ifNo("#Money").tag("Date","date-value"),a.match("#Value (#WeekDay|#Month)").ifNo("#Money").tag("Date","value-date"),a.match("#TextValue #TextValue").if("#Date").tag("#Date","textvalue-date");var n=a.if("#Duration");!0===n.found&&(n.match("for #Value #Duration").tag("Date","for-x-duration"),n.match("#Value #Duration #Conjunction").tag("Date","val-duration-conjunction"),n.match("".concat(c,"? #Value #Duration")).tag("Date","value-duration"),n.match("#Value #Duration old").unTag("Date","val-years-old"))}var r=t.if(h);!0===r.found&&(r.match("".concat(c,"? ").concat(d," ").concat(h)).tag("Date","thisNext-season"),r.match("the? ".concat(l," of ").concat(h)).tag("Date","section-season"),r.match("".concat(h," ").concat(c,"? #Cardinal")).tag("Date","season-year"));var o=t.if("#Date");!0===o.found&&(o.match("#Date the? #Ordinal").tag("Date","correction"),o.match("".concat(d," #Date")).tag("Date","thisNext"),o.match("due? (by|before|after|until) #Date").tag("Date","by"),o.match("(last|next|this|previous|current|upcoming|coming|the) #Date").tag("Date","next-feb"),o.match("the? ".concat(l," of #Date")).tag("Date","section-of"),o.match("#Ordinal #Duration in #Date").tag("Date","duration-in"),o.match("(early|late) (at|in)? the? #Date").tag("Time","early-evening"),o.match("#Date (by|before|after|at|@|about) #Cardinal").not("^#Date").tag("Time","date-before-Cardinal"),o.match("#Date [(am|pm)]",0).unTag("Verb").unTag("Copula").tag("Time","date-am"),o.match("#Date (#Preposition|to) #Date").ifNo("#Duration").tag("Date","date-prep-date"));var i=t.if("#Cardinal");if(!0===i.found){var u=i.match("#Date #Value [#Cardinal]",0);m(u,"date-value-year"),u=i.match("#Date+ [#Cardinal]",0),m(u,"date-year"),u=i.match("#Month #Value [#Cardinal]",0),m(u,"month-value-year"),u=i.match("#Month #Value to #Value [#Cardinal]",0),m(u,"month-range-year"),u=i.match("(in|of|by|during|before|starting|ending|for|year) [#Cardinal]",0),m(u,"in-year"),u=i.match("(q1|q2|q3|q4) [#Cardinal]",0),m(u,"in-year"),u=i.match("#Ordinal quarter [#Cardinal]",0),m(u,"in-year"),u=i.match("the year [#Cardinal]",0),m(u,"in-year"),function(t,e){if(!0===t.found){var a=t.termList()[0];if(a){var n=parseInt(a.clean,10);n&&n>1900&&n<2030&&t.tag("Year",e)}}}(u=i.match("it (is|was) [#Cardinal]",0),"in-year")}var s=t.if("#Time");return!0===s.found&&(s.match("(by|before|after|at|@|about) #Time").tag("Time","preposition-time"),s.match("#Cardinal #Time").not("#Year").tag("Time","value-time"),s.match("#Time [(eastern|pacific|central|mountain)]",0).tag("Date","timezone"),s.match("#Time [(est|pst|gmt)]",0).tag("Date","timezone abbr")),t},function(t){return t.has("#Value")&&(t.match("#Month #Value to #Value of? #Year?").tag("Date",f),t.match("#Value to #Value of? #Month #Year?").tag("Date",f),t.match("#Value #Duration of #Date").tag("Date",f),t.match("#Value+ #Duration (after|before|into|later|afterwards|ago)?").tag("Date",f),t.match("#Value #Date").tag("Date",f),t.match("#Date #Value").tag("Date",f),t.match("#Date #Preposition #Value").tag("Date",f),t.match("#Date (after|before|during|on|in) #Value").tag("Date",f),t.match("#Value (year|month|week|day) and a half").tag("Date",f),t.match("#Value and a half (years|months|weeks|days)").tag("Date",f),t.match("on the #Ordinal").tag("Date",f)),t},function(t){return t.match("(spring|summer|winter|fall|autumn|springtime|wintertime|summertime)").match("#Noun").tag("Season",y),t.match("(q1|q2|q3|q4)").tag("FinancialQuarter",y),t.match("(this|next|last|current) quarter").tag("FinancialQuarter",y),t.match("(this|next|last|current) season").tag("Season",y),t.has("#Date")&&(t.match("#Date #Preposition #Date").tag("Date",y),t.match("(once|twice) (a|an|each) #Date").tag("Date",y),t.match("(by|until|on|in|at|during|over|every|each|due) the? #Date").tag("Date",y),t.match("#Date+").tag("Date",y),t.match("(by|until|on|in|at|during|over|every|each|due) the? #Date").tag("Date",y),t.match("a #Duration").tag("Date",y),t.match("(between|from) #Date").tag("Date",y),t.match("(to|until|upto) #Date").tag("Date",y),t.match("#Date and #Date").tag("Date",y),t.match("(by|until|after|before|during|on|in|following) (next|this|last)? (#Date|#Date)").tag("Date",y),t.match("the? #Date after next one?").tag("Date",y),t.match("(about|approx|approximately|around) #Date").tag("Date",y)),t},function(t){return t.has("#Date")&&(t.match("this? (last|next|past|this|previous|current|upcoming|coming|the) #Date").tag("Date",p),t.match("(starting|beginning|ending) #Date").tag("Date",p),t.match("the? (start|end|middle|beginning) of (last|next|this|the) (#Date|#Date)").tag("Date",p),t.match("(the|this) #Date").tag("Date",p)),t},function(t){return t.has("#Cardinal")&&!t.has("#Month")&&t.match("(half|quarter|25|15|10|5) (past|after|to) #Cardinal").tag("Time",g),t.has("#Date")&&(t.match("#Noun (standard|daylight|central|mountain)? time").tag("Timezone",g),t.match("/^utc[+-][0-9]/").tag("Timezone",g),t.match("/^gmt[+-][0-9]/").tag("Timezone",g),t.match("(in|for|by|near|at) #Timezone").tag("Timezone",g)),t},function(t){return t.has("#Date")&&(t.match("#Cardinal #Duration (before|after)").tag("#DateShift",v),t.match("in #Cardinal #Duration").tag("#DateShift",v),t.match("#Cardinal #Duration and? #DateShift").tag("#DateShift",v),t.match("#DateShift and #Cardinal #Duration").tag("#DateShift",v)),t},function(t){if(t.has("#Date")){var e=t.match("#Date+ by #Date+");e.found&&!e.has("^due")&&e.match("^#Date+").unTag("Date","by-monday");var a=t.match("#Date+");a.match("^day$").unTag("Date","spa-day"),a.match("(in|of|by|for)? (#Possessive && #Date)").unTag("Date","tomorrows meeting");var n="(yesterday|today|tomorrow)";a.has(n)&&(a.match("".concat(n," [#Value]$")).unTag("Date","yesterday-7"),a.match("^[#Value] ".concat(n,"$"),0).unTag("Date","7 yesterday"),a.match("#WeekDay+ ".concat(n,"$")).unTag("Date").lastTerm().tag("Date","fri-yesterday"),a.match("(this|last|next) #Date ".concat(n,"$")).unTag("Date").lastTerm().tag("Date","this month yesterday")),a.match("on #Cardinal$").unTag("Date",b),a.match("this tomorrow").terms(0).unTag("Date","this-tomorrow"),a.match("(q1|q2|q3|q4) #Year").tag("Date",b),a.match("^#Value (this|next|last)").terms(0).unTag("Date",b),a.has("(last|this|next)")&&(a.match("(last|this|next) #Duration #Value").terms(2).unTag("Date",b),a.match("!#Month #Value (last|this|next) #Date").terms(0).unTag("Date",b)),!1===a.has("(#Year|#Time|#TextValue|#NumberRange)")&&a.match("(#Month|#WeekDay) #Value #Value").terms(2).unTag("Date",b),a.has("^between")&&!a.has("and .")&&a.unTag("Date",b),!a.has("#Month #Month")||a.has("@hasHyphen")||a.has("@hasComma")||a.match("#Month").lastTerm().unTag("Date","month-month"),a.has("(minutes|seconds|weeks|hours|days|months)")&&!a.has("#Value #Duration")&&a.match("(minutes|seconds|weeks|hours|days|months)").unTag("#Date","log-hours"),a.has("about #Holiday")&&a.match("about").unTag("#Date","about-thanksgiving")}return t}],k=function(t){return w.forEach((function(e){return e(t)})),t},D={FinancialQuarter:{isA:"Date"},Season:{isA:"Date"},Year:{isA:["Date"],notA:"RomanNumeral"},Duration:{isA:["Date","Noun"]},Holiday:{isA:["Date","Noun"]},Timezone:{isA:["Date","Noun"]},DateShift:{isA:["Date"]}};var z,O=function(t,e){return t(e={exports:{}},e.exports),e.exports}((function(t,e){e.isLeapYear=function(t){return t%4==0&&t%100!=0||t%400==0},e.isDate=function(t){return"[object Date]"===Object.prototype.toString.call(t)&&!isNaN(t.valueOf())},e.isArray=function(t){return"[object Array]"===Object.prototype.toString.call(t)},e.isObject=function(t){return"[object Object]"===Object.prototype.toString.call(t)},e.zeroPad=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,a="0";return(t+="").length>=e?t:new Array(e-t.length+1).join(a)+t},e.titleCase=function(t){return t?t[0].toUpperCase()+t.substr(1):""},e.ordinal=function(t){var e=t%10,a=t%100;return 1===e&&11!==a?t+"st":2===e&&12!==a?t+"nd":3===e&&13!==a?t+"rd":t+"th"},e.toCardinal=function(t){return t=(t=String(t)).replace(/([0-9])(st|nd|rd|th)$/i,"$1"),parseInt(t,10)},e.normalize=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return"day"===(t=(t=(t=(t=t.toLowerCase().trim()).replace(/ies$/,"y")).replace(/s$/,"")).replace(/-/g,""))?"date":t},e.getEpoch=function(t){return"number"==typeof t?t:e.isDate(t)?t.getTime():t.epoch?t.epoch:null},e.beADate=function(t,a){return!1===e.isObject(t)?a.clone().set(t):t},e.formatTimezone=function(t){var a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=Math.abs(t),r=t>0?"+":"-";return"".concat(r).concat(e.zeroPad(n)).concat(a,"00")}})),_=(O.isLeapYear,O.isDate,O.isArray,O.isObject,O.zeroPad,O.titleCase,O.ordinal,O.toCardinal,O.normalize,O.getEpoch,O.beADate,O.formatTimezone,O.zeroPad),x=function(t,e,a,n){var r=new Date(t),o=(r.getTimezoneOffset()||0)+60*n;o=60*o*1e3;var i=function(t){return _(t.getMonth()+1)+"/"+_(t.getDate())+":"+_(t.getHours())}(r=new Date(t+o));return i>=e&&i");return!0===x(t.epoch,r[0],r[1],a)?a:n},T=["africa","america","asia","atlantic","australia","brazil","canada","chile","europe","indian","mexico","pacific","antarctica","etc"],M=(z=Object.freeze({__proto__:null,default:{"9|s":"2/dili,2/jayapura","9|n":"2/chita,2/khandyga,2/pyongyang,2/seoul,2/tokyo,11/palau","9.5|s|04/05:03->10/04:02":"4/adelaide,4/broken_hill,4/south,4/yancowinna","9.5|s":"4/darwin,4/north","8|s":"12/casey,2/kuala_lumpur,2/makassar,2/singapore,4/perth,4/west","8|n|03/25:03->09/29:23":"2/ulan_bator","8|n":"2/brunei,2/choibalsan,2/chongqing,2/chungking,2/harbin,2/hong_kong,2/irkutsk,2/kuching,2/macao,2/macau,2/manila,2/shanghai,2/taipei,2/ujung_pandang,2/ulaanbaatar","8.75|s":"4/eucla","7|s":"12/davis,2/jakarta,9/christmas","7|n":"2/bangkok,2/barnaul,2/ho_chi_minh,2/hovd,2/krasnoyarsk,2/novokuznetsk,2/novosibirsk,2/phnom_penh,2/pontianak,2/saigon,2/tomsk,2/vientiane","6|s":"12/vostok","6|n":"2/almaty,2/bishkek,2/dacca,2/dhaka,2/kashgar,2/omsk,2/qyzylorda,2/thimbu,2/thimphu,2/urumqi,9/chagos","6.5|n":"2/rangoon,2/yangon,9/cocos","5|s":"12/mawson,9/kerguelen","5|n":"2/aqtau,2/aqtobe,2/ashgabat,2/ashkhabad,2/atyrau,2/baku,2/dushanbe,2/karachi,2/oral,2/samarkand,2/tashkent,2/yekaterinburg,9/maldives","5.75|n":"2/kathmandu,2/katmandu","5.5|n":"2/calcutta,2/colombo,2/kolkata","4|s":"9/reunion","4|n":"2/dubai,2/muscat,2/tbilisi,2/yerevan,8/astrakhan,8/samara,8/saratov,8/ulyanovsk,8/volgograd,2/volgograd,9/mahe,9/mauritius","4.5|n|03/21:00->09/20:24":"2/tehran","4.5|n":"2/kabul","3|s":"12/syowa,9/antananarivo","3|n|03/29:03->10/25:04":"2/famagusta,2/nicosia,8/athens,8/bucharest,8/helsinki,8/kiev,8/mariehamn,8/nicosia,8/riga,8/sofia,8/tallinn,8/uzhgorod,8/vilnius,8/zaporozhye","3|n|03/29:02->10/25:03":"8/chisinau,8/tiraspol","3|n|03/29:00->10/24:24":"2/beirut","3|n|03/27:02->10/25:02":"2/jerusalem,2/tel_aviv","3|n|03/27:00->10/31:01":"2/gaza,2/hebron","3|n|03/27:00->10/30:01":"2/amman","3|n|03/27:00->10/29:24":"2/damascus","3|n":"0/addis_ababa,0/asmara,0/asmera,0/dar_es_salaam,0/djibouti,0/juba,0/kampala,0/mogadishu,0/nairobi,2/aden,2/baghdad,2/bahrain,2/istanbul,2/kuwait,2/qatar,2/riyadh,8/istanbul,8/kirov,8/minsk,8/moscow,8/simferopol,9/comoro,9/mayotte","2|s|03/29:02->10/25:02":"12/troll","2|s":"0/gaborone,0/harare,0/johannesburg,0/lubumbashi,0/lusaka,0/maputo,0/maseru,0/mbabane","2|n|03/29:02->10/25:03":"0/ceuta,arctic/longyearbyen,3/jan_mayen,8/amsterdam,8/andorra,8/belgrade,8/berlin,8/bratislava,8/brussels,8/budapest,8/busingen,8/copenhagen,8/gibraltar,8/ljubljana,8/luxembourg,8/madrid,8/malta,8/monaco,8/oslo,8/paris,8/podgorica,8/prague,8/rome,8/san_marino,8/sarajevo,8/skopje,8/stockholm,8/tirane,8/vaduz,8/vatican,8/vienna,8/warsaw,8/zagreb,8/zurich","2|n":"0/blantyre,0/bujumbura,0/cairo,0/khartoum,0/kigali,0/tripoli,8/kaliningrad","1|s|04/02:01->09/03:03":"0/windhoek","1|s":"0/kinshasa,0/luanda","1|n|04/19:03->05/31:02":"0/casablanca,0/el_aaiun","1|n|03/29:01->10/25:02":"3/canary,3/faeroe,3/faroe,3/madeira,8/belfast,8/dublin,8/guernsey,8/isle_of_man,8/jersey,8/lisbon,8/london","1|n":"0/algiers,0/bangui,0/brazzaville,0/douala,0/lagos,0/libreville,0/malabo,0/ndjamena,0/niamey,0/porto-novo,0/tunis","14|n":"11/kiritimati","13|s|04/05:04->09/27:03":"11/apia","13|s|01/15:02->11/05:03":"11/tongatapu","13|n":"11/enderbury,11/fakaofo","12|s|04/05:03->09/27:02":"12/mcmurdo,12/south_pole,11/auckland","12|s|01/12:03->11/08:02":"11/fiji","12|n":"2/anadyr,2/kamchatka,2/srednekolymsk,11/funafuti,11/kwajalein,11/majuro,11/nauru,11/tarawa,11/wake,11/wallis","12.75|s|04/05:03->04/05:02":"11/chatham","11|s":"12/macquarie,11/bougainville","11|n":"2/magadan,2/sakhalin,11/efate,11/guadalcanal,11/kosrae,11/noumea,11/pohnpei,11/ponape","11.5|n|04/05:03->10/04:02":"11/norfolk","10|s|04/05:03->10/04:02":"4/act,4/canberra,4/currie,4/hobart,4/melbourne,4/nsw,4/sydney,4/tasmania,4/victoria","10|s":"12/dumontdurville,4/brisbane,4/lindeman,4/queensland","10|n":"2/ust-nera,2/vladivostok,2/yakutsk,11/chuuk,11/guam,11/port_moresby,11/saipan,11/truk,11/yap","10.5|s|04/05:01->10/04:02":"4/lhi,4/lord_howe","0|n|03/29:00->10/25:01":"1/scoresbysund,3/azores","0|n":"0/abidjan,0/accra,0/bamako,0/banjul,0/bissau,0/conakry,0/dakar,0/freetown,0/lome,0/monrovia,0/nouakchott,0/ouagadougou,0/sao_tome,0/timbuktu,1/danmarkshavn,3/reykjavik,3/st_helena,13/gmt,13/gmt+0,13/gmt-0,13/gmt0,13/greenwich,13/utc,13/universal,13/zulu","-9|n|03/08:02->11/01:02":"1/adak,1/atka","-9|n":"11/gambier","-9.5|n":"11/marquesas","-8|n|03/08:02->11/01:02":"1/anchorage,1/juneau,1/metlakatla,1/nome,1/sitka,1/yakutat","-8|n":"11/pitcairn","-7|n|03/08:02->11/01:02":"1/dawson,1/ensenada,1/los_angeles,1/santa_isabel,1/tijuana,1/vancouver,1/whitehorse,6/pacific,6/yukon,10/bajanorte","-7|n":"1/creston,1/dawson_creek,1/hermosillo,1/phoenix","-6|s|04/04:22->09/05:22":"7/easterisland,11/easter","-6|n|04/05:02->10/25:02":"1/chihuahua,1/mazatlan,10/bajasur","-6|n|03/08:02->11/01:02":"1/boise,1/cambridge_bay,1/denver,1/edmonton,1/inuvik,1/ojinaga,1/shiprock,1/yellowknife,6/mountain","-6|n":"1/belize,1/costa_rica,1/el_salvador,1/guatemala,1/managua,1/regina,1/swift_current,1/tegucigalpa,6/east-saskatchewan,6/saskatchewan,11/galapagos","-5|s":"1/lima,1/rio_branco,5/acre","-5|n|04/05:02->10/25:02":"1/bahia_banderas,1/merida,1/mexico_city,1/monterrey,10/general","-5|n|03/12:03->11/05:01":"1/north_dakota","-5|n|03/08:02->11/01:02":"1/chicago,1/knox_in,1/matamoros,1/menominee,1/rainy_river,1/rankin_inlet,1/resolute,1/winnipeg,6/central","-5|n":"1/atikokan,1/bogota,1/cancun,1/cayman,1/coral_harbour,1/eirunepe,1/guayaquil,1/jamaica,1/panama,1/porto_acre","-4|s|05/13:23->08/13:01":"12/palmer","-4|s|04/04:24->09/06:00":"1/santiago,7/continental","-4|s|03/21:24->10/04:00":"1/asuncion","-4|s|02/16:24->11/03:00":"1/campo_grande,1/cuiaba","-4|s":"1/la_paz,1/manaus,5/west","-4|n|03/12:03->11/05:01":"1/indiana,1/kentucky","-4|n|03/08:02->11/01:02":"1/detroit,1/fort_wayne,1/grand_turk,1/indianapolis,1/iqaluit,1/louisville,1/montreal,1/nassau,1/new_york,1/nipigon,1/pangnirtung,1/port-au-prince,1/thunder_bay,1/toronto,6/eastern","-4|n|03/08:00->11/01:01":"1/havana","-4|n":"1/anguilla,1/antigua,1/aruba,1/barbados,1/blanc-sablon,1/boa_vista,1/caracas,1/curacao,1/dominica,1/grenada,1/guadeloupe,1/guyana,1/kralendijk,1/lower_princes,1/marigot,1/martinique,1/montserrat,1/port_of_spain,1/porto_velho,1/puerto_rico,1/santo_domingo,1/st_barthelemy,1/st_kitts,1/st_lucia,1/st_thomas,1/st_vincent,1/tortola,1/virgin","-3|s":"1/argentina,1/buenos_aires,1/cordoba,1/fortaleza,1/montevideo,1/punta_arenas,1/sao_paulo,12/rothera,3/stanley,5/east","-3|n|03/08:02->11/01:02":"1/glace_bay,1/goose_bay,1/halifax,1/moncton,1/thule,3/bermuda,6/atlantic","-3|n":"1/araguaina,1/bahia,1/belem,1/catamarca,1/cayenne,1/jujuy,1/maceio,1/mendoza,1/paramaribo,1/recife,1/rosario,1/santarem","-2|s":"5/denoronha","-2|n|03/28:22->10/24:23":"1/godthab","-2|n|03/08:02->11/01:02":"1/miquelon","-2|n":"1/noronha,3/south_georgia","-2.5|n|03/08:02->11/01:02":"1/st_johns,6/newfoundland","-1|n":"3/cape_verde","-11|n":"11/midway,11/niue,11/pago_pago,11/samoa","-10|n":"11/honolulu,11/johnston,11/rarotonga,11/tahiti"}}))&&z.default||z,q={};Object.keys(M).forEach((function(t){var e=t.split("|"),a={offset:Number(e[0]),hem:e[1]};e[2]&&(a.dst=e[2]),M[t].split(",").forEach((function(t){t=t.replace(/(^[0-9]+)\//,(function(t,e){return e=Number(e),T[e]+"/"})),q[t]=a}))})),q.utc={offset:0,hem:"n"};for(var P=-14;P<=14;P+=.5){var C=P;C>0&&(C="+"+C);var S="etc/gmt"+C;q[S]={offset:-1*P,hem:"n"},q[S="utc/gmt"+C]={offset:-1*P,hem:"n"}}var A=q,E=/(\-?[0-9]+)h(rs)?/i,V=/(\-?[0-9]+)/,N=/utc([\-+]?[0-9]+)/i,L=/gmt([\-+]?[0-9]+)/i,Y=function(t){return(t=Number(t))>-13&&t<13?"etc/gmt"+(t=((t*=-1)>0?"+":"")+t):null},I=function(t){var e=t.match(E);if(null!==e)return Y(e[1]);if(null!==(e=t.match(N)))return Y(e[1]);if(null!==(e=t.match(L))){var a=-1*Number(e[1]);return Y(a)}return null!==(e=t.match(V))?Y(e[1]):null},H=function(){var t=function(){if("undefined"==typeof Intl||void 0===Intl.DateTimeFormat)return null;var t=Intl.DateTimeFormat();if(void 0===t||void 0===t.resolvedOptions)return null;var e=t.resolvedOptions().timeZone;return e?e.toLowerCase():null}();return null===t?"utc":t}(),$=Object.keys(A).reduce((function(t,e){var a=e.split("/")[1]||"";return t[a=a.replace(/_/g," ")]=e,t}),{}),B=function(t,e){if(!t)return H;var a=t.trim(),n=t.split("/");if(n.length>2&&!1===e.hasOwnProperty(a)&&(a=n[0]+"/"+n[1]),a=a.toLowerCase(),!0===e.hasOwnProperty(a))return a;if(a=function(t){return t=(t=(t=(t=(t=(t=t.replace(/ time/g,"")).replace(/ (standard|daylight|summer)/g,"")).replace(/\b(east|west|north|south)ern/g,"$1")).replace(/\b(africa|america|australia)n/g,"$1")).replace(/\beuropean/g,"europe")).replace(/\islands/g,"island")}(a),!0===e.hasOwnProperty(a))return a;if(!0===$.hasOwnProperty(a))return $[a];if(!0===/[0-9]/.test(a)){var r=I(a);if(r)return r}throw new Error("Spacetime: Cannot find timezone named: '"+t+"'. Please enter an IANA timezone id.")},F={millisecond:1,second:1e3,minute:6e4,hour:36e5,day:864e5};F.date=F.day,F.month=25488e5,F.week=6048e5,F.year=3154e7,Object.keys(F).forEach((function(t){F[t+"s"]=F[t]}));var J=F,Q=function(t,e,a,n,r){var o=t.d[a]();if(o!==e){var i=null===r?null:t.d[r](),u=t.epoch,s=e-o;t.epoch+=J[n]*s,"day"===n&&Math.abs(s)>28&&e<28&&(t.epoch+=J.hour);for(var c=J[n]/2;t.d[a]()e;)t.epoch-=c;null!==r&&i!==t.d[r]()&&(t.epoch=u,t.epoch+=J[n]*s*.89)}},K={year:{valid:function(t){return t>-4e3&&t<4e3},walkTo:function(t,e){return Q(t,e,"getFullYear","year",null)}},month:{valid:function(t){return t>=0&&t<=11},walkTo:function(t,e){var a=t.d,n=a.getMonth(),r=t.epoch,o=a.getFullYear();if(n!==e){var i=e-n;for(t.epoch+=J.day*(28*i),o!==t.d.getFullYear()&&(t.epoch=r);t.d.getMonth()e;)t.epoch-=J.day}}},date:{valid:function(t){return t>0&&t<=31},walkTo:function(t,e){return Q(t,e,"getDate","day","getMonth")}},hour:{valid:function(t){return t>=0&&t<24},walkTo:function(t,e){return Q(t,e,"getHours","hour","getDate")}},minute:{valid:function(t){return t>=0&&t<60},walkTo:function(t,e){return Q(t,e,"getMinutes","minute","getHours")}},second:{valid:function(t){return t>=0&&t<60},walkTo:function(t,e){t.epoch=t.seconds(e).epoch}},millisecond:{valid:function(t){return t>=0&&t<1e3},walkTo:function(t,e){t.epoch=t.milliseconds(e).epoch}}},Z=function(t,e){for(var a=Object.keys(K),n=t.clone(),r=0;r100&&(a/=100),(a*=-1)>=0&&(a="+"+a);var n="etc/gmt"+a;return t.timezones[n]&&(t.tz=n),t},at=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",a=(e=e.replace(/^\s+/,"").toLowerCase()).match(/([0-9]{1,2}):([0-9]{1,2}):?([0-9]{1,2})?[:\.]?([0-9]{1,4})?/);if(null!==a){var n=Number(a[1]);if(n<0||n>24)return t.startOf("day");var r=Number(a[2]);if(a[2].length<2||r<0||r>59)return t.startOf("day");t=(t=(t=(t=t.hour(n)).minute(r)).seconds(a[3]||0)).millisecond(a[4]||0);var o=e.match(/[\b0-9](am|pm)\b/);return null!==o&&o[1]&&(t=t.ampm(o[1])),t}if(null!==(a=e.match(/([0-9]+) ?(am|pm)/))&&a[1]){var i=Number(a[1]);return i>12||i<1?t.startOf("day"):t=(t=(t=t.hour(a[1]||0)).ampm(a[2])).startOf("hour")}return t=t.startOf("day")},nt=[31,28,31,30,31,30,31,31,30,31,30,31],rt=O.isLeapYear,ot=function(t){if(!0!==nt.hasOwnProperty(t.month))return!1;if(1===t.month)return!!(rt(t.year)&&t.date<=29)||t.date<=28;var e=nt[t.month]||0;return t.date<=e},it=X(),ut=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",e=arguments.length>1?arguments[1]:void 0,a=parseInt(t.trim(),10);return!a&&e&&(a=e.year),a=a||(new Date).getFullYear()},st=[{reg:/^(\-?0?0?[0-9]{3,4})-([0-9]{1,2})-([0-9]{1,2})[T| ]([0-9.:]+)(Z|[0-9\-\+:]+)?$/,parse:function(t,e,a,n){var r=parseInt(e[2],10)-1,o={year:e[1],month:r,date:e[3]};return!1===ot(o)?(t.epoch=null,t):(et(t,e[5]),Z(t,o),t=at(t,e[4]))}},{reg:/^([0-9]{4})[\-\/]([0-9]{1,2})[\-\/]([0-9]{1,2}),?( [0-9]{1,2}:[0-9]{2}:?[0-9]{0,2}? ?(am|pm|gmt))?$/i,parse:function(t,e){var a={year:e[1],month:parseInt(e[2],10)-1,date:parseInt(e[3],10)};return a.month>=12&&(a.date=parseInt(e[2],10),a.month=parseInt(e[3],10)-1),!1===ot(a)?(t.epoch=null,t):(Z(t,a),t=at(t,e[4]))}},{reg:/^([0-9]{1,2})[\-\/]([0-9]{1,2})[\-\/]?([0-9]{4})?,?( [0-9]{1,2}:[0-9]{2}:?[0-9]{0,2}? ?(am|pm|gmt))?$/i,parse:function(t,e){var a=parseInt(e[1],10)-1,n=parseInt(e[2],10);(t.british||a>=12)&&(n=parseInt(e[1],10),a=parseInt(e[2],10)-1);var r={year:e[3]||(new Date).getFullYear(),month:a,date:n};return!1===ot(r)?(t.epoch=null,t):(Z(t,r),t=at(t,e[4]))}},{reg:/^([0-9]{1,2})[\-\/]([a-z]+)[\-\/]?([0-9]{4})?$/i,parse:function(t,e){var a=it[e[2].toLowerCase()],n={year:ut(e[3],t._today),month:a,date:O.toCardinal(e[1]||"")};return!1===ot(n)?(t.epoch=null,t):(Z(t,n),t=at(t,e[4]))}},{reg:/^([a-z]+) ([0-9]{1,2}(?:st|nd|rd|th)?),?( [0-9]{4})?( ([0-9:]+( ?am| ?pm| ?gmt)?))?$/i,parse:function(t,e){var a=it[e[1].toLowerCase()],n={year:ut(e[3],t._today),month:a,date:O.toCardinal(e[2]||"")};return!1===ot(n)?(t.epoch=null,t):(Z(t,n),t=at(t,e[4]))}},{reg:/^([a-z]+) ([0-9]{4})$/i,parse:function(t,e){var a=it[e[1].toLowerCase()],n={year:ut(e[2],t._today),month:a,date:t._today.date||1};return!1===ot(n)?(t.epoch=null,t):(Z(t,n),t=at(t,e[4]))}},{reg:/^([0-9]{1,2}(?:st|nd|rd|th)?) ([a-z]+),?( [0-9]{4})?,? ?([0-9]{1,2}:[0-9]{2}:?[0-9]{0,2}? ?(am|pm|gmt))?$/i,parse:function(t,e){var a=it[e[2].toLowerCase()];if(!a)return null;var n={year:ut(e[3],t._today),month:a,date:O.toCardinal(e[1])};return!1===ot(n)?(t.epoch=null,t):(Z(t,n),t=at(t,e[4]))}},{reg:/^[0-9,]+ ?b\.?c\.?$/i,parse:function(t,e){var a=e[0]||"";a=(a=a.replace(/^([0-9,]+) ?b\.?c\.?$/i,"-$1")).replace(/,/g,"");var n=parseInt(a.trim(),10),r=new Date,o={year:n,month:r.getMonth(),date:r.getDate()};return!1===ot(o)?(t.epoch=null,t):(Z(t,o),t=at(t))}},{reg:/^[0-9,]+ ?(a\.?d\.?|c\.?e\.?)$/i,parse:function(t,e){var a=e[0]||"";a=a.replace(/,/g,"");var n=parseInt(a.trim(),10),r=new Date,o={year:n,month:r.getMonth(),date:r.getDate()};return!1===ot(o)?(t.epoch=null,t):(Z(t,o),t=at(t))}},{reg:/^[0-9]{4}( ?a\.?d\.?)?$/i,parse:function(t,e){var a=t._today,n=ut(e[0],a),r=new Date;a.month&&!a.date&&(a.date=1);var o={year:n,month:a.month||r.getMonth(),date:a.date||r.getDate()};return!1===ot(o)?(t.epoch=null,t):(Z(t,o),t=at(t))}}],ct={now:function(t){return t.epoch=Date.now(),t},tonight:function(t){return t.epoch=Date.now(),t=t.hour(18)},today:function(t){return t.epoch=Date.now(),t},tomorrow:function(t){return t.epoch=Date.now(),t=(t=t.add(1,"day")).startOf("day")},yesterday:function(t){return t.epoch=Date.now(),t=(t=t.subtract(1,"day")).startOf("day")},christmas:function(t){var e=(new Date).getFullYear();return t=t.set([e,11,25,18,0,0])},"new years":function(t){var e=(new Date).getFullYear();return t=t.set([e,11,31,18,0,0])}};ct["new years eve"]=ct["new years"];var dt=ct,lt={year:(new Date).getFullYear(),month:0,date:1},ht=function(t,e,a){var n=t._today||lt;if("number"==typeof e)return e>0&&e<25e8&&!1===t.silent&&(console.warn(" - Warning: You are setting the date to January 1970."),console.warn(" - did input seconds instead of milliseconds?")),t.epoch=e,t;if(t.epoch=Date.now(),null==e)return t;if(!0===O.isDate(e))return t.epoch=e.getTime(),t;if(!0===O.isArray(e))return t=function(t,e,a){for(var n=["year","month","date","hour","minute","second","millisecond"],r=0;r=0?Math.floor(e):Math.ceil(e)),a?(e*=-1,e="-"+(e=O.zeroPad(e,2))):e="+"+(e=O.zeroPad(e,2)),"+00:00"===(e=e+":"+n)&&(e="Z"),e},bt={day:function(t){return O.titleCase(t.dayName())},"day-short":function(t){return O.titleCase(yt()[t.day()])},"day-number":function(t){return t.day()},"day-ordinal":function(t){return O.ordinal(t.day())},"day-pad":function(t){return O.zeroPad(t.day())},date:function(t){return t.date()},"date-ordinal":function(t){return O.ordinal(t.date())},"date-pad":function(t){return O.zeroPad(t.date())},month:function(t){return O.titleCase(t.monthName())},"month-short":function(t){return O.titleCase(W()[t.month()])},"month-number":function(t){return t.month()},"month-ordinal":function(t){return O.ordinal(t.month())},"month-pad":function(t){return O.zeroPad(t.month())},"iso-month":function(t){return O.zeroPad(t.month()+1)},year:function(t){var e=t.year();return e>0?e:(e=Math.abs(e),e+" BC")},"year-short":function(t){var e=t.year();return e>0?"'".concat(String(t.year()).substr(2,4)):(e=Math.abs(e))+" BC"},"iso-year":function(t){var e=t.year(),a=e<0,n=O.zeroPad(Math.abs(e),4);return a&&(n="-"+(n=O.zeroPad(n,6))),n},time:function(t){return t.time()},"time-24":function(t){return"".concat(t.hour24(),":").concat(O.zeroPad(t.minute()))},hour:function(t){return t.hour12()},"hour-pad":function(t){return O.zeroPad(t.hour12())},"hour-24":function(t){return t.hour24()},"hour-24-pad":function(t){return O.zeroPad(t.hour24())},minute:function(t){return t.minute()},"minute-pad":function(t){return O.zeroPad(t.minute())},second:function(t){return t.second()},"second-pad":function(t){return O.zeroPad(t.second())},ampm:function(t){return t.ampm()},quarter:function(t){return"Q"+t.quarter()},season:function(t){return t.season()},era:function(t){return t.era()},json:function(t){return t.json()},timezone:function(t){return t.timezone().name},offset:function(t){return vt(t)},numeric:function(t){return"".concat(t.year(),"/").concat(O.zeroPad(t.month()+1),"/").concat(O.zeroPad(t.date()))},"numeric-us":function(t){return"".concat(O.zeroPad(t.month()+1),"/").concat(O.zeroPad(t.date()),"/").concat(t.year())},"numeric-uk":function(t){return"".concat(O.zeroPad(t.date()),"/").concat(O.zeroPad(t.month()+1),"/").concat(t.year())},"mm/dd":function(t){return"".concat(O.zeroPad(t.month()+1),"/").concat(O.zeroPad(t.date()))},iso:function(t){var e=t.format("iso-year"),a=O.zeroPad(t.month()+1),n=O.zeroPad(t.date()),r=O.zeroPad(t.h24()),o=O.zeroPad(t.minute()),i=O.zeroPad(t.second()),u=O.zeroPad(t.millisecond(),3),s=vt(t);return"".concat(e,"-").concat(a,"-").concat(n,"T").concat(r,":").concat(o,":").concat(i,".").concat(u).concat(s)},"iso-short":function(t){var e=O.zeroPad(t.month()+1),a=O.zeroPad(t.date());return"".concat(t.year(),"-").concat(e,"-").concat(a)},"iso-utc":function(t){return new Date(t.epoch).toISOString()},nice:function(t){return"".concat(W()[t.month()]," ").concat(O.ordinal(t.date()),", ").concat(t.time())},"nice-year":function(t){return"".concat(W()[t.month()]," ").concat(O.ordinal(t.date()),", ").concat(t.year())},"nice-day":function(t){return"".concat(yt()[t.day()]," ").concat(O.titleCase(W()[t.month()])," ").concat(O.ordinal(t.date()))},"nice-full":function(t){return"".concat(t.dayName()," ").concat(O.titleCase(t.monthName())," ").concat(O.ordinal(t.date()),", ").concat(t.time())}},wt={"day-name":"day","month-name":"month","iso 8601":"iso","time-h24":"time-24","time-12":"time","time-h12":"time",tz:"timezone","day-num":"day-number","month-num":"month-number","month-iso":"iso-month","year-iso":"iso-year","nice-short":"nice",mdy:"numeric-us",dmy:"numeric-uk",ymd:"numeric","yyyy/mm/dd":"numeric","mm/dd/yyyy":"numeric-us","dd/mm/yyyy":"numeric-us","little-endian":"numeric-uk","big-endian":"numeric","day-nice":"nice-day"};Object.keys(wt).forEach((function(t){return bt[t]=bt[wt[t]]}));var kt=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";if(!0!==t.isValid())return"";if(bt.hasOwnProperty(e)){var a=bt[e](t)||"";return"json"!==e&&(a=String(a),"ampm"!==e&&(a=O.titleCase(a))),a}if(-1!==e.indexOf("{")){var n=/\{(.+?)\}/g;return e=e.replace(n,(function(e,a){return a=a.toLowerCase().trim(),bt.hasOwnProperty(a)?String(bt[a](t)||""):""}))}return t.format("iso-short")},Dt=O.zeroPad,zt=O.formatTimezone,Ot={G:function(t){return t.era()},GG:function(t){return t.era()},GGG:function(t){return t.era()},GGGG:function(t){return"AD"===t.era()?"Anno Domini":"Before Christ"},y:function(t){return t.year()},yy:function(t){return parseInt(String(t.year()).substr(2,4),10)},yyy:function(t){return t.year()},yyyy:function(t){return t.year()},yyyyy:function(t){return"0"+t.year()},Q:function(t){return t.quarter()},QQ:function(t){return t.quarter()},QQQ:function(t){return t.quarter()},QQQQ:function(t){return t.quarter()},M:function(t){return t.month()+1},MM:function(t){return Dt(t.month()+1)},MMM:function(t){return t.format("month-short")},MMMM:function(t){return t.format("month")},w:function(t){return t.week()},ww:function(t){return Dt(t.week())},d:function(t){return t.date()},dd:function(t){return Dt(t.date())},D:function(t){return t.dayOfYear()},DD:function(t){return Dt(t.dayOfYear())},DDD:function(t){return Dt(t.dayOfYear(),3)},E:function(t){return t.format("day-short")},EE:function(t){return t.format("day-short")},EEE:function(t){return t.format("day-short")},EEEE:function(t){return t.format("day")},EEEEE:function(t){return t.format("day")[0]},e:function(t){return t.day()},ee:function(t){return t.day()},eee:function(t){return t.format("day-short")},eeee:function(t){return t.format("day")},eeeee:function(t){return t.format("day")[0]},a:function(t){return t.ampm().toUpperCase()},aa:function(t){return t.ampm().toUpperCase()},aaa:function(t){return t.ampm().toUpperCase()},aaaa:function(t){return t.ampm().toUpperCase()},h:function(t){return t.h12()},hh:function(t){return Dt(t.h12())},H:function(t){return t.hour()},HH:function(t){return Dt(t.hour())},m:function(t){return t.minute()},mm:function(t){return Dt(t.minute())},s:function(t){return t.second()},ss:function(t){return Dt(t.second())},A:function(t){return t.epoch-t.startOf("day").epoch},z:function(t){return t.timezone().name},zz:function(t){return t.timezone().name},zzz:function(t){return t.timezone().name},zzzz:function(t){return t.timezone().name},Z:function(t){return zt(t.timezone().current.offset)},ZZ:function(t){return zt(t.timezone().current.offset)},ZZZ:function(t){return zt(t.timezone().current.offset)},ZZZZ:function(t){return zt(t.timezone().current.offset,":")}},_t=function(t,e,a){for(var n=t,r=e,o=0;o.5&&(t=t.add(1,e)),t=t.startOf(e)):!1===t.silent&&console.warn("no known unit '"+e+"'"),t},Pt=function(t,e,a){var n=0;for(t=t.clone();t.isBefore(e);)t=t.add(1,a),n+=1;return t.isAfter(e,a)&&(n-=1),n},Ct=function(t,e,a){return t.isBefore(e)?Pt(t,e,a):-1*Pt(e,t,a)},St=function(t,e){var a=e.epoch-t.epoch,n={milliseconds:a,seconds:parseInt(a/1e3,10)};n.minutes=parseInt(n.seconds/60,10),n.hours=parseInt(n.minutes/60,10);var r=t.clone();return n.years=function(t,e){var a=e.year()-t.year();return(t=t.year(e.year())).isAfter(e)&&(a-=1),a}(r,e),r=t.add(n.years,"year"),n.months=12*n.years,r=t.add(n.months,"month"),n.months+=Ct(r,e,"month"),n.weeks=52*n.years,r=t.add(n.weeks,"week"),n.weeks+=Ct(r,e,"week"),n.days=7*n.weeks,r=t.add(n.days,"day"),n.days+=Ct(r,e,"day"),n},At=function(t,e,a){e=O.beADate(e,t);var n=!1;if(t.isAfter(e)){var r=t;t=e,e=r,n=!0}var o=St(t,e);return n&&(o=function(t){return Object.keys(t).forEach((function(e){t[e]*=-1})),t}(o)),a?(a=O.normalize(a),!0!==/s$/.test(a)&&(a+="s"),"dates"===a&&(a="days"),o[a]):o},Et={months:{almost:10,over:4},days:{almost:25,over:10},hours:{almost:20,over:8},minutes:{almost:50,over:20},seconds:{almost:50,over:20}};function Vt(t,e){return 1===t&&(e=e.slice(0,-1)),t+" "+e}var Nt=function(t,e){var a,n,r,o=function(t,e){var a=t.isBefore(e),n=a?e:t,r=a?t:e;r=r.clone();var o={years:0,months:0,days:0,hours:0,minutes:0,seconds:0};return Object.keys(o).forEach((function(t){if(!r.isSame(n,t)){var e=r.diff(n,t);r=r.add(e,t),o[t]=e}})),a&&Object.keys(o).forEach((function(t){0!==o[t]&&(o[t]*=-1)})),o}(t,e=O.beADate(e,t));if(!0===Object.keys(o).every((function(t){return!o[t]})))return{diff:o,rounded:"now",qualified:"now",precise:"now"};var i=[];return Object.keys(o).forEach((function(t,e,r){var u=Math.abs(o[t]);if(0!==u){var s=Vt(u,t);if(i.push(s),!a){if(a=n=s,e>4)return;var c=r[e+1],d=Math.abs(o[c]);d>Et[c].almost?(a=Vt(u+1,t),n="almost "+a):d>Et[c].over&&(n="over "+s)}}})),r=i.splice(0,2).join(", "),!0===t.isAfter(e)?(a+=" ago",n+=" ago",r+=" ago"):(a="in "+a,n="in "+n,r="in "+r),{diff:o,rounded:a,qualified:n,precise:r}},Lt={north:[["spring",2,1],["summer",5,1],["fall",8,1],["autumn",8,1],["winter",11,1]],south:[["fall",2,1],["autumn",2,1],["winter",5,1],["spring",8,1],["summer",11,1]]},Yt=[null,[0,1],[3,1],[6,1],[9,1]],It={minute:function(t){return Z(t,{second:0,millisecond:0}),t},quarterhour:function(t){var e=t.minutes();return t=e>=45?t.minutes(45):e>=30?t.minutes(30):e>=15?t.minutes(15):t.minutes(0),Z(t,{second:0,millisecond:0}),t},hour:function(t){return Z(t,{minute:0,second:0,millisecond:0}),t},day:function(t){return Z(t,{hour:0,minute:0,second:0,millisecond:0}),t},week:function(t){var e=t.clone();return(t=t.day(t._weekStart)).isAfter(e)&&(t=t.subtract(1,"week")),Z(t,{hour:0,minute:0,second:0,millisecond:0}),t},month:function(t){return Z(t,{date:1,hour:0,minute:0,second:0,millisecond:0}),t},quarter:function(t){var e=t.quarter();return Yt[e]&&Z(t,{month:Yt[e][0],date:Yt[e][1],hour:0,minute:0,second:0,millisecond:0}),t},season:function(t){var e=t.season(),a="north";"South"===t.hemisphere()&&(a="south");for(var n=0;n1&&void 0!==arguments[1]?arguments[1]:"",a=arguments.length>2?arguments[2]:void 0;if(!e||!a)return[];if(e=O.normalize(e),a=t.clone().set(a),t.isAfter(a)){var n=t;t=a,a=n}var r=t.clone();Bt(e)?(r=r.next(e),e="week"):r=r.next(e);for(var o=[];r.isBefore(a);)o.push(r),r=r.add(1,e);return o},Jt=function(t){var e=t.timezones,a=t.tz;if(!1===e.hasOwnProperty(a)&&(a=B(t.tz,e)),null===a)return!1===t.silent&&console.warn("Warn: could not find given or local timezone - '"+t.tz+"'"),{current:{epochShift:0}};var n,r,o=e[a],i={name:(n=a,n=(n=(n=n[0].toUpperCase()+n.substr(1)).replace(/\/gmt/,"/GMT")).replace(/[\/_]([a-z])/gi,(function(t){return t.toUpperCase()}))),hasDst:Boolean(o.dst),default_offset:o.offset,hemisphere:"s"===o.hem?"South":"North",current:{}};if(i.hasDst){var u=(r=o.dst)?r.split("->"):[];i.change={start:u[0],back:u[1]}}var s=o.offset,c=s;return!0===i.hasDst&&(c="North"===i.hemisphere?s-1:o.offset+1),!1===i.hasDst?(i.current.offset=s,i.current.isDST=!1):!0===x(t.epoch,i.change.start,i.change.back,s)?(i.current.offset=s,i.current.isDST="North"===i.hemisphere):(i.current.offset=c,i.current.isDST="South"===i.hemisphere),i},Qt=["century","decade","year","month","date","day","hour","minute","second","millisecond"],Kt={set:function(t,e){var a=this.clone();return a=ht(a,t,null),e&&(this.tz=B(e)),a},timezone:function(){return Jt(this)},isDST:function(){return Jt(this).current.isDST},hasDST:function(){return Jt(this).hasDst},offset:function(){return 60*Jt(this).current.offset},hemisphere:function(){return Jt(this).hemisphere},format:function(t){return kt(this,t)},unixFmt:function(t){return xt(this,t)},startOf:function(t){return Ht(this,t)},endOf:function(t){return $t(this,t)},leapYear:function(){var t=this.year();return O.isLeapYear(t)},progress:function(t){return Mt(this,t)},nearest:function(t){return qt(this,t)},diff:function(t,e){return At(this,t,e)},since:function(t){return t||(t=this.clone().set()),Nt(this,t)},next:function(t){return this.add(1,t).startOf(t)},last:function(t){return this.subtract(1,t).startOf(t)},isValid:function(){return!(!this.epoch&&0!==this.epoch)&&!isNaN(this.d.getTime())},goto:function(t){var e=this.clone();return e.tz=B(t,e.timezones),e},every:function(t,e){return Ft(this,t,e)},isAwake:function(){var t=this.hour();return!(t<8||t>22)},isAsleep:function(){return!this.isAwake()},log:function(){return console.log(""),console.log(kt(this,"nice-short")),this},logYear:function(){return console.log(""),console.log(kt(this,"full-short")),this},json:function(){var t=this;return Qt.reduce((function(e,a){return e[a]=t[a](),e}),{})},debug:function(){var t=this.timezone(),e=this.format("MM")+" "+this.format("date-ordinal")+" "+this.year();return e+="\n - "+this.format("time"),console.log("\n\n",e+"\n - "+t.name+" ("+t.current.offset+")"),this},from:function(t){return(t=this.clone().set(t)).since(this)},fromNow:function(){return this.clone().set(Date.now()).since(this)},weekStart:function(t){if("number"==typeof t)return this._weekStart=t,this;if("string"==typeof t){t=t.toLowerCase().trim();var e=yt().indexOf(t);-1===e&&(e=pt().indexOf(t)),-1===e&&(e=1),this._weekStart=e}else console.warn("Spacetime Error: Cannot understand .weekStart() input:",t);return this}};Kt.inDST=Kt.isDST,Kt.round=Kt.nearest,Kt.each=Kt.every;var Zt=Kt,Gt=function(t){return"string"==typeof t&&(t=parseInt(t,10)),t},Rt=["year","month","date","hour","minute","second","millisecond"],Wt=function(t,e,a){for(var n=Rt.indexOf(a),r=Rt.slice(n,Rt.length),o=0;o=24?e=24:e<0&&(e=0);var a=t.clone(),n=(t.hour()-e)*J.hour;return t.epoch-=n,Z(t,{hour:e}),Wt(t,a,"minute"),t.epoch},ae=function(t,e){var a=e.match(/([0-9]{1,2}):([0-9]{1,2})(am|pm)?/);if(!a){if(!(a=e.match(/([0-9]{1,2})(am|pm)/)))return t.epoch;a.splice(2,0,"0")}var n=!1,r=parseInt(a[1],10),o=parseInt(a[2],10);return r>12&&(n=!0),!1===n&&("am"===a[3]&&12===r&&(r=0),"pm"===a[3]&&r<12&&(r+=12)),(t=(t=(t=(t=t.hour(r)).minute(o)).second(0)).millisecond(0)).epoch},ne=function(t,e){if((e=Gt(e))>28){var a=nt[t.month()];e>a&&(e=a)}return e<=0&&(e=1),Z(t,{date:e}),t.epoch},re=function(t,e){"string"==typeof e&&(e=X()[e.toLowerCase()]),(e=Gt(e))>=12&&(e=11),e<=0&&(e=0);var a=t.date();return a>nt[e]&&(a=nt[e]),Z(t,{month:e,date:a}),t.epoch},oe=function(t,e){return e=Gt(e),Z(t,{year:e}),t.epoch},ie=function(t,e){e=Gt(e);var a=t.clone();return(e-=1)<=0?e=0:e>=365&&(e=364),t=(t=t.startOf("year")).add(e,"day"),Wt(t,a,"hour"),t.epoch},ue={millisecond:function(t){if(void 0!==t){var e=this.clone();return e.epoch=Ut(e,t),e}return this.d.getMilliseconds()},second:function(t){if(void 0!==t){var e=this.clone();return e.epoch=Xt(e,t),e}return this.d.getSeconds()},minute:function(t){if(void 0!==t){var e=this.clone();return e.epoch=te(e,t),e}return this.d.getMinutes()},hour:function(t){var e=this.d;if(void 0!==t){var a=this.clone();return a.epoch=ee(a,t),a}return e.getHours()},hourFloat:function(t){if(void 0!==t){var e=this.clone(),a=t%1;a*=60;var n=parseInt(t,10);return e.epoch=ee(e,n),e.epoch=te(e,a),e}var r=this.d,o=r.getHours(),i=r.getMinutes();return o+(i/=60)},hour12:function(t){var e=this.d;if(void 0!==t){var a=this.clone(),n=(t=""+t).match(/^([0-9]+)(am|pm)$/);if(n){var r=parseInt(n[1],10);"pm"===n[2]&&(r+=12),a.epoch=ee(a,r)}return a}var o=e.getHours();return o>12&&(o-=12),0===o&&(o=12),o},time:function(t){if(void 0!==t){var e=this.clone();return e.epoch=ae(e,t),e}return"".concat(this.h12(),":").concat(O.zeroPad(this.minute())).concat(this.ampm())},ampm:function(t){var e="am",a=this.hour();if(a>=12&&(e="pm"),"string"!=typeof t)return e;var n=this.clone();return t=t.toLowerCase().trim(),a>=12&&"am"===t?(a-=12,n.hour(a)):a<12&&"pm"===t?(a+=12,n.hour(a)):n},dayTime:function(t){if(void 0!==t){var e={morning:"7:00am",breakfast:"7:00am",noon:"12:00am",lunch:"12:00pm",afternoon:"2:00pm",evening:"6:00pm",dinner:"6:00pm",night:"11:00pm",midnight:"23:59pm"},a=this.clone();return t=(t=t||"").toLowerCase(),!0===e.hasOwnProperty(t)&&(a=a.time(e[t])),a}var n=this.hour();return n<6?"night":n<12?"morning":n<17?"afternoon":n<22?"evening":"night"},iso:function(t){return void 0!==t?this.set(t):this.format("iso")}},se={date:function(t){if(void 0!==t){var e=this.clone();return e.epoch=ne(e,t),e}return this.d.getDate()},day:function(t){if(void 0===t)return this.d.getDay();var e=this.clone(),a=t;"string"==typeof t&&(t=t.toLowerCase(),-1===(a=yt().indexOf(t))&&(a=pt().indexOf(t)));var n=this.d.getDay(),r=n-a,o=this.subtract(24*r,"hours");return Z(o,{hour:e.hour(),minute:e.minute(),second:e.second()}),o},dayName:function(t){if(void 0===t)return pt()[this.day()];var e=this.clone();return e=e.day(t)},month:function(t){if(void 0!==t){var e=this.clone();return e.epoch=re(e,t),e}return this.d.getMonth()}},ce=function(t){return t=(t=(t=t.minute(0)).second(0)).millisecond(1)},de={dayOfYear:function(t){if(void 0!==t){var e=this.clone();return e.epoch=ie(e,t),e}for(var a,n=0,r=this.d.getMonth(),o=1;o<=r;o++)(a=new Date).setDate(1),a.setFullYear(this.d.getFullYear()),a.setHours(1),a.setMinutes(1),a.setMonth(o),a.setHours(-2),n+=a.getDate();return n+this.d.getDate()},week:function(t){if(void 0!==t){var e=this.clone();return e=(e=(e=e.month(0)).date(1)).day("monday"),"december"===(e=ce(e)).monthName()&&(e=e.add(1,"week")),t-=1,e=e.add(t,"weeks")}var a=this.clone();a=(a=a.month(0)).date(1),"december"===(a=(a=ce(a)).day("monday")).monthName()&&(a=a.add(1,"week"));var n=1;1===a.date()&&(n=0),a=a.minus(1,"second");var r=this.epoch;if(a.epoch>r)return 1;var o=0,i=4*this.month();for(a.epoch+=J.week*i,o+=i;o<52;o++){if(a.epoch>r)return o+n;a=a.add(1,"week")}return 52},monthName:function(t){if(void 0===t)return U()[this.month()];var e=this.clone();return e=e.month(t)},quarter:function(t){if(void 0!==t&&("string"==typeof t&&(t=t.replace(/^q/i,""),t=parseInt(t,10)),Yt[t])){var e=this.clone(),a=Yt[t][0];return e=(e=(e=e.month(a)).date(1)).startOf("day")}for(var n=this.d.getMonth(),r=1;r=Lt[e][o][1]&&r0&&(e.epoch=oe(e,-1*a)),"ad"===t&&a<0&&(e.epoch=oe(e,-1*a)),e}return this.d.getFullYear()<0?"BC":"AD"},decade:function(t){if(void 0!==t){if(!(t=(t=(t=String(t)).replace(/([0-9])'?s$/,"$1")).replace(/([0-9])(th|rd|st|nd)/,"$1")))return console.warn("Spacetime: Invalid decade input"),this;2===t.length&&/[0-9][0-9]/.test(t)&&(t="19"+t);var e=Number(t);return isNaN(e)?this:(e=10*Math.floor(e/10),this.year(e))}return this.startOf("decade").year()},century:function(t){if(void 0!==t){"string"==typeof t&&(t=(t=(t=t.replace(/([0-9])(th|rd|st|nd)/,"$1")).replace(/([0-9]+) ?(b\.?c\.?|a\.?d\.?)/i,(function(t,e,a){return a.match(/b\.?c\.?/i)&&(e="-"+e),e}))).replace(/c$/,""));var e=Number(t);return isNaN(t)?(console.warn("Spacetime: Invalid century input"),this):(0===e&&(e=1),e=e>=0?100*(e-1):100*(e+1),this.year(e))}var a=this.startOf("century").year();return(a=Math.floor(a/100))<0?a-1:a+1},millenium:function(t){if(void 0!==t){if("string"==typeof t&&(t=t.replace(/([0-9])(th|rd|st|nd)/,"$1"),t=Number(t),isNaN(t)))return console.warn("Spacetime: Invalid millenium input"),this;t>0&&(t-=1);var e=1e3*t;return 0===e&&(e=1),this.year(e)}var a=Math.floor(this.year()/1e3);return a>=0&&(a+=1),a}},le=Object.assign({},ue,se,de);le.milliseconds=le.millisecond,le.seconds=le.second,le.minutes=le.minute,le.hours=le.hour,le.hour24=le.hour,le.h12=le.hour12,le.h24=le.hour24,le.days=le.day;var he=function(t){Object.keys(le).forEach((function(e){t.prototype[e]=le[e]}))},me=O.isLeapYear,fe=function(t,e){return 1===t&&me(e)?29:nt[t]},ye=function(t,e){if(t.month>0){var a=parseInt(t.month/12,10);t.year=e.year()+a,t.month=t.month%12}else if(t.month<0){var n=Math.floor(Math.abs(t.month)/13,10);n=Math.abs(n)+1,t.year=e.year()-n,t.month=t.month%12,t.month=t.month+12,12===t.month&&(t.month=0)}return t},pe=function(t,e,a){for(var n=e.year(),r=e.month(),o=fe(r,n);a>o;)a-=o,(r+=1)>=12&&(r-=12,n+=1),o=fe(r,n);return t.month=r,t.date=a,t},ge=function(t,e,a){t.year=e.year(),t.month=e.month();var n=e.date();for(t.date=n-Math.abs(a);t.date<1;){t.month-=1,t.month<0&&(t.month=11,t.year-=1);var r=fe(t.month,t.year);t.date+=r}return t},ve=["millisecond","second","minute","hour","date","month"],be={second:ve.slice(0,1),minute:ve.slice(0,2),quarterhour:ve.slice(0,2),hour:ve.slice(0,3),date:ve.slice(0,4),month:ve.slice(0,4),quarter:ve.slice(0,4),season:ve.slice(0,4),year:ve,decade:ve,century:ve};be.week=be.hour,be.season=be.date,be.quarter=be.date;var we={year:!0,quarter:!0,season:!0,month:!0,week:!0,day:!0},ke={month:!0,quarter:!0,season:!0,year:!0},De=function(t){t.prototype.add=function(t,e){var a=this.clone();if(!e||0===t)return a;var n=this.clone();e=O.normalize(e),J[e]?a.epoch+=J[e]*t:"week"===e?a.epoch+=J.day*(7*t):"quarter"===e||"season"===e||"season"===e?a.epoch+=J.month*(4*t):"quarterhour"===e&&(a.epoch+=15*J.minute*t);var r={};if(be[e]&&be[e].forEach((function(t){r[t]=n[t]()})),we[e]){var o=n.timezone().current.offset-a.timezone().current.offset;a.epoch+=3600*o*1e3}if("month"===e&&(r.month=n.month()+t,r=ye(r,n)),"week"===e){var i=n.date()+7*t;i<=28&&i>1&&(r.date=i)}else if("date"===e){if(t<0)r=ge(r,n,t);else{var u=n.date()+t;r=pe(r,n,u)}0!==t&&n.isSame(a,"day")&&(r.date=n.date()+t)}else"year"===e&&a.year()===n.year()?a.epoch+=J.week:"decade"===e?r.year=a.year()+10:"century"===e&&(r.year=a.year()+100);if(ke[e]){var s=nt[r.month];r.date=n.date(),r.date>s&&(r.date=s)}return Z(a,r),a},t.prototype.subtract=function(t,e){return this.clone().add(-1*t,e)},t.prototype.minus=t.prototype.subtract,t.prototype.plus=t.prototype.add},ze={millisecond:function(t){return t.epoch},second:function(t){return[t.year(),t.month(),t.date(),t.hour(),t.minute(),t.second()].join("-")},minute:function(t){return[t.year(),t.month(),t.date(),t.hour(),t.minute()].join("-")},hour:function(t){return[t.year(),t.month(),t.date(),t.hour()].join("-")},day:function(t){return[t.year(),t.month(),t.date()].join("-")},week:function(t){return[t.year(),t.week()].join("-")},month:function(t){return[t.year(),t.month()].join("-")},quarter:function(t){return[t.year(),t.quarter()].join("-")},year:function(t){return t.year()}};ze.date=ze.day;var Oe=function(t){t.prototype.isSame=function(e,a){return a?("string"!=typeof e&&"number"!=typeof e||(e=new t(e,this.timezone.name)),a=a.replace(/s$/,""),ze[a]?ze[a](this)===ze[a](e):null):null}},_e=function(t){var e={isAfter:function(t){t=O.beADate(t,this);var e=O.getEpoch(t);return null===e?null:this.epoch>e},isBefore:function(t){t=O.beADate(t,this);var e=O.getEpoch(t);return null===e?null:this.epoch2&&void 0!==arguments[2]&&arguments[2];t=O.beADate(t,this),e=O.beADate(e,this);var n=O.getEpoch(t);if(null===n)return null;var r=O.getEpoch(e);return null===r?null:a?this.isBetween(t,e)||this.isEqual(t)||this.isEqual(e):n2&&void 0!==arguments[2]?arguments[2]:{};this.epoch=null,this.tz=B(e,je),this.silent=a.silent||!0,this.british=a.dmy||a.british,this._weekStart=1,void 0!==a.weekStart&&(this._weekStart=a.weekStart),this._today={},void 0!==a.today&&(this._today=a.today),Object.defineProperty(this,"d",{get:function(){var t=j(this),e=(new Date(this.epoch).getTimezoneOffset()||0)+60*t;e=60*e*1e3;var a=this.epoch+e;return new Date(a)}}),Object.defineProperty(this,"timezones",{get:function(){return je},set:function(t){return je=t,t}});var n=ht(this,t,e);this.epoch=n.epoch};Object.keys(Zt).forEach((function(t){Te.prototype[t]=Zt[t]})),Te.prototype.clone=function(){return new Te(this.epoch,this.tz,{silent:this.silent,weekStart:this._weekStart,today:this._today})},Te.prototype.toLocalDate=function(){return new Date(this.epoch)},he(Te),De(Te),Oe(Te),_e(Te),xe(Te);var Me=Te,qe=function(t,e){var a=new Me(null),n=new Me(null);a=a.time(t),n=e?n.time(e):a.add(59,"minutes");var r=a.hour(),o=n.hour();return Object.keys(a.timezones).filter((function(t){if(-1===t.indexOf("/"))return!1;var e=new Me(null,t),i=e.hour();return i>=r&&i<=o&&(!(i===r&&e.minute()n.minute()))}))},Pe=function(t,e,a){return new Me(t,e,a)},Ce=function(t){var e=t._today||{};return Object.keys(e).forEach((function(a){t=t[a](e[a])})),t};Pe.now=function(t,e){var a=new Me((new Date).getTime(),t,e);return a=Ce(a)},Pe.today=function(t,e){var a=new Me((new Date).getTime(),t,e);return(a=Ce(a)).startOf("day")},Pe.tomorrow=function(t,e){var a=new Me((new Date).getTime(),t,e);return(a=Ce(a)).add(1,"day").startOf("day")},Pe.yesterday=function(t,e){var a=new Me((new Date).getTime(),t,e);return(a=Ce(a)).subtract(1,"day").startOf("day")},Pe.extend=function(t){return Object.keys(t).forEach((function(e){Me.prototype[e]=t[e]})),this},Pe.whereIts=qe,Pe.version="6.6.0",Pe.plugin=Pe.extend;var Se=Pe;"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self&&self;var Ae=function(t){return t&&t.default||t}(Object.freeze({__proto__:null,default:Se})),Ee="America/",Ve="Asia/",Ne="Europe/",Le="Africa/",Ye="Australia/",Ie="Pacific/",He={"british summer time":Ne+"London",bst:Ne+"London","british time":Ne+"London","britain time":Ne+"London","irish summer time":Ne+"Dublin","irish time":Ne+"Dublin",ireland:Ne+"Dublin","central european time":Ne+"Berlin",cet:Ne+"Berlin","central european summer time":Ne+"Berlin",cest:Ne+"Berlin","central europe":Ne+"Berlin","eastern european time":Ne+"Riga",eet:Ne+"Riga","eastern european summer time":Ne+"Riga",eest:Ne+"Riga","eastern europe time":Ne+"Riga","western european time":Ne+"Lisbon","western european summer time":Ne+"Lisbon","western europe":Ne+"Lisbon","turkey standard time":Ne+"Istanbul",trt:Ne+"Istanbul","turkish time":Ne+"Istanbul",etc:Le+"Freetown",utc:Le+"Freetown","greenwich standard time":Le+"Freetown",gmt:Le+"Freetown","east africa time":Le+"Nairobi","east african time":Le+"Nairobi","eastern africa time":Le+"Nairobi","central africa time":Le+"Khartoum","central african time":Le+"Khartoum","south africa standard time":Le+"Johannesburg",sast:Le+"Johannesburg","southern africa":Le+"Johannesburg","south african":Le+"Johannesburg","west africa standard time":Le+"Lagos","western africa time":Le+"Lagos","west african time":Le+"Lagos","australian central standard time":Ye+"Adelaide",acst:Ye+"Adelaide","australian central daylight time":Ye+"Adelaide",acdt:Ye+"Adelaide","australia central":Ye+"Adelaide","australian eastern standard time":Ye+"Brisbane",aest:Ye+"Brisbane","australian eastern daylight time":Ye+"Brisbane",aedt:Ye+"Brisbane","australia east":Ye+"Brisbane","australian western standard time":Ye+"Perth",awst:Ye+"Perth","australian western daylight time":Ye+"Perth",awdt:Ye+"Perth","australia west":Ye+"Perth","australian central western standard time":Ye+"Eucla",acwst:Ye+"Eucla","australia central west":Ye+"Eucla","lord howe standard time":Ye+"Lord_Howe",lhst:Ye+"Lord_Howe","lord howe daylight time":Ye+"Lord_Howe",lhdt:Ye+"Lord_Howe","russian standard time":Ne+"Moscow",msk:Ne+"Moscow",russian:Ne+"Moscow","central standard time":Ee+"Chicago","central time":Ee+"Chicago",cst:Ee+"Havana","central daylight time":Ee+"Chicago",cdt:Ee+"Havana","mountain standard time":Ee+"Denver","mountain time":Ee+"Denver",mst:Ee+"Denver","mountain daylight time":Ee+"Denver",mdt:Ee+"Denver","atlantic standard time":Ee+"Halifax","atlantic time":Ee+"Halifax",ast:Ve+"Baghdad","atlantic daylight time":Ee+"Halifax",adt:Ee+"Halifax","eastern standard time":Ee+"New_York","eastern time":Ee+"New_York",est:Ee+"New_York","eastern daylight time":Ee+"New_York",edt:Ee+"New_York","pacific time":Ee+"Los_Angeles","pacific standard time":Ee+"Los_Angeles",pst:Ee+"Los_Angeles","pacific daylight time":Ee+"Los_Angeles",pdt:Ee+"Los_Angeles","alaskan standard time":Ee+"Anchorage","alaskan time":Ee+"Anchorage",ahst:Ee+"Anchorage","alaskan daylight time":Ee+"Anchorage",ahdt:Ee+"Anchorage","hawaiian standard time":Ie+"Honolulu","hawaiian time":Ie+"Honolulu",hst:Ie+"Honolulu","aleutian time":Ie+"Honolulu","hawaii time":Ie+"Honolulu","newfoundland standard time":Ee+"St_Johns","newfoundland time":Ee+"St_Johns",nst:Ee+"St_Johns","newfoundland daylight time":Ee+"St_Johns",ndt:Ee+"St_Johns","brazil time":Ee+"Sao_Paulo",brt:Ee+"Sao_Paulo","brasília":Ee+"Sao_Paulo",brasilia:Ee+"Sao_Paulo","brazilian time":Ee+"Sao_Paulo","argentina time":Ee+"Buenos_Aires","argentinian time":Ee+"Buenos_Aires","amazon time":Ee+"Manaus",amt:Ee+"Manaus","amazonian time":Ee+"Manaus","easter island standard time":"Chile/Easterisland",east:"Chile/Easterisland","easter island summer time":"Chile/Easterisland",easst:"Chile/Easterisland","venezuelan standard time":Ee+"Caracas","venezuelan time":Ee+"Caracas",vet:Ee+"Caracas","venezuela time":Ee+"Caracas","paraguay time":Ee+"Asuncion",pyt:Ee+"Asuncion","paraguay summer time":Ee+"Asuncion",pyst:Ee+"Asuncion","cuba standard time":Ee+"Havana","cuba time":Ee+"Havana","cuba daylight time":Ee+"Havana","cuban time":Ee+"Havana","bolivia time":Ee+"La_Paz","bolivian time":Ee+"La_Paz","colombia time":Ee+"Bogota",cot:Ee+"Bogota","colombian time":Ee+"Bogota","acre time":Ee+"Eirunepe","peru time":Ee+"Lima","chile standard time":Ee+"Punta_Arenas","chile time":Ee+"Punta_Arenas",clst:Ee+"Punta_Arenas","chile summer time":Ee+"Punta_Arenas",cldt:Ee+"Punta_Arenas","uruguay time":Ee+"Montevideo",uyt:Ee+"Montevideo",ist:Ve+"Jerusalem","arabic standard time":Ve+"Baghdad","arabic time":Ve+"Baghdad","arab time":Ve+"Baghdad","iran standard time":Ve+"Tehran","iran time":Ve+"Tehran",irst:Ve+"Tehran","iran daylight time":Ve+"Tehran",irdt:Ve+"Tehran",iranian:Ve+"Tehran","pakistan standard time":Ve+"Karachi","pakistan time":Ve+"Karachi",pkt:Ve+"Karachi","india standard time":Ve+"Kolkata","indian time":Ve+"Kolkata","indochina time":Ve+"Bangkok",ict:Ve+"Bangkok","south east asia":Ve+"Bangkok","china standard time":Ve+"Shanghai",ct:Ve+"Shanghai","chinese time":Ve+"Shanghai","alma-ata time":Ve+"Almaty",almt:Ve+"Almaty","oral time":Ve+"Oral","orat time":Ve+"Oral","yakutsk time":Ve+"Yakutsk",yakt:Ve+"Yakutsk","gulf standard time":Ve+"Dubai","gulf time":Ve+"Dubai",gst:Ve+"Dubai",uae:Ve+"Dubai","hong kong time":Ve+"Hong_Kong",hkt:Ve+"Hong_Kong","western indonesian time":Ve+"Jakarta",wib:Ve+"Jakarta","indonesia time":Ve+"Jakarta","central indonesian time":Ve+"Makassar",wita:Ve+"Makassar","israel daylight time":Ve+"Jerusalem",idt:Ve+"Jerusalem","israel standard time":Ve+"Jerusalem","israel time":Ve+"Jerusalem",israeli:Ve+"Jerusalem","krasnoyarsk time":Ve+"Krasnoyarsk",krat:Ve+"Krasnoyarsk","malaysia time":Ve+"Kuala_Lumpur",myt:Ve+"Kuala_Lumpur","singapore time":Ve+"Singapore",sgt:Ve+"Singapore","korea standard time":Ve+"Seoul","korea time":Ve+"Seoul",kst:Ve+"Seoul","korean time":Ve+"Seoul","uzbekistan time":Ve+"Samarkand",uzt:Ve+"Samarkand","vladivostok time":Ve+"Vladivostok",vlat:Ve+"Vladivostok","maldives time":"Indian/Maldives",mvt:"Indian/Maldives","mauritius time":"Indian/Mauritius",mut:"Indian/Mauritius","marshall islands time":Ie+"Kwajalein",mht:Ie+"Kwajalein","samoa standard time":Ie+"Midway",sst:Ie+"Midway","somoan time":Ie+"Midway","chamorro standard time":Ie+"Guam",chst:Ie+"Guam","papua new guinea time":Ie+"Bougainville",pgt:Ie+"Bougainville"},$e=Ae().timezones,Be=Object.keys($e).reduce((function(t,e){return t[e]=e,t}),{}),Fe=Object.assign({},He,Be),Je={};[[["weekday","summer","winter","autumn","some day","one day","all day","some point","eod","eom","standard time","daylight time"],"#Date"],[["centuries","century","day","days","decade","decades","hour","hours","millisecond","milliseconds","minute","minutes","month","months","seconds","week","weeks","year","years"],"#Duration"],[["all hallows eve","all saints day","all sts day","april fools","armistice day","australia day","bastille day","boxing day","canada day","christmas eve","christmas","cinco de mayo","day of the dead","dia de muertos","dieciseis de septiembre","emancipation day","grito de dolores","groundhog day","halloween","harvey milk day","inauguration day","independence day","independents day","juneteenth","labour day","national freedom day","national nurses day","new years eve","new years","purple heart day","rememberance day","rosa parks day","saint andrews day","saint patricks day","saint stephens day","saint valentines day","st andrews day","st patricks day","st stephens day","st valentines day ","valentines day","valentines","veterans day","victoria day","womens equality day","xmas","epiphany","orthodox christmas day","orthodox new year","assumption of mary","all souls day","feast of the immaculate conception","feast of our lady of guadalupe","kwanzaa","imbolc","beltaine","lughnassadh","samhain","martin luther king day","mlk day","presidents day","mardi gras","tax day","commonwealth day","mothers day","memorial day","fathers day","columbus day","indigenous peoples day","canadian thanksgiving","election day","thanksgiving","t-day","turkey day","black friday","cyber monday","ash wednesday","palm sunday","maundy thursday","good friday","holy saturday","easter","easter sunday","easter monday","orthodox good friday","orthodox holy saturday","orthodox easter","orthodox easter monday","ascension day","pentecost","whitsunday","whit sunday","whit monday","trinity sunday","corpus christi","advent","tu bishvat","tu bshevat","purim","passover","yom hashoah","lag baomer","shavuot","tisha bav","rosh hashana","yom kippur","sukkot","shmini atzeret","simchat torah","chanukah","hanukkah","isra and miraj","lailat al-qadr","eid al-fitr","id al-Fitr","eid ul-Fitr","ramadan","eid al-adha","muharram","the prophets birthday","ostara","march equinox","vernal equinox","litha","june solistice","summer solistice","mabon","september equinox","fall equinox","autumnal equinox","yule","december solstice","winter solstice","chinese new year","diwali"],"#Holiday"],[["noon","midnight","now","morning","tonight","evening","afternoon","night","breakfast time","lunchtime","dinnertime","ago","sometime","eod","oclock","oclock","all day","at night"],"#Time"],[Object.keys(Fe),"#Timezone"]].forEach((function(t){for(var e=0;e-13&&t<13?"Etc/GMT"+(t=((t*=-1)>0?"+":"")+t):null},na=function(t){var e=t.match("#Timezone+"),a=(e=e.remove("(in|for|by|near|at)")).text("reduced");if(t.remove("#Timezone+"),Fe.hasOwnProperty(a))return Fe[a];var n=function(t){var e=t.match(Ue);if(null!==e)return aa(e[1]);if(null!==(e=t.match(ta)))return aa(e[1]);if(null!==(e=t.match(ea))){var a=-1*Number(e[1]);return aa(a)}return null!==(e=t.match(Xe))?aa(e[1]):null}(a);return n||null},ra=function(){function t(a,n,r){e(this,t),this.unit=n||"day";var o={};(r=r||{}).today&&(o={date:r.today.date(),month:r.today.month(),year:r.today.year()});var i=Ae(a,r.timezone,{today:o});i.isValid()&&(i=i.startOf(this.unit)),Object.defineProperty(this,"d",{enumerable:!1,writable:!0,value:i}),Object.defineProperty(this,"context",{enumerable:!1,writable:!0,value:r})}return n(t,[{key:"clone",value:function(){return new t(this.d,this.unit,this.context)}},{key:"log",value:function(){return console.log("--"),this.d.log(),console.log("\n"),this}},{key:"applyShift",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return Object.keys(e).forEach((function(a){t.d=t.d.add(e[a],a)})),this}},{key:"applyTime",value:function(t){return this.d=t?this.d.time(t):this.d.startOf("day"),this}},{key:"format",value:function(t){return this.d.format(t)}},{key:"start",value:function(){return this.d=this.d.startOf(this.unit),this}},{key:"end",value:function(){return this.d=this.d.endOf(this.unit),this}},{key:"before",value:function(){return this.d=Ae.now(this.context.timezone,{today:this.context.today}),this}},{key:"after",value:function(){return this.d=this.d.add(1,this.unit),this.d=this.d.startOf(this.unit),this}},{key:"next",value:function(){return this.d=this.d.add(1,this.unit),this.d=this.d.startOf(this.unit),this}},{key:"last",value:function(){return this.d=this.d.minus(1,this.unit),this.d=this.d.startOf(this.unit),this}}]),t}(),oa={Unit:ra,Day:function(t){r(n,t);var a=s(n);function n(t,r,o){var i;return e(this,n),(i=a.call(this,t,r,o)).unit="day",i}return n}(ra),Month:function(t){r(n,t);var a=s(n);function n(t,r,o){var i;return e(this,n),(i=a.call(this,t,r,o)).unit="month",i}return n}(ra),Quarter:function(t){r(n,t);var a=s(n);function n(t,r,o){var i;return e(this,n),(i=a.call(this,t,r,o)).unit="quarter",i}return n}(ra),Year:function(t){r(n,t);var a=s(n);function n(t,r,o){var i;return e(this,n),(i=a.call(this,t,r,o)).unit="year",i}return n}(ra),WeekDay:function(t){r(o,t);var a=s(o);function o(t,n,r){var i;return e(this,o),(i=a.call(this,t,n,r)).unit="week",i.d=i.d.day(t),i.weekDay=i.d.dayName(),i.d.date()0&&(n=new ia(e.today,null,e))),n},sa={week:oa.Week,month:oa.Month,quarter:oa.Quarter,year:oa.Year,season:oa.Season},ca=function(t,e){var a=t.match("(weekday|week|month|quarter|season|year)");if(!0===a.found){var n=a.lastTerm().text("reduced");if(sa.hasOwnProperty(n)){var r=sa[n];return r?new r(null,n,e):null}}if(!0===(a=t.match("(monday|tuesday|wednesday|thursday|friday|saturday|sunday)")).found){var o=a.lastTerm().text("reduced");return new oa.WeekDay(o,null,e)}return null},da=function(t,e,a){return t(a={path:e,exports:{},require:function(t,e){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}(null==e&&a.path)}},a.exports),a.exports}((function(t,e){t.exports=function(t){t=t&&t.hasOwnProperty("default")?t.default:t;var e="january",a="february",n="april",r="may",o="july",i="august",u="september",s="october",c="november",d="december",l={"new years eve":[d,31],"new years":[e,1],"new years day":[e,1],"inauguration day":[e,20],"australia day":[e,26],"national freedom day":[a,1],"groundhog day":[a,2],"rosa parks day":[a,4],"valentines day":[a,14],"saint valentines day":[a,14],"st valentines day ":[a,14],"saint patricks day":["march",17],"st patricks day":["march",17],"april fools":[n,1],"april fools day":[n,1],"emancipation day":[n,16],"tax day":[n,15],"labour day":[r,1],"cinco de mayo":[r,5],"national nurses day":[r,6],"harvey milk day":[r,22],"victoria day":[r,24],juneteenth:["june",19],"canada day":[o,1],"independence day":[o,4],"independents day":[o,4],"bastille day":[o,14],"purple heart day":[i,7],"womens equality day":[i,26],"16 de septiembre":[u,16],"dieciseis de septiembre":[u,16],"grito de dolores":[u,16],halloween:[s,31],"all hallows eve":[s,31],"day of the dead":[s,31],"dia de muertos":[s,31],"veterans day":[c,11],"st andrews day":[c,30],"saint andrews day":[c,30],"all saints day":[c,1],"all sts day":[c,1],"armistice day":[c,11],"rememberance day":[c,11],"christmas eve":[d,24],christmas:[d,25],xmas:[d,25],"boxing day":[d,26],"st stephens day":[d,26],"saint stephens day":[d,26],epiphany:[e,6],"orthodox christmas day":[e,7],"orthodox new year":[e,14],"assumption of mary":[i,15],"all souls day":[c,2],"feast of the immaculate conception":[d,8],"feast of our lady of guadalupe":[d,12],kwanzaa:[d,26],imbolc:[a,2],beltaine:[r,1],lughnassadh:[i,1],samhain:[s,31]},h=function(e,a,n){if(l.hasOwnProperty(e)||l.hasOwnProperty(a)){var r=l[e]||l[a]||[],o=t.now();if((o=(o=(o=(o=o.year(n)).startOf("year")).month(r[0])).date(r[1])).isValid())return o}return null},m="monday",f={"martin luther king day":[3,m,"january"],"presidents day":[3,m,"february"],"commonwealth day":[2,m,"march"],"mothers day":[2,"sunday","may"],"fathers day":[3,"sunday","june"],"labor day":[1,m,"september"],"columbus day":[2,m,"october"],"canadian thanksgiving":[2,m,"october"],thanksgiving:[4,"thursday","november"],"black friday":[4,"friday","november"]};f["turday day"]=f.thanksgiving,f["indigenous peoples day"]=f["columbus day"],f["mlk day"]=f["martin luther king day"];var y=f,p=function(e,a,n){if(y.hasOwnProperty(e)||y.hasOwnProperty(a)){var r=y[e]||y[a]||[],o=t.now(),i=(o=(o=(o=o.year(n)).month(r[2])).startOf("month")).month();if((o=o.day(r[1])).month()!==i&&(o=o.add(1,"week")),r[0]>1&&(o=o.add(r[0]-1,"week")),o.isValid())return o}return null},g={easter:0,"ash wednesday":-46,"palm sunday":7,"maundy thursday":-3,"good friday":-2,"holy saturday":-1,"easter saturday":-1,"easter monday":1,"ascension day":39,"whit sunday":49,"whit monday":50,"trinity sunday":65,"corpus christi":60,"mardi gras":-47};g["easter sunday"]=g.easter,g.pentecost=g["whit sunday"],g.whitsun=g["whit sunday"];var v=g,b=function(t){var e=Math.floor,a=t%19,n=e(t/100),r=(n-e(n/4)-e((8*n+13)/25)+19*a+15)%30,o=r-e(r/28)*(1-e(29/(r+1))*e((21-a)/11)),i=o-(t+e(t/4)+o+2-n+e(n/4))%7,u=3+e((i+40)/44),s=i+28-31*e(u/4);return(u=4===u?"April":"March")+" "+s},w=function(e,a,n){if(v.hasOwnProperty(e)||v.hasOwnProperty(a)){var r=v[e]||v[a]||[],o=b(n);if(!o)return null;var i=t(o),u=(i=i.year(n)).add(r,"day");if(u.isValid())return u}return null},k={spring:[2003,2007,2044,2048,2052,2056,2060,2064,2068,2072,2076,2077,2080,2081,2084,2085,2088,2089,2092,2093,2096,2097],summer:[2021,2016,2020,2024,2028,2032,2036,2040,2041,2044,2045,2048,2049,2052,2053,2056,2057,2060,2061,2064,2065,2068,2069,2070,2072,2073,2074,2076,2077,2078,2080,2081,2082,2084,2085,2086,2088,2089,2090,2092,2093,2094,2096,2097,2098,2099],fall:[2002,2003,2004,2006,2007,2010,2011,2014,2015,2018,2019,2022,2023,2026,2027,2031,2035,2039,2043,2047,2051,2055,2059,2092,2096],winter:[2002,2003,2006,2007,2011,2015,2019,2023,2027,2031,2035,2039,2043,2080,2084,2088,2092,2096]},D=[2080,2084,2088,2092,2096],z=function(t){var e={spring:"March 20 "+t,summer:"June 21 "+t,fall:"Sept 22 "+t,winter:"Dec 21 "+t};return-1!==k.spring.indexOf(t)&&(e.spring="March 19 "+t),-1!==k.summer.indexOf(t)&&(e.summer="June 20 "+t),-1!==k.fall.indexOf(t)&&(e.fall="Sept 21 "+t),-1!==k.winter.indexOf(t)&&(e.winter="Dec 22 "+t),-1!==D.indexOf(t)&&(e.winter="Dec 20 "+t),e},O={"spring equinox":"spring","summer solistice":"summer","fall equinox":"fall","winter solstice":"winter"};O["march equinox"]=O["spring equinox"],O["vernal equinox"]=O["spring equinox"],O.ostara=O["spring equinox"],O["june solstice"]=O["summer solistice"],O.litha=O["summer solistice"],O["autumn equinox"]=O["fall equinox"],O["autumnal equinox"]=O["fall equinox"],O["september equinox"]=O["fall equinox"],O["sept equinox"]=O["fall equinox"],O.mabon=O["fall equinox"],O["december solstice"]=O["winter solistice"],O["dec solstice"]=O["winter solistice"],O.yule=O["winter solistice"];var _=O,x=function(e,a,n){if(_.hasOwnProperty(e)||_.hasOwnProperty(a)){var r=_[e]||_[a],o=z(n);if(!r||!o||!o[r])return null;var i=t(o[r]);if(i.isValid())return i}return null},j={"isra and miraj":"april 13","lailat al-qadr":"june 10","eid al-fitr":"june 15","id al-Fitr":"june 15","eid ul-Fitr":"june 15",ramadan:"may 16","eid al-adha":"sep 22",muharram:"sep 12","prophets birthday":"nov 21"},T=function(e,a,n){if(j.hasOwnProperty(e)||j.hasOwnProperty(a)){var r=j[e]||j[a]||[];if(!r)return null;var o=t(r+" 2018"),i=-10.64*(n-2018);if((o=(o=(o=o.add(i,"day")).startOf("day")).year(n)).isValid())return o}return null},M=t.now().year();return function(t,e){e=e||M,t=t||"";var a=(t=(t=(t=String(t)).trim().toLowerCase()).replace(/'s/,"s")).replace(/ day$/,"");a=(a=a.replace(/^the /,"")).replace(/^orthodox /,"");var n=h(t,a,e);return null!==n||null!==(n=p(t,a,e))||null!==(n=w(t,a,e))||null!==(n=x(t,a,e))||null!==(n=T(t,a,e))?n:null}}(Ae)})),la=oa.CalendarDate,ha=function(t,e){var a=null,n=t.match("#Holiday+").text("reduced"),r=da(n,2020);return null!==r&&(a=new la(r,null,e)),a},ma=oa.Unit,fa=oa.Day,ya=oa.CalendarDate,pa={today:function(t){return new fa(t.today,null,t)},yesterday:function(t){new fa(t.today.minus(1,"day"),null,t)},tomorrow:function(t){new fa(t.today.plus(1,"day"),null,t)}},ga={shift:Ge,time:Re,relative:We,timezone:na},va={implied:ua,duration:ca,holiday:ha,explicit:function(t,e){var a=e.today.year(),n=t.match("[#Value] of [#Month] [#Year?]");if(n.found||(n=t.match("[#Month] the [#Value] [#Year?]")),n.found){var r={month:n.groups("month").text(),date:n.groups("date").text(),year:n.groups("year").text()||a},o=new ya(r,null,e);if(!0===o.d.isValid())return o}if(n.found){var i={month:n.groups("month").text(),date:n.groups("date").text(),year:e.today.year()},u=new ya(i,null,e);if(!0===u.d.isValid())return u}var s=t.text("reduced");if(!0===pa.hasOwnProperty(s))return pa[s](e);var c=new ma(s,null,e);return!1===c.d.isValid()?null:c}},ba=function(t,e){var a=ga.shift(t),n=ga.timezone(t),r=ga.time(t,e),o=ga.relative(t);if(n){var i=(e=Object.assign({},e,{timezone:n})).today.format("iso-short");e.today=e.today.goto(e.timezone).set(i)}var u=null;return(u=(u=(u=(u=u||va.implied(t,e,{shift:a,time:r,rel:o}))||va.duration(t,e))||va.holiday(t,e))||va.explicit(t,e))?("last"===o&&u.last(),"next"===o&&u.next(),a&&u.applyShift(a),u.applyTime(r),u):null},wa=function(t,e){return t=t.applyShift(e.casual_duration)},ka=function(t,e){var a=t.match("between [*] and [*]");if(a.found){var n=a.groups("start");n=ba(n,e);var r=a.groups("end");if(r=ba(r,e),n)return{start:n,end:r}}if((a=t.match("[#Month #Value] to [#Month #Value] [#Year?]")).found){var o=a.groups(),i=o.from;if(o.year&&(i=i.concat(o.year)),i=ba(i,e)){var u=o.to;return o.year&&(u=u.concat(o.year)),{start:i,end:u=ba(u,e)}}}if((a=t.match("[#Month] [#Value] to [#Value] of? [#Year]")).found){var s=a.groups(),c=s.month.concat(s.from,s.year);if(c=ba(c,e)){var d=s.month.concat(s.to,s.year);return{start:c,end:d=ba(d,e)}}}if((a=t.match("[#Value] to [#Value of? #Month of? #Year]")).found){var l=a.groups("to");if(l=ba(l,e)){var h=a.groups("to"),m=l.clone();return m.d=m.d.date(h.text("normal")),{start:m,end:l}}}if((a=t.match("[#Value] to [#Value of? #Month]")).found){var f=a.groups("to");if(f=ba(f,e)){var y=a.groups("from"),p=f.clone();return p.d=p.d.date(y.text("normal")),{start:p,end:f}}}if((a=t.match("[#Month #Value] to [#Value]")).found){var g=a.groups("from");if(g=ba(g,e)){var v=a.groups("to"),b=g.clone();return b.d=b.d.date(v.text("normal")),{start:g,end:b}}}if((a=t.match("from? [*] (to|@hasHyphen|until|upto) [*]")).found){var w=a.groups("from"),k=a.groups("to");if(w=ba(w,e),k=ba(k,e),w&&k)return{start:w,end:k}}if((a=t.match("^due (by|before|on|in)? [*]",0)).found){var D=ba(a,e);if(D)return{start:new ra(e.today,null,e),end:wa(D.clone(),e)}}if((a=t.match("^(after|following|from) [*]",0)).found){var z=ba(a,e);if(z)return{start:z,end:wa(z.clone(),e)}}if((a=t.match("^(on|during|in) [*]",0)).found){var O=ba(a,e);if(O)return{start:O,end:O.clone().end()}}return{start:ba(t,e),end:null}},Da=function(t,e){return(e=e||{}).timezone=e.timezone||"ETC/UTC",e.today=Ae(e.today||null,e.timezone),t=Ke(t),ka(t,e)},za=[["mon","monday"],["tue","tuesday"],["tues","tuesday"],["wed","wednesday"],["thu","thursday"],["thurs","thursday"],["fri","friday"],["sat","saturday"],["sun","sunday"],["jan","january"],["feb","february"],["mar","march"],["apr","april"],["jun","june"],["jul","july"],["aug","august"],["sep","september"],["sept","september"],["oct","october"],["nov","november"],["dec","december"]],Oa=za=za.map((function(t){return{short:t[0],long:t[1]}})),_a={json:function(t){var e=this,a=null;"number"==typeof t&&(a=t,t=null);var n=[],r=(t=t||{terms:!1}).format||"iso";return this.forEach((function(a){var o=a.json(t)[0],i=Da(a,e.context),u=i.start?i.start.format(r):null,s=i.end?i.end.format(r):null;o.date={start:u,end:s},u&&s&&(o.date.duration=i.start.d.diff(i.end.d),delete o.date.duration.milliseconds,delete o.date.duration.seconds),n.push(o)})),null!==a?n[a]:n},format:function(t){var e=this;return this.forEach((function(a){var n=Da(a,e.context),r="";if(n.start){if(r=n.start.format(t),n.end){var o=n.start.format(t);r!==o&&(r+=" to "+o)}a.replaceWith(r,{keepTags:!0,keepCase:!1})}})),this},toLongForm:function(){var t=this;return Oa.forEach((function(e){t.replace(e.short,e.long,!0)})),this},toShortForm:function(){var t=this;return Oa.forEach((function(e){t.replace(e.long,e.short,!0)})),this}};return function(a,n){n.addTags(D),n.addWords(Qe),n.postProcess(k);var o=function(t){r(n,t);var a=s(n);function n(t,r,o){var i;return e(this,n),(i=a.call(this,t,r,o)).context={casual_duration:{weeks:2}},i}return n}(a);Object.assign(o.prototype,_a),a.prototype.dates=function(e){var a={};e&&"object"===t(e)&&(a=e,e=null);var n=this.clauses().match("#Date+");"number"==typeof e&&(n=n.get(e)),"number"==typeof e&&(n=n.get(e));var r=new o(n.list,this,this.world);return a.today&&(a.today=Ae(a.today,a.timezone)),r.context=a,r}}})); +!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t=t||self).compromiseDates=e()}(this,(function(){"use strict";function t(e){return(t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(e)}function e(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function a(t,e){for(var a=0;a1e3&&n<3e3&&t.tag("Year",e)}}},f="date-values",y="date-tagger",p="section-tagger",g="time-tagger",v="shift-tagger",b="fix-tagger",w=[function(t){t.match("in the (night|evening|morning|afternoon|day|daytime)").tag("Time","in-the-night"),t.match("(#Value|#Time) (am|pm)").tag("Time","value-ampm");var e=t.if("#Month");!0===e.found&&(e.match("#Month #Date+").tag("Date","correction-numberRange"),e.match("#Value of #Month").tag("Date","value-of-month"),e.match("#Cardinal #Month").tag("Date","cardinal-month"),e.match("#Month #Value to #Value").tag("Date","value-to-value"),e.match("#Month the #Value").tag("Date","month-the-value"));var a=t.if("#Value");if(!0===a.found){a.match("(#WeekDay|#Month) #Value").ifNo("#Money").tag("Date","date-value"),a.match("#Value (#WeekDay|#Month)").ifNo("#Money").tag("Date","value-date"),a.match("#TextValue #TextValue").if("#Date").tag("#Date","textvalue-date");var n=a.if("#Duration");!0===n.found&&(n.match("for #Value #Duration").tag("Date","for-x-duration"),n.match("#Value #Duration #Conjunction").tag("Date","val-duration-conjunction"),n.match("".concat(c,"? #Value #Duration")).tag("Date","value-duration"),n.match("#Value #Duration old").unTag("Date","val-years-old"))}var r=t.if(h);!0===r.found&&(r.match("".concat(c,"? ").concat(d," ").concat(h)).tag("Date","thisNext-season"),r.match("the? ".concat(l," of ").concat(h)).tag("Date","section-season"),r.match("".concat(h," ").concat(c,"? #Cardinal")).tag("Date","season-year"));var o=t.if("#Date");!0===o.found&&(o.match("#Date the? #Ordinal").tag("Date","correction"),o.match("".concat(d," #Date")).tag("Date","thisNext"),o.match("due? (by|before|after|until) #Date").tag("Date","by"),o.match("(last|next|this|previous|current|upcoming|coming|the) #Date").tag("Date","next-feb"),o.match("the? ".concat(l," of #Date")).tag("Date","section-of"),o.match("#Ordinal #Duration in #Date").tag("Date","duration-in"),o.match("(early|late) (at|in)? the? #Date").tag("Time","early-evening"),o.match("#Date (by|before|after|at|@|about) #Cardinal").not("^#Date").tag("Time","date-before-Cardinal"),o.match("#Date [(am|pm)]",0).unTag("Verb").unTag("Copula").tag("Time","date-am"),o.match("#Date (#Preposition|to) #Date").ifNo("#Duration").tag("Date","date-prep-date"));var i=t.if("#Cardinal");if(!0===i.found){var u=i.match("#Date #Value [#Cardinal]",0);m(u,"date-value-year"),u=i.match("#Date+ [#Cardinal]",0),m(u,"date-year"),u=i.match("#Month #Value [#Cardinal]",0),m(u,"month-value-year"),u=i.match("#Month #Value to #Value [#Cardinal]",0),m(u,"month-range-year"),u=i.match("(in|of|by|during|before|starting|ending|for|year) [#Cardinal]",0),m(u,"in-year"),u=i.match("(q1|q2|q3|q4) [#Cardinal]",0),m(u,"in-year"),u=i.match("#Ordinal quarter [#Cardinal]",0),m(u,"in-year"),u=i.match("the year [#Cardinal]",0),m(u,"in-year"),function(t,e){if(!0===t.found){var a=t.termList()[0];if(a){var n=parseInt(a.clean,10);n&&n>1900&&n<2030&&t.tag("Year",e)}}}(u=i.match("it (is|was) [#Cardinal]",0),"in-year")}var s=t.if("#Time");return!0===s.found&&(s.match("(by|before|after|at|@|about) #Time").tag("Time","preposition-time"),s.match("#Cardinal #Time").not("#Year").tag("Time","value-time"),s.match("#Time [(eastern|pacific|central|mountain)]",0).tag("Date","timezone"),s.match("#Time [(est|pst|gmt)]",0).tag("Date","timezone abbr")),t},function(t){return t.match("!once [a] #Duration",0).replaceWith("1").tag("Cardinal",f),t.has("#Value")&&(t.match("#Month #Value to #Value of? #Year?").tag("Date",f),t.match("#Value to #Value of? #Month #Year?").tag("Date",f),t.match("#Value #Duration of #Date").tag("Date",f),t.match("#Value+ #Duration (after|before|into|later|afterwards|ago)?").tag("Date",f),t.match("#Value #Date").tag("Date",f),t.match("#Date #Value").tag("Date",f),t.match("#Date #Preposition #Value").tag("Date",f),t.match("#Date (after|before|during|on|in) #Value").tag("Date",f),t.match("#Value (year|month|week|day) and a half").tag("Date",f),t.match("#Value and a half (years|months|weeks|days)").tag("Date",f),t.match("on the #Ordinal").tag("Date",f)),t},function(t){return t.match("(spring|summer|winter|fall|autumn|springtime|wintertime|summertime)").match("#Noun").tag("Season",y),t.match("(q1|q2|q3|q4)").tag("FinancialQuarter",y),t.match("(this|next|last|current) quarter").tag("FinancialQuarter",y),t.match("(this|next|last|current) season").tag("Season",y),t.has("#Date")&&(t.match("#Date #Preposition #Date").tag("Date",y),t.match("(once|twice) (a|an|each) #Date").tag("Date",y),t.match("(by|until|on|in|at|during|over|every|each|due) the? #Date").tag("Date",y),t.match("#Date+").tag("Date",y),t.match("(by|until|on|in|at|during|over|every|each|due) the? #Date").tag("Date",y),t.match("a #Duration").tag("Date",y),t.match("(between|from) #Date").tag("Date",y),t.match("(to|until|upto) #Date").tag("Date",y),t.match("#Date and #Date").tag("Date",y),t.match("(by|until|after|before|during|on|in|following) (next|this|last)? (#Date|#Date)").tag("Date",y),t.match("the? #Date after next one?").tag("Date",y),t.match("(about|approx|approximately|around) #Date").tag("Date",y)),t},function(t){return t.has("#Date")&&(t.match("this? (last|next|past|this|previous|current|upcoming|coming|the) #Date").tag("Date",p),t.match("(starting|beginning|ending) #Date").tag("Date",p),t.match("the? (start|end|middle|beginning) of (last|next|this|the) (#Date|#Date)").tag("Date",p),t.match("(the|this) #Date").tag("Date",p)),t},function(t){return t.has("#Cardinal")&&!t.has("#Month")&&t.match("(half|quarter|25|15|10|5) (past|after|to) #Cardinal").tag("Time",g),t.has("#Date")&&(t.match("#Noun (standard|daylight|central|mountain)? time").tag("Timezone",g),t.match("/^utc[+-][0-9]/").tag("Timezone",g),t.match("/^gmt[+-][0-9]/").tag("Timezone",g),t.match("(in|for|by|near|at) #Timezone").tag("Timezone",g)),t},function(t){return t.has("#Date")&&(t.match("#Cardinal #Duration (before|after|ago|from)").tag("#DateShift",v),t.match("in #Cardinal #Duration").tag("#DateShift",v),t.match("#Cardinal #Duration and? #DateShift").tag("#DateShift",v),t.match("#DateShift and #Cardinal #Duration").tag("#DateShift",v)),t},function(t){if(t.has("#Date")){var e=t.match("#Date+ by #Date+");e.found&&!e.has("^due")&&e.match("^#Date+").unTag("Date","by-monday");var a=t.match("#Date+");a.match("^day$").unTag("Date","spa-day"),a.match("(in|of|by|for)? (#Possessive && #Date)").unTag("Date","tomorrows meeting");var n="(yesterday|today|tomorrow)";a.has(n)&&(a.match("".concat(n," [#Value]$")).unTag("Date","yesterday-7"),a.match("^[#Value] ".concat(n,"$"),0).unTag("Date","7 yesterday"),a.match("#WeekDay+ ".concat(n,"$")).unTag("Date").lastTerm().tag("Date","fri-yesterday"),a.match("(this|last|next) #Date ".concat(n,"$")).unTag("Date").lastTerm().tag("Date","this month yesterday")),a.match("on #Cardinal$").unTag("Date",b),a.match("this tomorrow").terms(0).unTag("Date","this-tomorrow"),a.match("(q1|q2|q3|q4) #Year").tag("Date",b),a.match("^#Value (this|next|last)").terms(0).unTag("Date",b),a.has("(last|this|next)")&&(a.match("(last|this|next) #Duration #Value").terms(2).unTag("Date",b),a.match("!#Month #Value (last|this|next) #Date").terms(0).unTag("Date",b)),!1===a.has("(#Year|#Time|#TextValue|#NumberRange)")&&a.match("(#Month|#WeekDay) #Value #Value").terms(2).unTag("Date",b),a.has("^between")&&!a.has("and .")&&a.unTag("Date",b),!a.has("#Month #Month")||a.has("@hasHyphen")||a.has("@hasComma")||a.match("#Month").lastTerm().unTag("Date","month-month"),a.has("(minutes|seconds|weeks|hours|days|months)")&&!a.has("#Value #Duration")&&a.match("(minutes|seconds|weeks|hours|days|months)").unTag("#Date","log-hours"),a.has("about #Holiday")&&a.match("about").unTag("#Date","about-thanksgiving")}return t}],k=function(t){return w.forEach((function(e){return e(t)})),t},D={FinancialQuarter:{isA:"Date"},Season:{isA:"Date"},Year:{isA:["Date"],notA:"RomanNumeral"},Duration:{isA:["Date","Noun"]},Holiday:{isA:["Date","Noun"]},Timezone:{isA:["Date","Noun"]},DateShift:{isA:["Date"]}};var z,O=function(t,e){return t(e={exports:{}},e.exports),e.exports}((function(t,e){e.isLeapYear=function(t){return t%4==0&&t%100!=0||t%400==0},e.isDate=function(t){return"[object Date]"===Object.prototype.toString.call(t)&&!isNaN(t.valueOf())},e.isArray=function(t){return"[object Array]"===Object.prototype.toString.call(t)},e.isObject=function(t){return"[object Object]"===Object.prototype.toString.call(t)},e.zeroPad=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,a="0";return(t+="").length>=e?t:new Array(e-t.length+1).join(a)+t},e.titleCase=function(t){return t?t[0].toUpperCase()+t.substr(1):""},e.ordinal=function(t){var e=t%10,a=t%100;return 1===e&&11!==a?t+"st":2===e&&12!==a?t+"nd":3===e&&13!==a?t+"rd":t+"th"},e.toCardinal=function(t){return t=(t=String(t)).replace(/([0-9])(st|nd|rd|th)$/i,"$1"),parseInt(t,10)},e.normalize=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return"day"===(t=(t=(t=(t=t.toLowerCase().trim()).replace(/ies$/,"y")).replace(/s$/,"")).replace(/-/g,""))?"date":t},e.getEpoch=function(t){return"number"==typeof t?t:e.isDate(t)?t.getTime():t.epoch?t.epoch:null},e.beADate=function(t,a){return!1===e.isObject(t)?a.clone().set(t):t},e.formatTimezone=function(t){var a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=Math.abs(t),r=t>0?"+":"-";return"".concat(r).concat(e.zeroPad(n)).concat(a,"00")}})),_=(O.isLeapYear,O.isDate,O.isArray,O.isObject,O.zeroPad,O.titleCase,O.ordinal,O.toCardinal,O.normalize,O.getEpoch,O.beADate,O.formatTimezone,O.zeroPad),x=function(t,e,a,n){var r=new Date(t),o=(r.getTimezoneOffset()||0)+60*n;o=60*o*1e3;var i=function(t){return _(t.getMonth()+1)+"/"+_(t.getDate())+":"+_(t.getHours())}(r=new Date(t+o));return i>=e&&i");return!0===x(t.epoch,r[0],r[1],a)?a:n},M=["africa","america","asia","atlantic","australia","brazil","canada","chile","europe","indian","mexico","pacific","antarctica","etc"],T=(z=Object.freeze({__proto__:null,default:{"9|s":"2/dili,2/jayapura","9|n":"2/chita,2/khandyga,2/pyongyang,2/seoul,2/tokyo,11/palau","9.5|s|04/05:03->10/04:02":"4/adelaide,4/broken_hill,4/south,4/yancowinna","9.5|s":"4/darwin,4/north","8|s":"12/casey,2/kuala_lumpur,2/makassar,2/singapore,4/perth,4/west","8|n|03/25:03->09/29:23":"2/ulan_bator","8|n":"2/brunei,2/choibalsan,2/chongqing,2/chungking,2/harbin,2/hong_kong,2/irkutsk,2/kuching,2/macao,2/macau,2/manila,2/shanghai,2/taipei,2/ujung_pandang,2/ulaanbaatar","8.75|s":"4/eucla","7|s":"12/davis,2/jakarta,9/christmas","7|n":"2/bangkok,2/barnaul,2/ho_chi_minh,2/hovd,2/krasnoyarsk,2/novokuznetsk,2/novosibirsk,2/phnom_penh,2/pontianak,2/saigon,2/tomsk,2/vientiane","6|s":"12/vostok","6|n":"2/almaty,2/bishkek,2/dacca,2/dhaka,2/kashgar,2/omsk,2/qyzylorda,2/thimbu,2/thimphu,2/urumqi,9/chagos","6.5|n":"2/rangoon,2/yangon,9/cocos","5|s":"12/mawson,9/kerguelen","5|n":"2/aqtau,2/aqtobe,2/ashgabat,2/ashkhabad,2/atyrau,2/baku,2/dushanbe,2/karachi,2/oral,2/samarkand,2/tashkent,2/yekaterinburg,9/maldives","5.75|n":"2/kathmandu,2/katmandu","5.5|n":"2/calcutta,2/colombo,2/kolkata","4|s":"9/reunion","4|n":"2/dubai,2/muscat,2/tbilisi,2/yerevan,8/astrakhan,8/samara,8/saratov,8/ulyanovsk,8/volgograd,2/volgograd,9/mahe,9/mauritius","4.5|n|03/21:00->09/20:24":"2/tehran","4.5|n":"2/kabul","3|s":"12/syowa,9/antananarivo","3|n|03/29:03->10/25:04":"2/famagusta,2/nicosia,8/athens,8/bucharest,8/helsinki,8/kiev,8/mariehamn,8/nicosia,8/riga,8/sofia,8/tallinn,8/uzhgorod,8/vilnius,8/zaporozhye","3|n|03/29:02->10/25:03":"8/chisinau,8/tiraspol","3|n|03/29:00->10/24:24":"2/beirut","3|n|03/27:02->10/25:02":"2/jerusalem,2/tel_aviv","3|n|03/27:00->10/31:01":"2/gaza,2/hebron","3|n|03/27:00->10/30:01":"2/amman","3|n|03/27:00->10/29:24":"2/damascus","3|n":"0/addis_ababa,0/asmara,0/asmera,0/dar_es_salaam,0/djibouti,0/juba,0/kampala,0/mogadishu,0/nairobi,2/aden,2/baghdad,2/bahrain,2/istanbul,2/kuwait,2/qatar,2/riyadh,8/istanbul,8/kirov,8/minsk,8/moscow,8/simferopol,9/comoro,9/mayotte","2|s|03/29:02->10/25:02":"12/troll","2|s":"0/gaborone,0/harare,0/johannesburg,0/lubumbashi,0/lusaka,0/maputo,0/maseru,0/mbabane","2|n|03/29:02->10/25:03":"0/ceuta,arctic/longyearbyen,3/jan_mayen,8/amsterdam,8/andorra,8/belgrade,8/berlin,8/bratislava,8/brussels,8/budapest,8/busingen,8/copenhagen,8/gibraltar,8/ljubljana,8/luxembourg,8/madrid,8/malta,8/monaco,8/oslo,8/paris,8/podgorica,8/prague,8/rome,8/san_marino,8/sarajevo,8/skopje,8/stockholm,8/tirane,8/vaduz,8/vatican,8/vienna,8/warsaw,8/zagreb,8/zurich","2|n":"0/blantyre,0/bujumbura,0/cairo,0/khartoum,0/kigali,0/tripoli,8/kaliningrad","1|s|04/02:01->09/03:03":"0/windhoek","1|s":"0/kinshasa,0/luanda","1|n|04/19:03->05/31:02":"0/casablanca,0/el_aaiun","1|n|03/29:01->10/25:02":"3/canary,3/faeroe,3/faroe,3/madeira,8/belfast,8/dublin,8/guernsey,8/isle_of_man,8/jersey,8/lisbon,8/london","1|n":"0/algiers,0/bangui,0/brazzaville,0/douala,0/lagos,0/libreville,0/malabo,0/ndjamena,0/niamey,0/porto-novo,0/tunis","14|n":"11/kiritimati","13|s|04/05:04->09/27:03":"11/apia","13|s|01/15:02->11/05:03":"11/tongatapu","13|n":"11/enderbury,11/fakaofo","12|s|04/05:03->09/27:02":"12/mcmurdo,12/south_pole,11/auckland","12|s|01/12:03->11/08:02":"11/fiji","12|n":"2/anadyr,2/kamchatka,2/srednekolymsk,11/funafuti,11/kwajalein,11/majuro,11/nauru,11/tarawa,11/wake,11/wallis","12.75|s|04/05:03->04/05:02":"11/chatham","11|s":"12/macquarie,11/bougainville","11|n":"2/magadan,2/sakhalin,11/efate,11/guadalcanal,11/kosrae,11/noumea,11/pohnpei,11/ponape","11.5|n|04/05:03->10/04:02":"11/norfolk","10|s|04/05:03->10/04:02":"4/act,4/canberra,4/currie,4/hobart,4/melbourne,4/nsw,4/sydney,4/tasmania,4/victoria","10|s":"12/dumontdurville,4/brisbane,4/lindeman,4/queensland","10|n":"2/ust-nera,2/vladivostok,2/yakutsk,11/chuuk,11/guam,11/port_moresby,11/saipan,11/truk,11/yap","10.5|s|04/05:01->10/04:02":"4/lhi,4/lord_howe","0|n|03/29:00->10/25:01":"1/scoresbysund,3/azores","0|n":"0/abidjan,0/accra,0/bamako,0/banjul,0/bissau,0/conakry,0/dakar,0/freetown,0/lome,0/monrovia,0/nouakchott,0/ouagadougou,0/sao_tome,0/timbuktu,1/danmarkshavn,3/reykjavik,3/st_helena,13/gmt,13/gmt+0,13/gmt-0,13/gmt0,13/greenwich,13/utc,13/universal,13/zulu","-9|n|03/08:02->11/01:02":"1/adak,1/atka","-9|n":"11/gambier","-9.5|n":"11/marquesas","-8|n|03/08:02->11/01:02":"1/anchorage,1/juneau,1/metlakatla,1/nome,1/sitka,1/yakutat","-8|n":"11/pitcairn","-7|n|03/08:02->11/01:02":"1/dawson,1/ensenada,1/los_angeles,1/santa_isabel,1/tijuana,1/vancouver,1/whitehorse,6/pacific,6/yukon,10/bajanorte","-7|n":"1/creston,1/dawson_creek,1/hermosillo,1/phoenix","-6|s|04/04:22->09/05:22":"7/easterisland,11/easter","-6|n|04/05:02->10/25:02":"1/chihuahua,1/mazatlan,10/bajasur","-6|n|03/08:02->11/01:02":"1/boise,1/cambridge_bay,1/denver,1/edmonton,1/inuvik,1/ojinaga,1/shiprock,1/yellowknife,6/mountain","-6|n":"1/belize,1/costa_rica,1/el_salvador,1/guatemala,1/managua,1/regina,1/swift_current,1/tegucigalpa,6/east-saskatchewan,6/saskatchewan,11/galapagos","-5|s":"1/lima,1/rio_branco,5/acre","-5|n|04/05:02->10/25:02":"1/bahia_banderas,1/merida,1/mexico_city,1/monterrey,10/general","-5|n|03/12:03->11/05:01":"1/north_dakota","-5|n|03/08:02->11/01:02":"1/chicago,1/knox_in,1/matamoros,1/menominee,1/rainy_river,1/rankin_inlet,1/resolute,1/winnipeg,6/central","-5|n":"1/atikokan,1/bogota,1/cancun,1/cayman,1/coral_harbour,1/eirunepe,1/guayaquil,1/jamaica,1/panama,1/porto_acre","-4|s|05/13:23->08/13:01":"12/palmer","-4|s|04/04:24->09/06:00":"1/santiago,7/continental","-4|s|03/21:24->10/04:00":"1/asuncion","-4|s|02/16:24->11/03:00":"1/campo_grande,1/cuiaba","-4|s":"1/la_paz,1/manaus,5/west","-4|n|03/12:03->11/05:01":"1/indiana,1/kentucky","-4|n|03/08:02->11/01:02":"1/detroit,1/fort_wayne,1/grand_turk,1/indianapolis,1/iqaluit,1/louisville,1/montreal,1/nassau,1/new_york,1/nipigon,1/pangnirtung,1/port-au-prince,1/thunder_bay,1/toronto,6/eastern","-4|n|03/08:00->11/01:01":"1/havana","-4|n":"1/anguilla,1/antigua,1/aruba,1/barbados,1/blanc-sablon,1/boa_vista,1/caracas,1/curacao,1/dominica,1/grenada,1/guadeloupe,1/guyana,1/kralendijk,1/lower_princes,1/marigot,1/martinique,1/montserrat,1/port_of_spain,1/porto_velho,1/puerto_rico,1/santo_domingo,1/st_barthelemy,1/st_kitts,1/st_lucia,1/st_thomas,1/st_vincent,1/tortola,1/virgin","-3|s":"1/argentina,1/buenos_aires,1/cordoba,1/fortaleza,1/montevideo,1/punta_arenas,1/sao_paulo,12/rothera,3/stanley,5/east","-3|n|03/08:02->11/01:02":"1/glace_bay,1/goose_bay,1/halifax,1/moncton,1/thule,3/bermuda,6/atlantic","-3|n":"1/araguaina,1/bahia,1/belem,1/catamarca,1/cayenne,1/jujuy,1/maceio,1/mendoza,1/paramaribo,1/recife,1/rosario,1/santarem","-2|s":"5/denoronha","-2|n|03/28:22->10/24:23":"1/godthab","-2|n|03/08:02->11/01:02":"1/miquelon","-2|n":"1/noronha,3/south_georgia","-2.5|n|03/08:02->11/01:02":"1/st_johns,6/newfoundland","-1|n":"3/cape_verde","-11|n":"11/midway,11/niue,11/pago_pago,11/samoa","-10|n":"11/honolulu,11/johnston,11/rarotonga,11/tahiti"}}))&&z.default||z,q={};Object.keys(T).forEach((function(t){var e=t.split("|"),a={offset:Number(e[0]),hem:e[1]};e[2]&&(a.dst=e[2]),T[t].split(",").forEach((function(t){t=t.replace(/(^[0-9]+)\//,(function(t,e){return e=Number(e),M[e]+"/"})),q[t]=a}))})),q.utc={offset:0,hem:"n"};for(var P=-14;P<=14;P+=.5){var C=P;C>0&&(C="+"+C);var S="etc/gmt"+C;q[S]={offset:-1*P,hem:"n"},q[S="utc/gmt"+C]={offset:-1*P,hem:"n"}}var V=q,E=/(\-?[0-9]+)h(rs)?/i,A=/(\-?[0-9]+)/,N=/utc([\-+]?[0-9]+)/i,L=/gmt([\-+]?[0-9]+)/i,Y=function(t){return(t=Number(t))>-13&&t<13?"etc/gmt"+(t=((t*=-1)>0?"+":"")+t):null},I=function(t){var e=t.match(E);if(null!==e)return Y(e[1]);if(null!==(e=t.match(N)))return Y(e[1]);if(null!==(e=t.match(L))){var a=-1*Number(e[1]);return Y(a)}return null!==(e=t.match(A))?Y(e[1]):null},H=function(){var t=function(){if("undefined"==typeof Intl||void 0===Intl.DateTimeFormat)return null;var t=Intl.DateTimeFormat();if(void 0===t||void 0===t.resolvedOptions)return null;var e=t.resolvedOptions().timeZone;return e?e.toLowerCase():null}();return null===t?"utc":t}(),$=Object.keys(V).reduce((function(t,e){var a=e.split("/")[1]||"";return t[a=a.replace(/_/g," ")]=e,t}),{}),B=function(t,e){if(!t)return H;var a=t.trim(),n=t.split("/");if(n.length>2&&!1===e.hasOwnProperty(a)&&(a=n[0]+"/"+n[1]),a=a.toLowerCase(),!0===e.hasOwnProperty(a))return a;if(a=function(t){return t=(t=(t=(t=(t=(t=t.replace(/ time/g,"")).replace(/ (standard|daylight|summer)/g,"")).replace(/\b(east|west|north|south)ern/g,"$1")).replace(/\b(africa|america|australia)n/g,"$1")).replace(/\beuropean/g,"europe")).replace(/\islands/g,"island")}(a),!0===e.hasOwnProperty(a))return a;if(!0===$.hasOwnProperty(a))return $[a];if(!0===/[0-9]/.test(a)){var r=I(a);if(r)return r}throw new Error("Spacetime: Cannot find timezone named: '"+t+"'. Please enter an IANA timezone id.")},F={millisecond:1,second:1e3,minute:6e4,hour:36e5,day:864e5};F.date=F.day,F.month=25488e5,F.week=6048e5,F.year=3154e7,Object.keys(F).forEach((function(t){F[t+"s"]=F[t]}));var J=F,Q=function(t,e,a,n,r){var o=t.d[a]();if(o!==e){var i=null===r?null:t.d[r](),u=t.epoch,s=e-o;t.epoch+=J[n]*s,"day"===n&&Math.abs(s)>28&&e<28&&(t.epoch+=J.hour),null!==r&&i!==t.d[r]()&&(t.epoch=u);for(var c=J[n]/2;t.d[a]()e;)t.epoch-=c;null!==r&&i!==t.d[r]()&&(t.epoch=u)}},K={year:{valid:function(t){return t>-4e3&&t<4e3},walkTo:function(t,e){return Q(t,e,"getFullYear","year",null)}},month:{valid:function(t){return t>=0&&t<=11},walkTo:function(t,e){var a=t.d,n=a.getMonth(),r=t.epoch,o=a.getFullYear();if(n!==e){var i=e-n;for(t.epoch+=J.day*(28*i),o!==t.d.getFullYear()&&(t.epoch=r);t.d.getMonth()e;)t.epoch-=J.day}}},date:{valid:function(t){return t>0&&t<=31},walkTo:function(t,e){return Q(t,e,"getDate","day","getMonth")}},hour:{valid:function(t){return t>=0&&t<24},walkTo:function(t,e){return Q(t,e,"getHours","hour","getDate")}},minute:{valid:function(t){return t>=0&&t<60},walkTo:function(t,e){return Q(t,e,"getMinutes","minute","getHours")}},second:{valid:function(t){return t>=0&&t<60},walkTo:function(t,e){t.epoch=t.seconds(e).epoch}},millisecond:{valid:function(t){return t>=0&&t<1e3},walkTo:function(t,e){t.epoch=t.milliseconds(e).epoch}}},G=function(t,e){for(var a=Object.keys(K),n=t.clone(),r=0;r100&&(a/=100),(a*=-1)>=0&&(a="+"+a);var n="etc/gmt"+a;return t.timezones[n]&&(t.tz=n),t},at=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",a=(e=e.replace(/^\s+/,"").toLowerCase()).match(/([0-9]{1,2}):([0-9]{1,2}):?([0-9]{1,2})?[:\.]?([0-9]{1,4})?/);if(null!==a){var n=Number(a[1]);if(n<0||n>24)return t.startOf("day");var r=Number(a[2]);if(a[2].length<2||r<0||r>59)return t.startOf("day");t=(t=(t=(t=t.hour(n)).minute(r)).seconds(a[3]||0)).millisecond(a[4]||0);var o=e.match(/[\b0-9](am|pm)\b/);return null!==o&&o[1]&&(t=t.ampm(o[1])),t}if(null!==(a=e.match(/([0-9]+) ?(am|pm)/))&&a[1]){var i=Number(a[1]);return i>12||i<1?t.startOf("day"):t=(t=(t=t.hour(a[1]||0)).ampm(a[2])).startOf("hour")}return t=t.startOf("day")},nt=[31,28,31,30,31,30,31,31,30,31,30,31],rt=O.isLeapYear,ot=function(t){if(!0!==nt.hasOwnProperty(t.month))return!1;if(1===t.month)return!!(rt(t.year)&&t.date<=29)||t.date<=28;var e=nt[t.month]||0;return t.date<=e},it=X(),ut=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",e=arguments.length>1?arguments[1]:void 0,a=parseInt(t.trim(),10);return!a&&e&&(a=e.year),a=a||(new Date).getFullYear()},st=[{reg:/^(\-?0?0?[0-9]{3,4})-([0-9]{1,2})-([0-9]{1,2})[T| ]([0-9.:]+)(Z|[0-9\-\+:]+)?$/,parse:function(t,e,a,n){var r=parseInt(e[2],10)-1,o={year:e[1],month:r,date:e[3]};return!1===ot(o)?(t.epoch=null,t):(et(t,e[5]),G(t,o),t=at(t,e[4]))}},{reg:/^([0-9]{4})[\-\/]([0-9]{1,2})[\-\/]([0-9]{1,2}),?( [0-9]{1,2}:[0-9]{2}:?[0-9]{0,2}? ?(am|pm|gmt))?$/i,parse:function(t,e){var a={year:e[1],month:parseInt(e[2],10)-1,date:parseInt(e[3],10)};return a.month>=12&&(a.date=parseInt(e[2],10),a.month=parseInt(e[3],10)-1),!1===ot(a)?(t.epoch=null,t):(G(t,a),t=at(t,e[4]))}},{reg:/^([0-9]{1,2})[\-\/]([0-9]{1,2})[\-\/]?([0-9]{4})?,?( [0-9]{1,2}:[0-9]{2}:?[0-9]{0,2}? ?(am|pm|gmt))?$/i,parse:function(t,e){var a=parseInt(e[1],10)-1,n=parseInt(e[2],10);(t.british||a>=12)&&(n=parseInt(e[1],10),a=parseInt(e[2],10)-1);var r={year:e[3]||(new Date).getFullYear(),month:a,date:n};return!1===ot(r)?(t.epoch=null,t):(G(t,r),t=at(t,e[4]))}},{reg:/^([0-9]{1,2})[\-\/]([a-z]+)[\-\/]?([0-9]{4})?$/i,parse:function(t,e){var a=it[e[2].toLowerCase()],n={year:ut(e[3],t._today),month:a,date:O.toCardinal(e[1]||"")};return!1===ot(n)?(t.epoch=null,t):(G(t,n),t=at(t,e[4]))}},{reg:/^([a-z]+) ([0-9]{1,2}(?:st|nd|rd|th)?),?( [0-9]{4})?( ([0-9:]+( ?am| ?pm| ?gmt)?))?$/i,parse:function(t,e){var a=it[e[1].toLowerCase()],n={year:ut(e[3],t._today),month:a,date:O.toCardinal(e[2]||"")};return!1===ot(n)?(t.epoch=null,t):(G(t,n),t=at(t,e[4]))}},{reg:/^([a-z]+) ([0-9]{4})$/i,parse:function(t,e){var a=it[e[1].toLowerCase()],n={year:ut(e[2],t._today),month:a,date:t._today.date||1};return!1===ot(n)?(t.epoch=null,t):(G(t,n),t=at(t,e[4]))}},{reg:/^([0-9]{1,2}(?:st|nd|rd|th)?) ([a-z]+),?( [0-9]{4})?,? ?([0-9]{1,2}:[0-9]{2}:?[0-9]{0,2}? ?(am|pm|gmt))?$/i,parse:function(t,e){var a=it[e[2].toLowerCase()];if(!a)return null;var n={year:ut(e[3],t._today),month:a,date:O.toCardinal(e[1])};return!1===ot(n)?(t.epoch=null,t):(G(t,n),t=at(t,e[4]))}},{reg:/^[0-9,]+ ?b\.?c\.?$/i,parse:function(t,e){var a=e[0]||"";a=(a=a.replace(/^([0-9,]+) ?b\.?c\.?$/i,"-$1")).replace(/,/g,"");var n=parseInt(a.trim(),10),r=new Date,o={year:n,month:r.getMonth(),date:r.getDate()};return!1===ot(o)?(t.epoch=null,t):(G(t,o),t=at(t))}},{reg:/^[0-9,]+ ?(a\.?d\.?|c\.?e\.?)$/i,parse:function(t,e){var a=e[0]||"";a=a.replace(/,/g,"");var n=parseInt(a.trim(),10),r=new Date,o={year:n,month:r.getMonth(),date:r.getDate()};return!1===ot(o)?(t.epoch=null,t):(G(t,o),t=at(t))}},{reg:/^[0-9]{4}( ?a\.?d\.?)?$/i,parse:function(t,e){var a=t._today,n=ut(e[0],a),r=new Date;a.month&&!a.date&&(a.date=1);var o={year:n,month:a.month||r.getMonth(),date:a.date||r.getDate()};return!1===ot(o)?(t.epoch=null,t):(G(t,o),t=at(t))}}],ct=function(t){return t.epoch=Date.now(),Object.keys(t._today||{}).forEach((function(e){"function"==typeof t[e]&&(t=t[e](t._today[e]))})),t},dt={now:function(t){return ct(t)},today:function(t){return ct(t)},tonight:function(t){return t=(t=ct(t)).hour(18)},tomorrow:function(t){return t=(t=(t=ct(t)).add(1,"day")).startOf("day")},yesterday:function(t){return t=(t=(t=ct(t)).subtract(1,"day")).startOf("day")},christmas:function(t){var e=ct(t).year();return t=t.set([e,11,25,18,0,0])},"new years":function(t){var e=ct(t).year();return t=t.set([e,11,31,18,0,0])}};dt["new years eve"]=dt["new years"];var lt=dt,ht={year:(new Date).getFullYear(),month:0,date:1},mt=function(t,e,a){e=Object.assign({},ht,a,e);for(var n=Object.keys(e),r=0;r0&&e<25e8&&!1===t.silent&&(console.warn(" - Warning: You are setting the date to January 1970."),console.warn(" - did input seconds instead of milliseconds?")),t.epoch=e,t;if(t.epoch=Date.now(),t._today&&O.isObject(t._today)&&Object.keys(t._today).length>0){var r=mt(t,n,ht);r.isValid()&&(t.epoch=r.epoch)}if(null==e||""===e)return t;if(!0===O.isDate(e))return t.epoch=e.getTime(),t;if(!0===O.isArray(e))return t=function(t,e,a){for(var n=["year","month","date","hour","minute","second","millisecond"],r=0;r=0?Math.floor(e):Math.ceil(e)),a?(e*=-1,e="-"+(e=O.zeroPad(e,2))):e="+"+(e=O.zeroPad(e,2)),"+00:00"===(e=e+":"+n)&&(e="Z"),e},kt={day:function(t){return O.titleCase(t.dayName())},"day-short":function(t){return O.titleCase(gt()[t.day()])},"day-number":function(t){return t.day()},"day-ordinal":function(t){return O.ordinal(t.day())},"day-pad":function(t){return O.zeroPad(t.day())},date:function(t){return t.date()},"date-ordinal":function(t){return O.ordinal(t.date())},"date-pad":function(t){return O.zeroPad(t.date())},month:function(t){return O.titleCase(t.monthName())},"month-short":function(t){return O.titleCase(W()[t.month()])},"month-number":function(t){return t.month()},"month-ordinal":function(t){return O.ordinal(t.month())},"month-pad":function(t){return O.zeroPad(t.month())},"iso-month":function(t){return O.zeroPad(t.month()+1)},year:function(t){var e=t.year();return e>0?e:(e=Math.abs(e),e+" BC")},"year-short":function(t){var e=t.year();return e>0?"'".concat(String(t.year()).substr(2,4)):(e=Math.abs(e))+" BC"},"iso-year":function(t){var e=t.year(),a=e<0,n=O.zeroPad(Math.abs(e),4);return a&&(n="-"+(n=O.zeroPad(n,6))),n},time:function(t){return t.time()},"time-24":function(t){return"".concat(t.hour24(),":").concat(O.zeroPad(t.minute()))},hour:function(t){return t.hour12()},"hour-pad":function(t){return O.zeroPad(t.hour12())},"hour-24":function(t){return t.hour24()},"hour-24-pad":function(t){return O.zeroPad(t.hour24())},minute:function(t){return t.minute()},"minute-pad":function(t){return O.zeroPad(t.minute())},second:function(t){return t.second()},"second-pad":function(t){return O.zeroPad(t.second())},ampm:function(t){return t.ampm()},quarter:function(t){return"Q"+t.quarter()},season:function(t){return t.season()},era:function(t){return t.era()},json:function(t){return t.json()},timezone:function(t){return t.timezone().name},offset:function(t){return wt(t)},numeric:function(t){return"".concat(t.year(),"/").concat(O.zeroPad(t.month()+1),"/").concat(O.zeroPad(t.date()))},"numeric-us":function(t){return"".concat(O.zeroPad(t.month()+1),"/").concat(O.zeroPad(t.date()),"/").concat(t.year())},"numeric-uk":function(t){return"".concat(O.zeroPad(t.date()),"/").concat(O.zeroPad(t.month()+1),"/").concat(t.year())},"mm/dd":function(t){return"".concat(O.zeroPad(t.month()+1),"/").concat(O.zeroPad(t.date()))},iso:function(t){var e=t.format("iso-year"),a=O.zeroPad(t.month()+1),n=O.zeroPad(t.date()),r=O.zeroPad(t.h24()),o=O.zeroPad(t.minute()),i=O.zeroPad(t.second()),u=O.zeroPad(t.millisecond(),3),s=wt(t);return"".concat(e,"-").concat(a,"-").concat(n,"T").concat(r,":").concat(o,":").concat(i,".").concat(u).concat(s)},"iso-short":function(t){var e=O.zeroPad(t.month()+1),a=O.zeroPad(t.date());return"".concat(t.year(),"-").concat(e,"-").concat(a)},"iso-utc":function(t){return new Date(t.epoch).toISOString()},nice:function(t){return"".concat(W()[t.month()]," ").concat(O.ordinal(t.date()),", ").concat(t.time())},"nice-year":function(t){return"".concat(W()[t.month()]," ").concat(O.ordinal(t.date()),", ").concat(t.year())},"nice-day":function(t){return"".concat(gt()[t.day()]," ").concat(O.titleCase(W()[t.month()])," ").concat(O.ordinal(t.date()))},"nice-full":function(t){return"".concat(t.dayName()," ").concat(O.titleCase(t.monthName())," ").concat(O.ordinal(t.date()),", ").concat(t.time())}},Dt={"day-name":"day","month-name":"month","iso 8601":"iso","time-h24":"time-24","time-12":"time","time-h12":"time",tz:"timezone","day-num":"day-number","month-num":"month-number","month-iso":"iso-month","year-iso":"iso-year","nice-short":"nice",mdy:"numeric-us",dmy:"numeric-uk",ymd:"numeric","yyyy/mm/dd":"numeric","mm/dd/yyyy":"numeric-us","dd/mm/yyyy":"numeric-us","little-endian":"numeric-uk","big-endian":"numeric","day-nice":"nice-day"};Object.keys(Dt).forEach((function(t){return kt[t]=kt[Dt[t]]}));var zt=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";if(!0!==t.isValid())return"";if(kt.hasOwnProperty(e)){var a=kt[e](t)||"";return"json"!==e&&(a=String(a),"ampm"!==e&&(a=O.titleCase(a))),a}if(-1!==e.indexOf("{")){var n=/\{(.+?)\}/g;return e=e.replace(n,(function(e,a){return a=a.toLowerCase().trim(),kt.hasOwnProperty(a)?String(kt[a](t)):""}))}return t.format("iso-short")},Ot=O.zeroPad,_t=O.formatTimezone,xt={G:function(t){return t.era()},GG:function(t){return t.era()},GGG:function(t){return t.era()},GGGG:function(t){return"AD"===t.era()?"Anno Domini":"Before Christ"},y:function(t){return t.year()},yy:function(t){return parseInt(String(t.year()).substr(2,4),10)},yyy:function(t){return t.year()},yyyy:function(t){return t.year()},yyyyy:function(t){return"0"+t.year()},Q:function(t){return t.quarter()},QQ:function(t){return t.quarter()},QQQ:function(t){return t.quarter()},QQQQ:function(t){return t.quarter()},M:function(t){return t.month()+1},MM:function(t){return Ot(t.month()+1)},MMM:function(t){return t.format("month-short")},MMMM:function(t){return t.format("month")},w:function(t){return t.week()},ww:function(t){return Ot(t.week())},d:function(t){return t.date()},dd:function(t){return Ot(t.date())},D:function(t){return t.dayOfYear()},DD:function(t){return Ot(t.dayOfYear())},DDD:function(t){return Ot(t.dayOfYear(),3)},E:function(t){return t.format("day-short")},EE:function(t){return t.format("day-short")},EEE:function(t){return t.format("day-short")},EEEE:function(t){return t.format("day")},EEEEE:function(t){return t.format("day")[0]},e:function(t){return t.day()},ee:function(t){return t.day()},eee:function(t){return t.format("day-short")},eeee:function(t){return t.format("day")},eeeee:function(t){return t.format("day")[0]},a:function(t){return t.ampm().toUpperCase()},aa:function(t){return t.ampm().toUpperCase()},aaa:function(t){return t.ampm().toUpperCase()},aaaa:function(t){return t.ampm().toUpperCase()},h:function(t){return t.h12()},hh:function(t){return Ot(t.h12())},H:function(t){return t.hour()},HH:function(t){return Ot(t.hour())},m:function(t){return t.minute()},mm:function(t){return Ot(t.minute())},s:function(t){return t.second()},ss:function(t){return Ot(t.second())},A:function(t){return t.epoch-t.startOf("day").epoch},z:function(t){return t.timezone().name},zz:function(t){return t.timezone().name},zzz:function(t){return t.timezone().name},zzzz:function(t){return t.timezone().name},Z:function(t){return _t(t.timezone().current.offset)},ZZ:function(t){return _t(t.timezone().current.offset)},ZZZ:function(t){return _t(t.timezone().current.offset)},ZZZZ:function(t){return _t(t.timezone().current.offset,":")}},jt=function(t,e,a){for(var n=t,r=e,o=0;o.5&&(t=t.add(1,e)),t=t.startOf(e)):!1===t.silent&&console.warn("no known unit '"+e+"'"),t},St=function(t,e,a){var n=0;for(t=t.clone();t.isBefore(e);)t=t.add(1,a),n+=1;return t.isAfter(e,a)&&(n-=1),n},Vt=function(t,e,a){return t.isBefore(e)?St(t,e,a):-1*St(e,t,a)},Et=function(t,e){var a=e.epoch-t.epoch,n={milliseconds:a,seconds:parseInt(a/1e3,10)};n.minutes=parseInt(n.seconds/60,10),n.hours=parseInt(n.minutes/60,10);var r=t.clone();return n.years=function(t,e){var a=e.year()-t.year();return(t=t.year(e.year())).isAfter(e)&&(a-=1),a}(r,e),r=t.add(n.years,"year"),n.months=12*n.years,r=t.add(n.months,"month"),n.months+=Vt(r,e,"month"),n.weeks=52*n.years,r=t.add(n.weeks,"week"),n.weeks+=Vt(r,e,"week"),n.days=7*n.weeks,r=t.add(n.days,"day"),n.days+=Vt(r,e,"day"),n},At=function(t,e,a){e=O.beADate(e,t);var n=!1;if(t.isAfter(e)){var r=t;t=e,e=r,n=!0}var o=Et(t,e);return n&&(o=function(t){return Object.keys(t).forEach((function(e){t[e]*=-1})),t}(o)),a?(a=O.normalize(a),!0!==/s$/.test(a)&&(a+="s"),"dates"===a&&(a="days"),o[a]):o},Nt={months:{almost:10,over:4},days:{almost:25,over:10},hours:{almost:20,over:8},minutes:{almost:50,over:20},seconds:{almost:50,over:20}};function Lt(t,e){return 1===t&&(e=e.slice(0,-1)),t+" "+e}var Yt=function(t,e){var a,n,r,o=function(t,e){var a=t.isBefore(e),n=a?e:t,r=a?t:e;r=r.clone();var o={years:0,months:0,days:0,hours:0,minutes:0,seconds:0};return Object.keys(o).forEach((function(t){if(!r.isSame(n,t)){var e=r.diff(n,t);r=r.add(e,t),o[t]=e}})),a&&Object.keys(o).forEach((function(t){0!==o[t]&&(o[t]*=-1)})),o}(t,e=O.beADate(e,t));if(!0===Object.keys(o).every((function(t){return!o[t]})))return{diff:o,rounded:"now",qualified:"now",precise:"now"};var i=[];return Object.keys(o).forEach((function(t,e,r){var u=Math.abs(o[t]);if(0!==u){var s=Lt(u,t);if(i.push(s),!a){if(a=n=s,e>4)return;var c=r[e+1],d=Math.abs(o[c]);d>Nt[c].almost?(a=Lt(u+1,t),n="almost "+a):d>Nt[c].over&&(n="over "+s)}}})),r=i.splice(0,2).join(", "),!0===t.isAfter(e)?(a+=" ago",n+=" ago",r+=" ago"):(a="in "+a,n="in "+n,r="in "+r),{diff:o,rounded:a,qualified:n,precise:r}},It={north:[["spring",2,1],["summer",5,1],["fall",8,1],["autumn",8,1],["winter",11,1]],south:[["fall",2,1],["autumn",2,1],["winter",5,1],["spring",8,1],["summer",11,1]]},Ht=[null,[0,1],[3,1],[6,1],[9,1]],$t={minute:function(t){return G(t,{second:0,millisecond:0}),t},quarterhour:function(t){var e=t.minutes();return t=e>=45?t.minutes(45):e>=30?t.minutes(30):e>=15?t.minutes(15):t.minutes(0),G(t,{second:0,millisecond:0}),t},hour:function(t){return G(t,{minute:0,second:0,millisecond:0}),t},day:function(t){return G(t,{hour:0,minute:0,second:0,millisecond:0}),t},week:function(t){var e=t.clone();return(t=t.day(t._weekStart)).isAfter(e)&&(t=t.subtract(1,"week")),G(t,{hour:0,minute:0,second:0,millisecond:0}),t},month:function(t){return G(t,{date:1,hour:0,minute:0,second:0,millisecond:0}),t},quarter:function(t){var e=t.quarter();return Ht[e]&&G(t,{month:Ht[e][0],date:Ht[e][1],hour:0,minute:0,second:0,millisecond:0}),t},season:function(t){var e=t.season(),a="north";"South"===t.hemisphere()&&(a="south");for(var n=0;n1&&void 0!==arguments[1]?arguments[1]:"",a=arguments.length>2?arguments[2]:void 0;if(!e||!a)return[];if(e=O.normalize(e),a=t.clone().set(a),t.isAfter(a)){var n=t;t=a,a=n}var r=t.clone();Jt(e)?(r=r.next(e),e="week"):r=r.next(e);for(var o=[];r.isBefore(a);)o.push(r),r=r.add(1,e);return o},Kt=function(t){var e=t.timezones,a=t.tz;if(!1===e.hasOwnProperty(a)&&(a=B(t.tz,e)),null===a)return!1===t.silent&&console.warn("Warn: could not find given or local timezone - '"+t.tz+"'"),{current:{epochShift:0}};var n,r,o=e[a],i={name:(n=a,n=(n=(n=n[0].toUpperCase()+n.substr(1)).replace(/\/gmt/,"/GMT")).replace(/[\/_]([a-z])/gi,(function(t){return t.toUpperCase()}))),hasDst:Boolean(o.dst),default_offset:o.offset,hemisphere:"s"===o.hem?"South":"North",current:{}};if(i.hasDst){var u=(r=o.dst)?r.split("->"):[];i.change={start:u[0],back:u[1]}}var s=o.offset,c=s;return!0===i.hasDst&&(c="North"===i.hemisphere?s-1:o.offset+1),!1===i.hasDst?(i.current.offset=s,i.current.isDST=!1):!0===x(t.epoch,i.change.start,i.change.back,s)?(i.current.offset=s,i.current.isDST="North"===i.hemisphere):(i.current.offset=c,i.current.isDST="South"===i.hemisphere),i},Gt=["century","decade","year","month","date","day","hour","minute","second","millisecond"],Zt={set:function(t,e){var a=this.clone();return a=ft(a,t,null),e&&(this.tz=B(e)),a},timezone:function(){return Kt(this)},isDST:function(){return Kt(this).current.isDST},hasDST:function(){return Kt(this).hasDst},offset:function(){return 60*Kt(this).current.offset},hemisphere:function(){return Kt(this).hemisphere},format:function(t){return zt(this,t)},unixFmt:function(t){return Mt(this,t)},startOf:function(t){return Bt(this,t)},endOf:function(t){return Ft(this,t)},leapYear:function(){var t=this.year();return O.isLeapYear(t)},progress:function(t){return Pt(this,t)},nearest:function(t){return Ct(this,t)},diff:function(t,e){return At(this,t,e)},since:function(t){return t||(t=this.clone().set()),Yt(this,t)},next:function(t){return this.add(1,t).startOf(t)},last:function(t){return this.subtract(1,t).startOf(t)},isValid:function(){return!(!this.epoch&&0!==this.epoch)&&!isNaN(this.d.getTime())},goto:function(t){var e=this.clone();return e.tz=B(t,e.timezones),e},every:function(t,e){return Qt(this,t,e)},isAwake:function(){var t=this.hour();return!(t<8||t>22)},isAsleep:function(){return!this.isAwake()},log:function(){return console.log(""),console.log(zt(this,"nice-short")),this},logYear:function(){return console.log(""),console.log(zt(this,"full-short")),this},json:function(){var t=this;return Gt.reduce((function(e,a){return e[a]=t[a](),e}),{})},debug:function(){var t=this.timezone(),e=this.format("MM")+" "+this.format("date-ordinal")+" "+this.year();return e+="\n - "+this.format("time"),console.log("\n\n",e+"\n - "+t.name+" ("+t.current.offset+")"),this},from:function(t){return(t=this.clone().set(t)).since(this)},fromNow:function(){return this.clone().set(Date.now()).since(this)},weekStart:function(t){if("number"==typeof t)return this._weekStart=t,this;if("string"==typeof t){t=t.toLowerCase().trim();var e=gt().indexOf(t);-1===e&&(e=vt().indexOf(t)),-1===e&&(e=1),this._weekStart=e}else console.warn("Spacetime Error: Cannot understand .weekStart() input:",t);return this}};Zt.inDST=Zt.isDST,Zt.round=Zt.nearest,Zt.each=Zt.every;var Rt=Zt,Wt=O.isLeapYear,Ut=function(t){return"string"==typeof t&&(t=parseInt(t,10)),t},Xt=["year","month","date","hour","minute","second","millisecond"],te=function(t,e,a){for(var n=Xt.indexOf(a),r=Xt.slice(n,Xt.length),o=0;o=24?e=24:e<0&&(e=0);var a=t.clone(),n=(t.hour()-e)*J.hour;return t.epoch-=n,G(t,{hour:e}),te(t,a,"minute"),t.epoch},oe=function(t,e){var a=e.match(/([0-9]{1,2}):([0-9]{1,2})(am|pm)?/);if(!a){if(!(a=e.match(/([0-9]{1,2})(am|pm)/)))return t.epoch;a.splice(2,0,"0")}var n=!1,r=parseInt(a[1],10),o=parseInt(a[2],10);return r>12&&(n=!0),!1===n&&("am"===a[3]&&12===r&&(r=0),"pm"===a[3]&&r<12&&(r+=12)),(t=(t=(t=(t=t.hour(r)).minute(o)).second(0)).millisecond(0)).epoch},ie=function(t,e){if((e=Ut(e))>28){var a=t.month(),n=nt[a];1===a&&29===e&&Wt(t.year())&&(n=29),e>n&&(e=n)}return e<=0&&(e=1),G(t,{date:e}),t.epoch},ue=function(t,e){"string"==typeof e&&(e=X()[e.toLowerCase()]),(e=Ut(e))>=12&&(e=11),e<=0&&(e=0);var a=t.date();return a>nt[e]&&(a=nt[e]),G(t,{month:e,date:a}),t.epoch},se=function(t,e){return e=Ut(e),G(t,{year:e}),t.epoch},ce=function(t,e){e=Ut(e);var a=t.clone();return(e-=1)<=0?e=0:e>=365&&(e=364),t=(t=t.startOf("year")).add(e,"day"),te(t,a,"hour"),t.epoch},de={millisecond:function(t){if(void 0!==t){var e=this.clone();return e.epoch=ee(e,t),e}return this.d.getMilliseconds()},second:function(t){if(void 0!==t){var e=this.clone();return e.epoch=ae(e,t),e}return this.d.getSeconds()},minute:function(t){if(void 0!==t){var e=this.clone();return e.epoch=ne(e,t),e}return this.d.getMinutes()},hour:function(t){var e=this.d;if(void 0!==t){var a=this.clone();return a.epoch=re(a,t),a}return e.getHours()},hourFloat:function(t){if(void 0!==t){var e=this.clone(),a=t%1;a*=60;var n=parseInt(t,10);return e.epoch=re(e,n),e.epoch=ne(e,a),e}var r=this.d,o=r.getHours(),i=r.getMinutes();return o+(i/=60)},hour12:function(t){var e=this.d;if(void 0!==t){var a=this.clone(),n=(t=""+t).match(/^([0-9]+)(am|pm)$/);if(n){var r=parseInt(n[1],10);"pm"===n[2]&&(r+=12),a.epoch=re(a,r)}return a}var o=e.getHours();return o>12&&(o-=12),0===o&&(o=12),o},time:function(t){if(void 0!==t){var e=this.clone();return e.epoch=oe(e,t),e}return"".concat(this.h12(),":").concat(O.zeroPad(this.minute())).concat(this.ampm())},ampm:function(t){var e="am",a=this.hour();if(a>=12&&(e="pm"),"string"!=typeof t)return e;var n=this.clone();return t=t.toLowerCase().trim(),a>=12&&"am"===t?(a-=12,n.hour(a)):a<12&&"pm"===t?(a+=12,n.hour(a)):n},dayTime:function(t){if(void 0!==t){var e={morning:"7:00am",breakfast:"7:00am",noon:"12:00am",lunch:"12:00pm",afternoon:"2:00pm",evening:"6:00pm",dinner:"6:00pm",night:"11:00pm",midnight:"23:59pm"},a=this.clone();return t=(t=t||"").toLowerCase(),!0===e.hasOwnProperty(t)&&(a=a.time(e[t])),a}var n=this.hour();return n<6?"night":n<12?"morning":n<17?"afternoon":n<22?"evening":"night"},iso:function(t){return void 0!==t?this.set(t):this.format("iso")}},le={date:function(t){if(void 0!==t){var e=this.clone();return e.epoch=ie(e,t),e}return this.d.getDate()},day:function(t){if(void 0===t)return this.d.getDay();var e=this.clone(),a=t;"string"==typeof t&&(t=t.toLowerCase(),-1===(a=gt().indexOf(t))&&(a=vt().indexOf(t)));var n=this.d.getDay(),r=n-a,o=this.subtract(24*r,"hours");return G(o,{hour:e.hour(),minute:e.minute(),second:e.second()}),o},dayName:function(t){if(void 0===t)return vt()[this.day()];var e=this.clone();return e=e.day(t)},month:function(t){if(void 0!==t){var e=this.clone();return e.epoch=ue(e,t),e}return this.d.getMonth()}},he=function(t){return t=(t=(t=t.minute(0)).second(0)).millisecond(1)},me={dayOfYear:function(t){if(void 0!==t){var e=this.clone();return e.epoch=ce(e,t),e}for(var a,n=0,r=this.d.getMonth(),o=1;o<=r;o++)(a=new Date).setDate(1),a.setFullYear(this.d.getFullYear()),a.setHours(1),a.setMinutes(1),a.setMonth(o),a.setHours(-2),n+=a.getDate();return n+this.d.getDate()},week:function(t){if(void 0!==t){var e=this.clone();return e=(e=(e=e.month(0)).date(1)).day("monday"),"december"===(e=he(e)).monthName()&&(e=e.add(1,"week")),t-=1,e=e.add(t,"weeks")}var a=this.clone();a=(a=a.month(0)).date(1),"december"===(a=(a=he(a)).day("monday")).monthName()&&(a=a.add(1,"week"));var n=1;1===a.date()&&(n=0),a=a.minus(1,"second");var r=this.epoch;if(a.epoch>r)return 1;var o=0,i=4*this.month();for(a.epoch+=J.week*i,o+=i;o<52;o++){if(a.epoch>r)return o+n;a=a.add(1,"week")}return 52},monthName:function(t){if(void 0===t)return U()[this.month()];var e=this.clone();return e=e.month(t)},quarter:function(t){if(void 0!==t&&("string"==typeof t&&(t=t.replace(/^q/i,""),t=parseInt(t,10)),Ht[t])){var e=this.clone(),a=Ht[t][0];return e=(e=(e=e.month(a)).date(1)).startOf("day")}for(var n=this.d.getMonth(),r=1;r=It[e][o][1]&&r0&&(e.epoch=se(e,-1*a)),"ad"===t&&a<0&&(e.epoch=se(e,-1*a)),e}return this.d.getFullYear()<0?"BC":"AD"},decade:function(t){if(void 0!==t){if(!(t=(t=(t=String(t)).replace(/([0-9])'?s$/,"$1")).replace(/([0-9])(th|rd|st|nd)/,"$1")))return console.warn("Spacetime: Invalid decade input"),this;2===t.length&&/[0-9][0-9]/.test(t)&&(t="19"+t);var e=Number(t);return isNaN(e)?this:(e=10*Math.floor(e/10),this.year(e))}return this.startOf("decade").year()},century:function(t){if(void 0!==t){"string"==typeof t&&(t=(t=(t=t.replace(/([0-9])(th|rd|st|nd)/,"$1")).replace(/([0-9]+) ?(b\.?c\.?|a\.?d\.?)/i,(function(t,e,a){return a.match(/b\.?c\.?/i)&&(e="-"+e),e}))).replace(/c$/,""));var e=Number(t);return isNaN(t)?(console.warn("Spacetime: Invalid century input"),this):(0===e&&(e=1),e=e>=0?100*(e-1):100*(e+1),this.year(e))}var a=this.startOf("century").year();return(a=Math.floor(a/100))<0?a-1:a+1},millenium:function(t){if(void 0!==t){if("string"==typeof t&&(t=t.replace(/([0-9])(th|rd|st|nd)/,"$1"),t=Number(t),isNaN(t)))return console.warn("Spacetime: Invalid millenium input"),this;t>0&&(t-=1);var e=1e3*t;return 0===e&&(e=1),this.year(e)}var a=Math.floor(this.year()/1e3);return a>=0&&(a+=1),a}},fe=Object.assign({},de,le,me);fe.milliseconds=fe.millisecond,fe.seconds=fe.second,fe.minutes=fe.minute,fe.hours=fe.hour,fe.hour24=fe.hour,fe.h12=fe.hour12,fe.h24=fe.hour24,fe.days=fe.day;var ye=function(t){Object.keys(fe).forEach((function(e){t.prototype[e]=fe[e]}))},pe=O.isLeapYear,ge=function(t,e){return 1===t&&pe(e)?29:nt[t]},ve=function(t,e){if(t.month>0){var a=parseInt(t.month/12,10);t.year=e.year()+a,t.month=t.month%12}else if(t.month<0){var n=Math.floor(Math.abs(t.month)/13,10);n=Math.abs(n)+1,t.year=e.year()-n,t.month=t.month%12,t.month=t.month+12,12===t.month&&(t.month=0)}return t},be=function(t,e,a){for(var n=e.year(),r=e.month(),o=ge(r,n);a>o;)a-=o,(r+=1)>=12&&(r-=12,n+=1),o=ge(r,n);return t.month=r,t.date=a,t},we=function(t,e,a){t.year=e.year(),t.month=e.month();var n=e.date();for(t.date=n-Math.abs(a);t.date<1;){t.month-=1,t.month<0&&(t.month=11,t.year-=1);var r=ge(t.month,t.year);t.date+=r}return t},ke=["millisecond","second","minute","hour","date","month"],De={second:ke.slice(0,1),minute:ke.slice(0,2),quarterhour:ke.slice(0,2),hour:ke.slice(0,3),date:ke.slice(0,4),month:ke.slice(0,4),quarter:ke.slice(0,4),season:ke.slice(0,4),year:ke,decade:ke,century:ke};De.week=De.hour,De.season=De.date,De.quarter=De.date;var ze={year:!0,quarter:!0,season:!0,month:!0,week:!0,day:!0},Oe={month:!0,quarter:!0,season:!0,year:!0},_e=function(t){t.prototype.add=function(t,e){var a=this.clone();if(!e||0===t)return a;var n=this.clone();e=O.normalize(e),J[e]?a.epoch+=J[e]*t:"week"===e?a.epoch+=J.day*(7*t):"quarter"===e||"season"===e||"season"===e?a.epoch+=J.month*(4*t):"quarterhour"===e&&(a.epoch+=15*J.minute*t);var r={};if(De[e]&&De[e].forEach((function(t){r[t]=n[t]()})),ze[e]){var o=n.timezone().current.offset-a.timezone().current.offset;a.epoch+=3600*o*1e3}if("month"===e&&(r.month=n.month()+t,r=ve(r,n)),"week"===e){var i=n.date()+7*t;i<=28&&i>1&&(r.date=i)}else if("date"===e){if(t<0)r=we(r,n,t);else{var u=n.date()+t;r=be(r,n,u)}0!==t&&n.isSame(a,"day")&&(r.date=n.date()+t)}else"year"===e&&a.year()===n.year()?a.epoch+=J.week:"decade"===e?r.year=a.year()+10:"century"===e&&(r.year=a.year()+100);if(Oe[e]){var s=nt[r.month];r.date=n.date(),r.date>s&&(r.date=s)}return G(a,r),a},t.prototype.subtract=function(t,e){return this.clone().add(-1*t,e)},t.prototype.minus=t.prototype.subtract,t.prototype.plus=t.prototype.add},xe={millisecond:function(t){return t.epoch},second:function(t){return[t.year(),t.month(),t.date(),t.hour(),t.minute(),t.second()].join("-")},minute:function(t){return[t.year(),t.month(),t.date(),t.hour(),t.minute()].join("-")},hour:function(t){return[t.year(),t.month(),t.date(),t.hour()].join("-")},day:function(t){return[t.year(),t.month(),t.date()].join("-")},week:function(t){return[t.year(),t.week()].join("-")},month:function(t){return[t.year(),t.month()].join("-")},quarter:function(t){return[t.year(),t.quarter()].join("-")},year:function(t){return t.year()}};xe.date=xe.day;var je=function(t){t.prototype.isSame=function(e,a){return a?("string"!=typeof e&&"number"!=typeof e||(e=new t(e,this.timezone.name)),a=a.replace(/s$/,""),xe[a]?xe[a](this)===xe[a](e):null):null}},Me=function(t){var e={isAfter:function(t){t=O.beADate(t,this);var e=O.getEpoch(t);return null===e?null:this.epoch>e},isBefore:function(t){t=O.beADate(t,this);var e=O.getEpoch(t);return null===e?null:this.epoch2&&void 0!==arguments[2]&&arguments[2];t=O.beADate(t,this),e=O.beADate(e,this);var n=O.getEpoch(t);if(null===n)return null;var r=O.getEpoch(e);return null===r?null:a?this.isBetween(t,e)||this.isEqual(t)||this.isEqual(e):n2&&void 0!==arguments[2]?arguments[2]:{};this.epoch=null,this.tz=B(e,qe),this.silent=a.silent||!0,this.british=a.dmy||a.british,this._weekStart=1,void 0!==a.weekStart&&(this._weekStart=a.weekStart),this._today={},void 0!==a.today&&(this._today=a.today),Object.defineProperty(this,"d",{get:function(){var t=j(this),e=(new Date(this.epoch).getTimezoneOffset()||0)+60*t;e=60*e*1e3;var a=this.epoch+e;return new Date(a)}}),Object.defineProperty(this,"timezones",{get:function(){return qe},set:function(t){return qe=t,t}});var n=ft(this,t,e);this.epoch=n.epoch};Object.keys(Rt).forEach((function(t){Pe.prototype[t]=Rt[t]})),Pe.prototype.clone=function(){return new Pe(this.epoch,this.tz,{silent:this.silent,weekStart:this._weekStart,today:this._today})},Pe.prototype.toLocalDate=function(){return new Date(this.epoch)},ye(Pe),_e(Pe),je(Pe),Me(Pe),Te(Pe);var Ce=Pe,Se=function(t,e){var a=new Ce(null),n=new Ce(null);a=a.time(t),n=e?n.time(e):a.add(59,"minutes");var r=a.hour(),o=n.hour();return Object.keys(a.timezones).filter((function(t){if(-1===t.indexOf("/"))return!1;var e=new Ce(null,t),i=e.hour();return i>=r&&i<=o&&(!(i===r&&e.minute()n.minute()))}))},Ve=function(t,e,a){return new Ce(t,e,a)},Ee=function(t){var e=t._today||{};return Object.keys(e).forEach((function(a){t=t[a](e[a])})),t};Ve.now=function(t,e){var a=new Ce((new Date).getTime(),t,e);return a=Ee(a)},Ve.today=function(t,e){var a=new Ce((new Date).getTime(),t,e);return(a=Ee(a)).startOf("day")},Ve.tomorrow=function(t,e){var a=new Ce((new Date).getTime(),t,e);return(a=Ee(a)).add(1,"day").startOf("day")},Ve.yesterday=function(t,e){var a=new Ce((new Date).getTime(),t,e);return(a=Ee(a)).subtract(1,"day").startOf("day")},Ve.extend=function(t){return Object.keys(t).forEach((function(e){Ce.prototype[e]=t[e]})),this},Ve.whereIts=Se,Ve.version="6.6.3",Ve.plugin=Ve.extend;var Ae=Ve;"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self&&self;var Ne=function(t){return t&&t.default||t}(Object.freeze({__proto__:null,default:Ae})),Le="America/",Ye="Asia/",Ie="Europe/",He="Africa/",$e="Australia/",Be="Pacific/",Fe={"british summer time":Ie+"London",bst:Ie+"London","british time":Ie+"London","britain time":Ie+"London","irish summer time":Ie+"Dublin","irish time":Ie+"Dublin",ireland:Ie+"Dublin","central european time":Ie+"Berlin",cet:Ie+"Berlin","central european summer time":Ie+"Berlin",cest:Ie+"Berlin","central europe":Ie+"Berlin","eastern european time":Ie+"Riga",eet:Ie+"Riga","eastern european summer time":Ie+"Riga",eest:Ie+"Riga","eastern europe time":Ie+"Riga","western european time":Ie+"Lisbon","western european summer time":Ie+"Lisbon","western europe":Ie+"Lisbon","turkey standard time":Ie+"Istanbul",trt:Ie+"Istanbul","turkish time":Ie+"Istanbul",etc:He+"Freetown",utc:He+"Freetown","greenwich standard time":He+"Freetown",gmt:He+"Freetown","east africa time":He+"Nairobi","east african time":He+"Nairobi","eastern africa time":He+"Nairobi","central africa time":He+"Khartoum","central african time":He+"Khartoum","south africa standard time":He+"Johannesburg",sast:He+"Johannesburg","southern africa":He+"Johannesburg","south african":He+"Johannesburg","west africa standard time":He+"Lagos","western africa time":He+"Lagos","west african time":He+"Lagos","australian central standard time":$e+"Adelaide",acst:$e+"Adelaide","australian central daylight time":$e+"Adelaide",acdt:$e+"Adelaide","australia central":$e+"Adelaide","australian eastern standard time":$e+"Brisbane",aest:$e+"Brisbane","australian eastern daylight time":$e+"Brisbane",aedt:$e+"Brisbane","australia east":$e+"Brisbane","australian western standard time":$e+"Perth",awst:$e+"Perth","australian western daylight time":$e+"Perth",awdt:$e+"Perth","australia west":$e+"Perth","australian central western standard time":$e+"Eucla",acwst:$e+"Eucla","australia central west":$e+"Eucla","lord howe standard time":$e+"Lord_Howe",lhst:$e+"Lord_Howe","lord howe daylight time":$e+"Lord_Howe",lhdt:$e+"Lord_Howe","russian standard time":Ie+"Moscow",msk:Ie+"Moscow",russian:Ie+"Moscow","central standard time":Le+"Chicago","central time":Le+"Chicago",cst:Le+"Havana","central daylight time":Le+"Chicago",cdt:Le+"Havana","mountain standard time":Le+"Denver","mountain time":Le+"Denver",mst:Le+"Denver","mountain daylight time":Le+"Denver",mdt:Le+"Denver","atlantic standard time":Le+"Halifax","atlantic time":Le+"Halifax",ast:Ye+"Baghdad","atlantic daylight time":Le+"Halifax",adt:Le+"Halifax","eastern standard time":Le+"New_York","eastern time":Le+"New_York",est:Le+"New_York","eastern daylight time":Le+"New_York",edt:Le+"New_York","pacific time":Le+"Los_Angeles","pacific standard time":Le+"Los_Angeles",pst:Le+"Los_Angeles","pacific daylight time":Le+"Los_Angeles",pdt:Le+"Los_Angeles","alaskan standard time":Le+"Anchorage","alaskan time":Le+"Anchorage",ahst:Le+"Anchorage","alaskan daylight time":Le+"Anchorage",ahdt:Le+"Anchorage","hawaiian standard time":Be+"Honolulu","hawaiian time":Be+"Honolulu",hst:Be+"Honolulu","aleutian time":Be+"Honolulu","hawaii time":Be+"Honolulu","newfoundland standard time":Le+"St_Johns","newfoundland time":Le+"St_Johns",nst:Le+"St_Johns","newfoundland daylight time":Le+"St_Johns",ndt:Le+"St_Johns","brazil time":Le+"Sao_Paulo",brt:Le+"Sao_Paulo","brasília":Le+"Sao_Paulo",brasilia:Le+"Sao_Paulo","brazilian time":Le+"Sao_Paulo","argentina time":Le+"Buenos_Aires","argentinian time":Le+"Buenos_Aires","amazon time":Le+"Manaus",amt:Le+"Manaus","amazonian time":Le+"Manaus","easter island standard time":"Chile/Easterisland",east:"Chile/Easterisland","easter island summer time":"Chile/Easterisland",easst:"Chile/Easterisland","venezuelan standard time":Le+"Caracas","venezuelan time":Le+"Caracas",vet:Le+"Caracas","venezuela time":Le+"Caracas","paraguay time":Le+"Asuncion",pyt:Le+"Asuncion","paraguay summer time":Le+"Asuncion",pyst:Le+"Asuncion","cuba standard time":Le+"Havana","cuba time":Le+"Havana","cuba daylight time":Le+"Havana","cuban time":Le+"Havana","bolivia time":Le+"La_Paz","bolivian time":Le+"La_Paz","colombia time":Le+"Bogota",cot:Le+"Bogota","colombian time":Le+"Bogota","acre time":Le+"Eirunepe","peru time":Le+"Lima","chile standard time":Le+"Punta_Arenas","chile time":Le+"Punta_Arenas",clst:Le+"Punta_Arenas","chile summer time":Le+"Punta_Arenas",cldt:Le+"Punta_Arenas","uruguay time":Le+"Montevideo",uyt:Le+"Montevideo",ist:Ye+"Jerusalem","arabic standard time":Ye+"Baghdad","arabic time":Ye+"Baghdad","arab time":Ye+"Baghdad","iran standard time":Ye+"Tehran","iran time":Ye+"Tehran",irst:Ye+"Tehran","iran daylight time":Ye+"Tehran",irdt:Ye+"Tehran",iranian:Ye+"Tehran","pakistan standard time":Ye+"Karachi","pakistan time":Ye+"Karachi",pkt:Ye+"Karachi","india standard time":Ye+"Kolkata","indian time":Ye+"Kolkata","indochina time":Ye+"Bangkok",ict:Ye+"Bangkok","south east asia":Ye+"Bangkok","china standard time":Ye+"Shanghai",ct:Ye+"Shanghai","chinese time":Ye+"Shanghai","alma-ata time":Ye+"Almaty",almt:Ye+"Almaty","oral time":Ye+"Oral","orat time":Ye+"Oral","yakutsk time":Ye+"Yakutsk",yakt:Ye+"Yakutsk","gulf standard time":Ye+"Dubai","gulf time":Ye+"Dubai",gst:Ye+"Dubai",uae:Ye+"Dubai","hong kong time":Ye+"Hong_Kong",hkt:Ye+"Hong_Kong","western indonesian time":Ye+"Jakarta",wib:Ye+"Jakarta","indonesia time":Ye+"Jakarta","central indonesian time":Ye+"Makassar",wita:Ye+"Makassar","israel daylight time":Ye+"Jerusalem",idt:Ye+"Jerusalem","israel standard time":Ye+"Jerusalem","israel time":Ye+"Jerusalem",israeli:Ye+"Jerusalem","krasnoyarsk time":Ye+"Krasnoyarsk",krat:Ye+"Krasnoyarsk","malaysia time":Ye+"Kuala_Lumpur",myt:Ye+"Kuala_Lumpur","singapore time":Ye+"Singapore",sgt:Ye+"Singapore","korea standard time":Ye+"Seoul","korea time":Ye+"Seoul",kst:Ye+"Seoul","korean time":Ye+"Seoul","uzbekistan time":Ye+"Samarkand",uzt:Ye+"Samarkand","vladivostok time":Ye+"Vladivostok",vlat:Ye+"Vladivostok","maldives time":"Indian/Maldives",mvt:"Indian/Maldives","mauritius time":"Indian/Mauritius",mut:"Indian/Mauritius","marshall islands time":Be+"Kwajalein",mht:Be+"Kwajalein","samoa standard time":Be+"Midway",sst:Be+"Midway","somoan time":Be+"Midway","chamorro standard time":Be+"Guam",chst:Be+"Guam","papua new guinea time":Be+"Bougainville",pgt:Be+"Bougainville"},Je=Ne().timezones,Qe=Object.keys(Je).reduce((function(t,e){return t[e]=e,t}),{}),Ke=Object.assign({},Fe,Qe),Ge={};[[["weekday","summer","winter","autumn","some day","one day","all day","some point","eod","eom","standard time","daylight time"],"#Date"],[["centuries","century","day","days","decade","decades","hour","hours","millisecond","milliseconds","minute","minutes","month","months","seconds","week","weeks","year","years"],"#Duration"],[["all hallows eve","all saints day","all sts day","april fools","armistice day","australia day","bastille day","boxing day","canada day","christmas eve","christmas","cinco de mayo","day of the dead","dia de muertos","dieciseis de septiembre","emancipation day","grito de dolores","groundhog day","halloween","harvey milk day","inauguration day","independence day","independents day","juneteenth","labour day","national freedom day","national nurses day","new years eve","new years","purple heart day","rememberance day","rosa parks day","saint andrews day","saint patricks day","saint stephens day","saint valentines day","st andrews day","st patricks day","st stephens day","st valentines day ","valentines day","valentines","veterans day","victoria day","womens equality day","xmas","epiphany","orthodox christmas day","orthodox new year","assumption of mary","all souls day","feast of the immaculate conception","feast of our lady of guadalupe","kwanzaa","imbolc","beltaine","lughnassadh","samhain","martin luther king day","mlk day","presidents day","mardi gras","tax day","commonwealth day","mothers day","memorial day","fathers day","columbus day","indigenous peoples day","canadian thanksgiving","election day","thanksgiving","t-day","turkey day","black friday","cyber monday","ash wednesday","palm sunday","maundy thursday","good friday","holy saturday","easter","easter sunday","easter monday","orthodox good friday","orthodox holy saturday","orthodox easter","orthodox easter monday","ascension day","pentecost","whitsunday","whit sunday","whit monday","trinity sunday","corpus christi","advent","tu bishvat","tu bshevat","purim","passover","yom hashoah","lag baomer","shavuot","tisha bav","rosh hashana","yom kippur","sukkot","shmini atzeret","simchat torah","chanukah","hanukkah","isra and miraj","lailat al-qadr","eid al-fitr","id al-Fitr","eid ul-Fitr","ramadan","eid al-adha","muharram","the prophets birthday","ostara","march equinox","vernal equinox","litha","june solistice","summer solistice","mabon","september equinox","fall equinox","autumnal equinox","yule","december solstice","winter solstice","chinese new year","diwali"],"#Holiday"],[["noon","midnight","now","morning","tonight","evening","afternoon","night","breakfast time","lunchtime","dinnertime","sometime","eod","oclock","oclock","all day","at night"],"#Time"],[Object.keys(Ke),"#Timezone"]].forEach((function(t){for(var e=0;e-13&&t<13?"Etc/GMT"+(t=((t*=-1)>0?"+":"")+t):null},ua=function(t){var e=t.match("#Timezone+"),a=(e=e.remove("(in|for|by|near|at)")).text("reduced");if(t.remove("#Timezone+"),Ke.hasOwnProperty(a))return Ke[a];var n=function(t){var e=t.match(aa);if(null!==e)return ia(e[1]);if(null!==(e=t.match(ra)))return ia(e[1]);if(null!==(e=t.match(oa))){var a=-1*Number(e[1]);return ia(a)}return null!==(e=t.match(na))?ia(e[1]):null}(a);return n||null},sa=function(){function t(a,n,r){e(this,t),this.unit=n||"day";var o={};(r=r||{}).today&&(o={date:r.today.date(),month:r.today.month(),year:r.today.year()});var i=Ne(a,r.timezone,{today:o});i.isValid()&&(i=i.startOf(this.unit)),Object.defineProperty(this,"d",{enumerable:!1,writable:!0,value:i}),Object.defineProperty(this,"context",{enumerable:!1,writable:!0,value:r})}return n(t,[{key:"clone",value:function(){return new t(this.d,this.unit,this.context)}},{key:"log",value:function(){return console.log("--"),this.d.log(),console.log("\n"),this}},{key:"applyShift",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return Object.keys(e).forEach((function(a){t.d=t.d.add(e[a],a)})),this}},{key:"applyTime",value:function(t){return this.d=t?this.d.time(t):this.d.startOf("day"),this}},{key:"format",value:function(t){return this.d.format(t)}},{key:"start",value:function(){return this.d=this.d.startOf(this.unit),this}},{key:"end",value:function(){return this.d=this.d.endOf(this.unit),this}},{key:"before",value:function(){return this.d=Ne.now(this.context.timezone,{today:this.context.today}),this}},{key:"after",value:function(){return this.d=this.d.add(1,this.unit),this.d=this.d.startOf(this.unit),this}},{key:"next",value:function(){return this.d=this.d.add(1,this.unit),this.d=this.d.startOf(this.unit),this}},{key:"last",value:function(){return this.d=this.d.minus(1,this.unit),this.d=this.d.startOf(this.unit),this}}]),t}(),ca={Unit:sa,Day:function(t){r(n,t);var a=s(n);function n(t,r,o){var i;return e(this,n),(i=a.call(this,t,r,o)).unit="day",i}return n}(sa),Month:function(t){r(n,t);var a=s(n);function n(t,r,o){var i;return e(this,n),(i=a.call(this,t,r,o)).unit="month",i}return n}(sa),Quarter:function(t){r(n,t);var a=s(n);function n(t,r,o){var i;return e(this,n),(i=a.call(this,t,r,o)).unit="quarter",i}return n}(sa),Year:function(t){r(n,t);var a=s(n);function n(t,r,o){var i;return e(this,n),(i=a.call(this,t,r,o)).unit="year",i}return n}(sa),WeekDay:function(t){r(o,t);var a=s(o);function o(t,n,r){var i;return e(this,o),(i=a.call(this,t,n,r)).unit="week",i.d=Ne(r.today,r.timezone),i.d=i.d.day(t),i.weekDay=i.d.dayName(),i.d.date()0&&(n=new da(e.today,null,e))),n},ha={week:ca.Week,month:ca.Month,quarter:ca.Quarter,year:ca.Year,season:ca.Season},ma=function(t,e){var a=t.match("(weekday|week|month|quarter|season|year)");if(!0===a.found){var n=a.lastTerm().text("reduced");if(ha.hasOwnProperty(n)){var r=ha[n];return r?new r(null,n,e):null}}if(!0===(a=t.match("(monday|tuesday|wednesday|thursday|friday|saturday|sunday)")).found){var o=a.lastTerm().text("reduced");return new ca.WeekDay(o,null,e)}return null},fa=function(t,e,a){return t(a={path:e,exports:{},require:function(t,e){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}(null==e&&a.path)}},a.exports),a.exports}((function(t,e){t.exports=function(t){t=t&&t.hasOwnProperty("default")?t.default:t;var e="january",a="february",n="april",r="may",o="july",i="august",u="september",s="october",c="november",d="december",l={"new years eve":[d,31],"new years":[e,1],"new years day":[e,1],"inauguration day":[e,20],"australia day":[e,26],"national freedom day":[a,1],"groundhog day":[a,2],"rosa parks day":[a,4],"valentines day":[a,14],"saint valentines day":[a,14],"st valentines day ":[a,14],"saint patricks day":["march",17],"st patricks day":["march",17],"april fools":[n,1],"april fools day":[n,1],"emancipation day":[n,16],"tax day":[n,15],"labour day":[r,1],"cinco de mayo":[r,5],"national nurses day":[r,6],"harvey milk day":[r,22],"victoria day":[r,24],juneteenth:["june",19],"canada day":[o,1],"independence day":[o,4],"independents day":[o,4],"bastille day":[o,14],"purple heart day":[i,7],"womens equality day":[i,26],"16 de septiembre":[u,16],"dieciseis de septiembre":[u,16],"grito de dolores":[u,16],halloween:[s,31],"all hallows eve":[s,31],"day of the dead":[s,31],"dia de muertos":[s,31],"veterans day":[c,11],"st andrews day":[c,30],"saint andrews day":[c,30],"all saints day":[c,1],"all sts day":[c,1],"armistice day":[c,11],"rememberance day":[c,11],"christmas eve":[d,24],christmas:[d,25],xmas:[d,25],"boxing day":[d,26],"st stephens day":[d,26],"saint stephens day":[d,26],epiphany:[e,6],"orthodox christmas day":[e,7],"orthodox new year":[e,14],"assumption of mary":[i,15],"all souls day":[c,2],"feast of the immaculate conception":[d,8],"feast of our lady of guadalupe":[d,12],kwanzaa:[d,26],imbolc:[a,2],beltaine:[r,1],lughnassadh:[i,1],samhain:[s,31]},h=function(e,a,n){if(l.hasOwnProperty(e)||l.hasOwnProperty(a)){var r=l[e]||l[a]||[],o=t.now();if((o=(o=(o=(o=o.year(n)).startOf("year")).month(r[0])).date(r[1])).isValid())return o}return null},m="monday",f={"martin luther king day":[3,m,"january"],"presidents day":[3,m,"february"],"commonwealth day":[2,m,"march"],"mothers day":[2,"sunday","may"],"fathers day":[3,"sunday","june"],"labor day":[1,m,"september"],"columbus day":[2,m,"october"],"canadian thanksgiving":[2,m,"october"],thanksgiving:[4,"thursday","november"],"black friday":[4,"friday","november"]};f["turday day"]=f.thanksgiving,f["indigenous peoples day"]=f["columbus day"],f["mlk day"]=f["martin luther king day"];var y=f,p=function(e,a,n){if(y.hasOwnProperty(e)||y.hasOwnProperty(a)){var r=y[e]||y[a]||[],o=t.now(),i=(o=(o=(o=o.year(n)).month(r[2])).startOf("month")).month();if((o=o.day(r[1])).month()!==i&&(o=o.add(1,"week")),r[0]>1&&(o=o.add(r[0]-1,"week")),o.isValid())return o}return null},g={easter:0,"ash wednesday":-46,"palm sunday":7,"maundy thursday":-3,"good friday":-2,"holy saturday":-1,"easter saturday":-1,"easter monday":1,"ascension day":39,"whit sunday":49,"whit monday":50,"trinity sunday":65,"corpus christi":60,"mardi gras":-47};g["easter sunday"]=g.easter,g.pentecost=g["whit sunday"],g.whitsun=g["whit sunday"];var v=g,b=function(t){var e=Math.floor,a=t%19,n=e(t/100),r=(n-e(n/4)-e((8*n+13)/25)+19*a+15)%30,o=r-e(r/28)*(1-e(29/(r+1))*e((21-a)/11)),i=o-(t+e(t/4)+o+2-n+e(n/4))%7,u=3+e((i+40)/44),s=i+28-31*e(u/4);return(u=4===u?"April":"March")+" "+s},w=function(e,a,n){if(v.hasOwnProperty(e)||v.hasOwnProperty(a)){var r=v[e]||v[a]||[],o=b(n);if(!o)return null;var i=t(o),u=(i=i.year(n)).add(r,"day");if(u.isValid())return u}return null},k={spring:[2003,2007,2044,2048,2052,2056,2060,2064,2068,2072,2076,2077,2080,2081,2084,2085,2088,2089,2092,2093,2096,2097],summer:[2021,2016,2020,2024,2028,2032,2036,2040,2041,2044,2045,2048,2049,2052,2053,2056,2057,2060,2061,2064,2065,2068,2069,2070,2072,2073,2074,2076,2077,2078,2080,2081,2082,2084,2085,2086,2088,2089,2090,2092,2093,2094,2096,2097,2098,2099],fall:[2002,2003,2004,2006,2007,2010,2011,2014,2015,2018,2019,2022,2023,2026,2027,2031,2035,2039,2043,2047,2051,2055,2059,2092,2096],winter:[2002,2003,2006,2007,2011,2015,2019,2023,2027,2031,2035,2039,2043,2080,2084,2088,2092,2096]},D=[2080,2084,2088,2092,2096],z=function(t){var e={spring:"March 20 "+t,summer:"June 21 "+t,fall:"Sept 22 "+t,winter:"Dec 21 "+t};return-1!==k.spring.indexOf(t)&&(e.spring="March 19 "+t),-1!==k.summer.indexOf(t)&&(e.summer="June 20 "+t),-1!==k.fall.indexOf(t)&&(e.fall="Sept 21 "+t),-1!==k.winter.indexOf(t)&&(e.winter="Dec 22 "+t),-1!==D.indexOf(t)&&(e.winter="Dec 20 "+t),e},O={"spring equinox":"spring","summer solistice":"summer","fall equinox":"fall","winter solstice":"winter"};O["march equinox"]=O["spring equinox"],O["vernal equinox"]=O["spring equinox"],O.ostara=O["spring equinox"],O["june solstice"]=O["summer solistice"],O.litha=O["summer solistice"],O["autumn equinox"]=O["fall equinox"],O["autumnal equinox"]=O["fall equinox"],O["september equinox"]=O["fall equinox"],O["sept equinox"]=O["fall equinox"],O.mabon=O["fall equinox"],O["december solstice"]=O["winter solistice"],O["dec solstice"]=O["winter solistice"],O.yule=O["winter solistice"];var _=O,x=function(e,a,n){if(_.hasOwnProperty(e)||_.hasOwnProperty(a)){var r=_[e]||_[a],o=z(n);if(!r||!o||!o[r])return null;var i=t(o[r]);if(i.isValid())return i}return null},j={"isra and miraj":"april 13","lailat al-qadr":"june 10","eid al-fitr":"june 15","id al-Fitr":"june 15","eid ul-Fitr":"june 15",ramadan:"may 16","eid al-adha":"sep 22",muharram:"sep 12","prophets birthday":"nov 21"},M=function(e,a,n){if(j.hasOwnProperty(e)||j.hasOwnProperty(a)){var r=j[e]||j[a]||[];if(!r)return null;var o=t(r+" 2018"),i=-10.64*(n-2018);if((o=(o=(o=o.add(i,"day")).startOf("day")).year(n)).isValid())return o}return null},T=t.now().year();return function(t,e){e=e||T,t=t||"";var a=(t=(t=(t=String(t)).trim().toLowerCase()).replace(/'s/,"s")).replace(/ day$/,"");a=(a=a.replace(/^the /,"")).replace(/^orthodox /,"");var n=h(t,a,e);return null!==n||null!==(n=p(t,a,e))||null!==(n=w(t,a,e))||null!==(n=x(t,a,e))||null!==(n=M(t,a,e))?n:null}}(Ne)})),ya=ca.CalendarDate,pa=function(t,e){var a=null,n=t.match("#Holiday+").text("reduced"),r=fa(n,2020);return null!==r&&(a=new ya(r,null,e)),a},ga=ca.Unit,va=ca.Day,ba=ca.CalendarDate,wa=ca.Month,ka={today:function(t){return new va(t.today,null,t)},yesterday:function(t){return new va(t.today.minus(1,"day"),null,t)},tomorrow:function(t){return new va(t.today.plus(1,"day"),null,t)}},Da={shift:Ue,time:ta,relative:ea,timezone:ua},za={implied:la,duration:ma,holiday:pa,explicit:function(t,e){var a=e.today.year(),n=t.match("[#Value] of? [#Month] [#Year]");if(n.found||(n=t.match("[#Month] the? [#Value] [#Year]")),n.found){var r={month:n.groups("month").text(),date:n.groups("date").text(),year:n.groups("year").text()||a},o=new ba(r,null,e);if(!0===o.d.isValid())return o}if((n=t.match("[#Month] of? [#Year]")).found){var i={month:n.groups("month").text(),year:n.groups("year").text()||a},u=new wa(i,null,e);if(!0===u.d.isValid())return u}if((n=t.match("[#Value] of? [#Month]")).found||(n=t.match("[#Month] the? [#Value]")),n.found){var s={month:n.groups("month").text(),date:n.groups("date").text(),year:e.today.year()},c=new ba(s,null,e);if(!0===c.d.isValid())return c}if(t.has("#Month")){var d={month:t.match("#Month").text(),date:1,year:e.today.year()},l=new ba(d,null,e);if(!0===l.d.isValid())return l}if((n=t.match("the [#Value]")).found){var h={month:e.today.month(),date:n.groups("date").text(),year:e.today.year()},m=new ba(h,null,e);if(!0===m.d.isValid())return m}var f=t.text("reduced");if(!0===ka.hasOwnProperty(f))return ka[f](e);var y=new ga(f,null,e);return!1===y.d.isValid()?null:y}},Oa=function(e,a){var n=Da.shift(e),r=Da.timezone(e),o=Da.time(e,a),i=Da.relative(e);if(r){var u=(a=Object.assign({},a,{timezone:r})).today.format("iso-short");a.today=a.today.goto(a.timezone).set(u)}var s=null;return s=(s=(s=(s=s||za.implied(e,a,{shift:n,time:o,rel:i}))||za.duration(e,a))||za.holiday(e,a))||za.explicit(e,a),void 0!==("undefined"==typeof process?"undefined":t(process))&&process&&process.env.DEBUG&&(console.log("\n\n=-=-=-=-=-=Date-=-=-=-=-=-=-"),console.log(" shift: ".concat(JSON.stringify(n))),console.log(" rel: ".concat(i||"-")),console.log(" time: ".concat(o||"-")),console.log("\n str: '".concat(e.text(),"'")),console.log("\n ",s),console.log("=-=-=-=-=-=-=-=-=-=-=-=-=-=-\n\n")),s?("last"===i&&s.last(),"next"===i&&s.next(),n&&s.applyShift(n),s.applyTime(o),s):null},_a=function(t,e){return t=t.applyShift(e.casual_duration)},xa=function(t,e){var a=t.match("between [*] and [*]");if(a.found){var n=a.groups("start");n=Oa(n,e);var r=a.groups("end");if(r=Oa(r,e),n)return{start:n,end:r}}if((a=t.match("[#Month #Value] to [#Month #Value] [#Year?]")).found){var o=a.groups(),i=o.from;if(o.year&&(i=i.concat(o.year)),i=Oa(i,e)){var u=o.to;return o.year&&(u=u.concat(o.year)),{start:i,end:u=Oa(u,e)}}}if((a=t.match("[#Month] [#Value] to [#Value] of? [#Year]")).found){var s=a.groups(),c=s.month.concat(s.from,s.year);if(c=Oa(c,e)){var d=s.month.concat(s.to,s.year);return{start:c,end:d=Oa(d,e)}}}if((a=t.match("[#Value] to [#Value of? #Month of? #Year]")).found){var l=a.groups("to");if(l=Oa(l,e)){var h=a.groups("to"),m=l.clone();return m.d=m.d.date(h.text("normal")),{start:m,end:l}}}if((a=t.match("[#Value] to [#Value of? #Month]")).found){var f=a.groups("to");if(f=Oa(f,e)){var y=a.groups("from"),p=f.clone();return p.d=p.d.date(y.text("normal")),{start:p,end:f}}}if((a=t.match("[#Month #Value] to [#Value]")).found){var g=a.groups("from");if(g=Oa(g,e)){var v=a.groups("to"),b=g.clone();return b.d=b.d.date(v.text("normal")),{start:g,end:b}}}if((a=t.match("from? [*] (to|@hasHyphen|until|upto) [*]")).found){var w=a.groups("from"),k=a.groups("to");if(w=Oa(w,e),k=Oa(k,e),w&&k)return{start:w,end:k}}if((a=t.match("^due (by|before|on|in)? [*]",0)).found){var D=Oa(a,e);if(D)return{start:new sa(e.today,null,e),end:_a(D.clone(),e)}}if((a=t.match("^(after|following|from) [*]",0)).found){var z=Oa(a,e);if(z)return{start:z,end:_a(z.clone(),e)}}if((a=t.match("^(on|during|in) [*]",0)).found){var O=Oa(a,e);if(O)return{start:O,end:O.clone().end()}}var _=Oa(t,e);return{start:_,end:_.clone().end()}},ja=function(t,e){return(e=e||{}).timezone=e.timezone||"ETC/UTC",e.today=Ne(e.today||null,e.timezone),t=Re(t),xa(t,e)},Ma=[["mon","monday"],["tue","tuesday"],["tues","tuesday"],["wed","wednesday"],["thu","thursday"],["thurs","thursday"],["fri","friday"],["sat","saturday"],["sun","sunday"],["jan","january"],["feb","february"],["mar","march"],["apr","april"],["jun","june"],["jul","july"],["aug","august"],["sep","september"],["sept","september"],["oct","october"],["nov","november"],["dec","december"]],Ta=Ma=Ma.map((function(t){return{short:t[0],long:t[1]}})),qa={json:function(t){var e=this,a=null;"number"==typeof t&&(a=t,t=null);var n=[],r=(t=t||{terms:!1}).format||"iso";return this.forEach((function(a){var o=a.json(t)[0],i=ja(a,e.context),u=i.start?i.start.format(r):null,s=i.end?i.end.format(r):null;o.date={start:u,end:s},u&&s&&(o.date.duration=i.start.d.diff(i.end.d),delete o.date.duration.milliseconds,delete o.date.duration.seconds),n.push(o)})),null!==a?n[a]:n},format:function(t){var e=this;return this.forEach((function(a){var n=ja(a,e.context),r="";if(n.start){if(r=n.start.format(t),n.end){var o=n.start.format(t);r!==o&&(r+=" to "+o)}a.replaceWith(r,{keepTags:!0,keepCase:!1})}})),this},toLongForm:function(){var t=this;return Ta.forEach((function(e){t.replace(e.short,e.long,!0)})),this},toShortForm:function(){var t=this;return Ta.forEach((function(e){t.replace(e.long,e.short,!0)})),this}};return function(a,n){n.addTags(D),n.addWords(Ze),n.postProcess(k);var o=function(t){r(n,t);var a=s(n);function n(t,r,o){var i;return e(this,n),(i=a.call(this,t,r,o)).context={casual_duration:{weeks:2}},i}return n}(a);Object.assign(o.prototype,qa),a.prototype.dates=function(e){var a={};e&&"object"===t(e)&&(a=e,e=null);var n=this.clauses().match("#Date+");"number"==typeof e&&(n=n.get(e)),"number"==typeof e&&(n=n.get(e));var r=new o(n.list,this,this.world);return a.today&&(a.today=Ne(a.today,a.timezone)),r.context=a,r}}})); diff --git a/plugins/dates/builds/compromise-dates.mjs b/plugins/dates/builds/compromise-dates.mjs index 761ba0754..624c810fa 100644 --- a/plugins/dates/builds/compromise-dates.mjs +++ b/plugins/dates/builds/compromise-dates.mjs @@ -1,4 +1,4 @@ -/* compromise-dates 1.0.0 MIT */ +/* compromise-dates 1.1.0 MIT */ function _typeof(obj) { "@babel/helpers - typeof"; @@ -291,6 +291,9 @@ var _00Basic = fixDates; var here = 'date-values'; // var values = function values(doc) { + // a year ago + doc.match('!once [a] #Duration', 0).replaceWith('1').tag('Cardinal', here); + if (doc.has('#Value')) { //june 5 to 7th doc.match('#Month #Value to #Value of? #Year?').tag('Date', here); //5 to 7th june @@ -408,8 +411,8 @@ var here$4 = 'shift-tagger'; // var shiftTagger = function shiftTagger(doc) { if (doc.has('#Date')) { - //two weeks before - doc.match('#Cardinal #Duration (before|after)').tag('#DateShift', here$4); // in two weeks + //'two days before'/ 'nine weeks frow now' + doc.match('#Cardinal #Duration (before|after|ago|from)').tag('#DateShift', here$4); // in two weeks doc.match('in #Cardinal #Duration').tag('#DateShift', here$4); //two weeks and three days before @@ -551,7 +554,7 @@ var _tags = { } }; -/* spencermountain/spacetime 6.6.0 Apache 2.0 */ +/* spencermountain/spacetime 6.6.3 Apache 2.0 */ function createCommonjsModule(fn, module) { return module = { exports: {} @@ -1092,12 +1095,20 @@ var walk = function walk(s, n, fn, unit, previous) { var diff = n - current; s.epoch += milliseconds[unit] * diff; //DST edge-case: if we are going many days, be a little conservative + // console.log(unit, diff) - if (unit === 'day' && Math.abs(diff) > 28) { + if (unit === 'day') { + // s.epoch -= ms.minute //but don't push it over a month - if (n < 28) { + if (Math.abs(diff) > 28 && n < 28) { s.epoch += milliseconds.hour; } + } // 1st time: oops, did we change previous unit? revert it. + + + if (previous !== null && startUnit !== s.d[previous]()) { + // console.warn('spacetime warning: missed setting ' + unit) + s.epoch = original; // s.epoch += ms[unit] * diff * 0.89 // maybe try and make it close...? } //repair it if we've gone too far or something //(go by half-steps, just in case) @@ -1110,14 +1121,12 @@ var walk = function walk(s, n, fn, unit, previous) { while (s.d[fn]() > n) { s.epoch -= halfStep; - } //oops, did we change previous unit? revert it. + } // 2nd time: did we change previous unit? revert it. if (previous !== null && startUnit !== s.d[previous]()) { // console.warn('spacetime warning: missed setting ' + unit) - s.epoch = original; // i mean, but make it close... - - s.epoch += milliseconds[unit] * diff * 0.89; // i guess? + s.epoch = original; } }; //find the desired date by a increment/check while loop @@ -1233,8 +1242,7 @@ var walkTo = function walkTo(s, wants) { } return; - } // console.log(k, n) - + } units[k].walkTo(s, n); } @@ -1698,41 +1706,51 @@ var strFmt = [//iso-this 1998-05-30T22:00:00:000Z, iso-that 2017-04-03T08:00:00- return s; } }]; -var strParse = strFmt; +var strParse = strFmt; // pull in 'today' data for the baseline moment + +var getNow = function getNow(s) { + s.epoch = Date.now(); + Object.keys(s._today || {}).forEach(function (k) { + if (typeof s[k] === 'function') { + s = s[k](s._today[k]); + } + }); + return s; +}; + var dates = { now: function now(s) { - s.epoch = Date.now(); - return s; - }, - tonight: function tonight(s) { - s.epoch = Date.now(); - s = s.hour(18); - return s; + return getNow(s); }, today: function today(s) { - s.epoch = Date.now(); + return getNow(s); + }, + tonight: function tonight(s) { + s = getNow(s); + s = s.hour(18); //6pm + return s; }, tomorrow: function tomorrow(s) { - s.epoch = Date.now(); + s = getNow(s); s = s.add(1, 'day'); s = s.startOf('day'); return s; }, yesterday: function yesterday(s) { - s.epoch = Date.now(); + s = getNow(s); s = s.subtract(1, 'day'); s = s.startOf('day'); return s; }, christmas: function christmas(s) { - var year = new Date().getFullYear(); + var year = getNow(s).year(); s = s.set([year, 11, 25, 18, 0, 0]); // Dec 25 return s; }, 'new years': function newYears(s) { - var year = new Date().getFullYear(); + var year = getNow(s).year(); s = s.set([year, 11, 31, 18, 0, 0]); // Dec 31 return s; @@ -1809,9 +1827,18 @@ var parseInput = function parseInput(s, input, givenTz) { } //set tmp time - s.epoch = Date.now(); + s.epoch = Date.now(); // overwrite tmp time with 'today' value, if exists + + if (s._today && fns.isObject(s._today) && Object.keys(s._today).length > 0) { + var res = handleObject(s, today, defaults); + + if (res.isValid()) { + s.epoch = res.epoch; + } + } // null input means 'now' - if (input === null || input === undefined) { + + if (input === null || input === undefined || input === '') { return s; //k, we're good. } //support input of Date() object @@ -1860,10 +1887,10 @@ var parseInput = function parseInput(s, input, givenTz) { var m = input.match(strParse[i].reg); if (m) { - var res = strParse[i].parse(s, m, givenTz); + var _res = strParse[i].parse(s, m, givenTz); - if (res !== null) { - return res; + if (_res !== null) { + return _res; } } } @@ -2167,7 +2194,7 @@ var printFormat = function printFormat(s) { fmt = fmt.toLowerCase().trim(); if (format.hasOwnProperty(fmt)) { - return String(format[fmt](s) || ''); + return String(format[fmt](s)); } return ''; @@ -3271,6 +3298,8 @@ methods$1.round = methods$1.nearest; methods$1.each = methods$1.every; var methods_1 = methods$1; //these methods wrap around them. +var isLeapYear$1 = fns.isLeapYear; + var validate = function validate(n) { //handle number as a string if (typeof n === 'string') { @@ -3313,7 +3342,14 @@ var set = { var old = s.clone(); var diff = s.minute() - n; var shift = diff * milliseconds.minute; - s.epoch -= shift; + s.epoch -= shift; // check against a screw-up + // if (old.hour() != s.hour()) { + // walkTo(old, { + // minute: n + // }) + // return old.epoch + // } + confirm(s, old, 'second'); return s.epoch; }, @@ -3382,7 +3418,12 @@ var set = { n = validate(n); //avoid setting february 31st if (n > 28) { - var max = monthLengths_1[s.month()]; + var month = s.month(); + var max = monthLengths_1[month]; // support leap day in february + + if (month === 1 && n === 29 && isLeapYear$1(s.year())) { + max = 29; + } if (n > max) { n = max; @@ -4049,10 +4090,10 @@ var addMethods = function addMethods(Space) { }; var query = addMethods; -var isLeapYear$1 = fns.isLeapYear; +var isLeapYear$2 = fns.isLeapYear; var getMonthLength = function getMonthLength(month, year) { - if (month === 1 && isLeapYear$1(year)) { + if (month === 1 && isLeapYear$2(year)) { return 29; } @@ -4083,7 +4124,8 @@ var rollMonth = function rollMonth(want, old) { } return want; -}; +}; // briefly support day=-2 (this does not need to be perfect.) + var rollDaysDown = function rollDaysDown(want, old, sum) { want.year = old.year(); @@ -4540,7 +4582,7 @@ var whereIts = function whereIts(a, b) { }; var whereIts_1 = whereIts; -var _version = '6.6.0'; +var _version = '6.6.3'; var main$1 = function main(input, tz, options) { return new spacetime(input, tz, options); @@ -4884,7 +4926,7 @@ var holidays = ['all hallows eve', 'all saints day', 'all sts day', 'april fools 'isra and miraj', 'lailat al-qadr', 'eid al-fitr', 'id al-Fitr', 'eid ul-Fitr', 'ramadan', 'eid al-adha', 'muharram', 'the prophets birthday', 'ostara', 'march equinox', 'vernal equinox', 'litha', 'june solistice', 'summer solistice', 'mabon', 'september equinox', 'fall equinox', 'autumnal equinox', 'yule', 'december solstice', 'winter solstice', // Additional important holidays 'chinese new year', 'diwali']; -var times = ['noon', 'midnight', 'now', 'morning', 'tonight', 'evening', 'afternoon', 'night', 'breakfast time', 'lunchtime', 'dinnertime', 'ago', 'sometime', 'eod', 'oclock', 'oclock', 'all day', 'at night']; +var times = ['noon', 'midnight', 'now', 'morning', 'tonight', 'evening', 'afternoon', 'night', 'breakfast time', 'lunchtime', 'dinnertime', 'sometime', 'eod', 'oclock', 'oclock', 'all day', 'at night']; var lex = {}; var data$1 = [[dates$1, '#Date'], [durations, '#Duration'], [holidays, '#Holiday'], [times, '#Time'], [Object.keys(_timezones), '#Timezone']]; @@ -4946,9 +4988,9 @@ var parseShift = function parseShift(doc) { result[unit] = num; } } - }); //is it 2 weeks before? → -2 + }); //is it 2 weeks ago? → -2 - if (m.has('before$') === true) { + if (m.has('(before|ago)$') === true) { Object.keys(result).forEach(function (k) { return result[k] *= -1; }); @@ -4961,6 +5003,20 @@ var parseShift = function parseShift(doc) { var _01Shift = parseShift; +var hardCoded = { + daybreak: '7:00am', + //ergh + breakfast: '8:00am', + morning: '9:00am', + noon: '12:00pm', + afternoon: '2:00pm', + lunchtime: '12:00pm', + evening: '6:00pm', + dinnertime: '6:00pm', + night: '8:00pm', + midnight: '12:00am' +}; + var halfPast = function halfPast(m, s) { var hour = m.match('#Cardinal$').text('reduced'); var term = m.match('(half|quarter|25|15|10|5)'); @@ -4999,7 +5055,14 @@ var parseTime$1 = function parseTime(doc, context) { time = time.not('(at|by|for|before|sharp)'); time = time.not('on the dot'); var s = spacetime$2.now(context.timezone); - var now = s.clone(); // '5 oclock' + var now = s.clone(); // check for known-times (like 'today') + + var timeStr = time.text('reduced'); + + if (hardCoded.hasOwnProperty(timeStr)) { + return hardCoded[timeStr]; + } // '5 oclock' + var m = time.match('^#Cardinal oclock (am|pm)?'); @@ -5350,6 +5413,7 @@ var WeekDay = /*#__PURE__*/function (_Unit5) { _this5 = _super5.call(this, input, unit, context); _this5.unit = 'week'; + _this5.d = spacetime$2(context.today, context.timezone); _this5.d = _this5.d.day(input); _this5.weekDay = _this5.d.dayName(); //assume a wednesday in the future @@ -5963,27 +6027,28 @@ var _02Holidays = parseHoliday; var Unit$2 = _units.Unit, Day$1 = _units.Day, - CalendarDate$2 = _units.CalendarDate; + CalendarDate$2 = _units.CalendarDate, + Month$1 = _units.Month; var knownWord = { today: function today(context) { return new Day$1(context.today, null, context); }, yesterday: function yesterday(context) { - new Day$1(context.today.minus(1, 'day'), null, context); + return new Day$1(context.today.minus(1, 'day'), null, context); }, tomorrow: function tomorrow(context) { - new Day$1(context.today.plus(1, 'day'), null, context); + return new Day$1(context.today.plus(1, 'day'), null, context); } }; // parse things like 'june 5th 2019' // most of this is done in spacetime var parseExplicit = function parseExplicit(doc, context) { - var impliedYear = context.today.year(); // 'fifth of june' + var impliedYear = context.today.year(); // 'fifth of june 1992' - var m = doc.match('[#Value] of [#Month] [#Year?]'); // 'june the fifth' + var m = doc.match('[#Value] of? [#Month] [#Year]'); // 'june the fifth 1992' if (!m.found) { - m = doc.match('[#Month] the [#Value] [#Year?]'); + m = doc.match('[#Month] the? [#Value] [#Year]'); } if (m.found) { @@ -5998,28 +6063,87 @@ var parseExplicit = function parseExplicit(doc, context) { if (_d.d.isValid() === true) { return _d; } - } + } //no-dates + // 'march 1992' + + + m = doc.match('[#Month] of? [#Year]'); if (m.found) { var _obj = { month: m.groups('month').text(), - date: m.groups('date').text(), - year: context.today.year() + year: m.groups('year').text() || impliedYear }; - var _d2 = new CalendarDate$2(_obj, null, context); + var _d2 = new Month$1(_obj, null, context); if (_d2.d.isValid() === true) { return _d2; } + } //no-years + // 'fifth of june' + + + m = doc.match('[#Value] of? [#Month]'); // 'june the fifth' + + if (!m.found) { + m = doc.match('[#Month] the? [#Value]'); + } // support 'dec 5th' + + + if (m.found) { + var _obj2 = { + month: m.groups('month').text(), + date: m.groups('date').text(), + year: context.today.year() + }; + + var _d3 = new CalendarDate$2(_obj2, null, context); + + if (_d3.d.isValid() === true) { + return _d3; + } + } // support 'december' + + + if (doc.has('#Month')) { + var _obj3 = { + month: doc.match('#Month').text(), + date: 1, + //assume 1st + year: context.today.year() + }; + + var _d4 = new CalendarDate$2(_obj3, null, context); + + if (_d4.d.isValid() === true) { + return _d4; + } + } // support date-only 'the 21st' + + + m = doc.match('the [#Value]'); + + if (m.found) { + var _obj4 = { + month: context.today.month(), + date: m.groups('date').text(), + year: context.today.year() + }; + + var _d5 = new CalendarDate$2(_obj4, null, context); + + if (_d5.d.isValid() === true) { + return _d5; + } } var str = doc.text('reduced'); // today, yesterday, tomorrow if (knownWord.hasOwnProperty(str) === true) { - var _d3 = knownWord[str](context); + var _d6 = knownWord[str](context); - return _d3; + return _d6; } // punt it to spacetime, for the heavy-lifting @@ -6076,6 +6200,16 @@ var parseDate = function parseDate(doc, context) { d = d || steps.explicit(doc, context); + if ((typeof process === "undefined" ? "undefined" : _typeof(process)) !== undefined && process && process.env.DEBUG) { + console.log('\n\n=-=-=-=-=-=Date-=-=-=-=-=-=-'); + console.log(" shift: ".concat(JSON.stringify(shift))); + console.log(" rel: ".concat(rel || '-')); + console.log(" time: ".concat(time || '-')); + console.log("\n str: '".concat(doc.text(), "'")); + console.log('\n ', d); + console.log('=-=-=-=-=-=-=-=-=-=-=-=-=-=-\n\n'); + } + if (!d) { return null; } // // apply relative @@ -6300,7 +6434,7 @@ var logic = function logic(doc, context) { var d = _03ParseDate(doc, context); return { start: d, - end: null + end: d.clone().end() }; }; diff --git a/plugins/dates/package-lock.json b/plugins/dates/package-lock.json index 0c49b8b8b..df0e250cd 100644 --- a/plugins/dates/package-lock.json +++ b/plugins/dates/package-lock.json @@ -1,6 +1,6 @@ { "name": "compromise-dates", - "version": "0.0.6", + "version": "1.0.0", "lockfileVersion": 1, "requires": true, "dependencies": { @@ -866,9 +866,9 @@ "dev": true }, "spacetime": { - "version": "6.6.0", - "resolved": "https://registry.npmjs.org/spacetime/-/spacetime-6.6.0.tgz", - "integrity": "sha512-WQoWx+D2S+YG24jeVP+VHyxD3L6+ZWQu7kegg+LSRTwaVt8g0cdtsFm0fMGs5m3NKfKSQVTF/srh4fnK0+Zo8g==" + "version": "6.6.3", + "resolved": "https://registry.npmjs.org/spacetime/-/spacetime-6.6.3.tgz", + "integrity": "sha512-0e4g04PAbKPuONcohGa6zl6NUWlemUCCkGSQ5Nmc7VOxsN6b2N9/NJuNhkSjJ5K0AK37fopvNP/pjqNj+hqymw==" }, "spacetime-holiday": { "version": "0.0.2", diff --git a/plugins/dates/package.json b/plugins/dates/package.json index 1e0afb471..4e7c66bc0 100644 --- a/plugins/dates/package.json +++ b/plugins/dates/package.json @@ -1,7 +1,7 @@ { "name": "compromise-dates", "description": "plugin for nlp-compromise", - "version": "1.0.0", + "version": "1.1.0", "author": "Spencer Kelly (http://spencermounta.in)", "main": "./builds/compromise-dates.js", "unpkg": "./builds/compromise-dates.min.js", @@ -47,7 +47,7 @@ "tape": "5.0.1" }, "dependencies": { - "spacetime": "6.6.0", + "spacetime": "6.6.3", "spacetime-holiday": "0.0.2" }, "license": "MIT" diff --git a/plugins/dates/src/01-tag/00-basic.js b/plugins/dates/src/01-tag/00-basic.js index d0ab5055e..7007752cc 100644 --- a/plugins/dates/src/01-tag/00-basic.js +++ b/plugins/dates/src/01-tag/00-basic.js @@ -32,7 +32,7 @@ const tagYearSafe = (m, reason) => { } } -const fixDates = function(doc) { +const fixDates = function (doc) { doc.match('in the (night|evening|morning|afternoon|day|daytime)').tag('Time', 'in-the-night') doc.match('(#Value|#Time) (am|pm)').tag('Time', 'value-ampm') @@ -55,22 +55,13 @@ const fixDates = function(doc) { let val = doc.if('#Value') if (val.found === true) { //june 7 - val - .match('(#WeekDay|#Month) #Value') - .ifNo('#Money') - .tag('Date', 'date-value') + val.match('(#WeekDay|#Month) #Value').ifNo('#Money').tag('Date', 'date-value') //7 june - val - .match('#Value (#WeekDay|#Month)') - .ifNo('#Money') - .tag('Date', 'value-date') + val.match('#Value (#WeekDay|#Month)').ifNo('#Money').tag('Date', 'value-date') //may twenty five - val - .match('#TextValue #TextValue') - .if('#Date') - .tag('#Date', 'textvalue-date') + val.match('#TextValue #TextValue').if('#Date').tag('#Date', 'textvalue-date') //eg 'year' let duration = val.if('#Duration') @@ -112,21 +103,11 @@ const fixDates = function(doc) { //early in june date.match('(early|late) (at|in)? the? #Date').tag('Time', 'early-evening') //tomorrow before 3 - date - .match('#Date (by|before|after|at|@|about) #Cardinal') - .not('^#Date') - .tag('Time', 'date-before-Cardinal') + date.match('#Date (by|before|after|at|@|about) #Cardinal').not('^#Date').tag('Time', 'date-before-Cardinal') //saturday am - date - .match('#Date [(am|pm)]', 0) - .unTag('Verb') - .unTag('Copula') - .tag('Time', 'date-am') + date.match('#Date [(am|pm)]', 0).unTag('Verb').unTag('Copula').tag('Time', 'date-am') //feb to june - date - .match('#Date (#Preposition|to) #Date') - .ifNo('#Duration') - .tag('Date', 'date-prep-date') + date.match('#Date (#Preposition|to) #Date').ifNo('#Duration').tag('Date', 'date-prep-date') } //year/cardinal tagging @@ -165,10 +146,7 @@ const fixDates = function(doc) { //by 6pm time.match('(by|before|after|at|@|about) #Time').tag('Time', 'preposition-time') //7 7pm - time - .match('#Cardinal #Time') - .not('#Year') - .tag('Time', 'value-time') + time.match('#Cardinal #Time').not('#Year').tag('Time', 'value-time') //2pm est time.match('#Time [(eastern|pacific|central|mountain)]', 0).tag('Date', 'timezone') //6pm est diff --git a/plugins/dates/src/01-tag/01-values.js b/plugins/dates/src/01-tag/01-values.js index be4bf8d59..d1f131f1c 100644 --- a/plugins/dates/src/01-tag/01-values.js +++ b/plugins/dates/src/01-tag/01-values.js @@ -1,29 +1,31 @@ const here = 'date-values' // -const values = function(doc) { +const values = function (doc) { + // a year ago + doc.match('!once [a] #Duration', 0).replaceWith('1').tag('Cardinal', here) if (doc.has('#Value')) { //june 5 to 7th - doc.match('#Month #Value to #Value of? #Year?').tag('Date', here); + doc.match('#Month #Value to #Value of? #Year?').tag('Date', here) //5 to 7th june - doc.match('#Value to #Value of? #Month #Year?').tag('Date', here); + doc.match('#Value to #Value of? #Month #Year?').tag('Date', here) //third week of may - doc.match('#Value #Duration of #Date').tag('Date', here); + doc.match('#Value #Duration of #Date').tag('Date', here) //two days after - doc.match('#Value+ #Duration (after|before|into|later|afterwards|ago)?').tag('Date', here); + doc.match('#Value+ #Duration (after|before|into|later|afterwards|ago)?').tag('Date', here) //two days - doc.match('#Value #Date').tag('Date', here); + doc.match('#Value #Date').tag('Date', here) //june 5th - doc.match('#Date #Value').tag('Date', here); + doc.match('#Date #Value').tag('Date', here) //tuesday at 5 - doc.match('#Date #Preposition #Value').tag('Date', here); + doc.match('#Date #Preposition #Value').tag('Date', here) //tomorrow before 3 - doc.match('#Date (after|before|during|on|in) #Value').tag('Date', here); + doc.match('#Date (after|before|during|on|in) #Value').tag('Date', here) //a year and a half - doc.match('#Value (year|month|week|day) and a half').tag('Date', here); + doc.match('#Value (year|month|week|day) and a half').tag('Date', here) //5 and a half years - doc.match('#Value and a half (years|months|weeks|days)').tag('Date', here); + doc.match('#Value and a half (years|months|weeks|days)').tag('Date', here) //on the fifth - doc.match('on the #Ordinal').tag('Date', here); + doc.match('on the #Ordinal').tag('Date', here) } return doc } diff --git a/plugins/dates/src/01-tag/05-shifts.js b/plugins/dates/src/01-tag/05-shifts.js index f778c544d..13d21c61d 100644 --- a/plugins/dates/src/01-tag/05-shifts.js +++ b/plugins/dates/src/01-tag/05-shifts.js @@ -1,9 +1,9 @@ const here = 'shift-tagger' // -const shiftTagger = function(doc) { +const shiftTagger = function (doc) { if (doc.has('#Date')) { - //two weeks before - doc.match('#Cardinal #Duration (before|after)').tag('#DateShift', here) + //'two days before'/ 'nine weeks frow now' + doc.match('#Cardinal #Duration (before|after|ago|from)').tag('#DateShift', here) // in two weeks doc.match('in #Cardinal #Duration').tag('#DateShift', here) //two weeks and three days before diff --git a/plugins/dates/src/02-getDate/01-parse-range.js b/plugins/dates/src/02-getDate/01-parse-range.js index b62105ae3..38ec4642f 100644 --- a/plugins/dates/src/02-getDate/01-parse-range.js +++ b/plugins/dates/src/02-getDate/01-parse-range.js @@ -156,7 +156,7 @@ const logic = function (doc, context) { let d = parseDate(doc, context) return { start: d, - end: null, + end: d.clone().end(), } } module.exports = logic diff --git a/plugins/dates/src/03-parseDate/_units.js b/plugins/dates/src/03-parseDate/_units.js index 3685c8169..689b80564 100644 --- a/plugins/dates/src/03-parseDate/_units.js +++ b/plugins/dates/src/03-parseDate/_units.js @@ -29,6 +29,7 @@ class WeekDay extends Unit { constructor(input, unit, context) { super(input, unit, context) this.unit = 'week' + this.d = spacetime(context.today, context.timezone) this.d = this.d.day(input) this.weekDay = this.d.dayName() //assume a wednesday in the future diff --git a/plugins/dates/src/03-parseDate/index.js b/plugins/dates/src/03-parseDate/index.js index ffee4f647..05b688ee4 100644 --- a/plugins/dates/src/03-parseDate/index.js +++ b/plugins/dates/src/03-parseDate/index.js @@ -34,6 +34,17 @@ const parseDate = function (doc, context) { d = d || steps.holiday(doc, context) // 'this june 2nd' d = d || steps.explicit(doc, context) + + if (typeof process !== undefined && process && process.env.DEBUG) { + console.log('\n\n=-=-=-=-=-=Date-=-=-=-=-=-=-') + console.log(` shift: ${JSON.stringify(shift)}`) + console.log(` rel: ${rel || '-'}`) + console.log(` time: ${time || '-'}`) + console.log(`\n str: '${doc.text()}'`) + console.log('\n ', d) + console.log('=-=-=-=-=-=-=-=-=-=-=-=-=-=-\n\n') + } + if (!d) { return null } diff --git a/plugins/dates/src/03-parseDate/sections/01-shift.js b/plugins/dates/src/03-parseDate/sections/01-shift.js index c8ced7acd..0309d9c4e 100644 --- a/plugins/dates/src/03-parseDate/sections/01-shift.js +++ b/plugins/dates/src/03-parseDate/sections/01-shift.js @@ -11,13 +11,13 @@ const knownUnits = { } //turn '5 weeks before' to {weeks:5} -const parseShift = function(doc) { +const parseShift = function (doc) { let result = {} let m = doc.match('#DateShift+') if (m.found === false) { return result } - m.match('#Cardinal #Duration').forEach(ts => { + m.match('#Cardinal #Duration').forEach((ts) => { let num = ts.match('#Cardinal').text('normal') num = parseFloat(num) if (num && typeof num === 'number') { @@ -28,9 +28,9 @@ const parseShift = function(doc) { } } }) - //is it 2 weeks before? → -2 - if (m.has('before$') === true) { - Object.keys(result).forEach(k => (result[k] *= -1)) + //is it 2 weeks ago? → -2 + if (m.has('(before|ago)$') === true) { + Object.keys(result).forEach((k) => (result[k] *= -1)) } // finally, remove it from our text doc.remove('#DateShift') diff --git a/plugins/dates/src/03-parseDate/sections/02-time.js b/plugins/dates/src/03-parseDate/sections/02-time.js index cf9ef0b96..a6ef41b4a 100644 --- a/plugins/dates/src/03-parseDate/sections/02-time.js +++ b/plugins/dates/src/03-parseDate/sections/02-time.js @@ -1,7 +1,19 @@ const spacetime = require('spacetime') -//hmmm: 'june 5th between 9 and 10am' -const halfPast = function(m, s) { +const hardCoded = { + daybreak: '7:00am', //ergh + breakfast: '8:00am', + morning: '9:00am', + noon: '12:00pm', + afternoon: '2:00pm', + lunchtime: '12:00pm', + evening: '6:00pm', + dinnertime: '6:00pm', + night: '8:00pm', + midnight: '12:00am', +} + +const halfPast = function (m, s) { let hour = m.match('#Cardinal$').text('reduced') let term = m.match('(half|quarter|25|15|10|5)') @@ -24,7 +36,7 @@ const halfPast = function(m, s) { return s } -const parseTime = function(doc, context) { +const parseTime = function (doc, context) { let time = doc.match('(at|by|for|before)? #Time+') if (time.found) { doc.remove(time) @@ -35,6 +47,12 @@ const parseTime = function(doc, context) { let s = spacetime.now(context.timezone) let now = s.clone() + // check for known-times (like 'today') + let timeStr = time.text('reduced') + if (hardCoded.hasOwnProperty(timeStr)) { + return hardCoded[timeStr] + } + // '5 oclock' let m = time.match('^#Cardinal oclock (am|pm)?') if (m.found) { diff --git a/plugins/dates/src/03-parseDate/steps/01-duration.js b/plugins/dates/src/03-parseDate/steps/01-duration.js index 233f54464..231aafa9a 100644 --- a/plugins/dates/src/03-parseDate/steps/01-duration.js +++ b/plugins/dates/src/03-parseDate/steps/01-duration.js @@ -8,7 +8,7 @@ const mapping = { } // when a unit of time is spoken of as 'this month' - instead of 'february' -const namedUnit = function(doc, context) { +const namedUnit = function (doc, context) { //this month, last quarter, next year let m = doc.match('(weekday|week|month|quarter|season|year)') if (m.found === true) { diff --git a/plugins/dates/src/03-parseDate/steps/03-explicit.js b/plugins/dates/src/03-parseDate/steps/03-explicit.js index 1a8ab6ac3..09ff343ed 100644 --- a/plugins/dates/src/03-parseDate/steps/03-explicit.js +++ b/plugins/dates/src/03-parseDate/steps/03-explicit.js @@ -1,12 +1,15 @@ -const { Unit, Day, CalendarDate } = require('../_units') +const { Unit, Day, CalendarDate, Month } = require('../_units') +const tryHere = require('../../../../../src/Phrase/match/03-tryMatch') const knownWord = { - today: (context) => new Day(context.today, null, context), + today: (context) => { + return new Day(context.today, null, context) + }, yesterday: (context) => { - new Day(context.today.minus(1, 'day'), null, context) + return new Day(context.today.minus(1, 'day'), null, context) }, tomorrow: (context) => { - new Day(context.today.plus(1, 'day'), null, context) + return new Day(context.today.plus(1, 'day'), null, context) }, } @@ -14,11 +17,12 @@ const knownWord = { // most of this is done in spacetime const parseExplicit = function (doc, context) { let impliedYear = context.today.year() - // 'fifth of june' - let m = doc.match('[#Value] of [#Month] [#Year?]') - // 'june the fifth' + + // 'fifth of june 1992' + let m = doc.match('[#Value] of? [#Month] [#Year]') + // 'june the fifth 1992' if (!m.found) { - m = doc.match('[#Month] the [#Value] [#Year?]') + m = doc.match('[#Month] the? [#Value] [#Year]') } if (m.found) { let obj = { @@ -32,6 +36,27 @@ const parseExplicit = function (doc, context) { } } + //no-dates + // 'march 1992' + m = doc.match('[#Month] of? [#Year]') + if (m.found) { + let obj = { + month: m.groups('month').text(), + year: m.groups('year').text() || impliedYear, + } + let d = new Month(obj, null, context) + if (d.d.isValid() === true) { + return d + } + } + //no-years + // 'fifth of june' + m = doc.match('[#Value] of? [#Month]') + // 'june the fifth' + if (!m.found) { + m = doc.match('[#Month] the? [#Value]') + } + // support 'dec 5th' if (m.found) { let obj = { month: m.groups('month').text(), @@ -43,7 +68,32 @@ const parseExplicit = function (doc, context) { return d } } + // support 'december' + if (doc.has('#Month')) { + let obj = { + month: doc.match('#Month').text(), + date: 1, //assume 1st + year: context.today.year(), + } + let d = new CalendarDate(obj, null, context) + if (d.d.isValid() === true) { + return d + } + } + // support date-only 'the 21st' + m = doc.match('the [#Value]') + if (m.found) { + let obj = { + month: context.today.month(), + date: m.groups('date').text(), + year: context.today.year(), + } + let d = new CalendarDate(obj, null, context) + if (d.d.isValid() === true) { + return d + } + } let str = doc.text('reduced') // today, yesterday, tomorrow if (knownWord.hasOwnProperty(str) === true) { diff --git a/plugins/dates/src/data/words/times.js b/plugins/dates/src/data/words/times.js index a89dd502e..7b1ab7d57 100644 --- a/plugins/dates/src/data/words/times.js +++ b/plugins/dates/src/data/words/times.js @@ -10,7 +10,6 @@ module.exports = [ 'breakfast time', 'lunchtime', 'dinnertime', - 'ago', 'sometime', 'eod', 'oclock', diff --git a/plugins/dates/tests/backlog/startDates.ignore.js b/plugins/dates/tests/backlog/startDates.ignore.js index 8d511c91d..1e218aace 100644 --- a/plugins/dates/tests/backlog/startDates.ignore.js +++ b/plugins/dates/tests/backlog/startDates.ignore.js @@ -392,18 +392,18 @@ const tests = [ ], }, { - today: [2016, september, 28], + today: [2016, october, 28], //friday tests: [ - ['saturday morning', [2016, october, 1]], - ['saturday early in the day', [2016, october, 1]], - ['saturday am', [2016, october, 1]], - ['saturday pm', [2016, october, 1]], - ['saturday noon', [2016, october, 1]], - ['saturday afternoon', [2016, october, 1]], - ['saturday evening', [2016, october, 1]], - ['saturday night', [2016, october, 1]], - ['saturday late night', [2016, october, 1]], - ['saturday late at night', [2016, october, 1]], + ['saturday morning', [2016, october, 29]], + ['saturday early in the day', [2016, october, 29]], + ['saturday am', [2016, october, 29]], + ['saturday pm', [2016, october, 29]], + ['saturday noon', [2016, october, 29]], + ['saturday afternoon', [2016, october, 29]], + ['saturday evening', [2016, october, 29]], + ['saturday night', [2016, october, 29]], + ['saturday late night', [2016, october, 29]], + ['saturday late at night', [2016, october, 29]], ], }, { @@ -598,9 +598,10 @@ test('start dates', (t) => { timezone: 'Canada/Eastern', } tests[k].tests.forEach((a) => { - let want = spacetime(a[1], context.timezone).startOf('day').iso() + let want = spacetime(a[1], context.timezone).startOf('day').format('iso-short') let json = nlp(a[0]).dates(context).json()[0] || {} let start = (json.date || {}).start + start = spacetime(start).format('iso-short') t.equal(start, want, a[0]) }) }) diff --git a/plugins/sentences/builds/compromise-sentences.js b/plugins/sentences/builds/compromise-sentences.js index 0d11a31cb..0e992b786 100644 --- a/plugins/sentences/builds/compromise-sentences.js +++ b/plugins/sentences/builds/compromise-sentences.js @@ -1,4 +1,4 @@ -/* compromise-sentences 0.0.6 MIT */ +/* compromise-sentences 0.1.0 MIT */ (function (global, factory) { typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() : typeof define === 'function' && define.amd ? define(factory) : @@ -319,22 +319,59 @@ toStatement: toStatement }; + var useParticiple = function useParticiple(vb) { + if (vb.has('(could|should|would|may|can|must)')) { + return true; + } + + return false; + }; /** he walks -> he walked */ + var toPastTense = function toPastTense() { this.forEach(function (doc) { if (doc.has('#PastTense')) { return; } + var obj = parse_1(doc); + var vb = obj.verb.clone(); // support 'he could drive' -> 'he could have driven' + + if (useParticiple(vb)) { + vb = vb.verbs().toParticiple(); + obj.verb.replaceWith(vb, false); + } else { + //do a normal conjugation + vb = vb.verbs().toPastTense(); + obj.verb.replaceWith(vb, false); + } // trailing gerund/future/present are okay, but 'walked and eats' is not + + + if (obj.object && obj.object.found && obj.object.has('#PresentTense')) { + var verbs = obj.object.verbs(); + verbs["if"]('#PresentTense').verbs().toPastTense(); + } + }); + return this; + }; + /** he drives -> he has driven */ + + + var toParticiple = function toParticiple() { + this.forEach(function (doc) { + if (doc.has('has #Participle')) { + return; + } + var obj = parse_1(doc); var vb = obj.verb.clone(); - vb = vb.verbs().toPastTense(); + vb = vb.verbs().toParticiple(); obj.verb.replaceWith(vb, false); // trailing gerund/future/present are okay, but 'walked and eats' is not if (obj.object && obj.object.found && obj.object.has('#PresentTense')) { var verbs = obj.object.verbs(); - verbs["if"]('#PresentTense').verbs().toPastTense(); + verbs["if"]('#PresentTense').verbs().toParticiple(); } }); return this; @@ -392,6 +429,7 @@ var tense = { toPastTense: toPastTense, + toParticiple: toParticiple, toPresentTense: toPresentTense, toFutureTense: toFutureTense }; diff --git a/plugins/sentences/builds/compromise-sentences.js.map b/plugins/sentences/builds/compromise-sentences.js.map index 4d600ec1c..4d164c385 100644 --- a/plugins/sentences/builds/compromise-sentences.js.map +++ b/plugins/sentences/builds/compromise-sentences.js.map @@ -1 +1 @@ -{"version":3,"file":"compromise-sentences.js","sources":["../src/mainClause.js","../src/parse.js","../src/methods/negate.js","../src/methods/types/isQuestion.js","../src/methods/types/index.js","../src/methods/tense.js","../src/methods/index.js","../src/index.js"],"sourcesContent":["// if a clause starts with these, it's not a main clause\nconst subordinate = `(after|although|as|because|before|if|since|than|that|though|when|whenever|where|whereas|wherever|whether|while|why|unless|until|once)`\nconst relative = `(that|which|whichever|who|whoever|whom|whose|whomever)`\n\n//try to remove secondary clauses\nconst mainClause = function(og) {\n let m = og.clone(true)\n if (m.length === 1) {\n return m\n }\n // if there's no verb?\n m = m.if('#Verb')\n if (m.length === 1) {\n return m\n }\n // this is a signal for subordinate-clauses\n m = m.ifNo(subordinate)\n m = m.ifNo('^even (if|though)')\n m = m.ifNo('^so that')\n m = m.ifNo('^rather than')\n m = m.ifNo('^provided that')\n if (m.length === 1) {\n return m\n }\n // relative clauses\n m = m.ifNo(relative)\n if (m.length === 1) {\n return m\n }\n\n m = m.ifNo('(despite|during|before|through|throughout)')\n if (m.length === 1) {\n return m\n }\n // did we go too far?\n if (m.length === 0) {\n m = og\n }\n // choose the first one?\n return m.eq(0)\n}\nmodule.exports = mainClause\n","const mainClause = require('./mainClause')\n\nconst parse = function(doc) {\n let clauses = doc.clauses()\n let main = mainClause(clauses)\n let nouns = main.match('#Determiner? (#Noun|#Adjective)+').if('#Noun')\n let verb = main.verbs().eq(0)\n // match('(do|will)? not? #Verb+ not?').eq(0)\n return {\n subject: nouns.eq(0),\n verb: verb,\n object: verb.lookAhead('.*'),\n }\n}\nmodule.exports = parse\n","const parse = require('../parse')\n\n/** he walks -> he did not walk */\nexports.toNegative = function() {\n this.forEach(doc => {\n let obj = parse(doc)\n let vb = obj.verb.clone()\n vb = vb.verbs().toNegative()\n obj.verb.replaceWith(vb, false)\n })\n return this\n}\n/** he doesn't walk -> he walks */\nexports.toPositive = function() {\n this.forEach(doc => {\n let obj = parse(doc)\n let vb = obj.verb.clone()\n vb = vb.verbs().toPositive()\n obj.verb.replaceWith(vb, false)\n })\n return this\n}\n","//is this sentence asking a question?\nconst isQuestion = function (doc) {\n let endPunct = doc.post()\n let clauses = doc.clauses()\n\n if (/\\?/.test(endPunct) === true) {\n return true\n }\n\n // Has ellipsis at the end means it's probably not a question\n // e.g., Is this just fantasy...\n if (/\\.\\.$/.test(doc.out('text'))) {\n return false\n }\n\n // Starts with question word, but has a comma, so probably not a question\n // e.g., Why are we caught in a land slide, no escape from reality\n if (doc.has('^#QuestionWord') && doc.has('#Comma')) {\n return false\n }\n\n // Starts with a #QuestionWord\n // e.g., What open your eyes look up to the skies and see\n if (doc.has('^#QuestionWord')) {\n return true\n }\n\n // Second word is a #QuestionWord\n // e.g., I'm what a poor boy\n // case ts.has('^\\w+\\s#QuestionWord'):\n // return true;\n\n // is it, do you - start of sentence\n // e.g., Do I need no sympathy\n if (doc.has('^(do|does|did|is|was|can|could|will|would|may) #Noun')) {\n return true\n }\n\n // these are a little more loose..\n // e.g., Must I be come easy come easy go\n if (doc.has('^(have|must) you')) {\n return true\n }\n\n // Clause starts with a question word\n // e.g., Anyway the wind blows, what doesn't really matter to me\n if (clauses.has('^#QuestionWord')) {\n return true\n }\n\n //is wayne gretskzy alive\n if (clauses.has('(do|does|is|was) #Noun+ #Adverb? (#Adjective|#Infinitive)$')) {\n return true\n }\n\n // Probably not a question\n return false\n}\nmodule.exports = isQuestion\n","const isQuestion = require('./isQuestion')\n\n/** return sentences ending with '?' */\nexports.isQuestion = function () {\n return this.filter((d) => isQuestion(d))\n}\n/** return sentences ending with '!' */\nexports.isExclamation = function () {\n return this.filter((doc) => {\n let term = doc.lastTerm().termList(0)\n return term.hasPost('!')\n })\n}\n/** return sentences with neither a question or an exclamation */\nexports.isStatement = function () {\n return this.filter((doc) => {\n let term = doc.lastTerm().termList(0)\n return !term.hasPost('?') && !term.hasPost('!')\n })\n}\n\n/** 'he is.' -> 'he is!' */\nexports.toExclamation = function () {\n this.post('!')\n return this\n}\n/** 'he is.' -> 'he is?' */\nexports.toQuestion = function () {\n this.post('?')\n return this\n}\n/** 'he is?' -> 'he is.' */\nexports.toStatement = function () {\n this.post('.')\n return this\n}\n","const parse = require('../parse')\n\n/** he walks -> he walked */\nexports.toPastTense = function() {\n this.forEach(doc => {\n if (doc.has('#PastTense')) {\n return\n }\n let obj = parse(doc)\n let vb = obj.verb.clone()\n vb = vb.verbs().toPastTense()\n obj.verb.replaceWith(vb, false)\n // trailing gerund/future/present are okay, but 'walked and eats' is not\n if (obj.object && obj.object.found && obj.object.has('#PresentTense')) {\n let verbs = obj.object.verbs()\n verbs\n .if('#PresentTense')\n .verbs()\n .toPastTense()\n }\n })\n return this\n}\n\n/** he walked -> he walks */\nexports.toPresentTense = function() {\n this.forEach(doc => {\n let obj = parse(doc)\n let isPlural = obj.verb.lookBehind('(i|we) (#Adverb|#Verb)?$').found\n let vb = obj.verb.clone()\n // 'i look', not 'i looks'\n if (isPlural) {\n //quick hack for copula verb - be/am\n if (vb.has('(is|was|am|be)')) {\n vb = vb.replace('will? (is|was|am|be)', 'am')\n } else {\n vb = vb.verbs().toInfinitive()\n }\n } else {\n //'he looks'\n vb = vb.verbs().toPresentTense()\n }\n obj.verb.replaceWith(vb, false)\n\n // future is okay, but 'walks and ate' -> 'walks and eats'\n if (obj.object && obj.object.found && obj.object.has('#PastTense')) {\n let verbs = obj.object.verbs()\n verbs\n .if('#PastTense')\n .verbs()\n .toPresentTense()\n }\n })\n return this\n}\n\n/**he walked -> he will walk */\nexports.toFutureTense = function() {\n this.forEach(doc => {\n let obj = parse(doc)\n let vb = obj.verb.clone()\n vb = vb.verbs().toFutureTense()\n obj.verb.replaceWith(vb, false)\n //Present is okay, but 'will walk and ate' -> 'will walk and eat'\n if (obj.object && obj.object.found && obj.object.has('(#PastTense|#PresentTense)')) {\n let verbs = obj.object.verbs()\n verbs\n .if('(#PastTense|#PresentTense)')\n .verbs()\n .toInfinitive()\n }\n })\n return this\n}\n\n// toContinuous() {\n// return this\n// }\n","module.exports = Object.assign({}, require('./negate'), require('./types'), require('./tense'))\n","const parse = require('./parse')\nconst methods = require('./methods')\n\nconst addMethod = function (Doc) {\n /** */\n class Sentences extends Doc {\n constructor(list, from, world) {\n list = list.map((p) => p.clone(true))\n super(list, from, world)\n }\n\n /** overload the original json with noun information */\n json(options) {\n let n = null\n if (typeof options === 'number') {\n n = options\n options = null\n }\n options = options || { text: true, normal: true, trim: true, terms: true }\n let res = []\n this.forEach((doc) => {\n let json = doc.json(options)[0]\n let obj = parse(doc)\n json.subject = obj.subject.json(options)[0]\n json.verb = obj.verb.json(options)[0]\n json.object = obj.object.json(options)[0]\n res.push(json)\n })\n if (n !== null) {\n return res[n]\n }\n return res\n }\n\n /** the main noun of the sentence */\n subjects() {\n return this.map((doc) => {\n let res = parse(doc)\n return res.subject\n })\n }\n\n /** return sentences that are in passive-voice */\n isPassive() {\n return this.if('was #Adverb? #PastTense #Adverb? by') //haha\n }\n\n /** add a word to the start of this sentence */\n prepend(str) {\n this.forEach((doc) => {\n // repair the titlecase\n let firstTerms = doc.match('^.')\n firstTerms.not('#ProperNoun').toLowerCase()\n // actually add the word\n firstTerms.prepend(str)\n // add a titlecase\n firstTerms.terms(0).toTitleCase()\n })\n return this\n }\n\n /** add a word to the end of this sentence */\n append(str) {\n let hasEnd = /[.?!]\\s*$/.test(str)\n this.forEach((doc) => {\n let end = doc.match('.$')\n let lastTerm = end.termList(0)\n let punct = lastTerm.post\n if (hasEnd === true) {\n punct = ''\n }\n // add punctuation to the end\n end.append(str + punct)\n // remove punctuation from the former last-term\n lastTerm.post = ' '\n })\n return this\n }\n }\n // add some aliases\n methods.questions = methods.isQuestion\n methods.exclamations = methods.isExclamation\n methods.statements = methods.isStatement\n\n Object.assign(Sentences.prototype, methods)\n\n /** overload original sentences() method and return Sentence class**/\n Doc.prototype.sentences = function (n) {\n let arr = []\n this.list.forEach((p) => {\n arr.push(p.fullSentence())\n })\n //grab (n)th result\n let s = new Sentences(arr, this, this.world)\n if (typeof n === 'number') {\n s = s.get(n)\n }\n return s\n }\n return Doc\n}\nmodule.exports = addMethod\n"],"names":["subordinate","relative","mainClause","og","m","clone","length","ifNo","eq","parse","doc","clauses","main","nouns","match","verb","verbs","subject","object","lookAhead","forEach","obj","vb","toNegative","replaceWith","toPositive","isQuestion","endPunct","post","test","out","has","filter","d","term","lastTerm","termList","hasPost","toPastTense","found","isPlural","lookBehind","replace","toInfinitive","toPresentTense","toFutureTense","Object","assign","require$$0","require$$1","require$$2","addMethod","Doc","Sentences","list","from","world","map","p","options","n","text","normal","trim","terms","res","json","push","str","firstTerms","not","toLowerCase","prepend","toTitleCase","hasEnd","end","punct","append","methods","questions","exclamations","isExclamation","statements","isStatement","prototype","sentences","arr","fullSentence","s","get"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAAA;EACA,IAAMA,WAAW,0IAAjB;EACA,IAAMC,QAAQ,2DAAd;;EAGA,IAAMC,UAAU,GAAG,SAAbA,UAAa,CAASC,EAAT,EAAa;EAC9B,MAAIC,CAAC,GAAGD,EAAE,CAACE,KAAH,CAAS,IAAT,CAAR;;EACA,MAAID,CAAC,CAACE,MAAF,KAAa,CAAjB,EAAoB;EAClB,WAAOF,CAAP;EACD,GAJ6B;;;EAM9BA,EAAAA,CAAC,GAAGA,CAAC,MAAD,CAAK,OAAL,CAAJ;;EACA,MAAIA,CAAC,CAACE,MAAF,KAAa,CAAjB,EAAoB;EAClB,WAAOF,CAAP;EACD,GAT6B;;;EAW9BA,EAAAA,CAAC,GAAGA,CAAC,CAACG,IAAF,CAAOP,WAAP,CAAJ;EACAI,EAAAA,CAAC,GAAGA,CAAC,CAACG,IAAF,CAAO,mBAAP,CAAJ;EACAH,EAAAA,CAAC,GAAGA,CAAC,CAACG,IAAF,CAAO,UAAP,CAAJ;EACAH,EAAAA,CAAC,GAAGA,CAAC,CAACG,IAAF,CAAO,cAAP,CAAJ;EACAH,EAAAA,CAAC,GAAGA,CAAC,CAACG,IAAF,CAAO,gBAAP,CAAJ;;EACA,MAAIH,CAAC,CAACE,MAAF,KAAa,CAAjB,EAAoB;EAClB,WAAOF,CAAP;EACD,GAlB6B;;;EAoB9BA,EAAAA,CAAC,GAAGA,CAAC,CAACG,IAAF,CAAON,QAAP,CAAJ;;EACA,MAAIG,CAAC,CAACE,MAAF,KAAa,CAAjB,EAAoB;EAClB,WAAOF,CAAP;EACD;;EAEDA,EAAAA,CAAC,GAAGA,CAAC,CAACG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file":"compromise-sentences.js","sources":["../src/mainClause.js","../src/parse.js","../src/methods/negate.js","../src/methods/types/isQuestion.js","../src/methods/types/index.js","../src/methods/tense.js","../src/methods/index.js","../src/index.js"],"sourcesContent":["// if a clause starts with these, it's not a main clause\nconst subordinate = `(after|although|as|because|before|if|since|than|that|though|when|whenever|where|whereas|wherever|whether|while|why|unless|until|once)`\nconst relative = `(that|which|whichever|who|whoever|whom|whose|whomever)`\n\n//try to remove secondary clauses\nconst mainClause = function(og) {\n let m = og.clone(true)\n if (m.length === 1) {\n return m\n }\n // if there's no verb?\n m = m.if('#Verb')\n if (m.length === 1) {\n return m\n }\n // this is a signal for subordinate-clauses\n m = m.ifNo(subordinate)\n m = m.ifNo('^even (if|though)')\n m = m.ifNo('^so that')\n m = m.ifNo('^rather than')\n m = m.ifNo('^provided that')\n if (m.length === 1) {\n return m\n }\n // relative clauses\n m = m.ifNo(relative)\n if (m.length === 1) {\n return m\n }\n\n m = m.ifNo('(despite|during|before|through|throughout)')\n if (m.length === 1) {\n return m\n }\n // did we go too far?\n if (m.length === 0) {\n m = og\n }\n // choose the first one?\n return m.eq(0)\n}\nmodule.exports = mainClause\n","const mainClause = require('./mainClause')\n\nconst parse = function(doc) {\n let clauses = doc.clauses()\n let main = mainClause(clauses)\n let nouns = main.match('#Determiner? (#Noun|#Adjective)+').if('#Noun')\n let verb = main.verbs().eq(0)\n // match('(do|will)? not? #Verb+ not?').eq(0)\n return {\n subject: nouns.eq(0),\n verb: verb,\n object: verb.lookAhead('.*'),\n }\n}\nmodule.exports = parse\n","const parse = require('../parse')\n\n/** he walks -> he did not walk */\nexports.toNegative = function() {\n this.forEach(doc => {\n let obj = parse(doc)\n let vb = obj.verb.clone()\n vb = vb.verbs().toNegative()\n obj.verb.replaceWith(vb, false)\n })\n return this\n}\n/** he doesn't walk -> he walks */\nexports.toPositive = function() {\n this.forEach(doc => {\n let obj = parse(doc)\n let vb = obj.verb.clone()\n vb = vb.verbs().toPositive()\n obj.verb.replaceWith(vb, false)\n })\n return this\n}\n","//is this sentence asking a question?\nconst isQuestion = function (doc) {\n let endPunct = doc.post()\n let clauses = doc.clauses()\n\n if (/\\?/.test(endPunct) === true) {\n return true\n }\n\n // Has ellipsis at the end means it's probably not a question\n // e.g., Is this just fantasy...\n if (/\\.\\.$/.test(doc.out('text'))) {\n return false\n }\n\n // Starts with question word, but has a comma, so probably not a question\n // e.g., Why are we caught in a land slide, no escape from reality\n if (doc.has('^#QuestionWord') && doc.has('#Comma')) {\n return false\n }\n\n // Starts with a #QuestionWord\n // e.g., What open your eyes look up to the skies and see\n if (doc.has('^#QuestionWord')) {\n return true\n }\n\n // Second word is a #QuestionWord\n // e.g., I'm what a poor boy\n // case ts.has('^\\w+\\s#QuestionWord'):\n // return true;\n\n // is it, do you - start of sentence\n // e.g., Do I need no sympathy\n if (doc.has('^(do|does|did|is|was|can|could|will|would|may) #Noun')) {\n return true\n }\n\n // these are a little more loose..\n // e.g., Must I be come easy come easy go\n if (doc.has('^(have|must) you')) {\n return true\n }\n\n // Clause starts with a question word\n // e.g., Anyway the wind blows, what doesn't really matter to me\n if (clauses.has('^#QuestionWord')) {\n return true\n }\n\n //is wayne gretskzy alive\n if (clauses.has('(do|does|is|was) #Noun+ #Adverb? (#Adjective|#Infinitive)$')) {\n return true\n }\n\n // Probably not a question\n return false\n}\nmodule.exports = isQuestion\n","const isQuestion = require('./isQuestion')\n\n/** return sentences ending with '?' */\nexports.isQuestion = function () {\n return this.filter((d) => isQuestion(d))\n}\n/** return sentences ending with '!' */\nexports.isExclamation = function () {\n return this.filter((doc) => {\n let term = doc.lastTerm().termList(0)\n return term.hasPost('!')\n })\n}\n/** return sentences with neither a question or an exclamation */\nexports.isStatement = function () {\n return this.filter((doc) => {\n let term = doc.lastTerm().termList(0)\n return !term.hasPost('?') && !term.hasPost('!')\n })\n}\n\n/** 'he is.' -> 'he is!' */\nexports.toExclamation = function () {\n this.post('!')\n return this\n}\n/** 'he is.' -> 'he is?' */\nexports.toQuestion = function () {\n this.post('?')\n return this\n}\n/** 'he is?' -> 'he is.' */\nexports.toStatement = function () {\n this.post('.')\n return this\n}\n","const parse = require('../parse')\n\n// 'i could drive' -> 'i could have driven'\nconst useParticiple = function (vb) {\n if (vb.has('(could|should|would|may|can|must)')) {\n return true\n }\n return false\n}\n\n/** he walks -> he walked */\nexports.toPastTense = function () {\n this.forEach((doc) => {\n if (doc.has('#PastTense')) {\n return\n }\n let obj = parse(doc)\n let vb = obj.verb.clone()\n // support 'he could drive' -> 'he could have driven'\n if (useParticiple(vb)) {\n vb = vb.verbs().toParticiple()\n obj.verb.replaceWith(vb, false)\n } else {\n //do a normal conjugation\n vb = vb.verbs().toPastTense()\n obj.verb.replaceWith(vb, false)\n }\n // trailing gerund/future/present are okay, but 'walked and eats' is not\n if (obj.object && obj.object.found && obj.object.has('#PresentTense')) {\n let verbs = obj.object.verbs()\n verbs.if('#PresentTense').verbs().toPastTense()\n }\n })\n return this\n}\n\n/** he drives -> he has driven */\nexports.toParticiple = function () {\n this.forEach((doc) => {\n if (doc.has('has #Participle')) {\n return\n }\n let obj = parse(doc)\n let vb = obj.verb.clone()\n vb = vb.verbs().toParticiple()\n obj.verb.replaceWith(vb, false)\n // trailing gerund/future/present are okay, but 'walked and eats' is not\n if (obj.object && obj.object.found && obj.object.has('#PresentTense')) {\n let verbs = obj.object.verbs()\n verbs.if('#PresentTense').verbs().toParticiple()\n }\n })\n return this\n}\n\n/** he walked -> he walks */\nexports.toPresentTense = function () {\n this.forEach((doc) => {\n let obj = parse(doc)\n let isPlural = obj.verb.lookBehind('(i|we) (#Adverb|#Verb)?$').found\n let vb = obj.verb.clone()\n // 'i look', not 'i looks'\n if (isPlural) {\n //quick hack for copula verb - be/am\n if (vb.has('(is|was|am|be)')) {\n vb = vb.replace('will? (is|was|am|be)', 'am')\n } else {\n vb = vb.verbs().toInfinitive()\n }\n } else {\n //'he looks'\n vb = vb.verbs().toPresentTense()\n }\n obj.verb.replaceWith(vb, false)\n\n // future is okay, but 'walks and ate' -> 'walks and eats'\n if (obj.object && obj.object.found && obj.object.has('#PastTense')) {\n let verbs = obj.object.verbs()\n verbs.if('#PastTense').verbs().toPresentTense()\n }\n })\n return this\n}\n\n/**he walked -> he will walk */\nexports.toFutureTense = function () {\n this.forEach((doc) => {\n let obj = parse(doc)\n let vb = obj.verb.clone()\n vb = vb.verbs().toFutureTense()\n obj.verb.replaceWith(vb, false)\n //Present is okay, but 'will walk and ate' -> 'will walk and eat'\n if (obj.object && obj.object.found && obj.object.has('(#PastTense|#PresentTense)')) {\n let verbs = obj.object.verbs()\n verbs.if('(#PastTense|#PresentTense)').verbs().toInfinitive()\n }\n })\n return this\n}\n\n// toContinuous() {\n// return this\n// }\n","module.exports = Object.assign({}, require('./negate'), require('./types'), require('./tense'))\n","const parse = require('./parse')\nconst methods = require('./methods')\n\nconst addMethod = function (Doc) {\n /** */\n class Sentences extends Doc {\n constructor(list, from, world) {\n list = list.map((p) => p.clone(true))\n super(list, from, world)\n }\n\n /** overload the original json with noun information */\n json(options) {\n let n = null\n if (typeof options === 'number') {\n n = options\n options = null\n }\n options = options || { text: true, normal: true, trim: true, terms: true }\n let res = []\n this.forEach((doc) => {\n let json = doc.json(options)[0]\n let obj = parse(doc)\n json.subject = obj.subject.json(options)[0]\n json.verb = obj.verb.json(options)[0]\n json.object = obj.object.json(options)[0]\n res.push(json)\n })\n if (n !== null) {\n return res[n]\n }\n return res\n }\n\n /** the main noun of the sentence */\n subjects() {\n return this.map((doc) => {\n let res = parse(doc)\n return res.subject\n })\n }\n\n /** return sentences that are in passive-voice */\n isPassive() {\n return this.if('was #Adverb? #PastTense #Adverb? by') //haha\n }\n\n /** add a word to the start of this sentence */\n prepend(str) {\n this.forEach((doc) => {\n // repair the titlecase\n let firstTerms = doc.match('^.')\n firstTerms.not('#ProperNoun').toLowerCase()\n // actually add the word\n firstTerms.prepend(str)\n // add a titlecase\n firstTerms.terms(0).toTitleCase()\n })\n return this\n }\n\n /** add a word to the end of this sentence */\n append(str) {\n let hasEnd = /[.?!]\\s*$/.test(str)\n this.forEach((doc) => {\n let end = doc.match('.$')\n let lastTerm = end.termList(0)\n let punct = lastTerm.post\n if (hasEnd === true) {\n punct = ''\n }\n // add punctuation to the end\n end.append(str + punct)\n // remove punctuation from the former last-term\n lastTerm.post = ' '\n })\n return this\n }\n }\n // add some aliases\n methods.questions = methods.isQuestion\n methods.exclamations = methods.isExclamation\n methods.statements = methods.isStatement\n\n Object.assign(Sentences.prototype, methods)\n\n /** overload original sentences() method and return Sentence class**/\n Doc.prototype.sentences = function (n) {\n let arr = []\n this.list.forEach((p) => {\n arr.push(p.fullSentence())\n })\n //grab (n)th result\n let s = new Sentences(arr, this, this.world)\n if (typeof n === 'number') {\n s = s.get(n)\n }\n return s\n }\n return Doc\n}\nmodule.exports = addMethod\n"],"names":["subordinate","relative","mainClause","og","m","clone","length","ifNo","eq","parse","doc","clauses","main","nouns","match","verb","verbs","subject","object","lookAhead","forEach","obj","vb","toNegative","replaceWith","toPositive","isQuestion","endPunct","post","test","out","has","filter","d","term","lastTerm","termList","hasPost","useParticiple","toParticiple","toPastTense","found","isPlural","lookBehind","replace","toInfinitive","toPresentTense","toFutureTense","Object","assign","require$$0","require$$1","require$$2","addMethod","Doc","Sentences","list","from","world","map","p","options","n","text","normal","trim","terms","res","json","push","str","firstTerms","not","toLowerCase","prepend","toTitleCase","hasEnd","end","punct","append","methods","questions","exclamations","isExclamation","statements","isStatement","prototype","sentences","arr","fullSentence","s","get"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAAA;EACA,IAAMA,WAAW,0IAAjB;EACA,IAAMC,QAAQ,2DAAd;;EAGA,IAAMC,UAAU,GAAG,SAAbA,UAAa,CAASC,EAAT,EAAa;EAC9B,MAAIC,CAAC,GAAGD,EAAE,CAACE,KAAH,CAAS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BF,OAAO,CAACG,aAA/B;EACAH,EAAAA,OAAO,CAACI,UAAR,GAAqBJ,OAAO,CAACK,WAA7B;EAEArC,EAAAA,MAAM,CAACC,MAAP,CAAcM,SAAS,CAAC+B,SAAxB,EAAmCN,OAAnC;;;EAGA1B,EAAAA,GAAG,CAACgC,SAAJ,CAAcC,SAAd,GAA0B,UAAUzB,CAAV,EAAa;EACrC,QAAI0B,GAAG,GAAG,EAAV;EACA,SAAKhC,IAAL,CAAUpC,OAAV,CAAkB,UAACwC,CAAD,EAAO;EACvB4B,MAAAA,GAAG,CAACnB,IAAJ,CAAST,CAAC,CAAC6B,YAAF,EAAT;EACD,KAFD,EAFqC;;EAMrC,QAAIC,CAAC,GAAG,IAAInC,SAAJ,CAAciC,GAAd,EAAmB,IAAnB,EAAyB,KAAK9B,KAA9B,CAAR;;EACA,QAAI,OAAOI,CAAP,KAAa,QAAjB,EAA2B;EACzB4B,MAAAA,CAAC,GAAGA,CAAC,CAACC,GAAF,CAAM7B,CAAN,CAAJ;EACD;;EACD,WAAO4B,CAAP;EACD,GAXD;;EAYA,SAAOpC,GAAP;EACD,CAjGD;;EAkGA,OAAc,GAAGD,SAAjB;;;;;;;;"} \ No newline at end of file diff --git a/plugins/sentences/builds/compromise-sentences.min.js b/plugins/sentences/builds/compromise-sentences.min.js index 512cd09a5..38621cb25 100644 --- a/plugins/sentences/builds/compromise-sentences.min.js +++ b/plugins/sentences/builds/compromise-sentences.min.js @@ -1 +1 @@ -!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e=e||self).compromiseSentences=t()}(this,(function(){"use strict";function e(e,t){for(var n=0;n he walked */ + var toPastTense = function toPastTense() { this.forEach(function (doc) { if (doc.has('#PastTense')) { return; } + var obj = parse_1(doc); + var vb = obj.verb.clone(); // support 'he could drive' -> 'he could have driven' + + if (useParticiple(vb)) { + vb = vb.verbs().toParticiple(); + obj.verb.replaceWith(vb, false); + } else { + //do a normal conjugation + vb = vb.verbs().toPastTense(); + obj.verb.replaceWith(vb, false); + } // trailing gerund/future/present are okay, but 'walked and eats' is not + + + if (obj.object && obj.object.found && obj.object.has('#PresentTense')) { + var verbs = obj.object.verbs(); + verbs["if"]('#PresentTense').verbs().toPastTense(); + } + }); + return this; +}; +/** he drives -> he has driven */ + + +var toParticiple = function toParticiple() { + this.forEach(function (doc) { + if (doc.has('has #Participle')) { + return; + } + var obj = parse_1(doc); var vb = obj.verb.clone(); - vb = vb.verbs().toPastTense(); + vb = vb.verbs().toParticiple(); obj.verb.replaceWith(vb, false); // trailing gerund/future/present are okay, but 'walked and eats' is not if (obj.object && obj.object.found && obj.object.has('#PresentTense')) { var verbs = obj.object.verbs(); - verbs["if"]('#PresentTense').verbs().toPastTense(); + verbs["if"]('#PresentTense').verbs().toParticiple(); } }); return this; @@ -386,6 +423,7 @@ var toFutureTense = function toFutureTense() { var tense = { toPastTense: toPastTense, + toParticiple: toParticiple, toPresentTense: toPresentTense, toFutureTense: toFutureTense }; diff --git a/plugins/sentences/package.json b/plugins/sentences/package.json index c1f42dcd1..2177ef235 100644 --- a/plugins/sentences/package.json +++ b/plugins/sentences/package.json @@ -1,7 +1,7 @@ { "name": "compromise-sentences", "description": "plugin for nlp-compromise", - "version": "0.0.6", + "version": "0.1.0", "author": "Spencer Kelly (http://spencermounta.in)", "main": "./builds/compromise-sentences.js", "unpkg": "./builds/compromise-sentences.min.js", diff --git a/plugins/sentences/src/methods/tense.js b/plugins/sentences/src/methods/tense.js index abe9795b8..78373f8ef 100644 --- a/plugins/sentences/src/methods/tense.js +++ b/plugins/sentences/src/methods/tense.js @@ -1,30 +1,61 @@ const parse = require('../parse') +// 'i could drive' -> 'i could have driven' +const useParticiple = function (vb) { + if (vb.has('(could|should|would|may|can|must)')) { + return true + } + return false +} + /** he walks -> he walked */ -exports.toPastTense = function() { - this.forEach(doc => { +exports.toPastTense = function () { + this.forEach((doc) => { if (doc.has('#PastTense')) { return } let obj = parse(doc) let vb = obj.verb.clone() - vb = vb.verbs().toPastTense() + // support 'he could drive' -> 'he could have driven' + if (useParticiple(vb)) { + vb = vb.verbs().toParticiple() + obj.verb.replaceWith(vb, false) + } else { + //do a normal conjugation + vb = vb.verbs().toPastTense() + obj.verb.replaceWith(vb, false) + } + // trailing gerund/future/present are okay, but 'walked and eats' is not + if (obj.object && obj.object.found && obj.object.has('#PresentTense')) { + let verbs = obj.object.verbs() + verbs.if('#PresentTense').verbs().toPastTense() + } + }) + return this +} + +/** he drives -> he has driven */ +exports.toParticiple = function () { + this.forEach((doc) => { + if (doc.has('has #Participle')) { + return + } + let obj = parse(doc) + let vb = obj.verb.clone() + vb = vb.verbs().toParticiple() obj.verb.replaceWith(vb, false) // trailing gerund/future/present are okay, but 'walked and eats' is not if (obj.object && obj.object.found && obj.object.has('#PresentTense')) { let verbs = obj.object.verbs() - verbs - .if('#PresentTense') - .verbs() - .toPastTense() + verbs.if('#PresentTense').verbs().toParticiple() } }) return this } /** he walked -> he walks */ -exports.toPresentTense = function() { - this.forEach(doc => { +exports.toPresentTense = function () { + this.forEach((doc) => { let obj = parse(doc) let isPlural = obj.verb.lookBehind('(i|we) (#Adverb|#Verb)?$').found let vb = obj.verb.clone() @@ -45,18 +76,15 @@ exports.toPresentTense = function() { // future is okay, but 'walks and ate' -> 'walks and eats' if (obj.object && obj.object.found && obj.object.has('#PastTense')) { let verbs = obj.object.verbs() - verbs - .if('#PastTense') - .verbs() - .toPresentTense() + verbs.if('#PastTense').verbs().toPresentTense() } }) return this } /**he walked -> he will walk */ -exports.toFutureTense = function() { - this.forEach(doc => { +exports.toFutureTense = function () { + this.forEach((doc) => { let obj = parse(doc) let vb = obj.verb.clone() vb = vb.verbs().toFutureTense() @@ -64,10 +92,7 @@ exports.toFutureTense = function() { //Present is okay, but 'will walk and ate' -> 'will walk and eat' if (obj.object && obj.object.found && obj.object.has('(#PastTense|#PresentTense)')) { let verbs = obj.object.verbs() - verbs - .if('(#PastTense|#PresentTense)') - .verbs() - .toInfinitive() + verbs.if('(#PastTense|#PresentTense)').verbs().toInfinitive() } }) return this diff --git a/plugins/sentences/tests/participle.test.js b/plugins/sentences/tests/participle.test.js new file mode 100644 index 000000000..223b86def --- /dev/null +++ b/plugins/sentences/tests/participle.test.js @@ -0,0 +1,68 @@ +const test = require('tape') +const nlp = require('./_lib') + +test('toPast finds participle form', function (t) { + let doc = nlp('i drive') + doc.sentences().toPastTense() + t.equal(doc.text(), 'i drove', 'no modal') + + doc = nlp('i really drive') + doc.sentences().toPastTense() + t.equal(doc.text(), 'i really drove', 'adverb no modal') + + doc = nlp('i should drive') + doc.sentences().toPastTense() + t.equal(doc.text(), 'i should have driven', 'with should') + + doc = nlp('i really may drive') + doc.sentences().toPastTense() + t.equal(doc.text(), 'i really may have driven', 'with really may') + + doc = nlp('i could actually drive') + doc.sentences().toPastTense() + t.equal(doc.text(), 'i could have actually driven', 'with could actually') + + doc = nlp("i seriously couldn't drive") + doc.sentences().toPastTense() + t.equal(doc.text(), "i seriously couldn't have driven", 'with adverb + neg') + + // doc = nlp("i seriously couldn't even drive") + // doc.sentences().toPastTense() + // t.equal(doc.text(), "i seriously couldn't even have driven", 'with many modals') + + t.end() +}) + +test('toParticiple', function (t) { + let arr = [ + ['i drive', 'i have driven'], + ['we smoke', 'we have smoked'], + // ['i will go', 'i will have gone'], //hmm + ['they all swim', 'they all have swam'], + ['i learn', 'i have learned'], + ['i really travel to india', 'i really have traveled to india'], + ] + arr.forEach((a) => { + let doc = nlp(a[0]) + doc.sentences().toParticiple() + t.equal(doc.text(), a[1], a[0]) + }) + t.end() +}) + +test('modal-present-to-past', function (t) { + let arr = [ + ['he may drive', 'he may have driven'], + ['he should smoke', 'he should have smoked'], + ['i could go', 'i could have gone'], + ['nobody can swim', 'nobody could have swam'], + ['i must learn', 'i must have learned'], + ['i really may travel', 'i really may have traveled'], + ] + arr.forEach((a) => { + let doc = nlp(a[0]) + doc.sentences().toPastTense() + t.equal(doc.text(), a[1], a[0]) + }) + t.end() +}) diff --git a/plugins/sentences/tests/tense.test.js b/plugins/sentences/tests/tense.test.js index 55694c293..d1bcb9c5c 100644 --- a/plugins/sentences/tests/tense.test.js +++ b/plugins/sentences/tests/tense.test.js @@ -1,7 +1,7 @@ const test = require('tape') const nlp = require('./_lib') -test('sentence-change-tense:', function(t) { +test('sentence-change-tense:', function (t) { let arr = [ ['john walks quickly', 'john walked quickly', 'john will walk quickly'], ['he is quick', 'he was quick', 'he will be quick'], @@ -30,7 +30,7 @@ test('sentence-change-tense:', function(t) { //support negative // ['this isn\'t one sentence. This doesn\'t make two now.', 'this was not one sentence. This didn\'t make two now.', 'this won\'t be one sentence. This won\'t make two now.'] ] - arr.forEach(function(a) { + arr.forEach(function (a) { let r = nlp(a[0]).sentences() r.toPastTense() @@ -48,7 +48,7 @@ test('sentence-change-tense:', function(t) { t.end() }) -test('copula-form', function(t) { +test('copula-form', function (t) { let m = nlp('john is nice').sentences() m.toPastTense() @@ -77,7 +77,7 @@ test('copula-form', function(t) { }) // -test('conjugate-form', function(t) { +test('conjugate-form', function (t) { let m = nlp('john walks quickly').sentences() m.toPastTense() @@ -105,7 +105,7 @@ test('conjugate-form', function(t) { t.end() }) -test('particle-form', function(t) { +test('particle-form', function (t) { let m = nlp('the stool falls over').sentences() m.toPastTense() @@ -133,145 +133,91 @@ test('particle-form', function(t) { t.end() }) -test('contraction-cases', function(t) { +test('contraction past-tense', function (t) { let arr = [ [`I'm going to the shops`, `I went to the shops`], [`I'll go to the shops`, `I went to the shops`], - ] - arr.forEach(a => { - let str = nlp(a[0]) - .sentences() - .toPastTense() - .out() - t.equal(str, a[1], 'past-tense ' + a.join(' - ')) - }) - arr = [ [`We're looking`, `We looked`], [`We'll look`, `We looked`], [`We are looking`, `We looked`], ] - arr.forEach(a => { - let str = nlp(a[0]) - .sentences() - .toPastTense() - .out() + arr.forEach((a) => { + let str = nlp(a[0]).sentences().toPastTense().out() t.equal(str, a[1], 'past-tense ' + a.join(' - ')) }) - arr = [ + t.end() +}) + +test('contraction future-tense', function (t) { + let arr = [ [`I'm going to the shops`, `I will go to the shops`], [`I'll go to the shops`, `I will go to the shops`], ] - arr.forEach(a => { - let str = nlp(a[0]) - .sentences() - .toFutureTense() - .out() + arr.forEach((a) => { + let str = nlp(a[0]).sentences().toFutureTense().out() t.equal(str, a[1], 'future-tense ' + a.join(' - ')) }) - arr = [ - [`I'm going to the shops`, `I go to the shops`], + t.end() +}) + +test('contraction present-tense', function (t) { + let arr = [ + [`I'm going to the shops`, `I am going to the shops`], + [`I'm looking for a bug`, `I am looking for a bug`], [`I'll go to the shops`, `I go to the shops`], - ] - arr.forEach(a => { - let str = nlp(a[0]) - .sentences() - .toPresentTense() - .out() - t.equal(str, a[1], 'present-tense ' + a.join(' - ')) - }) - arr = [ - [`I'm looking for a bug`, `I look for a bug`], [`I'll look for a bug`, `I look for a bug`], ] - arr.forEach(a => { - let str = nlp(a[0]) - .sentences() - .toPresentTense() - .out() + arr.forEach((a) => { + let str = nlp(a[0]).sentences().toPresentTense().out() t.equal(str, a[1], 'present-tense ' + a.join(' - ')) }) - // let str = nlp('I’m lookin’ for Amanda Hugginkiss') - // .sentences() - // .toPastTense() - // .out() - // t.equal(str, 'i looked for Amanda Hugginkiss', 'present-tense slang') t.end() }) -test('pronoun-specific', function(t) { +test('pronoun-specific', function (t) { //from present - let m = nlp('i am cool') - .sentences() - .toPresentTense() + let m = nlp('i am cool').sentences().toPresentTense() t.equal(m.out(), 'i am cool', 'toPresent-I') - m = nlp('i am cool') - .sentences() - .toPastTense() + m = nlp('i am cool').sentences().toPastTense() t.equal(m.out(), 'i was cool', 'toPastTense-I') - m = nlp('i am cool') - .sentences() - .toFutureTense() + m = nlp('i am cool').sentences().toFutureTense() t.equal(m.out(), 'i will be cool', 'toFutureTense-I') //from future - m = nlp('i will be cool') - .sentences() - .toFutureTense() + m = nlp('i will be cool').sentences().toFutureTense() t.equal(m.out(), 'i will be cool', 'toFutureTense-I-2') - m = nlp('i will be cool') - .sentences() - .toPastTense() + m = nlp('i will be cool').sentences().toPastTense() t.equal(m.out(), 'i was cool', 'toPastTense-I-2') - m = nlp('i will be cool') - .sentences() - .toPresentTense() + m = nlp('i will be cool').sentences().toPresentTense() t.equal(m.out(), 'i am cool', 'toPresentTense-I-2') //from past - m = nlp('i was cool') - .sentences() - .toPresentTense() + m = nlp('i was cool').sentences().toPresentTense() t.equal(m.out(), 'i am cool', 'toPresentTense-I-3') - m = nlp('i was cool') - .sentences() - .toPastTense() + m = nlp('i was cool').sentences().toPastTense() t.equal(m.out(), 'i was cool', 'toPastTense-I-3') - m = nlp('i was cool') - .sentences() - .toFutureTense() + m = nlp('i was cool').sentences().toFutureTense() t.equal(m.out(), 'i will be cool', 'toFutureTense-I-3') //with negative - m = nlp('i was not cool') - .sentences() - .toPresentTense() + m = nlp('i was not cool').sentences().toPresentTense() t.equal(m.out(), 'i am not cool', 'neg-1') - m = nlp("i wasn't cool") - .sentences() - .toPastTense() + m = nlp("i wasn't cool").sentences().toPastTense() t.equal(m.out(), "i wasn't cool", 'neg-2') - m = nlp('i was not cool') - .sentences() - .toFutureTense() + m = nlp('i was not cool').sentences().toFutureTense() t.equal(m.out(), 'i will not be cool', 'neg-3') //with adverbs - m = nlp('i was really cool') - .sentences() - .toPresentTense() + m = nlp('i was really cool').sentences().toPresentTense() t.equal(m.out(), 'i am really cool', 'toPresentTense-I-3') - m = nlp('i was really cool') - .sentences() - .toPastTense() + m = nlp('i was really cool').sentences().toPastTense() t.equal(m.out(), 'i was really cool', 'toPastTense-I-3') - m = nlp('i was really cool') - .sentences() - .toFutureTense() + m = nlp('i was really cool').sentences().toFutureTense() t.equal(m.out(), 'i will be really cool', 'toFutureTense-I-3') t.end() }) -test('tense-multiple', function(t) { +test('tense-multiple', function (t) { let doc = nlp(`he walks down the street and smells the flowers.`) doc.sentences().toPastTense() t.equal(doc.text(), 'he walked down the street and smelled the flowers.', 'to-past') diff --git a/scratch.js b/scratch.js index 7a18bb879..ed2c174f0 100644 --- a/scratch.js +++ b/scratch.js @@ -1,16 +1,22 @@ const nlp = require('./src/index') +const spacetime = require('/Users/spencer/mountain/spacetime/src') // nlp.verbose(true) // let txt = require('./scripts/test/speed/_sotu-text.js') nlp.extend(require('./plugins/numbers/src')) nlp.extend(require('./plugins/dates/src')) +// nlp.extend(require('./plugins/sentences/src')) -// // let doc = nlp('i am being driven') -// let doc = nlp('i should be driven') -// let doc = nlp('i should drive') -// let doc = nlp('i should drive') -// let doc = nlp('i should have been driven') -// doc.sentences().toFutureTense().debug() -// doc.sentences().toPastTense().debug() +// let doc = nlp('april fools').debug() +// console.log(spacetime(dates.date.start).format('{day-short} {month-short} {date} {year}, {time}')) -// console.log(nlp('next week').dates().json()) -nlp('you are John, Lisa, Fred').match('#FirstName{1,2}').debug() +// let doc = nlp(`once a month`) +let doc = nlp(`March 1929`) + +// doc.debug() +let dates = doc.dates({ today: { year: 1999 } }).json(0) +console.log(dates) +if (dates.date.end) { + console.log(spacetime(dates.date.end).format('{day-short} {month-short} {date} {year}, {time}')) +} else { + console.log('--') +} diff --git a/src/02-tagger/01-init/data/startsWith.js b/src/02-tagger/01-init/data/startsWith.js index 34667b6aa..a4fec4701 100644 --- a/src/02-tagger/01-init/data/startsWith.js +++ b/src/02-tagger/01-init/data/startsWith.js @@ -17,6 +17,7 @@ module.exports = [ [/^[a-z0-9]*? o\'?clock$/, 'Time'], //3 oclock [/^[0-9]{1,4}-[0-9]{1,2}-[0-9]{1,4}$/, 'Date'], // 03-02-89 [/^[0-9]{1,4}\/[0-9]{1,2}\/[0-9]{1,4}$/, 'Date'], // 03/02/89 + [/^[0-9]{1,4}-[a-z]{2,9}-[0-9]{1,4}$/i, 'Date'], // 03-March-89 //names [/^ma?c\'.*/, 'LastName'], //mc'adams diff --git a/src/02-tagger/01-init/data/suffixMap.js b/src/02-tagger/01-init/data/suffixMap.js index 630ae79d7..76653353b 100644 --- a/src/02-tagger/01-init/data/suffixMap.js +++ b/src/02-tagger/01-init/data/suffixMap.js @@ -78,6 +78,7 @@ module.exports = [ gone: Adj, ices: Plrl, ints: Plrl, + ines: Plrl, ions: Plrl, less: Avb, llen: Adj, diff --git a/src/02-tagger/04-correction/matches/02-dates.js b/src/02-tagger/04-correction/matches/02-dates.js index c95dca563..dfc1aab4c 100644 --- a/src/02-tagger/04-correction/matches/02-dates.js +++ b/src/02-tagger/04-correction/matches/02-dates.js @@ -33,9 +33,9 @@ let list = [ // feb to march { match: `#Date .? [(march|may)]`, group: 0, tag: 'Month', reason: 'feb-and-march' }, //quickly march - { match: `#Adverb [(march|may)]`, group: 0, tag: 'Infinitive', reason: 'quickly-march' }, + { match: `#Adverb [(march|may)]`, group: 0, tag: 'Verb', reason: 'quickly-march' }, //march quickly - { match: `(march|may) [#Adverb]`, group: 0, tag: 'Infinitive', reason: 'march-quickly' }, + { match: `[(march|may)] #Adverb`, group: 0, tag: 'Verb', reason: 'march-quickly' }, //5th of March { match: '#Value of #Month', tag: 'Date', reason: 'value-of-month' }, diff --git a/src/02-tagger/04-correction/matches/03-noun.js b/src/02-tagger/04-correction/matches/03-noun.js index bf40e2db6..c9bb967b9 100644 --- a/src/02-tagger/04-correction/matches/03-noun.js +++ b/src/02-tagger/04-correction/matches/03-noun.js @@ -17,9 +17,10 @@ module.exports = [ { match: '#Organization+ #Possessive', tag: 'Possessive', reason: 'org-possessive' }, //Los Angeles's fundraiser { match: '#Place+ #Possessive', tag: 'Possessive', reason: 'place-possessive' }, - + // assign all tasks + { match: '#Verb (all|every|each|most|some|no) [#PresentTense]', group: 0, tag: 'Noun', reason: 'all-presentTense' }, //big dreams, critical thinking - { match: '#Adjective [#PresentTense]', group: 0, tag: 'Noun', reason: 'adj-presentTense' }, + { match: '(#Adjective && !all) [#PresentTense]', group: 0, tag: 'Noun', reason: 'adj-presentTense' }, //his fine { match: '(his|her|its) [#Adjective]', group: 0, tag: 'Noun', reason: 'his-fine' }, //some pressing issues diff --git a/src/02-tagger/04-correction/matches/06-value.js b/src/02-tagger/04-correction/matches/06-value.js index 5ae77c825..82c123013 100644 --- a/src/02-tagger/04-correction/matches/06-value.js +++ b/src/02-tagger/04-correction/matches/06-value.js @@ -39,7 +39,7 @@ module.exports = [ }, //'a/an' can mean 1 - "a hour" { - match: '[(a|an)] (#Duration|hundred|thousand|million|billion|trillion)', + match: '!once [(a|an)] (#Duration|hundred|thousand|million|billion|trillion)', group: 0, tag: 'Value', reason: 'a-is-one', diff --git a/src/02-tagger/04-correction/matches/07-verbs.js b/src/02-tagger/04-correction/matches/07-verbs.js index 7771ca0c1..d7738f051 100644 --- a/src/02-tagger/04-correction/matches/07-verbs.js +++ b/src/02-tagger/04-correction/matches/07-verbs.js @@ -13,7 +13,7 @@ let list = [ //support a splattering of auxillaries before a verb { match: `[(has|had) (#Adverb|not)+?] #PastTense`, group: 0, tag: 'Auxiliary', reason: 'had-walked' }, //would walk - { match: `[(#Modal|did) (#Adverb|not)+?] #Verb`, group: 0, tag: 'Auxiliary', reason: 'modal-verb' }, + { match: `[#Adverb+? (#Modal|did)+ (#Adverb|not)+?] #Verb`, group: 0, tag: 'Auxiliary', reason: 'modal-verb' }, //would have had { match: `[#Modal (#Adverb|not)+? have (#Adverb|not)+? had (#Adverb|not)+?] #Verb`, @@ -34,8 +34,6 @@ let list = [ { match: `[#Copula (#Adverb|not)+?] (#Gerund|#PastTense)`, group: 0, tag: 'Auxiliary', reason: 'copula-walking' }, //support a splattering of auxillaries before a verb { match: `[(has|had) (#Adverb|not)+?] #PastTense`, group: 0, tag: 'Auxiliary', reason: 'had-walked' }, - //would walk - { match: `[(#Modal|did) (#Adverb|not)+?] #Verb`, group: 0, tag: 'Auxiliary', reason: 'modal-verb' }, // will walk { match: '[(do|does|will|have|had)] (not|#Adverb)? #Verb', group: 0, tag: 'Auxiliary', reason: 'have-had' }, // about to go @@ -58,7 +56,7 @@ let list = [ }, // was being driven - { match: '[being] #Participle', group: 0, tag: 'Auxiliary', reason: 'being-foo' }, + { match: '[(be|being|been)] #Participle', group: 0, tag: 'Auxiliary', reason: 'being-foo' }, // ==== Phrasal ==== //'foo-up' diff --git a/src/02-tagger/04-correction/matches/10-people.js b/src/02-tagger/04-correction/matches/10-people.js index c0837775e..9f44f31f8 100644 --- a/src/02-tagger/04-correction/matches/10-people.js +++ b/src/02-tagger/04-correction/matches/10-people.js @@ -83,7 +83,7 @@ let list = [ { match: `#Infinitive [${months}]`, group: 0, tag: 'Person', reason: 'infinitive-person' }, // may waits for { match: `[${months}] #PresentTense for`, group: 0, tag: 'Person', reason: 'ambig-active-for' }, - // may waits for + // may waits to { match: `[${months}] #PresentTense to`, group: 0, tag: 'Person', reason: 'ambig-active-to' }, // april will { match: `[${months}] #Modal`, group: 0, tag: 'Person', reason: 'ambig-modal' }, diff --git a/src/Doc/methods/01-utils.js b/src/Doc/methods/01-utils.js index 19726d731..3e1b4a261 100644 --- a/src/Doc/methods/01-utils.js +++ b/src/Doc/methods/01-utils.js @@ -1,10 +1,10 @@ /** return the root, first document */ -exports.all = function() { +exports.all = function () { return this.parents()[0] || this } /** return the previous result */ -exports.parent = function() { +exports.parent = function () { if (this.from) { return this.from } @@ -12,9 +12,9 @@ exports.parent = function() { } /** return a list of all previous results */ -exports.parents = function(n) { +exports.parents = function (n) { let arr = [] - const addParent = function(doc) { + const addParent = function (doc) { if (doc.from) { arr.push(doc.from) addParent(doc.from) @@ -29,14 +29,14 @@ exports.parents = function(n) { } /** deep-copy the document, so that no references remain */ -exports.clone = function(doShallow) { +exports.clone = function (doShallow) { let list = this.list.map(ts => ts.clone(doShallow)) let tmp = this.buildFrom(list) return tmp } /** how many seperate terms does the document have? */ -exports.wordCount = function() { +exports.wordCount = function () { return this.list.reduce((count, p) => { count += p.wordCount() return count diff --git a/src/Doc/methods/insert/02-insert.js b/src/Doc/methods/insert/02-insert.js index bfcf0aab3..4ed3007d4 100644 --- a/src/Doc/methods/insert/02-insert.js +++ b/src/Doc/methods/insert/02-insert.js @@ -1,10 +1,23 @@ const tokenize = require('../../../01-tokenizer') +// if it's empty, just create the phrase +const makeNew = function (str, doc) { + let phrase = tokenize(str, doc.world)[0] //assume it's one sentence, for now + let tmpDoc = doc.buildFrom([phrase]) + tmpDoc.tagger() + doc.list = tmpDoc.list + return doc +} + /** add these new terms to the end*/ -exports.append = function(str) { +exports.append = function (str) { if (!str) { return this } + // if it's empty, just create the phrase + if (!this.found) { + return makeNew(str, this) + } // clear the cache this.uncache() //add it to end of every phrase @@ -23,10 +36,14 @@ exports.insertAfter = exports.append exports.insertAt = exports.append /** add these new terms to the front*/ -exports.prepend = function(str) { +exports.prepend = function (str) { if (!str) { return this } + // if it's empty, just create the phrase + if (!this.found) { + return makeNew(str, this) + } // clear the cache this.uncache() //add it to start of every phrase @@ -44,7 +61,7 @@ exports.prepend = function(str) { exports.insertBefore = exports.prepend /** add these new things to the end*/ -exports.concat = function() { +exports.concat = function () { // clear the cache this.uncache() let list = this.list.slice(0) @@ -66,7 +83,7 @@ exports.concat = function() { } /** fully remove these terms from the document */ -exports.delete = function(match) { +exports.delete = function (match) { // clear the cache this.uncache() let toRemove = this diff --git a/src/Phrase/methods/01-utils.js b/src/Phrase/methods/01-utils.js index 942d5f49b..dd72d9f4a 100644 --- a/src/Phrase/methods/01-utils.js +++ b/src/Phrase/methods/01-utils.js @@ -1,5 +1,5 @@ /** return a flat array of Term objects */ -exports.terms = function(n) { +exports.terms = function (n) { if (this.length === 0) { return [] } @@ -35,7 +35,7 @@ exports.terms = function(n) { } /** return a shallow or deep copy of this phrase */ -exports.clone = function(isShallow) { +exports.clone = function (isShallow) { if (isShallow) { let p = this.buildFrom(this.start, this.length) p.cache = this.cache @@ -44,6 +44,7 @@ exports.clone = function(isShallow) { //how do we clone part of the pool? let terms = this.terms() let newTerms = terms.map(t => t.clone()) + // console.log(newTerms) //connect these new ids up newTerms.forEach((t, i) => { //add it to the pool.. @@ -59,13 +60,13 @@ exports.clone = function(isShallow) { } /** return last term object */ -exports.lastTerm = function() { +exports.lastTerm = function () { let terms = this.terms() return terms[terms.length - 1] } /** quick lookup for a term id */ -exports.hasId = function(wantId) { +exports.hasId = function (wantId) { if (this.length === 0 || !wantId) { return false } @@ -100,12 +101,12 @@ exports.hasId = function(wantId) { } /** how many seperate, non-empty words is it? */ -exports.wordCount = function() { +exports.wordCount = function () { return this.terms().filter(t => t.text !== '').length } /** get the full-sentence this phrase belongs to */ -exports.fullSentence = function() { +exports.fullSentence = function () { let t = this.terms(0) //find first term in sentence while (t.prev) { diff --git a/src/Subset/Verbs/conjugate/doModal.js b/src/Subset/Verbs/conjugate/doModal.js new file mode 100644 index 000000000..3d6b61316 --- /dev/null +++ b/src/Subset/Verbs/conjugate/doModal.js @@ -0,0 +1,16 @@ +// 'may/could/should' -> 'may/could/should have' +const doModal = function (parsed) { + let str = parsed.verb.text() + let res = { + PastTense: str + ' have', + PresentTense: str, + FutureTense: str, + Infinitive: str, + // Gerund: , + // Actor: '', + // PerfectTense: '', + // Pluperfect: '', + } + return res +} +module.exports = doModal diff --git a/src/Subset/Verbs/conjugate/index.js b/src/Subset/Verbs/conjugate/index.js index 5a72be1a5..73a6accb9 100644 --- a/src/Subset/Verbs/conjugate/index.js +++ b/src/Subset/Verbs/conjugate/index.js @@ -1,5 +1,6 @@ const toInfinitive = require('../toInfinitive') const toBe = require('./toBe') +const doModal = require('./doModal') const conjugate = function (parsed, world) { let verb = parsed.verb @@ -9,6 +10,11 @@ const conjugate = function (parsed, world) { return toBe(parsed, world) } + // special handling of 'he could.' + if (verb.has('#Modal')) { + return doModal(parsed, world) + } + let hasHyphen = parsed.verb.termList(0).hasHyphen() let infinitive = toInfinitive(parsed, world) @@ -25,15 +31,15 @@ const conjugate = function (parsed, world) { Object.keys(forms).forEach(k => (forms[k] += space + particle)) } //put the adverb at the end? - if (parsed.adverb.found) { - let adverb = parsed.adverb.text() - let space = hasHyphen === true ? '-' : ' ' - if (parsed.adverbAfter === true) { - Object.keys(forms).forEach(k => (forms[k] += space + adverb)) - } else { - Object.keys(forms).forEach(k => (forms[k] = adverb + space + forms[k])) - } - } + // if (parsed.adverb.found) { + // let adverb = parsed.adverb.text() + // let space = hasHyphen === true ? '-' : ' ' + // if (parsed.adverbAfter === true) { + // Object.keys(forms).forEach(k => (forms[k] += space + adverb)) + // } else { + // Object.keys(forms).forEach(k => (forms[k] = adverb + space + forms[k])) + // } + // } //apply negative const isNegative = parsed.negative.found diff --git a/src/Subset/Verbs/methods.js b/src/Subset/Verbs/methods.js index 9707147c9..ddf0c3caf 100644 --- a/src/Subset/Verbs/methods.js +++ b/src/Subset/Verbs/methods.js @@ -2,10 +2,23 @@ const toNegative = require('./toNegative') const parseVerb = require('./parse') const isPlural = require('./isPlural') const conjugate = require('./conjugate') +const { toParticiple, useParticiple } = require('./participle') + +// remove any tense-information in auxiliary verbs +const makeNeutral = function (parsed) { + //remove tense-info from auxiliaries + parsed.auxiliary.remove('(will|are|am|being)') + parsed.auxiliary.remove('(did|does)') + parsed.auxiliary.remove('(had|has|have)') + //our conjugation includes the 'not' and the phrasal-verb particle + parsed.particle.remove() + parsed.negative.remove() + return parsed +} module.exports = { /** overload the original json with verb information */ - json: function(options) { + json: function (options) { let n = null if (typeof options === 'number') { n = options @@ -35,7 +48,7 @@ module.exports = { }, /** grab the adverbs describing these verbs */ - adverbs: function() { + adverbs: function () { let list = [] // look at internal adverbs this.forEach(vb => { @@ -56,8 +69,10 @@ module.exports = { } return this.buildFrom(list) }, + + /// Verb Inflection /**return verbs like 'we walk' and not 'spencer walks' */ - isPlural: function() { + isPlural: function () { let list = [] this.forEach(vb => { let parsed = parseVerb(vb) @@ -68,7 +83,7 @@ module.exports = { return this.buildFrom(list) }, /** return verbs like 'spencer walks' and not 'we walk' */ - isSingular: function() { + isSingular: function () { let list = [] this.forEach(vb => { let parsed = parseVerb(vb) @@ -79,8 +94,9 @@ module.exports = { return this.buildFrom(list) }, - /** */ - conjugate: function() { + /// Conjugation + /** return all forms of this verb */ + conjugate: function () { let result = [] this.forEach(vb => { let parsed = parseVerb(vb) @@ -89,22 +105,29 @@ module.exports = { }) return result }, - /** */ - toPastTense: function() { + /** walk ➔ walked*/ + toPastTense: function () { this.forEach(vb => { let parsed = parseVerb(vb) + // should we support 'would swim' ➔ 'would have swam' + if (useParticiple(parsed)) { + toParticiple(parsed, this.world) + return + } let str = conjugate(parsed, this.world).PastTense if (str) { - vb.replaceWith(str, false) + parsed = makeNeutral(parsed) + parsed.verb.replaceWith(str, false) // vb.tag('PastTense') } }) return this }, - /** */ - toPresentTense: function() { + /** walk ➔ walks */ + toPresentTense: function () { this.forEach(vb => { let parsed = parseVerb(vb) + let obj = conjugate(parsed, this.world) let str = obj.PresentTense // 'i look', not 'i looks' @@ -112,26 +135,45 @@ module.exports = { str = obj.Infinitive } if (str) { - vb.replaceWith(str, false) - vb.tag('PresentTense') + //awkward support for present-participle form + // -- should we support 'have been swimming' ➔ 'am swimming' + if (parsed.auxiliary.has('(have|had) been')) { + parsed.auxiliary.replace('(have|had) been', 'am being') + if (obj.Particle) { + str = obj.Particle || obj.PastTense + } + return + } + parsed.verb.replaceWith(str, false) + parsed.verb.tag('PresentTense') + parsed = makeNeutral(parsed) + // avoid 'he would walks' + parsed.auxiliary.remove('#Modal') } }) return this }, - /** */ - toFutureTense: function() { + /** walk ➔ will walk*/ + toFutureTense: function () { this.forEach(vb => { let parsed = parseVerb(vb) + // 'i should drive' is already future-enough + if (useParticiple(parsed)) { + return + } let str = conjugate(parsed, this.world).FutureTense if (str) { - vb.replaceWith(str, false) - vb.tag('FutureTense') + parsed = makeNeutral(parsed) + // avoid 'he would will go' + parsed.auxiliary.remove('#Modal') + parsed.verb.replaceWith(str, false) + parsed.verb.tag('FutureTense') } }) return this }, - /** */ - toInfinitive: function() { + /** walks ➔ walk */ + toInfinitive: function () { this.forEach(vb => { let parsed = parseVerb(vb) let str = conjugate(parsed, this.world).Infinitive @@ -142,8 +184,8 @@ module.exports = { }) return this }, - /** */ - toGerund: function() { + /** walk ➔ walking */ + toGerund: function () { this.forEach(vb => { let parsed = parseVerb(vb) let str = conjugate(parsed, this.world).Gerund @@ -154,17 +196,32 @@ module.exports = { }) return this }, + /** drive ➔ driven - naked past-participle if it exists, otherwise past-tense */ + toParticiple: function () { + this.forEach(vb => { + let parsed = parseVerb(vb) + let noAux = !parsed.auxiliary.found + toParticiple(parsed, this.world) + // dirty trick to ensure our new auxiliary is found + if (noAux) { + parsed.verb.prepend(parsed.auxiliary.text()) + parsed.auxiliary.remove() + } + }) + return this + }, + /// Negation /** return only verbs with 'not'*/ - isNegative: function() { + isNegative: function () { return this.if('#Negative') }, /** return only verbs without 'not'*/ - isPositive: function() { + isPositive: function () { return this.ifNo('#Negative') }, /** add a 'not' to these verbs */ - toNegative: function() { + toNegative: function () { this.list.forEach(p => { let doc = this.buildFrom([p]) let parsed = parseVerb(doc) @@ -173,7 +230,7 @@ module.exports = { return this }, /** remove 'not' from these verbs */ - toPositive: function() { + toPositive: function () { let m = this.match('do not #Verb') if (m.found) { m.remove('do not') diff --git a/src/Subset/Verbs/parse.js b/src/Subset/Verbs/parse.js index cbedc1c50..7e1c9e462 100644 --- a/src/Subset/Verbs/parse.js +++ b/src/Subset/Verbs/parse.js @@ -3,9 +3,9 @@ const parseVerb = function (vb) { let parsed = { adverb: vb.match('#Adverb+'), // 'really' negative: vb.match('#Negative'), // 'not' - auxiliary: vb.match('#Auxiliary').not('(#Negative|#Adverb)'), // 'will' of 'will go' + auxiliary: vb.match('#Auxiliary+').not('(#Negative|#Adverb)'), // 'will' of 'will go' particle: vb.match('#Particle'), // 'up' of 'pull up' - verb: vb.match('#Verb').not('(#Adverb|#Negative|#Auxiliary|#Particle)'), + verb: vb.match('#Verb+').not('(#Adverb|#Negative|#Auxiliary|#Particle)'), } // fallback, if no verb found if (!parsed.verb.found) { diff --git a/src/Subset/Verbs/participle.js b/src/Subset/Verbs/participle.js new file mode 100644 index 000000000..9ae1b1c9c --- /dev/null +++ b/src/Subset/Verbs/participle.js @@ -0,0 +1,56 @@ +const conjugate = require('./conjugate') + +// 'i could drive' -> 'i could have driven' +// if something is 'modal-ish' we are forced to use past-participle +// ('i could drove' is wrong) +const useParticiple = function (parsed) { + if (parsed.auxiliary.has('(could|should|would|may|can|must)')) { + return true + } + if (parsed.auxiliary.has('am .+? being')) { + return true + } + if (parsed.auxiliary.has('had .+? been')) { + return true + } + return false +} + +// conjugate 'drive' ➔ 'have driven' +const toParticiple = function (parsed, world) { + //is it already a participle? + if (parsed.auxiliary.has('(have|had)') && parsed.verb.has('#Participle')) { + return + } + // try to swap the main verb to its participle form + let obj = conjugate(parsed, world) + let str = obj.Participle || obj.PastTense + if (str) { + parsed.verb.replaceWith(str, false) + } + // 'am being driven' ➔ 'have been driven' + if (parsed.auxiliary.has('am .+? being')) { + parsed.auxiliary.remove('am') + parsed.auxiliary.replace('being', 'have been') + } + + // add a 'have' + if (!parsed.auxiliary.has('have')) { + parsed.auxiliary.append('have') + } + // tag it as a participle + parsed.verb.tag('Participle', 'toParticiple') + // turn 'i can swim' to -> 'i could swim' + parsed.auxiliary.replace('can', 'could') + //'must be' ➔ 'must have been' + parsed.auxiliary.replace('be have', 'have been') + //'not have' ➔ 'have not' + parsed.auxiliary.replace('not have', 'have not') + // ensure all new words are tagged right + parsed.auxiliary.tag('Auxiliary') +} + +module.exports = { + useParticiple: useParticiple, + toParticiple: toParticiple, +} diff --git a/src/Subset/Verbs/toNegative.js b/src/Subset/Verbs/toNegative.js index e9603e941..8442b868a 100644 --- a/src/Subset/Verbs/toNegative.js +++ b/src/Subset/Verbs/toNegative.js @@ -7,7 +7,7 @@ const isPlural = require('./isPlural') // #Gerund : walking: -> not walking // #Infinitive : walk -> do not walk -const toNegative = function(parsed, world) { +const toNegative = function (parsed, world) { let vb = parsed.verb // if it's already negative... if (parsed.negative.found) { @@ -17,6 +17,10 @@ const toNegative = function(parsed, world) { // would walk -> would not walk if (parsed.auxiliary.found) { parsed.auxiliary.eq(0).append('not') + // 'would not have' ➔ 'would not have' + if (parsed.auxiliary.has('#Modal have not')) { + parsed.auxiliary.replace('have not', 'not have') + } return } // is walking -> is not walking diff --git a/src/Term/Term.js b/src/Term/Term.js index fb906361a..50c5c9611 100644 --- a/src/Term/Term.js +++ b/src/Term/Term.js @@ -37,10 +37,14 @@ class Term { } /** create a deep-copy of this term */ -Term.prototype.clone = function() { +Term.prototype.clone = function () { let term = new Term(this.text) term.pre = this.pre term.post = this.post + term.clean = this.clean + term.reduced = this.reduced + term.root = this.root + term.implicit = this.implicit term.tags = Object.assign({}, this.tags) //use the old id, so it can be matched with .match(doc) // term.id = this.id diff --git a/src/World/_data.js b/src/World/_data.js index ae2cd5bf3..f92fbd51f 100644 --- a/src/World/_data.js +++ b/src/World/_data.js @@ -6,14 +6,14 @@ module.exports={ "Noun": "true¦a5b4c2f1here,ie,lit,m0no doubt,pd,tce;a,d;t,y;a,ca,o0;l,rp;a,l;d,l,rc", "Copula": "true¦a1is,w0;as,ere;m,re", "PastTense": "true¦be3came,d2had,lied,meant,sa2taken,w0;as,e0;nt,re;id;en,gan", - "Condition": "true¦if,unless", + "Condition": "true¦if,lest,unless", "Gerund": "true¦accord0be0develop0go0result0stain0;ing", "Negative": "true¦n0;ever,o0;!n,t", "QuestionWord": "true¦how3wh0;at,e1ich,o0y;!m,se;n,re; come,'s", "Plural": "true¦records", "Conjunction": "true¦&,aEbAcuz,how8in caDno7o6p4supposing,t1vers5wh0yet;eth8ile;h0o;eref9o0;!uC;l0rovided that;us;r,therwi6; matt1r;!ev0;er;e0ut;cau1f0;ore;se;lthou1nd,s 0;far as,if;gh", "Pronoun": "true¦'em,elle,h4i3me,ourselves,she5th1us,we,you0;!rself;e0ou;m,y;!l,t;e0im;!'s", - "Singular": "true¦0:0X;1:10;a0Wb0Kc0Bd04e02fXgShOici1jel0kitty,lNmJnIoHpDquestion mark,rBs7t4u2womW;nc0Rs 2;doll0Dst0F; rex,a3h2ic,ragedy,v show;ere,i1;l0x return;ist0Pky,omeone,t2uper bowl,yst0W;ep3ri1u2;de0Pff;faMmoM;al0i1o2;om,se;a4i0Jl05r3u2;dLrpoD;erogaVobl0O;rt,te0I;bjSceGthers;othi1umb0E;a4ee04o2;del,m2nopo0th0C;!my;n,yf0;i0unch;ead start,o2;l0me3u2;se;! run;adf0entlem5irlZlaci04od,rand3u2;l0y; slam,fa2mo2;th01;an;a5ella,ly,ol0r3un2;di1;iTo2;ntiWsN;mi0thV;conomy,gg,ner5veWx2;ampQecu7;ad7e4innSo2ragonf0ude;cumentFg2i0l0or;gy;ath,t2;ec2;tive;!dy;a8eili1h6i4o2redit card;ttage,u2;riJsin;ty,vil w2;ar;andeliGocol2;ate;n2rD;ary;aAel0lesHo6r4u2;n2tterf0;ti1;eakfast,o2;!th8;dy,tt4y2;!fri2;end;le;nki1r2;ri2;er;d4l0noma0u2;nt;ly; homin4verti2;si1;ng;em", + "Singular": "true¦0:0Z;1:12;a0Yb0Mc0Dd06e04fZgUhQiPjel0kitty,lOmKnJoIpEquestion mark,rCs7t4u2womY;nc0Ts 2;doll0Fst0H; rex,a3h2ic,ragedy,v show;ere,i1;l0x return;i5ky,omeone,t2uper bowl,yst0Y;ep3ri1u2;de0Rff;faOmoO;st0Nze;al0i1o2;om,se;a4i0Kl06r3u2;dMrpoE;erogaWobl0P;rt,te0J;bjTceHthers;othi1umb0F;a4ee05o2;del,m2nopo0th0D;!my;n,yf0;i0unch;ci1nsect;ead start,o2;l0me3u2;se;! run;adf0entlem5irlZlaci04od,rand3u2;l0y; slam,fa2mo2;th01;an;a5ella,ly,ol0r3un2;di1;iTo2;ntiWsN;mi0thV;conomy,gg,ner5veWx2;ampQecu7;ad7e4innSo2ragonf0ude;cumentFg2i0l0or;gy;ath,t2;ec2;tive;!dy;a8eili1h6i4o2redit card;ttage,u2;riJsin;ty,vil w2;ar;andeliGocol2;ate;n2rD;ary;aAel0lesHo6r4u2;n2tterf0;ti1;eakfast,o2;!th8;dy,tt4y2;!fri2;end;le;nki1r2;ri2;er;d4l0noma0u2;nt;ly; homin4verti2;si1;ng;em", "Actor": "true¦aJbGcFdCengineIfAgardenIh9instructPjournalLlawyIm8nurse,opeOp5r3s1t0;echnCherapK;ailNcientJoldiGu0;pervKrgeon;e0oofE;ceptionGsearC;hotographClumbColi1r0sychologF;actitionBogrammB;cem6t5;echanic,inist9us4;airdress8ousekeep8;arm7ire0;fight6m2;eputy,iet0;ici0;an;arpent2lerk;ricklay1ut0;ch0;er;ccoun6d2ge7r0ssis6ttenda7;chitect,t0;ist;minist1v0;is1;rat0;or;ta0;nt", "Honorific": "true¦a03b00cSdReQfiLgKhon,jr,king,lJmEoDp8queen,r4s0taoiseach,vice7;e1fc,gt,ir,r,u0;ltTpt,rg;c0nDrgeaL;ond liJretary;abbi,e0;ar1pAs,v0;!erend; admirY;astPhd,r0vt;esideEi1of0;!essN;me mini5nce0;!ss;fficOp,rd;a3essrs,i2lle,me,r1s0;!tr;!s;stK;gistrate,j,r6yF;i3lb,t;en,ov;eld mar3rst l0;ady,i0;eutena0;nt;shG;sq,xcellency;et,oct6r,utchess;apt6hance4mdr,o0pl;lonel,m2ngress0unci3;m0wom0;an;dr,mand5;ll0;or;!ain;ldg,rig0;!adi0;er;d0sst,tty,yatullah;j,m0v;!ir0;al", "SportsTeam": "true¦0:1A;1:1H;2:1G;a1Eb16c0Td0Kfc dallas,g0Ihouston 0Hindiana0Gjacksonville jagua0k0El0Bm01newToQpJqueens parkIreal salt lake,sAt5utah jazz,vancouver whitecaps,w3yW;ashington 3est ham0Rh10;natio1Oredski2wizar0W;ampa bay 6e5o3;ronto 3ttenham hotspur;blue ja0Mrapto0;nnessee tita2xasC;buccanee0ra0K;a7eattle 5heffield0Kporting kansas0Wt3;. louis 3oke0V;c1Frams;marine0s3;eah15ounG;cramento Rn 3;antonio spu0diego 3francisco gJjose earthquak1;char08paA; ran07;a8h5ittsburgh 4ortland t3;imbe0rail blaze0;pirat1steele0;il3oenix su2;adelphia 3li1;eagl1philNunE;dr1;akland 3klahoma city thunder,rlando magic;athle0Mrai3;de0; 3castle01;england 7orleans 6york 3;city fc,g4je0FknXme0Fred bul0Yy3;anke1;ian0D;pelica2sain0C;patrio0Brevolut3;ion;anchester Be9i3ontreal impact;ami 7lwaukee b6nnesota 3;t4u0Fvi3;kings;imberwolv1wi2;rewe0uc0K;dolphi2heat,marli2;mphis grizz3ts;li1;cXu08;a4eicesterVos angeles 3;clippe0dodDla9; galaxy,ke0;ansas city 3nE;chiefs,roya0E; pace0polis colU;astr06dynamo,rockeTtexa2;olden state warrio0reen bay pac3;ke0;.c.Aallas 7e3i05od5;nver 5troit 3;lio2pisto2ti3;ge0;broncZnuggeM;cowbo4maver3;ic00;ys; uQ;arCelKh8incinnati 6leveland 5ol3;orado r3umbus crew sc;api5ocki1;brow2cavalie0india2;bengaWre3;ds;arlotte horAicago 3;b4cubs,fire,wh3;iteB;ea0ulR;diff3olina panthe0; c3;ity;altimore 9lackburn rove0oston 5rooklyn 3uffalo bilN;ne3;ts;cel4red3; sox;tics;rs;oriol1rave2;rizona Ast8tlanta 3;brav1falco2h4u3;nited;aw9;ns;es;on villa,r3;os;c5di3;amondbac3;ks;ardi3;na3;ls", @@ -25,14 +25,14 @@ module.exports={ "Possessive": "true¦anyAh5its,m3noCo1sometBthe0yo1;ir1mselves;ur0;!s;i8y0;!se4;er1i0;mse2s;!s0;!e0;lf;o1t0;hing;ne", "Currency": "true¦$,aud,bScQdLeurKfJgbp,hkd,iIjpy,kGlEp8r7s3usd,x2y1z0¢,£,¥,ден,лв,руб,฿,₡,₨,€,₭,﷼;lotySł;en,uanR;af,of;h0t5;e0il5;k0q0;elM;iel,oubleLp,upeeL;e2ound st0;er0;lingI;n0soH;ceGn0;ies,y;e0i8;i,mpi7;n,r0wanzaCyatC;!onaBw;ls,nr;ori7ranc9;!o8;en3i2kk,o0;b0ll2;ra5;me4n0rham4;ar3;ad,e0ny;nt1;aht,itcoin0;!s", "City": "true¦a2Wb26c1Wd1Re1Qf1Og1Ih1Ai18jakar2Hk0Zl0Tm0Gn0Co0ApZquiYrVsLtCuBv8w3y1z0;agreb,uri1Z;ang1Te0okohama;katerin1Hrev34;ars3e2i0rocl3;ckl0Vn0;nipeg,terth0W;llingt1Oxford;aw;a1i0;en2Hlni2Z;lenc2Uncouv0Gr2G;lan bat0Dtrecht;a6bilisi,e5he4i3o2rondheim,u0;nVr0;in,ku;kyo,ronIulouC;anj23l13miso2Jra2A; haJssaloni0X;gucigalpa,hr2Ol av0L;i0llinn,mpe2Bngi07rtu;chu22n2MpT;a3e2h1kopje,t0ydney;ockholm,uttga12;angh1Fenzh1X;o0KvZ;int peters0Ul3n0ppo1F; 0ti1B;jo0salv2;se;v0z0Q;adU;eykjavik,i1o0;me,sario,t25;ga,o de janei17;to;a8e6h5i4o2r0ueb1Qyongya1N;a0etor24;gue;rt0zn24; elizabe3o;ls1Grae24;iladelph1Znom pe07oenix;r0tah tik19;th;lerJr0tr10;is;dessa,s0ttawa;a1Hlo;a2ew 0is;delTtaip0york;ei;goya,nt0Upl0Uv1R;a5e4i3o1u0;mb0Lni0I;nt0scH;evideo,real;l1Mn01skolc;dellín,lbour0S;drid,l5n3r0;ib1se0;ille;or;chest0dalWi0Z;er;mo;a4i1o0vAy01;nd00s angel0F;ege,ma0nz,sbZverpo1;!ss0;ol; pla0Iusan0F;a5hark4i3laipeda,o1rak0uala lump2;ow;be,pavog0sice;ur;ev,ng8;iv;b3mpa0Kndy,ohsiu0Hra0un03;c0j;hi;ncheMstanb0̇zmir;ul;a5e3o0; chi mi1ms,u0;stI;nh;lsin0rakliG;ki;ifa,m0noi,va0A;bu0SiltD;alw4dan3en2hent,iza,othen1raz,ua0;dalaj0Gngzhou;bu0P;eUoa;sk;ay;es,rankfu0;rt;dmont4indhovU;a1ha01oha,u0;blRrb0Eshanbe;e0kar,masc0FugavpiJ;gu,je0;on;a7ebu,h2o0raioJuriti01;lo0nstanJpenhagNrk;gFmbo;enn3i1ristchur0;ch;ang m1c0ttagoL;ago;ai;i0lgary,pe town,rac4;ro;aHeBirminghWogoAr5u0;char3dap3enos air2r0sZ;g0sa;as;es;est;a2isba1usse0;ls;ne;silPtisla0;va;ta;i3lgrade,r0;g1l0n;in;en;ji0rut;ng;ku,n3r0sel;celo1ranquil0;la;na;g1ja lu0;ka;alo0kok;re;aBb9hmedabad,l7m4n2qa1sh0thens,uckland;dod,gabat;ba;k0twerp;ara;m5s0;terd0;am;exandr0maty;ia;idj0u dhabi;an;lbo1rh0;us;rg", - "Abbreviation": "true¦a0Tb0Qc0Kd0Ie0Ff0Cg0Ah08i06j04k02l00mRnOoNpIqHrFs9t6u5v2w0yb,µg;is0r,y0L;!c;a,b,e1i0ol,s,t;tro,vo;r,t;niv,safa,t;b1ce,d,e0sp;l,mp,nn,x;!l,sp;ask,e3fc,gt,i2q1r,s,t,u0;pt,rg;! ft;r,tu;c,nVp0;!t;b,d,e0;pSs,v;t,ue;a,d,enn3hd,l,p,r1s0t,vt;!a,eud;ef,o0;b,f,n;!a;ct,kla,nt,p,rd,z;e0ov;b0e;!r;a7b,d,essrs,g,i4l3m2p1rHs0t;!tr;h,s;!e;!le;!n1s0;c,ter;!n;!j,r,sc;at,b,it,lb,m,ng,t0x;!d;an6b,g,m0;!ph;an,d,r,u0;l,n;a,da,e,n0;c,f;g,on,r0wy,z;!s;a0b,en,ov;!l;e1ig,l0m,r,t,y;! oz,a;b,m;a,g,ng,s1tc,x0;!p;p,q,t;ak,e0g,ist,l,m,r;c,f,pt,t;a3ca,g,l,m2o0pl,res,t,yn;!l0mdr,nn,rp;!o;!dr;!l0pt;!if;a,c,l1r0;ig,os;!dg,vd;d4l3p2r1ss0tty,ug,ve;n,t;c,iz;prox,r,t;!ta;!j,m,v", + "Abbreviation": "true¦a0Tb0Qc0Kd0Ie0Ff0Cg0Ah08i06j04k02l00mRnOoNpIqHrFs9t6u5v2w0yb,µg;is0r,y0L;!c;a,b,e1i0ol,s,t;tro,vo;r,t;niv,safa,t;b1ce,d,e0sp;l,mp,nn,x;!l,sp;ask,e3fc,gt,i2q1r,s,t,u0;pt,rg;! ft;r,tu;c,nVp0;!t;b,d,e0;pSs,v;t,ue;a,d,enn3hd,l,p,r1s0t,vt;!eud;ef,o0;b,f,n;!a;ct,kla,nt,p,rd,z;e0ov;b0e;!r;a7b,d,essrs,g,i4l3m2p1rHs0t;!tr;h,s;!e;!le;!n1s0;c,ter;!n;!j,r,sc;at,b,it,lb,m,ng,t0x;!d;an6b,g,m0;!ph;an,d,r,u0;l,n;a,da,e,n0;c,f;g,on,r0wy,z;!s;a0b,en,ov;!l;e1ig,l0m,r,t,y;! oz,a;b,m;a,g,ng,s1tc,x0;!p;p,q,t;ak,e0g,ist,l,m,r;c,f,pt,t;a3ca,g,l,m2o0pl,res,t,yn;!l0mdr,nn,rp;!o;!dr;!l0pt;!if;a,c,l1r0;ig,os;!dg,vd;d4l3p2r1ss0tty,ug,ve;n,t;c,iz;prox,r,t;!ta;!j,m,v", "Country": "true¦0:38;1:2L;a2Wb2Dc21d1Xe1Rf1Lg1Bh19i13j11k0Zl0Um0Gn05om3CpZqat1JrXsKtCu6v4wal3yemTz2;a24imbabwe;es,lis and futu2X;a2enezue31ietnam;nuatu,tican city;.5gTkraiZnited 3ruXs2zbeE;a,sr;arab emirat0Kkingdom,states2;! of am2X;k.,s.2; 27a.;a7haBimor-les0Bo6rinidad4u2;nis0rk2valu;ey,me2Xs and caic1T; and 2-2;toba1J;go,kel0Ynga;iw2Vji2nz2R;ki2T;aCcotl1eBi8lov7o5pa2Bri lanka,u4w2yr0;az2ed9itzerl1;il1;d2Qriname;lomon1Vmal0uth 2;afr2IkLsud2O;ak0en0;erra leoEn2;gapo1Wt maart2;en;negKrb0ychellY;int 2moa,n marino,udi arab0;hele24luc0mart1Z;epublic of ir0Com2Cuss0w2;an25;a3eHhilippinTitcairn1Ko2uerto riM;l1rtugE;ki2Bl3nama,pua new0Tra2;gu6;au,esti2;ne;aAe8i6or2;folk1Gth3w2;ay; k2ern mariana1B;or0M;caragua,ger2ue;!ia;p2ther18w zeal1;al;mib0u2;ru;a6exi5icro09o2yanm04;ldova,n2roc4zamb9;a3gol0t2;enegro,serrat;co;c9dagascZl6r4urit3yot2;te;an0i14;shall0Vtin2;ique;a3div2i,ta;es;wi,ys0;ao,ed00;a5e4i2uxembourg;b2echtenste10thu1E;er0ya;ban0Gsotho;os,tv0;azakh1De2iriba02osovo,uwait,yrgyz1D;eling0Jnya;a2erF;ma15p1B;c6nd5r3s2taly,vory coast;le of m19rael;a2el1;n,q;ia,oI;el1;aiSon2ungary;dur0Mg kong;aAermany,ha0Pibralt9re7u2;a5ern4inea2ya0O;!-biss2;au;sey;deloupe,m,tema0P;e2na0M;ce,nl1;ar;bTmb0;a6i5r2;ance,ench 2;guia0Dpoly2;nes0;ji,nl1;lklandTroeT;ast tim6cu5gypt,l salv5ngl1quatorial3ritr4st2thiop0;on0; guin2;ea;ad2;or;enmark,jibou4ominica3r con2;go;!n B;ti;aAentral african 9h7o4roat0u3yprQzech2; 8ia;ba,racao;c3lo2morPngo-brazzaville,okFsta r03te d'ivoiK;mb0;osD;i2ristmasF;le,na;republic;m2naTpe verde,yman9;bod0ero2;on;aFeChut00o8r4u2;lgar0r2;kina faso,ma,undi;azil,itish 2unei;virgin2; is2;lands;liv0nai4snia and herzegoviGtswaGuvet2; isl1;and;re;l2n7rmuF;ar2gium,ize;us;h3ngladesh,rbad2;os;am3ra2;in;as;fghaFlCmAn5r3ustr2zerbaijH;al0ia;genti2men0uba;na;dorra,g4t2;arct6igua and barbu2;da;o2uil2;la;er2;ica;b2ger0;an0;ia;ni2;st2;an", "Region": "true¦0:1U;a20b1Sc1Id1Des1Cf19g13h10i0Xj0Vk0Tl0Qm0FnZoXpSqPrMsDtAut9v6w3y1zacatec22;o05u1;cat18kZ;a1est vi4isconsin,yomi14;rwick0shington1;! dc;er2i1;rgin1S;acruz,mont;ah,tar pradesh;a2e1laxca1DuscaA;nnessee,x1R;bas0Kmaulip1QsmJ;a6i4o2taf0Ou1ylh13;ffVrr00s0Y;me10no1Auth 1;cSdR;ber1Ic1naloa;hu0Sily;n2skatchew0Rxo1;ny; luis potosi,ta catari1I;a1hode7;j1ngp02;asth0Mshahi;inghai,u1;e1intana roo;bec,ensWreta0E;ara4e2rince edward1; isU;i,nnsylv1rnambu02;an14;!na;axa0Ndisha,h1klaho1Bntar1reg4x04;io;ayarit,eBo3u1;evo le1nav0L;on;r1tt0Rva scot0X;f6mandy,th1; 1ampton0;c3d2yo1;rk0;ako0Y;aroli0V;olk;bras0Xva01w1; 2foundland1;! and labrador;brunswick,hamp0jers1mexiJyork state;ey;a6i2o1;nta0Nrelos;ch3dlanBn2ss1;issippi,ouri;as geraGneso0M;igQoacQ;dhya,harasht04ine,ni3r1ssachusetts;anhao,y1;land;p1toba;ur;anca0e1incoln0ouis8;e1iH;ds;a1entucky,hul0A;ns08rnata0Dshmir;alis1iangxi;co;daho,llino2nd1owa;ia05;is;a2ert1idalEunA;ford0;mp0waii;ansu,eorgWlou5u1;an2erre1izhou,jarat;ro;ajuato,gdo1;ng;cester0;lori2uji1;an;da;sex;e4o2uran1;go;rs1;et;lawaErby0;a8ea7hi6o1umbrH;ahui4l3nnectic2rsi1ventry;ca;ut;iMorado;la;apEhuahua;ra;l8m1;bridge0peche;a5r4uck1;ingham0;shi1;re;emen,itish columb3;h2ja cal1sque,var2;iforn1;ia;guascalientes,l4r1;izo2kans1;as;na;a2ber1;ta;ba2s1;ka;ma", "FemaleName": "true¦0:FY;1:G2;2:FR;3:FD;4:FC;5:FS;6:ER;7:EP;8:GF;9:EZ;A:GB;B:E5;C:G8;D:FO;E:FL;F:EG;aE2bD4cB8dAIe9Gf91g8Hh83i7Sj6Uk60l4Om38n2To2Qp2Fqu2Er1Os0Qt04ursu6vUwOyLzG;aJeHoG;e,la,ra;lGna;da,ma;da,ra;as7EeHol1TvG;et7onB9;le0sen3;an9endBNhiB4iG;lInG;if3AniGo0;e,f39;a,helmi0lGma;a,ow;aMeJiG;cHviG;an9XenG1;kCZtor3;da,l8Vnus,rG;a,nGoniD2;a,iDC;leGnesEC;nDLrG;i1y;aSePhNiMoJrGu6y4;acG3iGu0E;c3na,sG;h9Mta;nHrG;a,i;i9Jya;a5IffaCGna,s5;al3eGomasi0;a,l8Go6Xres1;g7Uo6WrHssG;!a,ie;eFi,ri8;bNliMmKnIrHs5tGwa0;ia0um;a,yn;iGya;a,ka,s5;a4e4iGmCAra;!ka;a,t5;at5it5;a05carlet2Ye04hUiSkye,oQtMuHyG;bFJlvi1;e,sHzG;an2Tet7ie,y;anGi8;!a,e,nG;aEe;aIeG;fGl3DphG;an2;cF8r6;f3nGphi1;d4ia,ja,ya;er4lv3mon1nGobh75;dy;aKeGirlBLo0y6;ba,e0i6lIrG;iGrBPyl;!d70;ia,lBV;ki4nIrHu0w0yG;la,na;i,leAon,ron;a,da,ia,nGon;a,on;l5Yre0;bMdLi9lKmIndHrGs5vannaE;aEi0;ra,y;aGi4;nt5ra;lBNome;e,ie;in1ri0;a02eXhViToHuG;by,thBK;bQcPlOnNsHwe0xG;an94ie,y;aHeGie,lC;ann8ll1marBFtB;!lGnn1;iGyn;e,nG;a,d7W;da,i,na;an9;hel53io;bin,erByn;a,cGkki,na,ta;helBZki;ea,iannDXoG;da,n12;an0bIgi0i0nGta,y0;aGee;!e,ta;a,eG;cARkaE;chGe,i0mo0n5EquCDvDy0;aCCelGi9;!e,le;een2ia0;aMeLhJoIrG;iGudenAW;scil1Uyamva9;lly,rt3;ilome0oebe,ylG;is,lis;arl,ggy,nelope,r6t4;ige,m0Fn4Oo6rvaBBtHulG;a,et7in1;ricGsy,tA8;a,e,ia;ctav3deHfAWlGphAW;a,ga,iv3;l3t7;aQePiJoGy6;eHrG;aEeDma;ll1mi;aKcIkGla,na,s5ta;iGki;!ta;hoB2k8BolG;a,eBH;!mh;l7Tna,risF;dIi5PnHo23taG;li1s5;cy,et7;eAiCO;a01ckenz2eViLoIrignayani,uriBGyG;a,rG;a,na,tAS;i4ll9XnG;a,iG;ca,ka,qB4;a,chOkaNlJmi,nIrGtzi;aGiam;!n9;a,dy,erva,h,n2;a,dIi9JlG;iGy;cent,e;red;!e6;ae6el3G;ag4KgKi,lHrG;edi61isFyl;an2iGliF;nGsAM;a,da;!an,han;b08c9Ed06e,g04i03l01nZrKtJuHv6Sx87yGz2;a,bell,ra;de,rG;a,eD;h75il9t2;a,cSgOiJjor2l6In2s5tIyG;!aGbe5QjaAlou;m,n9S;a,ha,i0;!aIbALeHja,lCna,sGt53;!a,ol,sa;!l06;!h,m,nG;!a,e,n1;arIeHie,oGr3Kueri7;!t;!ry;et3IiB;elGi61y;a,l1;dGon,ue6;akranBy;iGlo36;a,ka,n9;a,re,s2;daGg2;!l2W;alCd2elGge,isBGon0;eiAin1yn;el,le;a0Ie08iWoQuKyG;d3la,nG;!a,dHe9SnGsAQ;!a,e9R;a,sAO;aB1cJelIiFlHna,pGz;e,iB;a,u;a,la;iGy;a2Ae,l25n9;is,l1GrHtt2uG;el6is1;aIeHi8na,rG;a6Zi8;lei,n1tB;!in1;aQbPd3lLnIsHv3zG;!a,be4Ket7z2;a,et7;a,dG;a,sGy;ay,ey,i,y;a,iaIlG;iGy;a8Ge;!n4F;b7Terty;!n5R;aNda,e0iLla,nKoIslARtGx2;iGt2;c3t3;la,nGra;a,ie,o4;a,or1;a,gh,laG;!ni;!h,nG;a,d4e,n4N;cNdon7Si6kes5na,rMtKurIvHxGy6;mi;ern1in3;a,eGie,yn;l,n;as5is5oG;nya,ya;a,isF;ey,ie,y;aZeUhadija,iMoLrIyG;lGra;a,ee,ie;istGy5B;a,en,iGy;!e,n48;ri,urtn9A;aMerLl99mIrGzzy;a,stG;en,in;!berlG;eGi,y;e,y;a,stD;!na,ra;el6PiJlInHrG;a,i,ri;d4na;ey,i,l9Qs2y;ra,s5;c8Wi5XlOma6nyakumari,rMss5LtJviByG;!e,lG;a,eG;e,i78;a5EeHhGi3PlCri0y;ar5Cer5Cie,leDr9Fy;!lyn73;a,en,iGl4Uyn;!ma,n31sF;ei72i,l2;a04eVilToMuG;anKdJliGst56;aHeGsF;!nAt0W;!n8X;i2Ry;a,iB;!anLcelCd5Vel71han6IlJni,sHva0yG;a,ce;eGie;fi0lCph4X;eGie;en,n1;!a,e,n36;!i10lG;!i0Z;anLle0nIrHsG;i5Qsi5Q;i,ri;!a,el6Pif1RnG;a,et7iGy;!e,f1P;a,e72iHnG;a,e71iG;e,n1;cLd1mi,nHqueliAsmin2Uvie4yAzG;min8;a8eHiG;ce,e,n1s;!lGsFt06;e,le;inHk2lCquelG;in1yn;da,ta;lPmNnMo0rLsHvaG;!na;aHiGob6U;do4;!belGdo4;!a,e,l2G;en1i0ma;a,di4es,gr5R;el9ogG;en1;a,eAia0o0se;aNeKilHoGyacin1N;ll2rten1H;aHdGlaH;a,egard;ry;ath0WiHlGnrietBrmiAst0W;en24ga;di;il75lKnJrGtt2yl75z6D;iGmo4Fri4G;etG;!te;aEnaE;ey,l2;aYeTiOlMold12rIwG;enGyne18;!dolC;acHetGisel9;a,chD;e,ieG;!la;adys,enGor3yn1Y;a,da,na;aJgi,lHna,ov71selG;a,e,le;da,liG;an;!n0;mYnIorgHrG;ald35i,m2Stru73;et7i5T;a,eGna;s1Nvieve;briel3Fil,le,rnet,yle;aReOio0loMrG;anHe9iG;da,e9;!cG;esHiGoi0G;n1s3V;!ca;!rG;a,en43;lHrnG;!an9;ec3ic3;rHtiGy8;ma;ah,rah;d0FileDkBl00mUn4ArRsMtLuKvG;aIelHiG;e,ta;in0Ayn;!ngel2H;geni1la,ni3R;h52ta;meral9peranJtG;eHhGrel6;er;l2Pr;za;iGma,nest29yn;cGka,n;a,ka;eJilImG;aGie,y;!liA;ee,i1y;lGrald;da,y;aTeRiMlLma,no4oJsIvG;a,iG;na,ra;a,ie;iGuiG;se;a,en,ie,y;a0c3da,nJsGzaH;aGe;!beG;th;!a,or;anor,nG;!a;in1na;en,iGna,wi0;e,th;aWeKiJoGul2U;lor51miniq3Yn30rGtt2;a,eDis,la,othGthy;ea,y;an09naEonAx2;anPbOde,eNiLja,lImetr3nGsir4U;a,iG;ce,se;a,iHla,orGphiA;es,is;a,l5J;dGrdG;re;!d4Mna;!b2CoraEra;a,d4nG;!a,e;hl3i0mMnKphn1rHvi1WyG;le,na;a,by,cHia,lG;a,en1;ey,ie;a,et7iG;!ca,el1Aka;arGia;is;a0Qe0Mh04i02lUoJrHynG;di,th3;istGy04;al,i0;lOnLrHurG;tn1D;aId28iGn28riA;!nG;a,e,n1;!l1S;n2sG;tanGuelo;ce,za;eGleD;en,t7;aIeoHotG;il4B;!pat4;ir8rIudG;et7iG;a,ne;a,e,iG;ce,sX;a4er4ndG;i,y;aPeMloe,rG;isHyG;stal;sy,tG;aHen,iGy;!an1e,n1;!l;lseHrG;!i8yl;a,y;nLrG;isJlHmG;aiA;a,eGot7;n1t7;!sa;d4el1PtG;al,el1O;cHlG;es7i3F;el3ilG;e,ia,y;iYlXmilWndVrNsLtGy6;aJeIhGri0;erGleDrCy;in1;ri0;li0ri0;a2GsG;a2Fie;a,iMlKmeIolHrG;ie,ol;!e,in1yn;lGn;!a,la;a,eGie,y;ne,y;na,sF;a0Di0D;a,e,l1;isBl2;tlG;in,yn;arb0CeYianXlVoTrG;andRePiIoHyG;an0nn;nwCok8;an2NdgKg0ItG;n27tG;!aHnG;ey,i,y;ny;etG;!t8;an0e,nG;da,na;i8y;bbi8nG;iBn2;ancGossom,ythe;a,he;ca;aRcky,lin9niBrNssMtIulaEvG;!erlG;ey,y;hHsy,tG;e,i0Zy8;!anG;ie,y;!ie;nGt5yl;adHiG;ce;et7iA;!triG;ce,z;a4ie,ra;aliy29b24d1Lg1Hi19l0Sm0Nn01rWsNthe0uJvIyG;anGes5;a,na;a,r25;drIgusHrG;el3;ti0;a,ey,i,y;hHtrG;id;aKlGt1P;eHi8yG;!n;e,iGy;gh;!nG;ti;iIleHpiB;ta;en,n1t7;an19elG;le;aYdWeUgQiOja,nHtoGya;inet7n3;!aJeHiGmI;e,ka;!mGt7;ar2;!belHliFmT;sa;!le;ka,sGta;a,sa;elGie;a,iG;a,ca,n1qG;ue;!t7;te;je6rea;la;!bHmGstas3;ar3;el;aIberHel3iGy;e,na;!ly;l3n9;da;aTba,eNiKlIma,yG;a,c3sG;a,on,sa;iGys0J;e,s0I;a,cHna,sGza;a,ha,on,sa;e,ia;c3is5jaIna,ssaIxG;aGia;!nd4;nd4;ra;ia;i0nHyG;ah,na;a,is,naE;c5da,leDmLnslKsG;haElG;inGyW;g,n;!h;ey;ee;en;at5g2nG;es;ie;ha;aVdiSelLrG;eIiG;anLenG;a,e,ne;an0;na;aKeJiHyG;nn;a,n1;a,e;!ne;!iG;de;e,lCsG;on;yn;!lG;iAyn;ne;agaJbHiG;!gaI;ey,i8y;!e;il;ah", "Place": "true¦a07b05cZdYeXfVgRhQiOjfk,kMlKmHneEoDp9que,rd,s8t5u4v3w0yyz;is1y0;!o;!c;a,t;pYsafa,t;e1he 0;bronx,hamptons;nn,x;ask,fo,oho,t,under6yd;a2e1h0;l,x;k,nnK;!cifX;kla,nt;b1w eng0;land;!r;a1co,i0t,uc;dKnn;libu,nhattS;a0gw,hr;s,x;an0ul;!s;a0cn,da,ndianMst;!x;arlem,kg,nd,wy;a2re0;at 0enwich;britain,lak6;!y village;co,l0ra;!a;urope,verglad2;ak,en,fw,ist,own4xb;al4dg,gk,hina3l2o1r0t;es;lo,nn;!t;town;!if;cn,e0kk,lvd,rooklyn;l air,verly hills;frica,lta,m5ntarct2r1sia,tl0ve;!ant1;ct0iz;ic0; oce0;an;ericas,s", "WeekDay": "true¦fri2mon2s1t0wednesd3;hurs1ues1;aturd1und1;!d0;ay0;!s", "Month": "true¦aBdec9feb7j2mar,nov9oct1sep0;!t8;!o8;an3u0;l1n0;!e;!y;!u1;!ru0;ary;!em0;ber;pr1ug0;!ust;!il", - "Date": "true¦t0weekend,yesterd2;mr2o0;d0morrow;ay;!w", + "Date": "true¦ago,t0weekend,yesterd2;mr2o0;d0morrow;ay;!w", "FirstName": "true¦aEblair,cCdevBj8k6lashawn,m3nelly,quinn,re2sh0;ay,e0iloh;a,lby;g1ne;ar1el,org0;an;ion,lo;as8e0r9;ls7nyatta,rry;am0ess1ude;ie,m0;ie;an,on;as0heyenne;ey,sidy;lex1ndra,ubr0;ey;is", "LastName": "true¦0:34;1:3B;2:39;3:2Y;4:2E;5:30;a3Bb31c2Od2Ee2Bf25g1Zh1Pi1Kj1Ek17l0Zm0Nn0Jo0Gp05rYsMtHvFwCxBy8zh6;a6ou,u;ng,o;a6eun2Uoshi1Kun;ma6ng;da,guc1Zmo27sh21zaR;iao,u;a7eb0il6o3right,u;li3Bs2;gn0lk0ng,tanabe;a6ivaldi;ssilj37zqu1;a9h8i2Go7r6sui,urn0;an,ynisJ;lst0Prr1Uth;at1Uomps2;kah0Vnaka,ylor;aEchDeChimizu,iBmiAo9t7u6zabo;ar1lliv2AzuE;a6ein0;l23rm0;sa,u3;rn4th;lva,mmo24ngh;mjon4rrano;midt,neid0ulz;ito,n7sa6to;ki;ch1dLtos,z;amBeag1Zi9o7u6;bio,iz,sD;b6dri1MgIj0Tme24osevelt,ssi,ux;erts,ins2;c6ve0F;ci,hards2;ir1os;aEeAh8ic6ow20ut1N;as6hl0;so;a6illips;m,n1T;ders5et8r7t6;e0Nr4;ez,ry;ers;h21rk0t6vl4;el,te0J;baBg0Blivei01r6;t6w1O;ega,iz;a6eils2guy5ix2owak,ym1E;gy,ka6var1K;ji6muW;ma;aEeCiBo8u6;ll0n6rr0Bssolini,ñ6;oz;lina,oKr6zart;al0Me6r0U;au,no;hhail4ll0;rci0ssi6y0;!er;eWmmad4r6tsu07;in6tin1;!o;aCe8i6op1uo;!n6u;coln,dholm;fe7n0Qr6w0J;oy;bv6v6;re;mmy,rs5u;aBennedy,imuAle0Lo8u7wo6;k,n;mar,znets4;bay6vacs;asY;ra;hn,rl9to,ur,zl4;aAen9ha3imen1o6u3;h6nYu3;an6ns2;ss2;ki0Es5;cks2nsse0D;glesi9ke8noue,shik7to,vano6;u,v;awa;da;as;aBe8itchcock,o7u6;!a3b0ghNynh;a3ffmann,rvat;mingw7nde6rN;rs2;ay;ns5rrQs7y6;asDes;an4hi6;moJ;a9il,o8r7u6;o,tierr1;ayli3ub0;m1nzal1;nd6o,rcia;hi;erAis9lor8o7uj6;ita;st0urni0;es;ch0;nand1;d7insteHsposi6vaL;to;is2wards;aCeBi9omin8u6;bo6rand;is;gu1;az,mitr4;ov;lgado,vi;nkula,rw7vi6;es,s;in;aFhBlarkAo6;h5l6op0rbyn,x;em7li6;ns;an;!e;an8e7iu,o6ristens5u3we;i,ng,u3w,y;!n,on6u3;!g;mpb7rt0st6;ro;ell;aBe8ha3lanco,oyko,r6yrne;ooks,yant;ng;ck7ethov5nnett;en;er,ham;ch,h8iley,rn6;es,i0;er;k,ng;dDl9nd6;ers6rA;en,on,s2;on;eks7iy8var1;ez;ej6;ev;ams", "MaleName": "true¦0:CE;1:BL;2:C2;3:BT;4:B5;5:BZ;6:AT;7:9V;8:BD;9:AX;A:AO;aB4bA8c97d87e7Gf6Yg6Gh5Wi5Ij4Lk4Bl3Rm2Pn2Eo28p22qu20r1As0Qt06u05v00wNxavi3yGzB;aBor0;cBh8Ine;hCkB;!aB1;ar51eB0;ass2i,oCuB;sDu25;nEsDusB;oBsC;uf;ef;at0g;aJeHiCoByaAP;lfgang,odrow;lBn1O;bDey,frBJlB;aA5iB;am,e,s;e89ur;i,nde7sB;!l6t1;de,lCrr5yB;l1ne;lBt3;a93y;aEern1iBladimir;cCha0kt5CnceBrg9Bva0;!nt;ente,t5A;lentin49n8Yughn;lyss4Msm0;aTeOhKiIoErCyB;!l3ro8s1;av9QeBist0oy,um0;nt9Iv54y;bDd7XmBny;!as,mBoharu;aAYie,y;i83y;mBt9;!my,othy;adDeoCia7DomB;!as;!do7M;!de9;dErB;en8HrB;an8GeBy;ll,n8F;!dy;dgh,ic9Tnn3req,ts45;aRcotPeNhJiHoFpenc3tBur1Oylve8Hzym1;anDeBua7B;f0phAFvBwa7A;e57ie;!islaw,l6;lom1nA3uB;leyma8ta;dBl7Jm1;!n6;aDeB;lBrm0;d1t1;h6Sne,qu0Uun,wn,y8;aBbasti0k1Xl41rg40th,ymo9I;m9n;!tB;!ie,y;lCmBnti21q4Iul;!mAu4;ik,vato6V;aWeShe92iOoFuCyB;an,ou;b6LdCf9pe6QssB;!elAI;ol2Uy;an,bIcHdGel,geFh0landA9mEnDry,sCyB;!ce;coe,s;!a95nA;an,eo;l3Jr;e4Qg3n6olfo,ri68;co,ky;bAe9U;cBl6;ar5Oc5NhCkBo;!ey,ie,y;a85ie;gCid,ub5x,yBza;ansh,nS;g8WiB;na8Ss;ch5Yfa4lDmCndBpha4sh6Uul,ymo70;al9Yol2By;i9Ion;f,ph;ent2inB;cy,t1;aFeDhilCier62ol,reB;st1;!ip,lip;d9Brcy,tB;ar,e2V;b3Sdra6Ft44ul;ctav2Vliv3m96rFsCtBum8Uw5;is,to;aCc8SvB;al52;ma;i,l49vJ;athJeHiDoB;aBel,l0ma0r2X;h,m;cCg4i3IkB;h6Uola;hol5XkBol5X;!ol5W;al,d,il,ls1vB;il50;anBy;!a4i4;aWeTiKoFuCyB;l21r1;hamCr5ZstaB;fa,p4G;ed,mF;dibo,e,hamDis1XntCsBussa;es,he;e,y;ad,ed,mB;ad,ed;cGgu4kElDnCtchB;!e7;a78ik;house,o03t1;e,olB;aj;ah,hBk6;a4eB;al,l;hClv2rB;le,ri7v2;di,met;ck,hNlLmOnu4rHs1tDuricCxB;!imilian8Cwe7;e,io;eo,hCi52tB;!eo,hew,ia;eBis;us,w;cDio,k86lCqu6Gsha7tBv2;i2Hy;in,on;!el,oKus;achBcolm,ik;ai,y;amBdi,moud;adB;ou;aReNiMlo2RoIuCyB;le,nd1;cEiDkBth3;aBe;!s;gi,s;as,iaB;no;g0nn6RrenDuBwe7;!iB;e,s;!zo;am,on4;a7Bevi,la4SnDoBst3vi;!nB;!a60el;!ny;mCnBr67ur4Twr4T;ce,d1;ar,o4N;aIeDhaled,iBrist4Vu48y3B;er0p,rB;by,k,ollos;en0iEnBrmit,v2;!dCnBt5C;e0Yy;a7ri4N;r,th;na68rBthem;im,l;aYeQiOoDuB;an,liBst2;an,o,us;aqu2eJhnInGrEsB;eChBi7Bue;!ua;!ph;dBge;an,i,on;!aBny;h,s,th4X;!ath4Wie,nA;!l,sBy;ph;an,e,mB;!mA;d,ffGrDsB;sBus;!e;a5JemCmai8oBry;me,ni0O;i6Uy;!e58rB;ey,y;cHd5kGmFrDsCvi3yB;!d5s1;on,p3;ed,od,rBv4M;e4Zod;al,es,is1;e,ob,ub;k,ob,quB;es;aNbrahMchika,gKkeJlija,nuIrGsDtBv0;ai,sB;uki;aBha0i6Fma4sac;ac,iaB;h,s;a,vinBw2;!g;k,nngu52;!r;nacBor;io;im;in,n;aJeFina4VoDuByd56;be25gBmber4CsD;h,o;m3ra33sBwa3X;se2;aDctCitCn4ErB;be20m0;or;th;bKlJmza,nIo,rDsCyB;a43d5;an,s0;lEo4FrDuBv6;hi40ki,tB;a,o;is1y;an,ey;k,s;!im;ib;aQeMiLlenKoIrEuB;illerCsB;!tavo;mo;aDegBov3;!g,orB;io,y;dy,h57nt;nzaBrd1;lo;!n;lbe4Qno,ovan4R;ne,oDrB;aBry;ld,rd4U;ffr6rge;bri4l5rBv2;la1Zr3Eth,y;aReNiLlJorr0IrB;anDedBitz;!dAeBri24;ri23;cDkB;!ie,lB;in,yn;esJisB;!co,zek;etch3oB;yd;d4lBonn;ip;deriDliCng,rnB;an01;pe,x;co;bi0di;arZdUfrTit0lNmGnFo2rCsteb0th0uge8vBym5zra;an,ere2V;gi,iCnBrol,v2w2;est45ie;c07k;och,rique,zo;aGerFiCmB;aFe2P;lCrB;!h0;!io;s1y;nu4;be09d1iEliDmCt1viBwood;n,s;er,o;ot1Ts;!as,j43sB;ha;a2en;!dAg32mEuCwB;a25in;arB;do;o0Su0S;l,nB;est;aYeOiLoErDuCwByl0;ay8ight;a8dl6nc0st2;ag0ew;minFnDri0ugCyB;le;!l03;!a29nBov0;e7ie,y;go,icB;!k;armuCeBll1on,rk;go;id;anIj0lbeHmetri9nFon,rEsDvCwBxt3;ay8ey;en,in;hawn,mo08;ek,ri0F;is,nBv3;is,y;rt;!dB;re;lKmInHrDvB;e,iB;!d;en,iDne7rByl;eBin,yl;l2Vn;n,o,us;!e,i4ny;iBon;an,en,on;e,lB;as;a06e04hWiar0lLoGrEuCyrB;il,us;rtB;!is;aBistobal;ig;dy,lEnCrB;ey,neli9y;or,rB;ad;by,e,in,l2t1;aGeDiByI;fBnt;fo0Ct1;meCt9velaB;nd;nt;rDuCyB;!t1;de;enB;ce;aFeErisCuB;ck;!tB;i0oph3;st3;d,rlBs;eBie;s,y;cBdric,s11;il;lEmer1rB;ey,lCro7y;ll;!os,t1;eb,v2;ar02eUilTlaSoPrCuByr1;ddy,rtI;aJeEiDuCyB;an,ce,on;ce,no;an,ce;nCtB;!t;dCtB;!on;an,on;dCndB;en,on;!foBl6y;rd;bCrByd;is;!by;i8ke;al,lA;nFrBshoi;at,nCtB;!r10;aBie;rd0S;!edict,iCjam2nA;ie,y;to;n6rBt;eBy;tt;ey;ar0Xb0Nd0Jgust2hm0Gid5ja0ElZmXnPputsiOrFsaEuCveBya0ziz;ry;gust9st2;us;hi;aIchHi4jun,maFnDon,tBy0;hBu06;ur;av,oB;ld;an,nd0A;el;ie;ta;aq;dGgel05tB;hoEoB;i8nB;!i02y;ne;ny;reBy;!as,s,w;ir,mBos;ar;an,beOd5eIfFi,lEonDphonHt1vB;aMin;on;so,zo;an,en;onCrB;edP;so;c,jaEksandDssaExB;!and3;er;ar,er;ndB;ro;rtH;ni;en;ad,eB;d,t;in;aColfBri0vik;!o;mBn;!a;dFeEraCuB;!bakr,lfazl;hBm;am;!l;allEel,oulaye,ulB;!lCrahm0;an;ah,o;ah;av,on", diff --git a/src/_version.js b/src/_version.js index afa20f744..797c2571a 100644 --- a/src/_version.js +++ b/src/_version.js @@ -1 +1 @@ -module.exports = '13.3.2' \ No newline at end of file +module.exports = '13.4.0' \ No newline at end of file diff --git a/tests/verbs/misc.test.js b/tests/verbs/misc.test.js index 680e8c124..ee23bff65 100644 --- a/tests/verbs/misc.test.js +++ b/tests/verbs/misc.test.js @@ -21,3 +21,31 @@ test('verbs.adverbs', function (t) { t.end() }) + +test('dont conjugate modals', function (t) { + let doc = nlp('i may') + doc.verbs().toPastTense() + t.equal(doc.out(), 'i may have', 'may') + + doc = nlp('i think he really could.') + doc.verbs().toPastTense() + t.equal(doc.out(), 'i thought he really could have.', 'really could') + + doc = nlp('everybody ought to.') + doc.verbs().toPastTense() + t.equal(doc.out(), 'everybody ought to have.', 'ought to') + + t.end() +}) + +// test('detect participle in past-tense', function (t) { +// let doc = nlp('everybody ought to swim.') +// doc.verbs().toPastTense() +// t.equal(doc.out(), 'everybody ought to have swam.', 'ought to swim') + +// doc = nlp('i think he really could have.') +// doc.verbs().toPastTense() +// t.equal(doc.out(), 'i thought he really could have.', 'really could') + +// t.end() +// }) diff --git a/tests/verbs/modal.test.js b/tests/verbs/modal.test.js index 2e07bbccf..b81e16c2c 100644 --- a/tests/verbs/modal.test.js +++ b/tests/verbs/modal.test.js @@ -2,14 +2,14 @@ const test = require('tape') const nlp = require('../_lib') //ignore some modals during conjugation, i guess -test('ignore-would-behaviour', t => { +test('modal-verb conjugation', t => { let doc = nlp('he would walk') doc.verbs().toPastTense() - t.equal(doc.text(), 'he walked', 'would-past') + t.equal(doc.text(), 'he would have walked', 'would-past') doc = nlp('he would walk') doc.verbs().toFutureTense() - t.equal(doc.out(), 'he will walk', 'would-future') + t.equal(doc.out(), 'he would walk', 'would-future') doc = nlp('he would walk') doc.verbs().toPresentTense() diff --git a/tests/verbs/toParticiple.test.js b/tests/verbs/toParticiple.test.js new file mode 100644 index 000000000..64bee99b9 --- /dev/null +++ b/tests/verbs/toParticiple.test.js @@ -0,0 +1,19 @@ +const test = require('tape') +const nlp = require('../_lib') + +test('toParticiple', function (t) { + let arr = [ + ['i drive', 'i have driven'], + ['we smoke', 'we have smoked'], + // ['i will go', 'i will have gone'], //still future-tense? + ['they all swim', 'they all have swam'], + ['i learn', 'i have learned'], + ['i really travel to india', 'i really have traveled to india'], + ] + arr.forEach(a => { + let doc = nlp(a[0]) + doc.verbs().toParticiple() + t.equal(doc.text(), a[1], a[0]) + }) + t.end() +}) diff --git a/tests/verbs/toPast.test.js b/tests/verbs/toPast.test.js index 510fd6270..de54778f5 100644 --- a/tests/verbs/toPast.test.js +++ b/tests/verbs/toPast.test.js @@ -1,7 +1,7 @@ const test = require('tape') const nlp = require('../_lib') -test('ake-suffix toPast:', function(t) { +test('ake-suffix toPast:', function (t) { let arr = [ //oke ['awakes', 'awoke'], @@ -22,12 +22,26 @@ test('ake-suffix toPast:', function(t) { ['fakes', 'faked'], ['snakes', 'snaked'], ] - arr.forEach(function(a) { - const str = nlp(a[0]) - .verbs() - .toPastTense() - .out('normal') + arr.forEach(function (a) { + const str = nlp(a[0]).verbs().toPastTense().out('normal') t.equal(str, a[1], a[0] + ' -> ' + str) }) t.end() }) + +test('sneaky past participles', function (t) { + let arr = [ + // present + ['i am being driven', 'i have been driven'], + ['i should be driven', 'i should have been driven'], + // past->past + ['i had been driven', 'i had been driven'], + ['i should have been driven', 'i should have been driven'], + ] + arr.forEach(function (a) { + let doc = nlp(a[0]) + doc.verbs().toPastTense() + t.equal(doc.text(), a[1], a[0]) + }) + t.end() +}) diff --git a/types/index.d.ts b/types/index.d.ts index f7bac7a3d..69f01e133 100644 --- a/types/index.d.ts +++ b/types/index.d.ts @@ -424,6 +424,8 @@ declare module nlp { toInfinitive(): ExtendedDocument /** 'walks' → 'walking' */ toGerund(): ExtendedDocument + /** 'drive' → 'driven' if it exists, otherwise past-tense */ + toParticiple(): ExtendedDocument /** return verbs with 'not' */ isNegative(): ExtendedDocument /** only verbs without 'not'*/